/* =========================================================================
   practice-paper-exam.css — the print half of practice-paper.html

   practice-paper.html serves the 91 `paper-v*.json` papers. On SCREEN it is an
   interactive revision tool: the student types into textareas, answers persist
   in localStorage, Section I self-marks. That is the right screen product and
   this file does not touch it.

   On PAPER it should be an exam paper. So the page renders a SECOND DOM from
   the same JSON — `.exam-paper` — using the class vocabulary of
   papers/practice-papers/exam-paper.css, the stylesheet behind the twelve
   standalone NESA-convention papers. That stylesheet is linked here with
   media="print" and is NOT copied: the runtime papers and the static ones are
   the same designed artefact, so a change to it lands on both.

   This file therefore does only two things:
     1. switches which of the two DOMs is visible, per medium;
     2. adds the handful of rules exam-paper.css has no reason to carry,
        because they exist only where a paper is generated at runtime.

   NOT `assets/css/worksheet-print.css`. Despite its name that is a separate
   366-page exam system with its own vocabulary (`ws-head`, `ws-meta`), and it
   paginates at runtime by measuring getBoundingClientRect() with no gate over
   the result. It is also held by PR #1434. Nothing here reads or changes it.
   ========================================================================= */

/* ---- Medium switch ---------------------------------------------------- */

/* The exam DOM is print-only. It carries no inputs and no persistence, so it
   is inert on screen; hiding it keeps one focusable copy of the paper for
   keyboard and screen-reader users rather than two. */
.exam-paper { display: none; }

/* Announce the print pack on screen so a student knows the button produces an
   exam paper rather than a printout of the web page. */
.pp-print-note {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--adv-muted, #6b6478);
}
.pp-print-note strong { color: var(--adv-ink, #241f2e); }

@media print {
  /* The web tool, hidden — the whole wrapper, not rule by rule. `.exam-paper`
     is a sibling of `.wc-scope`, not a descendant, precisely so that this can
     be one declaration and so that wc-design.css's class+element selectors
     (`.wc-scope p { margin: 0 }`) never reach the exam paper to outrank
     exam-paper.css's single-class rules. */
  .wc-scope { display: none !important; }

  /* The exam paper, shown. From here down exam-paper.css governs the page
     unopposed: @page owns the margins, `html, body` the 11pt serif measure.
     Nothing below restates any of its metrics. */
  .exam-paper { display: block; }

  /* Where timing is NOT a measured convention for this blueprint, it is
     printed under its own heading and never inside General Instructions, so
     the two cannot be read as the same kind of claim. */
  .cover-suggested-timing {
    margin: 4mm 0 0;
    padding-top: 2mm;
    border-top: 0.4pt dotted var(--rule, #9a9a9a);
  }
  .cover-suggested-timing h2 { font-size: 10pt; }
  .cover-suggested-timing ul { margin-bottom: 0; }
  .cover-suggested-timing .timing-caveat {
    font-size: 8.5pt;
    font-style: italic;
    margin: 1.5mm 0 0;
  }

  /* An outcome code is an identifier; breaking BIO12-13 across two lines
     turns it into two. */
  .cover-footnote .outcome-code { white-space: nowrap; }

  /* Section II parts arrive from the bank as inline "(a) … (b) …" prose (a
     recorded data-model gap, FINDINGS-LOG). Nothing here splits them — the
     verbatim rule forbids it — but a stem stranded at the foot of a page,
     with its ruled space overleaf, reads badly. */
  .sa-head,
  .sa-stem { break-after: avoid; }

  /* KaTeX renders inline in the maths papers; keep it from forcing a
     horizontal overflow inside the printed measure. */
  .exam-paper .katex-display { overflow-x: hidden; }
  .exam-paper .katex { font-size: 1em; }

  /* The runtime papers carry no figures today (0 of 1,761 questions declare
     `assets`), but the renderer supports them, so give a printed figure the
     same bare-line-work treatment the static papers use. */
  .exam-paper .stimulus-figure img { max-width: 100%; height: auto; }
}
