@font-face {
  font-family: "Atkinson Next";
  src: url("/fonts/atkinson-hyperlegible-next-latin-wght-normal.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Atkinson Next";
  src: url("/fonts/atkinson-hyperlegible-next-latin-wght-italic.woff2") format("woff2");
  font-weight: 200 800;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Atkinson Mono";
  src: url("/fonts/atkinson-hyperlegible-mono-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #ffffff;
  --panel: #eef2f3;
  --ink: #142026;
  --soft: #4d5b62;
  --rule: #cfd8db;
  --teal: #0f766e;
  --col: 42rem;
  --wide: 56rem;
  --sans: "Atkinson Next", "Atkinson Hyperlegible", Georgia, serif;
  --mono: "Atkinson Mono", "Atkinson Hyperlegible Mono", ui-monospace, monospace;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-weight: 400;
  font-variant-numeric: tabular-nums;
}
img, svg { max-width: 100%; height: auto; }

a { color: var(--ink); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.18em; text-decoration-color: var(--soft); }
a:hover { text-decoration-thickness: 2px; text-decoration-color: var(--ink); }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; }

.skip { position: absolute; left: -999px; top: 0; background: var(--paper); padding: 0.5rem 1rem; }
.skip:focus { left: 1rem; z-index: 10; }

/* Masthead */
.mast {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 1.25rem 1rem 0.9rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 2rem;
  align-items: baseline;
  justify-content: space-between;
  border-bottom: 1px solid var(--ink);
}
.mark { display: inline-flex; gap: 0.6rem; align-items: center; text-decoration: none; font-weight: 800; font-size: 1.12rem; letter-spacing: -0.01em; }
.mark svg { width: 22px; height: 22px; flex: none; }
.mast nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.25rem 1.1rem; font-size: 0.95rem; }
.mast nav a { text-decoration: none; }
.mast nav a:hover, .mast nav a[aria-current="page"] { text-decoration: underline; text-decoration-thickness: 2px; }

/* Reading column */
main { max-width: var(--col); margin: 0 auto; padding: 2.5rem 1rem 4rem; }
.crumbs { font-size: 0.9rem; color: var(--soft); margin: 0 0 1.75rem; }
.crumbs a { color: var(--soft); }
.crumbs span[aria-hidden] { padding: 0 0.35rem; }

h1, h2, h3, h4 { line-height: 1.15; margin: 0; letter-spacing: -0.015em; }
h1 { font-size: clamp(2.1rem, 6vw, 3.1rem); font-weight: 800; margin-bottom: 1rem; max-width: 20ch; }
h2 { font-size: 1.5rem; font-weight: 700; margin: 3.25rem 0 0.9rem; }
h3 { font-size: 1.15rem; font-weight: 700; margin: 2rem 0 0.5rem; }
p { margin: 0 0 1rem; }
ul, ol { padding-left: 1.3rem; margin: 0 0 1.25rem; }
li { margin-bottom: 0.4rem; }
.lead { font-size: 1.2rem; line-height: 1.5; margin-bottom: 1.6rem; }
.note { font-weight: 300; font-style: italic; color: var(--soft); font-size: 0.97rem; }
.data, time, .mono { font-family: var(--mono); font-size: 0.93em; letter-spacing: 0; }
hr { border: 0; border-top: 1px solid var(--rule); margin: 3rem 0; }
blockquote { margin: 1.5rem 0; padding-left: 1rem; border-left: 1px solid var(--ink); }

/* Panels: finder and worksheets */
.panel { background: var(--panel); padding: 1.5rem 1.25rem 1.75rem; margin: 1.5rem 0 2rem; }
.panel > h2:first-child, .panel > h3:first-child { margin-top: 0; }

.finder fieldset { border: 0; margin: 0; padding: 1.1rem 0 1.25rem; border-top: 1px solid var(--rule); display: grid; grid-template-columns: 2.6rem 1fr; column-gap: 0.75rem; }
.finder fieldset:first-of-type { border-top: 0; padding-top: 0.25rem; }
.finder .qn { grid-row: span 2; font-weight: 800; font-size: 2rem; line-height: 1; color: var(--ink); font-variant-numeric: tabular-nums; }
.finder legend { float: left; width: 100%; padding: 0; font-weight: 700; font-size: 1.08rem; margin-bottom: 0.55rem; line-height: 1.3; }
.finder .opts { display: flex; flex-wrap: wrap; gap: 0.45rem; clear: both; }
.finder label { display: inline-flex; align-items: center; gap: 0.5rem; background: var(--paper); border: 1px solid var(--rule); border-radius: 2px; padding: 0.45rem 0.8rem; cursor: pointer; font-size: 0.98rem; line-height: 1.3; }
.finder input[type="radio"] { position: absolute; opacity: 0; width: 1px; height: 1px; }
.finder label::before { content: ""; width: 0.8rem; height: 0.8rem; border-radius: 50%; border: 1.5px solid var(--soft); flex: none; }
.finder input:checked + label { border-color: var(--teal); color: var(--teal); font-weight: 700; }
.finder input:checked + label::before { border-color: var(--teal); background: var(--teal); box-shadow: inset 0 0 0 2px var(--paper); }
.finder input:focus-visible + label { outline: 3px solid var(--teal); outline-offset: 2px; }
.finder .go { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; border-top: 1px solid var(--ink); padding-top: 1.1rem; }
button, .btn { font: inherit; font-weight: 700; background: var(--ink); color: var(--paper); border: 0; border-radius: 2px; padding: 0.7rem 1.2rem; cursor: pointer; text-decoration: none; }
button:hover { background: #24343c; }

/* Tool-type map */
.map { max-width: var(--wide); margin: 1rem 0 0.5rem; background: var(--panel); padding: 1rem 0.75rem; overflow-x: auto; }
.map svg { display: block; min-width: 560px; width: 100%; }
.map text { font-family: var(--sans); fill: var(--ink); }
.map a { text-decoration: none; }
.map a:hover, .map a:focus { text-decoration: underline; }
.key { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; font-size: 0.92rem; color: var(--soft); margin: 0.5rem 0 1rem; }
.key svg { width: 14px; height: 14px; vertical-align: -2px; margin-right: 0.35rem; }

/* Wide blocks may break out of the column on desktop */
@media (min-width: 64rem) {
  .bleed { margin-left: calc((var(--col) - var(--wide)) / 2 + 1rem); margin-right: calc((var(--col) - var(--wide)) / 2 + 1rem); }
}

/* Reference tables */
.tablewrap { overflow-x: auto; margin: 1rem 0 1.75rem; }
table { border-collapse: collapse; width: 100%; font-size: 0.95rem; font-variant-numeric: tabular-nums lining-nums; }
caption { text-align: left; font-weight: 700; padding-bottom: 0.5rem; }
th, td { text-align: left; vertical-align: top; padding: 0.55rem 0.75rem 0.55rem 0; border-bottom: 1px solid var(--rule); }
thead th { font-weight: 700; color: var(--soft); border-bottom: 1px solid var(--ink); font-size: 0.9rem; }
tbody th { font-weight: 700; }
td.num, th.num { text-align: right; font-family: var(--mono); white-space: nowrap; }
.st { white-space: nowrap; }
.st svg { width: 12px; height: 12px; vertical-align: -1px; margin-right: 0.35rem; }

dl.facts { display: grid; grid-template-columns: minmax(7rem, 11rem) 1fr; margin: 1.25rem 0 2rem; border-top: 1px solid var(--ink); }
dl.facts dt, dl.facts dd { margin: 0; padding: 0.55rem 0; border-bottom: 1px solid var(--rule); }
dl.facts dt { font-weight: 700; padding-right: 1rem; }

/* Lists of vendors, lessons, desk items */
.reflist { list-style: none; padding: 0; margin: 0 0 2rem; border-top: 1px solid var(--ink); }
.reflist > li { padding: 0.85rem 0; border-bottom: 1px solid var(--rule); margin: 0; }
.reflist .name { font-weight: 700; }
.reflist .line { display: block; color: var(--soft); font-size: 0.97rem; margin-top: 0.15rem; }
ol.course { list-style: none; counter-reset: c; padding: 0; border-top: 1px solid var(--ink); }
ol.course > li { counter-increment: c; display: grid; grid-template-columns: 2.4rem 1fr; padding: 0.8rem 0; border-bottom: 1px solid var(--rule); margin: 0; }
ol.course > li::before { content: counter(c); font-weight: 800; font-size: 1.4rem; line-height: 1.2; }
ol.course .line { grid-column: 2; color: var(--soft); font-size: 0.97rem; }
.desklist time { display: block; color: var(--soft); font-size: 0.85rem; }

/* Worksheet */
.worksheet ul.checks { list-style: none; padding: 0; margin: 0; }
.worksheet ul.checks li { display: grid; grid-template-columns: 1.5rem 1fr; gap: 0.6rem; padding: 0.5rem 0; border-bottom: 1px solid var(--rule); margin: 0; }
.worksheet input[type="checkbox"] { appearance: none; -webkit-appearance: none; width: 1.05rem; height: 1.05rem; border: 1.5px solid var(--ink); border-radius: 0; margin: 0.22rem 0 0; background: var(--paper); cursor: pointer; }
.worksheet input[type="checkbox"]:checked { background: var(--ink); box-shadow: inset 0 0 0 2px var(--paper); }
.worksheet label { cursor: pointer; }
.why li.picked { color: var(--teal); font-weight: 700; }
.match { color: var(--teal); }
.matchbox { border: 2px solid var(--teal); padding: 1rem 1.1rem; margin: 0 0 2rem; }
.matchbox p { margin: 0; }

.faq dt { font-weight: 700; margin-top: 1.4rem; }
.faq dd { margin: 0.35rem 0 0; }
.sources { font-size: 0.95rem; }
.sources li { overflow-wrap: anywhere; }
.pair { display: grid; grid-template-columns: 1fr; gap: 0 2rem; }
@media (min-width: 40rem) { .pair { grid-template-columns: 1fr 1fr; } }
.pair h3 { margin-top: 1.25rem; }

/* Footer */
.foot { border-top: 1px solid var(--ink); margin-top: 3rem; }
.foot .in { max-width: var(--wide); margin: 0 auto; padding: 2rem 1rem 3rem; display: grid; gap: 1.5rem; grid-template-columns: 1fr; font-size: 0.93rem; }
@media (min-width: 48rem) { .foot .in { grid-template-columns: 2fr 1fr 1fr; } }
.foot ul { list-style: none; padding: 0; margin: 0; }
.foot li { margin-bottom: 0.3rem; }
.foot .pub { font-weight: 400; max-width: 34rem; }
.foot .pub strong { font-weight: 700; }
.foot .upd { color: var(--soft); }

@media (max-width: 30rem) {
  main { padding-top: 1.75rem; }
  .finder fieldset { grid-template-columns: 1fr; }
  .finder .qn { grid-row: auto; font-size: 1.5rem; margin-bottom: 0.25rem; }
  dl.facts { grid-template-columns: 1fr; }
  dl.facts dt { border-bottom: 0; padding-bottom: 0; }
}

@media print {
  @page { margin: 16mm 14mm; }
  body { font-size: 10.5pt; line-height: 1.45; color: #000; }
  .mast nav, .foot .in > div:not(.pubcol), .skip, .crumbs, .noprint, .finder .go button { display: none; }
  .mast { border-bottom: 1px solid #000; padding: 0 0 4mm; }
  main { max-width: none; padding: 6mm 0 0; }
  h1 { font-size: 20pt; max-width: none; }
  h2 { font-size: 13pt; margin-top: 7mm; break-after: avoid; }
  .panel, .map { background: none; padding: 0; border: 1px solid #000; padding: 4mm; }
  .worksheet ul.checks li { break-inside: avoid; }
  .worksheet input[type="checkbox"] { border: 1px solid #000; }
  .reflist > li, tr { break-inside: avoid; }
  a { text-decoration: none; }
  .sources a[href^="http"]::after, .worksheet a[href^="http"]::after { content: " <" attr(href) ">"; font-size: 8pt; overflow-wrap: anywhere; }
  .foot { margin-top: 6mm; }
  .foot .in { padding: 3mm 0 0; display: block; }
}
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
