/* ==========================================================================
   The Penman — design system
   Concept: an author's library and writing desk. Paper and blue-black ink,
   with scribal red ("rubric") used sparingly for marks, as medieval scribes
   used red ink for headings and notes. Lamplight gold marks things forthcoming.
   Type: Newsreader (reading & display) · IBM Plex Sans (interface) · IBM Plex Mono (references).
   ========================================================================== */
:root {
  --paper: #FBFAF7; --paper-2: #F2F0EA; --card: #FFFFFF;
  --ink: #16202C; --ink-2: #3A4555; --muted: #667080; --rule: #E2DFD7; --rule-2: #CFCAC0;
  --rubric: #A3311F; --rubric-soft: #F7E8E4; --lamp: #9C6F1E; --lamp-soft: #F6EEDD;
  --on-ink: #FBFAF7; --shadow: 0 1px 2px rgba(22,32,44,.08), 0 10px 30px rgba(22,32,44,.10);
  --serif: "Newsreader", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --shell: 1180px; --gutter: clamp(16px, 4vw, 40px); --radius: 10px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --paper: #0E131A; --paper-2: #131A23; --card: #17202A;
  --ink: #ECE9E2; --ink-2: #C8CBD1; --muted: #98A1AD; --rule: #27303C; --rule-2: #364150;
  --rubric: #E8836E; --rubric-soft: #2B1D1A; --lamp: #E0B463; --lamp-soft: #29231A;
  --on-ink: #0E131A; --shadow: 0 1px 2px rgba(0,0,0,.4), 0 12px 32px rgba(0,0,0,.35); color-scheme: dark; } }
:root[data-theme="dark"] {
  --paper: #0E131A; --paper-2: #131A23; --card: #17202A;
  --ink: #ECE9E2; --ink-2: #C8CBD1; --muted: #98A1AD; --rule: #27303C; --rule-2: #364150;
  --rubric: #E8836E; --rubric-soft: #2B1D1A; --lamp: #E0B463; --lamp-soft: #29231A;
  --on-ink: #0E131A; --shadow: 0 1px 2px rgba(0,0,0,.4), 0 12px 32px rgba(0,0,0,.35); color-scheme: dark; }

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 84px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 1.0625rem/1.6 var(--sans); text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration-color: color-mix(in srgb, currentColor 35%, transparent); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--rubric); text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--rubric); outline-offset: 3px; border-radius: 4px; }
[hidden] { display: none !important; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 500; line-height: 1.15; margin: 0; text-wrap: balance; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }
button, input, select, textarea { font: inherit; color: inherit; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--ink); color: var(--on-ink); padding: 10px 14px; border-radius: 6px; z-index: 100; }
.skip:focus { top: 12px; }
main { display: block; outline: none; }
.shell { width: 100%; max-width: var(--shell); margin-inline: auto; padding-inline: var(--gutter); }
.mono { font-family: var(--mono); font-size: .9em; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.narrow { max-width: 62ch; }
.ico { flex: none; }

/* ---------- type scale ---------- */
.display { font-size: clamp(2.5rem, 5.6vw, 4.4rem); font-weight: 400; line-height: 1.04; letter-spacing: -0.02em; font-variation-settings: "opsz" 72; }
.h1 { font-size: clamp(2rem, 3.8vw, 3rem); font-weight: 400; }
.h2 { font-size: clamp(1.55rem, 2.8vw, 2.15rem); font-weight: 400; }
.h3 { font-size: 1.35rem; }
.h4 { font-size: 1.12rem; }
.lede { font-family: var(--serif); font-size: clamp(1.15rem, 1.6vw, 1.32rem); line-height: 1.55; color: var(--ink-2); }
.kicker { font: 600 .75rem/1.3 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin: 0 0 .9rem; display: flex; align-items: center; gap: .5em; }
.kicker .ico { width: 16px; height: 16px; color: var(--rubric); }
.sect { color: var(--rubric); font-family: var(--serif); font-size: 1.15rem; letter-spacing: 0; line-height: 1; }
.rubric-h { font-family: var(--sans); font-size: .78rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--rubric); margin-bottom: 1rem; }
.meta { display: flex; flex-wrap: wrap; gap: .25rem .9rem; margin: 0 0 .5rem; font-size: .8125rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.meta__cat { color: var(--rubric); font-weight: 600; letter-spacing: .06em; text-transform: uppercase; font-size: .72rem; align-self: center; }
.flag { font: 600 .68rem/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; color: var(--lamp); border: 1px solid currentColor; border-radius: 4px; padding: 3px 6px; align-self: center; }
mark.ph { background: var(--lamp-soft); color: var(--lamp); font-family: var(--mono); font-size: .82em; padding: .05em .3em; border-radius: 3px; border: 1px dashed color-mix(in srgb, var(--lamp) 55%, transparent); }

/* ---------- buttons & links ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-height: 46px; padding: .7rem 1.2rem; border-radius: 999px; border: 1.5px solid var(--ink); font: 500 .95rem/1 var(--sans); text-decoration: none; cursor: pointer; transition: background .15s, color .15s, border-color .15s, transform .15s; white-space: nowrap; }
.btn .ico { width: 18px; height: 18px; }
.btn--ink { background: var(--ink); color: var(--paper); }
.btn--ink:hover { background: var(--rubric); border-color: var(--rubric); color: var(--paper); }
.btn--line { background: transparent; color: var(--ink); }
.btn--line:hover { background: var(--ink); color: var(--paper); }
.btn--ghost { border-style: dashed; border-color: var(--rule-2); color: var(--muted); cursor: default; }
.btn--sm { min-height: 38px; padding: .5rem .95rem; font-size: .875rem; }
.btn--wide { width: 100%; }
.btn[disabled] { opacity: .55; cursor: progress; }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.5rem; }
.textlink { display: inline-flex; align-items: center; gap: .4rem; font-weight: 500; font-size: .95rem; text-decoration: none; color: var(--ink); background: none; border: 0; padding: 0; cursor: pointer; }
.textlink .ico { width: 18px; height: 18px; color: var(--rubric); transition: transform .2s; }
.textlink:hover .ico { transform: translateX(3px); }
.linkbtn { background: none; border: 0; padding: 0; text-decoration: underline; text-underline-offset: .18em; cursor: pointer; color: inherit; font-size: inherit; }
.iconbtn { display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; border: 1px solid transparent; background: none; cursor: pointer; color: var(--ink); }
.iconbtn:hover { border-color: var(--rule-2); color: var(--rubric); }
.chip { border: 1px solid var(--rule-2); background: transparent; border-radius: 999px; padding: .42rem .9rem; font-size: .875rem; cursor: pointer; color: var(--ink-2); }
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip.is-on { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.pill { display: inline-flex; align-items: center; gap: .45em; font: 600 .7rem/1 var(--sans); letter-spacing: .1em; text-transform: uppercase; padding: .45em .75em; border-radius: 999px; background: var(--paper-2); color: var(--ink-2); width: fit-content; }
.pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.pill--now { background: var(--rubric-soft); color: var(--rubric); }
.pill--soon { background: var(--lamp-soft); color: var(--lamp); }
.badge { display: inline-block; font: 500 .66rem/1 var(--mono); letter-spacing: .08em; padding: .35em .5em; border-radius: 3px; border: 1px solid var(--rule-2); color: var(--ink-2); flex: none; }
.badge--book { border-color: var(--ink); color: var(--ink); }
.badge--article { border-color: var(--rubric); color: var(--rubric); }
.badge--podcast { border-color: var(--lamp); color: var(--lamp); }
.badge--project { background: var(--paper-2); }

/* ---------- masthead ---------- */
.masthead { position: sticky; top: 0; z-index: 40; background: color-mix(in srgb, var(--paper) 88%, transparent); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--rule); padding-top: env(safe-area-inset-top, 0px); }
.masthead__row { display: flex; align-items: center; gap: 1.25rem; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: .65rem; text-decoration: none; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand .nib { color: var(--ink); }
.brand__text { display: grid; line-height: 1.1; }
.brand__name { font: 500 1.12rem/1.1 var(--serif); letter-spacing: -.005em; }
.brand__mark { font: 500 .66rem/1.3 var(--sans); letter-spacing: .2em; text-transform: uppercase; color: var(--rubric); }
.brand--lg .brand__name { font-size: 1.4rem; }
.mainnav { margin-left: auto; }
.mainnav ul { display: flex; gap: .2rem; list-style: none; margin: 0; padding: 0; }
.mainnav a { display: block; padding: .5rem .7rem; border-radius: 6px; text-decoration: none; font-size: .94rem; color: var(--ink-2); position: relative; }
.mainnav a:hover { color: var(--ink); }
.mainnav a[aria-current="page"] { color: var(--ink); }
.mainnav a[aria-current="page"]::after { content: ""; position: absolute; left: .7rem; right: .7rem; bottom: .15rem; height: 2px; background: var(--rubric); border-radius: 2px; }
.mainnav__extra { display: none; }
.masthead__tools { display: flex; align-items: center; gap: .35rem; }
.askbtn { display: inline-flex; align-items: center; gap: .4rem; height: 40px; padding: 0 .95rem 0 .75rem; border-radius: 999px; border: 1px solid var(--ink); background: transparent; cursor: pointer; font-size: .9rem; font-weight: 500; }
.askbtn .ico { width: 17px; height: 17px; color: var(--rubric); }
.askbtn:hover { background: var(--ink); color: var(--paper); }
.menubtn { display: none; }
@media (max-width: 1020px) {
  .menubtn { display: inline-grid; }
  .mainnav { position: fixed; inset: calc(68px + env(safe-area-inset-top, 0px)) 0 auto 0; background: var(--paper); border-bottom: 1px solid var(--rule); padding: 1rem var(--gutter) 1.5rem; display: none; max-height: calc(100dvh - 68px); overflow: auto; box-shadow: var(--shadow); }
  .mainnav.is-open { display: block; }
  .mainnav ul { flex-direction: column; gap: 0; }
  .mainnav a { font: 400 1.5rem/1.2 var(--serif); padding: .65rem 0; border-bottom: 1px solid var(--rule); border-radius: 0; color: var(--ink); }
  .mainnav a[aria-current="page"]::after { left: auto; right: 0; top: 50%; bottom: auto; width: 8px; height: 8px; border-radius: 50%; transform: translateY(-50%); }
  .mainnav__extra { display: flex; flex-wrap: wrap; gap: .5rem 1.2rem; padding-top: 1rem; }
  .mainnav__extra a { font: 500 .95rem var(--sans); border: 0; padding: .3rem 0; color: var(--ink-2); }
  .masthead__tools { margin-left: auto; }
}
@media (max-width: 420px) { .brand__mark { display: none; } .askbtn span { display: none; } .askbtn { padding: 0; width: 40px; justify-content: center; } }

/* ---------- section scaffolding ---------- */
.band { padding-block: clamp(56px, 8vw, 96px); }
.band--tint { background: var(--paper-2); }
.band--slim { padding-block: clamp(32px, 5vw, 56px); border-top: 1px solid var(--rule); }
.sechead { display: flex; justify-content: space-between; align-items: end; gap: .75rem 2rem; flex-wrap: wrap; margin-bottom: 1.75rem; }
.sechead h2 { font-size: clamp(1.6rem, 3vw, 2.25rem); font-weight: 400; }
.sechead .kicker { margin-bottom: .55rem; }
.split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(32px, 6vw, 80px); }
.stack { display: grid; gap: 0; }
.pagehead { padding-block: clamp(48px, 8vw, 96px) clamp(28px, 4vw, 48px); }
.pagehead .lede { margin-top: 1.1rem; }
.crumbs { font-size: .85rem; color: var(--muted); padding-top: 1.75rem; display: flex; gap: .5rem; flex-wrap: wrap; }
.crumbs a { color: var(--muted); }
.notecard { background: var(--paper-2); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1.1rem 1.25rem; margin-block: 2rem; }
.notecard p { margin: 0 0 .75rem; } .notecard p:last-child { margin: 0; }
.banner { background: var(--lamp-soft); color: var(--lamp); border-left: 3px solid var(--lamp); padding: .7rem 1rem; border-radius: 4px; font-size: .92rem; font-weight: 500; }
.empty { color: var(--muted); padding: 2rem 0; }
.filters { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0 0 2rem; }
@media (max-width: 760px) { .split { grid-template-columns: minmax(0, 1fr); } }

/* ---------- hero & contents ---------- */
.hero { padding-block: clamp(48px, 9vw, 120px) clamp(48px, 7vw, 88px); position: relative; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; background: radial-gradient(60% 70% at 85% 10%, color-mix(in srgb, var(--lamp) 14%, transparent), transparent 70%); pointer-events: none; }
.hero__grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, .9fr); gap: clamp(32px, 6vw, 88px); align-items: end; position: relative; }
.hero .display { font-size: clamp(2.9rem, 7.4vw, 5.6rem); }
.hero .lede { margin-top: 1.4rem; max-width: 34em; }
.hero .kicker { color: var(--rubric); }
.contents { background: var(--card); border: 1px solid var(--rule); border-radius: 4px 12px 12px 4px; padding: 1.6rem 1.6rem 1.2rem; box-shadow: var(--shadow); position: relative; }
.contents::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px; border-radius: 4px 0 0 4px; background: linear-gradient(90deg, color-mix(in srgb, var(--ink) 18%, transparent), transparent); }
.contents__title { font: 500 .78rem var(--mono); letter-spacing: .2em; text-transform: uppercase; color: var(--rubric); text-align: center; margin-bottom: 1rem; }
.contents ol { list-style: none; margin: 0; padding: 0; counter-reset: c; }
.contents li a { display: flex; align-items: baseline; gap: .5rem; padding: .48rem 0; text-decoration: none; font-family: var(--serif); font-size: 1.12rem; }
.contents li a span::before { counter-increment: c; content: counter(c, upper-roman) ". "; font-family: var(--mono); font-size: .72rem; color: var(--muted); display: inline-block; width: 2.6rem; }
.contents li i { flex: 1; border-bottom: 1.5px dotted var(--rule-2); transform: translateY(-.3em); min-width: 1rem; }
.contents li b { font: 500 .9rem var(--mono); color: var(--ink-2); font-variant-numeric: tabular-nums; }
.contents li a:hover span { color: var(--rubric); }
.contents__foot { margin: 1rem 0 0; font-size: .8rem; color: var(--muted); font-style: italic; font-family: var(--serif); text-align: center; }
@media (max-width: 860px) { .hero__grid { grid-template-columns: minmax(0, 1fr); } }

/* ---------- covers ---------- */
.cover { position: relative; aspect-ratio: 2 / 3; border-radius: 2px 5px 5px 2px; overflow: hidden; box-shadow: 0 1px 1px rgba(0,0,0,.1), 0 6px 14px -2px rgba(22,32,44,.22), 0 22px 40px -12px rgba(22,32,44,.3); background: var(--paper-2); }
.cover::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0,0,0,.18) 0, rgba(255,255,255,.12) 1.2%, rgba(0,0,0,.05) 2.6%, transparent 6%); pointer-events: none; }
.cover img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.cover__typeset { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center; gap: .6rem; padding: 12% 11%; text-align: left; color: #F6F1E6; }
.cover__kicker { font: 600 .55rem/1.2 var(--sans); letter-spacing: .2em; opacity: .8; position: absolute; top: 9%; left: 11%; }
.cover__title { font: 400 clamp(1.1rem, 2.2vw, 1.7rem)/1.08 var(--serif); }
.cover__sub { font: italic 400 .8rem/1.3 var(--serif); opacity: .85; }
.cover__rule { position: absolute; left: 11%; right: 11%; bottom: 10%; height: 1px; background: currentColor; opacity: .5; }
.cover--ink { background: radial-gradient(120% 80% at 20% 0%, #2B3B52, #121A26); }
.cover--forest { background: radial-gradient(120% 80% at 20% 0%, #335E52, #142B25); }
.cover--plum { background: radial-gradient(120% 80% at 20% 0%, #5C3A5E, #24152A); }
.cover--rose { background: radial-gradient(120% 80% at 20% 0%, #9A3A4E, #4A1424); }
.cover--lg { width: min(340px, 100%); }
.cover--xl { width: min(380px, 100%); }
.cover--xl .cover__title { font-size: clamp(1.6rem, 3vw, 2.4rem); }

/* ---------- featured book ---------- */
.feature-book { padding-block: clamp(56px, 8vw, 100px); position: relative; overflow: hidden; }
.feature-book::before { content: ""; position: absolute; inset: 0; background: radial-gradient(50% 80% at 18% 50%, rgba(224,180,99,.16), transparent 70%); }
.feature-book__grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(32px, 7vw, 96px); align-items: center; position: relative; }
.feature-book__cover { justify-self: center; transform: rotate(-2deg); transition: transform .4s ease; }
.feature-book__cover:hover { transform: rotate(0); }
.feature-book .kicker, .feature-book .lede { color: color-mix(in srgb, var(--paper) 75%, transparent); }
.feature-book .sect { color: var(--lamp); }
.feature-book__sub { font: italic 400 1.25rem var(--serif); color: color-mix(in srgb, var(--paper) 70%, transparent); margin: .4rem 0 1rem; }
.feature-book .pull { border-color: var(--lamp); color: var(--paper); }
.feature-book .btn--ink { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.feature-book .btn--ink:hover { background: var(--lamp); border-color: var(--lamp); }
.feature-book .btn--line { color: var(--paper); border-color: color-mix(in srgb, var(--paper) 50%, transparent); }
.feature-book .btn--line:hover { background: var(--paper); color: var(--ink); }
.pull { margin: 1.5rem 0 0; padding-left: 1.1rem; border-left: 2px solid var(--rubric); font: italic 400 1.35rem/1.4 var(--serif); }
@media (max-width: 760px) { .feature-book__grid { grid-template-columns: minmax(0, 1fr); } .feature-book__cover .cover { width: 220px; } }

/* ---------- writing ---------- */
.writing-feature { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); }
.lead-article { padding-right: clamp(0px, 3vw, 40px); border-right: 1px solid var(--rule); }
.lead-article h3 { margin: .2rem 0 .6rem; }
.lead-article h3 a { text-decoration: none; }
.deck { font: italic 400 1.2rem/1.45 var(--serif); color: var(--ink-2); margin: .5rem 0 1rem; }
.lead-article__open { font: 400 1.1rem/1.7 var(--serif); color: var(--ink-2); }
.lead-article__open::first-letter { font-size: 3.1em; float: left; line-height: .85; padding: .05em .1em 0 0; color: var(--rubric); font-family: var(--serif); }
.row-article { padding: 1.25rem 0; border-top: 1px solid var(--rule); }
.stack > .row-article:first-child, .journal__list > .row-article:first-child { border-top: 0; padding-top: 0; }
.row-article h3 { font-size: 1.3rem; margin-bottom: .35rem; }
.row-article h3 a { text-decoration: none; }
.row-article__sum { color: var(--muted); margin: 0; font-size: .97rem; }
.journal__list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: clamp(28px, 5vw, 64px); }
.journal__list > .row-article:nth-child(2) { border-top: 0; padding-top: 0; }
@media (max-width: 860px) { .writing-feature, .journal__list { grid-template-columns: minmax(0, 1fr); } .lead-article { border-right: 0; padding-right: 0; } .journal__list > .row-article:nth-child(2) { border-top: 1px solid var(--rule); padding-top: 1.25rem; } }

/* ---------- podcast ---------- */
.ep { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 1rem; padding: 1.15rem 0; border-top: 1px solid var(--rule); }
.stack > .ep:first-child { border-top: 0; padding-top: 0; }
.ep__play, .player__btn { width: 46px; height: 46px; border-radius: 50%; border: 1.5px solid var(--ink); background: transparent; display: grid; place-items: center; cursor: pointer; color: var(--ink); transition: background .15s, color .15s; }
.ep__play:hover, .player__btn:hover, .ep__play.is-playing, .player__btn.is-playing { background: var(--ink); color: var(--paper); }
.ep__play .ico, .player__btn .ico { width: 18px; height: 18px; }
.ep h3 { font-size: 1.2rem; margin-bottom: .25rem; }
.ep h3 a { text-decoration: none; }
.ep__sum { color: var(--muted); margin: 0; font-size: .95rem; }
.showcard { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: clamp(24px, 4vw, 48px); align-items: center; padding-bottom: 2.5rem; margin-bottom: 1rem; border-bottom: 1px solid var(--rule); }
.showcard--page { padding-top: 2rem; }
.showcard__art img, .showart { width: 100%; aspect-ratio: 1; border-radius: 8px; }
.showart { background: var(--ink); color: var(--paper); display: flex; flex-direction: column; justify-content: flex-end; padding: 1.1rem; position: relative; overflow: hidden; }
.showart__wave { position: absolute; inset: 18% 12% auto; height: 40%; background: repeating-linear-gradient(90deg, var(--lamp) 0 3px, transparent 3px 9px); -webkit-mask: radial-gradient(60% 50% at 50% 50%, #000 40%, transparent 72%); mask: radial-gradient(60% 50% at 50% 50%, #000 40%, transparent 72%); opacity: .85; }
.showart__title { font: 400 1.7rem/1 var(--serif); position: relative; }
.showart__host { font: 500 .7rem var(--sans); letter-spacing: .14em; text-transform: uppercase; opacity: .75; position: relative; margin-top: .35rem; }
.platforms { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; }
@media (max-width: 640px) { .showcard { grid-template-columns: minmax(0, 1fr); } .showcard__art { max-width: 200px; } }
.episode__head { padding-block: 1.5rem 1.5rem; max-width: 52rem; }
.player { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; padding: 1rem 1.2rem; border: 1px solid var(--rule); border-radius: 999px; background: var(--card); margin-bottom: 2.5rem; max-width: 52rem; }
.player__info { display: grid; flex: 1; min-width: 0; }
.player__info b { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.player__info span { font-size: .85rem; color: var(--muted); }
.episode__grid, .project__grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: clamp(28px, 6vw, 80px); padding-bottom: 4rem; }
.episode__grid section, .book__main > section { margin-bottom: 2.5rem; }
.transcript summary { cursor: pointer; font-weight: 500; }
@media (max-width: 860px) { .episode__grid, .project__grid { grid-template-columns: minmax(0, 1fr); } .player { border-radius: 16px; } }

/* persistent audio bar */
.audiobar { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(16px + env(safe-area-inset-bottom, 0px)); width: min(680px, calc(100% - 24px)); z-index: 45; background: var(--ink); color: var(--paper); border-radius: 16px; padding: .7rem .8rem .7rem 1rem; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: .9rem; align-items: center; box-shadow: 0 18px 40px rgba(0,0,0,.3); }
.audiobar a { color: var(--paper); text-decoration: none; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
.audiobar .bar { height: 4px; background: color-mix(in srgb, var(--paper) 25%, transparent); border-radius: 2px; margin-top: .4rem; cursor: pointer; position: relative; }
.audiobar .bar i { position: absolute; inset: 0 auto 0 0; background: var(--lamp); border-radius: 2px; width: 0; }
.audiobar .time { font: 500 .75rem var(--mono); opacity: .75; }
.audiobar button { background: none; border: 0; color: var(--paper); cursor: pointer; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; }
.audiobar button:hover { background: rgba(255,255,255,.12); }
.audiobar .err { color: var(--lamp); font-size: .8rem; }

/* ---------- ministry, pillars, projects ---------- */
.pillars { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: var(--radius); overflow: hidden; margin-top: 2rem; }
.pillar { background: var(--paper); padding: 1.6rem 1.5rem 1.7rem; text-decoration: none; display: grid; gap: .55rem; align-content: start; transition: background .2s; }
.band--tint .pillar { background: var(--paper-2); }
.pillar:hover { background: var(--card); color: var(--ink); }
.pillar h2, .pillar h3 { font-size: 1.35rem; }
.pillar p { margin: 0; color: var(--muted); font-size: .97rem; }
.pillar__n { color: var(--rubric); font-size: .78rem; }
.pillar--sm { border: 1px solid var(--rule); border-radius: var(--radius); padding: 1rem 1.1rem; }
.pillars--six { margin-top: 0; }
@media (max-width: 900px) { .pillars { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .pillars { grid-template-columns: minmax(0, 1fr); } }
.principles { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: .8rem; }
.principles li { padding-left: 1.4rem; position: relative; }
.principles li::before { content: "¶"; position: absolute; left: 0; color: var(--rubric); font-family: var(--serif); }
.timeline { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--rule-2); }
.timeline li { display: grid; gap: .25rem; padding: 0 0 1.4rem 1.4rem; position: relative; }
.timeline li::before { content: ""; position: absolute; left: -5px; top: .45rem; width: 9px; height: 9px; border-radius: 50%; background: var(--paper-2); border: 2px solid var(--rubric); }
.timeline__y { font-size: .78rem; color: var(--muted); }
.timeline p { margin: .2rem 0 0; color: var(--ink-2); font-size: .97rem; }
.invite { display: flex; justify-content: space-between; align-items: center; gap: 1.5rem; flex-wrap: wrap; padding-block: 3rem 5rem; }
.projgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 1.25rem; }
.projcard { background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1.4rem 1.4rem 1.2rem; display: grid; gap: .4rem; align-content: start; }
.projcard h3 { font-size: 1.45rem; }
.projcard h3 a { text-decoration: none; }
.projcard__sum { color: var(--muted); font-size: .95rem; margin: 0 0 .6rem; }
.projgrid--compact .projcard { padding: 1.1rem; }
.projgrid--compact .projcard h3 { font-size: 1.2rem; }
.stages { display: grid; grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr)); margin-top: .5rem; }
.stage { display: grid; gap: .4rem; font-size: .72rem; color: var(--muted); }
.stage i { height: 4px; background: var(--rule); border-radius: 2px; margin-right: 3px; }
.stage.is-done i { background: var(--ink-2); }
.stage.is-now i { background: linear-gradient(90deg, var(--rubric) 55%, var(--rule) 55%); }
.stage.is-now b { color: var(--rubric); }
.stage b { font-weight: 500; }
.project header { padding-block: 1.5rem 2rem; }
.project .stages { margin-bottom: 1.5rem; max-width: 520px; }

/* ---------- books ---------- */
.bookgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); gap: 2.5rem 1.75rem; padding-bottom: 2rem; }
.bookcard { display: grid; gap: 1rem; align-content: start; }
.bookcard__link { display: block; transition: transform .25s ease; }
.bookcard__link:hover { transform: translateY(-4px); }
.bookcard h3 { font-size: 1.3rem; margin-top: .25rem; }
.bookcard h3 a { text-decoration: none; }
.bookcard__body { display: grid; gap: .3rem; }
.bookcard__sub { font: italic 400 1rem var(--serif); color: var(--ink-2); margin: 0; }
.bookcard__cats { font-size: .8rem; color: var(--muted); margin: 0; }
.book__head { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: clamp(32px, 6vw, 88px); padding-block: 2rem 3.5rem; align-items: start; }
.book__cover { position: sticky; top: 100px; width: 100%; display: flex; justify-content: center; }
.book__intro .display { margin-top: .9rem; }
.book__sub { font: italic 400 1.45rem/1.3 var(--serif); color: var(--ink-2); margin: .5rem 0 .2rem; }
.book__by { color: var(--muted); margin-bottom: 1.4rem; }
.formats { border-top: 1px solid var(--rule); margin-top: 1.6rem; }
.format { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .9rem 0; border-bottom: 1px solid var(--rule); flex-wrap: wrap; }
.format b { font-weight: 500; display: block; }
.format span { font-size: .82rem; color: var(--muted); }
.format__buy { display: flex; align-items: center; gap: 1rem; }
.price { font: 500 1rem var(--mono); font-variant-numeric: tabular-nums; color: var(--ink); }
.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 1rem 1.5rem; margin: 2rem 0 0; padding-top: 1.4rem; border-top: 1px solid var(--rule); }
.facts dt { font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: .2rem; }
.facts dd { margin: 0; font-size: .95rem; }
.facts--wide { grid-template-columns: minmax(0, 1fr); margin: 0 0 2rem; border-top: 0; padding-top: 0; }
.book__body { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 88px); padding-block: 3rem 4rem; border-top: 1px solid var(--rule); }
.authors-note { background: var(--card); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1.6rem 1.8rem; }
.signature { font: italic 400 1.15rem var(--serif); color: var(--ink-2); text-align: right; margin: 0; }
.sample__page { position: relative; background: var(--card); border: 1px solid var(--rule); border-radius: 3px; padding: clamp(1.5rem, 4vw, 3rem); max-height: 520px; overflow: hidden; box-shadow: var(--shadow); transition: max-height .5s ease; }
.sample__page.is-open { max-height: none; }
.sample__fade { position: absolute; left: 0; right: 0; bottom: 0; height: 160px; background: linear-gradient(transparent, var(--card)); pointer-events: none; }
.sample__page.is-open .sample__fade { display: none; }
.quotes { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.2rem; }
.quotes blockquote { margin: 0; font: italic 400 1.25rem/1.45 var(--serif); padding-left: 1rem; border-left: 2px solid var(--rubric); }
.toc { background: var(--paper-2); border-radius: var(--radius); padding: 1.4rem 1.5rem; margin-bottom: 2rem; }
.toc__h { font: 500 .78rem var(--mono); letter-spacing: .2em; text-transform: uppercase; color: var(--rubric); margin-bottom: .8rem; }
.toc ol { margin: 0; padding-left: 1.6rem; font-family: var(--serif); font-size: 1.04rem; }
.toc li { padding: .28rem 0; border-bottom: 1px dotted var(--rule-2); }
.toc li::marker { font: .75rem var(--mono); color: var(--muted); }
.notify { background: var(--lamp-soft); border-radius: var(--radius); padding: 1.1rem 1.2rem; margin-top: 1.6rem; }
.notify p { margin-bottom: .7rem; }
@media (max-width: 860px) { .book__head, .book__body { grid-template-columns: minmax(0, 1fr); } .book__cover { position: static; } .book__cover .cover { width: min(260px, 70vw); } }

/* ---------- article / prose ---------- */
.readbar { position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 50; pointer-events: none; }
.readbar i { display: block; height: 100%; width: 0; background: var(--rubric); }
.article__head { padding-bottom: 2rem; }
.article__head > * { max-width: 52rem; }
.article__title { margin: 1.25rem 0 .6rem; font-size: clamp(2.3rem, 5vw, 3.9rem); }
.byline { margin-top: 1.25rem; }
.article__grid { display: grid; grid-template-columns: minmax(0, 42rem) minmax(0, 1fr); gap: clamp(32px, 6vw, 96px); padding-bottom: 4rem; }
.article__aside .sticky { position: sticky; top: 96px; display: grid; gap: 2rem; }
.aside-letter { border-top: 2px solid var(--ink); padding-top: 1rem; }
.prose { font: 400 1.16rem/1.75 var(--serif); color: var(--ink); }
.prose--article, .prose--book { font-size: clamp(1.12rem, 1.25vw, 1.24rem); }
.prose > * { margin-block: 0; }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { font-size: 1.65rem; margin-top: 2em; font-weight: 500; }
.prose h3 { font-size: 1.3rem; margin-top: 1.6em; }
.prose a { color: var(--rubric); }
.prose blockquote { margin: 1.6em 0; padding: .2em 0 .2em 1.3em; border-left: 2px solid var(--rubric); color: var(--ink-2); font-size: .95em; }
.prose blockquote p { margin: 0; }
.prose cite { display: block; margin-top: .6em; font: normal 500 .78rem/1.3 var(--mono); letter-spacing: .02em; color: var(--muted); }
.prose cite a { color: inherit; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: .4em; }
.prose sup a, .footnote-ref { color: var(--rubric); text-decoration: none; font: 600 .7em var(--mono); padding: 0 .1em; }
.prose .footnote { margin-top: 3em; font-size: .9rem; font-family: var(--sans); color: var(--ink-2); }
.prose .footnote hr { border: 0; border-top: 1px solid var(--rule-2); width: 6rem; margin: 0 0 1rem; }
.prose .footnote ol { padding-left: 1.4em; }
.prose .footnote li::marker { font-family: var(--mono); color: var(--rubric); }
.footnote-backref { text-decoration: none; margin-left: .3em; }
.prose--letter { font-style: italic; }
.dropcap > p:first-of-type::first-letter { float: left; font-size: 4.1em; line-height: .82; padding: .06em .09em 0 0; color: var(--rubric); font-weight: 400; }
.summary-lead { font-size: 1.3rem; line-height: 1.6; color: var(--ink-2); }
.scripture-refs { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .6rem; margin-bottom: 1.5rem; font: 500 .82rem var(--mono); }
.scripture-refs span { color: var(--muted); letter-spacing: .1em; text-transform: uppercase; font-size: .7rem; }
.scripture-refs a { color: var(--rubric); border: 1px solid color-mix(in srgb, var(--rubric) 35%, transparent); padding: .25em .55em; border-radius: 4px; text-decoration: none; }
.refs { margin-top: 3rem; border-top: 1px solid var(--rule-2); padding-top: 1.2rem; font-size: .92rem; }
.refs h2 { font: 600 .75rem var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--rubric); margin-bottom: .8rem; }
.refs ol { padding-left: 1.4em; display: grid; gap: .4rem; }
.article__foot { margin-top: 3rem; display: grid; gap: 2rem; }
.authorbox { display: flex; gap: 1rem; align-items: flex-start; padding: 1.3rem; border: 1px solid var(--rule); border-radius: var(--radius); background: var(--card); }
.authorbox p { margin: 0 0 .5rem; }
.discussion { border-top: 1px solid var(--rule); padding-top: 1.5rem; }
.method { border: 1px solid var(--rule); border-radius: var(--radius); padding: 1.3rem 1.5rem; margin-bottom: 2rem; background: var(--card); }
.method ul { margin: 0; padding-left: 1.2rem; display: grid; gap: .4rem; }
.research-section .pagehead { background: linear-gradient(var(--paper-2), var(--paper)); }
@media (max-width: 960px) { .article__grid { grid-template-columns: minmax(0, 1fr); } .article__aside .sticky { position: static; } }

/* ---------- related / share ---------- */
.related { margin-bottom: 1.8rem; }
.related__h, .colophon__h { font: 600 .74rem var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: .75rem; }
.related__list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.related__list a { display: flex; align-items: baseline; gap: .7rem; padding: .7rem 0; border-bottom: 1px solid var(--rule); text-decoration: none; }
.related__list a span:last-child { font-family: var(--serif); font-size: 1.04rem; }
.share { display: flex; flex-wrap: wrap; gap: .4rem .9rem; align-items: center; font-size: .88rem; }
.share__label { font: 600 .72rem var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.share a, .share .linkbtn { color: var(--ink-2); }
.taglist { list-style: none; padding: 0; margin: 0 0 2rem; display: flex; flex-wrap: wrap; gap: .45rem; }
.taglist li { border: 1px solid var(--rule-2); border-radius: 999px; padding: .3rem .75rem; font-size: .88rem; }

/* ---------- about ---------- */
.about__head { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, .8fr); gap: clamp(32px, 6vw, 80px); align-items: center; }
.about__mark { font: 500 .8rem var(--sans); letter-spacing: .18em; text-transform: uppercase; color: var(--rubric); margin: .9rem 0 1.2rem; }
.portrait { margin: 0; }
.portrait img, .portrait__ph { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 4px; }
.portrait__ph { background: var(--paper-2); border: 1px dashed var(--rule-2); display: grid; place-content: center; justify-items: center; gap: 1rem; color: var(--rule-2); }
.about__grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 88px); padding-block: 1rem 4rem; }
.about__grid section { margin-bottom: 2.5rem; }
.published-bio .prose { font-size: 1.22rem; }
@media (max-width: 860px) { .about__head, .about__grid { grid-template-columns: minmax(0, 1fr); } .portrait { max-width: 320px; } }

/* ---------- forms ---------- */
.form { display: grid; gap: 1.2rem; }
.field { display: grid; gap: .4rem; min-width: 0; border: 0; padding: 0; margin: 0; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
label, legend { font-size: .9rem; font-weight: 500; color: var(--ink-2); padding: 0; }
.opt { font-weight: 400; color: var(--muted); font-size: .8rem; }
input:not([type="radio"]):not([type="checkbox"]), select, textarea { width: 100%; min-height: 48px; padding: .7rem .9rem; border: 1px solid var(--rule-2); border-radius: 8px; background: var(--card); color: var(--ink); }
textarea { resize: vertical; line-height: 1.5; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--rubric); outline-offset: 0; border-color: transparent; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { min-height: 1.4em; margin: 0; font-size: .92rem; }
.form-status.is-ok { color: var(--ink); } .form-status.is-err { color: var(--rubric); }
.subscribe { display: grid; gap: .5rem; width: 100%; max-width: 480px; position: relative; }
.subscribe__row { display: flex; gap: .5rem; }
.subscribe__row input { flex: 1; min-width: 0; border-radius: 999px !important; padding-inline: 1.1rem !important; }
.subscribe--compact .subscribe__row { flex-direction: column; }
.contact, .give { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 88px); padding-bottom: 5rem; }
.topic-extra { border: 1px solid var(--rule); border-radius: var(--radius); padding: 1rem; display: grid; gap: 1rem; }
.seg { display: inline-flex; border: 1px solid var(--rule-2); border-radius: 999px; padding: 4px; width: fit-content; gap: 4px; }
.seg label { cursor: pointer; padding: .5rem 1.2rem; border-radius: 999px; font-weight: 500; color: var(--ink-2); }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label:has(input:checked) { background: var(--ink); color: var(--paper); }
.seg label:has(input:focus-visible), .amount:has(input:focus-visible) { outline: 2px solid var(--rubric); outline-offset: 2px; }
.amounts { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: .6rem; }
.amount { position: relative; cursor: pointer; }
.amount input { position: absolute; opacity: 0; }
.amount span { display: grid; place-items: center; min-height: 56px; border: 1px solid var(--rule-2); border-radius: 8px; font: 500 1.1rem var(--mono); background: var(--card); }
.amount--custom span { font: 500 .95rem var(--sans); }
.amount:has(input:checked) span { border-color: var(--ink); background: var(--ink); color: var(--paper); }
@media (max-width: 760px) { .contact, .give { grid-template-columns: minmax(0, 1fr); } .field-row { grid-template-columns: minmax(0, 1fr); } }

/* ---------- newsletter band & page ---------- */
.letter-band { border-top: 1px solid var(--rule); background: var(--paper-2); padding-block: clamp(48px, 7vw, 80px); }
.letter-band__inner { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 2rem; align-items: center; }
.letter-band h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); font-weight: 400; font-style: italic; margin-bottom: .5rem; }
.letter-band .subscribe { justify-self: end; }
@media (max-width: 760px) { .letter-band__inner { grid-template-columns: minmax(0, 1fr); } .letter-band .subscribe { justify-self: stretch; } }
.letterhead__grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 80px); align-items: start; padding-bottom: 3rem; }
.letterhead .lede { margin: 1rem 0 1.8rem; }
.letter-sample { background: var(--card); border: 1px solid var(--rule); border-radius: 4px; padding: 1.6rem; box-shadow: var(--shadow); background-image: repeating-linear-gradient(transparent 0 31px, var(--rule) 31px 32px); background-position: 0 3.2rem; }
.letter-sample ul { list-style: none; padding: 0; margin: 1rem 0; font: 400 1.12rem/32px var(--serif); }
.letter-sample li::before { content: "— "; color: var(--rubric); }
@media (max-width: 760px) { .letterhead__grid { grid-template-columns: minmax(0, 1fr); } }

/* ---------- ask card & assistant ---------- */
.askcard { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 2rem; align-items: center; background: var(--card); border: 1px solid var(--rule); border-radius: 16px; padding: clamp(1.5rem, 4vw, 3rem); box-shadow: var(--shadow); }
.askcard__form { display: flex; gap: .5rem; }
.askcard__form input { flex: 1; min-width: 0; border-radius: 999px !important; }
@media (max-width: 760px) { .askcard { grid-template-columns: minmax(0, 1fr); } }
.support-strip { display: flex; justify-content: space-between; align-items: center; gap: 1.5rem; flex-wrap: wrap; }
.support-strip p { margin: 0; }

.assistant-dialog { border: 0; padding: 0; margin: 0 0 0 auto; width: min(460px, 100%); height: 100dvh; max-height: 100dvh; max-width: 100%; background: var(--paper); color: var(--ink); box-shadow: -20px 0 60px rgba(0,0,0,.25); }
.assistant-dialog::backdrop { background: rgba(14, 19, 26, .45); backdrop-filter: blur(2px); }
.assistant-dialog[open] { display: flex; }
@media (prefers-reduced-motion: no-preference) { .assistant-dialog[open] { animation: slidein .28s ease; } @keyframes slidein { from { transform: translateX(30px); opacity: 0; } } }
.assistant { display: grid; grid-template-rows: auto minmax(0, 1fr) auto auto; width: 100%; height: 100%; min-height: 0; }
.assistant__head { display: flex; justify-content: space-between; align-items: center; padding: calc(1rem + env(safe-area-inset-top, 0px)) 1.25rem 1rem; border-bottom: 1px solid var(--rule); }
.assistant__head h2 { font-size: 1.35rem; }
.assistant__head .kicker { margin: 0 0 .2rem; }
.assistant__log { overflow-y: auto; padding: 1.25rem; display: flex; flex-direction: column; gap: 1rem; min-height: 0; }
.msg { max-width: 92%; padding: .85rem 1rem; border-radius: 14px; font-size: .97rem; line-height: 1.55; overflow-wrap: anywhere; }
.msg p { margin: 0 0 .6em; } .msg p:last-child { margin: 0; }
.msg--bot { background: var(--card); border: 1px solid var(--rule); border-bottom-left-radius: 4px; align-self: flex-start; }
.msg--me { background: var(--ink); color: var(--paper); border-bottom-right-radius: 4px; align-self: flex-end; white-space: pre-wrap; }
.msg__note { font-size: .84rem; color: var(--muted); }
.msg a { color: var(--rubric); }
.msg .sources { margin-top: .7rem; padding-top: .6rem; border-top: 1px dashed var(--rule-2); display: grid; gap: .35rem; font-size: .84rem; }
.msg .sources a { display: flex; gap: .5rem; align-items: baseline; text-decoration: none; color: var(--ink); }
.msg .sources a:hover span:last-child { text-decoration: underline; }
.src { display: inline-block; font: 600 .62rem/1 var(--sans); letter-spacing: .08em; text-transform: uppercase; padding: .35em .5em; border-radius: 3px; white-space: nowrap; }
.src--author { background: var(--rubric-soft); color: var(--rubric); }
.src--site { background: var(--paper-2); color: var(--ink-2); border: 1px solid var(--rule-2); }
.src--general { background: var(--lamp-soft); color: var(--lamp); }
.src--unknown { border: 1px dashed var(--rule-2); color: var(--muted); }
.typing { display: inline-flex; gap: 4px; } .typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--muted); }
@media (prefers-reduced-motion: no-preference) { .typing i { animation: blink 1.2s infinite; } .typing i:nth-child(2) { animation-delay: .2s; } .typing i:nth-child(3) { animation-delay: .4s; } @keyframes blink { 50% { opacity: .2; } } }
.chips { display: flex; flex-wrap: wrap; gap: .45rem; }
.chips button { border: 1px solid var(--rule-2); background: transparent; color: var(--ink-2); border-radius: 999px; padding: .45rem .8rem; font-size: .84rem; cursor: pointer; text-align: left; }
.chips button:hover { border-color: var(--rubric); color: var(--rubric); }
.assistant__form { display: flex; gap: .5rem; align-items: flex-end; padding: .9rem 1.25rem; border-top: 1px solid var(--rule); }
.assistant__form textarea { flex: 1; min-height: 48px; max-height: 140px; resize: none; border-radius: 14px; }
.assistant__form .btn { min-width: 48px; padding: 0; width: 48px; height: 48px; border-radius: 50%; }
.assistant__disclaimer { font-size: .74rem; color: var(--muted); padding: 0 1.25rem calc(1rem + env(safe-area-inset-bottom, 0px)); margin: 0; line-height: 1.45; }
.askpage { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); padding-bottom: 5rem; }
.assistant--page { border: 1px solid var(--rule); border-radius: 16px; background: var(--paper); height: min(680px, 80dvh); box-shadow: var(--shadow); grid-template-rows: minmax(0, 1fr) auto auto; overflow: hidden; }
.legend { display: grid; gap: 1rem; margin: 0 0 1.5rem; }
.legend dd { margin: .35rem 0 0; color: var(--ink-2); font-size: .94rem; }
@media (max-width: 860px) { .askpage { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 560px) { .assistant-dialog { width: 100%; } }

/* ---------- search ---------- */
.searchbox { display: flex; gap: .5rem; margin: 1.6rem 0 1.2rem; max-width: 720px; }
.searchbox input { flex: 1; min-width: 0; font-size: 1.15rem !important; min-height: 56px !important; border-radius: 999px !important; padding-inline: 1.3rem !important; }
.searchbox .btn { width: 56px; height: 56px; padding: 0; }
.search__count { color: var(--muted); font-size: .92rem; }
.results { list-style: none; margin: 0 0 5rem; padding: 0; max-width: 820px; }
.results li { border-top: 1px solid var(--rule); padding: 1.1rem 0; }
.results h2 { font-size: 1.3rem; margin: .35rem 0; }
.results h2 a { text-decoration: none; }
.results p { margin: 0; color: var(--muted); font-size: .95rem; }
.results mark { background: var(--lamp-soft); color: inherit; border-radius: 2px; padding: 0 .1em; }

/* ---------- media ---------- */
.mediagrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 1.25rem; padding-bottom: 4rem; }
.mediacard { border: 1px solid var(--rule); border-radius: var(--radius); background: var(--card); padding: 1.2rem; display: grid; gap: .4rem; align-content: start; }
.mediacard h2 a { text-decoration: none; }
.mediacard p { margin: 0; }
.mediacard .textlink { margin-top: .4rem; }
.mediacard.is-placeholder { border-style: dashed; background: transparent; }

/* ---------- footer ---------- */
.colophon { padding-block: 3.5rem calc(2rem + env(safe-area-inset-bottom, 0px)); --rule: rgba(255,255,255,.14); }
.colophon a { color: var(--paper); text-decoration: none; }
.colophon a:hover { color: var(--lamp); }
.colophon .brand { color: var(--paper); }
.colophon .brand__mark { color: var(--lamp); letter-spacing: .08em; text-transform: none; font: italic 400 1rem var(--serif); }
.colophon__top { display: flex; justify-content: space-between; align-items: center; gap: 1.5rem; flex-wrap: wrap; padding-bottom: 2.5rem; border-bottom: 1px solid var(--rule); }
.social { display: flex; flex-wrap: wrap; gap: .5rem 1.2rem; list-style: none; margin: 0; padding: 0; font-size: .92rem; }
.colophon__cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 2rem; padding-block: 2.5rem; }
.colophon__h { color: rgba(255,255,255,.55); }
.colophon__cols ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.colophon__base { border-top: 1px solid var(--rule); padding-top: 1.5rem; display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; font-size: .82rem; color: rgba(255,255,255,.6); }
.colophon__base p { margin: 0; }
.colophon .linkbtn { color: rgba(255,255,255,.8); }
@media (max-width: 760px) { .colophon__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* inverted panels keep a fixed light-on-ink scheme in both themes */
.feature-book, .colophon { --paper: #FBFAF7; --ink: #16202C; --lamp: #E0B463; background: #16202C; color: #FBFAF7; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .feature-book, :root:not([data-theme="light"]) .colophon { background: #080B10; --ink: #080B10; } }
:root[data-theme="dark"] .feature-book, :root[data-theme="dark"] .colophon { background: #080B10; --ink: #080B10; }
.colophon .brand .nib { color: #FBFAF7; --paper: #16202C; }

/* motion: a quiet fade for sections already visible at rest */
@media (prefers-reduced-motion: no-preference) {
  .reveal { animation: rise .6s ease both; }
  @keyframes rise { from { opacity: .001; transform: translateY(8px); } }
}
@media print { .masthead, .colophon, .letter-band, .assistant-dialog, .audiobar, .share { display: none !important; } body { background: #fff; color: #000; } }
.give__aside .stack { gap: .75rem; }
main > section.shell { padding-bottom: clamp(32px, 5vw, 64px); }

/* author introduction & CC */
.author-intro__grid { display: grid; grid-template-columns: minmax(0, .7fr) minmax(0, 1.3fr); gap: clamp(32px, 6vw, 88px); align-items: center; }
.author-intro__photo { margin: 0; }
.author-intro__photo img, .portrait img { border-radius: 4px; box-shadow: var(--shadow); }
.author-intro .h1 { margin-bottom: .6rem; }
.cc-note { display: flex; align-items: baseline; gap: .6rem; margin: 0 0 1.2rem; font-size: .92rem; color: var(--ink-2); }
.cc-note abbr { text-decoration: none; font: 600 .78rem var(--mono); letter-spacing: .12em; color: var(--rubric); border: 1px solid currentColor; border-radius: 3px; padding: .2em .45em; }
.portrait figcaption { margin-top: .5rem; text-align: right; }
.dedication { font: italic 400 1.2rem/1.55 var(--serif); color: var(--ink-2); max-width: 40ch; }
@media (max-width: 760px) { .author-intro__grid { grid-template-columns: minmax(0, 1fr); } .author-intro__photo { max-width: 300px; } }
