/* bavovniatko explorer. Every size is in rem, and the root font size grows with the viewport (15 px on phones and
   laptops, about 19 px at 2560 px wide, 22 px on 4K), so the whole layout scales instead of staying tiny on big
   screens. Breakpoints are in em (based on the browser's 16 px default). */

:root {
  --bg: #f4f3ee; --panel: #ffffff; --panel-2: #fafaf7; --ink: #1b2129; --muted: #5b6672; --line: #dedfd8;
  --accent: #0057b7; --accent-ink: #ffffff; --accent-soft: #e5eefa; --accent-2: #ffd500; --mark: #ffe680;
  --error: #a4161a; --code-bg: #eef0ea; --shadow: 0 1px 2px rgb(20 30 40 / 6%), 0 2px 8px rgb(20 30 40 / 5%);
  --ua: #0057b7; --ru: #c1121f; --ok: #2e8540; --warn: #d97706;
  --mono: ui-monospace, "JetBrains Mono", "Cascadia Code", Menlo, Consolas, monospace;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", sans-serif;
  --radius: .6rem; --gap: clamp(.75rem, 1.2vw, 1.5rem);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #11151a; --panel: #192028; --panel-2: #1d252e; --ink: #e4e8eb; --muted: #9aa6b0; --line: #2b343e;
    --accent: #6aa8ff; --accent-ink: #0b1a2c; --accent-soft: #1d3150; --accent-2: #ffd500; --mark: #6b5a12;
    --error: #ff8a8e; --code-bg: #222b35; --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 2px 10px rgb(0 0 0 / 25%);
    --ua: #6aa8ff; --ru: #ff6b72; --ok: #5cc479; --warn: #f0a33a;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { font-size: clamp(15px, 0.35vw + 10px, 22px); -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 1rem/1.55 var(--sans); min-height: 100vh;
       display: flex; flex-direction: column; }
a { color: var(--accent); text-underline-offset: .15em; }
code, pre { font-family: var(--mono); font-size: .9em; }
h1, h2, h3 { line-height: 1.25; }
button { font: inherit; color: inherit; background: var(--panel); border: 1px solid var(--line); border-radius: .4rem;
         padding: .3rem .75rem; cursor: pointer; transition: border-color .12s, background .12s; }
button:hover:not(:disabled) { border-color: var(--accent); }
button:disabled { opacity: .55; cursor: default; }
button.active { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
select, input[type=search] { font: inherit; color: var(--ink); background: var(--panel); border: 1px solid var(--line);
         border-radius: .4rem; padding: .35rem .6rem; max-width: 100%; }

/* --- header ------------------------------------------------------------------------------------------------ */
header {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: .5rem 1.5rem; flex-wrap: wrap;
  padding: .55rem var(--gap); background: color-mix(in srgb, var(--panel) 92%, transparent);
  backdrop-filter: blur(8px); border-bottom: .2rem solid var(--accent-2); box-shadow: var(--shadow);
}
a.brand { color: inherit; text-decoration: none; display: flex; align-items: baseline; gap: .6rem; flex-wrap: wrap; }
.brand .title { font-weight: 750; font-size: 1.2rem; letter-spacing: .01em; }
.brand .subtitle { color: var(--muted); font-size: .9rem; }
nav { display: flex; gap: .2rem; overflow-x: auto; scrollbar-width: none; }
nav::-webkit-scrollbar { display: none; }
nav a.tab { color: inherit; text-decoration: none; border-radius: .4rem; padding: .3rem .7rem; white-space: nowrap; font-size: .95rem; }
nav a.tab:hover { background: var(--code-bg); }
nav a.tab.active { background: var(--accent); color: var(--accent-ink); }
.status { margin-left: auto; color: var(--muted); font-size: .8rem; display: flex; align-items: center; gap: .5rem; white-space: nowrap; }
.status progress { width: 8rem; accent-color: var(--accent); }
.status.failed { color: var(--error); white-space: normal; }
@media (max-width: 56em) {
  header { gap: .35rem 1rem; padding-bottom: .35rem; }
  .brand .subtitle { display: none; }
  .status { order: 2; }
  nav { order: 3; flex-basis: 100%; margin: 0 calc(-1 * var(--gap)); padding: 0 var(--gap); }
}

/* --- page frame -------------------------------------------------------------------------------------------- */
main { flex: 1; width: 100%; max-width: 150rem; margin: 0 auto; padding: var(--gap); }
footer { width: 100%; max-width: 150rem; margin: 0 auto; padding: 1rem var(--gap) 1.5rem; color: var(--muted);
         font-size: .78rem; border-top: 1px solid var(--line); }
footer a { color: var(--muted); }

/* every page is centred in the frame and grows up to its own maximum width */
.page, .claim-page, .about, .chapters, .notebook, .map-page { margin-left: auto; margin-right: auto; }
.page { max-width: 110rem; }
.page h1, .chapter-body h1, .about h1 { font-size: 1.6rem; margin: .2rem 0 .4rem; letter-spacing: -.01em; }
.lede { color: var(--muted); max-width: 60rem; font-size: 1.02rem; margin-top: 0; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: .8rem 1.2rem;
         margin: 0 0 var(--gap); box-shadow: var(--shadow); min-width: 0; }
.panel h2 { font-size: 1.05rem; margin: .3rem 0 .6rem; }
.panel h3 { font-size: .85rem; margin: 1rem 0 .3rem; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.placeholder { color: var(--muted); padding: 1.5rem; }
.error { color: var(--error); padding: .7rem; white-space: pre-wrap; font-family: var(--mono); font-size: .85rem; }
.chip { display: inline-block; background: var(--code-bg); border-radius: 1rem; padding: .05rem .55rem; font-size: .8rem; margin-right: .25rem; }
.chip a { text-decoration: none; }
.badge { display: inline-block; border-radius: .3rem; padding: .05rem .45rem; font-size: .8rem; background: var(--code-bg); margin-right: .25rem; }
.badge.outcome { background: var(--accent-2); color: #1b2129; font-weight: 650; }
.badge.disputed, .badge.open { background: color-mix(in srgb, var(--ru) 18%, var(--panel)); color: var(--ru); }
.badge.explained { background: color-mix(in srgb, var(--ok) 18%, var(--panel)); color: var(--ok); }
.side { font-size: .8rem; margin-left: .35rem; }
.side.ua { color: var(--ua); } .side.ru { color: var(--ru); }
ul.plain { list-style: none; padding: 0; margin: 0 0 .6rem; }
ul.plain li { padding: .15rem 0; }
.filters { display: flex; gap: .6rem; align-items: center; margin: .8rem 0; flex-wrap: wrap; }
.filters input[type=search] { min-width: min(20rem, 100%); }
.filters select { max-width: min(36rem, 100%); }
.legend { display: flex; gap: .4rem 1rem; flex-wrap: wrap; font-size: .82rem; color: var(--muted); margin: .5rem 0; }
.legend i { display: inline-block; width: .7rem; height: .7rem; border-radius: 50%; margin-right: .35rem; vertical-align: -.05em; }
mark { background: var(--mark); color: inherit; border-radius: .15rem; padding: 0 .1em; }

/* collapsible side lists (examples, chapters): a <details> that is open on wide screens */
details.side-list > summary { cursor: pointer; font-weight: 650; list-style: none; padding: .1rem 0 .4rem; }
details.side-list > summary::-webkit-details-marker { display: none; }
details.side-list > summary::after { content: "▾"; float: right; color: var(--muted); }
details.side-list:not([open]) > summary::after { content: "▸"; }

/* --- notebook ---------------------------------------------------------------------------------------------- */
.notebook { display: grid; grid-template-columns: minmax(16rem, 21rem) minmax(0, 1fr); gap: var(--gap); align-items: start; }
.gallery { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: .7rem .9rem;
           box-shadow: var(--shadow); position: sticky; top: 4.5rem; max-height: calc(100vh - 6rem); overflow: auto; }
.gallery h3 { font-size: .72rem; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); margin: .9rem 0 .2rem; }
.gallery ul { list-style: none; margin: 0; padding: 0; }
.gallery .example { border: none; background: transparent; text-align: left; padding: .3rem .45rem; width: 100%;
                    border-radius: .35rem; font-size: .9rem; line-height: 1.35; }
.gallery .example:hover { background: var(--accent-soft); }
@media (max-width: 64em) {
  .notebook { grid-template-columns: 1fr; }
  .gallery { position: static; max-height: none; order: 2; }
  .work { order: 1; }
}

.editor { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.toolbar { display: flex; gap: .5rem; align-items: center; padding: .5rem .6rem; border-top: 1px solid var(--line); flex-wrap: wrap; background: var(--panel-2); }
.toolbar .run { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); font-weight: 600; }
.toolbar .hint { color: var(--muted); font-size: .8rem; margin-left: auto; }
.cm-host { min-height: 9rem; }
.cm-host .cm-editor { min-height: 9rem; max-height: 55vh; font-size: .92rem; background: var(--panel); color: var(--ink); }
.cm-host .cm-editor.cm-focused { outline: none; }
.cm-host .cm-scroller { font-family: var(--mono); line-height: 1.6; }
.cm-host .cm-gutters { background: var(--panel-2); color: var(--muted); border-right: 1px solid var(--line); }
.cm-host .cm-activeLine, .cm-host .cm-activeLineGutter { background: color-mix(in srgb, var(--accent) 7%, transparent); }
.cm-tooltip-autocomplete { font-family: var(--mono); font-size: .85rem; }

.results { margin-top: var(--gap); display: flex; flex-direction: column; gap: .8rem; }
.statement { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.statement-head { display: flex; gap: .8rem; align-items: center; padding: .4rem .7rem; border-bottom: 1px solid var(--line); font-size: .85rem; background: var(--panel-2); }
.statement-head .label { font-weight: 650; }
.statement-head .rows { color: var(--muted); }
.statement-head .modes { margin-left: auto; display: flex; gap: .25rem; }
.statement-head .modes button { padding: .05rem .55rem; font-size: .78rem; }
.timing { color: var(--muted); font-size: .78rem; text-align: right; }

.table-wrap { overflow: auto; max-height: 72vh; }
table { border-collapse: collapse; width: 100%; font-size: .85rem; }
th { position: sticky; top: 0; background: var(--panel-2); text-align: left; font-weight: 650; padding: .4rem .6rem;
     border-bottom: 1px solid var(--line); white-space: nowrap; color: var(--muted); font-size: .78rem;
     text-transform: uppercase; letter-spacing: .04em; }
td { padding: .4rem .6rem; border-bottom: 1px solid var(--line); vertical-align: top; max-width: 42rem; }
tbody tr:hover td { background: color-mix(in srgb, var(--accent) 4%, transparent); }
td .num, td.num { font-variant-numeric: tabular-nums; }
td .null { color: var(--muted); }
.list { display: flex; flex-wrap: wrap; gap: .1rem .5rem; }
.list.block { flex-direction: column; gap: .35rem; }
.obj { display: inline-flex; flex-wrap: wrap; align-items: baseline; gap: .1rem .6rem; }
.obj .k { color: var(--muted); font-size: .72rem; }
td .compact { font-size: .8rem; color: var(--muted); word-break: break-word; }
td .geo { color: var(--muted); font-style: italic; }
td .sources-cell { display: flex; flex-direction: column; gap: .15rem; min-width: 14rem; }
td .sources-cell a { font-size: .82rem; line-height: 1.3; }
a.rid { font-family: var(--mono); font-size: .8rem; text-decoration: none; white-space: nowrap; }
a.rid:hover { text-decoration: underline; }
a.rid.named { font-family: var(--sans); font-size: inherit; white-space: normal; }
.more { margin: .6rem; }
/* phones: result rows become cards of label/value pairs; empty cells are left out */
@media (max-width: 40em) {
  .results thead { display: none; }
  .results table, .results tbody, .results tr, .results td { display: block; width: 100%; max-width: none; }
  .results tr { padding: .5rem .7rem; border-bottom: 1px solid var(--line); }
  .results td { display: grid; grid-template-columns: 5.5rem minmax(0, 1fr); gap: .5rem; padding: .12rem 0; border: none; }
  .results td::before { content: attr(data-label); color: var(--muted); font-size: .75rem; text-transform: uppercase;
                        letter-spacing: .04em; padding-top: .15rem; overflow: hidden; text-overflow: ellipsis; }
  .results td:has(> .null), .results td:has(> .list:empty), .results td:empty { display: none; }
  .results tbody tr:hover td { background: none; }
}
pre.json { margin: 0; padding: .8rem 1rem; overflow: auto; max-height: 72vh; font-size: .82rem; background: var(--panel); }
table.obs { width: auto; min-width: min(100%, 36rem); margin-top: .5rem; }
.page > table.obs { width: 100%; }

/* --- claim page -------------------------------------------------------------------------------------------- */
.claim-page { max-width: 120rem; }
.claim-head { background: var(--panel); border: 1px solid var(--line); border-left: .3rem solid var(--accent);
              border-radius: var(--radius); padding: 1rem 1.4rem; margin-bottom: var(--gap); box-shadow: var(--shadow); }
.claim-text { font-size: clamp(1.15rem, 1rem + .5vw, 1.55rem); line-height: 1.4; margin: .5rem 0; max-width: 70rem; font-weight: 450; }
.claim-head .when { color: var(--muted); font-size: .85rem; margin-left: .35rem; }
.claim-head .note { color: var(--muted); font-style: italic; max-width: 70rem; }
.claim-head .meta { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; font-size: .82rem; color: var(--muted); }
.rid-label { font-family: var(--mono); }
.claim-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 26rem), 1fr)); gap: var(--gap); align-items: start; }
.claim-grid .panel { margin: 0; }
.record-title { font-size: clamp(1.25rem, 1.05rem + .6vw, 1.75rem); margin: .4rem 0; font-weight: 600; }
dl.fields { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: .35rem .9rem; margin: 0; }
dl.fields dt { color: var(--muted); font-size: .8rem; padding-top: .1rem; }
dl.fields dd { margin: 0; overflow-wrap: anywhere; }
@media (min-width: 30em) { ul.history.compact li { grid-template-columns: 5.5rem minmax(0, 1fr); } }
ul.counters li { padding: .45rem 0; border-bottom: 1px solid var(--line); }
ul.counters li:last-child { border-bottom: none; }
ul.counters p { margin: .2rem 0 0; }
.claim-relations { margin-top: var(--gap); }
.relations-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: var(--gap); align-items: start; }
@media (max-width: 70em) { .relations-layout { grid-template-columns: 1fr; } }
ol.sources { padding-left: 1.3rem; margin: 0; }
ol.sources li { margin-bottom: .7rem; }
blockquote { margin: .3rem 0 0; padding-left: .7rem; border-left: .2rem solid var(--line); color: var(--muted); font-size: .85rem; }
.rel.high { color: var(--ok); } .rel.low { color: var(--ru); }
svg.ego { width: 100%; max-width: 36rem; height: auto; display: block; margin: 0 auto; }
.ego-center { fill: var(--accent-2); stroke: var(--ink); stroke-width: 1.5; }
svg.ego .node { stroke: var(--panel); stroke-width: 1.5; cursor: pointer; transition: r .1s; }
svg.ego .node:hover { stroke: var(--ink); r: 12; }
ul.rel-list { list-style: none; padding: 0; margin: 0; }
ul.rel-list li { border-left: .25rem solid var(--line); padding: .35rem .7rem; margin: .4rem 0; background: var(--panel-2); border-radius: 0 .35rem .35rem 0; }
ul.rel-list a { color: inherit; text-decoration: none; }
ul.rel-list a:hover { color: var(--accent); }
.resolution { font-size: .85rem; margin-top: .25rem; }

/* --- disputes ---------------------------------------------------------------------------------------------- */
.disputes { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 44rem), 1fr)); gap: .8rem; }
.dispute { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: .8rem 1rem; box-shadow: var(--shadow); }
.dispute-head { display: flex; gap: .4rem; align-items: center; margin-bottom: .5rem; flex-wrap: wrap; }
.dispute .strength { font-weight: 750; color: var(--ru); margin-right: .25rem; font-variant-numeric: tabular-nums; }
.sides { display: grid; grid-template-columns: 1fr auto 1fr; gap: .8rem; align-items: start; }
@media (max-width: 40em) { .sides { grid-template-columns: 1fr; } .versus { padding: 0; } }
.sides .side { font-size: .92rem; margin: 0; }
.sides .side a { color: inherit; text-decoration: none; }
.sides .side a:hover { color: var(--accent); }
.versus { color: var(--ru); font-weight: 750; padding-top: .1rem; font-size: .85rem; }

/* --- map --------------------------------------------------------------------------------------------------- */
.map-page { display: flex; flex-direction: column; gap: .6rem; height: calc(100vh - 7.5rem); min-height: 32rem; }
.map-controls { display: flex; gap: .6rem 1.4rem; align-items: center; flex-wrap: wrap; font-size: .88rem; }
.map-controls label { display: flex; align-items: center; gap: .4rem; }
.map-controls input[type=range] { width: clamp(8rem, 18vw, 22rem); accent-color: var(--accent); }
.map-body { display: grid; grid-template-columns: minmax(0, 1fr) clamp(20rem, 26vw, 34rem); gap: var(--gap); flex: 1; min-height: 0; }
.map { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; min-height: 20rem; box-shadow: var(--shadow); }
.map-side { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: .8rem 1rem; overflow: auto; box-shadow: var(--shadow); }
.map-side h2 { font-size: 1.1rem; margin: .2rem 0; text-transform: capitalize; }
@media (max-width: 56em) {
  .map-page { height: auto; }
  .map-body { grid-template-columns: 1fr; }
  .map { height: 62vh; }
  .map-side { max-height: none; }
}
ul.history { list-style: none; padding: 0; margin: 0; }
ul.history li { padding: .4rem 0; border-bottom: 1px solid var(--line); font-size: .9rem; display: grid;
                grid-template-columns: 7.5rem minmax(0, 1fr); gap: .6rem; }
ul.history li > :nth-child(n+3) { grid-column: 2; }
ul.history .when { color: var(--muted); font-size: .8rem; padding-top: .1rem; font-variant-numeric: tabular-nums; }
ul.history a { color: inherit; text-decoration: none; }
ul.history a:hover { color: var(--accent); }
ul.history li.outcome { background: color-mix(in srgb, var(--accent-2) 20%, transparent); border-radius: .3rem; padding-left: .3rem; }
@media (max-width: 30em) { ul.history li { grid-template-columns: 1fr; gap: .1rem; } ul.history li > * { grid-column: 1 !important; } }

/* --- arms race --------------------------------------------------------------------------------------------- */
.lane-filter { display: flex; flex-wrap: wrap; gap: .3rem; margin: .6rem 0; }
.lane-filter button { font-size: .78rem; padding: .1rem .55rem; border-radius: 1rem; }
.timeline-wrap { overflow-x: auto; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
svg.timeline { display: block; width: 100%; min-width: 62rem; height: auto; }
svg.timeline .year { font-size: 11px; fill: var(--muted); }
svg.timeline .year-line { stroke: var(--line); }
svg.timeline .lane { font-size: 11.5px; fill: var(--ink); font-weight: 650; }
svg.timeline .bar { fill: var(--accent); opacity: .75; cursor: pointer; }
svg.timeline .bar.lag { fill: var(--warn); }
svg.timeline .bar:hover { opacity: 1; stroke: var(--ink); }
.selected h2 a { text-decoration: none; }

/* --- numbers ----------------------------------------------------------------------------------------------- */
.chart-wrap { overflow-x: auto; }
svg.chart { display: block; width: 100%; min-width: 34rem; height: auto; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
svg.chart .grid { stroke: var(--line); }
svg.chart .tick { font-size: 11px; fill: var(--muted); }
svg.chart .pt { cursor: pointer; }
svg.chart .pt:hover circle { stroke: var(--ink); stroke-width: 1.5; }

/* --- chapters ---------------------------------------------------------------------------------------------- */
.chapters { display: grid; grid-template-columns: minmax(17rem, 23rem) minmax(0, 1fr); gap: var(--gap); align-items: start; }
.chapter-list { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: .7rem .9rem;
                position: sticky; top: 4.5rem; max-height: calc(100vh - 6rem); overflow: auto; box-shadow: var(--shadow); }
.chapter-list ol { list-style: none; padding: 0; margin: 0; }
.chapter-list li { padding: .35rem .5rem; border-radius: .4rem; }
.chapter-list li:hover { background: var(--code-bg); }
.chapter-list li.active { background: var(--accent-soft); }
.chapter-list a { color: inherit; text-decoration: none; display: block; line-height: 1.35; }
.chapter-list .code { font-family: var(--mono); font-size: .78rem; color: var(--muted); margin-right: .35rem; }
.chapter-body { min-width: 0; max-width: 110rem; }
.chapter-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 36rem), 1fr)); gap: var(--gap); align-items: start; }
@media (max-width: 64em) {
  .chapters { grid-template-columns: 1fr; }
  .chapter-list { position: static; max-height: none; }
}

/* --- search ----------------------------------------------------------------------------------------------- */
.search-page { max-width: 70rem; }
.search-bar { display: flex; gap: .5rem; align-items: center; margin: .8rem 0; }
.search-bar input { flex: 1; font: inherit; color: var(--ink); background: var(--panel); border: 1px solid var(--line);
                    border-radius: .4rem; padding: .5rem .8rem; min-width: 0; }
.search-bar input:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
.search-bar .go { background: var(--accent); color: var(--accent-ink); text-decoration: none; border-radius: .4rem;
                  padding: .5rem 1rem; }
ul.hits { list-style: none; padding: 0; margin: 0; }
.hit { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: .7rem 1rem;
       margin-bottom: .7rem; box-shadow: var(--shadow); }
.hit-head { display: flex; gap: .6rem; align-items: baseline; flex-wrap: wrap; }
.hit-text { margin: .3rem 0; line-height: 1.45; }
.hit-sources { display: flex; flex-wrap: wrap; gap: .2rem .7rem; font-size: .78rem; }
ul.examples { display: flex; flex-wrap: wrap; gap: .4rem; }
ul.examples button { font-size: .85rem; border-radius: 1rem; padding: .15rem .7rem; }

/* --- questions -------------------------------------------------------------------------------------------- */
ul.questions { list-style: none; padding: 0; margin: .6rem 0 0; }
.question { background: var(--panel); border: 1px solid var(--line); border-left: .25rem solid var(--warn);
            border-radius: 0 var(--radius) var(--radius) 0; padding: .7rem 1rem; margin-bottom: .6rem; box-shadow: var(--shadow); }
.question .q-head { display: flex; gap: .4rem; align-items: center; flex-wrap: wrap; margin-bottom: .3rem; }
.chip.era { color: var(--muted); }
.question .q-text { margin: .2rem 0 .4rem; line-height: 1.5; }
.question .bullet { color: var(--muted); }
.question .src { font-size: .78rem; white-space: nowrap; }
.question .src a { color: var(--muted); text-decoration: none; border-bottom: 1px dotted var(--line); }
.question .src a:hover { color: var(--accent); border-bottom-color: var(--accent); }
.filters label.check { display: flex; align-items: center; gap: .3rem; color: var(--muted); font-size: .88rem; }

/* --- claim graph ------------------------------------------------------------------------------------------ */
.graph-page { max-width: 130rem; }
.graph-head { display: flex; gap: .5rem 1.5rem; align-items: baseline; flex-wrap: wrap; }
.graph-head h1 { margin-bottom: 0; }
.graph-head .filters { margin: .2rem 0; }
a.steps { display: inline-block; min-width: 1.9rem; text-align: center; padding: .3rem .5rem; border-radius: .4rem;
          border: 1px solid var(--line); background: var(--panel); text-decoration: none; font-variant-numeric: tabular-nums; }
a.steps.active { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.graph-links { display: flex; gap: .4rem 1rem; flex-wrap: wrap; margin: .5rem 0; font-size: .88rem; }
.graph-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(18rem, 28rem); gap: var(--gap); align-items: start; }
@media (max-width: 70em) { .graph-body { grid-template-columns: 1fr; } }
.graph-wrap { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
              padding: .6rem; box-shadow: var(--shadow); min-width: 0; }
svg.graph { display: block; width: 100%; height: auto; }
svg.graph .gnode { cursor: pointer; }
svg.graph a:hover .gnode { stroke: var(--ink); }
svg.graph .gedge line { transition: stroke-opacity .12s; }
svg.graph a:hover + line, svg.graph .gedge:hover line { stroke-opacity: 1; }
.graph-side { max-height: 84vh; overflow: auto; }
.graph-side .rel-list li { font-size: .85rem; }
.seed-list li { padding: .25rem 0; }
.seed-list code { font-size: .85rem; }

/* --- front page ------------------------------------------------------------------------------------------- */
.home { max-width: 100rem; }
.home-head { margin-bottom: var(--gap); }
.home-head h1 { font-size: clamp(1.8rem, 1.4rem + 1.4vw, 2.6rem); margin: 0 0 .3rem; letter-spacing: -.02em; }
.home-search { display: flex; gap: .5rem; max-width: 44rem; margin-top: .9rem; }
.home-search input { flex: 1; font: inherit; padding: .55rem .9rem; border: 1px solid var(--line); border-radius: .4rem;
                     background: var(--panel); color: var(--ink); min-width: 0; }
.home-search input:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
.home-search .go { background: var(--accent); color: var(--accent-ink); text-decoration: none; padding: .55rem 1.1rem;
                   border-radius: .4rem; font-weight: 600; }
.figures { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 11rem), 1fr)); gap: .7rem;
           margin-bottom: var(--gap); }
a.figure { display: flex; flex-direction: column; gap: .1rem; background: var(--panel); border: 1px solid var(--line);
           border-radius: var(--radius); padding: .7rem .9rem; text-decoration: none; color: inherit; box-shadow: var(--shadow); }
a.figure:hover { border-color: var(--accent); }
a.figure .n { font-size: 1.6rem; font-weight: 750; line-height: 1.1; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
a.figure .l { font-weight: 600; font-size: .9rem; }
a.figure .note { color: var(--muted); font-size: .78rem; }
.home-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 32rem), 1fr)); gap: var(--gap);
            align-items: start; }
.home-cols .panel { margin: 0; }
ul.routes li { padding: .3rem 0; }
ul.routes a { font-weight: 600; text-decoration: none; }
ul.routes a:hover { text-decoration: underline; }
.mini-dispute { padding: .3rem 0; border-bottom: 1px solid var(--line); font-size: .88rem; }
.mini-dispute:last-child { border-bottom: none; }
.mini-dispute a { color: inherit; text-decoration: none; }
.mini-dispute a:hover { color: var(--accent); }
.mini-dispute .vs { color: var(--ru); font-weight: 700; font-size: .78rem; margin: 0 .35rem; }
ol.eras { list-style: none; padding: 0; margin: 0; display: grid;
          grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr)); gap: .5rem 1.5rem; }
ol.eras li { border-left: .2rem solid var(--accent-2); padding-left: .6rem; font-size: .9rem; }
ol.eras .code { margin-right: .4rem; font-size: .8rem; }
ol.eras strong { margin-right: .4rem; }
ul.topics { columns: 2; column-gap: 2rem; }
@media (max-width: 40em) { ul.topics { columns: 1; } }
ul.topics li { break-inside: avoid; }

/* --- about ------------------------------------------------------------------------------------------------- */
.about { max-width: 64rem; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
         padding: .6rem clamp(1rem, 3vw, 2rem) 1.4rem; box-shadow: var(--shadow); line-height: 1.6; }
.about h2 { font-size: 1.1rem; margin-top: 1.5rem; }
.about li { margin-bottom: .4rem; }
