/* =========================================================
   Lastro Contabilidade — estilos
   Linguagem visual inspirada no ReUI / shadcn/ui:
   base neutra (zinc), bordas 1px, cantos arredondados,
   badges em pílula, grids bento e modo escuro.
   ========================================================= */

/* ---------- Tokens (tema claro) ---------- */
:root {
  /* Neutros extraídos do ReUI (reui.io) */
  --background: #ffffff;
  --foreground: #0a0a0a;
  --card: #ffffff;
  --muted: #f5f5f5;
  --muted-2: #fafafa;
  --muted-foreground: #696969;
  --border: #e5e5e5;
  --input: #e5e5e5;

  /* Cor principal — troque aqui para mudar a identidade */
  --primary: #047857;
  --primary-hover: #065f46;
  --primary-foreground: #ffffff;
  --primary-soft: #ecfdf5;
  --primary-soft-border: #a7f3d0;
  --primary-text: #047857;

  --warning: #b45309;
  --star: #f59e0b;
  --danger: #dc2626;

  --ring: rgba(4, 120, 87, 0.35);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 20px 40px -12px rgba(0, 0, 0, 0.12), 0 4px 12px -4px rgba(0, 0, 0, 0.06);

  --radius: 0.625rem;
  --radius-lg: 0.875rem;
  --radius-xl: 1.25rem;

  --font-sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --font-serif: "Instrument Serif", ui-serif, Georgia, "Times New Roman", serif;

  --container: 1200px;
  --header-h: 64px;
  --logo-ink: var(--primary-foreground);

  color-scheme: light;
}

/* ---------- Tema escuro ---------- */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --background: #0a0a0a;
    --foreground: #fafafa;
    --card: #171717;
    --muted: #262626;
    --muted-2: #111111;
    --muted-foreground: #a1a1a1;
    --border: rgba(255, 255, 255, 0.1);
    --input: rgba(255, 255, 255, 0.15);
    --primary: #10b981;
    --primary-hover: #34d399;
    --primary-foreground: #022c22;
    --primary-soft: rgba(16, 185, 129, 0.1);
    --primary-soft-border: rgba(16, 185, 129, 0.3);
    --primary-text: #34d399;
    --warning: #fbbf24;
    --ring: rgba(16, 185, 129, 0.4);
    --shadow-lg: 0 20px 40px -12px rgba(0, 0, 0, 0.6), 0 4px 12px -4px rgba(0, 0, 0, 0.4);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --background: #0a0a0a;
  --foreground: #fafafa;
  --card: #171717;
  --muted: #262626;
  --muted-2: #111111;
  --muted-foreground: #a1a1a1;
  --border: rgba(255, 255, 255, 0.1);
  --input: rgba(255, 255, 255, 0.15);
  --primary: #10b981;
  --primary-hover: #34d399;
  --primary-foreground: #022c22;
  --primary-soft: rgba(16, 185, 129, 0.1);
  --primary-soft-border: rgba(16, 185, 129, 0.3);
  --primary-text: #34d399;
  --warning: #fbbf24;
  --ring: rgba(16, 185, 129, 0.4);
  --shadow-lg: 0 20px 40px -12px rgba(0, 0, 0, 0.6), 0 4px 12px -4px rgba(0, 0, 0, 0.4);
  color-scheme: dark;
}

/* ---------- Reset / base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--foreground);
  background: var(--background);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, h4 { margin: 0; line-height: 1.15; letter-spacing: -0.025em; font-weight: 600; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; cursor: pointer; }
input, select, textarea { font: inherit; color: inherit; }
ul, ol { margin: 0; padding: 0; list-style: none; }
[hidden] { display: none !important; }
::selection { background: var(--primary); color: var(--primary-foreground); }

:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; border-radius: 6px; }

.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; z-index: 100;
  background: var(--foreground); color: var(--background);
  padding: 8px 14px; border-radius: var(--radius); transition: top .2s;
}
.skip-link:focus { top: 12px; }

/* ---------- Utilitários ---------- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: 24px; }
.muted { color: var(--muted-foreground); }
.small { font-size: 0.875rem; }
.fine { font-size: 0.8125rem; line-height: 1.5; }
.mono { font-family: var(--font-mono); font-feature-settings: "tnum"; letter-spacing: -0.02em; }
.center { text-align: center; }
/* Destaque tipográfico: serifa itálica em palavras-chave dos títulos */
.serif {
  font-family: var(--font-serif);
  font-style: italic; font-weight: 400;
  font-size: 1.12em; letter-spacing: -0.01em; line-height: 1;
}
h2 .serif { color: var(--primary-text); }
.accent { color: var(--primary-text); }
.link { color: var(--primary-text); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.link:hover { text-decoration-thickness: 2px; }

.icon { width: 20px; height: 20px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.icon-sm { width: 16px; height: 16px; }
.icon-xs { width: 14px; height: 14px; }

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

/* ---------- Botões ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 16px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-size: 0.9375rem; font-weight: 500; white-space: nowrap;
  transition: background-color .15s, border-color .15s, color .15s, box-shadow .15s, transform .15s;
}
.btn:active { transform: translateY(1px); }
.btn-sm { height: 36px; padding: 0 12px; font-size: 0.875rem; }
.btn-lg { height: 48px; padding: 0 22px; font-size: 1rem; }
.btn-block { width: 100%; }

.btn-primary { background: var(--primary); color: var(--primary-foreground); box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(255,255,255,.12); }
.btn-primary:hover { background: var(--primary-hover); }
.btn-outline { background: var(--card); border-color: var(--border); box-shadow: var(--shadow-sm); }
.btn-outline:hover { background: var(--muted); }
.btn-ghost:hover { background: var(--muted); }
.btn .icon { width: 18px; height: 18px; }
.btn-primary .icon[aria-hidden] { transition: transform .2s; }
.btn-primary:hover .icon { transform: translateX(2px); }

.icon-btn {
  display: inline-grid; place-items: center;
  width: 36px; height: 36px; border-radius: var(--radius);
  background: transparent; border: 1px solid transparent;
  transition: background-color .15s;
}
.icon-btn:hover { background: var(--muted); }

/* ---------- Badges / pills ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  height: 22px; padding: 0 8px;
  font-size: 0.75rem; font-weight: 500; line-height: 1;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--muted);
  color: var(--muted-foreground);
  white-space: nowrap;
}
.badge-success { background: var(--primary-soft); border-color: var(--primary-soft-border); color: var(--primary-text); }
.badge-solid { background: var(--primary); border-color: var(--primary); color: var(--primary-foreground); }
.badge .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 3px var(--primary-soft); }

.pill {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 4px 12px 4px 4px;
  border: 1px solid var(--border); border-radius: 999px;
  background: var(--card); box-shadow: var(--shadow-sm);
  font-size: 0.875rem; color: var(--muted-foreground);
  transition: border-color .15s, color .15s;
}
.pill:hover { border-color: var(--primary-soft-border); color: var(--foreground); }
.pill-tag {
  padding: 2px 8px; border-radius: 999px;
  background: var(--primary-soft); color: var(--primary-text);
  font-size: 0.75rem; font-weight: 600;
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--primary-text);
  margin-bottom: 12px;
}

/* ---------- Avatares ---------- */
.avatar {
  --h: 160;
  display: inline-grid; place-items: center;
  width: 36px; height: 36px; border-radius: 50%;
  font-size: 0.75rem; font-weight: 600; letter-spacing: 0;
  color: hsl(var(--h) 60% 28%);
  background: hsl(var(--h) 70% 90%);
  border: 2px solid var(--card);
  flex-shrink: 0;
}
:root[data-theme="dark"] .avatar { color: hsl(var(--h) 70% 85%); background: hsl(var(--h) 35% 22%); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .avatar { color: hsl(var(--h) 70% 85%); background: hsl(var(--h) 35% 22%); }
}
img.avatar { object-fit: cover; background: var(--muted); }
.avatar-sm { width: 28px; height: 28px; font-size: 0.6875rem; border-width: 0; }
.avatar-lg { width: 72px; height: 72px; font-size: 1.25rem; border-width: 0; }
.avatar-stack { display: flex; }
.avatar-stack .avatar + .avatar { margin-left: -10px; }

.stars { display: flex; align-items: center; gap: 2px; color: var(--star); font-weight: 600; font-size: 0.875rem; }
.stars svg { width: 16px; height: 16px; fill: currentColor; stroke: none; }
.stars span { margin-left: 6px; color: var(--foreground); }
.stars.sm svg { width: 14px; height: 14px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: color-mix(in srgb, var(--background) 80%, transparent);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s, background-color .2s;
}
.site-header.is-scrolled { border-bottom-color: var(--border); }
.header-inner { display: flex; align-items: center; gap: 24px; height: var(--header-h); }

.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; }
.brand-mark { width: 30px; height: 30px; color: var(--primary); }
.brand-mark.sm { width: 20px; height: 20px; }
.brand-name {
  display: flex; flex-direction: column; line-height: 1;
  font-family: var(--font-serif); font-size: 1.5rem; font-weight: 400; letter-spacing: -0.01em;
}
.brand-sub {
  font-family: var(--font-sans); font-size: 0.5625rem; font-weight: 600; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--muted-foreground); margin-top: 1px;
}

.main-nav { display: flex; gap: 4px; margin-left: 12px; }
.main-nav a {
  padding: 6px 12px; border-radius: var(--radius);
  font-size: 0.9375rem; color: var(--muted-foreground);
  transition: color .15s, background-color .15s;
}
.main-nav a:hover { color: var(--foreground); background: var(--muted); }
.main-nav a.is-active { color: var(--foreground); }

.header-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.theme-toggle .icon-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun { display: none; }
  :root:not([data-theme="light"]) .theme-toggle .icon-moon { display: block; }
}
.menu-toggle { display: none; }

.mobile-nav { border-top: 1px solid var(--border); background: var(--background); }
.mobile-nav nav { display: flex; flex-direction: column; padding-block: 12px 20px; }
.mobile-nav a:not(.btn) { padding: 12px 4px; border-bottom: 1px solid var(--border); font-size: 1rem; }
.mobile-nav .btn { margin-top: 16px; }

/* ---------- Hero ---------- */
.hero { position: relative; padding-block: 72px 96px; overflow: hidden; }
.hero-bg {
  position: absolute; inset: 0; z-index: -1;
  background-image:
    linear-gradient(to right, var(--border) 1px, transparent 1px),
    linear-gradient(to bottom, var(--border) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 0%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 0%, #000 30%, transparent 75%);
  opacity: .6;
}
.hero-bg::after {
  content: ""; position: absolute; inset: -20% 10% auto; height: 60%;
  background: radial-gradient(closest-side, var(--primary-soft), transparent);
  filter: blur(20px);
}
/* Hero centralizado, no estilo do ReUI */
.hero-grid { display: flex; flex-direction: column; align-items: center; gap: 64px; }
.hero-copy { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 24px; max-width: 56rem; }
.hero-title {
  display: flex; flex-wrap: wrap; justify-content: center; align-items: center; column-gap: 0.28em; row-gap: 0.08em;
  font-size: clamp(2.25rem, 5.4vw, 4.25rem); font-weight: 600; letter-spacing: -0.045em; line-height: 1.06;
  text-wrap: balance;
}
.inline-faces { display: inline-flex; align-items: center; vertical-align: middle; }
.inline-faces img {
  width: 0.92em; height: 0.92em; border-radius: 999px; object-fit: cover;
  border: 3px solid var(--background); box-shadow: 0 0 0 1px var(--border);
}
.inline-faces img + img { margin-left: -0.22em; }
.text-accent { color: var(--primary-text); }
.hero-lead { font-size: 1.125rem; color: var(--muted-foreground); max-width: 38rem; text-wrap: pretty; }
.hero-lead strong { color: var(--foreground); font-weight: 600; }
.hero-ctas { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.hero-proof { display: flex; align-items: center; gap: 14px; text-align: left; }

/* Mockup do painel */
.hero-visual { position: relative; width: 100%; max-width: 920px; padding-inline: 24px; }
.hero-visual::before {
  content: ""; position: absolute; inset: -12px 12px; z-index: -1;
  border: 1px solid var(--border); border-radius: calc(var(--radius-xl) + 12px);
  background: var(--muted-2);
}
.dash { box-shadow: var(--shadow-lg); overflow: hidden; border-radius: var(--radius-xl); }
.dash-head {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; border-bottom: 1px solid var(--border); background: var(--muted-2);
}
.dash-head .badge { margin-left: auto; }
.dash-dots { display: flex; gap: 6px; }
.dash-dots span { width: 10px; height: 10px; border-radius: 50%; background: var(--border); }
.dash-body {
  padding: 20px; display: grid; gap: 16px;
  grid-template-columns: 1fr 1.15fr;
  grid-template-areas: "row chart" "tasks chart";
}
.dash-row { grid-area: row; }
.dash-chart { grid-area: chart; display: flex; flex-direction: column; }
.dash-chart .bars { flex: 1; min-height: 140px; }
.dash-tasks { grid-area: tasks; }
.dash-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.dash-stat {
  display: flex; flex-direction: column; gap: 2px;
  padding: 14px; border: 1px solid var(--border); border-radius: var(--radius);
}
.dash-stat strong { font-size: 1.375rem; font-weight: 500; }
.delta { font-size: 0.8125rem; font-weight: 500; }
.delta.up { color: var(--primary-text); }

.dash-chart { padding: 14px; border: 1px solid var(--border); border-radius: var(--radius); }
.chart-head { display: flex; justify-content: space-between; margin-bottom: 12px; }
.bars { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; height: 120px; align-items: end; }
.bar-col { position: relative; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; padding-bottom: 20px; }
.bar-col span, .bar-col i {
  display: block; width: 100%; max-width: 28px; border-radius: 4px 4px 2px 2px;
  transform-origin: bottom; transform: scaleY(0);
  transition: transform .9s cubic-bezier(.2,.8,.2,1);
}
.bar-col span { height: calc(var(--v) * 1%); background: var(--primary-soft); border: 1px solid var(--primary-soft-border); }
.bar-col i { position: absolute; bottom: 20px; height: calc(var(--v) * 1%); background: var(--primary); }
.bar-col em { position: absolute; bottom: 0; font-style: normal; font-size: 0.6875rem; color: var(--muted-foreground); font-family: var(--font-mono); }
.hero-visual.is-visible .bar-col span,
.hero-visual.is-visible .bar-col i { transform: scaleY(1); }
.bar-col:nth-child(2) span, .bar-col:nth-child(2) i { transition-delay: .06s; }
.bar-col:nth-child(3) span, .bar-col:nth-child(3) i { transition-delay: .12s; }
.bar-col:nth-child(4) span, .bar-col:nth-child(4) i { transition-delay: .18s; }
.bar-col:nth-child(5) span, .bar-col:nth-child(5) i { transition-delay: .24s; }
.bar-col:nth-child(6) span, .bar-col:nth-child(6) i { transition-delay: .30s; }

.dash-tasks { display: grid; gap: 2px; }
.dash-tasks li {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 4px; font-size: 0.875rem;
  border-bottom: 1px dashed var(--border);
}
.dash-tasks li:last-child { border-bottom: 0; }
.dash-tasks li > :last-child { margin-left: auto; }
.dash-tasks .ok { color: var(--primary-text); }
.dash-tasks .pending { color: var(--warning); }

.float-card {
  position: absolute; display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; box-shadow: var(--shadow-lg);
  animation: float 6s ease-in-out infinite;
}
.float-card > div { display: flex; flex-direction: column; line-height: 1.3; }
.float-card strong.mono { font-size: 1.125rem; font-weight: 500; }
.float-a { left: -24px; bottom: -36px; }
.float-b { right: -24px; top: -64px; animation-delay: -3s; }
.float-icon {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: var(--radius);
  background: var(--primary-soft); color: var(--primary-text);
}
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

/* ---------- Faixa de números ---------- */
.stats-band { border-block: 1px solid var(--border); background: var(--muted-2); padding-block: 40px 32px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { display: flex; flex-direction: column; gap: 4px; padding-inline: 24px; border-left: 1px solid var(--border); }
.stat:first-child { border-left: 0; padding-left: 0; }
.stat strong { font-size: clamp(1.75rem, 3vw, 2.25rem); font-weight: 600; letter-spacing: -0.03em; font-feature-settings: "tnum"; }
.seals { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 28px; padding-top: 24px; border-top: 1px dashed var(--border); }
.seal { display: inline-flex; align-items: center; gap: 8px; font-size: 0.875rem; color: var(--muted-foreground); }
.seal .icon { color: var(--primary-text); }

/* ---------- Seções ---------- */
.section { padding-block: 96px; }
.section-muted { background: var(--muted-2); border-block: 1px solid var(--border); }
.section-head { max-width: 40rem; margin: 0 auto 48px; text-align: center; }
.section-head.left { text-align: left; margin: 0; }
.section-head h2 { font-size: clamp(1.875rem, 3.6vw, 2.75rem); letter-spacing: -0.035em; }
.section-head p { margin-top: 14px; font-size: 1.0625rem; }

.icon-box {
  display: inline-grid; place-items: center;
  width: 40px; height: 40px; border-radius: var(--radius);
  border: 1px solid var(--border); background: var(--card);
  color: var(--primary-text); box-shadow: var(--shadow-sm);
}
.icon-box.sm { width: 36px; height: 36px; }

/* ---------- Bento ---------- */
.bento { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.bento-card {
  position: relative; display: flex; flex-direction: column; gap: 12px;
  padding: 24px; border: 1px solid var(--border); border-radius: var(--radius-lg);
  background: var(--card); overflow: hidden;
  transition: border-color .2s, box-shadow .2s, transform .2s;
}
.bento-card:hover { border-color: var(--primary-soft-border); box-shadow: var(--shadow-lg); transform: translateY(-2px); }
.bento-card h3 { font-size: 1.125rem; margin-top: 8px; }
.bento-card p { font-size: 0.9375rem; }
.bento-card.span-2 { grid-column: span 2; display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: center; }
.bento-text { display: flex; flex-direction: column; gap: 12px; }
.bento-photo { padding-top: 0; }
.bento-img {
  width: calc(100% + 48px); max-width: none; margin: 0 -24px 4px; height: 140px; object-fit: cover;
  border-bottom: 1px solid var(--border); filter: saturate(.85);
}
.bento-photo .icon-box { margin-top: -36px; position: relative; }

.mini-timeline { display: grid; gap: 0; padding: 16px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--muted-2); }
.mini-timeline li { position: relative; display: flex; align-items: center; gap: 12px; padding: 7px 0; font-size: 0.875rem; color: var(--muted-foreground); }
.mini-timeline li span { position: relative; z-index: 1; width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--border); background: var(--card); flex-shrink: 0; }
.mini-timeline li:not(:last-child)::after { content: ""; position: absolute; left: 5px; top: 50%; height: 100%; width: 2px; background: var(--border); }
.mini-timeline li.done { color: var(--foreground); }
.mini-timeline li.done span { background: var(--primary); border-color: var(--primary); }
.mini-timeline li.done::after { background: var(--primary); }
.mini-timeline li.current { color: var(--foreground); font-weight: 500; }
.mini-timeline li.current span { border-color: var(--primary); box-shadow: 0 0 0 4px var(--primary-soft); }

.mini-payroll { display: grid; gap: 8px; }
.mini-payroll li {
  display: grid; grid-template-columns: auto 1fr auto auto; align-items: center; gap: 10px;
  padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--muted-2); font-size: 0.875rem;
}

/* ---------- Tabs ---------- */
.tab-list {
  display: flex; gap: 4px; padding: 4px; margin: 0 auto 20px; width: fit-content; max-width: 100%;
  overflow-x: auto; scrollbar-width: none;
  background: var(--muted); border: 1px solid var(--border); border-radius: calc(var(--radius) + 4px);
}
.tab-list::-webkit-scrollbar { display: none; }
.tab-list [role="tab"] {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px; border: 1px solid transparent; border-radius: var(--radius);
  background: transparent; font-size: 0.9375rem; font-weight: 500; white-space: nowrap;
  color: var(--muted-foreground); transition: color .15s, background-color .15s;
}
.tab-list [role="tab"]:hover { color: var(--foreground); }
.tab-list [role="tab"][aria-selected="true"] { background: var(--card); color: var(--foreground); border-color: var(--border); box-shadow: var(--shadow-sm); }
.tab-list [role="tab"][aria-selected="true"] .icon { color: var(--primary-text); }

.tab-panel { display: grid; grid-template-columns: 1.6fr 1fr; gap: 32px; padding: 32px; animation: fade-in .3s ease; }
.tab-panel h3 { font-size: 1.375rem; }
.tab-panel > div > p { margin-top: 10px; }
.tab-highlight {
  display: flex; flex-direction: column; justify-content: center; gap: 4px;
  padding: 24px; border-radius: var(--radius); border: 1px solid var(--primary-soft-border);
  background: var(--primary-soft);
}
.tab-highlight strong { font-size: 2.5rem; font-weight: 500; color: var(--primary-text); line-height: 1.1; }
@keyframes fade-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.check-list { display: grid; gap: 10px; margin-top: 20px; }
.check-list li { display: flex; align-items: flex-start; gap: 10px; font-size: 0.9375rem; }
.check-list .icon { margin-top: 4px; color: var(--primary-text); }

/* ---------- Passos ---------- */
.how-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: center; }
.photo-card { position: relative; margin: 0; }
.photo-card img {
  width: 100%; aspect-ratio: 10 / 11; object-fit: cover;
  border-radius: var(--radius-xl); border: 1px solid var(--border);
}
.photo-caption {
  position: absolute; left: 20px; bottom: 20px;
  display: flex; align-items: center; gap: 12px; padding: 12px 16px; box-shadow: var(--shadow-lg);
}
.photo-caption > span:last-child { display: flex; flex-direction: column; line-height: 1.3; }
.photo-caption .mono { font-size: 1.125rem; }

.steps { display: grid; gap: 0; }
.step { position: relative; display: flex; gap: 20px; padding-bottom: 32px; }
.step:last-child { padding-bottom: 0; }
.step h3 { font-size: 1.125rem; margin: 8px 0 6px; }
.step p { font-size: 0.9375rem; }
.step-num {
  position: relative; z-index: 1;
  display: inline-grid; place-items: center; width: 40px; height: 40px; flex-shrink: 0;
  border-radius: 50%; border: 1px solid var(--primary-soft-border);
  background: var(--primary-soft); color: var(--primary-text); font-size: 0.875rem;
}
.step:not(:last-child)::before {
  content: ""; position: absolute; left: 19.5px; top: 40px; bottom: 0; width: 1px;
  background: repeating-linear-gradient(to bottom, var(--border) 0 6px, transparent 6px 12px);
}

/* ---------- Simulador ---------- */
.sim-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: center; }
.sim-copy h2 { font-size: clamp(1.875rem, 3.6vw, 2.75rem); letter-spacing: -0.035em; }
.sim-copy > p { margin-top: 16px; font-size: 1.0625rem; }
.sim-copy .fine { font-size: 0.8125rem; padding: 12px 14px; border-left: 2px solid var(--border); }
.sim { padding: 28px; box-shadow: var(--shadow-lg); }
.field-label { display: block; font-size: 0.875rem; font-weight: 500; margin-bottom: 8px; }
.sim-input {
  display: flex; align-items: baseline; gap: 8px;
  padding: 4px 0 8px;
}
.sim-input input {
  width: 100%; border: 0; background: transparent; outline: none;
  font-family: var(--font-mono); font-size: 2.5rem; font-weight: 500; letter-spacing: -0.03em;
}
.sim-input:focus-within { box-shadow: 0 2px 0 var(--primary); }

.range { -webkit-appearance: none; appearance: none; width: 100%; height: 6px; margin: 12px 0 6px; border-radius: 999px; outline: none;
  background: linear-gradient(to right, var(--primary) 0 var(--fill, 20%), var(--muted) var(--fill, 20%) 100%); }
.range::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; border-radius: 50%; background: var(--card); border: 2px solid var(--primary); box-shadow: var(--shadow); cursor: grab; }
.range::-moz-range-thumb { width: 18px; height: 18px; border-radius: 50%; background: var(--card); border: 2px solid var(--primary); box-shadow: var(--shadow); cursor: grab; }
.range:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 4px var(--ring); }
.range-scale { display: flex; justify-content: space-between; }

.sim-compare { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 24px; }
.sim-col { display: flex; flex-direction: column; gap: 6px; padding: 16px; border: 1px solid var(--border); border-radius: var(--radius); }
.sim-col strong { font-size: 1.5rem; font-weight: 500; }
.sim-col strong::after { content: "/mês"; font-size: 0.8125rem; color: var(--muted-foreground); margin-left: 2px; }
.meter { height: 6px; border-radius: 999px; background: var(--muted); overflow: hidden; }
.meter span { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--muted-foreground); transition: width .4s ease; }
.meter-accent span { background: var(--primary); }

.sim-result {
  display: flex; flex-direction: column; gap: 2px; align-items: center; text-align: center;
  margin: 16px 0 20px; padding: 20px;
  border-radius: var(--radius); background: var(--primary-soft); border: 1px solid var(--primary-soft-border);
}
.sim-result strong { font-size: 2.25rem; font-weight: 500; color: var(--primary-text); line-height: 1.2; }
.sim-result.is-neutral { background: var(--muted); border-color: var(--border); }
.sim-result.is-neutral strong { color: var(--foreground); font-size: 1.25rem; }

/* ---------- Comparativo (formato "ReUI or the Grind") ---------- */
.versus { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: 960px; margin-inline: auto; }
.versus-card { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; padding: 32px; }
.versus-card h3 { font-size: clamp(1.25rem, 2.2vw, 1.5rem); }
.versus-card .check-list, .versus-card .x-list { margin-top: 8px; }
.versus-bad { background: var(--muted-2); }
.versus-bad h3 { color: var(--muted-foreground); }
.versus-good { border-color: var(--primary-soft-border); box-shadow: 0 0 0 4px var(--primary-soft), var(--shadow-lg); }
.versus-good .badge .brand-mark { width: 14px; height: 14px; }
.x-list { display: grid; gap: 10px; }
.x-list li { display: flex; align-items: flex-start; gap: 10px; font-size: 0.9375rem; color: var(--muted-foreground); }
.x-list .icon { margin-top: 4px; color: var(--danger); opacity: .7; }

/* ---------- Planos ---------- */
.billing-toggle {
  display: flex; gap: 4px; width: fit-content; margin: -16px auto 40px; padding: 4px;
  border: 1px solid var(--border); border-radius: 999px; background: var(--muted);
}
.billing-toggle button {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 16px; border-radius: 999px; border: 0; background: transparent;
  font-size: 0.875rem; font-weight: 500; color: var(--muted-foreground);
}
.billing-toggle button[aria-pressed="true"] { background: var(--card); color: var(--foreground); box-shadow: var(--shadow); }

.pricing { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; align-items: stretch; }
.plan { position: relative; display: flex; flex-direction: column; padding: 28px; }
.plan h3 { font-size: 1.125rem; }
.plan > .muted.small { margin-top: 6px; min-height: 2.8em; }
.price { display: flex; align-items: baseline; gap: 4px; margin-top: 20px; }
.price strong { font-size: 3rem; font-weight: 500; letter-spacing: -0.04em; line-height: 1; }
.price-note { margin: 6px 0 20px; min-height: 1.4em; }
.plan .check-list { margin-top: 24px; padding-top: 24px; border-top: 1px solid var(--border); }
.plan-featured { border-color: var(--primary); box-shadow: 0 0 0 1px var(--primary), var(--shadow-lg); }
.plan-flag { position: absolute; top: -11px; left: 28px; }

/* ---------- Depoimentos ---------- */
.wall { columns: 3 300px; column-gap: 16px; }
.quote { break-inside: avoid; margin: 0 0 16px; padding: 24px; display: flex; flex-direction: column; gap: 16px; }
.quote blockquote { margin: 0; font-size: 0.9875rem; line-height: 1.65; }
.quote figcaption { display: flex; align-items: center; gap: 12px; }
.quote figcaption > span:last-child { display: flex; flex-direction: column; line-height: 1.35; }
.quote figcaption strong { font-size: 0.9375rem; font-weight: 600; }

/* ---------- Equipe ---------- */
.team { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.member { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; padding: 32px 20px 24px; }
.member .avatar { margin-bottom: 10px; box-shadow: 0 0 0 6px var(--muted-2), 0 0 0 7px var(--border); }
.member h3 { font-size: 1.0625rem; }
.member .badge { margin-top: 10px; }

/* ---------- CTA invertido ---------- */
.cta-band-wrap { padding-block: 96px 0; }
.cta-band {
  position: relative; overflow: hidden; isolation: isolate;
  display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap;
  padding: clamp(32px, 5vw, 56px);
  border-radius: var(--radius-xl);
  background: #0a0a0a; color: #fafafa;
  border: 1px solid #262626;
}
.cta-band::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image:
    linear-gradient(to right, rgba(255,255,255,.06) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,.06) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: radial-gradient(ellipse 60% 80% at 100% 50%, #000, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse 60% 80% at 100% 50%, #000, transparent 70%);
}
.cta-band::after {
  content: ""; position: absolute; z-index: -1; right: -10%; top: -60%; width: 60%; height: 220%;
  background: radial-gradient(closest-side, rgba(16,185,129,.28), transparent);
}
.cta-band-copy { max-width: 36rem; }
.cta-band h2 { font-size: clamp(1.75rem, 3.4vw, 2.5rem); letter-spacing: -0.035em; }
.cta-band h2 .serif { color: #34d399; }
.cta-band p { margin-top: 12px; color: #a1a1a1; font-size: 1.0625rem; }
.cta-band-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.btn-invert { background: #fafafa; color: #0a0a0a; }
.btn-invert:hover { background: #e5e5e5; }
.btn-invert-ghost { color: #fafafa; border-color: rgba(255,255,255,.18); }
.btn-invert-ghost:hover { background: rgba(255,255,255,.08); }
:root[data-theme="dark"] .cta-band { background: #171717; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .cta-band { background: #171717; } }

/* ---------- FAQ ---------- */
.faq-grid { display: grid; grid-template-columns: 1fr 1.6fr; gap: 56px; align-items: start; }
.faq-grid .section-head { position: sticky; top: calc(var(--header-h) + 32px); }
.accordion { border-top: 1px solid var(--border); }
.accordion details { border-bottom: 1px solid var(--border); }
.accordion summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 20px 0; font-weight: 500; font-size: 1.0625rem; cursor: pointer; list-style: none;
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary:hover { color: var(--primary-text); }
.accordion summary .icon { color: var(--muted-foreground); transition: transform .25s; }
.accordion details[open] summary .icon { transform: rotate(180deg); }
.acc-body { overflow: hidden; }
.acc-body p { padding-bottom: 20px; color: var(--muted-foreground); max-width: 44rem; }

/* ---------- Contato ---------- */
.section-cta { position: relative; background: var(--muted-2); border-top: 1px solid var(--border); overflow: hidden; }
.section-cta::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(var(--border) 1px, transparent 1px);
  background-size: 20px 20px;
  mask-image: linear-gradient(to right, #000, transparent 60%);
  -webkit-mask-image: linear-gradient(to right, #000, transparent 60%);
}
.contact-grid { position: relative; display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: start; }
.contact-copy h2 { font-size: clamp(1.875rem, 3.6vw, 2.75rem); letter-spacing: -0.035em; }
.contact-copy > p { margin-top: 16px; font-size: 1.0625rem; }
.contact-photo { margin: 28px 0 0; }
.contact-photo img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius-lg); border: 1px solid var(--border); }
.contact-list { display: grid; gap: 16px; margin-top: 28px; }
.contact-list li { display: flex; align-items: center; gap: 14px; }
.contact-list li > span:last-child { display: flex; flex-direction: column; line-height: 1.4; font-size: 0.9375rem; }

.form-card { padding: 28px; box-shadow: var(--shadow-lg); }
#lead-form { display: grid; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field label { font-size: 0.875rem; font-weight: 500; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 40px; padding: 8px 12px;
  border: 1px solid var(--input); border-radius: var(--radius);
  background: var(--background); font-size: 0.9375rem;
  box-shadow: var(--shadow-sm);
  transition: border-color .15s, box-shadow .15s;
}
.field textarea { resize: vertical; min-height: 80px; }
.field input::placeholder, .field textarea::placeholder { color: var(--muted-foreground); opacity: .8; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--ring); }
.field.has-error input, .field.has-error select { border-color: var(--danger); }
.field.has-error input:focus, .field.has-error select:focus { box-shadow: 0 0 0 3px rgba(220, 38, 38, .2); }
.field-error { font-size: 0.8125rem; color: var(--danger); min-height: 0; }
.field-error:empty { display: none; }
.select-wrap { position: relative; }
.select-wrap select { appearance: none; -webkit-appearance: none; padding-right: 36px; cursor: pointer; }
.select-wrap .icon { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); pointer-events: none; color: var(--muted-foreground); }

.checkbox { display: flex; align-items: flex-start; gap: 10px; font-size: 0.875rem; color: var(--muted-foreground); cursor: pointer; }
.checkbox input { width: 16px; height: 16px; margin-top: 3px; accent-color: var(--primary); flex-shrink: 0; }
#lead-form .fine { display: flex; align-items: center; justify-content: center; gap: 6px; }

.form-success { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px; padding: 32px 8px; outline: none; }
.form-success h3 { font-size: 1.375rem; }
.success-icon {
  display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%;
  background: var(--primary-soft); color: var(--primary-text); border: 1px solid var(--primary-soft-border);
  animation: pop .4s cubic-bezier(.2,1.4,.4,1);
}
.success-icon .icon { width: 28px; height: 28px; stroke-width: 2.5; }
.form-success .btn { margin-top: 8px; }
@keyframes pop { from { transform: scale(.5); opacity: 0; } to { transform: scale(1); opacity: 1; } }

/* ---------- Rodapé ---------- */
.site-footer { border-top: 1px solid var(--border); padding-block: 56px 32px; padding-bottom: calc(32px + env(safe-area-inset-bottom, 0px)); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; }
.footer-brand p { margin-top: 16px; max-width: 18rem; }
.site-footer h4 { font-size: 0.875rem; font-weight: 600; margin-bottom: 14px; letter-spacing: 0; }
.site-footer ul { display: grid; gap: 10px; font-size: 0.875rem; }
.site-footer ul a { color: var(--muted-foreground); transition: color .15s; }
.site-footer ul a:hover { color: var(--foreground); }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--border); }

/* ---------- Botão flutuante ---------- */
.fab {
  position: fixed; right: 20px; bottom: calc(20px + env(safe-area-inset-bottom, 0px)); z-index: 40;
  display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%;
  background: var(--primary); color: var(--primary-foreground);
  box-shadow: 0 10px 24px -6px rgba(4, 120, 87, .5);
  transition: transform .2s, opacity .3s;
}
.fab:hover { transform: scale(1.06); }
.fab .icon { width: 24px; height: 24px; }
.fab.is-hidden { opacity: 0; pointer-events: none; transform: translateY(12px); }

/* ---------- Animações de entrada ---------- */
.js [data-reveal] { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s cubic-bezier(.2,.8,.2,1); }
.js [data-reveal].is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js [data-reveal] { opacity: 1; transform: none; }
  .bar-col span, .bar-col i { transform: none; }
}

/* ---------- Responsivo ---------- */
@media (max-width: 1080px) {
  .main-nav { display: none; }
  .menu-toggle { display: inline-grid; }
  .float-a { left: 0; }
  .float-b { right: 0; }
  .bento { grid-template-columns: repeat(2, 1fr); }
  .bento-card.span-2 { grid-column: span 2; }
  .how-grid { grid-template-columns: 1fr 1fr; gap: 40px; }
  .sim-grid, .contact-grid, .faq-grid { grid-template-columns: 1fr; gap: 40px; }
  .faq-grid .section-head { position: static; }
  .team { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}

@media (max-width: 720px) {
  .container { padding-inline: 16px; }
  .hide-sm { display: none; }
  .hero { padding-block: 40px 64px; }
  .hero-grid { gap: 48px; }
  .hero-ctas { width: 100%; }
  .hero-ctas .btn { flex: 1 1 100%; }
  .hero-visual { padding-inline: 0; }
  .hero-visual::before { inset: -8px -8px; }
  .dash-body { grid-template-columns: 1fr; grid-template-areas: "row" "chart" "tasks"; padding: 16px; }
  .float-b { right: 4px; top: -36px; }
  .float-a { left: 4px; bottom: -24px; }
  .how-grid { grid-template-columns: 1fr; }
  .photo-card img { aspect-ratio: 4 / 3; }
  .versus { grid-template-columns: 1fr; }
  .versus-card { padding: 24px; }
  .section { padding-block: 64px; }
  .section-head { margin-bottom: 32px; }
  .stats-grid { grid-template-columns: 1fr 1fr; row-gap: 24px; }
  .stat:nth-child(3) { border-left: 0; padding-left: 0; }
  .bento { grid-template-columns: 1fr; }
  .bento-card.span-2 { grid-column: auto; grid-template-columns: 1fr; }
  .tab-panel { grid-template-columns: 1fr; padding: 20px; }
  .pricing { grid-template-columns: 1fr; }
  .team { grid-template-columns: 1fr 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .sim, .form-card { padding: 20px; }
  .sim-input input { font-size: 2rem; }
  .sim-compare { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .header-actions .btn-primary { display: none; }
}

@media (max-width: 400px) {
  .team { grid-template-columns: 1fr; }
  .dash-row { grid-template-columns: 1fr; }
  .float-card { display: none; }
}

/* ---------- Crédito do portfólio ---------- */
.portfolio-credit { flex-basis: 100%; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 24px; margin-top: 12px; padding-top: 16px; border-top: 1px dashed var(--border); font-size: 0.8125rem; color: var(--muted-foreground); }
.portfolio-credit strong { color: var(--foreground); font-weight: 600; }
.credit-links a { color: var(--primary-text); font-weight: 500; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.credit-links a:hover { text-decoration-thickness: 2px; }
