/* ============================================================
   revision.css — Revision-notes-specific styles
   Loads after page.css on /resources pages.
============================================================ */

/* ============================================================
   META BADGES — for hero (AQA, Paper 1 etc)
============================================================ */
.rn-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}
.rn-meta-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 5px 10px;
  border: 1px solid var(--hairline);
  background: var(--paper);
  border-radius: 999px;
  font-weight: 500;
  color: var(--ink-soft);
}
.rn-meta-badge.aqa {
  color: var(--accent);
  border-color: color-mix(in srgb, var(--accent) 40%, transparent);
}
.rn-meta-badge.paper1,
.rn-meta-badge.paper2 {
  color: var(--ink);
}
/* Muted "coming soon" variant of a meta badge (e.g. Paper 2 on the
   GCSE hub hero, where those notes are still in progress). */
.rn-meta-badge.is-coming {
  color: var(--muted);
  border-style: dashed;
}

/* Topic pager styles live in the TOPIC PAGER section lower in this file. */

/* ============================================================
   HERO MOTIF — chapter line art beside the heading
   Mirrors the OG card art (see assets/og/build-og.mjs). Turns the
   hero into two columns: text on the left, motif on the right.
============================================================ */
.rn-hero-inner {
  max-width: none;            /* span the full wrap, not the 880px article cap */
  display: flex;
  align-items: center;
  gap: clamp(28px, 5vw, 72px);
}
.rn-hero-main {
  flex: 1 1 0;
  min-width: 0;              /* let the text column shrink instead of overflowing */
  max-width: 820px;
}
.rn-hero-figure {
  flex: 0 0 auto;
  width: clamp(220px, 26vw, 340px);
  display: flex;
  justify-content: center;
}
/* C4's motif is landscape (beaker + electrolysis cell) — give it more room */
.rn-hero-figure.is-wide {
  width: clamp(260px, 34vw, 440px);
}
.rn-hero-svg {
  width: 100%;
  height: auto;
  overflow: visible;
}

@media (max-width: 900px) {
  .rn-hero-inner { display: block; }
  .rn-hero-figure { display: none; }   /* decorative — drop it on narrow screens */
}

/* ============================================================
   LEGEND — explains badge meanings on topic index
============================================================ */
.rn-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 24px;
  align-items: center;
  margin: 24px 0 40px;
  padding: 16px 20px;
  border: 1px solid var(--hairline);
  background: var(--paper-2);
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.02em;
  color: var(--muted);
}
.rn-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.rn-legend .tag {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.08em;
  font-weight: 500;
  padding: 3px 8px;
  border-radius: 999px;
  text-transform: uppercase;
  border: 1px solid currentColor;
}

/* ============================================================
   TIER & SPEC TAGS — inline (Triple, Higher, Coming soon)
============================================================ */
.tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 500;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid currentColor;
  vertical-align: middle;
  margin-left: 6px;
  white-space: nowrap;
}
.tag-triple { color: oklch(0.42 0.10 290); }
.tag-higher { color: oklch(0.45 0.13 50); }
.tag-coming { color: var(--muted); }

/* Compact single-letter tier badge (used in the TOC so long entries
   don't push the full-word pill onto its own line). */
.tag-dot,
.rn-legend .tag-dot {
  box-sizing: border-box;
  width: 17px;
  height: 17px;
  padding: 0;
  line-height: 15px;
  text-align: center;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0;
}

/* ============================================================
   TOPIC INDEX (paper sections + grid)
============================================================ */
.rn-papers {
  padding: clamp(56px, 8vw, 100px) 0;
}
.rn-paper-heading {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1.05;
  letter-spacing: -0.018em;
  color: var(--ink);
  margin: 48px 0 6px;
}
.rn-paper-heading:first-of-type { margin-top: 0; }
.rn-paper-sub {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 24px;
}
.rn-topic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1px;
  background: var(--hairline);
  border: 1px solid var(--hairline);
  margin-bottom: 48px;
}
.rn-topic-card {
  background: var(--paper);
  padding: 24px 24px 22px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  transition: background .15s;
  position: relative;
  min-height: 180px;
}
.rn-topic-card:hover {
  background: var(--paper-2);
}
.rn-topic-card:hover .rn-topic-link { color: var(--accent); }
.rn-topic-num {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 500;
}
.rn-topic-card h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 22px;
  line-height: 1.1;
  letter-spacing: -0.012em;
  margin: 0;
  color: var(--ink);
}
.rn-topic-card p {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--ink-soft);
  flex-grow: 1;
}
.rn-topic-link {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--hairline);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
  transition: color .15s;
}
.rn-topic-card-coming {
  opacity: 0.6;
  cursor: default;
  pointer-events: none;
}
.rn-topic-card-coming .rn-topic-num { color: var(--muted); }
.rn-topic-card-coming::after {
  content: "Coming soon";
  position: absolute;
  top: 18px;
  right: 18px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 3px 8px;
  border: 1px solid var(--hairline);
  border-radius: 999px;
}

/* ============================================================
   REVISION NOTE ARTICLE — 2-col layout
============================================================ */
.rn-wrap {
  padding: clamp(48px, 7vw, 80px) 0 clamp(28px, 4vw, 48px);
}
.rn-grid {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: start;
}

/* ── Sticky TOC ────────────────────────────────────────── */
.rn-toc {
  position: sticky;
  top: 100px;
  /* Cap to the viewport so a long contents list scrolls within itself
     instead of being clipped at the bottom while reading the notes. */
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--paper-2);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  padding: 22px 22px 20px;
}
/* Slim, unobtrusive scrollbar for the contents panel */
.rn-toc {
  scrollbar-width: thin;
  scrollbar-color: var(--hairline) transparent;
}
.rn-toc::-webkit-scrollbar {
  width: 8px;
}
.rn-toc::-webkit-scrollbar-thumb {
  background: var(--hairline);
  border-radius: 999px;
  border: 2px solid var(--paper-2);
}
.rn-toc::-webkit-scrollbar-track {
  background: transparent;
}
.rn-toc-title {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 500;
  margin: 0 0 14px;
}
.rn-toc-list {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: rn-toc;
}
.rn-toc-list li {
  counter-increment: rn-toc;
  position: relative;
  padding-left: 28px;
  margin-bottom: 8px;
}
.rn-toc-list li::before {
  content: counter(rn-toc, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 1px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.04em;
  color: var(--accent);
}
.rn-toc-list a {
  font-size: 13px;
  line-height: 1.4;
  color: var(--ink-soft);
  text-decoration: none;
  transition: color .15s;
}
.rn-toc-list a:hover,
.rn-toc-list a.is-active { color: var(--ink); }
.rn-toc-divider {
  border: 0;
  border-top: 1px solid var(--hairline);
  margin: 16px 0;
}
.rn-toc-meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.02em;
  color: var(--muted);
  line-height: 1.5;
}
.rn-toc-meta .tag {
  font-size: 9px;
  margin-left: 0;
}
.rn-toc-meta .tag-dot {
  font-size: 10px;
  margin-right: 7px;
}
/* Keep a pair of tier badges together so they wrap as one unit
   rather than splitting across two lines. */
.rn-toc-tags { white-space: nowrap; }

.rn-print-btn {
  margin-top: 12px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: 100%;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--hairline);
  padding: 10px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: background .15s, color .15s, border-color .15s;
}
.rn-print-btn:hover {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}

/* ── Main content ──────────────────────────────────────── */
.rn-content { min-width: 0; }
.rn-content > h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(28px, 3vw, 38px);
  line-height: 1.08;
  letter-spacing: -0.018em;
  color: var(--ink);
  margin: 56px 0 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--hairline);
  display: flex;
  align-items: center;
  gap: 14px;
  scroll-margin-top: 100px;
}
.rn-content > h2:first-child { margin-top: 0; }
.section-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  background: var(--ink);
  color: var(--paper);
  border-radius: 50%;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.02em;
  flex-shrink: 0;
}
.rn-content > h3 {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 17px;
  letter-spacing: -0.005em;
  color: var(--ink);
  margin: 32px 0 10px;
}
.rn-content > p {
  margin: 0 0 18px;
  font-size: 16.5px;
  line-height: 1.7;
  color: var(--ink-soft);
}
.rn-content > p strong { color: var(--ink); font-weight: 600; }
.rn-content > p em { color: var(--ink); font-style: italic; }
.rn-content > ul,
.rn-content > ol {
  padding-left: 0;
  list-style: none;
  display: grid;
  gap: 10px;
  margin: 0 0 22px;
  font-size: 15.5px;
  line-height: 1.6;
  color: var(--ink-soft);
}
.rn-content > ul li,
.rn-content > ol li {
  position: relative;
  padding-left: 24px;
}
.rn-content > ul li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.7em;
  width: 12px; height: 1px;
  background: var(--accent);
}
.rn-content > ol {
  counter-reset: rn-ol;
}
.rn-content > ol > li {
  counter-increment: rn-ol;
}
.rn-content > ol > li::before {
  content: counter(rn-ol, decimal-leading-zero) ".";
  position: absolute;
  left: 0; top: 0;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--accent);
  font-weight: 500;
  line-height: 1.9;
}
.rn-content li strong { color: var(--ink); font-weight: 600; }
.rn-content a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  text-decoration-color: color-mix(in srgb, var(--accent) 50%, transparent);
  transition: color .15s, text-decoration-color .15s;
}
.rn-content a:hover {
  color: var(--accent);
  text-decoration-color: var(--accent);
}
.rn-content sub, .rn-content sup {
  font-size: 0.72em;
  line-height: 0;
}

/* Equation / formula highlight (e.g. <p style="background...") */
.rn-eq {
  background: var(--paper-2);
  border-left: 3px solid var(--accent);
  padding: 12px 18px;
  font-weight: 500;
  font-family: var(--font-mono);
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--ink);
  margin: 0 0 18px;
}

/* ============================================================
   CALLOUTS — definition / key / tip / warning
============================================================ */
.callout {
  border: 1px solid var(--hairline);
  border-left-width: 4px;
  border-radius: 0 4px 4px 0;
  padding: 18px 22px;
  margin: 24px 0;
  background: var(--paper-2);
  font-size: 15.5px;
}
.callout-title {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 500;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.callout p {
  margin: 0 0 8px;
  line-height: 1.65;
  color: var(--ink-soft);
}
.callout p:last-child { margin-bottom: 0; }
.callout p strong { color: var(--ink); font-weight: 600; }
.callout p em { color: var(--ink); }
.callout ul,
.callout ol {
  padding-left: 0;
  list-style: none;
  margin: 8px 0 0;
  display: grid;
  gap: 6px;
}
.callout ul li,
.callout ol li {
  position: relative;
  padding-left: 20px;
  line-height: 1.6;
  color: var(--ink-soft);
}
.callout ul li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.7em;
  width: 10px; height: 1px;
  background: currentColor;
  opacity: 0.5;
}
.callout ol {
  counter-reset: cl-ol;
}
.callout ol > li {
  counter-increment: cl-ol;
}
.callout ol > li::before {
  content: counter(cl-ol) ".";
  position: absolute;
  left: 0; top: 0;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  color: currentColor;
  opacity: 0.7;
  line-height: 1.7;
}
.callout li strong { color: var(--ink); font-weight: 600; }

/* Variant colours: just the left border + title color */
.callout-def       { border-left-color: var(--ink); }
.callout-def .callout-title { color: var(--ink); }
.callout-key       { border-left-color: var(--accent); }
.callout-key .callout-title { color: var(--accent); }
.callout-tip       { border-left-color: oklch(0.55 0.11 75); }
.callout-tip .callout-title { color: oklch(0.45 0.11 75); }
.callout-warn      { border-left-color: oklch(0.55 0.15 25); }
.callout-warn .callout-title { color: oklch(0.45 0.15 25); }

/* ============================================================
   TABLES — editorial restyle
============================================================ */
.rn-table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0 28px;
  font-size: 14.5px;
  border: 1px solid var(--hairline);
}
.rn-table th {
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-mono);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 10px 14px;
  text-align: left;
  vertical-align: top;
}
.rn-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--hairline);
  vertical-align: top;
  line-height: 1.55;
  color: var(--ink-soft);
}
.rn-table tr:last-child td { border-bottom: 0; }
.rn-table tr:nth-child(even) td { background: var(--paper-2); }
.rn-table .highlight-col {
  font-weight: 500;
  color: var(--ink);
  font-family: var(--font-body);
}
.rn-table td strong { color: var(--ink); font-weight: 600; }

/* ============================================================
   TIMELINE — history of the atom
============================================================ */
.rn-timeline {
  list-style: none;
  padding: 0;
  margin: 16px 0 28px;
  border-left: 1px solid var(--hairline);
  position: relative;
}
.rn-timeline-item {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 24px;
  padding: 24px 0 24px 24px;
  position: relative;
  border-bottom: 1px solid var(--hairline);
}
.rn-timeline-item:last-child { border-bottom: 0; }
.rn-timeline-item::before {
  content: "";
  position: absolute;
  left: -5px; top: 30px;
  width: 9px; height: 9px;
  background: var(--accent);
  border-radius: 50%;
  border: 2px solid var(--paper);
  box-shadow: 0 0 0 1px var(--accent);
}
.rn-timeline-date {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  font-weight: 500;
  color: var(--accent);
  padding-top: 2px;
}
.rn-timeline-scientist {
  font-family: var(--font-display);
  font-size: 22px;
  line-height: 1.1;
  letter-spacing: -0.012em;
  font-weight: 400;
  margin: 0 0 8px;
  color: var(--ink);
}
.rn-timeline-body p {
  margin: 0 0 10px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-soft);
}
.rn-timeline-body p:last-child { margin-bottom: 0; }
.rn-timeline-body strong { color: var(--ink); font-weight: 600; }
.rn-timeline-body em { color: var(--ink); }
.rn-timeline-body ul {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
  display: grid;
  gap: 6px;
}
.rn-timeline-body ul li {
  position: relative;
  padding-left: 20px;
  font-size: 14.5px;
  line-height: 1.55;
  color: var(--ink-soft);
}
.rn-timeline-body ul li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.7em;
  width: 10px; height: 1px;
  background: var(--accent);
}

.rn-portrait {
  float: right;
  margin: 0 0 12px 20px;
  text-align: center;
  width: 88px;
}
.rn-portrait img {
  width: 100%;
  height: 88px;
  object-fit: cover;
  border: 1px solid var(--hairline);
  border-radius: 2px;
  background: var(--paper-2);
  display: block;
}
.rn-portrait figcaption {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin-top: 6px;
  text-transform: uppercase;
}

/* ============================================================
   FIGURES & IMAGES
============================================================ */
.rn-img-figure {
  margin: 18px 0 22px;
}
.rn-img-figure.center { text-align: center; }
.rn-img-figure img {
  max-width: 100%;
  border: 1px solid var(--hairline);
  border-radius: 2px;
  background: var(--paper-2);
  display: block;
}
.rn-img-figure.center img { margin: 0 auto; }
.rn-img-caption {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--muted);
  margin: 8px 0 0;
  line-height: 1.5;
  text-transform: uppercase;
}
/* Chemical formulae keep their correct case (e.g. SiO₂, NaCl, HCl) even inside
   uppercase editorial labels like .rn-img-caption, .callout-title and mono labels. */
.rn-chem { text-transform: none; letter-spacing: normal; }
/* Scrollable figures (e.g. full periodic table SVG) — scroll rather than shrink on mobile */
.rn-img-figure--scrollable {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.rn-img-figure--scrollable svg {
  min-width: 560px;
}

/* ============================================================
   ATOM DIAGRAM
============================================================ */
.atom-diagram {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 28px 0 32px;
  padding: 28px;
  background: var(--paper-2);
  border: 1px solid var(--hairline);
  border-radius: 4px;
}
.atom-outer {
  width: 220px;
  height: 220px;
  border-radius: 50%;
  border: 1px dashed color-mix(in srgb, var(--ink) 25%, transparent);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.atom-nucleus {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--paper);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-align: center;
  line-height: 1.2;
  letter-spacing: 0.02em;
}
.atom-shell {
  position: absolute;
  border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--ink) 18%, transparent);
}
.atom-shell-1 { width: 100px; height: 100px; }
.atom-shell-2 { width: 170px; height: 170px; }
.atom-electron {
  position: absolute;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--paper);
}
.atom-caption {
  margin-top: 16px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--muted);
  text-align: center;
  text-transform: uppercase;
}

/* ============================================================
   ELECTRONIC CONFIG GRID
============================================================ */
.econfig-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1px;
  background: var(--hairline);
  border: 1px solid var(--hairline);
  margin: 18px 0 28px;
}
.econfig-card {
  background: var(--paper);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13.5px;
  color: var(--ink-soft);
}
.econfig-symbol {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--ink);
  line-height: 1.1;
}
.econfig-config {
  font-family: var(--font-mono);
  font-size: 13.5px;
  font-weight: 500;
  color: var(--accent);
  letter-spacing: 0.02em;
}
.econfig-note {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.02em;
  color: var(--muted);
  margin-top: 2px;
  line-height: 1.4;
  text-transform: uppercase;
}

/* ── Periodic table layout ──────────────────────────────────── */
.econfig-ptable {
  display: grid;
  grid-template-columns: auto repeat(2, 1fr) 28px repeat(6, 1fr);
  gap: 4px;
  margin: 16px 0 24px;
  overflow-x: auto;
}
.econfig-period-label {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 6px;
  font-size: 0.68rem;
  font-weight: 600;
  color: #6a7e88;
  white-space: nowrap;
  letter-spacing: 0.02em;
}
.econfig-gh {
  background: #e8f0f5;
  border: 1px solid #c8d8e4;
  border-radius: 6px;
  font-size: 0.65rem;
  font-weight: 700;
  color: #3a5a6a;
  text-align: center;
  padding: 4px 2px;
  white-space: nowrap;
}
.econfig-ptable .econfig-card {
  padding: 6px 5px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
  min-width: 0;
  text-align: center;
}
.econfig-ptable .econfig-symbol {
  font-size: 1.05rem;
  font-weight: 700;
  color: #0a2d4a;
  line-height: 1;
  text-transform: none;
  letter-spacing: 0;
}
.econfig-name {
  font-size: 0.6rem;
  color: #4a6070;
  line-height: 1.2;
  text-transform: none;
  font-family: var(--font-sans);
}
.econfig-ptable .econfig-config {
  font-size: 0.72rem;
  margin-top: 3px;
}
.econfig-ptable .econfig-note { display: none; }
.econfig-ptable-gap {
  border: 1px dashed #b8ccd4;
  border-radius: 6px;
  background: repeating-linear-gradient(45deg, transparent, transparent 3px, rgba(0,0,0,0.035) 3px, rgba(0,0,0,0.035) 6px);
  display: flex;
  align-items: center;
  justify-content: center;
}
.econfig-ptable-gap span {
  writing-mode: vertical-rl;
  font-size: 0.58rem;
  color: #7a9aaa;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-family: var(--font-mono);
}
.econfig-noble { background: #eef5f0; border-color: #afd0b8; }
.econfig-noble .econfig-symbol { color: #1c6040; }

.econfig-ptable .econfig-card { cursor: pointer; }

.econfig-popup {
  position: fixed;
  width: 140px;
  height: 140px;
  background: #f8f5ef;
  border: 1px solid #d4ccc4;
  border-radius: 10px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.13);
  padding: 6px;
  box-sizing: border-box;
  opacity: 0;
  pointer-events: none;
  z-index: 50;
  transform: translateY(4px);
  transition: opacity 0.12s ease, transform 0.12s ease;
}
.econfig-popup.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.econfig-popup svg { width: 100%; height: 100%; display: block; }

/* ============================================================
   RESPONSIVE
============================================================ */
@media (max-width: 960px) {
  .rn-grid { grid-template-columns: 1fr; gap: 32px; }
  /* Single column: let the contents list flow naturally rather than
     becoming a cramped internal scroll box. */
  .rn-toc { position: static; max-height: none; overflow-y: visible; }
  .rn-timeline-item { grid-template-columns: 1fr; gap: 4px; }
}
@media (max-width: 720px) {
  /* Tables scroll horizontally rather than overflowing or squashing */
  .rn-table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}
@media (max-width: 600px) {
  .rn-portrait { float: none; margin: 0 0 12px; width: 100%; max-width: 200px; }
  .rn-portrait img { height: auto; aspect-ratio: 1 / 1; }
  .rn-content > h2 { gap: 10px; font-size: 24px; }
  .section-num { width: 30px; height: 30px; font-size: 11px; }
  /* Clear inline floats on timeline figures (Thomson, Rutherford diagrams) */
  .rn-timeline-body .rn-img-figure {
    float: none !important;
    width: 100% !important;
    margin: 0 0 16px 0 !important;
  }
}

/* ============================================================
   TABLE UTILITY WIDTH CLASSES
============================================================ */
.rn-table--narrow { max-width: 420px; }
.rn-table--med    { max-width: 620px; }

/* ============================================================
   PRACTICE QUESTIONS — <details>/<summary> reveal component
============================================================ */
.rn-practice {
  border: 1px solid var(--hairline);
  border-left: 4px solid oklch(0.52 0.13 200);
  border-radius: 0 4px 4px 0;
  margin: 28px 0;
  background: var(--paper-2);
  overflow: hidden;
}
.rn-practice-header {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 500;
  color: oklch(0.40 0.12 200);
  padding: 14px 22px 6px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.rn-practice-q {
  padding: 0 22px 14px;
  font-size: 15.5px;
  line-height: 1.65;
  color: var(--ink-soft);
  margin: 0;
}
.rn-practice-q strong { color: var(--ink); font-weight: 600; }
/* Descendant combinator so reveals nested inside .rn-exam-q (e.g. C4's
   per-question answers) get the same styling as direct children. */
.rn-practice details {
  border-top: 1px solid var(--hairline);
}
.rn-practice details > summary {
  padding: 10px 22px;
  cursor: pointer;
  font-family: var(--font-mono);
  /* font-size:0 hides the literal "Show answer" text node so it doesn't
     duplicate the ::after label; ::after restores its own size below. */
  font-size: 0;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 500;
  color: oklch(0.40 0.12 200);
  list-style: none;
  display: flex;
  align-items: center;
  gap: 8px;
  user-select: none;
  transition: background .15s;
}
.rn-practice details > summary::-webkit-details-marker { display: none; }
.rn-practice details > summary::after {
  content: "Show answer →";
  font-size: 11px;
  margin-left: auto;
}
.rn-practice details[open] > summary::after { content: "Hide ↑"; }
.rn-practice details > summary:hover {
  background: color-mix(in srgb, oklch(0.52 0.13 200) 8%, transparent);
}
.rn-practice-answer {
  padding: 14px 22px;
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink-soft);
  border-top: 1px solid var(--hairline);
}
.rn-practice-answer p { margin: 0 0 8px; }
.rn-practice-answer p:last-child { margin-bottom: 0; }
.rn-practice-answer strong { color: var(--ink); font-weight: 600; }
.rn-practice-answer ul {
  list-style: none;
  padding: 0;
  margin: 6px 0 0;
  display: grid;
  gap: 4px;
}
.rn-practice-answer ul li {
  position: relative;
  padding-left: 18px;
  line-height: 1.55;
}
.rn-practice-answer ul li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.7em;
  width: 10px; height: 1px;
  background: oklch(0.52 0.13 200);
}

/* ============================================================
   COLLAPSIBLE EXAM SECTIONS — testing practice tucked behind a bar
   (.rn-practice container upgraded from <div> to <details>; the
   header becomes a full-width clickable summary. Closed by default
   so teaching content isn't crowded by question banks.)
============================================================ */
details.rn-practice--collapsible > summary.rn-practice-summary {
  cursor: pointer;
  list-style: none;
  user-select: none;
  padding: 13px 22px;          /* balanced bar when closed */
  align-items: center;
  transition: background .15s;
}
details.rn-practice--collapsible > summary.rn-practice-summary::-webkit-details-marker { display: none; }
details.rn-practice--collapsible > summary.rn-practice-summary::after {
  content: "Show questions ↓";
  margin-left: auto;
  font-size: 10.5px;
  letter-spacing: 0.06em;
  color: var(--muted);
  flex: none;
}
details.rn-practice--collapsible[open] > summary.rn-practice-summary::after { content: "Hide ↑"; }
details.rn-practice--collapsible > summary.rn-practice-summary:hover {
  background: color-mix(in srgb, oklch(0.52 0.13 200) 8%, transparent);
}
details.rn-practice--collapsible[open] > summary.rn-practice-summary {
  border-bottom: 1px solid var(--hairline);
}

/* ============================================================
   EXAM-STYLE QUESTIONS — builds on .rn-practice
   (interactive MCQ tick-boxes, type-in numeric, equation balancing)
============================================================ */
.rn-exam-q { padding: 15px 22px 17px; border-top: 1px solid var(--hairline); }
.rn-exam-qhead { display: flex; align-items: baseline; gap: 12px; margin-bottom: 10px; }
.rn-exam-num {
  font-family: var(--font-mono); font-size: 11px; font-weight: 500; letter-spacing: 0.05em;
  color: var(--paper); background: oklch(0.40 0.12 200);
  padding: 2px 8px; border-radius: 3px; flex: none;
}
.rn-exam-marks { font-family: var(--font-mono); font-size: 11px; color: var(--muted); margin-left: auto; flex: none; }
.rn-exam-stem { font-size: 15.5px; line-height: 1.6; color: var(--ink-soft); margin: 0; }
.rn-exam-stem + .rn-exam-stem { margin-top: 9px; }
.rn-exam-stem strong { color: var(--ink); font-weight: 600; }
.rn-exam-instr { display: block; margin-top: 5px; font-size: 13px; color: var(--muted); font-style: italic; }
.rn-exam-given {
  margin: 13px 0 0; padding: 9px 13px; border-left: 2px solid oklch(0.52 0.13 200);
  background: var(--paper); font-size: 13.5px; line-height: 1.55; color: var(--ink-soft);
  border-radius: 0 3px 3px 0;
}
.rn-exam-given strong { color: var(--ink); font-weight: 600; }
.rn-exam-eq, .rn-exam-work { font-family: var(--font-mono); font-size: 13px; color: var(--ink); }
.rn-exam-mk { font-family: var(--font-mono); font-size: 10px; font-weight: 500; letter-spacing: 0.04em; text-transform: uppercase; color: oklch(0.40 0.12 200); background: oklch(0.95 0.025 200); border: 1px solid oklch(0.82 0.04 200); border-radius: 3px; padding: 1px 5px; white-space: nowrap; }
.rn-exam-note { color: var(--muted); font-size: 13px; }
.rn-exam-src { margin: 14px 0 0; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); }
/* Interactive tick-the-box options — feedback colours mirror .rn-classify */
.rn-exam-options { padding: 0; margin: 13px 0 0; display: grid; gap: 8px; }
.rn-exam-option {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left;
  font-family: inherit; font-size: 15px; color: var(--ink-soft);
  min-height: 44px;                 /* comfortable touch target on phones */
  padding: 8px 11px; border: 1px solid var(--hairline); border-radius: 4px;
  background: var(--paper); cursor: pointer; transition: background .12s, border-color .12s;
}
.rn-exam-option:hover:not(:disabled) { background: var(--paper-2); border-color: var(--ink-soft); }
.rn-exam-option:disabled { cursor: default; }
.rn-exam-option:focus-visible { outline: 2px solid oklch(0.52 0.13 200); outline-offset: 2px; }
.rn-exam-box {
  flex: none; width: 17px; height: 17px; border: 1.5px solid var(--muted); border-radius: 3px;
  background: var(--paper); display: inline-flex; align-items: center; justify-content: center;
  font-size: 12px; line-height: 1; color: var(--paper); font-weight: 700;
}
.rn-exam-option.opt-ok  { background: oklch(0.95 0.04 155); border-color: oklch(0.50 0.15 155); color: oklch(0.30 0.12 155); }
.rn-exam-option.opt-err { background: oklch(0.96 0.04 25);  border-color: oklch(0.55 0.15 25);  color: oklch(0.35 0.15 25); }
.rn-exam-option.opt-dim { opacity: 0.4; }
.rn-exam-option.opt-ok  .rn-exam-box { border-color: oklch(0.45 0.15 155); background: oklch(0.52 0.15 155); }
.rn-exam-option.opt-ok  .rn-exam-box::after { content: "✓"; }
.rn-exam-option.opt-err .rn-exam-box { border-color: oklch(0.55 0.15 25);  background: oklch(0.60 0.17 25); }
.rn-exam-option.opt-err .rn-exam-box::after { content: "✗"; }
.rn-exam-feedback { margin: 12px 0 0; font-family: var(--font-mono); font-size: 12px; font-weight: 500; letter-spacing: 0.02em; }
.rn-exam-feedback:empty { display: none; }
.rn-exam-feedback.fc-ok  { color: oklch(0.38 0.13 155); }
.rn-exam-feedback.fc-err { color: oklch(0.45 0.15 25); }
.rn-exam-explanation {
  margin: 9px 0 0; padding: 11px 14px; border-radius: 3px; font-size: 14.5px; line-height: 1.6;
  border: 1px solid var(--hairline); background: var(--paper-2); color: var(--ink-soft);
}
.rn-exam-explanation.fc-ok  { background: oklch(0.95 0.04 155); color: oklch(0.30 0.12 155); border-color: oklch(0.50 0.15 155); }
.rn-exam-explanation.fc-err { background: oklch(0.96 0.04 25);  color: oklch(0.35 0.15 25);  border-color: oklch(0.55 0.15 25); }
.rn-exam-explanation strong { color: inherit; font-weight: 700; }
/* Type-in numeric answers */
.rn-exam-numeric { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 9px; margin: 13px 0 0; }
.rn-exam-numeric + .rn-exam-numeric { margin-top: 9px; }
.rn-exam-ilabel { font-family: var(--font-mono); font-size: 12.5px; color: var(--muted); }
.rn-exam-field {
  font-family: var(--font-mono); font-size: 15px; color: var(--ink);
  width: 130px; max-width: 46vw; padding: 8px 11px;
  border: 1px solid var(--hairline); border-radius: 4px; background: var(--paper);
}
.rn-exam-field::placeholder { color: var(--muted); opacity: 0.55; }
.rn-exam-field:focus-visible { outline: 2px solid oklch(0.52 0.13 200); outline-offset: 1px; border-color: oklch(0.52 0.13 200); }
.rn-exam-unit { font-family: var(--font-mono); font-size: 14px; color: var(--ink-soft); }
.rn-exam-field.is-ok  { border-color: oklch(0.50 0.15 155); background: oklch(0.96 0.035 155); color: oklch(0.30 0.12 155); font-weight: 600; }
.rn-exam-field.is-err { border-color: oklch(0.58 0.16 25);  background: oklch(0.96 0.035 25);  color: oklch(0.38 0.16 25); }
.rn-exam-check {
  display: inline-block; margin-top: 11px;
  font-family: var(--font-mono); font-size: 11.5px; font-weight: 500; letter-spacing: 0.05em; text-transform: uppercase;
  color: var(--paper); background: oklch(0.40 0.12 200); border: 1px solid oklch(0.40 0.12 200);
  padding: 9px 17px; border-radius: 4px; cursor: pointer; transition: background .12s;
}
.rn-exam-check:hover { background: oklch(0.34 0.12 200); }
.rn-exam-check:focus-visible { outline: 2px solid oklch(0.52 0.13 200); outline-offset: 2px; }
/* Interactive balancing */
.rn-exam-eqline {
  display: flex; flex-wrap: wrap; align-items: center; gap: 4px 7px; margin: 14px 0 2px;
  font-family: var(--font-mono); font-size: 15.5px; color: var(--ink); line-height: 2;
}
.rn-exam-eqline .rn-exam-check { margin-top: 0; margin-left: 6px; }
.rn-exam-coef {
  font-family: var(--font-mono); font-size: 15px; font-weight: 600; color: var(--accent);
  width: 40px; text-align: center; padding: 6px 2px;
  border: 1px solid var(--hairline); border-radius: 4px; background: var(--paper);
}
.rn-exam-coef::placeholder { color: var(--muted); opacity: 0.5; font-weight: 400; }
.rn-exam-coef:focus-visible { outline: 2px solid oklch(0.52 0.13 200); outline-offset: 1px; border-color: oklch(0.52 0.13 200); }
.rn-exam-coef.is-ok  { border-color: oklch(0.50 0.15 155); background: oklch(0.96 0.035 155); color: oklch(0.30 0.12 155); }
.rn-exam-coef.is-err { border-color: oklch(0.58 0.16 25);  background: oklch(0.96 0.035 25);  color: oklch(0.38 0.16 25); }

/* ============================================================
   ASIDE — beyond-spec / interesting note
============================================================ */
.rn-aside {
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
  border-left: 2px solid var(--hairline);
  padding: 4px 14px;
  margin: 10px 0 12px;
  font-style: italic;
}
.rn-aside strong { color: var(--ink-soft); font-weight: 600; font-style: normal; }

/* ============================================================
   FORWARD LINK — "covered later" signposting banner
============================================================ */
.rn-forward-link {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 18px;
  background: var(--paper-2);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  margin: 16px 0 24px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink-soft);
}
.rn-forward-link-icon {
  font-size: 16px;
  flex-shrink: 0;
  margin-top: 1px;
}
.rn-forward-link a {
  color: var(--accent);
  font-weight: 500;
  text-decoration: none;
}
.rn-forward-link a:hover { text-decoration: underline; }

/* ============================================================
   RUTHERFORD DIAGRAM
============================================================ */
.rn-rutherford-svg {
  display: block;
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  border: 1px solid var(--hairline);
  border-radius: 2px;
  background: var(--paper-2);
}

/* ============================================================
   INLINE FRACTION — for equation display
============================================================ */
.rn-frac {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  vertical-align: middle;
  line-height: 1.3;
  margin: 0 2px;
}
.rn-frac-num {
  border-bottom: 1.5px solid currentColor;
  padding: 0 6px 3px;
}
.rn-frac-den {
  padding: 3px 6px 0;
}

/* ============================================================
   PARTICLE INPUT TABLE — interactive practice
============================================================ */
.rn-practice-hint {
  font-size: 14.5px;
  color: var(--ink-soft);
  margin: -8px 0 14px;
  line-height: 1.55;
}
.rn-particle-input {
  width: 68px;
  padding: 5px 8px;
  font-family: var(--font-mono);
  font-size: 13.5px;
  font-weight: 500;
  color: var(--ink);
  background: var(--paper);
  border: 1.5px solid var(--hairline);
  border-radius: 3px;
  text-align: center;
  outline: none;
  transition: border-color .15s, background .15s;
  -moz-appearance: textfield;
}
.rn-particle-input::-webkit-inner-spin-button,
.rn-particle-input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.rn-particle-input:focus {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 6%, var(--paper));
}
.rn-particle-input.is-correct {
  border-color: oklch(0.50 0.15 155);
  background: oklch(0.95 0.04 155);
  color: oklch(0.30 0.12 155);
}
.rn-particle-input.is-incorrect {
  border-color: oklch(0.55 0.15 25);
  background: oklch(0.96 0.04 25);
  color: oklch(0.35 0.15 25);
}
.rn-practice-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: -12px 0 28px;
  flex-wrap: wrap;
}
.rn-check-btn,
.rn-reset-btn {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 500;
  padding: 9px 18px;
  border-radius: 999px;
  border: 1.5px solid;
  cursor: pointer;
  transition: background .15s, color .15s, border-color .15s;
}
.rn-check-btn {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}
.rn-check-btn:hover {
  background: oklch(0.45 0.12 200);
  border-color: oklch(0.45 0.12 200);
}
.rn-reset-btn {
  background: transparent;
  color: var(--ink-soft);
  border-color: var(--hairline);
}
.rn-reset-btn:hover {
  background: var(--paper-2);
  border-color: var(--ink-soft);
  color: var(--ink);
}
.rn-score {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--ink-soft);
}
.rn-score.is-perfect { color: oklch(0.38 0.13 155); }
.rn-score.is-partial  { color: oklch(0.45 0.11 75); }
.rn-score.is-zero     { color: oklch(0.45 0.15 25); }

/* ============================================================
   TOC GROUP HEADINGS — subheadings between content-group lists
============================================================ */
.rn-toc-subheading {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--muted);
  margin: 14px 0 6px;
  padding-bottom: 5px;
  border-bottom: 1px solid var(--hairline);
}
.rn-toc-subheading:first-of-type { margin-top: 0; }
.rn-toc-list + .rn-toc-subheading { margin-top: 14px; }

/* ============================================================
   DIAGRAM PLACEHOLDER — temporary marker for future diagrams
============================================================ */
.rn-diagram-placeholder {
  border: 1.5px dashed var(--hairline);
  border-radius: 4px;
  background: var(--paper-2);
  padding: 28px 20px;
  text-align: center;
  margin: 18px 0 24px;
}
.rn-diagram-placeholder p {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.03em;
  color: var(--muted);
  margin: 0;
  line-height: 1.6;
}

/* ============================================================
   FEEDBACK — report an error / suggestion (Formspree)
============================================================ */
.rn-feedback {
  padding: clamp(36px, 5vw, 60px) 0;
  border-top: 1px solid var(--hairline);
}
.rn-feedback-inner {
  max-width: 680px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px 24px;
}
.rn-feedback-copy { max-width: 44ch; }
.rn-feedback-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(21px, 2.4vw, 27px);
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin: 0 0 6px;
  color: var(--ink);
}
.rn-feedback-sub {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-soft);
}
.rn-feedback-toggle { flex: none; }
.rn-feedback-toggle[hidden] { display: none; }

/* Form — revealed when the toggle is pressed */
.rn-feedback-form {
  flex-basis: 100%;
  margin-top: 4px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  animation: rn-feedback-in .25s ease;
}
.rn-feedback-form[hidden] { display: none; }
@keyframes rn-feedback-in {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: none; }
}
.rn-feedback-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.rn-feedback-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
}
.rn-feedback-opt { font-weight: 400; color: var(--muted); }
.rn-feedback-form textarea,
.rn-feedback-form input[type="email"] {
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  padding: 10px 12px;
  width: 100%;
}
.rn-feedback-form textarea { resize: vertical; min-height: 92px; }
.rn-feedback-form textarea:focus,
.rn-feedback-form input[type="email"]:focus {
  outline: none;
  border-color: var(--accent);
}
.rn-feedback-form textarea::placeholder,
.rn-feedback-form input::placeholder { color: var(--muted); }
.rn-feedback-actions {
  display: flex;
  align-items: center;
  gap: 8px 18px;
  flex-wrap: wrap;
}
.rn-feedback-status {
  margin: 0;
  font-size: 14px;
  color: var(--ink-soft);
}
.rn-feedback-status.is-err { color: var(--accent); }
.rn-feedback-thanks {
  margin: 0;
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
}
@media (prefers-reduced-motion: reduce) {
  .rn-feedback-form { animation: none; }
}
@media (max-width: 560px) {
  .rn-feedback-inner { flex-direction: column; align-items: stretch; }
  .rn-feedback-toggle { width: 100%; }
}

/* ============================================================
   TOPIC PAGER — previous / next in the Paper 1 sequence
============================================================ */
.rn-pager-section { padding: 0; }
.rn-pager {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--hairline);
  border: 1px solid var(--hairline);
}
.rn-pager-link {
  background: var(--paper);
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-decoration: none;
  color: inherit;
  transition: background .15s;
}
.rn-pager-link:hover { background: var(--paper-2); }
.rn-pager-next { align-items: flex-end; text-align: right; }
.rn-pager-dir {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.rn-pager-link:hover .rn-pager-dir { color: var(--ink-soft); }
.rn-pager-topic {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 19px;
  line-height: 1.2;
  letter-spacing: -0.012em;
  color: var(--ink);
}
.rn-pager-link:hover .rn-pager-topic { color: var(--accent); }
@media (max-width: 600px) {
  .rn-pager { grid-template-columns: 1fr; }
  .rn-pager-next { align-items: flex-start; text-align: left; }
}

/* ============================================================
   PRINT
============================================================ */
@media print {
  .header, .footer, .rn-toc, .article-cta, .final-cta, .nav-cta, .rn-feedback, .rn-pager-section { display: none !important; }
  .rn-grid { grid-template-columns: 1fr; }
  .rn-content > h2 { page-break-after: avoid; }
  .callout, .rn-table, .rn-timeline-item, .atom-diagram, .econfig-grid { break-inside: avoid; }
  body { background: white; color: black; }
}
