:root {
  color-scheme: light;
  --canvas: #fcfcf9;
  --paper: #ffffff;
  --accent: #245b46;
  --accent-hover: #194333;
  --ink: #192621;
  --ink-secondary: #52625a;
  --ink-tertiary: #657169;
  --border: rgb(0 0 0 / 10%);
  --border-strong: rgb(0 0 0 / 18%);
  --fill-quiet: #f0f3ed;
  --fill-hover: #e9eee6;
  --fill-pressed: #e0e9dd;
  --error: #8a1c1c;
  /* Correctness, which is a different axis from selection. --fill-pressed is
     the pale green that says "you picked this"; these say "this is the key"
     and "this was your wrong answer", and a list carrying a verdict drops the
     selected fill so green has exactly one meaning on that screen. */
  --correct-fill: #e3efe6;
  --correct-edge: #245b46;
  --correct-ink: #17402e;
  --wrong-fill: #fbeae9;
  --wrong-edge: #8a1c1c;
  --wrong-ink: #7a1818;
  --radius: 8px;
  --content-width: 1320px;
  --reading-width: 720px;
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 16px;
  --space-4: 24px;
  --space-5: 32px;
  --space-6: 40px;
  --space-7: 48px;
  --space-8: 64px;
  --space-9: 80px;
  font-family: "Inter Variable", Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--canvas);
  color: var(--ink);
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background: var(--canvas);
  font-size: 17px;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
}

button,
input {
  font: inherit;
}

button {
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
input:focus-visible,
a:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  z-index: 10;
  top: var(--space-3);
  left: var(--space-3);
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
  border-radius: 6px;
  background: var(--ink);
  color: var(--canvas);
  font-weight: 600;
}

.skip-link:focus {
  width: auto;
  height: auto;
  padding: 10px 14px;
  margin: 0;
  overflow: visible;
  clip-path: none;
}

#app:focus {
  outline: none;
}

.masthead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  width: min(calc(100% - 112px), var(--content-width));
  margin: 0 auto;
  padding: var(--space-4) 0;
  border-bottom: 1px solid var(--border);
}

.signed-in-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--space-2) var(--space-3);
  width: min(calc(100% - 112px), var(--content-width));
  margin: var(--space-3) auto 0;
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--fill-quiet);
  color: var(--ink);
}

.signed-in-banner-text {
  margin: 0;
  font-weight: 600;
}

@media (max-width: 720px) {
  .signed-in-banner {
    width: calc(100% - 32px);
  }
}

.wordmark {
  font-size: 20px;
  font-weight: 650;
  letter-spacing: -0.025em;
}

.masthead-end {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--space-4);
}

.session-progress-control {
  max-width: 240px;
}

.session-progress-note {
  margin: var(--space-1) 0 0;
  color: var(--ink-secondary);
  font-size: 12px;
  line-height: 1.4;
}

.product-context {
  margin: 0;
  color: var(--ink-secondary);
  font-size: 15px;
}

#app {
  width: min(calc(100% - 112px), var(--content-width));
  margin: 0 auto;
  padding: var(--space-7) 0 var(--space-8);
}

.state-message,
.home,
.transition,
.results,
.daily-ready,
.daily-complete {
  max-width: var(--reading-width);
}

.eyebrow,
.question-count,
.result-domain,
.save-state {
  margin: 0;
  color: var(--ink-secondary);
  font-size: 14px;
  font-weight: 500;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1,
h2,
h3 {
  color: var(--ink);
  font-weight: 550;
  letter-spacing: -0.03em;
}

h1 {
  max-width: 15ch;
  margin: var(--space-3) 0 var(--space-4);
  font-size: clamp(36px, 4.3vw, 54px);
  line-height: 1.12;
}

.transition h1,
.daily-ready h1,
.daily-complete h1,
.results h1,
.dashboard h1 {
  max-width: 22ch;
}

h2 {
  margin: 0 0 var(--space-3);
  font-size: 28px;
  line-height: 1.16;
}

h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.3;
  letter-spacing: -0.015em;
}

.supporting-copy,
.intro-copy,
.transition-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  align-items: center;
  margin-top: var(--space-5);
}

.transition-copy,
.result-intro,
.next-task p,
.tutor-disclosure p,
.credit-rule {
  max-width: 60ch;
  margin: 0;
  color: var(--ink-secondary);
}

.intro-copy {
  font-size: 19px;
}

.home,
.transition,
.daily-ready,
.daily-complete,
.results,
.dashboard,
.state-message {
  margin-inline: auto;
}

.home {
  max-width: 840px;
}

.home .intro-copy {
  max-width: 52ch;
  margin-top: 0;
  color: var(--ink-secondary);
}

.home-duration {
  margin: var(--space-4) 0 var(--space-7);
  color: var(--ink);
  font-size: 18px;
  font-weight: 550;
  letter-spacing: -0.02em;
}

.home .primary-action {
  min-width: 220px;
}

.home .eyebrow {
  color: var(--accent);
}

.test-tools .text-action {
  min-height: 40px;
  padding: 6px;
  font-size: 14px;
}

.home-skills {
  margin-top: var(--space-8);
}

.home-skills h2 {
  margin: 0 0 var(--space-2);
  font-size: 22px;
}

.home-skill-section {
  margin-top: var(--space-5);
}

.home-skill-section > h3 {
  margin: 0 0 var(--space-3);
  color: var(--ink-secondary);
  font-size: 14px;
  font-weight: 550;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.section-sequence {
  list-style: none;
  padding: 0;
  margin: var(--space-8) 0 var(--space-7);
}

.home .section-sequence {
  margin: var(--space-5) 0 var(--space-6);
  max-width: 660px;
}

.sequence-row {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  gap: var(--space-3);
  align-items: baseline;
  padding: var(--space-4) 0;
  border-top: 1px solid var(--border);
}

.sequence-row:last-child {
  border-bottom: 1px solid var(--border);
}

.sequence-number,
.sequence-time {
  color: var(--ink-secondary);
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}

.sequence-name {
  font-weight: 500;
}

.primary-action,
.secondary-action,
.text-action {
  min-height: 48px;
  border-radius: var(--radius);
  cursor: pointer;
  font-weight: 550;
  transition: background-color 140ms ease, color 140ms ease, border-color 140ms ease, transform 120ms ease;
}

.primary-action {
  padding: 11px 22px;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: #fff;
}

.secondary-action {
  padding: 11px 20px;
  border: 1px solid var(--border-strong);
  background: var(--canvas);
  color: var(--ink);
}

.official-practice-action {
  display: flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  max-width: 100%;
  margin-top: var(--space-4);
}

.text-action {
  padding: 10px 4px;
  border: 0;
  background: transparent;
  color: var(--ink-secondary);
}

/* Unavailable, not chosen. A filled background is this interface's "pressed"
   and "selected" signal (.choice:has(input:checked), a toggled tool), so a
   disabled control wearing one reads as the option the student picked. A
   disabled control is flat, dimmed and keeps its outline. */
.primary-action:disabled,
.secondary-action:disabled,
.text-action:disabled {
  cursor: not-allowed;
  background: none;
  border-color: var(--border);
  color: var(--ink-tertiary);
  text-decoration: none;
  opacity: 0.65;
}

.primary-action:disabled {
  /* The primary action is the only filled control, so it stays filled or it
     stops looking like the step the student is on; it dims instead. */
  background: var(--fill-quiet);
  border-color: var(--border);
}

.test-column {
  min-width: 0;
}

.test-column.is-line-reading {
  position: relative;
}

.test-column.is-line-reading::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
  background: linear-gradient(
    to bottom,
    rgb(0 0 0 / 28%) 0,
    rgb(0 0 0 / 28%) var(--line-top, 0px),
    transparent var(--line-top, 0px),
    transparent var(--line-bottom, 32px),
    rgb(0 0 0 / 28%) var(--line-bottom, 32px)
  );
}

.active-shell.is-text-lg .test-column {
  font-size: 1.12em;
}

.active-shell.is-text-xl .test-column {
  font-size: 1.25em;
}

.item-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--space-6);
  align-items: start;
}

.stimulus {
  min-width: 0;
}

/* A Reading and Writing passage beside its question stays in view while the
   question column scrolls, below the test bar. A Math question is one
   column (Ruchi Baid's review, item 3): its tables and figures are part of
   the question at full width, and nothing sticks. */
.item-split > .stimulus {
  position: sticky;
  top: calc(var(--test-bar-height, 0px) + 16px);
  max-height: calc(100vh - var(--test-bar-height, 0px) - var(--test-bottom-height, 0px) - 32px);
  overflow: auto;
}

/* Daily practice is one column too, so the passage neither sticks nor needs
   a height bound on a wide screen: it reuses .stimulus purely so the
   narrow-screen bound below applies to it too. */
.daily-question .stimulus {
  position: static;
  max-height: none;
  overflow: visible;
}

.item-main {
  min-width: 0;
}

/* The timed test's column is a grid item too, and carries the same tables. */
.test-column {
  min-width: 0;
}

.figure-overlay {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  align-items: center;
  justify-content: center;
  padding: var(--space-5);
  background: rgb(0 0 0 / 72%);
}

.figure-overlay img {
  max-width: min(96vw, 1100px);
  max-height: 80vh;
  background: var(--canvas);
}

.figure-overlay-close {
  color: #fff;
}

.test-header {
  display: grid;
  grid-template-columns: minmax(7rem, auto) minmax(0, 1fr) auto;
  gap: var(--space-3) var(--space-4);
  align-items: start;
  margin-bottom: var(--space-5);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid var(--border);
}

.test-tools {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  align-items: baseline;
  justify-content: flex-end;
}

.clock-cluster {
  display: flex;
  align-items: baseline;
  gap: var(--space-3);
}

.section-name,
.timer {
  margin: 0;
  font-size: 15px;
  font-weight: 550;
}

.timer {
  color: var(--ink-secondary);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.timer.is-low {
  color: var(--error);
  font-weight: 600;
}

.timer.is-hidden-clock {
  color: var(--ink-secondary);
  font-weight: 550;
}

.text-action.is-tool-on {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* --- the Math reference sheet (Ruchi Baid's second review, 27 Oct 2026,
   item 1): Bluebook's page as inline SVG drawings and MathML formulas,
   built by mathReferencePanel. The panel is a size container, so how many
   figures share a row follows the pane's own width (the Reference pane
   opens at 380px and only widens; the phone sheet is the screen): from
   700px Bluebook's two rows of five, from 400px three cards to a row, and
   two to a row below that. Type scales with the pane too; the drawings'
   labels are sized per tier so none drops under 10px at the pane's
   default width. */
.reference-panel {
  container: reference / inline-size;
  margin-top: var(--space-6);
  padding: var(--space-4) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--fill-quiet);
}

.reference-panel h2 {
  margin: 0 0 var(--space-3);
  font-size: 1.1rem;
}

/* A row of the sheet: six slots across the first (the two special right
   triangles share one card and one caption, so that card spans two), five
   across the second. Each card takes two rows of the grid, drawing above
   formula, so a row's formulas line up whatever their drawings' heights. */
.reference-row {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: var(--space-1) var(--space-2);
  margin: 0;
  padding: 0;
  list-style: none;
}

.reference-row.is-solid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.reference-row + .reference-row {
  margin-top: var(--space-5);
}

.reference-figure {
  display: grid;
  grid-row: span 2;
  grid-template-rows: subgrid;
  grid-template-columns: minmax(0, 1fr);
  align-items: end;
  justify-items: center;
  min-width: 0;
  text-align: center;
}

.reference-figure.is-special-right-triangles {
  grid-column: span 2;
}

.reference-drawings {
  display: flex;
  gap: var(--space-1);
  width: 100%;
}

.reference-drawing {
  display: block;
  flex: 1 1 0;
  min-width: 0;
  height: auto;
  overflow: visible;
}

/* The figures' labels: a serif, as the formulas under them. Variables are
   italic through their tspan's own font-style. The size is in the
   drawing's own units (it scales with the drawing), set per tier below. */
.reference-drawing text {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 13px;
}

/* The formula lines, centred under the drawing (one wider than its slot
   overhangs both sides evenly) and on one baseline across the row, so a
   stacked fraction rises above its neighbours rather than sinking below. */
.reference-formulas {
  display: flex;
  flex-direction: column;
  align-items: center;
  align-self: baseline;
  width: 100%;
  font-size: 0.875rem;
  font-size: clamp(12px, 3.2cqi, 16px);
  line-height: 1.35;
  white-space: nowrap;
}

.reference-formulas math {
  display: block;
  margin: 0;
}

.reference-formulas math + math {
  margin-top: var(--space-1);
}

.reference-facts {
  margin-top: var(--space-5);
  font-size: 0.95rem;
  line-height: 1.5;
}

.reference-fact {
  margin: 0;
}

/* Under 700px (a floating pane widened past its default): three cards to
   a row, the special right triangles still two of them. The drawings are
   larger than in Bluebook's rows, so their labels take fewer drawing units
   to land near the formulas' size. */
@container reference (max-width: 699px) {
  .reference-row,
  .reference-row.is-solid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .reference-drawing text {
    font-size: 8px;
  }
}

@container reference (max-width: 549px) {
  .reference-drawing text {
    font-size: 10px;
  }
}

/* Under 400px (the Reference pane as it opens, at 380px, or the phone
   sheet): two figures to a row, the special right triangles taking a row
   of their own. */
@container reference (max-width: 399px) {
  .reference-row,
  .reference-row.is-solid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--space-1) var(--space-3);
  }

  .reference-formulas {
    font-size: 1rem;
  }

  .reference-drawing text {
    font-size: 10px;
  }
}

.question-form {
  /* A grid item's min-width is `auto`, which means "no narrower than my own
     content". A .prompt-table carries min-width: 420px, so the form refused
     to shrink below it, grew past its 350px column and scrolled the whole
     phone sideways -- while .table-scroll, the element that exists to absorb
     exactly that, sat inside it already narrow enough and never engaged.
     Measured at 390x844 on item_d6226f0b8dd54809967808e827a21a02: the form
     was 444px wide in a 350px track. */
  min-width: 0;
  max-width: 760px;
}

.question-form.has-stimulus {
  max-width: none;
}

.question-count {
  margin-bottom: var(--space-4);
}

.prompt-block {
  margin: 0 0 var(--space-5);
  padding: var(--space-4);
  border-radius: var(--radius);
  background: var(--fill-quiet);
}

.prompt-text {
  margin: 0;
  line-height: 1.68;
  white-space: pre-wrap;
}

/* The lines about a passage, not part of it: its source line and the
   "Text 1" / "Text 2" labels of a pair. */
.prompt-source,
.prompt-label {
  display: block;
  white-space: normal;
}

.prompt-source {
  margin-bottom: var(--space-3);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid var(--border);
  color: var(--ink-secondary);
  font-size: 0.9em;
  line-height: 1.5;
}

.prompt-label {
  margin-bottom: var(--space-1);
  color: var(--ink-secondary);
  font-size: 0.85em;
  font-weight: 600;
}

/* A line of verse: its own block, and a line that wraps hangs indented under
   its start, so it is not read as a new line of the poem (phones). */
.prompt-text .verse-line {
  display: block;
  white-space: normal;
  padding-left: 1.6em;
  text-indent: -1.6em;
}

.prompt-text .verse-break {
  height: 0.9em;
}

.prompt-label:not(:first-child) {
  margin-top: var(--space-4);
}

.prompt-text u,
.answer-group legend u {
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.table-scroll {
  max-width: 100%;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  /* Scroll shadows: a soft edge shows there are more columns to the side,
     and fades once the student reaches that edge. */
  background:
    linear-gradient(to right, var(--fill-quiet) 30%, transparent) left / 24px 100% no-repeat local,
    linear-gradient(to left, var(--fill-quiet) 30%, transparent) right / 24px 100% no-repeat local,
    radial-gradient(farthest-side at 0 50%, rgb(0 0 0 / 0.16), transparent) left / 12px 100% no-repeat scroll,
    radial-gradient(farthest-side at 100% 50%, rgb(0 0 0 / 0.16), transparent) right / 12px 100% no-repeat scroll,
    var(--fill-quiet);
}

.prompt-table {
  width: 100%;
  min-width: 420px;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
}

.prompt-table caption {
  margin-bottom: var(--space-3);
  text-align: left;
  /* The caption is the stem's own prose before the table, word for word. */
  font-weight: inherit;
}

.prompt-table-compact {
  min-width: 0;
  table-layout: fixed;
  overflow-wrap: anywhere;
}

.prompt-table th,
.prompt-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: top;
}

.prompt-table th {
  font-weight: 550;
}

/* A figure is inline at full size, as in Bluebook: its natural width up to
   the column, framed, with a zoom bar on top. Zoomed in, it scrolls inside
   its frame rather than widening the page. */
.prompt-block.prompt-figure {
  display: flex;
  justify-content: center;
  padding: 0;
  background: none;
}

.figure-frame {
  display: inline-flex;
  flex-direction: column;
  max-width: 100%;
  overflow: hidden;
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  background: var(--paper);
}

.figure-zoom-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1);
  padding: 2px var(--space-2);
  border-bottom: 1px solid var(--border);
  background: var(--fill-quiet);
}

.figure-zoom-bar button {
  min-width: 40px;
  min-height: 36px;
  padding: 0 8px;
  border: 0;
  border-radius: 6px;
  background: none;
  color: var(--ink);
  cursor: pointer;
  font-size: 15px;
  font-weight: 550;
}

.figure-zoom-bar .figure-zoom-in,
.figure-zoom-bar .figure-zoom-out {
  font-size: 20px;
  line-height: 1;
}

.figure-zoom-bar button:disabled {
  color: var(--ink-tertiary);
  cursor: not-allowed;
}

.figure-zoom-level {
  min-width: 4.5ch;
  color: var(--ink-secondary);
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  text-align: center;
}

.figure-zoom-bar .figure-full-screen {
  margin-left: var(--space-1);
  border-left: 1px solid var(--border);
  border-radius: 0 6px 6px 0;
}

.full-screen-icon {
  display: block;
  width: 18px;
  height: 18px;
  margin: 0 auto;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 18' fill='none' stroke='black' stroke-width='1.8'%3E%3Cpath d='M1 6V1h5M12 1h5v5M17 12v5h-5M6 17H1v-5'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 18' fill='none' stroke='black' stroke-width='1.8'%3E%3Cpath d='M1 6V1h5M12 1h5v5M17 12v5h-5M6 17H1v-5'/%3E%3C/svg%3E") center / contain no-repeat;
}

.figure-viewport {
  max-width: 100%;
  overflow: auto;
  overscroll-behavior: contain;
}

.figure-image {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
}

.answer-group {
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

/* The question reads at the same size and weight as its choices, as in
   Bluebook (Ruchi Baid's second review, 27 Oct: "questions are really big
   causing more scrolling"). The text-size controls (.is-text-lg, .is-text-xl
   on the column) scale both together. */
.answer-group legend {
  width: 100%;
  margin: 0 0 var(--space-5);
  padding: 0;
  font-size: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  line-height: inherit;
  white-space: pre-wrap;
}

.choice-list {
  display: grid;
  margin: 0;
}

.choice {
  display: grid;
  grid-template-columns: 24px 30px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
  min-height: 56px;
  padding: 15px 12px;
  border-top: 1px solid var(--border);
  cursor: pointer;
}

.choice:last-child {
  border-bottom: 1px solid var(--border);
}

.choice:has(input:checked) {
  background: var(--fill-pressed);
}

.choice input {
  width: 18px;
  height: 18px;
  margin: 3px 0 0;
  accent-color: var(--ink);
}

.choice-key {
  color: var(--ink-secondary);
  font-weight: 550;
}

.choice-text {
  white-space: pre-wrap;
}

.choice.is-eliminated .choice-key,
.choice.is-eliminated .choice-text {
  text-decoration: line-through;
  opacity: 0.45;
}

/* In a list that carries a verdict, "selected" is spent: the answer is
   submitted, and the only two filled rows are the key and the answer the
   student gave.
   Both the scope and the :not() pair are load-bearing, and a local student
   walk caught each of them in turn. The base .choice:has(input:checked) rule
   above is (0,2,1), so an UNSCOPED .choice.is-chosen-wrong (0,2,0) loses to
   it and the student's own wrong answer keeps the pale-green selected fill.
   And :has(input:checked) takes its argument's specificity, so the
   suppression below would be (0,4,1) and would beat the scoped (0,4,0)
   verdict rules, leaving that same row with no fill at all. Scope the
   verdicts, and exclude them from the suppression. */
.choice-list.has-verdict .choice:has(input:checked):not(.is-correct-choice):not(.is-chosen-wrong) {
  background: none;
}

.choice-list.has-verdict .choice.is-correct-choice,
.choice-list.has-verdict .choice.is-chosen-wrong {
  /* inset instead of border: a real border would move the row against the
     1px separators its siblings keep. */
  border-radius: var(--radius);
}

.choice-list.has-verdict .choice.is-correct-choice {
  background: var(--correct-fill);
  box-shadow: inset 0 0 0 2px var(--correct-edge);
}

.choice-list.has-verdict .choice.is-chosen-wrong {
  background: var(--wrong-fill);
  box-shadow: inset 0 0 0 2px var(--wrong-edge);
}

.choice-verdict {
  grid-row: 2;
  grid-column: 3 / -1;
  margin: var(--space-1) 0 0;
  font-size: 13px;
  font-weight: 650;
  letter-spacing: 0.01em;
}

.choice.is-correct-choice .choice-verdict,
.choice-verdict.is-correct-choice {
  color: var(--correct-ink);
}

.choice.is-chosen-wrong .choice-verdict,
.choice-verdict.is-chosen-wrong {
  color: var(--wrong-ink);
}

.spr-answer.has-verdict .choice-verdict {
  margin: var(--space-2) 0 0;
}

.spr-input.is-correct-choice {
  border-color: var(--correct-edge);
  box-shadow: inset 0 0 0 1px var(--correct-edge);
}

.spr-input.is-chosen-wrong {
  border-color: var(--wrong-edge);
  box-shadow: inset 0 0 0 1px var(--wrong-edge);
}

.eliminate-choice {
  margin: 0;
  min-height: 44px;
  min-width: 44px;
  padding: 0 4px;
  border: 0;
  background: none;
  color: var(--ink-secondary);
  cursor: pointer;
  font-size: 12px;
  font-weight: 550;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.spr-label {
  display: block;
  margin-bottom: var(--space-2);
  font-size: 15px;
  font-weight: 550;
}

.spr-input {
  width: min(100%, 360px);
  min-height: 52px;
  padding: 10px 14px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--canvas);
  color: var(--ink);
  font-size: 20px;
}

.spr-hint {
  max-width: 52ch;
  margin: var(--space-2) 0 0;
  color: var(--ink-secondary);
  font-size: 14px;
}

/* The on-screen keypad is for touch screens, where the system keyboard
   for a decimal box has no fraction bar or minus sign. A keyboard types
   (Ruchi Baid's review, item 6: desktop Bluebook has no keypad). */
.spr-keypad {
  display: none;
  flex-direction: column;
  gap: 8px;
  width: min(100%, 240px);
  margin-top: var(--space-3);
}

@media (pointer: coarse) {
  .spr-keypad {
    display: flex;
  }
}

.spr-key-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.spr-key {
  min-height: 44px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--canvas);
  color: var(--ink);
  font-size: 18px;
  font-weight: 550;
}

.spr-key.is-edit {
  font-size: 14px;
}

.review-filters {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin: 0 0 var(--space-3);
}

.review-filters .text-action {
  padding: 4px 0;
  font-size: 14px;
}

.is-review-on {
  font-weight: 650;
  color: var(--ink);
}

.exam-highlight {
  background: #f6e58d;
  color: inherit;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.is-highlight-on {
  font-weight: 650;
}

.highlight-hint {
  margin: 0 0 0.75rem;
  color: var(--ink-secondary);
  font-size: 0.9rem;
}

.active-shell.is-highlighting .prompt-text,
.active-shell.is-highlighting .answer-group legend {
  cursor: text;
}

/* The question. Its Math tools float over the page in panes (see "the
   floating panes" below), so this is one column at every width. */
.work-area {
  display: grid;
  /* minmax(0, 1fr) rather than the implicit `auto` track, for the same
     reason: an auto track is also floored at its content's min-content size. */
  grid-template-columns: minmax(0, 1fr);
  min-width: 0;
  gap: var(--space-6);
}

.work-area > * {
  min-width: 0;
}

.tool-stack {
  display: grid;
  min-width: 0;
  gap: var(--space-5);
}

/* The same floor .work-area > * lifts, one level down. A grid item's default
   min-width is auto, which is floored at its content's min-content size, and
   the calculator's is its expression panel plus a graph. Without this the
   panel refuses to shrink to its track and hangs 12px past the content edge
   at 1280. */
.tool-stack > * {
  min-width: 0;
}

.tool-stack .reference-panel {
  margin-top: 0;
}

.calculator-panel {
  margin-top: 0;
}

.desmos-frame,
.desmos-host {
  display: block;
  width: 100%;
  height: 380px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--canvas);
}

.desmos-host {
  overflow: hidden;
}

.desmos-host .supporting-copy {
  margin: var(--space-4);
}

/* --- the AlphaSAT calculator inside a question screen ---
   The calculator is ours, so it is told the app's palette rather than
   carrying its own: every value below is an existing app token, and the two
   surfaces stay one system when a token changes. Only the variables the
   calculator publishes are set; none of its rules are overridden, so the
   binding survives a calculator update. */

.calculator-panel.is-alphasat .desmos-host {
  --acalc-ink: var(--ink);
  --acalc-ink-2: var(--ink-secondary);
  --acalc-ink-3: var(--ink-tertiary);
  --acalc-accent: var(--accent);
  --acalc-panel: var(--fill-quiet);
  --acalc-paper: var(--paper);
  --acalc-line: var(--border);
  --acalc-line-strong: var(--border-strong);
  --acalc-hover: var(--fill-hover);
  --acalc-pressed: var(--fill-pressed);
  --acalc-error: var(--error);
  --acalc-focus: var(--accent);

  /* An expression list beside a graph needs more than the 380px square a
     frame gets: at 380px the calculator reads its own width as a phone and
     stacks. Height follows the viewport so the graph is worth looking at on
     a laptop, with a floor that keeps the keypad reachable on a short one.

     290px is where the panel starts on an unscrolled question screen, so
     subtracting it keeps the whole calculator, keypad toggle included, above
     the fold before the student scrolls and the sticky panel rises. */
  height: clamp(380px, calc(100vh - 290px), 620px);

  /* The calculator paints no outer edge of its own: its graph is white on
     the app's off-white canvas, which is a boundary you have to look for.
     It keeps the app's border and radius, so it is framed exactly as the
     reference sheet beside it is. */
  background: var(--paper);
}

/* A failed load leaves prose in the host, which then needs the border back
   and no calculator-sized box. */
.calculator-panel.is-alphasat .desmos-host:not(.acalc) {
  height: auto;
  min-height: 120px;
  border-color: var(--border);
  background: var(--canvas);
}

@media (max-width: 999px) {
  /* Stacked: the question is above and stays reachable by scrolling, and the
     calculator gets enough height for the graph and the on-screen keypad
     together. It collapses its own expression list at this width. */
  .calculator-panel.is-alphasat .desmos-host {
    height: clamp(420px, 68vh, 560px);
  }
}

.save-state {
  min-height: 22px;
}

.save-retry {
  min-height: 44px;
  margin-left: var(--space-2);
  padding: 4px;
  border: 0;
  background: transparent;
  color: var(--error);
  cursor: pointer;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.transition-copy {
  margin-bottom: var(--space-7);
  font-size: 19px;
}

.daily-brief {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 520px;
  margin: var(--space-8) 0 var(--space-7);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.daily-brief > div {
  padding: var(--space-4) 0;
}

.daily-brief dt {
  margin-bottom: var(--space-1);
  color: var(--ink-secondary);
  font-size: 14px;
}

.daily-brief dd {
  margin: 0;
  font-weight: 550;
}

/* Daily, catch-up and extra practice use the whole app column, as the
   practice test uses the whole page (Ilma, 4 Nov 2026: the practice page
   "occupying the full width but only shrinking once the calculator was
   added"): the header across the column like the test bar, the question area
   centred at the test's measure, a question at the test's one-column width,
   the two typed-answer panels side by side across the area (.spr-layout). A
   docked calculator or reference sheet then shifts the whole section by the
   pane (.daily-active.has-calculator-pane, below). */
.daily-active {
  max-width: none;
}

.daily-header {
  max-width: none;
}

.daily-active .work-area {
  max-width: 1180px;
  margin-inline: auto;
}

/* The same measure as .active-shell .question-form.is-one-column; the
   typed-answer rule (.spr-layout > .question-form, from 1000px) lifts it so
   the two panels share the area. The explicit width matters: the form is a
   grid item, and a grid item with auto margins is sized to its content, so
   on a phone a question holding a 420px-minimum table would grow past its
   350px track and the table's own scroller would never engage (Codex, 4 Nov
   2026). At 100% of the track it stays put and the table scrolls inside it. */
.daily-active .question-form {
  width: 100%;
  max-width: 900px;
  margin-inline: auto;
}

.daily-question-actions {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-5);
  margin-top: var(--space-7);
}

.tutor-disclosure {
  max-width: 420px;
}

.tutor-disclosure p {
  font-size: 14px;
}

.tutor-disclosure .text-action {
  min-height: 44px;
  margin-top: var(--space-1);
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.tutor-panel,
.daily-feedback {
  max-width: 760px;
  margin-top: var(--space-8);
  padding: var(--space-5);
  border-radius: var(--radius);
  background: var(--fill-quiet);
}

.tutor-panel h2,
.daily-feedback h2 {
  margin-top: var(--space-2);
}

.tutor-panel > p:not(.eyebrow),
.feedback-explanation {
  max-width: 64ch;
  margin: 0;
  white-space: pre-wrap;
}

.credit-rule {
  margin-top: var(--space-4);
  font-size: 14px;
}

.feedback-status {
  margin: 0 0 var(--space-2);
  font-size: 15px;
  font-weight: 600;
}

.feedback-status.is-correct {
  color: var(--ink);
}

.feedback-status.is-incorrect {
  color: var(--error);
}

.choice-feedback {
  margin: var(--space-3) 0 var(--space-4);
  padding-left: var(--space-3);
  border-left: 2px solid var(--border-strong);
}

.choice-feedback-heading {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
}

.choice-feedback-heading + .choice-feedback-text {
  margin-top: var(--space-1);
}

.choice-feedback-text {
  max-width: 64ch;
  margin: 0 0 var(--space-3);
  white-space: pre-wrap;
}

.choice-feedback-text:last-child {
  margin-bottom: 0;
}

.correct-response {
  margin: 0 0 var(--space-4);
  font-weight: 550;
}

.daily-feedback .feedback-disclosure {
  display: block;
  margin-bottom: var(--space-2);
  padding-left: 0;
  color: var(--ink);
  text-align: left;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.daily-feedback .primary-action {
  margin-top: var(--space-5);
}

.daily-finish-action {
  margin-top: var(--space-8);
}

/* The Finish control sits under the question at the question's left edge
   (Bugbot on #1109): the area is centred at 1180px and a one-column question
   at 900px inside it, so the control takes the same left offset the form
   gets, and none once the section is narrower than 900px (a docked pane, a
   phone), where the form starts at the section's edge too. */
.daily-active > .daily-finish-action,
.daily-active > .daily-finish-check {
  margin-left: max(0px, calc((100% - 900px) / 2));
}

.daily-finish-check {
  max-width: 560px;
  margin-top: var(--space-7);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border);
}

.daily-finish-check p {
  margin: 0 0 var(--space-3);
}

.daily-finish-actions {
  display: flex;
  gap: var(--space-3);
  align-items: center;
}

.next-task {
  max-width: 720px;
  margin: 0 0 var(--space-9);
  padding: var(--space-5);
  border-radius: var(--radius);
  background: var(--fill-quiet);
}

.next-task h2 {
  margin-top: var(--space-2);
}

.next-task .primary-action {
  margin-top: var(--space-5);
}

.daily-complete {
  max-width: 880px;
}

.results {
  max-width: 880px;
}

.result-intro {
  margin-bottom: var(--space-8);
  font-size: 18px;
}

.result-section + .result-section {
  margin-top: var(--space-9);
}

.result-list {
  margin-top: var(--space-5);
}

.result-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--space-4);
  align-items: baseline;
  padding: var(--space-4) 0;
  border-top: 1px solid var(--border);
}

.result-row:last-child {
  border-bottom: 1px solid var(--border);
}

.result-domain {
  margin-top: var(--space-1);
}

.result-counts {
  margin: 0;
  color: var(--ink-secondary);
  font-size: 15px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.result-skill-name {
  margin: 0;
  font-weight: 550;
}

/* An unmeasured skill is present and quiet: it is part of the map, not a
   result. The row keeps its height so the list reads as one scale. */
.result-row.is-unmeasured .result-skill-name,
.result-row.is-unmeasured .result-domain {
  color: var(--ink-tertiary);
}

.result-counts.is-unmeasured {
  color: var(--ink-tertiary);
  font-style: normal;
}

.home-skill-domain + .home-skill-domain {
  margin-top: var(--space-5);
}

.home-skill-domain-name {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
}

.home-skill-domain .result-list {
  margin-top: var(--space-2);
}

/* --- question-by-question review and mistake review --- */

.review {
  max-width: 880px;
}

.review-list {
  display: grid;
  gap: var(--space-6);
  margin: var(--space-6) 0 var(--space-7);
}

.review-item {
  padding: var(--space-5) 0 0;
  border-top: 1px solid var(--border);
}

.review-item-head {
  display: grid;
  gap: var(--space-1);
  margin-bottom: var(--space-4);
}

.review-item-head h3 {
  margin: 0;
  font-size: 18px;
}

.review-verdict {
  margin: 0;
  font-size: 15px;
  font-weight: 650;
}

.review-meta {
  margin: 0;
  color: var(--ink-secondary);
  font-size: 14px;
}

.review-stem {
  margin: 0 0 var(--space-3);
  font-size: inherit;
  font-weight: inherit;
  white-space: pre-wrap;
}

/* Review is read-only, so the choices are not inputs: the first grid column
   the answer list reserves for a radio is not needed here. */
.choice-list.is-review .choice {
  grid-template-columns: 30px minmax(0, 1fr) auto;
  cursor: default;
}

.choice-list.is-review .choice-verdict {
  grid-column: 2 / -1;
}

.review-item.is-unavailable .review-meta,
.review-item.is-unavailable .supporting-copy {
  color: var(--ink-tertiary);
}

.review-spr {
  display: grid;
  gap: var(--space-1);
}

.review-spr-line {
  margin: 0;
}

.review-spr-label {
  color: var(--ink-secondary);
  font-size: 15px;
}

.review-item .choice-list,
.review-item .review-spr {
  margin-bottom: var(--space-4);
}

.review-item.is-open {
  padding-bottom: var(--space-5);
}

/* Scoped to this screen: .review-filters is already the in-test All /
   Unanswered / Marked group, and its spacing is tuned for the rail. */
.mistake-more {
  display: grid;
  justify-items: start;
  gap: var(--space-2);
  margin: var(--space-5) 0 var(--space-6);
}

.review > .review-filters {
  gap: var(--space-4);
  margin: var(--space-5) 0 0;
}

.dashboard {
  max-width: 880px;
}

.dashboard .result-intro {
  margin-bottom: var(--space-7);
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin: 0 0 var(--space-8);
  padding: 1px;
  background: var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.stat {
  margin: 0;
  padding: var(--space-4);
  background: var(--canvas);
}

.stat-label {
  margin: 0 0 var(--space-2);
  color: var(--ink-secondary);
  font-size: 14px;
  font-weight: 500;
}

.stat-value {
  margin: 0;
  font-size: 34px;
  font-weight: 550;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}

.stat-hint {
  margin: var(--space-2) 0 0;
  color: var(--ink-tertiary);
  font-size: 13px;
}

.dashboard-block {
  margin: 0 0 var(--space-8);
}

.dashboard-block h2 {
  margin-bottom: var(--space-3);
  font-size: 22px;
}

.band-card {
  padding: var(--space-5);
  border-radius: var(--radius);
  background: var(--fill-quiet);
}

.band-card h2 {
  margin-top: var(--space-2);
}

.score-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-4);
  margin: var(--space-4) 0 var(--space-3);
}

.score-cell {
  margin: 0;
}

/* Which kind of practice this is, on the question screen itself. Quiet: it is
   context for the clock beside it, not a banner. */
.practice-kind-note {
  grid-column: 1 / -1;
  margin: var(--space-1) 0 0;
  color: var(--ink-secondary);
  font-size: 13px;
}

/* The estimated score. Reuses .score-grid, so the estimate and the reported
   official band read as the same kind of thing laid out the same way. */
.score-estimate {
  margin-top: var(--space-7);
  padding: var(--space-5);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

/* The next action does not touch the card above it. */
.score-estimate + .secondary-action,
.score-estimate + .primary-action {
  margin-top: var(--space-6);
}

.score-estimate h2 {
  margin: 0 0 var(--space-2);
  font-size: 22px;
}

.score-row {
  margin: 0;
}

.score-label {
  margin: 0;
  color: var(--ink-secondary);
  font-size: 14px;
  font-weight: 550;
}

.score-point {
  margin: var(--space-1) 0 0;
  font-size: 34px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

/* Never smaller than a caption and never further than a line from its number:
   the range is the estimate, not a footnote to it. */
.score-range {
  margin: var(--space-1) 0 0;
  color: var(--ink-secondary);
  font-size: 16px;
  font-variant-numeric: tabular-nums;
}

.score-estimate.is-unavailable .supporting-copy:first-of-type {
  color: var(--ink);
}

.band-card .band-note {
  margin-top: var(--space-3);
  font-size: 14px;
}

.earlier-scores {
  margin-top: var(--space-4);
  padding-top: var(--space-3);
  border-top: 1px solid var(--border);
}

.earlier-scores-label {
  margin: 0 0 var(--space-2);
  color: var(--ink-secondary);
  font-size: 14px;
  font-weight: 500;
}

.earlier-score-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: flex-start;
  gap: var(--space-1) var(--space-3);
  padding: var(--space-2) 0;
}

.earlier-score-total {
  font-weight: 550;
  font-variant-numeric: tabular-nums;
}

.earlier-score-meta,
.earlier-score-sections {
  flex: 0 1 auto;
  color: var(--ink-secondary);
  font-size: 14px;
}

.earlier-score-sections {
  font-variant-numeric: tabular-nums;
}

.earlier-score-sections::before {
  content: "·";
  margin-right: var(--space-3);
  color: var(--ink-tertiary);
}

.dashboard-actions {
  margin-top: var(--space-6);
}

.dashboard-link {
  display: block;
  margin-top: var(--space-4);
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.daily-complete-actions {
  margin-top: var(--space-7);
}

.error-copy {
  color: var(--error);
}

.retry-action {
  margin-top: var(--space-5);
}

.noscript-message {
  margin: var(--space-5);
  color: var(--error);
}

.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

@media (hover: hover) and (pointer: fine) {
  .primary-action:not(:disabled):hover {
    background: var(--accent-hover);
  }

  .secondary-action:not(:disabled):hover,
  .choice:hover {
    background: var(--fill-hover);
  }

  .question-nav button:hover {
    background: var(--fill-hover);
  }

  /* An answered question keeps a dark fill under the pointer: the pale
     hover fill once left white text on pale green (walk 2). */
  .question-nav button.is-answered:hover {
    background: var(--accent-hover);
    color: #fff;
  }

  .text-action:not(:disabled):hover {
    color: var(--ink);
  }
}

.primary-action:not(:disabled):active,
.secondary-action:not(:disabled):active,
.text-action:not(:disabled):active,
.question-nav button:active {
  transform: scale(0.97);
}

@media (min-width: 761px) and (max-width: 1100px) {
  .item-split { grid-template-columns: 1fr; }
  .item-split > .stimulus { position: static; max-height: none; }
}

@media (max-width: 760px) {
  .masthead,
  #app {
    width: calc(100% - 48px);
  }

  .masthead {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: var(--space-1) var(--space-3);
    padding-block: 12px;
  }

  .masthead-end,
  .session-progress-control {
    display: contents;
  }

  .masthead .product-context {
    justify-self: end;
  }

  .masthead .text-action {
    min-height: 44px;
    padding-block: 8px;
  }

  #session-progress {
    grid-column: 1;
    grid-row: 2;
    justify-self: start;
  }

  .session-sign-out {
    grid-column: 2;
    grid-row: 2;
    justify-self: end;
  }

  .session-progress-note {
    grid-column: 1 / -1;
    grid-row: 3;
    margin: 0;
  }

  #app {
    padding-top: var(--space-6);
  }

  h1 {
    font-size: 38px;
  }

  .section-sequence {
    margin-top: var(--space-7);
  }

  .sequence-row {
    grid-template-columns: 36px minmax(0, 1fr);
  }

  .sequence-time {
    grid-column: 2;
  }

  .item-split {
    display: block;
  }

  /* Stacked above the question on a narrow screen, the passage flows in the
     page like the rest of the question. It used to get its own window (40vh,
     30vh on a phone) that scrolled inside the page: a student walk found the
     key column of a data table cut off in that box, and a long passage read
     through a slot a few lines high. One page scroll is easier than a box
     inside a page. A wide table still scrolls sideways, but only inside its
     own .table-scroll frame, so the page itself never does. */
  .stimulus,
  .daily-question .stimulus {
    position: static;
    min-width: 0;
    max-height: none;
    overflow: visible;
    margin-bottom: var(--space-5);
  }

  .test-header {
    grid-template-columns: 1fr;
    gap: var(--space-2) var(--space-3);
    margin-bottom: var(--space-4);
    padding-bottom: var(--space-3);
  }

  .question-count {
    margin-bottom: var(--space-3);
  }

  .work-area {
    gap: var(--space-5);
  }

  .test-tools {
    justify-content: flex-start;
  }

  .prompt-block {
    margin-right: -8px;
    margin-left: -8px;
    padding: var(--space-4) var(--space-3);
  }

  /* The block bleeds 8px past each edge like the passage above it, so the
     table frame lines up with the passage instead of stopping 16px short. */
  .prompt-block.table-scroll {
    max-width: none;
  }

  /* Three columns fit a phone once long headers wrap, so they are not made
     to scroll sideways; wider tables keep their minimum and scroll in their
     own frame. */
  .prompt-table[data-columns="3"] {
    min-width: 0;
  }

  .result-row {
    display: block;
  }

  .result-counts {
    margin-top: var(--space-2);
  }

  /* The stat tiles' narrow-screen columns moved to the progress layout block
     at the end of this file (28 Oct 2026): two by two under 900px, one
     column under 480px. */

  .score-grid {
    grid-template-columns: 1fr;
    gap: var(--space-3);
  }

  .daily-question-actions {
    display: block;
    margin-top: var(--space-6);
  }

  .tutor-disclosure {
    margin-top: var(--space-4);
  }

  .tutor-panel,
  .daily-feedback,
  .next-task {
    margin-right: -8px;
    margin-left: -8px;
    padding: var(--space-4) var(--space-3);
  }

  .daily-finish-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .daily-finish-actions .text-action {
    align-self: flex-start;
  }
}

@media (max-width: 430px) {
  .masthead,
  #app {
    width: calc(100% - 40px);
  }

  /* Everything above the question, measured at 390x844 and cut back: the
     masthead, the app's own top padding and the question header were taking
     about 40% of the first screen between them. */
  .masthead {
    padding-block: 8px;
    gap: 0 var(--space-3);
  }

  .product-context {
    font-size: 14px;
  }

  /* The wordmark already says AlphaSAT; the signed-out "SAT practice" label
     beside it is a second label for the same thing, and on a phone it costs a
     line. Signed in it is the way back to practice (28 Oct 2026), and stays. */
  .masthead p.product-context {
    display: none;
  }

  #app {
    padding-top: var(--space-4);
  }

  h1 {
    font-size: 38px;
  }

  .test-header h1.section-name,
  .daily-header h1.section-name {
    font-size: 15px;
  }

  .answer-group legend {
    margin-bottom: var(--space-4);
  }

  .test-header {
    gap: var(--space-1) var(--space-2);
    margin-bottom: var(--space-3);
  }

  .test-tools {
    gap: var(--space-1) var(--space-2);
  }

  .test-tools .text-action {
    min-height: 36px;
    padding: 4px 6px;
  }

  .choice {
    grid-template-columns: 22px 26px minmax(0, 1fr) auto;
    gap: 10px;
    padding-right: 8px;
    padding-left: 8px;
  }

  .daily-brief {
    grid-template-columns: 1fr;
  }

  .daily-brief > div + div {
    padding-top: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Guided support remains in the current question and uses native controls. */
.tutor-work {
  display: block;
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  margin-top: var(--space-2);
  padding: var(--space-3);
  resize: vertical;
  border: 1px solid var(--ink-muted);
  border-radius: var(--radius);
  color: var(--ink);
  background: var(--paper, white);
  font: inherit;
}
.tutor-turn { margin-block: var(--space-4); }
.tutor-turn-label { font-weight: 650; margin-bottom: var(--space-2); }
.tutor-message, .tutor-work-saved { white-space: pre-wrap; overflow-wrap: anywhere; }
.tutor-work-saved { font-size: 14px; }
.tutor-actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-4); align-items: center; }
.tutor-actions button { min-height: 44px; max-width: 100%; white-space: normal; }
.tutor-error { overflow-wrap: anywhere; }
@media (max-width: 520px) {
  .tutor-actions { align-items: stretch; flex-direction: column; }
  .tutor-actions button { width: 100%; }
}

/* Math is MathML (public/math-notation.js mathMarkup; Ruchi Baid's second
   review, 27 Oct), drawn by the browser in the system's math font: Cambria
   Math on Windows, STIX Two Math where it is installed, the browser's own
   math face otherwise. Inline math takes the text's size; a display line (a
   solution step's equation) is full size and sits at the left of its line,
   not centred. */
math {
  font-family: "STIX Two Math", "Cambria Math", "Latin Modern Math", math, serif;
}

math[display="block"] {
  margin: 0;
  text-align: left;
}

/* The typed-answer preview and the directions' example draw their own small
   fraction (showSprPreview, sprDirections): what the student typed, not
   notation from the bank. */
.math-frac {
  display: inline-flex;
  flex-direction: column;
  align-items: stretch;
  margin: 0 0.12em;
  font-size: 0.86em;
  line-height: 1.15;
  text-align: center;
  vertical-align: middle;
  white-space: nowrap;
}

.math-num {
  padding: 0 0.15em 0.06em;
  border-bottom: 0.08em solid currentColor;
}

.math-den {
  padding: 0.06em 0.15em 0;
}

/* A written explanation as numbered steps (explanationBlock), and a
   structured solution (solutionStepsList; Ruchi Baid's second review, item
   4, img/image2.png): each step its title, then its equation lines with a
   short note in italics beside each. A Desmos block is boxed, with one
   button that loads its expressions into the calculator. On a narrow screen
   the note drops under its equation. Equation and note are always
   left-aligned and share one left edge (justify-items: start keeps the block
   math content-sized, so the browser has no slack to centre it in; the
   mock-up is left-aligned too). */
.solution-steps {
  max-width: 64ch;
  margin: 0;
  padding: 0 0 0 1.6em;
}

.explanation-points {
  max-width: 64ch;
  margin: 0;
  padding: 0 0 0 1.2em;
  white-space: normal;
}

.explanation-points > li + li {
  margin-top: var(--space-3);
}

.solution-steps > li + li {
  margin-top: var(--space-3);
}

.solution-steps > li::marker {
  font-weight: 600;
}

.solution-step-title {
  margin: 0 0 var(--space-1);
  font-weight: 600;
}

.solution-lines {
  display: grid;
  gap: var(--space-2);
  margin: 0;
  padding: 0;
  list-style: none;
}

.solution-line {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  column-gap: var(--space-4);
  align-items: baseline;
  justify-items: start;
}

.solution-note {
  color: var(--ink-secondary);
  font-size: 15px;
  font-style: italic;
}

.solution-lines.is-desmos {
  margin-top: var(--space-2);
  padding: var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.solution-calculator {
  margin-top: var(--space-2);
  padding: 0;
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 4px;
}

@media (max-width: 480px) {
  .solution-line {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* The mini-lesson before a skill's first questions: one quiet card between
   the brief and the start button on the practice start screen. Its example
   lines reuse the solution-line grid above. */
.skill-lesson {
  max-width: 60ch;
  margin: var(--space-5) 0 0;
  padding: var(--space-4) var(--space-5);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.skill-lesson h2 {
  margin-bottom: var(--space-2);
  font-size: 20px;
}

.skill-lesson-text {
  margin: 0 0 var(--space-2);
  color: var(--ink);
  font-size: 17px;
  line-height: 1.5;
}

.skill-lesson-example {
  margin-top: var(--space-3);
}

.skill-lesson-example .skill-lesson-text {
  color: var(--ink-secondary);
}

.daily-ready .skill-lesson + .primary-action {
  margin-top: var(--space-5);
}

/* The section break's early start sits below the break's own actions: the
   break is the default, starting Math early is the quieter choice. */
.transition-note {
  margin: var(--space-6) 0 var(--space-2);
  color: var(--ink-secondary);
  font-size: 15px;
}

.transition-note[hidden],
.break-skip[hidden] {
  display: none;
}

/* --- the calculator as a sheet on a phone ---
   Stacked below the question, the calculator sat about 890px down the page:
   a student had to scroll away from the question to use it and back to
   answer. On a phone it opens as a sheet over the lower part of the screen
   instead, and the page gets matching room at the bottom so every part of
   the question can still be scrolled above the sheet. */
.calculator-sheet-bar {
  display: none;
}

@media (max-width: 760px) {
  /* Every constructed provider: the calculator lane serves Desmos, with ours
     as the fallback (which provider mounted is on the host's
     data-calculator-provider). */
  .calculator-panel.is-desmos-api,
  .calculator-panel.is-desmos-public-page,
  .calculator-panel.is-alphasat {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 40;
    display: flex;
    flex-direction: column;
    height: min(56vh, 520px);
    height: min(56dvh, 520px);
    padding: 0 8px calc(8px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--border-strong);
    border-radius: 14px 14px 0 0;
    background: var(--paper);
    box-shadow: 0 -8px 24px rgb(0 0 0 / 0.12);
  }

  .calculator-panel.is-desmos-api .calculator-sheet-bar,
  .calculator-panel.is-desmos-public-page .calculator-sheet-bar,
  .calculator-panel.is-alphasat .calculator-sheet-bar {
    display: flex;
    flex: none;
    align-items: center;
    justify-content: space-between;
    min-height: 44px;
    padding: 0 4px;
  }

  .calculator-sheet-title {
    font-weight: 600;
  }

  /* On the light sheet the pressed tab is the dark one. */
  .calculator-sheet-bar .calculator-tab.is-tab-on {
    background: var(--ink);
    color: var(--canvas);
  }

  .calculator-panel.is-desmos-api .desmos-host,
  .calculator-panel.is-desmos-public-page .desmos-frame,
  .calculator-panel.is-alphasat .desmos-host {
    flex: 1 1 auto;
    min-height: 0;
    height: auto;
  }

  /* On a phone the calculator pane's own bar steps aside for the sheet's. */
  .tool-pane.is-calculator-pane > .tool-pane-bar,
  .tool-pane.is-calculator-pane > .tool-pane-resize {
    display: none;
  }

  body:has(.calculator-panel.is-desmos-api) #app,
  body:has(.calculator-panel.is-desmos-public-page) #app,
  body:has(.calculator-panel.is-alphasat) #app {
    padding-bottom: calc(min(56vh, 520px) + var(--space-5));
  }

  /* The calculator keypad needs room of its own: the sheet grows while it is
     up, so the graph stays usable above it. */
  .calculator-panel.is-alphasat:has(.acalc.has-keypad) {
    height: min(76vh, 680px);
    height: min(76dvh, 680px);
  }

  body:has(.calculator-panel.is-alphasat .acalc.has-keypad) #app {
    padding-bottom: calc(min(76vh, 680px) + var(--space-5));
  }
}

/* "19-1=18" stays on one line instead of breaking after the minus. */
.math-nowrap {
  white-space: nowrap;
}

/* An expression never breaks across lines (Ruchi Baid's review, item 3:
   "y = -(x +" on one line and "3)² - 9" on the next). Each drawn run of math
   and each whole expression (typesetTextNodes wraps it in .math-expression)
   is one unbreakable piece; text around it still wraps at its spaces, and a
   choice wraps only at a space outside a run. */
.math-run,
.math-expression {
  white-space: nowrap;
}

.spr-hint.is-error {
  color: var(--error);
  font-weight: 550;
}


/* --- the test screen at Bluebook parity (Ruchi Baid's review, 23 Oct) ---
   During a module the screen is three parts, as in Bluebook: one bar at the
   top (section and Directions, the clock, the tools), the question, and a
   bar at the bottom (the student's name, the question list, Back and Next).
   The app masthead steps aside while a module is on screen. */
/* The tool icons, drawn as masks so they take the text colour. Defined at
   the root: daily practice's header shows the same Calculator and
   Reference buttons. */
:root {
  --icon-calculator: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Crect x='3.5' y='1.5' width='13' height='17' rx='1.5' fill='none' stroke='black' stroke-width='1.5'/%3E%3Crect x='6' y='4' width='8' height='3'/%3E%3Crect x='6' y='9' width='2' height='2'/%3E%3Crect x='9' y='9' width='2' height='2'/%3E%3Crect x='12' y='9' width='2' height='2'/%3E%3Crect x='6' y='12.5' width='2' height='2'/%3E%3Crect x='9' y='12.5' width='2' height='2'/%3E%3Crect x='12' y='12.5' width='2' height='4.5'/%3E%3Crect x='6' y='15.5' width='5' height='1.5'/%3E%3C/svg%3E");
  --icon-more: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='10' cy='4' r='2'/%3E%3Ccircle cx='10' cy='10' r='2'/%3E%3Ccircle cx='10' cy='16' r='2'/%3E%3C/svg%3E");
  --icon-bookmark: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 18'%3E%3Cpath d='M1.5 1.5h11v15l-5.5-4.2-5.5 4.2z' fill='none' stroke='black' stroke-width='1.6' stroke-linejoin='round'/%3E%3C/svg%3E");
  --icon-bookmark-filled: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 18'%3E%3Cpath d='M1 1h12v16l-6-4.6L1 17z'/%3E%3C/svg%3E");
  --icon-pin: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 20'%3E%3Cpath d='M8 1a6 6 0 0 0-6 6c0 4.5 6 12 6 12s6-7.5 6-12a6 6 0 0 0-6-6zm0 8.5A2.5 2.5 0 1 1 8 4.5a2.5 2.5 0 0 1 0 5z'/%3E%3C/svg%3E");
}

body.is-module-screen .masthead,
body.is-module-screen .signed-in-banner {
  display: none;
}

body.is-module-screen #app {
  width: 100%;
  max-width: none;
  padding: 0;
}

.active-shell {
  --test-bar-height: 76px;
  --test-bottom-height: 68px;
  --test-rule: rgb(25 38 33 / 45%);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}

.tool-icon,
.bookmark-icon,
.legend-icon {
  display: block;
  flex: none;
}

.calculator-icon,
.more-icon {
  width: 22px;
  height: 22px;
  background: currentColor;
  -webkit-mask: var(--icon) center / contain no-repeat;
  mask: var(--icon) center / contain no-repeat;
}

.calculator-icon {
  --icon: var(--icon-calculator);
}

.more-icon {
  --icon: var(--icon-more);
}

.reference-icon {
  height: 22px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 19px;
  font-style: italic;
  font-weight: 700;
  line-height: 22px;
}

.reference-icon::before {
  content: "x²";
}

/* The top bar. */
.test-bar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: var(--space-3);
  min-height: var(--test-bar-height);
  padding: var(--space-2) clamp(16px, 3vw, 48px);
  border-bottom: 2px dashed var(--test-rule);
  background: var(--fill-quiet);
}

.test-bar-start {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
}

.test-bar .section-name {
  max-width: none;
  margin: 0;
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.25;
}

.test-bar-menu {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  padding: 4px 0;
  border: 0;
  background: none;
  color: var(--ink);
  cursor: pointer;
  font-size: 15px;
  font-weight: 550;
}

.menu-chevron {
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: translateY(-2px) rotate(45deg);
  transition: transform 140ms ease;
}

[aria-expanded="true"] > .menu-chevron {
  transform: translateY(2px) rotate(-135deg);
}

/* The question list opens upward from the bottom bar, so its arrow points
   up while it is closed, as in Bluebook. */
.question-menu-toggle .menu-chevron {
  transform: translateY(2px) rotate(-135deg);
}

.question-menu-toggle[aria-expanded="true"] .menu-chevron {
  transform: translateY(-2px) rotate(45deg);
}

.test-bar-clock {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.test-bar .timer {
  color: var(--ink);
  font-size: 24px;
  font-weight: 650;
  line-height: 1.1;
}

.test-bar .timer.is-hidden-clock {
  color: var(--ink-secondary);
  font-size: 15px;
  font-weight: 550;
}

.test-bar .timer.is-low {
  color: var(--error);
}

.timer-toggle {
  min-height: 30px;
  padding: 2px 16px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink);
  cursor: pointer;
  font-size: 13px;
  font-weight: 650;
}

.test-bar-tools {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-2);
}

.test-bar-tool {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  min-width: 64px;
  min-height: 54px;
  padding: 4px 8px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: none;
  color: var(--ink);
  cursor: pointer;
  font-size: 14px;
  font-weight: 550;
}

.test-bar-tool.is-tool-on {
  border-bottom-color: var(--ink);
}

/* The drop-downs: Directions, More, and the question list. */
.test-popover {
  position: absolute;
  z-index: 45;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  background: var(--paper);
  box-shadow: 0 14px 36px rgb(0 0 0 / 0.18);
}

.test-popover[hidden] {
  display: none;
}

.directions-panel {
  top: calc(100% + 8px);
  left: 0;
  width: min(640px, calc(100vw - 32px));
  max-height: min(70vh, 560px);
  overflow-y: auto;
  padding: var(--space-4) var(--space-5) var(--space-5);
}

.directions-panel h2 {
  font-size: 20px;
}

.directions-panel p {
  max-width: 62ch;
  margin: 0 0 var(--space-3);
}

.directions-panel .directions-note {
  color: var(--ink-secondary);
  font-size: 15px;
}

.more-menu {
  position: relative;
}

.more-panel {
  top: calc(100% + 6px);
  right: 0;
  display: grid;
  min-width: 210px;
  padding: var(--space-2);
}

.more-item {
  min-height: 44px;
  padding: 8px 12px;
  border: 0;
  border-radius: 6px;
  background: none;
  color: var(--ink);
  cursor: pointer;
  text-align: left;
  font-size: 15px;
}

.more-item.is-tool-on {
  font-weight: 650;
}

.more-item:disabled {
  color: var(--ink-tertiary);
  cursor: not-allowed;
}

.more-sign-out {
  margin-top: var(--space-1);
  border-top: 1px solid var(--border);
  border-radius: 0 0 6px 6px;
}

/* The question. */
.active-shell .test-column {
  flex: 1 0 auto;
  padding: var(--space-5) clamp(16px, 3vw, 48px) var(--space-7);
}

.active-shell .work-area {
  max-width: 1180px;
  margin-inline: auto;
}

.question-strip {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
  padding-right: var(--space-2);
  border-bottom: 2px dashed var(--test-rule);
  background: var(--fill-quiet);
}

.question-strip:has(.question-count:focus) {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

.question-number {
  display: grid;
  place-items: center;
  min-width: 40px;
  height: 44px;
  padding: 0 10px;
  background: var(--ink);
  color: var(--canvas);
  font-size: 18px;
  font-variant-numeric: tabular-nums;
  font-weight: 650;
}

.mark-review {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 8px;
  border: 0;
  background: none;
  color: var(--ink);
  cursor: pointer;
  font-size: 15px;
}

.bookmark-icon {
  width: 14px;
  height: 18px;
  background: currentColor;
  -webkit-mask: var(--icon-bookmark) center / contain no-repeat;
  mask: var(--icon-bookmark) center / contain no-repeat;
}

.mark-review.is-marked-action .bookmark-icon {
  background: var(--error);
  -webkit-mask-image: var(--icon-bookmark-filled);
  mask-image: var(--icon-bookmark-filled);
}

.eliminator-toggle {
  min-width: 48px;
  min-height: 36px;
  margin-left: auto;
  padding: 2px 8px;
  border: 1px solid var(--ink);
  border-radius: 6px;
  background: var(--paper);
  color: var(--ink);
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-decoration: line-through;
}

.eliminator-toggle.is-tool-on {
  background: var(--ink);
  color: var(--canvas);
}

/* The bottom bar. */
.test-bottom-bar {
  position: sticky;
  bottom: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: var(--space-3);
  min-height: var(--test-bottom-height);
  padding: var(--space-2) clamp(16px, 3vw, 48px);
  border-top: 2px dashed var(--test-rule);
  background: var(--fill-quiet);
}

.test-bottom-start {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0 var(--space-3);
  min-width: 0;
}

.learner-name {
  margin: 0;
  overflow: hidden;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.test-bottom-start .save-state {
  margin: 0;
}

.question-menu-toggle {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 8px 18px;
  border: 0;
  border-radius: 6px;
  background: var(--ink);
  color: var(--canvas);
  cursor: pointer;
  font-size: 16px;
  font-weight: 650;
  white-space: nowrap;
}

.test-bottom-nav {
  display: flex;
  justify-content: flex-end;
  gap: var(--space-2);
}

.test-bottom-nav .primary-action,
.test-bottom-nav .secondary-action {
  min-width: 104px;
  border-radius: 999px;
}

/* The question list. */
.question-menu {
  position: fixed;
  bottom: calc(var(--test-bottom-height) + 12px);
  left: 50%;
  width: min(720px, calc(100vw - 32px));
  max-height: calc(100vh - var(--test-bar-height) - var(--test-bottom-height) - 32px);
  overflow-y: auto;
  padding: var(--space-3) var(--space-5) var(--space-5);
  transform: translateX(-50%);
}

.question-menu-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding-bottom: var(--space-2);
}

.question-menu-head h2 {
  margin: 0;
  font-size: 20px;
}

.popover-close {
  min-width: 44px;
  min-height: 44px;
  border: 0;
  background: none;
  color: var(--ink);
  cursor: pointer;
  font-size: 28px;
  line-height: 1;
}

.question-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-2) var(--space-5);
  margin: 0;
  padding: var(--space-3) 0;
  border-block: 1px solid var(--border);
  list-style: none;
  font-size: 15px;
}

.question-legend li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.legend-icon {
  width: 18px;
  height: 18px;
}

.legend-current .legend-icon {
  width: 15px;
  background: var(--ink);
  -webkit-mask: var(--icon-pin) center / contain no-repeat;
  mask: var(--icon-pin) center / contain no-repeat;
}

.legend-unanswered .legend-icon {
  border: 1px dashed var(--ink-secondary);
}

.legend-review .legend-icon {
  width: 13px;
  background: var(--error);
  -webkit-mask: var(--icon-bookmark-filled) center / contain no-repeat;
  mask: var(--icon-bookmark-filled) center / contain no-repeat;
}

.question-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 30px 16px;
  padding: 30px 0 var(--space-4);
}

.question-nav button {
  position: relative;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--ink-secondary);
  border-radius: 4px;
  background: var(--paper);
  color: var(--accent);
  cursor: pointer;
  font-size: 18px;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
}

.question-nav button:not(.is-answered) {
  border-style: dashed;
}

.question-nav button.is-answered {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.question-nav button.is-marked::after {
  content: "";
  position: absolute;
  top: -7px;
  right: -6px;
  width: 12px;
  height: 16px;
  background: var(--error);
  -webkit-mask: var(--icon-bookmark-filled) center / contain no-repeat;
  mask: var(--icon-bookmark-filled) center / contain no-repeat;
}

.question-nav button[aria-current="step"] {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.question-nav button[aria-current="step"]::before {
  content: "";
  position: absolute;
  top: -26px;
  left: 50%;
  width: 16px;
  height: 20px;
  background: var(--ink);
  transform: translateX(-50%);
  -webkit-mask: var(--icon-pin) center / contain no-repeat;
  mask: var(--icon-pin) center / contain no-repeat;
}

.question-menu-note {
  margin: 0 0 var(--space-3);
  color: var(--ink-secondary);
  text-align: center;
  font-size: 14px;
}

.go-to-review {
  display: block;
  margin: 0 auto;
  border-color: var(--accent);
  border-radius: 999px;
  color: var(--accent);
}

/* Check Your Work, the end of every module. */
.check-work {
  max-width: 1040px;
  margin: 0 auto;
  text-align: center;
}

.check-work-title {
  margin: var(--space-4) 0;
  font-size: clamp(30px, 3vw, 40px);
  font-weight: 500;
}

.check-work-copy {
  max-width: 64ch;
  margin: 0 auto var(--space-2);
}

.check-work-clock {
  margin: var(--space-3) 0 0;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

.check-work-card {
  margin-top: var(--space-6);
  padding: var(--space-5);
  border-radius: 10px;
  background: var(--paper);
  box-shadow: 0 4px 18px rgb(0 0 0 / 0.08);
  text-align: left;
}

.check-work-card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding-bottom: var(--space-3);
  border-bottom: 1px solid var(--border);
}

.check-work-card-head h3 {
  font-size: 20px;
}

.check-work-card .question-legend {
  padding: 0;
  border: 0;
}

.check-work-card .question-nav {
  padding-top: var(--space-4);
}

@media (max-width: 760px) {
  /* Two rows on a phone (the 24 Oct walk at 390px found three or four: the
     title wrapping, Directions under it, the tools on a row of their own):
     the section title on one line with Directions beside it and the
     clock and Hide on the right; then the tools, each an icon beside its
     label. A title too long for the line ends in an ellipsis rather than
     wrapping. */
  .test-bar {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "start clock"
      "tools tools";
    gap: 2px var(--space-2);
    padding: var(--space-1) var(--space-3);
  }

  .test-bar-start {
    grid-area: start;
    flex-direction: row;
    align-items: center;
    gap: var(--space-2);
  }

  .test-bar-clock {
    grid-area: clock;
    flex-direction: row;
    gap: var(--space-2);
  }

  .test-bar-tools {
    grid-area: tools;
    justify-content: flex-start;
    gap: var(--space-1);
  }

  .test-bar .section-name {
    flex: 0 1 auto;
    min-width: 0;
    overflow: hidden;
    font-size: 15px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .test-bar .test-bar-menu {
    flex: none;
    min-height: 40px;
    font-size: 14px;
  }

  .test-bar .timer {
    font-size: 18px;
  }

  .test-bar .timer-toggle {
    padding: 2px 12px;
  }

  .test-bar-tool {
    flex-direction: row;
    gap: 6px;
    min-width: 0;
    min-height: 40px;
    padding: 2px 8px;
    font-size: 13px;
  }

  .test-bar-tool .calculator-icon,
  .test-bar-tool .more-icon {
    width: 18px;
    height: 18px;
  }

  .test-bar-tool .reference-icon {
    height: 18px;
    font-size: 16px;
    line-height: 18px;
  }

  .directions-panel {
    position: fixed;
    top: auto;
    right: var(--space-3);
    left: var(--space-3);
    width: auto;
  }

  .active-shell .test-column {
    padding: var(--space-4) var(--space-3) var(--space-6);
  }

  /* One row: the name (cut short with an ellipsis, never wrapped under),
     the question button, Back and Next. A save message takes the name's
     place while it shows. */
  .test-bottom-bar {
    grid-template-columns: minmax(0, 1fr) auto auto;
    grid-template-areas: "start centre nav";
    column-gap: var(--space-2);
    padding: var(--space-2) var(--space-3);
  }

  .test-bottom-start {
    grid-area: start;
    flex-wrap: nowrap;
  }

  .test-bottom-start .learner-name {
    flex: 0 1 auto;
    min-width: 0;
  }

  .test-bottom-start:has(.save-state:not(:empty)) .learner-name {
    display: none;
  }

  .test-bottom-start .save-state {
    min-width: 0;
    font-size: 13px;
    line-height: 1.25;
  }

  .question-menu-toggle,
  .test-bottom-centre {
    grid-area: centre;
  }

  .question-menu-toggle {
    gap: 8px;
    padding: 8px 12px;
    font-size: 15px;
  }

  .test-bottom-nav {
    grid-area: nav;
  }

  .test-bottom-nav .primary-action,
  .test-bottom-nav .secondary-action {
    min-width: 0;
    padding-inline: 16px;
  }

  .question-menu {
    width: calc(100vw - 24px);
  }

  .question-nav {
    gap: 28px 12px;
  }
}


/* --- the floating panes: the calculator and the reference sheet ---
   Bluebook opens both as panes over the page (Ruchi Baid's review, item 3).
   Docked by default, the calculator at the left and the reference sheet at
   the right, between the test bar and the bottom bar; the question column
   moves aside by the pane's width while there is room (the shell's
   has-calculator-pane / has-reference-pane, set by applyToolPaneShift).
   Dragged by its bar a pane floats (is-moved) at the place and size the
   student gave it. Geometry arrives as custom properties set from script:
   the CSP refuses inline styles. */
.tool-pane {
  min-width: 0;
}

.tool-pane-bar {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 44px;
  padding: 0 var(--space-1) 0 var(--space-3);
  background: var(--ink);
  color: var(--canvas);
}

.tool-pane-grip {
  width: 14px;
  height: 14px;
  background: radial-gradient(circle, currentColor 1.4px, transparent 1.6px) 0 0 / 7px 7px;
  opacity: 0.8;
}

.tool-pane-title {
  flex: 1;
  font-size: 15px;
  font-weight: 650;
}

/* Bluebook's Graphing | Scientific toggle, in the calculator pane's bar (and,
   on a phone, the sheet's bar). Two joined buttons; the pressed one is the
   filled one, as in Bluebook, and underlined so the state is not colour
   alone. */
.calculator-tabs {
  display: inline-flex;
  flex: none;
  margin-right: auto;
  border: 1px solid currentColor;
  border-radius: 6px;
  overflow: hidden;
}

.calculator-tab {
  min-height: 32px;
  padding: 4px 12px;
  border: 0;
  background: none;
  color: inherit;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
}

.calculator-tab + .calculator-tab {
  border-left: 1px solid currentColor;
}

.calculator-tab.is-tab-on {
  background: var(--canvas);
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Scientific without Desmos: a plain note where the calculator would be. */
.calculator-panel > .calculator-unavailable {
  margin: var(--space-4);
}

.tool-pane-close {
  min-width: 44px;
  min-height: 44px;
  border: 0;
  background: none;
  color: inherit;
  cursor: pointer;
  font-size: 26px;
  line-height: 1;
}

.tool-pane-body {
  min-width: 0;
}

.tool-pane-body .reference-panel {
  margin: 0;
  border: 0;
  border-radius: 0;
}

.tool-pane-resize {
  display: none;
}

/* From 761px up a pane floats over the page and can be dragged and
   resized; the question moves aside for a docked pane only from 1000px up
   (applyToolPaneShift), so between 761px and 999px the pane overlays the
   question. At 760px and below the calculator is the phone sheet. */
@media (min-width: 761px) {
  .tool-stack {
    display: contents;
  }

  .tool-pane {
    position: fixed;
    z-index: 35;
    top: var(--test-bar-height, 0px);
    bottom: var(--test-bottom-height, 0px);
    display: flex;
    flex-direction: column;
    width: var(--pane-width, 480px);
    max-width: calc(100vw - 24px);
    min-height: 440px;
    border: 1px solid var(--border-strong);
    background: var(--paper);
    box-shadow: 0 10px 30px rgb(0 0 0 / 0.16);
  }

  .tool-pane.is-calculator-pane {
    left: 0;
  }

  .tool-pane.is-reference-pane {
    right: 0;
    min-height: 240px;
  }

  .tool-pane.is-moved {
    top: var(--pane-top);
    right: auto;
    bottom: auto;
    left: var(--pane-left);
    height: var(--pane-height);
    max-height: calc(100vh - var(--pane-top));
    border-radius: 8px;
    overflow: hidden;
  }

  .tool-pane-bar {
    cursor: move;
    touch-action: none;
    user-select: none;
  }

  .tool-pane-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    overscroll-behavior: contain;
  }

  /* The calculator fills its pane; Desmos draws nothing in a box with no
     height, so the host never goes below 380px. */
  .tool-pane .calculator-panel {
    display: flex;
    flex-direction: column;
    height: 100%;
  }

  .tool-pane .calculator-panel .desmos-host,
  .tool-pane .calculator-panel .desmos-frame {
    flex: 1 1 auto;
    height: auto;
    min-height: 380px;
    border: 0;
    border-radius: 0;
  }

  .tool-pane-resize {
    position: absolute;
    right: 0;
    bottom: 0;
    display: block;
    width: 22px;
    height: 22px;
    background:
      linear-gradient(135deg, transparent 55%, var(--ink-secondary) 55%, var(--ink-secondary) 62%, transparent 62%,
        transparent 74%, var(--ink-secondary) 74%, var(--ink-secondary) 81%, transparent 81%);
    cursor: nwse-resize;
    touch-action: none;
  }

  /* Docked, a pane only widens; floating, it takes both directions. */
  .tool-pane:not(.is-moved) .tool-pane-resize {
    cursor: ew-resize;
  }
}

/* The question moves aside for a docked pane only from 1000px up (and
   applyToolPaneShift sets these classes only then, with room to spare). */
@media (min-width: 1000px) {
  .active-shell.has-calculator-pane .test-column {
    padding-left: calc(var(--calculator-pane-width) + var(--space-5));
  }

  .active-shell.has-reference-pane .test-column {
    padding-right: calc(var(--reference-pane-width) + var(--space-5));
  }

  /* Daily practice sits in the app's centred column, so it moves over only
     by what the pane covers of it: the pane's width less the column's own
     left margin. */
  .daily-active {
    --test-bar-height: 0px;
    --test-bottom-height: 0px;
  }

  .daily-active.has-calculator-pane {
    margin-left: max(0px, calc(var(--calculator-pane-width) + var(--space-4) - (100vw - min(calc(100vw - 112px), var(--content-width))) / 2));
  }

  .daily-active.has-reference-pane {
    margin-right: max(0px, calc(var(--reference-pane-width) + var(--space-4) - (100vw - min(calc(100vw - 112px), var(--content-width))) / 2));
  }
}

@media (max-width: 760px) {
  .tool-stack {
    margin-top: var(--space-6);
  }

  .tool-pane {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
  }

  .tool-pane + .tool-pane {
    margin-top: var(--space-5);
  }

  .active-shell > .tool-stack {
    padding: 0 clamp(16px, 3vw, 48px) var(--space-6);
  }
}

/* A Math question is one column, centred, at a readable width; a Reading
   and Writing question keeps its two panels across the screen. */
.active-shell .question-form {
  margin-inline: auto;
}

.active-shell .question-form.is-one-column {
  max-width: 900px;
}

.question-form.is-one-column > .stimulus {
  margin-bottom: var(--space-2);
}

/* In a one-column Math question the text before the stem reads as part of
   the question, as in Bluebook, not as a boxed passage. */
.question-form.is-one-column .prompt-block:not(.table-scroll):not(.prompt-figure) {
  padding: 0;
  background: none;
}


/* --- typed answers at Bluebook's rules (Ruchi Baid's review, item 6) ---
   The directions and their Examples table beside the question, the box
   under the stem, and the Answer Preview under the box. */
.spr-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-4);
}

.spr-directions {
  min-width: 0;
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--paper);
}

.spr-directions-title {
  display: none;
  margin: 0 0 var(--space-3);
  font-size: 22px;
}

.spr-directions-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  width: 100%;
  min-height: 44px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  text-align: left;
}

.spr-directions-body[hidden] {
  display: none;
}

.spr-rules {
  margin: var(--space-2) 0 var(--space-4);
  padding-left: 1.2em;
  line-height: 1.6;
}

.spr-rules li + li {
  margin-top: var(--space-1);
}

.spr-examples {
  width: 100%;
  border-collapse: collapse;
  text-align: center;
  font-size: 15px;
}

.spr-examples caption {
  margin-bottom: var(--space-2);
  font-weight: 550;
}

.spr-examples th,
.spr-examples td {
  padding: var(--space-2);
  border: 1px solid var(--border-strong);
  vertical-align: middle;
}

.spr-examples th {
  font-weight: 500;
}

.spr-examples code {
  display: block;
  width: fit-content;
  margin: 4px auto;
  padding: 1px 6px;
  border-radius: 4px;
  background: var(--fill-quiet);
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  letter-spacing: 0.08em;
}

.spr-answer .spr-input {
  width: 160px;
  font-variant-numeric: tabular-nums;
}

.spr-preview-line {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-height: 48px;
  margin: var(--space-5) 0 0;
}

.spr-preview-label {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 22px;
  font-weight: 700;
}

.spr-preview-value {
  font-size: 22px;
  font-variant-numeric: tabular-nums;
}

.spr-preview-value .math-frac {
  font-size: 0.9em;
}

/* The hint line is quiet until there is a rule to show. */
.spr-hint:empty {
  display: none;
}

@media (min-width: 1000px) {
  /* Bluebook's two panels: the directions on the left, the question on the
     right, the directions always open. */
  .spr-layout {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 0;
    align-items: start;
  }

  .spr-layout > .spr-directions {
    position: sticky;
    top: calc(var(--test-bar-height, 0px) + 16px);
    max-height: calc(100vh - var(--test-bar-height, 0px) - var(--test-bottom-height, 0px) - 32px);
    overflow-y: auto;
    margin-right: var(--space-5);
    padding: 0 var(--space-5) 0 0;
    border: 0;
    border-right: 3px solid var(--border-strong);
    border-radius: 0;
    background: none;
  }

  .spr-layout > .question-form {
    max-width: none;
    margin: 0;
  }

  .spr-directions-title {
    display: block;
  }

  .spr-directions-toggle {
    display: none;
  }

  .spr-directions-body[hidden] {
    display: block;
  }
}

/* progress layout (28 Oct 2026) */
/* "How practice is going" as Ruchi Baid's mock-up (third review, image3):
   the stat tiles in one row from 900px (four in the mock-up; five since the
   "XP today" tile of 24 Nov 2026, docs/xp-practice-20261124.md section 7), two
   by two under it and one column under 480px; under them two columns from 900px, "Skills to work on"
   on the left and the Starting test, the practice test, recent practice and
   official scores on the right; one column under 900px in that DOM order.
   The tiles are the dashboard's only .stat-grid, so these rules replace the
   one-column rule the 760px block used to carry. */
.dashboard .stat-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: var(--space-3);
}

.dashboard .progress-note {
  margin: 0 0 var(--space-6);
  color: var(--ink-tertiary);
  font-size: 14px;
}

/* The pace lines under the "Time per question" number: one per section, the
   verdict in the ink colour so it reads first. */
.stat-pacing .pace-lines {
  display: grid;
  gap: var(--space-1);
  margin-top: var(--space-3);
}

.pace-line {
  margin: 0;
  color: var(--ink-secondary);
  font-size: 13px;
  line-height: 1.45;
}

.pace-line .pace-line-numbers {
  font-variant-numeric: tabular-nums;
}

.pace-line .pace-verdict {
  color: var(--ink);
  font-weight: 550;
}

.pace-line.is-not_enough .pace-verdict {
  color: var(--ink-tertiary);
  font-weight: 500;
}

.progress-columns {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-4);
  align-items: start;
}

.progress-column {
  display: grid;
  gap: var(--space-4);
  min-width: 0;
}

.progress-column > .dashboard-block {
  margin: 0;
}

.progress-card {
  padding: var(--space-4) var(--space-4) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--paper);
}

.progress-card h2 {
  font-size: 20px;
}

.progress-card .result-list {
  margin-top: var(--space-3);
}

.progress-card .result-row:last-child {
  border-bottom: 0;
}

.progress-card .secondary-action {
  margin-top: var(--space-2);
}

.progress-card .score-estimate {
  margin-top: var(--space-4);
}

.dashboard .dashboard-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  align-items: center;
  margin-top: var(--space-7);
}

@media (min-width: 900px) {
  .dashboard {
    max-width: none;
  }

  .dashboard .stat-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .progress-columns {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 899px) {
  .dashboard .stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .progress-columns {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* "Under 480px": exactly 480px is still two by two. */
@media (max-width: 479px) {
  .dashboard .stat-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .dashboard .dashboard-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .dashboard .dashboard-actions .text-action {
    align-self: flex-start;
  }
}

/* The masthead's "SAT practice", a control when signed in (Ruchi Baid, 28 Oct
   2026: Progress had no way back to practice but the bottom of the page). It
   sits where the label sat and reads like Progress and Sign out beside it;
   whichever of the two places is on screen carries aria-current="page". */
.masthead .masthead-home {
  margin: 0;
  font-size: inherit;
}

.masthead-end [aria-current="page"] {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 6px;
}

/* skill graph (28 Oct 2026) */
/* The four states, quiet: a fill at low alpha and a stroke in the state colour;
   the unchecked state is grey text on no fill. Green is the app's accent; amber
   and orange are new tokens, scoped to the skills section.

   The section uses the room the screen has: .home is an 840 px column centred
   in #app, itself centred in the viewport, so a negative side margin widens the
   section symmetrically, up to 1120 px and never past 24 px from the viewport's
   edges. The Math graph (1,036 units at natural size) then fits a laptop without
   scrolling. */
.home-skills {
  --skill-strong: var(--accent);
  --skill-strong-fill: rgb(36 91 70 / 12%);
  --skill-fading: #9a6700;
  --skill-fading-fill: rgb(154 103 0 / 12%);
  --skill-working: #b4532a;
  --skill-working-fill: rgb(180 83 42 / 12%);
  --skills-width: min(1120px, max(100%, 100vw - 48px));
  width: var(--skills-width);
  margin-left: calc((100% - var(--skills-width)) / 2);
}

.skill-view-switch {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin: var(--space-3) 0 var(--space-4);
}

.skill-view-button {
  min-height: 36px;
  padding: 6px 14px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  background: var(--canvas);
  color: var(--ink-secondary);
  font-size: 14px;
}

.skill-view-button[aria-pressed="true"] {
  border-color: var(--accent);
  background: var(--fill-pressed);
  color: var(--ink);
}

/* A panel hugs its picture: Reading and Writing (620 units) stays left-aligned
   at its natural width, never stretched to the section. */
.skill-graph-panel {
  width: fit-content;
  max-width: 100%;
  margin: 0 0 var(--space-5);
  padding: var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--paper);
}

.skill-graph-panel:last-child {
  margin-bottom: 0;
}

.skill-graph-title {
  margin: 0 0 var(--space-3);
  color: var(--ink-secondary);
  font-size: 14px;
  font-weight: 550;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* The SVG is drawn at its natural size (its width and height attributes equal
   its viewBox), never scaled up or down: scaled text falls under 12 px. A panel
   narrower than the picture scrolls sideways in this box; the legend and the
   details line sit outside it. */
.skill-graph-scroll {
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
}

.skill-graph-svg {
  display: block;
  max-width: none;
  overflow: visible;
  font-family: inherit;
}

.skill-band-title {
  fill: var(--ink-secondary);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.skill-edge {
  fill: none;
  stroke: var(--border-strong);
  stroke-width: 1.5;
}

.skill-node {
  cursor: pointer;
  outline: none;
}

.skill-node-box {
  fill: var(--paper);
  stroke: var(--border-strong);
  stroke-width: 1.25;
}

.skill-node-label {
  fill: var(--ink);
  font-size: 12.5px;
  font-weight: 550;
}

.skill-node.is-strong .skill-node-box {
  fill: var(--skill-strong-fill);
  stroke: var(--skill-strong);
}

.skill-node.is-fading .skill-node-box {
  fill: var(--skill-fading-fill);
  stroke: var(--skill-fading);
}

.skill-node.is-working .skill-node-box {
  fill: var(--skill-working-fill);
  stroke: var(--skill-working);
}

.skill-node.is-unchecked .skill-node-box {
  fill: none;
  stroke: var(--border);
}

.skill-node.is-unchecked .skill-node-label {
  fill: var(--ink-tertiary);
  font-weight: 450;
}

.skill-node.is-selected .skill-node-box {
  stroke-width: 2.5;
}

.skill-node:focus-visible .skill-node-box {
  stroke: var(--ink);
  stroke-width: 2.5;
}

.skill-legend {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-4);
  margin: var(--space-3) 0 0;
  padding: 0;
  color: var(--ink-secondary);
  font-size: 14px;
  list-style: none;
}

.skill-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.skill-swatch {
  display: inline-block;
  flex: none;
  width: 12px;
  height: 12px;
  border: 1.5px solid var(--border-strong);
  border-radius: 3px;
  background: transparent;
}

.skill-swatch.is-strong {
  border-color: var(--skill-strong);
  background: var(--skill-strong-fill);
}

.skill-swatch.is-fading {
  border-color: var(--skill-fading);
  background: var(--skill-fading-fill);
}

.skill-swatch.is-working {
  border-color: var(--skill-working);
  background: var(--skill-working-fill);
}

.skill-swatch.is-unchecked {
  border-color: var(--border);
}

.skill-graph-details {
  min-height: 1.5em;
  margin: var(--space-3) 0 0;
  color: var(--ink-secondary);
  font-size: 15px;
}

/* The compact list (Ruchi's mock-up): two columns from 700 px, a card per domain. */
.skill-list {
  display: grid;
  gap: var(--space-5);
}

@media (min-width: 700px) {
  .skill-list {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: start;
  }
}

.skill-list .home-skill-section {
  margin-top: 0;
}

.skill-card {
  padding: 0 var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--paper);
}

.home-skill-domain.skill-card + .home-skill-domain.skill-card {
  margin-top: var(--space-3);
}

.skill-card .home-skill-domain-name {
  padding: var(--space-3) 0;
}

.skill-card .result-list {
  margin-top: 0;
}

.skill-card .result-row {
  padding: 10px 0;
}

.skill-card .result-row:last-child {
  border-bottom: 0;
}

.skill-row-state {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.skill-row-state.is-strong {
  color: var(--skill-strong);
}

.skill-row-state.is-fading {
  color: var(--skill-fading);
}

.skill-row-state.is-working {
  color: var(--skill-working);
}

/* solution view toggle (28 Oct 2026) */
/* A solution with a Desmos path (Ruchi Baid's third review): two buttons,
   "Algebra" | "Desmos", above the two lists. A filled background is this
   interface's pressed signal, so the chosen view is the filled button. */
.solution-views {
  display: grid;
  gap: var(--space-3);
}

/* Author display beats the browser's [hidden] rule, so a collapsed review
   explanation kept its grid and stayed visible (Codex round 1, B1). */
.solution-views[hidden] {
  display: none;
}

.solution-view-toggle {
  display: inline-flex;
  justify-self: start;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  overflow: hidden;
}

.solution-view-button {
  min-height: 44px;
  padding: 8px 18px;
  border: 0;
  background: transparent;
  color: var(--ink-secondary);
  font: inherit;
  font-weight: 550;
  cursor: pointer;
  transition: background-color 140ms ease, color 140ms ease;
}

.solution-view-button + .solution-view-button {
  border-left: 1px solid var(--border-strong);
}

.solution-view-button[aria-pressed="true"] {
  background: var(--ink);
  color: #fff;
}

.solution-view-button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.solution-views > .solution-steps[hidden] {
  display: none;
}

/* practice XP bar (28 Oct 2026 as the block bar; XP since 24 Nov 2026) */
/* How much of the exercise's XP is earned: a thin bar and "9 of 15 XP". Quiet by design:
   no countdown, no colour change, no low state (docs/xp-practice-20261124.md section 7);
   it moves when an answer lands and never ticks. */
.practice-block {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  min-width: 9rem;
  margin: 0;
  color: var(--ink-secondary);
  font-size: 15px;
  font-weight: 550;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.practice-block-track {
  display: block;
  width: 100%;
  height: 4px;
  overflow: hidden;
  border-radius: 2px;
  background: var(--border);
}

.practice-block-fill {
  display: block;
  width: calc(var(--practice-block-progress, 0) * 100%);
  height: 100%;
  border-radius: inherit;
  background: var(--ink-secondary);
  transition: width 0.4s ease-out;
}

.practice-block-text {
  display: block;
}

/* The practice question line: "Question N" and, at its end, the stopwatch the learner can
   show or hide (public/question-timer.js). Quiet like the block bar: secondary ink, no
   colour change at any value. */
.question-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-1) var(--space-3);
  margin-bottom: var(--space-4);
}

.question-line .question-count {
  margin-bottom: 0;
}

/* On a phone the line keeps the tighter gap the question count had there. This rule sits
   after the one above on purpose: the same weight, so the later one wins. */
@media (max-width: 760px) {
  .question-line {
    margin-bottom: var(--space-3);
  }
}

.question-timer {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-left: auto;
  color: var(--ink-secondary);
  font-size: 14px;
}

.question-timer-face {
  font-weight: 550;
  font-variant-numeric: tabular-nums;
}

.question-timer .question-timer-toggle {
  min-height: 36px;
  /* The button keeps its 36px target without making the question line taller than its text. */
  margin-block: -7px;
  padding: 4px 6px;
  font-size: 14px;
}

/* key idea and Desmos table (4 Nov 2026) */
/* A v3 solution opens with its key idea (Ilma's review: the fact the question
   turns on, said in plain words), above the Algebra | Desmos toggle. The label
   is a quiet line of its own; the sentence reads at the body size. */
.solution-idea {
  max-width: 64ch;
  margin: 0;
  line-height: 1.5;
}

.solution-idea-label {
  display: block;
  margin-bottom: 2px;
  color: var(--ink-secondary);
  font-size: 14px;
  font-weight: 600;
}

/* A Desmos table expression, in the place of a display line: the column names
   across the top, the values below. Bordered like .spr-examples, small and
   content-sized, so it sits in the line's grid with its note beside it. */
.solution-table {
  width: auto;
  margin: 0;
  border-collapse: collapse;
  text-align: center;
  font-size: 15px;
}

.solution-table th,
.solution-table td {
  padding: var(--space-1) var(--space-3);
  border: 1px solid var(--border-strong);
  vertical-align: middle;
}

.solution-table th {
  font-weight: 500;
}

/* The learner's SAT date and goal score (docs/sat-goal-20261110.md): Home's
   card, Home's one line and the Progress row. Layout only. The card is a
   .progress-card, the boxes are .spr-input under .spr-label, the buttons and
   the error text are the app's own; no colour or type of its own. */
.sat-goal-card {
  max-width: 660px;
  margin: 0 0 var(--space-6);
}

.sat-goal-field + .sat-goal-field {
  margin-top: var(--space-4);
}

.sat-goal-card .sat-goal-field:first-child,
.sat-goal-progress .sat-goal-field:first-child {
  margin-top: var(--space-3);
}

.sat-goal-input {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-3);
  align-items: center;
}

.sat-goal-input .spr-input {
  box-sizing: border-box;
  max-width: 100%;
}

.sat-goal-error {
  margin: var(--space-2) 0 0;
  font-size: 14px;
}

.sat-goal-error:empty {
  display: none;
}

/* The card's Save button keeps its own width; Home's start button is the one
   made wide (.home .primary-action). */
.sat-goal-form .primary-action {
  min-width: 0;
}

.sat-goal-line {
  margin-top: var(--space-2);
}

.sat-goal-progress .result-row {
  align-items: center;
}

/* solution step why (24 Nov 2026) */
/* Ruchi Baid's fourth review: the reason a step holds, one or two plain
   sentences drawn under the step's title and before its lines, in body text
   (the body size and colour; never the note's italics or its secondary
   colour). Layout only; no colour or type of its own. */
.solution-step-why {
  max-width: 64ch;
  margin: 0 0 var(--space-2);
  line-height: 1.5;
}
