/* A figure-led research page. The paper's artwork and four operation colors
   provide the visual identity; layout stays deliberately quiet around them. */
:root {
  color-scheme: light;
  --ink: #172c40;
  --navy: #173c60;
  --body: #415264;
  --muted: #667380;
  --line: #dfe5ea;
  --surface: #f6f8fa;
  --reading: #ffbf00;
  --writing: #06b0f0;
  --sharing: #82f5b1;
  --interacting: #cd93e3;
  --serif: Georgia, "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body { margin: 0; background: #fff; color: var(--ink); font: 16px/1.65 var(--sans); -webkit-font-smoothing: antialiased; }
[hidden] { display: none !important; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .22em; }
a:hover { color: #075f96; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { cursor: default; opacity: .4; }
button, select { touch-action: manipulation; }
:focus-visible { outline: 3px solid #087cae; outline-offset: 5px; }
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3, h4, p, figure { margin: 0; }
h1, h2 { text-wrap: balance; }
p { text-wrap: pretty; }
sup { font-size: .65em; vertical-align: super; line-height: 0; }
.skip-link { position: fixed; top: -80px; left: 20px; padding: 10px 20px; background: #fff; z-index: 50; }
.skip-link:focus { top: 10px; }

/* A small masthead and reference-style chapter dots leave the figures room. */
.site-header {
  min-height: 64px; padding: 13px 4.2%; display: flex; align-items: center;
  justify-content: space-between; gap: 24px; border-bottom: 1px solid var(--line);
  background: #ffffffed; position: sticky; top: 0; z-index: 20; backdrop-filter: blur(12px);
}
.wordmark { font: bold 23px/1.2 var(--serif); text-decoration: none; white-space: nowrap; }
.wordmark > span { font-weight: 400; color: #718293; padding: 0 2px; }
.wordmark small { font: 11px var(--sans); color: var(--muted); letter-spacing: .09em; text-transform: uppercase; margin-left: 15px; }
.site-header nav { display: flex; align-items: center; gap: 28px; font-size: 14px; font-weight: 600; }
.site-header nav a { text-decoration: none; padding-block: 6px; }
.chapter-nav { position: fixed; right: 16px; top: 50%; transform: translateY(-50%); z-index: 25; display: grid; }
.chapter-nav a { width: 26px; height: 27px; display: grid; place-items: center; text-decoration: none; position: relative; }
.chapter-nav a::after { content: ""; width: 7px; height: 7px; border: 1px solid #9eabb7; border-radius: 50%; background: #fff; transition: transform .2s, background .2s; }
.chapter-nav a[aria-current]::after { transform: scale(1.35); background: var(--navy); border-color: var(--navy); }
.chapter-nav a span { position: absolute; right: 32px; opacity: 0; pointer-events: none; white-space: nowrap; font-size: 12px; background: #fff; padding: 2px 9px; box-shadow: 0 2px 12px #1b314318; border-radius: 4px; transition: opacity .15s; }
.chapter-nav a:hover span, .chapter-nav a:focus-visible span { opacity: 1; }
.reading-progress { position: fixed; bottom: 0; right: 0; padding: 6px 20px; border-top: 1px solid var(--line); border-left: 1px solid var(--line); font-size: 10px; background: #fffffff2; color: var(--muted); display: flex; gap: 20px; z-index: 20; letter-spacing: .04em; }

/* Centered cover: large title, manuscript symbols, then the original teaser. */
.cover { position: relative; padding: 52px 52px 58px; isolation: isolate; overflow: hidden; }
.cover::before {
  content: ""; position: absolute; z-index: -1; inset: 0 0 auto; height: 620px;
  background-image: linear-gradient(#fff0 10%, #fff 100%), linear-gradient(#1d496308 1px, transparent 1px), linear-gradient(90deg, #1d496308 1px, transparent 1px);
  background-size: 100% 100%, 52px 52px, 52px 52px; background-color: #f7f9fc;
}
.cover-inner { max-width: 1160px; margin: auto; text-align: center; }
h1 { color: var(--navy); font: bold clamp(36px, 4.3vw, 56px)/1.15 var(--serif); letter-spacing: -.035em; }
.title-line { display: block; }
.four-operations { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px 28px; margin-top: 27px; }
.four-operations a { display: inline-flex; gap: 9px; align-items: center; text-decoration: none; font: bold 24px/1.3 var(--serif); }
.four-operations img { width: 28px; height: 28px; transition: transform .18s; }
.four-operations a:hover img { transform: translateY(-3px); }
.four-operations .reading { color: #946000; }
.four-operations .writing { color: #007eac; }
.four-operations .sharing { color: #008538; }
.four-operations .interacting { color: #9c49bc; }
.cover-subtitle { font: 20px/1.5 var(--serif); margin-top: 7px; color: #5c6876; }
.byline { max-width: 960px; margin: 24px auto 0; }
.authors { font-size: 19px; font-weight: 550; line-height: 1.9; }
.author-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 0 24px; }
.author { white-space: nowrap; }
.affiliations { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 24px; max-width: 760px; margin: 10px auto 0; color: var(--body); font-size: 15px; line-height: 1.8; }
.affiliations span { white-space: nowrap; }
.author-notes { margin-top: 8px; font-size: 13px; color: var(--muted); }
.cover-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; margin-top: 23px; }
.button { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 9px 22px; border: 1px solid #cfd7df; border-radius: 7px; background: #fff; color: var(--ink); text-decoration: none; font-size: 14px; font-weight: 600; transition: background .15s, transform .15s; }
.button:hover { color: var(--ink); border-color: #8b9bab; transform: translateY(-1px); background: #f3f6f9; }
.button.primary { color: #fff; border-color: #172c40; background: #172c40; }
.button.primary:hover { background: #2b4b67; }
.cover .cover-figure { max-width: 1040px; margin: 30px auto 0; }
.cover-figure figcaption { max-width: 720px; }

/* Chapters: clear research headings, broad white figure surfaces, quiet captions. */
.chapter { max-width: 1200px; margin: auto; padding: 62px 52px 76px; position: relative; scroll-margin-top: 0; }
.chapter + .chapter { border-top: 1px solid var(--line); }
.chapter-heading { text-align: center; margin: 0 auto 34px; }
.kicker { letter-spacing: .045em; font-size: 15px; font-weight: 600; color: #52697d; margin-bottom: 15px; }
h2 { font: bold clamp(30px, 3.3vw, 46px)/1.15 var(--serif); letter-spacing: -.025em; color: #263c50; }
.chapter-heading > p:last-child:not(.kicker) { max-width: 820px; margin: 20px auto 0; font-size: 16px; color: var(--body); line-height: 1.8; }
.paper-figure { margin: 24px 0 0; }
.figure-link { position: relative; display: block; text-decoration: none; background: #fff; cursor: zoom-in; }
.figure-link > img { width: 100%; }
.enlarge { position: absolute; right: 9px; bottom: 8px; padding: 5px 11px; border: 1px solid #d2dbe3; border-radius: 5px; color: #425e74; background: #fffffff2; font-size: 10px; opacity: 0; transition: opacity .15s; }
.figure-link:hover .enlarge, .figure-link:focus-visible .enlarge { opacity: 1; }
figcaption { margin: 17px auto 0; text-align: center; color: var(--muted); max-width: 850px; font-size: 14px; line-height: 1.75; }
figcaption strong { font-weight: 600; color: #485a6a; }
.figure-note { color: var(--muted); font-size: 12px; text-align: center; max-width: 880px; margin: 20px auto 0; }
.figure-note a { color: #286e97; }
.world-definitions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 50px; margin: 45px 10px 0; text-align: center; }
.math-symbol { font: italic 38px var(--serif); display: block; color: #527c9b; margin-bottom: 14px; }
.math-symbol sub { font-size: .5em; }
.world-definitions h3 { font-size: 17px; margin-bottom: 8px; }
.world-definitions p { font-size: 15px; color: var(--body); }
.distinction { max-width: 900px; margin: 42px auto 0; padding: 20px 24px; border-left: 3px solid #89a8c0; background: #f4f7fa; font-size: 15px; color: var(--body); }
.distinction strong { font-size: 16px; color: var(--ink); }
.distinction p { margin-top: 6px; }
.timeline-section { padding-bottom: 64px; }
.timeline-figure { max-width: 1040px; margin-inline: auto; }
.timeline-figure figcaption { max-width: 700px; }
.operations-intro { max-width: 1096px; margin: 10px auto 0; display: flex; align-items: center; gap: 20px; font-size: 14px; letter-spacing: .045em; color: var(--muted); }
.operations-intro::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.operation { --accent: var(--reading); }
.writing-section { --accent: var(--writing); }
.sharing-section { --accent: var(--sharing); }
.interacting-section { --accent: var(--interacting); }
.operation::before { content: ""; position: absolute; top: 0; height: 3px; left: 52px; width: 80px; background: var(--accent); }
.operation-heading h2 { display: flex; align-items: center; justify-content: center; gap: 15px; }
.operation-heading h2 img { width: 42px; height: 42px; flex-shrink: 0; }
.operation-heading .kicker { margin-bottom: 18px; }
.chapter-notes { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; margin: 36px 10px 0; }
.chapter-notes h3 { font: bold 20px/1.4 var(--serif); letter-spacing: -.01em; margin-bottom: 10px; }
.chapter-notes p { color: var(--body); font-size: 15px; line-height: 1.8; }
.chapter-end { border-top: 1px solid var(--line); margin-top: 34px; padding-top: 18px; display: flex; align-items: center; justify-content: space-between; gap: 20px; font-size: 13px; }
.chapter-end p { color: var(--muted); }
.chapter-end a { white-space: nowrap; text-decoration: none; font-weight: 600; }
.chapter-end a span { padding: 2px 6px; margin: 0 4px; background: color-mix(in srgb, var(--accent) 26%, white); border-radius: 3px; }
.figure-tabs { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px 26px; border-bottom: 1px solid var(--line); margin: 0 auto 20px; }
.figure-tabs a { padding: 11px 1px 12px; border-bottom: 2px solid transparent; text-decoration: none; font-size: 14px; color: var(--muted); }
.figure-tabs a[aria-selected="true"] { border-bottom-color: #365a76; color: var(--ink); font-weight: 600; }
.figure-gallery .paper-figure { margin-top: 0; }
.anchor-alias { position: absolute; top: 0; }
.taxonomy-figure .figure-link { aspect-ratio: 1.95; overflow: hidden; }
.taxonomy-figure img { margin-top: -6%; } /* Only blank PDF page margins are outside the viewport; full original opens in viewer. */
.evidence-steps { list-style: none; padding: 0; margin: 45px 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px; }
.evidence-steps li { border-top: 3px solid var(--reading); padding-top: 17px; }
.evidence-steps li:nth-child(2) { border-color: var(--writing); }
.evidence-steps li:nth-child(3) { border-color: var(--sharing); }
.evidence-steps li:nth-child(4) { border-color: var(--interacting); }
.evidence-steps li > span { color: #9ba7b1; font: 15px var(--serif); }
.evidence-steps h3 { font-size: 16px; margin-top: 10px; }
.evidence-steps p { color: var(--body); font-size: 14px; margin-top: 8px; }
.centered-link { text-align: center; margin-top: 35px; font-size: 12px; }

/* Original challenge illustrations are paired with a concise, readable test. */
.challenge-list { margin-top: 35px; border-top: 1px solid var(--line); }
.challenge-list details { border-bottom: 1px solid var(--line); }
.challenge-list summary { display: flex; align-items: center; gap: 22px; cursor: pointer; list-style: none; padding: 22px 3px; }
.challenge-list summary::-webkit-details-marker { display: none; }
.challenge-number { font: 16px var(--serif); color: #8b9eae; }
.challenge-list summary h3 { font: bold 20px/1.4 var(--serif); flex: 1; }
.expand-sign::after { content: "+"; font-size: 22px; color: #71808b; font-weight: 300; }
details[open] > summary .expand-sign::after { content: "−"; }
.challenge-content { display: grid; grid-template-columns: .85fr 1.25fr; align-items: center; gap: 38px; padding: 0 0 28px 42px; }
.challenge-content > div { color: var(--body); font-size: 15px; line-height: 1.85; }
.challenge-content h4 { font-size: 13px; letter-spacing: .04em; margin-top: 20px; color: #526c80; }
.challenge-content .paper-figure { margin: 0; }
.challenge-content figcaption { font-size: 12px; margin-top: 7px; }
.challenge-content figcaption strong { display: none; }

/* The collection is a restrained, useful bibliography rather than a card grid. */
.library-section { padding-top: 90px; }
.library-tools { border: 1px solid var(--line); border-radius: 6px; background: #f8fafc; padding: 25px; }
#search-form label { font-size: 14px; font-weight: 600; display: block; margin-bottom: 8px; }
.search-wrap { position: relative; }
.search-wrap > span { position: absolute; top: 6px; left: 16px; font-size: 24px; color: #8095a4; }
#search { width: 100%; height: 46px; border: 1px solid #ccd7e0; border-radius: 4px; padding: 0 42px; background: #fff; color: var(--ink); font-size: 16px; }
#search::-webkit-search-cancel-button { display: none; }
#clear-search { position: absolute; right: 3px; top: 3px; height: 40px; width: 36px; border: 0; color: #6e7d88; background: transparent; font-size: 22px; }
.library-categories { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.library-categories button { min-height: 40px; border: 1px solid #dce3e9; border-radius: 4px; padding: 7px 11px; color: var(--body); background: #fff; font-size: 13px; }
.library-categories button[aria-pressed="true"] { color: #fff; border-color: var(--navy); background: var(--navy); }
.library-categories button span { margin-left: 6px; opacity: .8; font-size: 12px; }
.filter-row { display: flex; flex-wrap: wrap; align-items: end; gap: 16px; margin-top: 21px; }
.select-field { display: grid; gap: 4px; }
.select-field label { font-size: 13px; color: var(--muted); }
.select-field select { height: 40px; max-width: 240px; min-width: 135px; padding: 0 30px 0 10px; border: 1px solid #ccd7e0; border-radius: 3px; background: #fff; color: var(--body); font-size: 13px; }
.reset-button { border: 0; background: transparent; padding: 10px 0; font-size: 13px; color: #63788a; margin-left: auto; text-decoration: underline; text-underline-offset: 3px; }
.results-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin: 27px 0 10px; font-size: 13px; color: var(--muted); scroll-margin-top: 85px; }
.text-link { border: 0; padding: 0; background: transparent; font-size: 13px; color: #286e97; text-decoration: underline; text-underline-offset: 3px; }
.paper-row { display: grid; grid-template-columns: 46px minmax(0,1fr) 58px; gap: 18px; padding: 22px 0; border-bottom: 1px solid var(--line); align-items: start; }
.paper-year { color: #8795a2; font: 14px/1.6 var(--serif); }
.paper-main h3 { font-size: 17px; font-weight: 600; line-height: 1.6; }
.paper-main h3 a { text-decoration: none; }
.paper-main h3 a:hover { text-decoration: underline; }
.paper-authors { font-size: 13px; color: var(--muted); margin-top: 5px; }
.paper-meta { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-top: 8px; font-size: 12px; color: var(--muted); }
.paper-resources { display: flex; flex-wrap: wrap; gap: 6px 17px; margin-top: 10px; font-size: 13px; }
.paper-resources a { color: #286e97; }
.category-label { display: inline-flex; align-items: center; gap: 5px; }
.category-label::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #a8b6c1; }
.category-label[data-category="understanding"]::before { background: var(--reading); }
.category-label[data-category="generation"]::before { background: var(--writing); }
.category-label[data-category="unified"]::before { background: var(--sharing); }
.category-label[data-category="world-models"]::before { background: var(--interacting); }
.venue-label { border-left: 1px solid var(--line); padding-left: 12px; }
.bib-button { font-size: 12px; border: 1px solid var(--line); border-radius: 3px; background: #fff; padding: 7px 8px; color: #516b80; margin-top: 3px; }
.bib-button:hover { background: var(--surface); }
.pagination { display: flex; gap: 20px; justify-content: center; align-items: center; margin-top: 28px; font-size: 13px; }
.pagination button { border: 1px solid var(--line); border-radius: 4px; padding: 9px 14px; font-size: 13px; background: #fff; color: var(--ink); }
.library-note { font-size: 13px; color: var(--muted); text-align: center; max-width: 850px; margin: 30px auto 0; }
.no-results { text-align: center; padding: 45px 0; }
.no-results h3 { font-size: 17px; }
.no-results p { color: var(--muted); font-size: 13px; margin: 8px 0 20px; }
#library-error, noscript { font-size: 14px; }
footer { margin: auto; max-width: 1200px; padding: 25px 52px 55px; display: flex; align-items: center; gap: 25px; border-top: 1px solid var(--line); }
footer .wordmark { font-size: 20px; }
footer nav { display: flex; flex-wrap: wrap; gap: 12px 24px; flex: 1; font-size: 13px; }
footer nav a { text-decoration: none; }
footer > a:last-child { font-size: 13px; text-decoration: none; }

/* Native dialogs provide keyboard focus containment and Escape-to-close. */
body:has(dialog[open]) { overflow: hidden; }
dialog { border: 1px solid #cfd8e1; border-radius: 8px; padding: 27px; width: min(760px, calc(100vw - 32px)); max-height: calc(100dvh - 42px); color: var(--ink); background: #fff; }
dialog::backdrop { background: #13283bd1; backdrop-filter: blur(4px); }
.dialog-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.dialog-heading h2 { font-size: 26px; }
.dialog-heading button, #close-figure { border: 0; background: transparent; font-size: 26px; color: var(--body); width: 35px; height: 35px; }
#bib-paper-title { color: var(--body); font-size: 13px; margin-top: 14px; }
#bib-content { white-space: pre-wrap; overflow-wrap: anywhere; overflow-y: auto; max-height: 45dvh; padding: 18px; background: #f3f6f9; font-size: 11px; line-height: 1.8; border: 1px solid var(--line); border-radius: 4px; }
.dialog-actions { display: flex; align-items: center; gap: 20px; }
#copy-status { font-size: 11px; color: var(--body); }
.figure-dialog { width: calc(100vw - 48px); max-width: 1600px; height: calc(100dvh - 48px); max-height: none; padding: 0; overflow: hidden; }
.figure-dialog-toolbar { display: flex; justify-content: space-between; align-items: center; padding: 11px 20px; border-bottom: 1px solid var(--line); min-height: 59px; gap: 20px; }
.figure-dialog-toolbar h2 { font: 600 14px/1.4 var(--sans); letter-spacing: 0; }
.figure-dialog-toolbar > div { display: flex; align-items: center; gap: 17px; flex-shrink: 0; }
.figure-dialog-toolbar button:not(#close-figure), .figure-dialog-toolbar a { font-size: 11px; background: #fff; border: 0; color: #3b6484; text-decoration: underline; text-underline-offset: 3px; padding: 5px 0; }
.figure-viewport { height: calc(100% - 91px); overflow: auto; background: #fff; }
.figure-viewport img { width: 100%; height: 100%; object-fit: contain; max-width: none; cursor: zoom-in; }
.figure-viewport.tall img { height: auto; object-fit: initial; }
.figure-viewport.zoomed img { width: max(1400px, 170%); height: auto; object-fit: initial; cursor: zoom-out; }
.figure-dialog-note { height: 32px; display: flex; align-items: center; justify-content: center; border-top: 1px solid var(--line); color: var(--muted); font-size: 10px; }

@media (min-width: 1500px) {
  .cover { padding-top: 65px; }
  .chapter { max-width: 1320px; }
  .cover-inner { max-width: 1280px; }
}
@media (max-width: 1000px) {
  .site-header { padding-inline: 26px; }
  .wordmark small { display: none; }
  .chapter-nav { right: 7px; }
  .chapter { padding-inline: 42px; }
  .cover { padding-inline: 42px; }
  .operation::before { left: 42px; }
  .operations-intro { margin-inline: 42px; }
  .chapter-notes { gap: 35px; }
  .chapter-end { flex-direction: column; align-items: flex-start; gap: 10px; }
  .four-operations { gap: 10px 22px; }
  .four-operations a { font-size: 22px; }
  .four-operations img { width: 25px; height: 25px; }
  .challenge-content { padding-left: 0; gap: 25px; }
}
@media (max-width: 720px) {
  html { scroll-padding-top: 73px; }
  .site-header { min-height: 57px; padding: 12px 20px; gap: 16px; }
  .wordmark { font-size: 19px; }
  .site-header nav { gap: 16px; font-size: 12px; }
  .site-header nav a:first-child { display: none; }
  .chapter-nav, .reading-progress { display: none; }
  .cover { padding: 43px 22px 35px; }
  h1 { font-size: clamp(31px, 5.5vw, 40px); line-height: 1.15; }
  .title-line + .title-line { margin-top: .2em; }
  .four-operations { display: grid; grid-template-columns: repeat(2, max-content); gap: 12px 24px; max-width: 430px; margin: 24px auto 0; }
  .four-operations a { font-size: 18px; }
  .four-operations img { width: 22px; height: 22px; }
  .cover-subtitle { font-size: 16px; margin-top: 12px; }
  .authors { font-size: 16px; line-height: 1.85; }
  .author-row { column-gap: 17px; }
  .byline { margin-top: 20px; }
  .affiliations { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 16px; font-size: 13px; max-width: 450px; line-height: 1.65; }
  .affiliations span { white-space: normal; }
  .author-notes { font-size: 12px; margin-top: 12px; }
  .cover-actions { margin-top: 22px; gap: 8px; }
  .button { font-size: 13px; min-height: 42px; padding: 8px 14px; }
  .cover .cover-figure { margin-top: 27px; }
  .cover-figure .figure-link { margin-inline: -10px; }
  .cover-figure figcaption { font-size: 12px; }
  .chapter { padding: 48px 23px 48px; scroll-margin-top: 0; }
  .chapter-heading { margin-bottom: 25px; }
  h2 { font-size: 32px; }
  .kicker { font-size: 14px; letter-spacing: .035em; }
  .chapter-heading > p:last-child:not(.kicker) { font-size: 14px; margin-top: 17px; line-height: 1.8; }
  .world-definitions { grid-template-columns: 1fr; gap: 26px; margin: 30px auto 0; max-width: 360px; }
  .math-symbol { font-size: 30px; }
  .world-definitions h3 { font-size: 16px; }
  .world-definitions p { font-size: 14px; }
  .distinction { margin-top: 30px; padding: 17px 18px; font-size: 14px; }
  .distinction strong { font-size: 14px; }
  figcaption, .figure-note { font-size: 12px; }
  .enlarge { opacity: 1; font-size: 8px; padding: 3px 6px; right: 4px; bottom: 4px; }
  .operations-intro { margin-inline: 23px; font-size: 13px; letter-spacing: .025em; }
  .operation::before { left: 23px; width: 60px; }
  .operation-heading h2 { gap: 10px; font-size: 29px; }
  .operation-heading h2 img { width: 31px; height: 31px; }
  .wide-only { display: none; }
  .chapter-notes { grid-template-columns: 1fr; gap: 22px; margin: 26px 0 0; }
  .chapter-notes h3 { font-size: 18px; margin-bottom: 7px; }
  .chapter-notes p { font-size: 14px; }
  .chapter-end { font-size: 12px; margin-top: 25px; }
  .figure-tabs { gap: 2px 16px; }
  .figure-tabs a { font-size: 13px; padding-bottom: 8px; }
  .evidence-steps { grid-template-columns: 1fr 1fr; gap: 26px 20px; margin-top: 30px; }
  .evidence-steps h3 { font-size: 15px; }
  .evidence-steps p { font-size: 13px; }
  .challenge-list summary { gap: 14px; padding-block: 18px; }
  .challenge-list summary h3 { font-size: 17px; }
  .challenge-number { font-size: 13px; }
  .challenge-content { grid-template-columns: 1fr; gap: 20px; }
  .challenge-content > div { font-size: 14px; }
  .challenge-content .paper-figure { max-width: 500px; }
  .library-tools { padding: 17px; }
  #search { font-size: 16px; padding-left: 36px; }
  #search-form label { font-size: 13px; }
  .library-categories { gap: 6px; }
  .library-categories button { font-size: 12px; padding: 7px 9px; }
  .filter-row { gap: 12px; display: grid; grid-template-columns: 1fr 1fr; }
  .select-field { min-width: 0; }
  .select-field select { min-width: 0; width: 100%; max-width: 100%; }
  .reset-button { justify-self: end; }
  .results-toolbar { flex-wrap: wrap; gap: 8px; font-size: 12px; }
  .text-link { font-size: 12px; }
  .paper-row { grid-template-columns: 34px minmax(0,1fr); gap: 7px 13px; padding: 19px 0; }
  .paper-year { font-size: 12px; }
  .paper-main h3 { font-size: 16px; }
  .paper-authors { font-size: 12px; }
  .bib-button { grid-column: 2; justify-self: start; margin: 0; }
  .paper-meta { font-size: 11px; }
  .paper-resources { font-size: 13px; }
  footer { padding: 23px 23px 35px; flex-wrap: wrap; gap: 10px 20px; }
  footer nav { flex-basis: 100%; order: 3; }
  footer > a:last-child { margin-left: auto; }
  .figure-dialog { width: calc(100vw - 16px); height: calc(100dvh - 24px); }
  .figure-dialog-toolbar { padding: 9px 12px; gap: 10px; flex-wrap: wrap; height: 94px; align-content: center; }
  .figure-dialog-toolbar h2 { flex-basis: 100%; font-size: 12px; }
  .figure-dialog-toolbar > div { width: 100%; gap: 20px; }
  #close-figure { margin-left: auto; height: 25px; }
  .figure-viewport { height: calc(100% - 126px); }
  .figure-dialog-note { font-size: 8px; }
  .figure-viewport.zoomed img { width: 1400px; }
  dialog:not(.figure-dialog) { padding: 20px; }
}
@media (max-width: 390px) {
  .site-header { padding-inline: 16px; gap: 10px; }
  .site-header nav { gap: 12px; font-size: 12px; }
  .wordmark { font-size: 17px; }
  .four-operations { column-gap: 17px; }
  .four-operations a { font-size: 17px; }
  .operation-heading h2 { font-size: 25px; }
  .cover { padding-inline: 19px; }
  .button { padding-inline: 11px; }
}
@media (max-width: 360px) {
  h1 { font-size: 28px; }
  .authors { font-size: 15px; }
  .site-header nav a[href="#timeline"] { display: none; }
  .operation-heading h2 { font-size: 23px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
@media print {
  .site-header, .chapter-nav, .reading-progress, .cover-actions, .enlarge, .library-section, dialog { display: none !important; }
  .cover::before { display: none; }
  .cover, .chapter { padding: 20px; max-width: none; }
  [data-figure-panel][hidden] { display: block !important; }
  .chapter { break-before: page; }
  .figure-link { break-inside: avoid; }
}
