/* ============================================================
   CounselGrid v2 — opinionated, typography-led, dark-first.
   Inspired by Harvey AI (restraint), Linear (precision),
   Anthropic (clarity). No emoji. No tilt. No particles.
   ============================================================ */

/* ── Tokens ────────────────────────────────────────────────── */
:root {
  /* Surfaces */
  --bg: #0a0a0f;
  --bg-elev: #101019;
  --surface: #14141e;
  --surface-2: #1a1a28;
  --bg-rgb: 10, 10, 15;
  --fg-rgb: 255, 255, 255;
  --border: rgba(var(--fg-rgb), 0.06);
  --border-strong: rgba(var(--fg-rgb), 0.12);

  /* Text */
  --fg: #fafafa;
  --fg-muted: #a1a1aa;
  --fg-dim: #6b6b78;
  --on-accent: #0a0a0f;

  /* Accent — single color family, no rainbow */
  --accent: #8b7cf6;
  --accent-bright: #a78bfa;
  --accent-rgb: 139, 124, 246;
  --accent-soft: rgba(var(--accent-rgb), 0.12);
  --accent-glow: rgba(var(--accent-rgb), 0.35);

  /* Semantic */
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;

  /* Spacing scale (8px base) */
  --s-1: 4px;
  --s-2: 8px;
  --s-3: 12px;
  --s-4: 16px;
  --s-6: 24px;
  --s-8: 32px;
  --s-10: 40px;
  --s-12: 48px;
  --s-16: 64px;
  --s-20: 80px;
  --s-24: 96px;
  --s-32: 128px;

  /* Radii */
  --r-sm: 6px;
  --r: 10px;
  --r-lg: 16px;
  --r-xl: 24px;

  /* Type */
  --font-display: 'Instrument Serif', 'Canela', Georgia, serif;
  --font-sans: 'Inter', 'Inter var', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', 'Menlo', monospace;

  --lh-tight: 1.05;
  --lh-snug: 1.2;
  --lh-normal: 1.55;

  /* Motion */
  --ease: cubic-bezier(0.2, 0, 0, 1);
  --dur: 240ms;
}

/* ── Light theme palette ───────────────────────────────────────
   Applied in three cases:
   (a) user forced light via [data-theme="light"] (toggle + localStorage)
   (b) OS prefers light AND user hasn't forced dark
   [data-theme="dark"] on :root always keeps the default dark palette.
   ──────────────────────────────────────────────────────────── */
:root[data-theme="light"] {
  /* Surfaces */
  --bg: #fbfbfd;
  --bg-elev: #ffffff;
  --surface: #ffffff;
  --surface-2: #f4f4f7;
  --bg-rgb: 251, 251, 253;
  --fg-rgb: 10, 10, 15;
  --border: rgba(var(--fg-rgb), 0.08);
  --border-strong: rgba(var(--fg-rgb), 0.16);

  /* Text */
  --fg: #0a0a0f;
  --fg-muted: #4e4e57;
  --fg-dim: #737380;
  --on-accent: #ffffff;

  /* Accent — darker purple for contrast against light bg */
  --accent: #6d28d9;
  --accent-bright: #7c3aed;
  --accent-rgb: 109, 40, 217;
  --accent-soft: rgba(var(--accent-rgb), 0.08);
  --accent-glow: rgba(var(--accent-rgb), 0.25);
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #fbfbfd;
    --bg-elev: #ffffff;
    --surface: #ffffff;
    --surface-2: #f4f4f7;
    --bg-rgb: 251, 251, 253;
    --fg-rgb: 10, 10, 15;
    --border: rgba(var(--fg-rgb), 0.08);
    --border-strong: rgba(var(--fg-rgb), 0.16);

    --fg: #0a0a0f;
    --fg-muted: #4e4e57;
    --fg-dim: #737380;
    --on-accent: #ffffff;

    --accent: #6d28d9;
    --accent-bright: #7c3aed;
    --accent-rgb: 109, 40, 217;
    --accent-soft: rgba(var(--accent-rgb), 0.08);
    --accent-glow: rgba(var(--accent-rgb), 0.25);
  }
}

/* ── Reset & Base ──────────────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
  scroll-padding-top: 72px;
  background: var(--bg);
  color: var(--fg);
}

body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: var(--lh-normal);
  font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11', 'ss01';
  background: var(--bg);
  color: var(--fg);
  overflow-x: hidden;
  min-height: 100vh;
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--dur) var(--ease);
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

/* ── Focus visibility (keyboard users) ─────────────────────── */
a:focus-visible,
button:focus-visible,
.btn:focus-visible,
summary:focus-visible,
details:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--accent-bright);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ── Skip-to-content link ──────────────────────────────────── */
.skip-link {
  position: absolute;
  top: -40px;
  left: var(--s-4);
  background: var(--accent);
  color: var(--on-accent);
  padding: 10px 14px;
  border-radius: var(--r-sm);
  font-size: 14px;
  font-weight: 600;
  z-index: 100;
  transition: top var(--dur) var(--ease);
}

.skip-link:focus {
  top: var(--s-3);
}

/* ── Typography ────────────────────────────────────────────── */
.h-display {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: var(--lh-tight);
}

.h-sans {
  font-family: var(--font-sans);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: var(--lh-snug);
}

.kicker {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
}

.kicker::before {
  content: '';
  width: 24px;
  height: 1px;
  background: currentColor;
  opacity: 0.5;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--fg-muted);
}

.muted {
  color: var(--fg-muted);
}

.dim {
  color: var(--fg-dim);
}

/* ── Layout ────────────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--s-6);
}

.container-tight {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 var(--s-6);
}

.container-prose {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 var(--s-6);
}

section {
  position: relative;
}

.section-pad {
  padding-block: var(--s-20);
}

.section-pad-lg {
  padding-block: var(--s-32);
}

.divider {
  height: 1px;
  background: var(--border);
  width: 100%;
  margin: 0;
}

/* ── Nav ──────────────────────────────────────────────────── */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(var(--bg-rgb), 0.7);
  backdrop-filter: saturate(140%) blur(12px);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease);
}

.nav.is-scrolled {
  border-bottom-color: var(--border);
  background: rgba(var(--bg-rgb), 0.85);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--s-6);
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  font-weight: 600;
  letter-spacing: -0.01em;
  font-size: 17px;
}

.brand-mark {
  width: 22px;
  height: 22px;
  border-radius: 5px;
  background: linear-gradient(135deg, var(--accent) 0%, #5eead4 100%);
  display: grid;
  place-items: center;
  color: #0a0a0f;
  /* brand mark: dark text stays dark in both themes (over the fixed gradient) */
  font-weight: 700;
  font-size: 12px;
  font-family: var(--font-mono);
  /* One-time pulse on first paint — brand memorability without a splash. */
  animation: brand-pulse 1200ms var(--ease) 250ms both;
}

@keyframes brand-pulse {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(var(--accent-rgb), 0.6);
  }
  40% {
    transform: scale(1.12);
    box-shadow: 0 0 0 8px rgba(var(--accent-rgb), 0);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(var(--accent-rgb), 0);
  }
}

.nav-links {
  display: flex;
  gap: var(--s-6);
  font-size: 14px;
  color: var(--fg-muted);
}

.nav-links a:hover {
  color: var(--fg);
}

.nav-cta {
  display: flex;
  gap: var(--s-3);
  align-items: center;
}

/* Theme toggle — always visible, small, unobtrusive */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--r-sm);
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--fg-muted);
  padding: 0;
  transition: color var(--dur) var(--ease), background var(--dur) var(--ease),
    border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}

.theme-toggle:hover {
  color: var(--fg);
  background: var(--surface-2);
  border-color: var(--accent);
}

.theme-toggle:active {
  transform: scale(0.94);
}

.theme-toggle-icon {
  width: 18px;
  height: 18px;
}

/* Button shows the target theme's icon (click to go there):
   default dark → show sun.
   light mode   → show moon. */
.theme-toggle-moon { display: none; }
.theme-toggle-sun { display: block; }

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

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .theme-toggle-sun { display: none; }
  :root:not([data-theme="dark"]) .theme-toggle-moon { display: block; }
}

/* Hamburger toggle — hidden on desktop */
.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: var(--r-sm);
  border: 1px solid var(--border-strong);
  background: var(--surface);
  padding: 0;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  transition: background var(--dur) var(--ease), border-color var(--dur) var(--ease);
}

.nav-toggle:hover {
  background: var(--surface-2);
  border-color: var(--accent);
}

.nav-toggle-bar {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--fg);
  border-radius: 1px;
  transition: transform var(--dur) var(--ease), opacity var(--dur) var(--ease);
}

.nav.is-open .nav-toggle-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav.is-open .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.nav.is-open .nav-toggle-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 820px) {
  .nav-toggle {
    display: inline-flex;
    order: 3;
  }

  .nav-cta {
    display: none;
  }

  .nav-links {
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
    padding: var(--s-2) 0 var(--s-4);
    background: rgba(var(--bg-rgb), 0.98);
    backdrop-filter: saturate(140%) blur(12px);
    -webkit-backdrop-filter: saturate(140%) blur(12px);
    border-bottom: 1px solid var(--border);
    font-size: 15px;
    max-height: 0;
    overflow: hidden;
    visibility: hidden;
    transition: max-height var(--dur) var(--ease), visibility 0s linear var(--dur);
  }

  .nav.is-open .nav-links {
    max-height: calc(100vh - 64px);
    visibility: visible;
    transition: max-height var(--dur) var(--ease), visibility 0s linear 0s;
  }

  .nav-links a {
    padding: var(--s-3) var(--s-6);
    color: var(--fg);
    border-top: 1px solid var(--border);
  }

  .nav-links a:first-child {
    border-top: none;
  }

  .nav.is-open::after {
    content: '';
    position: fixed;
    inset: 64px 0 0 0;
    background: rgba(var(--bg-rgb), 0.5);
    z-index: -1;
    pointer-events: none;
  }
}

/* ── Buttons ──────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  padding: 10px 18px;
  border-radius: var(--r);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.01em;
  transition: transform var(--dur) var(--ease), background var(--dur) var(--ease),
    border-color var(--dur) var(--ease), color var(--dur) var(--ease),
    box-shadow var(--dur) var(--ease);
  border: 1px solid transparent;
  white-space: nowrap;
  line-height: 1;
  cursor: pointer;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--fg);
  color: var(--bg);
  font-weight: 600;
}

.btn-primary:hover {
  background: var(--fg);
  filter: brightness(1.05);
  box-shadow: 0 10px 30px -12px var(--accent-glow);
}

.btn-accent {
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
}

.btn-accent:hover {
  background: var(--accent-bright);
  box-shadow: 0 10px 30px -12px var(--accent-glow);
}

.btn-ghost {
  color: var(--fg);
  border-color: var(--border-strong);
  background: transparent;
}

.btn-ghost:hover {
  background: var(--surface);
  border-color: rgba(var(--fg-rgb), 0.2);
}

.btn-lg {
  padding: 14px 24px;
  font-size: 15px;
  border-radius: var(--r);
}

.btn svg {
  width: 14px;
  height: 14px;
}

/* ── Hero ─────────────────────────────────────────────────── */
.hero {
  padding-top: var(--s-32);
  padding-bottom: var(--s-24);
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.hero-bg::before {
  content: '';
  position: absolute;
  top: -20%;
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  height: 100%;
  background:
    radial-gradient(600px 400px at 50% 40%, var(--accent-soft), transparent 70%);
  filter: blur(20px);
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  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 80% 50% at 50% 40%, #000 10%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse 80% 50% at 50% 40%, #000 10%, transparent 70%);
  opacity: 0.4;
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-16);
  align-items: center;
}

@media (min-width: 960px) {
  .hero-inner {
    grid-template-columns: 1.1fr 0.9fr;
    gap: var(--s-20);
  }
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  padding: 6px 12px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: rgba(var(--fg-rgb), 0.02);
  font-size: 12px;
  color: var(--fg-muted);
  margin-bottom: var(--s-6);
}

.hero-badge .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 8px currentColor;
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(40px, 6.5vw, 72px);
  line-height: 1;
  letter-spacing: -0.025em;
  color: var(--fg);
  margin-bottom: var(--s-6);
}

.hero-title em {
  font-style: italic;
  color: var(--accent-bright);
  font-family: var(--font-display);
}

.hero-sub {
  font-size: 18px;
  line-height: 1.55;
  color: var(--fg-muted);
  max-width: 540px;
  margin-bottom: var(--s-10);
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3);
  margin-bottom: var(--s-6);
}

.hero-micro {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--fg-dim);
  display: flex;
  gap: var(--s-6);
  flex-wrap: wrap;
}

.hero-micro span::before {
  content: '—';
  margin-right: var(--s-2);
  color: var(--accent);
}

/* ── Product preview (hero right) ─────────────────────────── */
.preview {
  --preview-rot-y: -6deg;
  --preview-rot-x: 2deg;
  position: relative;
  border: 1px solid var(--border-strong);
  border-radius: var(--r-lg);
  background: var(--surface);
  box-shadow: 0 40px 80px -20px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(var(--fg-rgb), 0.03) inset;
  overflow: hidden;
  transform: perspective(1600px) rotateY(var(--preview-rot-y)) rotateX(var(--preview-rot-x));
  transition: transform 900ms var(--ease), opacity 900ms var(--ease);
}

/* Pre-entrance state — JS adds this before first paint, removes after 400ms
   so the preview "flies in" from a more extreme tilt into its resting pose. */
.preview.pre-entrance {
  opacity: 0;
  transform: perspective(1600px) rotateY(-18deg) rotateX(6deg) translateX(30px) scale(0.96);
}

.preview:hover {
  --preview-rot-y: -3deg;
  --preview-rot-x: 1deg;
}

.preview-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  background: var(--bg-elev);
  border-bottom: 1px solid var(--border);
}

.preview-bar-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border-strong);
}

.preview-bar-url {
  margin-left: var(--s-3);
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fg-dim);
  background: rgba(var(--fg-rgb), 0.03);
  padding: 4px 10px;
  border-radius: 4px;
  flex: 1;
  min-width: 0;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.preview-body {
  padding: var(--s-6);
  display: grid;
  gap: var(--s-4);
}

.preview-card {
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: var(--s-4);
  background: linear-gradient(180deg, rgba(var(--fg-rgb),0.02) 0%, transparent 100%);
}

.preview-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--s-3);
  font-size: 12px;
}

.preview-card-title {
  font-weight: 600;
  color: var(--fg);
  letter-spacing: -0.01em;
}

.preview-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 3px 8px;
  border-radius: 4px;
  background: var(--accent-soft);
  color: var(--accent-bright);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.preview-tag.warn {
  background: rgba(245, 158, 11, 0.12);
  color: var(--warning);
}

.preview-tag.ok {
  background: rgba(16, 185, 129, 0.12);
  color: var(--success);
}

.preview-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  padding: 8px 0;
  border-top: 1px solid var(--border);
  color: var(--fg-muted);
}

.preview-row:first-child {
  border-top: none;
}

.preview-row-label {
  color: var(--fg-dim);
  font-family: var(--font-mono);
  font-size: 11px;
}

.preview-row-val {
  color: var(--fg);
  font-weight: 500;
}

.preview-cite {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--accent);
  margin-left: var(--s-2);
}

/* ── Trustbar ─────────────────────────────────────────────── */
.trustbar {
  padding-block: var(--s-10);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.trustbar-inner {
  display: flex;
  gap: var(--s-12);
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}

.trustbar-label {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--fg-dim);
}

.trustbar-logos {
  display: flex;
  gap: var(--s-10);
  align-items: center;
  flex-wrap: wrap;
  color: var(--fg-muted);
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
}

.trustbar-logo {
  opacity: 0.55;
  transition: opacity var(--dur) var(--ease);
}

.trustbar-logo:hover {
  opacity: 1;
}

/* ── Section header ───────────────────────────────────────── */
.section-head {
  max-width: 720px;
  margin-bottom: var(--s-16);
}

.section-head-center {
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

.section-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(32px, 4.5vw, 52px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--fg);
  margin-top: var(--s-4);
  margin-bottom: var(--s-4);
}

.section-title em {
  font-style: italic;
  color: var(--accent-bright);
}

.section-lede {
  font-size: 17px;
  color: var(--fg-muted);
  max-width: 640px;
  line-height: 1.55;
}

/* ── Manifesto (editorial break) ──────────────────────────── */
.manifesto {
  padding-block: var(--s-32);
  text-align: center;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}

.manifesto::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--accent-soft), transparent 60%);
  pointer-events: none;
}

.manifesto-quote {
  position: relative;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1.2;
  letter-spacing: -0.02em;
  max-width: 900px;
  margin: 0 auto;
  color: var(--fg);
}

.manifesto-quote em {
  font-style: italic;
  color: var(--accent-bright);
}

.manifesto-byline {
  margin-top: var(--s-8);
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--fg-dim);
}

/* ── Pillar sections (differentiated, not identical cards) ── */
.pillar {
  padding-block: var(--s-24);
}

.pillar-inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-12);
  align-items: center;
}

@media (min-width: 960px) {
  .pillar-inner {
    grid-template-columns: 1fr 1fr;
    gap: var(--s-20);
  }

  .pillar-reverse .pillar-inner {
    direction: rtl;
  }

  .pillar-reverse .pillar-inner > * {
    direction: ltr;
  }
}

.pillar-heading {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(28px, 4vw, 44px);
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-top: var(--s-4);
  margin-bottom: var(--s-6);
}

.pillar-body {
  font-size: 17px;
  color: var(--fg-muted);
  line-height: 1.6;
  margin-bottom: var(--s-6);
}

.pillar-points {
  list-style: none;
  padding: 0;
  display: grid;
  gap: var(--s-3);
}

.pillar-points li {
  padding-left: 24px;
  position: relative;
  font-size: 15px;
  color: var(--fg-muted);
  line-height: 1.5;
}

.pillar-points li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 9px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

/* Unique visual for each pillar */
.visual {
  position: relative;
  border: 1px solid var(--border-strong);
  border-radius: var(--r-lg);
  background: var(--surface);
  padding: var(--s-6);
  overflow: hidden;
  min-height: 340px;
}

.visual::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--accent-glow), transparent);
}

/* Visual 1: citations */
.visual-citations .cite-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--s-3);
  padding: var(--s-3) 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}

.visual-citations .cite-row:last-child {
  border-bottom: none;
}

.visual-citations .cite-text {
  color: var(--fg);
}

.visual-citations .cite-source {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--accent);
  padding: 2px 8px;
  border: 1px solid var(--accent-soft);
  border-radius: 4px;
  white-space: nowrap;
}

.visual-citations .cite-query {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--fg-dim);
  margin-bottom: var(--s-4);
  padding: var(--s-3);
  background: var(--bg-elev);
  border-radius: var(--r-sm);
}

.visual-citations .cite-query::before {
  content: '> ';
  color: var(--accent);
}

/* Visual 2: workflow */
.visual-workflow .flow-step {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: var(--s-4);
  padding: var(--s-3) 0;
  font-size: 13px;
  align-items: start;
  position: relative;
}

.visual-workflow .flow-step::before {
  content: '';
  position: absolute;
  left: 36px;
  top: 28px;
  bottom: -8px;
  width: 1px;
  background: var(--border);
}

.visual-workflow .flow-step:last-child::before {
  display: none;
}

.visual-workflow .flow-time {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--fg-dim);
  padding-top: 2px;
}

.visual-workflow .flow-content {
  color: var(--fg);
  position: relative;
}

.visual-workflow .flow-content::before {
  content: '';
  position: absolute;
  left: -20px;
  top: 7px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--surface);
  border: 2px solid var(--accent);
}

.visual-workflow .flow-sub {
  font-size: 12px;
  color: var(--fg-muted);
  margin-top: 2px;
}

/* Visual 3: stats */
.visual-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-4);
  padding: 0;
}

.visual-stats .stat {
  padding: var(--s-6);
  border: 1px solid var(--border);
  border-radius: var(--r);
  background: linear-gradient(180deg, rgba(139,124,246,0.04) 0%, transparent 100%);
}

.visual-stats .stat-big {
  font-family: var(--font-display);
  font-size: 44px;
  line-height: 1;
  color: var(--fg);
  letter-spacing: -0.03em;
  margin-bottom: var(--s-2);
}

.visual-stats .stat-big em {
  font-family: var(--font-mono);
  font-size: 16px;
  color: var(--accent);
  font-style: normal;
  vertical-align: middle;
  margin-left: 4px;
}

.visual-stats .stat-label {
  font-size: 13px;
  color: var(--fg-muted);
  line-height: 1.4;
}

/* ── Modules strip (product breadth) ──────────────────────── */
.modules {
  padding-block: var(--s-24);
  border-top: 1px solid var(--border);
}

.modules-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  margin-top: var(--s-10);
}

@media (min-width: 720px) {
  .modules-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 960px) {
  .modules-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.module {
  background: var(--surface);
  padding: var(--s-8) var(--s-6);
  transition: background var(--dur) var(--ease);
  position: relative;
}

.module:hover {
  background: var(--surface-2);
}

.module-num {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--fg-dim);
  letter-spacing: 0.12em;
  margin-bottom: var(--s-4);
}

.module-name {
  font-family: var(--font-display);
  font-size: 22px;
  letter-spacing: -0.02em;
  color: var(--fg);
  margin-bottom: var(--s-3);
  line-height: 1.1;
}

.module-desc {
  font-size: 13px;
  color: var(--fg-muted);
  line-height: 1.5;
}

.module-badge {
  position: absolute;
  top: var(--s-4);
  right: var(--s-4);
  font-family: var(--font-mono);
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  background: var(--accent-soft);
  padding: 2px 6px;
  border-radius: 3px;
}

/* ── Enterprise block ─────────────────────────────────────── */
.enterprise {
  padding-block: var(--s-24);
  border-top: 1px solid var(--border);
  background:
    radial-gradient(800px 400px at 80% 50%, var(--accent-soft), transparent 60%);
}

.enterprise-inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-10);
  align-items: center;
}

@media (min-width: 960px) {
  .enterprise-inner {
    grid-template-columns: 1fr 1fr;
    gap: var(--s-16);
  }
}

.enterprise-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(30px, 4vw, 44px);
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: var(--s-4);
}

.enterprise-title em {
  font-style: italic;
  color: var(--accent-bright);
}

.enterprise-desc {
  font-size: 16px;
  color: var(--fg-muted);
  line-height: 1.6;
  margin-bottom: var(--s-6);
}

.enterprise-features {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--s-3) var(--s-4);
  margin-bottom: var(--s-8);
}

.enterprise-features li {
  list-style: none;
  font-size: 14px;
  color: var(--fg-muted);
  padding-left: var(--s-4);
  position: relative;
  line-height: 1.5;
}

.enterprise-features li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
  font-size: 12px;
}

/* Grouped enterprise capabilities — conveys breadth without overwhelming */
.enterprise-capabilities {
  display: flex;
  flex-direction: column;
  gap: var(--s-6);
  margin-bottom: var(--s-8);
}

.enterprise-cap-group {
  padding-top: var(--s-4);
  border-top: 1px solid var(--border);
}

.enterprise-cap-group:first-child {
  padding-top: 0;
  border-top: none;
}

.enterprise-cap-title {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: var(--s-3);
}

.enterprise-cap-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--s-2) var(--s-4);
}

.enterprise-cap-list li {
  list-style: none;
  font-size: 14px;
  color: var(--fg-muted);
  padding-left: var(--s-4);
  position: relative;
  line-height: 1.5;
}

.enterprise-cap-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
  font-size: 12px;
}

@media (max-width: 720px) {
  .enterprise-cap-list {
    grid-template-columns: 1fr;
  }
}

.enterprise-card {
  border: 1px solid var(--border-strong);
  border-radius: var(--r-lg);
  background: var(--surface);
  padding: var(--s-6);
  position: relative;
}

.enterprise-card-title {
  font-size: 13px;
  color: var(--fg-muted);
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: var(--s-4);
  padding-bottom: var(--s-3);
  border-bottom: 1px solid var(--border);
}

.enterprise-flow {
  display: flex;
  flex-direction: column;
  gap: 0;
  font-size: 13px;
}

.enterprise-flow-step {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: var(--s-3);
  padding: var(--s-3) 0;
  border-bottom: 1px solid var(--border);
  align-items: center;
}

.enterprise-flow-step:last-child {
  border-bottom: none;
}

.enterprise-flow-num {
  font-family: var(--font-mono);
  font-size: 10px;
  background: var(--bg-elev);
  color: var(--accent);
  width: 20px;
  height: 20px;
  border-radius: 4px;
  display: grid;
  place-items: center;
}

.enterprise-flow-label {
  color: var(--fg);
}

.enterprise-flow-meta {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--fg-dim);
  background: var(--bg-elev);
  padding: 2px 8px;
  border-radius: 4px;
}

/* ── Surfaces — where CounselGrid lives (web, mobile, Word, WA) ── */
.surfaces {
  padding-block: var(--s-24);
  border-top: 1px solid var(--border);
}

.surfaces-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--s-4);
  margin-top: var(--s-10);
}

.surface {
  position: relative;
  padding: var(--s-6);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-lg);
  background: var(--surface);
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}

.surface:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}

.surface-featured {
  border-color: var(--accent);
  background: linear-gradient(180deg, var(--accent-soft) 0%, var(--surface) 60%);
}

.surface-badge {
  position: absolute;
  top: var(--s-3);
  right: var(--s-3);
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--on-accent);
  background: var(--accent);
  padding: 3px 8px;
  border-radius: 999px;
  white-space: nowrap;
}

.surface-icon {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: var(--r-sm);
  background: var(--accent-soft);
  color: var(--accent);
  margin-bottom: var(--s-3);
}

.surface-icon svg {
  width: 20px;
  height: 20px;
}

.surface-name {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: var(--s-2);
  color: var(--fg);
}

.surface-desc {
  font-size: 13px;
  line-height: 1.55;
  color: var(--fg-muted);
}

/* ── Personas (slim version) ──────────────────────────────── */
.personas {
  padding-block: var(--s-24);
  border-top: 1px solid var(--border);
}

.personas-grid {
  display: grid;
  gap: var(--s-4);
  grid-template-columns: 1fr;
}

@media (min-width: 720px) {
  .personas-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1080px) {
  .personas-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.persona {
  padding: var(--s-8);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--surface);
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}

.persona:hover {
  border-color: var(--border-strong);
  transform: translateY(-2px);
}

.persona-scale {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: var(--s-3);
}

.persona-name {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 22px;
  letter-spacing: -0.01em;
  margin-bottom: var(--s-3);
  color: var(--fg);
}

.persona-desc {
  font-size: 14px;
  color: var(--fg-muted);
  line-height: 1.55;
}

/* ── Plans ────────────────────────────────────────────────── */
.plans {
  padding-block: var(--s-24);
  border-top: 1px solid var(--border);
  position: relative;
}

.plans-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-6);
  margin-top: var(--s-12);
  align-items: stretch;
}

.plan {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: var(--s-8);
  border: 1px solid var(--border-strong);
  border-radius: var(--r-lg);
  background: var(--surface);
  transition: border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}

.plan:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}

.plan-featured {
  border-color: var(--accent);
  background: linear-gradient(180deg, var(--accent-soft) 0%, var(--surface) 60%);
  box-shadow: 0 20px 40px -20px var(--accent-glow);
}

.plan-badge {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--on-accent);
  background: var(--accent);
  padding: 5px 12px;
  border-radius: 999px;
  white-space: nowrap;
}

.plan-head {
  margin-bottom: var(--s-6);
}

.plan-name {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.05;
  margin-bottom: var(--s-2);
  color: var(--fg);
}

.plan-price {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: var(--s-3);
}

.plan-desc {
  font-size: 14px;
  color: var(--fg-muted);
  line-height: 1.55;
}

.plan-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  margin-bottom: var(--s-8);
  flex: 1;
}

.plan-features li {
  font-size: 14px;
  color: var(--fg);
  padding-left: var(--s-6);
  position: relative;
  line-height: 1.5;
}

.plan-features li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 7px;
  width: 14px;
  height: 8px;
  border-left: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg);
}

.plan-cta {
  width: 100%;
  justify-content: center;
  margin-top: auto;
}

.plans-footnote {
  text-align: center;
  font-size: 13px;
  margin-top: var(--s-10);
}

@media (max-width: 900px) {
  .plans-grid {
    grid-template-columns: 1fr;
    gap: var(--s-8);
  }

  .plan-featured {
    order: -1; /* put featured tier first when stacked */
  }
}

/* ── Security & Privacy ──────────────────────────────────── */
.security {
  padding-block: var(--s-24);
  border-top: 1px solid var(--border);
  position: relative;
}

.security-head {
  max-width: 760px;
  margin: 0 auto var(--s-12);
  text-align: center;
}

.security-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-4);
}

@media (min-width: 720px) {
  .security-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1080px) {
  .security-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.security-item {
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: var(--s-6);
  background: var(--surface);
  transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease);
  position: relative;
}

.security-item:hover {
  border-color: var(--border-strong);
  background: var(--surface-2);
}

.security-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--accent-soft);
  display: grid;
  place-items: center;
  margin-bottom: var(--s-4);
  color: var(--accent-bright);
}

.security-icon svg {
  width: 16px;
  height: 16px;
  stroke-width: 2;
}

.security-name {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--fg);
  margin-bottom: var(--s-2);
}

.security-detail {
  font-size: 13px;
  color: var(--fg-muted);
  line-height: 1.5;
}

.security-note {
  margin-top: var(--s-10);
  padding: var(--s-6);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--bg-elev);
  text-align: center;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--fg-muted);
  line-height: 1.6;
}

.security-note em {
  font-style: normal;
  color: var(--fg);
}

/* ── FAQ ──────────────────────────────────────────────────── */
.faq {
  padding-block: var(--s-24);
  border-top: 1px solid var(--border);
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-top: var(--s-10);
  border-top: 1px solid var(--border);
}

.faq-item {
  border-bottom: 1px solid var(--border);
  padding: var(--s-6) 0;
}

.faq-q {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--fg);
  cursor: pointer;
  text-align: left;
}

.faq-q-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--fg-muted);
  transition: transform var(--dur) var(--ease), color var(--dur) var(--ease);
}

.faq-item[open] .faq-q-icon {
  transform: rotate(45deg);
  color: var(--accent);
}

.faq-a {
  padding-top: var(--s-4);
  font-size: 15px;
  color: var(--fg-muted);
  line-height: 1.65;
  max-width: 760px;
}

/* ── Final CTA ────────────────────────────────────────────── */
.final-cta {
  padding-block: var(--s-32);
  position: relative;
  text-align: center;
  overflow: hidden;
  border-top: 1px solid var(--border);
}

.final-cta::before {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -50%;
  transform: translateX(-50%);
  width: 1200px;
  height: 1200px;
  background: radial-gradient(circle, var(--accent-soft), transparent 60%);
  pointer-events: none;
}

.final-cta-inner {
  position: relative;
  z-index: 1;
}

.final-cta-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1;
  letter-spacing: -0.025em;
  margin-bottom: var(--s-6);
}

.final-cta-title em {
  font-style: italic;
  color: var(--accent-bright);
}

.final-cta-sub {
  font-size: 18px;
  color: var(--fg-muted);
  max-width: 560px;
  margin: 0 auto var(--s-10);
}

.final-cta-buttons {
  display: flex;
  gap: var(--s-3);
  justify-content: center;
  flex-wrap: wrap;
}

/* ── Footer ───────────────────────────────────────────────── */
.footer {
  padding-block: var(--s-16) var(--s-10);
  border-top: 1px solid var(--border);
  font-size: 14px;
  color: var(--fg-muted);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--s-10);
  margin-bottom: var(--s-12);
}

@media (max-width: 720px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: var(--s-8) var(--s-6);
  }

  /* Brand block spans both columns so the 3 link cols line up 1fr 1fr beneath */
  .footer-grid > div:first-child {
    grid-column: 1 / -1;
  }
}

.footer-brand {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--fg);
  margin-bottom: var(--s-3);
}

.footer-tag {
  font-size: 13px;
  line-height: 1.5;
  color: var(--fg-dim);
  max-width: 280px;
}

.footer-col h4 {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--fg-dim);
  margin-bottom: var(--s-4);
  font-weight: 500;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

.footer-col a {
  font-size: 14px;
  color: var(--fg-muted);
}

.footer-col a:hover {
  color: var(--fg);
}

.footer-bottom {
  padding-top: var(--s-6);
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--fg-dim);
  font-family: var(--font-mono);
}

/* ── Floating WhatsApp (minimal) ───────────────────────────── */
.fab-wa {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 40;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #25d366;
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 10px 30px -10px rgba(37, 211, 102, 0.5);
  transition: transform var(--dur) var(--ease);
}

.fab-wa:hover {
  transform: scale(1.1);
}

/* ── Motion (respect prefers-reduced-motion) ──────────────── */

/* Hero entrance — staggered fade + gentle rise.
   Applied via .js-hero-enter on <body> so entrance only runs for users
   with JS (and with motion allowed). */
@keyframes hero-rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.js-motion .hero-badge,
.js-motion .hero-title,
.js-motion .hero-sub,
.js-motion .hero-cta,
.js-motion .hero-micro {
  animation: hero-rise 620ms var(--ease) both;
}

.js-motion .hero-badge { animation-delay:  80ms; }
.js-motion .hero-title { animation-delay: 180ms; }
.js-motion .hero-sub   { animation-delay: 320ms; }
.js-motion .hero-cta   { animation-delay: 460ms; }
.js-motion .hero-micro { animation-delay: 600ms; }

/* Reveal on scroll — adds subtle 3D perspective so sections "land" in
   instead of just fading up. Grid children stagger via :nth-child. */
.reveal {
  opacity: 0;
  transform: perspective(1200px) translateY(22px) rotateX(4deg);
  transform-origin: 50% 90%;
  transition: opacity 720ms var(--ease), transform 720ms var(--ease);
  will-change: opacity, transform;
}

.reveal.is-visible {
  opacity: 1;
  transform: perspective(1200px) translateY(0) rotateX(0deg);
}

/* Staggered reveals inside grids — items enter one after the other
   rather than all at once when the grid scrolls into view. */
.modules-grid .reveal:nth-child(1) { transition-delay:   0ms; }
.modules-grid .reveal:nth-child(2) { transition-delay:  70ms; }
.modules-grid .reveal:nth-child(3) { transition-delay: 140ms; }
.modules-grid .reveal:nth-child(4) { transition-delay: 210ms; }
.modules-grid .reveal:nth-child(5) { transition-delay: 280ms; }

.personas-grid .reveal:nth-child(1) { transition-delay:   0ms; }
.personas-grid .reveal:nth-child(2) { transition-delay:  80ms; }
.personas-grid .reveal:nth-child(3) { transition-delay: 160ms; }
.personas-grid .reveal:nth-child(4) { transition-delay: 240ms; }

.security-grid .reveal:nth-child(1) { transition-delay:   0ms; }
.security-grid .reveal:nth-child(2) { transition-delay:  70ms; }
.security-grid .reveal:nth-child(3) { transition-delay: 140ms; }
.security-grid .reveal:nth-child(4) { transition-delay: 210ms; }
.security-grid .reveal:nth-child(5) { transition-delay: 280ms; }
.security-grid .reveal:nth-child(6) { transition-delay: 350ms; }

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .preview,
  .preview.pre-entrance {
    transform: none;
    opacity: 1;
  }

  .brand-mark {
    animation: none;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}

/* ── Mobile tweaks ────────────────────────────────────────── */
@media (max-width: 720px) {
  /* Breathing room / type scale */
  .container,
  .container-tight,
  .container-prose {
    padding-inline: var(--s-4);
  }

  .nav-inner {
    padding-inline: var(--s-4);
  }

  .hero {
    padding-top: var(--s-16);
    padding-bottom: var(--s-16);
  }

  .section-pad,
  .pillar,
  .personas,
  .faq,
  .modules,
  .enterprise,
  .surfaces,
  .plans,
  .security {
    padding-block: var(--s-16);
  }

  .manifesto,
  .final-cta {
    padding-block: var(--s-20);
  }

  /* Hero typography — looser line-height reads better at 40px */
  .hero-title {
    font-size: 36px;
    line-height: 1.08;
  }

  .hero-sub {
    font-size: 16px;
  }

  /* Section headings — prevent cramped display */
  .section-title {
    font-size: 28px;
    line-height: 1.15;
  }

  .pillar-heading {
    font-size: 26px;
    line-height: 1.15;
  }

  .enterprise-title {
    font-size: 26px;
    line-height: 1.2;
  }

  .final-cta-title {
    font-size: 34px;
    line-height: 1.1;
  }

  .manifesto-quote {
    font-size: 26px;
    line-height: 1.25;
  }

  /* Preview downgrade (already disabled tilt; drop margin noise) */
  .preview {
    transform: none;
  }

  /* Tap-target friendly: stack primary CTAs full-width on phones */
  .hero-cta,
  .final-cta-buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-cta .btn,
  .final-cta-buttons .btn {
    width: 100%;
    justify-content: center;
  }

  /* Enterprise CTAs too */
  .enterprise .hero-cta .btn {
    width: 100%;
  }

  /* Hero micro strip: tighter gap so three chips fit cleanly */
  .hero-micro {
    gap: var(--s-3) var(--s-4);
    font-size: 11px;
  }

  /* Trustbar: stack the label and inner cluster */
  .trustbar-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--s-4);
  }

  .trustbar-logos {
    width: 100%;
    justify-content: space-between;
    gap: var(--s-3);
  }

  /* Enterprise example card: tighter padding, smaller labels */
  .enterprise-card {
    padding: var(--s-5, 20px);
  }

  /* Stats grid — 2×2 fits on narrow screens when font is scaled */
  .visual-stats .stat-big {
    font-size: 34px;
  }

  /* FAQ: more breathing space and larger tap area for the summary */
  .faq-item {
    padding-block: var(--s-4);
  }

  .faq-q {
    gap: var(--s-3);
  }

  /* WhatsApp FAB: smaller + tucked into safe area on phones */
  .fab-wa {
    right: 16px;
    bottom: 16px;
    width: 44px;
    height: 44px;
  }
}

/* Extra narrow (≤380 px) — prevent squish on compact devices */
@media (max-width: 380px) {
  .hero-title {
    font-size: 32px;
  }

  .final-cta-title {
    font-size: 30px;
  }

  .manifesto-quote {
    font-size: 22px;
  }

  .visual-stats {
    grid-template-columns: 1fr;
  }
}
