/* The Longevity Review v3 — clinical, spacious, sans-first.
   System font stacks only — no network font requests, no CDNs, no build step. */

:root {
  /* Core surfaces — warm-paper direction (roadmap item 15, Morrow-derived).
     Cool blue-blacks and cool greys retired; --paper-2 promoted to default body. */
  --ink:        #1E1C1B;   /* warm near-black: header + dark sections */
  --ink-2:      #2a2726;   /* raised dark surface */
  --ink-3:      #383433;
  --paper:      #fefdfb;   /* near-white, faint warm cast */
  --paper-2:    #f5f3ef;   /* warm off-white — now the default body surface */
  --paper-3:    #ebe8e2;

  /* Decorative-only editorial tones (Morrow's muted set). Fill/background/
     border use ONLY — never as text (contrast), never near a grade badge,
     never where they could read as evidence data. */
  --rose:  #9E777C;
  --sage:  #C9D7D3;
  --peach: #F2BD99;
  --mauve: #B376AB;

  /* Accent — cool cyan. Never used for body text on white. */
  --accent:      #6fd3ef;
  --accent-mid:  #2ba6cd;
  --accent-deep: #0d7695;  /* AA contrast on white */
  --accent-wash: #eaf7fc;

  --text:        #221f1d;
  --text-dim:    #6b645f;
  --on-dark:     #f2f6f8;
  --on-dark-dim: #a8b6c0;

  --border:      #e5e2dc;
  --border-dark: rgba(255,255,255,0.14);
  --focus:       #0d7695;

  /* Evidence grades — legible on light and dark */
  --strong:   #1a7f42;  --strong-bg:   #e8f7ee;  --strong-on:   #7ee0a4;
  --moderate: #2563c9;  --moderate-bg: #e9f0fd;  --moderate-on: #8ab8f5;
  --weak:     #9c5708;  --weak-bg:     #fdf2e5;  --weak-on:     #f0b46a;
  --emerging: #7028d0;  --emerging-bg: #f3ecfd;  --emerging-on: #c39cf5;

  --sans:  "Segoe UI Variable Display", "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  --serif: "Fraunces", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --mono:  "IBM Plex Mono", ui-monospace, "Cascadia Mono", "Segoe UI Mono", Consolas, monospace;

  --maxw:      1200px;
  --maxw-text: 720px;

  --space-1: 4px;   --space-2: 8px;   --space-3: 12px;  --space-4: 16px;
  --space-5: 24px;  --space-6: 32px;  --space-7: 48px;  --space-8: 72px;
  --space-9: 112px;

  --radius-sm:   6px;
  --radius-md:   12px;
  --radius-lg:   20px;
  --radius-xl:   28px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(11,15,18,0.05);
  --shadow-md: 0 8px 30px rgba(11,15,18,0.09);
  --shadow-lg: 0 24px 70px rgba(11,15,18,0.16);
}

* { box-sizing: border-box; }

/* ============================================================
   Self-hosted fonts (roadmap item 16) — Fraunces variable serif
   (display headings, one file covers 400/500/600) + IBM Plex Mono
   (data/labels). Both subsetted to latin; font-display: swap.
   ============================================================ */
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('../fonts/fraunces.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/plexmono-400.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/plexmono-500.woff2') format('woff2');
}

/* The mobile nav panel parks off-canvas to the right; without this it widens
   the document and clips every page on small screens. */
html { scroll-behavior: smooth; overflow-x: hidden; }
body { overflow-x: hidden; }

body {
  margin: 0;
  font-family: var(--sans);
  color: var(--text);
  background: var(--paper-2);
  line-height: 1.6;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent-deep); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
img, svg { max-width: 100%; }

/* Headings: large, light, tight tracking — deliberately not bold serif. */
h1, h2, h3, h4 {
  font-family: var(--sans);
  font-weight: 500;
  letter-spacing: -0.025em;
  line-height: 1.1;
  color: var(--text);
  margin: 0 0 var(--space-4);
}
h1 { font-size: clamp(2.6rem, 5.4vw, 4.1rem); font-weight: 400; }
h2 { font-size: clamp(1.9rem, 3.2vw, 2.75rem); font-weight: 400; }
h3 { font-size: clamp(1.15rem, 1.6vw, 1.4rem); font-weight: 600; letter-spacing: -0.015em; }
h4 { font-size: 1.02rem; font-weight: 600; letter-spacing: 0; }

/* The only serif on the site: an italic emphasis phrase inside a headline. */
h1 em, h2 em, .accent-em {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.01em;
}
h1 em, h2 em { color: var(--accent-mid); }
.hero h1 em, .band-dark h1 em, .band-dark h2 em { color: var(--accent); }

p { margin: 0 0 var(--space-4); }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--space-5); }

a:focus-visible, button:focus-visible, .nav-toggle:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 3px;
}
.site-header a:focus-visible, .hero a:focus-visible,
.band-dark a:focus-visible, .site-footer a:focus-visible { outline-color: var(--accent); }

.skip-link {
  position: absolute; left: -999px; top: auto;
  width: 1px; height: 1px; overflow: hidden; z-index: 1000;
}
.skip-link:focus {
  left: 12px; top: 12px; width: auto; height: auto;
  background: var(--ink); color: #fff;
  padding: 10px 18px; border-radius: var(--radius-pill);
  font-size: 0.9rem; font-weight: 600; text-decoration: none;
  box-shadow: var(--shadow-md);
}

/* ============ Announcement ribbon ============ */
.advice-ribbon {
  background: var(--accent);
  color: #06232e;
  text-align: center;
  font-size: 0.83rem;
  font-weight: 500;
  padding: 9px var(--space-5);
}
.advice-ribbon a {
  color: #06232e; font-weight: 600;
  text-decoration: underline; text-underline-offset: 2px;
}

/* ============ Header ============ */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(11,15,18,0.88);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: background .25s ease, border-color .25s ease;
}
.site-header.scrolled { background: rgba(11,15,18,0.97); border-bottom-color: var(--border-dark); }
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--space-5); min-height: 68px;
}
.brand {
  display: inline-flex; align-items: baseline; gap: 10px;
  color: #fff; font-size: 1.06rem; font-weight: 600;
  letter-spacing: -0.02em; white-space: nowrap;
}
.brand:hover { text-decoration: none; opacity: .85; }
.brand .tag {
  font-size: 0.66rem; font-weight: 500; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--accent);
}
.main-nav { display: flex; align-items: center; gap: 2px; }
.main-nav a {
  color: var(--on-dark-dim);
  font-size: 0.9rem; font-weight: 500;
  padding: 8px 13px; border-radius: var(--radius-pill);
  transition: color .18s ease, background .18s ease;
}
.main-nav a:hover { color: #fff; background: rgba(255,255,255,0.09); text-decoration: none; }
.main-nav a.active { color: #fff; background: rgba(255,255,255,0.14); }
.main-nav a.nav-cta {
  color: var(--ink); background: #fff; font-weight: 600; margin-left: 8px;
}
.main-nav a.nav-cta:hover { background: var(--accent); color: var(--ink); }

/* Dropdown menus — CSS only, opened on hover and on keyboard focus. */
.nav-item { position: relative; display: flex; align-items: center; }
.nav-item > a .caret {
  display: inline-block; width: 0; height: 0; margin-left: 7px;
  border-left: 4px solid transparent; border-right: 4px solid transparent;
  border-top: 4px solid currentColor; opacity: .55; vertical-align: middle;
  font-size: 0; line-height: 0;
}
.nav-menu {
  position: absolute; top: calc(100% + 10px); left: -8px;
  min-width: 270px;
  background: var(--ink-2);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: var(--space-2);
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity .18s ease, transform .18s ease, visibility .18s;
}
.nav-item:hover > .nav-menu,
.nav-item:focus-within > .nav-menu { opacity: 1; visibility: visible; transform: none; }
.nav-menu a {
  display: block; padding: 9px 13px; border-radius: var(--radius-sm);
  color: var(--on-dark); font-size: 0.9rem; font-weight: 500;
}
.nav-menu a em {
  display: block; font-style: normal;
  font-size: 0.72rem; font-weight: 500; color: var(--on-dark-dim); margin-top: 2px;
}
.nav-menu a:hover { background: rgba(255,255,255,0.09); color: #fff; text-decoration: none; }
.nav-menu-all {
  border-top: 1px solid var(--border-dark);
  margin-top: var(--space-2); padding-top: 12px !important;
  border-radius: 0 !important; color: var(--accent) !important; font-weight: 600 !important;
}
.nav-menu-group {
  display: block; padding: 10px 13px 4px;
  font-size: 0.64rem; font-weight: 700; letter-spacing: 0.14em;
  text-transform: uppercase; color: #6f7d87;
}
.nav-close { display: none; }

/* Inner pages carry their own vertical rhythm; the homepage supplies its own bands. */
main#main:not(.banded) { display: block; padding: var(--space-8) 0 var(--space-9); }
main#main:not(.banded) > .wrap > h1 { max-width: 18ch; }
main#main:not(.banded) > .wrap > h1 + .section-intro { max-width: 68ch; font-size: 1.08rem; margin-bottom: var(--space-7); }
.nav-toggle {
  display: none;
  background: transparent; border: 1px solid var(--border-dark);
  color: #fff; font-family: inherit; font-size: 0.85rem; font-weight: 600;
  padding: 8px 15px; border-radius: var(--radius-pill); cursor: pointer;
}

/* ============ Hero — inset rounded card ============ */
.hero {
  position: relative;
  margin: var(--space-3);
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: var(--ink);   /* image + scrim live on ::before / ::after */
  color: var(--on-dark);
  display: flex;
  align-items: flex-end;
  /* Height follows the content (no min-height) so the thesis line below
     lands in the same fold as the question: ROADMAP decision 9 measured
     172px of empty space between them (2026-10-03). */
  padding: var(--space-7) 0 var(--space-7);
}
/* The stock watch-movement video was removed 2026-10-03 (ROADMAP decision 9:
   drop the luxury-watch execution; imagery must be brand-owned). The hero is
   the CSS-only wash defined under "Landing-page motion" below. */
.hero .wrap { position: relative; z-index: 1; }
.hero-lede { max-width: 940px; }
.hero .eyebrow { color: var(--accent); }
/* Item 11: the H1 is a short audience-defining imperative; the evidence
   verdict lives further down the page as an isolated thesis beat. */
.hero-h1 {
  font-size: clamp(2.8rem, 6vw, 4.6rem);
  font-weight: 500;
  line-height: 1.02;
  letter-spacing: -0.035em;
  color: #fff;
  max-width: 16ch;
  margin: 0 0 var(--space-5);
}
.hero-claim {
  font-size: clamp(2.5rem, 5.6vw, 4.2rem);
  font-weight: 400;
  line-height: 1.04;
  letter-spacing: -0.032em;
  color: #fff;
  max-width: 22ch;
  margin: 0 0 var(--space-5);
}
.hero-claim b { font-weight: 400; color: var(--accent); }
.hero-claim em {
  font-family: var(--serif); font-style: italic; font-weight: 400; color: var(--accent);
}
.hero-sub {
  font-size: clamp(1.02rem, 1.4vw, 1.16rem);
  line-height: 1.6;
  color: var(--on-dark-dim);
  max-width: 82ch;  /* two lines on desktop (decision 9) */
  text-wrap: balance;
  margin: 0 0 var(--space-6);
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }

/* Hero stat strip, mirroring the reference's bottom-of-hero data row */
.hero-stats {
  display: flex; flex-wrap: wrap; gap: var(--space-7);
  margin-top: var(--space-7);
  padding-top: var(--space-5);
  border-top: 1px solid rgba(255,255,255,0.18);
}
.hero-stat { min-width: 130px; }
.hero-stat b {
  display: block; font-family: var(--serif); font-size: 1.5rem; font-weight: 500;
  letter-spacing: -0.02em; color: #fff; line-height: 1.15;
}
.hero-stat span {
  display: block; font-family: var(--mono); font-size: 0.76rem; font-weight: 500;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--on-dark-dim);
  margin-top: 4px;
}

/* ============ Buttons — squared (de-AI: sharp corners over template pills) ============ */
.btn, .btn-solid, .btn-outline, .btn-primary, .btn-ghost {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: inherit; font-size: 0.94rem; font-weight: 600;
  padding: 13px 26px; border-radius: var(--radius-sm);
  border: 1px solid transparent; cursor: pointer;
  transition: background .18s ease, border-color .18s ease, color .18s ease,
              box-shadow .18s ease, transform .18s ease;
  white-space: nowrap;
}
.btn:hover, .btn-solid:hover, .btn-outline:hover,
.btn-primary:hover, .btn-ghost:hover { text-decoration: none; }
.btn:active, .btn-solid:active, .btn-primary:active { transform: none; }

/* Default (on dark) */
.btn-solid, .btn-primary {
  background: #fff; color: var(--ink); border-color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-solid:hover, .btn-primary:hover {
  background: var(--accent); border-color: var(--accent); color: var(--ink);
  box-shadow: var(--shadow-md); transform: translateY(-1px);
}
.btn-outline, .btn-ghost {
  background: rgba(255,255,255,0.07); color: var(--on-dark); border-color: rgba(255,255,255,0.28);
}
.btn-outline:hover, .btn-ghost:hover {
  background: rgba(255,255,255,0.16); border-color: rgba(255,255,255,0.5); color: #fff;
}

/* On light bands */
.band-white .btn-solid, .band-light .btn-solid, .btn-dark {
  background: var(--ink); color: #fff; border-color: var(--ink);
  box-shadow: var(--shadow-sm);
}
.band-white .btn-solid:hover, .band-light .btn-solid:hover, .btn-dark:hover {
  background: var(--accent-deep); border-color: var(--accent-deep); color: #fff;
  box-shadow: var(--shadow-md); transform: translateY(-1px);
}
.band-white .btn-outline, .band-light .btn-outline {
  background: transparent; color: var(--text); border-color: var(--border);
}
.band-white .btn-outline:hover, .band-light .btn-outline:hover {
  background: var(--paper-2); border-color: var(--text); color: var(--text);
}
.btn.compact { padding: 9px 18px; font-size: 0.86rem; }

/* ============ Bands / sections ============ */
.band { padding: var(--space-9) 0; }
.band-white { background: var(--paper); }
.band-light { background: var(--paper-2); }
.band-dark  { background: var(--ink); color: var(--on-dark); }
.band-dark h1, .band-dark h2, .band-dark h3, .band-dark h4 { color: #fff; }
.band-dark p { color: var(--on-dark-dim); }
.band-dark a { color: var(--accent); }
.band-dark .eyebrow { color: var(--accent); }

.eyebrow {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--accent-deep);
  margin: 0 0 var(--space-4);
}
.eyebrow.dark { color: var(--accent-deep); }

.section-head {
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: var(--space-6) var(--space-8);
  align-items: end;
  margin-bottom: var(--space-8);
}
.section-head h2 { margin: 0; }
.section-intro {
  font-size: 1.05rem; line-height: 1.65; color: var(--text-dim); margin: 0;
}
.band-dark .section-intro { color: var(--on-dark-dim); }

/* ============ Evidence chart ============ */
.evidence-chart { margin: 0; }
.ec-rows { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-4); }
.ec-row {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr) auto;
  align-items: center; gap: var(--space-5);
}
.ec-label {
  font-size: 0.74rem; font-weight: 600; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--text-dim);
}
.ec-track {
  position: relative; height: 12px; border-radius: var(--radius-pill);
  background: var(--paper-3); overflow: hidden;
}
.ec-bar {
  display: block; height: 100%; width: var(--w); border-radius: var(--radius-pill);
  transform: scaleX(0); transform-origin: left center;
  transition: transform 1.1s cubic-bezier(.22,.9,.3,1);
}
/* Bars grow from zero once the chart scrolls into view. Without a .js-reveal
   ancestor (JS failed / not run) they render full-width immediately. Grown
   with transform, not width, so the reveal never triggers layout. */
.reveal.in .ec-bar, .no-anim .ec-bar { transform: none; }
html:not(.js-reveal) .ec-bar { transform: none; }
.ec-strong   { background: var(--strong); }
.ec-moderate { background: var(--moderate); }
.ec-weak     { background: var(--weak); }
.ec-emerging { background: var(--emerging); }
.ec-val { font-size: 0.9rem; color: var(--text-dim); white-space: nowrap; }
.ec-val b { color: var(--text); font-weight: 600; font-size: 1.05rem; margin-right: 4px; }
.ec-foot { margin: var(--space-6) 0 0; font-size: 0.9rem; color: var(--text-dim); }

/* ============ Test cards ============ */
.test-card {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-6) var(--space-7);
  margin: 0 0 var(--space-5);
  scroll-margin-top: 96px;
  box-shadow: var(--shadow-sm); /* Resting Lift Rule: never perfectly flat at rest */
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.test-card:hover { border-color: var(--border); box-shadow: var(--shadow-md); }
.test-card-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: var(--space-5); margin-bottom: var(--space-4);
}
.test-card-head h3 { margin: 0; }
.test-card p { margin: 0 0 var(--space-4); }
.test-card p:last-child { margin-bottom: 0; }

/* Grade tags — squared, color + text always paired (roadmap §4) */
.grade {
  flex: none;
  display: inline-block;
  font-size: 0.68rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  padding: 5px 13px; border-radius: var(--radius-sm);
  border: 1px solid transparent; white-space: nowrap;
}
.grade-strong   { background: var(--strong-bg);   color: var(--strong);   border-color: #bde9cd; }
.grade-moderate { background: var(--moderate-bg); color: var(--moderate); border-color: #c3d8f8; }
.grade-weak     { background: var(--weak-bg);     color: var(--weak);     border-color: #f2d5ae; }
.grade-emerging { background: var(--emerging-bg); color: var(--emerging); border-color: #dcc8f7; }

/* Metadata strip at the foot of each card */
.test-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: var(--space-5);
  margin-top: var(--space-5);
  padding-top: var(--space-5);
  border-top: 1px solid var(--border);
}
.test-meta > div > .label { margin-bottom: 6px; }
.label {
  display: block;
  font-family: var(--mono);
  font-size: 0.68rem; font-weight: 500;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--text-dim);
}
.small { font-size: 0.93rem; line-height: 1.55; color: var(--text); }

/* Evidence panel — carries the citation and explains the grade */
.evidence {
  background: var(--paper-2);
  border-radius: var(--radius-md);
  padding: var(--space-5);
  margin: var(--space-5) 0 0;
}
.evidence p { margin: 0; font-size: 0.95rem; line-height: 1.62; }
.evidence-label {
  display: block;
  font-size: 0.68rem; font-weight: 700;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--text-dim); margin-bottom: var(--space-3);
}
.citation {
  font-size: 0.86rem; line-height: 1.55; color: var(--text-dim);
  border-left: 2px solid var(--accent);
  padding: 2px 0 2px var(--space-4);
  margin: var(--space-4) 0 0;
}
.citation a { font-weight: 500; }

/* ============ Callouts ============ */
.callout {
  background: var(--accent-wash);
  border: 1px solid #cdeaf5;
  border-radius: var(--radius-md);
  padding: var(--space-5) var(--space-6);
  margin: var(--space-6) 0;
}
.callout > :last-child { margin-bottom: 0; }
.callout.warn { background: var(--weak-bg); border-color: #f2d5ae; }
/* The quiet sibling of .callout: an editorial caveat, not a status. It used
   to carry a 3px accent left-tab, which was decoration doing no work — the
   caution is in the words. Separation now comes from tone, the same way
   .callout gets it from a tint rather than a stripe (2026-08-27). */
.flag-box {
  background: var(--paper-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: var(--space-5) var(--space-6);
  margin: var(--space-6) 0;
}
.flag-box > :last-child { margin-bottom: 0; }

/* Singapore guidance (STRC 2026 Vol 1) on each test page. Neutral tokens
   only: the grade colours mean evidence strength, and a national
   recommendation is a different axis (2026-10-03). */
.sg-guidance {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-5) var(--space-6);
  margin: var(--space-6) 0;
}
.sg-guidance > .label { margin: 0 0 var(--space-3); }
.sg-guidance p { font-size: 0.95rem; line-height: 1.62; margin: 0 0 var(--space-3); }
.sg-guidance > :last-child { margin-bottom: 0; }
.sg-status {
  font-weight: 600;
  color: var(--text);
}
.sg-split {
  list-style: none;
  margin: 0 0 var(--space-3);
  padding: 0;
  font-weight: 600;
  color: var(--text);
}
.sg-split li + li { margin-top: var(--space-2); }
.sg-use {
  font-family: var(--mono);
  font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-dim);
  margin-right: var(--space-2);
}
.sg-guidance .sg-source {
  font-size: 0.86rem; line-height: 1.55;
  color: var(--text-dim);
  padding-top: var(--space-3);
  border-top: 1px solid var(--border);
}
.statement-band {
  background: var(--ink); color: var(--on-dark);
  border-radius: var(--radius-lg);
  padding: var(--space-8) var(--space-7);
  margin: var(--space-8) 0;
}
.statement-band h2, .statement-band h3 { color: #fff; }
.statement-note { font-size: 0.92rem; color: var(--on-dark-dim); margin: var(--space-4) 0 0; }

/* ============ Authority band (item 12) ============ */
/* The honest substitute for "physician-led": authority from what a reader
   can verify — rubric, citation index, corrections process. */
.authority-promise {
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: #fff;
  margin: 0 0 var(--space-6);
}
.authority-promise b { font-weight: 600; }
.authority-list {
  display: grid;
  gap: 0;
  margin-bottom: var(--space-6);
}
/* Citation-block rows — the site's signature evidence device (2px cyan left
   border) used instead of equal card boxes, per the Morrow-model authority
   band. */
.authority-item {
  border-left: 2px solid var(--accent);
  padding: var(--space-4) 0 var(--space-4) var(--space-5);
  margin-top: var(--space-4);
}
.authority-item h3 {
  color: #fff;
  font-size: 1.02rem;
  letter-spacing: 0.01em;
  margin: 0 0 var(--space-2);
}
.authority-item p { color: var(--on-dark-dim); font-size: 0.94rem; margin: 0; }
.authority-item a { color: var(--accent); }

/* ============ Reading list (item 13) ============ */
/* Editorial page — the one place a decorative tone shows at full strength,
   as the rose count badge below. Decorative tones are fills only, never text.
   The sage/peach left-tabs on .rl-item were dropped 2026-08-27: they restated
   the section the heading already names, and read as a stock accent bar. */
.rl-section { margin: var(--space-8) 0; }
.rl-section h2 {
  display: flex; align-items: baseline; gap: var(--space-3);
  margin: 0 0 var(--space-2);
}
.rl-count {
  font-family: var(--mono);
  font-size: 0.85rem; color: var(--text-dim);
  background: var(--rose); color: #fff;
  border-radius: var(--radius-sm); padding: 2px 10px;
}
.rl-blurb { color: var(--text-dim); max-width: 60ch; margin: 0 0 var(--space-5); }
.rl-list { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-4); }
.rl-item {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-4) var(--space-5);
}
.rl-test { font-weight: 600; }
a.rl-test:hover { color: var(--accent-deep); }
.rl-cite { margin: var(--space-1) 0; font-size: 0.9rem; color: var(--text-dim); }
.rl-pmid { white-space: nowrap; }
.rl-finding { margin: 0; }

/* ============ Suitability quiz (item 8) ============ */
.quiz-q {
  border: 1px solid var(--border);
  background: var(--paper);
  border-radius: var(--radius-md);
  padding: var(--space-5);
  margin: 0 0 var(--space-4);
}
.quiz-q legend { font-weight: 600; padding: 0 var(--space-2); }
.quiz-opt {
  display: flex; align-items: flex-start; gap: 10px;
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  margin-top: var(--space-2); cursor: pointer;
  transition: border-color .14s ease, background .14s ease;
}
.quiz-opt:hover { border-color: var(--accent-mid); }
.quiz-opt input { margin-top: 4px; accent-color: var(--accent-deep); }
.verdict {
  background: var(--ink); color: var(--on-dark);
  border-radius: var(--radius-lg);
  padding: var(--space-7) var(--space-7) var(--space-6);
  margin: var(--space-7) 0;
}
.verdict h2 {
  color: #fff; font-size: clamp(1.4rem, 2.6vw, 1.9rem);
  line-height: 1.25; letter-spacing: -0.02em;
  max-width: 30ch; margin: var(--space-3) 0 var(--space-5);
}
.verdict .eyebrow { color: var(--accent); }
.verdict p { color: var(--on-dark-dim); max-width: 62ch; }
.verdict a { color: var(--accent); }

/* ============ National screening list (singapore-screening.html) ============ */
.sg-list td { vertical-align: top; }
.sg-list td:first-child { font-weight: 600; white-space: nowrap; }
.sg-nograde { font-size: 0.86rem; color: var(--text-dim); }
@media (max-width: 720px) { .sg-list td:first-child { white-space: normal; } }

/* ============ OSTA calculator (osta.html, 2026-10-03) ============ */
/* Neutral throughout: risk bands are not evidence grades, so no grade
   colours. Reuses .quiz-q / .quiz-opt for the sex choice. */
.osta-form { margin: 0 0 var(--space-5); }
.osta-form .quiz-opt { display: inline-flex; margin-right: var(--space-2); }
.osta-fields {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: var(--space-4);
  margin: 0 0 var(--space-5);
}
.osta-field .label { margin-bottom: 6px; }
.osta-field input {
  width: 100%;
  font: inherit; font-size: 1.05rem;
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--paper);
  color: var(--text);
}
.osta-field input:focus-visible { outline: 2px solid var(--accent-deep); outline-offset: 1px; }
.osta-result {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-5) var(--space-6);
  margin: 0 0 var(--space-7);
}
.osta-result p { margin: 0 0 var(--space-3); max-width: 62ch; }
.osta-result > :last-child { margin-bottom: 0; }
.osta-headline { font-family: var(--serif); font-size: 1.35rem; color: var(--text); }
.osta-sum { font-family: var(--mono); font-size: 0.9rem; color: var(--text-dim); }

/* ============ Prose ============ */
.prose { max-width: var(--maxw-text); }
.prose h2 { margin-top: var(--space-8); }
.prose h3 { margin-top: var(--space-7); }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 var(--space-4); }
.prose li { margin-bottom: var(--space-2); }
.last-updated {
  font-size: 0.82rem; color: var(--text-dim);
  margin: 0 0 var(--space-6);
}

/* ============ Tables ============ */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  margin: var(--space-6) 0;
}
.table-wrap table { border-collapse: collapse; width: 100%; min-width: 560px; font-size: 0.93rem; }
.table-wrap th, .table-wrap td {
  padding: 13px var(--space-5); text-align: left;
  border-bottom: 1px solid var(--border); vertical-align: top;
}
.table-wrap th {
  background: var(--paper-2);
  font-size: 0.7rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-dim);
  white-space: nowrap;
}
.table-wrap tr:last-child td { border-bottom: none; }
.table-wrap tbody tr:hover { background: var(--paper-2); }

/* ============ Breadcrumbs ============ */
.breadcrumbs {
  font-size: 0.83rem; color: var(--text-dim);
  margin: 0 0 var(--space-5);
}
.breadcrumbs a { color: var(--text-dim); }
.breadcrumbs a:hover { color: var(--accent-deep); }
.crumb-sep { margin: 0 8px; opacity: .5; }

/* ============ Spotlight rows (homepage) ============ */
.spotlight-list { list-style: none; margin: 0; padding: 0; }
.spotlight-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto 28px;
  align-items: center; gap: var(--space-5);
  padding: var(--space-5) 0;
  border-bottom: 1px solid var(--border);
}
/* Hover nudge via transform on the cells, not padding, so it never reflows. */
.spotlight-row > * { transition: transform .2s ease; }
.spotlight-row:hover { text-decoration: none; }
.spotlight-row:hover > * { transform: translateX(var(--space-3)); }
.spotlight-row:first-child { border-top: 1px solid var(--border); }
.spotlight-title-wrap { min-width: 0; }
.spotlight-title {
  display: block; font-size: 1.12rem; font-weight: 500;
  letter-spacing: -0.015em; color: var(--text);
}
.spotlight-row:hover .spotlight-title { color: var(--accent-deep); }
.spotlight-price { font-size: 0.93rem; color: var(--text-dim); white-space: nowrap; }
.spotlight-arrow { color: var(--text-dim); font-size: 1.1rem; text-align: right; }
.spotlight-row:hover .spotlight-arrow { color: var(--accent-deep); }

/* ============ Tier cards ============ */
.tier-grid {
  display: grid; gap: var(--space-5);
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.tier-card {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
}
.band-light .tier-card { background: var(--paper); }
.tier-card h3 { margin-top: 0; }
.tier-price {
  display: block; font-size: 1.6rem; font-weight: 500;
  letter-spacing: -0.02em; color: var(--text); margin: var(--space-3) 0;
}
/* Homepage tier strip — editorial hairline rows (de-boxed 2026-08-26) */
.tier-mini-grid {
  display: grid; gap: 0;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.tier-mini-card {
  border-top: 1px solid var(--border);
  padding: var(--space-5) var(--space-5) 0 0;
  text-decoration: none;
  color: var(--text);
}
.tier-mini-card:hover { text-decoration: none; }
.tier-mini-card h3 {
  font-family: var(--serif);
  font-size: 1.3rem; font-weight: 500; letter-spacing: -0.015em;
  margin: var(--space-2) 0 var(--space-2);
}
.tier-mini-num {
  font-family: var(--mono);
  font-size: 0.74rem; font-weight: 500; letter-spacing: 0.16em;
  color: var(--text-dim);
}
.tier-mini-price { display: block; font-size: 1.05rem; font-weight: 600; color: var(--text); }
.tier-mini-card p { margin: var(--space-2) 0 0; font-size: 0.9rem; color: var(--text-dim); }
@media (max-width: 720px) {
  .tier-mini-grid { grid-template-columns: 1fr; }
}

/* ============ Page nav (prev/next) ============ */
.page-nav {
  display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-5);
  margin: var(--space-8) 0 0;
  padding-top: var(--space-6);
  border-top: 1px solid var(--border);
}
.page-nav-link {
  display: block;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-5);
  transition: border-color .18s ease, background .18s ease;
}
.page-nav-link:hover { border-color: var(--text); background: var(--paper-2); text-decoration: none; }
.page-nav-link.next { text-align: right; }
.page-nav-label {
  display: block; font-size: 0.68rem; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-dim);
  margin-bottom: 6px;
}
.page-nav-title { display: block; font-size: 1rem; font-weight: 500; color: var(--text); }
.page-nav-link:hover .page-nav-title { color: var(--accent-deep); }

/* ============ Ad slot ============ */
.ad-slot {
  border: 1px dashed var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-7) var(--space-5);
  margin: var(--space-7) 0;
  text-align: center;
  font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: #a9a396;
}

/* ============ Isolated thesis beat (item 11) ============ */
/* The verdict, full-width, alone on a white field — no stats around it. */
.band-thesis { padding-top: var(--space-6); }
/* The journey steps and the chart share one band; without this the chart's
   eyebrow sat flush against the step links above it. */
.journey + section { margin-top: var(--space-9); }
.thesis-beat {
  text-align: center;
  padding: 0 0 var(--space-5);
  border-bottom: 1px solid var(--border);
  margin-bottom: var(--space-6);
}
.thesis-beat .hero-claim { max-width: none; margin: 0; color: var(--text); }
.thesis-beat .hero-claim b { color: var(--accent-deep); }

/* ============ Plan at a Glance strip (item 9, Morrow-style) ============ */
/* Morrow's spec strip is a quiet inline row with middots — not a grid of
   giant numerals. De-numeralled 2026-08-26 (user: layout looked AI). */
.plan-strip { padding: var(--space-5) 0 0; }
.plan-strip-head { margin: 0 0 var(--space-4); }
.plan-spec-row {
  margin: 0;
  font-family: var(--mono);
  font-size: 0.9rem; font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--text);
  padding-top: var(--space-5);
  border-top: 1px solid rgba(158, 119, 124, 0.22); /* warm rose hairline */
}

/* ============ Three-phase journey (item 9) ============ */
/* Editorial columns on hairlines — deliberately NOT rounded cards: the
   filled-box look read as AI-template, user rejected it 2026-08-26. */
.journey { margin-top: var(--space-7); }
.journey-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--space-5) var(--space-7);
}
.journey-phase {
  border-top: 1px solid rgba(158, 119, 124, 0.22); /* warm rose hairline */
  padding: var(--space-5) 0 0;
  display: flex; flex-direction: column; align-items: flex-start;
}
.journey-num {
  font-family: var(--mono);
  font-size: 0.74rem; font-weight: 500;
  letter-spacing: 0.16em;
  color: var(--text-dim);
  margin-bottom: var(--space-3);
}
.journey-phase .eyebrow { margin: 0 0 var(--space-3); }
.journey-phase h3 {
  font-family: var(--serif);
  font-size: 1.35rem; font-weight: 500; line-height: 1.3;
  letter-spacing: -0.015em;
  margin: 0 0 var(--space-3);
}
.journey-phase p { margin: 0 0 var(--space-4); font-size: 0.96rem; }
.journey-phase .phase-link {
  margin-top: auto;
  font-weight: 600; font-size: 0.95rem;
  color: var(--accent-deep); text-decoration: none;
}
.journey-phase .phase-link:hover { text-decoration: underline; }

/* ============ Closing CTA band (roadmap item 14) ============ */
/* Restates the hero thesis once, before the footer — copy-only, no stats. */
.closing-band {
  background: var(--paper-3);
  border-top: 1px solid var(--border);
  padding: var(--space-9) 0;
  text-align: center;
}
.closing-thesis {
  font-size: clamp(1.35rem, 2.6vw, 1.9rem);
  line-height: 1.3;
  letter-spacing: -0.02em;
  max-width: var(--maxw-text);
  margin: 0 auto var(--space-5);
}

/* ============ Footer ============ */
.site-footer {
  background: var(--ink); color: var(--on-dark-dim);
  padding: var(--space-9) 0 var(--space-7);
  font-size: 0.92rem;
}
.foot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: var(--space-7);
  padding-bottom: var(--space-7);
  border-bottom: 1px solid var(--border-dark);
}
.foot-col a { display: block; color: var(--on-dark-dim); padding: 5px 0; }
.foot-col a:hover { color: #fff; }
.foot-label {
  display: block; font-family: var(--mono); font-size: 0.68rem; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase; color: #fff;
  margin-bottom: var(--space-3);
}
.disclaimer-strip {
  padding-top: var(--space-6);
  font-size: 0.83rem; line-height: 1.6; color: #7d8b95;
}
.disclaimer-strip a { color: var(--on-dark-dim); text-decoration: underline; text-underline-offset: 2px; }
.disclaimer-strip a:hover { color: #fff; }

/* ============ Consent banner ============ */
#consent-banner {
  position: fixed; left: var(--space-4); right: var(--space-4); bottom: var(--space-4);
  z-index: 90;
  display: none;
  background: var(--ink-2); color: var(--on-dark);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: var(--space-5) var(--space-6);
  max-width: 560px;
  margin-left: auto;
  font-size: 0.88rem; line-height: 1.55;
}
#consent-banner.show { display: block; }
#consent-banner p { margin: 0 0 var(--space-4); }
#consent-banner a { color: var(--accent); }
.consent-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.consent-actions .btn { padding: 9px 18px; font-size: 0.86rem; }

/* ============ Scroll reveal ============ */
/* Reveal-on-scroll only engages once JS confirms it is running, so a script
   failure can never leave a section invisible. */
.js-reveal .reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.js-reveal .reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .reveal { opacity: 1; transform: none; }
  .btn:hover, .btn-solid:hover, .btn-primary:hover,
  .band-white .btn-solid:hover, .band-light .btn-solid:hover, .btn-dark:hover { transform: none; }
}

/* ============ Responsive ============ */
/* Between the mobile menu (900px) and here, the full nav and the brand
   tagline don't both fit on one line; the tagline gives way first. */
@media (max-width: 1220px) {
  .brand .tag { display: none; }
  .main-nav a { white-space: nowrap; }
}
/* Just above the mobile menu, the links themselves have to tighten up. */
@media (max-width: 1020px) {
  .header-inner { gap: var(--space-4); }
  .main-nav a { padding: 8px 7px; }
  .main-nav a.nav-cta { padding: 8px 13px; margin-left: 4px; }
}
@media (max-width: 900px) {
  body { font-size: 16px; }
  .band { padding: var(--space-8) 0; }
  .section-head { grid-template-columns: 1fr; align-items: start; gap: var(--space-4); }
  .hero { min-height: auto; padding: var(--space-8) 0 var(--space-7); margin: var(--space-2); }
  .hero-claim { max-width: none; }
  .hero-stats { gap: var(--space-5) var(--space-6); margin-top: var(--space-6); }
  .test-card { padding: var(--space-5); }
  .page-nav { grid-template-columns: 1fr; }
  .page-nav-link.next { text-align: left; }
  .spotlight-row { grid-template-columns: minmax(0,1fr) auto; gap: var(--space-3); }
  .spotlight-grade { grid-column: 1; }
  .spotlight-arrow { display: none; }

  .nav-toggle { display: inline-block; flex: none; }
  /* backdrop-filter makes .site-header a containing block for fixed-position
     descendants, which traps the slide-in nav inside the header box. Drop the
     blur on mobile so the panel positions against the viewport instead. */
  .site-header { backdrop-filter: none; -webkit-backdrop-filter: none; background: var(--ink); }
  .brand { font-size: 1rem; min-width: 0; }
  .header-inner { gap: var(--space-4); }
  .main-nav {
    position: fixed; inset: 0 0 0 auto;
    width: min(88vw, 340px);
    background: var(--ink);
    flex-direction: column; align-items: stretch;
    gap: 2px;
    padding: var(--space-8) var(--space-5) var(--space-5);
    transform: translateX(100%);
    transition: transform .28s cubic-bezier(.4,0,.2,1);
    z-index: 100;
    overflow-y: auto;
  }
  .main-nav.open { transform: none; }
  .main-nav a { font-size: 1.05rem; padding: 13px var(--space-4); border-radius: var(--radius-sm); }
  .nav-item { display: block; }
  .nav-item > a .caret { display: none; }
  .nav-menu {
    position: static; opacity: 1; visibility: visible; transform: none;
    min-width: 0; background: transparent; border: 0; box-shadow: none;
    padding: 0 0 var(--space-3) var(--space-4);
  }
  .nav-menu a { font-size: 0.95rem; padding: 9px var(--space-4); }
  .nav-menu a em { display: none; }
  .nav-menu-group { padding-left: var(--space-4); }
  .main-nav a.nav-cta { margin: var(--space-4) 0 0; text-align: center; justify-content: center; }
  .nav-close {
    display: block; position: absolute; top: var(--space-4); right: var(--space-4);
    background: transparent; border: 0; color: var(--on-dark-dim);
    font-size: 1.4rem; line-height: 1; cursor: pointer; padding: 8px;
  }
  .nav-backdrop {
    position: fixed; inset: 0; background: rgba(8,12,16,0.6);
    opacity: 0; pointer-events: none; transition: opacity .28s ease; z-index: 95;
  }
  .nav-backdrop.show { opacity: 1; pointer-events: auto; }
  /* .site-header carries z-index:60 and so forms a stacking context: the nav
     panel inside it is capped at 60 relative to the page, losing to the consent
     banner (90). Lift the whole header while the menu is open. */
  body.nav-open .site-header { z-index: 110; }
  body.nav-open { overflow: hidden; }
}

@media (max-width: 560px) {
  .test-card-head { flex-direction: column; gap: var(--space-3); }
  .test-meta { grid-template-columns: 1fr; gap: var(--space-4); }
  .brand .tag { display: none; }
  .ec-row { grid-template-columns: 92px minmax(0,1fr); gap: var(--space-3) var(--space-4); }
  .ec-val { grid-column: 2; }
  #consent-banner { left: var(--space-2); right: var(--space-2); bottom: var(--space-2); }
}

@media print {
  .site-header, .advice-ribbon, #consent-banner, .ad-slot, .page-nav, .nav-toggle { display: none !important; }
  .hero { min-height: auto; margin: 0; border-radius: 0; }
  body { font-size: 12pt; }
}

/* ============ Hub pages (tests.html, costs.html) ============ */
.page-intro { max-width: 860px; margin: 0 0 var(--space-8); }
.page-intro h1 { margin: 0 0 var(--space-5); }
.page-lede {
  font-size: clamp(1.05rem, 1.5vw, 1.2rem);
  line-height: 1.6; color: var(--text-dim); margin: 0; max-width: 68ch;
}

.grade-section { margin: var(--space-8) 0 0; scroll-margin-top: 96px; }
.grade-section-head { max-width: 780px; margin-bottom: var(--space-6); }
.grade-section-head .grade { margin-bottom: var(--space-4); }
.grade-section-head h2 { margin: 0 0 var(--space-4); display: flex; align-items: baseline; gap: var(--space-4); flex-wrap: wrap; }
.grade-count {
  font-size: 0.76rem; font-weight: 600; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--text-dim);
}
.grade-section .table-wrap table { min-width: 680px; }
.grade-section .table-wrap td:first-child { width: 38%; }

.cost-group { margin: var(--space-8) 0 0; }
.cost-group .section-head { margin-bottom: var(--space-5); }
.cost-group .spotlight-title-wrap .small { display: block; margin-top: 3px; }

/* The evidence chart doubles as a hub summary, so give it breathing room there. */
.page-intro + .evidence-chart { margin-bottom: var(--space-8); }

/* ============ Utility ============ */
.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;
}
.muted { color: #a9a396; }

/* ============ Faceted filters (tests hub) ============ */
.filters {
  position: sticky; top: 68px; z-index: 30;
  background: rgba(255,255,255,0.94);
  backdrop-filter: saturate(160%) blur(10px);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  box-shadow: var(--shadow-sm); /* Resting Lift Rule */
  margin: 0 0 var(--space-8);
  display: grid; gap: var(--space-4);
}
.filter-search input {
  width: 100%;
  font-family: inherit; font-size: 1rem;
  color: var(--text);
  padding: 12px var(--space-5);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--paper);
  transition: border-color .18s ease, box-shadow .18s ease;
}
.filter-search input::placeholder { color: #9aa3ab; }
.filter-search input:focus {
  outline: none;
  border-color: var(--accent-mid);
  box-shadow: 0 0 0 3px rgba(111,211,239,0.3);
}
.chip-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.chip {
  font-family: inherit; font-size: 0.84rem; font-weight: 500;
  color: var(--text); background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 7px 14px; cursor: pointer;
  display: inline-flex; align-items: center; gap: 7px;
  transition: background .16s ease, border-color .16s ease, color .16s ease;
}
.chip:hover { border-color: var(--text-dim); }
.chip[aria-pressed="true"] {
  background: var(--ink); border-color: var(--ink); color: #fff;
}
.chip-n {
  font-size: 0.72rem; font-weight: 600;
  color: var(--text-dim); font-variant-numeric: tabular-nums;
}
.chip[aria-pressed="true"] .chip-n { color: var(--accent); }
.filter-foot {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--space-4); flex-wrap: wrap;
  font-size: 0.88rem; color: var(--text-dim);
}
.btn-reset {
  font-family: inherit; font-size: 0.84rem; font-weight: 600;
  color: var(--accent-deep); background: transparent;
  border: 0; padding: 4px 2px; cursor: pointer;
  text-decoration: underline; text-underline-offset: 3px;
}
.btn-reset:hover { color: var(--text); }
.no-results {
  padding: var(--space-8) 0; text-align: center;
  font-size: 1.05rem; color: var(--text-dim);
}
tr[data-test-row].is-hidden { display: none; }
.grade-section.is-hidden { display: none; }
/* Global sort (name/cost) flattens the grade sections into one list; the
   surviving first section loses its heading so no orphaned grade label
   sits above the mixed order. */
.grade-section.flat .grade-section-head { display: none; }

/* ============ Per-test pages ============ */
.test-hero { max-width: 820px; margin: 0 0 var(--space-7); }
.test-hero .grade { margin-bottom: var(--space-4); }
.test-hero h1 {
  font-size: clamp(2rem, 4vw, 3.1rem);
  margin: 0; text-wrap: balance;
}
.test-body { max-width: var(--maxw-text); font-size: 1.06rem; }
.test-body > p { line-height: 1.7; }
.test-body .evidence { margin-top: var(--space-6); }
.test-body .test-meta { margin-top: var(--space-7); }

/* ============ Tool pages: build-your-panel + compare ============ */
/* Both follow the established language: pill for anything interactive, soft
   rounded rectangles for containers, resting shadow on the primary surface. */

.basket {
  position: sticky; top: 68px; z-index: 30;
  background: rgba(255,255,255,0.94);
  backdrop-filter: saturate(160%) blur(10px);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  box-shadow: var(--shadow-sm); /* Resting Lift Rule */
  margin: 0 0 var(--space-7);
  display: grid; gap: var(--space-4);
}
.basket-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: var(--space-4) var(--space-5); flex-wrap: wrap;
}
.basket-figures { display: grid; gap: 2px; }
.basket-figures b {
  font-size: 1.02rem; font-weight: 600; color: var(--text);
  letter-spacing: -0.015em;
}
.basket-cost {
  font-size: clamp(1.6rem, 3vw, 2.1rem); font-weight: 400;
  letter-spacing: -0.025em; line-height: 1.15; color: var(--text);
  font-variant-numeric: tabular-nums;
}
.basket-actions { display: flex; align-items: center; gap: var(--space-4); }

/* The stacked spend bar. Same four confidence-scale colors as the homepage
   evidence chart — semantic data, not a second accent. */
.basket-bar {
  display: flex; width: 100%; height: 10px;
  border-radius: var(--radius-pill);
  background: var(--paper-3);
  overflow: hidden;
}
.basket-seg { height: 100%; }
.bs-strong   { background: var(--strong); }
.bs-moderate { background: var(--moderate); }
.bs-weak     { background: var(--weak); }
.bs-emerging { background: var(--emerging); }

.basket-legend {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: var(--space-3) var(--space-5);
  font-size: 0.86rem; color: var(--text-dim);
}
.basket-legend li { display: inline-flex; align-items: center; gap: 8px; }
.basket-legend .dot {
  width: 9px; height: 9px; border-radius: var(--radius-pill); flex: none;
}
.basket-legend b { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }
.basket-verdict {
  margin: 0; font-size: 0.95rem; color: var(--text-dim); max-width: 68ch;
}
.basket-verdict strong { color: var(--text); font-weight: 600; }
.basket-presets { padding-top: var(--space-1); }
.basket-presets .label { color: var(--text-dim); }

/* Checkbox rows in the picker tables. */
.pick {
  display: inline-flex; align-items: flex-start; gap: var(--space-3);
  cursor: pointer; font-weight: 600;
}
.pick input {
  margin: 3px 0 0; flex: none;
  width: 17px; height: 17px;
  accent-color: var(--accent-deep); cursor: pointer;
}
.pick input:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
tr.is-picked td { background: var(--accent-wash); }

/* Compare picker + table. */
.compare-slots {
  display: grid; gap: var(--space-4);
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.compare-slot { display: grid; gap: var(--space-2); }
.compare-slot .label { color: var(--text-dim); }
.compare-slot select {
  width: 100%;
  font-family: inherit; font-size: 0.95rem; color: var(--text);
  padding: 11px var(--space-5);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--paper);
  cursor: pointer;
  transition: border-color .18s ease, box-shadow .18s ease;
}
.compare-slot select:focus {
  outline: none;
  border-color: var(--accent-mid);
  box-shadow: 0 0 0 3px rgba(111,211,239,0.3);
}
.compare-wrap { margin-top: var(--space-6); }
/* Fixed layout so the three test columns stay equal instead of being sized by
   whichever one happens to have the longest cost string. */
.compare-table { min-width: 760px; table-layout: fixed; }
.compare-table th[scope="row"] {
  width: 190px; vertical-align: top; white-space: normal;
  font-size: 0.7rem; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--text-dim);
}
.compare-table td { vertical-align: top; overflow-wrap: break-word; }
.compare-table thead th[scope="col"] {
  font-size: 0.95rem; letter-spacing: -0.015em; text-transform: none;
  font-weight: 600; color: var(--text);
  /* .table-wrap th is nowrap for short column labels; these are test names. */
  white-space: normal; overflow-wrap: break-word;
}
.compare-table tbody tr:hover { background: transparent; }
.compare-table tr.compare-prose td { font-size: 0.9rem; color: var(--text-dim); }
.compare-table tr.compare-prose p { margin: 0 0 var(--space-3); }
.compare-table tr.compare-prose p:last-child { margin-bottom: 0; }
.compare-table .evidence-label { display: block; margin-bottom: var(--space-2); }
.compare-table .citation { margin: 0; }

/* Grade-color ambient row tints (roadmap §4/§5): additive cue only — the
   text-labelled badge in the same row remains the primary differentiator. */
.compare-table tbody tr.grade-row-strong   { background: rgba(26,127,66,0.06); }
.compare-table tbody tr.grade-row-moderate { background: rgba(37,99,201,0.06); }
.compare-table tbody tr.grade-row-weak     { background: rgba(156,87,8,0.06); }
.compare-table tbody tr.grade-row-emerging { background: rgba(112,40,208,0.06); }

.tool-crosslink {
  margin: var(--space-7) 0 0;
  font-size: 0.95rem; color: var(--text-dim);
}

@media (max-width: 900px) {
  .compare-slots { grid-template-columns: 1fr; }
  .basket { position: static; }
  .basket-head { align-items: flex-start; }
}

/* ============ Landing-page motion ============ */
/* All of it sits behind .js-reveal, so a script failure leaves a static,
   fully-visible hero rather than a blank one. The global
   prefers-reduced-motion block disables every animation below. */
.hero { background: var(--ink); }
.hero::before,
.hero::after { content: ""; position: absolute; inset: 0; }
/* CSS-only hero: warm-paper-to-ink wash with a quiet four-band echo of the
   evidence chart in the grade colors. Replaces img/hero-lab.jpg — zero KB,
   zero requests, no stock lab imagery (roadmap imagery rule, option 1). */
.hero::before {
  background-image:
    radial-gradient(120% 90% at 85% -10%,
      rgba(111,211,239,0.16) 0%, rgba(13,118,149,0.10) 34%, transparent 62%),
    linear-gradient(180deg, #2a2726 0%, var(--ink) 58%, #141210 100%);
}
.js-reveal .hero::before { animation: hero-drift 20s ease-out forwards; }
/* Stack order (no video since 2026-10-03, ROADMAP decision 9):
   ::before base gradient z 0, ::after colour wash z 2, .wrap content z 4. */
.hero::before { z-index: 0; }
.hero::after {
  background:
    conic-gradient(from 210deg at 50% 115%,
      rgba(26,127,66,0.14) 0deg, rgba(37,99,201,0.14) 90deg,
      rgba(156,87,8,0.14) 180deg, rgba(112,40,208,0.14) 270deg,
      rgba(26,127,66,0.14) 360deg);
  mix-blend-mode: screen;
  opacity: 0.5;
  z-index: 2;
}
.hero .wrap { z-index: 4; }

/* Gentle ambient drift of the gradient wash — replaces the photo slow-zoom.
   Purely decorative movement; content never depends on it. */
@keyframes hero-drift {
  from { transform: scale(1) translateY(0); }
  to   { transform: scale(1.06) translateY(-8px); }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: none; }
}

.js-reveal .hero-lede > * {
  opacity: 0;
  animation: rise .75s cubic-bezier(.22,.9,.3,1) forwards;
}
.js-reveal .hero-lede > *:nth-child(1) { animation-delay: .06s; }
.js-reveal .hero-lede > *:nth-child(2) { animation-delay: .16s; }
.js-reveal .hero-lede > *:nth-child(3) { animation-delay: .26s; }
.js-reveal .hero-lede > *:nth-child(4) { animation-delay: .36s; }
.js-reveal .hero-lede > *:nth-child(5) { animation-delay: .46s; }

/* Counting numbers must not reflow the layout as digits change. */
.hero-stat b, .ec-val b { font-variant-numeric: tabular-nums; }

@media (max-width: 900px) {
  .filters { top: 60px; padding: var(--space-4); }
  .filters .chip-row { gap: 6px; }
  .chip { font-size: 0.8rem; padding: 6px 12px; }
}

/* ============ Wave 1 reorg: anchor-nav pills ============ */
/* Pill row used as the hub mini-strip and inside the tests.html sticky
   filter bar. Plain links first; JS only adds the .is-current highlight. */
.anchor-nav {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: var(--space-2);
  margin: 0 0 var(--space-6);
}
.filters .anchor-nav { margin: 0; }
.anchor-pill {
  font-family: inherit; font-size: 0.86rem; font-weight: 500;
  color: var(--text); background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 7px 15px;
  display: inline-flex; align-items: center; gap: 7px;
  text-decoration: none;
  transition: background .16s ease, border-color .16s ease, color .16s ease;
}
.anchor-pill:hover { border-color: var(--text-dim); text-decoration: none; }
.anchor-pill b {
  font-size: 0.74rem; font-weight: 600;
  color: var(--text-dim); font-variant-numeric: tabular-nums;
}
.anchor-pill.is-current {
  background: var(--ink); border-color: var(--ink); color: #fff;
}
.anchor-pill.is-current b { color: var(--accent); }

/* ============ Wave 1 reorg: compact index rows (ix-*) ============ */
/* Shared by the five intervention hubs, the four category pages, and
   tests.html. Compact by design: name + one-line verdict + badge + cost,
   with full prose one step away (details on hubs, per-test page on the
   categories). Row ids keep legacy #anchor targets alive. */
.ix-list {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: var(--space-3);
}
.ix-row {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--space-4) var(--space-5);
  scroll-margin-top: 96px;
  display: grid; gap: var(--space-3);
  transition: border-color .16s ease, box-shadow .16s ease;
}
/* Grade-color ambient left-border (roadmap §4/§5): additive cue only —
   every ix-row also carries a text-labelled grade badge. */
.ix-row.grade-row-strong   { box-shadow: inset 3px 0 0 rgba(26,127,66,0.45); }
.ix-row.grade-row-moderate { box-shadow: inset 3px 0 0 rgba(37,99,201,0.45); }
.ix-row.grade-row-weak     { box-shadow: inset 3px 0 0 rgba(156,87,8,0.45); }
.ix-row.grade-row-emerging { box-shadow: inset 3px 0 0 rgba(112,40,208,0.45); }
.ix-row:hover { border-color: var(--accent-mid); }
.ix-main {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center; gap: var(--space-4);
}
.ix-grade { flex: none; }
.ix-grade .grade { font-size: 0.78rem; }
.ix-titlewrap { display: grid; gap: 2px; min-width: 0; }
.ix-name {
  font-weight: 600; font-size: 1.02rem; letter-spacing: -0.01em;
  color: var(--text);
}
a.ix-name:hover { color: var(--accent-deep); }
.ix-verdict {
  font-size: 0.9rem; line-height: 1.45; color: var(--text-dim);
}
.ix-cost {
  font-size: 0.88rem; color: var(--text-dim); text-align: right;
  line-height: 1.4; max-width: 22ch;
}
.ix-guide { display: block; margin-top: 2px; }
.ix-guide a { font-size: 0.84rem; white-space: nowrap; }
.ix-detail { min-width: 0; }
.ix-detail summary {
  cursor: pointer; font-weight: 600; font-size: 0.9rem;
  color: var(--accent-deep); padding: var(--space-1) 0 0;
  width: fit-content;
}
.ix-detail summary:hover { color: var(--text); }
.ix-detail[open] summary { color: var(--text); }
.ix-detail-body {
  border-top: 1px solid var(--border);
  margin-top: var(--space-3); padding-top: var(--space-4);
  font-size: 0.96rem; line-height: 1.65; color: var(--text);
  max-width: 74ch;
}
.ix-detail-body .evidence { margin-top: var(--space-4); }
.ix-detail-body p:last-child { margin-bottom: 0; }
.ix-cites {
  margin: var(--space-4) 0 0; padding-left: 1.4em;
  font-size: 0.88rem; color: var(--text-dim);
}
.ix-cites li { margin-bottom: 6px; }
.ix-cites li:last-child { margin-bottom: 0; }
.ix-section { scroll-margin-top: 96px; }

/* ============ Hub index rows (de-AI'd + split to detail pages, 2026-08-26) ============ */
/* The hub is an INDEX: one-line rows (number, title, verdict, grade, arrow)
   linking to per-intervention pages. Full content lives on the detail page —
   the diet page was a wall of text. */
.short-version {
  font-size: 1.02rem; line-height: 1.6; color: var(--text);
  max-width: 68ch; margin: 0 0 var(--space-5);
  padding-bottom: var(--space-5);
  border-bottom: 1px solid var(--border);
}
.fw-jump {
  font-family: var(--mono);
  font-size: 0.8rem; letter-spacing: 0.02em;
  color: var(--text-dim);
  margin: 0 0 var(--space-7);
}
.fw-jump a { color: var(--accent-deep); text-decoration: none; }
.fw-jump a:hover { text-decoration: underline; }
.fw-section { margin-top: var(--space-8); }
.fw-section .grade-section-head { margin-bottom: var(--space-5); }
.fw-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto 20px;
  align-items: baseline;
  gap: var(--space-4);
  padding: var(--space-4) 0;
  border-top: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
  transition: background .14s ease;
}
.fw-row:hover { background: var(--paper-2); text-decoration: none; }
.fw-row:last-child { border-bottom: 1px solid var(--border); }
.fw-num {
  font-family: var(--mono);
  font-size: 0.78rem; font-weight: 500; letter-spacing: 0.1em;
  color: var(--text-dim);
}
.fw-rowtitle {
  display: inline;
  font-family: var(--serif);
  font-size: 1.2rem; font-weight: 500; letter-spacing: -0.015em;
}
.fw-rowverdict {
  display: block;
  margin-top: 2px;
  font-size: 0.9rem; line-height: 1.5; color: var(--text-dim);
  max-width: 64ch;
}
.fw-arrow { color: var(--accent-deep); }
@media (max-width: 640px) {
  .fw-row { grid-template-columns: 36px minmax(0, 1fr) auto; }
  .fw-arrow { display: none; }
}
/* Per-intervention detail pages reuse test-page styles (.test-hero,
   .test-body, .evidence, .test-meta, .ix-cites) — no extra CSS needed. */

/* ============ Wave 1 reorg: homepage hub list (editorial rows, 2026-08-26) ============ */
/* User: card grids look AI. Hubs are now numbered full-width rows on hairlines. */
.hub-list {
  margin-top: var(--space-6);
  border-bottom: 1px solid var(--border);
}
.hub-row {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto 24px;
  align-items: baseline;
  gap: var(--space-4);
  padding: var(--space-5) 0;
  border-top: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
  transition: background .14s ease, box-shadow .14s ease;
}
/* The hover tint bleeds past the row edges with box-shadow instead of
   padding, so the text stays put and nothing reflows. */
.hub-row:hover {
  background: var(--paper-2);
  box-shadow: calc(-1 * var(--space-4)) 0 0 var(--paper-2), var(--space-4) 0 0 var(--paper-2);
  text-decoration: none;
}
.hub-num {
  font-family: var(--mono);
  font-size: 0.78rem; font-weight: 500; letter-spacing: 0.1em;
  color: var(--text-dim);
}
.hub-body h3 {
  display: inline;
  margin: 0;
  font-family: var(--serif);
  font-size: 1.35rem; font-weight: 500; letter-spacing: -0.015em;
}
.hub-blurb {
  display: block;
  margin: 4px 0 0;
  font-size: 0.92rem; line-height: 1.5; color: var(--text-dim);
  max-width: 64ch;
}
.hub-count {
  margin: 0; font-size: 0.78rem; color: var(--text-dim);
  white-space: nowrap;
}
.hub-count b { font-weight: 600; color: var(--text); font-variant-numeric: tabular-nums; }
.hub-arrow { color: var(--accent-deep); font-size: 1.1rem; }
@media (max-width: 720px) {
  .hub-row { grid-template-columns: 44px minmax(0, 1fr) auto; }
  .hub-blurb { grid-column: 2 / -1; }
  .hub-count { grid-column: 3; }
  .hub-arrow { display: none; }
}

/* ============ Wave 1 reorg: responsive ============ */
@media (max-width: 900px) {
  .ix-main { grid-template-columns: auto minmax(0, 1fr); }
  .ix-cost { grid-column: 2; text-align: left; max-width: none; }
  .anchor-pill { padding: 6px 13px; font-size: 0.82rem; }
}
@media (max-width: 560px) {
  .ix-row { padding: var(--space-4); }
  .ix-main { grid-template-columns: 1fr; gap: var(--space-3); }
  .ix-cost { grid-column: auto; }
  .ix-detail-body { font-size: 0.94rem; }
  .hub-grid { grid-template-columns: 1fr; }
  .hub-card:last-child { grid-column: auto; }
  .anchor-nav { gap: 6px; }
}

/* ---------------------------------------------------------------- Net cost
   Roadmap item 19. Hairline spec rows, not a card: the gross price sits in
   .test-meta above and this block answers "what do I actually pay". No
   background fill, no radius - a filled box here would read as a template
   component, which is the AI tell the design law forbids. Subsidy state is
   carried by a 2px left rule in the same neutral register as the site, never
   by a colour that would imply a grade. */
.net-cost {
  margin: var(--space-6) 0;
  padding: var(--space-5) 0 var(--space-4);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.net-cost > .label { margin: 0 0 var(--space-3); }
.nc-rows { margin: 0; }
.nc-row {
  display: grid;
  grid-template-columns: 11rem 1fr;
  gap: var(--space-3);
  align-items: baseline;
  padding: var(--space-3) 0 var(--space-3) var(--space-3);
  border-left: 2px solid var(--border);
}
.nc-row + .nc-row { border-top: 1px solid var(--border); }
.nc-row dt {
  font-family: var(--mono);
  font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-dim);
}
.nc-row dd { margin: 0; font-size: 0.95rem; color: var(--text); }
.nc-hsg-covered, .nc-hsg-covered-in-visit, .nc-ms-claimable {
  border-left-color: var(--text);
}
.nc-hsg-not-covered, .nc-ms-not-listed {
  border-left-color: var(--border);
}
.nc-detail {
  font-size: 0.9rem; line-height: 1.6;
  color: var(--text-dim);
  padding: var(--space-2) 0 var(--space-3) calc(11rem + var(--space-4));
}
.nc-elig { color: var(--text); }
.nc-source {
  font-size: 0.86rem; line-height: 1.55;
  color: var(--text-dim);
  margin: var(--space-3) 0 0;
  padding-left: var(--space-3);
  border-left: 2px solid var(--border);
}
@media (max-width: 560px) {
  .nc-row { grid-template-columns: 1fr; gap: var(--space-2); }
  .nc-detail { padding-left: var(--space-3); }
}

/* ---------------------------------------------------------------- Harm
   Item 18. Same hairline spec-row register as .net-cost - no fill, no
   radius. Severity is carried by a left rule weight, not a colour: the grade
   palette is the only chromatic system on this site and inventing a red
   "danger" chip here would both read as a template component and collide
   with the meaning the grade colours already carry. */
.harm {
  margin: var(--space-6) 0;
  padding: var(--space-5) 0 var(--space-4);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.harm > .label { margin: 0 0 var(--space-3); }
.harm-rows { margin: 0; }
.harm-row {
  display: grid;
  grid-template-columns: 11rem 1fr;
  gap: var(--space-3);
  align-items: baseline;
  padding: var(--space-3) 0 var(--space-3) var(--space-3);
  border-left: 2px solid var(--border);
}
.harm-row + .harm-row { border-top: 1px solid var(--border); }
.harm-row dt {
  font-family: var(--mono);
  font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-dim);
}
.harm-row dd { margin: 0; font-size: 0.95rem; color: var(--text); }
.harm-sev-material .harm-row { border-left-color: var(--text); }
.harm-sev-material > .label { color: var(--text); }
.harm-sev-minor .harm-row:first-of-type { border-left-color: var(--text-dim); }
.harm-note {
  font-size: 0.95rem; line-height: 1.62;
  color: var(--text);
  margin: var(--space-3) 0 0;
  padding-left: var(--space-3);
  border-left: 2px solid var(--border);
}
.harm-conf {
  font-size: 0.88rem; line-height: 1.55;
  color: var(--text-dim);
  margin: var(--space-2) 0 0;
  padding-left: var(--space-3);
}
.harm-source {
  font-size: 0.86rem; line-height: 1.55;
  color: var(--text-dim);
  margin: var(--space-3) 0 0;
  padding-left: var(--space-3);
  border-left: 2px solid var(--border);
}
@media (max-width: 560px) {
  .harm-row { grid-template-columns: 1fr; gap: var(--space-2); }
}
