:root {
  color-scheme: light dark;
  --page: var(--paper);
  --text: var(--ink);
  --muted: var(--secondary);
  --link: var(--plum);
  --draft: var(--gold-wash);
  --draft-text: var(--gold);
  font: 100%/1.65 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--page);
  color: var(--text);
}

* { box-sizing: border-box; }
body { max-width: 48rem; margin: auto; padding: 1.5rem; overflow-wrap: anywhere; }
header { border-bottom: 1px solid var(--line); padding-bottom: 1.25rem; }
.brand { font-weight: 700; font-size: 1.25rem; margin: 0 0 0.5rem; }
.brand a { display: inline-block; min-height: 44px; padding-block: 0.4rem; color: var(--ink); text-decoration: none; }
.brand a:hover { text-decoration: underline; }
nav { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; }
a { color: var(--link); text-underline-offset: 0.18em; }
nav a { display: inline-block; padding-block: 0.6rem; }
a[aria-current="page"] { font-weight: 700; }
a:focus-visible { outline: 3px solid currentColor; outline-offset: 4px; border-radius: 2px; }
h1, h2 { line-height: 1.25; text-wrap: balance; }
h1 { font-family: Georgia, "Times New Roman", serif; font-weight: 500; font-size: clamp(2rem, 6vw, 3rem); margin: 2rem 0 1rem; }
h2 { font-size: 1.4rem; margin-top: 2.25rem; }
p, ul { margin-block: 1rem; }
li + li { margin-top: 0.5rem; }
ul { padding-left: 1.5rem; }
code { font-size: 0.95em; }
.draft { background: var(--draft); color: var(--draft-text); padding: 1rem; border: 1px solid currentColor; border-radius: 0.4rem; }
footer { margin-top: 3rem; padding-top: 1rem; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.95rem; }
.skip { position: absolute; top: -5rem; background: var(--page); padding: 0.5rem; z-index: 1; }
.skip:focus { top: 0.5rem; }

@media print {
  :root { color-scheme: light; }
  body { max-width: none; padding: 0; }
  nav, .skip { display: none; }
  a { text-decoration: underline; }
}
