/*
 * Public site styles transferred from the legacy site (book-quote-publisher):
 * - home page: nginx/html/index.html inline styles
 * - quote page: app/web/templates/public_quote.html inline styles
 * Page-specific rules are namespaced with the body class (page-home/page-quote).
 */

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

/* Home page (legacy landing) */
body.page-home {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: #f8fafc;
  color: #1e293b;
  padding: 1.5rem;
}

.page-home .card {
  text-align: center;
  max-width: 28rem;
}

.page-home .avatar {
  width: 7rem;
  height: 7rem;
  border-radius: 50%;
  margin-bottom: 1.5rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.page-home h1 {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 0.75rem;
}

.page-home .accent {
  color: #6366f1;
}

.page-home .quote {
  font-size: 1rem;
  color: #475569;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.page-home .quote cite {
  display: block;
  font-style: normal;
  font-size: 0.875rem;
  color: #94a3b8;
  margin-top: 0.375rem;
}

.page-home .subtitle {
  font-size: 1.125rem;
  color: #64748b;
  line-height: 1.6;
  margin-bottom: 2rem;
}

.page-home .socials {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  margin-bottom: 2rem;
}

.page-home .social-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  text-decoration: none;
  color: #fff;
  transition: transform 0.15s, box-shadow 0.15s;
}

.page-home .social-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.page-home .social-btn svg {
  width: 1.5rem;
  height: 1.5rem;
  fill: currentColor;
}

.page-home .tg { background: #2AABEE; }
.page-home .vk { background: #0077FF; }
.page-home .dzen { background: #000; }
.page-home .yandex { background: #2DC6F5; }

.page-home .badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #eef2ff;
  color: #4f46e5;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 9999px;
}

.page-home .dot {
  width: 0.5rem;
  height: 0.5rem;
  background: #6366f1;
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* Quote page (legacy chat bubble) */
body.page-quote {
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: #e6ddd4;
  color: #1e293b;
  padding: 1rem;
}

.page-quote .chat {
  max-width: 30rem;
  width: 100%;
}

.page-quote .message {
  display: flex;
  align-items: flex-end;
}

.page-quote .avatar {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  flex-shrink: 0;
}

.page-quote .bubble {
  position: relative;
  background: #fff;
  border-radius: 10px;
  padding: 5px 8px 4px;
  margin-left: 6px;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.12);
  text-align: left;
  font-size: 0.9375rem;
  line-height: 1.4;
  color: #000;
  word-wrap: break-word;
  max-width: 85%;
}

.page-quote .bubble .text {
  white-space: pre-line;
}

.page-quote .quote-image {
  display: block;
  width: calc(100% + 16px);
  max-height: 28rem;
  object-fit: cover;
  border-radius: 7px 7px 0 0;
  margin: 6px -8px 6px;
}

.page-quote .sender {
  font-size: 0.8125rem;
  font-weight: 500;
  color: #3a6ea5;
  white-space: nowrap;
  line-height: 1.2;
}

.page-quote .time {
  display: inline-block;
  float: right;
  font-size: 0.6875rem;
  color: #8e8e8e;
  margin-left: 8px;
  margin-top: 4px;
  white-space: nowrap;
}

.page-quote .sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
