/* ============================================================
   Paying Attention — Ghost theme
   E. T. Brooking. "Declassified Modern".

   Charter: brand/website/DESIGN.md (binding). Tokens are law.
   Ported from etbrooking.com (Astro, src/styles/global.css) so the
   newsletter reads as the same property: same faces, same tokens,
   same index rows, same document header, same flat surfaces.

   Nothing here is loaded from a CDN. All three faces are self-hosted
   in assets/fonts/.
   ============================================================ */

/* ---------- Fonts (self-hosted, no CDN — DESIGN.md §3) ---------- */
@font-face {
  font-family: "Newsreader";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url(../fonts/newsreader.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Newsreader";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url(../fonts/newsreader-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Newsreader";
  font-style: italic;
  font-weight: 300 600;
  font-display: swap;
  src: url(../fonts/newsreader-italic.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Newsreader";
  font-style: italic;
  font-weight: 300 600;
  font-display: swap;
  src: url(../fonts/newsreader-italic-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Public Sans";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(../fonts/public-sans-v.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Public Sans";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(../fonts/public-sans-ext-v.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Courier Prime";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(../fonts/courier-prime-400.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Courier Prime";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(../fonts/courier-prime-400-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Courier Prime";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(../fonts/courier-prime-700.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Courier Prime";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(../fonts/courier-prime-700-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- Tokens (DESIGN.md §2, verbatim) ---------- */
:root {
  --paper: #F8F8F5;
  --well: #EFEFEA;
  --ink: #1B1E20;
  --body: #33383B;
  --muted: #6C7176;
  --rule: #D9DBD4;
  --accent: #8A2433;
  --accent-hover: #6F1D29;
  --accent-deep: #560015;
  --signal: #3E6B66; /* inside figures/charts only, never UI chrome */

  /* Ghost's Koenig cards read these; pinning them keeps injected card
     CSS inside the palette instead of Ghost's blues and greys. */
  --color-primary-text: var(--body);
  --ghost-accent-color: var(--accent);
}

/* The charter has no dark scheme. One is not invented here; the
   declaration only stops the UA from painting dark form controls. */
:root { color-scheme: light; }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; }
/* Full-bleed cards use 100vw; clip the scrollbar-width overshoot. */
html { overflow-x: clip; }
body {
  background: var(--paper);
  color: var(--body);
  font-family: "Newsreader", Georgia, serif;
  font-size: 18px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; text-underline-offset: 3px; }
img { max-width: 100%; height: auto; }
.mono { font-family: "Courier Prime", "Courier New", monospace; }
em, i { font-style: italic; } /* cited work titles and quotations only */
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--paper); color: var(--accent);
  padding: 8px 14px; z-index: 10;
  font-family: "Public Sans", sans-serif; font-size: .85rem;
}
.skip-link:focus { left: 0; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0;
}

/* ---------- Masthead ---------- */
header.masthead { border-bottom: 1px solid var(--rule); }
/* One frame, 1080px — the charter's grid cap (§5) — governs masthead,
   apparatus rail, index pages and footer. The 720 measure centres
   inside it. Content wider than the frame is a bug. */
.bar {
  max-width: 1080px; margin: 0 auto;
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 20px 32px; gap: 12px 24px;
}
.wordmark {
  font-family: "Public Sans", sans-serif; font-weight: 800;
  font-size: 1.05rem; letter-spacing: -.01em; color: var(--ink);
  white-space: nowrap;
}
.wordmark span { color: var(--accent-deep); }
a.wordmark:hover { color: var(--accent-deep); text-decoration: none; }
nav.sitenav { display: flex; gap: 26px; align-items: baseline; flex-wrap: wrap; }
nav.sitenav a {
  font-family: "Public Sans", sans-serif; font-weight: 600;
  font-size: .88rem; color: var(--body); white-space: nowrap;
}
nav.sitenav a:hover { color: var(--accent); text-decoration: none; }
nav.sitenav a[aria-current="page"] { color: var(--accent); }
nav.sitenav a.offsite .outmark {
  font-family: "Courier Prime", "Courier New", monospace;
  color: var(--muted); font-size: .9em; padding-left: 2px;
}
nav.sitenav a.offsite:hover .outmark { color: var(--accent); }
/* The page's single solid button (DESIGN.md §4). */
nav.sitenav a.subscribe {
  background: var(--accent); color: var(--paper);
  padding: 7px 14px; border-radius: 2px;
}
nav.sitenav a.subscribe:hover { background: var(--accent-hover); color: var(--paper); text-decoration: none; }
.apparatus {
  max-width: 1080px; margin: 0 auto; padding: 10px 32px 0;
  font-size: .72rem; color: var(--muted); letter-spacing: .02em;
  text-transform: uppercase;
}

/* ---------- Layout containers (DESIGN.md §5 — two widths, exactly) ---------- */
.measure { max-width: 720px; margin: 0 auto; padding: 0 32px; }
.wide { max-width: 1080px; margin: 0 auto; padding: 0 32px; }

/* ---------- Plate (site signature, DESIGN.md §4) ---------- */
figure.plate { margin: 0; border: 1px solid var(--rule); padding: 10px; background: #fff; }
figure.plate img { display: block; width: 100%; height: auto; }
figure.plate figcaption {
  padding: 9px 2px 1px; font-size: .72rem; line-height: 1.5; color: var(--muted);
  font-family: "Courier Prime", "Courier New", monospace;
}
figure.plate figcaption a { color: inherit; text-decoration: underline; text-underline-offset: 2px; text-decoration-color: var(--rule); }
figure.plate figcaption a:hover { color: var(--accent); text-decoration-color: currentColor; }
.plate.feature { margin: 26px 0 6px; }

/* ---------- Section rules ---------- */
hr.divider { border: none; border-top: 1px dashed var(--rule); margin: 0 0 14px; }
hr.divider.act { margin: 56px 0 14px; }

/* ---------- Issue number (see partials/issue-serial.hbs) ---------- */
/* Only internal tags whose slug starts `hash-issue-` are shown. Every
   other internal tag renders nothing at all — no number is ever
   invented (DESIGN.md §7). */
.serial { display: none; }
.serial[data-tag^="hash-issue-"] { display: inline; text-transform: none; }
/* In the document header the separator lives inside the span so it
   disappears with it when a post carries no issue tag. */
.doc-meta .serial[data-tag^="hash-issue-"]::before { content: "\00a0\00B7\00a0"; }
/* Clip the fixed 11-character `hash-issue-` prefix. Courier Prime is
   monospace, so 11ch is the exact advance of those 11 glyphs; the
   negative margin reclaims the space the clipped run would occupy.
   letter-spacing must be 0 here or the ch arithmetic drifts. */
.serial-n {
  display: inline-block;
  font-family: "Courier Prime", "Courier New", monospace;
  letter-spacing: 0;
  margin-left: -11ch;
  clip-path: inset(0 0 0 11ch);
}

/* ---------- Index (the archive) ---------- */
.idx { padding: 30px 0 24px; }
.pa-head {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 10px 24px;
  border-top: 1px solid var(--ink); padding: 10px 0 8px;
  font-size: .74rem; color: var(--muted); text-transform: uppercase;
}
.pa-head b { color: var(--accent); font-weight: 700; }

table.index { width: 100%; border-collapse: collapse; border-top: 1px solid var(--ink); }
table.index td { border-top: 1px solid var(--rule); padding: 15px 0; vertical-align: baseline; }
table.index tbody:first-child tr:first-child td { border-top: none; }
/* Hovering anywhere in an entry lights the title and its destination;
   clicking stays on the links themselves. No motion, no underline
   animation, no card lift. */
table.index tbody.entry:hover td.t a,
table.index tbody.entry:hover td.m a.onsite { color: var(--accent); }
table.index td.c {
  white-space: nowrap; font-size: .72rem; color: var(--muted);
  padding-right: 22px; width: 1%;
}
table.index td.c .cstack { display: inline-flex; flex-direction: column; align-items: flex-start; }
table.index td.t { font-size: 1.22rem; line-height: 1.35; color: var(--ink); font-family: "Newsreader", Georgia, serif; }
table.index td.t a { color: var(--ink); }
table.index td.t a:hover { color: var(--accent); text-decoration: none; }
table.index td.m {
  text-align: right; white-space: nowrap; font-size: .74rem;
  color: var(--muted); padding-left: 24px; text-transform: uppercase;
}
/* Date under the title, over the lede — the site-wide index-row
   grammar. The meta cell holds destinations only. */
table.index td.t .idate {
  font-size: .7rem; color: var(--muted); letter-spacing: .02em;
  margin: 3px 0 8px; line-height: 1.4; text-transform: uppercase;
}
table.index td.m a.onsite { color: var(--muted); }
table.index td.m a.onsite:hover { color: var(--accent); text-decoration: none; }
table.index td.m a.onsite .inmark { font-size: .9em; padding-left: 2px; }
.lede-excerpt { font-size: 1rem; line-height: 1.55; color: var(--body); margin: 8px 0 0; max-width: 58ch; }
.lede-excerpt.clamped {
  display: -webkit-box; -webkit-line-clamp: 4; line-clamp: 4;
  -webkit-box-orient: vertical; overflow: hidden;
}
.empty-note { font-size: 1.1rem; color: var(--body); padding: 22px 0 4px; margin: 0; }

/* ---------- Pagination ---------- */
.pagination {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 10px 24px; margin-top: 26px; padding-top: 14px;
  border-top: 1px solid var(--rule);
  font-size: .72rem; color: var(--muted); text-transform: uppercase;
  letter-spacing: .02em;
}
.pagination a.pg { color: var(--muted); }
.pagination a.pg:hover { color: var(--accent); text-decoration: none; }
.pagination .pg.off { color: var(--rule); }

/* ---------- Article/document ---------- */
.doc-header { padding: 46px 0 8px; }
.doc-header h1 {
  font-family: "Public Sans", sans-serif; font-weight: 800;
  font-size: 2.6rem; line-height: 1.05; letter-spacing: -.022em;
  color: var(--ink); margin: 0 0 14px;
}
.doc-meta {
  font-size: .74rem; color: var(--muted); letter-spacing: .02em;
  margin: 0; text-transform: uppercase;
}
.doc-meta a { color: var(--muted); }
.doc-meta a:hover { color: var(--accent); }

.prose { padding: 26px 0 8px; }
/* A page whose author switched off the title and feature image
   ({{@page.show_title_and_feature_image}}) starts with the prose;
   it keeps the document header's top margin. */
.prose:first-child { padding-top: 46px; }
.prose > p, .prose p { margin: 0 0 16px; }
.prose h2 {
  font-family: "Public Sans", sans-serif; font-weight: 800; font-size: 1.35rem;
  letter-spacing: -.01em; color: var(--ink); margin: 36px 0 12px;
}
.prose h3 { font-family: "Public Sans", sans-serif; font-weight: 600; font-size: 1.1rem; color: var(--ink); margin: 28px 0 10px; }
.prose h4, .prose h5, .prose h6 {
  font-family: "Public Sans", sans-serif; font-weight: 600; font-size: 1rem;
  color: var(--ink); margin: 24px 0 8px;
}
/* Quote bar: faint accent red, not hairline grey. */
.prose blockquote {
  margin: 0 0 16px; padding: 2px 0 2px 20px;
  border-left: 2px solid color-mix(in srgb, var(--accent) 32%, var(--paper));
  color: var(--body);
}
.prose blockquote p:last-child { margin-bottom: 0; }
.prose ul, .prose ol { margin: 0 0 16px; padding-left: 26px; }
.prose li { margin: 0 0 6px; }
.prose img { max-width: 100%; height: auto; }
.prose figure { margin: 24px 0; }
.prose hr { border: none; border-top: 1px solid var(--rule); margin: 28px 0; }
.prose code {
  font-family: "Courier Prime", "Courier New", monospace; font-size: .92em;
  background: var(--well); padding: 1px 5px;
}
.prose pre {
  background: var(--well); border: 1px solid var(--rule); padding: 14px 16px;
  overflow-x: auto; font-size: .85rem; line-height: 1.5;
  font-family: "Courier Prime", "Courier New", monospace;
}
.prose pre code { background: none; padding: 0; }
.prose table { width: 100%; border-collapse: collapse; margin: 0 0 20px; font-size: .95rem; }
.prose th, .prose td { border-top: 1px solid var(--rule); padding: 9px 10px 9px 0; text-align: left; vertical-align: top; }
.prose th { font-family: "Courier Prime", "Courier New", monospace; font-size: .72rem; text-transform: uppercase; color: var(--muted); font-weight: 400; }

/* End mark: the house dinkus, square like the punched register. */
.endmark { display: flex; gap: 7px; justify-content: center; padding: 26px 0 2px; }
.endmark span { width: 4px; height: 4px; background: var(--accent); }

.doc-tags { font-size: .72rem; color: var(--muted); text-transform: uppercase; letter-spacing: .02em; padding: 22px 0 0; margin: 0; }
.doc-tags a { color: var(--muted); }
.doc-tags a:hover { color: var(--accent); }

.backlink { font-size: .74rem; padding: 14px 0 40px; margin: 0; text-transform: uppercase; }
.backlink a { color: var(--muted); }
.backlink a:hover { color: var(--accent); }

/* ---------- Adjacent issues ---------- */
.issue-nav { padding: 30px 0 0; }
.issue-nav .adj {
  display: block; border-top: 1px solid var(--rule);
  padding: 13px 0 12px; color: var(--ink);
}
.issue-nav .adj:hover { text-decoration: none; }
.issue-nav .adj-lbl {
  display: block; font-size: .7rem; color: var(--muted);
  letter-spacing: .02em; text-transform: uppercase; margin-bottom: 3px;
}
.issue-nav .adj-t {
  display: block; font-family: "Newsreader", Georgia, serif;
  font-size: 1.08rem; line-height: 1.35; color: var(--ink);
}
.issue-nav .adj:hover .adj-t { color: var(--accent); }

/* ---------- Subscribe (native Ghost members form) ---------- */
.subscribe { padding: 42px 0 8px; }
.sub-pitch { font-size: 1.05rem; color: var(--body); margin: 14px 0 16px; max-width: 58ch; }
.sub-form { margin: 0; }
.sub-fields { display: flex; gap: 10px; flex-wrap: wrap; max-width: 520px; }
.sub-input {
  flex: 1 1 240px; min-width: 0;
  font-family: "Newsreader", Georgia, serif; font-size: 1rem;
  color: var(--ink); background: var(--paper);
  border: 1px solid var(--rule); border-radius: 0;
  padding: 10px 12px; appearance: none;
}
.sub-input::placeholder { color: var(--muted); }
.sub-input:focus { border-color: var(--accent); outline: 2px solid var(--accent); outline-offset: 1px; }
/* Hairline-framed, not solid: the masthead holds the page's one solid
   button (DESIGN.md §4). Radius 0, transparent ground. */
.sub-btn {
  font-family: "Courier Prime", "Courier New", monospace; font-size: .8rem;
  text-transform: uppercase; letter-spacing: .04em;
  color: var(--accent); background: transparent;
  border: 1px solid var(--rule); border-radius: 0;
  padding: 10px 20px; cursor: pointer;
}
.sub-btn:hover { border-color: var(--accent); color: var(--accent-hover); }
.sub-note { font-size: .72rem; letter-spacing: .02em; text-transform: uppercase; margin: 12px 0 0; }
.sub-note.msg-success { color: var(--accent); display: none; }
.sub-note.msg-error { color: var(--accent-deep); display: none; }
.sub-form.success .msg-success { display: block; }
.sub-form.error .msg-error { display: block; }
.sub-form.loading .sub-btn { color: var(--muted); border-color: var(--rule); }

/* Ghost's own upgrade/paywall CTA on gated posts. */
.gh-post-upgrade-cta, .gh-post-upgrade-cta-content {
  background: var(--well) !important; border: 1px solid var(--rule) !important;
  border-radius: 0 !important; box-shadow: none !important; color: var(--body) !important;
  padding: 26px 24px; margin: 30px 0;
}
.gh-post-upgrade-cta h2, .gh-post-upgrade-cta-content h2 {
  font-family: "Public Sans", sans-serif !important; font-weight: 800 !important;
  color: var(--ink) !important;
}
.gh-post-upgrade-cta a, .gh-post-upgrade-cta-content a {
  background: var(--accent) !important; color: var(--paper) !important;
  border-radius: 2px !important; box-shadow: none !important;
}

/* ---------- Koenig editor cards, restyled flat (DESIGN.md §6) ----------
   Ghost injects cards.min.css from {{ghost_head}}, i.e. after this
   file. These selectors are deliberately two classes deep so they win
   on specificity rather than on source order. Everything below removes
   radius, shadow and lift; depth comes from hairlines and the well. */

.gh-content { position: relative; }

/* Breakout widths ride the charter's two widths: wide reaches the
   1080 grid, full bleeds. Prose itself never leaves the 720 measure. */
.gh-content .kg-width-wide {
  position: relative; left: 50%; transform: translateX(-50%);
  width: min(1016px, calc(100vw - 40px)); max-width: none;
}
.gh-content .kg-width-full {
  position: relative; left: 50%; transform: translateX(-50%);
  width: 100vw; max-width: 100vw;
}

/* Image cards become plates: hairline frame, Courier caption. */
.gh-content .kg-image-card, .gh-content .kg-gallery-card { margin: 28px 0; }
.gh-content .kg-image-card img, .gh-content .kg-gallery-image img {
  border-radius: 0; box-shadow: none;
}
.gh-content .kg-image-card .kg-image {
  border: 1px solid var(--rule); background: #fff; padding: 10px;
  border-radius: 0; box-shadow: none;
}
.gh-content .kg-card figcaption, .gh-content .kg-card-figcaption {
  font-family: "Courier Prime", "Courier New", monospace;
  font-size: .72rem; line-height: 1.5; color: var(--muted);
  text-align: left; padding: 9px 2px 1px; max-width: none;
}
.gh-content .kg-card figcaption a { color: inherit; text-decoration: underline; text-underline-offset: 2px; text-decoration-color: var(--rule); }
.gh-content .kg-card figcaption a:hover { color: var(--accent); text-decoration-color: currentColor; }

/* Callout: a well with a hairline frame, no radius, no tint palette. */
.gh-content .kg-callout-card {
  background: var(--well) !important; border: 1px solid var(--rule);
  border-left: 2px solid var(--accent);
  border-radius: 0; box-shadow: none;
  padding: 16px 20px; margin: 26px 0;
}
.gh-content .kg-callout-card .kg-callout-text {
  font-family: "Newsreader", Georgia, serif; font-size: 1rem;
  line-height: 1.6; color: var(--body);
}
.gh-content .kg-callout-card .kg-callout-emoji { font-size: 1rem; padding-right: 12px; }

/* Bookmark: a filing record, not a shadowed preview card. */
.gh-content .kg-bookmark-card, .gh-content .kg-bookmark-container {
  border-radius: 0; box-shadow: none; margin: 26px 0;
}
.gh-content .kg-bookmark-container {
  border: 1px solid var(--rule); background: var(--paper);
  color: var(--body); text-decoration: none;
}
.gh-content .kg-bookmark-container:hover { border-color: var(--accent); text-decoration: none; }
.gh-content .kg-bookmark-content { padding: 18px 20px; }
.gh-content .kg-bookmark-title {
  font-family: "Public Sans", sans-serif; font-weight: 600;
  font-size: 1rem; color: var(--ink); line-height: 1.35;
}
.gh-content .kg-bookmark-container:hover .kg-bookmark-title { color: var(--accent); }
.gh-content .kg-bookmark-description {
  font-family: "Newsreader", Georgia, serif; font-size: .95rem;
  color: var(--body); margin-top: 6px;
}
.gh-content .kg-bookmark-metadata {
  font-family: "Courier Prime", "Courier New", monospace;
  font-size: .7rem; text-transform: uppercase; letter-spacing: .02em;
  color: var(--muted); margin-top: 10px;
}
.gh-content .kg-bookmark-thumbnail img { border-radius: 0; }

/* Blockquotes authored as cards. */
.gh-content .kg-blockquote-alt {
  font-family: "Newsreader", Georgia, serif; font-style: normal;
  font-size: 1.3rem; line-height: 1.5; color: var(--ink);
  border-left: 2px solid color-mix(in srgb, var(--accent) 32%, var(--paper));
  padding-left: 22px; text-align: left;
}

/* Buttons authored as cards: radius 2px, oxblood, flat. */
.gh-content .kg-button-card .kg-btn {
  font-family: "Public Sans", sans-serif; font-weight: 600;
  border-radius: 2px; box-shadow: none; text-transform: none;
  background: var(--accent); color: var(--paper); border: 1px solid var(--accent);
}
.gh-content .kg-button-card .kg-btn:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--paper); }
.gh-content .kg-button-card .kg-btn-accent { background: var(--accent); color: var(--paper); }

/* Toggle, file, audio, video, product, header and signup cards: strip
   radius and shadow, keep Ghost's layout. */
.gh-content .kg-toggle-card,
.gh-content .kg-file-card .kg-file-card-container,
.gh-content .kg-audio-card,
.gh-content .kg-product-card .kg-product-card-container,
.gh-content .kg-header-card,
.gh-content .kg-signup-card {
  border-radius: 0 !important; box-shadow: none !important;
  border: 1px solid var(--rule) !important; background: var(--paper) !important;
}
.gh-content .kg-toggle-card .kg-toggle-heading-text,
.gh-content .kg-file-card .kg-file-card-title,
.gh-content .kg-header-card .kg-header-card-header {
  font-family: "Public Sans", sans-serif; font-weight: 700; color: var(--ink);
}
.gh-content .kg-video-card, .gh-content .kg-embed-card { margin: 28px 0; }
.gh-content .kg-video-card .kg-video-container,
.gh-content .kg-embed-card iframe { border-radius: 0; box-shadow: none; }
.gh-content .kg-signup-card .kg-signup-card-button {
  border-radius: 2px !important; box-shadow: none !important;
  background: var(--accent) !important; color: var(--paper) !important;
}
.gh-content .kg-signup-card input {
  border-radius: 0 !important; box-shadow: none !important;
  border: 1px solid var(--rule) !important;
}

/* ---------- Footer ---------- */
footer.sitefoot { max-width: 1080px; margin: 0 auto; padding: 56px 32px 64px; }
.frule {
  border-top: 1px dashed var(--rule); padding-top: 18px;
  display: flex; justify-content: space-between; gap: 8px 28px;
  font-size: .72rem; color: var(--muted); text-transform: uppercase;
}
.frule a { color: var(--muted); white-space: nowrap; }
.frule a:hover { color: var(--accent); }

/* ---------- Load reveal (one per page, CSS-only, DESIGN.md §7) ---------- */
.r { opacity: 0; transform: translateY(6px); animation: reveal .5s ease-out forwards; }
.r2 { animation-delay: .12s; } .r3 { animation-delay: .24s; } .r4 { animation-delay: .36s; }
@keyframes reveal { to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .r { animation: none; opacity: 1; transform: none; }
  * { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

/* ---------- Responsive (DESIGN.md §8) ---------- */
/* Body holds 18px at every width; only the display scales. */
@media (max-width: 720px) {
  .doc-header h1 { font-size: 2rem; }
  .bar { padding: 16px 20px; flex-wrap: wrap; gap: 10px 0; }
  .wordmark { flex: 1 1 100%; }
  nav.sitenav { gap: 14px 18px; flex-wrap: wrap; }
  .apparatus { padding-left: 20px; padding-right: 20px; }
  .measure, .wide, footer.sitefoot { padding-left: 20px; padding-right: 20px; }
  .frule { flex-direction: column; align-items: flex-start; }
  .gh-content .kg-width-wide { width: calc(100vw - 40px); }
}
@media (max-width: 560px) {
  /* Rows stack title-over-meta; hairlines retained. Apparatus may wrap,
     never truncate — white-space resets so stacked meta cannot clip. */
  table.index tr { display: block; border-top: 1px solid var(--rule); padding: 13px 0; }
  table.index tbody:first-child tr:first-child { border-top: 1px solid var(--ink); }
  table.index td { display: block; border-top: none; padding: 0; width: auto; }
  table.index td.c { padding-right: 0; }
  table.index td.m { text-align: left; padding: 6px 0 0; white-space: normal; }
  .pa-head { flex-direction: column; }
  .pagination { flex-wrap: wrap; }
}
