/* Option A: SLAB reading layout. Shared tokens remain in assets/slab.css. */
body { grid-template-columns: 14rem minmax(0, 1fr); }
main.canvas { width: min(calc(100% - 5rem), var(--canvas)); min-width: 0; }
p { margin: 0 0 1rem; max-width: 78ch; }
h1 { font-size: clamp(2rem, 3.5vw, 3rem); line-height: 1.15; margin: .7rem 0 1rem; }
h2 { font-size: clamp(1.45rem, 2.3vw, 2rem); line-height: 1.2; margin: .4rem 0 1.25rem; }
h3 { font-size: 1.15rem; margin: 2rem 0 1rem; }
h4 { font-size: .98rem; line-height: 1.6; margin: 0 0 .8rem; }
blockquote { margin: 0; font-size: .88rem; line-height: 1.8; }
a { text-underline-offset: .18em; }
ul { padding-left: 1.2rem; }
li + li { margin-top: .5rem; }
button, input, select { font: inherit; }
[hidden] { display: none !important; }
:target { scroll-margin-top: 2rem; }
.section { padding-block: 2.5rem; }
.section-top .label { font-size: .65rem; }
.section > p { font-size: .92rem; }
.index-nav .nav-inner { padding: 2rem 1.25rem; }
.studio-brand { text-decoration: none; display: flex !important; flex-direction: column; padding: 0 !important; margin-bottom: 3rem; color: var(--ink) !important; }
.studio-brand strong { font-size: 1.8rem; letter-spacing: -.1em; font-weight: 600; }
.studio-brand span { font-size: .55rem; letter-spacing: .2em; }
.index-nav .nav-title { line-height: 1.8; font-size: .62rem; }
.index-nav li { margin: 0; }
.index-nav a { font-weight: 500; padding: .65rem .2rem; font-size: .76rem; }
.index-nav a .mono { font-size: .65rem; color: var(--accent-1-ink); margin-right: .5rem; }
.index-nav a[aria-current="location"] { color: var(--accent-1-ink); font-weight: 700; }
.nav-foot { margin-top: 2rem; color: var(--muted); font-size: .7rem; }
.page-header { padding: 2rem 0 1rem; }
.page-header .label { font-size: .66rem; }
.page-header > p:last-child { font-size: .95rem; color: var(--ink-soft); }
.reading-key { display: flex; flex-wrap: wrap; gap: .7rem 2rem; padding: 0 0 1.5rem; font-size: .74rem; }
.reading-key span { display: flex; align-items: center; gap: .5rem; }
.reading-key span::before { content: ''; width: .7rem; height: .7rem; border: 1px solid var(--rule); background: var(--surface); }
.reading-key .guide-key::before { background: var(--accent-1-soft); border-color: var(--accent-1-ink); }
.voice { font: 600 .65rem/1.5 var(--font-ui); letter-spacing: .07em; text-transform: uppercase; margin-bottom: .8rem; }
.voice.official { color: var(--muted); }
.voice.guide { color: var(--accent-1-ink); }
.weights { margin: 1rem 0 1.5rem; }
.weight-band { display: flex; gap: 3px; min-height: 10rem; }
.weight-band a { flex: var(--share) 1 0; display: flex; flex-direction: column; padding: 1rem; background: var(--surface); border: 1px solid var(--rule); text-decoration: none; min-width: 0; }
.weight-band a:hover { outline: 2px solid var(--ink); outline-offset: -2px; }
.weight-band a > span { font: .7rem var(--font-mono); }
.weight-band strong { font-size: 2rem; font-weight: 500; line-height: 1.5; }
.weight-band small { font-size: .7rem; line-height: 1.5; margin-top: auto; padding-top: .8rem; }
.weights figcaption { font-size: .8rem; max-width: 80ch; }
.commentary { background: var(--accent-1-soft); border-left: 3px solid var(--accent-1-ink); padding: 1.1rem 1.25rem; margin: 1.25rem 0; font-family: var(--font-serif); font-size: 1rem; line-height: 1.7; }
.commentary > :last-child { margin-bottom: 0; }
.commentary ul { margin: .8rem 0; }
.criterion { padding-top: 1.6rem; margin-top: 2rem; border-top: 2px solid var(--ink); }
.criterion-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.criterion-head .label { color: var(--accent-1-ink); font-size: .7rem; }
.criterion-head h3 { font-size: 1.25rem; line-height: 1.4; margin: .4rem 0; }
.criterion-weight { font: 500 2rem/1.3 var(--font-display); letter-spacing: -.04em; white-space: nowrap; }
.criterion-weight span { font-size: 1rem; margin-left: .1rem; }
.criterion-body { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 1.5rem; align-items: start; }
.official-panel { background: var(--surface); border: 1px solid var(--rule); padding: 1.25rem; }
.criterion-body .commentary { margin: 0; }
.mapped { margin-top: 1rem; border-top: 1px solid var(--rule-soft); padding-top: 1rem; }
.mapped p { font-size: .75rem; line-height: 1.9; margin-bottom: .5rem; }
.pitfall { padding-top: .8rem; border-top: 1px solid var(--accent-1-ink); }
.grade-ladder { margin: 1rem 0 2rem; border-top: 2px solid var(--ink); }
.grade-step { display: grid; grid-template-columns: 10rem minmax(0,1fr); gap: 2rem; border-bottom: 1px solid var(--rule); padding: 1rem 0; }
.grade-step > div { display: flex; flex-direction: column; }
.grade-step strong { font: 500 1.4rem var(--font-display); }
.grade-step span { font-size: .75rem; margin-top: .3rem; }
.grade-step p { font-family: var(--font-serif); font-size: 1rem; line-height: 1.7; margin: 0; align-self: center; }
.band-control { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; font-size: .8rem; font-weight: 600; margin: 1rem 0; }
select { padding: .6rem; background: var(--surface); color: var(--ink); border: 1px solid var(--rule); border-radius: 0; max-width: 100%; font-size: .83rem; cursor: pointer; }
.rubric-scroll { overflow-x: auto; border: 1px solid var(--rule); background: var(--surface); }
table { border-collapse: collapse; width: 100%; text-align: left; }
.official-rubric { min-width: 90rem; table-layout: fixed; font-size: .8rem; line-height: 1.7; }
.official-rubric.filtered { min-width: 0; }
.official-rubric caption { text-align: left; font-size: .75rem; padding: .8rem; color: var(--ink-soft); caption-side: bottom; border-top: 1px solid var(--rule); }
.official-rubric th, .official-rubric td { border-right: 1px solid var(--rule-soft); border-bottom: 1px solid var(--rule); padding: 1rem; vertical-align: top; }
.official-rubric thead th { background: var(--sunk); }
.official-rubric tbody th { background: var(--paper); font-weight: 600; }
.official-rubric.filtered tr > :first-child { width: 25%; }
.outcome { display: grid; grid-template-columns: 4rem minmax(0,1fr); gap: 1rem; padding: 1.5rem 0; border-top: 1px solid var(--rule); margin-top: 1.5rem; }
.outcome-id { font-size: 1.15rem; color: var(--accent-1-ink); margin: 0; }
.outcome .commentary { margin: 1rem 0; padding: .9rem 1rem; }
.outcome .commentary .voice { margin-bottom: .4rem; }
.connections { font-size: .78rem; line-height: 1.9; }
.mapping { margin-top: 1.5rem; font-size: .8rem; }
.mapping th, .mapping td { border: 1px solid var(--rule); padding: .7rem .5rem; text-align: center; }
.mapping th:first-child { text-align: left; }
.mapping th { background: var(--sunk); }
.mapping caption { text-align: left; font-size: .85rem; font-weight: 600; margin-bottom: 1rem; }
.mapping-figure figcaption { font-size: .78rem; }
.gc-entry { border-top: 1px solid var(--rule); padding: 1.25rem 0; }
.gc-entry h4 .mono { color: var(--accent-1-ink); margin-right: .5rem; }
.gc-entry > .connections { margin-bottom: .6rem; }
details { font-size: .85rem; }
summary { cursor: pointer; font-size: .8rem; font-weight: 600; }
details[open] > summary { margin-bottom: 1rem; }
.extra-frameworks, .module-aims { border: 1px solid var(--rule); padding: 1rem; margin: 1rem 0; background: var(--surface); }
.extra-frameworks .gc-entry:first-of-type { border-top: 0; }
dl { margin: 1rem 0; }
dl > div { display: grid; grid-template-columns: 5rem minmax(0,1fr); gap: 1rem; padding: .7rem 0; border-bottom: 1px solid var(--rule-soft); }
dt { font: 600 .8rem/1.8 var(--font-mono); }
dd { margin: 0; font-size: .85rem; line-height: 1.8; }
.fheq-group { margin: 1.5rem 0; }
.fheq-group h4 { padding-bottom: .7rem; border-bottom: 2px solid var(--ink); }
.skill-links { display: block; font-size: .72rem; color: var(--ink-soft); margin-top: .3rem; }
.review-list { margin: 1.5rem 0 1rem; border-top: 2px solid var(--ink); }
.review-row { padding: 1rem 0; border-bottom: 1px solid var(--rule); display: flex; align-items: flex-start; gap: 1rem; cursor: pointer; }
.review-row input { width: 1.2rem; height: 1.2rem; margin: .25rem 0; flex: none; accent-color: var(--accent-1-ink); }
.review-row > span { display: grid; gap: .3rem; }
.review-row strong { font-size: .75rem; }
.review-row > span > span { font-family: var(--font-serif); font-size: 1rem; }
.review-row:has(input:checked) { background: var(--surface); }
.small-note { font-size: .75rem !important; color: var(--muted); }
footer { padding: 1.5rem 0 2rem; border-top: 1px solid var(--rule); }
footer p { font-size: .85rem; }
footer > div { display: flex; justify-content: space-between; gap: 1rem; font-size: .72rem; color: var(--muted); }
@media (max-width: 1100px) {
  main.canvas { width: calc(100% - 3rem); }
  .criterion-body { grid-template-columns: minmax(0,1fr); }
}
@media (max-width: 1023px) {
  body { display: block; }
  .index-nav .nav-inner { padding: .65rem 1rem; }
  .index-nav .studio-brand, .nav-foot { display: none !important; }
  .index-nav a { padding: .4rem .55rem; white-space: nowrap; }
  :target { scroll-margin-top: 5rem; }
}
@media (max-width: 760px) {
  main.canvas { width: calc(100% - 2rem); }
  .section { padding-block: 2rem; }
  .weight-band { display: grid; grid-template-columns: 1fr 1fr; }
  .weight-band a { min-height: 9rem; }
  .weights figcaption::after { content: ' Read the percentages for the weights; panels are equal-sized on small screens.'; }
  .criterion-head h3 { font-size: 1.1rem; }
  .criterion-weight { font-size: 1.8rem; }
  .criterion-body { gap: 1rem; }
  .official-panel, .commentary { padding: 1rem; }
  .grade-step { grid-template-columns: 6.5rem minmax(0,1fr); gap: 1rem; }
  .grade-step strong { font-size: 1.2rem; }
  .rubric-scroll { overflow: visible; border: 0; background: transparent; }
  .official-rubric, .official-rubric tbody, .official-rubric tr, .official-rubric td, .official-rubric tbody th { display: block; min-width: 0; width: 100% !important; }
  .official-rubric thead { display: none; }
  .official-rubric tbody th { padding: 1rem 0; margin-top: 1rem; border: 0; font-size: 1rem; }
  .official-rubric td { background: var(--surface); border: 1px solid var(--rule); border-bottom: 0; }
  .official-rubric td:last-child { border-bottom: 1px solid var(--rule); }
  .official-rubric td::before { content: attr(data-label); display: block; font-weight: 700; color: var(--accent-1-ink); margin-bottom: .6rem; }
  .official-rubric caption { display: block; border: 0; padding: 1rem 0; }
  .outcome { grid-template-columns: 1fr; gap: .5rem; }
  .mapping th, .mapping td { padding: .6rem .3rem; font-size: .7rem; }
  dl > div { grid-template-columns: 4rem minmax(0,1fr); gap: .6rem; }
}
@media print {
  @page { margin: 15mm; }
  body { display: block; }
  main.canvas { width: 100%; }
  .page-header h1 { font-size: 2rem; }
  .band-control, .reading-key, footer > div { display: none !important; }
  .criterion-body { display: block; }
  .criterion-body .commentary { margin-top: 1rem; }
  .official-rubric, .official-rubric tbody, .official-rubric tr, .official-rubric td, .official-rubric tbody th { display: block; min-width: 0; width: 100% !important; }
  .official-rubric thead { display: none; }
  .official-rubric tbody [data-band][hidden] { display: block !important; }
  .official-rubric td::before { content: attr(data-label); display: block; font-weight: 700; margin-bottom: .5rem; }
  .official-rubric th, .official-rubric td { border: 0; border-bottom: 1px solid var(--rule); }
  .official-rubric tr { margin-bottom: 1.5rem; }
  .official-rubric td { break-inside: avoid; }
  .rubric-scroll { border: 0; overflow: visible; }
  .official-rubric caption { display: block; }
  .official-panel, .commentary { background: transparent; border: 1px solid var(--rule); }
  .commentary { border-left: 3px solid var(--ink); }
  details, .gc-entry, .outcome, .criterion { break-inside: auto; }
  a[href^="http"]::after { overflow-wrap: anywhere; }
}
