/* ============================================================
   Booking a Burt — styles
   Aesthetic: deadpan corporate meets letterpress resume.
   Fourth in the family after becomingabibby.com, puente.party
   and serrato.date; re-skinned pine + brass.
   Tweak the variables below to re-skin the whole site.
   ============================================================ */

:root {
  --ink:        #1e241f;   /* near-black, faintly green */
  --ink-soft:   #4d5750;
  --ink-faint:  #737d76;
  --paper:      #faf9f4;   /* cool cream */
  --paper-2:    #eef0e7;
  --card:       #ffffff;
  --line:       #dfe2d6;
  --accent:     #2c6b47;   /* pine — the "stamp" color */
  --accent-2:   #1e241f;
  --gold:       #a87227;   /* brass — secondary accent */

  /* themeable surface tokens (overridden in dark mode below) */
  --bar-bg:     rgba(250,249,244,.82);  /* sticky top bar */
  --cta-bg:     #1e241f;                /* apply section bg (dark in both modes) */
  --cta-fg:     #faf9f4;
  --no-bg:      #fbf0ee;                /* "dealbreakers" card */
  --no-border:  #eccec6;
  --no-fg:      #a8452c;                /* dealbreakers heading */

  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans:  "Inter", system-ui, -apple-system, sans-serif;
  --mono:  "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --maxw: 880px;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(30,36,31,.04), 0 12px 32px rgba(30,36,31,.08);
}

/* ---------- Dark theme ----------
   Values live in one custom-property block, applied via two selectors:
   1) system preference is dark AND the user hasn't forced light
   2) the user explicitly chose dark (data-theme="dark")
   Explicit light (data-theme="light") always wins by being excluded from #1.
   Edit both blocks together — they share the same values. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --ink:        #e7eae4;
    --ink-soft:   #adb5ae;
    --ink-faint:  #8b948c;
    --paper:      #131711;
    --paper-2:    #1c211a;
    --card:       #191e18;
    --line:       #2e352e;
    --accent:     #6cc094;
    --gold:       #d9a24f;
    --bar-bg:     rgba(19,23,17,.82);
    --cta-bg:     #0c0f0b;
    --cta-fg:     #e7eae4;
    --no-bg:      #241a19;
    --no-border:  #402e2a;
    --no-fg:      #e29580;
    --shadow:     0 1px 2px rgba(0,0,0,.3), 0 14px 40px rgba(0,0,0,.45);
  }
}
:root[data-theme="dark"] {
  --ink:        #e7eae4;
  --ink-soft:   #adb5ae;
  --ink-faint:  #8b948c;
  --paper:      #131711;
  --paper-2:    #1c211a;
  --card:       #191e18;
  --line:       #2e352e;
  --accent:     #6cc094;
  --gold:       #d9a24f;
  --bar-bg:     rgba(19,23,17,.82);
  --cta-bg:     #0c0f0b;
  --cta-fg:     #e7eae4;
  --no-bg:      #241a19;
  --no-border:  #402e2a;
  --no-fg:      #e29580;
  --shadow:     0 1px 2px rgba(0,0,0,.3), 0 14px 40px rgba(0,0,0,.45);
}

* { box-sizing: border-box; }

:root { color-scheme: light dark; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 24px; }

a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 2px; }

/* height:auto is load-bearing: without it the width/height attributes win over
   CSS sizing and every image renders at its full pixel height. */
img { max-width: 100%; height: auto; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--sans);
  font-weight: 600;
  font-size: .98rem;
  letter-spacing: .01em;
  padding: 14px 26px;
  border-radius: 999px;
  text-decoration: none;
  border: 1.5px solid var(--ink);
  transition: transform .12s ease, background .2s ease, color .2s ease, box-shadow .2s ease;
  cursor: pointer;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(30,36,31,.22); }
.btn--ghost { background: transparent; color: var(--ink); }
.btn--ghost:hover { background: var(--ink); color: var(--paper); }
.btn--small { padding: 9px 18px; font-size: .85rem; }
.btn__ic { margin-right: 7px; }
.btn--big { font-size: 1.1rem; padding: 18px 38px; background: var(--accent); border-color: var(--accent); color: #fff; }
.btn--big:hover { box-shadow: 0 10px 30px rgba(44,107,71,.4); }

/* ---------- Top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: var(--bar-bg);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.topbar__inner { display: flex; align-items: center; gap: 24px; height: 62px; }
.brand { font-family: var(--mono); font-weight: 500; font-size: .95rem; color: var(--ink); text-decoration: none; letter-spacing: -.02em; }
.brand__dot { color: var(--accent); }
.topnav { display: flex; gap: 18px; margin-left: auto; }
.topnav a { color: var(--ink-soft); text-decoration: none; font-size: .9rem; font-weight: 500; white-space: nowrap; }
.topnav a:hover { color: var(--accent); }

/* Theme toggle */
.theme-toggle {
  display: inline-grid; place-items: center;
  width: 38px; height: 38px; margin-left: 10px; padding: 0;
  background: transparent; color: var(--ink);
  border: 1.5px solid var(--line); border-radius: 999px;
  cursor: pointer; transition: border-color .2s, color .2s, transform .12s;
}
.theme-toggle:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-1px); }
.theme-toggle svg { width: 18px; height: 18px; display: block; }
/* Icon reflects the *effective* theme: moon in light mode, sun in dark mode. */
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun { display: block; }
  :root:not([data-theme="light"]) .theme-toggle .icon-moon { display: none; }
}
:root[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

/* ---------- Hero ---------- */
.hero { background:
    radial-gradient(120% 80% at 80% -10%, rgba(168,114,39,.13), transparent 60%),
    linear-gradient(180deg, var(--paper-2), var(--paper));
  border-bottom: 1px solid var(--line);
  padding: 86px 0 72px;
}
.kicker {
  font-family: var(--mono); font-size: .78rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--accent); margin: 0 0 18px;
}
.kicker--light { color: rgba(255,255,255,.7); }
.hero__title {
  font-family: var(--serif); font-weight: 600; font-size: clamp(3rem, 9vw, 6.2rem);
  line-height: .92; letter-spacing: -.02em; margin: 0;
}
.hero__title-em { font-style: italic; color: var(--accent); font-weight: 500; }
.hero__lede { max-width: 56ch; font-size: 1.18rem; color: var(--ink-soft); margin: 26px 0 32px; }
.hero__lede strong { color: var(--ink); }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; }

.hero__stats {
  list-style: none; display: flex; flex-wrap: wrap; gap: 40px;
  margin: 54px 0 0; padding: 28px 0 0; border-top: 1px solid var(--line);
}
.hero__stats li { display: flex; flex-direction: column; }
.stat__num { font-family: var(--serif); font-weight: 600; font-size: 2.4rem; line-height: 1; color: var(--ink); }
.stat__label { font-size: .85rem; color: var(--ink-faint); margin-top: 6px; }

/* One-line aside under the hero rule. */
.hero__gloss {
  margin: 22px 0 0; font-family: var(--mono); font-size: .8rem;
  color: var(--ink-faint); letter-spacing: .02em;
}
.hero__gloss em { color: var(--gold); font-style: normal; }

/* ---------- The resume document ---------- */
.doc {
  background: var(--card);
  margin: -40px auto 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 56px 60px 40px;
  position: relative;
}
.doc::before { /* faint approval-stamp vibe */
  content: "ON FILE"; position: absolute; top: 30px; right: 34px;
  font-family: var(--mono); font-size: .7rem; letter-spacing: .25em;
  color: var(--accent); opacity: .25; border: 1.5px solid var(--accent);
  padding: 4px 10px; border-radius: 4px; transform: rotate(8deg);
}

.resume-head { display: flex; gap: 28px; align-items: center; padding-bottom: 26px; border-bottom: 2px solid var(--ink); }
.resume-head__main { flex: 1; }
.name { font-family: var(--serif); font-size: clamp(2rem, 5vw, 2.9rem); font-weight: 600; margin: 0; letter-spacing: -.02em; }
.title { color: var(--accent); font-weight: 600; margin: 4px 0 14px; }
.contactline { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 0; padding: 0; font-size: .9rem; color: var(--ink-soft); }
/* Emoji glyphs sit tight against their label — nudge the gap open. */
.contactline li > span[aria-hidden] { margin-right: 3px; }

.resume-head__photo { flex-shrink: 0; }
.resume-head__photo img { width: 110px; height: 130px; object-fit: cover; object-position: 50% 30%; border-radius: 8px; }

/* Blocks */
.block { padding: 30px 0; border-bottom: 1px solid var(--line); }
.block:last-child { border-bottom: 0; }
.block__h {
  font-family: var(--mono); font-size: .82rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--ink); margin: 0 0 18px; padding-bottom: 0;
}
.block__sub, .block__h .block__sub { color: var(--ink-faint); text-transform: none; letter-spacing: 0; font-weight: 400; }
.block p { margin: 0 0 12px; color: var(--ink-soft); }
.block p:last-child { margin-bottom: 0; }
.objective { font-family: var(--serif); font-size: 1.22rem; font-style: italic; color: var(--ink) !important; line-height: 1.55; }

/* ---------- The Rider (contract, not procedure) ---------- */
.rider { border-top: 3px double var(--ink); border-bottom: 3px double var(--ink); padding: 20px 0 18px; }
.rider .rider__meta {
  font-family: var(--mono); font-size: .7rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--ink-faint); text-align: center; margin: 0 0 16px !important;
}
.rider ol { list-style: none; margin: 0; padding: 0; counter-reset: clause; }
.rider li {
  counter-increment: clause; position: relative;
  padding: 11px 0 11px 54px; color: var(--ink-soft); font-size: .96rem;
}
.rider li + li { border-top: 1px dotted var(--line); }
.rider li::before {
  content: counter(clause) "."; position: absolute; left: 0; top: 11px;
  font-family: var(--mono); font-size: .82rem; color: var(--accent);
}
.rider li strong {
  color: var(--ink); font-family: var(--mono); font-size: .8rem;
  letter-spacing: .1em; text-transform: uppercase; display: block; margin-bottom: 3px;
}
.rider__sig { display: flex; flex-wrap: wrap; gap: 14px 34px; margin-top: 20px; padding-left: 54px; }
.rider__sig span {
  font-family: var(--mono); font-size: .72rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-faint); border-bottom: 1px solid var(--line); padding-bottom: 4px; min-width: 170px;
}

/* ---------- Note on usage (dictionary entry) ---------- */
.lexicon { border-left: 3px solid var(--gold); padding: 2px 0 2px 22px; }
/* `.block p` is (0,1,1) — these have to out-specify it or they lose their color
   and their margins. Same trap as the rider header. */
.lexicon .lexicon__head {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; margin: 0 0 14px !important;
}
.lexicon__word { font-family: var(--serif); font-size: 1.5rem; font-weight: 600; color: var(--ink); letter-spacing: -.01em; }
.lexicon__pron { font-family: var(--mono); font-size: .8rem; color: var(--ink-faint); }
.lexicon__pos  { font-style: italic; font-size: .95rem; color: var(--ink-soft); }
.lexicon ol { margin: 0 0 14px; padding-left: 20px; color: var(--ink-soft); font-size: .96rem; }
.lexicon ol li { margin-bottom: 9px; }
.lexicon ol li::marker { color: var(--gold); font-family: var(--mono); font-size: .85em; }
.lexicon .lexicon__note { font-size: .96rem; color: var(--ink-soft); margin-bottom: 0 !important; }
.lexicon strong { color: var(--ink); }

/* ---------- Schedule C: the height chart ---------- */
.chart { display: block; width: 100%; height: auto; margin: 4px 0 18px; }
.chart text { font-family: var(--mono); }
.chart .ax    { stroke: var(--ink-faint); fill: none; stroke-width: 1.2; }
.chart .ref   { stroke: var(--ink-faint); fill: none; stroke-width: 1.2; stroke-dasharray: 5 5; opacity: .7; }
.chart .her   { stroke: var(--accent); fill: none; stroke-width: 3; }
.chart .tick  { fill: var(--ink-faint); font-size: 8.5px; }
.chart .lbl   { fill: var(--ink-faint); font-size: 9px; }
.chart .lblx  { fill: var(--accent); font-size: 10px; font-weight: 600; }
.chart .ground { stroke: var(--ink); fill: none; stroke-width: 2; }

/* ---------- Feature block (figure + spec) ---------- */
.feature { display: grid; grid-template-columns: 260px 1fr; gap: 30px; align-items: start; }
.feature__figure { margin: 0; }
.feature__figure img { width: 100%; height: auto; border-radius: 8px; display: block; box-shadow: var(--shadow); }
.feature__figure figcaption {
  font-family: var(--mono); font-size: .7rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-faint); margin-top: 10px; text-align: center;
}
.spec { margin: 0 0 16px; font-family: var(--mono); font-size: .84rem; }
.spec div { display: flex; align-items: baseline; gap: 8px; padding: 5px 0; border-bottom: 1px dotted var(--line); }
.spec dt { color: var(--ink); white-space: nowrap; flex-shrink: 0; }
.spec dd { margin: 0; color: var(--ink-soft); text-align: right; margin-left: auto; }
.feature__note { font-size: .96rem; }

/* Skills */
.skills { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 36px; }
.skill__row { display: flex; justify-content: space-between; gap: 12px; font-size: .92rem; font-weight: 500; margin-bottom: 6px; }
.skill__pct { font-family: var(--mono); color: var(--accent); }
.bar { height: 8px; background: var(--paper-2); border-radius: 999px; overflow: hidden; }
.bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--accent), var(--gold)); border-radius: 999px; transition: width 1.1s cubic-bezier(.2,.7,.2,1); }
.bar.is-in i { width: var(--w); }
/* Fill widths set here (not inline) so a strict style-src 'self' CSP allows them. */
.bar[data-fill="0"]   { --w: 0%; }
.bar[data-fill="8"]   { --w: 8%; }
.bar[data-fill="97"]  { --w: 97%; }
.bar[data-fill="98"]  { --w: 98%; }
.bar[data-fill="100"] { --w: 100%; }
.skills__note { margin-top: 18px !important; font-size: .92rem; }

/* Experience */
.exp-note { font-family: var(--serif); font-style: italic; font-size: 1.08rem; color: var(--ink) !important; margin-bottom: 6px !important; }
.job { padding: 16px 0; }
.job + .job { border-top: 1px dashed var(--line); }
.job__head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; }
.job__title { font-family: var(--serif); font-size: 1.18rem; font-weight: 600; margin: 0; }
.job__co { color: var(--ink-faint); font-weight: 400; font-size: .95rem; font-family: var(--sans); }
.job__date { font-family: var(--mono); font-size: .8rem; color: var(--ink-faint); white-space: nowrap; }
.job__bullets { margin: 10px 0 0; padding-left: 20px; color: var(--ink-soft); }
.job__bullets li { margin-bottom: 5px; }

/* Certs */
.certs { margin: 0; padding-left: 20px; color: var(--ink-soft); }
.certs li { margin-bottom: 8px; }
.certs strong { color: var(--ink); }

/* Requirements */
.reqs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.reqs__col { background: var(--paper); border: 1px solid var(--line); border-radius: 8px; padding: 18px 20px; }
.reqs__col h4 { margin: 0 0 10px; font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ink); }
.reqs__col ul { margin: 0; padding-left: 18px; font-size: .92rem; color: var(--ink-soft); }
.reqs__col li { margin-bottom: 6px; }
.reqs__col--no { background: var(--no-bg); border-color: var(--no-border); }
.reqs__col--no h4 { color: var(--no-fg); }

/* Benefits */
.benefits__intro { margin-bottom: 20px !important; }
.benefits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.benefit { background: var(--paper); border: 1px solid var(--line); border-radius: 10px; padding: 20px; transition: transform .15s ease, box-shadow .15s ease; }
.benefit:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.benefit__ic { font-size: 1.6rem; display: block; margin-bottom: 8px; }
.benefit h4 { margin: 0 0 6px; font-size: 1rem; font-family: var(--serif); }
.benefit p { font-size: .9rem; margin: 0; }

/* ---------- Exhibits (attachments gallery) ---------- */
.exhibits__intro { margin-bottom: 20px !important; }
.exhibits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px 18px; }
.exhibit { margin: 0; }
.exhibit__btn {
  display: block; width: 100%; padding: 0; border: 1px solid var(--line);
  background: var(--paper-2); border-radius: 8px; overflow: hidden; cursor: zoom-in;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.exhibit__btn:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--accent); }
.exhibit__btn img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 4; object-fit: cover; }
.exhibit figcaption { font-size: .82rem; color: var(--ink-soft); margin-top: 9px; line-height: 1.45; }
.exhibit__id { display: block; font-family: var(--mono); font-size: .68rem; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin-bottom: 2px; }

/* Lightbox (native <dialog>).
   The panel carries its own dark surface rather than leaning on ::backdrop —
   the caption has to stay legible even where the backdrop doesn't paint. */
.lb { border: 0; padding: 14px; background: #131711; border-radius: 14px;
      max-width: 92vw; max-height: 92vh; color: #e7eae4; box-shadow: 0 24px 70px rgba(0,0,0,.6); }
.lb::backdrop { background: rgba(12,15,11,.86); }
.lb img { display: block; max-width: calc(92vw - 28px); max-height: 74vh; width: auto; height: auto; border-radius: 8px; }
.lb__cap { font-size: .86rem; color: #a9b1aa; margin: 12px 4px 2px; max-width: 62ch; }
.lb__close {
  position: absolute; top: 22px; right: 22px; width: 34px; height: 34px; line-height: 1;
  border-radius: 999px; border: 0; cursor: pointer; font-size: 1.1rem;
  background: rgba(19,23,17,.72); color: #e7eae4; backdrop-filter: blur(6px);
}
.lb__close:hover { background: rgba(19,23,17,.92); }

/* FAQ */
.faq details { border-bottom: 1px solid var(--line); padding: 4px 0; }
.faq summary { cursor: pointer; font-weight: 600; font-family: var(--serif); font-size: 1.1rem; padding: 12px 0; list-style: none; display: flex; justify-content: space-between; gap: 16px; align-items: center; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--sans); color: var(--accent); font-weight: 400; font-size: 1.5rem; transition: transform .2s ease; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 0 16px; margin: 0; }

.references { font-family: var(--serif); font-style: italic; font-size: 1.1rem; color: var(--ink) !important; }

/* ---------- Apply ---------- */
.apply { background:
    radial-gradient(100% 120% at 50% -20%, rgba(44,107,71,.34), transparent 60%),
    var(--cta-bg);
  color: var(--cta-fg); text-align: center; padding: 90px 0; margin-top: 70px;
}
.apply__title { font-family: var(--serif); font-size: clamp(2.2rem, 6vw, 3.4rem); font-weight: 600; margin: 0 0 18px; letter-spacing: -.02em; }
.apply__lede { max-width: 50ch; margin: 0 auto 32px; color: rgba(250,249,244,.78); font-size: 1.1rem; }
.apply__fine { margin-top: 24px; font-size: .85rem; color: rgba(250,249,244,.5); }

/* ---------- Footer ---------- */
.footer { background: var(--paper-2); border-top: 1px solid var(--line); padding: 34px 0; }
.footer__inner { text-align: center; }
.footer p { margin: 0 auto 6px; font-size: .88rem; color: var(--ink-faint); max-width: 70ch; }
.footer__fine { font-size: .82rem; }

/* ---------- Reveal-on-scroll ---------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 760px) {
  body { font-size: 16px; }
  .topnav { display: none; }
  .theme-toggle { margin-left: auto; }
  .doc { padding: 36px 22px 28px; margin-top: -24px; border-radius: 0; border-left: 0; border-right: 0; }
  .doc::before { display: none; }
  .resume-head { flex-direction: column-reverse; align-items: flex-start; }
  .skills, .reqs, .benefits { grid-template-columns: 1fr; }
  .exhibits { grid-template-columns: 1fr 1fr; gap: 16px 14px; }
  .feature { grid-template-columns: 1fr; gap: 20px; }
  .feature__figure { max-width: 260px; margin-inline: auto; }
  /* Narrow: the right-aligned value lands on its own line and reads as orphaned.
     Drop back to a plain label-then-value definition list. */
  .spec { font-size: .78rem; }
  .spec div { flex-wrap: wrap; }
  .spec dd { margin-left: 0; text-align: left; }
  .rider li { padding-left: 40px; }
  .rider li::before { font-size: .76rem; }
  .rider__sig { padding-left: 0; }
  .hero__stats { gap: 26px; }
  .job__head { flex-direction: column; gap: 2px; }
}

/* ---------- Accessibility ---------- */
/* Visually hidden but read by screen readers (labels for emoji facts, etc.) */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* Shown only on the printed resume (e.g. the contact email) */
.print-only { display: none; }

.skip-link {
  position: absolute; left: 12px; top: -50px; z-index: 100;
  background: var(--accent); color: #fff; padding: 10px 16px; border-radius: 8px;
  font-size: .9rem; font-weight: 600; text-decoration: none; transition: top .2s ease;
}
.skip-link:focus { top: 12px; }

:focus-visible {
  outline: 2.5px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- Anchor scroll offset (sticky top bar is ~62px) ---------- */
:where(#top, #summary, #height, #rider, #usage, #skills, #benefits, #exhibits, #faq, #apply) {
  scroll-margin-top: 78px;
}

/* ---------- Scroll-spy active nav link ---------- */
.topnav a { position: relative; }
.topnav a.is-active { color: var(--accent); }
.topnav a.is-active::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -6px;
  height: 2px; background: var(--accent); border-radius: 2px;
}

/* ---------- Smooth theme cross-fade (applied briefly on toggle) ---------- */
:root.theme-transition, :root.theme-transition * {
  transition: background-color .35s ease, color .35s ease, border-color .35s ease, fill .35s ease !important;
}

/* ---------- Apply: compose chooser ---------- */
.apply__compose { position: relative; display: inline-block; }
.compose-menu {
  position: absolute; left: 50%; transform: translateX(-50%);
  top: calc(100% + 12px); z-index: 30;
  min-width: 270px; padding: 8px;
  background: var(--card); color: var(--ink);
  border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow);
  display: flex; flex-direction: column; gap: 2px;
  text-align: left;
}
.compose-menu[hidden] { display: none; }
.compose-opt {
  display: flex; align-items: center; gap: 11px;
  width: 100%; padding: 11px 14px; border-radius: 8px;
  font: inherit; font-size: .95rem; font-weight: 500; line-height: 1.2;
  color: var(--ink); text-decoration: none; text-align: left;
  background: transparent; border: 0; cursor: pointer;
}
.compose-opt:hover, .compose-opt:focus-visible { background: var(--paper-2); color: var(--accent); }
.compose-opt__ic { font-size: 1.1rem; flex-shrink: 0; }

/* ---------- 404 page ---------- */
/* ---------- 404 art + notice ---------- */
.nf__art { display: block; width: 100%; max-width: 272px; height: auto; margin: 0 auto 26px; }
.nf__art .art-line { stroke: var(--accent); fill: none; stroke-linecap: round; }
.nf__art .art-fill { fill: var(--accent); stroke: none; }
.nf__art .art-alt  { fill: var(--gold); stroke: none; }
.nf__art .art-faint { stroke: var(--ink-faint); fill: none; stroke-linecap: round; }
/* The notice block is the site's own device, reused — it reads left-aligned
   even though the rest of the 404 is centered. */
.nf__notice { text-align: left; margin: 26px 0 30px; }


.nf-body { display: grid; min-height: 100vh; place-items: center; }
.nf { text-align: center; padding: 48px 24px; max-width: 640px; }
.nf__code {
  font-family: var(--mono); font-size: .8rem; letter-spacing: .3em; text-transform: uppercase;
  color: var(--accent); margin: 0 0 14px;
}
.nf__title {
  font-family: var(--serif); font-weight: 600; font-size: clamp(2.2rem, 7vw, 3.6rem);
  line-height: 1.05; letter-spacing: -.02em; margin: 0 0 22px;
}
.nf__cursor { color: var(--accent); font-family: var(--mono); animation: nf-blink 1.05s steps(1) infinite; }
@keyframes nf-blink { 50% { opacity: 0; } }
.nf__msg { color: var(--ink-soft); font-size: 1.12rem; margin: 0 auto 30px; max-width: 46ch; }
.nf__cta { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.nf__fine { margin-top: 34px; font-family: var(--mono); font-size: .78rem; color: var(--ink-faint); }

/* ---------- Print: it should actually print like a resume ---------- */
@media print {
  .topbar, .hero__cta, .apply, .footer, .doc::before, .skip-link, .exhibits, .exhibits__intro, .lb { display: none !important; }
  .print-only { display: initial; }
  body { background: #fff; font-size: 11pt; }
  .hero { padding: 20px 0; border: 0; background: #fff; }
  .doc { box-shadow: none; border: 0; margin: 0; padding: 0; }
  .block { padding: 14px 0; }
  .feature__figure { display: none; }
  .feature { grid-template-columns: 1fr; }
  .rider { border-color: #000; }
  a { color: inherit; text-decoration: none; }
  .reveal { opacity: 1 !important; transform: none !important; }
  .bar.is-in i, .bar i { width: var(--w) !important; }
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}
