/* ============================================================
   site.css — Krerk Piromsopa, Ph.D.
   Dark editorial theme · numbered sections · light toggle
   Applies to: index, bio, cv, publication, patents, poem.
   ============================================================ */

@import url("https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,600;9..144,700&family=Inter+Tight:wght@400;500;600&family=Noto+Serif+Thai:wght@400;600&family=IBM+Plex+Sans+Thai:wght@400;600&family=JetBrains+Mono:wght@400;500&display=swap");

/* ── Theme tokens ─────────────────────────────────────────── */
:root {
  /* Dark (default) */
  --bg:        #0e0e10;
  --surface:   #19181d;
  --ink:       #e8e6e0;
  --ink-soft:  #c5c2b8;
  --muted:     #8a8780;
  --rule:      #2a2a2e;
  --accent:    #f0a93d;
  --accent-hi: #ffc56b;
  --portrait-bg: #19181d;

  --measure:   700px;
  --pad-x:     2rem;
  --pad-x-sm:  1.25rem;

  --serif-lat: "Fraunces", "Source Serif 4", Georgia, serif;
  --serif-tha: "Noto Serif Thai", "Fraunces", serif;
  --sans-lat:  "Inter Tight", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --sans-tha:  "IBM Plex Sans Thai", "Inter Tight", sans-serif;
  --mono:      "JetBrains Mono", ui-monospace, "SF Mono", Consolas, monospace;

  color-scheme: dark;
}

[data-theme="light"] {
  --bg:        #faf7f2;
  --surface:   #fffdf8;
  --ink:       #1a1814;
  --ink-soft:  #4a4640;
  --muted:     #8a857c;
  --rule:      #e6dfd2;
  --accent:    #a8540e;
  --accent-hi: #c4623f;
  --portrait-bg: #efeae0;
  color-scheme: light;
}

/* ── Reset & base ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  background: var(--bg);
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans-lat);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: "ss01", "cv11";
  transition: background-color .25s ease, color .25s ease;
}

img { max-width: 100%; height: auto; display: block; }

a {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color .15s ease, border-color .15s ease;
}
a:hover, a:focus { color: var(--accent-hi); border-bottom-color: currentColor; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }

::selection { background: var(--accent); color: var(--bg); }

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

/* ── Layout shell ─────────────────────────────────────────── */
.page {
  max-width: calc(var(--measure) + var(--pad-x) * 2);
  margin: 0 auto;
  padding: 4rem var(--pad-x) 6rem;
  position: relative;
}
@media (max-width: 720px) {
  .page { padding: 2.5rem var(--pad-x-sm) 4rem; }
  body { font-size: 16px; }
}

/* ── Theme toggle ─────────────────────────────────────────── */
.theme-toggle {
  position: absolute;
  top: 1.75rem;
  right: var(--pad-x);
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: .35rem .85rem;
  cursor: pointer;
  transition: color .2s, border-color .2s, background-color .2s;
}
.theme-toggle:hover {
  color: var(--ink);
  border-color: var(--ink-soft);
}
.theme-toggle::before {
  content: "◐";
  margin-right: .5em;
  color: var(--accent);
  font-size: 1.1em;
  line-height: 1;
}
@media (max-width: 720px) {
  .theme-toggle { top: 1rem; right: var(--pad-x-sm); }
}

/* ── Bilingual hooks ──────────────────────────────────────── */
.tha {
  font-family: var(--serif-tha);
  word-break: keep-all;
  line-break: loose;
}
.tha-sans {
  font-family: var(--sans-tha);
  word-break: keep-all;
  line-break: loose;
}
.lat { font-family: var(--serif-lat); }
.lat-sans { font-family: var(--sans-lat); }
.sep { color: var(--muted); margin: 0 .55em; font-weight: 400; }

/* ── Top navigation backlink ──────────────────────────────── */
.topnav {
  font-family: var(--mono);
  font-size: .78rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 3rem;
}
.topnav a { color: var(--muted); }
.topnav a:hover { color: var(--accent); }
.topnav .tha-sans { letter-spacing: 0; text-transform: none; }

/* ── Hero / page head ─────────────────────────────────────── */
.hero, .page-head { margin-bottom: 4rem; }

/* Big editorial mark above the name */
.eyebrow {
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1.5rem;
  display: flex;
  align-items: center;
  gap: .85rem;
}
.eyebrow::before {
  content: "";
  width: 1.6rem;
  height: 1px;
  background: var(--accent);
}

.hero h1, .page-head h1 {
  font-family: var(--serif-lat);
  font-weight: 600;
  font-size: clamp(2.2rem, 5.5vw, 3.6rem);
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin: 0 0 .35em;
  color: var(--ink);
  font-variation-settings: "opsz" 64, "SOFT" 50;
}
.hero h1 .tha, .page-head h1 .tha {
  display: block;
  font-weight: 600;
  font-size: .56em;
  letter-spacing: 0;
  margin-bottom: .3em;
  color: var(--ink-soft);
  font-family: var(--serif-tha);
}
.hero h1 .lat, .page-head h1 .lat {
  display: block;
  color: var(--ink);
  font-style: italic;
  font-variation-settings: "opsz" 144, "SOFT" 0;
}

.role {
  font-family: var(--sans-lat);
  font-size: 1rem;
  color: var(--ink-soft);
  line-height: 1.55;
  margin: 1.25rem 0 0;
  max-width: 32em;
}
.role .tha-sans { display: block; color: var(--muted); }
.role .lat-sans { display: block; color: var(--ink-soft); }

.contact {
  font-family: var(--mono);
  font-size: .82rem;
  letter-spacing: .04em;
  color: var(--muted);
  margin-top: 1.75rem;
}
.contact a { color: var(--ink-soft); }
.contact a:hover { color: var(--accent); }

/* ── Research interests strip (in hero) ──────────────────── */
.interests {
  list-style: none;
  padding: 0;
  margin: 2.25rem 0 0;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: .5rem 1.1rem;
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-soft);
  line-height: 1.6;
}
.interests::before {
  content: "Research";
  display: inline-flex;
  align-items: center;
  gap: .65rem;
  color: var(--accent);
  letter-spacing: .2em;
  font-weight: 500;
}
.interests::before {
  content: "Research —";
}
.interests li { position: relative; }
.interests li + li::before {
  content: "";
  position: absolute;
  left: -.65rem;
  top: .55em;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--rule);
}

.portrait {
  width: 96px;
  height: 96px;
  border-radius: 4px;
  object-fit: cover;
  margin: 0 0 2.5rem;
  background: var(--portrait-bg);
  filter: saturate(.95);
}

/* ── Featured callout (ClassDeeDee) ───────────────────────── */
.featured {
  display: block;
  padding: 1.75rem 2rem 1.85rem;
  margin: 0 0 4.5rem;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-left: 3px solid var(--accent);
  border-radius: 4px;
  text-decoration: none;
  position: relative;
  transition: border-color .25s ease, transform .25s ease, background .25s ease;
}
.featured:hover {
  border-color: var(--accent);
  background: var(--bg);
  transform: translateY(-2px);
  border-bottom-color: var(--accent);
}
.featured:hover { border-left-color: var(--accent-hi); }
.featured-logo {
  display: block;
  height: 40px;
  width: auto;
  margin-bottom: 1.1rem;
}
.featured-eyebrow {
  display: flex;
  align-items: center;
  gap: .85rem;
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: .9rem;
}
.featured-eyebrow .tha-sans {
  font-family: var(--sans-tha);
  letter-spacing: 0;
  text-transform: none;
  font-size: .9rem;
  color: var(--muted);
}
.featured-eyebrow .sep { color: var(--muted); margin: 0; }
.featured-title {
  display: block;
  font-family: var(--serif-lat);
  font-style: italic;
  font-weight: 600;
  font-size: clamp(1.85rem, 4vw, 2.4rem);
  color: var(--ink);
  line-height: 1.05;
  letter-spacing: -0.015em;
  font-variation-settings: "opsz" 64;
  margin-bottom: .65rem;
}
.featured-desc {
  display: block;
  font-family: var(--sans-lat);
  font-size: 1rem;
  color: var(--ink-soft);
  line-height: 1.55;
  margin-bottom: 1.1rem;
}
.featured-desc .tha-sans {
  display: block;
  font-size: .92em;
  color: var(--muted);
  margin-top: .25em;
}
.featured-url {
  display: inline-flex;
  align-items: center;
  gap: .55em;
  font-family: var(--mono);
  font-size: .78rem;
  letter-spacing: .04em;
  color: var(--muted);
  transition: color .2s ease, gap .2s ease;
}
.featured-url::after {
  content: "→";
  color: var(--accent);
  transition: transform .2s ease;
}
.featured:hover .featured-url { color: var(--ink-soft); gap: .85em; }
.featured:hover .featured-url::after { color: var(--accent-hi); }

@media (max-width: 720px) {
  .featured { padding: 1.5rem 1.5rem 1.65rem; margin-bottom: 3.5rem; }
}

/* ── Book list (numbered, optional cover, access links) ──── */
.book-list {
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: book;
}
.book-list > li {
  counter-increment: book;
  display: grid;
  grid-template-columns: 2.6rem auto 1fr;
  column-gap: 1.25rem;
  align-items: start;
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--rule);
}
.book-list > li:first-child { border-top: 1px solid var(--rule); }
.book-list > li::before {
  content: counter(book, decimal-leading-zero);
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--muted);
  letter-spacing: .08em;
  padding-top: .35em;
}
/* When a row has no cover, let content fill the cover column too */
.book-list > li.no-cover { grid-template-columns: 2.6rem 1fr; }

.book-cover {
  display: block;
  width: 76px;
  flex-shrink: 0;
  border: 1px solid var(--rule);
  border-radius: 3px;
  overflow: hidden;
  line-height: 0;
  transition: border-color .2s ease, transform .2s ease;
}
.book-cover img { width: 100%; height: auto; display: block; }
.book-cover:hover { border-color: var(--accent); transform: translateY(-2px); border-bottom-color: var(--accent); }

.book-content { min-width: 0; }
.book-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: .35rem .9rem;
  margin-bottom: .55rem;
}
.book-title {
  font-family: var(--serif-lat);
  font-style: italic;
  font-weight: 600;
  font-size: 1.3rem;
  color: var(--ink);
  letter-spacing: -0.01em;
  font-variation-settings: "opsz" 48;
  line-height: 1.15;
}
a.book-title { border-bottom-color: transparent; }
a.book-title:hover { color: var(--accent); border-bottom-color: transparent; }
.book-edition {
  font-family: var(--mono);
  font-size: .7rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
}
.book-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .55rem .9rem;
  font-family: var(--mono);
  font-size: .74rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.book-links a {
  color: var(--ink-soft);
  border-bottom: 1px solid transparent;
}
.book-links a:hover { color: var(--accent); border-bottom-color: var(--accent); }
.book-links .dot { color: var(--rule); }

/* "Coming soon / in publication" badge */
.book-badge {
  display: inline-flex;
  align-items: center;
  gap: .5em;
  font-family: var(--mono);
  font-size: .68rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--accent);
  padding: .18em .7em;
  border: 1px solid var(--rule);
  border-radius: 999px;
}
.book-badge::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
}

@media (max-width: 540px) {
  .book-cover { width: 60px; }
  .book-list > li { column-gap: .9rem; }
}

/* ── Numbered sections ────────────────────────────────────── */
.page { counter-reset: section; }

.section {
  margin-top: 4.5rem;
  padding-top: 0;
  counter-increment: section;
}
.section:first-of-type { margin-top: 0; }

.section > h2 {
  font-family: var(--mono);
  font-weight: 500;
  font-size: .82rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 0 0 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.section > h2::before {
  content: counter(section, decimal-leading-zero);
  color: var(--accent);
  font-weight: 600;
  letter-spacing: .1em;
}
.section > h2::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--rule);
  margin-left: .4rem;
}
.section > h2 .tha-sans,
.section > h2 .lat-sans { display: inline; letter-spacing: .15em; }
.section > h2 .lat-sans { color: var(--muted); }
.section > h2 .sep { display: none; }

/* h3 — subgroup headings used inside long pages */
.section h3 {
  font-family: var(--mono);
  font-weight: 500;
  font-size: .78rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 3rem 0 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule);
}
.section h3 .tha-sans { display: inline; letter-spacing: .12em; }
.section h3 small {
  display: inline;
  margin-left: .65em;
  font-size: 1em;
  font-weight: 400;
  color: var(--muted);
}

.section p { margin: 0 0 1.4rem; font-size: 1.02rem; line-height: 1.7; color: var(--ink-soft); }
.section p:last-child { margin-bottom: 0; }
.section strong { color: var(--ink); font-weight: 600; }
.section em { color: var(--ink-soft); }

/* ── Numbered link list ───────────────────────────────────── */
.linklist {
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: link;
}
.linklist li {
  counter-increment: link;
  display: grid;
  grid-template-columns: 2.6rem 1fr auto;
  align-items: baseline;
  column-gap: 1rem;
  padding: .9rem 0;
  border-bottom: 1px solid var(--rule);
  font-family: var(--sans-lat);
  font-size: 1rem;
  transition: padding-left .2s ease;
}
.linklist li:first-child { border-top: 1px solid var(--rule); }
.linklist li::before {
  content: counter(link, decimal-leading-zero);
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--muted);
  letter-spacing: .08em;
}
.linklist li a {
  color: var(--ink);
  font-weight: 500;
}
.linklist li a:hover { color: var(--accent); border-bottom-color: transparent; }
.linklist li:hover { padding-left: .35rem; }
.linklist li:hover::before { color: var(--accent); }
.linklist .meta {
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .04em;
  color: var(--muted);
  text-transform: lowercase;
}
.linklist .meta:lang(th) { font-family: var(--sans-tha); text-transform: none; letter-spacing: 0; font-size: .8rem; }

/* Affiliations inline list */
.inline-list {
  font-family: var(--sans-lat);
  font-size: .95rem;
  color: var(--ink-soft);
  line-height: 1.85;
}
.inline-list a { color: var(--ink-soft); }
.inline-list a:hover { color: var(--accent); }
.inline-list .sep { color: var(--muted); }

/* ── CV: date-grid rows ───────────────────────────────────── */
.cv-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.cv-list > li {
  display: grid;
  grid-template-columns: 9rem 1fr;
  column-gap: 1.5rem;
  padding: .9rem 0;
  border-bottom: 1px solid var(--rule);
  font-family: var(--sans-lat);
  font-size: .96rem;
  line-height: 1.6;
}
.cv-list > li:last-child { border-bottom: 0; }
.cv-list .when {
  font-family: var(--mono);
  font-size: .78rem;
  color: var(--accent);
  letter-spacing: .04em;
  padding-top: .25em;
  text-transform: uppercase;
}
.cv-list .what { color: var(--ink); }
.cv-list .what em { font-style: italic; color: var(--ink-soft); }
.cv-list .what .place { color: var(--muted); display: inline; font-size: .92em; }
.cv-list .what .note { color: var(--muted); font-size: .85em; font-style: italic; }

@media (max-width: 540px) {
  .cv-list > li { grid-template-columns: 1fr; row-gap: .15rem; }
  .cv-list .when { padding-top: 0; }
}

/* Inline label list */
.fact-list {
  font-family: var(--sans-lat);
  font-size: .96rem;
  margin: 0;
}
.fact-list dt {
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: .35em;
}
.fact-list dd {
  margin: 0 0 1.5rem;
  color: var(--ink-soft);
  line-height: 1.6;
}
.fact-list dd:last-child { margin-bottom: 0; }

/* ── Publications ─────────────────────────────────────────── */
.pub-list {
  list-style: none;
  padding-left: 0;
  margin: 0;
  counter-reset: pub;
}
.pub-list > li {
  position: relative;
  padding: .9rem 0 .9rem 3.2rem;
  border-bottom: 1px solid var(--rule);
  font-family: var(--sans-lat);
  font-size: .96rem;
  line-height: 1.6;
  color: var(--ink-soft);
  counter-increment: pub;
}
.pub-list > li:first-child { border-top: 1px solid var(--rule); }
.pub-list > li::before {
  content: counter(pub, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 1.1rem;
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--muted);
  letter-spacing: .08em;
}
.pub-list em { color: var(--ink); font-style: italic; }
.pub-list code, .pub-list .mono {
  font-family: var(--mono);
  font-size: .82em;
  color: var(--accent);
  background: var(--surface);
  padding: .1em .4em;
  border-radius: 3px;
  letter-spacing: .02em;
}
.subgroup {
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 3rem 0 1rem;
}
.subgroup::before { content: "↓ "; color: var(--accent); }

/* ── Patents ──────────────────────────────────────────────── */
.patent {
  padding: 2rem 0 2.25rem;
  border-bottom: 1px solid var(--rule);
}
.patent:last-of-type { border-bottom: 0; }
.patent h3 {
  font-family: var(--serif-lat);
  font-weight: 600;
  font-size: 1.6rem;
  margin: 0 0 .65em;
  color: var(--ink);
  border-top: 0;
  padding-top: 0;
  text-transform: none;
  letter-spacing: -0.01em;
  font-variation-settings: "opsz" 64;
}
.patent .filing {
  font-family: var(--mono);
  font-size: .76rem;
  letter-spacing: .04em;
  color: var(--muted);
  margin: 0 0 1.5rem;
  text-transform: uppercase;
}
.patent p { margin: 0 0 1.25rem; }

/* ── Biography prose ──────────────────────────────────────── */
.prose p {
  margin: 0 0 1.5rem;
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--ink-soft);
}
.prose .signature {
  font-family: var(--mono);
  font-size: .78rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: right;
  margin-top: 3rem;
}

/* ── Poem-page typography ─────────────────────────────────── */
.poem {
  text-align: center;
  margin: 5rem 0;
  padding-top: 3rem;
  border-top: 1px solid var(--rule);
}
.poem:first-of-type { border-top: 0; padding-top: 0; margin-top: 2rem; }
.poem h2 {
  font-family: var(--serif-lat);
  font-weight: 600;
  font-size: 1.85rem;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 0 0 1.75rem;
  font-style: italic;
  font-variation-settings: "opsz" 144;
  text-transform: none;
}
.poem h2.tha {
  font-family: var(--serif-tha);
  font-style: normal;
}
.poem h2::after { display: none; }
.poem .verse {
  font-family: var(--serif-lat);
  font-size: 1.05rem;
  line-height: 1.95;
  color: var(--ink);
  margin: 0 auto 1.5rem;
  max-width: 36em;
  font-variation-settings: "opsz" 14;
}
.poem .verse.tha {
  font-family: var(--serif-tha);
  line-height: 2.1;
}
.poem .credit {
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 1rem 0 0;
}
.poem .credit em {
  font-family: var(--sans-lat);
  font-style: italic;
  letter-spacing: 0;
  text-transform: none;
  font-size: 1.05em;
  color: var(--ink-soft);
}

.poem-intro {
  font-family: var(--serif-lat);
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--ink-soft);
  max-width: 38em;
  margin: 0 auto 2.5rem;
  text-align: center;
  font-style: italic;
  font-variation-settings: "opsz" 14;
}
.audio-note {
  font-family: var(--mono);
  font-size: .76rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
  margin: 3rem 0;
}
.audio-note a { color: var(--ink-soft); }

/* ── "More from this site" strip (inner pages) ───────────── */
.related {
  margin-top: 5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--rule);
  font-family: var(--mono);
  font-size: .76rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .65rem 1.4rem;
  line-height: 1.5;
}
.related-label {
  color: var(--accent);
  letter-spacing: .2em;
  font-weight: 500;
}
.related-label::after {
  content: "—";
  margin-left: .55rem;
  color: var(--rule);
}
.related a {
  color: var(--ink-soft);
  border-bottom: 1px solid transparent;
  transition: color .15s ease, border-color .15s ease;
}
.related a:hover { color: var(--accent); border-bottom-color: var(--accent); }
@media (max-width: 540px) {
  .related { font-size: .7rem; gap: .5rem 1rem; }
}

/* ── Footer ───────────────────────────────────────────────── */
.site-footer {
  margin-top: 6rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--rule);
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: left;
  line-height: 1.75;
}
.site-footer a { color: var(--ink-soft); }
.site-footer a:hover { color: var(--accent); }
.site-footer .quote {
  font-family: var(--serif-lat);
  font-style: italic;
  color: var(--ink-soft);
  font-size: 1.05rem;
  letter-spacing: 0;
  text-transform: none;
  max-width: 32em;
  margin: 0 0 2.5rem;
  line-height: 1.65;
  font-variation-settings: "opsz" 36;
}
.site-footer .quote::before {
  content: "";
  display: block;
  width: 2rem;
  height: 1px;
  background: var(--accent);
  margin-bottom: 1.25rem;
}

/* ── Print stylesheet ─────────────────────────────────────── */
@media print {
  :root, [data-theme="light"] {
    --bg: #fff;
    --surface: #fff;
    --ink: #000;
    --ink-soft: #222;
    --muted: #555;
    --accent: #000;
    --accent-hi: #000;
    --rule: #999;
  }
  body { background: #fff; color: #000; font-size: 11pt; }
  .topnav, .site-footer, .audio-note, .theme-toggle { display: none; }
  .page { max-width: none; padding: .75in; }
  a { color: #000; border-bottom: 0; }
  .pub-list > li, .cv-list > li, .section { page-break-inside: avoid; }
  .portrait { display: none; }
  .hero, .page-head { text-align: left; margin-bottom: 2rem; }
  .pub-list code, .pub-list .mono { background: transparent; padding: 0; color: #000; }
}
