/* ============================================================
   HARVEST · SECTION-SPECIFIC STYLES
   Welcome screen, intake form, item types, audio prompts
   ============================================================ */

/* ─── Welcome / Landing ──────────────────────────────────────── */
.welcome-hero {
  text-align: center;
  padding: var(--sp-6) var(--sp-4);
}
.welcome-hero-brand {
  display: flex;
  justify-content: center;
  margin-bottom: var(--sp-4);
}
.welcome-hero-brand svg,
.welcome-hero-brand img { display: block; max-width: 100%; height: auto; }
.welcome-eyebrow {
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-weight: 700;
  letter-spacing: 0.24em;
  color: var(--fs-secondary);
  text-transform: uppercase;
  margin-bottom: var(--sp-2);
}
.welcome-product-name {
  font-family: var(--font-display);
  font-size: clamp(3rem, 7vw, 5.5rem);
  color: var(--green);
  margin-bottom: var(--sp-3);
  line-height: 1;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.welcome-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, var(--fs-6xl));
  color: var(--green);
  margin-bottom: var(--sp-3);
  line-height: 1.1;
}
.welcome-hero .subtitle {
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--fs-xl);
  font-weight: 400;
  color: var(--fs-secondary);
  margin-bottom: var(--sp-5);
}
.welcome-hero .lead {
  font-size: var(--fs-lg);
  color: var(--ink-soft);
  line-height: 1.65;
  max-width: 60ch;
  margin: 0 auto var(--sp-5) auto;
}
.welcome-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--sp-3);
  margin: var(--sp-5) 0;
}
.welcome-meta-item {
  background: var(--paper-warm);
  border-radius: var(--r-md);
  padding: var(--sp-3);
  text-align: center;
  border: 1px solid var(--paper-deep);
  transition: transform var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
}
.welcome-meta-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
  border-color: var(--gold);
}
.welcome-meta-icon {
  width: 32px;
  height: 32px;
  margin: 0 auto var(--sp-2) auto;
  color: var(--green-rich);
}
.welcome-meta-icon svg { width: 100%; height: 100%; }
.welcome-meta-label {
  font-size: var(--fs-xs);
  color: var(--ink-mute);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
}
.welcome-meta-value {
  font-weight: 600;
  color: var(--green);
  font-size: var(--fs-sm);
  margin-top: 2px;
}

/* ─── Sprint 2 P3-A: Roster + cohort dashboard ─── */
.roster .cohort-summary { margin-bottom: var(--sp-4); }
.roster .cohort-summary h3 { font-family: var(--font-display); color: var(--green); margin-bottom: var(--sp-2); }
.roster-tools { display: flex; gap: var(--sp-2); margin-bottom: var(--sp-3); }
.roster-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--paper-warm);
  border-radius: var(--r-md);
  overflow: hidden;
}
.roster-table th, .roster-table td {
  padding: 8px 12px;
  text-align: left;
  border-bottom: 1px solid var(--paper-deep);
  font-size: var(--fs-sm);
}
.roster-table th {
  background: var(--green);
  color: var(--paper);
  font-weight: 600;
  text-transform: uppercase;
  font-size: var(--fs-xs);
  letter-spacing: 0.05em;
}
.roster-name { font-weight: 600; color: var(--green); }
.status-pill {
  display: inline-block;
  padding: 2px 10px;
  border-radius: var(--r-pill);
  font-size: var(--fs-2xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.status-pill.status-completed   { background: var(--ok-pale);    color: var(--ok); }
.status-pill.status-in-progress { background: var(--warn-pale);  color: var(--ink-warn); }
.status-pill.status-paused      { background: var(--info-pale);  color: var(--info); }
.status-pill.status-unknown     { background: var(--paper-deep); color: var(--ink-mute); }

/* ─── Oral reading (Section C, rebuilt 2026-10-19) ─────────────────
   Replaces the stopwatch pop-up, which covered and blurred the passage
   on a tablet while the parent timed it. Now the passage IS the screen:
   the parent's helper bar stays in view as the page scrolls (sticky,
   solid, no backdrop, no blur), so text is scrolled past it, never
   hidden or blurred by it, and every word stays readable and tappable.
   The words are buttons that look like plain text until timing starts. */

/* .btn sets its own display, which beats the hidden attribute. */
.orf [hidden] { display: none !important; }

.orf-kid-line {
  font-family: var(--font-child);
  font-size: var(--fs-xl);
  color: var(--ink);
  text-align: center;
  margin: 0 0 var(--sp-3);
}

.orf-guide {
  background: var(--paper-warm);
  border-left: 4px solid var(--gold);
  border-radius: var(--r-md);
  padding: var(--sp-2) var(--sp-3);
  margin: 0 0 var(--sp-3);
  font-size: var(--fs-sm);
  color: var(--ink-soft);
}
.orf-guide summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--ink-warn);
  min-height: 32px;
  display: flex;
  align-items: center;
  list-style: none;
}
/* display:flex removes a summary's own arrow, so both fold-outs draw one. */
.orf-guide summary::-webkit-details-marker,
.orf-lookback summary::-webkit-details-marker { display: none; }
.orf-guide summary::before,
.orf-lookback summary::before {
  content: '';
  flex: none;
  width: 0;
  height: 0;
  margin-right: 0.55em;
  border-style: solid;
  border-width: 0.36em 0 0.36em 0.55em;
  border-color: transparent transparent transparent currentColor;
  transition: transform var(--t-fast) var(--ease);
}
.orf-guide[open] summary::before,
.orf-lookback[open] summary::before { transform: rotate(90deg); }
.orf-guide ol { margin: var(--sp-2) 0 var(--sp-2) 1.2em; padding: 0; }
.orf-guide li { margin-bottom: 4px; line-height: 1.5; color: var(--ink-soft); }
.orf-guide-note { font-size: var(--fs-xs); color: var(--ink-mute); margin: 0; }

.orf-bar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  background: var(--paper);
  border: 1.5px solid var(--paper-deep);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-md);
  padding: var(--sp-2) var(--sp-3);
  margin: 0 0 var(--sp-3);
}
.orf[data-orf-state="running"] .orf-bar { border-color: var(--green-mid); }
.orf[data-orf-state="stopped"] .orf-bar { border-color: var(--gold); }
.orf-bar-top {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  flex-wrap: wrap;
}
.orf-status {
  flex: 1 1 15rem;
  margin: 0;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--ink);
  line-height: 1.4;
}
.orf-time { display: flex; align-items: center; gap: var(--sp-2); }
.orf-clock {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  font-size: var(--fs-lg);
  color: var(--green);
  white-space: nowrap;
}
.orf-track {
  display: block;
  width: 72px;
  height: 6px;
  border-radius: var(--r-pill);
  background: var(--paper-deep);
  overflow: hidden;
}
.orf-track-fill {
  display: block;
  height: 100%;
  width: 0;
  background: var(--green-mid);
  transition: width 200ms linear;
}
.orf-tally { font-size: var(--fs-sm); font-weight: 600; color: var(--gold-rich); white-space: nowrap; }
.orf-summary { margin: 0; font-size: var(--fs-sm); color: var(--ink-soft); line-height: 1.45; }
.orf-summary-problem { color: var(--alert); font-weight: 600; }
.orf-modes {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  flex-wrap: wrap;
  font-size: var(--fs-sm);
}
.orf-modes-label { color: var(--ink-mute); }
.orf-mode-btn {
  padding: 6px 14px;
  min-height: 40px;
  border: 1.5px solid var(--paper-deep);
  border-radius: var(--r-pill);
  background: var(--paper-warm);
  color: var(--ink-soft);
  font-weight: 600;
  font-size: var(--fs-sm);
}
.orf-mode-btn[aria-pressed="true"] {
  background: var(--green-rich);
  border-color: var(--green-rich);
  color: var(--paper);
}
.orf-actions { display: flex; gap: var(--sp-2); flex-wrap: wrap; align-items: center; }
.orf-actions .btn { min-height: 44px; }

/* The passage. Each word is a button so the parent can tap it; it reads as plain text. */
.orf-passage { line-height: 2; }
.orf-passage p { margin-bottom: var(--sp-3); }
.orf-word {
  display: inline;
  font: inherit;
  line-height: inherit;
  color: inherit;
  letter-spacing: inherit;
  background: transparent;
  border: 0;
  border-radius: 6px;
  padding: 0 0.06em;
  margin: 0;
  cursor: default;
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
}
.orf-word:disabled { color: inherit; opacity: 1; cursor: default; }
.orf:not([data-orf-state="ready"]) .orf-word { cursor: pointer; }
.orf:not([data-orf-state="ready"]) .orf-word:active { background: var(--gold-pale); }
/* Read wrongly: a calm underline the parent can see, not a red cross a child reads as failing. */
.orf-word.is-wrong { background: var(--gold-pale); box-shadow: inset 0 -3px 0 var(--gold-rich); }
.orf-word.is-last { background: var(--ok-pale); box-shadow: 0 0 0 2px var(--green-rich); }
.orf-word.is-wrong.is-last { box-shadow: inset 0 -3px 0 var(--gold-rich), 0 0 0 2px var(--green-rich); }
/* Words after the last one read: not counted, and drawn as not counted. */
.orf-word.is-unread { opacity: 0.38; }
.orf-word:focus-visible { outline: 3px solid var(--gold); outline-offset: 1px; }
.orf-footer { display: flex; justify-content: center; margin-top: var(--sp-3); }

/* Looking back at the passage while answering (Grade 2 and up fold it away; K-1 keep it open).
   Opened, the passage scrolls inside its own box, so the question and its answers stay on screen. */
.orf-lookback { margin: 0 0 var(--sp-4); }
.orf-lookback summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--sec-c);
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  list-style: none;
  padding: 0 var(--sp-4);
  border: 1.5px solid var(--sec-c-pale);
  border-radius: var(--r-pill);
  background: var(--paper);
}
.orf-lookback summary:hover { background: var(--sec-c-pale); }
.orf-lookback .orf-reread {
  max-height: 34vh;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.orf-reread {
  font-size: var(--fs-lg);
  line-height: 1.7;
  padding: var(--sp-4);
  margin: var(--sp-2) 0 var(--sp-4);
}
.orf-reread h3 { font-size: var(--fs-xl); }

/* No passage today (a child not yet reading words). */
.orf-none .section-icon { color: var(--sec-c); }
.orf-none h2 { margin-bottom: var(--sp-4); }
.orf-none p { max-width: 46ch; margin: 0 auto; }

/* A phone: the bar must stay small, because every line it takes is a line of passage the child
   cannot see. The item padding goes (the stage already has its own), the clock leaves the stopped
   bar (the result line carries the time), and the two choices and two buttons share one row each. */
@media (max-width: 480px) {
  .orf.item-container { padding-left: 0; padding-right: 0; }
  .orf-bar { padding: var(--sp-2); gap: 6px; }
  .orf-bar-top { gap: 4px var(--sp-3); }
  .orf-status { flex-basis: 100%; }
  .orf[data-orf-state="stopped"] .orf-time { display: none; }
  .orf-modes-label { display: none; }
  .orf-mode-btn { min-height: 38px; padding: 4px 12px; }
  .orf-actions .btn { flex: 1 1 0; min-width: 0; padding-left: 10px; padding-right: 10px; }
  .orf-track { width: 56px; }
  .orf-passage { padding: var(--sp-4); }
  .orf-reread { padding: var(--sp-3); line-height: 1.55; }
  .orf-reread h3 { font-size: var(--fs-lg); margin-bottom: var(--sp-2); }
}

/* ─── SVG visual item rendering (Sprint 2 P1-A) ─── */
.harvest-shape, .harvest-coin, .harvest-clock, .harvest-matrix, .harvest-matrix-mini, .harvest-fraction, .harvest-tenframe {
  display: block;
  max-width: 100%;
  height: auto;
}
.harvest-coin-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  justify-content: center;
  align-items: center;
  padding: var(--sp-4);
  margin: var(--sp-3) auto var(--sp-4);
  background: var(--paper-warm);
  border-radius: var(--r-md);
  max-width: 500px;
  border: 1px dashed var(--paper-deep);
}

/* Shape-choice button: SVG shape + label below */
.shape-choice-btn, .clock-choice-btn, .matrix-choice-btn {
  display: flex !important;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: var(--sp-3);
}
.shape-choice-btn .harvest-shape,
.clock-choice-btn .harvest-clock {
  display: block;
}
.shape-choice-label, .clock-choice-label {
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  color: var(--ink-soft);
  font-weight: 600;
  margin-top: 4px;
}

/* Matrix puzzle layout */
.matrix-choices {
  grid-template-columns: repeat(4, 1fr) !important;
  max-width: 400px;
  margin: 0 auto !important;
}
@media (max-width: 480px) {
  .matrix-choices { grid-template-columns: repeat(2, 1fr) !important; }
}
.matrix-choice-btn {
  min-height: 84px;
}
.matrix-choice-btn svg { width: 64px; height: 64px; }

/* ─── Mode picker grid (Phase A — modular scope selection) ─── */
.welcome-section-title {
  font-family: var(--font-display);
  font-size: var(--fs-2xl);
  color: var(--green);
  text-align: center;
  margin-top: var(--sp-6);
  margin-bottom: var(--sp-2);
}
.welcome-section-blurb {
  text-align: center;
  color: var(--ink-soft);
  font-size: var(--fs-sm);
  margin-bottom: var(--sp-4);
  max-width: 60ch;
  margin-left: auto;
  margin-right: auto;
}
.mode-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--sp-3);
  margin: 0 auto var(--sp-5) auto;
  max-width: 1000px;
}
.mode-card {
  display: block;
  text-align: left;
  background: var(--paper);
  border: 2px solid var(--paper-deep);
  border-radius: var(--r-lg);
  padding: var(--sp-4);
  cursor: pointer;
  transition: transform var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.mode-card:hover {
  transform: translateY(-3px);
  border-color: var(--gold);
  box-shadow: var(--shadow-md);
}
.mode-card.selected {
  background: var(--ok-pale);
  border-color: var(--green-rich);
  box-shadow: var(--shadow-glow-green);
}
.mode-card.selected::after {
  content: '✓ Selected';
  display: block;
  margin-top: var(--sp-2);
  font-size: var(--fs-xs);
  color: var(--green-rich);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.mode-card .mode-icon {
  width: 36px;
  height: 36px;
  color: var(--green-rich);
  margin-bottom: var(--sp-2);
}
.mode-card .mode-icon svg { width: 100%; height: 100%; }
.mode-card.selected .mode-icon { color: var(--green); }
.mode-card .mode-label {
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  color: var(--green);
  font-weight: 600;
  margin-bottom: 2px;
}
.mode-card .mode-duration {
  font-size: var(--fs-xs);
  color: var(--gold-rich);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 700;
  margin-bottom: var(--sp-2);
}
.mode-card .mode-blurb {
  font-size: var(--fs-sm);
  color: var(--ink-soft);
  line-height: 1.45;
  margin-bottom: var(--sp-2);
}
.mode-card .mode-sections-tag {
  font-size: var(--fs-2xs);
  color: var(--ink-mute);
  font-family: var(--font-mono);
  margin-top: var(--sp-2);
  padding-top: var(--sp-2);
  border-top: 1px dashed var(--paper-deep);
}
.mode-card-custom {
  background: var(--gold-pale);
  border-style: dashed;
  border-color: var(--gold);
}
.mode-card-custom:hover { background: var(--paper-cream); }
.mode-card-custom .mode-icon { color: var(--gold-rich); }

.quickstart-banner {
  background: var(--warn-pale);
  border: 1.5px solid var(--gold);
  border-radius: var(--r-md);
  padding: var(--sp-3) var(--sp-4);
  margin: var(--sp-3) auto var(--sp-4) auto;
  max-width: 700px;
  text-align: center;
  font-size: var(--fs-sm);
  color: var(--ink-warn);
}
.quickstart-banner code {
  background: rgba(0, 0, 0, 0.05);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: var(--font-mono);
}

@media (max-width: 720px) {
  .mode-grid {
    grid-template-columns: 1fr;
  }
}

.welcome-action-row {
  display: flex;
  gap: var(--sp-3);
  justify-content: center;
  margin-top: var(--sp-5);
  flex-wrap: wrap;
}

.legal-notice {
  background: var(--green-glaze);
  border-radius: var(--r-md);
  padding: var(--sp-4);
  margin-top: var(--sp-5);
  text-align: left;
  font-size: var(--fs-sm);
  color: var(--ink-soft);
  line-height: 1.6;
}
.legal-notice strong { color: var(--green); }

/* ─── Intake Form Layout ─────────────────────────────────────── */
.intake-form {
  max-width: 720px;
  margin: 0 auto;
}
.intake-section {
  background: var(--paper-warm);
  border-radius: var(--r-lg);
  padding: var(--sp-5);
  margin-bottom: var(--sp-4);
  border: 1px solid var(--paper-deep);
}
.intake-section-title {
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  color: var(--green);
  margin-bottom: var(--sp-2);
  display: flex;
  align-items: center;
  gap: var(--sp-2);
}
.intake-section-meta {
  font-size: var(--fs-sm);
  color: var(--ink-mute);
  margin-bottom: var(--sp-4);
  font-style: italic;
}
.intake-section-num {
  background: var(--gold);
  color: var(--paper);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: var(--fs-xs);
  font-weight: 700;
}

/* ─── Signature Pad ──────────────────────────────────────────── */
.signature-block {
  background: var(--paper);
  border: 1.5px solid var(--paper-deep);
  border-radius: var(--r-md);
  padding: var(--sp-3);
}
.signature-canvas {
  display: block;
  width: 100%;
  height: 120px;
  background: var(--paper);
  border: 1px dashed var(--paper-deep);
  border-radius: var(--r-sm);
  cursor: crosshair;
  touch-action: none;
}
.signature-line {
  border-top: 1px solid var(--ink-mute);
  margin-top: 4px;
  font-size: var(--fs-xs);
  color: var(--ink-mute);
  padding-top: 4px;
  text-align: center;
  font-style: italic;
}
.signature-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: var(--sp-2);
  font-size: var(--fs-sm);
  color: var(--ink-mute);
}

/* ─── Section Letter Specific Backgrounds ────────────────────── */
.section-a .section-intro .section-letter { background: var(--sec-a); }
.section-b .section-intro .section-letter { background: var(--sec-b); }
.section-c .section-intro .section-letter { background: var(--sec-c); }
.section-d .section-intro .section-letter { background: var(--sec-d); }
.section-e .section-intro .section-letter { background: var(--sec-e); }
.section-f .section-intro .section-letter { background: var(--sec-f); }
.section-g .section-intro .section-letter { background: var(--sec-g); }

/* ─── Item Type: Phoneme/Sound ───────────────────────────────── */
.phoneme-display {
  text-align: center;
  margin: var(--sp-6) 0;
}
.phoneme-bubble {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, var(--gold-warm), var(--gold-rich));
  color: var(--paper);
  font-family: var(--font-child);
  font-size: var(--fs-5xl);
  font-weight: 700;
  box-shadow: var(--shadow-lg);
  margin-bottom: var(--sp-4);
}
.phoneme-play-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 10px 20px;
  background: var(--green);
  color: var(--paper);
  border-radius: var(--r-pill);
  font-size: var(--fs-base);
  font-weight: 600;
}
.phoneme-play-btn svg { width: 18px; height: 18px; }
.phoneme-play-btn:hover { background: var(--green-rich); }

/* ─── Word display (large reading text) ──────────────────────── */
.word-display-large {
  font-family: var(--font-child);
  font-size: clamp(3rem, 10vw, 7rem);
  text-align: center;
  color: var(--green);
  letter-spacing: 0.02em;
  margin: var(--sp-6) 0;
  line-height: 1.1;
}
.word-display-medium {
  font-family: var(--font-child);
  font-size: clamp(2rem, 6vw, 4rem);
  text-align: center;
  color: var(--green);
  margin: var(--sp-5) 0;
}

/* ─── Counting tap zone (syllables) ──────────────────────────── */
.tap-counter {
  text-align: center;
  margin: var(--sp-4) 0;
}
.tap-target {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: var(--gold-pale);
  border: 4px solid var(--gold);
  color: var(--gold-rich);
  font-family: var(--font-display);
  font-size: var(--fs-6xl);
  font-weight: 700;
  cursor: pointer;
  transition: all var(--t-fast) var(--ease);
  user-select: none;
}
.tap-target:hover { background: var(--gold-warm); transform: scale(1.02); }
.tap-target:active { transform: scale(0.96); background: var(--gold); color: var(--paper); }
.tap-label {
  font-size: var(--fs-base);
  color: var(--ink-soft);
  margin-top: var(--sp-3);
  font-style: italic;
}

/* ─── Dolch / Sight Word Display ─────────────────────────────── */
.sight-word-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: var(--sp-3);
  margin: var(--sp-5) 0;
}
.sight-word-card {
  background: var(--paper);
  border: 2px solid var(--paper-deep);
  border-radius: var(--r-md);
  padding: var(--sp-4);
  text-align: center;
  font-family: var(--font-child);
  font-size: var(--fs-2xl);
  color: var(--green);
  cursor: pointer;
  transition: all var(--t-fast) var(--ease);
}
.sight-word-card:hover { background: var(--paper-cream); border-color: var(--gold); }
.sight-word-card.correct { background: var(--ok-pale); border-color: var(--ok); }
.sight-word-card.incorrect { background: var(--alert-pale); border-color: var(--alert); }
.sight-word-card.skipped { background: var(--warn-pale); border-color: var(--warn); }

/* ─── Number Line ────────────────────────────────────────────── */
.number-line {
  position: relative;
  height: 90px;
  margin: var(--sp-5) 0;
  background: var(--paper-warm);
  border-radius: var(--r-md);
  padding: var(--sp-4);
}
.number-line-track {
  position: absolute;
  top: 50%;
  left: var(--sp-5);
  right: var(--sp-5);
  height: 4px;
  background: var(--green-mid);
  border-radius: 2px;
}
.number-line-tick {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}
.number-line-tick::before {
  content: '';
  width: 2px;
  height: 12px;
  background: var(--green-mid);
}
.number-line-label {
  font-family: var(--font-display);
  font-size: var(--fs-sm);
  color: var(--ink-soft);
  margin-top: 16px;
}
.number-line-marker {
  position: absolute;
  top: 30%;
  width: 28px;
  height: 28px;
  background: var(--gold);
  border: 3px solid var(--paper);
  border-radius: 50%;
  transform: translateX(-50%);
  cursor: grab;
  box-shadow: var(--shadow-md);
  z-index: 5;
}
.number-line-marker:active { cursor: grabbing; }

/* ─── Math operation display ─────────────────────────────────── */
.math-equation {
  font-family: var(--font-child);
  font-size: clamp(3rem, 8vw, 5rem);
  color: var(--green);
  text-align: center;
  margin: var(--sp-5) 0;
  letter-spacing: 0.05em;
  font-variant-numeric: tabular-nums;
}
.math-equation .op { color: var(--gold-rich); margin: 0 0.2em; }
.math-equation .blank {
  display: inline-block;
  min-width: 1.2em;
  border-bottom: 4px solid var(--gold);
  padding: 0 0.2em;
}
.math-stacked {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: clamp(2rem, 6vw, 3.5rem);
  color: var(--green);
  text-align: right;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}
.math-stacked-row { padding: 4px 12px; }
.math-stacked-line { border-bottom: 3px solid var(--ink); padding-bottom: 8px; }

/* ─── Math facts grid (fluency) ──────────────────────────────── */
.fluency-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: var(--sp-3);
}
.fluency-item {
  background: var(--paper-warm);
  border: 1.5px solid var(--paper-deep);
  border-radius: var(--r-md);
  padding: var(--sp-3);
  font-family: var(--font-child);
  font-size: var(--fs-2xl);
  text-align: center;
  color: var(--green);
}
.fluency-item input {
  width: 80px;
  text-align: center;
  font-size: inherit;
  font-family: inherit;
  border: 2px solid var(--paper-deep);
  border-radius: var(--r-sm);
  background: var(--paper);
  padding: 4px;
  color: var(--green);
}
.fluency-item.correct { background: var(--ok-pale); border-color: var(--ok); }
.fluency-item.incorrect { background: var(--alert-pale); border-color: var(--alert); }

/* ─── Shapes / Geometry ──────────────────────────────────────── */
.shape-display {
  display: flex;
  justify-content: center;
  margin: var(--sp-5) 0;
}
.shape-display svg {
  max-width: 280px;
  max-height: 280px;
}

/* ─── Money / Coin Display ───────────────────────────────────── */
.coin-display {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  justify-content: center;
  margin: var(--sp-4) 0;
}
.coin {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--fs-sm);
  box-shadow: var(--shadow-sm);
}
.coin.penny { background: #B87333; color: var(--paper); }
.coin.nickel { background: #C0C0C0; color: var(--ink); }
.coin.dime { width: 52px; height: 52px; background: #D4D4D4; color: var(--ink); font-size: var(--fs-xs); }
.coin.quarter { width: 72px; height: 72px; background: #C0C0C0; color: var(--ink); }
.coin.dollar {
  width: 96px; height: 56px; border-radius: 8px;
  background: #6E8B6E; color: var(--paper);
}

/* ─── Clock Face ─────────────────────────────────────────────── */
.clock-svg {
  display: block;
  margin: 0 auto var(--sp-4) auto;
  width: 200px;
  height: 200px;
}

/* ─── Matrix / Pattern Reasoning ─────────────────────────────── */
.matrix-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--sp-2);
  max-width: 360px;
  margin: var(--sp-5) auto;
}
.matrix-cell {
  background: var(--paper-warm);
  border: 2px solid var(--paper-deep);
  border-radius: var(--r-sm);
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: var(--fs-3xl);
  color: var(--green);
}
.matrix-cell.missing {
  background: var(--gold-pale);
  border-color: var(--gold);
  color: var(--gold-rich);
}
.matrix-cell svg { width: 60%; height: 60%; }

/* ─── Pause / Break Overlay ──────────────────────────────────── */
.pause-overlay {
  position: fixed;
  inset: 0;
  background: linear-gradient(180deg, rgba(244, 217, 184, 0.97), rgba(232, 197, 148, 0.97));
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: var(--sp-5);
  text-align: center;
}
.pause-overlay h2 {
  font-family: var(--font-display);
  font-size: var(--fs-5xl);
  color: var(--green);
  margin-bottom: var(--sp-3);
}
.pause-overlay p { font-size: var(--fs-lg); color: var(--ink-soft); max-width: 60ch; margin-bottom: var(--sp-5); }
.pause-icon {
  width: 120px;
  height: 120px;
  margin-bottom: var(--sp-5);
  color: var(--gold-rich);
}

/* ─── Section Transition ─────────────────────────────────────── */
.section-transition {
  text-align: center;
  padding: var(--sp-7) var(--sp-4);
}
.section-transition .check-icon {
  width: 96px;
  height: 96px;
  margin: 0 auto var(--sp-4) auto;
  background: var(--ok);
  color: var(--paper);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  animation: checkPop 600ms var(--ease-bounce);
}
.section-transition .check-icon svg { width: 48px; height: 48px; }
@keyframes checkPop {
  from { transform: scale(0); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

/* ─── Mobile tweaks ──────────────────────────────────────────── */
@media (max-width: 720px) {
  .word-display-large { font-size: clamp(2.5rem, 12vw, 5rem); }
  .math-equation { font-size: clamp(2rem, 10vw, 3.5rem); }
  .phoneme-bubble { width: 150px; height: 150px; font-size: var(--fs-4xl); }
  .tap-target { width: 150px; height: 150px; font-size: var(--fs-5xl); }
}
