/* AI Scholar Coach — marketing landing, version 3 ("The Coach's Line").
   System fonts only; rem units so text scaling reflows. Purple means "next step". */

:root {
  --paper: #faf8f4;
  --paper-2: #f3efe7;
  --surface: #fff;
  --ink: #152542;
  --text: #2c3a52;
  --muted: #52647c;
  --line: #e4ded3;
  --line-mid: #cfc7b9;
  --line-strong: #7f8898;
  --accent: #6631bc;
  --accent-deep: #4e2495;
  --accent-soft: #f1eafb;
  --strong: #1a7350;
  --strong-soft: #e4f5ed;
  --dev: #b26a00;
  --dev-text: #855000;
  --dev-soft: #fff3dc;
  --need: #b0334f;
  --need-soft: #fbe9ee;
  --focus: #752fbd;
  --lavender: #c9b1ff;
  --on-ink: #c2cbe0;
  --footer: #0f1b31;
  --serif: "Iowan Old Style", "Sitka Heading", "Palatino Linotype", Palatino, Charter, Georgia, ui-serif, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI Variable Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --shadow-sheet: 0 1px 2px rgba(21, 37, 66, .05), 0 1.75rem 3.5rem -2rem rgba(21, 37, 66, .3);
  --shadow-card: 0 1px 2px rgba(21, 37, 66, .06), 0 2rem 4rem -1.75rem rgba(21, 37, 66, .38);
  --gutter: 2.5rem;
  --radius: .75rem;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font: 400 1.0625rem/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}
[hidden] { display: none !important; }
h1, h2, h3, p, ul, ol, figure, blockquote { margin: 0; }
ul, ol { padding: 0; }
a { color: inherit; }
button, input, select { font: inherit; }
svg { flex: none; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.i { width: 1.125em; height: 1.125em; }
.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0;
}
html:not(.js) .js-only { display: none !important; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: .25rem; }
.final :focus-visible, .site-footer :focus-visible { outline-color: var(--lavender); }
main:focus { outline: none; }

.skip-link {
  position: absolute; left: 1rem; top: -10rem; z-index: 100;
  padding: .75rem 1.125rem; border-radius: var(--radius);
  background: var(--ink); color: #fff; font-weight: 650; text-decoration: none;
}
.skip-link:focus { top: 1rem; }

.wrap { width: 100%; max-width: 77.5rem; margin-inline: auto; padding-inline: var(--gutter); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 2.75rem; padding: .625rem 1.25rem;
  border: 1.5px solid transparent; border-radius: var(--radius);
  font-weight: 650; font-size: 1rem; line-height: 1.2; text-align: center; text-decoration: none;
  cursor: pointer;
}
.btn .i { width: 1.125rem; height: 1.125rem; }
.btn-sm { padding: .5rem 1.125rem; font-size: .9375rem; }
.btn-lg { min-height: 3.5rem; padding: .875rem 1.75rem; font-size: 1.0625rem; }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 .625rem 1.375rem -.75rem rgba(102, 49, 188, .7); }
.btn-primary:hover { background: var(--accent-deep); }
.btn-quiet { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn-quiet:hover { border-color: var(--ink); background: rgba(21, 37, 66, .03); }
.btn-ink { background: var(--ink); color: #fff; }
.btn-ink:hover { background: #22375c; }
.btn-light { background: var(--lavender); color: var(--ink); }
.btn-light:hover { background: #dccbff; }
.btn-ghost-light { color: #fff; border-color: rgba(255, 255, 255, .55); }
.btn-ghost-light:hover { border-color: #fff; background: rgba(255, 255, 255, .06); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250, 248, 244, .96);
  border-bottom: 1px solid var(--line);
}
@supports (backdrop-filter: blur(1px)) {
  .site-header { background: rgba(250, 248, 244, .88); backdrop-filter: saturate(1.4) blur(.75rem); }
}
.header-inner { display: flex; align-items: center; gap: 1.5rem; min-height: 4.5rem; }
.brand {
  display: inline-flex; align-items: center; gap: .625rem; min-height: 2.75rem;
  color: var(--ink); text-decoration: none; flex: none;
}
.brand-mark { width: 2rem; height: 2rem; }
.wordmark { font-family: var(--serif); font-size: 1.1875rem; font-weight: 600; line-height: 1.15; letter-spacing: -.005em; white-space: nowrap; }
.site-nav { display: flex; align-items: center; gap: .25rem; margin-left: auto; }
.site-nav a {
  display: inline-flex; align-items: center; min-height: 2.75rem; padding: .5rem .875rem;
  border-radius: .5rem; color: var(--ink); font-size: .9375rem; font-weight: 560; text-decoration: none;
}
.site-nav a:hover { background: var(--paper-2); }
.site-nav a[data-link="login"] { position: relative; margin-left: .75rem; }
.site-nav a[data-link="login"]::before {
  content: ""; position: absolute; left: -.5rem; top: 50%; width: 1px; height: 1.25rem;
  margin-top: -.625rem; background: var(--line-mid);
}
.header-cta { flex: none; }

/* ---------- Hero ---------- */
.hero { padding: 4rem 0 6rem; overflow-x: clip; }
.hero-grid {
  display: grid; grid-template-columns: minmax(0, 29.5rem) minmax(0, 1fr);
  gap: 4.5rem; align-items: center;
}
.eyebrow {
  display: flex; align-items: center; gap: .875rem;
  color: var(--ink); font-size: .9375rem; font-weight: 650; line-height: 1.35;
}
.eyebrow-line {
  position: relative; flex: none; width: 1.875rem; height: .15625rem; border-radius: 2px; background: var(--accent);
}
.eyebrow-line::after {
  content: ""; position: absolute; right: -.1875rem; top: -.1875rem;
  width: .53125rem; height: .53125rem; border-radius: 50%; background: var(--accent);
}
.hero h1 {
  margin: 1.375rem 0 1.625rem;
  font: 400 clamp(2.625rem, 1.2rem + 3.4vw, 4.375rem)/1.03 var(--serif);
  letter-spacing: -.02em; color: var(--ink); text-wrap: balance;
}
.hero h1 em { font-style: italic; }
.lead { font-size: 1.25rem; line-height: 1.55; color: var(--text); max-width: 29em; }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }
.hero-tests {
  display: flex; flex-wrap: wrap; align-items: center; column-gap: 1.25rem;
  margin-top: 1.75rem; font-size: .9375rem;
}
.hero-tests-label { flex-basis: 100%; color: var(--muted); }
.hero-tests a {
  display: inline-flex; align-items: center; min-height: 2.75rem;
  color: var(--ink); font-weight: 650; text-decoration: underline;
  text-decoration-color: var(--lavender); text-decoration-thickness: 2px; text-underline-offset: .3em;
}
.hero-tests a:hover { text-decoration-color: var(--accent); }

/* Hero visual: skills map → coach's line → next session */
.hero-visual {
  --drop: 6.75rem;
  position: relative; display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 23rem);
  grid-template-areas: "nmap nmap" "sheet sheet" "ncard card";
  column-gap: 1.5rem;
}
.hero-visual::before {
  content: ""; position: absolute; inset: -2.5rem -1.25rem -2.5rem -2.5rem; z-index: -1;
  background-image: radial-gradient(circle, #e3dccf 1.2px, transparent 1.4px);
  background-size: 1.375rem 1.375rem;
  -webkit-mask-image: radial-gradient(ellipse at 55% 45%, #000 30%, transparent 72%);
  mask-image: radial-gradient(ellipse at 55% 45%, #000 30%, transparent 72%);
}
.note {
  display: flex; align-items: flex-start; gap: .5625rem;
  color: var(--text); font-size: .875rem; font-weight: 560; line-height: 1.4;
}
.note-dot {
  flex: none; width: .5625rem; height: .5625rem; margin-top: .3125rem;
  border: 2px solid var(--line-strong); border-radius: 50%; background: var(--surface);
}
.note-map { grid-area: nmap; justify-self: end; margin: 0 3rem .75rem 0; }
.note-card {
  grid-area: ncard; justify-self: end; align-self: center;
  max-width: 13.5rem; margin-top: 3.5rem; flex-direction: row-reverse; text-align: right;
}

.sheet {
  position: relative; background: var(--surface);
  border: 1px solid var(--line); border-radius: 1.125rem; box-shadow: var(--shadow-sheet);
}
.map-sheet { grid-area: sheet; margin-right: 3rem; padding: 1.5rem 1.875rem 2.75rem; }
.sheet-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: .75rem 1.5rem; margin-bottom: 1rem; }
.sheet-title { font: 400 1.3125rem/1.25 var(--serif); color: var(--ink); }
.label { font-size: .8125rem; font-weight: 600; line-height: 1.4; color: var(--muted); letter-spacing: .01em; }
.label-accent { color: var(--accent); }
.label-ink { color: var(--ink); }
.legend { list-style: none; display: flex; flex-wrap: wrap; gap: .25rem .875rem; font-size: .8125rem; color: var(--muted); }
.legend li { display: flex; align-items: center; gap: .375rem; }
.legend .n { width: .75rem; height: .75rem; }

.map-rows { list-style: none; }
.map-row { display: grid; grid-template-columns: 11.25rem minmax(0, 1fr); align-items: center; min-height: 2.875rem; }
.row-name { font-size: .9375rem; font-weight: 600; color: var(--ink); line-height: 1.3; }
.track { position: relative; display: flex; justify-content: space-between; align-items: center; min-height: 2rem; padding-inline: .25rem; }
.track::before {
  content: ""; position: absolute; left: .5rem; right: .5rem; top: 50%;
  height: 1.5px; margin-top: -.75px; background: #e2dbcf;
}

/* Status nodes: shape + colour (solid = Strong, half = Developing, ring = Building) */
.n {
  position: relative; z-index: 1; display: inline-block; flex: none;
  width: 1rem; height: 1rem; border-radius: 50%; font-style: normal;
}
.n.s { background: var(--strong); }
.n.d { border: 2px solid var(--dev); background: linear-gradient(90deg, var(--dev) 50%, var(--surface) 50%); }
.n.x { border: 2px solid var(--need); background: var(--surface); }
.n.chosen {
  width: 1.125rem; height: 1.125rem; z-index: 2;
  box-shadow: 0 0 0 .25rem var(--surface), 0 0 0 .40625rem var(--accent);
}
.chosen-label {
  position: absolute; top: calc(100% + .625rem); right: calc(50% + .5rem);
  /* One line normally; wraps (right-aligned) only when large text would push it past the map's edge. */
  width: max-content; max-width: var(--label-room, none); text-align: right;
  font-size: .8125rem; font-weight: 650; line-height: 1.3; color: var(--ink);
}
.coach-line {
  position: absolute; left: 50%; top: calc(100% + .5rem); z-index: 3;
  width: 2.5rem; height: var(--drop); margin-left: -.09375rem; pointer-events: none;
}
.coach-line svg { display: block; width: 100%; height: 100%; overflow: visible; }
.coach-line path { fill: none; stroke: var(--accent); stroke-width: 2.5px; stroke-linecap: round; }
.coach-line::after {
  content: ""; position: absolute; right: calc(3.75% - .3125rem); bottom: -.3125rem;
  width: .625rem; height: .625rem; border-radius: 50%; background: var(--accent);
  box-shadow: 0 0 0 .1875rem var(--surface);
}

.next-card {
  grid-area: card; position: relative; z-index: 1; margin-top: 3.5rem;
  padding: 1.375rem 1.5rem 1.25rem;
  background: var(--surface); border: 1px solid var(--line); border-radius: 1.125rem; box-shadow: var(--shadow-card);
}
.card-title { margin: .375rem 0 .875rem; font: 400 1.375rem/1.25 var(--serif); color: var(--ink); }
.steps { list-style: none; border-top: 1px solid var(--line); }
.steps li {
  display: grid; grid-template-columns: 1.5rem minmax(0, 1fr) auto; gap: .75rem; align-items: center;
  padding: .625rem 0; border-bottom: 1px solid var(--line);
  color: var(--ink); font-size: .9375rem; line-height: 1.35;
}
.step-n {
  display: grid; place-items: center; width: 1.5rem; height: 1.5rem; border-radius: 50%;
  background: var(--accent-soft); color: var(--accent-deep); font-size: .75rem; font-weight: 700;
}
.mins { color: var(--muted); font-size: .875rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.why-this { margin-top: .875rem; font-size: .875rem; line-height: 1.5; color: var(--text); }
.why-this strong { color: var(--ink); }

/* ---------- Why ---------- */
.why { padding: 6rem 0 6.5rem; border-top: 1px solid var(--line); }
/* Keep anchor targets and keyboard focus clear of the pinned header. */
html { scroll-padding-top: calc(var(--sticky-h, 4.5rem) + .5rem); }
section[id], .test-choice label { scroll-margin-top: .5rem; }
/* Land the section rule under the header rule, so #why never shows a double line. */
#why { scroll-margin-top: calc(-.5rem - 1px); }
.why-head { max-width: 44rem; margin: 0 auto 4rem; text-align: center; }
h2 {
  font: 400 clamp(2.125rem, 1.4rem + 1.8vw, 3.125rem)/1.08 var(--serif);
  letter-spacing: -.015em; color: var(--ink); text-wrap: balance;
}
.why-intro { margin-top: 1rem; font-size: 1.1875rem; line-height: 1.55; color: var(--text); }
.why-route { list-style: none; position: relative; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 3.5rem; }
.why-route::before {
  content: ""; position: absolute; top: 3rem; left: 16.6%; right: 16.6%;
  border-top: 1.5px dashed var(--line-mid);
}
.why-item { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; }
.why-icon {
  position: relative; display: grid; place-items: center; width: 6rem; height: 6rem; margin: 0 auto 1.75rem;
  border: 1px solid var(--line); border-radius: 50%; background: var(--paper);
}
.why-icon svg { width: 3.625rem; height: 3.625rem; }
.why-item h3 { font: 400 1.5rem/1.25 var(--serif); color: var(--ink); }
.why-item p { max-width: 22rem; margin: .75rem auto .75rem; color: var(--text); line-height: 1.62; }
.why-item .router { margin-top: auto; }
.router {
  display: inline-flex; align-items: center; gap: .375rem; min-height: 2.75rem; margin-top: .75rem;
  color: var(--accent); font-size: .9375rem; font-weight: 650; text-decoration: none;
}
.router:hover { text-decoration: underline; text-underline-offset: .25em; }

/* ---------- Bands ---------- */
.band { padding: 6rem 0; }
.band-paper { background: var(--paper-2); }
.band-white { background: var(--surface); }
.band-white .sheet { box-shadow: 0 1px 2px rgba(21, 37, 66, .04), 0 1rem 2.5rem -1.75rem rgba(21, 37, 66, .25); }
.section-head { max-width: 46rem; margin-bottom: 3rem; }
.kicker { display: flex; align-items: center; gap: .875rem; margin-bottom: 1rem; color: var(--ink); font-size: .9375rem; font-weight: 650; }
.kicker::before { content: ""; width: 1.875rem; height: .15625rem; border-radius: 2px; background: var(--ink); }
.standfirst { margin-top: 1rem; font-size: 1.1875rem; line-height: 1.55; color: var(--text); max-width: 42rem; }

/* Segmented radio controls (CSS-only switching for the test panels) */
.choice { min-inline-size: 0; margin: 0; padding: 0; border: 0; }
.segmented {
  display: inline-flex; flex-wrap: wrap; gap: .25rem; padding: .3125rem;
  border: 1px solid var(--line-mid); border-radius: 1rem; background: var(--surface);
}
.segmented input { position: absolute; width: 1px; height: 1px; margin: 0; opacity: 0; }
.segmented label {
  display: inline-flex; align-items: center; min-height: 2.75rem; padding: .5rem 1.125rem;
  border-radius: .6875rem; color: var(--ink); font-size: .9375rem; font-weight: 620; line-height: 1.25; cursor: pointer;
}
.segmented label:hover { background: var(--paper-2); }
.segmented input:checked + label { background: var(--ink); color: #fff; }
.segmented input:focus-visible + label { outline: 3px solid var(--focus); outline-offset: 2px; }
.segmented-sm label { padding: .375rem .875rem; font-size: .875rem; }
.test-choice .segmented label { gap: .3em; }

/* ---------- Built around the test ahead ---------- */
.test-choice { margin-bottom: 1.5rem; }
.test-sheet { padding: 2.25rem 2.5rem 2rem; }
@supports selector(:has(*)) {
  .test-panel { display: none; }
  .test-demo:has(#t-nsw:checked) [data-test="nsw"],
  .test-demo:has(#t-acer:checked) [data-test="acer"],
  .test-demo:has(#t-oc:checked) [data-test="oc"] { display: block; }
}
@supports not selector(:has(*)) {
  .test-choice { display: none; }
  .test-panel + .test-panel { margin-top: 2.5rem; padding-top: 2.5rem; border-top: 1px solid var(--line); }
}
.coverage .label { margin-bottom: .75rem; }
.cover-bar { list-style: none; display: grid; gap: .5rem; }
.cover-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cover-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cover-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.cover-bar li {
  display: flex; flex-direction: column; justify-content: space-between; gap: .5rem;
  min-height: 5.25rem; padding: .875rem 1rem .75rem;
  border-top: .25rem solid var(--ink); border-radius: .25rem .25rem .625rem .625rem; background: var(--paper);
}
.cover-name { color: var(--ink); font-size: .9375rem; font-weight: 650; line-height: 1.3; }
.cover-bar.cover-plain li { min-height: 0; border-top-width: 2px; }
.cover-weight { font: 400 1.625rem/1 var(--serif); color: var(--ink); }

.path { list-style: none; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .9fr) minmax(0, 1.1fr); gap: 3rem; margin-top: 2.25rem; }
.path-step { position: relative; }
.path-step + .path-step::before {
  content: ""; position: absolute; left: -2.125rem; top: .6875rem; width: 1.25rem; border-top: 1.5px solid var(--line-strong);
}
.path-step + .path-step::after {
  content: ""; position: absolute; left: -1.25rem; top: .4375rem; width: .5rem; height: .5rem;
  border-top: 1.5px solid var(--line-strong); border-right: 1.5px solid var(--line-strong); transform: rotate(45deg);
}
.path-label { margin-bottom: .625rem; color: var(--ink); font-size: .875rem; font-weight: 700; line-height: 1.35; }
.path-label span { color: var(--muted); font-weight: 500; }
.path-label span::before { content: "· "; }
.path-q {
  padding: 1rem 1.125rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper);
  font: 400 1.1875rem/1.45 var(--serif); color: var(--ink);
}
.nums { display: block; margin-top: .375rem; font: 650 1.25rem/1.4 var(--sans); letter-spacing: .04em; }
.path-title { font: 400 1.3125rem/1.3 var(--serif); color: var(--ink); }
.path-note { margin-top: .375rem; color: var(--muted); font-size: .9375rem; line-height: 1.5; }
.lesson-parts { list-style: none; margin-top: .5rem; font-size: .9375rem; line-height: 1.45; }
.lesson-parts li { position: relative; padding: .3125rem 0 .3125rem 1.375rem; color: var(--text); }
.lesson-parts li::before {
  content: ""; position: absolute; left: .25rem; top: .84rem; width: .3125rem; height: .3125rem;
  border-radius: 50%; background: var(--ink);
}
.foundations {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: .25rem .75rem; margin-top: 2.25rem;
  padding: 1rem 1.25rem; border: 1.5px dashed var(--line-mid); border-radius: var(--radius);
  color: var(--text); font-size: .9375rem;
}
.foundations-tag { color: var(--ink); font-weight: 700; }

/* ---------- Plan ---------- */
.split { display: grid; grid-template-columns: minmax(0, 23rem) minmax(0, 1fr); gap: 4rem; align-items: start; }
.ticks { list-style: none; margin-top: 1.75rem; }
.ticks li { position: relative; padding: .4375rem 0 .4375rem 2rem; color: var(--ink); line-height: 1.45; }
.ticks li::after {
  content: ""; position: absolute; left: .4375rem; top: .78rem; width: .375rem; height: .625rem;
  border-right: 2px solid var(--ink); border-bottom: 2px solid var(--ink); transform: rotate(45deg);
}
.plan-sheet { padding: 1.75rem 2rem 2rem; }
.plan-top {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 1rem 1.5rem;
  margin-bottom: 1.5rem; padding-bottom: 1.25rem; border-bottom: 1px solid var(--line);
}
.time-choice legend { float: left; width: 100%; margin-bottom: .375rem; padding: 0; }
.time-choice .segmented { clear: both; }
.plan-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.12fr); gap: 2rem; }
.focus-list { list-style: none; margin-top: .5rem; }
.focus-list li {
  display: grid; grid-template-columns: 1.375rem minmax(0, 1fr) auto; gap: .75rem; align-items: center;
  padding: .75rem 0; border-bottom: 1px solid var(--line);
}
.focus-list .n { justify-self: center; transition: box-shadow .3s ease, background-color .3s ease, border-color .3s ease; }
.focus-list li[data-focus="true"] .n { box-shadow: 0 0 0 .1875rem var(--surface), 0 0 0 .34375rem var(--accent); }
.skill { display: flex; flex-direction: column; min-width: 0; }
.skill-name { color: var(--ink); font-size: .9375rem; font-weight: 650; line-height: 1.3; }
.skill-sec { color: var(--muted); font-size: .8125rem; line-height: 1.35; }
.state { padding: .1875rem .5625rem; border-radius: 999px; font-size: .8125rem; font-weight: 650; line-height: 1.3; white-space: nowrap; }
[data-state="need"] .state { background: var(--need-soft); color: var(--need); }
[data-state="dev"] .state { background: var(--dev-soft); color: var(--dev-text); }
[data-state="strong"] .state { background: var(--strong-soft); color: var(--strong); }
.activity { display: flex; align-items: flex-start; gap: .5rem; margin-top: 1rem; color: var(--text); font-size: .875rem; line-height: 1.45; }
.activity-dot { flex: none; width: .5rem; height: .5rem; margin-top: .375rem; border-radius: 50%; background: var(--line-strong); }
[data-done="true"] .activity-dot { background: var(--strong); }
.activity-shift { display: none; align-items: center; gap: .25rem; flex: none; margin-top: .125rem; }
.activity-shift .n { width: .875rem; height: .875rem; }
.activity-shift .i { width: .875rem; height: .875rem; color: var(--muted); }
[data-done="true"] .activity-shift { display: inline-flex; }
[data-done="true"] .activity-dot { display: none; }
.plan-next {
  padding: 1.25rem 1.375rem 1.375rem; border: 1px solid var(--line); border-radius: .875rem; background: var(--paper);
}
.plan-next .time-choice { margin-bottom: 1.125rem; }
.plan-next .steps { border-top-color: var(--line-mid); }
.plan-next .steps li { border-bottom-color: var(--line-mid); }
.plan-actions, .demo-actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1.25rem; }
.is-changed { animation: settle .6s ease-out; }
@keyframes settle { from { background-color: var(--accent-soft); } to { background-color: transparent; } }

/* ---------- Help ---------- */
.help-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); gap: 2rem; align-items: start; }
.tutor-sheet, .writing-sheet, .child-sheet, .parent-sheet { padding: 1.75rem 2rem 2rem; }
.demo-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: .75rem 1rem; margin-bottom: 1.25rem; }
.demo-head h3 { font: 400 1.4375rem/1.25 var(--serif); color: var(--ink); }
.chip {
  padding: .25rem .75rem; border: 1px solid var(--line); border-radius: 999px; background: var(--paper);
  color: var(--muted); font-size: .8125rem; font-weight: 600; line-height: 1.4;
}
.tutor-q, .writing-prompt { margin-bottom: 1rem; color: var(--ink); line-height: 1.5; }
.tutor-q .label, .writing-prompt .label { display: block; margin-bottom: .125rem; }

.bar-model { margin-bottom: 1.25rem; padding: 1rem 1.125rem .875rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.bar-row { display: grid; grid-template-columns: 3rem minmax(0, 1fr) 4.25rem; gap: .75rem; align-items: center; margin-bottom: .5rem; }
.bar-name, .bar-val { color: var(--ink); font-size: .875rem; font-weight: 650; }
.bar-val { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.bar { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 2px; }
.bar i { height: 1.375rem; border-radius: 3px; animation: pop .3s ease-out; }
.bar-flour i { background: #e6d6b5; border: 1px solid #a8916a; }
.bar-milk i { background: #c9d6ea; border: 1px solid #7486a8; }
[data-scale="1"] .bar-flour i:nth-child(n+3), [data-scale="1"] .bar-milk i:nth-child(n+4),
[data-scale="2"] .bar-flour i:nth-child(n+5), [data-scale="2"] .bar-milk i:nth-child(n+7) { display: none; }
@keyframes pop { from { transform: scaleX(.4); opacity: .3; } to { transform: none; opacity: 1; } }
.bar-caption { margin-top: .25rem; color: var(--text); font-size: .875rem; line-height: 1.45; }

.tutor-log { list-style: none; display: flex; flex-direction: column; gap: .75rem; }
.turn { max-width: 88%; padding: .75rem 1rem; border-radius: 1rem; font-size: .9375rem; line-height: 1.5; color: var(--ink); }
.turn p { margin: 0; }
.who { display: flex; align-items: center; gap: .5rem; margin-bottom: .25rem; color: var(--muted); font-size: .75rem; font-weight: 700; letter-spacing: .02em; }
.turn-child { align-self: flex-end; background: var(--paper-2); border-bottom-right-radius: .25rem; }
.turn-tutor { align-self: flex-start; background: var(--surface); border: 1px solid var(--line-mid); border-bottom-left-radius: .25rem; }
.voice { display: inline-flex; align-items: center; gap: .25rem; font-weight: 600; letter-spacing: 0; }
.voice .i { width: .875rem; height: .875rem; }
.turn.is-new { animation: rise .35s ease-out; }
@keyframes rise { from { opacity: 0; transform: translateY(.5rem); } to { opacity: 1; transform: none; } }

.criteria { display: flex; flex-wrap: wrap; align-items: baseline; gap: .25rem .875rem; margin-bottom: 1rem; color: var(--muted); font-size: .875rem; line-height: 1.5; }
.criteria-k { font-weight: 600; }
.criteria .is-active { color: var(--ink); font-weight: 650; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: .3em; }
.draft, .revision { padding: 1rem 1.125rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.draft-text { margin-top: .375rem; font: 400 1.0625rem/1.6 var(--serif); color: var(--ink); }
mark { padding: 0 .1em; background: var(--need-soft); color: inherit; box-shadow: inset 0 -2px 0 var(--need); }
.feedback { margin: 1rem 0; padding: 1rem 1.125rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.feedback p:last-child { margin-top: .375rem; color: var(--ink); font-size: .9375rem; line-height: 1.55; }
.revision { border-color: #b9dccb; background: var(--surface); }
.js .revision:not(.is-shown) { display: none; }
.revision.is-shown { animation: rise .35s ease-out; }
.revision-note { display: flex; align-items: center; gap: .375rem; margin-top: .75rem; color: var(--strong); font-size: .875rem; font-weight: 650; }

/* ---------- Motivation and visibility ---------- */
.family-grid { display: grid; grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr); gap: 2rem; align-items: start; }
.coins {
  display: inline-flex; align-items: center; gap: .375rem; padding: .25rem .75rem .25rem .5rem;
  border: 1px solid #ecd9a6; border-radius: 999px; background: #fff8e6;
  color: var(--ink); font-size: 1.0625rem; font-weight: 700; font-variant-numeric: tabular-nums;
}
.coin { width: 1.25rem; height: 1.25rem; }
.coins.is-changed { animation: glow 1s ease-out; }
@keyframes glow { from { box-shadow: 0 0 0 .375rem rgba(242, 196, 90, .55); } to { box-shadow: 0 0 0 0 rgba(242, 196, 90, 0); } }
.quest {
  display: grid; grid-template-columns: 5rem minmax(0, 1fr); gap: 1.25rem; align-items: center;
  padding: 1.25rem; border: 1px solid var(--line); border-radius: .875rem; background: var(--paper);
}
.avatar svg { width: 5rem; height: 5rem; }
.avatar-hat { opacity: 0; transition: opacity .4s ease, transform .4s ease; transform: translateY(-.375rem); }
.avatar[data-reward="hat"][data-unlocked="true"] .avatar-hat, .avatar[data-hat="owned"] .avatar-hat { opacity: 1; transform: none; }
.quest-title { margin: .25rem 0 .75rem; font: 400 1.375rem/1.25 var(--serif); color: var(--ink); }
.quest-progress { list-style: none; display: flex; gap: .375rem; }
.quest-progress li { flex: 1; height: .625rem; border: 1.5px solid var(--line-strong); border-radius: 999px; background: var(--surface); }
.quest-progress li.done { border-color: var(--ink); background: var(--ink); }
.quest-progress li.is-next { border-color: var(--accent); border-style: dashed; }
.quest-count { margin-top: .5rem; color: var(--ink); font-size: .875rem; font-weight: 650; }
.quest-reward-line { margin-top: .25rem; color: var(--text); font-size: .875rem; line-height: 1.45; }
#quest-reward { color: var(--ink); font-weight: 650; }
.child-facts { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; margin-top: 1rem; }
.child-facts li { display: flex; flex-direction: column; gap: .125rem; padding: .75rem 1rem; border: 1px solid var(--line); border-radius: var(--radius); }
.fact-k { color: var(--muted); font-size: .8125rem; font-weight: 600; }
.fact-v { color: var(--ink); font-weight: 650; line-height: 1.35; }
.band-chip { color: var(--ink); }
.quest-done {
  display: flex; align-items: center; gap: .5rem; margin-top: 1rem; padding: .75rem 1rem;
  border-radius: var(--radius); background: var(--strong-soft); color: var(--strong); font-size: .9375rem; font-weight: 650; line-height: 1.4;
}
.quest-done .i { width: 1.25rem; height: 1.25rem; }

.parent-top { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 1rem; margin-bottom: 1.25rem; }
.goal-note {
  display: flex; align-items: flex-start; gap: .5rem; margin-top: .875rem;
  color: var(--ink); font-size: .875rem; font-weight: 600; line-height: 1.45;
}
.goal-note .i { flex: none; width: 1.125rem; height: 1.125rem; margin-top: .0625rem; color: var(--strong); }
.score, .compare { padding: 1rem 1.125rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.score-v, .compare-v { margin: .25rem 0 .375rem; font: 400 2rem/1.1 var(--serif); color: var(--ink); }
.score-trend { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; color: var(--strong); font-size: .8125rem; font-weight: 650; }
.score-note { margin-top: .25rem; color: var(--muted); font-size: .8125rem; }
.spark { width: 3rem; height: 1.125rem; }
.compare-cohort { color: var(--muted); font-size: .8125rem; line-height: 1.45; }
.sections { list-style: none; margin-bottom: 1rem; }
.sections li { display: grid; grid-template-columns: minmax(0, 11.5rem) minmax(0, 1fr) 2.75rem; gap: .75rem; align-items: center; padding: .375rem 0; font-size: .875rem; }
.sec-name { color: var(--ink); font-weight: 600; line-height: 1.3; }
.sec-bar { height: .5rem; overflow: hidden; border-radius: 999px; background: var(--paper-2); }
.sec-bar i { display: block; height: 100%; border-radius: inherit; background: var(--ink); }
.w78 { width: 78%; } .w71 { width: 71%; } .w74 { width: 74%; } .w66 { width: 66%; }
.sec-v { color: var(--ink); font-weight: 650; text-align: right; font-variant-numeric: tabular-nums; }
.sg { margin-bottom: 1.25rem; color: var(--text); font-size: .875rem; line-height: 1.55; }
.sg strong { color: var(--ink); }
.goal-controls { padding-top: 1.125rem; border-top: 1px solid var(--line); }
.controls-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; margin-top: .625rem; }
.control { display: flex; flex-direction: column; gap: .375rem; color: var(--ink); font-size: .8125rem; font-weight: 600; }
select {
  width: 100%; min-height: 2.75rem; padding: .5rem 2.25rem .5rem .75rem;
  border: 1.5px solid var(--line-strong); border-radius: .625rem;
  background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%23152542' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right .75rem center / .75rem;
  color: var(--ink); font-size: .9375rem; font-weight: 500; line-height: 1.3;
  -webkit-appearance: none; appearance: none; cursor: pointer;
}
select:hover { border-color: var(--ink); }

.extras { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem; margin-top: 1rem; padding-top: 2rem; border-top: 1px solid var(--line); }
.extras li { color: var(--text); font-size: .9375rem; line-height: 1.55; }
.extra-k { display: block; margin-bottom: .25rem; color: var(--ink); font-weight: 700; }

/* ---------- Family experiences ---------- */
.quotes { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2.5rem; }
.quote { display: flex; flex-direction: column; justify-content: space-between; gap: 1.5rem; padding-top: 1.5rem; border-top: 2px solid var(--ink); }
.quote blockquote p { font: 400 1.1875rem/1.55 var(--serif); color: var(--ink); }
.quote-by { display: flex; align-items: center; gap: .75rem; font-size: .875rem; line-height: 1.4; }
.quote-by > span:last-child { display: flex; flex-direction: column; color: var(--muted); }
.quote-by strong { color: var(--ink); font-size: .9375rem; }
.mono {
  display: grid; place-items: center; flex: none; width: 2.5rem; height: 2.5rem; border-radius: 50%;
  background: var(--surface); border: 1px solid var(--line-mid); color: var(--ink); font: 400 1.125rem/1 var(--serif);
}

/* ---------- FAQ ---------- */
.faq-wrap { display: grid; grid-template-columns: minmax(0, 21rem) minmax(0, 1fr); gap: 4rem; align-items: start; }
.faq details { border-bottom: 1px solid var(--line-mid); }
.faq details:first-child { border-top: 1px solid var(--line-mid); }
.faq summary {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  min-height: 2.75rem; padding: 1.125rem 0; list-style: none; cursor: pointer;
  color: var(--ink); font-size: 1.0625rem; font-weight: 650; line-height: 1.4;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: .625rem; height: .625rem; margin-right: .375rem;
  border-right: 2px solid var(--ink); border-bottom: 2px solid var(--ink);
  transform: translateY(-25%) rotate(45deg); transition: transform .2s ease;
}
.faq details[open] summary::after { transform: translateY(15%) rotate(-135deg); }
.faq summary:hover { color: var(--accent-deep); }
.faq details p { max-width: 40rem; padding-bottom: 1.25rem; color: var(--text); line-height: 1.6; }

/* ---------- Final invitation and footer ---------- */
.final { padding: 5.5rem 0; background: var(--ink); color: var(--on-ink); }
.final-inner { max-width: 46rem; text-align: center; }
.final h2 { color: #fff; }
.final p { max-width: 34rem; margin: 1rem auto 0; font-size: 1.1875rem; line-height: 1.55; }
.final .actions { justify-content: center; }
.site-footer { background: var(--footer); color: var(--on-ink); font-size: .9375rem; }
.footer-inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 1.5rem 3rem; padding-top: 3rem; padding-bottom: 2.5rem; }
.brand-light { color: #fff; }
.footer-brand p { margin-top: .5rem; max-width: 26rem; line-height: 1.5; }
.footer-nav { display: flex; flex-wrap: wrap; align-items: flex-start; column-gap: 1.5rem; }
.footer-nav a { display: inline-flex; align-items: center; justify-content: center; min-width: 2.75rem; min-height: 2.75rem; color: #e8ecf5; text-decoration: none; }
.footer-nav a:hover { text-decoration: underline; text-underline-offset: .25em; }
.footer-tests { grid-column: 1 / -1; font-size: .875rem; }
.footer-legal { grid-column: 1 / -1; padding-top: 1.5rem; border-top: 1px solid rgba(255, 255, 255, .14); font-size: .8125rem; line-height: 1.5; }

/* ---------- Responsive ---------- */
@media (min-width: 64em) {
  /* The feature notes fill the space under Mia's card beside the taller parent view. */
  .family-grid { grid-template-areas: "child parent" "extras parent"; grid-template-rows: auto 1fr; }
  .child-sheet { grid-area: child; }
  .parent-sheet { grid-area: parent; }
  .extras { grid-area: extras; align-self: start; grid-template-columns: minmax(0, 1fr); gap: 1rem; margin-top: 0; padding: 1.5rem .25rem 0; }
}

@media (min-width: 64em) and (max-width: 75em) {
  /* Small laptops and landscape tablets: the hero visual stacks so its notes keep a readable width. */
  .hero-visual { grid-template-columns: minmax(0, 1fr); grid-template-areas: "nmap" "sheet" "ncard" "card"; }
  .note-map { justify-self: start; margin: 0 0 .625rem; }
  .note-card {
    justify-self: start; align-self: auto; align-items: center; flex-direction: row; text-align: left;
    max-width: 48%; min-height: 5rem; margin: 0; padding: .75rem 0;
  }
  .note-card .note-dot { margin-top: 0; }
  .next-card { margin-top: 0; }
  /* The plan sheet is narrow beside its copy here: the focus list sits above the next session. */
  .plan-grid { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; }
}

@media (max-width: 75em) {
  .hero-grid { grid-template-columns: minmax(0, 26rem) minmax(0, 1fr); gap: 3rem; }
  .map-sheet { margin-right: 0; }
  .map-row { grid-template-columns: 10rem minmax(0, 1fr); }
}

@media (max-width: 63.99em) {
  :root { --gutter: 2rem; }
  .hero { padding: 3rem 0 5rem; }
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 3.5rem; }
  .hero-copy { max-width: 40rem; }
  .hero-visual { max-width: 42.5rem; }
  .map-sheet { margin-right: 3rem; }
  .split, .faq-wrap { grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }
  .split-copy { max-width: 42rem; }
  .help-grid, .family-grid { grid-template-columns: minmax(0, 1fr); }
  .help-grid > *, .family-grid > * { max-width: 42.5rem; }
  .path { grid-template-columns: minmax(0, 1fr); gap: 2.25rem; }
  .path-step + .path-step::before { left: .75rem; top: -1.75rem; width: 0; height: 1.25rem; border-top: 0; border-left: 1.5px solid var(--line-strong); }
  .path-step + .path-step::after { left: .53rem; top: -.75rem; transform: rotate(135deg); }
  .quotes { grid-template-columns: minmax(0, 1fr); gap: 2rem; max-width: 42rem; }
  .why-head { margin: 0 0 2.5rem; text-align: left; }
  .why-route { grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }
  .why-route::before { display: none; }
  .why-item { display: grid; grid-template-columns: 4rem minmax(0, 1fr); column-gap: 1.25rem; align-items: normal; text-align: left; }
  .why-item:not(:last-child)::after {
    content: ""; position: absolute; left: 2rem; top: 4.75rem; bottom: -1.75rem;
    border-left: 1.5px dashed var(--line-mid);
  }
  .why-icon { grid-row: 1 / span 3; width: 4rem; height: 4rem; margin: 0; }
  .why-icon svg { width: 2.5rem; height: 2.5rem; }
  .why-item h3 { font-size: 1.375rem; align-self: center; }
  .why-item p { max-width: 36rem; margin: .5rem 0 0; }
  .why-item .router { margin-top: .25rem; justify-self: start; }
}

@media (max-width: 47.99em) {
  :root { --gutter: 1.25rem; }
  body { font-size: 1rem; }
  .site-header { top: calc(-1 * var(--util-h, 2.75rem)); }
  .header-inner {
    display: grid; grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas: "util util" "brand cta"; gap: 0 .75rem; min-height: 0;
  }
  .site-nav {
    grid-area: util; justify-content: flex-start; flex-wrap: wrap; gap: 0 .25rem; margin: 0 calc(-1 * var(--gutter));
    padding: 0 calc(var(--gutter) - .5rem); border-bottom: 1px solid var(--line); min-height: 2.75rem;
  }
  .site-nav a { padding: .375rem .5rem; font-size: .875rem; }
  .site-nav a[data-link="login"] { margin-left: auto; }
  .site-nav a[data-link="login"]::before { display: none; }
  .brand { grid-area: brand; min-width: 0; min-height: 4rem; padding-block: .5rem; }
  .wordmark { white-space: normal; }
  .header-cta { grid-area: cta; }

  .hero { padding: 2rem 0 4rem; }
  .hero-grid { gap: 2.75rem; }
  .hero h1 { margin: 1rem 0 1.25rem; }
  .lead { font-size: 1.125rem; }
  .actions { margin-top: 1.625rem; }
  .actions .btn { flex: 1 1 auto; }
  .hero-tests { margin-top: 1.25rem; column-gap: 1rem; }

  .hero-visual {
    --drop: 7.5rem;
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "nmap" "sheet" "ncard" "card";
  }
  .hero-visual::before { inset: -1.5rem calc(-1 * var(--gutter)); }
  .note-map { justify-self: start; margin: 0 0 .625rem; }
  .note-card {
    justify-self: start; align-self: auto; align-items: center; flex-direction: row; text-align: left;
    max-width: 48%; min-height: 5rem; margin: 0; padding: .75rem 0;
  }
  .note-card .note-dot { margin-top: 0; }
  .map-sheet { margin-right: 0; padding: 1.25rem 1.25rem 2.5rem; }
  .sheet-head { margin-bottom: .5rem; }
  .map-row { grid-template-columns: minmax(0, 1fr); padding: .375rem 0 0; min-height: 0; }
  .row-name { font-size: .875rem; }
  .next-card { margin-top: 0; padding: 1.25rem 1.25rem 1.125rem; }

  .why { padding: 4.5rem 0; }

  .band { padding: 4.5rem 0; }
  .section-head { margin-bottom: 2rem; }
  .standfirst { font-size: 1.0625rem; }
  .test-sheet, .plan-sheet, .tutor-sheet, .writing-sheet, .child-sheet, .parent-sheet { padding: 1.25rem; }
  .segmented { display: flex; }
  .test-choice .segmented { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .test-choice .segmented label { flex-direction: column; gap: 0; justify-content: center; padding: .4375rem .375rem; text-align: center; }
  .seg-name { font-size: .9375rem; }
  .seg-kind { font-size: .75rem; font-weight: 560; opacity: .82; }
  .cover-3, .cover-4, .cover-5 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cover-3 li:first-child, .cover-5 li:last-child { grid-column: 1 / -1; }
  .cover-bar li { min-height: 4.5rem; }
  .plan-grid { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; }
  .plan-top { align-items: flex-start; }
  .time-choice { width: 100%; }
  .time-choice label { flex: 1 1 auto; justify-content: center; }
  .turn { max-width: 94%; }
  .quest { grid-template-columns: minmax(0, 1fr); gap: .75rem; }
  .avatar svg { width: 4rem; height: 4rem; }
  .parent-top, .controls-row { grid-template-columns: minmax(0, 1fr); }
  .sections li { grid-template-columns: minmax(0, 1fr) 2.75rem; row-gap: .25rem; }
  .sec-bar { grid-column: 1 / -1; grid-row: 2; }
  .extras { grid-template-columns: minmax(0, 1fr); gap: 1.25rem; margin-top: .5rem; }
  .final { padding: 4.5rem 0; }
  .final .actions .btn { flex: 1 1 100%; }
  .final .actions .btn-ghost-light { border-color: transparent; text-decoration: underline; text-underline-offset: .25em; }
  .footer-inner { grid-template-columns: minmax(0, 1fr); }
  .cover-plain { align-items: start; }
}

/* Portrait phones: keep the bar model in view while the conversation grows. Not on short
   (landscape) screens or at very large text, where it would cover too much of the page. */
@media (max-width: 47.99em) and (min-height: 36em) {
  .bar-model { position: sticky; top: var(--sticky-h, 4rem); z-index: 2; box-shadow: 0 .5rem 1rem -.75rem rgba(21, 37, 66, .35); }
  .bar-model::before { content: ""; position: absolute; left: -1px; right: -1px; bottom: 100%; height: .5rem; background: var(--surface); }
  /* Focus moving back to the tutor's buttons stops below the pinned bar model, not under it. */
  .tutor-sheet .demo-actions .btn { scroll-margin-top: calc(var(--bar-h, 8rem) + .5rem); }
}

@media (max-width: 22.4375em) {
  :root { --gutter: 1rem; }
  .wordmark { font-size: 1rem; }
  .brand { gap: .5rem; }
  .brand-mark { width: 1.75rem; height: 1.75rem; }
  .header-cta { padding-inline: .875rem; }
  .site-nav a { padding-inline: .375rem; }
  .bar-row { grid-template-columns: 2.75rem minmax(0, 1fr) 3.75rem; gap: .5rem; }
  .quest { grid-template-columns: minmax(0, 1fr); }
  .child-facts { grid-template-columns: minmax(0, 1fr); }
  .cover-bar li { padding-inline: .625rem; }
  .cover-name { font-size: .875rem; }
}

/* Very narrow or very large text (e.g. 200% text on a phone): stack the header and
   choices, and let the taller header scroll away rather than cover the page. */
@media (max-width: 19em) {
  .site-header { position: relative; top: 0; }
  .header-inner { grid-template-columns: minmax(0, 1fr); grid-template-areas: "util" "brand" "cta"; }
  .header-cta { justify-self: start; margin-bottom: .75rem; }
  .test-choice .segmented { grid-template-columns: minmax(0, 1fr); }
  .test-choice .segmented label { flex-direction: row; flex-wrap: wrap; gap: 0 .3em; }
  .seg-name, .seg-kind { font-size: .9375rem; }
  .bar-model { position: static; box-shadow: none; }
  .bar-model::before { content: none; }
  /* Large text on a phone: the map label and its note keep to the space left of the coach's line. */
  .chosen-label { font-size: .6875rem; }
  .note-card { max-width: var(--note-room, 48%); }
  .note-card .note-dot { display: none; }
  /* Whole words on every line: less nested padding, and secondary details move under their text. */
  h2 { font-size: 1.625rem; }
  .test-sheet, .plan-sheet, .tutor-sheet, .writing-sheet, .child-sheet, .parent-sheet, .next-card, .map-sheet { padding-inline: 1rem; }
  .plan-next, .score, .compare { padding-inline: .5rem; }
  .steps li, .focus-list li { grid-template-columns: 1.5rem minmax(0, 1fr); gap: .25rem .5rem; }
  .steps .mins, .focus-list .state { grid-column: 2; justify-self: start; }
  .cover-3, .cover-4, .cover-5 { grid-template-columns: minmax(0, 1fr); }
  .cover-3 li:first-child, .cover-5 li:last-child { grid-column: auto; }
  .why-item { grid-template-columns: minmax(0, 1fr); }
  .why-item:not(:last-child)::after { content: none; }
  .why-icon { grid-row: auto; width: 3rem; height: 3rem; margin-bottom: .75rem; }
  .why-icon svg { width: 2rem; height: 2rem; }
  .score-v, .compare-v { font-size: 1.375rem; }
  .sections li { grid-template-columns: minmax(0, 1fr) auto; }
  .sec-name { grid-column: 1 / -1; }
  .sec-bar { grid-column: 1; grid-row: 2; }
  .sec-v { grid-row: 2; }
  .state { white-space: normal; }
  .bar-row { grid-template-columns: minmax(0, 1fr) auto; row-gap: .25rem; }
  .bar-row .bar { grid-column: 1 / -1; grid-row: 2; }
}

/* Large text on the narrowest phones (about 320px at 200% text): the same layout with smaller display
   type and thinner frames, so long words keep whole. */
@media (max-width: 12em) {
  :root { --gutter: .5rem; }
  .hero h1 { font-size: 1.75rem; }
  h2 { font-size: 1.375rem; }
  .test-sheet, .plan-sheet, .tutor-sheet, .writing-sheet, .child-sheet, .parent-sheet, .next-card, .map-sheet { padding-inline: .5rem; }
  .plan-next, .score, .compare { padding-inline: .25rem; }
  .ticks li { padding-left: 1.25rem; }
  .ticks li::after { left: .125rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

@media print {
  .site-header { position: static; }
  .js-only, .skip-link { display: none !important; }
}
