/* Landing e páginas públicas. Mesmos tokens e fontes do painel (admin.css), com os
   pares de contraste já validados em WCAG AA. Fontes servidas pelo próprio app. */
@font-face {
  font-family: "Fraunces";
  src: url("/static/fonts/fraunces-latin-var.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Work Sans";
  src: url("/static/fonts/work-sans-latin-var.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  color-scheme: light;
  --bg: #FBF1EC;
  --surface: #F7E2DC;
  --card: #FFFFFF;
  --text: #3A2A24;
  --muted: #6E5A52;
  --border: #EBCFC6;
  --accent: #C3264C;       /* branco sobre ele 5.67:1; ele sobre fundo 5.10:1, sobre painel 4.56:1 */
  --accent-hover: #A51F40;
  --accent-soft: #E0607F;  /* só decorativo, nunca com texto por cima */
  --ink: #3A2A24;          /* fundo do aviso de DM no mockup: branco sobre ele 14:1 */
  --font-body: "Work Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font: 17px/1.6 var(--font-body); background: var(--bg); color: var(--text); }
h1, h2, h3, .logo { font-family: var(--font-display); letter-spacing: -0.015em; }
h2 { font-size: clamp(26px, 3.2vw, 34px); line-height: 1.2; margin: 0 0 28px; font-weight: 650; }
h3 { font-size: 20px; margin: 0 0 8px; font-weight: 650; }
p { margin: 0 0 16px; }
a { color: var(--accent); }
a:hover { color: var(--accent-hover); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.container { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 760px; }
.center { text-align: center; }
.muted { color: var(--muted); }
.eyebrow { color: var(--accent); font-weight: 600; font-size: 14px; letter-spacing: 0.04em; text-transform: uppercase; margin-bottom: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 16px; top: -48px; padding: 8px 12px; background: var(--card); color: var(--accent); border-radius: 6px; z-index: 20; }
.skip-link:focus { top: 8px; }

.button { display: inline-block; padding: 14px 26px; font-weight: 600; color: #FFFFFF; background: var(--accent); border-radius: 999px; text-decoration: none; box-shadow: 0 6px 18px rgba(195, 38, 76, 0.22); transition: background .15s ease, transform .15s ease; }
.button:hover { color: #FFFFFF; background: var(--accent-hover); transform: translateY(-1px); }

/* Nav fixa */
.site-nav { position: sticky; top: 0; z-index: 10; background: rgba(251, 241, 236, 0.92); backdrop-filter: saturate(1.2) blur(8px); border-bottom: 1px solid var(--border); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.logo { font-size: 22px; font-weight: 700; color: var(--text); text-decoration: none; }
.logo span { color: var(--accent); }
.nav-link { font-weight: 600; text-decoration: none; }

/* Hero */
.hero { padding: 64px 0 56px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 48px; align-items: center; }
.hero h1 { font-size: clamp(38px, 6vw, 64px); line-height: 1.05; margin: 0 0 20px; font-weight: 700; }
.lead { font-size: 19px; max-width: 34ch; margin-bottom: 28px; }
.trust { margin-top: 18px; font-size: 14px; color: var(--muted); max-width: 40ch; }

/* Mockup do celular — só CSS, elementos genéricos (sem logo/glifo do Instagram) */
.phone { justify-self: center; width: min(320px, 100%); aspect-ratio: 9 / 18.5; padding: 12px; background: var(--ink); border-radius: 44px; box-shadow: 0 30px 60px rgba(58, 42, 36, 0.25); }
.phone-screen { position: relative; height: 100%; overflow: hidden; background: var(--card); border-radius: 34px; font-size: 13px; line-height: 1.4; color: var(--text); }
.phone-status { display: flex; justify-content: space-between; align-items: center; padding: 10px 20px 6px; font-size: 11px; font-weight: 600; }
.phone-notch { width: 70px; height: 18px; background: var(--ink); border-radius: 12px; }
.post-head { display: flex; align-items: center; gap: 8px; padding: 6px 12px; }
.post-head .dots { margin-left: auto; color: var(--muted); }
.avatar { flex: none; width: 28px; height: 28px; border-radius: 50%; background: linear-gradient(135deg, var(--accent-soft), var(--accent)); }
.avatar.sm { width: 22px; height: 22px; }
.avatar.a2 { background: linear-gradient(135deg, #E9C9A8, #B98A6A); }
.post-media { position: relative; height: 40%; background: linear-gradient(160deg, #F3D6D9 0%, #E7B7A8 55%, #D98A96 100%); }
.play { position: absolute; left: 50%; top: 50%; width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%; background: rgba(255, 255, 255, 0.75); }
.play::after { content: ""; position: absolute; left: 18px; top: 14px; border-style: solid; border-width: 9px 0 9px 14px; border-color: transparent transparent transparent var(--ink); }
.post-actions { display: flex; gap: 12px; padding: 8px 12px 2px; color: var(--text); }
.post-caption { margin: 6px 12px 2px; }
.post-more { margin: 0 12px 4px; color: var(--muted); font-size: 12px; }
.comments { list-style: none; margin: 0; padding: 0 12px; }
.comment { display: flex; gap: 8px; align-items: flex-start; margin: 8px 0; }
.comment p { margin: 0; }
.comment.reply { margin-left: 22px; }
.dm-toast { position: absolute; left: 10px; right: 10px; top: 34px; display: flex; gap: 10px; align-items: center; padding: 10px 12px; color: #FFFFFF; background: var(--ink); border-radius: 16px; box-shadow: 0 10px 24px rgba(58, 42, 36, 0.3); }
.dm-toast p { margin: 0; display: grid; }
.dm-toast span:not(.avatar) { color: #F3D6D9; font-size: 12px; }

/* Sequência: comentário → resposta → aviso de DM, em loop */
.c1 { animation: appear 9s ease infinite; animation-delay: 0s; }
.c2 { animation: appear 9s ease infinite; animation-delay: 1.4s; }
.dm-toast { animation: drop 9s ease infinite; animation-delay: 2.8s; }
@keyframes appear {
  0% { opacity: 0; transform: translateY(6px); }
  6%, 85% { opacity: 1; transform: none; }
  95%, 100% { opacity: 0; }
}
@keyframes drop {
  0% { opacity: 0; transform: translateY(-120%); }
  6%, 70% { opacity: 1; transform: none; }
  80%, 100% { opacity: 0; transform: translateY(-120%); }
}
.c1, .c2, .dm-toast { opacity: 0; animation-fill-mode: both; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .c1, .c2, .dm-toast { animation: none; opacity: 1; transform: none; }
  .dm-toast { top: auto; bottom: 14px; }
  .button { transition: none; }
}

/* Contadores */
.stats { padding: 8px 0 48px; }
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; margin: 0; }
.stats-grid > div { padding: 24px; background: var(--surface); border: 1px solid var(--border); border-radius: 18px; display: flex; flex-direction: column-reverse; gap: 4px; }
.stats-grid dd { margin: 0; font-family: var(--font-display); font-size: clamp(34px, 5vw, 48px); font-weight: 700; line-height: 1; color: var(--accent); }
.stats-grid dt { color: var(--muted); font-weight: 500; }
.stats-note { margin-top: 14px; font-size: 14px; color: var(--muted); }

/* Passos */
.steps, .features, .faq { padding: 56px 0; }
.steps-grid, .features-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 20px; }
.steps-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.steps-grid li { padding: 28px; background: var(--card); border: 1px solid var(--border); border-radius: 20px; }
.step-n { display: block; margin-bottom: 14px; font-family: var(--font-display); font-size: 40px; font-weight: 700; line-height: 1; color: var(--accent); }
.steps-grid p, .features-grid p { color: var(--muted); margin: 0; }

/* Recursos */
.features { background: var(--surface); border-block: 1px solid var(--border); }
.features-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.features-grid li { padding: 24px 24px 24px 20px; background: var(--card); border-radius: 16px; border-left: 4px solid var(--accent-soft); }

/* FAQ nativo */
.faq details { background: var(--card); border: 1px solid var(--border); border-radius: 14px; padding: 0 20px; margin-bottom: 12px; }
.faq summary { cursor: pointer; padding: 18px 0; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--accent); font-size: 22px; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { color: var(--muted); padding-bottom: 18px; margin: 0; }

.cta-final { padding: 40px 0 72px; }

/* Rodapé */
.site-footer { border-top: 1px solid var(--border); background: var(--surface); padding: 28px 0; }
.footer-inner { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; }
.site-footer nav { display: flex; gap: 20px; flex-wrap: wrap; }
.site-footer nav a { font-weight: 500; }

/* Política de Privacidade */
.legal { padding-top: 48px; padding-bottom: 72px; }
.legal-head h1 { font-size: clamp(32px, 4.5vw, 44px); line-height: 1.15; margin: 0 0 8px; font-weight: 700; }
.legal-head { margin-bottom: 32px; }
.legal-body { background: var(--card); border: 1px solid var(--border); border-radius: 18px; padding: clamp(24px, 4vw, 44px); }
.legal-body section + section { margin-top: 28px; padding-top: 28px; border-top: 1px solid var(--border); }
.legal-body h2 { font-size: 22px; margin-bottom: 12px; }
.legal-body p, .legal-body li { max-width: 64ch; }
.legal-body ul { padding-left: 20px; margin: 0 0 16px; }
.legal-body li { margin-bottom: 6px; }
.contact-box { display: inline-block; padding: 12px 18px; background: var(--surface); border-radius: 10px; font-weight: 600; }

@media (max-width: 860px) {
  .hero { padding-top: 40px; }
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .steps-grid, .stats-grid { grid-template-columns: minmax(0, 1fr); }
  .features-grid { grid-template-columns: minmax(0, 1fr); }
}
