/* ==========================================================================
   Design tokens — espelham lib/core/theme (colors_consts.dart, light/dark_theme.dart)
   ========================================================================== */
:root {
  /* Superfícies: página (scaffold) vs. cartão (card) */
  --page: #f1f5f9;      /* AppColors.scaffoldBackgroundColor / canvasColor */
  --surface: #f8fafc;   /* AppColors.cardColor */
  --surface-raised: #ffffff;
  --text: #0f172a;      /* AppColors.darkScaffoldBackgroundColor usado como texto no light theme */
  --text-muted: #4b5568;
  --border: #e2e8f0;

  /* Marca — constante entre light/dark, como no app (AppColors.brandPrimary) */
  --brand: #6096ba;
  --brand-dark: #3d6a89;
  --brand-strong: #5f92bf; /* AppColors.backButtonColor */
  --brand-tint: #e9f1f6;

  /* Acento secundário — laranja (AppColors.drawerSettingsColor), uso pontual apenas */
  --accent: #c9791e;

  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 22px;
  --shadow: 0 12px 30px -14px rgba(15, 23, 42, 0.16);
  --max-width: 1160px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --page: #0f172a;      /* AppColors.darkScaffoldBackgroundColor */
    --surface: #1e293b;   /* AppColors.darkCardColor / darkCanvasColor */
    --surface-raised: #1e293b;
    --text: #ededed;      /* AppColors.grey */
    --text-muted: #97a3b3;
    --border: #334155;

    --brand: #6096ba;
    --brand-dark: #8fbdda;
    --brand-strong: #7ab0dd;
    --brand-tint: #24313f;

    --accent: #e0994a;
    --shadow: 0 12px 30px -14px rgba(0, 0, 0, 0.55);
  }
}

:root[data-theme="dark"] {
  --page: #0f172a;
  --surface: #1e293b;
  --surface-raised: #1e293b;
  --text: #ededed;
  --text-muted: #97a3b3;
  --border: #334155;
  --brand: #6096ba;
  --brand-dark: #8fbdda;
  --brand-strong: #7ab0dd;
  --brand-tint: #24313f;
  --accent: #e0994a;
  --shadow: 0 12px 30px -14px rgba(0, 0, 0, 0.55);
}

/* ==========================================================================
   Transição de tema (claro/escuro) — View Transitions API com revelação
   circular a partir do botão de alternância; fallback = crossfade simples
   ========================================================================== */
::view-transition-old(root),
::view-transition-new(root) {
  animation: none;
  mix-blend-mode: normal;
}
::view-transition-old(root) { z-index: 1; }
::view-transition-new(root) { z-index: 2; }

@media (prefers-reduced-motion: no-preference) {
  body,
  .site-header,
  .feature-card,
  .game-card,
  .zimbo-card,
  .step,
  .social-link,
  .theme-toggle,
  .lang-toggle,
  .mock-item,
  .eyebrow,
  .pill-list li,
  .changelog-version,
  .store-badge,
  .btn-outline {
    transition: background-color .35s ease, border-color .35s ease, color .35s ease, box-shadow .3s ease;
  }
}

/* ==========================================================================
   Base
   ========================================================================== */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }

body {
  margin: 0;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--page);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background .2s ease, color .2s ease;
}

h1, h2, h3, h4, .logo-text, .eyebrow, .btn, .nav-cta {
  font-family: "Poppins", "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
}

img, svg { max-width: 100%; display: block; }
.icon { fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--brand);
  color: #fff;
  padding: 10px 16px;
  z-index: 1000;
  border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.25; letter-spacing: -0.01em; }
p { margin: 0 0 1em; color: var(--text-muted); }

.eyebrow {
  display: inline-block;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--brand-dark);
  background: var(--brand-tint);
  padding: 6px 12px;
  border-radius: 999px;
  margin-bottom: 14px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 15px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .3s cubic-bezier(.34, 1.56, .64, 1), box-shadow .2s ease, background .2s ease;
}
.btn:hover { transform: translateY(-2px) scale(1.02); }
.btn:active { transform: translateY(0) scale(.98); }
.btn-primary { background: var(--brand); color: #fff; box-shadow: var(--shadow); }
.btn-primary:hover { background: var(--brand-dark); }
.btn-sm { padding: 9px 16px; font-size: 14px; }
.btn-light { background: #ffffff; color: var(--brand-dark); }
.btn-outline { background: transparent; color: var(--text); border-color: var(--border); }
.btn-outline:hover { border-color: var(--brand); color: var(--brand-dark); }

/* THEME TOGGLE */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
}
.theme-toggle .icon { width: 18px; height: 18px; }
.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; }

/* LANGUAGE TOGGLE — pill switch com indicador deslizante */
.lang-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  height: 38px;
  padding: 3px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  cursor: pointer;
  isolation: isolate;
}
.lang-toggle:hover { border-color: var(--brand); }
.lang-toggle:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }

.lang-toggle-thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: calc(50% - 3px);
  height: calc(100% - 6px);
  border-radius: 999px;
  background: var(--brand);
  transition: transform .35s cubic-bezier(.34, 1.56, .64, 1);
  z-index: 0;
}
.lang-toggle[data-lang="en"] .lang-toggle-thumb {
  transform: translateX(100%);
}

.lang-toggle-option {
  position: relative;
  z-index: 1;
  width: 28px;
  text-align: center;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .03em;
  color: var(--text-muted);
  transition: color .3s ease;
}
.lang-toggle[data-lang="pt"] .lang-toggle-option:first-child,
.lang-toggle[data-lang="en"] .lang-toggle-option:last-child {
  color: #fff;
}

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: color-mix(in srgb, var(--page) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  gap: 16px;
}
.logo { display: flex; align-items: center; }
.logo-img { height: 26px; width: auto; display: block; }

.main-nav {
  display: flex;
  gap: 24px;
}
.main-nav a {
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text-muted);
  transition: color .15s ease;
  white-space: nowrap;
}
.main-nav a:hover { color: var(--text); }

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

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
}

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  position: relative;
  overflow: hidden;
  padding: 64px 0 40px;
}
.hero-inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}
.hero-copy .eyebrow { margin-bottom: 18px; }
.hero h1 {
  font-size: clamp(30px, 4.2vw, 46px);
  font-weight: 800;
}
.hero .lead {
  font-size: 17px;
  max-width: 48ch;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 28px 0 24px;
}
.store-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--text);
  color: var(--page);
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  transition: transform .15s ease;
}
.store-badge:hover { transform: translateY(-1px); }
.store-icon { width: 20px; height: 20px; }
.store-text { display: flex; flex-direction: column; font-weight: 700; font-size: 14px; }
.store-text small { font-weight: 400; font-size: 11px; opacity: .75; }

.hero-trust { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text-muted); }
.hero-trust .stars { display: flex; gap: 2px; color: var(--accent); }
.hero-trust .stars .icon { width: 15px; height: 15px; fill: currentColor; stroke: none; }

.hero-visual { position: relative; display: flex; justify-content: center; }
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(44px);
  opacity: .28;
  z-index: 0;
}
.blob-1 { width: 260px; height: 260px; background: var(--brand); top: -30px; left: -20px; animation: blobPulse 7s ease-in-out infinite; }
.blob-2 { width: 200px; height: 200px; background: var(--accent); bottom: -20px; right: -10px; opacity: .16; animation: blobPulse 8s ease-in-out infinite reverse; }

@keyframes blobPulse {
  0%, 100% { transform: scale(1) translate(0, 0); }
  50% { transform: scale(1.12) translate(6px, -6px); }
}

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

.phone-mock {
  position: relative;
  z-index: 1;
  width: 250px;
  border-radius: 34px;
  background: var(--text);
  padding: 12px;
  box-shadow: var(--shadow);
  animation: floatSoft 5s ease-in-out infinite;
}
.phone-notch {
  width: 64px; height: 16px;
  background: var(--text);
  border-radius: 0 0 10px 10px;
  margin: -12px auto 8px;
}
.phone-screen {
  background: var(--page);
  border-radius: 22px;
  padding: 16px;
  min-height: 400px;
}
.mock-topbar { display: flex; gap: 6px; margin-bottom: 16px; }
.mock-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--border); }

.mock-balance {
  background: var(--brand-tint);
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 18px;
}
.mock-label { display: block; font-size: 12px; color: var(--text-muted); }
.mock-value { display: block; font-size: 20px; font-weight: 800; margin: 4px 0 8px; }
.mock-tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
}
.mock-tag-up { background: var(--brand); color: #fff; }

.mock-bars {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  height: 64px;
  margin-bottom: 18px;
}
.mock-bar {
  flex: 1;
  height: var(--h);
  background: linear-gradient(180deg, var(--brand), var(--brand-dark));
  border-radius: 4px;
}

.mock-list { display: flex; flex-direction: column; gap: 10px; }
.mock-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
}
.mock-item .icon { width: 16px; height: 16px; color: var(--brand-dark); flex-shrink: 0; }
.mock-item span.mock-text { flex: 1; color: var(--text); }
.mock-amount { font-weight: 700; color: var(--brand-dark); }

/* ==========================================================================
   Strip
   ========================================================================== */
.strip { background: var(--brand-dark); color: #fff; }
.strip-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: center;
  padding: 15px 24px;
  font-size: 13.5px;
}
.strip-inner span:nth-child(4n+1) { font-weight: 800; }
.strip-sep { opacity: .5; padding: 0 8px; }

/* ==========================================================================
   Sections
   ========================================================================== */
.section { padding: 80px 0; }
.section-alt { background: var(--surface); }
.section-head {
  max-width: 620px;
  margin: 0 auto 44px;
  text-align: center;
}
.section-head h2 { font-size: clamp(24px, 3vw, 34px); }
.section-head p { font-size: 16.5px; }

/* FEATURES */
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.feature-card {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  transition: transform .3s cubic-bezier(.34, 1.56, .64, 1), box-shadow .25s ease;
}
.section-alt .feature-card,
.section-alt .game-card,
.section-alt .step { background: var(--surface-raised); }
.feature-card:hover,
.game-card:hover,
.zimbo-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.feature-icon {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  background: var(--brand-tint);
  border-radius: 12px;
  margin-bottom: 16px;
  transition: transform .4s cubic-bezier(.34, 1.56, .64, 1);
}
.feature-icon .icon { width: 22px; height: 22px; color: var(--brand-dark); }
.feature-card:hover .feature-icon,
.game-card:hover .feature-icon,
.zimbo-card:hover .feature-icon { transform: scale(1.12) rotate(-4deg); }
.feature-card h3 { font-size: 17px; }
.feature-card p { margin: 0; font-size: 14.5px; }

/* STEPS */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
.step {
  background: var(--surface-raised);
  border-radius: var(--radius);
  padding: 26px;
  border: 1px solid var(--border);
}
.step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  font-weight: 800;
  margin-bottom: 16px;
  font-size: 14px;
}
.step h3 { font-size: 16.5px; }
.step p { margin: 0; font-size: 14.5px; }

/* PILL LIST */
.pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
  padding: 0;
  list-style: none;
}
.pill-list li {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--brand-dark);
  background: var(--brand-tint);
  border-radius: 999px;
  padding: 5px 12px;
}

/* GRUPOS DENTRO DE UMA SECÇÃO (ex.: Juros Simples / Composto / Outras) */
.group-title {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--text-muted);
  margin: 0 0 16px;
}
.calc-group + .calc-group { margin-top: 36px; }

/* INFO HIGHLIGHT (destaque explicativo dentro de uma secção) */
.info-highlight {
  margin-top: 36px;
  background: var(--brand-tint);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  display: flex;
  align-items: center;
  gap: 18px;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}
.info-highlight .icon-wrap {
  width: 44px; height: 44px;
  flex-shrink: 0;
  border-radius: 12px;
  background: var(--surface-raised);
  display: flex; align-items: center; justify-content: center;
}
.info-highlight .icon-wrap .icon { width: 22px; height: 22px; color: var(--brand-dark); }
.info-highlight p { margin: 0; font-size: 14.5px; }
.info-highlight strong { color: var(--text); }

/* PLANS */
.plans-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}
.plan-card {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  transition: transform .3s cubic-bezier(.34, 1.56, .64, 1), box-shadow .25s ease;
}
.plan-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.plan-card h3 { font-size: 16.5px; margin-bottom: 6px; }
.plan-card p { font-size: 13.5px; margin: 0; }
.plan-tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--brand-dark);
  background: var(--brand-tint);
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 12px;
}

/* GAMES */
.games-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
}
.game-card {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 16px;
  text-align: center;
  transition: transform .3s cubic-bezier(.34, 1.56, .64, 1), box-shadow .25s ease;
}
.game-card .feature-icon { margin: 0 auto 12px; }
.game-card h3 { font-size: 14.5px; margin-bottom: 4px; }
.game-card p { font-size: 12.5px; margin: 0; }

/* ZIMBO / XP */
.zimbo-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.zimbo-card {
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px;
  transition: transform .3s cubic-bezier(.34, 1.56, .64, 1), box-shadow .25s ease;
}
.zimbo-card .feature-icon { background: var(--brand-tint); }
.zimbo-card h3 { font-size: 16.5px; }
.zimbo-card p { font-size: 14.5px; margin: 0; }

/* CHANGELOG */
.changelog {
  display: flex;
  flex-direction: column;
  gap: 0;
  max-width: 760px;
  margin: 0 auto;
  border-left: 2px solid var(--border);
  padding-left: 28px;
}
.changelog-item { position: relative; padding-bottom: 34px; }
.changelog-item:last-child { padding-bottom: 0; }
.changelog-item::before {
  content: "";
  position: absolute;
  left: -34px;
  top: 4px;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--brand);
  border: 3px solid var(--surface);
}
.changelog-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
  font-size: 13px;
}
.changelog-version {
  font-weight: 700;
  color: var(--brand-dark);
  background: var(--brand-tint);
  padding: 2px 10px;
  border-radius: 999px;
}
.changelog-meta time { color: var(--text-muted); }
.changelog-body h3 { font-size: 16.5px; margin-bottom: 6px; }
.changelog-body p { margin: 0; font-size: 14.5px; }

/* SOCIAL */
.social-section { text-align: center; }
.social-links { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }
.social-link {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  color: var(--text);
  transition: transform .15s ease, background .15s ease, color .15s ease, border-color .15s ease;
}
.social-link .icon { width: 19px; height: 19px; fill: currentColor; stroke: none; }
.social-link:hover { background: var(--brand); color: #fff; border-color: var(--brand); transform: translateY(-2px); }

.contact-email {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 22px;
  font-size: 15px;
  font-weight: 600;
  color: var(--brand-dark);
}
.contact-email .icon { width: 18px; height: 18px; }

/* CTA FINAL */
.cta-final { background: linear-gradient(135deg, var(--brand), var(--brand-dark)); color: #fff; }
.cta-final-inner { text-align: center; padding: 72px 24px; }
.cta-final h2 { font-size: clamp(24px, 3vw, 34px); }
.cta-final p { color: rgba(255,255,255,.85); font-size: 16.5px; }

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 56px 0 28px;
}
.footer-top {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 32px;
  padding-bottom: 36px;
  border-bottom: 1px solid var(--border);
}
.footer-brand .logo-img { height: 22px; }
.footer-brand p { font-size: 13.5px; max-width: 30ch; margin-top: 14px; }
.social-links-footer { justify-content: flex-start; margin-top: 16px; }
.social-links-footer .social-link { width: 34px; height: 34px; }
.social-links-footer .social-link .icon { width: 16px; height: 16px; }

.footer-col { display: flex; flex-direction: column; gap: 10px; }
.footer-col h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--text-muted); margin-bottom: 4px; }
.footer-col a { font-size: 13.5px; color: var(--text-muted); }
.footer-col a:hover { color: var(--text); }

.footer-bottom {
  padding-top: 22px;
  text-align: center;
  font-size: 12.5px;
  color: var(--text-muted);
}
.footer-bottom p { margin: 0; }

/* ==========================================================================
   Responsive — mobile / tablet / desktop
   ========================================================================== */
@media (max-width: 1080px) {
  .main-nav { gap: 16px; }
  .main-nav a { font-size: 14px; }
  .games-grid { grid-template-columns: repeat(3, 1fr); }
  .plans-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 960px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-visual { order: -1; max-width: 320px; margin: 0 auto; }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .zimbo-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .main-nav { display: none; }
  .nav-toggle { display: flex; }
}

@media (max-width: 640px) {
  .section { padding: 60px 0; }
  .features-grid { grid-template-columns: 1fr; }
  .zimbo-grid { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; }
  .games-grid { grid-template-columns: repeat(2, 1fr); }
  .plans-grid { grid-template-columns: 1fr; }
  .info-highlight { flex-direction: column; text-align: center; }
}

body.nav-open .main-nav {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 100%;
  left: 0; right: 0;
  background: var(--page);
  border-bottom: 1px solid var(--border);
  padding: 16px 24px 24px;
  gap: 16px;
  z-index: 99;
}

/* ==========================================================================
   Scroll reveal — entram com fade + leve deslize e um toque de bounce
   ========================================================================== */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity .7s ease, transform .7s cubic-bezier(.22, 1, .36, 1);
  }
  .reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
  }

  .features-grid > *:nth-child(2),
  .games-grid > *:nth-child(2),
  .zimbo-grid > *:nth-child(2),
  .steps > *:nth-child(2) { transition-delay: .08s; }
  .features-grid > *:nth-child(3),
  .games-grid > *:nth-child(3),
  .zimbo-grid > *:nth-child(3),
  .steps > *:nth-child(3) { transition-delay: .16s; }
  .features-grid > *:nth-child(4),
  .games-grid > *:nth-child(4) { transition-delay: .24s; }
  .features-grid > *:nth-child(5),
  .games-grid > *:nth-child(5) { transition-delay: .32s; }
  .features-grid > *:nth-child(6) { transition-delay: .4s; }
}

/* ==========================================================================
   Rodapé — link "Legal" como botão (mesma aparência de <a>)
   ========================================================================== */
.footer-link-btn {
  all: unset;
  cursor: pointer;
  font-size: 13.5px;
  color: var(--text-muted);
  transition: color .2s ease;
}
.footer-link-btn:hover { color: var(--text); }

/* ==========================================================================
   Modais legais (Termos de uso / Privacidade)
   ========================================================================== */
.legal-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.legal-modal[hidden] { display: none; }

.legal-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(2px);
  animation: legalFadeIn .2s ease;
}

.legal-modal-panel {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 720px;
  max-height: min(80vh, 720px);
  display: flex;
  flex-direction: column;
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  overflow: hidden;
  animation: legalPopIn .3s cubic-bezier(.22, 1, .36, 1);
}

@keyframes legalFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes legalPopIn {
  from { opacity: 0; transform: translateY(14px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.legal-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.legal-modal-header h2 {
  margin: 0;
  font-size: 18px;
}
.legal-modal-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  flex-shrink: 0;
  transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.legal-modal-close:hover { background: var(--brand); color: #fff; border-color: var(--brand); }
.legal-modal-close .icon { width: 16px; height: 16px; }

.legal-modal-body {
  padding: 22px 24px 28px;
  overflow-y: auto;
  font-size: 14.5px;
  line-height: 1.65;
}
.legal-modal-body h3 {
  font-size: 15.5px;
  color: var(--text);
  margin: 24px 0 8px;
}
.legal-modal-body h3:first-child { margin-top: 0; }
.legal-modal-body p { margin: 0 0 12px; color: var(--text-muted); }
.legal-modal-body ul { margin: 0 0 12px; padding-left: 20px; color: var(--text-muted); }
.legal-modal-body li { margin-bottom: 4px; }
.legal-modal-body strong { color: var(--text); }
.legal-modal-meta {
  font-size: 13px;
  padding: 10px 14px;
  background: var(--brand-tint);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
}
.legal-modal-note {
  font-size: 12.5px;
  font-style: italic;
  margin-top: 8px !important;
}
.legal-modal-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 28px 0;
}
.legal-modal-subtitle {
  font-size: 17px;
  margin: 0 0 12px;
}

body.modal-open { overflow: hidden; }

@media (max-width: 640px) {
  .legal-modal { padding: 0; align-items: flex-end; }
  .legal-modal-panel {
    max-width: 100%;
    max-height: 88vh;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }
}
