/* Tarixim. Phone first (ADR 0003), after the phone drafts E, G, I, K, M2, O2 on the design canvas.
   Palette Bitik; IBM Plex Sans Arabic for Uyghur, Inter for Latin text, Literata for headings. */
@font-face { font-family: "Plex Arabic"; font-weight: 400; font-display: swap; src: url(/fonts/IBMPlexSansArabic-Regular.woff2) format("woff2"); unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF, U+200C-200F; }
@font-face { font-family: "Plex Arabic"; font-weight: 600; font-display: swap; src: url(/fonts/IBMPlexSansArabic-SemiBold.woff2) format("woff2"); unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF, U+200C-200F; }
@font-face { font-family: "Plex Arabic"; font-weight: 700; font-display: swap; src: url(/fonts/IBMPlexSansArabic-Bold.woff2) format("woff2"); unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF, U+200C-200F; }
@font-face { font-family: Inter; font-weight: 400; font-display: swap; src: url(/fonts/inter-latin-400.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: Inter; font-weight: 400; font-display: swap; src: url(/fonts/inter-latin-ext-400.woff2) format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, 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: Inter; font-weight: 600; font-display: swap; src: url(/fonts/inter-latin-600.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: Inter; font-weight: 600; font-display: swap; src: url(/fonts/inter-latin-ext-600.woff2) format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, 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: Inter; font-weight: 700; font-display: swap; src: url(/fonts/inter-latin-700.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: Inter; font-weight: 700; font-display: swap; src: url(/fonts/inter-latin-ext-700.woff2) format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, 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: Literata; font-weight: 500; font-display: swap; src: url(/fonts/literata-latin-500.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: Literata; font-weight: 500; font-display: swap; src: url(/fonts/literata-latin-ext-500.woff2) format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, 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: Literata; font-weight: 700; font-display: swap; src: url(/fonts/literata-latin-700.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: Literata; font-weight: 700; font-display: swap; src: url(/fonts/literata-latin-ext-700.woff2) format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --page: #F7F2E9; --paper: #F3ECE0; --card: #FFFDF8; --panel: #EADFCB; --ink: #2A211C; --accent: #2F6A5C;
  --line: #D8CCB8; --muted: #5A4E45; --kicker: #5E4630; --dashed: #BFAF98; --band1: #DCE7E1; --band2: #C6D9D0; --band3: #A9C7BA;
  --inv: #2A211C; --inv-fg: #FFFDF8; --inv-k: #9FD0C2; --inv-sub: #D9CFC0; --cur-fg: #FFFDF8;
  --sans: "Plex Arabic", Inter, system-ui, -apple-system, "Segoe UI", "PingFang SC", "Noto Sans SC", sans-serif;
  --serif: "Plex Arabic", Literata, Georgia, "Songti SC", serif;
  color-scheme: light;
}
/* Theme: follows the system unless the reader picked one in settings (data-theme on <html>, set by prefs.js). */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --page: #1B1512; --paper: #2A211C; --card: #241C18; --panel: #2F2620; --ink: #EFE6D8; --accent: #5FA594;
    --line: #3D332B; --muted: #B5A693; --kicker: #CDB79C; --dashed: #5A4E45; --band1: #22332D; --band2: #2B4239; --band3: #36564A;
    --inv: #EFE6D8; --inv-fg: #1B1512; --inv-k: #2F6A5C; --inv-sub: #4A3F36; --cur-fg: #1B1512; color-scheme: dark; }
}
:root[data-theme="dark"] { --page: #1B1512; --paper: #2A211C; --card: #241C18; --panel: #2F2620; --ink: #EFE6D8; --accent: #5FA594;
    --line: #3D332B; --muted: #B5A693; --kicker: #CDB79C; --dashed: #5A4E45; --band1: #22332D; --band2: #2B4239; --band3: #36564A;
    --inv: #EFE6D8; --inv-fg: #1B1512; --inv-k: #2F6A5C; --inv-sub: #4A3F36; --cur-fg: #1B1512; color-scheme: dark; }
:root[data-size="xs"] { font-size: 87.5%; }
:root[data-size="s"] { font-size: 93.75%; }
:root[data-size="large"] { font-size: 112.5%; }
:root[data-size="larger"] { font-size: 125%; }
:root[data-size="largest"] { font-size: 137.5%; }

/* Extra tokens from the drafts: tags, soft fills, timeline dots. */
:root { --tag: #DCE7E1; --tag-ink: #234F44; --soft: #EFE7DA; --dot-muted: #8C7A68; --done: #DCE7E1; --done-line: #C6D9D0; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --tag: #22332D; --tag-ink: #9FD0C2; --soft: #2A221D; --dot-muted: #8C7A68; --done: #22332D; --done-line: #2B4239; } }
:root[data-theme="dark"] { --tag: #22332D; --tag-ink: #9FD0C2; --soft: #2A221D; --dot-muted: #8C7A68; --done: #22332D; --done-line: #2B4239; }

/* ---------- base ---------- */
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 80px; }
body { margin: 0; background: var(--page); color: var(--ink); font: 1rem/1.6 var(--sans); overflow-wrap: anywhere; }
body.has-bar { padding-bottom: 84px; }
body.has-cta { padding-bottom: 92px; }
:lang(ug) { line-height: 1.8; }
a { color: var(--accent); }
main { max-width: 1200px; margin: 0 auto; padding: 16px 16px 40px; display: flex; flex-direction: column; gap: 20px; }
main:focus { outline: none; }
footer { max-width: 1200px; margin: 0 auto; padding: 8px 16px 24px; border-top: 1px solid var(--line); }
h1, h2, h3 { font-family: var(--serif); line-height: 1.15; margin: 0; }
h1 { font-size: 1.9rem; }
h2 { font-size: 1.35rem; }
p { margin: 0; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; inset-inline-start: 8px; top: -60px; z-index: 10; padding: 10px 14px; border-radius: 8px; background: var(--inv); color: var(--inv-fg); }
.skip:focus { top: 8px; }
.lbl { font-family: var(--sans); font-size: .75rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
:lang(ug) .lbl, :lang(zh-Hans) .lbl { letter-spacing: 0; font-size: .8rem; }
.note { font-size: .8rem; color: var(--muted); }
.i { flex: none; }
a:focus-visible, button:focus-visible, input:focus-visible, summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

/* ---------- header ---------- */
.top { position: sticky; top: 0; z-index: 4; background: var(--page); border-bottom: 1px solid var(--line); }
.top .wrap { max-width: 1200px; margin: 0 auto; padding: 8px 12px 8px 16px; display: flex; align-items: center; gap: 8px; }
.brand { display: flex; align-items: center; gap: 10px; min-height: 44px; text-decoration: none; color: var(--ink); margin-inline-end: auto; }
/* Square mark 6f beside the wordmark (ADR 0003). Its colours follow the theme. */
.brand { direction: rtl; }
.brand .logo { width: 36px; height: 36px; flex: none; }
.brand .lg-frame { fill: #2A211C; } .brand .lg-ground { fill: #F3ECE0; } .brand .lg-turk { fill: #2A211C; }
.brand .lg-uyg { fill: #2F6A5C; } .brand .lg-letter { fill: #F3ECE0; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .brand .lg-frame { fill: #000; }
  :root:not([data-theme="light"]) .brand .lg-ground { fill: #241C18; }
  :root:not([data-theme="light"]) .brand .lg-turk { fill: #EFE6D8; }
  :root:not([data-theme="light"]) .brand .lg-uyg { fill: #5FA594; }
  :root:not([data-theme="light"]) .brand .lg-letter { fill: #1B1512; }
}
:root[data-theme="dark"] .brand .lg-frame { fill: #000; }
:root[data-theme="dark"] .brand .lg-ground { fill: #241C18; }
:root[data-theme="dark"] .brand .lg-turk { fill: #EFE6D8; }
:root[data-theme="dark"] .brand .lg-uyg { fill: #5FA594; }
:root[data-theme="dark"] .brand .lg-letter { fill: #1B1512; }
.wm { font-family: "Plex Arabic", sans-serif; font-size: 28px; font-weight: 700; line-height: 1.2; }
.btn-out { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 44px; height: 44px; padding: 0 12px; border: 1px solid var(--accent);
  border-radius: 10px; background: var(--card); color: var(--accent); text-decoration: none; font-weight: 600; font-size: .94rem; }
.top.inner { display: flex; align-items: center; gap: 10px; padding: 10px 16px; }
body.is-inner .top.main { display: none; }
.ibtn { flex: none; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); color: var(--ink);
  display: inline-flex; align-items: center; justify-content: center; text-decoration: none; font: inherit; font-size: 20px; cursor: pointer; }
.ibtn.ghost { border: 0; background: none; margin-inline-start: -10px; }
[dir="rtl"] .back .i { transform: scaleX(-1); }
.crumb { flex: 1; min-width: 0; font-size: .875rem; color: var(--muted); }
.crumb .two { display: flex; flex-direction: column; line-height: 1.3; }
.crumb .k { font-size: .75rem; }
.crumb .ttl { font-weight: 600; font-size: .95rem; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crumbs { display: none; }

/* ---------- hero (drafts H, M, J) ---------- */
.hero { display: flex; flex-direction: column; gap: 16px; }
.hero-text { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tag { background: var(--tag); color: var(--tag-ink); border-radius: 999px; padding: 4px 12px; font-size: .8rem; font-weight: 600; }
.tag.soft { background: var(--soft); color: var(--muted); font-weight: 400; }
.alt { font-size: 1rem; color: var(--muted); }
.alt.ug { font-family: "Plex Arabic", sans-serif; font-size: 1.35rem; font-weight: 700; color: var(--ink); align-self: flex-start; }
[dir="rtl"] .alt[dir="ltr"] { align-self: flex-end; }
.meta { font-size: .94rem; color: var(--muted); }
.badge { background: var(--soft); border-radius: 6px; padding: 2px 8px; font-size: .8rem; }
.lead { font-size: 1.12rem; line-height: 1.5; max-width: 660px; }
.kicker { font-size: .8rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); }
:lang(ug) .kicker { letter-spacing: 0; text-transform: none; }
.pic { margin: 0; display: flex; flex-direction: column; gap: 6px; }
/* Picture frames (ADR 0016). A frame gets its size here; the picture fills it, cropped at its focus (gen.css), or whole
   ("fit") on a blurred copy of itself. A large frame ("shape") takes the picture's shape (gen.css), capped in height. */
.fr { position: relative; display: block; overflow: hidden; background: var(--soft); }
.fr > img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; margin: auto; object-fit: cover; }
.fr > .bg { inset: -12%; width: 124%; height: 124%; filter: blur(14px) saturate(.85) brightness(.8); }
.fit > img:last-child { object-fit: contain; }
.shape { aspect-ratio: 4 / 3; }
.pf { width: 100%; max-height: 280px; border-radius: 14px; }
@media (min-width: 600px) { .pf { max-height: 360px; } }
.pic figcaption { display: flex; flex-wrap: wrap; gap: 2px 10px; font-size: .75rem; color: var(--muted); }
.pic .cap { font-weight: 600; color: var(--ink); }
.pic .credit a { color: var(--muted); }

/* ---------- boxes, facts, sections ---------- */
.box { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 20px; display: flex; flex-direction: column; gap: 12px; }
.box > p { font-size: 1.06rem; line-height: 1.6; }
.cols { display: flex; flex-direction: column; gap: 20px; }
.col-main { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.col-main > section, .chainwrap, .where { display: flex; flex-direction: column; gap: 12px; }
.col-side { display: flex; flex-direction: column; gap: 16px; }
.box.side { padding: 16px 18px; gap: 8px; }
.box.side h3 { font-family: var(--sans); margin: 0; }
.facts { margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.facts div { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.facts dt { font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
:lang(ug) .facts dt { letter-spacing: 0; }
.facts dd { margin: 0; }
.facts .v { font-weight: 600; font-size: 1rem; }
.facts .n { font-size: .82rem; color: var(--muted); }
.aiwrap .note { margin: 0; }

/* ---------- record cards (draft J "Who was who", H "Same time") ---------- */
.cards { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.cards.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 12px; }
.card { height: 100%; display: flex; flex-direction: column; gap: 3px; padding: 14px 16px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.card .k { font-size: .75rem; font-weight: 700; letter-spacing: .04em; color: var(--accent); text-transform: uppercase; }
:lang(ug) .card .k { letter-spacing: 0; text-transform: none; }
.card .ttl { font-weight: 600; font-size: 1rem; }
.card .sub { font-size: .85rem; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.plain { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.plain .pl, .plain li > a { display: flex; flex-direction: column; gap: 1px; min-height: 44px; justify-content: center; text-decoration: none; color: var(--ink); }
.plain .pl .ttl { font-weight: 600; }
.plain .pl .k { font-size: .82rem; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.plain li > a:not(.pl) { flex-direction: row; align-items: center; justify-content: flex-start; gap: 6px; font-weight: 600; color: var(--accent); }
.list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.list li { padding: 12px 16px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); }
.list .row { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; }
.list .k, .yrs { font-size: .85rem; color: var(--muted); }
.nb { font-size: .9rem; margin-top: 2px; }
.nb a { display: inline-flex; align-items: center; min-height: 40px; }

/* ---------- chips ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; margin-inline-end: -16px; padding-inline-end: 16px; scrollbar-width: none; }
.chip { flex: none; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 6px 14px; border-radius: 22px; border: 1px solid var(--line);
  background: var(--card); color: var(--ink); text-decoration: none; font-size: .875rem; }
/* In a row that wraps, a long chip (a path's full title) wraps its own text instead of running off the phone screen. */
.chips:not(.scroll) > .chip { flex-shrink: 1; max-width: 100%; }
.chip > svg { flex: none; }
.list .chip { margin-top: 6px; }
.words { display: flex; flex-wrap: wrap; gap: 8px; }
.word { display: inline-flex; align-items: baseline; gap: 8px; min-height: 44px; padding: 6px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--card); color: var(--ink); text-decoration: none; }
.word .ug { font-family: "Plex Arabic", sans-serif; font-weight: 700; font-size: 1.1rem; }
.word .g { font-size: .85rem; color: var(--muted); }

/* ---------- life line (draft H) ---------- */
.lifeline { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.lifeline li { display: grid; grid-template-columns: 78px 20px minmax(0, 1fr); gap: 10px; align-items: start; }
.lifeline .when { font-size: .85rem; font-weight: 700; padding-top: 12px; text-align: end; }
.lifeline .rail { align-self: stretch; display: flex; flex-direction: column; align-items: center; }
.lifeline .rail::before { content: ""; width: 2px; height: 16px; background: var(--line); }
.lifeline .rail i { width: 12px; height: 12px; border-radius: 50%; background: var(--accent); flex: none; }
.lifeline .rail::after { content: ""; flex: 1; width: 2px; background: var(--line); }
.lifeline li:first-child .rail::before { visibility: hidden; }
.lifeline li:last-child .rail::after { visibility: hidden; }
.lifeline .rail.muted i { background: var(--dot-muted); }
.lifeline .rail.ink i { background: var(--ink); }
.lifeline .what { display: flex; flex-direction: column; gap: 2px; padding: 8px 0 14px; }
.lifeline .what .k { font-size: .75rem; font-weight: 700; letter-spacing: .04em; color: var(--accent); text-transform: uppercase; }
:lang(ug) .lifeline .what .k { letter-spacing: 0; text-transform: none; }
.lifeline .what .ttl { font-weight: 600; font-size: 1rem; }
.lifeline .what .ttl a { color: var(--ink); }
.lifeline .what .n { font-size: .875rem; color: var(--muted); }

/* ---------- chain and moments (drafts J, K, M) ---------- */
.chain { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.chain .in { display: grid; grid-template-columns: 96px minmax(0, 1fr); column-gap: 10px; padding: 8px 10px; border-radius: 10px; text-decoration: none; color: var(--ink); min-height: 44px; align-items: baseline; }
.chain .when { grid-row: 1 / span 2; font-size: .85rem; color: var(--muted); }
.chain .ttl { font-weight: 600; font-size: .94rem; }
.chain .n { font-size: .8rem; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.chain a.in .ttl { color: var(--accent); }
.chain li.cur .in { background: var(--accent); color: var(--cur-fg); }
.chain li.cur .when, .chain li.cur .n { color: var(--done); }
.chain.moments .in { background: var(--card); border: 1px solid var(--line); }
.chain.moments a.in .ttl { color: var(--ink); }
.chain.moments .when { font-weight: 700; color: var(--accent); }

/* ---------- disputes (drafts H, J, M, Q) ---------- */
.dispute { background: var(--panel); border-radius: 16px; padding: 20px; display: flex; flex-direction: column; gap: 12px; }
.dispute .lbl { color: var(--kicker); }
.dispute h2 { font-size: 1.3rem; }
.dispute h2 a { color: inherit; text-decoration-color: var(--dashed); }
.views { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 12px; }
.view { background: var(--card); border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 6px; }
.view .vv { font-weight: 700; font-size: 1.1rem; }
.view p { font-size: .9rem; }
.view .note { color: var(--dot-muted); }
.view.pref { box-shadow: inset 0 0 0 2px var(--accent); }
.view .plbl { font-size: .75rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--accent); }
.view .vk { font-size: .75rem; font-weight: 600; color: var(--kicker); }
details.sources { border-top: 1px solid var(--line); padding-top: 8px; font-size: .9rem; color: var(--muted); }
details.sources summary { display: flex; align-items: center; min-height: 44px; cursor: pointer; font-weight: 600; color: var(--ink); }
details.sources ul { margin: 0; padding-inline-start: 18px; display: flex; flex-direction: column; gap: 4px; }

/* ---------- where next (all desktop drafts) ---------- */
.where { border-top: 1px solid var(--line); padding-top: 24px; }
.wgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 16px; }
.wcard { display: flex; flex-direction: column; gap: 6px; padding: 18px 20px; border-radius: 12px; border: 1px solid var(--line); background: var(--card); color: var(--ink); text-decoration: none; }
.wcard .lbl { color: var(--accent); }
.wcard .ttl { font-weight: 600; font-size: 1.1rem; }
.wcard .sub { font-size: .875rem; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.wcard.dark { background: var(--inv); border-color: var(--inv); color: var(--inv-fg); }
.wcard.dark .lbl { color: var(--inv-k); }
.wcard.dark .sub { color: var(--inv-sub); }

/* ---------- story path (drafts F, G) ---------- */
.pathhead { display: flex; flex-direction: column; gap: 10px; }
.pathhead .h1like { font-family: var(--serif); font-weight: 700; font-size: 1.6rem; line-height: 1.15; }
.wide-only-block { display: none; }
.progress { display: flex; gap: 4px; }
.progress span { flex: 1; height: 4px; border-radius: 2px; background: var(--line); }
.progress span.on { background: var(--accent); }
.strip-wrap { display: none; }
.steps .step { position: relative; padding-inline-start: 56px; }
.steps .dot { position: absolute; inset-inline-start: 14px; top: 14px; width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: var(--accent); color: var(--cur-fg); font-size: .85rem; font-weight: 700; }
.stop { gap: 14px; }
.stop h1 { font-size: 1.65rem; }
.stop .body { font-size: 1.06rem; line-height: 1.6; max-width: 680px; }
.stop .body.strong { font-weight: 600; }
/* Longer page text (ADR 0011): reader's question as heading, then the answer. */
.prose h2 { font-size: 1.15rem; line-height: 1.35; }
.prose p { font-size: 1.04rem; line-height: 1.65; max-width: 680px; margin: 0; }
.prose p + p { margin-top: .2rem; }
.prose p.note { font-size: .85rem; line-height: 1.45; }
.prose.more { display: flex; flex-direction: column; gap: 10px; padding-top: 6px; border-top: 1px solid var(--line); }
.here { display: flex; flex-direction: column; gap: 8px; }
.stopnav { display: none; }
.btn { align-self: flex-start; display: inline-flex; align-items: center; min-height: 48px; padding: 0 20px; border-radius: 10px; background: var(--accent); color: var(--cur-fg); text-decoration: none; font-weight: 700; }
.btn.dark { background: var(--inv); color: var(--inv-fg); }

/* ---------- bottom bars (phone) ---------- */
.bar { position: fixed; inset: auto 0 0 0; z-index: 5; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); background: var(--card); border-top: 1px solid var(--line); padding: 4px 8px calc(8px + env(safe-area-inset-bottom)); }
.bar a { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; min-height: 56px; text-decoration: none; color: var(--ink); font-size: .75rem; font-weight: 500; }
.bar a[aria-current] { color: var(--accent); font-weight: 700; }
.bar a[aria-current]::before { content: ""; position: absolute; top: 0; left: 25%; right: 25%; height: 3px; border-radius: 0 0 3px 3px; background: var(--accent); }
.ctabar { position: fixed; inset: auto 0 0 0; z-index: 5; display: flex; gap: 10px; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: var(--card); border-top: 1px solid var(--line); }
.cta { flex: 1; min-width: 0; min-height: 52px; padding: 6px 14px; border-radius: 12px; background: var(--inv); color: var(--inv-fg); text-decoration: none; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 10px; }
.cta .k { grid-column: 1; font-size: .75rem; font-weight: 600; color: var(--inv-k); }
.cta .ttl { grid-column: 1; font-weight: 600; font-size: .94rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cta .arr { grid-column: 2; grid-row: 1 / span 2; font-size: 1.2rem; }
.xbtn, .stopbar .prev { flex: none; min-height: 52px; min-width: 52px; padding: 0 14px; border: 1px solid var(--line); border-radius: 12px; display: flex; align-items: center; justify-content: center; gap: 6px; text-decoration: none; color: var(--ink); font-size: .875rem; font-weight: 600; }

/* ---------- main screen (drafts C, E) ---------- */
.homehero { display: flex; flex-direction: column; gap: 16px; }
.feature { background: var(--panel); border-radius: 16px; padding: 16px; display: flex; flex-direction: column; gap: 14px; }
.feature .ftext { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.feature .lbl { color: var(--kicker); }
.feature .ftitle { font-family: var(--serif); font-size: 1.35rem; line-height: 1.2; font-weight: 700; color: var(--ink); text-decoration: none; }
.feature p { font-size: .94rem; color: var(--muted); }
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pill { background: var(--card); border-radius: 999px; padding: 6px 12px; font-size: .8rem; }
.pill:empty { display: none; }
.fpic { margin: 0; }
.fpic img { display: block; width: 100%; height: 160px; object-fit: cover; border-radius: 10px; }
.paths-col { display: flex; gap: 12px; overflow-x: auto; margin-inline-end: -16px; padding-inline-end: 16px; scrollbar-width: none; align-items: stretch; }
.paths-col > h2 { display: none; }
.paths-col > .more { flex: none; display: flex; align-items: center; padding: 0 20px; border: 1px dashed var(--dashed); border-radius: 12px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.pcard, .hcard { flex: 0 0 min(240px, 72vw); text-decoration: none; color: var(--ink); border: 1px solid var(--line); border-radius: 12px; padding: 16px; display: flex; flex-direction: column; gap: 6px; background: var(--card); }
.pcard .ttl, .hcard .ttl { font-weight: 600; font-size: 1.02rem; }
.pcard .sub, .hcard .sub { font-size: .82rem; color: var(--muted); }
.pcard .lbl { color: var(--accent); }
.pcard.dark { background: var(--inv); color: var(--inv-fg); border-color: var(--inv); }
.pcard.dark .lbl { color: var(--inv-k); }
.pcard.dark .sub { color: var(--inv-sub); }
.hooks { display: flex; gap: 12px; overflow-x: auto; margin-inline-end: -16px; padding-inline-end: 16px; scrollbar-width: none; }
.hcard { flex-basis: min(210px, 64vw); }
.hcard .ugw { font-family: "Plex Arabic", sans-serif; font-size: 1.3rem; font-weight: 700; }
.hpic { display: block; height: 90px; border-radius: 8px; overflow: hidden; background: var(--soft); }
.hpic img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* Every list, with its size: the way to people, events, states, objects, themes and disputes from the main screen. */
.browse { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.bt { display: flex; flex-direction: column; gap: 2px; min-height: 64px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--card); color: var(--ink); text-decoration: none; }
.bt b { font-family: var(--serif); font-size: 1.35rem; line-height: 1.1; color: var(--accent); }
.bt span { font-size: .8rem; font-weight: 600; }
.themes-row { align-items: center; }
.themes-row .tl { font-size: .875rem; color: var(--muted); margin-inline-end: 4px; }
.timecard { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px; display: flex; flex-direction: column; gap: 8px; }
.rowhead { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.timecard h2 { font-family: var(--sans); font-size: .75rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.timecard .go { font-size: .875rem; font-weight: 600; text-decoration: none; min-height: 32px; display: inline-flex; align-items: center; }

/* ---------- era band (drafts C, E, O, O2) ---------- */
.band { display: flex; gap: 2px; height: 22px; }
.band .era { min-width: 0; display: block; background: var(--band1); color: var(--ink); text-decoration: none; overflow: hidden; }
.band .era.b1 { background: var(--band2); }
.band .era:first-child { border-radius: 6px 0 0 6px; } .band .era:last-child { border-radius: 0 6px 6px 0; }
.band .era span { display: none; }
.band .era.cur { outline: 3px solid var(--ink); outline-offset: -3px; font-weight: 700; }
.scale { position: relative; height: 18px; font-size: .75rem; color: var(--muted); margin-top: 4px; }
.scale bdi { position: absolute; top: 0; transform: translateX(-50%); white-space: nowrap; }
.scale .m0 { transform: none; }
.scale .mend { right: 0; transform: none; }

/* ---------- time (drafts O, O2) ---------- */
.timehead { display: flex; flex-direction: column; gap: 12px; }
.timehead .meta { margin-top: 4px; }
.yearpick { display: flex; align-items: center; gap: 8px; }
.yearpick .ibtn { width: 48px; height: 48px; border-radius: 12px; }
.yearbox { flex: 1; display: flex; justify-content: center; align-items: center; gap: 8px; min-height: 48px; border-radius: 12px; background: var(--inv); padding: 0 14px; }
.yearbox .yl { font-size: .8rem; color: var(--inv-sub); }
.yearbox input { width: 110px; border: 0; background: transparent; color: var(--inv-fg); font: inherit; font-size: 1.6rem; font-weight: 700; text-align: center; }
.slider { position: relative; padding: 6px 0; }
.slider .band { height: 32px; }
.slider input[type=range] { position: absolute; inset: 6px 0 auto 0; width: 100%; height: 32px; margin: 0; background: transparent; appearance: none; -webkit-appearance: none; cursor: pointer; }
.slider input[type=range]::-webkit-slider-runnable-track { height: 32px; background: transparent; }
.slider input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 26px; height: 44px; margin-top: -6px; border-radius: 13px; background: var(--inv); border: 3px solid var(--card); box-shadow: 0 2px 6px rgba(42,33,28,.25); }
.slider input[type=range]::-moz-range-thumb { width: 20px; height: 38px; border-radius: 13px; background: var(--inv); border: 3px solid var(--card); }
.ycards { display: flex; flex-direction: column; gap: 12px; }
.ybox { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; }
.ybox h3 { font-family: var(--sans); }
.ybox ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.ybox li a { display: flex; flex-direction: column; text-decoration: none; color: var(--ink); min-height: 40px; justify-content: center; }
.ybox .ttl { font-weight: 600; }
.ybox .n { font-size: .82rem; color: var(--muted); }
.ybox .maplink { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; font-weight: 600; }

/* ---------- misc pages ---------- */
.search input { width: 100%; min-height: 52px; padding: 0 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); color: var(--ink); font: inherit; font-size: 1.05rem; }
.opts { border: 0; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.opts legend { width: 100%; font-weight: 700; margin-bottom: 8px; padding: 0; }
.optrow { display: flex; flex-wrap: wrap; gap: 8px; }
.opt { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--card); color: var(--ink); text-decoration: none; cursor: pointer; }
.opt input { accent-color: var(--accent); width: 18px; height: 18px; margin: 0; }
.opt:has(input:checked), .opt.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); font-weight: 600; }
.srclist { margin: 0; padding-inline-start: 18px; display: flex; flex-direction: column; gap: 6px; }
.srclist a { font-weight: 600; }
.srclist .k { color: var(--muted); font-size: .85rem; }
@media (hover: hover) {
  .card:hover, .wcard:hover, .hcard:hover, .pcard:hover, .bt:hover, .chain.moments a.in:hover, .strip a:hover, .chip:hover, .opt:hover, .word:hover { border-color: var(--accent); }
  .chain a.in:hover { background: var(--soft); }
}
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }

/* ---------- desktop: the drafts are drawn at 1280 px, content 1200 px ---------- */
@media (min-width: 960px) {
  body.has-bar, body.has-cta { padding-bottom: 0; }
  .bar, .ctabar, .top.inner, .progress, .anchors { display: none; }
  body.is-inner .top.main { display: block; }
  main { padding: 28px 24px 56px; gap: 28px; }
  footer { padding: 16px 24px 32px; }
  .crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: .875rem; color: var(--muted); }
  h1 { font-size: 2.75rem; line-height: 1.1; }
  h2 { font-size: 1.5rem; }
  .hero { flex-direction: row; align-items: stretch; gap: 28px; }
  .hero-text { flex: 999 1 520px; gap: 12px; }
  .hero .pic { flex: 1 1 300px; max-width: 420px; }
  .hero .pic .pf { max-height: 340px; }
  .alt.ug { font-size: 1.6rem; }
  .lead { font-size: 1.25rem; }
  .facts { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
  .facts div { padding: 14px 16px; }
  .cols { flex-direction: row; align-items: flex-start; gap: 28px; }
  .col-main { flex: 999 1 560px; }
  .col-side { flex: 1 1 320px; max-width: 360px; position: sticky; top: 96px; gap: 20px; }
  .box { padding: 24px; }
  .lifeline li { grid-template-columns: 96px 20px minmax(0, 1fr); gap: 12px; }
  .lifeline .when { font-size: .875rem; padding-top: 14px; }
  .chain { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 8px; }
  .chain .in { display: flex; flex-direction: column; gap: 4px; padding: 12px; height: 100%; border: 1px solid var(--line); background: var(--card); border-radius: 12px; }
  .chain .when { font-size: .75rem; font-weight: 700; color: var(--accent); }
  .chain a.in .ttl { color: var(--ink); }
  .chain li.cur .in { border-color: var(--accent); }
  .dispute { padding: 22px; }
  .wide-only-block { display: flex; flex-direction: column; gap: 20px; }
  .strip-wrap { display: block; }
  .strip { list-style: none; margin: 0; padding: 0; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 8px; }
  .strip a { height: 100%; display: flex; flex-direction: column; gap: 6px; padding: 12px; border-radius: 12px; text-decoration: none; color: var(--ink); background: var(--card); border: 1px solid var(--line); }
  .strip .top { display: flex; align-items: center; gap: 8px; position: static; border: 0; background: none; }
  .strip .dot { width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: .8rem; font-weight: 700; border: 2px solid var(--ink); flex: none; }
  .strip .k { font-size: .72rem; font-weight: 700; letter-spacing: .04em; color: var(--muted); text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .strip .ttl { font-weight: 600; font-size: .9rem; line-height: 1.3; }
  .strip .n { font-size: .78rem; color: var(--muted); }
  .strip li.done a { background: var(--done); border-color: var(--done-line); }
  .strip li.done .dot { background: var(--accent); color: var(--cur-fg); border-color: var(--accent); }
  .strip li.now a { background: var(--accent); border-color: var(--accent); color: var(--cur-fg); }
  .strip li.now .dot { background: var(--card); color: var(--accent); border-color: var(--card); }
  .strip li.now .k, .strip li.now .n { color: var(--done); }
  .steps { display: none; }
  .stop { padding: 28px; gap: 18px; }
  .stop h1 { font-size: 1.9rem; }
  .stop .pic .pf { max-height: 300px; }
  .stopnav { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 16px; }
  .stopnav a { display: flex; flex-direction: column; gap: 2px; text-decoration: none; color: var(--ink); min-height: 44px; }
  .stopnav .k { font-size: .8rem; color: var(--muted); }
  .stopnav .ttl { font-weight: 600; }
  .stopnav a.nx { background: var(--inv); color: var(--inv-fg); border-radius: 10px; padding: 10px 18px; text-align: end; }
  .stopnav a.nx .k { color: var(--inv-sub); }
  .homehero { flex-direction: row; align-items: stretch; gap: 20px; }
  .feature { flex: 999 1 560px; flex-direction: row; padding: 28px; gap: 24px; }
  .feature .ftext { flex: 1 1 300px; gap: 14px; }
  .feature .ftitle { font-size: 2.1rem; line-height: 1.15; }
  .feature p { font-size: 1.06rem; }
  .fpic { flex: 0 1 260px; }
  .fpic img { height: 100%; min-height: 180px; }
  .paths-col { flex: 1 1 300px; flex-direction: column; gap: 16px; overflow: visible; margin: 0; padding: 0; }
  .paths-col > h2 { display: block; }
  .paths-col > .more { display: inline-flex; align-self: flex-start; padding: 0; border: 0; font-size: .875rem; font-weight: 400; text-decoration: underline; }
  .paths-col > .pcard:nth-child(n+4) { display: none; }
  .browse { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; }
  .bt { padding: 14px 18px; }
  .pcard { flex: none; padding: 20px; }
  .pcard .ttl { font-size: 1.12rem; }
  .hooks { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; overflow: visible; margin: 0; padding: 0; }
  .hcard { padding: 18px; gap: 8px; }
  .timecard { background: none; border: 0; border-top: 1px solid var(--line); border-radius: 0; padding: 24px 0 0; gap: 10px; }
  .timecard h2 { font-family: var(--serif); font-size: 1.5rem; font-weight: 700; letter-spacing: 0; text-transform: none; color: var(--ink); }
  .band { height: 48px; gap: 3px; }
  .band .era span { display: block; padding: 6px 8px; font-size: .75rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .band .era:first-child { border-radius: 8px 0 0 8px; } .band .era:last-child { border-radius: 0 8px 8px 0; }
  .timehead { flex-direction: row; justify-content: space-between; align-items: center; }
  .timehead h1 { font-size: 2.25rem; }
  .yearpick .ibtn { width: 44px; height: 44px; }
  .yearbox { flex: none; min-height: 44px; }
  .yearbox input { width: 80px; font-size: 1.4rem; }
  .slider .band { height: 40px; }
  .slider input[type=range] { height: 40px; }
  .slider input[type=range]::-webkit-slider-runnable-track { height: 40px; }
  .ycards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
  .ybox { padding: 16px 18px; }
}
/* Header between 960 and 1200 px: keep the wordmark whole and the menu on one line. */
.brand, .brand .wm { flex: none; white-space: nowrap; }

/* ---------- list pages (canvas boards R, R2, S, T, U) ---------- */
[hidden] { display: none !important; }
.listhead { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.listcols { display: flex; flex-direction: column; gap: 20px; }
.listmain { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.pnav { display: none; }
.grp { display: flex; flex-direction: column; scroll-margin-top: 80px; }
.ghead { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 14px 0 6px; border-bottom: 2px solid var(--ink); }
.ghead h2 { font-size: 1.2rem; }
.ghead span, .chip span { font-size: .82rem; color: var(--muted); font-weight: 400; }
.listmain > .grp:first-child .ghead, .pcards-first .ghead { padding-top: 2px; }
button.chip { font: inherit; font-size: .875rem; cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--inv); border-color: var(--inv); color: var(--inv-fg); font-weight: 600; }
.chip[aria-pressed="true"] span { color: var(--inv-sub); }
/* a thumbnail, or the first letter where a record has no picture of its own */
.th { flex: 0 0 56px; width: 56px; height: 56px; border-radius: 12px; overflow: hidden; background: var(--soft); display: block; }
.th img { display: block; width: 100%; height: 100%; object-fit: cover; }
.th.ini { display: flex; align-items: center; justify-content: center; font-family: var(--serif); font-size: 1.5rem; font-weight: 700; color: var(--dot-muted); }
/* people and objects: a row with picture, name, years, kind and one line */
.rows { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.lrow { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 9px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.rt { flex: 1; min-width: 0; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; column-gap: 8px; row-gap: 4px; align-items: center; }
.rt .ttl { grid-column: 1 / 3; grid-row: 1; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rt .yrs { grid-column: 3; grid-row: 1; font-size: .82rem; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.rt .role { grid-column: 1; grid-row: 2; background: var(--tag); color: var(--tag-ink); border-radius: 999px; padding: 1px 8px; font-size: .75rem; font-weight: 600; white-space: nowrap; }
.rt .sub { grid-column: 2 / 4; grid-row: 2; font-size: .82rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* events: a time line */
.jump { display: flex; flex-direction: column; gap: 6px; }
.jump .band { height: 24px; }
.tline { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.erow { display: grid; grid-template-columns: 64px 14px minmax(0, 1fr) auto; column-gap: 10px; min-height: 56px; text-decoration: none; color: var(--ink); }
.erow .when { padding-top: 10px; text-align: end; font-size: .82rem; font-weight: 700; color: var(--accent); white-space: nowrap; font-variant-numeric: tabular-nums; }
.tline .rail { display: flex; flex-direction: column; align-items: center; }
.tline .rail::before { content: ""; width: 2px; height: 13px; background: var(--line); }
.tline .rail::after { content: ""; flex: 1; width: 2px; background: var(--line); }
.tline .rail i { flex: none; width: 12px; height: 12px; border-radius: 50%; background: var(--accent); }
.tline .rail.ink i { background: var(--ink); }
.tline .rail.ring i { background: var(--card); border: 3px solid var(--accent); }
.erow .et { padding: 7px 0 11px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.erow .ttl { font-weight: 600; font-size: .94rem; line-height: 1.3; }
.erow .n { font-size: .82rem; color: var(--muted); }
.erow .th { align-self: center; flex-basis: 48px; width: 48px; height: 48px; border-radius: 10px; }
/* story paths: cards with a cover */
.pcards { list-style: none; margin: 10px 0 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.pathc { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.pathc .th { flex-basis: 88px; width: 88px; height: 88px; border-radius: 10px; }
.pathc .th.ini { color: var(--dot-muted); }
.pathc .pt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.pathc .kicker { font-size: .75rem; }
.pathc .ttl { font-family: var(--serif); font-weight: 700; font-size: 1rem; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pathc .sub { font-size: .82rem; line-height: 1.4; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.resume { display: flex; flex-direction: column; gap: 8px; padding: 14px 16px; border-radius: 14px; background: var(--inv); color: var(--inv-fg); text-decoration: none; }
.resume .rk { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.resume .lbl { color: var(--inv-k); }
.resume .go { font-weight: 600; font-size: .9rem; }
.resume .ttl { font-weight: 600; line-height: 1.3; }
.resume .prog { display: flex; gap: 4px; }
.resume .prog span { flex: 1; height: 4px; border-radius: 2px; background: var(--inv-sub); }
.resume .prog span.on { background: var(--inv-k); }
@media (hover: hover) {
  .lrow:hover .ttl, .erow:hover .ttl, .srow:hover .ttl { color: var(--accent); }
  .pathc:hover { border-color: var(--accent); }
}
@media (min-width: 960px) {
  .listcols { flex-direction: row; align-items: flex-start; gap: 28px; }
  .listmain { flex: 1; gap: 32px; }
  .listmain > .grp:first-child .ghead { padding-top: 2px; }
  .ghead { padding-top: 0; padding-bottom: 8px; margin-bottom: 14px; }
  .ghead h2 { font-size: 1.5rem; }
  .pnav { flex: 0 0 230px; position: sticky; top: 96px; display: flex; flex-direction: column; gap: 2px; padding: 14px 10px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); }
  .pnav .lbl { padding: 0 12px 6px; }
  .pnav a { display: flex; justify-content: space-between; gap: 10px; min-height: 40px; align-items: center; padding: 0 12px; border-radius: 8px; text-decoration: none; color: var(--ink); font-size: .9rem; }
  .pnav a span:last-child { color: var(--muted); }
  .pnav a:hover { background: var(--tag); }
  .filt.chips.scroll { flex-wrap: wrap; overflow: visible; margin-inline-end: 0; padding-inline-end: 0; }
  .rows { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
  .lrow { flex-direction: column; align-items: stretch; gap: 0; padding: 0; border: 1px solid var(--line); border-radius: 12px; background: var(--card); overflow: hidden; }
  .lrow .th { flex: none; width: 100%; height: 150px; border-radius: 0; }
  .lrow .th.ini { font-size: 3.5rem; color: var(--dashed); }
  .rt { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 6px; padding: 12px 14px 14px; }
  .rt .ttl { flex-basis: 100%; white-space: normal; }
  .rt .role { order: 1; background: none; padding: 0; color: var(--accent); }
  .rt .yrs { order: 2; }
  .rt .yrs::before { content: "· "; }
  .rt .sub { order: 3; flex-basis: 100%; white-space: normal; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; line-height: 1.45; }
  .jump .band { height: 48px; }
  .tline { max-width: 820px; }
  .erow { grid-template-columns: 80px 14px minmax(0, 1fr) auto; }
  .erow .ttl { font-size: 1rem; }
  .pcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 16px; }
  .pathc { padding: 12px; }
  .pathc .th { flex-basis: 110px; width: 110px; height: 110px; }
  .pathc .ttl { font-size: 1.1rem; }
  .resume { max-width: 720px; }
}

/* ================= Interface of ADR 0013 =================
   One idea runs through it: each kind of thing has its own shape, so a card never needs a label to say what it is. */
:root { --hero: #2A211C; --hero-fg: #F3ECE0; --hero-sub: #CFC4B3; --hero-k: #7CC0AE; --hero-line: #6E6259; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --hero: #2F2620; } }
:root[data-theme="dark"] { --hero: #2F2620; }

/* ---------- header: wordmark, three ways in, search, one menu ---------- */
.menu, .hsearch, .wide-only { display: none; }
.dd { position: relative; }
.dd > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 4px; min-height: 44px; }
.dd > summary::-webkit-details-marker { display: none; }
.dd[open] > summary { color: var(--accent); }
.mmenu > summary.ibtn { margin: 0; }
.mbtns { position: relative; display: flex; align-items: center; gap: 2px; }
.mbtns > .dd { position: static; }
.top.inner .mbtns { margin-inline-start: auto; }
.mset .aa { font-family: var(--serif); font-weight: 700; font-size: 1.15rem; line-height: 1; }
/* The "Aa" menu: the languages as a row of chips, then theme and text size. */
.mset .langlist { display: flex; flex-wrap: wrap; gap: 6px; padding: 6px 16px 10px; }
.mset .langlist a, .mset .langlist span { min-height: 40px; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px; font-size: .92rem; }
.mset .langlist span { background: var(--inv); color: var(--inv-fg); border-color: var(--inv); }
.mset .langlist span svg { display: none; }
.mmenu.mset .langlist { border-top: 0; margin-top: 0; }
.pop { position: absolute; inset-inline-end: 0; top: calc(100% + 6px); z-index: 8; min-width: 240px; padding: 8px 0; background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 12px 32px rgba(0, 0, 0, .18); color: var(--ink); }
.mmenu .pop { width: min(340px, calc(100vw - 24px)); max-height: calc(100vh - 160px); overflow-y: auto; }
.poplinks { display: flex; flex-direction: column; }
.poplinks a, .langlist a, .langlist span { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 16px; color: var(--ink); text-decoration: none; font-size: 1rem; font-weight: 400; }
.poplinks a.sep, .poplinks a.surprise { border-top: 1px solid var(--line); margin-top: 4px; }
.poplinks a[aria-current] { color: var(--accent); font-weight: 600; }
.mmenu .langlist { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 4px; }
.langlist span { justify-content: space-between; font-weight: 700; color: var(--accent); }
.prefrow { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 12px; padding: 6px 16px; font-size: .9rem; }
.segs { flex: 1 1 100%; }
.segs button { flex: 1; }
.langlist + .prefrow { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 10px; }
.segs { display: flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.segs button { min-height: 44px; padding: 0 10px; border: 0; background: none; color: var(--ink); font: inherit; font-size: .82rem; cursor: pointer; }
.segs button[aria-pressed="true"] { background: var(--inv); color: var(--inv-fg); font-weight: 600; }
/* Text size slider (draft D3): small A, the slider, large A; the size's name beside the label, no numbers. */
.sizerow .sizename { margin-inline-start: auto; color: var(--accent); font-weight: 600; font-size: .85rem; }
.sizebar { flex: 1 1 100%; display: flex; align-items: center; gap: 12px; }
.sizebar .a1 { font-size: .8rem; font-weight: 700; } .sizebar .a2 { font-size: 1.35rem; font-weight: 700; }
.sizer { flex: 1; min-width: 0; height: 44px; margin: 0; background: transparent; cursor: pointer; -webkit-appearance: none; appearance: none; --fill: 40%; }
.sizer::-webkit-slider-runnable-track { height: 6px; border-radius: 3px; background: linear-gradient(to right, var(--accent) var(--fill), var(--line) var(--fill)); }
.sizer::-moz-range-track { height: 6px; border-radius: 3px; background: linear-gradient(to right, var(--accent) var(--fill), var(--line) var(--fill)); }
.sizer::-webkit-slider-thumb { -webkit-appearance: none; width: 26px; height: 26px; margin-top: -10px; border-radius: 50%; background: var(--card); border: 3px solid var(--accent); box-sizing: border-box; }
.sizer::-moz-range-thumb { width: 26px; height: 26px; border-radius: 50%; background: var(--card); border: 3px solid var(--accent); box-sizing: border-box; }
[dir="rtl"] .sizebar { direction: ltr; }
.opts .legend { width: 100%; font-weight: 700; margin-bottom: 8px; }
.opts .sizerow { padding: 0; width: 100%; }
.foot-links { display: flex; flex-wrap: wrap; gap: 0 20px; margin: 0; }
.foot-links a { display: inline-flex; align-items: center; min-height: 44px; color: var(--muted); text-decoration: none; font-size: .9rem; }
.rowhead h2 { font-size: 1.25rem; }
.go { display: inline-flex; align-items: center; min-height: 44px; font-size: .9rem; font-weight: 600; text-decoration: none; }
.hsec { display: flex; flex-direction: column; gap: 6px; }

/* ---------- a path as the lead of a page ---------- */
.phero { display: flex; flex-direction: column; border-radius: 20px; overflow: hidden; background: var(--hero); color: var(--hero-fg); text-decoration: none; }
.ph-img { aspect-ratio: 5 / 4; max-height: 320px; } /* shapes in FRAME_SHAPES.phero */
.ph-t { display: flex; flex-direction: column; gap: 8px; padding: 18px 20px 20px; }
.ph-k { font-size: .85rem; color: var(--hero-sub); }
.ph-ttl { font-family: var(--serif); font-weight: 700; font-size: 1.75rem; line-height: 1.15; }
.ph-b { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 4px; font-size: .9rem; color: var(--hero-sub); }
.pbtn { background: var(--hero-fg); color: var(--hero); font-weight: 700; font-size: 1rem; padding: 12px 18px; border-radius: 999px; white-space: nowrap; }

/* ---------- main screen ---------- */
.hometop { display: flex; flex-direction: column; gap: 20px; }
.leaf { display: flex; gap: 16px; align-items: center; min-height: 88px; text-decoration: none; color: var(--ink); }
.cal { flex: 0 0 76px; display: flex; flex-direction: column; text-align: center; border-radius: 12px; overflow: hidden; background: var(--card); border: 1px solid var(--line); }
.cal .mo { background: var(--accent); color: var(--cur-fg); font-size: .72rem; font-weight: 700; padding: 4px 2px; white-space: nowrap; overflow: hidden; }
.cal .dd { font-family: var(--serif); font-weight: 700; font-size: 2.1rem; line-height: 1.3; }
.lt { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.lt .k { font-size: .85rem; color: var(--muted); }
.lt .ttl { font-family: var(--serif); font-weight: 700; font-size: 1.25rem; line-height: 1.25; }
.lt .sub { display: none; }
.faces { display: flex; gap: 14px; overflow-x: auto; margin-inline-end: -16px; padding-inline-end: 16px; scrollbar-width: none; }
.face { flex: 0 0 84px; display: flex; flex-direction: column; gap: 8px; text-align: center; font-size: .82rem; font-weight: 600; line-height: 1.25; color: var(--ink); text-decoration: none; }
.face img { display: block; width: 84px; height: 84px; border-radius: 50%; object-fit: cover; background: var(--soft); }
.htiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.htile { display: flex; flex-direction: column; gap: 2px; color: var(--ink); text-decoration: none; }
.hf { aspect-ratio: 4 / 5; border-radius: 14px; margin-bottom: 6px; } /* shapes in FRAME_SHAPES.htile */
@media (min-width: 600px) { .hf { aspect-ratio: 1; } }
.htile .ttl { font-weight: 600; font-size: .95rem; line-height: 1.25; }
.htile .k { font-size: .82rem; color: var(--muted); }
.versus { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 20px 0 8px; border-top: 2px solid var(--ink); border-bottom: 2px solid var(--ink); text-align: center; }
.versus h2 { font-size: 1.3rem; line-height: 1.25; }
.versus h2 a { color: var(--ink); text-decoration: none; }
.vs { display: flex; align-items: center; justify-content: center; gap: 8px 14px; flex-wrap: wrap; width: 100%; }
.vs .v { flex: 1 1 120px; font-family: var(--serif); font-weight: 700; font-size: 1.9rem; line-height: 1.2; }
.vs .v.pref { color: var(--accent); }
.vs .or { font-size: .82rem; font-weight: 700; color: var(--muted); }
.timecard { background: none; border: 0; border-radius: 0; padding: 0; gap: 4px; }
.timecard h2 { font-family: var(--serif); font-size: 1.25rem; font-weight: 700; letter-spacing: 0; text-transform: none; color: var(--ink); }
.timecard .band { height: 36px; }
.browse { display: flex; grid-template-columns: none; }
.wordline { display: flex; align-items: baseline; gap: 6px 12px; flex-wrap: wrap; padding: 14px 18px; border-radius: 14px; background: var(--panel); color: var(--ink); text-decoration: none; }
.wordline .ugw { font-family: "Plex Arabic", sans-serif; font-weight: 700; font-size: 1.4rem; }
.wordline .k { margin-inline-start: auto; font-size: .82rem; font-weight: 600; color: var(--accent); }

/* ---------- story paths: where you left off, one to start with, then the periods ---------- */
.resume { flex-direction: row; align-items: center; gap: 14px; background: var(--accent); color: var(--cur-fg); }
.resume .rt2 { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.resume .lbl { color: inherit; opacity: .85; }
.resume .ttl { font-size: 1.06rem; font-weight: 700; }
.resume .prog span { background: var(--cur-fg); opacity: .35; }
.resume .prog span.on { background: var(--cur-fg); opacity: 1; }
.resume .arr { font-size: 1.4rem; }
.pgroups { display: flex; flex-direction: column; }
.pgroups > h2 { font-size: 1.25rem; margin-bottom: 10px; }
.pgrp { border-top: 1px solid var(--line); scroll-margin-top: 80px; }
.pgrp[open] { border-top: 2px solid var(--ink); }
.pgrp > summary { list-style: none; display: flex; align-items: center; gap: 12px; min-height: 76px; cursor: pointer; }
.pgrp > summary::-webkit-details-marker { display: none; }
.pgrp[open] > summary > .i { transform: rotate(180deg); }
.pgrp .gt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.pgrp .gt .ttl { font-weight: 700; font-size: 1.06rem; }
.pgrp .gt .k, .prow .k { font-size: .88rem; color: var(--muted); }
.stack { display: flex; }
.stack .th + .th { margin-inline-start: -24px; box-shadow: 0 0 0 2px var(--page); }
.prows { list-style: none; margin: 0; padding: 0 0 10px; }
.prow { display: flex; align-items: center; gap: 12px; min-height: 68px; color: var(--ink); text-decoration: none; }
.prow .pt { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.prow .ttl { font-weight: 600; line-height: 1.25; }
.prows li.here .k { color: var(--accent); font-weight: 600; }

/* ---------- a path's stops along one line ---------- */
.route { list-style: none; margin: 0; padding: 0; }
.stp { display: grid; grid-template-columns: 52px 56px minmax(0, 1fr); align-items: center; min-height: 76px; color: var(--ink); text-decoration: none; }
.stp .yr { font-family: var(--serif); font-weight: 700; font-size: 1.02rem; line-height: 1.2; text-align: end; }
.nd { position: relative; align-self: stretch; display: flex; align-items: center; justify-content: center; }
.nd::before { content: ""; position: absolute; top: 0; bottom: 0; left: 50%; width: 2px; margin-left: -1px; background: var(--dashed); }
.route li:first-child .nd::before { top: 50%; }
.route li:last-child .nd::before { bottom: 50%; }
.nd i { position: relative; display: flex; align-items: center; justify-content: center; width: 14px; height: 14px; border-radius: 50%; background: var(--page); border: 3px solid var(--dot-muted); font-style: normal; }
.nd.q i { width: 24px; height: 24px; border: 0; background: var(--ink); color: var(--page); font-weight: 700; font-size: .85rem; }
.nd.av img { position: relative; display: block; width: 48px; height: 48px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 3px var(--page); }
.nd.band i { width: 14px; height: 44px; border-radius: 7px; border: 0; background: var(--accent); }
.stp .tx { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding: 10px 0; }
.is-state .tx { margin: 4px 0; padding: 10px 14px; border-radius: 12px; background: var(--tag); color: var(--tag-ink); }
.stp .ttl { font-weight: 700; line-height: 1.25; }
.stp .hk { font-size: .88rem; line-height: 1.35; color: var(--muted); }
.is-state .hk { color: inherit; }
.route li.done .nd::before { background: var(--accent); }
.route li.done .nd:not(.av):not(.band) i { width: 22px; height: 22px; border: 0; background: var(--accent); color: var(--cur-fg); font-size: 0; font-weight: 700; }
.route li.done .nd:not(.av):not(.band) i::after { content: "✓"; font-size: .8rem; }
.route li.done .ttl { font-weight: 600; color: var(--muted); }
.route li.done .hk { display: none; }
.route li.now .stp { margin: 6px 0; padding-inline-end: 12px; border: 2px solid var(--ink); border-radius: 18px; background: var(--card); grid-template-columns: 50px 56px minmax(0, 1fr); }
.route li.now .nd::before { display: none; }
.route li.now .ttl { font-size: 1.12rem; }

/* ---------- event: the story first ---------- */
.story { display: flex; flex-direction: column; gap: 16px; max-width: 720px; }
.dateline { font-size: .95rem; font-weight: 600; color: var(--accent); }
.story h1 { margin-top: -8px; }
.story .lead { font-family: var(--serif); font-size: 1.25rem; line-height: 1.5; }
.story .more { font-family: var(--serif); font-size: 1.1rem; line-height: 1.6; }
.part h2 { font-size: 1.35rem; margin: 12px 0 8px; }
.part p { font-family: var(--serif); font-size: 1.1rem; line-height: 1.65; margin: 0 0 10px; }
.part p.note { font-family: var(--sans); font-size: .82rem; line-height: 1.45; }
/* Short rows: the arrow stays near the name, not across a wide empty column (owner, 2026-11-16). */
.whos { list-style: none; margin: 0; padding: 0; max-width: 560px; }
.who { display: flex; align-items: center; gap: 12px; min-height: 68px; color: var(--ink); text-decoration: none; }
.who .th { border-radius: 50%; }
.who .tx { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.who .ttl { font-weight: 700; font-size: 1.06rem; }
.who .k { font-size: .88rem; color: var(--muted); }
.who .arr { font-size: 1.2rem; color: var(--accent); }
.vwrap { display: flex; flex-direction: column; gap: 10px; }
.vchain { position: relative; list-style: none; margin: 0; padding: 0; padding-inline-start: 28px; display: flex; flex-direction: column; gap: 8px; }
.vchain::before { content: ""; position: absolute; inset-inline-start: 7px; top: 18px; bottom: 18px; width: 2px; background: var(--accent); }
.vchain li { position: relative; }
.vchain li::before { content: ""; position: absolute; inset-inline-start: -28px; top: 16px; width: 16px; height: 16px; border-radius: 50%; background: var(--page); border: 3px solid var(--accent); }
.vchain li.cur::before { background: var(--accent); }
.vchain .in { display: flex; flex-direction: column; gap: 2px; padding: 10px 14px; border-radius: 14px; color: var(--ink); text-decoration: none; }
.vchain a.in { background: var(--card); border: 1px solid var(--line); }
.vchain li.cur .in { padding-inline-start: 0; }
.vchain .when { font-size: .85rem; font-weight: 600; color: var(--accent); }
.vchain li.cur .when { color: var(--muted); }
.vchain .ttl { font-weight: 700; line-height: 1.3; }
.maprow { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 10px 16px; border-radius: 14px; background: var(--panel); color: var(--ink); text-decoration: none; }
.maprow .ttl { font-weight: 600; }
.maprow .k { margin-inline-start: auto; font-size: .82rem; color: var(--muted); white-space: nowrap; }
.fine { display: flex; flex-direction: column; gap: 2px; }
.fine a { color: var(--muted); }

/* ---------- states: one chart of all of them, then a row each with its flag ---------- */
.sover { display: flex; flex-direction: column; gap: 6px; padding: 16px 14px 12px; border-radius: 20px; background: var(--hero); color: var(--hero-fg); }
.schart { position: relative; --lh: 14px; height: calc(var(--lanes) * var(--lh) + 12px); }
.schart .col { position: absolute; top: 0; bottom: 0; width: 25%; border-left: 1px solid var(--hero-line); }
.schart .c1 { left: 0; border-left: 0; } .schart .c2 { left: 25%; } .schart .c3 { left: 50%; } .schart .c4 { left: 75%; }
.schart .c2, .schart .c4 { background: rgba(255, 255, 255, .05); }
.ob { position: absolute; top: calc(var(--ln) * var(--lh) + 6px); height: calc(var(--lh) - 4px); min-width: 5px; border-radius: 5px; overflow: hidden; background: var(--hero-k); color: #1B1512; text-decoration: none; }
.ob.pale { background: color-mix(in srgb, var(--hero-k) 38%, transparent); color: var(--hero-fg); }
.ob span { display: none; }
.sticks { position: relative; height: 18px; font-size: .75rem; color: var(--hero-sub); }
.sticks bdi { position: absolute; top: 0; transform: translateX(-50%); white-space: nowrap; }
.sticks .t0 { left: 0; transform: none; } .sticks .t1 { left: 25%; } .sticks .t2 { left: 50%; } .sticks .t3 { left: 75%; } .sticks .t4 { right: 0; transform: none; }
.sover .note { color: var(--hero-sub); }
.slist { list-style: none; margin: 0 0 8px; padding: 0; display: flex; flex-direction: column; }
.slist li { scroll-margin-top: 90px; }
.srow2 { display: flex; align-items: flex-start; gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.slist li:target .srow2 { margin-inline: -10px; padding-inline: 10px; border-radius: 14px; background: var(--tag); }
.sf { flex: 0 0 96px; display: flex; justify-content: center; }
.flag { display: flex; flex-direction: column; align-items: center; gap: 6px; margin: 0; }
.sf .flag img { display: block; width: 96px; height: auto; border-radius: 2px; box-shadow: 0 1px 4px rgba(0, 0, 0, .3); }
.flag .fy { font-size: .75rem; line-height: 1.25; text-align: center; color: var(--muted); }
.flag.none svg { width: 84px; height: 56px; overflow: visible; }
.flag.none .pole { stroke: var(--dot-muted); stroke-width: 3; stroke-linecap: round; fill: none; }
.flag.none .cloth { fill: var(--card); stroke: var(--dashed); stroke-width: 2; stroke-dasharray: 5 4; stroke-linejoin: round; }
.flag.none text { fill: var(--dot-muted); font-family: var(--serif); font-weight: 700; font-size: 24px; }
.st { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.st .ttl { font-family: var(--serif); font-weight: 700; font-size: 1.15rem; line-height: 1.25; }
.st .k { font-size: .85rem; color: var(--muted); }
.st .sub { margin-top: 4px; font-size: .92rem; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.flags { display: flex; flex-wrap: wrap; gap: 16px 24px; margin-top: 4px; }
.flags .flag { align-items: flex-start; max-width: 260px; }
.flags img { display: block; height: 52px; width: auto; border-radius: 2px; box-shadow: 0 1px 4px rgba(0, 0, 0, .3); }
.flags figcaption { display: flex; flex-direction: column; gap: 1px; font-size: .75rem; color: var(--muted); }
.flags figcaption .fk { font-weight: 600; color: var(--ink); }
.flags figcaption a { color: var(--muted); }
/* a state's own page: no boxes */
.story.state { max-width: none; gap: 24px; }
.shead { display: flex; flex-direction: column-reverse; gap: 16px; }
.sh-t { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.scols, .sside, .smain { display: flex; flex-direction: column; gap: 24px; min-width: 0; }
.sside > section, .smain > section { display: flex; flex-direction: column; gap: 10px; }
.sside > section > h2, .smain > section > h2 { font-size: 1.35rem; }
.story .flags { margin: 0 0 4px; }
.story .tline .erow:last-child .rail::after { visibility: hidden; }
.shead.fig { flex-direction: column; }
.shead .pic .pf { max-height: 340px; }
.sside .side-pic { display: none; }
.sside .faces { flex-wrap: wrap; overflow: visible; margin: 0; padding: 0; gap: 16px 12px; }
.sside .face { flex-basis: 72px; }
.sside .face img, .sside .face .ini { width: 72px; height: 72px; }
.smain .htiles .cover { min-height: 200px; border-radius: 14px; }
.smain .lifeline { max-width: 720px; }
.smain .part, .smain .dispute, .smain details.sources, .smain .tline { max-width: 760px; }
/* The label column is as wide as its longest label, up to 45 %, so "araştırdığı yer" stays on one line. */
.cspans { margin: 0; display: grid; grid-template-columns: fit-content(45%) minmax(0, 1fr); column-gap: 16px; }
.cspans div { display: grid; grid-column: 1 / -1; grid-template-columns: subgrid; padding: 12px 0; border-top: 1px solid var(--line); }
.cspans dt { font-family: var(--serif); font-weight: 700; line-height: 1.5; }
.cspans dd { margin: 0; line-height: 1.9; }
.cspans a { color: var(--ink); text-decoration-color: var(--dashed); text-underline-offset: 3px; }
.story .faces { align-items: flex-start; }
.face .ini { display: flex; align-items: center; justify-content: center; width: 84px; height: 84px; border-radius: 50%; background: var(--soft); color: var(--dot-muted); font-family: var(--serif); font-size: 1.8rem; font-weight: 700; }
.nbs { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 8px 32px; }
.nbs h3 { font-family: var(--sans); margin: 0 0 2px; }
.nb2 { display: flex; align-items: center; gap: 14px; min-height: 60px; padding: 6px 0; color: var(--ink); text-decoration: none; }
/* The flag leads the row (owner, 2026-11-16); a row without one keeps its place so the names line up. */
.nb2 .flag { flex: 0 0 56px; }
/* Flags sit at the end of a row, so the names line up whether a state has a flag or not (owner, 2026-11-15). */
.srow2 .sf { order: 2; margin-inline-start: auto; }
.nb2 .flag img { display: block; width: 56px; height: auto; border-radius: 2px; box-shadow: 0 1px 4px rgba(0, 0, 0, .3); }
.nb2 .flag.none svg { width: 54px; height: 36px; }
.nb2 .tx { display: flex; flex-direction: column; min-width: 0; }
.nb2 .ttl { font-weight: 700; line-height: 1.25; }
.nb2 .k { font-size: .85rem; color: var(--muted); }
@media (hover: hover) { .srow2:hover .ttl { color: var(--accent); } .ob:hover { background: var(--hero-fg); } }

/* ---------- objects: a museum wall in the reader's theme (owner, 2026-11-16, draft D8 A; was dark in both) ---------- */
.olead .oi, .otile img { box-shadow: 0 10px 24px rgba(42,33,28,.16); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .olead .oi, :root:not([data-theme="light"]) .otile img { box-shadow: none; } }
:root[data-theme="dark"] .olead .oi, :root[data-theme="dark"] .otile img { box-shadow: none; }
.olead { display: flex; flex-direction: column; gap: 14px; margin-inline: -16px; color: var(--ink); text-decoration: none; }
.olead .oi { width: 100%; max-height: 320px; }
.olead .ot { display: flex; flex-direction: column; gap: 4px; padding: 0 16px; }
.olead .k, .otile .k { font-size: .85rem; color: var(--muted); }
.olead .h1like { font-family: var(--serif); font-weight: 700; font-size: 1.9rem; line-height: 1.15; }
.olead .sub { font-size: 1rem; line-height: 1.5; color: var(--muted); }
.wall { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 14px; }
.wall li { break-inside: avoid; margin-bottom: 22px; }
.otile { display: flex; flex-direction: column; gap: 2px; color: var(--ink); text-decoration: none; }
.otile img { display: block; width: 100%; height: auto; border-radius: 4px; margin-bottom: 6px; background: var(--soft); }
.otile .ttl { font-weight: 600; font-size: .95rem; line-height: 1.25; }
.cover { display: flex; flex-direction: column; justify-content: space-between; gap: 40px; min-height: 190px; padding: 16px 14px; margin-bottom: 6px; border-radius: 4px; background: var(--accent); color: var(--cur-fg); }
.cover bdi { font-size: .82rem; }
.cover b { font-family: var(--serif); font-size: 1.4rem; line-height: 1.15; }

/* ---------- time: the year leads ---------- */
.yearhero { display: flex; flex-direction: column; gap: 14px; padding: 22px 16px 18px; border-radius: 20px; background: var(--hero); color: var(--hero-fg); }
.yearhero .yearpick { justify-content: space-between; }
.rbtn { flex: none; width: 52px; height: 52px; border-radius: 50%; border: 1px solid var(--hero-line); background: none; color: inherit; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.rbtn.fw .i, [dir="rtl"] .rbtn:not(.fw) .i { transform: scaleX(-1); }
[dir="rtl"] .rbtn.fw .i { transform: none; }
.yearhero .yearbox { flex: 1; flex-direction: column; gap: 0; min-height: 0; padding: 0; background: none; }
.yearhero .yearbox .yl { color: var(--hero-sub); }
.yearhero .yearbox input { width: 100%; max-width: 230px; font-family: var(--serif); font-size: 4rem; line-height: 1.05; color: inherit; -moz-appearance: textfield; appearance: textfield; }
.yearhero .yearbox input::-webkit-inner-spin-button, .yearhero .yearbox input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.yearhero .slider { padding: 6px 0 0; }
.yearhero .band .era.cur { outline: 0; background: var(--hero-k); }
.yearhero .slider input[type=range]::-webkit-slider-thumb { width: 44px; height: 44px; border-radius: 50%; background: var(--hero-fg); border: 4px solid var(--hero); margin-top: -6px; }
.yearhero .slider input[type=range]::-moz-range-thumb { width: 36px; height: 36px; border-radius: 50%; background: var(--hero-fg); border: 4px solid var(--hero); }
.yearhero .scale { color: var(--hero-sub); }
/* The year bar (draft D4 A): a lane per state in its own colour; a needle and a knob at the year. The range input lies
   over the lanes, transparent, with a 44px thumb so its travel matches the 22px inset of the lanes and the scale. */
.tlanes { position: relative; padding: 14px 22px 40px; touch-action: pan-y; }
.lanes { position: relative; height: calc(var(--n, 6) * 14px); }
.ln { position: absolute; top: calc(var(--ln) * 14px); height: 10px; min-width: 4px; border-radius: 5px; opacity: .32; transition: opacity .15s; }
.ln.on { opacity: 1; }
.c0 { background: #7CC0AE; } .c1 { background: #E0A458; } .c2 { background: #9DB4E0; } .c3 { background: #E08F8F; } .c4 { background: #B9C97A; }
.c5 { background: #C7A0D8; } .c6 { background: #E6C86E; } .c7 { background: #86C8DC; } .c8 { background: #DDA07E; } .c9 { background: #A7D6A0; }
.tlanes input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; background: transparent; -webkit-appearance: none; appearance: none; cursor: pointer; }
.tlanes input::-webkit-slider-runnable-track { height: 100%; background: transparent; }
.tlanes input::-webkit-slider-thumb { -webkit-appearance: none; width: 44px; height: 100%; background: transparent; border: 0; }
.tlanes input::-moz-range-track { height: 100%; background: transparent; }
.tlanes input::-moz-range-thumb { width: 44px; height: 100%; background: transparent; border: 0; }
.tlanes input:focus-visible { outline: none; }
.needle { position: absolute; top: 4px; bottom: 30px; width: 3px; margin-left: -1.5px; border-radius: 2px; background: var(--hero-fg); pointer-events: none; }
.knob { position: absolute; bottom: 4px; width: 28px; height: 28px; margin-left: -14px; border-radius: 50%; background: var(--hero-fg); border: 4px solid var(--hero);
  box-sizing: border-box; pointer-events: none; }
.tlanes input:focus-visible ~ .knob { outline: 3px solid var(--hero-k); outline-offset: 2px; }
.lscale { position: relative; height: 16px; font-size: .75rem; color: var(--hero-sub); }
.lscale bdi { position: absolute; transform: translateX(-50%); white-space: nowrap; }
.lscale .m0 { transform: none; } .lscale .mend { right: 0; }
.tlanes + .lscale { margin-top: -6px; }
@media (max-width: 600px) { .lscale .m3 { display: none; } }
@media (min-width: 960px) { .lanes { height: calc(var(--n, 6) * 18px); } .ln { top: calc(var(--ln) * 18px); height: 13px; } }
.lanenames { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 12px; min-height: 36px; }
.lanenames a { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 12px; border-radius: 999px; background: rgba(255,255,255,.08);
  color: var(--hero-fg); font-weight: 600; font-size: .88rem; text-decoration: none; }
.lanenames a i { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.jumps .chip[aria-current] { background: var(--inv); border-color: var(--inv); color: var(--inv-fg); font-weight: 600; }
.yview { display: flex; flex-direction: column; gap: 26px; }
.ysec { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.ysec h2 { font-size: 1.2rem; }
.rulers { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.ruler { display: flex; flex-direction: column; gap: 6px; padding: 14px; border-radius: 16px; background: var(--panel); color: var(--ink); text-decoration: none; }
.ruler:first-child { background: var(--accent); color: var(--cur-fg); }
.ruler .ttl { font-family: var(--serif); font-weight: 700; font-size: 1.2rem; line-height: 1.2; }
.ruler .n { font-size: .88rem; line-height: 1.4; opacity: .88; }
.maplink { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; font-weight: 600; text-decoration: none; }
.yev, .alive { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.yev a { display: flex; align-items: center; gap: 14px; min-height: 76px; padding: 8px 0; color: var(--ink); text-decoration: none; }
.yev .th { flex: 0 0 72px; width: 72px; height: 72px; border-radius: 10px; }
.yev .th.none { display: none; }
.yev .tx, .alive .tx { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.yev .rel { font-size: .75rem; font-weight: 700; color: var(--muted); }
.yev .rel.now { color: var(--accent); }
.yev .ttl { font-family: var(--serif); font-weight: 700; font-size: 1.12rem; line-height: 1.25; }
.yev .n, .alive .n { font-size: .88rem; color: var(--muted); }
/* Who was alive (draft S6): face, name and role, the age on the same line at the end ("52 yaşında"). */
.alive a { display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 8px 0; border-top: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.alive img, .alive .ini { flex: none; width: 48px; height: 48px; border-radius: 50%; object-fit: cover; background: var(--soft); }
.alive .ini { display: flex; align-items: center; justify-content: center; color: var(--dot-muted); font-family: var(--serif); font-weight: 700; font-size: 1.3rem; }
.alive .tx { flex: 1; }
.alive .ttl { font-family: var(--serif); font-weight: 700; font-size: 1.05rem; line-height: 1.25; }
.alive .age { flex: none; white-space: nowrap; font-size: .9rem; color: var(--muted); }
.alive .age b { font-family: var(--serif); font-size: 1.6rem; line-height: 1; color: var(--accent); }
/* Another century (draft S6 A): chips that wrap, the current century dark. */
.cjump { display: flex; flex-direction: column; gap: 12px; }
.cjump h2 { margin: 0; }
.cchips { display: flex; flex-wrap: wrap; gap: 8px; }
.cchips a { display: inline-flex; align-items: center; justify-content: center; min-width: 52px; min-height: 44px; padding: 0 10px; box-sizing: border-box; border-radius: 999px; border: 1px solid var(--line); background: var(--card); color: var(--ink); text-decoration: none; font-weight: 600; font-size: .9rem; }
.cchips a[aria-current] { background: var(--ink); border-color: var(--ink); color: var(--page); }

/* ---------- search results ---------- */
.sresults { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.sres { display: flex; align-items: center; gap: 12px; min-height: 68px; padding: 8px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.sres .th { flex: 0 0 48px; width: 48px; height: 48px; border-radius: 8px; }
.th.kH { border-radius: 50%; }
.sres .tx { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.sres .ttl { font-weight: 600; }
.sres .k { font-size: .8rem; color: var(--accent); }
.sres .sub { font-size: .85rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

@media (min-width: 960px) {
  .top .wrap { padding: 12px 24px; gap: 20px; }
  .brand { margin-inline-end: 8px; }
  .wm { font-size: 30px; }
  .mmenu, .mbtns { display: none; }
  .menu { display: flex; align-items: center; gap: 24px; }
  .menu > a, .menu .dd > summary { color: var(--ink); text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; gap: 4px; font-weight: 600; white-space: nowrap; }
  .menu > a[aria-current], .menu .dd[open] > summary { color: var(--accent); }
  .menu .dd[open] > summary .i { transform: rotate(180deg); }
  .menu .pop { inset-inline: 0 auto; }
  .hsearch { display: block; position: relative; flex: 1 1 320px; max-width: 460px; margin-inline-start: auto; }
  .hsearch label { display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); color: var(--muted); }
  .hsearch label:focus-within { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
  .hsearch input { border: 0; outline: none; font: inherit; width: 100%; background: transparent; color: var(--ink); }
  .sugg { inset-inline: 0; padding: 6px 0; }
  .sugg a { display: flex; align-items: center; gap: 12px; min-height: 48px; padding: 0 14px; color: var(--ink); text-decoration: none; }
  .sugg a.on, .sugg a:hover { background: var(--soft); }
  .sugg .th { flex: 0 0 32px; width: 32px; height: 32px; border-radius: 6px; }
  .sugg .th.kH { border-radius: 50%; }
  .sugg b { flex: 1; min-width: 0; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .sugg .k { font-size: .8rem; color: var(--muted); white-space: nowrap; }
  .sugg a.all { justify-content: space-between; margin-top: 4px; border-top: 1px solid var(--line); font-weight: 600; color: var(--accent); }
  .sugg .note { padding: 10px 14px; }
  a.wide-only, .langdd.wide-only { display: inline-flex; }
  p.wide-only { display: block; }
  .langdd > summary { height: 44px; padding: 0 12px; border: 1px solid var(--line); border-radius: 12px; font-weight: 600; }
  .langdd[open] > summary .i { transform: rotate(180deg); }
  .langdd .pop { min-width: 280px; }
  .phero { flex-direction: row; }
  .phero .ph-img { flex: 1 1 50%; }
  .phero .ph-img { aspect-ratio: auto; height: 440px; max-height: none; }
  .phero .ph-t { flex: 1 1 50%; justify-content: center; gap: 12px; padding: 40px; }
  .ph-ttl { font-size: 2.6rem; }
  .hometop { display: grid; grid-template-columns: minmax(0, 2.4fr) minmax(0, 1fr); gap: 24px; align-items: stretch; }
  .leaf { flex-direction: column; align-items: flex-start; justify-content: center; padding: 28px; border-radius: 20px; background: var(--panel); }
  .lt { gap: 6px; }
  .lt .ttl { font-size: 1.6rem; }
  .lt .sub { display: block; font-size: .95rem; color: var(--muted); }
  .faces { gap: 24px; margin: 0; padding: 0; }
  .face { flex-basis: 96px; }
  .face img, .face .ini { width: 96px; height: 96px; }
  .story .faces { flex-wrap: wrap; gap: 20px 16px; }
  .sh-t { gap: 18px; }
  .scols { flex-direction: row; align-items: flex-start; gap: 64px; }
  /* Record pages (drafts D5, D6): two columns from the top, each as tall as its own content. The side column spans
     both rows; the head's row is only as tall as the head, the rest goes to the story's row. */
  .scols.rp { display: grid; grid-template-columns: minmax(0, 1fr) 380px; grid-template-rows: auto 1fr; gap: 32px 64px; align-items: start; }
  .scols.rp > .shead { grid-column: 1; grid-row: 1; }
  .scols.rp > .smain { grid-column: 1; grid-row: 2; }
  .scols.rp > .sside { grid-column: 2; grid-row: 1 / span 2; }
  .story.one .scols.rp { grid-template-columns: minmax(0, 760px); }
  .scols.rp > .shead > :not(.sh-t) { display: none; }
  .sside .side-pic { display: block; }
  .sside .side-pic .flags img { height: 120px; }
  .sside .side-pic .gallery { flex-direction: column; overflow: visible; margin: 0; padding: 0; gap: 20px; }
  .sside .side-pic .gallery .pic { flex: none; }
  .sside .side-pic .gallery .pic .pf { height: 300px; }
  .sside .side-pic .pic .pf { max-height: 440px; }
  .smain .htiles { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .smain { flex: 1 1 0; gap: 32px; }
  .sside { flex: 0 0 380px; gap: 32px; }
  .sside .nbs { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .sside .cspans { grid-template-columns: minmax(0, 1fr); }
  .sside .cspans div { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .htiles { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
  .versus { padding: 32px 0 16px; }
  .versus h2 { font-size: 1.75rem; }
  .vs { max-width: 720px; }
  .vs .v { font-size: 2.6rem; }
  .timecard { border: 0; padding: 0; }
  .timecard .band { height: 48px; }
  .prows { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 0 28px; }
  .route, .pathhead { max-width: 760px; }
  .stp { grid-template-columns: 72px 64px minmax(0, 1fr); }
  .route li.now .stp { grid-template-columns: 70px 64px minmax(0, 1fr); }
  .story { gap: 20px; }
  .story .lead { font-size: 1.45rem; }
  .story .more, .part p { font-size: 1.2rem; }
  .story .pic .pf { max-height: 400px; }
  .sover { padding: 24px 28px 16px; }
  .schart { --lh: 26px; }
  .ob span { display: block; padding: 0 8px; font-size: .75rem; font-weight: 600; line-height: 22px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .slist { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 48px; }
  .srow2 { gap: 20px; height: 100%; }
  .sf { flex-basis: 120px; }
  .sf .flag img { width: 120px; }
  .st .ttl { font-size: 1.3rem; }
  .olead { flex-direction: row; align-items: center; gap: 36px; margin: 0; }
  .olead .oi { flex: 1 1 55%; }
  .olead .oi { max-height: 440px; border-radius: 6px; }
  .olead .ot { flex: 1 1 45%; gap: 8px; padding: 0; }
  .olead .h1like { font-size: 2.6rem; }
  .olead .sub { font-size: 1.12rem; }
  .wall { columns: 4; column-gap: 20px; }
  .yearhero { padding: 32px 40px 24px; }
  .yearhero .yearpick { justify-content: center; gap: 24px; }
  .yearhero .yearbox { flex: 0 1 300px; }
  .yearhero .yearbox input { max-width: none; font-size: 5rem; }
  .yview { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 36px; align-items: start; }
  .jumps.chips.scroll { overflow: visible; }
}

/* ---------- fixes from the full review (ADR 0013) ---------- */
.band .era.nolabel span { visibility: hidden; }
a.timecard { display: flex; color: var(--ink); text-decoration: none; }
.timecard .h2like { font-family: var(--serif); font-size: 1.25rem; font-weight: 700; }
.timecard .go { color: var(--accent); }
.go { min-height: 44px; }
.cal .mo { font-size: .75rem; }
.cta .ttl { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; line-height: 1.3; }
.versus h2 a { display: block; padding: 6px 0; }
.srclist li { padding: 6px 0; }
.srclist a { display: inline-block; padding: 10px 0; }
.slider input[type=range] { height: 44px; }
.prow2 { display: flex; align-items: flex-start; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.prow2 img, .prow2 .ini { flex: 0 0 64px; width: 64px; height: 64px; border-radius: 50%; object-fit: cover; background: var(--soft); }
.prow2 .ini { display: flex; align-items: center; justify-content: center; color: var(--dot-muted); font-family: var(--serif); font-size: 1.6rem; font-weight: 700; }
.listmain .slist { margin-top: 4px; }
.pnav { display: flex; gap: 8px; overflow-x: auto; margin-inline-end: -16px; padding-inline-end: 16px; scrollbar-width: none; }
.pnav .lbl { display: none; }
.pnav a { flex: none; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--card); color: var(--ink); text-decoration: none; font-size: .875rem; white-space: nowrap; }
.pnav a span:last-child { color: var(--muted); font-size: .82rem; }
.stop2 .wide-side { display: none; }
.route.mini .stp { min-height: 44px; grid-template-columns: 48px 32px minmax(0, 1fr); }
.route.mini .stp .yr { font-size: .85rem; }
.route.mini .nd i { width: 10px; height: 10px; border-width: 2px; }
.route.mini .tx { padding: 6px 0; }
.route.mini .ttl { font-size: .9rem; font-weight: 600; }
.route.mini li.done .nd:not(.av):not(.band) i { width: 14px; height: 14px; }
.route.mini li.done .nd i::after { font-size: .55rem; }
.route.mini li.now .stp { margin: 4px 0; padding: 0; border-width: 2px; border-radius: 12px; grid-template-columns: 46px 32px minmax(0, 1fr); }
.route.mini li.now .ttl { font-size: .95rem; }
.sside h2 a { color: var(--ink); text-decoration: none; }
@media (max-width: 959px) {
  .ob { pointer-events: none; }
}
@media (min-width: 960px) {
  .pnav { flex-direction: column; overflow: visible; margin: 0; padding: 14px 10px; }
  .pnav .lbl { display: block; }
  .pnav a { justify-content: space-between; min-height: 40px; padding: 0 12px; border: 0; border-radius: 8px; background: none; font-size: .9rem; }
  .stop2 .wide-side { display: flex; position: sticky; top: 96px; }
  .listmain .slist { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .prow2 { gap: 18px; }
  .prow2 img, .prow2 .ini { flex-basis: 80px; width: 80px; height: 80px; }
}

/* Place names in the text (ADR 0014, draft H1): a dotted underline in the accent; the map panel opens on a tap. */
a.pl { color: var(--accent); font-weight: 600; text-decoration: underline dotted; text-decoration-thickness: 2px; text-underline-offset: 4px; }
a.pl:hover { text-decoration-style: solid; }
.lifeline .when a { color: inherit; text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 4px; }
.lifeline .when a:hover { color: var(--accent); }

/* The map card (drafts D1, D2): a popover by the tapped place name, as tall as its content; the page is not dimmed.
   mapsheet.mjs places it under the word (above it when there is no room) and points the arrow at the word. */
.mpop { position: absolute; inset: auto; margin: 0; padding: 0; width: min(380px, calc(100vw - 24px)); overflow: visible;
  background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 14px 40px rgba(0,0,0,.22); }
.mp-arrow { position: absolute; top: -8px; left: var(--ax, 40px); width: 14px; height: 14px; margin-left: -7px; background: var(--card);
  border-left: 1px solid var(--line); border-top: 1px solid var(--line); transform: rotate(45deg); }
.mpop.up .mp-arrow { top: auto; bottom: -8px; transform: rotate(225deg); }
.ms-map { position: relative; margin: 10px 10px 0; height: 190px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: var(--panel); }
/* More specific than MapLibre's own .maplibregl-map { position: relative }, which would fold the box to nothing. */
.ms-map .ms-canvas { position: absolute; inset: 0; }
.ms-msg { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; margin: 0; color: var(--muted); font-size: .94rem; }
.ms-msg[hidden] { display: none; }
.ms-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 12px; }
.ms-head { display: flex; align-items: flex-start; gap: 8px; }
.ms-t { flex: 1; font-family: var(--serif); font-size: 1.4rem; line-height: 1.15; margin: 0; outline: none; }
.ms-close { flex: none; width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; padding: 0; border: 1px solid var(--line);
  border-radius: 12px; background: transparent; color: var(--ink); cursor: pointer; }
.ms-body h3 { font-family: var(--sans); font-size: .8rem; font-weight: 600; color: var(--muted); margin: 0 0 6px; }
.ms-body .chips { display: flex; flex-wrap: wrap; gap: 6px; }
.ms-body .chips .chip { font: inherit; font-size: .88rem; cursor: pointer; min-height: 36px; padding: 0 12px; }
.ms-here ul { list-style: none; margin: 0; padding: 0; }
.ms-here li a { display: flex; gap: 10px; align-items: baseline; min-height: 40px; padding: 6px 0; border-bottom: 1px solid var(--line); color: inherit; text-decoration: none; font-size: .94rem; }
.ms-here li:last-child a { border-bottom: 0; }
.ms-here .w { color: var(--accent); font-weight: 700; font-size: .85rem; min-width: 5.5em; flex: none; }
.ms-open { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 46px; padding: 0 16px; background: var(--accent);
  color: var(--cur-fg); border-radius: 12px; font-weight: 700; text-decoration: none; }
/* In the map card's title row: the place's name, the way to Xeritem, close (owner, 2026-11-17). */
.ms-head { align-items: center; }
.ms-head .ms-open { flex: none; min-height: 44px; padding: 0 14px; gap: 6px; font-size: .95rem; }
@media (max-width: 600px) { .ms-map { height: 170px; } }
/* Markers on the panel's map: the place itself larger, the page's other places small and tappable. */
.mk { display: flex; align-items: center; gap: 6px; cursor: pointer; }
.mk i { width: 10px; height: 10px; border-radius: 50%; background: #8C7A68; border: 2px solid #FFFDF8; flex: none; }
.mk b { font: 600 12px/1.2 Inter, system-ui, sans-serif; color: #2A211C; background: rgba(255,253,248,.88); padding: 2px 6px; border-radius: 6px; white-space: nowrap; }
.mk.main { cursor: default; }
.mk.nolab b { display: none; }
.mk.main i { width: 16px; height: 16px; background: #2F6A5C; border-width: 3px; }
.mk.main b { font-size: 14px; font-weight: 700; }

/* Home: one line on what the site is (owner, 2026-11-15). */
.hintro { font-family: var(--serif); font-size: 1.15rem; line-height: 1.45; margin: 4px 0 18px; color: var(--muted); max-width: 46ch; }
/* Disputes: the year differences as plain rows under the big questions. */
.lead2 { color: var(--muted); max-width: 62ch; margin: 0 0 8px; }
.qrows { list-style: none; margin: 0; padding: 0; }
.qrows a { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 16px; padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; min-height: 44px; }
.qrows .ttl { font-weight: 600; }
.qrows .k { grid-row: 2; color: var(--muted); font-size: .88rem; }
.qrows .v { grid-row: 1 / span 2; grid-column: 2; align-self: center; max-width: 16rem; text-align: end; color: var(--accent); font-weight: 700; }
.qrows .v > span { display: inline-block; }
/* Big questions (draft T1/T2, owner A): two answers face each other, the preferred one first with a green dot; rules and
   type, no boxes. The desktop puts the question on the left and the two answers side by side. */
.qsec { display: flex; flex-direction: column; margin-top: 8px; }
.qsh { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding-bottom: 6px; border-bottom: 2px solid var(--ink); }
.qsh h2 { margin: 0; }
.qsh .cnt { font-size: .88rem; color: var(--muted); }
.qbig { display: flex; flex-direction: column; gap: 12px; padding: 20px 0 22px; border-bottom: 1px solid var(--line); }
.qbig .k { margin: 0; font-size: .82rem; color: var(--muted); }
.qbig h3 { margin: 4px 0 0; font-family: var(--serif); font-size: 1.4rem; line-height: 1.25; }
.qbig h3 a { color: var(--ink); text-decoration: none; }
.qa { display: flex; flex-direction: column; gap: 6px; }
.qa .qw { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; font-size: .82rem; font-weight: 600; color: var(--muted); }
.qa.pref .qw { color: var(--accent); }
.qa .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex: none; }
.qa .qp, .qa .qk { font-weight: 500; }
.qa .qs { margin: 0; font-family: var(--serif); font-size: 1.02rem; line-height: 1.5; }
.yada { display: flex; align-items: center; gap: 10px; margin: 0; font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.yada::before, .yada::after { content: ""; flex: 1; border-top: 1px solid var(--line); }
.qbig .more { align-self: flex-start; display: inline-flex; align-items: center; min-height: 44px; font-size: .88rem; font-weight: 600; color: var(--accent); text-decoration: none; }
@media (min-width: 960px) {
  .qbig { display: grid; grid-template-columns: 300px minmax(0, 1fr) minmax(0, 1fr); grid-template-areas: "head a b" "more a b";
    grid-template-rows: auto 1fr; gap: 4px 40px; padding: 26px 0; }
  .qhead { grid-area: head; }
  .qa1 { grid-area: a; }
  .qa2 { grid-area: b; padding-inline-start: 40px; margin-inline-start: -20px; border-inline-start: 1px solid var(--line); }
  .qbig .more { grid-area: more; }
  .yada { display: none; }
  .qbig h3 { font-size: 1.6rem; }
  .qrows { columns: 2; column-gap: 48px; }
  .qrows li { break-inside: avoid; }
}
/* On the phone the values take their own line under the question: long dates ("Miladiyedin ilgiriki 206-yil") would not fit beside it. */
@media (max-width: 599px) {
  .qrows a { grid-template-columns: minmax(0, 1fr); }
  .qrows .v { grid-row: auto; grid-column: 1; max-width: none; text-align: start; }
}

/* Swiping between stops (progress.js): the page slides out the way the finger went, then the next stop loads. */
.swipehint { margin: 6px 16px 0; font-size: .85rem; color: var(--muted); text-align: center; }
body.swipe-out-fwd main, body.swipe-out-back main { transition: transform .16s ease-in, opacity .16s ease-in; opacity: .2; }
body.swipe-out-fwd main { transform: translateX(-24%); }
body.swipe-out-back main { transform: translateX(24%); }
[dir="rtl"] body.swipe-out-fwd main { transform: translateX(24%); }
[dir="rtl"] body.swipe-out-back main { transform: translateX(-24%); }
@media (min-width: 960px) { .swipehint { display: none; } }

/* Several pictures on an event page: a row that scrolls sideways, each with its own caption. */
.gallery { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; margin: 16px 0; padding-bottom: 6px; }
.gallery .pic { flex: 0 0 82%; scroll-snap-align: start; margin: 0; }
.gallery .pic .pf { height: 240px; max-height: none; aspect-ratio: auto; }
@media (min-width: 960px) { .gallery .pic { flex-basis: calc(50% - 6px); } .gallery .pic .pf { height: 300px; } }

/* ---------- themes (owner, 2026-11-16, drafts D9, D10): a stele with an arched top, like the two stones of the mark ---------- */
.stelae { list-style: none; margin: 8px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 14px; }
.stl { display: flex; flex-direction: column; gap: 8px; color: var(--ink); text-decoration: none; }
.stf { display: block; aspect-ratio: 3 / 4; border-radius: 999px 999px 14px 14px; overflow: hidden; background: var(--panel); }
.stf.blank { background: var(--tag); }
.stl .tx { display: flex; flex-direction: column; gap: 4px; }
.stl .ttl { font-family: var(--serif); font-weight: 700; font-size: 1.15rem; line-height: 1.2; }
.stl .sum { display: none; font-family: var(--serif); font-size: .95rem; line-height: 1.45; color: var(--muted); }
.stl .k { font-size: .82rem; color: var(--muted); }
.stelae .first { grid-column: 1 / -1; }
.stelae .first .stl { flex-direction: row; align-items: flex-end; gap: 16px; }
.stelae .first .stf { flex: 0 0 42%; }
.stelae .first .ttl { font-size: 1.6rem; }
.stelae .first .sum { display: block; }
@media (hover: hover) { .stl:hover .ttl { color: var(--accent); } }
.stele .pic .pf.fr { aspect-ratio: 3 / 4; max-height: none; border-radius: 999px 999px 16px 16px; }
.stele .pic { max-width: 320px; }
.counts { font-size: .9rem; color: var(--muted); }
.stl-who .th { border-radius: 999px 999px 8px 8px; }
.stl-who .th.ini { background: var(--tag); color: var(--tag-ink); font-family: var(--serif); font-weight: 700; }
/* Events on a strip of time: rows on the phone, a row of cards along a line on the desktop. */
.tstrip { list-style: none; margin: 0; padding: 0; }
.tstrip a { display: grid; grid-template-columns: 72px minmax(0, 1fr) 56px; grid-template-rows: auto auto; column-gap: 12px; align-items: center; min-height: 68px;
  padding: 6px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.tstrip .im { grid-column: 3; grid-row: 1 / span 2; width: 56px; height: 56px; border-radius: 10px; overflow: hidden; background: var(--soft); }
.tstrip .im img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tstrip .im:empty { background: none; }
.tstrip .y { grid-column: 1; grid-row: 1 / span 2; font-weight: 700; color: var(--accent); font-size: .9rem; }
.tstrip .ttl { grid-column: 2; font-weight: 600; line-height: 1.3; }
.tstrip .n { grid-column: 2; font-size: .82rem; color: var(--muted); }
@media (min-width: 960px) {
  .stelae { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 24px; }
  .stelae .first { grid-column: auto; }
  .stelae .first .stl { flex-direction: column; align-items: stretch; gap: 8px; }
  .stelae .first .ttl { font-size: 1.25rem; }
  .stl .sum { display: block; }
  .tstrip { display: flex; gap: 18px; overflow-x: auto; padding: 22px 0 10px; border-top: 2px solid var(--line); scrollbar-width: thin; }
  .tstrip li { flex: 0 0 180px; position: relative; }
  .tstrip li::before { content: ""; position: absolute; top: -29px; left: 0; width: 12px; height: 12px; border-radius: 50%; background: var(--accent); border: 2px solid var(--page); }
  .tstrip a { display: flex; flex-direction: column; gap: 4px; min-height: 0; padding: 0; border: 0; }
  .tstrip .im { width: 100%; height: 104px; order: -1; margin-bottom: 4px; }
  .tstrip .im:empty { background: var(--soft); }
}
/* A name under a face wraps between words, never inside one (owner, 2026-11-16: "Musabaye / v"). */
.face span, .stl .ttl, .who .ttl { overflow-wrap: normal; word-break: normal; hyphens: manual; }

/* ---------- periods and world turning points (ADR 0018, drafts L1–L4) ---------- */
:root { --wbg: #F5E9D2; --wk: #8A5A12; --pin: #F3D9A4; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --wbg: #2E2619; --wk: #E3B866; } }
:root[data-theme="dark"] { --wbg: #2E2619; --wk: #E3B866; }
.wline { display: flex; gap: 10px; align-items: flex-start; margin: 0; padding: 10px 14px; border-radius: 12px; background: var(--wbg); font-size: .92rem; line-height: 1.5; }
.wline .lbl { flex: none; padding-top: 2px; font-size: .7rem; color: var(--wk); }
/* The states chart: lanes in the states' colours, world turning points as dashed lines with a numbered pin (phone) or
   their year and name (desktop); positions and rows in gen.css. */
.sover2 { display: flex; flex-direction: column; gap: 8px; padding: 14px 12px 12px; border-radius: 20px; background: var(--hero); color: var(--hero-fg); }
.schart2 { position: relative; --lh: 13px; padding-top: calc(var(--wm, 2) * 20px + 8px); }
.sbars { position: relative; height: calc(var(--lanes, 8) * var(--lh)); }
.sb { position: absolute; top: calc(var(--ln) * var(--lh) + (var(--lh) - 5px) / 2); height: 5px; min-width: 4px; border-radius: 3px; opacity: .6; text-decoration: none; }
.sb.big { top: calc(var(--ln) * var(--lh) + (var(--lh) - 9px) / 2); height: 9px; opacity: 1; }
.sb.pale { opacity: .35; }
.sb span { display: none; }
.schart2.lit .sb { opacity: .2; } .schart2.lit .sb.on { opacity: 1; }
.wpins { position: absolute; inset: 0; pointer-events: none; }
.wp { position: absolute; top: calc(var(--m) * 20px); bottom: 0; width: 0; padding: 0; border: 0; border-left: 1px dashed rgba(243, 217, 164, .5); background: none; color: #1B1512; font: inherit; }
/* An 18px numbered pin with a 32px tap area around it. */
.wp b { pointer-events: auto; position: absolute; top: -7px; left: -16px; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; cursor: pointer;
  font-size: 10px; font-weight: 700; background: radial-gradient(circle, var(--pin) 9px, transparent 9.5px); }
.wp span { display: none; }
.pticks { position: relative; height: 30px; }
.pticks .pt { position: absolute; top: 0; padding-inline-start: 4px; border-inline-start: 1px solid var(--hero-line); font-size: .68rem; line-height: 1.2; color: var(--hero-sub); }
.pticks .pt b { display: none; }
.sover2 .note { color: var(--hero-sub); font-size: .78rem; }
/* The chart's card: a state's summary, or a turning point with the states that ruled here then. */
.spop { padding: 14px 16px 16px; }
.sp-head { display: flex; align-items: flex-start; gap: 10px; }
.sp-flag { width: 56px; height: auto; border-radius: 2px; box-shadow: 0 1px 4px rgba(0, 0, 0, .3); flex: none; margin-top: 2px; }
.sp-tx { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.sp-tx .k { font-size: .78rem; font-weight: 700; color: var(--wk); }
.sp-t { font-family: var(--serif); font-size: 1.3rem; line-height: 1.15; margin: 0; }
.sp-sub { margin: 8px 0 0; font-family: var(--serif); font-size: .98rem; line-height: 1.5; color: var(--muted); }
.sp-here { margin: 8px 0 0; font-size: .9rem; }
.sp-nav { display: flex; gap: 8px; margin-top: 12px; }
.sp-step { flex: 1; min-height: 44px; border: 1px solid var(--line); border-radius: 12px; background: transparent; color: var(--ink); font: inherit; font-weight: 600; cursor: pointer; }
.spop .ms-open { margin-top: 12px; }
/* The list: the period, what happened in the world, the states with a flag as cards, the others as plain rows. */
.bigstrip .faces { gap: 12px; }
.bsf { flex: 0 0 116px; display: flex; flex-direction: column; gap: 6px; color: var(--ink); text-decoration: none; font-size: .85rem; line-height: 1.25; }
.bsf .flag img { display: block; width: 116px; height: 78px; object-fit: cover; border-radius: 3px; box-shadow: 0 1px 4px rgba(0, 0, 0, .3); }
.bsf bdi { color: var(--muted); font-size: .78rem; }
.sper { display: flex; flex-direction: column; gap: 14px; scroll-margin-top: 90px; }
.sfeats { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.sfeat { display: flex; gap: 14px; align-items: flex-start; padding: 16px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); color: var(--ink); text-decoration: none; scroll-margin-top: 90px; }
.sfeat .flag { flex: none; }
.sfeat .flag img { display: block; width: 72px; height: auto; border-radius: 2px; box-shadow: 0 1px 4px rgba(0, 0, 0, .3); }
.sfeat .tx { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.sfeat .k { font-size: .82rem; color: var(--muted); }
.sfeat .ttl { font-family: var(--serif); font-weight: 700; font-size: 1.25rem; line-height: 1.2; }
.sfeat .sub { font-family: var(--serif); font-size: .95rem; line-height: 1.45; color: var(--muted); }
.srows { list-style: none; margin: 0; padding: 0; }
.srows li { scroll-margin-top: 90px; }
.srow3 { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 12px; row-gap: 2px; padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.srow3 .ttl { font-family: var(--serif); font-weight: 700; font-size: 1.08rem; line-height: 1.25; }
.srow3 .y { font-size: .8rem; color: var(--muted); white-space: nowrap; padding-top: 3px; }
.srow3 .sub { grid-column: 1 / -1; font-family: var(--serif); font-size: .9rem; line-height: 1.45; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.srows li:target .srow3, .sfeat:target { background: var(--tag); }
@media (hover: hover) { .srow3:hover .ttl, .sfeat:hover .ttl { color: var(--accent); } }
/* Events: each period a chapter; its event leads with a picture, then its people, then the events, the rest folded. */
.echap { display: flex; flex-direction: column; gap: 14px; }
.efeat { display: flex; flex-direction: column; border-radius: 18px; overflow: hidden; background: var(--hero); color: var(--hero-fg); text-decoration: none; }
.efeat .efp { height: 190px; }
.efeat .tx { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px 18px; }
.efeat .lbl { color: var(--hero-k); }
.efeat .ttl { font-family: var(--serif); font-weight: 700; font-size: 1.35rem; line-height: 1.2; }
.efeat .sub { font-family: var(--serif); font-size: .98rem; line-height: 1.5; color: var(--hero-sub); }
.eppl { display: flex; flex-direction: column; gap: 8px; }
.emore > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; min-height: 44px; font-weight: 700; color: var(--accent); }
.emore > summary::-webkit-details-marker { display: none; }
.emore > summary::after { content: " ↓"; white-space: pre; }
.emore[open] > summary::after { content: " ↑"; }
@media (min-width: 960px) {
  .sover2 { padding: 22px 28px 16px; }
  .schart2 { --lh: 26px; padding-top: calc(var(--wr, 3) * 18px + 10px); }
  .sb { top: calc(var(--ln) * var(--lh) + (var(--lh) - 9px) / 2); height: 9px; }
  .sb.big { top: calc(var(--ln) * var(--lh) + 3px); height: calc(var(--lh) - 6px); border-radius: 6px; }
  .sb span { display: flex; align-items: center; position: absolute; top: 0; bottom: 0; white-space: nowrap; font-size: .75rem; font-weight: 700; }
  .sb .in { left: 8px; color: #1B1512; }
  .sb .out { left: calc(100% + 6px); color: var(--hero-fg); }
  .sb .left { right: calc(100% + 6px); color: var(--hero-fg); }
  .wp { top: calc(var(--r) * 18px); }
  .wp b { display: none; }
  .wp span { display: block; pointer-events: auto; cursor: pointer; position: absolute; top: 0; left: 4px; white-space: nowrap; font-size: .7rem; font-weight: 700; line-height: 16px; color: var(--pin); }
  .wp.flip span { left: auto; right: 4px; }
  .pticks { height: 36px; }
  .pticks .pt { font-size: .75rem; }
  .pticks .pt b { display: block; color: var(--hero-fg); font-weight: 600; }
  .bigstrip { display: none; }
  .sfeats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .sfeats.one { grid-template-columns: minmax(0, 1fr); }
  .sfeat { padding: 18px; gap: 16px; }
  .sfeat .flag img { width: 96px; }
  .sfeat .ttl { font-size: 1.4rem; }
  .srows { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 40px; }
  .srow3 .sub { -webkit-line-clamp: 1; }
  .efeat { flex-direction: row; }
  .efeat .efp { flex: 0 0 300px; height: auto; min-height: 220px; }
  .efeat .tx { padding: 22px 24px; justify-content: center; }
  .efeat .ttl { font-size: 1.75rem; }
  .ecols { columns: 2; column-gap: 32px; }
  .ecols li { break-inside: avoid; }
}
@media (max-width: 600px) { .pticks .pt:first-child bdi { visibility: hidden; } }
.pticks .pt { width: calc(12.5% - 6px); }
.pticks .pt b { white-space: normal; }

/* An object's photos (ADR 0019, draft L5): a strip that swipes sideways, each photo whole in a frame of one height on
   its blurred copy, "n / N" and the neighbour buttons on it, its caption and credit under it; thumbnails below. The
   buttons and thumbnails come with ui.js (`.live`); without it the strip still swipes. */
.ogal { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.ostrip { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.ostrip::-webkit-scrollbar { display: none; }
.ostrip .oslide { flex: 0 0 100%; min-width: 0; scroll-snap-align: start; scroll-snap-stop: always; }
.ogal:not(.live) .ostrip .oslide { flex-basis: 88%; }
.gfr { position: relative; }
.oslide .pf { height: 300px; max-height: none; aspect-ratio: auto; background: #3A2E26; }
.gn { position: absolute; inset-inline-end: 10px; top: 10px; padding: 4px 8px; border-radius: 8px; background: rgba(27, 21, 18, .72); color: #FFFDF8; font-size: .75rem; font-weight: 700; }
.gnav { position: absolute; top: 50%; margin-top: -22px; display: none; place-items: center; width: 44px; height: 44px; padding: 0; border: 0;
  border-radius: 50%; background: rgba(255, 253, 248, .9); color: #2A211C; cursor: pointer; }
.live .gnav { display: grid; }
.gnav.nx .i, [dir="rtl"] .gnav.pv .i { transform: scaleX(-1); }
[dir="rtl"] .gnav.nx .i { transform: none; }
.gnav.nx { inset-inline-end: 8px; }
.gnav.pv { inset-inline-start: 8px; }
.gthumbs { display: none; gap: 8px; overflow-x: auto; scrollbar-width: none; }
.live .gthumbs { display: flex; }
.gth { flex: 0 0 72px; height: 72px; padding: 0; overflow: hidden; border: 2px solid transparent; border-radius: 10px; background: var(--panel); cursor: pointer; }
.gth img { display: block; width: 100%; height: 100%; object-fit: cover; }
.gth[aria-current="true"] { border-color: var(--accent); }
@media (min-width: 960px) {
  .sside .side-pic .oslide .pf { height: 360px; max-height: none; }
  .gth { flex-basis: 64px; height: 64px; }
}

/* People (owner, 2026-11-17, draft S7): people to meet first, then each period led by one person with a picture and a
   summary, the rest as one-line rows; period and role as two selects that fit the phone. */
.pfeat { display: flex; flex-direction: column; gap: 12px; margin-bottom: 18px; }
.pfeat h2 { margin: 0; }
.pfeat .face { flex-basis: 96px; }
.pfeat .face img, .pfeat .face .ini { width: 96px; height: 96px; }
.pfeat .face .ini { display: flex; align-items: center; justify-content: center; border-radius: 50%; background: var(--soft); }
.pfeat .face .k { font-size: .76rem; font-weight: 400; color: var(--muted); }
.fsels { display: flex; gap: 10px; margin-bottom: 18px; }
.fsel { flex: 1; min-width: 0; }
.fsel select { width: 100%; min-height: 44px; padding: 0 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); color: var(--ink); font: inherit; font-size: .9rem; }
.fsels ~ .listcols .pnav { display: none; }
.plead { display: flex; gap: 14px; align-items: flex-start; padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.plead img, .plead .ini { flex: 0 0 88px; width: 88px; height: 88px; border-radius: 50%; object-fit: cover; background: var(--soft); }
.plead .ini, .prow3 .ini { display: flex; align-items: center; justify-content: center; color: var(--dot-muted); font-family: var(--serif); font-weight: 700; font-size: 1.6rem; }
.plead .st { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.plead .ttl { font-family: var(--serif); font-weight: 700; font-size: 1.3rem; line-height: 1.2; }
.plead .k { font-size: .82rem; color: var(--muted); }
.plead .sub { font-family: var(--serif); font-size: .95rem; line-height: 1.45; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.prow3 { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 6px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.prow3 img, .prow3 .ini { flex: 0 0 40px; width: 40px; height: 40px; border-radius: 50%; object-fit: cover; background: var(--soft); }
.prow3 .ini { font-size: 1rem; }
.plist { list-style: none; margin: 0; padding: 0; }
.prow3 .tx { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.prow3 .ttl { font-family: var(--serif); font-weight: 700; font-size: 1.02rem; line-height: 1.3; }
.prow3 .k { font-size: .8rem; color: var(--muted); }
.prow3 .y { flex: none; font-size: .8rem; color: var(--muted); white-space: nowrap; }
@media (hover: hover) { .plead:hover .ttl, .prow3:hover .ttl { color: var(--accent); } }
@media (min-width: 960px) {
  .fsels { max-width: 560px; }
  .fsel.fper { display: none; }
  .fsels ~ .listcols .pnav { display: flex; }
  .plead .sub { -webkit-line-clamp: 2; }
  .plist { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 32px; }
  .plist li:has(.plead) { grid-column: 1 / -1; }
}

/* Phone menu B (owner, 2026-11-17, draft S5): the screen's width, two columns, a picture and a count per kind. */
.mmenu .pop.mgridpop { position: fixed; top: 64px; inset-inline: 8px; width: auto; padding: 10px 14px 6px; }
.mgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 12px; }
.mgrid a { display: flex; align-items: center; gap: 10px; min-height: 60px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: .98rem; }
.mgrid img, .mgrid .mi { flex: none; width: 42px; height: 42px; border-radius: 50%; object-fit: cover; background: var(--soft); }
.mgrid img.flag { border-radius: 6px; height: 30px; margin-block: 6px; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); }
.mgrid .mi { display: flex; align-items: center; justify-content: center; font-family: var(--serif); font-weight: 700; font-size: 1.2rem; color: var(--muted); }
.mgrid .mt { display: flex; flex-direction: column; min-width: 0; line-height: 1.2; }
.mgrid .mc { font-size: .78rem; font-weight: 400; color: var(--muted); }
.mgrid a[aria-current] { color: var(--accent); }
.mfoot { display: flex; justify-content: space-between; align-items: center; border-top: 1px solid var(--line); margin-top: 6px; }
.mfoot a { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; color: var(--ink); text-decoration: none; font-weight: 600; }
.mfoot a span { color: var(--muted); font-weight: 400; font-size: .85rem; }
.mfoot a.surprise { color: var(--accent); }

/* Search with the field empty (draft S4): recent searches, things to look at, a hint. */
.ssug { display: flex; flex-direction: column; gap: 4px; margin-top: 4px; }
.ssug .lb { margin: 14px 0 2px; font-size: .78rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); font-family: var(--sans); }
.rlist { list-style: none; margin: 0; padding: 0; }
.rlist li { display: flex; align-items: center; border-bottom: 1px solid var(--line); }
.rlist .rq { flex: 1; min-height: 44px; text-align: start; border: 0; background: none; color: var(--ink); font: inherit; cursor: pointer; padding: 0; }
.rlist .rx { width: 44px; height: 44px; border: 0; background: none; color: var(--muted); font-size: 1.3rem; cursor: pointer; }
.ssug .th.yr { display: flex; align-items: center; justify-content: center; background: var(--inv); color: var(--inv-fg); }
#search-status:empty, #results:empty { display: none; }
.ssug .sres .k { color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ssug .lb:first-child, .ssug > div > .lb { margin-top: 6px; }

/* The main screen's path picture on the phone: wide and cropped (owner, 2026-11-17), never a letterbox on a blur. */
@media (max-width: 959px) { .home .hometop .ph-img { aspect-ratio: 16 / 9; } }

/* First visit B (draft S2): the page dimmed, the tab outlined, a bubble above it. */
.tour { position: fixed; inset: 0; z-index: 30; background: rgba(27, 21, 18, .62); }
.touring nav.bar { position: fixed; z-index: 31; }
.touring nav.bar a:not(.tour-on) { opacity: .35; }
.touring nav.bar a.tour-on { color: var(--accent); box-shadow: inset 0 0 0 2px var(--accent); border-radius: 12px; }
.tour-bub { position: fixed; inset-inline: 16px; bottom: calc(84px + env(safe-area-inset-bottom, 0px)); background: var(--card); color: var(--ink); border-radius: 16px; padding: 16px 16px 12px; box-shadow: 0 8px 24px rgba(0, 0, 0, .25); }
.tour-bub::after { content: ""; position: absolute; bottom: -8px; left: calc(var(--x, 50%) - 16px - 8px); width: 16px; height: 16px; background: var(--card); transform: rotate(45deg); }
.tb-n { margin: 0; font-size: .8rem; font-weight: 700; color: var(--accent); }
.tb-t { margin: 6px 0 12px; font-size: 1rem; line-height: 1.5; }
.tb-row { display: flex; justify-content: space-between; align-items: center; }
.tb-skip, .tb-next { min-height: 44px; padding: 0 18px; border-radius: 999px; font: inherit; font-weight: 700; cursor: pointer; }
.tb-skip { border: 0; background: none; color: var(--muted); padding-inline-start: 0; }
.tb-next { border: 0; background: var(--accent); color: var(--page); }

/* The sources page: rows under each heading, the title on its line and author and year under it. */
.srcgrp { margin-bottom: 28px; }
.srcrows { list-style: none; margin: 0; padding: 0; }
.srcrows a, .srcrows .nolink { display: flex; flex-direction: column; gap: 2px; padding: 10px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.srcrows .ttl { font-weight: 600; line-height: 1.35; }
.srcrows a .ttl { color: var(--accent); }
.srcrows .k { font-size: .85rem; color: var(--muted); }
@media (min-width: 960px) { .srcrows { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 40px; } }

/* Long BC years (Uyghur "مىلادىيەدىن ئىلگىرىكى 200-يىل") wrap at the start of a scale instead of running into the next
   mark, and in the events list's year column (found by the screen check, 2026-11-17). */
.scale .m0, .lscale .m0 { white-space: normal; max-width: 6.5em; line-height: 1.15; }
html[lang^="ug"] .scale, html[lang^="ug"] .lscale { height: 30px; }
.erow .when { white-space: normal; overflow-wrap: anywhere; }
@media (max-width: 600px) { html[lang^="ug"] .lscale .m1 { display: none; } }
/* The period ticks under the states chart sit in a row of equal columns (ADR 0018), so a long label grows the row
   instead of running over the note below. */
.pticks { display: flex; height: auto; }
.pticks .pt { position: static; flex: 0 0 12.5%; width: auto; box-sizing: border-box; padding-inline-end: 4px; }
.pticks .pt bdi { white-space: nowrap; }
[dir="rtl"] .tb-n { text-align: right; }

/* AI tag on staging only (ADR 0023) */
.aitag { display: inline-block; font-size: .7rem; font-weight: 700; letter-spacing: .06em; padding: 1px 6px; border-radius: 6px; border: 1px solid currentColor; opacity: .7; }
/* Report an error (ADR 0023): a quiet line at the end of the page that opens a form */
.report { margin-block: 24px 8px; }
.report summary { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; color: var(--dot-muted); font-size: .9rem; }
.report summary::-webkit-details-marker { display: none; }
.report[open] summary { color: inherit; }
.rform { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; max-width: 40rem; }
.rform textarea, .rform input { font: inherit; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--dashed); background: var(--card); color: inherit; }
.rform textarea { min-height: 7rem; resize: vertical; }
.rform .rmsg { font-size: .9rem; }
.rform .btn { border: 0; font: inherit; font-weight: 700; cursor: pointer; }
.rform .btn:disabled { opacity: .6; }
