/* ==========================================================================
   Kreindo — On Batteries
   An engraved-plate look: cream paper, black ink, Bodoni display,
   Caslon text, hairline rules.
   ========================================================================== */

:root {
  --paper: #eeebe3;
  --paper-2: #e6e2d7;
  --paper-3: #dcd7ca;
  --ink: #16140f;
  --ink-2: #34302a;
  --muted: #6b655a;
  --rule: rgba(22, 20, 15, 0.26);
  --rule-soft: rgba(22, 20, 15, 0.14);
  --brass: #84623a;
  --brass-2: #a8865a;
  --display: "Bodoni Moda", "Didot", "Bodoni 72", Georgia, serif;
  --text: "Libre Caslon Text", "Baskerville", Georgia, serif;
  --gutter: 16px;
  --max: 1200px;
  --measure: 66ch;
  color-scheme: light;
}

@media (min-width: 720px) {
  :root { --gutter: 32px; }
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 72px;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
  margin: 0;
  background-color: var(--paper);
  /* faint paper grain */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .09 0 0 0 0 .08 0 0 0 0 .06 0 0 0 .055 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  color: var(--ink-2);
  font-family: var(--text);
  font-size: 17px;
  line-height: 1.68;
  font-feature-settings: "kern", "liga", "onum";
  overflow-x: hidden;
}

@media (min-width: 720px) {
  body { font-size: 18px; }
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--brass); }
::selection { background: var(--ink); color: var(--paper); }

:focus-visible {
  outline: 2px solid var(--brass);
  outline-offset: 3px;
}

.skip {
  position: absolute; left: -9999px; top: 8px;
  background: var(--ink); color: var(--paper); padding: 8px 14px; z-index: 100;
}
.skip:focus { left: 8px; }

.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ---------- type primitives ---------- */

.caps {
  font-family: var(--text);
  text-transform: uppercase;
  letter-spacing: 0.32em;
  font-size: 0.72rem;
  line-height: 1.5;
  color: var(--ink);
}

.display {
  font-family: var(--display);
  font-optical-sizing: auto;
  color: var(--ink);
  font-weight: 500;
  line-height: 0.98;
  letter-spacing: -0.01em;
  margin: 0;
}

h2.display {
  font-size: clamp(2.3rem, 6.4vw, 4.6rem);
  text-transform: uppercase;
  text-wrap: balance;
}

h3 {
  font-family: var(--display);
  font-weight: 600;
  color: var(--ink);
  font-size: 1.45rem;
  line-height: 1.15;
  margin: 0 0 0.4em;
}

p { margin: 0 0 1.05em; }
.lede {
  font-size: 1.14em;
  font-style: italic;
  color: var(--ink);
  line-height: 1.55;
}

.prose { max-width: var(--measure); }
.prose p { text-wrap: pretty; }

.dropcap::first-letter {
  float: left;
  font-family: var(--display);
  font-weight: 600;
  font-size: 4.6em;
  line-height: 0.82;
  padding: 0.06em 0.1em 0 0;
  color: var(--ink);
}

sub, sup { line-height: 0; }

/* hairline rules */
.rule { border: 0; border-top: 1px solid var(--rule); margin: 0; }
.rule-double {
  border: 0;
  height: 5px;
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
  margin: 0;
}
.ornament {
  display: flex; align-items: center; gap: 14px;
  color: var(--ink);
}
.ornament::before, .ornament::after {
  content: ""; flex: 1; height: 1px; background: var(--ink); opacity: 0.55;
}
.ornament span { font-family: var(--display); font-size: 1.1rem; line-height: 1; }

/* ---------- footnote markers ---------- */

.fn {
  font-size: 0.66em;
  vertical-align: super;
  line-height: 0;
  font-family: var(--text);
  font-style: normal;
  white-space: nowrap;
}
.fn a {
  color: var(--brass);
  text-decoration: none;
  padding: 0 1px;
  font-weight: 700;
}
.fn a:hover { color: var(--ink); text-decoration: underline; }

.fn-tip {
  position: absolute;
  z-index: 60;
  max-width: min(360px, calc(100vw - 32px));
  background: var(--ink);
  color: var(--paper);
  font-size: 0.8rem;
  line-height: 1.45;
  padding: 10px 12px;
  border-radius: 2px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
  pointer-events: none;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.14s ease, transform 0.14s ease;
}
.fn-tip.on { opacity: 1; transform: none; }
.fn-tip b { color: #d8bf97; font-weight: 400; margin-right: 4px; }

/* ==========================================================================
   Masthead + nav
   ========================================================================== */

.masthead { padding-top: 18px; }
.masthead-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  padding-bottom: 12px;
}
.masthead-row .brand {
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: 0.24em;
  font-size: 0.95rem;
  color: var(--ink);
  text-decoration: none;
}
.masthead-row .center { text-align: center; }
.masthead-row .right { text-align: right; }
@media (max-width: 719px) {
  .masthead-row { grid-template-columns: 1fr auto; }
  .masthead-row .center { display: none; }
}

.chapters {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--rule);
}
.chapters ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 4px 26px;
  overflow-x: auto;
  scrollbar-width: none;
  white-space: nowrap;
}
.chapters ul::-webkit-scrollbar { display: none; }
.chapters a {
  display: inline-block;
  padding: 13px 0 11px;
  text-decoration: none;
  font-size: 0.68rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--muted);
  border-bottom: 1px solid transparent;
}
.chapters a:hover, .chapters a[aria-current="true"] { color: var(--ink); border-bottom-color: var(--ink); }
.chapters a i { font-style: normal; font-family: var(--display); letter-spacing: 0.05em; margin-right: 6px; color: var(--brass); }

/* ==========================================================================
   Hero
   ========================================================================== */

.hero { padding: 56px 0 0; }
.hero-title { text-align: center; }
.hero-title .kicker { color: var(--muted); margin: 0 0 18px; }
.hero h1 {
  font-size: clamp(3.3rem, 16.5vw, 9rem);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  line-height: 0.88;
}
.hero h1 span { display: block; }
@media (min-width: 720px) {
  .hero h1 { font-size: min(10.6vw, 9.4rem); }
  .hero h1 span { display: inline; }
}
.hero-title .strap {
  margin: 22px auto 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  color: var(--ink);
  max-width: 900px;
}
.hero-title .strap::before, .hero-title .strap::after {
  content: ""; flex: 1; height: 1px; background: var(--ink); opacity: .7; min-width: 20px;
}
.hero-grid {
  display: grid;
  gap: 40px;
  margin-top: 56px;
  align-items: start;
}
@media (min-width: 900px) {
  .hero-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: 72px; align-items: center; }
}
.hero .deck {
  margin: 0 0 22px;
  font-size: clamp(1.3rem, 2.6vw, 1.7rem);
  line-height: 1.35;
  font-style: italic;
  color: var(--ink);
  font-family: var(--display);
  max-width: 30ch;
}
.hero-intro .dropcap { max-width: 58ch; }
.hero-fig { margin: 0; }
.hero-fig .frame { padding: 14px; border: 1px solid var(--ink); background: rgba(255, 255, 255, 0.18); }
.hero-fig .frame > div { border: 1px solid var(--rule); padding: 10px; }

.facts {
  margin-top: 56px;
  display: grid;
  grid-template-columns: 1fr;
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}
@media (min-width: 720px) {
  .facts { grid-template-columns: repeat(4, 1fr); }
}
.fact {
  padding: 22px 0;
  border-bottom: 1px solid var(--rule);
}
.fact:last-child { border-bottom: 0; }
@media (min-width: 720px) {
  .fact { padding: 26px 22px; border-bottom: 0; border-left: 1px solid var(--rule); }
  .fact:first-child { border-left: 0; padding-left: 0; }
}
.fact .num {
  font-family: var(--display);
  font-size: 2.7rem;
  line-height: 1;
  color: var(--ink);
  font-weight: 500;
  display: block;
  margin-bottom: 10px;
}
.fact p { margin: 0; font-size: 0.92rem; line-height: 1.5; }

/* ==========================================================================
   Chapters / sections
   ========================================================================== */

.chapter { padding: 96px 0 0; }
@media (max-width: 719px) { .chapter { padding-top: 72px; } }

.chapter-head {
  display: grid;
  gap: 14px;
  margin-bottom: 44px;
  text-align: center;
  justify-items: center;
}
.chapter-head .numeral {
  font-family: var(--display);
  font-size: 1rem;
  color: var(--brass);
  letter-spacing: 0.3em;
}
.chapter-head .sub { color: var(--muted); max-width: 52ch; }

.two-col {
  display: grid;
  gap: 40px;
}
@media (min-width: 960px) {
  .two-col { grid-template-columns: 1fr 1fr; gap: 64px; align-items: start; }
  .two-col.wide-left { grid-template-columns: 1.1fr 0.9fr; }
}

/* ---------- figures & plates ---------- */

figure { margin: 0; }
figcaption {
  margin-top: 12px;
  font-size: 0.86rem;
  line-height: 1.5;
  color: var(--muted);
}
figcaption .caps { color: var(--ink); margin-right: 8px; letter-spacing: 0.24em; font-size: 0.66rem; }

.engraving {
  mix-blend-mode: multiply;
  filter: grayscale(1) sepia(0.18) contrast(1.06);
  width: 100%;
  height: auto;
}

.plate {
  border: 1px solid var(--ink);
  padding: 10px;
  background: rgba(255, 255, 255, 0.16);
}
.plate > .inner { border: 1px solid var(--rule); overflow: hidden; }
.plate img { width: 100%; height: auto; }
.plate button.zoom {
  all: unset;
  display: block;
  cursor: zoom-in;
  width: 100%;
}
.plate button.zoom:focus-visible { outline: 2px solid var(--brass); outline-offset: 2px; }

.plate-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
@media (max-width: 719px) {
  .plate-scroll img { width: 900px; max-width: none; }
}
.scroll-hint { display: none; }
@media (max-width: 719px) {
  .scroll-hint { display: block; margin-top: 8px; font-size: 0.8rem; color: var(--muted); font-style: italic; }
}

.note {
  margin-top: 18px;
  border-left: 2px solid var(--brass);
  padding: 4px 0 4px 16px;
  font-size: 0.92rem;
  line-height: 1.55;
}
.note .caps { color: var(--brass); display: block; margin-bottom: 4px; font-size: 0.64rem; }

/* parts list */
.parts { list-style: none; margin: 0; padding: 0; columns: 1; column-gap: 48px; }
@media (min-width: 720px) { .parts { columns: 2; } }
.parts li {
  break-inside: avoid;
  padding: 14px 0;
  border-top: 1px solid var(--rule);
}
.parts li b {
  display: block;
  font-family: var(--display);
  font-weight: 600;
  color: var(--ink);
  font-size: 1.1rem;
  line-height: 1.25;
}
.parts li span { font-size: 0.93rem; line-height: 1.5; }

.equation {
  margin: 32px 0 0;
  padding: 26px 18px;
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
  text-align: center;
}
.equation .eq {
  font-family: var(--display);
  font-size: clamp(1.15rem, 3.6vw, 1.9rem);
  color: var(--ink);
  line-height: 1.3;
  overflow-wrap: anywhere;
}
.equation .eq .arrow { margin: 0 0.3em; color: var(--brass); }
.equation p { margin: 10px auto 0; font-size: 0.88rem; color: var(--muted); max-width: 60ch; }

/* glossary (the words) */
.words {
  display: grid;
  grid-template-columns: 1fr;
  border-top: 1px solid var(--ink);
  margin-top: 8px;
}
@media (min-width: 600px) { .words { grid-template-columns: 1fr 1fr; } }
.words div { padding: 14px 0; border-bottom: 1px solid var(--rule); }
@media (min-width: 600px) {
  .words div:nth-child(odd) { padding-right: 22px; border-right: 1px solid var(--rule); }
  .words div:nth-child(even) { padding-left: 22px; }
}
.words dt {
  font-family: var(--display);
  font-size: 1.2rem;
  color: var(--ink);
  font-weight: 600;
  line-height: 1.2;
}
.words dt small { font-family: var(--text); font-weight: 400; font-style: italic; color: var(--muted); font-size: 0.8rem; margin-left: 6px; }
.words dd { margin: 4px 0 0; font-size: 0.92rem; line-height: 1.5; }

/* ---------- diagram widgets ---------- */

.diagram {
  border: 1px solid var(--ink);
  padding: 10px;
  background: rgba(255, 255, 255, 0.18);
}
.diagram > .inner { border: 1px solid var(--rule); padding: 14px; }
.diagram svg { width: 100%; height: auto; }
.diagram svg text { font-family: var(--text); fill: var(--ink); }
.diagram svg .lbl { font-size: 19px; font-style: italic; }
.diagram svg .lbl-caps { font-size: 14px; letter-spacing: 0.2em; text-transform: uppercase; }

.controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  margin-top: 14px;
}
.btn {
  appearance: none;
  border: 1px solid var(--ink);
  background: transparent;
  color: var(--ink);
  font-family: var(--text);
  font-size: 0.7rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  padding: 10px 14px 9px;
  cursor: pointer;
  border-radius: 0;
  min-height: 40px;
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.btn:disabled { opacity: 0.4; cursor: default; }
.readout {
  font-family: var(--display);
  color: var(--ink);
  font-size: 1.05rem;
  margin-left: auto;
}
@media (max-width: 599px) { .readout { margin-left: 0; width: 100%; } }

input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 28px;
  background: transparent;
  cursor: pointer;
}
input[type="range"]::-webkit-slider-runnable-track { height: 1px; background: var(--ink); }
input[type="range"]::-moz-range-track { height: 1px; background: var(--ink); }
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 18px; height: 18px; margin-top: -9px;
  border-radius: 50%; background: var(--paper); border: 1px solid var(--ink);
  box-shadow: inset 0 0 0 3px var(--paper), inset 0 0 0 9px var(--ink);
}
input[type="range"]::-moz-range-thumb {
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--ink); border: 3px solid var(--paper); box-shadow: 0 0 0 1px var(--ink);
}

.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; }
.steps li {
  counter-increment: step;
  position: relative;
  padding: 0 0 18px 46px;
}
.steps li::before {
  content: counter(step, upper-roman) ".";
  position: absolute;
  left: 0;
  top: 0;
  font-family: var(--display);
  color: var(--brass);
  font-size: 1rem;
  width: 36px;
  text-align: right;
}
.steps li b { color: var(--ink); }

/* ==========================================================================
   Chronology
   ========================================================================== */

.chron { margin-top: 64px; }
.chron-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 18px; }
.chron-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ink); }
.entry {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px 32px;
  padding: 30px 0;
  border-bottom: 1px solid var(--rule);
}
@media (min-width: 720px) {
  .entry { grid-template-columns: 130px 1fr; }
  .entry.has-fig { grid-template-columns: 130px 1fr 240px; }
}
@media (min-width: 1040px) {
  .entry.has-fig { grid-template-columns: 150px 1fr 300px; }
  .entry { grid-template-columns: 150px 1fr; }
}
.entry .year {
  font-family: var(--display);
  font-size: 2.3rem;
  line-height: 1;
  color: var(--ink);
  font-weight: 500;
}
.entry .year small { display: block; margin-top: 10px; font-family: var(--text); font-size: 0.62rem; letter-spacing: 0.28em; color: var(--muted); text-transform: uppercase; }
.entry h3 { font-size: 1.35rem; }
.entry .who { font-size: 0.66rem; letter-spacing: 0.28em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.entry p { font-size: 0.97rem; margin-bottom: 0; max-width: 62ch; }
.entry figure { align-self: start; }
.entry figure .frame { border: 1px solid var(--rule); padding: 8px; background: rgba(255, 255, 255, 0.22); }
.entry figure button.zoom { all: unset; display: block; cursor: zoom-in; width: 100%; }
.entry figure figcaption { font-size: 0.76rem; margin-top: 8px; }
@media (max-width: 719px) {
  .entry figure { max-width: 420px; }
}

/* ==========================================================================
   Chemistry table + stack calculator
   ========================================================================== */

.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--ink); }
table.chem {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
  font-size: 0.93rem;
}
table.chem th, table.chem td {
  text-align: left;
  padding: 13px 14px 12px 0;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}
table.chem tr:last-child td { border-bottom: 0; }
table.chem thead th {
  font-weight: 400;
  font-size: 0.62rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--muted);
  border-bottom: 1px solid var(--ink);
}
table.chem td:first-child { font-family: var(--display); font-weight: 600; color: var(--ink); font-size: 1.05rem; }
table.chem td.v { font-family: var(--display); color: var(--ink); font-size: 1.15rem; white-space: nowrap; font-variant-numeric: lining-nums tabular-nums; }
table.chem .tag {
  display: inline-block;
  font-size: 0.6rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  border: 1px solid var(--rule);
  padding: 3px 7px 2px;
  white-space: nowrap;
}
table.chem .tag.re { border-color: var(--brass-2); color: var(--brass); }

.stack {
  display: grid;
  gap: 28px;
  margin-top: 56px;
}
@media (min-width: 860px) { .stack { grid-template-columns: 0.9fr 1.1fr; gap: 56px; align-items: center; } }
.stack-controls label { display: block; margin: 18px 0 6px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.counter { display: flex; align-items: center; gap: 0; }
.counter .btn { min-width: 44px; padding: 8px 0; font-size: 1rem; letter-spacing: 0; }
.counter output {
  min-width: 64px; text-align: center;
  font-family: var(--display); font-size: 1.6rem; color: var(--ink);
  border-top: 1px solid var(--ink); border-bottom: 1px solid var(--ink);
  height: 40px; line-height: 40px;
}
.stack-total {
  margin-top: 22px;
  font-family: var(--display);
  font-size: clamp(2.4rem, 7vw, 3.6rem);
  line-height: 1;
  color: var(--ink);
}
.stack-total small { font-family: var(--text); font-size: 0.9rem; color: var(--muted); display: block; margin-top: 8px; font-style: italic; }
.stack-note { margin-top: 14px; font-size: 0.92rem; min-height: 3em; }
.stack-visual svg { width: 100%; height: auto; max-height: 520px; }

/* ==========================================================================
   Sizes plate
   ========================================================================== */

.sizes svg text { font-family: var(--text); fill: var(--ink); }
.sizes-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.sizes-scroll svg { min-width: 760px; }

/* ==========================================================================
   Label section
   ========================================================================== */

.units {
  display: grid;
  grid-template-columns: 1fr;
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}
@media (min-width: 760px) { .units { grid-template-columns: repeat(3, 1fr); } }
.unit { padding: 26px 0; border-bottom: 1px solid var(--rule); }
.unit:last-child { border-bottom: 0; }
@media (min-width: 760px) {
  .unit { padding: 28px 26px; border-bottom: 0; border-left: 1px solid var(--rule); }
  .unit:first-child { border-left: 0; padding-left: 0; }
}
.unit .sym { font-family: var(--display); font-size: 3rem; line-height: 1; color: var(--ink); }
.unit h3 { margin-top: 10px; }
.unit p { font-size: 0.95rem; margin: 0; }

.callout-grid { display: grid; gap: 28px; margin-top: 40px; }
@media (min-width: 860px) { .callout-grid { grid-template-columns: 1fr 1fr; gap: 48px; } }

.bars { margin-top: 14px; }
.bar { display: grid; grid-template-columns: 110px 1fr; gap: 12px; align-items: center; margin: 10px 0; font-size: 0.85rem; }
.bar .track { height: 26px; border: 1px solid var(--ink); position: relative; }
.bar .fill {
  position: absolute; inset: 0 auto 0 0;
  background: repeating-linear-gradient(115deg, var(--ink) 0 1px, transparent 1px 5px);
}
.bar .val { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); font-family: var(--display); color: var(--ink); background: var(--paper); padding: 0 6px; font-size: 0.95rem; }

/* ==========================================================================
   Safety
   ========================================================================== */

.disposal { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ink); }
.disposal li {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: baseline;
  gap: 4px 20px;
  padding: 16px 0;
  border-bottom: 1px solid var(--rule);
}
.disposal li > span:last-child { grid-column: 1 / -1; }
.disposal b { font-family: var(--display); font-weight: 600; color: var(--ink); font-size: 1.08rem; }
.verdict { font-size: 0.62rem; letter-spacing: 0.24em; text-transform: uppercase; text-align: right; }
.verdict.no { color: #7a2e1f; }
.verdict.ok { color: var(--muted); }
.disposal span:last-child { font-size: 0.93rem; line-height: 1.5; }

.notice {
  border: 1px solid var(--ink);
  padding: 8px;
  margin-top: 0;
}
.notice > div {
  border: 3px double var(--ink);
  padding: 26px 22px;
  text-align: center;
}
.notice .caps { display: block; margin-bottom: 10px; }
.notice .phone {
  font-family: var(--display);
  font-size: clamp(2rem, 6vw, 2.8rem);
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
  display: inline-block;
  margin: 4px 0 10px;
  line-height: 1.1;
}
.notice p { font-size: 0.93rem; margin: 0 auto 0.6em; max-width: 44ch; }

/* ==========================================================================
   Sources
   ========================================================================== */

.sources-intro { max-width: var(--measure); margin: 0 auto 40px; text-align: center; }
.biblio { display: grid; gap: 40px; }
@media (min-width: 960px) { .biblio { grid-template-columns: repeat(3, 1fr); gap: 40px; } }
.biblio h3 { font-size: 0.7rem; letter-spacing: 0.3em; text-transform: uppercase; font-family: var(--text); font-weight: 400; padding-bottom: 10px; border-bottom: 1px solid var(--ink); margin-bottom: 0; }
.biblio ol { list-style: none; margin: 0; padding: 0; }
.biblio li {
  display: grid;
  grid-template-columns: 30px 1fr;
  gap: 4px;
  padding: 12px 0;
  border-bottom: 1px solid var(--rule-soft);
  font-size: 0.86rem;
  line-height: 1.5;
  scroll-margin-top: 90px;
}
.biblio li .n { font-family: var(--display); color: var(--brass); font-weight: 600; }
.biblio li a { word-break: break-word; }
.biblio li:target { background: rgba(132, 98, 58, 0.12); outline: 6px solid rgba(132, 98, 58, 0.12); }
.biblio li .back { margin-left: 6px; text-decoration: none; color: var(--muted); font-size: 0.8rem; }

.credits { margin-top: 56px; }
.credits ol { columns: 1; column-gap: 40px; padding: 0; list-style: none; margin: 0; }
@media (min-width: 860px) { .credits ol { columns: 2; } }
.credits li { break-inside: avoid; font-size: 0.82rem; line-height: 1.5; padding: 9px 0; border-bottom: 1px solid var(--rule-soft); }

/* ==========================================================================
   Footer
   ========================================================================== */

.colophon { margin-top: 110px; padding: 0 0 48px; }
.colophon .inner { padding-top: 36px; display: grid; gap: 24px; }
@media (min-width: 860px) { .colophon .inner { grid-template-columns: 1fr auto; align-items: end; } }
.colophon .mark { font-family: var(--display); font-weight: 700; letter-spacing: 0.24em; color: var(--ink); font-size: 1.4rem; }
.colophon p { font-size: 0.86rem; margin: 6px 0 0; color: var(--muted); max-width: 60ch; }
.colophon nav { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.colophon nav a { font-size: 0.66rem; letter-spacing: 0.26em; text-transform: uppercase; text-decoration: none; }

/* ==========================================================================
   Lightbox
   ========================================================================== */

dialog.lightbox {
  border: 0;
  padding: 0;
  background: transparent;
  max-width: 100vw;
  max-height: 100vh;
  width: 100vw;
  height: 100vh;
  margin: 0;
}
dialog.lightbox::backdrop { background: rgba(22, 20, 15, 0.86); }
dialog.lightbox .lb-inner {
  width: 100%;
  height: 100%;
  overflow: auto;
  display: grid;
  place-items: center;
  padding: 56px 16px 24px;
}
dialog.lightbox img {
  max-width: min(1600px, 100%);
  max-height: calc(100vh - 110px);
  width: auto;
  height: auto;
  background: var(--paper);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.4);
}
dialog.lightbox .lb-cap { color: #e9e3d5; font-size: 0.85rem; margin-top: 12px; text-align: center; max-width: 70ch; }
dialog.lightbox .lb-close {
  position: fixed; top: 12px; right: 12px;
  border: 1px solid #e9e3d5; color: #e9e3d5; background: transparent;
}
dialog.lightbox .lb-close:hover { background: #e9e3d5; color: var(--ink); }

/* reveal */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.8s ease, transform 0.8s ease; }
.reveal.in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

/* generic zoomable image button */
button.zoom {
  all: unset;
  display: block;
  width: 100%;
  cursor: zoom-in;
}
button.zoom:focus-visible { outline: 2px solid var(--brass); outline-offset: 2px; }
button.zoom img { width: 100%; height: auto; }

.hero-fig { max-width: 460px; justify-self: center; width: 100%; }
@media (min-width: 960px) { .hero-fig { justify-self: end; } }

/* adjacent footnotes: 2,13 rather than 213 */
.fn + .fn::before { content: ","; color: var(--brass); font-weight: 700; }

@media (min-width: 960px) {
  .two-col > figure { position: sticky; top: 72px; }
}

@media (max-width: 719px) {
  .entry figure { max-width: 260px; }
  .hero-title .strap::before, .hero-title .strap::after { display: none; }
  .hero-title .strap { letter-spacing: 0.24em; }
}
