/* ==========================================================================
   SmartAgendaIA — Landing page
   Design tokens copiados VERBATIM de frontend/src/index.css (produto Omnichat).
   Tema claro por padrão (:root) + escuro ([data-theme="dark"]), igual ao app.
   ========================================================================== */

:root {
  /* Core palette — Professional teal with warm neutrals */
  --background: 210 20% 98%;
  --foreground: 222 47% 11%;

  --card: 0 0% 100%;
  --card-foreground: 222 47% 11%;

  /* Primary — Rich Teal */
  --primary: 173 58% 39%;
  --primary-foreground: 0 0% 100%;

  /* Secondary — Soft slate */
  --secondary: 215 20% 95%;
  --secondary-foreground: 222 47% 11%;

  /* Muted — Gentle gray */
  --muted: 215 20% 94%;
  --muted-foreground: 215 16% 47%;

  /* Accent — Lighter teal */
  --accent: 173 45% 93%;
  --accent-foreground: 173 58% 30%;

  /* UI elements */
  --border: 215 20% 91%;
  --input: 215 20% 91%;
  --ring: 173 58% 39%;
  --radius: 0.625rem;

  /* Status / canais */
  --success: 142 71% 45%;
  --warning: 38 92% 50%;
  --info: 199 89% 48%;
  --whatsapp: 142 70% 45%;

  /* Sidebar / superfícies escuras (usadas no rodapé e mock) */
  --sidebar-background: 222 47% 11%;
  --sidebar-foreground: 215 20% 85%;
  --sidebar-border: 222 30% 20%;

  /* Chat (usado no mock do hero) */
  --chat-inbound: 215 20% 95%;
  --chat-outbound: 173 45% 90%;

  /* Gradientes do produto */
  --gradient-primary: linear-gradient(135deg, hsl(173 58% 39%), hsl(173 58% 32%));
  --gradient-hero: linear-gradient(135deg, hsl(173 58% 39%), hsl(199 89% 48%));

  --shadow-card: 0 1px 3px 0 rgb(0 0 0 / 0.04), 0 1px 2px -1px rgb(0 0 0 / 0.04);
  --shadow-card-hover: 0 4px 6px -1px rgb(0 0 0 / 0.06), 0 2px 4px -2px rgb(0 0 0 / 0.06);
}

[data-theme="dark"] {
  --background: 222 47% 6%;
  --foreground: 215 20% 95%;

  --card: 222 47% 9%;
  --card-foreground: 215 20% 95%;

  --primary: 173 58% 45%;
  --primary-foreground: 0 0% 100%;

  --secondary: 222 35% 18%;
  --secondary-foreground: 215 20% 95%;

  --muted: 222 35% 18%;
  --muted-foreground: 215 16% 55%;

  --accent: 222 35% 22%;
  --accent-foreground: 173 58% 55%;

  --border: 222 30% 20%;
  --input: 222 30% 20%;
  --ring: 173 58% 45%;

  --sidebar-background: 222 50% 6%;
  --sidebar-foreground: 215 20% 80%;
  --sidebar-border: 222 35% 15%;

  --chat-inbound: 222 35% 18%;
  --chat-outbound: 173 40% 20%;

  --shadow-card: 0 1px 3px 0 rgb(0 0 0 / 0.4), 0 1px 2px -1px rgb(0 0 0 / 0.4);
  --shadow-card-hover: 0 8px 24px -6px rgb(0 0 0 / 0.5);
}

/* ----------------------------------------------------------------- Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-feature-settings: "cv02", "cv03", "cv04", "cv11";
  background: hsl(var(--background));
  color: hsl(var(--foreground));
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

::selection { background: hsl(var(--primary) / 0.2); }

/* Scrollbar — igual ao app (thin) */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: hsl(var(--border)); border-radius: 999px; }
::-webkit-scrollbar-thumb:hover { background: hsl(var(--muted-foreground) / 0.4); }

/* --------------------------------------------------------------- Layout */
.container { width: 100%; max-width: 1140px; margin: 0 auto; padding: 0 24px; }
.section { padding: 88px 0; }
.section-sm { padding: 56px 0; }

.eyebrow {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: hsl(var(--primary));
  margin-bottom: 14px;
}
.section-head { max-width: 680px; margin: 0 auto 52px; text-align: center; }
.section-head h2 {
  font-size: clamp(1.75rem, 1.1rem + 2.4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
}
.section-head p {
  margin-top: 16px;
  font-size: 1.0625rem;
  color: hsl(var(--muted-foreground));
}

/* --------------------------------------------------------------- Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: inherit; font-size: 0.95rem; font-weight: 600;
  border-radius: var(--radius);
  padding: 0 20px; height: 44px;
  cursor: pointer; border: 1px solid transparent;
  white-space: nowrap; transition: background-color .18s ease, color .18s ease, border-color .18s ease, transform .18s ease, box-shadow .18s ease;
}
.btn:active { transform: translateY(1px); }
.btn-lg { height: 52px; padding: 0 28px; font-size: 1.0625rem; }
.btn-block { width: 100%; }

.btn-primary { background: hsl(var(--primary)); color: hsl(var(--primary-foreground)); }
.btn-primary:hover { background: hsl(var(--primary) / 0.9); box-shadow: 0 8px 20px -6px hsl(var(--primary) / 0.5); }

.btn-outline { border-color: hsl(var(--input)); background: hsl(var(--card)); color: hsl(var(--foreground)); }
.btn-outline:hover { background: hsl(var(--accent)); color: hsl(var(--accent-foreground)); border-color: hsl(var(--accent)); }

.btn-ghost { background: transparent; color: hsl(var(--foreground)); }
.btn-ghost:hover { background: hsl(var(--accent)); color: hsl(var(--accent-foreground)); }

.btn-white { background: #fff; color: hsl(173 58% 30%); }
.btn-white:hover { background: hsl(0 0% 100% / 0.9); }
.btn-onhero-outline { border-color: hsl(0 0% 100% / 0.45); color: #fff; background: hsl(0 0% 100% / 0.08); }
.btn-onhero-outline:hover { background: hsl(0 0% 100% / 0.16); }

/* --------------------------------------------------------------- Icon chip */
.icon-chip {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: calc(var(--radius) + 2px);
  background: hsl(var(--primary) / 0.1); color: hsl(var(--primary));
  flex-shrink: 0;
}
.icon-chip svg { width: 24px; height: 24px; }

/* --------------------------------------------------------------- Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: hsl(var(--card) / 0.85);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid hsl(var(--border));
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.15rem; letter-spacing: -0.01em; }
.brand img { width: 34px; height: 34px; object-fit: contain; }
.brand b { color: hsl(var(--primary)); font-weight: 800; }

.nav { display: flex; align-items: center; gap: 4px; }
.nav a.navlink {
  padding: 8px 14px; border-radius: var(--radius);
  font-size: 0.95rem; font-weight: 500; color: hsl(var(--muted-foreground));
  transition: background-color .15s, color .15s;
}
.nav a.navlink:hover { color: hsl(var(--foreground)); background: hsl(var(--accent)); }

.header-actions { display: flex; align-items: center; gap: 8px; }

.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; border-radius: var(--radius);
  background: transparent; border: none; cursor: pointer; color: hsl(var(--muted-foreground));
  transition: background-color .15s, color .15s;
}
.icon-btn:hover { background: hsl(var(--accent)); color: hsl(var(--accent-foreground)); }
.icon-btn svg { width: 20px; height: 20px; }

.theme-toggle .moon { display: none; }
[data-theme="dark"] .theme-toggle .sun { display: none; }
[data-theme="dark"] .theme-toggle .moon { display: block; }

.menu-toggle { display: none; }
.mobile-only { display: none; }

/* --------------------------------------------------------------- Hero */
.hero {
  position: relative; overflow: hidden;
  padding: 96px 0 84px;
  background:
    radial-gradient(1200px 480px at 85% -10%, hsl(var(--accent) / 0.6), transparent 70%),
    radial-gradient(900px 420px at 10% 0%, hsl(var(--primary) / 0.07), transparent 65%),
    hsl(var(--background));
}
.hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center; }
.badge-pill {
  display: inline-flex; align-items: center; gap: 8px;
  background: hsl(var(--card)); border: 1px solid hsl(var(--border));
  padding: 7px 14px; border-radius: 999px; font-size: 0.85rem; font-weight: 600;
  color: hsl(var(--muted-foreground)); box-shadow: var(--shadow-card);
}
.badge-pill .dot { width: 8px; height: 8px; border-radius: 50%; background: hsl(var(--whatsapp)); box-shadow: 0 0 0 4px hsl(var(--whatsapp) / 0.18); }

.hero h1 {
  margin-top: 22px;
  font-size: clamp(2.1rem, 1.1rem + 3.6vw, 3.4rem);
  font-weight: 800; letter-spacing: -0.025em; line-height: 1.07;
}
.hero h1 .grad {
  background: var(--gradient-hero);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-sub { margin-top: 22px; font-size: 1.15rem; color: hsl(var(--muted-foreground)); max-width: 540px; }
.hero-cta { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 14px; }
.hero-trust { margin-top: 20px; font-size: 0.875rem; color: hsl(var(--muted-foreground)); display: flex; align-items: center; gap: 8px; }
.hero-trust svg { width: 18px; height: 18px; color: hsl(var(--whatsapp)); }

/* Hero mock — conversa WhatsApp + cartão de agenda (CSS puro) */
.mock { position: relative; }
.phone {
  background: hsl(var(--card)); border: 1px solid hsl(var(--border));
  border-radius: 24px; box-shadow: 0 24px 60px -20px hsl(222 47% 11% / 0.28); padding: 14px;
  max-width: 360px; margin: 0 auto;
}
.phone-top { display: flex; align-items: center; gap: 10px; padding: 6px 6px 12px; border-bottom: 1px solid hsl(var(--border)); }
.phone-avatar { width: 38px; height: 38px; border-radius: 50%; background: var(--gradient-primary); display: flex; align-items: center; justify-content: center; color: #fff; }
.phone-avatar svg { width: 20px; height: 20px; }
.phone-name { font-weight: 600; font-size: 0.95rem; }
.phone-status { font-size: 0.75rem; color: hsl(var(--whatsapp)); font-weight: 500; }
.chat { padding: 14px 6px 6px; display: flex; flex-direction: column; gap: 10px; }
.bubble { max-width: 80%; padding: 9px 13px; border-radius: 14px; font-size: 0.9rem; line-height: 1.4; }
.bubble.in { align-self: flex-start; background: hsl(var(--chat-inbound)); border-bottom-left-radius: 4px; color: hsl(var(--foreground)); }
.bubble.out { align-self: flex-end; background: hsl(var(--chat-outbound)); border-bottom-right-radius: 4px; color: hsl(173 58% 22%); }
[data-theme="dark"] .bubble.out { color: hsl(var(--foreground)); }
.bubble small { display: block; font-size: 0.68rem; opacity: 0.6; margin-top: 3px; }

.mini-cal {
  position: absolute; right: -18px; bottom: -22px; width: 210px;
  background: hsl(var(--card)); border: 1px solid hsl(var(--border));
  border-radius: var(--radius); box-shadow: var(--shadow-card-hover); padding: 14px;
}
.mini-cal h4 { font-size: 0.78rem; color: hsl(var(--muted-foreground)); font-weight: 600; margin-bottom: 10px; display: flex; align-items: center; gap: 6px; }
.mini-cal h4 svg { width: 15px; height: 15px; color: hsl(var(--primary)); }
.cal-row { display: flex; align-items: center; gap: 8px; font-size: 0.8rem; padding: 6px 0; }
.cal-dot { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
.cal-row b { font-weight: 600; }
.cal-row span { color: hsl(var(--muted-foreground)); margin-left: auto; }

/* --------------------------------------------------------------- Stats strip */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; text-align: center; }
.stats .stat b { display: block; font-size: 2rem; font-weight: 800; color: hsl(var(--primary)); letter-spacing: -0.02em; }
.stats .stat span { font-size: 0.95rem; color: hsl(var(--muted-foreground)); }

/* --------------------------------------------------------------- Cards / grids */
.card {
  background: hsl(var(--card)); border: 1px solid hsl(var(--border));
  border-radius: var(--radius); box-shadow: var(--shadow-card);
  padding: 28px; transition: box-shadow .2s ease, transform .2s ease;
}
.card:hover { box-shadow: var(--shadow-card-hover); transform: translateY(-3px); }
.card h3 { font-size: 1.2rem; font-weight: 700; margin: 18px 0 8px; letter-spacing: -0.01em; }
.card p { color: hsl(var(--muted-foreground)); font-size: 0.975rem; }

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }

/* --------------------------------------------------------------- How it works */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; counter-reset: step; }
.step { position: relative; padding: 26px; background: hsl(var(--card)); border: 1px solid hsl(var(--border)); border-radius: var(--radius); }
.step .num {
  counter-increment: step;
  width: 38px; height: 38px; border-radius: 50%;
  background: hsl(var(--primary) / 0.1); color: hsl(var(--primary));
  display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 1rem; margin-bottom: 14px;
}
.step .num::before { content: counter(step); }
.step h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 6px; }
.step p { font-size: 0.925rem; color: hsl(var(--muted-foreground)); }

/* --------------------------------------------------------------- Assist band */
.assist {
  background: hsl(var(--sidebar-background));
  color: hsl(var(--sidebar-foreground));
  border-radius: calc(var(--radius) + 6px);
  padding: 48px; display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; align-items: center;
}
.assist .eyebrow { color: hsl(173 58% 60%); }
.assist h2 { color: #fff; font-size: clamp(1.6rem, 1.1rem + 1.8vw, 2.2rem); font-weight: 700; letter-spacing: -0.02em; line-height: 1.2; }
.assist p { margin-top: 16px; color: hsl(215 20% 78%); font-size: 1.05rem; }
.assist ul { list-style: none; display: flex; flex-direction: column; gap: 14px; }
.assist li { display: flex; gap: 12px; align-items: flex-start; font-size: 1rem; }
.assist li svg { width: 22px; height: 22px; color: hsl(173 58% 55%); flex-shrink: 0; margin-top: 1px; }

/* --------------------------------------------------------------- Roadmap / omnichannel */
.roadmap-card { position: relative; }
.soon {
  position: absolute; top: 20px; right: 20px;
  font-size: 0.7rem; font-weight: 700; letter-spacing: 0.03em; text-transform: uppercase;
  color: hsl(var(--warning)); background: hsl(var(--warning) / 0.12);
  padding: 4px 10px; border-radius: 999px;
}
.roadmap-card .icon-chip.alt { background: hsl(var(--info) / 0.12); color: hsl(var(--info)); }
.roadmap-note { text-align: center; margin-top: 28px; font-size: 0.925rem; color: hsl(var(--muted-foreground)); }

/* --------------------------------------------------------------- Testimonials */
.placeholder-note {
  text-align: center; font-size: 0.8rem; color: hsl(var(--muted-foreground));
  background: hsl(var(--muted)); border: 1px dashed hsl(var(--border));
  border-radius: 999px; padding: 6px 16px; display: inline-block; margin: 0 auto 32px;
}
.t-card { display: flex; flex-direction: column; gap: 16px; }
.t-card p { font-size: 1.0125rem; color: hsl(var(--foreground)); }
.t-author { display: flex; align-items: center; gap: 12px; margin-top: auto; }
.t-avatar { width: 44px; height: 44px; border-radius: 50%; background: hsl(var(--accent)); color: hsl(var(--accent-foreground)); display: flex; align-items: center; justify-content: center; font-weight: 700; }
.t-author b { display: block; font-size: 0.95rem; }
.t-author span { font-size: 0.825rem; color: hsl(var(--muted-foreground)); }
.stars { display: flex; gap: 2px; color: hsl(var(--warning)); }
.stars svg { width: 18px; height: 18px; }

.logos { display: flex; flex-wrap: wrap; justify-content: center; gap: 18px; margin-top: 44px; }
.logo-ph {
  height: 38px; min-width: 130px; border-radius: var(--radius);
  background: hsl(var(--muted)); border: 1px solid hsl(var(--border));
  display: flex; align-items: center; justify-content: center;
  font-size: 0.8rem; font-weight: 600; color: hsl(var(--muted-foreground)); opacity: 0.8;
}

/* --------------------------------------------------------------- Final CTA */
.final-cta {
  position: relative; overflow: hidden;
  background: var(--gradient-hero); color: #fff;
  border-radius: calc(var(--radius) + 8px);
  padding: 64px 48px; text-align: center;
}
.final-cta h2 { font-size: clamp(1.7rem, 1.1rem + 2.2vw, 2.4rem); font-weight: 800; letter-spacing: -0.02em; }
.final-cta p { margin: 16px auto 0; max-width: 520px; font-size: 1.0625rem; opacity: 0.95; }
.final-cta .hero-cta { justify-content: center; margin-top: 30px; }
.final-cta .blob { position: absolute; border-radius: 50%; background: #fff; opacity: 0.1; }
.final-cta .blob.x1 { width: 360px; height: 360px; right: -120px; top: -120px; }
.final-cta .blob.x2 { width: 240px; height: 240px; left: -80px; bottom: -120px; opacity: 0.08; }

/* --------------------------------------------------------------- Footer */
.site-footer { background: hsl(var(--sidebar-background)); color: hsl(var(--sidebar-foreground)); padding: 56px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 40px; }
.site-footer .brand { color: #fff; }
.site-footer .brand b { color: hsl(173 58% 60%); }
.footer-about { margin-top: 14px; font-size: 0.925rem; color: hsl(215 20% 70%); max-width: 320px; }
.footer-col h4 { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.04em; color: hsl(215 20% 60%); margin-bottom: 14px; }
.footer-col a { display: block; padding: 5px 0; font-size: 0.95rem; color: hsl(215 20% 82%); transition: color .15s; }
.footer-col a:hover { color: #fff; }
.footer-bottom {
  margin-top: 40px; padding-top: 22px; border-top: 1px solid hsl(var(--sidebar-border));
  display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap;
  font-size: 0.85rem; color: hsl(215 20% 62%);
}

/* --------------------------------------------------------------- Animations */
@keyframes fade-up { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
.reveal { opacity: 0; }
.reveal.in-view { animation: fade-up 0.5s ease-out forwards; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1 !important; animation: none !important; }
  html { scroll-behavior: auto; }
}

/* --------------------------------------------------------------- Responsive */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 48px; }
  .mock { max-width: 380px; margin: 0 auto; }
  .grid-3, .steps { grid-template-columns: repeat(2, 1fr); }
  .assist { grid-template-columns: 1fr; padding: 36px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  .section { padding: 64px 0; }
  .nav, .header-actions .desktop-only { display: none; }
  .menu-toggle { display: inline-flex; }
  .nav.open {
    display: flex; flex-direction: column; align-items: stretch; gap: 4px;
    position: absolute; left: 0; right: 0; top: 68px;
    background: hsl(var(--card)); border-bottom: 1px solid hsl(var(--border));
    padding: 12px 24px 18px; box-shadow: var(--shadow-card-hover);
  }
  .nav.open a.navlink { padding: 12px 14px; }
  .nav.open .mobile-only { display: inline-flex; }
  .nav.open .btn { margin-top: 6px; }
  .grid-3, .grid-2, .steps, .stats, .footer-grid { grid-template-columns: 1fr; }
  .mini-cal { right: 0; bottom: -16px; width: 180px; }
  .final-cta { padding: 48px 24px; }
  .hero-cta .btn, .final-cta .btn { width: 100%; }
}
