:root {
  --paper: #fffaf0;
  --card: #ffffff;
  --ink: #30251d;
  --muted: #655344;
  --rule: #c9bbaa;
  --gold: #f1cf7b;
  --rust: #903c13;
  --soft: #f5ead7;
  --focus: #245c78;
  --serif: Georgia, "Times New Roman", serif;
  --sans: Arial, Helvetica, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 1rem; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 18px/1.65 var(--sans); }
a { color: var(--rust); text-underline-offset: .2em; }
a, button { -webkit-tap-highlight-color: transparent; }
button, input, textarea { font: inherit; }
button, summary, label { touch-action: manipulation; }
button { cursor: pointer; }
button:disabled { cursor: default; }
input, textarea, button { border-radius: 4px; }
textarea { resize: vertical; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; line-height: 1.12; text-wrap: balance; }
h1 { font-size: clamp(2.5rem, 5.2vw, 4.8rem); letter-spacing: -.045em; max-width: 17ch; }
h2 { font-size: clamp(1.9rem, 3.2vw, 2.6rem); letter-spacing: -.025em; }
h3 { font-size: 1.55rem; line-height: 1.25; }
ul, ol { padding-left: 1.3em; }
li + li { margin-top: .65rem; }
::selection { background: var(--gold); color: var(--ink); }
.u-wrap { width: min(1120px, calc(100% - 64px)); margin-inline: auto; }
.u-read { max-width: 68ch; }
.u-stack > * + * { margin-top: 1.2rem; }
.u-stack-lg > * + * { margin-top: 2rem; }
.u-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 2.4rem; }
.u-wide { grid-column: 1 / -1; }
.u-flex { display: flex; align-items: center; flex-wrap: wrap; gap: .9rem; }
.u-between { justify-content: space-between; }
.u-muted { color: var(--muted); }
.u-kicker { font-size: 16px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; }
.u-small { font-size: 16px; line-height: 1.55; }
.u-rule { padding-top: 2rem; border-top: 1px solid var(--rule); }
.u-pad { padding: 2rem; }
.u-paper { background: var(--card); border: 1px solid var(--rule); }
.u-gold { background: var(--gold); }
.u-soft { background: var(--soft); }
.u-link { display: inline-flex; align-items: center; min-height: 48px; padding-block: .55rem; font-size: 16px; }
.u-button { display: inline-flex; align-items: center; justify-content: center; gap: .6rem; min-height: 48px; padding: .65rem 1.15rem; border: 2px solid var(--ink); background: var(--ink); color: var(--paper); font-size: 17px; font-weight: 700; text-decoration: none; }
.u-button:hover { background: #4f3c2b; }
.u-button-outline { background: transparent; color: var(--ink); }
.u-button-outline:hover { background: var(--soft); }
.u-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
[hidden] { display: none !important; }
[data-role="skip"] { position: absolute; z-index: 10; top: -100px; left: 1rem; padding: .6rem 1rem; min-height: 48px; color: var(--paper); background: var(--ink); }
[data-role="skip"]:focus { top: 1rem; }
[data-role="masthead"] { border-top: 6px solid var(--rust); padding-block: 1.1rem; }
[data-role="home-link"] { color: var(--ink); text-decoration: none; display: flex; flex-direction: column; justify-content: center; min-height: 48px; line-height: 1.35; font-size: 16px; }
[data-role="home-link"] strong { font-size: 19px; letter-spacing: -.03em; }
[data-role="intro"] { padding: 3rem 0 3.6rem; border-bottom: 1px solid var(--rule); }
[data-role="intro"] .u-kicker { margin-bottom: 1.35rem; }
[data-role="intro"] h1 + p { margin-top: 1.4rem; max-width: 56ch; font-size: 20px; line-height: 1.6; }
[data-role="intro"] .u-flex { margin-top: 1.6rem; }
[data-role="scenario"] { border-left: 5px solid var(--gold); padding-left: 1.35rem; margin-top: 2.5rem; max-width: 62ch; }
[data-role="scenario"] .u-kicker { margin-bottom: .5rem; color: var(--muted); }
[data-role="content"] { padding-block: 3.1rem 4rem; }
[data-role="section"] + [data-role="section"] { margin-top: 3rem; }
[data-role="section"] > h2 { margin-bottom: 1.3rem; }
[data-role="claim-pair"] { margin-top: 1.25rem; padding-bottom: 1.25rem; border-bottom: 1px solid var(--rule); }
[data-role="claim-pair"]:last-child { padding-bottom: 0; border-bottom: 0; }
[data-role="source"] { display: inline-flex; align-items: center; min-height: 44px; gap: .7rem; margin-top: .4rem; font-size: 16px; line-height: 1.4; }
[data-role="source"]::before { content: "↗"; font-size: 18px; text-decoration: none; }
[data-role="reading-card"] { border-top: 5px solid var(--rust); }
[data-role="graphic"] { background: var(--soft); padding: 1.8rem; }
[data-role="graphic"] figcaption { font-size: 16px; font-weight: 700; line-height: 1.5; margin-bottom: 1.25rem; }
[data-role="route-list"] { padding: 0; list-style: none; }
[data-role="route-list"] li { border-top: 1px solid #b9a78b; padding-top: 1rem; margin-top: 1rem; font-size: 16px; }
[data-role="route-list"] strong { display: block; color: var(--ink); font-size: 18px; }
[data-role="route-list"] a { display: flex; min-height: 48px; align-items: center; justify-content: space-between; }
[data-role="worksheet"] { position: relative; border: 1px solid var(--rule); background: var(--card); padding: 2rem; }
[data-role="worksheet"]::before { content: ""; position: absolute; left: 0; top: 0; right: 0; height: 7px; background: repeating-linear-gradient(90deg, var(--gold), var(--gold) 16px, transparent 16px, transparent 24px); }
[data-role="worksheet"] h2, [data-role="worksheet"] h3 { margin-bottom: .7rem; }
[data-role="worksheet"] label:not([data-role="check"]) { display: block; margin-top: 1.25rem; font-weight: 700; line-height: 1.45; }
[data-role="worksheet"] textarea, [data-role="worksheet"] input[type="text"] { width: 100%; max-width: 100%; background: var(--paper); color: var(--ink); border: 1px solid #9c8b79; padding: .7rem .8rem; margin-top: .45rem; font-size: 18px; line-height: 1.5; }
[data-role="worksheet"] textarea { min-height: 100px; }
[data-role="check-list"] { padding: 0; list-style: none; margin-top: 1rem; }
[data-role="check-list"] li { margin: 0; border-bottom: 1px solid var(--rule); }
[data-role="check"] { display: flex; align-items: flex-start; gap: .9rem; min-height: 52px; padding-block: .8rem; font-size: 18px; line-height: 1.5; cursor: pointer; }
[data-role="check"] input { flex: 0 0 44px; width: 44px; height: 44px; margin: 0; accent-color: var(--rust); }
[data-role="note-tools"] { padding-top: 1.6rem; margin-top: 1.3rem; border-top: 1px solid var(--rule); }
[data-role="save-status"] { margin-top: .8rem; min-height: 1.55em; }
[data-role="progress"] { display: flex; flex-wrap: wrap; gap: .8rem; align-items: center; margin-top: 1rem; font-size: 16px; }
meter { accent-color: var(--rust); width: min(150px, 100%); height: 16px; }
[data-role="next"] { margin-top: 3rem; border-top: 1px solid var(--rule); padding-top: 1.5rem; }
[data-role="next"] a { display: inline-flex; align-items: center; gap: .8rem; min-height: 48px; font-size: 18px; }
[data-role="directory"] { background: var(--ink); color: var(--paper); padding-block: 3rem 2rem; }
[data-role="directory"] h2 { color: var(--gold); }
[data-role="directory"] .u-grid { column-gap: 3rem; row-gap: 0; margin-top: 1.2rem; }
[data-role="directory"] a { display: flex; gap: 1rem; justify-content: space-between; align-items: center; min-height: 64px; padding: .9rem 0; border-bottom: 1px solid #786451; color: var(--paper); text-decoration: none; font-size: 18px; }
[data-role="directory"] a:hover { color: var(--gold); }
[data-role="directory"] a[aria-current="page"] { color: var(--gold); }
[data-role="footer-line"] { max-width: 70ch; padding-top: 2rem; font-size: 16px; }
[data-role="urgent"] { border-left: 6px solid var(--rust); padding: 1.6rem; background: #fae8d9; }
[data-role="urgent"] h2 { margin-bottom: 1rem; }
[data-role="quote-grid"] { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 1.5rem; }
[data-role="erase-dialog"] { width: min(460px, calc(100% - 32px)); border: 2px solid var(--ink); border-radius: 4px; background: var(--paper); color: var(--ink); padding: 1.6rem; font-size: 18px; }
[data-role="erase-dialog"]::backdrop { background: rgb(48 37 29 / .6); }
[data-role="erase-dialog"] .u-flex { margin-top: 1.5rem; }
@media (max-width: 720px) {
  .u-wrap { width: calc(100% - 36px); }
  .u-grid { grid-template-columns: minmax(0, 1fr); gap: 1.6rem; }
  .u-wide { grid-column: auto; }
  .u-pad, [data-role="worksheet"], [data-role="graphic"] { padding: 1.4rem; }
  [data-role="intro"] { padding-block: 1.8rem 2.3rem; }
  [data-role="intro"] h1 + p { font-size: 18px; }
  [data-role="content"] { padding-block: 2rem 3rem; }
  [data-role="scenario"] { margin-top: 1.7rem; }
  [data-role="quote-grid"] { grid-template-columns: minmax(0, 1fr); }
  [data-role="directory"] .u-grid { row-gap: 0; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
@media print {
  body { background: #fff; color: #000; font-size: 16px; }
  .u-wrap { width: 100%; }
  [data-role="masthead"], [data-role="directory"], [data-role="next"], [data-role="note-tools"], [data-role="progress"], [data-role="skip"], [data-role="intro"] .u-flex { display: none; }
  [data-role="intro"], [data-role="content"] { padding-block: 1rem; }
  h1 { font-size: 32px; max-width: 100%; }
  h2 { font-size: 24px; }
  h3 { font-size: 20px; }
  .u-grid { display: block; }
  .u-grid > * + * { margin-top: 1rem; }
  [data-role="worksheet"], [data-role="reading-card"] { border: 1px solid #777; padding: 1rem; }
  [data-role="worksheet"] textarea { background: #fff; min-height: 90px; }
  [data-role="source"] { color: #000; }
  [data-role="check"] { color: #000; }
  [data-role="urgent"] { background: #fff; border-color: #000; }
  p, li, [data-role="check"], h2, h3 { break-inside: avoid; }
}
