/* Valuation Insights · Article 01
   Layout concept: a long-form financial essay on paper-ivory, set in a single
   reading column with a sticky contents rail; dark ink-navy bands carry the hero,
   the calculators' result panels and the closing reflection. Wide figures step out
   of the column into the right-hand margin on large screens.

   A deliberately single-theme, light editorial design (house style for the firm's
   publication): every colour is set explicitly from the tokens below. */

/* ---------- Fonts (SIL Open Font Licence, self-hosted; see assets/fonts/*-OFL.txt) ---------- */
@font-face { font-family: "Newsreader"; font-style: normal; font-weight: 200 800; font-display: swap;
  src: url("../fonts/newsreader-latin-opsz-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Newsreader"; font-style: normal; font-weight: 200 800; font-display: swap;
  src: url("../fonts/newsreader-latin-ext-opsz-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Newsreader"; font-style: italic; font-weight: 200 800; font-display: swap;
  src: url("../fonts/newsreader-latin-opsz-italic.woff2") format("woff2");
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Newsreader"; font-style: italic; font-weight: 200 800; font-display: swap;
  src: url("../fonts/newsreader-latin-ext-opsz-italic.woff2") format("woff2");
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("../fonts/public-sans-latin-wght-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("../fonts/public-sans-latin-ext-wght-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: "Public Sans"; font-style: italic; font-weight: 100 900; font-display: swap;
  src: url("../fonts/public-sans-latin-wght-italic.woff2") format("woff2");
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }

:root {
  /* colour */
  --ink-navy: #10243A;        /* hero, dark bands */
  --midnight: #142E4B;        /* raised surfaces on dark */
  --teal: #087F8C;            /* data: equity, positive effects (fills) */
  --teal-text: #06707B;       /* teal for text and links on light (5.4:1) */
  --gold: #C49A45;            /* accent: rules, markers, selection */
  --gold-text: #7A5C1F;       /* gold for text on light (≥5:1 on paper and mist) */
  --paper: #F8F6F1;           /* reading surface */
  --mist: #EDF2F5;            /* calculator panels */
  --ink: #1D2935;             /* body text */
  --ink-soft: #4F5D6B;        /* secondary text (6.2:1) */
  --rule: #D9D4C7;            /* hairlines on paper */
  --rule-cool: #CBD6DE;       /* hairlines on mist */
  --slate: #8396A8;           /* data: debt portion */
  --brick: #9C4F36;           /* data: deductions; warnings text */
  --on-dark: #F8F6F1;
  --on-dark-soft: #B9C8D4;
  --white: #FFFFFF;

  /* type */
  --f-display: "Newsreader", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --f-body: "Public Sans", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --f-figure: "Public Sans", "Segoe UI", system-ui, sans-serif;

  --t-xs: 0.8125rem;   /* 13px labels */
  --t-sm: 0.9375rem;   /* 15px captions */
  --t-base: 1.0625rem; /* 17px body */
  --t-lead: clamp(1.125rem, 1.02rem + 0.45vw, 1.3125rem);
  --t-h3: clamp(1.25rem, 1.12rem + 0.5vw, 1.5rem);
  --t-h2: clamp(1.6rem, 1.3rem + 1.3vw, 2.3rem);
  --t-h1: clamp(2.35rem, 1.6rem + 3.6vw, 4.6rem);

  /* space & layout */
  --gutter: max(16px, env(safe-area-inset-left, 0px));
  --gutter-r: max(16px, env(safe-area-inset-right, 0px));
  --measure: 40rem;
  --radius: 4px;
  --header-h: 56px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 24px); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--f-body); font-size: var(--t-base); line-height: 1.7;
  text-rendering: optimizeLegibility; overflow-x: hidden;
}
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 60; background: var(--ink-navy); }
img, svg { max-width: 100%; }
figure { margin: 0; }
a { color: var(--teal-text); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 2px; }
.dark :focus-visible { outline-color: var(--gold); }
[hidden] { display: none !important; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: var(--gutter); top: -60px; z-index: 100; background: var(--gold); color: var(--ink-navy); padding: 8px 14px; font-weight: 600; text-decoration: none; }
.skip:focus { top: calc(env(safe-area-inset-top, 0px) + 8px); }
.num, .tnum { font-variant-numeric: tabular-nums lining-nums; }

/* ---------- Masthead ---------- */
.masthead {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: var(--ink-navy); color: var(--on-dark);
  border-bottom: 1px solid rgba(196, 154, 69, 0.35);
}
.masthead-inner {
  max-width: 1280px; margin: 0 auto; height: var(--header-h);
  padding-left: var(--gutter); padding-right: var(--gutter-r);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.wordmark { display: flex; align-items: baseline; gap: 14px; color: var(--on-dark); text-decoration: none; min-width: 0; }
.wordmark-firm { font-family: var(--f-display); font-size: 1.05rem; font-weight: 600; letter-spacing: 0.02em; white-space: nowrap; }
.wordmark-firm .sp { letter-spacing: 0.32em; }
.wordmark-series { font-size: var(--t-xs); letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); white-space: nowrap; }
.actions { display: flex; gap: 6px; flex-shrink: 0; }
.icon-btn {
  display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 12px;
  border: 1px solid rgba(185, 200, 212, 0.35); border-radius: var(--radius);
  background: transparent; color: var(--on-dark); font: 500 var(--t-xs)/1 var(--f-body); cursor: pointer;
}
.icon-btn:hover { border-color: var(--gold); }
.icon-btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; }
.progress { position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; background: transparent; }
.progress-bar { height: 100%; background: var(--gold); transform-origin: 0 50%; transform: scaleX(0); }
.copy-fallback { position: absolute; right: var(--gutter-r); top: calc(var(--header-h) + 6px); width: min(420px, calc(100vw - 32px)); padding: 8px; font: inherit; font-size: var(--t-xs); border: 1px solid var(--gold); background: var(--white); color: var(--ink); }

/* ---------- Hero ---------- */
.hero { background: radial-gradient(120% 90% at 85% 40%, #183858 0%, var(--ink-navy) 62%); color: var(--on-dark); }
.hero-inner {
  max-width: 1280px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter-r);
  padding-block: clamp(40px, 6vw, 84px) clamp(36px, 5vw, 72px);
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: clamp(24px, 4vw, 56px); align-items: center;
}
.series-tag { display: inline-flex; gap: 10px; align-items: center; margin: 0 0 22px; font-size: var(--t-xs); letter-spacing: 0.16em; text-transform: uppercase; color: var(--gold); }
.series-tag::before { content: ""; width: 28px; height: 1px; background: var(--gold); }
.hero h1 {
  font-family: var(--f-display); font-weight: 500; font-size: var(--t-h1); line-height: 1.02;
  letter-spacing: -0.02em; margin: 0; text-wrap: balance; font-variation-settings: "opsz" 72;
}
.hero h1 em { font-style: italic; color: var(--gold); font-weight: 400; }
.dek { font-family: var(--f-display); font-size: var(--t-lead); line-height: 1.45; color: var(--on-dark-soft); max-width: 34rem; margin: 22px 0 28px; font-variation-settings: "opsz" 24; }
.byline { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 0; padding: 14px 0 0; border-top: 1px solid rgba(185, 200, 212, 0.22); font-size: var(--t-xs); color: var(--on-dark-soft); letter-spacing: 0.02em; }
.byline strong { color: var(--on-dark); font-weight: 600; }
.hero-art { margin: 0; }
.hero-art img { display: block; width: 100%; height: auto; }
.hero-art figcaption { font-size: var(--t-xs); color: var(--on-dark-soft); margin-top: 8px; font-style: italic; }

/* ---------- Article layout ---------- */
.layout {
  max-width: 1280px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter-r);
  display: grid; grid-template-columns: minmax(0, 1fr); gap: 0;
}
.toc-rail { display: none; }
.toc-mobile { margin: 20px 0 8px; border: 1px solid var(--rule); border-radius: var(--radius); background: var(--paper); }
.toc-mobile summary { cursor: pointer; padding: 12px 14px; font-size: var(--t-sm); font-weight: 600; list-style: none; display: flex; justify-content: space-between; }
.toc-mobile summary::-webkit-details-marker { display: none; }
.toc-mobile summary::after { content: "+"; color: var(--gold-text); font-weight: 400; }
.toc-mobile[open] summary::after { content: "−"; }
.toc ol { list-style: none; margin: 0; padding: 0 14px 12px; counter-reset: toc; }
.toc li { counter-increment: toc; }
.toc a { display: grid; grid-template-columns: 1.7em 1fr; padding: 6px 0; color: var(--ink-soft); text-decoration: none; font-size: var(--t-sm); line-height: 1.35; }
.toc a::before { content: counter(toc); font-variant-numeric: tabular-nums; color: var(--gold-text); font-size: var(--t-xs); padding-top: 1px; }
.toc a:hover { color: var(--ink); }
.toc a[aria-current] { color: var(--ink); font-weight: 600; }
.toc-title { font-size: var(--t-xs); letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-soft); margin: 0 0 10px; }

.article { min-width: 0; padding-block: 8px 40px; }
.prose > section > * { max-width: var(--measure); }
.prose > section > p, .prose li.q p { margin: 0 0 1.1em; }
.prose h2 {
  font-family: var(--f-display); font-weight: 500; font-size: var(--t-h2); line-height: 1.15; letter-spacing: -0.01em;
  margin: 2.4em 0 0.7em; text-wrap: balance; color: var(--ink-navy); font-variation-settings: "opsz" 48;
  display: grid; grid-template-columns: auto 1fr; column-gap: 0.55em; align-items: baseline;
}
.prose h2 .sec-no { font-family: var(--f-figure); font-size: 0.42em; font-weight: 600; letter-spacing: 0.08em; color: var(--gold-text); transform: translateY(-0.25em); }
.prose h2:first-child { margin-top: 1.2em; }
.prose strong { font-weight: 650; color: var(--ink-navy); }
.prose em { font-style: italic; }
.prose .lede { font-family: var(--f-display); font-size: var(--t-lead); line-height: 1.55; color: var(--ink); font-variation-settings: "opsz" 24; }
.prose .lede::first-letter { float: left; font-size: 3.7em; line-height: 0.85; padding: 0.06em 0.1em 0 0; color: var(--ink-navy); font-weight: 500; }
.prose .standalone { font-family: var(--f-display); font-size: 1.45rem; line-height: 1.35; color: var(--ink-navy); margin: 1.2em 0; padding-left: 18px; border-left: 2px solid var(--gold); }
.prose .fiction-note { font-size: var(--t-sm); color: var(--ink-soft); font-style: italic; border-top: 1px solid var(--rule); padding-top: 10px; }
.prose ol.questions { list-style: none; padding: 0; margin: 1.2em 0 1.6em; display: grid; gap: 18px; counter-reset: q; }
.prose .q { padding: 0 0 18px 0; border-bottom: 1px solid var(--rule); }
.prose .q:last-child { border-bottom: 0; }
.prose .q p { margin: 0; }
.prose figure p, .prose .tool p { max-width: none; }
.prose .tool p.block-intro, .prose figure .caption { max-width: 44rem; }
.prose .tool p.help, .prose .tool p.error { margin: 0; }
.prose .results p { margin: 0; }
.prose .q p strong:first-child { display: block; font-family: var(--f-display); font-size: 1.2rem; font-weight: 600; margin-bottom: 4px; }

/* table (normalisation bridge) */
.table-wrap { overflow-x: auto; margin: 1.6em 0 2em; }
.data-table { width: 100%; border-collapse: collapse; font-size: var(--t-sm); line-height: 1.45; font-variant-numeric: tabular-nums lining-nums; }
.data-table caption { text-align: left; font-family: var(--f-display); font-size: 1.15rem; font-weight: 600; color: var(--ink-navy); padding-bottom: 10px; }
.data-table th, .data-table td { padding: 10px 8px; border-bottom: 1px solid var(--rule); vertical-align: top; text-align: left; }
.data-table thead th { font-size: var(--t-xs); text-transform: uppercase; letter-spacing: 0.1em; color: var(--ink-soft); font-weight: 600; border-bottom: 1px solid var(--ink-soft); }
.data-table td.amt, .data-table th.amt { text-align: right; white-space: nowrap; width: 6.5em; }
.data-table tr.total td, .data-table tr.total th { border-top: 2px solid var(--ink-navy); border-bottom: 0; font-weight: 700; color: var(--ink-navy); }
.data-table .neg { color: var(--brick); }
.data-table .pos { color: var(--teal-text); }

/* ---------- Figures & tools (shared) ---------- */
.block { margin: 2.2em 0 2.6em; }
.eyebrow { font-size: var(--t-xs); text-transform: uppercase; letter-spacing: 0.14em; color: var(--gold-text); margin: 0 0 6px; font-weight: 600; }
.block h3 { font-family: var(--f-display); font-size: var(--t-h3); font-weight: 600; margin: 0 0 6px; color: var(--ink-navy); line-height: 1.2; text-wrap: balance; }
.block-intro { margin: 0 0 18px; color: var(--ink-soft); font-size: var(--t-sm); max-width: 40rem; }
.caption, figcaption.caption { font-size: var(--t-sm); color: var(--ink-soft); line-height: 1.55; margin-top: 14px; max-width: 44rem; }
.caption strong { color: var(--ink); }

/* Visual 2: perspectives */
.persp { background: var(--white); border: 1px solid var(--rule); padding: clamp(16px, 3vw, 28px); }
.persp-axis-title { font-size: var(--t-xs); color: var(--ink-soft); margin: 0 0 6px; }
.persp-scale, .persp-track { position: relative; height: 26px; }
.persp-scale { margin-left: 0; border-bottom: 1px solid var(--ink-soft); }
.persp-scale span { position: absolute; bottom: 4px; transform: translateX(-50%); font-size: var(--t-xs); color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.persp-scale span:first-child { transform: none; }
.persp-scale span:last-child { transform: translateX(-100%); }
.persp-rows { list-style: none; margin: 0; padding: 0; }
.persp-row { padding: 16px 0 14px; border-bottom: 1px solid var(--rule); display: grid; gap: 8px; }
.persp-row:last-child { border-bottom: 0; }
.persp-who { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
.persp-who strong { font-family: var(--f-display); font-size: 1.15rem; color: var(--ink-navy); font-weight: 600; }
.persp-who .persp-val { font-weight: 700; font-variant-numeric: tabular-nums; color: var(--ink-navy); }
.persp-how { font-size: var(--t-sm); color: var(--ink-soft); margin: 0; line-height: 1.5; }
.persp-track { height: 22px; background: linear-gradient(to right, var(--rule) 1px, transparent 1px) 0 0 / calc(100% / 6) 100% repeat-x; border-right: 1px solid var(--rule); }
.persp-track::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: var(--rule); }
.mark { position: absolute; top: 50%; transform: translateY(-50%); z-index: 1; }
.mark--point { width: 16px; height: 16px; border-radius: 50%; background: var(--gold); margin-left: -8px; left: calc(var(--v) / 60 * 100%); }
.mark--range { height: 14px; border-radius: 2px; background: var(--teal); left: calc(var(--from) / 60 * 100%); width: calc((var(--to) - var(--from)) / 60 * 100%); }
.mark--solid { width: 14px; height: 14px; border-radius: 50%; background: var(--midnight); margin-left: -7px; left: calc(var(--v) / 60 * 100%); z-index: 2; }
.mark--ghost { height: 12px; border: 1.5px dashed var(--midnight); border-radius: 2px; background: var(--white); left: calc(var(--from) / 60 * 100%); width: calc((var(--to) - var(--from)) / 60 * 100%); }
.persp-flaw { font-size: var(--t-xs); color: var(--ink-soft); margin: 0; line-height: 1.5; }
.persp-flaw b { color: var(--ink); font-weight: 600; }

/* Visual 5: drivers */
.drivers { background: var(--white); border: 1px solid var(--rule); padding: clamp(16px, 3vw, 28px); }
.drivers-key { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; font-size: var(--t-xs); text-transform: uppercase; letter-spacing: 0.12em; font-weight: 600; margin-bottom: 14px; }
.drivers-key .k-left { color: var(--brick); text-align: right; }
.drivers-key .k-right { color: var(--teal-text); }
.drivers-key .k-mid { color: var(--ink-soft); width: 2px; height: 18px; background: var(--ink-soft); }
.drivers-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.driver { display: grid; grid-template-columns: 1fr 2px 1fr; gap: 0 14px; align-items: stretch; }
.driver::before { content: ""; grid-column: 2; grid-row: 1; background: var(--rule); }
.driver-card { grid-row: 1; padding: 12px 14px; border-radius: var(--radius); font-size: var(--t-sm); line-height: 1.45; min-width: 0; }
.driver-card .driver-h { margin: 0 0 2px; font-size: var(--t-sm); font-weight: 700; color: var(--ink-navy); }
.driver-card p { margin: 0; color: var(--ink-soft); }
.driver-card .via { display: inline-block; margin-top: 6px; font-size: var(--t-xs); letter-spacing: 0.04em; color: var(--ink); font-weight: 600; }
.driver--weighs .driver-card { grid-column: 1; background: #F6ECE7; border-right: 3px solid var(--brick); text-align: right; }
.driver--supports .driver-card { grid-column: 3; background: #E6F2F2; border-left: 3px solid var(--teal); }
.driver--depends { grid-template-columns: 1fr; }
.driver--depends::before { display: none; }
.driver--depends .driver-card { grid-column: 1; background: var(--mist); border-top: 3px solid var(--slate); text-align: center; max-width: 30rem; margin: 0 auto; }
.tag-dir { display: none; }

/* ---------- Calculators ---------- */
.tool { background: var(--mist); border: 1px solid var(--rule-cool); border-radius: var(--radius); overflow: hidden; }
.tool-head { padding: clamp(18px, 3vw, 28px) clamp(16px, 3vw, 28px) 0; }
.tool-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0; }
.controls { padding: 10px clamp(16px, 3vw, 28px) 20px; display: grid; gap: 18px; margin: 0; }
.field { display: grid; gap: 6px; min-width: 0; }
.field-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.field label, .field .label { font-weight: 600; font-size: var(--t-sm); color: var(--ink-navy); }
.unit-input { display: inline-flex; align-items: stretch; border: 1px solid #9FB0BF; border-radius: var(--radius); background: var(--white); overflow: hidden; }
.unit-input:focus-within { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(8, 127, 140, 0.2); }
.unit-input .pre, .unit-input .post { display: inline-flex; align-items: center; padding: 0 9px; font-size: var(--t-xs); color: var(--ink-soft); background: #F4F7F9; }
.unit-input input { width: 6.2em; border: 0; padding: 8px 10px; font: 600 1rem/1.2 var(--f-figure); color: var(--ink); text-align: right; font-variant-numeric: tabular-nums; background: var(--white); min-width: 0; }
.unit-input input:focus { outline: none; }
.unit-input input[readonly] { background: #F4F7F9; color: var(--ink-soft); }
input[aria-invalid="true"] { background: #FBEDE8 !important; }
.unit-input:has(input[aria-invalid="true"]) { border-color: var(--brick); }
.help { margin: 0; font-size: var(--t-xs); color: var(--ink-soft); line-height: 1.45; }
.error { margin: 0; font-size: var(--t-xs); color: var(--brick); font-weight: 600; line-height: 1.45; }
input[type="range"] { -webkit-appearance: none; appearance: none; width: 100%; height: 28px; background: transparent; margin: 0; cursor: pointer; touch-action: pan-y; }
input[type="range"]::-webkit-slider-runnable-track { height: 4px; background: #B7C5D0; border-radius: 2px; }
input[type="range"]::-moz-range-track { height: 4px; background: #B7C5D0; border-radius: 2px; }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 22px; height: 22px; border-radius: 50%; background: var(--ink-navy); border: 3px solid var(--gold); margin-top: -9px; }
input[type="range"]::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--ink-navy); border: 3px solid var(--gold); }
input[type="range"]:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.range-scale { display: flex; justify-content: space-between; font-size: 0.75rem; color: var(--ink-soft); margin-top: -4px; font-variant-numeric: tabular-nums; }
.btn-row { display: flex; flex-wrap: wrap; gap: 8px; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 40px; padding: 0 14px; border-radius: var(--radius); font: 600 var(--t-xs)/1.2 var(--f-body); letter-spacing: 0.02em; cursor: pointer; border: 1px solid var(--ink-navy); background: transparent; color: var(--ink-navy); }
.btn:hover { background: var(--white); }
.btn-solid { background: var(--ink-navy); color: var(--on-dark); }
.btn-solid:hover { background: var(--midnight); }
.chip { min-height: 36px; border-color: #9FB0BF; background: var(--white); font-weight: 500; }
.chip:hover { border-color: var(--ink-navy); }
.checkline { display: flex; gap: 10px; align-items: flex-start; font-size: var(--t-sm); line-height: 1.4; }
.checkline { min-height: 32px; cursor: pointer; }
.checkline input { width: 24px; height: 24px; margin: 0; accent-color: var(--ink-navy); flex-shrink: 0; }

.results { background: var(--ink-navy); color: var(--on-dark); padding: clamp(18px, 3vw, 26px) clamp(16px, 3vw, 28px); display: grid; gap: 14px; align-content: start; transition: opacity .2s; }
.results.is-stale { opacity: 0.6; }
.kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 20px; margin: 0; }
.kpi { margin: 0; min-width: 0; }
.kpi dt { font-size: var(--t-xs); letter-spacing: 0.1em; text-transform: uppercase; color: var(--on-dark-soft); margin-bottom: 4px; }
.kpi dd { margin: 0; font-family: var(--f-figure); font-size: clamp(1.35rem, 1.1rem + 1vw, 1.8rem); font-weight: 650; font-variant-numeric: tabular-nums; line-height: 1.15; letter-spacing: -0.01em; overflow-wrap: anywhere; }
.kpi--accent dd { color: var(--gold); }
.kpi--sub dd { font-size: var(--t-sm); font-weight: 600; color: var(--on-dark); }
.results p { margin: 0; font-size: var(--t-sm); color: var(--on-dark-soft); line-height: 1.5; }
.results .data-table { color: var(--on-dark); }
.results .data-table caption { color: var(--on-dark); }
.results .data-table th, .results .data-table td { border-bottom-color: rgba(185, 200, 212, 0.28); }
.results .data-table thead th { color: var(--on-dark-soft); border-bottom-color: var(--on-dark-soft); }
.results .warn { background: rgba(156, 79, 54, 0.22); border-left: 3px solid #D98A6E; padding: 10px 12px; color: var(--on-dark); }
.results-label { font-size: var(--t-xs); text-transform: uppercase; letter-spacing: 0.14em; color: var(--gold); margin: 0; font-weight: 600; }

.chart-area { background: var(--white); border-top: 1px solid var(--rule-cool); padding: clamp(16px, 3vw, 24px) clamp(16px, 3vw, 28px); position: relative; }
.chart-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 20px; align-items: baseline; margin-bottom: 8px; }
.chart-head h4 { margin: 0; font-size: var(--t-sm); font-weight: 700; color: var(--ink-navy); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: var(--t-xs); color: var(--ink-soft); list-style: none; margin: 0; padding: 0; }
.legend li { display: inline-flex; align-items: center; gap: 6px; }
.sw { width: 12px; height: 12px; border-radius: 2px; display: inline-block; }
.sw-equity { background: var(--teal); } .sw-debt { background: var(--slate); }
.sw-line { width: 18px; height: 0; border-top: 2px dashed var(--gold); border-radius: 0; }
.sw-total { background: var(--ink-navy); } .sw-minus { background: var(--brick); } .sw-plus { background: var(--teal); } .sw-result { background: var(--gold); }
.chart-box { width: 100%; min-height: 300px; transition: opacity .2s; }
.chart-box--short { min-height: 0; }
.chart-box.is-stale { opacity: 0.4; }
.chart-box svg { display: block; width: 100%; height: auto; overflow: visible; font-family: var(--f-figure); }
.chart-note { font-size: var(--t-xs); color: var(--brick); margin: 4px 0 0; min-height: 1em; }
.chart .grid { stroke: #E4E9ED; stroke-width: 1; }
.chart .baseline { stroke: var(--ink-soft); stroke-width: 1; }
.chart .axis { fill: var(--ink-soft); font-size: 12px; font-variant-numeric: tabular-nums; }
.chart .axis-title { font-size: 11px; letter-spacing: 0.06em; }
.chart .val { fill: var(--ink); font-size: 13px; font-weight: 650; font-variant-numeric: tabular-nums; }
.chart .cat { fill: var(--ink-soft); font-size: 12.5px; }
.chart .cat-sub { font-size: 11px; fill: var(--gold-text); font-weight: 600; }
.chart .cat-strong { fill: var(--ink-navy); font-weight: 700; }
.chart .seg-equity { fill: var(--teal); }
.chart .seg-debt { fill: var(--slate); }
.chart .hit { fill: transparent; }
.chart .bar { cursor: pointer; outline: none; }
.chart .bar:hover .seg-equity, .chart .bar:focus .seg-equity { fill: #066A75; }
.chart .bar:focus-visible .hit { stroke: var(--gold); stroke-width: 2; }
.chart .sel-ring { fill: none; stroke: var(--gold); stroke-width: 2.5; }
.chart .bar.is-extra .seg-equity { fill: #3FA2AC; }
.chart .nd-line { stroke: var(--gold); stroke-width: 2; stroke-dasharray: 6 4; }
.chart .nd-label { fill: var(--gold-text); font-size: 12px; font-weight: 700; paint-order: stroke; stroke: var(--white); stroke-width: 4px; stroke-linejoin: round; }
.chart .val { paint-order: stroke; stroke: var(--white); stroke-width: 3px; stroke-linejoin: round; }
.chart .w-total { fill: var(--ink-navy); } .chart .w-minus { fill: var(--brick); } .chart .w-plus { fill: var(--teal); }
.chart .w-result { fill: var(--gold); } .chart .w-neg { fill: var(--brick); }
.chart .connector { stroke: var(--ink-soft); stroke-dasharray: 3 3; stroke-width: 1; }
.chart .a-up { fill: var(--teal); } .chart .a-down { fill: var(--brick); } .chart .a-total { fill: var(--ink-navy); }
.tip { position: absolute; transform: translate(-50%, -100%); background: var(--ink-navy); color: var(--on-dark); padding: 8px 10px; border-radius: var(--radius); font-size: var(--t-xs); line-height: 1.45; pointer-events: none; white-space: nowrap; z-index: 5; font-variant-numeric: tabular-nums; box-shadow: 0 6px 18px rgba(16, 36, 58, 0.25); }
.tip strong { color: var(--gold); display: block; }
details.as-table { margin-top: 10px; font-size: var(--t-sm); }
details.as-table summary { cursor: pointer; color: var(--teal-text); font-weight: 600; font-size: var(--t-xs); min-height: 32px; display: inline-flex; align-items: center; }
details.as-table table { margin-top: 10px; }
.persistent-note { margin: 0; padding: 14px clamp(16px, 3vw, 28px); border-top: 1px solid var(--rule-cool); font-size: var(--t-xs); color: var(--ink-soft); line-height: 1.55; background: var(--mist); }
.persistent-note strong { color: var(--ink); }
.noscript-note { margin: 0 clamp(16px, 3vw, 28px) 12px; padding: 10px 12px; background: #FFF7E6; border: 1px solid var(--gold); font-size: var(--t-xs); }

.compare { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; padding: 10px clamp(16px, 3vw, 28px) 20px; }
.compare fieldset { border: 1px solid var(--rule-cool); border-radius: var(--radius); background: var(--white); padding: 12px 14px 14px; margin: 0; display: grid; gap: 12px; min-width: 0; }
.compare legend { font-weight: 700; font-size: var(--t-sm); color: var(--ink-navy); padding: 0 6px; }
.compare fieldset.alt { border-color: var(--teal); }
.compare .field-row label { font-weight: 500; }
.ctable { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; font-size: var(--t-sm); color: var(--on-dark); }
.ctable th, .ctable td { padding: 8px 6px; text-align: right; border-bottom: 1px solid rgba(185, 200, 212, 0.18); white-space: nowrap; }
.ctable th:first-child { text-align: left; }
.ctable thead th { font-size: var(--t-xs); text-transform: uppercase; letter-spacing: 0.08em; color: var(--on-dark-soft); font-weight: 600; }
.ctable td.diff { color: var(--gold); font-weight: 650; }
.ctable-wrap { overflow-x: auto; }

/* glossary */
.glossary { border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); padding: 14px 0; }
.glossary h3 { font-size: 1.05rem; font-family: var(--f-body); font-weight: 700; letter-spacing: 0.02em; }
.glossary-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0; }
.glossary details { border-bottom: 1px dotted var(--rule); }
.glossary details:last-child { border-bottom: 0; }
.glossary summary { cursor: pointer; padding: 9px 0; font-weight: 600; font-size: var(--t-sm); color: var(--ink-navy); list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.glossary summary::-webkit-details-marker { display: none; }
.glossary summary::after { content: "+"; color: var(--gold-text); }
.glossary details[open] summary::after { content: "−"; }
.glossary details p { margin: 0 0 12px; font-size: var(--t-sm); color: var(--ink-soft); line-height: 1.6; }

/* ---------- Closing band (Visual 6) ---------- */
.closing-viz { background: var(--ink-navy); color: var(--on-dark); padding: clamp(28px, 5vw, 56px) clamp(18px, 4vw, 44px); border-radius: var(--radius); }
.cv-figure { text-align: center; }
.closing-viz p { margin: 0; max-width: none; }
.closing-viz .cv-number { margin-top: 6px; }
.chart--bridge.is-narrow .val { font-size: 11px; }
.cv-label { font-size: var(--t-xs); text-transform: uppercase; letter-spacing: 0.16em; color: var(--on-dark-soft); margin: 0 0 4px; }
.cv-number { font-family: var(--f-display); font-size: clamp(3rem, 2rem + 6vw, 6.2rem); line-height: 1; font-weight: 400; margin: 0; font-variant-numeric: lining-nums; letter-spacing: -0.02em; }
.cv-number small { font-size: 0.32em; color: var(--on-dark-soft); letter-spacing: 0; }
.cv-stem { width: 1px; height: 36px; background: var(--gold); margin: 16px auto 0; }
.cv-roots { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.cv-roots li { position: relative; padding: 14px 4px 12px; text-align: left; font-size: var(--t-sm); color: var(--on-dark-soft); line-height: 1.45; border-top: 1px solid rgba(196, 154, 69, 0.55); }
.cv-roots li b { display: block; color: var(--on-dark); font-family: var(--f-display); font-size: 1.1rem; font-weight: 600; margin-bottom: 2px; }
@media (min-width: 900px) {
  .cv-roots { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 0; border-top: 1px solid var(--gold); }
  .cv-roots li { border-top: 0; text-align: center; padding: 30px 8px 0; }
  .cv-roots li::before { content: ""; position: absolute; left: 50%; top: 0; width: 1px; height: 22px; background: rgba(196, 154, 69, 0.7); }
}
.closing-viz .cv-caption { text-align: center; margin: 28px auto 0; max-width: 34rem; font-family: var(--f-display); font-style: italic; font-size: 1.15rem; color: var(--on-dark); line-height: 1.5; }

/* ---------- After the article ---------- */
.endmatter { border-top: 1px solid var(--rule); margin-top: 40px; padding-top: 28px; display: grid; gap: 28px; }
.endmatter h2 { font-family: var(--f-display); font-size: 1.35rem; font-weight: 600; margin: 0 0 10px; color: var(--ink-navy); }
.endmatter p, .endmatter li { font-size: var(--t-sm); line-height: 1.6; color: var(--ink-soft); }
.endmatter ol, .endmatter ul { padding-left: 1.2em; margin: 0; display: grid; gap: 8px; }
.endmatter .verify { color: var(--gold-text); font-weight: 600; }
.cta { background: var(--white); border: 1px solid var(--rule); border-top: 3px solid var(--gold); padding: clamp(18px, 3vw, 28px); }
.cta h2 { font-size: 1.5rem; }
.cta p { color: var(--ink); font-size: var(--t-base); max-width: 40rem; }
.cta ul { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; list-style: none; margin: 14px 0 18px; }
.cta li { font-size: var(--t-xs); padding: 5px 10px; border: 1px solid var(--rule); border-radius: 999px; color: var(--ink); }
.config { display: inline-block; font-family: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; font-size: 0.8em; background: #FFF7E6; border: 1px dashed var(--gold); color: var(--gold-text); padding: 2px 6px; border-radius: 3px; }
.disclaimer { background: var(--mist); padding: 16px 18px; border-radius: var(--radius); }
.disclaimer p { margin: 0 0 8px; }
.disclaimer p:last-child { margin: 0; }

.site-footer { background: var(--ink-navy); color: var(--on-dark-soft); margin-top: 48px; }
.footer-inner { max-width: 1280px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter-r); padding-block: 32px calc(32px + env(safe-area-inset-bottom, 0px)); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px 32px; font-size: var(--t-xs); line-height: 1.6; }
.footer-inner strong { color: var(--on-dark); font-family: var(--f-display); font-size: 1rem; font-weight: 600; }
.footer-inner .config { background: rgba(196, 154, 69, 0.12); color: var(--gold); }

.toast { position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); background: var(--ink-navy); color: var(--on-dark); border: 1px solid var(--gold); padding: 10px 16px; border-radius: var(--radius); font-size: var(--t-sm); z-index: 80; max-width: calc(100vw - 32px); }

/* reveal (JS adds .is-pending only to blocks below the first screen) */
@media (prefers-reduced-motion: no-preference) {
  .reveal { transition: opacity .6s ease, transform .6s ease; }
  .reveal.is-pending { opacity: 0; transform: translateY(14px); }
}


/* ---------- Visual B: case file ---------- */
.dossier { background: var(--white); border: 1px solid var(--rule); border-top: 0; }
.dossier-tab { display: flex; justify-content: space-between; align-items: center; gap: 12px; background: var(--ink-navy); color: var(--on-dark); padding: 9px 16px; font-size: var(--t-xs); letter-spacing: 0.14em; text-transform: uppercase; font-weight: 600; }
.dossier-flag { color: var(--ink-navy); background: var(--gold); padding: 2px 8px; border-radius: 2px; letter-spacing: 0.1em; }
.dossier-name { font-family: var(--f-display); font-size: 1.35rem; font-weight: 600; color: var(--ink-navy); margin: 0; padding: 14px 16px 4px; }
.dossier-name span { font-family: var(--f-body); font-size: var(--t-xs); font-weight: 500; color: var(--ink-soft); letter-spacing: 0.04em; }
.dossier-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); margin: 0; padding: 4px 16px 6px; gap: 0 20px; }
.df { padding: 10px 0; border-bottom: 1px dotted var(--rule); min-width: 0; }
.df:first-child { grid-column: 1 / -1; }
.df dt { font-size: var(--t-xs); text-transform: uppercase; letter-spacing: 0.1em; color: var(--ink-soft); font-weight: 600; margin-bottom: 2px; }
.df dd { margin: 0; display: grid; gap: 1px; }
.df-main { font-variant-numeric: tabular-nums lining-nums; font-weight: 650; color: var(--ink); font-size: 1rem; line-height: 1.35; }
.df-sub { font-size: var(--t-sm); color: var(--ink-soft); line-height: 1.4; }
.dossier .caption { padding: 4px 16px 14px; margin: 0; }

/* ---------- Visual C/D: waterfalls ---------- */
.wf-box { width: 100%; min-height: 270px; }
.wf-box svg { display: block; width: 100%; height: auto; overflow: visible; font-family: var(--f-figure); }
.norm-fig { margin: 1.6em 0 2em; display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px 32px; align-items: center; }
.norm-fig .table-wrap { margin: 0; }
.norm-fig .caption { grid-column: 1 / -1; margin-top: 4px; }
.fcf-fig { background: var(--white); border: 1px solid var(--rule); padding: clamp(16px, 3vw, 28px); }
.fcf-fig h3 { font-family: var(--f-display); font-size: var(--t-h3); font-weight: 600; color: var(--ink-navy); margin: 0 0 10px; line-height: 1.2; text-wrap: balance; }
.recon-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px 28px; margin-top: 18px; }
.fcf-fig .table-wrap { margin: 0; }
.data-table.recon { font-size: var(--t-sm); }
.data-table.recon caption { font-size: 1rem; }
.chart .cat-base { font-size: 11px; fill: var(--ink-soft); font-weight: 600; letter-spacing: 0.04em; }
.chart--wf.is-narrow .val { font-size: 11.5px; }
.sw-ring { width: 12px; height: 12px; border: 2.5px solid var(--gold); border-radius: 2px; background: transparent; }

/* ---------- Visual G additions ---------- */
.mark--net { height: 12px; border-radius: 2px; background: rgba(8, 127, 140, 0.38); left: calc(var(--from) / 60 * 100%); width: calc((var(--to) - var(--from)) / 60 * 100%); z-index: 1; }
.persp-key, .mkey { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: var(--t-xs); color: var(--ink-soft); }
.persp-key li, .mkey li { display: inline-flex; align-items: center; gap: 6px; }
.k { display: inline-block; width: 14px; height: 10px; border-radius: 2px; }
.k-solid { width: 10px; height: 10px; border-radius: 50%; background: var(--midnight); }
.k-net { background: rgba(8, 127, 140, 0.38); }
.k-ghost { border: 1.5px dashed var(--midnight); background: var(--white); }

/* ---------- Visual H: minority interest ---------- */
.minority { background: var(--white); border: 1px solid var(--rule); padding: clamp(16px, 3vw, 28px); }
.minority h3 { font-family: var(--f-display); font-size: var(--t-h3); font-weight: 600; color: var(--ink-navy); margin: 0 0 14px; line-height: 1.2; }
.min-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 22px 36px; }
.min-sub { font-size: var(--t-xs); text-transform: uppercase; letter-spacing: 0.12em; color: var(--ink-soft); font-weight: 600; margin: 0 0 10px; }
.mrow { display: grid; gap: 6px; padding: 0 0 14px; margin-bottom: 14px; border-bottom: 1px solid var(--rule); }
.mrow-h { margin: 0; font-weight: 650; color: var(--ink-navy); font-size: var(--t-sm); }
.mbar { display: flex; height: 22px; background: var(--mist); border-radius: 2px; overflow: hidden; }
.seg { display: block; height: 100%; }
.seg-co { background: var(--midnight); }
.seg-fund { background: var(--teal); }
.seg-new { background: repeating-linear-gradient(135deg, var(--gold) 0 6px, #D9B970 6px 12px); }
.mrow-v { margin: 0; font-size: var(--t-sm); color: var(--ink-soft); line-height: 1.5; }
.mrow-v b { color: var(--ink); font-variant-numeric: tabular-nums; }
.k-co { background: var(--midnight); } .k-fund { background: var(--teal); } .k-new { background: var(--gold); }
.rights { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.rights li { display: grid; grid-template-columns: 4.6em minmax(0, 1fr); gap: 10px; align-items: start; padding-bottom: 10px; border-bottom: 1px dotted var(--rule); }
.rights li:last-child { border-bottom: 0; }
.rights p { margin: 0; font-size: var(--t-sm); line-height: 1.5; color: var(--ink-soft); }
.rights b { color: var(--ink); }
.src { display: inline-block; text-align: center; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; font-weight: 700; padding: 3px 0; border-radius: 2px; margin-top: 2px; }
.src-law { background: var(--ink-navy); color: var(--on-dark); }
.src-deal { background: #E6F2F2; color: var(--teal-text); }
.src-arts { background: var(--mist); color: var(--ink); }
.independence { margin: 0 0 18px; font-size: var(--t-sm); color: var(--ink); background: #FFF7E6; border-left: 3px solid var(--gold); padding: 8px 12px; max-width: 44rem; }
.controls--flush { padding-top: 0; }
.related ul { list-style: none; padding: 0; display: grid; gap: 6px; }

@media (min-width: 900px) {
  .norm-fig { grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); }
  .min-grid { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); }
  .recon-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dossier-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 520px) {
  .ctable, .ctable tbody, .ctable tr, .ctable th, .ctable td { display: block; width: 100%; }
  .ctable thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .ctable tr { padding: 8px 0 10px; border-bottom: 1px solid rgba(185, 200, 212, 0.25); }
  .ctable th[scope=row] { border: 0; padding: 0 0 6px; text-align: left; font-weight: 700; color: var(--gold); text-transform: uppercase; letter-spacing: 0.08em; font-size: var(--t-xs); }
  .ctable td { border: 0; padding: 3px 0; display: flex; justify-content: space-between; gap: 12px; text-align: right; white-space: normal; }
  .ctable td::before { content: attr(data-label); color: var(--on-dark-soft); text-align: left; font-weight: 500; }
}
@media (max-width: 420px) {
  .dossier-grid { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- Responsive ---------- */
@media (min-width: 640px) {
  .glossary-list { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 32px; }
  .compare { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 900px) {
  .tool-grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); }
  .tool-grid .controls { padding-bottom: 24px; }
  .endmatter { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .endmatter .span-all { grid-column: 1 / -1; }
}
@media (min-width: 1120px) {
  .layout { grid-template-columns: 220px minmax(0, 1fr); column-gap: 56px; }
  .toc-rail { display: block; position: relative; }
  .toc-rail .toc { position: sticky; top: calc(env(safe-area-inset-top, 0px) + var(--header-h) + 32px); padding-top: 40px; }
  .toc-rail .toc ol { padding: 0; }
  .toc-mobile { display: none; }
  .article { padding-top: 0; }
  .prose .wide { max-width: 52rem; }
}
@media (min-width: 1360px) {
  .prose .wide { max-width: 58rem; }
}
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: minmax(0, 1fr); }
  .hero-art { max-width: 520px; }
}
@media (max-width: 620px) {
  .wordmark-series { display: none; }
  .icon-btn .lbl { display: none; }
  .icon-btn { padding: 0 10px; }
  .wordmark-firm { font-size: 0.95rem; }
  .wordmark-firm .sp { letter-spacing: 0.18em; }
  .drivers-key { grid-template-columns: 1fr; text-align: left; }
  .drivers-key .k-left, .drivers-key .k-right { text-align: left; }
  .drivers-key .k-mid { display: none; }
  .driver { grid-template-columns: 1fr; }
  .driver::before { display: none; }
  .driver--weighs .driver-card, .driver--supports .driver-card { grid-column: 1; text-align: left; border-right: 0; border-left: 3px solid; }
  .driver--weighs .driver-card { border-left-color: var(--brick); }
  .driver--supports .driver-card { border-left-color: var(--teal); }
  .tag-dir { display: inline-block; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em; font-weight: 700; margin-bottom: 4px; }
  .driver--weighs .tag-dir { color: var(--brick); } .driver--supports .tag-dir { color: var(--teal-text); } .driver--depends .tag-dir { color: var(--ink-soft); }
  .driver--depends .driver-card { text-align: left; }
  .kpis { grid-template-columns: minmax(0, 1fr); }
  .prose .lede::first-letter { font-size: 3.1em; }
}
@media (max-width: 380px) {
  .unit-input input { width: 5.2em; }
}

/* ---------- Print ---------- */
@media print {
  @page { margin: 18mm 16mm; }
  body { background: #fff; color: #000; font-size: 10.5pt; line-height: 1.5; }
  body::before, .masthead, .toc-rail, .toc-mobile, .skip, .toast, .btn-row, .btn, input[type="range"], .range-scale, .chip, details.as-table summary, .copy-fallback, .noscript-note, .tip { display: none !important; }
  .hero { background: #fff !important; color: #000; }
  .hero-inner { display: block; padding: 0 0 12pt; }
  .hero h1 { color: #000; font-size: 26pt; }
  .dek, .byline, .byline strong { color: #333; }
  .series-tag { color: #000; }
  .hero-art { display: none; }
  .layout, .hero-inner, .footer-inner { padding: 0; max-width: none; }
  .prose > *, .prose .wide { max-width: none; }
  .reveal.is-pending { opacity: 1 !important; transform: none !important; }
  .chart-area, .results, .persp-row, .driver, .closing-viz, .cta, tr, .q, .dossier, .norm-fig, .fcf-fig, .minority, .mrow { break-inside: avoid; }
  .wf-box svg { max-height: 65mm; width: auto; max-width: 100%; margin: 0 auto; }
  .wf-box { min-height: 0; }
  .chart-box { min-height: 0; }
  .chart-box svg { max-height: 70mm; width: auto; max-width: 100%; margin: 0 auto; }
  .tool-grid { grid-template-columns: 1fr 1fr; }
  .prose h2 { break-after: avoid; margin-top: 1.6em; }
  .tool, .results, .closing-viz, .site-footer { background: #fff !important; color: #000 !important; border: 1px solid #999; }
  .results p, .kpi dt, .kpi dd, .ctable, .ctable th, .ctable td, .cv-roots li, .cv-roots li b, .cv-caption, .cv-label, .cv-number, .cv-number small { color: #000 !important; }
  .unit-input { border: 0; }
  .unit-input .pre, .unit-input .post { background: none; }
  .unit-input input { background: none; padding: 0 4px; }
  details.as-table > table, details.as-table[open] > table, details.as-table > *:not(summary) { display: table; }
  .glossary details > p { display: block; }
  .endmatter a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 8pt; word-break: break-all; color: #333; }
  .site-footer { margin-top: 16pt; }
}
