@font-face {
  font-family: Inter;
  src: url("fonts/InterVariable.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}
:root {
  color-scheme: dark;
  --page: #191c22;
  --shelf: #16191e;
  --panel: #151a22;
  --line: #343a45;
  --fg: #e3e7ee;
  --muted: #b1bac8;
  --quiet: #a2adbc;
  --accent: #aacbf7;
  font: 100%/1.5 Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  background: var(--page);
  color: var(--fg);
  scrollbar-color: #535e6e var(--shelf);
}
* { box-sizing: border-box; }
body, h1, h2, h3, p, figure, dl, dd, ul, ol { margin: 0; }
body { min-height: 100vh; }
input, button { font: inherit; color: inherit; }
button, summary { cursor: pointer; }
button:disabled { cursor: default; }
a { color: var(--accent); text-underline-offset: .2em; }
a:focus-visible, button:focus-visible, input:focus-visible, summary:focus-visible, [tabindex="0"]:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 3px;
}
[hidden] { display: none !important; }
.sr-only, .skip:not(:focus) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip:focus { position: fixed; z-index: 10; top: 8px; left: 8px; padding: 6px 12px; background: var(--panel); }
::selection { background: #bbd2ef; color: #101822; }
.book-layout { display: grid; grid-template-columns: 248px minmax(0,1fr); max-width: 1190px; min-height: 100vh; margin: 0 auto; }
.shelf {
  position: sticky; top: 0; align-self: start; height: 100vh; height: 100dvh; overflow-y: auto;
  background: var(--shelf); border-right: 1px solid var(--line); padding: 23px 17px 32px;
}
.shelf-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.wordmark { color: var(--fg); font: 600 1.375rem/1.25 Georgia, "Times New Roman", serif; text-decoration: none; }
.toc-toggle { color: var(--accent); background: none; border: 1px solid var(--line); padding: 3px 8px; border-radius: 4px; font-size: .8rem; }
#search-form, .word-filter {
  display: flex; align-items: center; gap: 9px; border: 1px solid #454c57; background: #1e232b; border-radius: 5px;
}
#search-form { margin: 18px 0; padding: 0 8px 0 11px; }
#search-form:focus-within, .word-filter:focus-within { border-color: var(--accent); outline: 1px solid var(--accent); }
.magnifier { width: 12px; height: 12px; border: 1.3px solid var(--muted); border-radius: 50%; position: relative; flex: none; }
.magnifier:after { content: ""; position: absolute; right: -5px; bottom: -2px; width: 6px; height: 1.3px; background: var(--muted); transform: rotate(45deg); }
input[type=search] { min-width: 0; width: 100%; border: 0; background: transparent; padding: 7px 2px; font-size: .875rem; line-height: 1.4; }
input[type=search]:focus-visible { outline: 0; }
::placeholder { color: var(--quiet); opacity: 1; }
#search::-webkit-search-cancel-button { appearance: none; }
#clear-search { flex: none; width: 25px; height: 33px; border: 0; padding: 0; background: none; color: var(--muted); font-size: 1.1rem; }
#topics { margin-top: 10px; }
.toc-group { border-bottom: 1px solid #2c3139; }
.toc-group summary { display: flex; align-items: center; gap: 9px; padding: 9px 3px; color: #d5dbe3; font-weight: 580; font-size: .875rem; list-style: none; }
summary::-webkit-details-marker { display: none; }
.toc-group summary::before, .word-group summary::before {
  content: ""; width: 6px; height: 6px; border: solid var(--quiet); border-width: 1px 1px 0 0; transform: rotate(45deg); flex: none;
}
.toc-group[open] > summary::before, .word-group[open] > summary::before { transform: rotate(135deg); }
.toc-group ul { list-style: none; padding: 0 0 7px; }
.toc-group li + li { margin-top: 1px; }
.toc-group a { display: block; border-left: 2px solid transparent; color: var(--muted); font-size: .875rem; line-height: 1.38; padding: 5px 8px 5px 17px; text-decoration: none; }
.toc-group a:hover, .toc-group summary:hover { color: var(--fg); background: #1c2129; }
.toc-group a[aria-current] { color: #deebff; background: #222a36; border-color: #94b8ed; font-weight: 575; }
.article { width: 100%; max-width: 852px; min-width: 0; padding: 25px 38px 52px; }
.article:focus, #topics:focus { outline: none; }
.context { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 8px; color: var(--quiet); font-size: .805rem; line-height: 1.4; }
.context a { color: var(--quiet); text-decoration: none; }
.context a:hover, .forward:hover, .wordmark:hover { text-decoration: underline; }
.section-context { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.dictionary-jump { color: var(--quiet); font-size: .79rem; text-decoration: none; }
.dictionary-jump:hover { color: var(--accent); text-decoration: underline; }
h1 { font: 600 1.625rem/1.2 Georgia, "Times New Roman", serif; letter-spacing: -.012em; margin: 12px 0 10px; }
h2 { font: 600 1.19rem/1.3 Georgia, "Times New Roman", serif; }
h3 { font-weight: 600; font-size: 1rem; line-height: 1.4; }
.lead, .reading p, .stage p, .entry-definition {
  font-size: 1rem; line-height: 1.58; max-width: 69ch; color: #dce1e8; overflow-wrap: break-word; text-wrap: pretty;
}
.term-link { color: inherit; text-decoration: underline dotted #74879f 1px; text-underline-offset: .23em; cursor: help; }
.term-link:hover, .term-link[aria-expanded=true] { color: #cce2ff; text-decoration: underline solid; }
.term-popup {
  position: fixed; z-index: 15; inset: auto; width: min(325px,calc(100vw - 16px)); max-height: calc(100dvh - 16px); overflow: auto;
  padding: 10px 13px; border: 1px solid #a9b6c8; border-radius: 5px; background: #e0e6ee; color: #172232;
  font-size: .875rem; line-height: 1.45; box-shadow: 0 4px 16px #0003; overflow-wrap: anywhere;
}
.term-popup strong { font-size: .925rem; }
.term-popup .aka { margin-left: 6px; color: #42566e; font-size: .81rem; }
.term-popup p { margin-top: 4px; }
.overview-diagram { padding: 15px 12px 11px; margin: 16px 0 15px; border-block: 1px solid #323944; background: var(--panel); }
.diagram-rail { display: flex; align-items: center; justify-content: center; max-width: 620px; margin: 0 auto; }
.diagram-node { display: grid; place-items: center; gap: 5px; flex: 0 1 130px; min-width: 0; text-align: center; font-size: .83rem; line-height: 1.35; }
.wire { position: relative; align-self: flex-start; flex: 1; min-width: 12px; height: 1px; background: #849bb7; margin: 17px -3px 0; }
.wire:after { content: ""; position: absolute; top: -2.5px; right: 0; height: 5px; width: 5px; border: solid #849bb7; border-width: 1px 1px 0 0; transform: rotate(45deg); }
.device { position: relative; display: grid; place-items: center; width: 46px; height: 32px; color: #b6c9e0; }
.device::before, .device::after, .device i { position: absolute; }
.device::before, .device::after { content: ""; }
.device-pc::before, .device-window::before { border: 1.5px solid; border-radius: 2px; inset: 1px 5px 7px; }
.device-pc::after { height: 2px; bottom: 3px; width: 44px; background: currentColor; }
.device-window::after { height: 1px; top: 7px; width: 34px; background: currentColor; }
.device-switch::before { border: 1.5px solid; border-radius: 3px; inset: 9px 0 4px; }
.device-switch i { top: 17px; width: 4px; height: 4px; background: currentColor; box-shadow: 7px 0 currentColor,14px 0 currentColor,-7px 0 currentColor,-14px 0 currentColor; }
.device-router::before, .device-disk::before { border: 1.5px solid; border-radius: 50% / 23%; inset: 6px 2px 3px; }
.device-router::after { content: "⇄"; font: 16px/1 system-ui; }
.device-disk::after { border-bottom: 1px solid; border-radius: 50%; width: 40px; top: 9px; height: 7px; }
.device-server::before, .device-layers::before { inset: 4px 1px 4px; border: 1.5px solid; border-radius: 2px; }
.device-server i,.device-layers i { width: 41px; border-top: 1px solid; }
.device-server::after { top: 9px; left: 7px; background: currentColor; width: 3px; height: 3px; box-shadow: 0 12px currentColor; }
.device-person::before { width: 11px; height: 11px; border: 1.5px solid; border-radius: 50%; top: 1px; }
.device-person::after { width: 25px; height: 11px; border: 1.5px solid; border-radius: 12px 12px 2px 2px; bottom: 3px; }
.device-process::before { inset: 5px 11px; border: 1.5px solid; outline: 1px dashed; outline-offset: 2px; }
.device-thread::before { content: "↳"; font: 32px/.9 system-ui; }
.device-folder::before { border: 1.5px solid; border-radius: 2px; inset: 8px 4px 4px; }
.device-folder::after { border: 1.5px solid; border-bottom: 0; width: 13px; height: 4px; top: 4px; left: 4px; }
.device-file::before { border: 1px solid; inset: 2px 12px; border-radius: 2px; }
.device-file::after { width: 12px; height: 1px; background: currentColor; box-shadow: 0 4px currentColor; }
.overview-diagram figcaption { margin-top: 10px; color: var(--quiet); font-size: .775rem; line-height: 1.48; text-align: center; }
.section-line { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 4px 14px; margin: 18px 0 4px; }
.forward { font-size: .84rem; text-decoration: none; }
.definitions { margin: 0; }
.definition-row { display: grid; grid-template-columns: minmax(128px,29%) minmax(0,1fr); gap: 18px; align-items: baseline; padding: 10px 0; border-bottom: 1px solid var(--line); scroll-margin: 22px; overflow-wrap: anywhere; }
.definition-row:target, .chapter-words li:target { background: #212c3b; outline: 1px solid #4b6789; outline-offset: 1px; }
.definition-row dt { font-weight: 600; font-size: .925rem; line-height: 1.45; }
.definition-row dd { font-size: .95rem; line-height: 1.5; color: #cbd2dc; }
.aliases { display: block; color: var(--quiet); font-size: .76rem; line-height: 1.45; font-weight: 400; margin-top: 2px; }
.full-dictionary { margin: 24px 0; }
.word-filter { max-width: 320px; padding: 0 10px; margin: 12px 0; }
.word-group { border-bottom: 1px solid var(--line); }
.word-group summary { display: flex; align-items: center; gap: 11px; padding: 10px 0; list-style: none; font-size: .94rem; }
.word-count { color: var(--quiet); font-size: .78rem; margin-left: auto; font-variant-numeric: tabular-nums; }
.word-group[open] > summary { color: var(--accent); }
.word-group .definitions { padding-left: 16px; }
.word-group .definition-row:last-child { border: 0; }
.minor { font-size: .84rem; color: var(--muted); }
.next-chapter, .lesson-neighbours { border-top: 1px solid var(--line); margin-top: 24px; padding-top: 15px; }
.next-chapter > span, .lesson-neighbours small { display: block; font-size: .77rem; color: var(--quiet); }
@media (max-width: 900px) {
  .book-layout { grid-template-columns: 214px minmax(0,1fr); }
  .shelf { padding-inline: 13px; }
  .article { padding-inline: 23px; }
  .definition-row { gap: 12px; }
}
@media (max-width: 690px) {
  .book-layout { display: block; }
  .shelf { position: static; height: auto; overflow: visible; border: 0; border-bottom: 1px solid var(--line); padding: 10px 16px 9px; }
  .wordmark { font-size: 1.16rem; }
  .toc-toggle { min-height: 32px; }
  #search-form { margin: 5px 0 0; }
  input[type=search] { font-size: 1rem; }
  .book-ready .shelf:not(.toc-open) #topics { display: none; }
  .article { padding: 17px 16px 36px; }
  h1 { font-size: 1.5rem; margin: 8px 0; }
  .definition-row { grid-template-columns: 1fr; gap: 4px; padding: 9px 0; }
  .aliases { display: inline; margin-left: 6px; }
  .overview-diagram { margin: 12px 0; padding: 12px 6px 9px; }
  .diagram-node { font-size: .74rem; }
  .wire { margin: 16px -8px 0; }
  .word-group .definitions { padding-left: 7px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; }
}
@media (forced-colors: active) {
  .term-popup,.overview-diagram,.device { border-color: CanvasText; }
  .toc-group a[aria-current] { outline: 1px solid Highlight; }
}
