/* Doza ascunsă — Lobul hepatic hexagonal viu & scutul de glutation */
@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("fonts/fraunces-normal-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D1, U+02D7, U+02DD, U+02EE, U+0300-030F, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("fonts/fraunces-normal-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Source Serif 4";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url("fonts/source-serif-4-normal-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D1, U+02D7, U+02DD, U+02EE, U+0300-030F, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Source Serif 4";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url("fonts/source-serif-4-normal-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Source Serif 4";
  font-style: italic;
  font-weight: 400 600;
  font-display: swap;
  src: url("fonts/source-serif-4-italic-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D1, U+02D7, U+02DD, U+02EE, U+0300-030F, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Source Serif 4";
  font-style: italic;
  font-weight: 400 600;
  font-display: swap;
  src: url("fonts/source-serif-4-italic-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Plex Sans";
  font-style: normal;
  font-weight: 500 600;
  font-display: swap;
  src: url("fonts/IBMPlexSans-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D1, U+02D7, U+02DD, U+02EE, U+0300-030F, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Plex Sans";
  font-style: normal;
  font-weight: 500 600;
  font-display: swap;
  src: url("fonts/IBMPlexSans-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/IBMPlexMono-400-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D1, U+02D7, U+02DD, U+02EE, U+0300-030F, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/IBMPlexMono-400-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("fonts/IBMPlexMono-600-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D1, U+02D7, U+02DD, U+02EE, U+0300-030F, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("fonts/IBMPlexMono-600-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Light: Anatomical Copperplate & Porcelain */
:root {
  --display: "Fraunces", Georgia, serif;
  --serif: "Source Serif 4", Georgia, serif;
  --ui: "Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;

  --bg: #F5F1E8;
  --surface: #FDFBF6;
  --recessed: #EAE3D5;
  --fg: #14191D;
  --mut: #424C54;
  --line: #CFC7B8;
  --line-soft: #E2DBCC;

  --safe: #126166;
  --safe-bg: #DFEFF0;
  --gsh: #A8640C;
  --gsh-bg: #F9EEDB;
  --napqi: #B5202A;
  --napqi-bg: #FBE6E8;

  --sr-line: #8A8270;
  --sr-ink: var(--fg);
  --sr-acc: var(--napqi);
  --sr-ok: var(--safe);

  --bar-h: 3rem;
  --col: 70rem;
  color-scheme: light;
}

/* Dark: Confocal Fluorescence Microscopy */
:root[data-theme="dark"] {
  --bg: #060A0E;
  --surface: #0D141B;
  --recessed: #131D27;
  --fg: #EEF3F8;
  --mut: #9FB1C1;
  --line: #233240;
  --line-soft: #17232E;

  --safe: #3BD4B8;
  --safe-bg: #0E2B29;
  --gsh: #F2B84B;
  --gsh-bg: #2E230E;
  --napqi: #FF5460;
  --napqi-bg: #361217;

  --sr-line: #546677;
  color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #060A0E;
    --surface: #0D141B;
    --recessed: #131D27;
    --fg: #EEF3F8;
    --mut: #9FB1C1;
    --line: #233240;
    --line-soft: #17232E;
    --safe: #3BD4B8;
    --safe-bg: #0E2B29;
    --gsh: #F2B84B;
    --gsh-bg: #2E230E;
    --napqi: #FF5460;
    --napqi-bg: #361217;
    --sr-line: #546677;
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html {
  background: var(--bg); color: var(--fg); font-family: var(--serif);
  line-height: 1.62; -webkit-text-size-adjust: 100%; scroll-behavior: smooth;
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; overflow-x: clip; background: var(--bg); color: var(--fg); }

.skip {
  position: absolute; left: -9999px; top: 0; padding: .65rem 1rem;
  background: var(--napqi); color: #fff; font: 600 .95rem/1 var(--ui); z-index: 200; text-decoration: none;
}
.skip:focus { left: .75rem; top: .75rem; }

/* Topbar */
.topbar {
  position: sticky; top: 0; z-index: 60;
  display: flex; align-items: center; gap: .75rem; min-height: var(--bar-h);
  padding: var(--browser-safe-top, env(safe-area-inset-top)) max(1rem, env(safe-area-inset-right)) 0 max(1rem, env(safe-area-inset-left));
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  backdrop-filter: blur(10px); border-bottom: 1px solid var(--line-soft);
  font: 500 .9rem/1 var(--ui);
}
.home {
  display: inline-flex; align-items: center; gap: .45rem; color: var(--fg);
  text-decoration: none; font-family: var(--ui); font-weight: 600; white-space: nowrap; flex: none; padding: .4rem 0;
}
.home:hover, .home:focus-visible { color: var(--safe); }
.home-mark { width: 18px; height: 18px; color: var(--safe); flex: none; }
.topnav { display: flex; align-items: center; gap: .25rem; overflow-x: auto; scrollbar-width: none; min-width: 0; }
@media (max-width: 639px) { .topnav { display: none; } }
.topnav a { color: var(--mut); text-decoration: none; white-space: nowrap; padding: .45rem .55rem; border-radius: .35rem; font-size: .88rem; }
.topnav a:hover, .topnav a:focus-visible { color: var(--fg); background: var(--recessed); }
.topnav a[aria-current="true"] { color: var(--safe); font-weight: 600; }
.spacer { flex: 1; }
.chip {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 2.1rem; padding: .35rem .65rem; border: 1px solid var(--line); border-radius: 999px;
  color: var(--fg); text-decoration: none; font-family: var(--ui); font-weight: 600; font-size: .84rem;
  white-space: nowrap; flex: none;
}
.chip:hover, .chip:focus-visible { border-color: var(--safe); color: var(--safe); }
.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.35rem; height: 2.35rem; border-radius: 50%; border: 1px solid var(--line);
  background: transparent; color: var(--fg); cursor: pointer; flex: none; padding: 0;
}
.icon-btn:hover, .icon-btn:focus-visible { border-color: var(--safe); color: var(--safe); }
.icon-btn svg { display: block; }
.icon-btn svg[hidden] { display: none !important; }

.progress-track {
  position: fixed; left: 0; right: 0; top: calc(var(--bar-h) + var(--browser-safe-top, env(safe-area-inset-top)));
  height: 2px; z-index: 59; pointer-events: none;
}
.progress-fill { height: 100%; width: 100%; background: var(--safe); transform-origin: left center; transform: scaleX(0); }

main { outline: none; }
.wrap { width: 100%; max-width: var(--col); margin: 0 auto; padding: 0 1.15rem; }
.prose-col { max-width: 45rem; }
section[id] { scroll-margin-top: calc(var(--bar-h) + var(--browser-safe-top, env(safe-area-inset-top)) + 1.4rem); }

/* Full-Bleed Hero & Living Lobule Stage */
.hero { padding: 1.5rem 0 1.8rem; }
.kicker {
  margin: 0 0 .42rem; font: 600 .78rem/1.3 var(--mono); letter-spacing: .05em;
  text-transform: uppercase; color: var(--safe);
}
h1 {
  margin: 0 0 .6rem; font-family: var(--display); font-weight: 600; font-variation-settings: "opsz" 48;
  font-size: clamp(1.85rem, 3.6vw, 2.75rem); line-height: 1.07; letter-spacing: -.018em; max-width: 22ch;
}
.deck { margin: 0 0 1.25rem; font-size: 1.06rem; line-height: 1.52; color: var(--mut); max-width: 64ch; }

.lobule-stage {
  position: relative; width: 100%; max-width: var(--col); margin: 0 auto;
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  background: radial-gradient(circle at 28% 50%, color-mix(in srgb, var(--safe) 7%, var(--bg)), var(--bg) 72%);
}
.lobule-canvas { display: block; width: 100%; height: 470px; }
@media (max-width: 679px) { .lobule-canvas { height: 560px; } }

/* Hairline Instrument Deck (no heavy nested cards) */
.instrument-deck { padding: 1.15rem 0 0; display: grid; gap: 1.05rem; }
.deck-row {
  display: flex; flex-wrap: wrap; align-items: center; gap: .65rem 1rem;
  padding-bottom: .9rem; border-bottom: 1px solid var(--line-soft);
}
.clock-readout {
  font: 600 1.15rem/1 var(--mono); color: var(--fg); min-width: 5.5rem; font-variant-numeric: tabular-nums;
}
.slider { flex: 1 1 12rem; min-width: 8rem; accent-color: var(--safe); height: 2.1rem; cursor: pointer; }
.play-btn {
  display: inline-flex; align-items: center; gap: .35rem; min-height: 2.5rem; padding: .38rem .92rem;
  border: 1px solid var(--safe); border-radius: 999px; background: var(--safe-bg); color: var(--safe);
  font: 600 .85rem/1 var(--ui); cursor: pointer; white-space: nowrap;
}
.play-btn[data-on="true"] { background: var(--safe); color: var(--bg); }
.reset-btn {
  min-height: 2.3rem; padding: .35rem .7rem; border: 1px solid var(--line); border-radius: .45rem;
  background: transparent; color: var(--fg); font: 600 .82rem/1 var(--ui); cursor: pointer;
}
.reset-btn:hover, .reset-btn:focus-visible { border-color: var(--safe); color: var(--safe); }

.ctrl-label { display: block; margin-bottom: .38rem; font: 600 .8rem/1.3 var(--mono); text-transform: uppercase; letter-spacing: .04em; color: var(--mut); }
.chip-row { display: flex; flex-wrap: wrap; gap: .38rem; }
.cbtn {
  min-height: 2.25rem; padding: .32rem .68rem; border: 1px solid var(--line); border-radius: .45rem;
  background: var(--surface); color: var(--fg); font: 500 .82rem/1.2 var(--ui); cursor: pointer;
}
.cbtn:hover, .cbtn:focus-visible { border-color: var(--safe); color: var(--safe); }
.cbtn[aria-pressed="true"] { background: var(--fg); color: var(--bg); border-color: var(--fg); font-weight: 600; }

.shelf-btn {
  min-height: 2.2rem; padding: .28rem .6rem; border: 1px dashed var(--line); border-radius: .4rem;
  background: transparent; color: var(--fg); font: 500 .81rem/1.2 var(--ui); cursor: pointer;
}
.shelf-btn:hover, .shelf-btn:focus-visible { border-color: var(--gsh); color: var(--gsh); border-style: solid; }

.dose-tray { display: flex; flex-wrap: wrap; gap: .38rem; min-height: 2.1rem; align-items: center; }
.dose-pill {
  display: inline-flex; align-items: center; gap: .35rem; padding: .25rem .55rem;
  border-radius: 999px; background: var(--recessed); border: 1px solid var(--line);
  font: 500 .8rem/1.1 var(--mono); color: var(--fg);
}
.dose-pill button {
  border: 0; background: transparent; color: var(--mut); cursor: pointer; font-size: .95rem; padding: 0 .1rem; line-height: 1;
}
.dose-pill button:hover { color: var(--napqi); }

.profile-grid {
  display: flex; flex-wrap: wrap; gap: .75rem 1.4rem; align-items: center;
  padding-bottom: .9rem; border-bottom: 1px solid var(--line-soft);
  font: 500 .86rem/1.3 var(--ui);
}
.weight-badge { font: 600 1rem/1 var(--mono); color: var(--gsh); min-width: 3.6rem; display: inline-block; }

/* Hairline Telemetry */
.telemetry {
  display: grid; gap: .8rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 11.5rem), 1fr));
}
.t-cell { padding: .6rem 0 .4rem; border-top: 2px solid var(--line); font-variant-numeric: tabular-nums; }
.t-cell span { display: block; font: 500 .78rem/1.25 var(--ui); color: var(--mut); }
.t-cell strong { display: block; margin-top: .22rem; font: 600 1.45rem/1.1 var(--mono); color: var(--fg); }
.t-cell[data-tone="safe"] { border-color: var(--safe); }
.t-cell[data-tone="safe"] strong { color: var(--safe); }
.t-cell[data-tone="gsh"] { border-color: var(--gsh); }
.t-cell[data-tone="gsh"] strong { color: var(--gsh); }
.t-cell[data-tone="napqi"] { border-color: var(--napqi); }
.t-cell[data-tone="napqi"] strong { color: var(--napqi); }

.verdict-note {
  margin: 0; padding: .75rem .95rem; border-left: 3px solid var(--gsh);
  background: var(--recessed); border-radius: 0 .45rem .45rem 0; font: 500 .95rem/1.45 var(--ui);
}
.verdict-note[data-tone="napqi"] { border-color: var(--napqi); background: var(--napqi-bg); }

.stage-actions {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem;
  padding-top: .85rem; border-top: 1px solid var(--line-soft);
}
.action-btn {
  display: inline-flex; align-items: center; gap: .4rem; min-height: 2.65rem; padding: .42rem .9rem;
  border: 1px solid var(--fg); border-radius: .45rem; background: var(--fg); color: var(--bg);
  font: 600 .85rem/1.2 var(--ui); cursor: pointer;
}
.action-btn.secondary { background: transparent; color: var(--fg); border-color: var(--line); }
.action-btn.secondary:hover, .action-btn.secondary:focus-visible { border-color: var(--safe); color: var(--safe); }

/* Share row */
.share { margin: 0; }
.share-row { display: flex; flex-wrap: wrap; gap: .38rem; align-items: center; }
.share-row .lab { font: 500 .84rem/1.2 var(--ui); color: var(--mut); margin-inline-end: .3rem; }
.share-row a, .share-row button {
  display: inline-grid; place-items: center; flex: none; width: 40px; height: 40px; padding: 0;
  border-radius: 50%; border: 1px solid var(--sr-line); background: transparent; color: var(--sr-ink);
  text-decoration: none; cursor: pointer; font: inherit; transition: color .15s, border-color .15s;
}
.share-row a:hover, .share-row button:hover, .share-row a:focus-visible, .share-row button:focus-visible {
  color: var(--sr-acc); border-color: var(--sr-acc);
}
.share-row [hidden] { display: none !important; }
@media (pointer: coarse) { .share-row a, .share-row button { width: 44px; height: 44px; } }
.share-status { font: 500 .82rem/1.2 var(--ui); color: var(--sr-ok); min-height: 1.1em; margin: .3rem 0 0; }
.share-status:empty { display: none; }

/* Sections */
.band { padding: 2.5rem 0; border-top: 1px solid var(--line-soft); }
h2 {
  margin: 0 0 .85rem; font-family: var(--display); font-weight: 600;
  font-variation-settings: "opsz" 32; font-size: clamp(1.45rem, 2.6vw, 2rem); line-height: 1.18;
}
.sec-link { color: inherit; text-decoration: none; }
.sec-link:hover::after, .sec-link:focus-visible::after { content: " #"; color: var(--safe); }

.nomogram-wrap { margin-top: 1.1rem; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: .85rem 0; }
.nomogram-canvas { display: block; width: 100%; height: 340px; }

.figure-card { margin: 1.15rem 0; background: var(--surface); border: 1px solid var(--line); border-radius: .75rem; overflow: hidden; }
.figure-card svg { display: block; width: 100%; height: auto; }
.figure-cap { padding: .75rem 1rem; border-top: 1px solid var(--line-soft); font: 400 .9rem/1.45 var(--ui); color: var(--mut); }

/* Pediatric Syringe Interactive */
.ped-shell {
  margin-top: 1.1rem; padding: 1.1rem 1.15rem; background: var(--surface);
  border: 1px solid var(--line); border-radius: .75rem; display: grid; gap: 1rem;
}
.ped-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr)); }
.ped-stat { padding: .85rem 1rem; border-radius: .55rem; border: 1px solid var(--line-soft); background: var(--bg); }
.ped-stat.danger { background: var(--napqi-bg); border-color: color-mix(in srgb, var(--napqi) 35%, transparent); }
.ped-big { font: 600 1.85rem/1.1 var(--mono); margin: .25rem 0; }
.ped-stat.danger .ped-big { color: var(--napqi); }

.table-wrap { margin-top: 1.05rem; overflow-x: auto; border: 1px solid var(--line); border-radius: .65rem; background: var(--surface); }
table { width: 100%; border-collapse: collapse; min-width: 38rem; font: 400 .92rem/1.45 var(--ui); }
th, td { padding: .7rem .82rem; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line-soft); }
th { font-weight: 600; font-size: .8rem; text-transform: uppercase; letter-spacing: .03em; color: var(--mut); background: var(--recessed); }
tr:last-child td { border-bottom: 0; }

.protocol-grid { display: grid; gap: .85rem; margin-top: 1rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); }
.protocol-step { padding: .9rem 1rem; background: var(--surface); border: 1px solid var(--line); border-radius: .6rem; }
.protocol-num { display: inline-block; margin-bottom: .3rem; font: 600 .8rem/1 var(--mono); color: var(--napqi); }
.protocol-step h3 { margin: 0 0 .3rem; font: 600 .98rem/1.3 var(--ui); }
.protocol-step p { margin: 0; font-size: .92rem; color: var(--mut); }

.sources-list { padding-left: 1.25rem; font-size: .95rem; }
.sources-list li { margin-bottom: .48rem; }
a { color: var(--safe); }

footer.site-footer {
  margin-top: 2rem; padding: 1.6rem 0 2.5rem; border-top: 1px solid var(--line);
  font: 400 .88rem/1.6 var(--ui); color: var(--mut);
}
.footer-inner { display: flex; flex-wrap: wrap; gap: .6rem 1.4rem; align-items: center; }
.footer-inner a { color: var(--fg); font-weight: 500; text-decoration: none; border-bottom: 1px solid var(--line); }
.footer-inner a:hover, .footer-inner a:focus-visible { color: var(--safe); border-color: var(--safe); }

/* Reading rail */
.rail { display: none; }
@media (min-width: 1280px) {
  .rail {
    --col: 70rem; --gut: 1.25rem;
    display: flex; flex-direction: column; position: fixed; top: 50%;
    left: calc(50% + var(--col) / 2 + var(--gut)); transform: translateY(-50%);
    z-index: 40; margin: 0; padding: .4rem 0; max-height: calc(100vh - 7rem);
  }
  .rail::before { content: ""; position: absolute; left: calc(.875rem - .5px); top: 1.1rem; bottom: 1.1rem; width: 1px; background: var(--line); }
  .rail-dot { position: relative; display: flex; align-items: center; justify-content: center; width: 1.75rem; height: 1.75rem; text-decoration: none; border-radius: 50%; }
  .rail-dot .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--mut); box-shadow: 0 0 0 3px var(--bg); transition: transform .2s, background .2s, box-shadow .2s; flex: none; }
  .rail-dot:hover .dot, .rail-dot:focus-visible .dot { background: var(--safe); transform: scale(1.25); }
  .rail-dot[aria-current="true"] .dot { background: var(--safe); transform: scale(1.45); box-shadow: 0 0 0 3px var(--bg), 0 0 0 4.5px color-mix(in srgb, var(--safe) 38%, transparent); }
  .rail-dot:focus-visible { outline: 2px solid var(--safe); outline-offset: -1px; }
  .rail-label {
    position: absolute; right: calc(100% + .3rem); top: 50%; transform: translate(6px, -50%); padding: .22rem .65rem;
    border: 1px solid var(--line); border-radius: .5rem; background: var(--bg); color: var(--fg); box-shadow: 0 6px 20px rgba(0,0,0,.14);
    font: 600 .82rem/1.3 var(--ui); white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity .15s, transform .15s;
  }
  .rail-dot:hover .rail-label, .rail-dot:focus-visible .rail-label { opacity: 1; transform: translate(0, -50%); }
}
@media (min-width: 1440px) {
  .rail-label {
    right: auto; left: calc(100% + .15rem); max-width: calc(50vw - var(--col) / 2 - var(--gut) - 3.25rem);
    overflow: hidden; text-overflow: ellipsis; padding: .1rem .2rem; border-color: transparent; background: transparent;
    box-shadow: none; color: var(--mut); transform: translate(-4px, -50%);
  }
  .rail-dot:hover .rail-label, .rail-dot:focus-visible .rail-label { color: var(--safe); }
}
@media (prefers-reduced-motion: reduce) { .rail .dot, .rail-label { transition: none; } }

[hidden] { display: none !important; }
svg[hidden] { display: none !important; }
