/* cache-epoch 2026-07-03: content bump to abandon a poisoned immutable-404 edge entry (see _middleware.js addCacheHeaders note) */
/* ==========================================================================
   V3 — Midnight Signal 2.0
   V1 as baseline. Logo blue. Centered hero. Radix-inspired dark scale.
   ========================================================================== */

:root {
  /* Neutrals — Radix-inspired 12-step dark scale */
  --n-1:  #08090B;   /* void */
  --n-2:  #0C0D11;   /* bg */
  --n-3:  #13151C;   /* surface */
  --n-4:  #181A23;   /* surface-2 */
  --n-5:  #1F2230;   /* surface-3 / border subtle */
  --n-6:  #2A2D3D;   /* border */
  --n-7:  #343749;   /* border-hi / element hover */
  --n-8:  #454967;   /* element active */
  --n-9:  #5C6070;   /* text-ghost — decorative separators, disabled (2.7:1, ok for non-text UI) */
  --n-10: #8A8D99;   /* text-dim — meta labels, hints (~5:1 on bg, AA ✓) */
  --n-11: #B4B7C2;   /* text-muted — body copy, descriptions (~8:1 on bg, AAA ✓) */
  --n-12: #F0F1F5;   /* text — headings, primary (~14:1 on bg, AAA ✓) */

  /* Accessibility — token contrast ratios on --bg (#0C0D11):
     text (F0F1F5)      ~14:1  AAA
     text-muted (B4B7C2) ~8:1   AAA
     text-dim (8A8D99)   ~5:1   AA ✓
     text-ghost (5C6070) ~2.7:1 decorative only (separators, icon backdrops)
     blue-text (58A9F0)  ~7:1   AAA
     ok (22C55E)         ~7.5:1 AAA
     warn (F59E0B)       ~9.5:1 AAA
     err (EF4444)        ~4.8:1 AA ✓
  */

  /* Convenience aliases */
  --bg-void:      var(--n-1);
  --bg:           var(--n-2);
  --surface:      var(--n-3);
  --surface-2:    var(--n-4);
  --surface-hi:   var(--n-5);
  --border:       var(--n-5);
  --border-hi:    var(--n-7);
  --text:         var(--n-12);
  --text-muted:   var(--n-11);
  --text-dim:     var(--n-10);
  --text-ghost:   var(--n-9);

  /* Accent — logo mark anchors to #0078D4, text/hover accents push brighter
     for more luminance on dark surfaces (blue channel maxed closer to 255) */
  --blue-primary:  #0078D4;       /* logo blue · solid buttons, active states */
  --blue-hi:       #1F93FF;       /* hover · more electric, higher B channel */
  --blue-text:     #4FA8FF;       /* readable accent text — punchier on dark */
  --blue-soft:     #7AC0FF;       /* inline highlights */
  --blue-deep:     #0060B8;       /* pressed / deep backgrounds */
  --blue-glow:     rgba(31,147,255,0.32);
  --blue-glow-soft:rgba(31,147,255,0.15);
  --blue-wash:     rgba(31,147,255,0.07);

  --accent:        var(--blue-primary);
  --accent-hi:     var(--blue-hi);
  --accent-text:   var(--blue-text);
  --accent-deep:   var(--blue-deep);
  --accent-glow:   var(--blue-glow);
  --accent-wash:   var(--blue-wash);

  /* Group accents — locked palette (8 groups, indigo 400 through gold).
     All Tailwind-400-weight level for uniform luminance + saturation on dark.
     Semantic logic: Foundation = indigo (strategic/intellectual);
     Business = bright blue; Growth = green (grows); Brand = violet (creative);
     Retention = orange (warmth); Scale = pink (expansion);
     Numbers = cyan (data); Exit = gold (finish). */
  --g-foundation: #818CF8;
  --g-business:   #3B9AFC;
  --g-growth:     #4ADE80;
  --g-brand:      #A78BFA;
  --g-retention:  #FB923C;
  --g-scale:      #F472B6;
  --g-numbers:    #22D3EE;
  --g-exit:       #FCD34D;

  /* Status — saturated, readable on dark, consistent across the system */
  --ok:           #22C55E;   /* emerald-500 */
  --warn:         #F59E0B;   /* amber-500 */
  --err:          #EF4444;   /* red-500 */
  --ok-glow:      rgba(34,197,94,0.22);
  --warn-glow:    rgba(245,158,11,0.22);
  --err-glow:     rgba(239,68,68,0.22);

  /* Type */
  --font-sans:    'Inter', system-ui, -apple-system, sans-serif;
  --font-mono:    'JetBrains Mono', 'SF Mono', Menlo, monospace;

  /* Spacing (4px base) */
  --s-1: 4px;  --s-2: 8px;   --s-3: 12px;  --s-4: 16px;
  --s-5: 24px; --s-6: 32px;  --s-7: 48px;  --s-8: 64px;
  --s-9: 96px; --s-10: 128px;

  /* Radius */
  --r-sm: 6px; --r-md: 10px; --r-lg: 14px; --r-xl: 20px;

  /* Shadow */
  --shadow-1: 0 1px 0 rgba(255,255,255,0.02) inset, 0 4px 12px rgba(0,0,0,0.25);
  --shadow-glow: 0 0 0 1px var(--border-hi), 0 0 48px -8px var(--accent-glow);
}

/* ==========================================================================
   Reset & base
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html {
  background: var(--bg-void);
  color-scheme: dark;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.6;
  font-feature-settings: "ss01", "cv11", "tnum";
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

/* Hero glow — deep atmospheric blue bloom, pulled down further for presence */
body::before {
  content: "";
  position: fixed;
  top: -500px; left: 50%;
  transform: translateX(-50%);
  width: 1600px; height: 1200px;
  background:
    radial-gradient(ellipse 60% 50% at center 30%, rgba(0,120,212,0.22) 0%, rgba(0,120,212,0.08) 35%, transparent 60%);
  pointer-events: none;
  z-index: 0;
  filter: blur(8px);
}

/* Subtle grain texture — stops backgrounds from reading 'digital flat' */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.04 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

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

/* Inline content links — distinguishable from regular text.
   Scoped to .section-body-content so navigation/wrapper anchors
   (sidebar, header, tool-card wrappers) stay unstyled.
   :not([class]) excludes class-bearing wrappers like a.tool-card —
   inline links generated from markdown have no class. */
.section-body-content a:not([class]) {
  color: var(--accent-text);
  text-decoration: underline;
  text-decoration-color: rgba(79, 168, 255, 0.4);
  text-underline-offset: 3px;
  transition: color 0.15s, text-decoration-color 0.15s;
}
.section-body-content a:not([class]):hover {
  color: var(--blue-text);
  text-decoration-color: var(--accent-text);
}

img, svg { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }
::selection { background: var(--blue-glow); color: white; }

/* ==========================================================================
   Typography system
   ========================================================================== */
.eyebrow,
.meta-label,
.mono-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  line-height: 1;
  color: var(--text-dim);
}
.eyebrow--accent { color: var(--accent-text); }
.mono-data {
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.4;
  font-weight: 400;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

h1, h2, h3, h4 { margin: 0; font-weight: 700; letter-spacing: -0.02em; color: var(--text); }
h1 { font-size: 44px; line-height: 1.05; letter-spacing: -0.03em; }
h2 { font-size: 28px; line-height: 1.15; }
h3 { font-size: 19px; line-height: 1.3; font-weight: 600; letter-spacing: -0.01em; }
h4 { font-size: 15px; line-height: 1.4; font-weight: 600; letter-spacing: 0; }

p { margin: 0 0 var(--s-4); color: var(--text-muted); }
p.lead { font-size: 17px; line-height: 1.6; color: var(--text); }

hr { border: none; border-top: 1px solid var(--border); margin: var(--s-6) 0; }

/* ==========================================================================
   Top bar — with cmdbar search
   ========================================================================== */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 55%, transparent);
  backdrop-filter: blur(24px) saturate(1.5);
  -webkit-backdrop-filter: blur(24px) saturate(1.5);
  border-bottom: 1px solid var(--border);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 8px 24px -12px rgba(0,0,0,0.4);
}
.topbar-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 14px 32px;
  display: flex; align-items: center; gap: var(--s-5);
}
.brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; letter-spacing: -0.015em;
  font-size: 14px;
  color: var(--text);
}
/* Brand wordmark accent — the "DTC" in "The DTC Playbook" renders in the brand
   blue anywhere it appears (body copy, headings, ledes). Component-scoped
   .accent rules (e.g. the glowing .hero-title .accent) override this by
   specificity, so hero glow etc. is preserved. */
.accent { color: var(--accent-text); }
.brand .accent { color: var(--accent-text); }
.brand-logo {
  width: 26px; height: 26px;
  flex-shrink: 0;
}
.nav {
  display: flex; align-items: center; gap: var(--s-5);
  margin-left: auto;
}
.nav a {
  font-size: 13px; color: var(--text-muted);
  transition: color 0.15s;
}
.nav a:hover { color: var(--text); }

/* Simple search link in nav — no keyboard-palette pretence */
.nav-search {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px;
  color: var(--text-muted);
  transition: color 0.15s;
}
.nav-search:hover { color: var(--text); }
.nav-search svg { color: var(--text-dim); }
.nav-search:hover svg { color: var(--accent-text); }

.kbd {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 3px 7px;
  border: 1px solid var(--border-hi);
  border-bottom-width: 2px;
  border-radius: 5px;
  background: var(--surface-2);
  font: 500 10px/1 var(--font-mono);
  color: var(--text-muted);
  min-height: 20px;
  font-variant-numeric: tabular-nums;
}

/* ==========================================================================
   Layout
   ========================================================================== */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--s-6);
  position: relative;
  z-index: 1;
}
.container--narrow { max-width: 880px; }
.container--wide { max-width: 1440px; }

/* ==========================================================================
   Hero — centered, real logo, no kbd pills
   ========================================================================== */
.hero {
  padding: var(--s-9) 0 var(--s-8);
  text-align: center;
  position: relative;
}
.hero-logo {
  width: 76px; height: 76px;
  margin: 0 auto var(--s-5);
  display: block;
  filter: drop-shadow(0 8px 24px var(--blue-glow));
}
.hero-eyebrow {
  margin-bottom: var(--s-5);
  display: inline-flex; gap: 10px; align-items: center;
  padding: 6px 14px;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 100px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}
.hero-eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent);
}
.hero-title {
  font-size: clamp(40px, 5.6vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.04em;
  font-weight: 800;
  margin: 0 auto var(--s-5);
  max-width: 1040px;
  color: var(--text);
  text-wrap: balance;
}
.hero-title .accent {
  color: var(--blue-hi);
  text-shadow:
    0 0 24px rgba(0,120,212,0.35),
    0 0 64px rgba(0,120,212,0.15);
}
.hero-title .muted { color: var(--text-dim); font-weight: 700; }
.hero-lead {
  font-size: 18px;
  line-height: 1.55;
  color: var(--text-muted);
  max-width: 620px;
  margin: 0 auto var(--s-6);
}
.hero-signoff {
  color: var(--text-dim);
  white-space: nowrap;
  font-style: italic;
}
.hero-meta {
  display: flex; justify-content: center; gap: var(--s-4);
  margin-top: var(--s-6);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  flex-wrap: wrap;
}
.hero-meta span { display: flex; align-items: center; gap: 8px; }
.hero-meta .sep { color: var(--text-ghost); }
.hero-meta .dot-ok {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 8px var(--ok);
}

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

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 22px;
  border-radius: 8px;
  font: 600 14px/1 var(--font-sans);
  letter-spacing: -0.005em;
  border: 1px solid transparent;
  transition: background 0.15s, border-color 0.15s, transform 0.1s, box-shadow 0.25s;
  cursor: pointer;
}
.btn:active { transform: translateY(1px); }
.btn--primary {
  background: var(--accent);
  color: white;
  border-color: rgba(255,255,255,0.1);
  box-shadow:
    0 8px 24px -6px var(--blue-glow),
    0 0 0 1px rgba(255,255,255,0.06) inset,
    0 1px 0 rgba(255,255,255,0.12) inset;
}
.btn--primary:hover {
  background: var(--accent-hi);
  box-shadow:
    0 12px 32px -6px var(--blue-glow),
    0 0 0 1px rgba(255,255,255,0.08) inset,
    0 1px 0 rgba(255,255,255,0.16) inset;
}
.btn--ghost {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border-hi);
}
.btn--ghost:hover { background: var(--surface-2); border-color: var(--border-hi); }
.btn .icon { width: 16px; height: 16px; }

/* ==========================================================================
   Three steps (how it works) — icons + big mono numbers + hover lift
   ========================================================================== */
/* Three steps (how it works) — horizontal trio with numbered circles
   that pop up out of the top edge of each card. No connector line
   between them: the numbered circles alone signal sequence, and a
   gradient stripe across the top read as noise rather than a
   connection (the circles cover its middle, the gradient fade kills
   its ends). Keeps .step and .step-cta class names so the JS
   hydration (data-step-cta="N") continues to work. */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-4);
  margin: var(--s-8) 0 var(--s-9);
  padding-top: 40px;
}
.step {
  padding: var(--s-5);
  /* Subtle blue glow — same radial-gradient language as .callout but
     lighter (10% top-right + 4% bottom-left vs. 18/7) because the
     steps already carry strong visual weight from the -28px top
     numbered ring. No per-card tones: steps are a unified "do this
     next" sequence, not three separate callouts. */
  background:
    radial-gradient(ellipse 80% 70% at top right,
      color-mix(in srgb, var(--accent) 10%, transparent) 0%,
      transparent 60%),
    radial-gradient(ellipse 60% 100% at bottom left,
      color-mix(in srgb, var(--accent) 4%, transparent) 0%,
      transparent 55%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.25s;
  position: relative;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 2px 6px rgba(0,0,0,0.15);
  display: flex; flex-direction: column;
  text-align: center;
  min-height: 220px;
}
.step:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 14px 32px -8px rgba(0,0,0,0.35);
}
.step:hover .step-cta { color: var(--blue-hi); }
.step-circle {
  position: absolute;
  top: -28px;
  left: 50%;
  transform: translateX(-50%);
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--bg);
  border: 1px solid var(--border-hi);
  display: grid; place-items: center;
  font: 600 20px/1 var(--font-mono);
  color: var(--accent-text);
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  box-shadow:
    0 0 0 4px var(--bg),
    inset 0 1px 0 rgba(255,255,255,0.05);
  transition: border-color 0.2s, color 0.2s;
  z-index: 2;
}
.step:hover .step-circle { border-color: var(--accent); }
.step-kicker {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  margin-top: var(--s-5);
  margin-bottom: var(--s-2);
}
.step-title {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: var(--s-3);
  color: var(--text);
}
.step-desc {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-muted);
  margin-bottom: var(--s-4);
  flex: 1;
}
/* CTA row at the bottom of each step card — always visible so the card
   reads as "an action you can take", not a static description. Hydrated
   by JS to show live state (score pill, "next: Email & SMS", etc). */
.step-cta {
  padding-top: var(--s-3);
  border-top: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-text);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: color 0.15s, gap 0.15s;
}
/* Done state — small green corner tick, dim the desc + CTA. No tint
   on the card itself (Rob: too much green upsets the page). */
.step.is-done .step-desc { color: var(--text-dim); font-size: 12px; }
.step.is-done .step-cta { color: var(--text-muted); }
.step.is-done::after {
  content: "";
  position: absolute;
  top: -14px;
  right: 14px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2322C55E' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'><path d='M20 6 9 17l-5-5'/></svg>") center/13px no-repeat,
    var(--bg);
  border: 1px solid color-mix(in srgb, var(--ok) 50%, transparent);
  box-shadow: 0 0 0 3px var(--bg);
  pointer-events: none;
  z-index: 3;
}
@media (max-width: 720px) {
  .steps { grid-template-columns: 1fr; gap: var(--s-6); padding-top: 40px; }
  .steps::before { display: none; }
}
/* HC score pill embedded inside step 2's CTA row — shows the latest
   overall_score + rating for returning users. Pill colours match the
   .bsr-hc tone bands (green ≥70, amber 45-69, red <45). */
.step-cta-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  background: color-mix(in srgb, var(--hc-tone, var(--accent-text)) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--hc-tone, var(--accent-text)) 32%, transparent);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--hc-tone, var(--accent-text));
}

/* ==========================================================================
   Group headers + section grid — each group carries a subtle coloured wash
   More generous spacing between groups for breathing room.
   ========================================================================== */
.group {
  position: relative;
  padding: var(--s-4) var(--s-5) var(--s-5);
  margin: 0 calc(var(--s-5) * -1) var(--s-5);
  border-radius: var(--r-lg);
  scroll-margin-top: 132px; /* clear the topbar + sticky index-jumpnav when scrolled to */
}
.group::before {
  content: "";
  position: absolute;
  inset: -40px; /* extend beyond group so mask can feather well outside */
  background:
    radial-gradient(ellipse 50% 60% at 20% 30%, var(--group-glow, transparent) 0%, transparent 100%),
    radial-gradient(ellipse 45% 55% at 80% 70%, var(--group-glow-2, transparent) 0%, transparent 100%);
  /* Radial mask fades the entire pseudo out at the edges — no rectangle visible */
  -webkit-mask-image: radial-gradient(ellipse 75% 75% at center, black 10%, transparent 95%);
          mask-image: radial-gradient(ellipse 75% 75% at center, black 10%, transparent 95%);
  filter: blur(16px);
  pointer-events: none;
  z-index: -1;
}
.group[data-group="foundation"]{ --group-glow: rgba(129,140,248,0.07); --group-glow-2: rgba(129,140,248,0.04); }
.group[data-group="business"]  { --group-glow: rgba(59,154,252,0.07);  --group-glow-2: rgba(59,154,252,0.04); }
.group[data-group="growth"]    { --group-glow: rgba(74,222,128,0.06);  --group-glow-2: rgba(74,222,128,0.03); }
.group[data-group="brand"]     { --group-glow: rgba(167,139,250,0.07); --group-glow-2: rgba(167,139,250,0.04); }
.group[data-group="retention"] { --group-glow: rgba(251,146,60,0.06);  --group-glow-2: rgba(251,146,60,0.03); }
.group[data-group="scale"]     { --group-glow: rgba(244,114,182,0.06); --group-glow-2: rgba(244,114,182,0.03); }
.group[data-group="numbers"]   { --group-glow: rgba(34,211,238,0.06);  --group-glow-2: rgba(34,211,238,0.03); }
.group[data-group="exit"]      { --group-glow: rgba(252,211,77,0.07);  --group-glow-2: rgba(252,211,77,0.04); }
.group-head {
  display: flex;
  align-items: baseline;
  gap: var(--s-4);
  padding-bottom: var(--s-3);
  margin-bottom: var(--s-4);
  border-bottom: 1px solid var(--border);
}
.group-head-num {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--group-accent, var(--accent-text));
  letter-spacing: 0.16em;
  text-transform: uppercase;
  min-width: 36px;
}
/* Map group accent to head num */
.group[data-group="foundation"] .group-head-num { color: var(--g-foundation); }
.group[data-group="business"]   .group-head-num { color: var(--g-business); }
.group[data-group="growth"]     .group-head-num { color: var(--g-growth); }
.group[data-group="brand"]      .group-head-num { color: var(--g-brand); }
.group[data-group="retention"]  .group-head-num { color: var(--g-retention); }
.group[data-group="scale"]      .group-head-num { color: var(--g-scale); }
.group[data-group="numbers"]    .group-head-num { color: var(--g-numbers); }
.group[data-group="exit"]       .group-head-num { color: var(--g-exit); }

.group-head-title {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text);
}
.group-head-sub {
  font-size: 13px;
  color: var(--text-dim);
  margin-left: auto;
}

.section-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-3);
}
.section-grid--single {
  grid-template-columns: 1fr;
  max-width: 560px;
}
/* MS 2.0 Index card (redesigned): three-row stacked layout instead of the
   old single-row flex. Top: icon + section-num + HC pill. Middle: title
   + subtitle. Bottom: meta footer (read state · checklist · arrow).
   Brings the .bsr discipline from the dashboard to the index. */
/* Section cards — glow-surface pattern (matches callouts / founders-note /
   waterfall / formula family). Per-group accent colour via --accent-color
   (set on the `data-group` attribute below) drives a dual radial-gradient
   glow. Dropped the 3px left stripe holdover; the rest-state glow carries
   the category identity. Hover intensifies + lifts slightly.
   Used by: landing-public.html SEO catalog + the category hub grids.
   (The SPA Index + /contents/ moved to the .section-row LIST, 2026-07.)
   Gate.html keeps the old flat+stripe styling via the
   `#gate-seo-content` override block below (remove when gate goes away). */
.section-card {
  --cw-tone: var(--accent-color, var(--accent));
  display: flex;
  flex-direction: column;
  padding: var(--s-4) var(--s-5);
  background:
    radial-gradient(ellipse 80% 70% at top right,
      color-mix(in srgb, var(--cw-tone) 13%, transparent) 0%,
      transparent 60%),
    radial-gradient(ellipse 60% 100% at bottom left,
      color-mix(in srgb, var(--cw-tone) 5%, transparent) 0%,
      transparent 55%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.25s;
  position: relative;
  cursor: pointer;
  min-height: 132px;
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 1px 2px rgba(0,0,0,0.2);
}
.section-card:hover {
  border-color: color-mix(in srgb, var(--cw-tone) 40%, var(--border));
  transform: translateY(-2px);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 10px 24px -8px rgba(0,0,0,0.35),
    0 0 32px -6px color-mix(in srgb, var(--cw-tone) 30%, transparent);
}
.section-card:hover .section-card-arrow { color: var(--cw-tone); transform: translateX(2px); }

/* Legacy override: restore flat surface + 3px left accent stripe for the
   pre-launch gate page only. Remove this block when templates/gate.html
   is deleted at launch. */
#gate-seo-content .section-card {
  --cw-tone: var(--accent-color, var(--accent));
  background: var(--surface);
}
#gate-seo-content .section-card:hover {
  background: var(--surface-2);
  border-color: var(--border-hi);
  transform: translateY(-1px);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 6px 16px rgba(0,0,0,0.3),
    0 0 24px -8px var(--blue-glow-soft);
}
#gate-seo-content .section-card::before {
  content: "";
  position: absolute;
  left: 0; top: 12%; bottom: 12%;
  width: 3px;
  background: var(--accent-color, var(--accent));
  border-radius: 0 3px 3px 0;
  opacity: 0.55;
  transition: opacity 0.15s, top 0.15s, bottom 0.15s;
}
#gate-seo-content .section-card:hover::before { opacity: 1; top: 8%; bottom: 8%; }

/* --- Card head row: icon + section number + HC score pill --- */
.section-card-head {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  margin-bottom: var(--s-3);
}
/* Naked icon — no container box. The card is the only box. */
.section-icon {
  width: 24px; height: 24px;
  flex-shrink: 0;
  display: grid; place-items: center;
}
.section-icon img {
  width: 22px; height: 22px;
  filter: brightness(0) saturate(100%) invert(50%) sepia(90%) saturate(2400%) hue-rotate(190deg);
  transition: filter 0.2s;
}
/* HC score pill — pinned right. Hydrated by updateTocCardColours()
   which writes the inner span. Empty = no submission yet (collapses). */
.section-hc-slot {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
}
.section-hc-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  background: color-mix(in srgb, var(--hc-tone, var(--text-dim)) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--hc-tone, var(--text-dim)) 36%, transparent);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--hc-tone, var(--text-dim));
  text-align: center;
}
.section-hc-pill.is-na {
  background: transparent;
  border: 1px dashed var(--border);
  color: var(--text-dim);
  font-weight: 500;
}
.section-card[data-group="foundation"] { --accent-color: var(--g-foundation); }
.section-card[data-group="foundation"] .section-icon img,
.section-row[data-group="foundation"] .section-icon img,
.brand-group[data-group="foundation"] .section-icon img,
.bsr[data-group="foundation"] .section-icon img {
  /* #818CF8 indigo — strategic/intellectual */
  filter: brightness(0) saturate(100%) invert(63%) sepia(32%) saturate(1800%) hue-rotate(215deg);
}
.section-card[data-group="business"] { --accent-color: var(--g-business); }
.section-card[data-group="business"] .section-icon img,
.section-row[data-group="business"] .section-icon img,
.brand-group[data-group="business"] .section-icon img,
.bsr[data-group="business"] .section-icon img {
  filter: brightness(0) saturate(100%) invert(55%) sepia(88%) saturate(2400%) hue-rotate(190deg);
}
.section-card[data-group="growth"] { --accent-color: var(--g-growth); }
.section-card[data-group="growth"] .section-icon img,
.section-row[data-group="growth"] .section-icon img,
.brand-group[data-group="growth"] .section-icon img,
.bsr[data-group="growth"] .section-icon img {
  filter: brightness(0) saturate(100%) invert(78%) sepia(46%) saturate(550%) hue-rotate(120deg);
}
.section-card[data-group="brand"] { --accent-color: var(--g-brand); }
.section-card[data-group="brand"] .section-icon img,
.section-row[data-group="brand"] .section-icon img,
.brand-group[data-group="brand"] .section-icon img,
.bsr[data-group="brand"] .section-icon img {
  filter: brightness(0) saturate(100%) invert(68%) sepia(32%) saturate(1500%) hue-rotate(240deg);
}
.section-card[data-group="retention"] { --accent-color: var(--g-retention); }
.section-card[data-group="retention"] .section-icon img,
.section-row[data-group="retention"] .section-icon img,
.brand-group[data-group="retention"] .section-icon img,
.bsr[data-group="retention"] .section-icon img {
  filter: brightness(0) saturate(100%) invert(72%) sepia(48%) saturate(1600%) hue-rotate(340deg);
}
.section-card[data-group="scale"] { --accent-color: var(--g-scale); }
.section-card[data-group="scale"] .section-icon img,
.section-row[data-group="scale"] .section-icon img,
.brand-group[data-group="scale"] .section-icon img,
.bsr[data-group="scale"] .section-icon img {
  filter: brightness(0) saturate(100%) invert(64%) sepia(26%) saturate(2400%) hue-rotate(300deg);
}
.section-card[data-group="numbers"] { --accent-color: var(--g-numbers); }
.section-card[data-group="numbers"] .section-icon img,
.section-row[data-group="numbers"] .section-icon img,
.brand-group[data-group="numbers"] .section-icon img,
.bsr[data-group="numbers"] .section-icon img {
  filter: brightness(0) saturate(100%) invert(76%) sepia(32%) saturate(600%) hue-rotate(100deg);
}
.section-card[data-group="exit"] { --accent-color: var(--g-exit); }
.section-card[data-group="exit"] .section-icon img,
.section-row[data-group="exit"] .section-icon img,
.brand-group[data-group="exit"] .section-icon img,
.bsr[data-group="exit"] .section-icon img {
  filter: brightness(0) saturate(100%) invert(78%) sepia(48%) saturate(900%) hue-rotate(360deg);
}

/* ============================================================
   Section list (row layout) — the public /contents/ page + the
   signed-in Index (#view-index). Opt-in via `.group--list` on the
   .group wrapper; each section renders as a full-width row instead
   of a grid card. Shares the group wrapper + per-group icon tints
   with the card grid (grids elsewhere are untouched). The signed-in
   variant reuses the card hydration hooks (.section-hc-slot,
   [data-section-state], .section-state-read, .section-checklist-mini*)
   so script.js paints HC pills + progress with no bespoke logic.
   ============================================================ */
.section-rows { display: flex; flex-direction: column; }
.section-row {
  display: grid;
  grid-template-columns: 50px 1fr auto;
  align-items: center;
  gap: var(--s-4);
  padding: 12px 14px 12px 8px;
  border-radius: var(--r-md);
  border: 1px solid transparent;
  text-decoration: none;
  color: inherit;
  position: relative;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.section-row + .section-row { border-top: 1px solid var(--border); }
.section-row:hover { background: var(--surface); border-color: var(--border); }
/* accent tick on hover */
.section-row::before {
  content: ""; position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 3px; height: 0; border-radius: 2px;
  background: var(--row-accent, var(--accent)); transition: height 0.15s;
}
.section-row:hover::before { height: 58%; }
.section-row-lead { display: flex; flex-direction: column; align-items: center; gap: 5px; }
.section-row-num {
  font-family: var(--font-mono); font-size: 10px; font-weight: 600;
  color: var(--row-accent, var(--text-dim)); letter-spacing: 0.06em;
}
.section-row-body { min-width: 0; }
.section-row-title {
  display: block; font-size: 15px; font-weight: 600; letter-spacing: -0.01em;
  color: var(--text); line-height: 1.3;
}
.section-row-sub {
  display: block; font-size: 13px; color: var(--text-dim); line-height: 1.35; margin-top: 3px;
}
.section-row-right { display: flex; align-items: center; gap: var(--s-4); justify-self: end; }
.section-row:hover .section-card-arrow { color: var(--row-accent, var(--accent)); transform: translateX(2px); }
/* public "read free" affordance */
.section-row-readfree {
  font-family: var(--font-mono); font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--text-dim); white-space: nowrap;
}
.section-row:hover .section-row-readfree { color: var(--row-accent, var(--accent-text)); }
/* signed-in state rail (reuses .section-state-read / .section-checklist-mini / .section-hc-*) */
.section-row-state {
  display: flex; align-items: center; gap: var(--s-3);
  font-family: var(--font-mono); font-size: 10px; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-dim);
}
.section-row-state .section-checklist-mini { flex: 0 0 auto; }
.section-row-state .section-checklist-mini-track { flex: 0 0 72px; width: 72px; }
.section-row-state .section-checklist-mini-fill { background: var(--row-accent, var(--accent)); }
.section-row-state .section-card-arrow { margin-left: 2px; }
.section-row .section-hc-slot { margin-left: 0; }
/* per-group accent for rows (num · hover tick · arrow · progress fill) */
.section-row[data-group="foundation"] { --row-accent: var(--g-foundation); }
.section-row[data-group="business"]   { --row-accent: var(--g-business); }
.section-row[data-group="growth"]     { --row-accent: var(--g-growth); }
.section-row[data-group="brand"]      { --row-accent: var(--g-brand); }
.section-row[data-group="retention"]  { --row-accent: var(--g-retention); }
.section-row[data-group="scale"]      { --row-accent: var(--g-scale); }
.section-row[data-group="numbers"]    { --row-accent: var(--g-numbers); }
.section-row[data-group="exit"]       { --row-accent: var(--g-exit); }
/* jump-nav landings clear the sticky topbar (~62px) + jump-nav (~50px) */
.group--list { scroll-margin-top: 116px; }
/* group descriptor moves left; section count sits right (list mode only) */
.group--list .group-head-sub { margin-left: 0; }
.group--list .group-head-sub::before { content: "·"; margin-right: 8px; color: var(--n-7); }
.group--list .group-head-count {
  margin-left: auto; font-family: var(--font-mono); font-size: 11px;
  color: var(--n-9); letter-spacing: 0.04em; text-transform: uppercase; white-space: nowrap;
}
/* mobile: drop the checklist bar + count, tighten the lead column */
@media (max-width: 600px) {
  .section-row { grid-template-columns: 44px 1fr auto; gap: var(--s-3); }
  .section-row-state .section-checklist-mini { display: none; }
  .group--list .group-head-count { display: none; }
}

.section-card-body {
  min-width: 0;
  flex: 1;
  margin-bottom: var(--s-3);
}
.section-num {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.16em;
}
.section-title {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--text);
  line-height: 1.25;
  margin-bottom: 4px;
  /* Allow wrapping — was nowrap+ellipsis, which clipped longer titles
     like "Brand DNA - Values, Pillars & Positioning". */
}
.section-sub {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.4;
}

/* --- Card meta footer: read state + checklist + arrow --- */
.section-card-meta {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  margin-top: auto;
  padding-top: var(--s-3);
  border-top: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-dim);
  min-height: 28px;
}
.section-state-read {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.section-state-read::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--text-dim);
  flex-shrink: 0;
}
.section-state-read.is-read {
  color: #4ADE80;
}
.section-state-read.is-read::before {
  background: #4ADE80;
  box-shadow: 0 0 0 3px rgba(74, 222, 128, 0.18);
}
.section-checklist-mini {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}
.section-checklist-mini-track {
  display: block;
  flex: 1;
  height: 4px;
  background: var(--border);
  border-radius: 999px;
  overflow: hidden;
  min-width: 30px;
}
.section-checklist-mini-fill {
  /* display:block is load-bearing: hydrateIndexProgress emits this as a
     <span> with an inline width:N% — a non-replaced inline element ignores
     width/height entirely, so without this the fill computes 0x0 and the
     progress bar renders permanently empty (the track is safe only because
     being a flex item blockifies it). */
  display: block;
  height: 100%;
  background: var(--accent);
  border-radius: 999px;
  transition: width 0.3s;
}
.section-checklist-mini-count {
  font-variant-numeric: tabular-nums;
  color: var(--text-dim);
  flex-shrink: 0;
}
.section-card-arrow {
  margin-left: auto;
  color: var(--text-ghost);
  font-size: 16px;
  font-family: var(--font-sans);
  font-weight: 400;
  letter-spacing: normal;
  text-transform: none;
  transition: color 0.15s, transform 0.15s;
  flex-shrink: 0;
  line-height: 1;
}

/* ==========================================================================
   Section page
   ========================================================================== */
.section-head {
  padding: var(--s-9) 0 var(--s-6);
}
/* Mobile: 96px top padding feels like dead space below the topbar.
   Tighten to 24px so content starts visible above the fold. */
@media (max-width: 768px) {
  .section-head {
    padding: var(--s-5) 0 var(--s-4);
  }
}
.breadcrumb {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-dim);
  margin-bottom: var(--s-5);
}
.breadcrumb a { color: var(--text-dim); transition: color 0.15s; }
.breadcrumb a:hover { color: var(--accent-text); }
.breadcrumb .sep { color: var(--text-ghost); }

.section-meta {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: var(--s-4);
}
.section-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  padding: 6px 12px;
  border: 1px solid var(--border-hi);
  border-radius: 6px;
  background: var(--surface);
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  display: inline-flex; align-items: center; gap: 8px;
}
.section-badge .dot {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--badge-color, var(--accent));
  box-shadow: 0 0 8px var(--badge-color, var(--accent));
}
/* Tint the section-badge dot + text to the group accent so the section
   chrome reads as part of its category. Matches the index card chips. */
.section-badge[data-group="foundation"] { --badge-color: var(--g-foundation); color: var(--g-foundation); }
.section-badge[data-group="business"]   { --badge-color: var(--g-business);   color: var(--g-business); }
.section-badge[data-group="growth"]     { --badge-color: var(--g-growth);     color: var(--g-growth); }
.section-badge[data-group="brand"]      { --badge-color: var(--g-brand);      color: var(--g-brand); }
.section-badge[data-group="retention"]  { --badge-color: var(--g-retention);  color: var(--g-retention); }
.section-badge[data-group="scale"]      { --badge-color: var(--g-scale);      color: var(--g-scale); }
.section-badge[data-group="numbers"]    { --badge-color: var(--g-numbers);    color: var(--g-numbers); }
.section-badge[data-group="exit"]       { --badge-color: var(--g-exit);       color: var(--g-exit); }

/* Section icon — inline with the H1 (was a stacked 44px emblem).
   Uses inline-block (NOT flex) so the icon flows with the title text —
   when long titles wrap to multiple lines, the icon stays on the first
   line next to the first word rather than being pushed to its own row
   by flex-wrap. Sizing keys off 1em so the icon scales with the H1 at
   any viewport (desktop 52px → icon ~50px; mobile 34px → icon ~34px). */
.section-head-icon-inline {
  display: inline-block;
  vertical-align: baseline;
  width: 0.9em;
  height: 0.9em;
  margin-right: 0.3em;
  /* Nudge the icon down a hair so it optically aligns with the text
     baseline (the icon's visual weight sits above the text cap height). */
  transform: translateY(0.1em);
  /* Default to accent blue; per-group filters below override. */
  filter: brightness(0) saturate(100%) invert(50%) sepia(90%) saturate(2400%) hue-rotate(190deg);
}
.section-head[data-group="foundation"] .section-head-icon-inline {
  filter: brightness(0) saturate(100%) invert(63%) sepia(32%) saturate(1800%) hue-rotate(215deg);
}
.section-head[data-group="business"] .section-head-icon-inline {
  filter: brightness(0) saturate(100%) invert(55%) sepia(88%) saturate(2400%) hue-rotate(190deg);
}
.section-head[data-group="growth"] .section-head-icon-inline {
  filter: brightness(0) saturate(100%) invert(78%) sepia(46%) saturate(550%) hue-rotate(120deg);
}
.section-head[data-group="brand"] .section-head-icon-inline {
  filter: brightness(0) saturate(100%) invert(68%) sepia(32%) saturate(1500%) hue-rotate(240deg);
}
.section-head[data-group="retention"] .section-head-icon-inline {
  filter: brightness(0) saturate(100%) invert(72%) sepia(48%) saturate(1600%) hue-rotate(340deg);
}
.section-head[data-group="scale"] .section-head-icon-inline {
  filter: brightness(0) saturate(100%) invert(64%) sepia(26%) saturate(2400%) hue-rotate(300deg);
}
.section-head[data-group="numbers"] .section-head-icon-inline {
  filter: brightness(0) saturate(100%) invert(76%) sepia(32%) saturate(600%) hue-rotate(100deg);
}
.section-head[data-group="exit"] .section-head-icon-inline {
  filter: brightness(0) saturate(100%) invert(78%) sepia(48%) saturate(900%) hue-rotate(360deg);
}

.section-head h1 {
  font-size: clamp(34px, 4.5vw, 52px);
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: var(--s-4);
  max-width: 820px;
}
.section-head .subtitle {
  font-size: 17px;
  color: var(--text-muted);
  max-width: 680px;
  margin-bottom: var(--s-6);
  line-height: 1.55;
}
.section-info {
  display: flex; gap: var(--s-5);
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  padding-top: var(--s-4);
  border-top: 1px solid var(--border);
}
.section-info span { display: flex; align-items: center; gap: 6px; }
.section-info .sep { color: var(--text-ghost); }

/* Layout: body + slim aside */
.section-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: var(--s-8);
  padding-bottom: var(--s-10);
}
@media (max-width: 960px) {
  /* `1fr` = `minmax(auto, 1fr)` = expands to fit min-content of children.
     The body column is full of blocks (.principle, .metric-grid, .pullquote,
     .founders-note, <pre>) whose intrinsic min-content widths can be 700px+.
     `minmax(0, 1fr)` lets the column shrink below content min-content, so
     blocks wrap/scroll inside the column instead of overflowing the page. */
  .section-layout { grid-template-columns: minmax(0, 1fr); }
  .section-aside { display: none; }
}

/* Body content */
.section-body-content { max-width: 720px; min-width: 0; }
/* Code blocks must clip + scroll inside the column, not push it wider. */
.section-body-content pre {
  max-width: 100%;
  overflow-x: auto;
  white-space: pre;
}
/* Tables: same — wrap in horizontal scroll if too wide for the column. */
.section-body-content .table-wrapper {
  max-width: 100%;
  overflow-x: auto;
}
.section-body-content > p {
  font-size: 16px;
  line-height: 1.75;
  color: var(--text-muted);
  margin-bottom: var(--s-4);
}
.section-body-content h2 {
  margin-top: var(--s-8);
  margin-bottom: var(--s-4);
  padding-top: var(--s-6);
  border-top: 1px solid var(--border);
  font-size: 26px;
  position: relative;
}
.section-body-content h2::before {
  content: attr(data-num);
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: 10px;
}
.section-body-content h3 {
  margin-top: var(--s-6);
  margin-bottom: var(--s-3);
  font-size: 19px;
}
.section-body-content strong { color: var(--text); font-weight: 600; }
.section-body-content ul, .section-body-content ol {
  margin: 0 0 var(--s-4);
  padding-left: 20px;
}
.section-body-content ul li, .section-body-content ol li {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-muted);
  margin-bottom: 8px;
}

/* =========================================================================
   BLOCK TYPES — the full library
   ========================================================================= */

/* Principle — ONE per section. Signature moment with Rob's attribution.
   Padding matches .callout (var(--s-5)) so it doesn't over-dominate as a
   page-opener. Margin relaxed to var(--s-5)/var(--s-6) for the same reason. */
.principle {
  margin: var(--s-5) 0 var(--s-6);
  padding: var(--s-5);
  background:
    radial-gradient(ellipse 80% 60% at top right,
      color-mix(in srgb, var(--principle-glow, var(--accent)) 22%, transparent) 0%,
      transparent 60%),
    radial-gradient(ellipse 60% 100% at bottom left,
      color-mix(in srgb, var(--principle-glow, var(--accent)) 10%, transparent) 0%,
      transparent 55%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  position: relative;
  overflow: hidden;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 20px 48px -16px rgba(0,0,0,0.4),
    0 0 0 1px color-mix(in srgb, var(--principle-glow, var(--accent)) 12%, transparent);
}
/* Principle glow colour per group — inherited from the .chapter data-group
   attribute. Replaces the old blue left stripe; the coloured glow carries
   the section's group identity across the whole card. */
.chapter[data-group="foundation"] .principle { --principle-glow: var(--g-foundation); }
.chapter[data-group="business"]   .principle { --principle-glow: var(--g-business); }
.chapter[data-group="growth"]     .principle { --principle-glow: var(--g-growth); }
.chapter[data-group="brand"]      .principle { --principle-glow: var(--g-brand); }
.chapter[data-group="retention"]  .principle { --principle-glow: var(--g-retention); }
.chapter[data-group="scale"]      .principle { --principle-glow: var(--g-scale); }
.chapter[data-group="numbers"]    .principle { --principle-glow: var(--g-numbers); }
.chapter[data-group="exit"]       .principle { --principle-glow: var(--g-exit); }
/* Kicker picks up the same group tone so the PRINCIPLE label reads as
   group-coloured too (was hardcoded to --accent-text blue). */
.chapter[data-group] .principle-kicker { color: var(--principle-glow, var(--accent-text)); }
/* Simplified kicker — replaces the old attribution row (avatar + "Rob Ward"
   + "FOUNDER'S PRINCIPLE" kicker). The block's blue gradient + left stripe
   already marks it as a principle; we just need a tiny text kicker. */
.principle-kicker {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-weight: 600;
  margin-bottom: var(--s-3);
}
.principle-title {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.2;
  margin-bottom: var(--s-4);
  color: var(--text);
  max-width: 640px;
}
.principle-body {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-muted);
  max-width: 680px;
}

/* Callouts — tip / warning / insight / info / ai / read.
   Glow-tinted surface by variant, sharing the same surface language as
   the founder's principle + founders-note. Drops the solid left-rule
   accent bar; variant signal comes from icon + label + glow tone.
   --cw-tone is the per-variant colour; the .callout base consumes it
   in the dual radial-gradient background. */
.callout {
  --cw-tone: var(--accent);
  margin: var(--s-5) 0;
  padding: var(--s-5);
  background:
    radial-gradient(ellipse 80% 70% at top right,
      color-mix(in srgb, var(--cw-tone) 18%, transparent) 0%,
      transparent 60%),
    radial-gradient(ellipse 60% 100% at bottom left,
      color-mix(in srgb, var(--cw-tone) 7%, transparent) 0%,
      transparent 55%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  position: relative;
  overflow: hidden;
}
/* Variant tones — one distinct colour per variant. Same mapping as
   pre-glow ("tip/ai split", warning amber, insight violet, etc.) so
   nothing changes semantically for authors. */
.callout-tip     { --cw-tone: var(--ok); }
.callout-warning { --cw-tone: var(--warn); }
.callout-insight { --cw-tone: var(--g-brand); }
.callout-info    { --cw-tone: var(--accent); }
.callout-ai      { --cw-tone: var(--g-numbers); }
.callout-read    { --cw-tone: var(--g-exit); }
.callout-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  margin-bottom: 10px;
  display: flex; align-items: center; gap: 10px;
}
/* Callout icons — naked, no chip. Status colour only. */
.callout-icon {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}
.callout-icon svg { width: 16px; height: 16px; stroke-width: 1.8; }
.callout-tip .callout-label,
.callout-tip .callout-icon { color: var(--ok); }
.callout-warning .callout-label,
.callout-warning .callout-icon { color: var(--warn); }
.callout-insight .callout-label,
.callout-insight .callout-icon { color: var(--g-brand); }
.callout-info .callout-label,
.callout-info .callout-icon { color: var(--accent-text); }
.callout-ai .callout-label,
.callout-ai .callout-icon { color: var(--g-numbers); }
.callout-read .callout-label,
.callout-read .callout-icon { color: var(--g-exit); }
/* Verdict modifier — colours a callout by the threshold band it lands in
   (worked examples). Authored as `::::callout-info green|amber|red`.
   Left border echoes .threshold-row so the verdict reads at a glance. */
.callout--verdict-green,
.callout--verdict-amber,
.callout--verdict-red { border-left: 3px solid var(--cw-tone); }
.callout--verdict-green { --cw-tone: var(--ok); }
.callout--verdict-amber { --cw-tone: var(--warn); }
.callout--verdict-red   { --cw-tone: var(--err); }
.callout--verdict-green .callout-label,
.callout--verdict-green .callout-icon { color: var(--ok); }
.callout--verdict-amber .callout-label,
.callout--verdict-amber .callout-icon { color: var(--warn); }
.callout--verdict-red .callout-label,
.callout--verdict-red .callout-icon { color: var(--err); }
.callout-title {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text);
  letter-spacing: -0.01em;
}
.callout p { font-size: 14px; line-height: 1.65; margin-bottom: 10px; }
.callout p:last-child { margin-bottom: 0; }

/* Pullquote — flat on the page, Georgia italic, centred. Typography
   spec borrowed from robyward.com .about__pullquote so the playbook's
   pullquotes read in Rob's own voice. Curly talking marks wrap the
   text, key phrase in accent blue via *em* or **strong**, 80% width
   centred in the column. No surface, no border. */
.pullquote {
  margin: var(--s-7) auto;
  padding: 0;
  max-width: 80%;
  text-align: center;
}
.pullquote-text {
  font-family: Georgia, 'Times New Roman', serif;
  font-style: italic;
  font-size: clamp(1.3rem, 3vw, 1.6rem);
  line-height: 1.6;
  color: var(--text);
  font-weight: 400;
}
.pullquote-text::before { content: "\201C"; } /* opening curly double-quote */
.pullquote-text::after  { content: "\201D"; } /* closing curly double-quote */
/* Emphasis — accent blue, weight 600. Both <em> and <strong> map so
   authors can use either *phrase* or **phrase** in markdown. */
.pullquote-text em,
.pullquote-text strong {
  font-style: italic;
  font-weight: 600;
  color: var(--accent-text);
}
.pullquote-attribution {
  margin-top: var(--s-3);
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-style: normal;
}

/* Founder's Note — same glow pattern as the callouts, accent-blue
   tone so it reads as Rob's voice while sitting in the same surface
   family. Drops the left accent bar. */
.founders-note {
  --cw-tone: var(--accent);
  margin: var(--s-6) 0;
  padding: var(--s-5);
  background:
    radial-gradient(ellipse 80% 70% at top right,
      color-mix(in srgb, var(--cw-tone) 16%, transparent) 0%,
      transparent 60%),
    radial-gradient(ellipse 60% 100% at bottom left,
      color-mix(in srgb, var(--cw-tone) 6%, transparent) 0%,
      transparent 55%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  position: relative;
  overflow: hidden;
}
.founders-note-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  margin-bottom: var(--s-3);
  display: inline-flex; align-items: center; gap: 8px;
}
/* Cap silhouette sitting in the label row — sized relative to the label's
   text so it scales with the mono type. */
.founders-note-cap {
  width: 22px;
  height: auto;
  flex-shrink: 0;
  color: var(--accent-text);
}
.founders-note p { font-size: 15px; line-height: 1.7; color: var(--text-muted); }
.founders-note p:last-child { margin-bottom: 0; }

/* Compare (good vs bad) */
.compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-3);
  margin: var(--s-5) 0;
}
/* Three-up variant — activated by `::::compare three-col` in the markdown
   (build.py parser emits .compare--3col on the wrapper). Was missing the
   CSS rule, so 3-card compares (e.g. S21) rendered 2+1 with an orphaned
   third card on row 2. */
.compare.compare--3col {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
@media (max-width: 720px) {
  .compare,
  .compare.compare--3col { grid-template-columns: 1fr; }
}
.compare-card {
  --cw-tone: var(--accent);
  padding: var(--s-5);
  background:
    radial-gradient(ellipse 80% 70% at top right,
      color-mix(in srgb, var(--cw-tone) 18%, transparent) 0%,
      transparent 60%),
    radial-gradient(ellipse 60% 100% at bottom left,
      color-mix(in srgb, var(--cw-tone) 7%, transparent) 0%,
      transparent 55%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  position: relative;
  overflow: hidden;
  box-shadow: 0 1px 0 rgba(255,255,255,0.04) inset;
}
.compare-card--bad     { --cw-tone: var(--err); }
.compare-card--good    { --cw-tone: var(--ok); }
.compare-card--warning { --cw-tone: var(--warn); }
.compare-card--neutral { --cw-tone: var(--text-dim); }
.compare-card-label {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  margin-bottom: var(--s-4);
  display: flex;
  align-items: center;
  gap: 10px;
}
/* Compare icons — naked, no chip. Matches callout icon treatment. */
.compare-icon {
  display: inline-flex; align-items: center;
  flex-shrink: 0;
}
.compare-icon svg { width: 16px; height: 16px; stroke-width: 2.2; }
.compare-card--bad     .compare-icon { color: var(--err); }
.compare-card--good    .compare-icon { color: var(--ok); }
.compare-card--warning .compare-icon { color: var(--warn); }
.compare-card--neutral .compare-icon { color: var(--text-dim); }
.compare-card--bad     .compare-card-label { color: var(--err); }
.compare-card--good    .compare-card-label { color: var(--ok); }
.compare-card--warning .compare-card-label { color: var(--warn); }
.compare-card--neutral .compare-card-label { color: var(--text-dim); }
.compare-card ul { margin: 0 0 var(--s-3); padding: 0; list-style: none; }
.compare-card li {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-muted);
  padding-left: 16px;
  position: relative;
  margin-bottom: 6px;
}
.compare-card li::before {
  content: "";
  position: absolute;
  left: 0; top: 9px;
  width: 6px; height: 1px;
  background: var(--text-ghost);
}
.compare-card li strong { color: var(--text); font-weight: 600; }
.compare-card-footer {
  padding-top: var(--s-3);
  border-top: 1px solid var(--border);
  font-size: 12px;
  color: var(--text);
  font-weight: 500;
}
@media (max-width: 720px) { .compare { grid-template-columns: 1fr; } }

/* Metric (single key stat) — flat */
.metric {
  margin: var(--s-5) 0;
  padding: var(--s-5) var(--s-6);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  display: grid;
  /* Cap the value column at ~38% so multi-word values like "25-40% of
     total revenue" can't eat the description column and leave it as a
     single-word-per-line ladder. Short values like "$200M" still look
     fine — they just don't fill the whole column. */
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  gap: var(--s-5);
  align-items: center;
}
.metric-value {
  font-family: var(--font-mono);
  font-size: clamp(32px, 4.4vw, 48px);
  font-weight: 600;
  line-height: 1.1;
  color: var(--accent-text);
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  min-width: 0;
  word-break: keep-all;
  overflow-wrap: break-word;
}
/* Title-style metric (multi-word concept instead of a number) — uses bold
   sans at a smaller size so the value column doesn't word-break mid-word.
   Auto-detected at build time when the value starts with a letter and
   contains spaces (e.g. "The Efficiency Equation" in S01). Numeric values
   ("$200M", "25-40% of total revenue") keep the big mono treatment. */
.metric--title .metric-value {
  font-family: var(--font-sans);
  font-size: clamp(22px, 2.6vw, 30px);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--text);
  font-variant-numeric: normal;
  word-break: normal;
}
@media (max-width: 720px) {
  .metric { grid-template-columns: 1fr; gap: var(--s-3); }
}
.metric-label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  line-height: 1.5;
}
.metric-label-title {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-weight: 500;
}
.metric-label-desc {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.55;
}

/* Metric Grid (2-4 related stats) */
.metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--s-3);
  margin: var(--s-5) 0;
}
.metric-grid .metric-cell {
  padding: var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  text-align: left;
}
.metric-cell-label {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: var(--s-3);
}
.metric-cell-value {
  font-family: var(--font-mono);
  font-size: 32px;
  font-weight: 600;
  line-height: 1;
  color: var(--text);
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  margin-bottom: 6px;
}
.metric-cell-hint { font-size: 12px; color: var(--text-dim); }
.metric-cell--ok .metric-cell-value { color: var(--ok); }
.metric-cell--warn .metric-cell-value { color: var(--warn); }
.metric-cell--err .metric-cell-value { color: var(--err); }
.metric-cell--accent .metric-cell-value { color: var(--accent-text); }

/* Metric stacked — used when a metric-grid line has the shape
   `value | long-prose-description` (auto-detected at build time).
   Group of related benchmarks in ONE unified surface (not three
   duplicate cards). Fixed value column so mixed-length values
   (`60-80%`, `3:1+`, `< 6 months`) share a gutter. Glow-tinted
   background puts it in the same family as callouts / waterfall. */
.metric-stack {
  margin: var(--s-5) 0;
  padding: var(--s-3) var(--s-6);
  background:
    radial-gradient(ellipse 80% 70% at top right,
      color-mix(in srgb, var(--accent) 12%, transparent) 0%,
      transparent 60%),
    radial-gradient(ellipse 60% 100% at bottom left,
      color-mix(in srgb, var(--accent) 5%, transparent) 0%,
      transparent 55%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  position: relative;
  overflow: hidden;
}
.metric-stacked {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: var(--s-5);
  align-items: center;
  padding: var(--s-4) 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}
.metric-stacked + .metric-stacked {
  border-top: 1px solid var(--border);
}
.metric-stacked-value {
  font-family: var(--font-mono);
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 600;
  line-height: 1.1;
  color: var(--accent-text);
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
.metric-stacked-desc {
  font-family: var(--font-sans);
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
}
.metric-stacked--ok    .metric-stacked-value { color: var(--ok); }
.metric-stacked--warn  .metric-stacked-value { color: var(--warn); }
.metric-stacked--err   .metric-stacked-value { color: var(--err); }
.metric-stacked--accent .metric-stacked-value { color: var(--accent-text); }
@media (max-width: 540px) {
  .metric-stacked {
    grid-template-columns: 1fr;
    gap: var(--s-2);
    padding: var(--s-3) 0;
  }
  .metric-stacked-value { font-size: 26px; }
}

/* Statement mode — single-field entries (no pipes, just a claim).
   Renders as a compact card with readable sans text + a blue accent
   stripe on the left, like a mini-callout. Replaces the old behaviour
   where single-field lines went into the .metric-cell-value slot and
   rendered as a 32px mono display — comically oversized for things
   like "CCC under 60 days". */
.metric-statement-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--s-3);
  margin: var(--s-5) 0;
}
.metric-statement {
  padding: var(--s-4) var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--r-md);
  font-family: var(--font-sans);
  font-size: 14.5px;
  color: var(--text);
  line-height: 1.5;
  box-shadow: 0 1px 0 rgba(255,255,255,0.04) inset;
}
.metric-statement strong { color: var(--text); font-weight: 700; }

/* Horizontal Steps (3-4 parallel items, circles + connecting track) */
.hsteps {
  display: flex;
  align-items: flex-start;
  gap: 0;
  margin: var(--s-6) 0;
  padding: var(--s-5) 0;
  position: relative;
}
/* Connecting gradient track behind the circles */
.hsteps::before {
  content: "";
  position: absolute;
  top: calc(var(--s-5) + 28px);
  left: 12%;
  right: 12%;
  height: 2px;
  background: linear-gradient(90deg,
    transparent 0%,
    var(--accent-deep) 8%,
    var(--accent) 50%,
    var(--accent-deep) 92%,
    transparent 100%);
  border-radius: 2px;
  opacity: 0.5;
}
.hstep {
  flex: 1;
  display: flex; flex-direction: column; align-items: center;
  padding: 0 var(--s-3);
  text-align: center;
  position: relative;
  z-index: 1;
}
.hstep-circle {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--border-hi);
  display: grid; place-items: center;
  font: 600 18px/1 var(--font-mono);
  color: var(--accent-text);
  margin-bottom: var(--s-4);
  position: relative;
  box-shadow:
    0 0 0 4px var(--bg),
    0 1px 0 rgba(255,255,255,0.06) inset;
  transition: transform 0.2s, border-color 0.2s;
}
.hstep:hover .hstep-circle {
  transform: translateY(-2px);
  border-color: var(--accent);
}
.hstep-circle::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: 50%;
  padding: 1px;
  background: linear-gradient(180deg, var(--accent-hi), transparent);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0.3;
  pointer-events: none;
}
.hstep-title { font-size: 15px; font-weight: 600; color: var(--text); margin-bottom: 6px; letter-spacing: -0.01em; }
.hstep-desc { font-size: 12px; line-height: 1.55; color: var(--text-muted); max-width: 180px; }
.hstep-arrow { display: none; }
@media (max-width: 720px) {
  .hsteps { flex-direction: column; gap: var(--s-4); }
  .hsteps::before { display: none; }
}

/* Stages (horizontal cards, equal height, progressive) */
/* minmax(168px, 1fr) — lets 4-item stages (the dominant pattern, 9 of 12
   blocks) fit across the body column (720px max) without orphaning the 4th
   to a second row. Was minmax(220px, 1fr) which forced 3+1 wrap. */
.stages {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(168px, 1fr));
  gap: var(--s-3);
  margin: var(--s-6) 0;
}
.stage {
  padding: var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  display: flex; flex-direction: column;
  position: relative;
  min-height: 220px;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 2px 6px rgba(0,0,0,0.15);
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.25s;
}
.stage:hover {
  border-color: var(--border-hi);
  transform: translateY(-2px);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 10px 24px -8px rgba(0,0,0,0.35);
}
.stage-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: var(--s-4);
  gap: var(--s-3);
}
.stage-icon {
  display: inline-flex; align-items: center;
  color: var(--accent-text);
  flex-shrink: 0;
}
.stage-icon svg { width: 22px; height: 22px; stroke-width: 1.8; }
.stage-num {
  font-family: var(--font-mono);
  font-size: 24px;
  font-weight: 500;
  line-height: 1;
  color: var(--text-ghost);
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
.stage-kicker {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  margin-bottom: var(--s-2);
}
.stage-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: var(--s-2);
  letter-spacing: -0.02em;
}
.stage-desc {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-muted);
  margin-bottom: var(--s-4);
}
.stage-range {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--accent-text);
  margin-top: auto;
  align-self: flex-start;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}

/* Vertical Steps (sequential funnel) — continuous connector track between circles */
.vsteps {
  margin: var(--s-6) 0;
  max-width: 720px;
  padding-left: 12px;
  position: relative;
}
/* Continuous vertical highlight track behind the number circles.
   Matches the horizontal-steps ::before gradient pattern so both step
   variants carry the same "these numbers are a connected sequence"
   visual cue. Replaces the old per-pair .vstep::after connector. */
.vsteps::before {
  content: "";
  position: absolute;
  /* Circle centre sits 12px + 48px margin - 48px absolute-left + 20px
     half-width = 32px from .vsteps' outer box. 2px track centred → 31. */
  left: 31px;
  top: 16px;      /* top of first circle */
  bottom: 16px;   /* top of last circle (doesn't need to reach the bottom) */
  width: 2px;
  background: linear-gradient(180deg,
    transparent 0%,
    var(--accent-deep) 6%,
    var(--accent) 50%,
    var(--accent-deep) 94%,
    transparent 100%);
  border-radius: 2px;
  opacity: 0.5;
  pointer-events: none;
}
.vstep {
  padding: var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  position: relative;
  margin-left: 48px;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 2px 6px rgba(0,0,0,0.15);
}
.vstep + .vstep { margin-top: var(--s-4); }
.vstep-head {
  display: flex; align-items: center; gap: 14px;
  margin-bottom: 8px;
}
.vstep-num {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--border-hi);
  display: grid; place-items: center;
  font: 600 14px/1 var(--font-mono);
  color: var(--accent-text);
  flex-shrink: 0;
  position: absolute;
  left: -48px; top: 16px;
  box-shadow:
    0 0 0 3px var(--bg),
    0 1px 0 rgba(255,255,255,0.06) inset;
}
.vstep-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.01em;
}
.vstep-body {
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-muted);
}

/* Waterfall — P&L statements, cost breakdowns, cash-flow templates.
   Replaces the old "raw markdown code block" treatment with a proper
   surface. Deductions indent + get a minus sign; subtotals pop in
   accent blue with a top rule; values right-align in mono tabular.
   Sits in the same surface family as callouts / founders-note. */
.waterfall {
  margin: var(--s-6) 0;
  padding: var(--s-5) var(--s-6);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  max-width: 640px;
}
.waterfall-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 4px 0;
  font-size: 14px;
  line-height: 1.5;
}
.waterfall-sign {
  flex-shrink: 0;
  width: 14px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-dim);
  text-align: center;
}
.waterfall-label {
  flex: 1;
  color: var(--text-muted);
}
.waterfall-value {
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  text-align: right;
}
.waterfall-row--topline {
  font-weight: 600;
  color: var(--text);
  padding-top: var(--s-2);
}
.waterfall-row--topline .waterfall-label { color: var(--text); }
.waterfall-row--item {
  padding-left: 0;
}
.waterfall-row--subtotal {
  font-weight: 600;
  margin-top: 6px;
  padding-top: 8px;
  border-top: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
}
.waterfall-row--subtotal .waterfall-label { color: var(--accent-text); }
.waterfall-row--subtotal .waterfall-sign { color: var(--accent-text); }
.waterfall-row--subtotal .waterfall-value { color: var(--accent-text); }
.waterfall-gap { height: var(--s-3); }

/* Formula — flat, no outer card. The equation itself is the anchor. */
/* Formula — glow-surface family (Option A from kitchen-sink). Full-block
   accent-blue glow matching callouts / waterfall / principle. Equation
   sits on a blue-tinted bottom border inside the card, variables follow
   as a legend with thin neutral dividers between rows. */
.formula {
  margin: var(--s-6) 0;
  padding: var(--s-5) var(--s-6);
  background:
    radial-gradient(ellipse 80% 70% at top right,
      color-mix(in srgb, var(--accent) 14%, transparent) 0%,
      transparent 60%),
    radial-gradient(ellipse 60% 100% at bottom left,
      color-mix(in srgb, var(--accent) 6%, transparent) 0%,
      transparent 55%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  position: relative;
  overflow: hidden;
}
.formula-name {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  margin-bottom: var(--s-3);
}
.formula-eq {
  font-family: var(--font-mono);
  font-size: clamp(20px, 2.6vw, 26px);
  color: var(--text);
  font-weight: 500;
  padding: var(--s-4) 0;
  background: transparent;
  border: 0;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 25%, transparent);
  border-radius: 0;
  margin-bottom: var(--s-4);
  overflow-x: auto;
  letter-spacing: -0.01em;
  text-align: left;
}
.formula-eq .var { color: var(--accent-text); font-weight: 600; }
.formula-eq .op  { color: var(--text-dim); }
.formula-vars {
  display: grid;
  gap: 0;
  padding: 0;
}
.formula-var {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: var(--s-4);
  font-size: 14px;
  line-height: 1.55;
  padding: 8px 0;
  border: 0;
}
.formula-var + .formula-var {
  border-top: 1px solid color-mix(in srgb, var(--border) 50%, transparent);
}
.formula-var-name {
  font-family: var(--font-mono);
  color: var(--accent-text);
  font-weight: 600;
  font-size: 12px;
}
.formula-var-desc { color: var(--text-muted); }

/* Threshold (colour-coded metric ranges) — flat, rows stand on their own */
.threshold { margin: var(--s-5) 0; }
.threshold-head {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  margin-bottom: var(--s-3);
  padding-bottom: var(--s-3);
  border-bottom: 1px solid var(--border);
  font-weight: 500;
}
.threshold-rows { display: grid; gap: var(--s-2); }
.threshold-row {
  display: grid;
  grid-template-columns: 140px 1fr auto;
  gap: var(--s-4);
  padding: var(--s-3) var(--s-4) var(--s-3) var(--s-3);
  border-radius: var(--r-sm);
  align-items: center;
  font-size: 14px;
  border-left: 2px solid transparent;
  background: var(--surface);
  box-shadow: 0 1px 0 rgba(255,255,255,0.03) inset;
}
.threshold-row--ok {
  border-left-color: var(--ok);
  background:
    linear-gradient(90deg, rgba(34,197,94,0.10), rgba(34,197,94,0.02) 40%),
    var(--surface);
}
.threshold-row--warn {
  border-left-color: var(--warn);
  background:
    linear-gradient(90deg, rgba(245,158,11,0.10), rgba(245,158,11,0.02) 40%),
    var(--surface);
}
.threshold-row--err {
  border-left-color: var(--err);
  background:
    linear-gradient(90deg, rgba(239,68,68,0.10), rgba(239,68,68,0.02) 40%),
    var(--surface);
}
.threshold-range {
  font-family: var(--font-mono);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
}
.threshold-row--ok .threshold-range { color: var(--ok); }
.threshold-row--warn .threshold-range { color: var(--warn); }
.threshold-row--err .threshold-range { color: var(--err); }
.threshold-desc { color: var(--text-muted); line-height: 1.5; }
.threshold-label {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-dim);
  font-weight: 500;
}

/* Tool Grid (tool/platform recommendations) */
.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--s-3);
  margin: var(--s-5) 0;
}
.tool-card {
  padding: var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  transition: border-color 0.15s, transform 0.15s, background 0.15s;
  display: flex; flex-direction: column;
  cursor: pointer;
}
.tool-card:hover {
  background: var(--surface-2);
  transform: translateY(-2px);
  border-color: var(--border-hi);
}
.tool-card-category {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: var(--s-3);
}
.tool-card-name {
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
  letter-spacing: -0.01em;
}
.tool-card-desc {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-muted);
  margin-bottom: var(--s-3);
}
.tool-card-link {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-top: auto;
  padding-top: var(--s-3);
  border-top: 1px solid var(--border);
  transition: color 0.15s;
}
.tool-card:hover .tool-card-link { color: var(--accent-text); }

/* Tables (standard markdown) */
.md-table {
  width: 100%;
  margin: var(--s-5) 0;
  border-collapse: collapse;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  overflow: hidden;
  font-size: 14px;
}
/* Header row — Inter (not mono) so mid-length column labels scan well,
   accent-blue for brand coherence, 5% accent wash + blue-tinted bottom
   border for structural weight without a heavy grey fill. Mono stays
   reserved for numbers / kickers / metric values elsewhere; tables are
   scanning surfaces and benefit from sans-serif. */
.md-table thead {
  background: color-mix(in srgb, var(--accent) 5%, var(--surface));
}
.md-table th {
  text-align: left;
  padding: var(--s-3) var(--s-4);
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 40%, transparent);
}
.md-table td {
  padding: var(--s-3) var(--s-4);
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
  line-height: 1.55;
  vertical-align: top;
}
.md-table tr:last-child td { border-bottom: none; }
.md-table td:first-child { color: var(--text); font-weight: 600; }
.md-table tr:hover td { background: var(--surface-2); }

/* Checklist */
.checklist {
  margin: var(--s-6) 0;
  padding: var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
}
.checklist-head {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-bottom: var(--s-4);
  padding-bottom: var(--s-3);
  border-bottom: 1px solid var(--border);
}
.checklist-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  display: flex; align-items: center; gap: 10px;
}
.checklist-count {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}
/* ── Accessibility utilities ──────────────────────────────────────────
   .sr-only: visually hidden but exposed to screen readers (text alternatives,
   labels). .skip-link: sr-only until keyboard-focused, then pinned top-left.
   Both render nothing for sighted mouse users. */
.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: fixed;
  top: 8px; left: 8px;
  z-index: 100000;
  transform: translateY(-150%);
  padding: 10px 16px;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  border-radius: 8px;
  text-decoration: none;
  transition: transform 0.12s ease;
}
.skip-link:focus {
  transform: translateY(0);
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.checklist-items { list-style: none; margin: 0; padding: 0; }
/* Hide the real <input type="checkbox"> — it would otherwise render the
   browser's native blue control next to our custom .checklist-check span.
   Keeps it focusable + accessible (clip pattern) while invisible. */
.checklist-items input.section-checkbox {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.checklist-items label { display: contents; cursor: pointer; }
.checklist-items input.section-checkbox:focus-visible + .checklist-check {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.checklist-items input.section-checkbox:checked ~ .checklist-text {
  color: var(--text-dim);
  text-decoration: line-through;
  text-decoration-color: var(--text-ghost);
}
.checklist-items li:has(input.section-checkbox:checked) .checklist-check {
  background: var(--accent);
  border-color: var(--accent);
}
.checklist-items li:has(input.section-checkbox:checked) .checklist-check::after {
  content: "";
  position: absolute;
  left: 5px; top: 2px;
  width: 4px; height: 9px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.checklist-items li {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.15s;
}
.checklist-items li:hover { color: var(--text); }
.checklist-items li:last-child { border-bottom: none; }
.checklist-check {
  width: 18px; height: 18px;
  border: 1.5px solid var(--text-ghost);
  border-radius: 4px;
  flex-shrink: 0;
  margin-top: 2px;
  transition: border-color 0.15s, background 0.15s;
  position: relative;
}
.checklist-items li:hover .checklist-check { border-color: var(--accent-text); }
.checklist-items li.done .checklist-check {
  background: var(--accent);
  border-color: var(--accent);
}
.checklist-items li.done .checklist-check::after {
  content: "";
  position: absolute;
  left: 5px; top: 2px;
  width: 4px; height: 9px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.checklist-items li.done {
  color: var(--text-dim);
  text-decoration: line-through;
  text-decoration-color: var(--text-ghost);
}

/* Reset button, centred inside the section-complete card. One click
   unticks every item in this section's checklist and returns the UI to
   the in-progress state. Subtle secondary styling so it doesn't compete
   with the "Section complete" celebration above it. */
.section-complete-actions {
  margin-top: var(--s-5);
  display: flex;
  justify-content: center;
}
.checklist-reset-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-dim);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s, background 0.15s;
}
.checklist-reset-btn:hover {
  color: var(--text);
  border-color: var(--border-hi);
  background: color-mix(in srgb, var(--accent) 6%, transparent);
}
.checklist-reset-btn:disabled {
  opacity: 0.5;
  cursor: wait;
}
.checklist-reset-btn svg {
  color: var(--accent-text);
  flex-shrink: 0;
}

/* ==========================================================================
   Scroll-triggered animations for the long-form sections.
   Elements with [data-animate] start invisible and fade+slide in
   when scrolled into view (via IntersectionObserver in the page <script>).
   ========================================================================== */
html.js-animate [data-animate] {
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}
html.js-animate [data-animate].is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Growth curve — animated line draw on the first viz */
html.js-animate .lf-viz-growth .viz-line {
  stroke-dasharray: 820;
  stroke-dashoffset: 820;
  transition: stroke-dashoffset 2s cubic-bezier(0.16, 1, 0.3, 1);
}
html.js-animate .lf-viz-growth.is-visible .viz-line {
  stroke-dashoffset: 0;
}
html.js-animate .lf-viz-growth .viz-area {
  opacity: 0;
  transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1) 0.6s;
}
html.js-animate .lf-viz-growth.is-visible .viz-area {
  opacity: 1;
}
html.js-animate .lf-viz-growth .viz-dot {
  opacity: 0;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
html.js-animate .lf-viz-growth.is-visible .viz-dot { opacity: 1; }

/* Diagnostic sliders — animated fill */
html.js-animate .lf-viz-sliders .viz-slider-line {
  stroke-dasharray: 600;
  stroke-dashoffset: 600;
  transition: stroke-dashoffset 1.4s cubic-bezier(0.16, 1, 0.3, 1);
}
html.js-animate .lf-viz-sliders.is-visible .viz-slider-line {
  stroke-dashoffset: 0;
}
html.js-animate .lf-viz-sliders .viz-slider-label {
  opacity: 0;
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1) 1.2s;
}
html.js-animate .lf-viz-sliders.is-visible .viz-slider-label { opacity: 1; }

/* Spreadsheet bars — scale up from 0 width */
html.js-animate .lf-viz-bars .viz-bar {
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}
html.js-animate .lf-viz-bars.is-visible .viz-bar { transform: scaleX(1); }

@media (prefers-reduced-motion: reduce) {
  html.js-animate [data-animate],
  html.js-animate [data-animate].is-visible,
  html.js-animate .lf-viz-growth .viz-line,
  html.js-animate .lf-viz-growth .viz-area,
  html.js-animate .lf-viz-growth .viz-dot,
  html.js-animate .lf-viz-sliders .viz-slider-line,
  html.js-animate .lf-viz-sliders .viz-slider-label,
  html.js-animate .lf-viz-bars .viz-bar {
    transition: none !important;
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
    stroke-dashoffset: 0 !important;
  }
}

/* ==========================================================================
   Long-form SEO sections (below the fold on public landing)
   Generous breathing room, flowing prose, animated section separators.
   ========================================================================== */

/* Section separator — thin gradient line between long-form sections */
.lf-sep {
  max-width: 200px;
  margin: var(--s-10) auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-hi), transparent);
}

/* Section viz (wraps SVG illustration) */
.lf-viz {
  margin: 0 auto var(--s-6);
  max-width: 760px;
  padding: 0 var(--s-5);
}
.lf-viz svg { width: 100%; height: auto; display: block; }

/* Long-form heading + prose block */
.lf-block {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 var(--s-5);
}
.lf-block h2 {
  font-size: clamp(28px, 3.8vw, 40px);
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: var(--s-5);
  color: var(--text);
}
.lf-block p {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-muted);
  margin-bottom: var(--s-4);
}
.lf-block .stat {
  color: var(--accent-text);
  font-weight: 600;
}

/* Big quote */
.lf-quote {
  max-width: 720px;
  margin: var(--s-7) auto;
  padding: 0 var(--s-5);
}
.lf-quote-text {
  font-size: clamp(24px, 3.4vw, 32px);
  font-weight: 500;
  font-style: italic;
  line-height: 1.3;
  color: var(--text);
  letter-spacing: -0.02em;
  border-left: 2px solid var(--accent);
  padding-left: var(--s-5);
}
.lf-quote-attr {
  text-align: right;
  margin-top: var(--s-3);
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-style: normal;
}

/* Big stats bar (99K words etc) */
.lf-stats-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--s-3);
  max-width: 720px;
  margin: var(--s-6) auto var(--s-5);
  padding: var(--s-5) var(--s-6);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: 0 1px 0 rgba(255,255,255,0.04) inset;
}
.lf-stat-item {
  text-align: center;
}
.lf-stat-num {
  font-family: var(--font-mono);
  font-size: 32px;
  font-weight: 600;
  line-height: 1;
  color: var(--text);
  letter-spacing: -0.025em;
  font-variant-numeric: tabular-nums;
  display: block;
  margin-bottom: 6px;
}
.lf-stat-label {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.16em;
}
@media (max-width: 640px) {
  .lf-stats-bar { grid-template-columns: repeat(2, 1fr); gap: var(--s-4); }
}

/* Feature rows (structured paragraphs with strong leads) */
.lf-features {
  max-width: 760px;
  margin: var(--s-5) auto;
  padding: 0 var(--s-5);
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.lf-features--grid {
  max-width: 960px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-3);
}
@media (max-width: 720px) { .lf-features--grid { grid-template-columns: 1fr; } }
.lf-feature {
  padding: var(--s-4) var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  box-shadow: 0 1px 0 rgba(255,255,255,0.04) inset;
}
.lf-feature strong {
  display: block;
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.01em;
  margin-bottom: 4px;
}
.lf-feature span {
  display: block;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-muted);
}

/* Social links (About Rob) */
.lf-social {
  display: flex;
  gap: var(--s-5);
  flex-wrap: wrap;
  margin: var(--s-5) 0 0;
}
.lf-social a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 13px;
  transition: color 0.15s;
}
.lf-social a:hover { color: var(--accent-text); }

/* Full section teaser grid (group-categorised) — each group carries its accent colour */
.lf-sections {
  max-width: 960px;
  margin: var(--s-6) auto;
  padding: 0 var(--s-5);
}
.lf-section-group {
  margin-bottom: var(--s-6);
  position: relative;
  padding: var(--s-4) var(--s-5);
  border-radius: var(--r-lg);
}
.lf-section-group::before {
  content: "";
  position: absolute;
  inset: -20px -40px;
  background:
    radial-gradient(ellipse 50% 60% at 20% 30%, var(--group-glow, transparent) 0%, transparent 100%),
    radial-gradient(ellipse 45% 55% at 80% 70%, var(--group-glow-2, transparent) 0%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 75% 75% at center, black 10%, transparent 95%);
          mask-image: radial-gradient(ellipse 75% 75% at center, black 10%, transparent 95%);
  filter: blur(16px);
  pointer-events: none;
  z-index: -1;
}
.lf-section-group[data-group="foundation"]  { --group-glow: rgba(129,140,248,0.10); --group-glow-2: rgba(129,140,248,0.06); --group-accent: var(--g-foundation); }
.lf-section-group[data-group="business"]    { --group-glow: rgba(59,154,252,0.10);  --group-glow-2: rgba(59,154,252,0.06); --group-accent: var(--g-business); }
.lf-section-group[data-group="growth"]      { --group-glow: rgba(74,222,128,0.09);  --group-glow-2: rgba(74,222,128,0.05); --group-accent: var(--g-growth); }
.lf-section-group[data-group="brand"]       { --group-glow: rgba(167,139,250,0.10); --group-glow-2: rgba(167,139,250,0.06); --group-accent: var(--g-brand); }
.lf-section-group[data-group="retention"]   { --group-glow: rgba(251,146,60,0.09);  --group-glow-2: rgba(251,146,60,0.05); --group-accent: var(--g-retention); }
.lf-section-group[data-group="scale"]       { --group-glow: rgba(244,114,182,0.09); --group-glow-2: rgba(244,114,182,0.05); --group-accent: var(--g-scale); }
.lf-section-group[data-group="numbers"]     { --group-glow: rgba(34,211,238,0.09);  --group-glow-2: rgba(34,211,238,0.05); --group-accent: var(--g-numbers); }
.lf-section-group[data-group="exit"]        { --group-glow: rgba(252,211,77,0.10);  --group-glow-2: rgba(252,211,77,0.06); --group-accent: var(--g-exit); }

.lf-section-group-head {
  display: flex;
  align-items: baseline;
  gap: var(--s-3);
  margin-bottom: var(--s-4);
  padding-bottom: var(--s-3);
  border-bottom: 1px solid var(--border);
}
.lf-section-group-num {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  color: var(--group-accent, var(--text-dim));
  letter-spacing: 0.16em;
  text-transform: uppercase;
  min-width: 32px;
}
.lf-section-group-title {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text);
}
.lf-section-group-count {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-left: auto;
}

.lf-section-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-2);
}
.lf-section-cards.two-col {
  grid-template-columns: 1fr 1fr;
}
.lf-section-card {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: var(--s-4);
  padding: var(--s-4) var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 2px solid var(--group-accent, var(--border));
  border-radius: var(--r-md);
  transition: border-color 0.15s, background 0.15s, transform 0.15s;
  box-shadow: 0 1px 0 rgba(255,255,255,0.04) inset;
}
.lf-section-card:hover {
  border-color: var(--border-hi);
  border-left-color: var(--group-accent, var(--accent));
  background: var(--surface-2);
  transform: translateY(-1px);
}
.lf-section-card img {
  width: 22px; height: 22px;
  margin-top: 2px;
}

/* Per-group icon tints — aligned with locked palette */
.lf-section-group[data-group="foundation"] .lf-section-card img {
  /* #818CF8 — indigo */
  filter: brightness(0) saturate(100%) invert(63%) sepia(32%) saturate(1800%) hue-rotate(215deg);
}
.lf-section-group[data-group="business"] .lf-section-card img {
  /* #3B9AFC — bright blue */
  filter: brightness(0) saturate(100%) invert(55%) sepia(58%) saturate(2100%) hue-rotate(195deg);
}
.lf-section-group[data-group="growth"] .lf-section-card img {
  /* #4ADE80 — green */
  filter: brightness(0) saturate(100%) invert(78%) sepia(44%) saturate(420%) hue-rotate(85deg);
}
.lf-section-group[data-group="brand"] .lf-section-card img {
  /* #A78BFA — violet */
  filter: brightness(0) saturate(100%) invert(66%) sepia(38%) saturate(1400%) hue-rotate(220deg);
}
.lf-section-group[data-group="retention"] .lf-section-card img {
  /* #FB923C — orange */
  filter: brightness(0) saturate(100%) invert(68%) sepia(50%) saturate(1400%) hue-rotate(340deg);
}
.lf-section-group[data-group="scale"] .lf-section-card img {
  /* #F472B6 — pink */
  filter: brightness(0) saturate(100%) invert(64%) sepia(32%) saturate(1500%) hue-rotate(295deg);
}
.lf-section-group[data-group="numbers"] .lf-section-card img {
  /* #22D3EE — cyan */
  filter: brightness(0) saturate(100%) invert(82%) sepia(38%) saturate(600%) hue-rotate(140deg);
}
.lf-section-group[data-group="exit"] .lf-section-card img {
  /* #FCD34D — gold */
  filter: brightness(0) saturate(100%) invert(84%) sepia(44%) saturate(800%) hue-rotate(355deg);
}

.lf-section-card-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
  letter-spacing: -0.005em;
}
.lf-section-card-desc {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-muted);
}
@media (max-width: 720px) { .lf-section-cards.two-col { grid-template-columns: 1fr; } }

/* Second CTA block (below-fold, matches final-CTA but full-width feeling) */
.lf-secondary-cta {
  max-width: 680px;
  margin: var(--s-8) auto 0;
  padding: var(--s-8) var(--s-6);
  background:
    radial-gradient(ellipse 70% 80% at center 40%, var(--blue-glow-soft), transparent 70%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  text-align: center;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 20px 48px -16px rgba(0,0,0,0.3);
}
.lf-secondary-cta h3 {
  font-size: clamp(24px, 3.4vw, 32px);
  letter-spacing: -0.03em;
  margin-bottom: var(--s-3);
}
.lf-secondary-cta h3 .accent { color: var(--accent-text); }
.lf-secondary-cta p {
  font-size: 15px;
  color: var(--text-muted);
  margin-bottom: var(--s-5);
  max-width: 460px;
  margin-left: auto; margin-right: auto;
  line-height: 1.55;
}

/* ==========================================================================
   Profile Complete — persona gate shown post-signup.
   Captures persona + persona-specific fields + universal (country, how_heard, problem).
   ========================================================================== */
.profile-view {
  max-width: 760px;
  margin: 0 auto;
  padding: var(--s-9) var(--s-5) var(--s-10);
}
.profile-hero {
  text-align: center;
  margin-bottom: var(--s-8);
}
.profile-hero-eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-weight: 600;
  margin-bottom: var(--s-3);
}
.profile-hero h1 {
  font-size: clamp(32px, 4.5vw, 44px);
  letter-spacing: -0.03em;
  margin-bottom: var(--s-3);
}
.profile-hero p {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.6;
}

/* Invitee mode — when the user accepted a team invite, brand-level fields
   are inherited from the brand they joined, so we hide any block tagged
   data-hide-for-invitee and swap the hero copy via JS. !important beats
   the persona-switcher's inline display:'' when a persona is picked.
   The is-invitee class is added to #view-profile-complete (outer wrapper)
   in script.js showProfileComplete — the .profile-view selector below
   never matched because the class lives one level up. Kept for safety
   in case that ever changes, but #view-profile-complete is the one that
   actually fires. */
#view-profile-complete.is-invitee [data-hide-for-invitee],
.profile-view.is-invitee [data-hide-for-invitee] { display: none !important; }
#view-profile-complete.is-invitee .profile-hero p strong,
.profile-view.is-invitee .profile-hero p strong { color: var(--accent-text); font-weight: 600; }

.profile-form {
  display: flex;
  flex-direction: column;
  gap: var(--s-8);
}
.profile-section {
  border: none;
  padding: 0;
  margin: 0;
}
.profile-section-head {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding-bottom: var(--s-3);
  margin-bottom: var(--s-5);
  border-bottom: 1px solid var(--border);
}
.profile-section-num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-weight: 600;
  min-width: 36px;
}
.profile-section-title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}
.profile-section-hint {
  font-size: 13px;
  color: var(--text-muted);
  margin-left: auto;
}

/* Persona picker — 4 cards */
.persona-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--s-3);
}
.persona-card {
  padding: var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, transform 0.15s, box-shadow 0.2s;
  position: relative;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-family: inherit;
  color: inherit;
  box-shadow: 0 1px 0 rgba(255,255,255,0.04) inset;
}
.persona-card:hover {
  border-color: var(--border-hi);
  transform: translateY(-1px);
}
.persona-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.persona-card.is-selected {
  border-color: var(--accent);
  background:
    radial-gradient(ellipse 60% 100% at top right, var(--blue-wash), transparent 70%),
    var(--surface);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 0 0 1px var(--accent) inset,
    0 8px 24px -6px var(--blue-glow-soft);
}
.persona-card-label {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}
.persona-card.is-selected .persona-card-label { color: var(--accent-text); }
.persona-card-title {
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.015em;
}
.persona-card-desc {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-muted);
}

/* Form grid for per-persona fields */
.profile-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--s-4) var(--s-3);
}
.profile-grid--full { grid-template-columns: 1fr; }
.profile-field { display: flex; flex-direction: column; gap: 6px; }
.profile-field-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}
.profile-field-hint {
  font-size: 12px;
  color: var(--text-dim);
  margin-top: 4px;
  font-style: italic;
}
.profile-input,
.profile-select,
.profile-textarea {
  padding: 11px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-size: 14px;
  font-family: var(--font-sans);
  transition: border-color 0.15s, box-shadow 0.15s;
  width: 100%;
}
.profile-input:focus,
.profile-select:focus,
.profile-textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--blue-glow-soft);
}
.profile-select {
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%238A8D99' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
  cursor: pointer;
}
.profile-textarea {
  min-height: 100px;
  resize: vertical;
  line-height: 1.55;
}
.profile-textarea::placeholder { color: var(--text-ghost); }
.profile-char-count {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-align: right;
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

/* Services multi-select (advisor) */
.service-checkboxes {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--s-2);
}
.service-check {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  color: var(--text-muted);
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}
.service-check:hover { border-color: var(--border-hi); color: var(--text); background: var(--surface-2); }
.service-check input[type="checkbox"] { accent-color: var(--accent); }
.service-check.is-checked {
  border-color: var(--accent);
  color: var(--text);
  background: var(--blue-wash);
}

/* Footer: consent + submit */
.profile-footer {
  margin-top: var(--s-6);
  padding-top: var(--s-5);
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.profile-submit {
  align-self: center;
  min-width: 240px;
  justify-content: center;
}

@media (max-width: 640px) {
  .persona-grid, .profile-grid, .service-checkboxes { grid-template-columns: 1fr; }
}

/* ==========================================================================
   Health Check — intro (tier picker), questions (slider), email gate, results
   ========================================================================== */

/* Shared HC layout */
.hc-view,
.hc-shell,
.hc-intro-shell,
.hc-question-shell,
.hc-stage-shell,
.hc-results-shell {
  max-width: 760px;
  margin: 0 auto;
  padding: var(--s-9) var(--s-5);
  text-align: center;
}
.hc-question-shell { text-align: left; }
/* Mobile: 96px top padding stacks under the topbar as dead space.
   Tighten so HC intro / question / stage / results content starts above the fold. */
@media (max-width: 768px) {
  .hc-view,
  .hc-shell,
  .hc-intro-shell,
  .hc-question-shell,
  .hc-stage-shell,
  .hc-results-shell {
    padding: var(--s-5) var(--s-5);
  }
}
.hc-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 100px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: var(--s-5);
}
.hc-eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent);
}
.hc-title {
  font-size: clamp(34px, 4.5vw, 52px);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.05;
  color: var(--text);
  margin-bottom: var(--s-4);
}
.hc-subtitle {
  font-size: 17px;
  line-height: 1.6;
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto var(--s-7);
}

/* Tier picker (intro) — two cards: Quick vs Full */
.hc-tiers {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--s-3);
  max-width: 720px;
  margin: 0 auto;
  text-align: left;
}
/* Single-tier layout — Phase 8 onwards (Quick HC removed). Centres a
   solo Full Diagnostic card on the intro page rather than letting it
   stretch across the 2-col grid. */
.hc-tiers--single {
  grid-template-columns: 1fr;
  max-width: 480px;
}
.hc-tier {
  padding: var(--s-6);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  position: relative;
  cursor: pointer;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.25s;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 2px 6px rgba(0,0,0,0.15);
  display: flex;
  flex-direction: column;
}
.hc-tier:hover {
  border-color: var(--border-hi);
  transform: translateY(-2px);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 12px 28px -8px rgba(0,0,0,0.35);
}
.hc-tier--recommended {
  border-color: rgba(31,147,255,0.3);
  background:
    radial-gradient(ellipse 60% 70% at top right, var(--blue-glow-soft), transparent 60%),
    var(--surface);
}
.hc-tier-badge {
  position: absolute;
  top: -10px;
  right: var(--s-5);
  padding: 4px 10px;
  background: var(--accent);
  color: white;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  border-radius: 4px;
  box-shadow: 0 4px 12px -2px var(--blue-glow);
}
.hc-tier-label {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  margin-bottom: var(--s-3);
  font-weight: 600;
}
.hc-tier-title {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: var(--s-3);
}
.hc-tier-desc {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-muted);
  margin-bottom: var(--s-4);
}
.hc-tier-meta {
  display: flex; flex-direction: column; gap: 8px;
  padding: var(--s-4) 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin-bottom: var(--s-4);
}
.hc-tier-meta-row {
  display: flex; align-items: center; gap: 10px;
  font-size: 13px;
  color: var(--text-muted);
}
.hc-tier-meta-row svg { color: var(--accent-text); flex-shrink: 0; }
.hc-tier-cta {
  margin-top: auto;
  width: 100%;
  justify-content: center;
}

/* Disabled-tier state — used on the Quick Check card once the brand has
   completed the Full Diagnostic. We keep the card visible (the page is
   explicitly a "pick one of two" choice, so an empty column would feel
   broken) but visually retire it and surface a one-line explanation on
   hover. Pointer stays default; the CTA is disabled so no accidental
   downgrade of the dashboard data. */
.hc-tier.is-disabled {
  opacity: 0.55;
  filter: saturate(0.7);
  cursor: default;
  transition: opacity 0.2s ease;
}
.hc-tier.is-disabled:hover {
  opacity: 1;
  transform: none;
  border-color: var(--border);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 2px 6px rgba(0,0,0,0.15);
}
.hc-tier.is-disabled .hc-tier-cta {
  pointer-events: none;
  background: transparent;
  border-color: var(--border);
  color: var(--text-dim);
  cursor: not-allowed;
}
/* Tooltip-style hover reveal for the "why is this greyed out" copy.
   Collapsed to 0 height in rest state so it doesn't push the CTA
   down when not in use. */
.hc-tier-reason {
  margin-top: var(--s-3);
  padding: 0 var(--s-3);
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  font-size: 12px;
  line-height: 1.55;
  color: var(--text-muted);
  border-left: 2px solid var(--accent);
  background: color-mix(in srgb, var(--accent) 8%, transparent);
  border-radius: 4px;
  transition: max-height 0.25s ease, opacity 0.2s ease, padding 0.25s ease;
}
.hc-tier-reason strong {
  color: var(--text);
  font-weight: 600;
}
.hc-tier.is-disabled:hover .hc-tier-reason,
.hc-tier.is-disabled:focus-within .hc-tier-reason {
  max-height: 240px;
  opacity: 1;
  padding: var(--s-3);
}

@media (max-width: 640px) {
  .hc-tiers { grid-template-columns: 1fr; }
  /* Touch devices don't have hover — just show the reason inline so mobile
     users still see the explanation of why the Quick tier is disabled. */
  .hc-tier.is-disabled .hc-tier-reason {
    max-height: 240px;
    opacity: 1;
    padding: var(--s-3);
  }
}

/* Question flow */
.hc-progress {
  display: flex; align-items: center; gap: var(--s-3);
  margin-bottom: var(--s-6);
  max-width: 560px;
  margin-left: auto; margin-right: auto;
}
.hc-progress-track {
  flex: 1;
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}
.hc-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-hi));
  border-radius: 2px;
  box-shadow: 0 0 8px var(--blue-glow-soft);
  transition: width 0.3s cubic-bezier(0.16,1,0.3,1);
}
.hc-progress-label {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.hc-question-cat {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-weight: 600;
  margin-bottom: var(--s-3);
}
/* Section-title eyebrow — kept for any legacy reference but DEPRECATED
   in favour of .hc-section-header below. */
.hc-section-title-eyebrow {
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--hc-accent, var(--accent-text));
  margin-bottom: var(--s-2);
}

/* Section header — BIG. Greg (beta tester) didn't realise he'd moved
   from "AI Lever" to "PMF" mid-flow because the eyebrow was too small.
   Now the section name is a dominant heading; users can't miss it.
   Kicker above it shows "Section NN · Category". */
.hc-section-header {
  margin: var(--s-5) auto var(--s-6);
  max-width: 640px;
  text-align: center;
  padding-bottom: var(--s-4);
  border-bottom: 1px solid var(--border);
}
.hc-section-header-kicker {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--hc-accent, var(--accent-text));
  margin-bottom: 6px;
}
.hc-section-header-title {
  font-family: var(--font-sans);
  font-size: clamp(22px, 3vw, 30px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.15;
  color: var(--text);
  margin: 0;
}
/* Per-question meta row: stage · subsection · section number.
   Was unstyled (browser default). Now small muted mono — reads as
   metadata, doesn't compete with the headline question. */
.hc-question-meta {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  margin-bottom: var(--s-4);
}
.hc-question-text {
  /* Smaller max font than before so even the longest question (117 chars)
     wraps to at most 3 lines at a 760px shell width. */
  font-size: clamp(20px, 2.4vw, 26px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.25;
  color: var(--text);
  margin-bottom: var(--s-2);
  /* Reserve 3 lines of height regardless of actual text length so the
     answer cards below don't jump up/down when navigating between
     short (1-line) and long (3-line) questions. 1.25 line-height × 3. */
  min-height: calc(1.25em * 3);
}
.hc-question-hint {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: var(--s-7);
  max-width: 520px;
  margin-left: auto; margin-right: auto;
}

/* Options-wrap: Least→Most vertical scale axis on the left, options
   stack on the right. The scale makes 1=least, 5=most unambiguous —
   Greg (beta tester) initially didn't realise the ordering, which
   compromised the whole assessment. */
.hc-options-wrap {
  max-width: 700px;
  margin: 0 auto var(--s-5);
  display: flex;
  gap: var(--s-4);
  align-items: stretch;
}
.hc-scale-axis {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  width: 64px;
  padding: 8px 0;
}
.hc-scale-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-dim);
}
.hc-scale-line {
  flex: 1;
  width: 2px;
  min-height: 40px;
  margin: 8px 0 6px;
  background: linear-gradient(to bottom, var(--border-hi) 0%, var(--accent-text) 100%);
  position: relative;
}
.hc-scale-line::after {
  content: "";
  position: absolute;
  bottom: -2px; left: -3px;
  width: 0; height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 7px solid var(--accent-text);
}
@media (max-width: 640px) {
  .hc-options-wrap { gap: var(--s-2); }
  .hc-scale-axis { width: 44px; }
  .hc-scale-label { font-size: 9px; letter-spacing: 0.12em; }
}

/* Previous button — ghost style, sits in the footer alongside Next.
   Putting prev here lets users navigate without reaching for the
   browser back button (which would bounce them off the SPA). */
.hc-prev-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 120px;
  justify-content: center;
  padding: 10px 18px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}
.hc-prev-btn:hover { border-color: var(--border-hi); color: var(--text); background: var(--surface); }
.hc-prev-btn .icon { width: 14px; height: 14px; }

/* Footer layout: prev on the left, centre status + save, next on the right. */
.hc-footer-actions {
  display: grid !important;
  grid-template-columns: 120px 1fr auto;
  align-items: center;
  gap: var(--s-4);
  margin-top: var(--s-6);
}
.hc-footer-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
  min-width: 0;
}
@media (max-width: 640px) {
  .hc-footer-actions {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "status  status"
      "prev    next";
  }
  .hc-footer-actions .hc-footer-center { grid-area: status; }
  .hc-footer-actions .hc-prev-btn { grid-area: prev; }
  .hc-footer-actions .hc-next-btn { grid-area: next; }
}

/* Options — 5 stacked choice cards per question. User picks one. */
.hc-options {
  flex: 1;
  min-width: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  text-align: left;
}
.hc-option {
  display: grid;
  grid-template-columns: 44px 1fr 24px;
  gap: var(--s-4);
  align-items: center;
  padding: var(--s-4) var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, transform 0.15s, box-shadow 0.2s;
  font-family: inherit;
  text-align: left;
  width: 100%;
  color: inherit;
  box-shadow: 0 1px 0 rgba(255,255,255,0.04) inset;
  position: relative;
}
.hc-option:hover {
  border-color: var(--border-hi);
  background: var(--surface-2);
  transform: translateY(-1px);
}
.hc-option:hover .hc-option-num { color: var(--accent-text); border-color: var(--border-hi); }
.hc-option.is-selected {
  border-color: var(--accent);
  background:
    radial-gradient(ellipse 60% 100% at left center, var(--blue-wash), transparent 70%),
    var(--surface);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 0 0 1px var(--accent) inset,
    0 8px 24px -6px var(--blue-glow-soft);
}
.hc-option.is-selected .hc-option-num {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}
.hc-option.is-selected .hc-option-check { opacity: 1; }

.hc-option-num {
  width: 36px; height: 36px;
  display: grid; place-items: center;
  border-radius: 50%;
  border: 1px solid var(--border-hi);
  font: 500 13px/1 var(--font-mono);
  color: var(--text-dim);
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  font-variant-numeric: tabular-nums;
}
.hc-option-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.hc-option-lead {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.01em;
}
.hc-option-text {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-muted);
}
.hc-option-check {
  opacity: 0;
  color: var(--accent-text);
  transition: opacity 0.15s;
  display: grid; place-items: center;
}

/* Not applicable option — smaller, quieter */
.hc-option--na {
  margin-top: var(--s-3);
  background: transparent;
  border-style: dashed;
}
.hc-option--na .hc-option-num { opacity: 0.5; }
.hc-option--na .hc-option-lead { color: var(--text-dim); font-weight: 500; }

/* Dimmed state: applied to score options when the user has marked the
   question N/A. Visual cue that they're inactive but still clickable
   (clicking any option undoes the N/A and selects that score). */
.hc-option.is-dimmed {
  opacity: 0.4;
  background: transparent;
}
.hc-option.is-dimmed:hover { opacity: 0.7; }

/* N/A button row: only rendered when question.na === true. Sits below
   the score options with breathing room. The button itself is a soft
   ghost-style action — visually subordinate to the score ladder so
   users default to scoring rather than skipping. */
.hc-na-row {
  margin-top: var(--s-4);
  padding-top: var(--s-4);
  border-top: 1px dashed var(--border);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--s-2);
}
.hc-na-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: var(--s-2) var(--s-3);
  color: var(--text-muted);
  font: 500 13px/1.2 var(--font-sans);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}
.hc-na-btn:hover {
  border-color: var(--border-hi);
  color: var(--text);
  background: rgba(255,255,255,0.02);
}
.hc-na-btn .hc-na-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 4px;
  border: 1.5px solid var(--border-hi);
  color: transparent;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.hc-na-btn.is-selected {
  border-color: var(--accent);
  color: var(--text);
  background: rgba(32, 128, 212, 0.08);
}
.hc-na-btn.is-selected .hc-na-check {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--bg-void);
}
.hc-na-help {
  font: 400 12px/1.4 var(--font-sans);
  color: var(--text-dim);
  padding-left: 2px;
}

@media (max-width: 640px) {
  .hc-option { grid-template-columns: 32px 1fr 20px; gap: var(--s-3); padding: var(--s-3) var(--s-4); }
  .hc-option-num { width: 28px; height: 28px; font-size: 11px; }
  .hc-option-lead { font-size: 14px; }
  .hc-na-btn { font-size: 12px; }
}

.hc-nav {
  display: flex;
  justify-content: center;
  gap: var(--s-3);
  margin-top: var(--s-7);
}

/* Email gate (Quick HC submit) */
.hc-email-gate {
  max-width: 460px;
  margin: 0 auto;
  padding: var(--s-6);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  text-align: left;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 16px 40px -12px rgba(0,0,0,0.3);
}
.hc-email-gate h2 {
  font-size: 24px;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
  text-align: center;
}
.hc-email-gate p {
  text-align: center;
  color: var(--text-muted);
  margin-bottom: var(--s-5);
  font-size: 14px;
  line-height: 1.55;
}

/* Results */
.hc-results-head {
  text-align: center;
  margin-bottom: var(--s-7);
}
.hc-score-big {
  font-family: var(--font-mono);
  font-size: clamp(80px, 12vw, 144px);
  font-weight: 500;
  line-height: 1;
  color: var(--text);
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
  margin-bottom: var(--s-3);
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
}
.hc-score-big .max {
  font-size: 0.3em;
  color: var(--text-dim);
  font-weight: 400;
}
.hc-score-rating {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  margin-bottom: var(--s-3);
  font-weight: 600;
}
.hc-score-archetype {
  font-size: 17px;
  color: var(--text-muted);
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.55;
}

.hc-cat-grid {
  display: grid;
  gap: var(--s-3);
  margin: var(--s-7) 0;
}
.hc-cat-row {
  display: grid;
  grid-template-columns: 200px 1fr 56px;
  gap: var(--s-4);
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.hc-cat-row:last-child { border-bottom: none; }
.hc-cat-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  display: flex; align-items: center; gap: 10px;
}
.hc-cat-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--cat-color, var(--accent));
  flex-shrink: 0;
  box-shadow: 0 0 8px var(--cat-color, var(--accent));
}
.hc-cat-track {
  height: 10px;
  background: var(--surface-2);
  border-radius: 5px;
  overflow: hidden;
  position: relative;
}
.hc-cat-fill {
  height: 100%;
  border-radius: 5px;
  background: var(--cat-color, var(--accent));
  box-shadow: 0 0 12px -2px var(--cat-glow, var(--blue-glow-soft));
}
.hc-cat-val {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  text-align: right;
  font-weight: 500;
}
.hc-cat-row[data-status="high"] { --cat-color: var(--ok); --cat-glow: var(--ok-glow); }
.hc-cat-row[data-status="mid"]  { --cat-color: var(--warn); --cat-glow: var(--warn-glow); }
.hc-cat-row[data-status="low"]  { --cat-color: var(--err); --cat-glow: var(--err-glow); }

@media (max-width: 640px) {
  .hc-cat-row { grid-template-columns: 140px 1fr 44px; gap: var(--s-3); }
}

.hc-recs-head {
  margin: var(--s-8) 0 var(--s-4);
  padding-bottom: var(--s-3);
  border-bottom: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  text-align: left;
}

/* ==========================================================================
   Auth Overlay — signin / register modal
   Triggered by CTAs on landing + anywhere "Sign in" is clicked.
   Preserve IDs used by script.js: #auth-landing-overlay, #auth-ol-signin, #auth-ol-register
   ========================================================================== */
.auth-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: var(--s-5);
}
.auth-overlay.is-open { display: flex; }
.auth-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 9, 11, 0.72);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
}
.auth-panel {
  position: relative;
  max-width: 440px;
  width: 100%;
  background:
    radial-gradient(ellipse 80% 60% at top right, var(--blue-glow-soft) 0%, transparent 60%),
    var(--surface);
  border: 1px solid var(--border-hi);
  border-radius: var(--r-lg);
  padding: var(--s-7);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 24px 64px -16px rgba(0,0,0,0.5),
    0 0 0 1px rgba(31,147,255,0.12);
}
.auth-close {
  position: absolute;
  top: var(--s-4);
  right: var(--s-4);
  width: 32px; height: 32px;
  border-radius: 8px;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  display: grid;
  place-items: center;
  font-size: 18px;
  line-height: 1;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}
.auth-close:hover {
  border-color: var(--border-hi);
  color: var(--text);
  background: var(--surface-2);
}
.auth-head { margin-bottom: var(--s-5); }
.auth-head h2 {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 6px;
  color: var(--text);
}
.auth-head p {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.5;
  margin: 0;
}

/* Form */
.auth-form {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.auth-field { display: flex; flex-direction: column; gap: 6px; }
.auth-field-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}
.auth-field-input {
  padding: 11px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  font-size: 14px;
  font-family: var(--font-sans);
  transition: border-color 0.15s, box-shadow 0.15s;
  width: 100%;
}
.auth-field-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--blue-glow-soft);
}
.auth-field-input::placeholder { color: var(--text-ghost); }

.auth-forgot {
  font-size: 12px;
  color: var(--accent-text);
  text-align: right;
  margin-top: -4px;
  transition: color 0.15s;
}
.auth-forgot:hover { color: var(--blue-hi); }

/* Cloudflare Turnstile widget — sits between the last field and the submit
   button. `data-size="flexible"` makes it fit the container; default ~65px
   tall when a challenge shows, ~0 when invisible-pass. */
.auth-turnstile {
  margin: var(--s-3) 0 var(--s-2);
  min-height: 65px;
  display: flex;
  justify-content: center;
}

.auth-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: var(--s-3) 0 var(--s-2);
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.5;
  cursor: pointer;
}
.auth-consent input {
  width: 16px; height: 16px;
  margin-top: 2px;
  flex-shrink: 0;
  accent-color: var(--accent);
}
.auth-consent a { color: var(--accent-text); }
/* Highlight when user tries to submit without ticking the consent box.
   Wraps the row in a soft red border + subtle wash so the field is obvious
   without screaming. Cleared on next submit attempt by the JS handler. */
.auth-consent.is-error {
  border: 1px solid rgba(239, 68, 68, 0.5);
  background: rgba(239, 68, 68, 0.06);
  border-radius: 8px;
  padding: 10px 12px;
  animation: authConsentShake 0.32s cubic-bezier(0.36,0.07,0.19,0.97);
}
.auth-consent.is-error input { accent-color: rgb(239, 68, 68); }
@keyframes authConsentShake {
  0%,100% { transform: translateX(0); }
  20% { transform: translateX(-3px); }
  40% { transform: translateX(3px); }
  60% { transform: translateX(-2px); }
  80% { transform: translateX(2px); }
}

.auth-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  margin-top: var(--s-3);
  padding: 13px 22px;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.1);
  font: 600 14px/1 var(--font-sans);
  letter-spacing: -0.005em;
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.25s;
  box-shadow: 0 8px 24px -6px var(--blue-glow), 0 0 0 1px rgba(255,255,255,0.06) inset;
}
.auth-submit:hover { background: var(--accent-hi); }
.auth-submit:disabled { opacity: 0.5; cursor: not-allowed; }
.auth-submit svg { flex-shrink: 0; }

/* Divider between email + Google */
.auth-divider {
  display: flex; align-items: center; gap: 12px;
  margin: var(--s-4) 0;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.16em;
}
.auth-divider::before, .auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* Google button (reusing btn-google if defined; otherwise local) */
.auth-google {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 18px;
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid var(--border-hi);
  font: 600 14px/1 var(--font-sans);
  letter-spacing: -0.01em;
  transition: background 0.15s, border-color 0.15s;
  width: 100%;
}
.auth-google:hover { background: var(--surface); border-color: var(--accent); }

/* Switch link at bottom */
.auth-switch {
  margin-top: var(--s-5);
  padding-top: var(--s-4);
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 13px;
  color: var(--text-muted);
}
.auth-switch a {
  color: var(--accent-text);
  font-weight: 600;
  transition: color 0.15s;
}
.auth-switch a:hover { color: var(--blue-hi); }

/* State visibility — only one state shown at a time */
.auth-panel .auth-state { display: none; }
.auth-panel.state-signin #auth-ol-signin,
.auth-panel.state-register #auth-ol-register { display: block; }

/* ==========================================================================
   Public Landing Page (pre-auth, front door — no topbar chrome)
   Two-zone structure: brand masthead → zone divider → value prop pitch.
   ========================================================================== */

/* ==========================================================================
   Persistent header (sticky nav after intro — small brand + sign-in)
   ========================================================================== */
.persistent-header {
  position: sticky; top: 0; z-index: 40;
  padding: 14px 32px;
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  backdrop-filter: blur(20px) saturate(1.3);
  -webkit-backdrop-filter: blur(20px) saturate(1.3);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 1px 0 rgba(255,255,255,0.03) inset;
}
.persistent-header-brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--text);
}
.persistent-header-brand img {
  width: 24px; height: 24px;
  filter: drop-shadow(0 2px 6px var(--blue-glow-soft));
}
.persistent-header-brand .accent { color: var(--accent-text); }
.persistent-header nav { display: flex; gap: var(--s-5); }
.persistent-header nav a {
  font-size: 13px;
  color: var(--accent-text);
  font-weight: 600;
  transition: color 0.15s;
}
.persistent-header nav a:hover { color: var(--blue-hi); }
@media (max-width: 640px) { .persistent-header { padding: 12px var(--s-4); } }

/* ==========================================================================
   Intro animation — masthead plays once per session, then exits to reveal pitch
   Default (post-intro, reduced-motion, JS off) = masthead hidden, pitch visible.
   Masthead + divider are display:none by default (set in their base rules below).
   ========================================================================== */
html.intro-playing .public-masthead {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: fixed;
  inset: 0;
  z-index: 100;
  background: var(--bg);
  padding: var(--s-6);
  min-height: 0;
  text-align: center;
  /* Slower, more purposeful — holds longer, fades slower. */
  animation: mastheadExit 2.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}
html.intro-playing .public-pitch {
  opacity: 0;
  transform: translateY(24px);
  /* Starts after masthead is mostly gone, enters slowly. */
  animation: pitchEnter 1.4s 2.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
html.intro-playing .persistent-header {
  opacity: 0;
  transform: translateY(-8px);
  animation: headerEnter 1s 3.0s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
@keyframes mastheadExit {
  0%, 50% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-40px); pointer-events: none; }
}
@keyframes pitchEnter {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes headerEnter {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  html.intro-playing .public-masthead,
  html.intro-playing .public-pitch,
  html.intro-playing .persistent-header {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}

/* Zone 1 — Brand masthead. Hidden by default — only shown during intro animation. */
.public-masthead {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: var(--s-10) 0 var(--s-8);
  min-height: 44vh;
  text-align: center;
}
.public-masthead-greeting {
  font-size: 15px;
  font-style: italic;
  color: var(--text-muted);
  margin-bottom: var(--s-4);
  letter-spacing: -0.005em;
}
.public-masthead-byline {
  font-size: 14px;
  color: var(--text-dim);
  margin-top: var(--s-4);
  font-style: italic;
  letter-spacing: -0.005em;
}

/* Zone divider — minimal line. Hidden by default (only shown during intro). */
.public-zone-divider {
  display: none;
  max-width: 400px;
  margin: 0 auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-hi), transparent);
}

/* Zone 2 — Value prop pitch. Conversion moment gets its own breathing room. */
.public-pitch {
  padding: var(--s-8) 0 var(--s-6);
  text-align: center;
}
/* Landing hero video: breathing room above (was flush to the sign-in row),
   tighter to the content below (was a 96px hero pad + section divider). */
.public-pitch .dtc-explainer { margin-top: var(--s-7); margin-bottom: 0; }
/* Concise reason-to-register line, directly above the auth buttons. */
.public-cta-reason {
  max-width: 640px;
  margin: 0 auto var(--s-4);
  font-size: 15px;
  line-height: 1.5;
  color: var(--text-muted);
}
.public-cta-reason strong { color: var(--text); font-weight: 600; }

/* Mid-page conversion bands, dropped at high-intent moments in the SEO content. */
.seo-cta {
  max-width: 600px;
  margin: var(--s-8) auto;
  padding: var(--s-7) var(--s-6);
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--border-hi);
  border-radius: 16px;
}
.seo-cta-line {
  margin: 0 0 var(--s-5);
  font-size: 16px;
  line-height: 1.55;
  color: var(--text-muted);
}
.seo-cta-line strong { color: var(--text); font-weight: 600; }
.seo-cta .btn { display: inline-flex; }

/* Legacy hero wrapper kept for back-compat if used elsewhere */
.public-hero {
  padding: var(--s-10) 0 var(--s-8);
  text-align: center;
  position: relative;
}
/* Brand lockup — logo + wordmark tight together, shared blue bloom behind */
.public-hero-brand {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
  width: fit-content;
  margin: 0 auto var(--s-6);
  padding: var(--s-4) var(--s-5);
}
.public-hero-brand::before {
  content: "";
  position: absolute;
  inset: -60px -80px;
  background:
    radial-gradient(ellipse 60% 70% at center, rgba(0,120,212,0.35), transparent 60%);
  filter: blur(40px);
  pointer-events: none;
  z-index: -1;
}
.public-hero-logo {
  width: 128px; height: 128px;
  display: block;
}
.public-hero-wordmark {
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  line-height: 1;
}
.public-hero-wordmark .accent { color: var(--accent-text); }

/* Public-landing legal footer (Terms / Privacy / Disclaimer + copyright).
   Stacked block layout — children are centered via parent's text-align,
   not flex. The previous flex-based rule + companion -brand / -links
   classes were leftovers from an earlier design that no longer ships
   (only referenced by static/design-studies/ which is excluded from
   prod builds). Removed the orphans. */
/* (.public-footer removed — the landing now uses the shared .dtc-footer.) */
.public-hero-eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 6px 14px;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: 100px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: var(--s-5);
}
.public-hero-eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 10px var(--ok);
}
.public-hero-title {
  font-size: clamp(44px, 6.5vw, 76px);
  line-height: 1;
  letter-spacing: -0.04em;
  font-weight: 800;
  margin: 0 auto var(--s-5);
  max-width: 900px;
}
.public-hero-title .accent {
  color: var(--blue-hi);
  text-shadow:
    0 0 24px rgba(0,120,212,0.35),
    0 0 64px rgba(0,120,212,0.15);
}
/* Credibility lede under the H1 - Rob's exit is the USP, stated up front
   (the video below carries the problem -> solution arc). */
.public-hero-lede {
  max-width: 640px;
  margin: 0 auto var(--s-6);
  font-size: clamp(17px, 2.4vw, 21px);
  line-height: 1.55;
  font-weight: 500;
  color: var(--text-muted);
}
.public-hero-lede .highlight { color: var(--accent-text); font-weight: 600; }
.public-hero-lede .signoff {
  color: var(--text-dim);
  font-style: italic;
}

.public-hero-story {
  max-width: 620px;
  margin: 0 auto var(--s-7);
  font-size: 17px;
  line-height: 1.65;
  color: var(--text-muted);
}
.public-hero-story .highlight { color: var(--accent-text); font-weight: 600; }
.public-hero-story .signoff {
  display: block;
  margin-top: var(--s-3);
  color: var(--text-dim);
  font-style: italic;
}
/* Rob's story relocated below the CTA — give it breathing room from the sign-in row. */
.public-hero-story--below { margin-top: var(--s-8); }

/* Explainer video embed — shared by the public landing hero and the section
   preview mastheads (both link this stylesheet). Responsive 16:9, poster paints
   first; the muted-loop MP4 starts when scrolled into view (see playback JS). */
.dtc-explainer {
  position: relative;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto var(--s-7);
  aspect-ratio: 16 / 9;
  border-radius: 20px;
  overflow: hidden;
  background: #06080D;
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 40px 120px rgba(0,0,0,0.5);
}
.dtc-explainer-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Auth CTAs */
.public-cta {
  max-width: 360px;
  width: 100%;
  margin: 0 auto var(--s-6);
  display: flex; flex-direction: column; align-items: stretch; gap: var(--s-3);
}
/* Force the register/sign-in row inside .public-cta to centre its content
   (the .btn base is inline-flex without justify-content, so on a stretched
   flex child the text sits at the left). Match the Google button. */
.public-cta .btn,
.public-cta .btn-google {
  width: 100%;
  justify-content: center;
}
.btn-google {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 13px 22px;
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-hi);
  font: 600 14px/1 var(--font-sans);
  letter-spacing: -0.01em;
  transition: background 0.15s, border-color 0.15s;
}
.btn-google:hover { background: var(--surface-2); border-color: var(--accent); }
.public-divider {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.16em;
}
.public-divider::before, .public-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}
/* Desktop: lay the two auth buttons side by side (Google | or | Register) to
   save vertical space. Stacks on narrow screens (<600px). */
@media (min-width: 600px) {
  .public-cta {
    flex-direction: row;
    align-items: stretch;
    justify-content: center;
    max-width: 560px;
    gap: var(--s-3);
  }
  .public-cta .btn,
  .public-cta .btn-google {
    width: auto;
    flex: 1;
  }
  .public-cta .public-divider { flex: 0 0 auto; }
  .public-cta .public-divider::before,
  .public-cta .public-divider::after { display: none; }
}
.public-signin {
  margin-top: var(--s-4);
  font-size: 13px;
  color: var(--text-muted);
  text-align: center;
}
.public-signin a {
  color: var(--accent-text);
  font-weight: 600;
  transition: color 0.15s;
}
.public-signin a:hover { color: var(--blue-hi); }

/* What you get - stat tile row */
.public-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--s-3);
  margin: var(--s-9) 0;
}
.public-stat {
  padding: var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  text-align: left;
}
.public-stat-num {
  font-family: var(--font-mono);
  font-size: 36px;
  font-weight: 600;
  line-height: 1;
  color: var(--text);
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  margin-bottom: var(--s-3);
}
.public-stat-num .accent { color: var(--accent-text); }
.public-stat-label {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  margin-bottom: 6px;
}
.public-stat-desc {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-muted);
}

/* Section titles on the marketing page */
.public-block-head {
  text-align: center;
  margin: var(--s-10) auto var(--s-6);
  max-width: 680px;
}
.public-block-eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  margin-bottom: var(--s-3);
}
.public-block-title {
  font-size: clamp(28px, 3.5vw, 40px);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin-bottom: var(--s-3);
  color: var(--text);
}
.public-block-sub {
  font-size: 17px;
  line-height: 1.55;
  color: var(--text-muted);
}

/* Final CTA panel */
.public-final-cta {
  margin: var(--s-10) 0 var(--s-9);
  padding: var(--s-9) var(--s-6);
  background:
    radial-gradient(ellipse 70% 80% at center 40%, var(--blue-glow-soft), transparent 70%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 20px 48px -16px rgba(0,0,0,0.3);
}
.public-final-cta h2 {
  font-size: clamp(28px, 4vw, 44px);
  letter-spacing: -0.03em;
  margin-bottom: var(--s-3);
  max-width: 640px;
  margin-left: auto; margin-right: auto;
}
.public-final-cta p {
  font-size: 17px;
  line-height: 1.55;
  color: var(--text-muted);
  max-width: 520px;
  margin: 0 auto var(--s-5);
}

@media (max-width: 640px) {
  .public-hero { padding: var(--s-8) 0 var(--s-6); }
  .public-cta { padding: 0 var(--s-4); }
  .public-final-cta { padding: var(--s-7) var(--s-4); }
}

/* Section Complete — earned moment. Cursor mark at scale with ambient blue glow.
   One of the few places in the system that keeps a gradient (signature moment).
   Hidden by default; script.js adds .is-visible when every checklist item in
   the section is ticked, fading the card in with a gentle rise. */
.section-complete {
  margin: var(--s-7) 0;
  padding: var(--s-8) var(--s-6);
  background:
    radial-gradient(ellipse 60% 70% at center 40%, var(--blue-glow-soft), transparent 70%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 2px 8px rgba(0,0,0,0.2);
  display: none;
}
.section-complete.is-visible {
  display: block;
  animation: sectionCompleteRise 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes sectionCompleteRise {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Grid-stack: checklist and section-complete card share the same grid
   cell. When the card is visible the checklist is simply hidden — no
   hover-peek, no toggling, no layout shift. The card now carries its
   own reset button, which is the only way back to the in-progress
   state. Keeps the UX linear and obvious. */
.checklist-complete-stack {
  display: grid;
  grid-template-areas: "stack";
  margin: var(--s-5) 0;
}
.checklist-complete-stack > .checklist,
.checklist-complete-stack > .section-complete {
  grid-area: stack;
  margin: 0; /* wrapper owns vertical rhythm */
}
.checklist-complete-stack:has(.section-complete.is-visible) > .checklist {
  display: none;
}

/* Mini section-read completion card — same treatment as section-complete
   but smaller (no section title — just the mark + "SECTION READ" label
   + meta). Used inside the read-complete-stack wrapper around the
   Finished-reading? toggle card. */
.section-read-complete {
  padding: var(--s-5) var(--s-5);
  background:
    radial-gradient(ellipse 60% 80% at center 40%, var(--blue-glow-soft), transparent 70%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 2px 8px rgba(0,0,0,0.2);
  display: none;
}
.section-read-complete .section-complete-mark {
  width: 48px;
  height: 48px;
  margin: 0 auto var(--s-2);
  color: var(--accent);
  filter: drop-shadow(0 0 16px var(--blue-glow));
  display: grid;
  place-items: center;
}
.section-read-complete .section-complete-mark svg {
  width: 48px;
  height: 48px;
}
.section-read-complete .section-complete-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.22em;
  margin-bottom: 4px;
}
.section-read-complete .section-complete-meta {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}
.section-read-complete.is-visible {
  display: block;
  animation: sectionCompleteRise 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Same stack-and-hide pattern as the main completion card. When the
   mini read-complete is visible, hide the toggle card underneath it.
   The "Mark unread" button in the card is the only way back. */
.read-complete-stack {
  display: grid;
  grid-template-areas: "stack";
  margin: var(--s-5) 0;
}
.read-complete-stack > .section-read-card,
.read-complete-stack > .section-read-complete {
  grid-area: stack;
  margin: 0;
}
.read-complete-stack:has(.section-read-complete.is-visible) > .section-read-card {
  display: none;
}
.section-complete-mark {
  width: 96px; height: 96px;
  margin: 0 auto var(--s-4);
  color: var(--accent);
  filter: drop-shadow(0 0 32px var(--blue-glow));
  display: grid; place-items: center;
}
.section-complete-mark img,
.section-complete-mark svg {
  width: 96px; height: 96px;
}
.section-complete-label {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.22em;
  margin-bottom: var(--s-2);
}
.section-complete-title {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: var(--s-3);
}
.section-complete-meta {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

/* ==========================================================================
   Hero banner — full-bleed image at the top of a section (currently used
   on Before You Start). Was rendering as a raw <img> with no framing.
   Treat it as a proper designed banner: rounded corners, subtle border
   + shadow to match other surface cards, fixed aspect ratio so it scales
   predictably, and a soft bottom fade so it grounds into the dark theme
   instead of cutting off at a hard edge.
   ========================================================================== */
/* Closing section author portrait — small circular headshot above the
   "Rob" signature. Was rendering at natural image size (uncropped,
   rectangular). */
.author-photo {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  overflow: hidden;
  margin: var(--s-7) 0 var(--s-3);
  border: 2px solid var(--border-hi);
  box-shadow: 0 0 0 1px var(--border), 0 8px 24px -8px rgba(0,0,0,0.4);
}
.author-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-banner {
  position: relative;
  margin: var(--s-6) 0 var(--s-7);
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 8px 28px -10px rgba(0,0,0,0.45);
  background: var(--surface);
  aspect-ratio: 3 / 1;
  /* Soft fade at the bottom so the image reads as part of the dark page,
     not a cropped edge. Pseudo-element overlay; pointer-events:none keeps
     the image below clickable if we ever wrap it in an <a>. */
}
.hero-banner::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 35%;
  background: linear-gradient(to bottom, transparent, rgba(13, 13, 18, 0.55));
  pointer-events: none;
}
.hero-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: grayscale(1);   /* v4: black-and-white portrait treatment (matches home) */
}
@media (max-width: 640px) {
  /* Slightly taller aspect on phones so faces don't get cropped. */
  .hero-banner { aspect-ratio: 16 / 9; margin: var(--s-5) 0 var(--s-6); }
}

/* ==========================================================================
   Health Check CTA card — closes a section with a push to the diagnostic.
   Used at the end of foundational sections (Before You Start, Retention,
   Exit Readiness, etc.) where the reader's just absorbed the framework
   and is at peak intent for self-scoring against it.
   Visual sibling of .section-complete: similar surface + glow, but with a
   left-aligned reading column and an explicit primary CTA inside.
   ========================================================================== */
.hc-cta-card {
  margin: var(--s-7) 0;
  padding: var(--s-7) var(--s-6);
  background:
    radial-gradient(ellipse 70% 80% at left top, var(--blue-glow-soft), transparent 65%),
    var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--r-lg);
  position: relative;
  overflow: hidden;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 2px 8px rgba(0,0,0,0.2);
}
.hc-cta-kicker {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  margin-bottom: var(--s-3);
}
.hc-cta-title {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: var(--s-3);
  line-height: 1.25;
}
.hc-cta-body {
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.6;
  margin-bottom: var(--s-5);
  max-width: 640px;
}
.hc-cta-body p { margin: 0 0 var(--s-3); }
.hc-cta-body p:last-child { margin: 0; }
.hc-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 22px;
  background: var(--accent);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  font: 600 14px/1 var(--font-sans);
  letter-spacing: -0.005em;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s, box-shadow 0.2s;
}
.hc-cta-btn:hover {
  background: var(--blue-hi);
  box-shadow: 0 8px 24px -8px var(--blue-glow-soft);
}
.hc-cta-btn:active { transform: translateY(1px); }
@media (max-width: 640px) {
  .hc-cta-card { padding: var(--s-6) var(--s-5); }
  .hc-cta-title { font-size: 19px; }
  .hc-cta-btn { width: 100%; justify-content: center; }
}

/* Section aside */
.section-aside {
  position: sticky;
  top: 80px;
  align-self: start;
  font-size: 13px;
}
.aside-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: var(--s-3);
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}
.aside-toc { list-style: none; margin: 0 0 var(--s-6); padding: 0; }
.aside-toc li {
  padding: 8px 0;
  border-left: 1px solid var(--border);
  padding-left: 14px;
  margin-left: 0;
  transition: border-color 0.15s, color 0.15s;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 13px;
  line-height: 1.5;
}
.aside-toc li:hover { color: var(--text); border-left-color: var(--border-hi); }
.aside-toc li.active {
  color: var(--accent-text);
  border-left: 2px solid var(--accent);
  padding-left: 13px;
  font-weight: 500;
}
.aside-nav { display: grid; gap: 8px; }
.aside-nav a {
  padding: 12px var(--s-4);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  display: flex; flex-direction: column; gap: 4px;
  transition: border-color 0.15s, background 0.15s;
  text-decoration: none;
}
.aside-nav a:hover {
  border-color: var(--accent);
  background: var(--surface-2);
}
/* Same label + title treatment as the inline mobile nav — so the two
   surfaces read as the same component in different slots. Blue mono
   kicker + bold sans title. */
.aside-nav .section-nav-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}
.aside-nav .section-nav-title {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.005em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
/* Legacy .arr — kept for any non-migrated callers */
.aside-nav .arr {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

/* Inline prev/next nav — mobile fallback for when .section-aside is
   hidden (≤960px). Shown inside the body content, right above the
   read-toggle + checklist, so mobile users get section-to-section
   navigation at the natural "I'm done here" moment. */
.section-nav-inline {
  display: none; /* hidden on desktop — sidebar covers nav there */
  grid-template-columns: 1fr 1fr;
  gap: var(--s-3);
  margin: var(--s-7) 0 var(--s-5);
}
.section-nav-inline .section-nav-prev,
.section-nav-inline .section-nav-next {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: var(--s-4);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  text-decoration: none;
  transition: border-color 0.15s, transform 0.15s, background 0.15s;
  min-width: 0;
}
.section-nav-inline .section-nav-prev:hover,
.section-nav-inline .section-nav-next:hover {
  border-color: var(--accent);
  background: var(--surface-2);
}
.section-nav-inline .section-nav-next { text-align: right; }
.section-nav-inline .section-nav-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}
.section-nav-inline .section-nav-title {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.005em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.section-nav-inline > span {
  /* Empty <span> placeholder for missing prev/next (first/last section) */
  display: none;
}
@media (max-width: 960px) {
  .section-nav-inline { display: grid; }
}

/* Progress bar */
.progress {
  position: fixed; top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--border);
  z-index: 40;
}
.progress-bar {
  height: 100%;
  width: 28%;
  background: linear-gradient(90deg, var(--accent), var(--accent-hi));
  box-shadow: 0 0 10px var(--accent-glow);
}

/* Return-to-studies banner */
.study-banner {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 10px 32px;
  display: flex; align-items: center; gap: var(--s-4);
  font-size: 12px;
  color: var(--text-muted);
  position: relative; z-index: 50;
}
.study-banner .mono-label { color: var(--accent-text); }
.study-banner a {
  color: var(--text-muted);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--border-hi);
  transition: color 0.15s, text-decoration-color 0.15s;
}
.study-banner a:hover { color: var(--text); text-decoration-color: var(--accent); }
.study-banner .spacer { flex: 1; }

/* =========================================================================
   My Brand Dashboard
   ========================================================================= */
.brand-head {
  padding: var(--s-8) 0 var(--s-6);
}
.brand-greeting {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: 10px;
}
.brand-title {
  font-size: 40px;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
  margin-bottom: 8px;
}
.brand-tagline {
  font-size: 15px;
  color: var(--text-muted);
}

/* Score panel — slightly richer treatment (this IS the primary dashboard moment) */
.score-panel {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: var(--s-6);
  background:
    radial-gradient(ellipse 50% 80% at left center, var(--blue-glow-soft), transparent 60%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: var(--s-7) var(--s-6);
  margin: var(--s-6) 0;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 12px 32px -12px rgba(0,0,0,0.3);
}
@media (max-width: 820px) {
  .score-panel { grid-template-columns: 1fr; }
}
.score-ring {
  width: 180px; height: 180px;
  margin: 0 auto var(--s-3);
  position: relative;
  display: grid; place-items: center;
}
.score-ring-svg { transform: rotate(-90deg); width: 180px; height: 180px; }
.score-ring-bg { fill: none; stroke: var(--border); stroke-width: 8; }
.score-ring-fg { fill: none; stroke: url(#ringGrad); stroke-width: 8; stroke-linecap: round; }
.score-ring-value {
  position: absolute;
  font: 800 44px/1 var(--font-sans);
  color: var(--text);
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.score-ring-pct {
  position: absolute;
  bottom: 46px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.score-panel-left { text-align: center; padding: var(--s-3) 0; }
.score-rating {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: 4px;
}
.score-note { font-size: 13px; color: var(--text-muted); }

.cat-bars { display: flex; flex-direction: column; gap: 10px; }
.cat-bar {
  display: grid;
  grid-template-columns: 180px 1fr 60px;
  gap: var(--s-3);
  align-items: center;
}
.cat-bar-label { font-size: 13px; color: var(--text); font-weight: 500; }
.cat-bar-track {
  height: 10px;
  background: var(--surface-2);
  border-radius: 5px;
  overflow: hidden;
  position: relative;
}
.cat-bar-fill {
  height: 100%;
  border-radius: 5px;
  background: var(--bar-color, var(--accent));
  box-shadow: 0 0 12px -2px var(--bar-glow, var(--blue-glow-soft));
}
.cat-bar-val {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  text-align: right;
  font-weight: 500;
}
.cat-bar[data-score="high"] { --bar-color: var(--ok); --bar-glow: var(--ok-glow); }
.cat-bar[data-score="mid"] { --bar-color: var(--warn); --bar-glow: var(--warn-glow); }
.cat-bar[data-score="low"] { --bar-color: var(--err); --bar-glow: var(--err-glow); }

/* Stat tiles — slightly more spaced */
.stat-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--s-3);
  margin: var(--s-6) 0;
}
.stat-tile {
  padding: var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
}
.stat-tile-label {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  margin-bottom: 10px;
}
.stat-tile-value {
  font-family: var(--font-mono);
  font-size: 28px;
  font-weight: 600;
  line-height: 1;
  color: var(--text);
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  margin-bottom: 4px;
}
.stat-tile-hint {
  font-size: 12px;
  color: var(--text-muted);
}

/* Recs section */
.recs { display: grid; gap: var(--s-3); margin: var(--s-5) 0; }
.rec-card {
  padding: var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 2px solid var(--rec-color, var(--accent));
  border-radius: var(--r-md);
  display: grid;
  grid-template-columns: 140px 1fr auto;
  gap: var(--s-4);
  align-items: center;
}
@media (max-width: 720px) {
  .rec-card { grid-template-columns: 1fr; }
}
.rec-card[data-priority="high"] { --rec-color: var(--err); }
.rec-card[data-priority="mid"] { --rec-color: var(--warn); }
.rec-card[data-priority="low"] { --rec-color: var(--ok); }
.rec-category {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}
.rec-title { font-size: 15px; font-weight: 600; color: var(--text); margin-bottom: 4px; letter-spacing: -0.005em; }
.rec-desc { font-size: 13px; color: var(--text-muted); line-height: 1.55; }
.rec-cta {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  white-space: nowrap;
}

/* Checklist overview (per-section progress) */
.chk-overview { margin: var(--s-5) 0; }
.chk-overview-head {
  display: flex; align-items: baseline; justify-content: space-between;
  padding-bottom: var(--s-3);
  border-bottom: 1px solid var(--border);
  margin-bottom: var(--s-4);
}
.chk-overview-title { font-size: 17px; font-weight: 600; color: var(--text); letter-spacing: -0.01em; }
.chk-overview-meta { font-family: var(--font-mono); font-size: 11px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.14em; }

.chk-sections { display: grid; gap: 2px; }
.chk-section {
  display: grid;
  grid-template-columns: 260px 1fr 80px;
  gap: var(--s-3);
  padding: 10px var(--s-3);
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  font-size: 13px;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.chk-section:hover { border-color: var(--border-hi); background: var(--surface-2); }
.chk-section-name { color: var(--text); font-weight: 500; display: flex; align-items: center; gap: 8px; }
.chk-section-name .tag {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  min-width: 40px;
}
.chk-section-track {
  height: 6px;
  background: var(--surface-2);
  border-radius: 3px;
  overflow: hidden;
}
.chk-section-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-hi));
  border-radius: 3px;
}
.chk-section-val {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
  text-align: right;
}

/* Team table */
.team-table {
  margin: var(--s-5) 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  overflow: hidden;
}
.team-row {
  display: grid;
  grid-template-columns: 40px 1fr 120px auto;
  gap: var(--s-3);
  align-items: center;
  padding: 12px var(--s-4);
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}
.team-row:last-child { border-bottom: none; }
.team-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-hi), var(--accent-deep));
  display: grid; place-items: center;
  color: white; font: 700 13px/1 var(--font-sans);
}
.team-meta-name { color: var(--text); font-weight: 600; }
.team-meta-email { font-size: 12px; color: var(--text-dim); font-family: var(--font-mono); }
/* Owner-only remove control on other members' rows (2026-07-16 review M3). */
.team-remove { font: 600 12px/1 var(--font-sans); padding: 7px 12px; border-radius: 8px; border: 1px solid var(--border); background: transparent; color: var(--text-dim); cursor: pointer; justify-self: end; transition: border-color .15s ease, color .15s ease; }
.team-remove:hover { border-color: rgba(220,38,38,0.5); color: #F87171; }
.team-remove:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.team-role {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  padding: 4px 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 4px;
  text-align: center;
}
.team-remove {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  background: none;
  border: 1px solid var(--border);
  padding: 6px 10px;
  border-radius: var(--r-sm);
  transition: color 0.15s, border-color 0.15s;
}
.team-remove:hover { color: var(--err); border-color: var(--err); }

/* Section header for dashboard panels — more breathing room between each */
.panel {
  margin: var(--s-9) 0 var(--s-5);
  padding-bottom: var(--s-4);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-4);
}
.panel-title { font-size: 22px; font-weight: 700; color: var(--text); letter-spacing: -0.02em; }
.panel-sub { font-size: 12px; color: var(--text-dim); font-family: var(--font-mono); text-transform: uppercase; letter-spacing: 0.14em; font-weight: 500; }
.panel-sub-link { color: var(--accent-text); font-weight: 600; white-space: nowrap; transition: color 0.15s; }
.panel-sub-link:hover { color: var(--accent); }

/* Brand Dashboard tool downloads — restored after the V3 rewrite dropped
   them. Each card is a static .xlsx download from /tools/. Vertical-stack
   layout (icon + .xlsx pill on top, then title, desc, download CTA below)
   so title + description get full card width. Auto-fits 2-3 columns based
   on viewport. Distinct from the Section content `.tool-card` pattern
   which is for tool *recommendations*. */
.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--s-4);
  margin-bottom: var(--s-5);
}
.tool-dl-card {
  display: flex;
  flex-direction: column;
  padding: var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  text-decoration: none;
  color: inherit;
  position: relative;
  transition: border-color 0.15s, transform 0.15s, box-shadow 0.2s;
}
.tool-dl-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 10px 28px -10px rgba(0,0,0,0.45);
}
.tool-dl-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--s-4);
}
.tool-dl-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: rgba(34, 197, 94, 0.10);
  color: #22c55e;
  flex-shrink: 0;
}
.tool-dl-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.14em;
}
.tool-dl-title {
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.015em;
  line-height: 1.25;
  margin-bottom: var(--s-2);
}
.tool-dl-desc {
  font-size: 13.5px;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: var(--s-4);
  flex: 1; /* push the CTA to the bottom of the card */
}
.tool-dl-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-text);
  letter-spacing: -0.005em;
  align-self: flex-start;
  transition: gap 0.15s, color 0.15s;
}
.tool-dl-cta svg { transition: transform 0.15s; }
.tool-dl-card:hover .tool-dl-cta {
  color: var(--blue-hi);
  gap: 12px;
}
.tool-dl-card:hover .tool-dl-cta svg { transform: translateY(1px); }

/* ============================================================
   Share tiles — shared component used by the dashboard's
   "Share the Health Check" panel and (future) in-section share
   blocks. Inline-icon + label pill with hover lift, mirrors the
   footer social-link pattern but at CTA scale.
   ============================================================ */
.share-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
  margin: 0 0 var(--s-5);
}
.share-tile {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  color: var(--text-muted);
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.005em;
  text-decoration: none;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s, transform 0.15s, background 0.15s;
}
.share-tile:hover {
  border-color: var(--border-hi);
  color: var(--text);
  background: var(--surface-2);
  transform: translateY(-1px);
}
.share-tile-icon {
  flex-shrink: 0;
  opacity: 0.75;
  transition: opacity 0.15s;
}
.share-tile:hover .share-tile-icon {
  opacity: 1;
}
.share-tile-label {
  flex: 1;
}
/* Copy-link feedback states (set by copyHcShareLink helper) */
.share-tile.is-copied {
  border-color: rgba(74,222,128,0.45);
  color: #4ADE80;
}
.share-tile.is-copied .share-tile-icon { opacity: 1; color: #4ADE80; }
.share-tile.is-error {
  border-color: rgba(239,68,68,0.45);
  color: #fca5a5;
}

/* End-of-section share block — appears after the checklist on every
   content section. Wraps the .share-tiles grid in a header + prose
   intro. Top border separates it from the content above. */
.section-share-block {
  margin: var(--s-7) 0 var(--s-5);
  padding-top: var(--s-6);
  border-top: 1px solid var(--border);
}
.section-share-head {
  max-width: 560px;
  margin: 0 auto var(--s-4);
  text-align: center;
}
.section-share-kicker {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 8px;
}
.section-share-title {
  font: 700 22px/1.3 var(--font-head);
  color: var(--text);
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}
.section-share-desc {
  font: 14px/1.55 var(--font-sans);
  color: var(--text-muted);
  margin: 0;
}
.section-share-block .share-tiles {
  max-width: 720px;
  margin: 0 auto;
}

/* Sidebar (.section-aside) compact share — icon-only buttons in a
   horizontal row. Sits below the Navigate / prev / next stack. */
.aside-share-tiles {
  display: flex;
  gap: 6px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.aside-share-tile {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  color: var(--text-muted);
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s, transform 0.15s, background 0.15s;
  text-decoration: none;
}
.aside-share-tile:hover {
  border-color: var(--border-hi);
  color: var(--text);
  background: var(--surface-2);
  transform: translateY(-1px);
}
.aside-share-tile svg { opacity: 0.85; transition: opacity 0.15s; }
.aside-share-tile:hover svg { opacity: 1; }
/* Copy feedback states for aside variant (label-less; the SVG colour
   shifts to signal success/failure since there's no text to swap) */
.aside-share-tile.is-copied {
  border-color: rgba(74,222,128,0.45);
  color: #4ADE80;
}
.aside-share-tile.is-error {
  border-color: rgba(239,68,68,0.45);
  color: #fca5a5;
}

/* Utility */
.muted { color: var(--text-muted); }
.dim { color: var(--text-dim); }
.row { display: flex; align-items: center; gap: var(--s-3); }
.row--between { justify-content: space-between; }

/* Responsive */
@media (max-width: 960px) {
  .section-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
  .nav { display: none; }
  .cmdbar { min-width: auto; }
  .cmdbar-text { display: none; }
}
@media (max-width: 640px) {
  .section-grid { grid-template-columns: 1fr; }
  .container { padding: 0 var(--s-4); }
  .hero { padding: var(--s-7) 0 var(--s-6); }
  .topbar-inner { padding: 12px var(--s-4); flex-wrap: wrap; }
  .study-banner { padding: 8px var(--s-4); font-size: 11px; }
  .study-banner .spacer { display: none; }
  .score-panel { grid-template-columns: 1fr; padding: var(--s-4); }
  .cat-bar { grid-template-columns: 120px 1fr 44px; }
  .rec-card { grid-template-columns: 1fr; }
  .chk-section { grid-template-columns: 140px 1fr 50px; }
}

/* ==========================================================================
   PRODUCTION ADDITIONS — Midnight Signal 2.0
   Rules not present in v3/styles.css because mock is standalone.
   Kept minimal; lives after the canonical block so nothing overrides V3.
   ========================================================================== */

/* Legacy var aliases — kept for JS-rendered HTML that still uses old token
   names. Post-rebuild cleanup removes these. */
:root {
  --primary:    var(--text);
  --muted:      var(--text-dim);
  --card:       var(--surface);
  --accent2:    var(--accent-text);
  --accent-secondary: var(--accent-text);
  --sidebar-w:  0;
  --header-h:   56px;
  --font-head:  var(--font-sans);
  --font-body:  var(--font-sans);
  --ease:       cubic-bezier(0.16, 1, 0.3, 1);
  --radius-sm:  var(--r-sm);
  --radius-md:  var(--r-md);
  --radius-lg:  var(--r-lg);
}

/* Page-level wrappers used by production SPA views */
.main { position: relative; z-index: 1; min-height: calc(100vh - var(--header-h)); padding-top: 0; padding-bottom: var(--s-9); }
.content-area { max-width: 1280px; margin: 0 auto; padding: 0 var(--s-4); }
#view-toc, #view-chapters, #view-healthcheck, #view-brand-admin, #view-landing, #view-profile-complete { position: relative; z-index: 1; }

/* Progress bar */
#progress-bar { position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 1100; background: transparent; pointer-events: none; }
#progress-bar .progress-fill { height: 100%; background: var(--accent); width: 0%; transition: width 0.15s linear; border-radius: 0 2px 2px 0; }

/* Password gate overlay full-screen */
#pw-gate { position: fixed; inset: 0; z-index: 9999; background: var(--bg); overflow-y: auto; display: block; padding: 0; }
#pw-gate.hidden { display: none; }
body:has(#pw-gate:not(.hidden)) { overflow: hidden !important; }
body:has(#pw-gate:not(.hidden)) .topbar { display: none !important; }

/* Hide topbar when auth overlay is open. The overlay lives inside <main>
   which creates a z-index:1 stacking context, trapping the overlay below
   the sticky topbar (z:50). Hiding the topbar avoids the modal title
   getting clipped behind it on mobile. */
body:has(.auth-overlay.is-open) .topbar { display: none !important; }

/* Auth overlay — positioning + panel only; V3 covers input/button styles */
/* Defensive base state: pointer-events:none so the full-viewport backdrop
   (z-index 8000, position absolute, inset 0) can never intercept clicks
   when the overlay isn't actively .is-open — even if a stale handler left
   inline display:flex hanging. The .is-open rule below restores
   interaction. Eliminates the "click-stuck" class of bugs. */
.auth-overlay { position: fixed; inset: 0; z-index: 8000; align-items: center; justify-content: center; padding: var(--s-5); display: none; pointer-events: none; }
.auth-overlay.is-open, .auth-overlay[style*="flex"] { display: flex; pointer-events: auto; }
.auth-overlay .auth-backdrop { position: absolute; inset: 0; background: rgba(12,13,17,0.88); backdrop-filter: blur(12px) saturate(1.2); z-index: 0; }
.auth-overlay .auth-panel { position: relative; z-index: 1; width: 100%; max-width: 440px; max-height: calc(100vh - 32px); overflow-y: auto; padding: var(--s-7) var(--s-6); background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: 0 1px 0 rgba(255,255,255,0.06) inset, 0 40px 80px -16px rgba(0,0,0,0.6); }
.auth-overlay .auth-close { position: absolute; top: var(--s-3); right: var(--s-3); background: transparent; border: none; color: var(--text-dim); font-size: 24px; cursor: pointer; line-height: 1; padding: 4px 10px; border-radius: 6px; transition: color 0.15s, background 0.15s; }
.auth-overlay .auth-close:hover { color: var(--text); background: var(--surface-2); }
.auth-overlay .auth-state { display: none; }
.auth-overlay .auth-state.is-active { display: block; }
.auth-overlay .auth-head { text-align: center; margin-bottom: var(--s-5); }
.auth-overlay .auth-head h2 { font-family: var(--font-sans); font-size: 24px; font-weight: 700; letter-spacing: -0.02em; color: var(--text); margin: 0 0 6px; line-height: 1.2; }
.auth-overlay .auth-head p { font-size: 14px; color: var(--text-muted); margin: 0; line-height: 1.55; }
.auth-overlay .auth-form { display: flex; flex-direction: column; gap: var(--s-3); margin: 0; }
.auth-overlay .auth-field { display: flex; flex-direction: column; gap: 6px; }
.auth-overlay .auth-field-label { font-family: var(--font-mono); font-size: 10px; font-weight: 600; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.16em; }
.auth-overlay .auth-field-input { padding: 12px 14px; background: var(--bg); border: 1px solid var(--border); border-radius: 8px; color: var(--text); font-size: 14px; font-family: var(--font-sans); transition: border-color 0.15s, box-shadow 0.15s; width: 100%; box-sizing: border-box; }
.auth-overlay .auth-field-input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--blue-glow-soft); }
.auth-overlay .auth-field-input::placeholder { color: var(--text-ghost); }
.auth-overlay .auth-forgot { align-self: flex-end; font-size: 12px; color: var(--text-dim); text-decoration: none; margin-top: -4px; transition: color 0.15s; }
.auth-overlay .auth-forgot:hover { color: var(--accent-text); }
.auth-overlay .auth-submit { display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 13px 22px; border-radius: 10px; background: var(--accent); color: #fff; border: 1px solid rgba(255,255,255,0.1); font: 600 14px/1 var(--font-sans); letter-spacing: -0.005em; cursor: pointer; transition: background 0.15s, box-shadow 0.25s; box-shadow: 0 8px 24px -6px var(--blue-glow), 0 0 0 1px rgba(255,255,255,0.06) inset; margin-top: var(--s-2); }
.auth-overlay .auth-submit:hover { background: var(--accent-hi); }
.auth-overlay .auth-inline-success { margin-top: var(--s-3); padding: var(--s-3); background: color-mix(in srgb,var(--ok) 10%,transparent); border: 1px solid color-mix(in srgb,var(--ok) 40%,transparent); border-radius: 8px; color: var(--ok); font-size: 13px; text-align: center; }
.auth-overlay .auth-inline-error { margin-top: var(--s-3); padding: var(--s-3); background: color-mix(in srgb,var(--err) 10%,transparent); border: 1px solid color-mix(in srgb,var(--err) 40%,transparent); border-radius: 8px; color: var(--err); font-size: 13px; text-align: center; }
.auth-overlay .auth-divider { display: flex; align-items: center; gap: var(--s-3); margin: var(--s-5) 0; font-family: var(--font-mono); font-size: 10px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.16em; }
.auth-overlay .auth-divider::before, .auth-overlay .auth-divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.auth-overlay .auth-google { display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 12px 22px; border-radius: 10px; background: var(--surface-2); color: var(--text); border: 1px solid var(--border-hi); font: 600 14px/1 var(--font-sans); letter-spacing: -0.005em; cursor: pointer; transition: background 0.15s, border-color 0.15s; width: 100%; }
.auth-overlay .auth-google:hover { background: var(--surface); border-color: var(--accent); }
.auth-overlay .auth-consent { display: flex; align-items: flex-start; gap: 12px; margin-top: var(--s-3); font-size: 12px; color: var(--text-dim); line-height: 1.5; }
.auth-overlay .auth-consent input { margin-top: 2px; accent-color: var(--accent); cursor: pointer; flex-shrink: 0; }
.auth-overlay .auth-consent a { color: var(--text-muted); text-decoration: underline; }
.auth-overlay .auth-switch { margin-top: var(--s-5); text-align: center; font-size: 13px; color: var(--text-muted); padding-top: var(--s-4); border-top: 1px solid var(--border); }
.auth-overlay .auth-switch a { color: var(--accent-text); font-weight: 600; text-decoration: none; transition: color 0.15s; cursor: pointer; }
.auth-overlay .auth-switch a:hover { color: var(--blue-hi); }
@media (max-width: 540px) {
  .auth-overlay .auth-panel { padding: var(--s-5) var(--s-4); }
  .auth-overlay .auth-head h2 { font-size: 20px; }
}

/* Mobile nav overlay (burger opens a full-page nav) */
#mobile-nav-overlay { position: fixed; inset: 0; z-index: 900; background: var(--bg); display: none; overflow-y: auto; padding: var(--s-6) var(--s-4); }
#mobile-nav-overlay.open { display: block; }
#mobile-nav-overlay .mobile-nav-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: var(--s-6); padding: 0 var(--s-2); }
#mobile-nav-overlay .mobile-nav-close { background: transparent; border: none; color: var(--text); font-size: 28px; cursor: pointer; line-height: 1; padding: 4px 12px; }
#mobile-nav-overlay .mobile-nav-section { margin-bottom: var(--s-4); }
#mobile-nav-overlay .mobile-nav-section a { display: block; padding: var(--s-3) var(--s-4); color: var(--text); border-radius: var(--r-md); margin-bottom: 4px; text-decoration: none; font-size: 15px; }
#mobile-nav-overlay .mobile-nav-section a:hover { background: var(--surface-2); }

/* SPA view switching — script.js manages display via inline style.
   Every chapter emits inline style="display:none"; showSection clears the
   inline to reveal. Don't add a .chapter {display:none} rule here — it
   would defeat the inline-clear pattern. */

/* Topbar burger — appears at the SAME breakpoint that hides the topbar
   nav (960px), so there's never a dead zone where users have neither the
   nav links nor the burger. Previously: nav hid at 960px, burger appeared
   at 720px → 240px window of invisible navigation. */
.topbar-burger { display: none; background: transparent; border: none; color: var(--text); padding: 8px; cursor: pointer; margin-left: auto; }
@media (max-width: 960px) {
  .topbar-burger { display: inline-flex; align-items: center; }
  .topbar .nav { display: none; }
  .topbar .nav-search { display: none; }
  #auth-signin-btn, #auth-user-menu { display: none !important; }
}

/* Auth user menu + dropdown (lives in topbar) */
.auth-user-menu { position: relative; display: none; }
.auth-user-name { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; background: var(--surface); border: 1px solid var(--border-hi); border-radius: 8px; color: var(--text); font: 600 13px/1 var(--font-sans); cursor: pointer; transition: background 0.15s, border-color 0.15s; }
.auth-user-name:hover { background: var(--surface-2); border-color: var(--accent); }
.auth-user-name::after { content: "▾"; font-size: 10px; color: var(--text-dim); margin-left: 2px; }
.auth-dropdown { position: absolute; top: calc(100% + 6px); right: 0; background: var(--surface); border: 1px solid var(--border-hi); border-radius: var(--r-md); min-width: 140px; padding: 4px; box-shadow: 0 12px 32px -8px rgba(0,0,0,0.4); z-index: 60; }
.auth-dropdown a { display: block; padding: 10px 14px; color: var(--text-muted); font-size: 13px; text-decoration: none; border-radius: var(--r-sm); transition: background 0.15s, color 0.15s; }
.auth-dropdown a:hover { background: var(--surface-2); color: var(--text); }

/* Intro animation helper (lives on <html>) — controls masthead/pitch transitions */
html.intro-playing .public-masthead { position: fixed; inset: 0; z-index: 100; background: var(--bg); padding: var(--s-6); min-height: 0; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; animation: mastheadExit 2.6s cubic-bezier(0.4,0,0.2,1) forwards; }
html.intro-playing .public-pitch { opacity: 0; transform: translateY(24px); animation: pitchEnter 1.4s 2.4s cubic-bezier(0.16,1,0.3,1) forwards; }
html.intro-playing .topbar { opacity: 0; transform: translateY(-8px); animation: headerEnter 1s 3.0s cubic-bezier(0.16,1,0.3,1) forwards; }
@keyframes mastheadExit { 0%,50% { opacity: 1; transform: translateY(0); } 100% { opacity: 0; transform: translateY(-40px); pointer-events: none; } }
@keyframes pitchEnter { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }
@keyframes headerEnter { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) {
  html.intro-playing .public-masthead, html.intro-playing .public-pitch, html.intro-playing .topbar { animation: none !important; opacity: 1 !important; transform: none !important; }
}

/* Public masthead (default state — hidden outside intro) */
.public-masthead { display: none; }
.public-zone-divider { display: none; }

/* ============================================================
   Gate SEO below-fold content (restored from pre-MS-2.0 head.html)
   Classes: .gate-seo, .stats-bar, .seo-features, .big-quote,
   .section-viz, .section-typewriter, .section-card (gate variant)
   ============================================================ */
/* Section dividers */
.gate-seo .seo-divider-auto{width:100%;height:1px;background:linear-gradient(90deg,transparent 0%,rgba(32,128,212,0.25) 50%,transparent 100%);margin:56px auto;border-radius:1px}
/* Animated section headers */
.section-viz{width:100%;height:100px;margin:0 0 -4px;display:flex;align-items:center;justify-content:center}
/* The revenue chart sits between the "Built From Experience" heading and the
   bio copy, so it needs real breathing room (the base viz margin is ~0). */
.section-viz.section-viz--chart{height:180px;margin-top:var(--s-6);margin-bottom:var(--s-6)}
.section-viz.section-viz--chart svg{height:180px}
#pw-gate.js-animate .section-viz{opacity:0;transform:translateY(24px);transition:opacity 0.8s cubic-bezier(0.16,1,0.3,1),transform 0.8s cubic-bezier(0.16,1,0.3,1)}
.section-viz.is-visible{opacity:1;transform:translateY(0)}
.section-viz svg{width:100%;height:100px;overflow:visible}
/* Typewriter header */
.section-typewriter{width:100%;height:48px;margin:0 0 -4px;display:flex;align-items:center;justify-content:center;font-family:'JetBrains Mono',monospace;font-size:clamp(12px,2.5vw,15px);font-weight:500;letter-spacing:0.15em;text-transform:uppercase}
#pw-gate.js-animate .section-typewriter{opacity:0;transform:translateY(16px);transition:opacity 0.6s cubic-bezier(0.16,1,0.3,1),transform 0.6s cubic-bezier(0.16,1,0.3,1)}
.section-typewriter.is-visible{opacity:1;transform:translateY(0)}
.section-typewriter .tw-text{display:inline;border-right:2px solid #2080D4;padding-right:4px;animation:twBlink 0.7s step-end infinite}
@keyframes twBlink{0%,100%{border-color:#2080D4}50%{border-color:transparent}}
.section-viz .viz-line{fill:none;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:var(--dash-len,600);stroke-dashoffset:var(--dash-len,600);transition:stroke-dashoffset 1.4s cubic-bezier(0.16,1,0.3,1)}
.section-viz.is-visible .viz-line{stroke-dashoffset:0}
.section-viz .viz-dot{r:0;transition:r 0.4s cubic-bezier(0.16,1,0.3,1)}
.section-viz.is-visible .viz-dot{r:3}
.section-viz .viz-check{stroke-dasharray:20;stroke-dashoffset:20;transition:stroke-dashoffset 0.35s cubic-bezier(0.16,1,0.3,1)}
.section-viz.is-visible .viz-check{stroke-dashoffset:0}
.section-viz .viz-bar{transform:scaleY(0);transform-origin:bottom;transition:transform 0.5s cubic-bezier(0.16,1,0.3,1)}
.section-viz.is-visible .viz-bar{transform:scaleY(1)}
.section-viz .viz-slider{stroke-dasharray:300;stroke-dashoffset:300;transition:stroke-dashoffset 1s cubic-bezier(0.16,1,0.3,1)}
.section-viz.is-visible .viz-slider{stroke-dashoffset:0}
@media(max-width:768px){
  #pw-gate{padding:32px 16px 80px;justify-content:flex-start;box-sizing:border-box}
  #pw-gate .gate-inner{max-width:100%}
  #pw-gate .gate-two-col{flex-direction:column;gap:28px}
  #pw-gate .gate-col-left{width:100%}
  #pw-gate .gate-col-right{flex:none!important;width:100%!important;max-width:100%!important;border-left:none!important;padding-left:0!important;box-sizing:border-box;border-top:1px solid rgba(255,255,255,0.06);padding-top:28px}
  #pw-gate .gate-inner{max-width:100%;box-sizing:border-box}
  #pw-gate .gate-about{max-width:100%;margin-left:auto;margin-right:auto}
  #pw-gate .gate-logo-icon{width:90px!important}
  #pw-gate .gate-title{font-size:clamp(26px,8vw,36px)}
  #pw-gate .gate-subtitle{font-size:11px;letter-spacing:0.12em;margin-bottom:10px}
  #pw-gate .gate-author{font-size:10px;margin-bottom:20px}
  #pw-gate .gate-about-text{font-size:15px}
  #pw-gate .gate-about-label{font-size:10px}
  #pw-gate form{max-width:100%}
  #pw-gate .gate-fields{max-width:100%}
  /* Landing page mobile */
  #landing-hero-cols{flex-direction:column!important;gap:20px!important;padding:40px 16px 40px!important}
  #landing-right-col{flex:none!important;width:100%!important;border-left:none!important;padding-left:0!important}
  .gate-seo .seo-features{grid-template-columns:1fr}
}

.gate-seo{max-width:740px;margin:80px auto 0;padding:0 24px;color:#9CA3AF;font-family:'Inter',system-ui,sans-serif;text-align:left}
.gate-seo .seo-section-alt{padding:40px 0;margin:0 -24px;padding-left:24px;padding-right:24px;background:rgba(255,255,255,0.015);border-top:1px solid rgba(255,255,255,0.06);border-bottom:1px solid rgba(255,255,255,0.06)}
.gate-seo h2{font-family:'Inter',system-ui,sans-serif;font-size:clamp(22px,4vw,28px);font-weight:700;color:#E5E7EB;margin:56px 0 16px;letter-spacing:-0.03em}
.gate-seo h2.seo-h2-blue{color:#2080D4}
.gate-seo .seo-stat{color:#2080D4;font-weight:700}
.gate-seo h2:first-child{margin-top:0}
.gate-seo h3{font-family:'JetBrains Mono',monospace;font-size:11px;font-weight:500;color:#2080D4;margin:36px 0 16px;text-transform:uppercase;letter-spacing:0.15em;display:inline-block;padding:6px 16px;border:1px solid rgba(32,128,212,0.25);border-radius:8px;background:rgba(32,128,212,0.06)}
.gate-seo .seo-section-group h3{margin:24px 0 14px}
.gate-seo p{font-size:17px;line-height:1.8;margin:0 0 16px;color:#9CA3AF}
.gate-seo strong{color:#E5E7EB}
/* Link colour inside .gate-seo — accent blue for inline text links only.
   Buttons are excluded via :not() so .btn--primary retains its white text
   on blue background. Without this the bottom "Create Your Free Account"
   CTA rendered as blue text on blue button (invisible). */
.gate-seo a:not(.btn):not(.btn--primary):not(.btn--ghost):not(.btn-google){color:#2080D4;text-decoration:none;transition:color 0.3s cubic-bezier(0.16,1,0.3,1)}
.gate-seo a:not(.btn):not(.btn--primary):not(.btn--ghost):not(.btn-google):hover{color:#3D96E8;text-decoration:none}
.gate-seo .seo-sections{margin:24px 0}
.gate-seo .seo-section-group{margin:20px 0}
.gate-seo .seo-section-item{padding:8px 0 8px 16px;border-left:3px solid rgba(32,128,212,0.3);margin:8px 0}
.gate-seo .seo-section-item strong{color:#E5E7EB;font-size:14px}
.gate-seo .seo-section-item span{color:#7C8493;font-size:13px;display:block;margin-top:2px}
.gate-seo .stats-bar{position:relative;display:flex;justify-content:center;gap:48px;flex-wrap:wrap;margin:48px 0;padding:40px 20px;background:transparent;border:none;border-radius:0}

.gate-seo .stat-item{position:relative;z-index:1}
.gate-seo .stat-item{text-align:center;min-width:100px}
.gate-seo .stat-item .stat-num{font-family:'Inter',system-ui,sans-serif;font-size:clamp(28px,5vw,36px);font-weight:800;color:#2080D4;display:block;line-height:1.2;letter-spacing:-0.03em}
.gate-seo .stat-item .stat-label{font-family:'JetBrains Mono',monospace;font-size:10px;color:#7C8493;text-transform:uppercase;letter-spacing:0.15em;margin-top:6px;display:block}
.gate-seo .section-cards{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin:0 0 24px;align-items:start}
/* Landing: stretch cards to equal height within each row (cards in the
   same row share the tallest sibling's height). Fixes the uneven-height
   issue where cards aligned to their own content. Gate kept as start. */
#landing-seo-content .section-cards { align-items: stretch; }
/* Legacy gate section-card surface (flat gradient + category border-left).
   Scoped to #gate-seo-content so landing-public can use the new glow
   treatment. Remove this entire legacy block when gate.html is deleted. */
#gate-seo-content .section-card{padding:20px 20px 20px 24px;background:linear-gradient(135deg,rgba(32,128,212,0.06) 0%,transparent 60%);border:none;border-radius:0 12px 12px 0;display:flex;flex-direction:column;transition:transform 0.4s cubic-bezier(0.16,1,0.3,1),border-color 0.4s cubic-bezier(0.16,1,0.3,1),box-shadow 0.4s cubic-bezier(0.16,1,0.3,1),background 0.4s cubic-bezier(0.16,1,0.3,1)}
#gate-seo-content .section-card:hover{transform:translateY(-3px);box-shadow:0 8px 32px rgba(0,0,0,0.3),inset 3px 0 12px -4px rgba(32,128,212,0.3);background:linear-gradient(135deg,rgba(32,128,212,0.1) 0%,transparent 60%)}
/* Category-specific gradients (gate only) */
#gate-seo-content .section-card.cat-business{background:linear-gradient(135deg,rgba(32,128,212,0.06) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-business:hover{background:linear-gradient(135deg,rgba(32,128,212,0.12) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-growth{background:linear-gradient(135deg,rgba(22,163,74,0.06) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-growth:hover{background:linear-gradient(135deg,rgba(22,163,74,0.12) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-brand{background:linear-gradient(135deg,rgba(139,92,246,0.06) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-brand:hover{background:linear-gradient(135deg,rgba(139,92,246,0.12) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-retention{background:linear-gradient(135deg,rgba(245,158,11,0.06) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-retention:hover{background:linear-gradient(135deg,rgba(245,158,11,0.12) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-scale{background:linear-gradient(135deg,rgba(6,182,212,0.06) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-scale:hover{background:linear-gradient(135deg,rgba(6,182,212,0.12) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-numbers{background:linear-gradient(135deg,rgba(239,68,68,0.06) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-numbers:hover{background:linear-gradient(135deg,rgba(239,68,68,0.12) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-exit{background:linear-gradient(135deg,rgba(236,72,153,0.06) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-exit:hover{background:linear-gradient(135deg,rgba(236,72,153,0.12) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-foundation{background:linear-gradient(135deg,rgba(107,114,128,0.06) 0%,transparent 60%)}
#gate-seo-content .section-card.cat-foundation:hover{background:linear-gradient(135deg,rgba(107,114,128,0.12) 0%,transparent 60%)}
.gate-seo .section-card .gate-section-title{display:flex;align-items:flex-start;gap:10px;margin-bottom:8px;min-height:30px}
.gate-seo .section-card .gate-section-icon{margin-top:2px}
.gate-seo .section-card strong{font-family:'Inter',system-ui,sans-serif;color:#E5E7EB;font-size:16px;font-weight:600;line-height:1.3;margin:0;padding:0}
.gate-seo .section-card .gate-section-icon{width:30px;height:30px;display:block;flex-shrink:0}
.gate-seo .cat-foundation .gate-section-icon{filter:brightness(0) invert(.7) sepia(.15) saturate(1) hue-rotate(0deg)}
.gate-seo .cat-business .gate-section-icon{filter:brightness(0) saturate(100%) invert(45%) sepia(90%) saturate(1200%) hue-rotate(186deg) brightness(95%) contrast(92%)}
.gate-seo .cat-growth .gate-section-icon{filter:brightness(0) saturate(100%) invert(75%) sepia(24%) saturate(818%) hue-rotate(88deg) brightness(98%) contrast(90%)}
.gate-seo .cat-brand .gate-section-icon{filter:brightness(0) saturate(100%) invert(62%) sepia(19%) saturate(1565%) hue-rotate(220deg) brightness(95%) contrast(96%)}
.gate-seo .cat-retention .gate-section-icon{filter:brightness(0) saturate(100%) invert(73%) sepia(43%) saturate(911%) hue-rotate(349deg) brightness(100%) contrast(92%)}
.gate-seo .cat-scale .gate-section-icon{filter:brightness(0) saturate(100%) invert(68%) sepia(70%) saturate(585%) hue-rotate(146deg) brightness(97%) contrast(93%)}
.gate-seo .cat-numbers .gate-section-icon{filter:brightness(0) invert(42%) sepia(98%) saturate(2000%) hue-rotate(342deg) brightness(100%) contrast(96%)}
.gate-seo .cat-exit .gate-section-icon{filter:brightness(0) saturate(100%) invert(63%) sepia(30%) saturate(2281%) hue-rotate(292deg) brightness(96%) contrast(95%)}
.gate-seo .section-card span{color:#9CA3AF;font-size:14px;line-height:1.7;flex:1}
.gate-seo .section-cards.single-col{grid-template-columns:1fr}
/* Category border-left stripes (gate only). Remove when gate.html goes. */
#gate-seo-content .section-card.cat-business{border-left:3px solid #2080D4}
#gate-seo-content .section-card.cat-growth{border-left:3px solid #16A34A}
#gate-seo-content .section-card.cat-brand{border-left:3px solid #8B5CF6}
#gate-seo-content .section-card.cat-retention{border-left:3px solid #F59E0B}
#gate-seo-content .section-card.cat-scale{border-left:3px solid #06B6D4}
#gate-seo-content .section-card.cat-numbers{border-left:3px solid #EF4444}
#gate-seo-content .section-card.cat-exit{border-left:3px solid #EC4899}
#gate-seo-content .section-card.cat-foundation{border-left:3px solid #6B7280}
.gate-seo .two-col-block{display:grid;grid-template-columns:1fr 1fr;gap:32px;align-items:center;margin:32px 0}
.gate-seo .two-col-block .col-text{}
.gate-seo .two-col-block .col-visual{background:#161620;border:1px solid rgba(255,255,255,0.06);border-radius:20px;padding:24px;text-align:center}
.gate-seo .big-quote{font-size:clamp(1.3rem,3vw,1.6rem);font-style:italic;color:#E5E7EB;font-family:Georgia,'Times New Roman',serif;line-height:1.6;text-align:left;padding:28px 0;margin:56px 0;border-left:none;background:none}
.gate-seo .big-quote .quote-attr{font-family:'JetBrains Mono',monospace;font-size:11px;color:#7C8493;font-style:normal;margin-top:14px;letter-spacing:0.1em;text-transform:uppercase}
@media(max-width:768px){.gate-seo .stats-bar{gap:20px;padding:24px 16px}.gate-seo .stat-item .stat-num{font-size:24px}.gate-seo .section-cards{grid-template-columns:1fr}.gate-seo .two-col-block{grid-template-columns:1fr}}
.gate-seo .seo-features{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin:24px 0}

/* Landing-public feature cards — glow-surface family. Used on the "Who it's
   for", HC features, and tools lists. No per-category tone (unlike
   section-card), so just a single accent-blue glow. */
.seo-feature {
  padding: var(--s-5);
  background:
    radial-gradient(ellipse 80% 70% at top right,
      color-mix(in srgb, var(--accent) 13%, transparent) 0%,
      transparent 60%),
    radial-gradient(ellipse 60% 100% at bottom left,
      color-mix(in srgb, var(--accent) 5%, transparent) 0%,
      transparent 55%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.25s;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 1px 2px rgba(0,0,0,0.2);
}
.seo-feature:hover {
  border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
  transform: translateY(-2px);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 10px 24px -8px rgba(0,0,0,0.35),
    0 0 32px -6px color-mix(in srgb, var(--accent) 30%, transparent);
}
.seo-feature strong {
  display: block;
  color: var(--text);
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}
.seo-feature span {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.6;
}
/* Head row: group-tinted section icon chip inline with the tool/calc name
   (2026-07-21, tools + calculators hubs). A div so `.seo-feature span`'s
   desc styling can't reach it; the chip itself is a .schip3 from the v4
   icon family. */
.seo-feature-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.seo-feature-head strong { margin-bottom: 0; }
.seo-feature-head .schip3 { flex-shrink: 0; }

/* Legacy gate .seo-feature surface (flat gradient + border-left stripe).
   Scoped to #gate-seo-content. Remove when gate.html is deleted. */
#gate-seo-content .seo-feature{padding:20px 20px 20px 24px;background:linear-gradient(135deg,rgba(32,128,212,0.06) 0%,transparent 60%);border:none;border-left:3px solid #2080D4;border-radius:0 12px 12px 0;box-shadow:none;transition:transform 0.4s cubic-bezier(0.16,1,0.3,1),border-color 0.4s cubic-bezier(0.16,1,0.3,1),box-shadow 0.4s cubic-bezier(0.16,1,0.3,1),background 0.4s cubic-bezier(0.16,1,0.3,1)}
#gate-seo-content .seo-feature:hover{transform:translateY(-3px);box-shadow:0 8px 32px rgba(0,0,0,0.3),inset 3px 0 12px -4px rgba(32,128,212,0.3);background:linear-gradient(135deg,rgba(32,128,212,0.1) 0%,transparent 60%);border-color:transparent}
#gate-seo-content .seo-feature strong{color:#E5E7EB}
#gate-seo-content .seo-feature span{color:#9CA3AF}
.gate-seo .seo-cta{text-align:center;margin:48px 0 32px;padding:36px;background:#161620;border:1px solid rgba(32,128,212,0.2);border-radius:20px}
.gate-seo .seo-cta h3{color:#E5E7EB;margin-top:0}
.gate-seo .seo-cta p{color:#9CA3AF}
.gate-seo .seo-divider{width:100%;height:1px;background:linear-gradient(90deg,transparent 0%,rgba(32,128,212,0.3) 50%,transparent 100%);margin:56px auto;border-radius:1px}
.gate-seo .seo-register{text-align:center;margin:56px 0 24px;padding:36px;background:#161620;border:1px solid rgba(32,128,212,0.2);border-radius:20px;animation:none}
.gate-seo .seo-register h3{font-family:'Inter',system-ui,sans-serif;color:#E5E7EB;margin-top:0;text-transform:none;letter-spacing:-0.02em;display:block;padding:0;border:none;border-radius:0;background:none;font-size:20px;font-weight:700;animation:none}
.gate-seo .seo-register input{font-family:'Inter',system-ui,sans-serif;background:#0D0D12;border:1px solid rgba(255,255,255,0.06);color:#E5E7EB;padding:14px 18px;border-radius:12px;font-size:15px;width:100%;max-width:320px;margin:4px 0;box-sizing:border-box;transition:border-color 0.3s cubic-bezier(0.16,1,0.3,1),box-shadow 0.3s cubic-bezier(0.16,1,0.3,1)}
.gate-seo .seo-register input::placeholder{color:#7C8493}
.gate-seo .seo-register input:focus{border-color:#2080D4;box-shadow:0 0 0 3px rgba(32,128,212,0.15)}
.gate-seo .seo-register button{position:relative;overflow:hidden;background:#2080D4;color:#fff;border:none;padding:14px 28px;border-radius:12px;font-family:'Inter',system-ui,sans-serif;font-size:14px;cursor:pointer;font-weight:600;width:100%;max-width:320px;margin-top:8px;transition:all 0.3s cubic-bezier(0.16,1,0.3,1)}
.gate-seo .seo-register button:hover{background:#3D96E8;transform:scale(1.03);box-shadow:0 4px 20px rgba(32,128,212,0.35)}
@media(max-width:768px){.gate-seo .seo-features{grid-template-columns:1fr}}

/* (Legacy .site-footer styles removed — superseded by the standardised
   .dtc-footer shared by every page.) */

/* ============================================================
   HC Stage Selection (Full diagnostic step 1)
   ============================================================ */
.hc-stage-shell { text-align: center; }
.hc-stage-shell h2 { font-size: clamp(26px, 3.5vw, 36px); font-weight: 800; letter-spacing: -0.02em; color: var(--text); margin: 16px 0 8px; }
.hc-stage-copy { color: var(--text-muted); font-size: 15px; line-height: 1.6; max-width: 520px; margin: 0 auto 32px; }
/* Mirror V3 .stages pattern: 5 cards equal-fit (auto-fit minmax handles
   any number of stages cleanly, wraps on narrow viewports). */
.hc-stage-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--s-3);
  max-width: 880px;
  margin: 0 auto;
  text-align: left;
}
.hc-stage-card {
  display: flex; flex-direction: column;
  padding: var(--s-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  color: inherit; cursor: pointer; font: inherit;
  position: relative;
  min-height: 220px;
  text-align: left; /* explicit — .hc-stage-shell parent is centred */
  box-shadow:
    0 1px 0 rgba(255,255,255,0.04) inset,
    0 2px 6px rgba(0,0,0,0.15);
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.25s;
}
.hc-stage-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.06) inset,
    0 10px 24px -8px rgba(0,0,0,0.35);
}
.hc-stage-card:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* Head row: icon on the left, oversized stage number on the right.
   Same visual rhythm as the home-page step cards + V3 .stage pattern. */
.hc-stage-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  margin-bottom: var(--s-4);
}
.hc-stage-icon {
  display: inline-flex;
  align-items: center;
  color: var(--accent-text);
  flex-shrink: 0;
}
.hc-stage-icon svg {
  width: 22px;
  height: 22px;
  stroke-width: 1.8;
}
.hc-stage-num {
  font-family: var(--font-mono);
  font-size: 24px;
  font-weight: 500;
  line-height: 1;
  color: var(--text-ghost, var(--text-dim));
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}
.hc-stage-kicker {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  color: var(--accent-text);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  margin-bottom: var(--s-2);
}
.hc-stage-name {
  font-family: var(--font-sans);
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  margin-bottom: var(--s-2);
}
.hc-stage-desc {
  color: var(--text-muted);
  font-size: 13.5px;
  line-height: 1.55;
}
/* Per-stage meta: question count + time estimate. Renders below the
   description in mono / dim treatment, matching the kicker vocabulary
   used elsewhere on the card so it reads as metadata, not body copy. */
.hc-stage-meta {
  margin-top: var(--s-3);
  padding-top: var(--s-3);
  border-top: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--text-dim);
  text-transform: uppercase;
}
.hc-progress-top { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 24px; text-align: left; }
.hc-back-link {
  background: none; border: none; color: var(--text-muted); font: 600 13px/1 var(--font-sans);
  padding: 6px 10px; border-radius: 6px; cursor: pointer; transition: background 0.15s, color 0.15s;
}
.hc-back-link:hover { background: var(--surface); color: var(--text); }
.hc-progress-label { font-family: var(--font-mono); font-size: 11px; font-weight: 600; color: var(--accent-text); letter-spacing: 0.15em; text-transform: uppercase; }
@media (max-width: 640px) { .hc-stage-grid { grid-template-columns: 1fr; } }

/* Resume-or-start-fresh prompt (replaces brittle native confirm() dialog
   for cross-device draft resume). Inherits .hc-stage-shell layout (centred,
   stacked) — adds button row + fineprint. */
.hc-resume-actions {
  display: flex; gap: 12px; justify-content: center; flex-wrap: wrap;
  margin: 8px auto 16px; max-width: 520px;
}
.hc-resume-btn { min-width: 180px; }
.hc-resume-fineprint {
  color: var(--text-dim); font-size: 13px; line-height: 1.5;
  max-width: 460px; margin: 0 auto; font-style: italic;
}
@media (max-width: 480px) {
  .hc-resume-actions { flex-direction: column; align-items: stretch; max-width: 320px; }
  .hc-resume-btn { width: 100%; }
}

/* Save-progress button states — pre-2026-05 it lied about success.
   Now waits for the server response and surfaces failures explicitly. */
.hc-save-btn.is-saving { opacity: 0.7; cursor: wait; }
.hc-save-btn.is-save-failed {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.4);
  color: #fca5a5;
}

/* Intro-page resume reassurance — appears under the CTA when a user has
   an in-progress draft. Tells returning users their save survived before
   they have to click through to find out. */
.hc-tier-resume-note {
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-muted);
  display: flex; align-items: center; gap: 8px;
  justify-content: center;
}
.hc-tier-resume-check {
  display: inline-flex; align-items: center; justify-content: center;
  width: 18px; height: 18px; border-radius: 50%;
  background: rgba(34, 197, 94, 0.15);
  color: #22c55e;
  flex-shrink: 0;
}

/* ============================================================
   Index view header
   ============================================================ */
.index-head {
  max-width: 780px;
  margin: var(--s-8) auto var(--s-7);
  text-align: center;
}
.index-head-kicker {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-text);
  padding: 6px 14px;
  border: 1px solid rgba(0,120,212,0.25);
  border-radius: 999px;
  background: rgba(0,120,212,0.06);
  margin-bottom: var(--s-4);
}
.index-title {
  font-size: clamp(36px, 4.8vw, 52px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.08;
  color: var(--text);
  text-wrap: balance;
  margin: 0 0 var(--s-4);
}
.index-lead {
  font-size: 17px;
  line-height: 1.65;
  color: var(--text-muted);
  max-width: 640px;
  margin: 0 auto var(--s-5);
}
.index-head .cta-row { justify-content: center; }

/* ============================================================
   Section "Mark as read" card (single-row checklist, sits above the action
   checklist so the reading -> executing flow reads top-down).
   Reuses .checklist / .checklist-items so visual weight matches.
   ============================================================ */
.section-read-card { margin-top: var(--s-6); margin-bottom: var(--s-3); }
.section-read-item { outline: none; }
.section-read-item:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

.section-read-status .section-read-state-default { color: var(--text-dim); }
.section-read-status .section-read-state-done { display: none; color: #4ADE80; }

/* Read state: tick the checkbox + swap the status pill to green "Read" */
.section-read-item.is-read .checklist-check {
  background: #4ADE80;
  border-color: #4ADE80;
}
.section-read-item.is-read .checklist-check::after {
  content: "";
  position: absolute;
  left: 5px; top: 2px;
  width: 4px; height: 9px;
  border: solid #0A0A0F;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.section-read-item.is-read .checklist-text {
  color: var(--text-dim);
}
.section-read-card:has(.section-read-item.is-read) .section-read-state-default { display: none; }
.section-read-card:has(.section-read-item.is-read) .section-read-state-done { display: inline; }

/* ============================================================
   Brand page: Category accordion (Progress by category)
   ============================================================ */
.brand-groups { display: flex; flex-direction: column; gap: var(--s-3); margin-top: var(--s-4); }

.brand-group {
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s;
}
/* Per-group accent (head num, row tag, bar fill, hover states) — the same
   --g-* accent language as the Index list + section cards. */
.brand-group[data-group="foundation"] { --row-accent: var(--g-foundation); }
.brand-group[data-group="business"]   { --row-accent: var(--g-business); }
.brand-group[data-group="growth"]     { --row-accent: var(--g-growth); }
.brand-group[data-group="brand"]      { --row-accent: var(--g-brand); }
.brand-group[data-group="retention"]  { --row-accent: var(--g-retention); }
.brand-group[data-group="scale"]      { --row-accent: var(--g-scale); }
.brand-group[data-group="numbers"]    { --row-accent: var(--g-numbers); }
.brand-group[data-group="exit"]       { --row-accent: var(--g-exit); }
/* Standalone .bsr rows (the Overview "Fix next" list) carry data-group
   on the row itself - same accent vars, no .brand-group ancestor. */
.bsr[data-group="foundation"] { --row-accent: var(--g-foundation); }
.bsr[data-group="business"] { --row-accent: var(--g-business); }
.bsr[data-group="growth"] { --row-accent: var(--g-growth); }
.bsr[data-group="brand"] { --row-accent: var(--g-brand); }
.bsr[data-group="retention"] { --row-accent: var(--g-retention); }
.bsr[data-group="scale"] { --row-accent: var(--g-scale); }
.bsr[data-group="numbers"] { --row-accent: var(--g-numbers); }
.bsr[data-group="exit"] { --row-accent: var(--g-exit); }
.brand-group:hover { border-color: var(--border-hi); }
.brand-group.is-open {
  border-color: rgba(0,120,212,0.3);
  box-shadow: 0 10px 32px -12px rgba(0,0,0,0.5);
}

/* Head */
.brand-group-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--s-5);
  align-items: center;
  width: 100%;
  padding: var(--s-4) var(--s-5);
  background: transparent;
  border: 0;
  color: inherit;
  font: inherit;
  cursor: pointer;
  text-align: left;
  transition: background 0.15s;
}
.brand-group-head:hover { background: rgba(255,255,255,0.02); }
.brand-group-head:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }

.bg-head-lead { display: flex; align-items: baseline; gap: var(--s-3); min-width: 0; flex-wrap: wrap; }
.bg-head-num {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.15em;
  color: var(--row-accent, var(--accent-text));
}
.bg-head-title {
  font-family: var(--font-sans);
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}
.bg-head-count {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--text-dim);
  text-transform: uppercase;
}

.bg-head-metrics { display: flex; align-items: center; gap: var(--s-5); }

.bg-metric { display: flex; flex-direction: column; gap: 4px; min-width: 52px; }
.bg-metric-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--text-dim);
  text-transform: uppercase;
}
.bg-metric-value {
  font-family: var(--font-mono);
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}
.bg-metric-empty .bg-metric-value { color: var(--text-dim); font-weight: 400; }

.bg-metric-progress { min-width: 160px; }
.bg-progress-wrap { display: flex; align-items: center; gap: 10px; }
.bg-progress-track {
  flex: 1;
  height: 6px;
  background: var(--surface-2);
  border-radius: 4px;
  overflow: hidden;
}
.bg-progress-fill { height: 100%; border-radius: 4px; transition: width 0.3s; }
.bg-progress-num {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

.bg-chevron {
  font-size: 15px;
  color: var(--text-dim);
  transition: transform 0.25s cubic-bezier(0.16,1,0.3,1), color 0.15s;
}
.brand-group-head:hover .bg-chevron { color: var(--text); }
.brand-group.is-open .bg-chevron { transform: rotate(180deg); color: var(--row-accent, var(--accent-text)); }

/* Body */
.brand-group-body {
  padding: 0 var(--s-5) var(--s-5);
  border-top: 1px solid var(--border);
  margin-top: -1px;
}
.brand-group-priority {
  margin: var(--s-4) 0 var(--s-3);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.brand-group-rows { display: flex; flex-direction: column; gap: 8px; }

/* Brand Section Row (.bsr) */
/* Columns: icon · tag · title · HC score · read chip · checklist bar · arrow.
   Group accent flows from --row-accent set on .brand-group[data-group] below
   (tag, bar fill, hover border/arrow) — same accent language as the Index
   .section-row list. */
.bsr {
  display: grid;
  grid-template-columns: 26px 58px 1fr 64px 82px 180px 24px;
  gap: var(--s-4);
  align-items: center;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  cursor: pointer;
  transition: transform 0.15s, border-color 0.15s, background 0.15s;
}
.bsr:hover {
  transform: translateX(2px);
  border-color: color-mix(in srgb, var(--row-accent, var(--accent)) 35%, var(--border));
  background: var(--surface);
}
.bsr-icon { width: 26px; height: 26px; display: grid; place-items: center; }
.bsr-icon img { width: 22px; height: 22px; opacity: 0.9; }
.bsr:hover .bsr-icon img { opacity: 1; }
.bsr-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--row-accent, var(--accent-text));
  background: color-mix(in srgb, var(--row-accent, var(--accent)) 10%, transparent);
  padding: 4px 8px;
  border-radius: 6px;
  text-align: center;
}
.bsr-title {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.005em;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.bsr-read {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--text-dim);
  border: 1px solid var(--border);
  text-align: center;
}
.bsr-read.is-read {
  background: rgba(74,222,128,0.15);
  border-color: rgba(74,222,128,0.35);
  color: #4ADE80;
}
.bsr-checklist { display: flex; align-items: center; gap: 10px; }
/* Bumped contrast: surface-2 was nearly identical to the dark .bsr bg
   so the empty track was invisible at 0% fill — Nira reported it as
   "text fractions, not visual bars". Now a darker bg + 1px border
   ensures the empty track is always readable. */
.bsr-track {
  flex: 1;
  height: 6px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  min-width: 80px;
}
.bsr-fill {
  height: 100%;
  background: var(--row-accent, var(--accent));
  border-radius: 3px;
  transition: width 0.3s;
}
.bsr-count {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
}
.bsr-arrow {
  font-size: 14px;
  color: var(--text-dim);
  transition: color 0.15s, transform 0.15s;
}
.bsr:hover .bsr-arrow { color: var(--row-accent, var(--accent-text)); transform: translateX(2px); }

.brand-group-more {
  margin-top: var(--s-3);
  padding-top: var(--s-3);
  border-top: 1px dashed var(--border);
  font-size: 13px;
  color: var(--text-muted);
}
.brand-group-more a {
  color: var(--accent-text);
  text-decoration: none;
  font-weight: 600;
}
.brand-group-more a:hover { text-decoration: underline; }

/* Per-section HC score badge — small mono pill, tone-coloured by band.
   Set via inline --hc-tone CSS var (green/amber/red). The "—" empty state
   means the section wasn't assessed at the user's selected stage. */
.bsr-hc {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 56px;
  padding: 4px 8px;
  background: color-mix(in srgb, var(--hc-tone, var(--text-dim)) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--hc-tone, var(--text-dim)) 32%, transparent);
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--hc-tone, var(--text-dim));
  text-align: center;
}
.bsr-hc-na, .bsr-hc-empty {
  background: transparent;
  border: 1px dashed var(--border);
  color: var(--text-dim);
  font-weight: 500;
}
.bsr-hc-empty { border: none; }

@media (max-width: 820px) {
  .brand-group-head { grid-template-columns: 1fr; }
  .bg-head-metrics { justify-content: flex-start; flex-wrap: wrap; gap: var(--s-4); }
  .bg-metric-progress { min-width: 120px; }
  /* Mobile: drop the HC badge to a second row inside the title block to
     keep the row scannable on small screens. */
  .bsr { grid-template-columns: 26px 58px 1fr 64px 82px 24px; gap: var(--s-3); }
  .bsr-checklist { grid-column: 1 / -1; }
}
@media (max-width: 480px) {
  /* Very narrow: the icon column costs more than it gives — hide it. */
  .bsr { grid-template-columns: 58px 1fr 64px 82px 24px; }
  .bsr-icon { display: none; }
}

/* ============================================================
   Index: sticky jump-nav + per-section state indicator
   ============================================================ */
.index-jumpnav {
  position: sticky;
  top: 62px;
  z-index: 40;
  display: flex;
  gap: 6px;
  padding: 10px 0;
  margin: 0 0 var(--s-4);
  background: color-mix(in oklab, var(--bg) 88%, transparent);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
  scrollbar-width: thin;
}
.index-jumpnav::-webkit-scrollbar { height: 4px; }
.index-jumpnav::-webkit-scrollbar-thumb { background: var(--border-hi); border-radius: 2px; }
.index-jump {
  flex-shrink: 0;
  padding: 7px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text-muted);
  font: 600 12px/1 var(--font-sans);
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s, transform 0.1s;
}
.index-jump:hover { background: var(--surface-2); color: var(--text); border-color: var(--border-hi); }
.index-jump:active { transform: translateY(1px); }
.index-jump[data-jump="foundation"]:hover { color: var(--g-foundation); border-color: var(--g-foundation); }
.index-jump[data-jump="business"]:hover  { color: var(--g-business);   border-color: var(--g-business); }
.index-jump[data-jump="growth"]:hover    { color: var(--g-growth);     border-color: var(--g-growth); }
.index-jump[data-jump="brand"]:hover     { color: var(--g-brand);      border-color: var(--g-brand); }
.index-jump[data-jump="retention"]:hover { color: var(--g-retention);  border-color: var(--g-retention); }
.index-jump[data-jump="scale"]:hover     { color: var(--g-scale);      border-color: var(--g-scale); }
.index-jump[data-jump="numbers"]:hover   { color: var(--g-numbers);    border-color: var(--g-numbers); }
.index-jump[data-jump="exit"]:hover      { color: var(--g-exit);       border-color: var(--g-exit); }

/* (Removed 2026-07: the legacy .section-state / .section-state-read /
   .section-state-bar* pill block from a pre-MS2.0 index card. Nothing emits
   those classes any more, and its later-in-cascade .section-state-read
   redefinition was overriding the live dot-chip styling (~L956) with a
   bordered pill on the new Index rows.) */

/* Row gets a subtle green treatment when the section is fully read + all
   checklist items ticked. Keeps the list visually calm but rewards
   completion. (.section-card kept for any legacy card surface.) */
.section-card.is-complete,
.section-row.is-complete {
  border-color: rgba(74,222,128,0.3);
  background: linear-gradient(135deg, rgba(74,222,128,0.05) 0%, var(--surface) 60%);
}

@media (max-width: 820px) {
  .index-jumpnav { top: 58px; }
  .section-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .section-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   HC question footer (next button + inline status)
   With auto-advance on answer click, the next button is mostly a
   keyboard fallback / "See results" affordance — it stays disabled
   until the current question has an answer, then turns blue.
   ============================================================ */
.hc-footer-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-3);
  margin-top: var(--s-6);
}
.hc-inline-status {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-dim);
}
.hc-next-btn {
  min-width: 180px;
  justify-content: center;
}
.hc-next-btn[disabled] {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
}

/* Save progress button — Full HC only. Secondary/ghost style so it
   doesn't compete with the primary Next/See results button. Confirms
   the localStorage autosave with a ✓ briefly after click. */
.hc-save-btn {
  display: inline-flex; align-items: center; gap: 8px;
  min-width: 160px; justify-content: center;
  padding: 8px 16px;
  font-size: 13px; font-weight: 500;
  color: var(--text-muted);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}
.hc-save-btn:hover { border-color: var(--border-hi); color: var(--text); background: var(--surface); }
.hc-save-btn.is-saved { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 50%, transparent); }
.hc-save-btn .icon { width: 14px; height: 14px; }
.hc-save-timestamp {
  font-family: var(--font-mono); font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase; letter-spacing: 0.14em;
  margin-top: -4px;
}

/* ============================================================
   HC results page (post-submit)
   ============================================================ */
.hc-results-shell {
  max-width: 880px;
  margin: 0 auto;
  padding: var(--s-7) var(--s-5);
}

.hc-results-hero {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--s-7);
  align-items: center;
  margin-bottom: var(--s-7);
  padding-bottom: var(--s-6);
  border-bottom: 1px solid var(--border);
  /* Kicker + title + tagline on the left — the shell is otherwise
     centre-aligned (see .hc-shell in the shared layout block). */
  text-align: left;
}
.hc-results-copy { margin-left: 0; }
.hc-results-hero h2 {
  font-size: clamp(34px, 4vw, 48px);
  font-weight: 800;
  letter-spacing: -0.025em;
  color: var(--text);
  margin: 6px 0 var(--s-3);
  line-height: 1.05;
}
.hc-kicker {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-text);
}
.hc-results-copy {
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.6;
  max-width: 420px;
  margin: 0;
}

/* Score gauge */
.hc-gauge {
  position: relative;
  width: 180px;
  height: 180px;
  flex-shrink: 0;
  background:
    conic-gradient(var(--accent) calc(var(--hc-score, 0) * 1%), var(--surface-2) 0%);
  border-radius: 50%;
  padding: 8px;
  box-shadow:
    0 0 0 1px var(--border) inset,
    0 18px 40px -18px rgba(0,120,212,0.4);
}
.hc-gauge-ring {
  position: absolute;
  inset: 8px;
  border-radius: 50%;
  background: var(--surface);
}
.hc-gauge-inner {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-radius: 50%;
  background: var(--surface);
}
.hc-gauge-score {
  font-family: var(--font-mono);
  font-size: 44px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.hc-gauge-rating {
  margin-top: 6px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  max-width: 130px;
  line-height: 1.3;
}

/* Two-column grid for breakdown + recs */
.hc-results-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-5);
  margin-bottom: var(--s-7);
}
.hc-results-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: var(--s-5);
}
.hc-results-card h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 var(--s-4);
  padding-bottom: var(--s-3);
  border-bottom: 1px solid var(--border);
  letter-spacing: -0.01em;
}

/* Category bars */
.hc-bars { display: flex; flex-direction: column; gap: 12px; }
.hc-bar-row {
  display: grid;
  grid-template-columns: 130px 1fr 44px;
  gap: var(--s-3);
  align-items: center;
}
.hc-bar-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  letter-spacing: -0.005em;
}
.hc-bar-track {
  height: 8px;
  background: var(--surface-2);
  border-radius: 4px;
  overflow: hidden;
}
.hc-bar-fill {
  height: 100%;
  border-radius: 4px;
  transition: width 0.4s cubic-bezier(0.16,1,0.3,1);
}
.hc-bar-value {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* Weakest areas */
.hc-weak-list { display: flex; flex-direction: column; gap: var(--s-3); }
.hc-weak-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--s-3);
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}
.hc-weak-item:last-child { border-bottom: none; }
.hc-weak-item strong {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}
.hc-weak-meta {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  letter-spacing: 0.06em;
  margin-top: 2px;
}
.hc-link-btn {
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font: 600 11px/1 var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 7px 12px;
  border-radius: 6px;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.15s, border-color 0.15s, background 0.15s;
}
.hc-link-btn:hover {
  color: var(--accent-text);
  border-color: var(--accent);
  background: rgba(0,120,212,0.08);
}

/* Recommended sections */
.hc-rec-list { display: flex; flex-direction: column; gap: 8px; }
.hc-rec-chip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-align: left;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font: 600 13px/1.4 var(--font-sans);
  cursor: pointer;
  transition: transform 0.15s, border-color 0.15s, background 0.15s;
}
.hc-rec-chip::after {
  content: "→";
  margin-left: 12px;
  color: var(--text-dim);
  transition: color 0.15s, transform 0.15s;
}
.hc-rec-chip:hover {
  transform: translateX(2px);
  border-color: rgba(0,120,212,0.3);
  background: var(--surface);
}
.hc-rec-chip:hover::after { color: var(--accent-text); transform: translateX(2px); }

/* Quick HC signup form (in results) */
.hc-signup-form { display: flex; flex-direction: column; gap: 10px; margin-top: var(--s-4); }
.hc-signup-form input {
  font-family: var(--font-sans);
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 11px 14px;
  border-radius: 8px;
  font-size: 14px;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.hc-signup-form input:focus {
  border-color: var(--accent);
  outline: none;
  box-shadow: 0 0 0 3px rgba(0,120,212,0.35);
}
.hc-signup-form button { margin-top: 4px; }
.hc-form-error {
  color: var(--err);
  font-size: 13px;
  margin-bottom: 6px;
}

/* Action buttons */
.hc-results-actions {
  display: flex;
  gap: var(--s-3);
  justify-content: center;
  flex-wrap: wrap;
  padding-top: var(--s-5);
  border-top: 1px solid var(--border);
}
.hc-results-actions .btn-primary,
.hc-results-actions .btn-outline { /* legacy class names emitted by JS */ }
.hc-results-actions .btn-primary {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
  padding: 12px 22px;
  border-radius: 10px;
  font: 600 14px/1 var(--font-sans);
  cursor: pointer;
  transition: background 0.15s, transform 0.15s;
}
.hc-results-actions .btn-primary:hover { background: var(--accent-hi); transform: translateY(-1px); }
.hc-results-actions .btn-outline {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border-hi);
  padding: 12px 22px;
  border-radius: 10px;
  font: 600 14px/1 var(--font-sans);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.hc-results-actions .btn-outline:hover { background: var(--surface); border-color: var(--accent); }

@media (max-width: 720px) {
  .hc-results-hero { grid-template-columns: 1fr; text-align: center; }
  .hc-results-hero .hc-gauge { margin: 0 auto; }
  .hc-results-grid { grid-template-columns: 1fr; }
  .hc-bar-row { grid-template-columns: 90px 1fr 40px; }
  .hc-weak-item { flex-direction: column; align-items: flex-start; }
  .hc-results-actions { flex-direction: column; align-items: stretch; }
  .hc-results-actions button { width: 100%; }
}

/* Brand: progress-over-time chart card */
.brand-chart-card {
  background:
    linear-gradient(135deg, rgba(32,128,212,0.06) 0%, transparent 70%),
    var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: var(--s-5);
  margin-top: var(--s-3);
  margin-bottom: var(--s-5);
}

/* ============================================================
   Inline icons in body content (e.g. compare-card labels). The SVG
   files are exported with hardcoded black strokes — without a filter
   they're invisible on the dark theme. Tint to text colour by default;
   compare-card variants override to inherit the variant tone.
   ============================================================ */
img.inline-icon {
  width: 18px;
  height: 18px;
  vertical-align: middle;
  margin-right: 6px;
  filter: brightness(0) invert(1) opacity(0.85);
}
.compare-card--good img.inline-icon { filter: brightness(0) saturate(100%) invert(72%) sepia(67%) saturate(412%) hue-rotate(80deg) brightness(94%) contrast(85%); }
.compare-card--bad img.inline-icon { filter: brightness(0) saturate(100%) invert(58%) sepia(67%) saturate(2700%) hue-rotate(330deg) brightness(96%) contrast(95%); }
.compare-card--warning img.inline-icon { filter: brightness(0) saturate(100%) invert(70%) sepia(57%) saturate(990%) hue-rotate(355deg) brightness(98%) contrast(96%); }
.compare-card--neutral img.inline-icon { filter: brightness(0) invert(1) opacity(0.7); }

/* Legacy button class aliases. Older JS strings + HTML (healthcheck.js,
   results.html, healthcheck.html, some templates) use .btn-primary /
   .btn-outline (single dash). Keep those working so buttons don't render
   as default browser grey. Style matches .btn--primary / .btn--ghost. */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 22px;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.1);
  font: 600 14px/1 var(--font-sans);
  letter-spacing: -0.005em;
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.25s, transform 0.15s;
  box-shadow: 0 8px 24px -6px var(--blue-glow), 0 0 0 1px rgba(255,255,255,0.06) inset;
  text-decoration: none;
}
.btn-primary:hover { background: var(--accent-hi); transform: translateY(-1px); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-primary svg { flex-shrink: 0; }

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 22px;
  border-radius: 10px;
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border-hi);
  font: 600 14px/1 var(--font-sans);
  letter-spacing: -0.005em;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
  text-decoration: none;
}
.btn-outline:hover { background: var(--surface); border-color: var(--accent); }

/* ============================================================
   Profile-complete form fields (post-signup persona pick).
   .pc-section / .pc-label / .pc-input / .pc-select had no CSS so the
   country dropdown + role/category/etc selects fell back to native
   browser styling — bright grey on the dark theme.
   ============================================================ */
/* Form-field blocks left-align to the .profile-view container so they
   line up with the persona cards above. The 520px cap keeps line-length
   readable for input fields. */
.pc-section { max-width: 520px; margin: 0 0 var(--s-5); }
/* Form labels are reading copy, not metadata — Inter sans, sentence case.
   MS 2.0 reserves JetBrains Mono for kickers/numbers/category badges; using
   it on every dropdown label made the form hard to scan. */
.pc-label {
  display: block;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.005em;
  color: var(--text);
  margin-bottom: 8px;
}
.pc-input,
.pc-select {
  width: 100%;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font: 14px/1.4 var(--font-sans);
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
  -webkit-appearance: none;
  appearance: none;
}
.pc-input:focus,
.pc-select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0,120,212,0.35);
}
.pc-input::placeholder { color: var(--text-dim); }
.pc-select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%237C8493' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}
.pc-select option { background: var(--surface); color: var(--text); }
.pc-persona-fields { animation: pcFadeIn 0.25s cubic-bezier(0.16,1,0.3,1); }
@keyframes pcFadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* ============================================================
   Profile-complete page — additional missing styles.

   The template uses .profile-view as the wrapper (already has
   max-width + padding at top of file), an eyebrow pill at the
   top, persona-specific field groups, multi-checkbox grids,
   a textarea, and a footer with consent + submit + signout link.

   Half of these classes had no CSS, so the page was rendering
   with browser defaults — cramped, mis-aligned, and out of sync
   with MS 2.0. This block fills the gaps.
   ============================================================ */

/* Eyebrow pill at top of form — replaces the bare mono label that
   was jammed against the navbar. Soft surface chip + amber dot
   (the "you're nearly done" signal Rob asked for). */
.profile-eyebrow-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px 6px 12px;
  margin: 0 auto var(--s-5);
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.28);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #F59E0B;
}
.profile-eyebrow-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #F59E0B;
  box-shadow:
    0 0 0 3px rgba(245, 158, 11, 0.18),
    0 0 12px rgba(245, 158, 11, 0.45);
  animation: pcDotPulse 2.4s ease-in-out infinite;
}
@keyframes pcDotPulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.18), 0 0 12px rgba(245, 158, 11, 0.45); }
  50% { box-shadow: 0 0 0 5px rgba(245, 158, 11, 0.10), 0 0 18px rgba(245, 158, 11, 0.65); }
}

/* Per-persona section heading ("About your brand", etc.) —
   was a bare <h3> with no styling. Now a left-aligned subheading
   that doesn't compete with the page title. */
.pc-fields-heading {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--text);
  margin: var(--s-7) 0 var(--s-4);
  padding-bottom: var(--s-3);
  border-bottom: 1px solid var(--border);
  max-width: 520px;
  text-align: left;
}

/* "Last two questions" divider — replaces an inline-styled <h3>
   with the canonical horizontal-line-with-text pattern. */
/* Left-aligned section break: thin rule above, mono kicker below.
   Replaces the centered chip-on-line pattern (which only reads cleanly
   when centred). */
.pc-divider {
  max-width: 520px;
  margin: var(--s-8) 0 var(--s-6);
  padding-top: var(--s-5);
  border-top: 1px solid var(--border);
}
.pc-divider span {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-text);
}

/* Textarea matches .pc-input visual treatment + room to type. */
.pc-textarea {
  display: block;
  width: 100%;
  min-height: 120px;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  color: var(--text);
  font: 14px/1.55 var(--font-sans);
  resize: vertical;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.pc-textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0,120,212,0.35);
}
.pc-textarea::placeholder { color: var(--text-dim); }
.pc-char-count {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-dim);
  text-align: right;
  margin-top: 6px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* Multi-select checkbox grid (investor firm-stage, advisor services, etc).
   Was rendering as raw inline checkboxes with no spacing. Now a 2-up grid
   of card-style toggles that match the persona-card visual language. */
.pc-multi {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}
.pc-checkbox-opt {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  color: var(--text-muted);
  transition: border-color 0.15s, color 0.15s, background 0.15s;
  user-select: none;
}
.pc-checkbox-opt:hover {
  border-color: var(--border-hi);
  color: var(--text);
}
.pc-checkbox-opt input[type="checkbox"] {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  accent-color: var(--accent);
  cursor: pointer;
}
.pc-checkbox-opt:has(input:checked) {
  border-color: var(--accent);
  background: var(--blue-wash);
  color: var(--text);
}

/* Inline hint text under a label (e.g. "Optional", "Select all that apply").
   Sentence-case sans, no italic — reads as helper text not a stylistic note. */
.pc-hint {
  font-family: var(--font-sans);
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 6px;
  line-height: 1.45;
}

/* Consent row — checkbox + agreement copy. Stacks safely on narrow widths. */
.pc-consent {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: var(--s-3) 0;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
  cursor: pointer;
}
.pc-consent input[type="checkbox"] {
  width: 16px;
  height: 16px;
  margin-top: 2px;
  flex-shrink: 0;
  accent-color: var(--accent);
}
.pc-consent a { color: var(--accent-text); text-decoration: underline; }

/* Submit CTA — full-width primary button below the consent row. */
.pc-submit {
  display: block;
  width: 100%;
  max-width: 520px;
  margin: var(--s-6) 0 0;
  padding: 14px 22px;
  background: var(--accent);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  font: 600 15px/1 var(--font-sans);
  letter-spacing: -0.005em;
  cursor: pointer;
  transition: background 0.15s, transform 0.1s, box-shadow 0.2s;
}
.pc-submit:hover {
  background: var(--blue-hi);
  box-shadow: 0 8px 24px -8px var(--blue-glow-soft);
}
.pc-submit:active { transform: translateY(1px); }
.pc-submit:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  background: var(--accent);
}

/* Inline error message under the submit button. */
.pc-error {
  max-width: 520px;
  margin: var(--s-3) 0 0;
  padding: 10px 14px;
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.35);
  border-radius: 8px;
  color: rgb(248, 113, 113);
  font-size: 13px;
  line-height: 1.4;
  display: none;
}
.pc-error:not(:empty) { display: block; }

/* "Not you? Sign out" footer link — small, centred, low-emphasis. */
.pc-signout {
  text-align: center;
  margin-top: var(--s-7);
  padding-top: var(--s-5);
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--text-dim);
}
.pc-signout a {
  color: var(--accent-text);
  text-decoration: none;
  font-weight: 600;
  margin-left: 4px;
}
.pc-signout a:hover { color: var(--blue-hi); text-decoration: underline; }

/* Persona-card grid: enforce 2-up on tablet+, single column on mobile.
   The base .persona-grid already does this, but tighten gap + ensure
   the wrapping fieldset doesn't add a default border (some browsers do). */
#view-profile-complete fieldset.profile-section {
  border: 0;
  padding: 0;
  margin: 0;
}

/* Mobile: collapse multi-checkbox grid to a single column so labels
   don't truncate awkwardly. */
@media (max-width: 540px) {
  .pc-multi { grid-template-columns: 1fr; }
  .profile-eyebrow-pill { font-size: 10px; letter-spacing: 0.12em; }
}

/* (Legacy .site-footer footer-link icon styles removed — see .dtc-footer.) */

/* ==========================================================================
   Feedback widget (floating button + modal)
   Authed-only; visibility toggled by script.js based on session state.
   ========================================================================== */

#feedback-widget {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 9500;
}

#feedback-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  box-shadow: var(--shadow-1);
  transition: border-color 0.15s, background 0.15s, transform 0.15s;
}
#feedback-btn:hover {
  border-color: var(--accent);
  background: var(--surface-hi);
  transform: translateY(-1px);
}
#feedback-btn:focus-visible {
  outline: 2px solid var(--accent-hi);
  outline-offset: 2px;
}
#feedback-btn svg { color: var(--accent-text); }

@media (max-width: 640px) {
  #feedback-widget { right: 12px; bottom: 12px; }
  #feedback-btn { padding: 8px 10px; font-size: 12px; }
  #feedback-btn span { display: none; }
}

/* Modal shell */
.fb-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.fb-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 9, 11, 0.72);
  backdrop-filter: blur(4px);
}
.fb-modal-card {
  position: relative;
  z-index: 1;
  width: min(540px, 100%);
  background: var(--surface);
  border: 1px solid var(--border-hi);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-1), 0 30px 80px -20px rgba(0,0,0,0.5);
  max-height: calc(100vh - 40px);
  overflow-y: auto;
}

.fb-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 12px;
  border-bottom: 1px solid var(--border);
}
.fb-modal-head h3 {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
}
.fb-close {
  background: transparent;
  border: 0;
  color: var(--text-dim);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--r-sm);
}
.fb-close:hover { color: var(--text); background: var(--surface-2); }

#feedback-form { padding: 16px 24px 20px; }

.fb-field { margin-bottom: 16px; }
.fb-field label {
  display: block;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 6px;
  letter-spacing: 0.01em;
}

.fb-field select,
.fb-field textarea {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 14px;
  padding: 10px 12px;
  transition: border-color 0.15s, background 0.15s;
}
.fb-field textarea { resize: vertical; min-height: 96px; line-height: 1.5; }
.fb-field select:focus,
.fb-field textarea:focus {
  outline: none;
  border-color: var(--accent);
  background: var(--surface-2);
}

.fb-hint {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  text-align: right;
  margin-top: 4px;
}

.fb-context {
  margin: 8px 0 16px;
  padding: 10px 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-dim);
  line-height: 1.6;
  word-break: break-all;
}
.fb-context:empty { display: none; }
.fb-context-row { display: flex; gap: 8px; }
.fb-context-row strong {
  color: var(--text-muted);
  font-weight: 500;
  min-width: 72px;
  flex-shrink: 0;
}

.fb-error {
  margin-bottom: 12px;
  padding: 8px 12px;
  background: var(--err-glow);
  border: 1px solid var(--err);
  border-radius: var(--r-sm);
  color: var(--err);
  font-size: 13px;
}

.fb-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 8px;
}
.fb-btn-ghost,
.fb-btn-primary {
  padding: 9px 16px;
  border-radius: var(--r-sm);
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, opacity 0.15s;
}
.fb-btn-ghost {
  background: transparent;
  border: 1px solid var(--border-hi);
  color: var(--text-muted);
}
.fb-btn-ghost:hover {
  border-color: var(--text-dim);
  color: var(--text);
}
.fb-btn-primary {
  background: var(--accent);
  border: 1px solid var(--accent);
  color: #fff;
}
.fb-btn-primary:hover { background: var(--accent-hi); border-color: var(--accent-hi); }
.fb-btn-primary:disabled { opacity: 0.5; cursor: progress; }

/* Toast */
.fb-toast {
  position: fixed;
  right: 20px;
  bottom: 76px;
  z-index: 10001;
  padding: 10px 16px;
  background: var(--surface);
  border: 1px solid var(--ok);
  border-radius: var(--r-sm);
  color: var(--text);
  font-size: 13px;
  box-shadow: var(--shadow-1);
  animation: fb-toast-in 0.2s ease-out;
}
@keyframes fb-toast-in {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}
@media (max-width: 640px) {
  .fb-toast { right: 12px; bottom: 58px; }
}

/* ─── Search modal (Cmd+K) ────────────────────────────────────── */
#search-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(8, 9, 11, 0.78);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: 80px 16px 16px;
  opacity: 0;
  transition: opacity 0.16s ease;
}
#search-modal-overlay.is-open {
  display: flex;
  opacity: 1;
}
.search-modal {
  width: 100%;
  max-width: 680px;
  max-height: calc(100vh - 96px);
  background: var(--surface);
  border: 1px solid var(--surface-hi);
  border-radius: 14px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.02) inset;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-family: var(--font-body, 'Inter', sans-serif);
  animation: search-modal-in 0.18s ease-out;
}
@keyframes search-modal-in {
  from { transform: translateY(-12px); opacity: 0; }
  to   { transform: translateY(0); opacity: 1; }
}
.search-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--surface-hi);
}
.search-icon {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  flex-shrink: 0;
}
.search-bar input {
  flex: 1;
  background: transparent;
  border: 0;
  outline: 0;
  font-size: 16px;
  font-weight: 500;
  color: var(--text);
  font-family: inherit;
  padding: 4px 0;
}
.search-bar input::placeholder {
  color: var(--text-muted);
}
/* Visible keyboard focus for the search field (it sets outline:0 above).
   :focus-visible only renders during keyboard nav, never on mouse click. */
.search-bar input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}
.search-close {
  background: var(--surface-2);
  border: 1px solid var(--surface-hi);
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  cursor: pointer;
  font-family: var(--font-mono, 'JetBrains Mono', monospace);
  text-transform: uppercase;
}
.search-close:hover {
  color: var(--text);
  background: var(--surface-hi);
}
.search-close:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.search-status {
  padding: 10px 18px;
  font-size: 12px;
  color: var(--text-muted);
  font-family: var(--font-mono, 'JetBrains Mono', monospace);
  letter-spacing: 0.04em;
  border-bottom: 1px solid var(--surface-hi);
  text-transform: uppercase;
}
.search-results {
  flex: 1;
  overflow-y: auto;
  padding: 8px 0;
  scrollbar-width: thin;
}
.search-result {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  width: 100%;
  background: transparent;
  border: 0;
  padding: 12px 18px;
  text-align: left;
  cursor: pointer;
  border-left: 3px solid transparent;
  transition: background 0.08s ease;
  font-family: inherit;
}
.search-result.is-active,
.search-result:focus-visible {
  background: var(--surface-2);
  border-left-color: var(--accent);
  outline: none;
}
.search-result-section {
  font-family: var(--font-mono, 'JetBrains Mono', monospace);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  padding-top: 2px;
  flex-shrink: 0;
  width: 28px;
}
.search-result-body {
  flex: 1;
  min-width: 0;
}
.search-result-primary {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
}
.search-result-sub {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
  line-height: 1.4;
}
.search-result-snippet {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.search-result mark {
  background: rgba(32, 128, 212, 0.22);
  color: var(--accent-text, #4FA8FF);
  border-radius: 2px;
  padding: 0 2px;
}
.search-signin-cta {
  background: var(--accent);
  border: 0;
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #fff;
  cursor: pointer;
  font-family: var(--font-mono, 'JetBrains Mono', monospace);
  text-transform: uppercase;
  margin-left: 8px;
}
.search-signin-cta:hover {
  background: var(--accent-hi, #3990E0);
}
.search-footer {
  padding: 10px 18px;
  font-size: 11px;
  color: var(--text-muted);
  border-top: 1px solid var(--surface-hi);
  font-family: var(--font-mono, 'JetBrains Mono', monospace);
  letter-spacing: 0.04em;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.search-footer kbd {
  background: var(--surface-2);
  border: 1px solid var(--surface-hi);
  border-radius: 4px;
  padding: 1px 5px;
  font-family: inherit;
  font-size: 10px;
  margin-right: 2px;
}

/* Topbar search button — hidden by default; shown by initAuthUI when
   the user is signed in + has completed the persona form. Mirrors the
   topbar-brand-link pattern. */
.topbar-search-btn {
  background: transparent;
  border: 1px solid var(--surface-hi);
  border-radius: 8px;
  padding: 6px 10px;
  display: none;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  color: var(--text-muted);
  font-family: var(--font-mono, 'JetBrains Mono', monospace);
  font-size: 12px;
  letter-spacing: 0.04em;
  transition: color 0.1s ease, border-color 0.1s ease, background 0.1s ease;
}
.topbar-search-btn.is-visible {
  display: inline-flex;
}
.topbar-search-btn:hover {
  color: var(--text);
  border-color: var(--accent);
  background: var(--surface-2);
}
.topbar-search-btn svg {
  width: 14px;
  height: 14px;
}
.topbar-search-btn .topbar-search-shortcut {
  background: var(--surface-2);
  border: 1px solid var(--surface-hi);
  border-radius: 4px;
  padding: 1px 5px;
  font-size: 10px;
  margin-left: 4px;
}
@media (max-width: 768px) {
  .topbar-search-btn-text,
  .topbar-search-btn .topbar-search-shortcut {
    display: none;
  }
  .topbar-search-btn {
    padding: 8px;
  }
  /* Modal goes full-screen on mobile */
  #search-modal-overlay {
    padding: 0;
  }
  .search-modal {
    max-width: 100%;
    max-height: 100vh;
    height: 100vh;
    border-radius: 0;
    border: 0;
  }
}

/* ─── Standardised footer (shared by SPA + all standalone pages) ──────────
   ONE footer everywhere (build.py PUBLIC_FOOTER), so it never restructures as
   you move around the site. "About" lives here now (moved out of the top nav). */
.dtc-footer { max-width: 1100px; margin: var(--s-8) auto 0; padding: var(--s-6) var(--s-5) var(--s-7); border-top: 1px solid var(--border); position: relative; z-index: 1; }
.dtc-footer-inner { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: var(--s-4); font-size: 13px; color: var(--text-dim); }
.dtc-footer-brand-col { display: flex; flex-direction: column; gap: 8px; }
.dtc-footer-brand { display: inline-flex; align-items: center; gap: 8px; color: var(--text); font-weight: 600; }
.dtc-footer-brand img { width: 18px; height: 18px; }
.dtc-footer-brand .accent { color: var(--accent-text); }
.dtc-footer-byline { color: var(--text-dim); }
.dtc-footer-byline a { color: var(--accent-text); }
.dtc-footer-social { display: inline-flex; align-items: center; gap: 14px; margin-top: 2px; }
.dtc-footer-social a { display: inline-flex; color: var(--text-dim); transition: color 0.15s, transform 0.15s; }
.dtc-footer-social a:hover { color: var(--accent-text); transform: translateY(-1px); }
.dtc-footer-social svg { width: 16px; height: 16px; display: block; }
.dtc-footer-nav { display: inline-flex; align-items: center; gap: var(--s-4); flex-wrap: wrap; }
.dtc-footer-nav a { color: var(--text-dim); transition: color 0.15s; }
.dtc-footer-nav a:hover { color: var(--accent-text); }
.dtc-footer-copy { max-width: 1100px; margin: var(--s-4) auto 0; padding: 0 var(--s-5); font-family: var(--font-mono); font-size: 10px; text-transform: uppercase; letter-spacing: 0.14em; color: var(--text-dim); text-align: center; }
@media (max-width: 640px) {
  .dtc-footer-inner { flex-direction: column; text-align: center; gap: var(--s-4); }
  .dtc-footer-brand-col { align-items: center; }
}

/* ─── Auth-aware public pages ─────────────────────────────────────────────
   The public standalone pages (preview / preview-page / preview-contents /
   preview-healthcheck) are served to everyone. The AUTH_AWARE snippet (see
   build.py) marks <html class="is-authed"> for signed-in visitors so they
   don't see signup CTAs meant for logged-out traffic. These rules are keyed
   on `.is-authed` (descendant selector → naturally higher specificity than
   the single-class inline CTA definitions; !important guards against inline
   display rules) and only ever HIDE conversion chrome or SWAP the topbar
   sign-in link — they never touch the anon experience. */
.is-authed .preview-cta-banner,
.is-authed .page-gate,
.is-authed .contents-gate,
.is-authed .contents-intro-actions,
.is-authed .preview-gate,
.is-authed .preview-rail-card { display: none !important; }

/* Constant topbar: swap "Sign in" for the account menu when authed. Applies to
   BOTH the static pages (is-authed set by AUTH_AWARE) AND the SPA (is-authed set
   synchronously in head.html, so the topbar paints in the right state instead of
   flashing logged-out while initAuthUI's async check runs). NO !important on the
   account menu / SPA sign-in button so initAuthUI's inline styles still win
   post-JS for the not-onboarded case (which must hide the menu). .auth-user-menu
   is display:none by default (above), so this reveal needs no !important either. */
.is-authed .auth-user-menu { display: block; }
.is-authed #auth-signin-btn { display: none; }
/* Static-page-only controls (PUBLIC_TOPBAR): no initAuthUI to defer to. */
.is-authed .topbar-signin { display: none !important; }
.is-authed .mobile-signin-only { display: none !important; }
.is-authed .mobile-authed-only { display: block !important; }
/* Kill the content flash: a signed-in visitor should never see the public
   marketing landing (#view-landing) while initAuthUI decides the real view. */
.is-authed #view-landing { display: none; }

/* Tool pages: unlock the .xlsx download for members (the file is already
   public; "Sign in to download" is only a conversion lever). The download
   link ships hidden inline; swap it in and hide the sign-in CTA when authed. */
.is-authed .preview-cta--signin { display: none !important; }
.is-authed .preview-cta--download { display: inline-flex !important; }


/* ─── Three Gates calculator (§26 interactive tool) ──────────────────────
   Mounts: SPA §26 embed (lazy module), My Brand dashboard (.tg-bare),
   and the public /finance-unit-economics/ + /tools/dtc-economics-calculator/
   pages (live compute-only, save gated behind sign-in). Logic spec:
   docs/three-gates-spec.md. New classes - no clash with head.html. */
.three-gates-calc { margin: var(--s-6) 0; padding: clamp(20px, 3vw, 28px); background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); }
.tg-calc-head { margin-bottom: var(--s-5); display: flex; align-items: flex-start; justify-content: space-between; gap: var(--s-4); }
.tg-calc-title { font-size: 20px; font-weight: 700; letter-spacing: -0.02em; color: var(--text); }
.tg-calc-sub { font-size: 13.5px; color: var(--text-dim); margin-top: 4px; line-height: 1.5; }

/* Share button (top-right of the card): copies the calculator's public link.
   Mirrors the .aside-share-tile icon-tile language; swaps to a check + green
   ring while .is-copied. */
.tg-share { position: relative; flex-shrink: 0; width: 36px; height: 36px; display: inline-flex; align-items: center; justify-content: center; padding: 0; background: var(--bg-void); border: 1px solid var(--border); border-radius: var(--r-md); color: var(--text-dim); cursor: pointer; transition: color 0.15s, border-color 0.15s; }
.tg-share:hover { color: var(--accent); border-color: var(--border-hi); }
.tg-share:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.tg-share svg { width: 16px; height: 16px; }
.tg-share .tg-share-ic-check { display: none; }
.tg-share.is-copied { color: var(--ok); border-color: var(--ok); }
.tg-share.is-copied .tg-share-ic-link { display: none; }
.tg-share.is-copied .tg-share-ic-check { display: block; }
.tg-share-status { position: absolute; top: calc(100% + 6px); right: 0; white-space: nowrap; font: 500 11px/1 var(--font-sans); color: var(--ok); pointer-events: none; }

.tg-inputs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-4) var(--s-5); }
@media (max-width: 560px) { .tg-inputs { grid-template-columns: 1fr; } }
.tg-field { display: flex; flex-direction: column; gap: 6px; }
.tg-field-label { font-size: 12.5px; color: var(--text-muted); font-weight: 500; }
.tg-input-wrap { position: relative; display: flex; align-items: center; }
.tg-input-wrap[data-prefix]::before { content: attr(data-prefix); position: absolute; left: 12px; color: var(--text-dim); font-size: 14px; pointer-events: none; }
.tg-input-wrap[data-suffix]::after { content: attr(data-suffix); position: absolute; right: 12px; color: var(--text-dim); font-size: 14px; pointer-events: none; }
.tg-input-wrap[data-prefix] .tg-in { padding-left: 26px; }
.tg-input-wrap[data-suffix] .tg-in { padding-right: 40px; }
.tg-in { width: 100%; box-sizing: border-box; padding: 10px 12px; font-size: 15px; font-family: var(--font-mono); color: var(--text); background: var(--bg-void); border: 1px solid var(--border); border-radius: var(--r-md); transition: border-color 0.15s; }
.tg-in:focus { outline: none; border-color: var(--accent); }

.tg-derived { margin: var(--s-5) 0 var(--s-4); font-size: 13.5px; color: var(--text-dim); font-family: var(--font-mono); }
.tg-derived strong { color: var(--text); margin-left: 6px; }

/* Shape line (v2): names the order shape from the first/repeat inputs -
   display only, never a verdict. Sits between derived and the gates. */
.tg-shape { margin: calc(var(--s-4) * -0.5) 0 var(--s-4); font-size: 12.5px; line-height: 1.5; color: var(--text-muted); }
.tg-shape[hidden] { display: none; }

/* Tail inputs (years 2+) revealed by the LTV window control - needs its own
   top gap since the toggle above carries no bottom margin. The explicit
   [hidden] rule is load-bearing: .tg-inputs sets display:grid, which beats
   the UA stylesheet's [hidden] { display:none }. */
.tg-tail { margin-top: var(--s-4); }
.tg-tail[hidden] { display: none; }

/* Payback curve chart (v3, spec 11.3): cumulative contribution staircase
   with the nCAC reference line. Pure inline SVG, token colours only. */
.tg-chart { margin-top: var(--s-4); position: relative; }
.tg-ch-pt { fill: var(--accent); }
.tg-chart [data-tip] { cursor: pointer; }
.tg-chart [data-tip]:hover + .tg-ch-pt { fill: var(--blue-text, #58A9F0); }
/* Custom hover/tap tooltip - native SVG <title> was unreliable. */
.tg-ch-tip { position: absolute; transform: translate(-50%, -100%); max-width: 280px; padding: 8px 10px; background: var(--bg-void); border: 1px solid var(--border-hi); border-radius: var(--r-md); box-shadow: 0 8px 24px rgba(0,0,0,0.5); font: 400 11.5px/1.5 var(--font-sans); color: var(--text-muted); text-align: left; pointer-events: none; z-index: 20; }
.tg-ch-tip[hidden] { display: none; }
.tg-chart svg { display: block; width: 100%; height: auto; }
.tg-ch-line { fill: none; stroke: var(--accent); stroke-width: 2; }
.tg-ch-ncac { stroke: var(--text-dim); stroke-width: 1; stroke-dasharray: 4 4; }
.tg-ch-grid { stroke: var(--border); stroke-width: 1; }
.tg-ch-dot { fill: var(--ok); }
.tg-ch-lbl { fill: var(--text-dim); font: 500 10px var(--font-mono); }
.tg-ch-lbl--ltv { fill: var(--text); }

/* "same as first order" mirror reset - appears when the repeat field has
   been edited away from the first-order value. */
.tg-mirror-reset { margin-left: 8px; padding: 0; border: 0; background: none; color: var(--accent); font: 500 11.5px/1 var(--font-sans); cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.tg-mirror-reset:hover { color: var(--accent-hi); }
.tg-mirror-reset[hidden] { display: none; }

/* (i) tooltips per input. Open on hover / keyboard focus (pure CSS) or
   click/tap (.is-open, wired in the module - the wrapping <label> would
   otherwise steal the tap). */
.tg-info { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; margin-left: 6px; vertical-align: -3px; color: var(--text-dim); cursor: help; }
.tg-info svg { width: 14px; height: 14px; }
.tg-info:hover, .tg-info:focus-visible, .tg-info.is-open { color: var(--accent); }
.tg-info:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 50%; }
.tg-tipbox { display: none; position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%); width: min(260px, 74vw); padding: 10px 12px; background: var(--bg-void); border: 1px solid var(--border-hi); border-radius: var(--r-md); box-shadow: 0 8px 24px rgba(0,0,0,0.5); font: 400 12px/1.55 var(--font-sans); color: var(--text-muted); text-align: left; z-index: 30; }
.tg-info:hover .tg-tipbox, .tg-info:focus-visible .tg-tipbox, .tg-info.is-open .tg-tipbox { display: block; }
/* Right-column fields (2-col grid: even children): a centered popup overflows
   the card/viewport edge - anchor it to the icon's right instead so it
   extends left over the calculator. Same treatment for everything in the
   1-col mobile layout. */
.tg-field:nth-child(even) .tg-tipbox { left: auto; right: -8px; transform: none; }
@media (max-width: 560px) { .tg-tipbox { left: auto; right: -8px; transform: none; } }

/* Orders/cadence contradiction notice - amber, mirrors the threshold row tone. */
.tg-consistency { margin-top: var(--s-4); padding: 10px 12px; background: rgba(245,158,11,0.07); border: 1px solid rgba(245,158,11,0.3); border-left: 3px solid var(--warn); border-radius: var(--r-md); font-size: 12.5px; line-height: 1.5; color: var(--text-muted); }
.tg-consistency[hidden] { display: none; }

.tg-gates { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-4); }
@media (max-width: 720px) { .tg-gates { grid-template-columns: 1fr; } }
/* Band colour lives IN the card (tint + dot/word) - no left-edge accent,
   per the MS 2.0 card standard (Rob, 2026-07-03). */
.tg-gate { padding: var(--s-4) var(--s-5); border: 1px solid var(--border); border-radius: var(--r-md); background: var(--surface-2); display: flex; flex-direction: column; gap: 8px; }
.tg-gate--green { background: linear-gradient(135deg, rgba(34,197,94,0.09), transparent 55%), var(--surface-2); }
.tg-gate--amber { background: linear-gradient(135deg, rgba(245,158,11,0.09), transparent 55%), var(--surface-2); }
.tg-gate--red { background: linear-gradient(135deg, rgba(239,68,68,0.09), transparent 55%), var(--surface-2); }
.tg-gate-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.tg-gate-name { font-size: 13px; font-weight: 600; color: var(--text); }
.tg-gate-num { font-family: var(--font-mono); font-size: 10px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-dim); display: block; }
.tg-band { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 600; color: var(--text-muted); white-space: nowrap; }
.tg-band-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--text-dim); flex-shrink: 0; }
.tg-gate--green .tg-band-dot { background: var(--ok); } .tg-gate--green .tg-band-word { color: var(--ok); }
.tg-gate--amber .tg-band-dot { background: var(--warn); } .tg-gate--amber .tg-band-word { color: var(--warn); }
.tg-gate--red .tg-band-dot { background: var(--err); } .tg-gate--red .tg-band-word { color: var(--err); }
.tg-gate-value .tg-num { display: block; font-size: 23px; font-weight: 800; letter-spacing: -0.02em; color: var(--text); font-family: var(--font-mono); }
.tg-gate-value .tg-sub { display: block; font-size: 11.5px; color: var(--text-dim); margin-top: 2px; line-height: 1.4; }
.tg-gate-verdict { font-size: 12.5px; line-height: 1.5; color: var(--text-muted); }

.tg-actions { display: flex; align-items: center; gap: var(--s-4); margin-top: var(--s-5); }
.tg-save { padding: 10px 18px; border-radius: var(--r-md); background: var(--accent); color: #fff; border: 1px solid rgba(255,255,255,0.1); font: 600 14px/1 var(--font-sans); cursor: pointer; transition: background 0.15s; }
.tg-save:hover { background: var(--accent-hi); }
.tg-save:disabled { opacity: 0.6; cursor: default; }
.tg-save-status { font-size: 13px; color: var(--text-dim); }
.tg-save-status.is-ok { color: var(--ok); }
.tg-save-status.is-error { color: var(--err); }

/* Dashboard mount: drop the outer card chrome so it sits flush inside .panel. */
.tg-bare .three-gates-calc { margin: 0; border: 0; background: transparent; padding: 0; }

.tg-gate--na .tg-band-word { color: var(--text-dim); }
.tg-gate--na .tg-gate-value .tg-num { color: var(--text-dim); }
.tg-toggle { display: flex; align-items: center; justify-content: space-between; gap: var(--s-4); flex-wrap: wrap; margin: var(--s-5) 0 0; padding: 12px 14px; background: var(--bg-void); border: 1px solid var(--border); border-radius: var(--r-md); }
.tg-toggle-label { font-size: 12.5px; color: var(--text-muted); font-weight: 500; }
.tg-toggle-btns { display: inline-flex; gap: 4px; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--r-md); padding: 3px; }
.tg-toggle-btn { padding: 7px 12px; border: 0; background: transparent; color: var(--text-dim); font: 600 12.5px/1 var(--font-sans); border-radius: calc(var(--r-md) - 3px); cursor: pointer; transition: background 0.15s, color 0.15s; white-space: nowrap; }
.tg-toggle-btn:hover { color: var(--text); }
.tg-toggle-btn.is-on { background: var(--accent); color: #fff; }
.tg-foot { margin-top: var(--s-4); font-size: 11.5px; color: var(--text-dim); line-height: 1.5; }

/* Public-page CTA under the live calculator (preview + tools leaf pages).
   Anchors reuse each template's inline .preview-cta styling; the pair swaps
   on .is-authed exactly like the tool-download signin/download pair above.
   (Static pages can't save - no bearer token - so authed visitors are routed
   into the SPA dashboard to persist their numbers.) */
.tg-public-cta { margin: var(--s-4) 0 var(--s-6); text-align: center; }
/* Two-class selector: the templates' inline .preview-cta base style
   (display:inline-flex) loads AFTER the hashed stylesheet and would win a
   single-class tie (gotcha #1's cascade-order trap, template edition). */
.tg-public-cta .tg-cta--dashboard { display: none; }
.is-authed .tg-cta--signin { display: none !important; }
.is-authed .tg-cta--dashboard { display: inline-flex !important; }
/* ─── Metrics Profile (wave 0 - dashboard "Your metrics" panel) ──────────
   Fields/tooltips/toggles reuse the calculator's .tg-* components; only the
   grouping chrome is new. .dash-nav is the dashboard sub-nav (tabs
   precursor per Rob 2026-07-03). */
/* Dashboard shell: left rail + tab panels (2026-07; replaced the .dash-nav
   anchor pills). Desktop = sticky grouped rail; <=900px the rail collapses
   to a sticky horizontal pill bar (same language as .index-jumpnav). */
.dash-shell { display: grid; grid-template-columns: 192px minmax(0, 1fr); gap: var(--s-6); align-items: start; margin-top: var(--s-4); }
.dash-rail { position: sticky; top: 78px; display: flex; flex-direction: column; gap: 2px; }
.dash-rail-group {
  font-family: var(--font-mono); font-size: 10px; font-weight: 600;
  letter-spacing: 0.15em; text-transform: uppercase; color: var(--text-dim);
  margin: var(--s-4) 0 4px; padding: 0 12px;
}
.dash-rail-item {
  position: relative; display: flex; align-items: center; gap: 8px;
  padding: 8px 12px; border-radius: 8px; border: 1px solid transparent;
  color: var(--text-muted); font: 600 13px/1.2 var(--font-sans);
  text-decoration: none; cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.dash-rail-item:hover { background: var(--surface); color: var(--text); }
.dash-rail-item.is-active { background: var(--surface); border-color: var(--border); color: var(--text); }
.dash-rail-item.is-active::before {
  content: ""; position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 3px; height: 55%; border-radius: 2px; background: var(--accent);
}
/* Launch pills on the 2026-07 surfaces (metrics profile, calculators,
   action plan). Label is "Beta" - Rob's explicit call 2026-07-16, overriding
   the earlier never-beta preference for these launch tags. Class names keep
   the -new- form (cosmetic only). Remove ~2026-09 / when the suite settles. */
.dash-rail-new-tag {
  margin-left: auto; font: 600 9px/1 var(--font-mono); letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--accent);
  border: 1px solid rgba(32,128,212,0.45); border-radius: 999px; padding: 3px 7px;
}
.nav-new-tag {
  margin-left: 6px; font: 600 8.5px/1 var(--font-mono); letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--accent);
  border: 1px solid rgba(32,128,212,0.45); border-radius: 999px; padding: 2px 6px;
  vertical-align: 2px; white-space: nowrap;
}
.dash-tab { display: block; min-width: 0; }
.dash-tab[hidden] { display: none; }
.dash-fixnext { display: flex; flex-direction: column; gap: 8px; }
.dash-exports { display: flex; gap: var(--s-3); flex-wrap: wrap; }
@media (max-width: 900px) {
  .dash-shell { display: block; }
  .dash-rail {
    top: 62px; z-index: 40; flex-direction: row; overflow-x: auto; gap: 6px;
    padding: 10px 0; margin-bottom: var(--s-4);
    background: color-mix(in oklab, var(--bg) 88%, transparent);
    backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--border); scrollbar-width: thin;
  }
  .dash-rail-group { display: none; }
  .dash-rail-item { flex-shrink: 0; border: 1px solid var(--border); border-radius: 999px; background: var(--surface); padding: 7px 13px; }
  .dash-rail-item.is-active { border-color: var(--accent-text); }
  .dash-rail-item.is-active::before { display: none; }
}
.dash-anchor { scroll-margin-top: 84px; }

.mp-panel { display: flex; flex-direction: column; gap: var(--s-3); }
.mp-note { font-size: 12.5px; line-height: 1.5; color: var(--text-dim); }
.mp-note strong { color: var(--warn); font-weight: 600; }

/* Calculators tab: pill picker for the inline decision calculators (2026-07-16).
   One pill per calc-kit tool; the active tool's .dash-calc-mount shows, the
   rest stay [hidden] (explicit companion rule per CSS gotcha #16). */
.dash-calc-picker { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 var(--s-4); }
.dash-calc-pill { font: 600 13px/1 var(--font-sans); padding: 9px 14px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text-muted); cursor: pointer; transition: border-color .15s ease, color .15s ease, background .15s ease; }
.dash-calc-pill:hover { border-color: var(--border-hi); color: var(--text); }
.dash-calc-pill:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.dash-calc-pill.is-on { background: rgba(32,128,212,0.12); border-color: var(--accent); color: var(--text); }
.dash-calc-mount[hidden] { display: none; }

/* ─── Action Plan tab (2026-07-16) ─────────────────────────────────────
   Categories ranked weakest-first, each with its HC recommendation and
   per-section <details> accordions of live-tickable checklist items. */
.ap-groups { display: flex; flex-direction: column; gap: var(--s-5); }
.ap-group { border: 1px solid var(--border); border-radius: var(--r-md); background: var(--surface); padding: var(--s-4) var(--s-5); }
.ap-group-head { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.ap-group-name { font: 700 15px/1.2 var(--font-sans); color: var(--text); }
.ap-group-score { font: 600 11.5px/1 var(--font-mono); color: var(--hc-tone, var(--text-dim)); border: 1px solid currentColor; border-radius: 999px; padding: 4px 9px; white-space: nowrap; }
.ap-group-rec { margin: 0 0 var(--s-3); font-size: 13px; line-height: 1.55; color: var(--text-muted); }
.ap-sec { border-top: 1px solid var(--border); }
.ap-sec-sum { display: flex; align-items: center; gap: 10px; padding: 11px 4px; cursor: pointer; list-style: none; }
.ap-sec-sum::-webkit-details-marker { display: none; }
.ap-sec-sum:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ap-sec-tag { font: 600 11px/1 var(--font-mono); color: var(--text-dim); }
.ap-sec-title { flex: 1; min-width: 0; font: 600 13.5px/1.3 var(--font-sans); color: var(--text); }
.ap-sec-hc { font: 600 11.5px/1 var(--font-mono); color: var(--hc-tone, var(--text-dim)); white-space: nowrap; }
.ap-sec-open { font: 600 11px/1 var(--font-mono); color: var(--text-muted); white-space: nowrap; }
.ap-sec-open.is-clear { color: var(--text-dim); }
.ap-sec-chev { width: 8px; height: 8px; border-right: 1.5px solid var(--text-dim); border-bottom: 1.5px solid var(--text-dim); transform: rotate(-45deg); transition: transform .15s ease; flex: none; }
.ap-sec[open] > .ap-sec-sum .ap-sec-chev { transform: rotate(45deg); }
.ap-items { display: flex; flex-direction: column; padding: 0 4px var(--s-2); }
.ap-item { display: flex; align-items: flex-start; gap: 10px; padding: 6px 0; font-size: 13.5px; line-height: 1.45; color: var(--text-muted); cursor: pointer; }
.ap-item input { accent-color: var(--accent); margin-top: 2px; flex: none; cursor: pointer; }
.ap-item.is-done span { color: var(--text-dim); text-decoration: line-through; }
.ap-sec-link { display: inline-block; margin: 0 4px var(--s-3); font-size: 12.5px; color: var(--accent); text-decoration: none; }
.ap-sec-link:hover { text-decoration: underline; }

/* ─── Benchmarks tab (2026-07-16 plan; ledger re-layout 2026-07-21) ────
   Aligned ledger table over the Metrics Profile: ONE shared column
   template (--dbm-cols on #dbm-mount) on every group header + row, so
   values/verdicts/links align across all four groups by construction.
   Band tones ride the .tg-band-dot via the row modifier. Notes render
   as a full-width sub-line (grid-column 1/-1) under the row's main line. */
#dbm-mount { container-type: inline-size; --dbm-cols: minmax(160px, 1.6fr) 96px minmax(170px, 1.2fr) 92px 124px; }
.dbm-controls { display: flex; flex-direction: column; gap: var(--s-3); margin: 0 0 var(--s-4); }
.dbm-control { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.dbm-control-label { font: 600 10px/1 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-dim); min-width: 112px; }
.dbm-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.dbm-pill { font: 600 12px/1 var(--font-sans); padding: 7px 11px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text-muted); cursor: pointer; transition: border-color .15s ease, color .15s ease; }
.dbm-pill:hover { border-color: var(--border-hi); color: var(--text); }
.dbm-pill:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.dbm-pill.is-on { background: rgba(32,128,212,0.12); border-color: var(--accent); color: var(--text); }
.dbm-pill-sub { margin-left: 5px; font: 500 10px/1 var(--font-mono); color: var(--text-dim); }
.dbm-meta { font-size: 12.5px; line-height: 1.55; color: var(--text-dim); margin: 0 0 var(--s-4); }
.dbm-meta a { color: var(--accent); }
.dbm-meta-n { font: 600 12px/1 var(--font-mono); color: var(--text-muted); }
.dbm-group { border-top: 2px solid var(--border-hi); padding: 0; margin: 0 0 var(--s-5); }
.dbm-ghead { display: grid; grid-template-columns: var(--dbm-cols); column-gap: 16px; align-items: baseline; padding: 10px 0 8px; }
.dbm-group-name { font: 600 10.5px/1 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-dim); }
.dbm-cap { font: 500 9.5px/1 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-dim); }
.dbm-cap--you { text-align: right; }
.dbm-row { display: grid; grid-template-columns: var(--dbm-cols); column-gap: 16px; row-gap: 3px; align-items: baseline; padding: 9px 0; border-top: 1px solid var(--border); }
.dbm-label { font: 600 13px/1.35 var(--font-sans); color: var(--text); }
/* No nowrap: long grader displays ("immediate", "beyond the curve") must
   wrap inside the fixed You column, not overflow into Target. */
.dbm-value { font: 600 14px/1.3 var(--font-mono); color: var(--text); text-align: right; font-variant-numeric: tabular-nums; }
.dbm-value--na { color: var(--text-ghost, var(--text-dim)); }
.dbm-bandtext { font-size: 12px; line-height: 1.5; color: var(--text-muted); }
.dbm-note { grid-column: 1 / -1; font-size: 12px; line-height: 1.5; color: var(--text-dim); max-width: 62em; }
.dbm-add { color: var(--accent); text-decoration: none; }
.dbm-add:hover { text-decoration: underline; }
.dbm-verdict { display: inline-flex; align-items: center; gap: 6px; font: 600 10.5px/1 var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-muted); white-space: nowrap; }
.dbm-row--green .tg-band-dot { background: #4ADE80; }
.dbm-row--amber .tg-band-dot { background: #FB923C; }
.dbm-row--red .tg-band-dot { background: #F87171; }
.dbm-row--info .tg-band-dot { background: var(--accent); }
.dbm-row--na .tg-band-dot { background: var(--border-hi); }
.dbm-links { display: flex; gap: 10px; justify-content: flex-end; }
.dbm-links a { font-size: 12px; color: var(--accent); text-decoration: none; white-space: nowrap; }
.dbm-links a:hover { text-decoration: underline; }
.dbm-hc { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; border: 1px solid var(--border-hi); border-radius: 10px; background: rgba(32,128,212,0.06); padding: 10px 16px; margin: 0 0 var(--s-4); }
.dbm-hc-k { font: 600 10px/1 var(--font-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-dim); white-space: nowrap; }
.dbm-hc-body { font-size: 12.5px; line-height: 1.55; color: var(--text-muted); }
.dbm-hc-body strong { color: var(--text); }
.dbm-hc-wait { color: var(--text-dim); }
.dbm-foot { display: flex; flex-direction: column; gap: 4px; font-size: 12.5px; color: var(--text-dim); border-top: 1px solid var(--border); padding-top: 12px; }
.dbm-foot a { color: var(--accent); }
.dbm-foot-note { font-size: 12px; }

/* Public /benchmarks/ topic pages: "see where your numbers sit" tie-in.
   Anon/authed pair swaps on html.is-authed (AUTH_AWARE pattern). */
.bm-compare-cta { display: flex; align-items: center; gap: var(--s-4); flex-wrap: wrap; border: 1px solid var(--border-hi); border-radius: var(--r-md); background: rgba(32,128,212,0.06); padding: var(--s-4) var(--s-5); margin: var(--s-5) 0; }
.bm-compare-copy { flex: 1; min-width: 240px; font-size: 13.5px; line-height: 1.55; color: var(--text-muted); }
.bm-compare-copy strong { color: var(--text); }
.bm-compare-authed { display: none; }
.is-authed .bm-compare-anon { display: none; }
.is-authed .bm-compare-authed { display: inline-flex; }
/* Stacked ledger rows when the MOUNT is narrow - a container query so the
   901-1000px viewport range (dash rail still present, content squeezed)
   stacks too, not just small viewports. The 720px media block below is the
   identical declaration set as a pre-container-query fallback. */
@container (max-width: 740px) {
  .dbm-ghead { grid-template-columns: 1fr; }
  .dbm-cap { display: none; }
  .dbm-row { grid-template-columns: 1fr auto; align-items: center; row-gap: 4px; grid-template-areas: "label value" "bandtext bandtext" "note note" "verdict links"; }
  .dbm-label { grid-area: label; } .dbm-value { grid-area: value; }
  .dbm-bandtext { grid-area: bandtext; } .dbm-note { grid-area: note; }
  .dbm-verdict { grid-area: verdict; } .dbm-links { grid-area: links; justify-self: end; }
}
@media (max-width: 720px) {
  .dbm-ghead { grid-template-columns: 1fr; }
  .dbm-cap { display: none; }
  .dbm-row { grid-template-columns: 1fr auto; align-items: center; row-gap: 4px; grid-template-areas: "label value" "bandtext bandtext" "note note" "verdict links"; }
  .dbm-label { grid-area: label; } .dbm-value { grid-area: value; }
  .dbm-bandtext { grid-area: bandtext; } .dbm-note { grid-area: note; }
  .dbm-verdict { grid-area: verdict; } .dbm-links { grid-area: links; justify-self: end; }
}

/* Save-capability note under calc-kit tools on PUBLIC/standalone pages (no
   core.js -> edits can't reach the brand row). Anon/authed variants swap on
   html.is-authed, same pattern as the Three Gates .tg-public-cta pair. */
.calc-save-note { margin-top: var(--s-3); font-size: 12.5px; line-height: 1.5; color: var(--text-dim); }
.calc-save-note a { color: var(--accent); }
.calc-save-note-authed { display: none; }
.is-authed .calc-save-note-anon { display: none; }
.is-authed .calc-save-note-authed { display: inline; }
.mp-group { border: 1px solid var(--border); border-radius: var(--r-md); background: var(--bg-void); padding: 0; }
.mp-group summary { display: flex; align-items: center; justify-content: space-between; gap: var(--s-4); padding: 12px 14px; cursor: pointer; font: 600 13px/1 var(--font-sans); color: var(--text); list-style: none; }
.mp-group summary::-webkit-details-marker { display: none; }
.mp-group-name { display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.mp-soon-tag { font: 500 10px/1 var(--font-mono); text-transform: uppercase; letter-spacing: 0.06em; color: var(--accent-text, var(--accent)); border: 1px solid var(--border-hi); border-radius: 999px; padding: 4px 8px; }
.mp-group summary::after { content: '+'; color: var(--text-dim); font-weight: 500; margin-left: 8px; }
.mp-group[open] summary::after { content: '\2212'; }
.mp-count { font: 500 11px/1 var(--font-mono); color: var(--text-dim); border: 1px solid var(--border); border-radius: 999px; padding: 4px 8px; }
.mp-grid { padding: 4px 14px 14px; }
.mp-derive { display: flex; align-items: center; gap: var(--s-4); flex-wrap: wrap; padding: 0 14px 12px; }
.mp-derive-out { font-size: 12px; color: var(--text-muted); }
/* "Use X" import button - the one path that writes a builder's target field */
.mp-use-btn { font: 700 11px/1 var(--font-sans); padding: 7px 13px; border-radius: 999px; border: 0; background: var(--accent); color: #fff; cursor: pointer; white-space: nowrap; transition: filter .15s ease; }
.mp-use-btn:hover { filter: brightness(1.08); }
.mp-use-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.mp-use-btn[hidden] { display: none; }
.mp-sources { padding: 0 14px 12px; }
.mp-sources summary { font: 500 12px/1 var(--font-sans); color: var(--accent-text, var(--accent)); cursor: pointer; padding: 4px 0; }
.mp-sources ul { margin: 8px 0 0; padding-left: 18px; }
.mp-sources li { font-size: 12px; line-height: 1.6; color: var(--text-dim); margin-bottom: 4px; }
.mp-sources li strong { color: var(--text-muted); font-weight: 600; }

/* Component builders nested inside Core (2026-07-16 de-dup): "don't know
   your contribution margin / nCAC? build it" expanders that replaced the
   peer margin/acquisition accordions. The .mp-group summary rules cascade
   onto these summaries; the overrides below re-key the +/- marker off the
   BUILDER's own open state (the ancestor group's [open] would win a tie). */
.mp-builder { margin: var(--s-2) 14px 12px; border: 1px dashed var(--border); border-radius: var(--r-md); background: rgba(255,255,255,0.015); }
.mp-builder summary { padding: 10px 12px; font: 600 12.5px/1.3 var(--font-sans); color: var(--text-muted); }
.mp-builder-name { flex: 1; min-width: 0; }
.mp-group .mp-builder summary::after { content: '+'; }
.mp-group .mp-builder[open] summary::after { content: '\2212'; }
.mp-builder .mp-grid { padding: 0 12px; }
.mp-builder .mp-derive { padding: 8px 12px 10px; }
.mp-builder .mp-sources { padding: 0 12px 10px; }

/* Provenance chip on auto-derived fields (contribution margin / nCAC). */
.mp-derived-chip { font: 600 9px/1 var(--font-mono); text-transform: uppercase; letter-spacing: 0.06em; color: var(--accent); border: 1px solid rgba(32,128,212,0.45); border-radius: 999px; padding: 3px 7px; margin-left: 6px; white-space: nowrap; }
.mp-derived-chip[hidden] { display: none; }

/* ─── calc-kit decision calculators (wave 1) ─────────────────────────────
   Reuse the .tg-* input/tooltip/share components; add verdict + output
   cards (.calc-*). Band colour lives in the card (MS 2.0 standard). */
.calc-tool { margin: var(--s-6) 0; padding: clamp(20px, 3vw, 28px); background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); }
.calc-verdict { margin: var(--s-5) 0 var(--s-4); padding: var(--s-4) var(--s-5); border: 1px solid var(--border); border-radius: var(--r-md); background: var(--surface-2); }
.calc-verdict--green { background: linear-gradient(135deg, rgba(34,197,94,0.09), transparent 55%), var(--surface-2); }
.calc-verdict--amber { background: linear-gradient(135deg, rgba(245,158,11,0.09), transparent 55%), var(--surface-2); }
.calc-verdict--red { background: linear-gradient(135deg, rgba(239,68,68,0.09), transparent 55%), var(--surface-2); }
.calc-verdict-band { display: inline-flex; align-items: center; gap: 6px; font: 600 11px/1 var(--font-sans); text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); margin-bottom: 8px; }
.calc-verdict--green .tg-band-dot { background: var(--ok); } .calc-verdict--green .tg-band-word { color: var(--ok); }
.calc-verdict--amber .tg-band-dot { background: var(--warn); } .calc-verdict--amber .tg-band-word { color: var(--warn); }
.calc-verdict--red .tg-band-dot { background: var(--err); } .calc-verdict--red .tg-band-word { color: var(--err); }
.calc-verdict--na .tg-band-dot { background: var(--text-dim); } .calc-verdict--na .tg-band-word { color: var(--text-dim); }
.calc-verdict-headline { font-size: 17px; font-weight: 700; letter-spacing: -0.01em; color: var(--text); line-height: 1.3; }
.calc-verdict-detail { margin-top: 6px; font-size: 13px; line-height: 1.55; color: var(--text-muted); }
.calc-outputs { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: var(--s-4); margin-bottom: var(--s-4); }
.calc-out { padding: var(--s-4); border: 1px solid var(--border); border-radius: var(--r-md); background: var(--bg-void); display: flex; flex-direction: column; gap: 3px; }
.calc-out-value { font: 800 21px/1.1 var(--font-mono); letter-spacing: -0.02em; color: var(--text); }
.calc-out-label { font-size: 12.5px; font-weight: 600; color: var(--text-muted); margin-top: 4px; }
.calc-out-sub { font-size: 11px; line-height: 1.45; color: var(--text-dim); }
.calc-foot { font-size: 11.5px; line-height: 1.6; color: var(--text-dim); }
.calc-foot a { color: var(--accent-text, var(--accent)); }
.calc-profile-link { font-weight: 600; }
/* "Prefilled with an example" hint (F8): shown until the profile covers the
   surfaced inputs. Honour [hidden] explicitly (see CSS gotcha #16). */
/* "These are example numbers" (H). Was 12px --text-dim mono, the lowest-
   contrast text on the page, sitting directly above a colour-washed verdict
   card - so on a public calculator the worked example read as an answer.
   Now an amber-tinted strip ABOVE the verdict it qualifies. */
.calc-example-note {
  display: block; margin: 0 0 var(--s-4); padding: 9px 13px;
  font: 500 12.5px/1.5 var(--font-mono); color: var(--text-muted);
  background: rgba(245, 158, 11, 0.08);
  border: 1px solid rgba(245, 158, 11, 0.28); border-radius: var(--r-md);
}
.calc-example-note strong { color: var(--text); }
.calc-example-note[hidden] { display: none; }

/* Orientation block (2026-07-22): "Use it when" / "Reading it", emitted by
   calc-kit for every surface EXCEPT the section embeds (where the teaching
   prose above the calculator already frames it). Exists for the dashboard
   Calculators tab, where most signed-in founders meet these tools with no
   surrounding copy at all. */
.calc-context {
  margin: 0 0 var(--s-4); padding: 12px 15px;
  background: var(--surface-2, rgba(255,255,255,0.02));
  border: 1px solid var(--border); border-radius: var(--r-md);
}
.calc-context p { margin: 0; font-size: 13px; line-height: 1.6; color: var(--text-muted); }
.calc-context p + p { margin-top: 7px; }
.calc-context strong {
  display: inline-block; margin-right: 6px; color: var(--text);
  font: 600 10.5px/1.3 var(--font-mono); text-transform: uppercase; letter-spacing: 0.09em;
}

/* Full-width subhead inside the .tg-inputs grid, for tools whose questions
   split into distinct clusters (Can I Scale Ads: the spend measurement vs the
   customer economics). Emitted by calc-kit when an input's `group` changes. */
.calc-group-head {
  grid-column: 1 / -1; margin: var(--s-2) 0 calc(var(--s-2) * -1 + 2px);
  font: 600 11px/1.3 var(--font-mono); text-transform: uppercase;
  letter-spacing: 0.09em; color: var(--text-dim);
}
.calc-group-head:first-child { margin-top: 0; }
/* "Where to find these numbers" list (G) - the registry `source` strings,
   which previously rendered only in the dashboard profile panel. */
.calc-sources { margin: var(--s-4) 0 0; }

/* Calculators hub suite note (forward-looking suite-is-growing signal). */
.calc-hub-wip { margin: 0 0 var(--s-5); padding: 12px 16px; background: rgba(32,128,212,0.06); border: 1px solid var(--border-hi); border-radius: var(--r-md); font-size: 13.5px; line-height: 1.55; color: var(--text-muted); }
.calc-hub-wip strong { color: var(--text); }

/* --- Section TOC / TL;DR / meta strip (2026-07) --------------------------
   Rendered by build.py (_section_toc_html / _section_tldr_html /
   _section_meta_html) on BOTH the authed SPA section view and the public
   /{slug}/ preview pages. */
.section-meta-strip {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-top: var(--s-3);
}
.section-meta-strip .sep { color: var(--text-ghost); }

/* TL;DR box - callout family, accent tone, bullets instead of prose. */
.callout-tldr { --cw-tone: var(--accent); }
.callout-tldr .callout-label { color: var(--accent-text); }
.callout-tldr ul { margin: 0; padding-left: 20px; }
.callout-tldr li { margin: 5px 0; line-height: 1.6; }

/* Jump-TOC links (SPA aside + preview rail reuse .aside-toc row styling). */
.aside-toc a { color: inherit; text-decoration: none; display: block; }
/* Safety net on every TOC surface: the list must never run off the bottom
   of the sticky aside/rail - cap it and scroll within. */
.section-aside .aside-toc,
.preview-rail-toc .aside-toc { max-height: 44vh; overflow-y: auto; margin-bottom: 0; }
.section-aside .aside-toc { margin-bottom: var(--s-6); }
/* The TOC is reading chrome, not a signup CTA - keep it visible for
   signed-in visitors (the .is-authed rule hides every .preview-rail-card). */
.is-authed .preview-rail-card.preview-rail-toc { display: block !important; }

/* Mobile inline TOC (preview pages only - the rail is desktop-only). */
.section-toc-inline {
  margin: var(--s-5) 0;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--surface);
  padding: 12px var(--s-4);
}
.section-toc-inline summary {
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--text-dim);
}
.section-toc-inline[open] summary { margin-bottom: 10px; }
.section-toc-inline .aside-toc { margin-bottom: 0; }
@media (min-width: 960px) {
  .section-toc-inline { display: none; }
}

/* Anchor landings clear the sticky topbar (TOC links + search deep-links). */
.section-body-content h3, .section-body-content h4 { scroll-margin-top: 84px; }

/* --- Boot loader + static-page nav feedback (2026-07-06) -----------------
   .boot-loader: full-screen cover shown synchronously (html.is-booting,
   flipped by the inline cookie check after <body>) while the SPA boots for
   a signed-in arrival; hidden by showView() on the first real view render.
   .nav-progress: thin indeterminate top bar injected by AUTH_AWARE_SNIPPET
   on static pages the instant a signed-in user clicks into an SPA view, so
   the click is acknowledged before the navigation lands. */
.boot-loader {
  position: fixed; inset: 0; z-index: 4000;
  display: none;
  align-items: center; justify-content: center; flex-direction: column;
  gap: 22px;
  background: var(--bg);
}
html.is-booting .boot-loader { display: flex; }
.boot-loader-brand {
  font-size: 19px; font-weight: 800; letter-spacing: -0.02em;
  color: var(--text);
}
.boot-loader-brand .accent { color: var(--accent); }
.boot-loader-track {
  width: 180px; height: 2px; border-radius: 2px;
  background: var(--surface-2, var(--surface));
  overflow: hidden; position: relative;
}
.boot-loader-fill {
  position: absolute; top: 0; left: 0; height: 100%; width: 40%;
  border-radius: 2px;
  background: var(--accent);
  animation: boot-loader-slide 1.1s ease-in-out infinite;
}
@keyframes boot-loader-slide {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(450%); }
}
.nav-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 4000;
  background: var(--surface-2, var(--surface));
  overflow: hidden;
}
.nav-progress::after {
  content: ""; position: absolute; top: 0; left: 0; height: 100%; width: 35%;
  background: var(--accent);
  animation: boot-loader-slide 1.1s ease-in-out infinite;
}
@media (prefers-reduced-motion: reduce) {
  .boot-loader-fill, .nav-progress::after { animation: none; width: 100%; opacity: 0.5; }
}

/* ============================================================
   DESIGN V4 (2026-07-18) - production layer, Phase 4.
   Ported from static/design-studies/v4/a3/styles.css (the locked
   mock). Tokens are SCOPED to .v4-scope so MS 2.0 surfaces are
   untouched during migration; MS rules above remain until every
   surface migrates, then get cleaned up (MS 2.0 playbook).
   Fonts: Hanken Grotesk + Newsreader + Spline Sans Mono.
   ============================================================ */

.v4-scope {
  --sans: "Hanken Grotesk", system-ui, sans-serif;
  --serif: "Newsreader", Georgia, serif;
  --mono4: "Spline Sans Mono", ui-monospace, monospace;
  /* Remap the MS font tokens inside v4 scopes: nested un-migrated rules
     (HC, dashboard) referencing var(--font-*) resolve to the v4 faces.
     (JetBrains/Inter stopped loading with the v4 font swap, so these
     were falling back to system fonts anyway.) */
  --font-sans: "Hanken Grotesk", system-ui, sans-serif;
  --font-head: "Hanken Grotesk", system-ui, sans-serif;
  --font-mono: "Spline Sans Mono", ui-monospace, monospace;
  /* :root defines --font-body AS var(--font-sans), resolved AT :root (the
     --accent-wash trap) - redeclare here so consumers (.search-modal) get
     Hanken, not the retired Inter. */
  --font-body: var(--font-sans);
  /* Remap the MS BRAND-BLUE tokens inside v4 scopes (2026-07-20 sweep):
     every un-migrated rule referencing the accent/blue token family now
     resolves to the chartreuse system in one stroke - links, focus rings,
     active states, fills, washes. Group colours + verdict tokens are
     separate families and untouched. Literal blue hexes bypass this and
     are fixed individually. */
  --blue-primary: #C6E84A;
  --blue-hi: #D3EE6E;
  --blue-text: #D3EE6E;
  --blue-deep: #55690F;
  --blue-glow: rgba(198,232,74,0.14);
  --blue-glow-soft: rgba(198,232,74,0.07);
  --blue-wash: rgba(198,232,74,0.08);
  --accent: #C6E84A;
  --accent-hi: #D3EE6E;
  --accent-text: #D3EE6E;
  --accent-deep: #55690F;
  /* :root defines these AS var(--blue-*), which resolves at :root - so the
     --blue-* remap above never reaches them. Redeclare here so they pick up
     the chartreuse values (rail active wash, progress-bar glow). */
  --accent-wash: var(--blue-wash);
  --accent-glow: var(--blue-glow);

  --bg4: #101114;
  --card4: #17191E;
  --card4-2: #1C1F25;
  --line4: rgba(255,255,255,0.09);
  --line4-2: rgba(255,255,255,0.22);
  --ink4: #F2F2F0;
  --ink4-2: #A7AAB3;
  --ink4-3: #70747E;
  --ghost4: rgba(255,255,255,0.16);

  --ok4: #34C97E; --ok4-bg: rgba(52,201,126,0.10);
  --warn4: #E8A33D; --warn4-bg: rgba(232,163,61,0.10);
  --err4: #E5544B; --err4-bg: rgba(229,84,75,0.10);

  --hl: #C6E84A;          /* chartreuse - LOCKED brand accent */
  --hl-ink: #D3EE6E;      /* accent as text on dark (~9.6:1 on bg) */
  --on-hl: #14160A;       /* text ON chartreuse (~13.5:1) */
  --hl-grad-a: #D9F272;
  --hl-grad-b: #B4D93C;
  --hl-glow: rgba(198,232,74,0.13);

  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
}
.v4-scope ::selection { background: var(--hl); color: var(--on-hl); }
.v4-scope h1, .v4-scope h2, .v4-scope h3, .v4-scope h4 { color: var(--ink4); }
.wrap3 { max-width: 1160px; margin: 0 auto; padding: 0 28px; }

/* Accent emphasis (marker retired - chartreuse as text) */
.mk { color: var(--hl-ink); font-weight: 550; }
.mlink { color: var(--hl-ink); font-weight: 600; font-size: 15px; text-decoration: none; }
.mlink:hover { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1.5px; }

/* Reveal motion */
.v4-scope [data-reveal] { opacity: 0; transform: translateY(16px);
  transition: opacity .6s ease, transform .6s cubic-bezier(.2,.7,.2,1); }
.v4-scope [data-reveal].in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .v4-scope [data-reveal] { opacity: 1; transform: none; transition: none; }
}

/* ---------- Floating pill nav (sticky wrapper keeps flow space) ---------- */
.fnav-wrap { position: sticky; top: 14px; z-index: 60; padding: 0 12px; }
.fnav {
  display: flex; align-items: center; gap: 16px;
  width: min(1120px, 100%); margin: 0 auto;
  padding: 9px 10px 9px 18px;
  background: rgba(16,17,20,0.82); backdrop-filter: blur(14px);
  border: 1px solid var(--line4); border-radius: 99px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.4);
}
.fnav-brand { color: var(--ink4); font-weight: 700; font-size: 15.5px; text-decoration: none;
              white-space: nowrap; display: flex; align-items: center; }
.fnav-brand b { color: var(--hl-ink); font-weight: 700; }
.fnav-links { display: flex; align-items: center; gap: 2px; flex: 1; }
.fnav-links > a, .fnav-dd-btn {
  color: var(--ink4-2); text-decoration: none; font-weight: 500; font-size: 14px;
  padding: 7px 12px; border-radius: 99px; background: none; border: 0; cursor: pointer;
  font-family: var(--sans); display: inline-flex; align-items: center; gap: 6px;
}
.fnav-links > a:hover, .fnav-dd-btn:hover { color: var(--ink4); background: rgba(255,255,255,0.06); }
.fnav-dd { position: relative; }
.fnav-dd-btn svg { width: 10px; height: 10px; opacity: 0.6; transition: transform .15s ease; }
.fnav-dd:hover .fnav-dd-btn svg, .fnav-dd:focus-within .fnav-dd-btn svg { transform: rotate(180deg); }
.fnav-menu {
  position: absolute; top: calc(100% + 10px); left: 0; min-width: 210px;
  background: rgba(23,25,30,0.96); backdrop-filter: blur(14px);
  border: 1px solid var(--line4); border-radius: 14px; padding: 6px;
  box-shadow: 0 18px 50px rgba(0,0,0,0.5);
  opacity: 0; visibility: hidden; transform: translateY(-4px);
  transition: opacity .15s ease, transform .15s ease, visibility .15s;
}
.fnav-dd:hover .fnav-menu, .fnav-dd:focus-within .fnav-menu { opacity: 1; visibility: visible; transform: none; }
.fnav-menu a { display: flex; flex-direction: column; gap: 1px; padding: 9px 12px; border-radius: 9px;
               text-decoration: none; }
.fnav-menu a b { color: var(--ink4); font-weight: 600; font-size: 13.5px; }
.fnav-menu a span { color: var(--ink4-3); font-size: 11.5px; }
.fnav-menu a:hover { background: rgba(255,255,255,0.06); }
.fnav-actions { display: flex; align-items: center; gap: 8px; }
.fnav .topbar-search-btn { display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 50%; background: none; border: 1px solid var(--line4);
  color: var(--ink4-2); cursor: pointer; padding: 0; margin: 0; }
.fnav .topbar-search-btn:hover { color: var(--ink4); border-color: var(--line4-2); }
.fnav .topbar-search-btn svg { width: 15px; height: 15px; }
.fnav .topbar-search-btn-text, .fnav .topbar-search-shortcut { display: none; }
.fnav .auth-user-menu { position: relative; }
.fnav-signin { color: var(--ink4); font-weight: 600; font-size: 14px; text-decoration: none;
               padding: 8px 12px; background: none; border: 0; cursor: pointer; font-family: var(--sans); }
.fnav-signin:hover { color: var(--hl-ink); }
.fnav .topbar-burger { display: none; background: none; border: 0; color: var(--ink4);
                       cursor: pointer; padding: 6px; }

.btn-hl {
  display: inline-flex; align-items: center; justify-content: center; background: var(--hl);
  color: var(--on-hl); font-weight: 700; font-size: 14px; padding: 9px 16px; border-radius: 99px;
  text-decoration: none; border: 0; cursor: pointer; font-family: var(--sans);
  transition: transform .15s ease, filter .15s ease;
}
.btn-hl:hover { filter: brightness(1.06); transform: translateY(-1px); }
.btn-hl-lg { padding: 14px 24px; font-size: 15.5px; }
.btn-hl-sm { padding: 8px 14px; font-size: 13.5px; }
.btn-ink {
  display: inline-flex; align-items: center; background: #101114; color: #F2F2F0;
  font-weight: 700; font-size: 15.5px; padding: 14px 26px; border-radius: 99px; text-decoration: none;
  transition: transform .15s ease;
}
.btn-ink:hover { transform: translateY(-1px); }

/* ---------- Hero ---------- */
.hero3 { padding: 84px 0 96px; }
.hero3-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
              gap: 72px; align-items: center; }
.kick { font-family: var(--mono4); font-size: 12px; font-weight: 500; letter-spacing: 0.16em;
        text-transform: uppercase; color: var(--ink4-3); margin: 0 0 26px; }
.hero3 h1 { font-family: var(--serif); font-weight: 460; font-optical-sizing: auto;
  font-size: clamp(48px, 6.6vw, 96px); line-height: 1.0; letter-spacing: -0.024em; margin: 0 0 28px; }
.hero3 h1 em { font-style: italic; font-weight: 420; }
.lede3 { font-size: 18px; line-height: 1.62; max-width: 32em; margin: 0; color: var(--ink4-2); }
.cta-row { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.note3 { margin: 20px 0 0; font-family: var(--mono4); font-size: 12px; color: var(--ink4-3); }
/* Hero CTA stack: shrink-wraps to the button row so the note centres under the
   buttons. Sits ABOVE the lede (2026-07-20, above-the-fold CTA) - it owns the
   gap down to the lede; .lede3 itself has no bottom margin. */
.cta-stack { width: fit-content; margin: 0 0 32px; }
.cta-stack .note3 { text-align: center; }

/* Hero visual - product UI */
.hero3-visual { position: relative; }
.hero3-visual::before { content: ""; position: absolute; inset: -14% -12%;
  background: radial-gradient(44% 40% at 30% 25%, var(--hl-glow), transparent 70%),
              radial-gradient(40% 36% at 75% 70%, rgba(34,211,238,0.09), transparent 70%);
  filter: blur(30px); pointer-events: none; }
.rep { position: relative; background: var(--card4); border: 1px solid var(--line4);
       border-radius: 16px; padding: 24px; box-shadow: 0 30px 80px rgba(0,0,0,0.45); }
.rep-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.rep-label { font-family: var(--mono4); font-size: 11px; font-weight: 600; letter-spacing: 0.12em;
             text-transform: uppercase; color: var(--ink4-3); }
.rep-chip { font-size: 12px; font-weight: 600; color: var(--ink4-2);
            border: 1px solid var(--line4-2); border-radius: 99px; padding: 3px 10px; }
.rep-score { display: flex; align-items: center; gap: 20px; margin: 20px 0; }
.ring3 { position: relative; width: 88px; height: 88px; border-radius: 50%; display: grid;
         place-items: center; flex-shrink: 0;
         background: conic-gradient(var(--hl) calc(var(--pct) * 1%), rgba(255,255,255,0.08) 0); }
.ring3::before { content: ""; position: absolute; inset: 7px; border-radius: 50%; background: var(--card4); }
.ring3 span { position: relative; font-family: var(--mono4); font-weight: 600; font-size: 28px; color: var(--ink4); }
.rep-verdict { display: flex; flex-direction: column; gap: 2px; }
.rep-verdict strong { color: var(--ink4); font-size: 16px; font-weight: 700; }
.rep-verdict span { font-size: 13px; color: var(--ink4-3); }
.rep-cats { display: flex; flex-direction: column; gap: 9px; border-top: 1px solid var(--line4); padding-top: 18px; }
.cat3 { display: grid; grid-template-columns: 118px 1fr 28px; align-items: center; gap: 12px; }
.cat3 > span { font-size: 12.5px; font-weight: 550; color: var(--ink4-2); }
.cat3 em { font-family: var(--mono4); font-style: normal; font-size: 11.5px; color: var(--ink4-3); text-align: right; }
.bar3 { display: block; height: 5px; border-radius: 3px; background: rgba(255,255,255,0.07); overflow: hidden; }
.bar3 b { display: block; height: 100%; border-radius: 3px; background: var(--gc); width: 0;
          transition: width .9s cubic-bezier(.2,.7,.2,1); }
.hero3-visual.in .bar3 b { width: var(--w); }
.hero3-visual.in .cat3:nth-child(1) b { transition-delay: .10s; }
.hero3-visual.in .cat3:nth-child(2) b { transition-delay: .18s; }
.hero3-visual.in .cat3:nth-child(3) b { transition-delay: .26s; }
.hero3-visual.in .cat3:nth-child(4) b { transition-delay: .34s; }
.hero3-visual.in .cat3:nth-child(5) b { transition-delay: .42s; }
.hero3-visual.in .cat3:nth-child(6) b { transition-delay: .50s; }
.hero3-visual.in .cat3:nth-child(7) b { transition-delay: .58s; }
.hero3-visual.in .cat3:nth-child(8) b { transition-delay: .66s; }
@media (prefers-reduced-motion: reduce) { .bar3 b { width: var(--w) !important; transition: none; } }
.cat3.is-weak > span { color: var(--warn4); }
.rep-sub { position: relative; margin: -14px 0 0 34px; background: var(--card4-2);
           border: 1px solid var(--line4); border-radius: 12px; padding: 14px 18px;
           box-shadow: 0 18px 50px rgba(0,0,0,0.4); }
.rep-sub-label { font-family: var(--mono4); font-size: 10.5px; font-weight: 600; letter-spacing: 0.12em;
                 text-transform: uppercase; color: var(--warn4); display: block; margin-bottom: 6px; }
.rep-sub p { margin: 0; font-size: 13.5px; line-height: 1.55; color: var(--ink4); }

/* ---------- Proof strip (self-contained - deletable) ---------- */
.proof3 { border-top: 1px solid var(--line4-2); border-bottom: 1px solid var(--line4); }
.proof3-row { display: grid; grid-template-columns: repeat(4, 1fr); }
.p3 { display: flex; flex-direction: column; gap: 6px; padding: 34px 28px; border-left: 1px solid var(--line4); }
.p3:first-child { border-left: none; padding-left: 0; }
.p3 b { font-family: var(--mono4); font-weight: 600; font-size: clamp(30px, 3.4vw, 46px);
        letter-spacing: -0.02em; color: var(--ink4); font-variant-numeric: tabular-nums; }
.p3 span { font-size: 13px; color: var(--ink4-3); }

/* ---------- Section rhythm ---------- */
.kick2 { font-family: var(--mono4); font-size: 12px; font-weight: 500; letter-spacing: 0.16em;
         text-transform: uppercase; color: var(--hl-ink); margin: 0 0 18px; }
.sys3 h2, .hcf3 h2, .ledger h2, .tools3 h2, .author3 h2, .res3 h2, .dashf h2 {
  font-family: var(--serif); font-weight: 480; font-size: clamp(34px, 4vw, 56px);
  line-height: 1.04; letter-spacing: -0.02em; margin: 0 0 22px; }

.sys3 { padding: 104px 0; }
.sys3-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin-top: 26px; }
.sys3-col { padding: 8px 36px 0; border-left: 1px solid var(--line4); }
.sys3-col:first-child { padding-left: 0; border-left: none; }
.sys3-num { font-family: var(--mono4); font-weight: 500; font-size: 64px; line-height: 1;
            color: var(--ghost4); display: block; margin-bottom: 22px; letter-spacing: -0.02em; }
.sys3-col h3 { font-size: 20px; font-weight: 700; margin: 0 0 10px; }
.sys3-col p { font-size: 15px; line-height: 1.62; margin: 0 0 14px; color: var(--ink4-2); }

/* ---------- HC feature ---------- */
.hcf3 { border-top: 1px solid var(--line4); padding: 104px 0; }
.hcf3-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
             gap: 80px; align-items: center; }
.hcf3-copy { font-size: 17px; line-height: 1.65; max-width: 30em; margin: 0 0 30px; color: var(--ink4-2); }
.hcf3-rec { background: var(--card4); border: 1px solid var(--line4); border-radius: 14px;
            padding: 26px; box-shadow: 0 20px 60px rgba(0,0,0,0.35); }
.rec3-label { font-family: var(--mono4); font-size: 11px; font-weight: 600; letter-spacing: 0.12em;
              text-transform: uppercase; color: var(--warn4); display: block; margin-bottom: 14px; }
.hcf3-rec p { margin: 0 0 16px; font-size: 16px; line-height: 1.65; color: var(--ink4); }
.rec3-foot { font-family: var(--mono4); font-size: 11.5px; color: var(--ink4-3);
             border-top: 1px solid var(--line4); display: block; padding-top: 13px; }
.hcf3-more { margin-top: 18px; }

/* ---------- The ledger (section index) ---------- */
.ledger { border-top: 1px solid var(--line4); padding: 104px 0; }
.ledger-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px;
               margin-bottom: 26px; }
.ledger-head h2 { margin-bottom: 0; }
.ledger-filters { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: 0 0 18px; }
.lf { background: none; border: 0; padding: 6px 0; cursor: pointer; font: 600 13.5px var(--sans);
      color: var(--ink4-3); }
.lf:hover { color: var(--ink4); }
.lf.is-on { color: var(--hl-ink); }
.ledger-rows { border-top: 2px solid var(--line4-2); }
.lrow { display: grid; grid-template-columns: 58px 20px minmax(200px, 0.9fr) 1.3fr 32px;
        align-items: center; gap: 14px; padding: 17px 4px; text-decoration: none;
        border-bottom: 1px solid var(--line4); transition: background .14s ease; }
.lrow:hover { background: rgba(255,255,255,0.028); }
.lnum { font-family: var(--mono4); font-size: 13px; font-weight: 500; color: var(--ink4-3);
        font-variant-numeric: tabular-nums; }
.ldot { width: 8px; height: 8px; border-radius: 50%; background: var(--gc, var(--ink4-3)); }
.lname { color: var(--ink4); font-weight: 650; font-size: 16.5px; }
.lrow:hover .lnum { color: var(--hl-ink); }
.ldesc { color: var(--ink4-3); font-size: 14px; }
.larr { color: var(--ink4-3); font-size: 16px; text-align: right;
        transition: transform .15s ease, color .15s ease; }
.lrow:hover .larr { transform: translate(3px, -3px); color: var(--hl-ink); }
.lrow-more .lname { color: var(--ink4-2); font-weight: 550; }
.lrow-more .ldesc { color: var(--hl-ink); font-weight: 600; }

/* ---------- Tools trio ---------- */
.tools3 { border-top: 1px solid var(--line4); padding: 104px 0; }
.tools3-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 44px; margin-top: 44px; }
.t3 { border-top: 2px solid var(--line4-2); padding-top: 24px; }
.t3 h3 { font-size: 18px; font-weight: 700; margin: 16px 0 8px; }
.t3-head { display: flex; align-items: center; gap: 12px; margin: 16px 0 8px; }
.t3-head h3 { margin: 0; }
.t3-q { font-family: var(--serif); font-style: italic; font-size: 18px; color: var(--hl-ink); margin: 0 0 10px; }
.t3 p:not(.t3-q) { font-size: 14.5px; line-height: 1.6; margin: 0 0 16px; color: var(--ink4-2); }
.tools3-more { margin-top: 36px; display: flex; gap: 24px; }

/* Icon glyphs - NAKED tinted marks, no chip box (Rob 2026-07-19: icons
   lose their boxes site-wide, the design reads lighter). The .schip3
   class names stay (markup unchanged); only the box died. */
.schip3 { display: inline-grid; place-items: center; width: auto; height: auto;
          background: none; border: 0; border-radius: 0; }
.schip3 i { display: block; width: 22px; height: 22px; background: var(--gc);
            -webkit-mask: var(--icon) center / contain no-repeat;
            mask: var(--icon) center / contain no-repeat; }
.schip3-lg i { width: 30px; height: 30px; }
.schip3-sm i { width: 18px; height: 18px; }

/* ---------- Resources band ---------- */
/* Dashboard signup-hook section (2026-07-20): 9 boxless feature cells +
   a 4-step ledger, homepage vocabulary. Naked chartreuse stroke icons. */
.dashf { border-top: 1px solid var(--line4); padding: 104px 0; }
.dashf-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 44px; margin-top: 40px; }
.dashf-item { border-top: 2px solid var(--line4-2); padding: 22px 0 6px;
  display: grid; grid-template-columns: auto 1fr; column-gap: 16px; row-gap: 6px; align-items: start; }
.dashf-ic { grid-row: 1 / span 2; color: var(--hl-ink); margin-top: 3px; display: block; }
.dashf-ic svg { width: 22px; height: 22px; display: block; }
.dashf-item h3 { grid-column: 2; font-size: 16px; font-weight: 700; color: var(--ink4);
  letter-spacing: -0.01em; margin: 0; line-height: 1.3; }
.dashf-item p { grid-column: 2; font-size: 14px; line-height: 1.6; color: var(--ink4-2); margin: 0; }
.dashf-how { margin-top: 72px; }
.dashf-how .kick2 { margin-bottom: 0; }
.dashf-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0 32px;
  margin-top: 22px; border-top: 2px solid var(--line4-2); }
.dashf-step { padding: 22px 0 6px; }
.dashf-num { font-family: var(--mono4); font-weight: 500; font-size: 40px; line-height: 1;
  color: var(--ghost4); display: block; margin-bottom: 16px; letter-spacing: -0.02em; }
.dashf-step h4 { font-size: 16px; font-weight: 700; color: var(--ink4); margin: 0 0 6px; letter-spacing: -0.005em; }
.dashf-step p { font-size: 14px; line-height: 1.6; color: var(--ink4-2); margin: 0; }
.dashf-cta { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; margin-top: 56px; }
@media (max-width: 900px) {
  .dashf-grid { grid-template-columns: repeat(2, 1fr); gap: 0 32px; }
  .dashf-steps { grid-template-columns: repeat(2, 1fr); gap: 0 28px; }
}
@media (max-width: 560px) {
  .dashf-grid, .dashf-steps { grid-template-columns: 1fr; }
}

.res3 { border-top: 1px solid var(--line4); padding: 104px 0; }
.res3-rows { border-top: 2px solid var(--line4-2); margin-top: 26px; }
.res3-row { display: grid; grid-template-columns: minmax(180px, 0.55fr) 1.45fr 32px;
            align-items: baseline; gap: 14px; padding: 18px 4px; text-decoration: none;
            border-bottom: 1px solid var(--line4); transition: background .14s ease; }
.res3-row:hover { background: rgba(255,255,255,0.028); }
.res3-name { color: var(--ink4); font-weight: 650; font-size: 16.5px; }
.res3-desc { color: var(--ink4-3); font-size: 14px; }
.res3-desc a { color: var(--ink4-2); text-decoration: underline; text-underline-offset: 3px;
               text-decoration-color: var(--line4-2); }
.res3-desc a:hover { color: var(--hl-ink); }
.res3-arr { color: var(--ink4-3); font-size: 16px; text-align: right; }
.res3-row:hover .res3-arr { color: var(--hl-ink); }
.res3-cats { display: flex; flex-wrap: wrap; gap: 6px 16px; padding: 18px 4px;
             border-bottom: 1px solid var(--line4); }
.res3-cats a { display: inline-flex; align-items: center; gap: 8px; color: var(--ink4-2);
               font-weight: 600; font-size: 14px; text-decoration: none; padding: 4px 0; }
.res3-cats a i { width: 8px; height: 8px; border-radius: 50%; background: var(--gc); }
.res3-cats a:hover { color: var(--ink4); }

/* ---------- Author ---------- */
.author3 { border-top: 1px solid var(--line4); padding: 104px 0; }
.author3-grid { display: grid; grid-template-columns: 300px 1fr; gap: 64px; align-items: center; }
.author3-photo { aspect-ratio: 4 / 5; border-radius: 14px; overflow: hidden;
                 border: 1px solid var(--line4); background: #17191E; }
.author3-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.author3-copy { font-size: 17.5px; line-height: 1.7; max-width: 36em; margin: 0 0 22px; color: var(--ink4-2); }

/* ---------- SEO copy block ---------- */
.seo3 { border-top: 1px solid var(--line4); padding: 72px 0; }
.seo3-inner { max-width: 760px; }
.seo3 h2 { font-family: var(--serif); font-weight: 500; font-size: 26px; margin: 0 0 16px; }
.seo3 p { font-size: 15.5px; line-height: 1.7; color: var(--ink4-2); margin: 0 0 14px; }
.seo3 a { color: var(--hl-ink); text-decoration: none; }
.seo3 a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ---------- The chartreuse CTA band ---------- */
.band { background: linear-gradient(115deg, var(--hl-grad-a), var(--hl) 52%, var(--hl-grad-b)); }
.band-inner { display: flex; flex-direction: column; align-items: center; text-align: center;
              padding: 104px 28px 112px; }
.band h2 { font-family: var(--serif); font-weight: 500; color: var(--on-hl);
           font-size: clamp(34px, 4.4vw, 60px); line-height: 1.04; letter-spacing: -0.02em;
           margin: 0 0 18px; max-width: 15em; }
.band p { font-family: var(--mono4); font-size: 13px;
          color: color-mix(in srgb, var(--on-hl) 72%, transparent); margin: 0 0 34px; }
.band-alt { margin-top: 20px; }
.band-alt a { color: color-mix(in srgb, var(--on-hl) 80%, transparent); font-weight: 650;
              font-size: 14px; text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Footer v4 restyle (shared .dtc-footer markup) ----------
   Width matches .container (1280px / --s-6 side padding) so the footer
   rule lines up with the page content instead of stopping short. */
.v4-scope .dtc-footer, .dtc-footer.v4-scope { border-top: 1px solid var(--line4);
  background: var(--bg4); max-width: 1280px;
  padding-left: var(--s-6); padding-right: var(--s-6); }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .fnav-links { display: none; }
  .fnav .topbar-burger { display: inline-flex; }
  .hero3 { padding-top: 56px; }
  .hero3-grid, .hcf3-grid { grid-template-columns: 1fr; gap: 48px; }
  .rep-sub { margin-left: 12px; }
  .proof3-row { grid-template-columns: repeat(2, 1fr); }
  .p3 { padding: 24px 20px; }
  .p3:nth-child(odd) { border-left: none; padding-left: 0; }
  .sys3-cols { grid-template-columns: 1fr; gap: 36px; }
  .sys3-col { border-left: none; padding: 0; }
  .tools3-cols { grid-template-columns: 1fr; gap: 36px; }
  .author3-grid { grid-template-columns: 1fr; gap: 36px; }
  .author3-photo { max-width: 300px; }
  .lrow { grid-template-columns: 48px 16px 1fr 28px; }
  .ldesc { display: none; }
  .res3-row { grid-template-columns: 1fr 28px; }
  .res3-desc { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
  .fnav-wrap { top: 8px; padding: 0 8px; }
  .fnav { gap: 8px; padding: 8px 8px 8px 12px; }
  .fnav-brand { font-size: 14px; }
  .fnav-brand img { width: 18px; height: 18px; }
  .fnav .topbar-search-btn { display: none; }
  .fnav .btn-hl { white-space: nowrap; font-size: 12.5px; padding: 8px 12px; }
  .fnav-signin { display: none; }
  .cta-row { gap: 14px; }
}

/* V4 additions (2026-07-18 homepage feedback round) */
.h2sub { font-size: 15.5px; line-height: 1.6; color: var(--ink4-2); max-width: 44em; margin: -6px 0 0; }
.lrow { grid-template-columns: 58px 38px minmax(200px, 0.9fr) 1.3fr 32px; }
.lrow .schip3-sm { align-self: center; }
@media (max-width: 980px) {
  .lrow { grid-template-columns: 48px 34px 1fr 28px; }
}

/* V4 motion round 2 (2026-07-18): staggered cascades + count-ups.
   All gated behind prefers-reduced-motion. */
.v4-scope [data-stagger] > * { opacity: 0; transform: translateY(12px);
  transition: opacity .55s ease, transform .55s cubic-bezier(.2,.7,.2,1); }
.v4-scope [data-stagger].in > * { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .v4-scope [data-stagger] > * { opacity: 1; transform: none; transition: none; }
}
/* The priority card lands after the bars finish drawing */
.hero3-visual .rep-sub { opacity: 0; transform: translateY(10px);
  transition: opacity .5s ease .95s, transform .5s cubic-bezier(.2,.7,.2,1) .95s; }
.hero3-visual.in .rep-sub { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .hero3-visual .rep-sub { opacity: 1; transform: none; transition: none; }
}
/* One-time nav drop-in on page load */
@keyframes fnavIn { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }
.fnav { animation: fnavIn .5s cubic-bezier(.2,.7,.2,1) both; }
@media (prefers-reduced-motion: reduce) { .fnav { animation: none; } }
/* Micro hover motion on ledger icon chips */
.lrow .schip3 { transition: transform .15s ease; }
.lrow:hover .schip3 { transform: translateY(-2px); }

/* ============================================================
   V4 READING RE-SKIN (Phase 4 step 2, 2026-07-18).
   Applies the locked A3 reading system to the EXISTING rendered
   markup (no structural changes - checklist ids, anchors and
   hydration mounts untouched). Scoped to .v4-scope, which
   build_section_html + preview.html set on .section-body-content
   along with the section's group colour as --gc.
   ============================================================ */

/* ---- Reading typography ---- */
.v4-scope { font-family: var(--sans); }
.v4-scope > p, .v4-scope .section-body-content > p { font-size: 17.5px; line-height: 1.74; color: #BFC3CB; }
.v4-scope p { font-family: var(--sans); }
/* Heading rules scoped to the READING BODY only. The bare `.v4-scope h2`
   version of these leaked into every v4 surface and squashed the
   homepage section H2s (and the CTA band's) to 31px serif ink - later
   in the file beats the `.sys3 h2`/`.band h2` ties (found 2026-07-19). */
.v4-scope .section-body-content h2, .section-body-content.v4-scope h2,
.v4-scope .section-body-content h3, .section-body-content.v4-scope h3 {
  font-family: var(--serif); font-weight: 500; font-size: 31px;
  letter-spacing: -0.012em; color: var(--ink4); margin: 56px 0 18px; }
.v4-scope .section-body-content h4, .section-body-content.v4-scope h4 {
  font-family: var(--sans); font-size: 19px; font-weight: 700;
  color: var(--ink4); margin: 42px 0 14px; }
/* Content links only (classless anchors) - classed chrome (CTAs, tiles,
   nav cells) styles itself. :not([class]) ties the MS
   .section-body-content a:not([class]) blue on specificity; later wins. */
.v4-scope a:not([class]) { color: var(--hl-ink);
  text-decoration-color: color-mix(in srgb, var(--hl-ink) 40%, transparent); }
.v4-scope a:not([class]):hover { color: var(--hl-ink);
  text-decoration-color: var(--hl-ink); }
/* ON a chartreuse surface (CTA band, principle band, preview gate) the
   chartreuse link colour vanishes - links there go near-black ink. */
.v4-scope .band a:not([class]), .v4-scope .principle a:not([class]),
.v4-scope .preview-gate a:not([class]) {
  color: color-mix(in srgb, var(--on-hl) 85%, transparent);
  text-decoration-color: color-mix(in srgb, var(--on-hl) 50%, transparent); }
.v4-scope .band a:not([class]):hover, .v4-scope .principle a:not([class]):hover,
.v4-scope .preview-gate a:not([class]):hover {
  color: var(--on-hl); text-decoration-color: var(--on-hl); }
.v4-scope strong { color: var(--ink4); }
.v4-scope li { font-family: var(--sans); }

/* ---- Tables: ledger treatment (kills the MS .md-table card + thead wash) ---- */
.v4-scope table { width: 100%; border-collapse: collapse; font-size: 15px;
  border: 0; border-top: 2px solid var(--line4-2); border-radius: 0;
  background: none; overflow: visible; }
.v4-scope thead { background: none; }
.v4-scope thead th { font-family: var(--mono4); font-size: 10.5px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink4-3); text-align: left;
  padding: 12px 14px 10px 0; border-bottom: 1px solid var(--line4); background: none; }
.v4-scope td { padding: 13px 14px 13px 0; border-bottom: 1px solid var(--line4);
  background: none; vertical-align: top; color: var(--ink4-2); }
.v4-scope tbody tr:hover td { background: rgba(255,255,255,0.02); }
.v4-scope td:first-child { color: var(--ink4); font-weight: 650; }

/* ---- TL;DR: numbered mono index in the group colour ---- */
.v4-scope .callout-tldr { background: none; border: 0; border-radius: 0; padding: 0 0 4px;
  border-top: 2px solid var(--gc, var(--hl)); padding-top: 13px; margin: 0 0 38px; box-shadow: none; }
.v4-scope .callout-tldr .callout-label { color: var(--gc, var(--hl-ink)); font-family: var(--mono4);
  font-size: 11px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase;
  background: none; padding: 0; margin: 0 0 12px; }
.v4-scope .callout-tldr .callout-label svg, .v4-scope .callout-tldr .callout-icon { display: none; }
.v4-scope .callout-tldr ul { list-style: none; margin: 0; padding: 0; counter-reset: tldr;
  display: flex; flex-direction: column; gap: 10px; }
.v4-scope .callout-tldr li { counter-increment: tldr; display: grid;
  grid-template-columns: 30px 1fr; gap: 12px; font-size: 15.5px; line-height: 1.6;
  color: var(--ink4-2); padding: 0; }
.v4-scope .callout-tldr li::before { content: counter(tldr, decimal-leading-zero);
  font-family: var(--mono4); font-size: 12px; color: var(--gc, var(--hl-ink)); padding-top: 3px; }
.v4-scope .callout-tldr li::marker { content: ''; }

/* ---- Founder's Principle: the chartreuse band ---- */
.v4-scope .principle { position: relative; overflow: hidden; border: 0; box-shadow: none;
  background: linear-gradient(115deg, var(--hl-grad-a), var(--hl) 48%, var(--hl-grad-b));
  border-radius: 6px; padding: 44px 40px; margin: 36px 0; }
.v4-scope .principle-kicker { font-family: var(--mono4); font-size: 11px; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase; color: color-mix(in srgb, var(--on-hl) 60%, transparent);
  margin: 0 0 14px; background: none; }
.v4-scope .principle-title { font-family: var(--serif); font-weight: 550;
  font-size: clamp(26px, 3vw, 34px); letter-spacing: -0.015em; color: var(--on-hl); margin: 0 0 12px; }
.v4-scope .principle-body { color: color-mix(in srgb, var(--on-hl) 85%, transparent);
  font-size: 16.5px; line-height: 1.66; font-weight: 500; max-width: 38em; margin: 0 0 10px; }
.v4-scope .principle-body strong { color: var(--on-hl); }
.v4-scope .principle::after { content: ""; position: absolute; right: -30px; top: 50%;
  transform: translateY(-50%); width: 200px; height: 200px;
  background: color-mix(in srgb, var(--on-hl) 8%, transparent);
  -webkit-mask: var(--wm-icon, linear-gradient(#0000, #0000)) center / contain no-repeat;
  mask: var(--wm-icon, linear-gradient(#0000, #0000)) center / contain no-repeat; pointer-events: none; }

/* ---- Founder's Note: the dark quote band ---- */
.v4-scope .founders-note { position: relative; border: 0; box-shadow: none; border-radius: 0;
  background: radial-gradient(42% 70% at 88% 18%, color-mix(in srgb, var(--hl) 5%, transparent), transparent 70%), var(--card4);
  border-top: 1px solid var(--line4); border-bottom: 1px solid var(--line4);
  padding: 40px 36px 36px 96px; margin: 44px 0; }
.v4-scope .founders-note::before { content: "\201C"; position: absolute; left: 28px; top: 30px;
  font-family: var(--serif); font-size: 64px; line-height: 0.8; color: var(--hl-ink); }
.v4-scope .founders-note-label { font-family: var(--mono4); font-size: 11px; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink4-3); margin: 0 0 14px;
  background: none; display: flex; align-items: center; gap: 8px; }
.v4-scope .founders-note-cap { width: 20px; height: 9px; color: var(--hl-ink); }
.v4-scope .founders-note p { font-family: var(--serif); font-size: 19.5px; line-height: 1.55;
  color: var(--ink4); margin: 0 0 14px; }
.v4-scope .founders-note p strong { color: var(--hl-ink); font-weight: 550; }

/* ---- Callouts: C1+ hanging chip + label, fading hairline, NO left rules ---- */
.v4-scope .callout { background: none; border: 0; border-radius: 0; box-shadow: none;
  padding: 0; margin: 30px 0; }
.v4-scope .callout-label { display: flex; align-items: center; gap: 10px;
  font-family: var(--mono4); font-size: 11px; font-weight: 600; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--cc, var(--ink4-3));
  padding: 0 0 11px; margin: 0 0 13px;
  background: linear-gradient(90deg, var(--line4-2), transparent 85%) bottom / 100% 1px no-repeat; }
/* Naked tinted glyph - no chip box (Rob 2026-07-19). */
.v4-scope .callout-icon { width: auto; height: auto; display: inline-grid; place-items: center;
  border-radius: 0; background: none; border: 0; flex-shrink: 0; }
.v4-scope .callout-icon svg { width: 15px; height: 15px; stroke: var(--cc, var(--ink4-3)); stroke-width: 2; }
.v4-scope .callout-tip { --cc: var(--ok4); }
.v4-scope .callout-warning { --cc: var(--err4); }
.v4-scope .callout-insight { --cc: var(--hl-ink); }
.v4-scope .callout-info { --cc: var(--ink4-3); }
.v4-scope .callout-ai { --cc: #22D3EE; }
.v4-scope .callout-read { --cc: var(--ink4-3); }
.v4-scope .callout-title { font-size: 15.5px; font-weight: 700; color: var(--ink4); margin: 0 0 6px; }
.v4-scope .callout p { font-size: 15.5px; line-height: 1.66; color: var(--ink4-2); margin: 0 0 10px; }

/* ---- Verdict callouts: C2+ glassy with the badge astride the top edge ---- */
.v4-scope .callout--verdict-green, .v4-scope .callout--verdict-amber, .v4-scope .callout--verdict-red {
  position: relative; border-radius: 14px; padding: 26px 24px 18px; margin: 40px 0 30px;
  /* The base .callout sets overflow:hidden (MS glow clipping); it slices the
     badge hanging at top:-14px in half. The v4 variant replaces that
     background, so un-clip. */
  overflow: visible;
  backdrop-filter: blur(16px); box-shadow: inset 0 1px 0 rgba(255,255,255,0.06); }
.v4-scope .callout--verdict-green { --cc: var(--ok4);
  background: linear-gradient(180deg, rgba(52,201,126,0.10), rgba(52,201,126,0.05)), rgba(28,31,37,0.45);
  border: 1px solid rgba(52,201,126,0.20); }
.v4-scope .callout--verdict-amber { --cc: var(--warn4);
  background: linear-gradient(180deg, rgba(232,163,61,0.10), rgba(232,163,61,0.05)), rgba(28,31,37,0.45);
  border: 1px solid rgba(232,163,61,0.20); }
.v4-scope .callout--verdict-red { --cc: var(--err4);
  background: linear-gradient(180deg, rgba(229,84,75,0.10), rgba(229,84,75,0.05)), rgba(28,31,37,0.45);
  border: 1px solid rgba(229,84,75,0.20); }
.v4-scope .callout--verdict-green .callout-label, .v4-scope .callout--verdict-amber .callout-label,
.v4-scope .callout--verdict-red .callout-label {
  position: absolute; top: -14px; left: 20px; background: var(--bg4);
  border-radius: 99px; padding: 5px 12px 5px 6px; margin: 0; }
.v4-scope .callout--verdict-green .callout-label { border: 1px solid rgba(52,201,126,0.35); padding-left: 11px; }
.v4-scope .callout--verdict-amber .callout-label { border: 1px solid rgba(232,163,61,0.35); padding-left: 11px; }
.v4-scope .callout--verdict-red .callout-label { border: 1px solid rgba(229,84,75,0.35); padding-left: 11px; }
/* Badge keeps its pill (it's a label, not an icon box); the icon inside
   goes naked like everywhere else. */
.v4-scope .callout--verdict-green .callout-icon svg, .v4-scope .callout--verdict-amber .callout-icon svg,
.v4-scope .callout--verdict-red .callout-icon svg { width: 12px; height: 12px; }

/* ---- Formula: F1+ ledger with WHERE table ---- */
.v4-scope .formula { background: none; border: 0; border-radius: 0; box-shadow: none;
  border-top: 2px solid var(--line4-2); border-bottom: 1px solid var(--line4);
  padding: 20px 0 18px; margin: 30px 0; }
.v4-scope .formula-name { font-family: var(--mono4); font-size: 12px; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--hl-ink); margin: 0 0 10px; }
.v4-scope .formula-eq { font-family: var(--mono4); font-size: 15px; font-weight: 500;
  line-height: 1.6; color: var(--ink4); background: none; padding: 0; }
.v4-scope .formula-vars { margin-top: 16px; display: grid; grid-template-columns: 150px 1fr;
  row-gap: 7px; column-gap: 18px; }
.v4-scope .formula-vars::before { content: "Where"; grid-column: 1 / -1;
  font-family: var(--mono4); font-size: 10px; font-weight: 600; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ink4-3); margin-bottom: 2px; }
.v4-scope .formula-var { display: contents; }
.v4-scope .formula-var-name { font-family: var(--mono4); font-size: 12.5px; color: var(--ink4);
  text-align: right; }
.v4-scope .formula-var-desc { font-size: 13.5px; color: var(--ink4-3); line-height: 1.5; }

/* ---- Threshold: state-tint pill bands ---- */
.v4-scope .threshold { background: none; border: 0; border-radius: 0; box-shadow: none;
  border-top: 2px solid var(--line4-2); margin: 30px 0; }
.v4-scope .threshold-head { font-family: var(--mono4); font-size: 11px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink4-3);
  padding: 13px 0 10px; border-bottom: 1px solid var(--line4); background: none; }
.v4-scope .threshold-row { display: grid; grid-template-columns: 220px 1fr; gap: 16px;
  align-items: start; padding: 12px 0; border: 0; border-radius: 0; box-shadow: none;
  border-bottom: 1px solid var(--line4); background: none; }
.v4-scope .threshold-range { justify-self: start; font-weight: 700; font-size: 13px;
  border-radius: 99px; padding: 4px 12px; font-family: var(--sans); }
.v4-scope .threshold-row--ok .threshold-range { color: var(--ok4); background: var(--ok4-bg); }
.v4-scope .threshold-row--warn .threshold-range { color: var(--warn4); background: var(--warn4-bg); }
.v4-scope .threshold-row--err .threshold-range { color: var(--err4); background: var(--err4-bg); }
.v4-scope .threshold-desc { font-size: 14.5px; line-height: 1.58; color: var(--ink4-2); padding-top: 3px; }
.v4-scope .threshold-label { display: none; }

/* ---- Pullquote: hanging chartreuse quote between rules ---- */
.v4-scope .pullquote { position: relative; background: none; border: 0; box-shadow: none;
  border-top: 2px solid var(--line4-2); border-bottom: 1px solid var(--line4);
  border-radius: 0; padding: 30px 0 26px 84px; margin: 44px 0; text-align: left; }
.v4-scope .pullquote::before { content: "\201C"; position: absolute; left: 0; top: 14px;
  font-family: var(--serif); font-size: 96px; line-height: 1; color: var(--hl-ink); }
.v4-scope .pullquote-text { font-family: var(--serif); font-size: 24px; font-weight: 460;
  line-height: 1.42; font-style: italic; color: var(--ink4); }
.v4-scope .pullquote-text strong { font-style: normal; color: var(--hl-ink); font-weight: 550; }
.v4-scope .pullquote-attribution { font-family: var(--mono4); font-size: 11.5px;
  color: var(--ink4-3); margin-top: 10px; }

/* ---- Metrics: serif numerals, rules not cards ---- */
.v4-scope .metric-stack { border-top: 2px solid var(--line4-2); margin: 34px 0; }
.v4-scope .metric-stacked { display: grid; grid-template-columns: 170px 1fr; gap: 20px;
  align-items: baseline; background: none; border: 0; border-bottom: 1px solid var(--line4);
  border-radius: 0; padding: 16px 0; box-shadow: none; }
.v4-scope .metric-stacked-value { font-family: var(--serif); font-weight: 500; font-size: 32px;
  letter-spacing: -0.015em; color: var(--ink4); background: none; }
.v4-scope .metric-stacked-desc { font-size: 13.5px; line-height: 1.55; color: var(--ink4-3); }
.v4-scope .metric-grid { gap: 0; border-top: 2px solid var(--line4-2); margin: 34px 0; }
.v4-scope .metric-cell { background: none; border: 0; border-left: 1px solid var(--line4);
  border-radius: 0; padding: 16px 20px 6px; box-shadow: none; }
.v4-scope .metric-cell:first-child { border-left: 0; padding-left: 0; }
.v4-scope .metric-cell-label { font-family: var(--mono4); font-size: 10px; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink4-3); }
.v4-scope .metric-cell-value { font-family: var(--serif); font-weight: 500; font-size: 30px;
  color: var(--ink4); }
.v4-scope .metric-cell-hint { font-size: 12.5px; color: var(--ink4-3); }
.v4-scope .metric { background: none; border: 0; border-radius: 0; box-shadow: none;
  border-top: 2px solid var(--line4-2); border-bottom: 1px solid var(--line4);
  padding: 18px 0; margin: 30px 0; }
.v4-scope .metric-value { font-family: var(--serif); font-weight: 500; font-size: 34px;
  letter-spacing: -0.015em; color: var(--ink4); background: none; }
.v4-scope .metric-label-desc { font-size: 13.5px; color: var(--ink4-3); }

/* ---- Checklists (action checklist + read card): ruled rows, chartreuse ticks.
   Markup + ids untouched; the locked preview overlay keeps its own styles. ---- */
.v4-scope .checklist { background: none; border: 0; border-radius: 0; box-shadow: none;
  border-top: 2px solid var(--line4-2); padding: 13px 0 0; margin: 42px 0; }
.v4-scope .checklist-title { font-family: var(--mono4); font-size: 11px; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink4-3); }
.v4-scope .checklist-item { border-bottom: 1px solid var(--line4); padding: 11px 0;
  font-size: 15.5px; color: var(--ink4-2); background: none; }
.v4-scope .checklist-check { width: 19px; height: 19px; border-radius: 6px;
  border: 1.5px solid var(--line4-2); background: none; }
.v4-scope .checklist-item:hover .checklist-check { border-color: var(--hl); }
/* Interactive states - the SPA's real mechanics: a visually-hidden native
   <input class="section-checkbox"> drives li:has(:checked) (main checklist),
   and the read toggle sets .is-read + aria-checked on .section-read-item.
   Ticks go chartreuse (act colour) with the near-black check stroke. */
.v4-scope .checklist-items li:has(input.section-checkbox:checked) .checklist-check,
.v4-scope .section-read-item.is-read .checklist-check {
  background: var(--hl); border-color: var(--hl); }
.v4-scope .checklist-items li:has(input.section-checkbox:checked) .checklist-check::after,
.v4-scope .section-read-item.is-read .checklist-check::after {
  border-color: var(--on-hl); }
.v4-scope .checklist-items input.section-checkbox:checked ~ .checklist-text,
.v4-scope .section-read-item.is-read .checklist-text,
.v4-scope .checklist-items li.done {
  color: var(--ink4-3); text-decoration-color: var(--ghost4); }
.v4-scope .checklist-items input.section-checkbox:focus-visible + .checklist-check {
  outline-color: var(--hl); }

@media (max-width: 700px) {
  .v4-scope .threshold-row { grid-template-columns: 1fr; gap: 6px; }
  .v4-scope .metric-stacked { grid-template-columns: 1fr; gap: 4px; }
  .v4-scope .formula-vars { grid-template-columns: 1fr; }
  .v4-scope .formula-var-name { text-align: left; }
  .v4-scope .pullquote { padding-left: 56px; }
  .v4-scope .pullquote::before { font-size: 64px; }
  .v4-scope .founders-note { padding: 32px 24px 28px 64px; }
  .v4-scope .founders-note::before { left: 18px; font-size: 48px; }
  .v4-scope .principle { padding: 32px 24px; }
}

/* ============================================================
   V4 SECTION HEADER CHROME (Phase 4 step 2b, 2026-07-18).
   Shared by the SPA (build_section_html) and the /{slug}/ preview
   (preview.html): breadcrumb, ghost group-tinted numeral, icon
   chip (.schip3 family above), serif title, combined mono meta
   row. --gc arrives on the scoped container.
   ============================================================ */

/* Breadcrumb: quiet mono path (overrides the MS .breadcrumb + the
   preview template's inline .preview-breadcrumb - two classes, but
   .v4-scope wins on specificity). */
.v4-scope .breadcrumb { font-family: var(--mono4); font-size: 12px; font-weight: 400;
  text-transform: none; letter-spacing: 0.02em; color: var(--ink4-3);
  gap: 8px; margin-bottom: 32px; }
.v4-scope .breadcrumb a { color: inherit; }
.v4-scope .breadcrumb a:hover { color: var(--ink4); }
.v4-scope .breadcrumb .sep { color: var(--ink4-3); opacity: 0.5; }
.v4-scope .breadcrumb > span:last-child { color: var(--ink4-2); }

/* V4 spacing for the header block (MS gave it ~96px top padding). */
.v4-scope .section-head { padding: 34px 0 0; }
@media (max-width: 768px) { .v4-scope .section-head { padding: 18px 0 0; } }

.v4-scope .sec3-head { position: relative; display: flex; gap: 18px; align-items: flex-start;
  margin-bottom: 8px; }
.v4-scope .sec3-head .schip3-lg { margin-top: 6px; flex-shrink: 0; }
.v4-scope .sec3-head-tx { flex: 1; min-width: 0; }
.v4-scope .ghostn { position: absolute; right: -8px; top: -48px; font-family: var(--mono4);
  font-weight: 600; font-size: clamp(110px, 15vw, 200px); line-height: 1;
  letter-spacing: -0.04em; color: color-mix(in srgb, var(--gc, #fff) 7%, transparent);
  pointer-events: none; user-select: none; z-index: 0; }
.v4-scope .sec3-head > :not(.ghostn), .v4-scope .sec3-head-tx > * { position: relative; z-index: 1; }
.v4-scope .sec3-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  font-family: var(--mono4); font-size: 11.5px; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--ink4-3); margin: 0 0 18px; }
.v4-scope .sec3-num, .v4-scope .sec3-cat { color: var(--gc, var(--hl-ink)); font-weight: 600; }
.v4-scope .dot3 { width: 3px; height: 3px; border-radius: 50%; background: var(--ink4-3); }
.v4-scope .sec3-title { font-family: var(--serif); font-weight: 460; font-optical-sizing: auto;
  font-size: clamp(40px, 5.2vw, 68px); line-height: 1.02; letter-spacing: -0.024em;
  color: var(--ink4); margin: 0 0 16px; max-width: none; }
.v4-scope .sec3-sub { font-size: 17px; color: var(--ink4-3); line-height: 1.55;
  margin: 0 0 40px; max-width: 680px; }
@media (max-width: 980px) {
  .v4-scope .ghostn { font-size: 110px; top: -26px; }
}
@media (max-width: 560px) {
  .v4-scope .sec3-head { gap: 12px; }
  .v4-scope .sec3-sub { margin-bottom: 28px; }
}

/* ============================================================
   V4 ASIDE / RAIL / PREV-NEXT (Phase 4 step 2b-2).
   Rule-label headings, numbered mono TOC (CSS counters - no
   markup change), ledger-cell prev/next on three slots (SPA
   aside, inline mobile nav, preview bottom nav), quiet share
   tiles. NO border-left accents (structural hairline column
   dividers in the ledger cells are the mock's own language).
   ============================================================ */

/* Rule-label: the aside heading pattern (border-TOP heavy rule). */
.v4-scope .aside-label { font-family: var(--mono4); font-size: 11px; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink4-3);
  border-bottom: 0; border-top: 2px solid var(--line4-2);
  padding: 13px 0 0; margin-bottom: 14px; }

/* Prev/next ledger cells - shared inner structure (.schip3-sm chip +
   .section-nav-text) across the three slots. */
.v4-scope .aside-nav { display: flex; flex-direction: column; gap: 0; }
.v4-scope .aside-nav a { display: flex; align-items: center; gap: 10px;
  padding: 11px 2px; background: none; border: 0; border-radius: 0;
  border-bottom: 1px solid var(--line4); text-decoration: none;
  transition: background .14s ease; }
.v4-scope .aside-nav a:hover { background: rgba(255,255,255,0.028); border-color: var(--line4); }
.v4-scope .section-nav-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.v4-scope .section-nav-label { font-family: var(--mono4); font-size: 10px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink4-3); }
.v4-scope .section-nav-title { font-family: var(--sans); font-size: 13.5px; font-weight: 650;
  color: var(--ink4); letter-spacing: 0; overflow: hidden; text-overflow: ellipsis;
  white-space: nowrap; }
.v4-scope .aside-nav a:hover .section-nav-title,
.v4-scope .section-nav-inline a:hover .section-nav-title,
.v4-scope .preview-nav-link:hover .section-nav-title { color: var(--hl-ink); }
.v4-scope .aside-nav .schip3-sm, .v4-scope .section-nav-inline .schip3-sm,
.v4-scope .preview-nav .schip3-sm { flex-shrink: 0; }

/* Inline mobile nav + preview bottom nav: the two-cell ledger with a
   centre hairline (the mock's pn3). */
.v4-scope .section-nav-inline, .v4-scope .preview-nav {
  grid-template-columns: 1fr 1fr; gap: 0; margin: 44px 0 8px;
  border-top: 2px solid var(--line4-2); }
/* .preview-nav is always-on grid; .section-nav-inline keeps the MS
   display:none-desktop / grid-mobile toggle - don't set display on it. */
.v4-scope .preview-nav { display: grid; margin-top: 52px; }
.v4-scope .section-nav-inline .section-nav-prev,
.v4-scope .section-nav-inline .section-nav-next,
.v4-scope .preview-nav-link {
  display: flex; flex-direction: row; align-items: center; gap: 12px;
  padding: 16px 12px; background: none; border: 0; border-radius: 0;
  text-decoration: none; text-align: left; transition: background .14s ease; }
.v4-scope .section-nav-inline .section-nav-next,
.v4-scope .preview-nav .section-nav-next {
  flex-direction: row-reverse; text-align: right;
  border-left: 1px solid var(--line4); /* structural column divider */ }
.v4-scope .section-nav-inline .section-nav-next .section-nav-text,
.v4-scope .preview-nav .section-nav-next .section-nav-text { align-items: flex-end; }
.v4-scope .section-nav-inline a:hover, .v4-scope .preview-nav-link:hover {
  background: rgba(255,255,255,0.028); border-color: var(--line4); transform: none; }
@media (max-width: 560px) {
  .v4-scope .section-nav-inline, .v4-scope .preview-nav { grid-template-columns: 1fr; }
  .v4-scope .section-nav-inline .section-nav-next,
  .v4-scope .preview-nav .section-nav-next { border-left: 0; border-top: 1px solid var(--line4); }
}

/* Numbered mono jump-TOC (SPA aside + preview rail; counter, no markup
   change). Kills the MS border-left spine + accent active stripe. */
.v4-scope .aside-toc { counter-reset: atoc; margin: 0 0 var(--s-6); }
.v4-scope .aside-toc li { counter-increment: atoc; display: grid;
  grid-template-columns: 24px 1fr; gap: 10px; padding: 6px 0; margin: 0;
  border: 0; color: var(--ink4-3); font-size: 13.5px; line-height: 1.5; }
.v4-scope .aside-toc li::before { content: counter(atoc, decimal-leading-zero);
  font-family: var(--mono4); font-size: 11px; color: var(--ghost4); padding-top: 2px; }
.v4-scope .aside-toc li:hover { color: var(--ink4); border: 0; }
.v4-scope .aside-toc li.active { color: var(--ink4); font-weight: 650;
  border: 0; padding-left: 0; }
.v4-scope .aside-toc li.active::before { color: var(--hl-ink); }
.v4-scope .aside-toc a { color: inherit; text-decoration: none; }

/* Share tiles: quiet hairline pills; copied = chartreuse (act colour,
   NOT verdict green). */
.v4-scope .aside-share-tiles { gap: 8px; }
.v4-scope .aside-share-tile { width: 34px; height: 34px; background: none;
  border: 1px solid var(--line4); border-radius: 9px; color: var(--ink4-3); }
.v4-scope .aside-share-tile:hover { border-color: var(--line4-2); color: var(--ink4);
  background: rgba(255,255,255,0.03); transform: none; }
.v4-scope .aside-share-tile.is-copied { border-color: var(--hl); color: var(--hl-ink); }
.v4-scope .aside-share-tile.is-error { border-color: var(--err4); color: var(--err4); }

.v4-scope .section-share-block { border-top: 2px solid var(--line4-2);
  padding-top: 14px; margin: 48px 0 8px; }
.v4-scope .section-share-head { max-width: none; margin: 0 0 18px; text-align: left; }
.v4-scope .section-share-kicker { font-family: var(--mono4); color: var(--ink4-3); }
.v4-scope .section-share-title { font-family: var(--serif); font-weight: 500;
  font-size: 26px; letter-spacing: -0.012em; color: var(--ink4); margin: 0 0 8px; }
.v4-scope .section-share-desc { font-size: 15px; color: var(--ink4-2); }
.v4-scope .share-tiles { max-width: none; margin: 0 0 var(--s-5); gap: 8px; }
.v4-scope .share-tile { background: none; border: 1px solid var(--line4);
  border-radius: 10px; color: var(--ink4-2); padding: 12px 16px;
  font-family: var(--sans); }
.v4-scope .share-tile:hover { border-color: var(--line4-2); color: var(--ink4);
  background: rgba(255,255,255,0.03); transform: none; }
.v4-scope .share-tile.is-copied { border-color: var(--hl); color: var(--hl-ink); }
.v4-scope .share-tile.is-copied .share-tile-icon { color: var(--hl-ink); }
.v4-scope .share-tile.is-error { border-color: var(--err4); color: var(--err4); }

/* Preview rail: boxless (rule-label pattern); the .preview-rail-card
   CLASS stays - it's in the .is-authed hide contract. */
.v4-scope.preview-rail { gap: 30px; }
.v4-scope .preview-rail-card { background: none; border: 0; border-radius: 0;
  box-shadow: none; padding: 0; }
.v4-scope .preview-rail-eyebrow { font-family: var(--mono4); font-size: 11px;
  font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink4-3); border-top: 2px solid var(--line4-2);
  padding-top: 13px; margin-bottom: 14px; }
.v4-scope .preview-rail-title { font-size: 16px; font-weight: 700; color: var(--ink4);
  letter-spacing: 0; margin-bottom: 10px; }
.v4-scope .preview-rail-list li { color: var(--ink4-2); font-size: 13.5px; }
.v4-scope .preview-rail-list li::before { background: var(--hl); color: var(--on-hl); }
.v4-scope .preview-rail-note { color: var(--ink4-3); }

/* The act CTA (banner, gate, rail): chartreuse pill. */
.v4-scope .preview-cta { background: var(--hl); color: var(--on-hl); border: 0;
  border-radius: 99px; box-shadow: none; font-weight: 700;
  font-family: var(--sans); transition: transform .15s ease, filter .15s ease; }
/* Hover keeps the REST background (chartreuse on dark pages, or the dark pill
   when the CTA sits on a chartreuse band/gate) - it must never force
   `background: var(--hl)`, which turned the dark band-pill chartreuse with
   light text still on it (white-on-chartreuse). Just brighten + lift. */
.v4-scope .preview-cta:hover { filter: brightness(1.06); transform: translateY(-1px); }
.v4-scope .preview-cta--ghost { background: none; color: var(--ink4);
  border: 1px solid var(--line4-2); }
.v4-scope .preview-cta--ghost:hover { background: rgba(255,255,255,0.04);
  border-color: var(--line4-2); filter: none; }
/* Ghost on a chartreuse gate: keep near-black ink + a dark hover overlay
   (the generic ghost hover uses a light overlay/border that greys out on
   chartreuse). */
.v4-scope .page-gate .preview-cta--ghost:hover,
.v4-scope .contents-gate .preview-cta--ghost:hover {
  background: rgba(0,0,0,0.06); color: var(--on-hl);
  border-color: color-mix(in srgb, var(--on-hl) 55%, transparent); }

/* ============================================================
   V4 CALCULATOR RE-SKIN (Phase 4 step 2b-4). K1+ card language:
   ruled header, big answer readout, doctrine footer - NOT glassy
   (product UI keeps its box). Scoped to .v4-scope ONLY, so the
   unmigrated dashboard (no scope class) keeps the MS look; the
   .tg-* family is shared by three-gates + calc-kit + metrics.
   ============================================================ */

/* The card. Fixed 22px padding so the ruled header/footer can extend
   edge-to-edge with plain negative margins. */
.v4-scope .three-gates-calc, .v4-scope .calc-tool {
  background: var(--card4); border: 1px solid var(--line4); border-radius: 14px;
  padding: 22px; margin: 38px 0; box-shadow: 0 18px 56px rgba(0,0,0,0.3); }
.v4-scope .tg-calc-head { margin: -22px -22px 20px; padding: 15px 22px;
  border-bottom: 1px solid var(--line4); align-items: center; }
.v4-scope .tg-calc-title { font-size: 15.5px; font-weight: 700; color: var(--ink4);
  letter-spacing: 0; }
.v4-scope .tg-calc-sub { font-size: 12.5px; color: var(--ink4-3); margin-top: 3px; }

/* Inputs: dark wells, mono values, chartreuse focus (act colour). */
.v4-scope .tg-field-label { font-size: 12.5px; font-weight: 650; color: var(--ink4-3); }
.v4-scope .tg-in { background: var(--bg4); border: 1px solid var(--line4-2);
  border-radius: 8px; font-family: var(--mono4); font-weight: 600; color: var(--ink4); }
.v4-scope .tg-in:focus { border-color: var(--hl); }
.v4-scope .tg-toggle { background: var(--bg4); border: 1px solid var(--line4);
  border-radius: 10px; }
.v4-scope .tg-toggle-label { color: var(--ink4-2); }
.v4-scope .tg-toggle-btns { background: var(--card4-2); border: 1px solid var(--line4);
  border-radius: 8px; }
.v4-scope .tg-toggle-btn { color: var(--ink4-3); border-radius: 6px; }
.v4-scope .tg-toggle-btn:hover { color: var(--ink4); }
.v4-scope .tg-toggle-btn.is-on { background: var(--hl); color: var(--on-hl); }
.v4-scope .tg-tipbox, .v4-scope .tg-ch-tip { background: #101114;
  border-color: var(--line4-2); color: var(--ink4-2); }
.v4-scope .tg-info:hover, .v4-scope .tg-info:focus-visible,
.v4-scope .tg-info.is-open { color: var(--hl-ink); }

/* Verdict strip: state tint, hairline in the band colour - no blur. */
.v4-scope .calc-verdict { border-radius: 10px; background: var(--card4-2);
  border: 1px solid var(--line4); }
.v4-scope .calc-verdict--green { background: linear-gradient(180deg, rgba(52,201,126,0.10), rgba(52,201,126,0.05)), var(--card4-2); border-color: rgba(52,201,126,0.20); }
.v4-scope .calc-verdict--amber { background: linear-gradient(180deg, rgba(232,163,61,0.10), rgba(232,163,61,0.05)), var(--card4-2); border-color: rgba(232,163,61,0.20); }
.v4-scope .calc-verdict--red { background: linear-gradient(180deg, rgba(229,84,75,0.10), rgba(229,84,75,0.05)), var(--card4-2); border-color: rgba(229,84,75,0.20); }
.v4-scope .calc-verdict-band { font-family: var(--mono4); font-size: 10.5px;
  letter-spacing: 0.1em; }
.v4-scope .calc-verdict--green .tg-band-dot { background: var(--ok4); }
.v4-scope .calc-verdict--green .tg-band-word { color: var(--ok4); }
.v4-scope .calc-verdict--amber .tg-band-dot { background: var(--warn4); }
.v4-scope .calc-verdict--amber .tg-band-word { color: var(--warn4); }
.v4-scope .calc-verdict--red .tg-band-dot { background: var(--err4); }
.v4-scope .calc-verdict--red .tg-band-word { color: var(--err4); }
.v4-scope .calc-verdict-headline { color: var(--ink4); font-size: 16.5px; }
.v4-scope .calc-verdict-detail { color: var(--ink4-2); font-size: 13px; }

/* Outputs: boxless answer cells with hairline column dividers; the big
   mono readout is the K1+ moment. */
.v4-scope .calc-outputs { gap: 0; border-top: 1px solid var(--line4);
  margin: 16px 0; padding-top: 2px; }
.v4-scope .calc-out { background: none; border: 0; border-left: 1px solid var(--line4);
  border-radius: 0; padding: 14px 18px 6px; }
.v4-scope .calc-out:first-child { border-left: 0; padding-left: 0; }
.v4-scope .calc-out-value { font: 600 30px/1.1 var(--mono4); letter-spacing: -0.02em;
  color: var(--ink4); font-variant-numeric: tabular-nums; }
.v4-scope .calc-out-label { color: var(--ink4-2); }
.v4-scope .calc-out-sub { color: var(--ink4-3); }
@media (max-width: 560px) {
  .v4-scope .calc-out { border-left: 0; padding-left: 0; border-bottom: 1px solid var(--line4); padding-bottom: 12px; }
  .v4-scope .calc-out:last-child { border-bottom: 0; }
}

/* Doctrine footer: mono, top hairline. (Not pulled edge-to-edge - the
   public save-note can render after it.) */
.v4-scope .calc-foot, .v4-scope .tg-foot { border-top: 1px solid var(--line4);
  padding-top: 12px; margin-top: 16px; font-family: var(--mono4); font-size: 11px;
  line-height: 1.6; color: var(--ink4-3); }
.v4-scope .calc-foot a, .v4-scope .tg-foot a { color: var(--hl-ink); }
/* Example note: v4 keeps the amber warning strip (it must not recede into
   --ink4-3 the way it did before H - a worked example reading as an answer is
   the whole failure mode), just in v4's amber + mono. */
.v4-scope .calc-example-note { color: var(--ink4-2); font-family: var(--mono4);
  background: rgba(232,163,61,0.10); border-color: rgba(232,163,61,0.30); }
.v4-scope .calc-example-note strong { color: var(--ink4); }
/* Orientation block: boxless per v4 - a hairline-topped strip, not a card.
   The label is the mono accent; the copy is body ink so it reads as content
   rather than fine print (it is the only framing the dashboard gives). */
.v4-scope .calc-context { background: none; border: 0; border-left: 0;
  border-bottom: 1px solid var(--line4); border-radius: 0;
  padding: 0 0 14px; margin-bottom: 16px; }
.v4-scope .calc-context p { color: var(--ink4-2); font-size: 13px; }
.v4-scope .calc-context strong { color: var(--hl-ink); font-family: var(--mono4); }
.v4-scope .calc-group-head { font-family: var(--mono4); color: var(--ink4-3); }
.v4-scope .calc-sources > summary { font-family: var(--mono4); color: var(--ink4-3); }
.v4-scope .calc-save-note { font-size: 11.5px; color: var(--ink4-3); margin-top: 10px; }
.v4-scope .calc-save-note a { color: var(--hl-ink); }

/* Three Gates specifics: gate cards in state tints, mono numerals. */
.v4-scope .tg-gate { background: var(--card4-2); border: 1px solid var(--line4);
  border-radius: 10px; }
.v4-scope .tg-gate--green { background: linear-gradient(180deg, rgba(52,201,126,0.10), rgba(52,201,126,0.05)), var(--card4-2); border-color: rgba(52,201,126,0.20); }
.v4-scope .tg-gate--amber { background: linear-gradient(180deg, rgba(232,163,61,0.10), rgba(232,163,61,0.05)), var(--card4-2); border-color: rgba(232,163,61,0.20); }
.v4-scope .tg-gate--red { background: linear-gradient(180deg, rgba(229,84,75,0.10), rgba(229,84,75,0.05)), var(--card4-2); border-color: rgba(229,84,75,0.20); }
.v4-scope .tg-gate--green .tg-band-dot { background: var(--ok4); }
.v4-scope .tg-gate--green .tg-band-word { color: var(--ok4); }
.v4-scope .tg-gate--amber .tg-band-dot { background: var(--warn4); }
.v4-scope .tg-gate--amber .tg-band-word { color: var(--warn4); }
.v4-scope .tg-gate--red .tg-band-dot { background: var(--err4); }
.v4-scope .tg-gate--red .tg-band-word { color: var(--err4); }
.v4-scope .tg-gate-num { font-family: var(--mono4); color: var(--ink4-3); }
.v4-scope .tg-gate-name { color: var(--ink4); }
.v4-scope .tg-gate-value .tg-num { font: 600 26px/1.15 var(--mono4);
  letter-spacing: -0.02em; color: var(--ink4); font-variant-numeric: tabular-nums; }
.v4-scope .tg-gate-value .tg-sub { color: var(--ink4-3); }
.v4-scope .tg-gate-verdict { color: var(--ink4-2); }
.v4-scope .tg-derived { color: var(--ink4-3); font-family: var(--mono4); }
.v4-scope .tg-derived strong { color: var(--ink4); }
.v4-scope .tg-shape { color: var(--ink4-2); }

/* Consistency notice: hairline amber - the border-left stripe is retired. */
.v4-scope .tg-consistency { background: rgba(232,163,61,0.07);
  border: 1px solid rgba(232,163,61,0.3); border-radius: 10px; color: var(--ink4-2); }

/* Chart: chartreuse curve (brand), payback dot stays verdict green. */
.v4-scope .tg-ch-line { stroke: var(--hl); }
.v4-scope .tg-ch-pt { fill: var(--hl); }
.v4-scope .tg-chart [data-tip]:hover + .tg-ch-pt { fill: var(--hl-ink); }
.v4-scope .tg-ch-ncac { stroke: var(--ink4-3); }
.v4-scope .tg-ch-grid { stroke: var(--line4); }
.v4-scope .tg-ch-dot { fill: var(--ok4); }
.v4-scope .tg-ch-lbl { fill: var(--ink4-3); font: 500 10px var(--mono4); }
.v4-scope .tg-ch-lbl--ltv { fill: var(--ink4); }
.v4-scope .tg-mirror-reset { color: var(--hl-ink); }
.v4-scope .tg-mirror-reset:hover { color: var(--hl-ink); }

/* Actions: save = chartreuse pill; share tile copied = chartreuse. */
.v4-scope .tg-save { background: var(--hl); color: var(--on-hl); border: 0;
  border-radius: 99px; font-weight: 700;
  transition: transform .15s ease, filter .15s ease; }
.v4-scope .tg-save:hover { background: var(--hl); filter: brightness(1.06);
  transform: translateY(-1px); }
.v4-scope .tg-save-status.is-ok { color: var(--hl-ink); }
.v4-scope .tg-save-status.is-error { color: var(--err4); }
.v4-scope .tg-share { background: none; border: 1px solid var(--line4);
  border-radius: 9px; color: var(--ink4-3); }
.v4-scope .tg-share:hover { color: var(--ink4); border-color: var(--line4-2); }
.v4-scope .tg-share.is-copied { color: var(--hl-ink); border-color: var(--hl); }
.v4-scope .tg-share-status { color: var(--hl-ink); }

/* ============================================================
   V4 MINOR BLOCKS (Phase 4 step 2b-5): compare, steps, stages,
   vertical-steps, waterfall, tool-grid. Quiet CSS-only re-skins
   to the boxless ledger language - heavy top rules, hairline
   column dividers, ghost mono numerals. No markup changes.
   ============================================================ */

/* Compare: boxless columns, state-tinted top rule + label (good/bad IS
   verdict semantics, so green/red are correct here). */
.v4-scope .compare { gap: 0 36px; margin: 34px 0; }
.v4-scope .compare-card { --cw-tone: var(--ink4-3);
  background: none; border: 0; border-radius: 0; box-shadow: none;
  overflow: visible; padding: 13px 0 0;
  border-top: 2px solid color-mix(in srgb, var(--cw-tone) 55%, transparent); }
.v4-scope .compare-card--bad { --cw-tone: var(--err4); }
.v4-scope .compare-card--good { --cw-tone: var(--ok4); }
.v4-scope .compare-card--warning { --cw-tone: var(--warn4); }
.v4-scope .compare-card--neutral { --cw-tone: var(--ink4-3); }
.v4-scope .compare-card-label { font-family: var(--mono4); font-size: 11px;
  letter-spacing: 0.12em; color: var(--cw-tone); }
.v4-scope .compare-card--bad .compare-card-label,
.v4-scope .compare-card--bad .compare-icon { color: var(--err4); }
.v4-scope .compare-card--good .compare-card-label,
.v4-scope .compare-card--good .compare-icon { color: var(--ok4); }
.v4-scope .compare-card--warning .compare-card-label,
.v4-scope .compare-card--warning .compare-icon { color: var(--warn4); }
.v4-scope .compare-card li { color: var(--ink4-2); font-size: 13.5px; }
.v4-scope .compare-card li::before { background: var(--ghost4); }
.v4-scope .compare-card li strong { color: var(--ink4); }
.v4-scope .compare-card-footer { border-top: 1px solid var(--line4); color: var(--ink4); }
@media (max-width: 720px) { .v4-scope .compare { gap: 26px; } }

/* Steps: circles + glow track retired - ghost mono numerals in ruled
   columns (the homepage sys3-col pattern at reading scale). */
.v4-scope .hsteps { padding: 0; margin: 34px 0; border-top: 2px solid var(--line4-2); }
.v4-scope .hsteps::before { display: none; }
.v4-scope .hstep { align-items: flex-start; text-align: left;
  padding: 16px 20px 4px; border-left: 1px solid var(--line4); }
.v4-scope .hstep:first-child { border-left: 0; padding-left: 0; }
.v4-scope .hstep-circle { width: auto; height: auto; border: 0; border-radius: 0;
  background: none; box-shadow: none; font: 500 34px/1 var(--mono4);
  color: var(--ghost4); letter-spacing: -0.02em; margin-bottom: 12px; }
.v4-scope .hstep-circle::before { display: none; }
.v4-scope .hstep:hover .hstep-circle { transform: none; border-color: transparent; }
.v4-scope .hstep-title { font-size: 15.5px; font-weight: 700; color: var(--ink4); }
.v4-scope .hstep-desc { max-width: none; font-size: 13px; color: var(--ink4-3); }
@media (max-width: 720px) {
  .v4-scope .hstep { border-left: 0; padding: 14px 0 4px; border-bottom: 1px solid var(--line4); }
  .v4-scope .hstep:last-child { border-bottom: 0; }
}

/* Stages: equal-height cards -> ruled ledger columns; kicker takes the
   section's group colour (identity), range pill goes hairline. */
.v4-scope .stages { gap: 0; margin: 34px 0; border-top: 2px solid var(--line4-2); }
.v4-scope .stage { background: none; border: 0; border-radius: 0; box-shadow: none;
  min-height: 0; padding: 16px 20px 10px; border-left: 1px solid var(--line4); }
.v4-scope .stage:first-child { border-left: 0; padding-left: 0; }
.v4-scope .stage:hover { transform: none; box-shadow: none; border-color: var(--line4); }
.v4-scope .stage-num { font-size: 34px; color: var(--ghost4); }
.v4-scope .stage-icon { color: var(--gc, var(--hl-ink)); }
.v4-scope .stage-kicker { color: var(--gc, var(--hl-ink)); letter-spacing: 0.14em; }
.v4-scope .stage-title { font-size: 17px; color: var(--ink4); }
.v4-scope .stage-desc { font-size: 13.5px; color: var(--ink4-2); }
.v4-scope .stage-range { background: none; border: 1px solid var(--line4-2);
  color: var(--ink4-2); font-family: var(--mono4); }
@media (max-width: 720px) {
  .v4-scope .stages { grid-template-columns: 1fr; }
  .v4-scope .stage { border-left: 0; padding: 14px 0 10px; border-bottom: 1px solid var(--line4); }
  .v4-scope .stage:last-child { border-bottom: 0; }
}

/* Vertical steps: tiles + connector track retired - numbered ledger rows. */
.v4-scope .vsteps { padding-left: 0; max-width: none; margin: 34px 0;
  border-top: 2px solid var(--line4-2); }
.v4-scope .vsteps::before { display: none; }
.v4-scope .vstep { background: none; border: 0; border-radius: 0; box-shadow: none;
  margin-left: 0; padding: 16px 0 15px 60px; border-bottom: 1px solid var(--line4); }
.v4-scope .vstep + .vstep { margin-top: 0; }
.v4-scope .vstep-num { position: absolute; left: 0; top: 19px; width: auto; height: auto;
  background: none; border: 0; border-radius: 0; box-shadow: none;
  font: 500 22px/1 var(--mono4); color: var(--ghost4); letter-spacing: -0.02em; }
.v4-scope .vstep-head { margin-bottom: 5px; }
.v4-scope .vstep-title { color: var(--ink4); font-weight: 700; font-size: 15.5px; }
.v4-scope .vstep-body { color: var(--ink4-2); font-size: 14.5px; }
@media (max-width: 560px) { .v4-scope .vstep { padding-left: 44px; } }

/* Waterfall: the natural ledger - rules instead of the card; subtotals
   take the brand syntax colour (mirrors the formula's lead token). */
.v4-scope .waterfall { background: none; border: 0; border-radius: 0;
  padding: 14px 0 6px; margin: 34px 0;
  border-top: 2px solid var(--line4-2); border-bottom: 1px solid var(--line4); }
.v4-scope .waterfall-row { font-size: 14.5px; }
.v4-scope .waterfall-label { color: var(--ink4-2); }
.v4-scope .waterfall-value { color: var(--ink4); font-family: var(--mono4); }
.v4-scope .waterfall-sign { color: var(--ink4-3); font-family: var(--mono4); }
.v4-scope .waterfall-row--topline .waterfall-label { color: var(--ink4); }
.v4-scope .waterfall-row--subtotal { border-top: 1px solid color-mix(in srgb, var(--hl) 35%, transparent); }
.v4-scope .waterfall-row--subtotal .waterfall-label,
.v4-scope .waterfall-row--subtotal .waterfall-sign,
.v4-scope .waterfall-row--subtotal .waterfall-value { color: var(--hl-ink); }

/* ============================================================
   V4 BRAND DASHBOARD (Phase 4 step 3c, 2026-07-19). CSS-only
   over brand-admin.js markup (#view-brand-admin carries
   .v4-scope; fonts arrive via the --font-* remap). Rail active
   stripe retired; stat tiles go ledger; ring is chartreuse
   (gradient stops set in brand-admin.js); verdict bars/pills
   keep traffic-light semantics on v4 state colours.
   ============================================================ */
.v4-scope input[type="checkbox"] { accent-color: var(--hl); }
.v4-scope .brand-greeting { font-family: var(--mono4); color: var(--hl-ink); }
.v4-scope .brand-title { font-family: var(--serif); font-weight: 460;
  font-optical-sizing: auto; letter-spacing: -0.02em; color: var(--ink4); }
.v4-scope .brand-tagline { color: var(--ink4-3); }

.v4-scope .dash-rail-group { color: var(--ink4-3); }
.v4-scope .dash-rail-item { color: var(--ink4-2); border-radius: 8px; }
.v4-scope .dash-rail-item:hover { background: rgba(255,255,255,0.04); color: var(--ink4); }
.v4-scope .dash-rail-item.is-active { background: var(--accent-wash, rgba(198,232,74,0.09));
  border-color: transparent; color: var(--hl-ink); }
.v4-scope .dash-rail-item.is-active::before { display: none; }
.v4-scope .dash-rail-new-tag { color: var(--hl-ink);
  border-color: color-mix(in srgb, var(--hl) 40%, transparent); }

/* Stat tiles -> ledger cells (proof-strip language). */
.v4-scope .stat-tile { background: none; border: 0; border-radius: 0;
  border-top: 2px solid var(--line4-2); padding: 14px 18px 10px 0; }
.v4-scope .stat-tile-label { color: var(--ink4-3); }
.v4-scope .stat-tile-value { color: var(--ink4); font-variant-numeric: tabular-nums; }

.v4-scope .panel { border-bottom: 1px solid var(--line4); }
.v4-scope .panel-title { color: var(--ink4); font-size: 19px; letter-spacing: 0; }
.v4-scope .panel-sub { color: var(--ink4-3); }
.v4-scope .panel-sub-link { color: var(--hl-ink); }
.v4-scope .panel-sub-link:hover { color: var(--hl-ink); }

.v4-scope .score-panel { background: var(--card4); border: 1px solid var(--line4);
  border-radius: 14px; box-shadow: none; }
.v4-scope .score-ring-bg { stroke: var(--line4); }
.v4-scope .score-ring-value { font-family: var(--mono4); color: var(--ink4); }
.v4-scope .score-ring-pct { color: var(--ink4-3); }
.v4-scope .score-note { color: var(--ink4-3); }
.v4-scope .cat-bar-label { color: var(--ink4); }
.v4-scope .cat-bar-track { background: rgba(255,255,255,0.07); }
.v4-scope .cat-bar-fill { box-shadow: none; }
.v4-scope .cat-bar-val { font-family: var(--mono4); color: var(--ink4); }
.v4-scope .cat-bar[data-score="high"] { --bar-color: var(--ok4); }
.v4-scope .cat-bar[data-score="mid"] { --bar-color: var(--warn4); }
.v4-scope .cat-bar[data-score="low"] { --bar-color: var(--err4); }

.v4-scope .bsr { border-color: var(--line4); }
.v4-scope .bsr:hover { background: rgba(255,255,255,0.028); }
.v4-scope .bsr-title { color: var(--ink4); }
.v4-scope .bsr-tag, .v4-scope .bsr-count, .v4-scope .bsr-read { color: var(--ink4-3); }
.v4-scope .bsr-track { background: rgba(255,255,255,0.07); }
/* Boxless ledger conversion (2026-07-20): the round-2 pass tinted these
   containers but kept them as bordered cards. v4 replaces boxes with rules -
   see the "LEDGER" sub-block at the end of this section. brand-chart-card
   keeps a hairline frame (a floating chart with no container reads as
   unmoored - product UI border allowance). */
.v4-scope .brand-chart-card { background: var(--card4); border: 1px solid var(--line4); }
.v4-scope .brand-group-head { background: none; }
.v4-scope .dash-calc-pill { background: none; border: 1px solid var(--line4);
  color: var(--ink4-2); border-radius: 99px; }
.v4-scope .dash-calc-pill:hover { border-color: var(--line4-2); color: var(--ink4); }
.v4-scope .dash-calc-pill.is-on { background: var(--hl); border-color: var(--hl);
  color: var(--on-hl); }
.v4-scope .team-remove { color: var(--err4);
  border-color: color-mix(in srgb, var(--err4) 40%, transparent); }
.v4-scope .ap-sec { border-color: var(--line4); }
.v4-scope .ap-item.is-done { color: var(--ink4-3); }
.v4-scope .calc-hub-wip { background: var(--accent-wash, rgba(198,232,74,0.07));
  border: 1px solid color-mix(in srgb, var(--hl) 25%, transparent);
  border-radius: 10px; color: var(--ink4-2); }
.v4-scope .calc-hub-wip strong { color: var(--ink4); }

/* Progress/Fix-next rows (.bsr): boxed pills -> ledger rows; S-num de-boxed. */
.v4-scope .bsr { background: none; border: 0; border-radius: 0;
  border-bottom: 1px solid var(--line4); padding: 12px 4px; }
.v4-scope .bsr:hover { transform: none; background: rgba(255,255,255,0.028);
  border-color: var(--line4); }
.v4-scope .bsr-tag { background: none; padding: 0; border-radius: 0; }
.v4-scope .bsr-hc-na { color: var(--ink4-3); }

/* History chart card + tools/downloads: naked file glyph, chartreuse act. */
.v4-scope .tool-dl-card { background: var(--card4); border: 1px solid var(--line4); }
.v4-scope .tool-dl-icon { background: none; border-radius: 0; width: auto; height: auto;
  color: var(--ok4); }
.v4-scope .tool-dl-pill { background: none; border: 1px solid var(--line4);
  border-radius: 99px; font-family: var(--mono4); color: var(--ink4-3); }
.v4-scope .tool-dl-title { color: var(--ink4); }
.v4-scope .tool-dl-desc { color: var(--ink4-2); }
.v4-scope .tool-dl-cta { color: var(--hl-ink); }

/* Team: avatar + role chips off the MS blue. */
.v4-scope .team-avatar { background: rgba(198,232,74,0.15); color: var(--hl-ink); }
.v4-scope .team-role { color: var(--ink4-3); background: none;
  border: 1px solid var(--line4-2); border-radius: 99px; }
.v4-scope .team-meta-email { font-family: var(--mono4); }

/* Benchmarks tab: pills, add-data links, band dots, doctrine links. */
.v4-scope .dbm-pill { background: none; border-color: var(--line4); color: var(--ink4-2); }
.v4-scope .dbm-pill:hover { border-color: var(--line4-2); color: var(--ink4); }
.v4-scope .dbm-pill:focus-visible { outline-color: var(--hl); }
.v4-scope .dbm-pill.is-on { background: var(--hl); border-color: var(--hl); color: var(--on-hl); }
.v4-scope .dbm-pill.is-on .dbm-pill-sub { color: color-mix(in srgb, var(--on-hl) 65%, transparent); }
.v4-scope .dbm-row { border-top: 1px solid var(--line4); }
.v4-scope .dbm-add { color: var(--hl-ink); }
.v4-scope .dbm-row--green .tg-band-dot { background: var(--ok4); }
.v4-scope .dbm-row--amber .tg-band-dot { background: var(--warn4); }
.v4-scope .dbm-row--red .tg-band-dot { background: var(--err4); }
.v4-scope .dbm-row--info .tg-band-dot { background: var(--ink4-3); }
.v4-scope .dbm-links a { color: var(--hl-ink); }
.v4-scope .dbm-cap { color: var(--ink4-3); }
.v4-scope .dbm-meta { color: var(--ink4-3); }
.v4-scope .dbm-meta a { color: var(--hl-ink); }
.v4-scope .dbm-meta-n { font-family: var(--mono4); color: var(--ink4-2); }
.v4-scope .mp-soon-tag { color: var(--hl-ink);
  border-color: color-mix(in srgb, var(--hl) 35%, transparent); }

/* ============================================================
   V4 DASHBOARD - BOXLESS LEDGER (Phase 4, 2026-07-20).
   The round-2 pass was colour; this is the layout: every bordered
   container becomes a boxless ledger block (heavy 2px opener rule,
   hairline row separators). Boxes survive ONLY for product UI (the
   score report + the history chart). No JS hooks touched.
   ============================================================ */

/* Overview "Fix next" - boxless rows under a heavy rule */
.v4-scope .dash-fixnext { background: none; border: 0; border-radius: 0;
  border-top: 2px solid var(--line4-2); }

/* Progress accordion - bordered cards -> ledger rows */
.v4-scope .brand-groups { border-top: 2px solid var(--line4-2); }
.v4-scope .brand-group { background: none; border: 0; border-radius: 0;
  border-bottom: 1px solid var(--line4); overflow: visible; }
.v4-scope .brand-group:hover { border-color: var(--line4); }
.v4-scope .brand-group.is-open { border-color: var(--line4); box-shadow: none;
  background: rgba(255,255,255,0.015); }
.v4-scope .brand-group-head { padding-left: 4px; padding-right: 4px; }
.v4-scope .brand-group-head:hover { background: rgba(255,255,255,0.028); }
.v4-scope .bg-head-num { color: var(--row-accent, var(--hl-ink)); }
.v4-scope .bg-head-title { color: var(--ink4); }
.v4-scope .bg-head-count, .v4-scope .bg-metric-label,
.v4-scope .brand-group-priority { color: var(--ink4-3); font-family: var(--mono4); }
.v4-scope .bg-progress-track { background: rgba(255,255,255,0.07); }
.v4-scope .bg-progress-num { font-family: var(--mono4); color: var(--ink4-2); }
.v4-scope .brand-group-body { border-top: 1px solid var(--line4); padding-left: 4px; padding-right: 4px; }

/* Action Plan - bordered group cards -> ledger blocks */
.v4-scope .ap-groups { border-top: 2px solid var(--line4-2); gap: 0; }
.v4-scope .ap-group { background: none; border: 0; border-radius: 0;
  border-bottom: 1px solid var(--line4); padding: 22px 4px; }
.v4-scope .ap-group-name { color: var(--ink4); }
.v4-scope .ap-group-rec { color: var(--ink4-2); }
.v4-scope .ap-sec { border-color: var(--line4); }
.v4-scope .ap-sec-tag { font-family: var(--mono4); color: var(--ink4-3); }
.v4-scope .ap-sec-title { color: var(--ink4); }
.v4-scope .ap-item { color: var(--ink4-2); }
.v4-scope .ap-sec-link { color: var(--hl-ink); }

/* Benchmarks - ledger recolour (the aligned-ledger LAYOUT lives in the
   base .dbm-* block; only inks/lines/wash are themed here) */
.v4-scope .dbm-group { border-top-color: var(--line4-2); }
.v4-scope .dbm-group-name { font-family: var(--mono4); color: var(--ink4-3); }
.v4-scope .dbm-row { border-top-color: var(--line4); }
.v4-scope .dbm-label { color: var(--ink4); }
.v4-scope .dbm-value { font-family: var(--mono4); color: var(--ink4); }
.v4-scope .dbm-bandtext { color: var(--ink4-2); }
.v4-scope .dbm-note { color: var(--ink4-3); }
.v4-scope .dbm-foot { border-top-color: var(--line4); }
.v4-scope .dbm-hc { background: var(--accent-wash, rgba(198,232,74,0.07));
  border: 1px solid color-mix(in srgb, var(--hl) 22%, transparent); }
.v4-scope .dbm-hc-k { font-family: var(--mono4); color: var(--hl-ink); }
.v4-scope .dbm-hc-body { color: var(--ink4-2); }
.v4-scope .dbm-hc-body strong { color: var(--ink4); }
.v4-scope .dbm-hc-wait { color: var(--ink4-3); }

/* Tools & Exports - bordered cards -> top-ruled ledger columns (.t3 pattern) */
.v4-scope .tool-dl-card { background: none; border: 0; border-radius: 0;
  border-top: 2px solid var(--line4-2); padding: 22px 0 0; }
.v4-scope .tool-dl-card:hover { transform: none; box-shadow: none; border-color: var(--line4-2); }
.v4-scope .tool-dl-title { color: var(--ink4); }
.v4-scope .tool-dl-desc { color: var(--ink4-2); }
.v4-scope .tool-dl-pill { background: none; border: 1px solid var(--line4);
  border-radius: 99px; font-family: var(--mono4); color: var(--ink4-3); }
.v4-scope .tool-dl-icon { background: none; width: auto; height: auto; border-radius: 0; color: var(--ok4); }
.v4-scope .tool-dl-cta, .v4-scope .tool-dl-card:hover .tool-dl-cta { color: var(--hl-ink); }

/* Team - member table + visibility cards -> boxless ledger */
.v4-scope .team-table { background: none; border: 0; border-radius: 0;
  border-top: 2px solid var(--line4-2); margin: 0 0 var(--s-5); }
.v4-scope .team-row { border-bottom: 1px solid var(--line4); padding-left: 4px; padding-right: 4px; }
.v4-scope .team-meta-name { color: var(--ink4); }
.v4-scope .brand-visibility-cards { border-top: 2px solid var(--line4-2); }
.v4-scope .brand-vis-card { background: none !important; border: 0 !important;
  border-radius: 0 !important; padding: 20px 28px 20px 0 !important; }
.v4-scope .brand-vis-personal { border-left: 1px solid var(--line4) !important; padding-left: 28px !important; }
@media (max-width: 620px) {
  .v4-scope .brand-vis-personal { border-left: 0 !important; padding-left: 0 !important; }
}

/* ============================================================
   V4 HEALTH CHECK (Phase 4 step 3b, 2026-07-19). CSS-only over
   healthcheck.js markup (#view-healthcheck carries .v4-scope).
   Chartreuse = act + score ring; green/amber/red = verdicts;
   cards stay for interactive product UI, chrome goes quiet.
   ============================================================ */

/* Shared buttons (healthcheck.js reuses .btn/.btn--primary/.btn--ghost) */
.v4-scope .btn { border-radius: 99px; font-family: var(--sans); }
.v4-scope .btn--primary { background: var(--hl); color: var(--on-hl); border: 0;
  font-weight: 700; box-shadow: none;
  transition: transform .15s ease, filter .15s ease; }
.v4-scope .btn--primary:hover { background: var(--hl); filter: brightness(1.06);
  transform: translateY(-1px); box-shadow: none; }
.v4-scope .btn--ghost { background: none; color: var(--ink4);
  border: 1px solid var(--line4-2); }
.v4-scope .btn--ghost:hover { background: rgba(255,255,255,0.04);
  border-color: var(--line4-2); }

/* Intro / shells */
.v4-scope .hc-eyebrow { background: none; border: 0; padding: 0;
  font-family: var(--mono4); color: var(--hl-ink); letter-spacing: 0.16em; }
.v4-scope .hc-eyebrow .dot { background: var(--hl); box-shadow: none; }
.v4-scope .hc-title { font-family: var(--serif); font-weight: 460;
  font-optical-sizing: auto; letter-spacing: -0.024em; color: var(--ink4); }
.v4-scope .hc-subtitle { color: var(--ink4-2); }
.v4-scope .hc-back-link, .v4-scope .hc-kicker { font-family: var(--mono4); color: var(--ink4-3); }
.v4-scope .hc-link-btn { color: var(--hl-ink); }
.v4-scope .hc-inline-status { color: var(--ink4-3); }

/* Tier card (intro CTA card) */
.v4-scope .hc-tier { background: var(--card4); border: 1px solid var(--line4);
  border-radius: 14px; box-shadow: 0 18px 56px rgba(0,0,0,0.3); }
.v4-scope .hc-tier:hover { border-color: var(--line4-2);
  box-shadow: 0 18px 56px rgba(0,0,0,0.35); }
.v4-scope .hc-tier--recommended { border-color: color-mix(in srgb, var(--hl) 35%, transparent);
  background: linear-gradient(180deg, var(--hl-glow), transparent 55%), var(--card4); }
.v4-scope .hc-tier-badge { background: var(--hl); color: var(--on-hl);
  border-radius: 99px; box-shadow: none; font-family: var(--mono4); }
.v4-scope .hc-tier-label { color: var(--hl-ink); font-family: var(--mono4); }
.v4-scope .hc-tier-title { color: var(--ink4); }
.v4-scope .hc-tier-desc, .v4-scope .hc-tier-reason { color: var(--ink4-2); }
.v4-scope .hc-tier-meta-row { color: var(--ink4-3); }
.v4-scope .hc-tier-resume-note { color: var(--hl-ink); }

/* Stage picker */
.v4-scope .hc-stage-shell h2 { font-family: var(--serif); font-weight: 480;
  color: var(--ink4); letter-spacing: -0.02em; }
.v4-scope .hc-stage-card { background: var(--card4); border: 1px solid var(--line4);
  border-radius: 12px; box-shadow: none; }
.v4-scope .hc-stage-card:hover { border-color: var(--line4-2);
  background: var(--card4-2); }
.v4-scope .hc-stage-card:focus-visible { outline-color: var(--hl); }
.v4-scope .hc-stage-num { font-family: var(--mono4); color: var(--ghost4); }
.v4-scope .hc-stage-kicker { font-family: var(--mono4); color: var(--hl-ink); }
.v4-scope .hc-stage-name { color: var(--ink4); }
.v4-scope .hc-stage-desc, .v4-scope .hc-stage-meta { color: var(--ink4-3); }
.v4-scope .hc-stage-icon { color: var(--ink4-2); }

/* Question flow */
.v4-scope .hc-progress-fill { background: var(--hl); box-shadow: none; }
.v4-scope .hc-progress-label { font-family: var(--mono4); color: var(--ink4-3); }
.v4-scope .hc-question-cat { font-family: var(--mono4); color: var(--hl-ink); }
.v4-scope .hc-question-text { color: var(--ink4); }
.v4-scope .hc-question-hint { color: var(--ink4-3); }
.v4-scope .hc-option { background: var(--card4); border: 1px solid var(--line4);
  border-radius: 10px; box-shadow: none; }
.v4-scope .hc-option:hover { background: var(--card4-2); border-color: var(--line4-2);
  transform: none; }
.v4-scope .hc-option:hover .hc-option-num { color: var(--ink4); border-color: var(--line4-2); }
.v4-scope .hc-option.is-selected { border-color: var(--hl);
  background: linear-gradient(90deg, var(--hl-glow), transparent 60%), var(--card4);
  box-shadow: 0 0 0 1px var(--hl) inset; }
.v4-scope .hc-option.is-selected .hc-option-num { background: var(--hl);
  color: var(--on-hl); border-color: var(--hl); }
.v4-scope .hc-option-num { font-family: var(--mono4); border-color: var(--line4-2);
  color: var(--ink4-3); }
.v4-scope .hc-option-lead { color: var(--ink4); }
.v4-scope .hc-option-text { color: var(--ink4-2); }
.v4-scope .hc-option-check { color: var(--hl-ink); }
.v4-scope .hc-na-btn.is-selected { border-color: var(--hl); color: var(--ink4); }
.v4-scope .hc-na-btn.is-selected .hc-na-check { background: var(--hl);
  border-color: var(--hl); color: var(--on-hl); }
.v4-scope .hc-save-btn { font-family: var(--mono4); border-radius: 99px; }
.v4-scope .hc-save-btn.is-saved { color: var(--hl-ink);
  border-color: color-mix(in srgb, var(--hl) 50%, transparent); }

/* Results */
.v4-scope .hc-gauge { background: conic-gradient(var(--hl) calc(var(--hc-score, 0) * 1%), var(--card4-2) 0%);
  box-shadow: 0 0 0 1px var(--line4) inset; }
.v4-scope .hc-gauge-ring, .v4-scope .hc-gauge-inner { background: var(--bg4); }
.v4-scope .hc-gauge-score { font-family: var(--mono4); color: var(--ink4); }
.v4-scope .hc-gauge-rating { color: var(--hl-ink); font-family: var(--mono4); }
.v4-scope .hc-cat-row { border-bottom: 1px solid var(--line4); }
.v4-scope .hc-cat-name { color: var(--ink4); }
.v4-scope .hc-cat-dot { box-shadow: none; }
.v4-scope .hc-cat-track { background: rgba(255,255,255,0.07); }
.v4-scope .hc-cat-fill { box-shadow: none; }
.v4-scope .hc-cat-val { font-family: var(--mono4); color: var(--ink4); }
.v4-scope .hc-cat-row[data-status="high"] { --cat-color: var(--ok4); }
.v4-scope .hc-cat-row[data-status="mid"]  { --cat-color: var(--warn4); }
.v4-scope .hc-cat-row[data-status="low"]  { --cat-color: var(--err4); }
.v4-scope .hc-bar-fill { box-shadow: none; }
.v4-scope .hc-recs-head { font-family: var(--mono4); color: var(--ink4-3);
  border-bottom: 0; border-top: 2px solid var(--line4-2); padding-top: 13px; }
.v4-scope .hc-rec-chip { background: none; border: 1px solid var(--line4);
  border-radius: 10px; color: var(--ink4-2); }
.v4-scope .hc-rec-chip:hover { border-color: var(--line4-2); color: var(--ink4); }
.v4-scope .hc-weak-item strong { color: var(--ink4); }
.v4-scope .hc-weak-meta { color: var(--ink4-3); }
.v4-scope .hc-cta-card { background: var(--card4); border: 1px solid var(--line4);
  border-radius: 14px; }
.v4-scope .hc-cta-kicker { font-family: var(--mono4); color: var(--hl-ink); }
.v4-scope .hc-cta-title { color: var(--ink4); }

/* ============================================================
   V4 HEALTH CHECK - full A3 layout (Phase 4, 2026-07-20).
   The step-3b pass was tokens over the MS card layouts; this
   is the actual ledger/serif structure: left-aligned serif
   display intro, ledger-row stage picker, and a results REPORT
   built from the homepage hero's own .rep/.ring3/.cat3 family
   (DECISIONS: "the HC results report is the source of the
   homepage mock"). All hooks (.hc-stage-card/data-stage,
   .hc-option, .hc-link-btn, .hc-rec-chip[data-section]) kept.
   ============================================================ */

/* Shells left-align + widen for the ledger. .hc-shell/-stage-/-results-
   inherit centre + 760px from the MS base rule - out-specify with .v4-scope. */
.v4-scope .hc3-intro,
.v4-scope .hc-stage-shell,
.v4-scope .hc-resume-shell { max-width: 840px; text-align: left; }
.v4-scope .hc3-results { max-width: 1120px; text-align: left; }

/* Shared editorial pieces */
.v4-scope .hc3-kick { font-family: var(--mono4); font-size: 12px; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--hl-ink); margin: 0 0 20px; }
.v4-scope .hc-title em, .v4-scope .hc3-display em { font-style: italic; font-weight: 420; }
.v4-scope .hc3-h2 { font-family: var(--serif); font-weight: 480; letter-spacing: -0.02em;
  font-size: clamp(30px, 3.6vw, 46px); line-height: 1.04; color: var(--ink4); margin: 0 0 12px; }
.v4-scope .hc3-lead { font-size: 17px; line-height: 1.62; color: var(--ink4-2);
  max-width: 40em; margin: 0 0 30px; }
.v4-scope .hc3-lead b { color: var(--hl-ink); font-weight: 600; }

/* Intro - serif display + ledger facts strip (boxless) */
.v4-scope .hc3-intro .hc-title { font-family: var(--serif); font-weight: 460;
  font-optical-sizing: auto; font-size: clamp(38px, 5vw, 68px); line-height: 1.0;
  letter-spacing: -0.024em; color: var(--ink4); margin: 0 0 20px; }
.v4-scope .hc3-intro .hc-subtitle { margin: 0 0 40px; max-width: 34em; color: var(--ink4-2);
  font-size: 18px; }
.v4-scope .hc3-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0;
  border-top: 2px solid var(--line4-2); margin: 0 0 40px; }
.v4-scope .hc3-fact { padding: 20px 28px 22px; border-left: 1px solid var(--line4); }
.v4-scope .hc3-fact:first-child { border-left: 0; padding-left: 0; }
.v4-scope .hc3-fact b { display: block; font-family: var(--serif); font-weight: 500;
  font-size: 26px; letter-spacing: -0.015em; color: var(--ink4); margin-bottom: 8px; }
.v4-scope .hc3-fact span { font-size: 13.5px; line-height: 1.55; color: var(--ink4-3); }
.v4-scope .hc3-cta-row { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.v4-scope .hc3-start { padding: 14px 24px; font-size: 15.5px; }
.v4-scope .hc-tier-reason { border-left: 0; background: none; padding: 0; margin-top: 18px;
  max-width: 40em; color: var(--ink4-3); font-size: 13.5px; opacity: 1; max-height: none; overflow: visible; }

/* Stage picker + resume - ledger rows */
.v4-scope .hc3-rows { border-top: 2px solid var(--line4-2); }
.v4-scope .hc-stage-card { display: grid; grid-template-columns: 44px 30px 1fr 24px;
  align-items: center; gap: 16px; width: 100%; text-align: left; padding: 20px 4px;
  min-height: 0; background: none; border: 0; border-bottom: 1px solid var(--line4); border-radius: 0;
  box-shadow: none; cursor: pointer; transition: background .14s ease; }
.v4-scope .hc-stage-card:hover { background: rgba(255,255,255,0.028); border-color: var(--line4); transform: none; }
.v4-scope .hc-stage-card:focus-visible { outline: 2px solid var(--hl); outline-offset: -2px; }
.v4-scope .hc3-row-num { font-family: var(--mono4); font-size: 22px; font-weight: 500;
  color: var(--ghost4); letter-spacing: -0.02em; align-self: start; padding-top: 2px; }
.v4-scope .hc3-row-icon { display: grid; place-items: center; color: var(--hl-ink); align-self: start; padding-top: 3px; }
.v4-scope .hc3-row-icon svg { width: 22px; height: 22px; }
.v4-scope .hc3-row-body { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.v4-scope .hc3-row-name { font-size: 18px; font-weight: 700; color: var(--ink4); }
.v4-scope .hc-stage-card:hover .hc3-row-name { color: var(--hl-ink); }
.v4-scope .hc3-row-desc { font-size: 14px; line-height: 1.55; color: var(--ink4-3); }
.v4-scope .hc3-row-meta { font-family: var(--mono4); font-size: 11.5px; color: var(--ink4-3);
  letter-spacing: 0.02em; margin-top: 2px; }
.v4-scope .hc3-row-arr { color: var(--ink4-3); font-size: 18px; text-align: right;
  align-self: center; transition: transform .15s ease, color .15s ease; }
.v4-scope .hc-stage-card:hover .hc3-row-arr { transform: translateX(3px); color: var(--hl-ink); }
.v4-scope .hc-resume-shell .hc3-facts { margin-bottom: 32px; }
.v4-scope .hc-resume-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.v4-scope .hc-resume-fineprint { color: var(--ink4-3); font-size: 13px; margin-top: 16px; }

/* Progress-top row (stage/question header) reads as quiet mono meta */
.v4-scope .hc-progress-top { border-bottom: 0; }
.v4-scope .hc-back-link { font-family: var(--mono4); font-size: 12px; letter-spacing: 0.04em;
  color: var(--ink4-3); background: none; border: 0; cursor: pointer; padding: 4px 0; }
.v4-scope .hc-back-link:hover { color: var(--ink4); background: none; }

/* ---- Results report ---- */
.v4-scope .hc3-results-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 460px);
  gap: 64px; align-items: center; margin-bottom: 8px; }
.v4-scope .hc3-results-copy .hc3-display { font-family: var(--serif); font-weight: 460;
  font-optical-sizing: auto; font-size: clamp(40px, 5.4vw, 72px); line-height: 1.0;
  letter-spacing: -0.024em; color: var(--ink4); margin: 0 0 22px; }
.v4-scope .hc3-results-copy .hc3-lead { font-size: 18px; max-width: none; margin: 0 0 30px; }
.v4-scope .hc-results-actions { display: flex; gap: 14px; flex-wrap: wrap; margin: 0; }

/* The report card + bar animation (mirrors the homepage .hero3-visual mechanic
   but keyed to .hc3-report.in so it fires when the results view mounts). */
.v4-scope .hc3-report { position: relative; }
.v4-scope .hc3-report .rep { box-shadow: 0 30px 80px rgba(0,0,0,0.4); }
.v4-scope .hc3-report .bar3 b { transition-delay: calc(var(--i, 0) * 0.07s + 0.15s); }
.v4-scope .hc3-report.in .bar3 b { width: var(--w); }
@media (prefers-reduced-motion: reduce) {
  .v4-scope .hc3-report .bar3 b { width: var(--w) !important; transition: none; }
}

/* Focus + recommended reading - ledger blocks under the report */
.v4-scope .hc3-block { margin: 44px 0 0; }
.v4-scope .hc3-rule-label { display: block; font-family: var(--mono4); font-size: 11px;
  font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink4-3);
  border-top: 2px solid var(--line4-2); padding-top: 13px; margin-bottom: 6px; }
.v4-scope .hc3-focus-rows { display: block; }
.v4-scope .hc3-frow { display: grid; grid-template-columns: 34px 1fr auto auto; align-items: center;
  gap: 16px; padding: 15px 4px; border-bottom: 1px solid var(--line4); }
.v4-scope .hc3-frow .hc3-row-num { font-size: 15px; padding-top: 0; align-self: center; }
.v4-scope .hc3-frow-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.v4-scope .hc3-frow-body strong { color: var(--ink4); font-weight: 650; font-size: 16px; }
.v4-scope .hc3-frow-meta { font-family: var(--mono4); font-size: 11px; color: var(--ink4-3);
  letter-spacing: 0.02em; }
.v4-scope .hc3-frow-pct { font-family: var(--mono4); font-weight: 600; font-size: 17px;
  font-variant-numeric: tabular-nums; text-align: right; }
.v4-scope .hc3-pct--ok { color: var(--ok4); }
.v4-scope .hc3-pct--warn { color: var(--warn4); }
.v4-scope .hc3-pct--err { color: var(--err4); }
.v4-scope .hc3-frow .hc-link-btn { font-family: var(--mono4); font-size: 12px; color: var(--hl-ink);
  background: none; border: 0; cursor: pointer; white-space: nowrap; padding: 0; }
.v4-scope .hc3-frow .hc-link-btn:hover { text-decoration: underline; text-underline-offset: 3px; }

.v4-scope .hc3-recs { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.v4-scope .hc3-recs .hc-rec-chip { display: inline-flex; align-items: center; gap: 10px;
  background: none; border: 1px solid var(--line4); border-radius: 99px; padding: 8px 16px 8px 12px;
  color: var(--ink4-2); font-size: 14px; font-weight: 550; cursor: pointer;
  transition: border-color .14s ease, color .14s ease; }
.v4-scope .hc3-recs .hc-rec-chip:hover { border-color: var(--line4-2); color: var(--ink4); }
.v4-scope .hc3-recs .hc-rec-chip::after { display: none; }
.v4-scope .hc3-rec-s { font-family: var(--mono4); font-size: 11.5px; font-weight: 600;
  color: var(--hl-ink); letter-spacing: 0.04em; }
.v4-scope .hc3-rec-arr { color: var(--ink4-3); font-size: 14px; }
.v4-scope .hc3-recs .hc-rec-chip:hover .hc3-rec-arr { color: var(--hl-ink); }

@media (max-width: 860px) {
  .v4-scope .hc3-results-grid { grid-template-columns: 1fr; gap: 40px; }
  .v4-scope .hc3-facts { grid-template-columns: 1fr; }
  .v4-scope .hc3-fact { border-left: 0; padding-left: 0; border-top: 1px solid var(--line4); }
  .v4-scope .hc3-fact:first-child { border-top: 0; }
}
@media (max-width: 560px) {
  .v4-scope .hc-stage-card { grid-template-columns: 34px 1fr 20px; gap: 12px; }
  .v4-scope .hc3-row-icon { display: none; }
  .v4-scope .hc3-frow { grid-template-columns: 28px 1fr auto; gap: 10px; }
  .v4-scope .hc3-frow .hc-link-btn { grid-column: 2 / -1; text-align: left; }
}

/* ============================================================
   V4 INDEX VIEW (Phase 4 step 3a, 2026-07-19). The list-row
   anatomy stays (Rob likes it - icons were already naked here);
   this is typography + tokens: serif title, mono jump chips,
   mono group numerals, v4 inks. All hydration hooks untouched.
   ============================================================ */
.v4-scope .index-head-kicker { font-family: var(--mono4); font-size: 12px;
  font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--hl-ink); background: none; border: 0; padding: 0; }
.v4-scope .index-title { font-family: var(--serif); font-weight: 460;
  font-optical-sizing: auto; font-size: clamp(38px, 4.6vw, 60px); line-height: 1.02;
  letter-spacing: -0.024em; color: var(--ink4); }
.v4-scope .index-title .accent { color: var(--hl-ink); }
.v4-scope .index-lead { color: var(--ink4-2); }
.v4-scope .index-jumpnav { background: rgba(16,17,20,0.88); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line4); }
.v4-scope .index-jump { font-family: var(--sans); font-weight: 600; font-size: 13.5px;
  color: var(--ink4-3); background: none; border: 0; border-radius: 99px; }
.v4-scope .index-jump:hover { color: var(--ink4); background: rgba(255,255,255,0.05); }
.v4-scope .group-head-num { font-family: var(--mono4); color: var(--ghost4); }
.v4-scope .group-head-title { color: var(--ink4); }
.v4-scope .group-head-sub { color: var(--ink4-3); }
.v4-scope .group-head-count { font-family: var(--mono4); color: var(--ink4-3); }
.v4-scope .group--list { border: 0; background: none; }

/* Group heads as CHAPTER DIVIDERS (Rob "Option A", 2026-07-20): serif group
   name + a large faint group-tinted GHOST numeral (the reading-page signature),
   opened by a heavy ledger rule. Drives BOTH /contents/ and the signed-in
   /#index. The section rows below stay quiet ledger rows on purpose. */
.v4-scope .group[data-group="foundation"] { --gc: var(--g-foundation); }
.v4-scope .group[data-group="business"]   { --gc: var(--g-business); }
.v4-scope .group[data-group="growth"]     { --gc: var(--g-growth); }
.v4-scope .group[data-group="brand"]      { --gc: var(--g-brand); }
.v4-scope .group[data-group="retention"]  { --gc: var(--g-retention); }
.v4-scope .group[data-group="scale"]      { --gc: var(--g-scale); }
.v4-scope .group[data-group="numbers"]    { --gc: var(--g-numbers); }
.v4-scope .group[data-group="exit"]       { --gc: var(--g-exit); }
.v4-scope .group--list .group-head { position: relative; display: block; overflow: hidden;
  border-top: 2px solid var(--line4-2); border-bottom: 0; padding: 32px 0 18px; margin-bottom: 4px; }
.v4-scope .group--list .group-head-num { position: absolute; right: 0; top: 4px; min-width: 0;
  font-family: var(--mono4); font-weight: 500; font-size: 92px; line-height: 0.82;
  letter-spacing: -0.04em; z-index: 0; pointer-events: none;
  color: color-mix(in srgb, var(--gc, var(--ink4-3)) 15%, transparent); }
.v4-scope .group--list .group-head-title { position: relative; z-index: 1; font-family: var(--serif);
  font-weight: 500; font-size: clamp(25px, 2.8vw, 33px); letter-spacing: -0.015em;
  color: var(--ink4); line-height: 1.05; }
.v4-scope .group--list .group-head-sub { position: relative; z-index: 1; display: inline-block;
  margin: 10px 0 0; font-family: var(--sans); font-size: 13.5px; letter-spacing: 0;
  text-transform: none; color: var(--ink4-3); }
.v4-scope .group--list .group-head-sub::before { content: none; }
.v4-scope .group--list .group-head-count { position: relative; z-index: 1; display: inline-block;
  margin-left: 0; font-family: var(--mono4); font-size: 11px; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--ink4-3); }
.v4-scope .group--list .group-head-count::before { content: "\00B7"; margin: 0 9px; color: var(--ink4-3); }
/* Category hubs reuse the .section-row ledger but have no group-head (the page
   hero names the category), so the row list opens with its own heavy rule. */
.v4-scope .cat-hub .section-rows { border-top: 2px solid var(--line4-2); margin-top: 8px; }

.v4-scope .section-row-num { font-family: var(--mono4); color: var(--ink4-3); }
.v4-scope .section-row-title { color: var(--ink4); }
.v4-scope .section-row-sub { color: var(--ink4-3); }
.v4-scope .section-row { border-bottom: 1px solid var(--line4); background: none; }
.v4-scope .section-row:hover { background: rgba(255,255,255,0.028); }
.v4-scope .section-row:hover .section-row-title { color: var(--hl-ink); }
.v4-scope .section-state-read { font-family: var(--mono4); }

/* ============================================================
   V4 AUTHED HOME (Phase 4 step 3a, 2026-07-19). Serif tagline
   hero + ledger step columns + boxless orientation columns.
   JS hooks kept: .step[data-step] / [data-step-cta] /
   [data-step-desc] / .is-done (updateHomeSteps), .share-tile.
   ============================================================ */
.home3 .hero { padding: 64px 0 8px; text-align: left; max-width: none; }
.home3-title { font-family: var(--serif); font-weight: 460; font-optical-sizing: auto;
  font-size: clamp(44px, 6vw, 84px); line-height: 1.0; letter-spacing: -0.024em;
  color: var(--ink4); margin: 0 0 26px; max-width: 14em; }
.home3-title em { font-style: italic; font-weight: 420; }
.home3-lead { font-size: 18px; line-height: 1.62; color: var(--ink4-2);
  max-width: 42em; margin: 0 0 30px; }
.home3-lead b { color: var(--hl-ink); font-weight: 500; }
.home3-signoff { color: var(--ink4-3); font-style: italic; }
/* Hero CTAs sit left with the lede (the MS .cta-row centres them). */
.home3 .cta-row { justify-content: flex-start; }
.home3-ctas { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }

/* Step columns: MS cards + circles retired -> ruled ledger columns with
   ghost mono numerals (the sys3-col pattern). The MS .step-circle is
   position:absolute at top:-28px (riding the container's top edge) - it
   must go static or the ledger rule strikes through the numerals. */
.home3 .steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0;
  margin: 56px 0 0; padding: 0; border-top: 2px solid var(--line4-2); }
.home3 .steps::before { display: none; }
.home3 .step { display: flex; flex-direction: column; align-items: flex-start;
  position: relative; text-align: left; background: none; border: 0;
  border-radius: 0; box-shadow: none;
  padding: 20px 28px 24px; border-left: 1px solid var(--line4);
  text-decoration: none; transition: background .14s ease; }
.home3 .step:first-child { border-left: 0; padding-left: 0; }
.home3 .step:hover { background: rgba(255,255,255,0.02); transform: none;
  border-color: var(--line4); box-shadow: none; }
.home3 .step-circle { position: static; left: auto; top: auto; transform: none;
  width: auto; height: auto; background: none; border: 0;
  box-shadow: none; border-radius: 0; font: 500 44px/1 var(--mono4);
  letter-spacing: -0.02em; color: var(--ghost4); margin-bottom: 16px; }
.home3 .step:hover .step-circle { border: 0; transform: none; }
.home3 .step-kicker { font-family: var(--mono4); font-size: 11px; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--hl-ink);
  margin-top: 0; margin-bottom: 8px; }
.home3 .step-title { font-size: 19px; font-weight: 700; color: var(--ink4);
  letter-spacing: 0; margin-bottom: 8px; }
.home3 .step-desc { font-size: 14px; line-height: 1.6; color: var(--ink4-2);
  margin-bottom: 14px; }
.home3 .step-cta { font-family: var(--mono4); font-size: 12px; color: var(--hl-ink);
  margin-top: auto; border-top: 0; padding-top: 0; justify-content: flex-start; }
/* The MS .step:hover .step-cta rule flashes blue-hi - out-specify it. */
.home3 .step:hover .step-cta { color: var(--hl-ink); }
.home3 .step.is-done .step-circle { color: color-mix(in srgb, var(--hl) 45%, transparent); }
.home3 .step.is-done .step-desc { color: var(--ink4-3); }
.home3 .step.is-done .step-cta,
.home3 .step.is-done:hover .step-cta { color: var(--ink4-3); }
/* Done tick: was riding the card's top edge (top:-14px + a bg halo) -
   sit it quietly inside the cell's top-right corner instead. */
.home3 .step.is-done::after { top: 22px; right: 16px;
  box-shadow: none; background-color: var(--card4); }
.home3 .step.is-done:first-child::after { right: 28px; }

/* Toolkit + share section headers: serif title over a lead line. */
.howw-head { max-width: 640px; margin: 0 0 30px; text-align: left; }
.howw-title { font-family: var(--serif); font-weight: 480;
  font-size: clamp(28px, 3.4vw, 44px); line-height: 1.04; letter-spacing: -0.02em;
  color: var(--ink4); margin: 0 0 12px; }
.howw-lead { font-size: 16px; line-height: 1.6; color: var(--ink4-2); margin: 0; }

/* "Your toolkit" launchpad ledger: heavy opener, hairline rows, each row a
   live link into the app (naked chartreuse glyph + name + one-liner + go). */
.tkit { padding: 88px 0 8px; }
.tkit-rows { border-top: 2px solid var(--line4-2); }
.tkit-row { display: grid; grid-template-columns: 40px 1fr auto; gap: 0 16px;
  align-items: center; padding: 18px 10px 18px 0;
  border-bottom: 1px solid var(--line4); text-decoration: none;
  transition: background .15s ease; }
.tkit-row:hover { background: rgba(255,255,255,0.02); }
.tkit-ic { color: var(--hl-ink); display: grid; place-items: center; }
.tkit-ic svg { width: 21px; height: 21px; display: block; }
.tkit-name { display: block; font-size: 16px; font-weight: 700;
  color: var(--ink4); letter-spacing: -0.005em; margin-bottom: 3px; }
.tkit-desc { display: block; font-size: 14px; line-height: 1.55;
  color: var(--ink4-2); max-width: 640px; }
.tkit-go { font-family: var(--mono4); font-size: 12px; font-weight: 600;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--hl-ink);
  white-space: nowrap; transition: transform .15s ease; }
.tkit-row:hover .tkit-go { transform: translateX(3px); }
@media (prefers-reduced-motion: reduce) {
  .tkit-row, .tkit-go { transition: none; }
  .tkit-row:hover .tkit-go { transform: none; }
}
.home3 .home-share { padding: 88px 0 40px; }
.home3 .home-share-tiles { max-width: 760px; margin: 0; }

@media (max-width: 900px) {
  .home3 .steps { grid-template-columns: 1fr; }
  .home3 .step { border-left: 0; padding: 18px 0;
    border-bottom: 1px solid var(--line4); }
  .home3 .step:last-child { border-bottom: 0; }
  .tkit-row { grid-template-columns: 30px 1fr; }
  .tkit-ic svg { width: 18px; height: 18px; }
  .tkit-go { display: none; }
}

/* Tool cards: the homepage t3 pattern - ruled cells, mono meta. */
.v4-scope .tool-grid { gap: 0 32px; margin: 30px 0; }
.v4-scope .tool-card { background: none; border: 0; border-radius: 0;
  box-shadow: none; padding: 15px 0 12px; border-top: 2px solid var(--line4-2); }
.v4-scope .tool-card:hover { background: none; transform: none; }
.v4-scope .tool-card-category { color: var(--ink4-3); font-family: var(--mono4); }
.v4-scope .tool-card-name { color: var(--ink4); font-weight: 700; }
.v4-scope .tool-card-desc { color: var(--ink4-2); }
.v4-scope .tool-card-link { color: var(--hl-ink); font-family: var(--mono4); }
.v4-scope .tool-card:hover .tool-card-link { color: var(--hl-ink); }

/* ============================================================
   V4 GLOBAL CHROME + MODALS (Phase 4 step 4b, 2026-07-19).
   The SPA body now carries .v4-scope (all views migrated), so
   the body-level overlays inherit the v4 tokens/faces. These
   late-file overrides restyle the auth overlay, search modal,
   feedback widget, boot loader and mobile nav; every JS-hooked
   id/class + state name is untouched.
   ============================================================ */

/* Auth overlay */
.auth-overlay .auth-panel { background: #17191E; border: 1px solid rgba(255,255,255,0.09);
  border-radius: 14px; box-shadow: 0 40px 80px -16px rgba(0,0,0,0.6); }
.auth-overlay .auth-head h2 { font-family: "Newsreader", Georgia, serif; font-weight: 500;
  font-size: 27px; letter-spacing: -0.015em; color: #F2F2F0; }
.auth-overlay .auth-head p { color: #A7AAB3; }
.auth-overlay .auth-field-label { font-family: "Spline Sans Mono", ui-monospace, monospace;
  color: #70747E; }
.auth-overlay .auth-field-input { background: #101114; border: 1px solid rgba(255,255,255,0.22);
  border-radius: 8px; color: #F2F2F0; font-family: "Hanken Grotesk", system-ui, sans-serif; }
.auth-overlay .auth-field-input:focus { border-color: #C6E84A;
  box-shadow: 0 0 0 3px rgba(198,232,74,0.15); }
.auth-overlay .auth-submit { background: #C6E84A; color: #14160A; border: 0;
  border-radius: 99px; font-weight: 700; box-shadow: none;
  font-family: "Hanken Grotesk", system-ui, sans-serif;
  transition: transform .15s ease, filter .15s ease; }
.auth-overlay .auth-submit:hover { background: #C6E84A; filter: brightness(1.06);
  transform: translateY(-1px); }
.auth-overlay .auth-google { background: none; border: 1px solid rgba(255,255,255,0.22);
  border-radius: 99px; color: #F2F2F0; font-family: "Hanken Grotesk", system-ui, sans-serif; }
.auth-overlay .auth-google:hover { background: rgba(255,255,255,0.04); border-color: rgba(255,255,255,0.22); }
.auth-overlay .auth-forgot:hover { color: #D3EE6E; }
.auth-overlay .auth-switch a { color: #D3EE6E; }
.auth-overlay .auth-switch a:hover { color: #D3EE6E; }
.auth-overlay .auth-consent a { color: #A7AAB3; }

/* Search modal */
.search-modal { background: #17191E; border: 1px solid rgba(255,255,255,0.09);
  border-radius: 14px; font-family: "Hanken Grotesk", system-ui, sans-serif; }
.search-bar { border-bottom: 1px solid rgba(255,255,255,0.09); }
.search-bar input { font-family: "Hanken Grotesk", system-ui, sans-serif; color: #F2F2F0; }
.search-bar input:focus-visible { outline: none; }
/* Active/hover result: quiet wash, NO left accent bar (the retired tell). */
.search-result { border-left: 0; }
.search-result:hover, .search-result.is-active { background: rgba(255,255,255,0.05);
  border-left: 0; }
.search-result.is-active, .search-result:focus-visible { border-left: 0; outline: none; }
/* Match highlight: chartreuse text wash instead of the MS blue pill. */
.search-result mark { background: rgba(198,232,74,0.14); color: #D3EE6E; }
.search-result-section { font-family: "Spline Sans Mono", ui-monospace, monospace; }
.search-footer { border-top: 1px solid rgba(255,255,255,0.09); }
.search-signin-cta { background: #C6E84A; color: #14160A; border-radius: 99px;
  font-weight: 700; }

/* Feedback widget */
#feedback-btn { background: #17191E; border: 1px solid rgba(255,255,255,0.09);
  border-radius: 99px; color: #F2F2F0; font-family: "Hanken Grotesk", system-ui, sans-serif; }
#feedback-btn:hover { border-color: rgba(255,255,255,0.22); background: #1C1F25; }
#feedback-btn:focus-visible { outline: 2px solid #C6E84A; }
#feedback-btn svg { color: #D3EE6E; }
.fb-modal-card { background: #17191E; border: 1px solid rgba(255,255,255,0.09);
  border-radius: 14px; }
.fb-btn-primary { background: #C6E84A; border-color: #C6E84A; color: #14160A;
  border-radius: 99px; font-weight: 700; }
.fb-btn-primary:hover { background: #C6E84A; border-color: #C6E84A; filter: brightness(1.06); }
.fb-btn-ghost { border-radius: 99px; }

/* Boot loader */
.boot-loader { background: #101114; }
.boot-loader-brand { font-family: "Hanken Grotesk", system-ui, sans-serif; }
.boot-loader-brand .accent { color: #D3EE6E; }
.boot-loader-fill { background: #C6E84A; }

/* Mobile nav overlay - v4 LEDGER (2026-07-20). Was a plain MS link list
   (rounded hover pills); now full-screen dark with a text brand + close
   head over a hairline, and links as ledger rows (heavy opener rule,
   hairline separators, larger type, chartreuse hover with a nudge).
   Both markup sources (header.html + PUBLIC_TOPBAR) share these classes. */
#mobile-nav-overlay { background: #101114; padding: 16px 22px 40px; }
#mobile-nav-overlay .mobile-nav-head { margin-bottom: 4px; padding: 8px 2px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.09); }
#mobile-nav-overlay .brand span { font-family: "Hanken Grotesk", system-ui, sans-serif;
  font-weight: 700; font-size: 16px; color: #F2F2F0; }
#mobile-nav-overlay .brand .accent { color: #D3EE6E; }
#mobile-nav-overlay .mobile-nav-close { color: #A7AAB3; font-size: 30px; background: none; border: 0; padding: 4px 8px; }
#mobile-nav-overlay .mobile-nav-section { margin: 0; border-top: 2px solid rgba(255,255,255,0.22); }
#mobile-nav-overlay .mobile-nav-section a { display: block; padding: 15px 2px; margin: 0; border-radius: 0;
  border-bottom: 1px solid rgba(255,255,255,0.09);
  font-family: "Hanken Grotesk", system-ui, sans-serif; font-weight: 600; font-size: 18px;
  letter-spacing: -0.01em; color: #F2F2F0; transition: color .14s ease, padding-left .14s ease; }
#mobile-nav-overlay .mobile-nav-section a:hover { background: none; color: #D3EE6E; padding-left: 8px; }

/* The nav fast-path progress bar (AUTH_AWARE creates it on static pages) */
.nav-progress { background: #C6E84A; }

/* ============================================================
   OLD-BRAND-BLUE SWEEP (2026-07-20). The v4 token remap above
   flips every var(--accent/--blue-*) reference to chartreuse;
   these close out the LITERAL blues + MS glow atmospherics
   still matching live markup.
   ============================================================ */
/* The MS fixed page glows: gone (v4 is flat dark, no atmosphere). */
body.v4-scope::before { display: none; }
.v4-scope .group::before { display: none; }
/* Progress fills are ACTS -> chartreuse (they read as old-brand blue on
   blue-group rows; verdict pills + icons keep their semantics). */
.v4-scope .bsr-fill { background: var(--hl); }
.v4-scope .section-row-state .section-checklist-mini-fill { background: var(--hl); }
/* Literal-blue leftovers on live components */
.v4-scope .hc-na-btn.is-selected { background: rgba(198,232,74,0.08); }
.v4-scope .mp-derived-chip { color: var(--hl-ink);
  border-color: color-mix(in srgb, var(--hl) 40%, transparent); }
/* --accent remaps to chartreuse in v4 scope - text ON it must be --on-hl, never white */
.v4-scope .mp-use-btn { background: var(--hl); color: var(--on-hl); }
.v4-scope .mp-use-btn:focus-visible { outline-color: var(--hl); }
.v4-scope .mp-soon-tag { border-color: color-mix(in srgb, var(--hl) 35%, transparent); }
.bm-compare-cta { background: rgba(198,232,74,0.06);
  border-color: rgba(255,255,255,0.15); }
.nav-new-tag { color: #D3EE6E; border-color: rgba(198,232,74,0.4); }

/* WHITE-ON-CHARTREUSE fixes: the accent remap turned every
   `background: var(--accent); color: #fff` pair into white text on
   chartreuse. Text ON chartreuse is ALWAYS near-black (--on-hl). */
.v4-scope .hc-cta-btn, .v4-scope .btn-primary,
.v4-scope .hc-results-actions .btn-primary,
.v4-scope .pc-submit, .skip-link {
  color: #14160A; box-shadow: none; border: 0; border-radius: 99px; font-weight: 700; }
.v4-scope .hc-cta-btn:hover, .v4-scope .btn-primary:hover,
.v4-scope .pc-submit:hover { background: var(--hl); filter: brightness(1.06); }
.v4-scope .checklist-items li.done .checklist-check::after { border-color: #14160A; }

/* ============================================================
   V4 PERSONA GATE (profile-complete.html, 2026-07-20).
   #view-profile-complete inherits .v4-scope from <body>, so tokens
   + fonts already resolve; this is the LAYOUT + literal-hex pass:
   left-aligned serif hero, naked chartreuse kicker (was an amber
   pulsing pill - amber is a verdict colour, wrong for the brand
   act), clean v4 selectable persona cards, and CHARTREUSE focus
   rings (were literal MS-blue rgba(0,120,212) that bypass the token
   remap). Every pc-* / persona-card id + class is a JS hook - kept.
   ============================================================ */
.v4-scope .profile-hero { text-align: left; }
.v4-scope .profile-hero-title, .v4-scope .profile-hero h1 {
  font-family: var(--serif); font-weight: 460; font-optical-sizing: auto;
  font-size: clamp(36px, 4.8vw, 56px); letter-spacing: -0.024em; line-height: 1.0; color: var(--ink4); }
.v4-scope .profile-hero-body, .v4-scope .profile-hero p {
  color: var(--ink4-2); max-width: 640px; margin: 0; font-size: 17px; line-height: 1.6; }
/* Naked chartreuse kicker (was an amber pulsing surface pill). */
.v4-scope .profile-eyebrow-pill { background: none; border: 0; padding: 0;
  margin: 0 0 var(--s-4); color: var(--hl-ink); }
.v4-scope .profile-eyebrow-dot { background: var(--hl); box-shadow: none; animation: none; }
/* Section heads, per-persona headings, divider -> v4 rule-labels. */
.v4-scope .profile-section-num, .v4-scope .pc-divider span { color: var(--hl-ink); font-family: var(--mono4); }
.v4-scope .profile-section-title { color: var(--ink4); }
.v4-scope .profile-section-head, .v4-scope .pc-fields-heading, .v4-scope .pc-divider { border-color: var(--line4); }
.v4-scope .pc-fields-heading, .v4-scope .pc-label { color: var(--ink4); }
.v4-scope .pc-hint, .v4-scope .pc-char-count { color: var(--ink4-3); font-family: var(--mono4); }
/* Persona cards - product-UI selectable, v4 (chartreuse select, no glow). */
.v4-scope .persona-card { background: var(--card4); border: 1px solid var(--line4);
  border-radius: 12px; box-shadow: none; }
.v4-scope .persona-card:hover { border-color: var(--line4-2); transform: none; background: var(--card4-2); }
.v4-scope .persona-card.is-selected { border-color: var(--hl);
  background: linear-gradient(160deg, var(--hl-glow), transparent 60%), var(--card4);
  box-shadow: 0 0 0 1px var(--hl) inset; }
.v4-scope .persona-card-label { color: var(--ink4-3); font-family: var(--mono4); }
.v4-scope .persona-card.is-selected .persona-card-label { color: var(--hl-ink); }
.v4-scope .persona-card-title { color: var(--ink4); }
.v4-scope .persona-card-desc { color: var(--ink4-2); }
/* Form controls - v4 inks + CHARTREUSE focus ring (was literal MS blue). */
.v4-scope .pc-input, .v4-scope .pc-select, .v4-scope .pc-textarea {
  background: var(--bg4); border: 1px solid var(--line4-2); color: var(--ink4); }
.v4-scope .pc-input:focus, .v4-scope .pc-select:focus, .v4-scope .pc-textarea:focus {
  border-color: var(--hl); box-shadow: 0 0 0 3px rgba(198,232,74,0.18); outline: none; }
.v4-scope .pc-input::placeholder, .v4-scope .pc-textarea::placeholder { color: var(--ink4-3); }
.v4-scope .pc-select option { background: var(--card4); color: var(--ink4); }
.v4-scope .pc-checkbox-opt { background: var(--card4); border-color: var(--line4); color: var(--ink4-2); }
.v4-scope .pc-checkbox-opt:hover { border-color: var(--line4-2); }
.v4-scope .pc-checkbox-opt:has(input:checked) { border-color: var(--hl);
  background: rgba(198,232,74,0.09); color: var(--ink4); }
.v4-scope .pc-consent a, .v4-scope .pc-signout a { color: var(--hl-ink); }
.v4-scope .pc-signout a:hover { color: var(--hl-ink); }
.v4-scope .pc-error:not(:empty) { color: var(--err4); }

/* Founder's Principle kicker: the MS group-tint rule
   (.chapter[data-group] .principle-kicker) out-specifies the band's own
   ink - on chartreuse the kicker is ALWAYS dark olive ink, never the
   section colour. */
.v4-scope .principle .principle-kicker {
  color: color-mix(in srgb, #14160A 60%, transparent); }

/* Aside Navigate cells: the MS .aside-nav a sets flex-direction column,
   which stacked the chip above centred text - force proper rows. */
.v4-scope .aside-nav a { flex-direction: row; }
.v4-scope .aside-nav .section-nav-text { align-items: flex-start; text-align: left; }

/* Dashboard nav link: signed-in only (both bars carry it; the SPA
   _NAV_INAPP delegate + AUTH_AWARE fast-path handle routing). */
.nav-dashboard-link { display: none; }
.is-authed .nav-dashboard-link { display: inline-flex; }

/* Account menu button (fnav): the base :hover uses var(--accent) = MS blue
   (the v4 scope defines --hl, not --accent), so the border flashed blue on
   hover. Chartreuse-tint it and quiet the resting box. */
.v4-scope .auth-user-name { background: none; border: 1px solid rgba(255,255,255,0.09);
  color: #F2F2F0; font-family: "Hanken Grotesk", system-ui, sans-serif; }
.v4-scope .auth-user-name:hover { background: rgba(255,255,255,0.04);
  border-color: color-mix(in srgb, #C6E84A 45%, transparent); }
.v4-scope .auth-user-name::after { color: #70747E; }
.v4-scope .auth-dropdown { background: #17191E; border: 1px solid rgba(255,255,255,0.09); }
.v4-scope .auth-dropdown a { color: #A7AAB3; }
.v4-scope .auth-dropdown a:hover { background: rgba(255,255,255,0.04); color: #F2F2F0; }

/* Category-hub .section-card grids: glow washes retired, quiet card4
   cells (used on the 8 category hub pages; the tinted icon + group
   colour on the badge carry identity). */
.v4-scope .section-card { background: var(--card4); border: 1px solid var(--line4);
  box-shadow: none; }
.v4-scope .section-card:hover { background: var(--card4-2); border-color: var(--line4-2);
  transform: none; box-shadow: none; }

/* ============================================================
   V4 REVIEW FIXES (Rob, 2026-07-20).
   ============================================================ */

/* (1) Chrome links are NEUTRAL. The content classless-link chartreuse rule
   (.v4-scope a:not([class]), 0,2,1) was bleeding onto the classless nav +
   footer links (Contents/Health Check green, Dashboard/Tools not - because
   Dashboard carries a class). These win at (0,3,1). */
.v4-scope .fnav-links a:not([class]) { color: var(--ink4-2); }
.v4-scope .fnav-links a:not([class]):hover { color: var(--ink4); background: rgba(255,255,255,0.06); }
.v4-scope .fnav-menu a:not([class]) { color: var(--ink4-2); }
.v4-scope .dtc-footer-nav a:not([class]) { color: var(--ink4-3); }
.v4-scope .dtc-footer-nav a:not([class]):hover { color: var(--ink4); }

/* (9) Signed-in home was 1280px (.container) - too wide. Tighten to an
   editorial measure; the anon homepage stays on its own .wrap3. */
.container.home3 { max-width: 1080px; }

/* (10) Tools + Calculators hub cards: the crowded boxed glow surface
   (.seo-feature, used ONLY by those two hubs) -> boxless ledger cells,
   matching the benchmarks hub they sit beside. */
.v4-scope .seo-feature { background: none; border: 0; border-radius: 0; box-shadow: none;
  border-top: 2px solid var(--line4-2); padding: 20px 0 22px; overflow: visible; }
.v4-scope .seo-feature:hover { transform: none; box-shadow: none; background: none;
  border-color: var(--line4-2); }
.v4-scope .seo-feature strong { font-family: var(--sans); color: var(--ink4); font-size: 17px;
  letter-spacing: -0.015em; }
.v4-scope .seo-feature:hover strong { color: var(--hl-ink); }
.v4-scope .seo-feature span { color: var(--ink4-3); }
/* the hubs render these in .bm-grid; give it column breathing room */
.v4-scope .bm-grid { gap: 0 44px; }

/* (12) Author photo on the home page -> black & white. */
.v4-scope .author3-photo img { filter: grayscale(1); }
