/* Cyberdelegate Bureau
   Palette: pale office wall, deep carpet green, partition teal, terminal navy, putty-coloured hardware. */
:root {
  --wall: #e7ebe5;
  --paper: #fbfbf8;
  --paper-2: #f2f4ef;
  --ink: #1b2725;
  --muted: #56645f;
  --rule: #d2d8d0;
  --rule-2: #b9c2b8;
  --link: #1d6570;
  --carpet: #2b4a3b;
  --carpet-2: #36594a;
  --on-carpet: #e9efe6;
  --on-carpet-muted: #bccdc0;
  --partition: #3c6b67;
  --partition-2: #335d5a;
  --stamp: #9a3e2a;
  --accent: #3c6b67;      /* partition teal used as text or edge on paper */
  --on-accent: #f4f7f2;   /* text on partition and carpet fills */
  --field: #869287;       /* form field edges */
  --crt-a: #e8e3d3; --crt-b: #d2cbb6;

  --screen: #0b2230;
  --glyph: #a8dce3;
  --glyph-dim: #6b9aa8;
  --land: #1c4454;
  --q1: #2d6a79; --q2: #4b98a6; --q3: #7cc2cb; --q4: #bde8ec;
  --k1: #7cc2cb; --k2: #e3b867; --k3: #b7a3dc; --k4: #5f7f8a; --attr: #e3b867;

  --bezel: #dcd6c4;
  --bezel-2: #c9c2ab;
  --bezel-edge: #aaa287;
  --bezel-ink: #44412f;
  --key: #efebdf;
  --key-edge: #a59d82;
  --key-ink: #3a382b;
  --key-on: #3c6b67;
  --key-on-ink: #f3f6ef;
  --slip: #f7f5ec;

  --sans: "Libre Franklin", "Franklin Gothic Medium", "Helvetica Neue", Arial, sans-serif;
  --head: var(--gh-font-heading, "Libre Franklin"), "Franklin Gothic Medium", "Helvetica Neue", Arial, sans-serif;
  --text: var(--gh-font-body, "Source Serif 4"), Georgia, "Times New Roman", serif;
  --crt: "VT323", "Lucida Console", monospace;
  --page: 1200px;
  --gut: 28px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --wall: #0a1519; --paper: #10202a; --paper-2: #142832; --ink: #dde8e5; --muted: #95aaa6; --rule: #223942; --rule-2: #2f4b55;
    --link: #8fd0d8; --carpet: #0c1a17; --carpet-2: #15291f; --partition: #17393b; --partition-2: #123032; --stamp: #e08a72;
    --bezel: #262c2a; --bezel-2: #1d2321; --bezel-edge: #121614; --bezel-ink: #c9cfc4;
    --key: #323936; --key-edge: #151a18; --key-ink: #dfe5dc; --key-on: #7cc2cb; --key-on-ink: #0b2230; --slip: #18282e; --accent: #7cc2cb; --on-accent: #f4f7f2; --field: #58757f; --crt-a: #343a37; --crt-b: #262b29; --on-carpet-muted: #a9bcae;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --wall: #0a1519; --paper: #10202a; --paper-2: #142832; --ink: #dde8e5; --muted: #95aaa6; --rule: #223942; --rule-2: #2f4b55;
  --link: #8fd0d8; --carpet: #0c1a17; --carpet-2: #15291f; --partition: #17393b; --partition-2: #123032; --stamp: #e08a72;
  --bezel: #262c2a; --bezel-2: #1d2321; --bezel-edge: #121614; --bezel-ink: #c9cfc4;
  --key: #323936; --key-edge: #151a18; --key-ink: #dfe5dc; --key-on: #7cc2cb; --key-on-ink: #0b2230; --slip: #18282e; --accent: #7cc2cb; --on-accent: #f4f7f2; --field: #58757f; --crt-a: #343a37; --crt-b: #262b29; --on-carpet-muted: #a9bcae;
  color-scheme: dark;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 60px; }
body {
  margin: 0; color: var(--ink); font: 16px/1.55 var(--sans);
  background-color: var(--wall);
  background-image: repeating-linear-gradient(90deg, transparent 0 159px, color-mix(in srgb, var(--ink) 4%, transparent) 159px 160px);
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-underline-offset: 3px; text-decoration-thickness: 1px; }
:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; z-index: 60; }
.skip:focus { left: 1rem; top: .5rem; background: var(--paper); padding: .4rem .8rem; }

.page { max-width: var(--page); margin: 0 auto; background: var(--paper); box-shadow: 0 0 0 1px var(--rule-2), 0 6px 24px -12px rgba(20, 40, 35, .25); }

/* Buttons and keys */
.btn { display: inline-block; font: 600 .9rem/1 var(--sans); background: var(--partition); color: var(--on-accent); border: 1px solid var(--partition-2); border-radius: 3px; padding: .7rem 1.1rem; text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--partition-2); }
.btn-sm { padding: .42rem .75rem; font-size: .8rem; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--rule-2); }
.btn-ghost:hover { background: var(--paper-2); }
.textbtn { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
.textbtn:hover { text-decoration: underline; }
.key {
  display: inline-block; font: 600 .78rem/1 var(--sans); color: var(--key-ink); background: var(--key);
  border: 1px solid var(--key-edge); border-bottom-width: 3px; border-radius: 4px; padding: .5rem .7rem .45rem;
  text-decoration: none; cursor: pointer; transition: transform .08s, border-bottom-width .08s;
}
.key:hover { background: color-mix(in srgb, var(--key) 85%, var(--key-on)); }
.key:active, .key[aria-pressed="true"] { transform: translateY(2px); border-bottom-width: 1px; margin-bottom: 2px; }
.key[aria-pressed="true"] { background: var(--key-on); color: var(--key-on-ink); border-color: var(--key-edge); }

/* ---------- Top bar ---------- */
.topbar { background: var(--carpet); color: var(--on-carpet); font: 500 .78rem/1 var(--sans); }
.topbar-in { display: flex; align-items: center; gap: 1.4rem; min-height: 38px; padding: 0 var(--gut); }
.today { margin: 0; color: var(--on-carpet-muted); white-space: nowrap; }
.ticker { display: flex; align-items: center; gap: .7rem; min-width: 0; flex: 1; padding-left: 1.4rem; border-left: 1px solid var(--carpet-2); }
.ticker-h { font-weight: 700; color: var(--on-carpet); background: var(--carpet-2); padding: .3rem .5rem; border-radius: 2px; }
.ticker ul { list-style: none; margin: 0; padding: 0; min-width: 0; flex: 1; }
.ticker li { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ticker li.in { animation: tick-in .4s ease-out; }
@keyframes tick-in { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }
.ticker a { color: var(--on-carpet); text-decoration: none; }
.ticker a:hover { text-decoration: underline; }
.topbar-links { display: flex; align-items: center; gap: 1.1rem; margin-left: auto; white-space: nowrap; }
.topbar a { color: var(--on-carpet); text-decoration: none; }
.topbar a:hover { text-decoration: underline; }
.topbar .btn { background: var(--on-carpet); color: var(--carpet); border-color: transparent; }
.topbar .btn:hover { background: color-mix(in srgb, var(--on-carpet) 80%, #fff); text-decoration: none; }
.lights { font: inherit; color: var(--on-carpet-muted); background: none; border: 1px solid var(--carpet-2); border-radius: 2px; padding: .28rem .5rem; cursor: pointer; }
.lights:hover { color: var(--on-carpet); }
.lights::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; margin-right: .4rem; vertical-align: 1px; background: #e8e2b8; box-shadow: 0 0 5px #f2ecc4; }
.lights[aria-pressed="true"]::before { background: #3d4a44; box-shadow: none; }

/* ---------- Masthead ---------- */
.head { display: flex; align-items: flex-end; justify-content: space-between; gap: 2rem; flex-wrap: wrap; padding: 1.7rem var(--gut) 1.3rem; border-bottom: 1px solid var(--rule); }
.wordmark { font: 800 clamp(2rem, 4.6vw, 3.1rem)/.95 var(--head); letter-spacing: -.025em; text-decoration: none; color: var(--ink); }
.wordmark img { max-height: 60px; width: auto; }
.wordmark { display: inline-flex; align-items: center; gap: .9rem; }
.wordmark .wordmark-mark { width: 64px; height: 64px; max-height: none; border-radius: 6px; flex: none; }
@media (max-width: 600px) { .wordmark .wordmark-mark { width: 46px; height: 46px; } }
.head-side { display: grid; justify-items: end; gap: .55rem; }
.head-line { margin: 0; max-width: 40ch; font: 400 .9rem/1.4 var(--sans); color: var(--muted); text-align: right; }
.head .nav { list-style: none; display: flex; gap: 1.1rem; margin: 0; padding: 0; font: 600 .8rem/1 var(--sans); }
.head .nav a { text-decoration: none; color: var(--muted); }
.head .nav a:hover, .head .nav .nav-current a { color: var(--ink); text-decoration: underline; }

/* ---------- Desk bar ---------- */
.desks { position: sticky; top: 0; z-index: 30; background: var(--partition); border-top: 1px solid var(--partition-2); border-bottom: 3px solid var(--partition-2); }
.desks ul { list-style: none; margin: 0; padding: 0 calc(var(--gut) - .85rem); display: flex; align-items: stretch; overflow-x: auto; scrollbar-width: none; }
.desks ul::-webkit-scrollbar { display: none; }
.desks a { display: flex; align-items: center; height: 100%; white-space: nowrap; font: 600 .86rem/1 var(--sans); padding: .95rem .85rem; color: var(--on-accent); text-decoration: none; }
.desks a:hover { background: var(--partition-2); color: #fff; }
.desks a[aria-current] { background: var(--paper); color: var(--ink); }
.desks-pp { margin-left: auto; }
.desks-pp a { background: color-mix(in srgb, var(--partition-2) 70%, #000); color: var(--on-accent); }

/* ---------- PREACH / PRACTICE wordmark ---------- */
.pp { position: relative; display: inline-flex; align-items: baseline; font: 800 1em/1 var(--head); letter-spacing: .03em; text-transform: uppercase; white-space: nowrap; }
.pp-sm { font-size: .82rem; }
.pp-md { font-size: 1.15rem; }
.pp-lg { font-size: clamp(1.6rem, 3.2vw, 2.3rem); }
.pp-xl { font-size: clamp(2.4rem, 7.5vw, 5.6rem); letter-spacing: .01em; }
.pp-slash { position: relative; display: inline-block; width: .4em; height: .78em; margin: 0 .2em; vertical-align: -.03em; color: var(--pp-accent, #5aa7a4); transition: width .35s cubic-bezier(.4, 0, .2, 1), margin .35s cubic-bezier(.4, 0, .2, 1); }
.pp-slash i {
  position: absolute; left: 50%; top: 50%; width: .4em; height: .12em; margin: -.06em 0 0 -.2em;
  background: currentColor; border-radius: .02em;
  transition: transform .5s cubic-bezier(.5, -.45, .25, 1.45);
}
.pp-slash i:first-child { transform: translate(.071em, -.176em) rotate(-68deg); }
.pp-slash i:last-child { transform: translate(-.071em, .176em) rotate(-68deg); transition-delay: .06s; }
a:hover .pp .pp-slash, a:focus-visible .pp .pp-slash, .pp:hover .pp-slash, .pp.is-on .pp-slash { width: .62em; margin: 0 .26em; }
a:hover .pp .pp-slash i:first-child, a:focus-visible .pp .pp-slash i:first-child, .pp:hover .pp-slash i:first-child, .pp.is-on .pp-slash i:first-child { transform: translate(0, -.15em) rotate(0) scaleX(1.3); }
a:hover .pp .pp-slash i:last-child, a:focus-visible .pp .pp-slash i:last-child, .pp:hover .pp-slash i:last-child, .pp.is-on .pp-slash i:last-child { transform: translate(0, .15em) rotate(0) scaleX(1.3); }
.desks .pp { --pp-accent: #a8dce3; }

/* ---------- Shared story parts ---------- */
.kicker { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem; margin: 0 0 .4rem; font: 700 .76rem/1.2 var(--sans); }
.kicker a { color: var(--link); text-decoration: none; }
.kicker a:hover { text-decoration: underline; }
.stamp { color: var(--stamp); border: 1px solid currentColor; border-radius: 2px; padding: .12rem .35rem; font: 700 .66rem/1 var(--sans); }
.byline { display: flex; flex-wrap: wrap; gap: .2rem .9rem; margin: .5rem 0 0; font: 400 .78rem/1.3 var(--sans); color: var(--muted); }
.dek { margin: .45rem 0 0; color: var(--muted); font: 400 .98rem/1.5 var(--text); }
.dek-lg { font-size: 1.12rem; color: var(--ink); max-width: 62ch; }
.h-xl, .h-lg, .h-md, .h-sm { font-family: var(--head); font-weight: 700; letter-spacing: -.012em; margin: 0; text-wrap: pretty; }
.h-xl { text-wrap: balance; }
.h-xl { font-size: clamp(1.8rem, 3.3vw, 2.6rem); line-height: 1.08; }
.h-lg { font-size: 1.32rem; line-height: 1.2; }
.h-md { font-size: 1.18rem; line-height: 1.25; }
.h-sm { font-size: 1rem; line-height: 1.3; font-weight: 600; }
.h-xl a, .h-lg a, .h-md a, .h-sm a { text-decoration: none; }
.h-xl a:hover, .h-lg a:hover, .h-md a:hover, .h-sm a:hover { color: var(--link); text-decoration: underline; }

/* Images: a little muted until you look at them */
.media { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--paper-2); border: 1px solid var(--rule); margin-bottom: .8rem; }
.media img, .thumb img { width: 100%; height: 100%; object-fit: cover; filter: saturate(.78) contrast(1.03); transition: filter .25s; }
.story:hover .media img, .story:hover .thumb img { filter: none; }
.media-empty { display: grid; place-items: end start; padding: .9rem; background: var(--partition); border-color: var(--partition-2); }
.media-empty span { font: 700 1.2rem/1.1 var(--head); color: var(--on-accent); }
.thumb { display: block; overflow: hidden; border: 1px solid var(--rule); background: var(--paper-2); }

.crumbs { margin: 0 0 1rem; font: 500 .78rem/1.3 var(--sans); color: var(--muted); }
.crumbs a { color: var(--link); text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.crumbs span { margin: 0 .45rem; color: var(--rule-2); }

/* ---------- Front page: top ---------- */
.top { display: grid; grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); gap: 2rem; padding: 1.8rem var(--gut) 0; }
.lead .media { aspect-ratio: 16 / 9; }
.top-side { border-left: 1px solid var(--rule); padding-left: 2rem; }
.rail-h { font: 700 .85rem/1 var(--sans); margin: 0 0 .2rem; padding: .55rem 0; border-bottom: 2px solid var(--ink); }
.story-sm { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: .9rem; padding: .95rem 0; border-bottom: 1px solid var(--rule); }
.story-sm:last-child { border-bottom: 0; }
.story-sm:not(:has(.thumb)) { grid-template-columns: minmax(0, 1fr); }
.story-sm .thumb { aspect-ratio: 1; }
.story-sm .kicker { margin-bottom: .25rem; }
.story-sm .byline { margin-top: .3rem; }

/* ---------- Console (dispatch map) ---------- */
.console { margin: 2rem var(--gut) 0; background: linear-gradient(var(--bezel), var(--bezel-2)); border: 1px solid var(--bezel-edge); border-radius: 6px; padding: 1rem 1.1rem 1.15rem; color: var(--bezel-ink); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45); }
.console-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: .8rem; }
.console-title { font: 700 1.15rem/1.1 var(--head); margin: 0; }
.console-note { margin: 0; font: 400 .82rem/1.3 var(--sans); opacity: .85; }
.console-body { display: grid; grid-template-columns: minmax(0, 1.95fr) minmax(240px, 1fr); gap: 1.1rem; align-items: start; }

.crt { position: relative; padding: 12px 12px 22px; border-radius: 14px; background: linear-gradient(var(--crt-a), var(--crt-b)); border: 1px solid var(--bezel-edge); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .7), 0 2px 0 rgba(0, 0, 0, .08); }
.crt-lamp { position: absolute; right: 18px; bottom: 7px; width: 7px; height: 7px; border-radius: 50%; background: #8fd18f; box-shadow: 0 0 6px #8fd18f; }
.crt-screen {
  position: relative; overflow: hidden; border-radius: 16px / 20px; padding: .7rem .9rem .6rem;
  background: radial-gradient(ellipse at 48% 38%, #15405a 0%, var(--screen) 58%, #06141d 100%);
  box-shadow: inset 0 0 0 2px #061219, inset 0 0 38px rgba(0, 0, 0, .65);
  color: var(--glyph);
}
.crt-screen::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse at 22% 12%, rgba(255, 255, 255, .07), transparent 45%),
    repeating-linear-gradient(to bottom, transparent 0 2px, rgba(0, 0, 0, .2) 2px 3px);
}
.crt-stat { margin: 0 0 .2rem; font: 400 1.18rem/1.15 var(--crt); text-shadow: 0 0 6px rgba(168, 220, 227, .45); min-height: 1.2em; }
.crt-stat::after { content: "_"; margin-left: .15em; animation: blink 1.1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.crt-legend { display: flex; align-items: center; gap: .3rem; margin-top: .3rem; font: 400 .95rem/1 var(--crt); color: var(--glyph-dim); }
.crt-legend i { width: 18px; height: 7px; display: inline-block; }
.crt-legend .q1 { background: var(--q1); } .crt-legend .q2 { background: var(--q2); } .crt-legend .q3 { background: var(--q3); } .crt-legend .q4 { background: var(--q4); }
.map-svg svg, .loc-svg svg { width: 100%; height: auto; display: block; }

.worldmap .sphere { fill: rgba(16, 52, 70, .55); }
.worldmap .c { fill: var(--land); stroke: #0b2230; stroke-width: .5; transition: fill .15s; }
.worldmap .c.q1 { fill: var(--q1); } .worldmap .c.q2 { fill: var(--q2); } .worldmap .c.q3 { fill: var(--q3); } .worldmap .c.q4 { fill: var(--q4); }
.worldmap .c.hit { cursor: pointer; }
.worldmap .c.hit:hover, .worldmap .c.hit:focus { fill: #f2fbfb; outline: none; }
.worldmap .c.on { fill: #f2fbfb; stroke: #f2fbfb; stroke-width: 1.1; }
.worldmap .arc { fill: none; stroke: var(--glyph); stroke-opacity: .5; stroke-linecap: round; pointer-events: none; }
.worldmap .arc.on { stroke: #fff; stroke-opacity: 1; }
.worldmap .end { fill: #e6f7f8; opacity: .85; pointer-events: none; }
.worldmap .home { fill: #fff; stroke: var(--q3); stroke-width: 2; pointer-events: none; }
.worldmap .ping { fill: none; stroke: #fff; stroke-width: 1.4; transform-box: fill-box; transform-origin: center; opacity: 0; pointer-events: none; animation: ping 2.6s ease-out infinite; }
@keyframes ping { 0% { transform: scale(.4); opacity: .9; } 100% { transform: scale(3.2); opacity: 0; } }
.worldmap .c, .worldmap .arc { vector-effect: non-scaling-stroke; }
.worldmap.zoomed .c { stroke-width: .3; }
.worldmap.zoomed .arc { stroke-opacity: .9; stroke-width: 1.6px !important; }

.console-panel { display: grid; gap: .7rem; }
.keys { display: flex; flex-wrap: wrap; gap: .4rem; }
.key-select {
  font: 600 .8rem/1 var(--sans); color: var(--key-ink); background-color: var(--key); border: 1px solid var(--key-edge); border-bottom-width: 3px; border-radius: 4px;
  padding: .5rem 2rem .45rem .7rem; appearance: none; cursor: pointer; width: 100%;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: calc(100% - 15px) 52%, calc(100% - 10px) 52%; background-size: 5px 5px; background-repeat: no-repeat;
}
.slip { background: var(--slip); border: 1px solid var(--key-edge); border-radius: 2px; padding: .7rem .8rem .5rem; min-height: 132px; color: var(--ink); box-shadow: 0 1px 0 rgba(0, 0, 0, .06); }
.card-country { margin: 0 0 .35rem; font: 700 .95rem/1.2 var(--sans); }
.card-country small { font-weight: 500; color: var(--muted); margin-left: .45rem; }
.card-list { list-style: none; margin: 0; padding: 0; }
.card-list li { padding: .42rem 0; border-top: 1px dashed var(--rule-2); }
.card-list time { display: block; font: 500 .7rem/1 var(--sans); color: var(--muted); margin-bottom: .2rem; }
.card-list a { text-decoration: none; font: 400 .92rem/1.3 var(--text); }
.card-list a:hover { text-decoration: underline; color: var(--link); }
.card-more { font: 500 .74rem var(--sans); color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: .35rem; }
.chips button { font: 600 .74rem/1 var(--sans); color: var(--key-ink); background: var(--key); border: 1px solid var(--key-edge); border-bottom-width: 2px; border-radius: 3px; padding: .38rem .5rem; cursor: pointer; }
.chips button span { opacity: .65; margin-left: .3rem; font-weight: 500; }
.chips button[aria-pressed="true"] { background: var(--key-on); color: var(--key-on-ink); }

/* ---------- Columns + sidebar ---------- */
.cols { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 2.5rem; padding: 1.8rem var(--gut) 2.5rem; align-items: start; }
.side { display: grid; gap: 1.6rem; }
.widget { border: 1px solid var(--rule); background: var(--paper); }
.widget > :not(.widget-h):not(.tablist) { margin-left: 1rem; margin-right: 1rem; }
.widget > :last-child { margin-bottom: 1rem; }
.widget-h { margin: 0 0 .8rem; padding: .6rem 1rem; font: 700 .86rem/1.2 var(--sans); background: var(--paper-2); border-bottom: 1px solid var(--rule); }
.widget-h a { text-decoration: none; }
.widget p { font: 400 .88rem/1.5 var(--sans); color: var(--muted); margin-top: 0; }
.widget-brief { border-top: 3px solid var(--accent); }
.brief-form label { display: block; font: 600 .78rem/1 var(--sans); margin-bottom: .4rem; }
.brief-form input { width: 100%; font: 400 .95rem var(--sans); padding: .6rem .7rem; border: 1px solid var(--field); border-radius: 2px; background: var(--paper); color: var(--ink); margin-bottom: .5rem; }
.brief-form .btn { width: 100%; }
.msg-ok, .msg-err { display: none; margin: .6rem 0 0 !important; }
form.success .msg-ok, form.error .msg-err { display: block; }
form.loading .btn { opacity: .7; cursor: progress; }
.mini { list-style: none; margin: 0; padding: 0; counter-reset: mini; }
.mini li { display: grid; grid-template-columns: 1.6rem minmax(0, 1fr); padding: .6rem 0; border-bottom: 1px solid var(--rule); counter-increment: mini; }
.mini li:last-child { border-bottom: 0; }
.mini li::before { content: counter(mini); grid-row: 1 / 3; font: 700 1rem/1.2 var(--head); color: var(--rule-2); }
.mini a { font: 600 .9rem/1.3 var(--sans); text-decoration: none; }
.mini a:hover { text-decoration: underline; color: var(--link); }
.mini time { font: 400 .72rem/1.4 var(--sans); color: var(--muted); }
.topics { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .35rem; }
.topics a { display: inline-block; font: 500 .8rem/1 var(--sans); text-decoration: none; padding: .38rem .5rem; border: 1px solid var(--rule-2); border-radius: 2px; background: var(--paper-2); }
.topics a:hover { border-color: var(--link); color: var(--link); }
.topics span { color: var(--muted); margin-left: .2rem; }
.widget-pp { background: var(--carpet); border-color: var(--carpet); color: var(--on-carpet); }
.widget-pp .widget-h { background: transparent; border-bottom-color: var(--carpet-2); color: var(--on-carpet); padding-top: .9rem; }
.widget-pp p { color: var(--on-carpet-muted); }
.widget-pp .more a { color: var(--on-carpet); }
.widget-pp .pp { --pp-accent: #8fcfc4; }
.home-template .widget-pp { display: none; }

/* Tabs */
.tablist { display: none; }
[data-tabs].is-tabs .tablist { display: flex; }
[data-tabs].is-tabs .panel-h { display: none; }
.tabpanel + .tabpanel { margin-top: 2rem; }
[data-tabs].is-tabs .tabpanel + .tabpanel { margin-top: 0; }
.panel-h { font: 700 1.1rem/1.2 var(--head); margin: 0 0 .8rem; }
.tablist-flat { border-bottom: 1px solid var(--rule); background: var(--paper-2); margin-bottom: .6rem; }
.tablist-flat button { flex: 1; font: 600 .78rem/1 var(--sans); color: var(--muted); background: none; border: 0; border-right: 1px solid var(--rule); padding: .75rem .3rem; cursor: pointer; }
.tablist-flat button:last-child { border-right: 0; }
.tablist-flat button[aria-selected="true"] { background: var(--paper); color: var(--ink); box-shadow: inset 0 3px 0 var(--partition); margin-bottom: -1px; }
.tablist-folder { gap: .25rem; align-items: flex-end; overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--rule-2); }
.tablist-folder button { white-space: nowrap; font: 600 .8rem/1 var(--sans); color: var(--muted); background: var(--paper-2); border: 1px solid var(--rule-2); border-bottom: 0; border-radius: 4px 4px 0 0; padding: .6rem .8rem; cursor: pointer; }
.tablist-folder button:hover { color: var(--ink); }
.tablist-folder button[aria-selected="true"] { background: var(--paper); color: var(--ink); padding-bottom: .7rem; margin-bottom: -1px; box-shadow: inset 0 3px 0 var(--partition); }
[data-tabs].is-tabs .folder { border: 1px solid var(--rule-2); border-top: 0; padding: 1.3rem; }

/* Section heads */
.sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; border-bottom: 2px solid var(--ink); padding-bottom: .5rem; margin: 2.4rem 0 1rem; }
.col-main > :first-child .sec-head, .col-main > .sec-head:first-child { margin-top: 0; }
.sec-h { font: 700 1.35rem/1.1 var(--head); margin: 0; letter-spacing: -.01em; }
.sec-h a { text-decoration: none; }
.sec-note { margin: 0; font: 400 .85rem/1.4 var(--sans); color: var(--muted); }
.desk-tabs .sec-head { border-bottom: 0; margin-bottom: .6rem; }
.empty { color: var(--muted); font: .92rem var(--sans); }
.more { margin: 1rem 0 0; font: 700 .82rem var(--sans); }
.more a { color: var(--link); }

.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.5rem; }
.desk-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 1.8rem; }
.desk-main .media { aspect-ratio: 16 / 9; }
.desk-side .story-sm:first-child { padding-top: 0; }

/* Stream rows with calendar dates */
.story-row { display: grid; grid-template-columns: 58px minmax(0, 1fr) 200px; gap: 1.3rem; padding: 1.3rem 0; border-bottom: 1px solid var(--rule); align-items: start; }
.story-row:not(:has(.thumb)) { grid-template-columns: 58px minmax(0, 1fr); }
.cal { display: grid; text-align: center; border: 1px solid var(--rule-2); background: var(--paper); font-family: var(--sans); line-height: 1; }
.cal-d { font: 800 1.45rem/1 var(--head); padding: .4rem 0 .15rem; }
.cal-m { font-weight: 600; font-size: .72rem; padding-bottom: .35rem; color: var(--muted); }
.cal-y { font-size: .66rem; color: var(--on-accent); background: var(--partition); padding: .22rem 0; }
.thumb-row { aspect-ratio: 16 / 10; }
.desk-top { padding-bottom: 1.4rem; border-bottom: 1px solid var(--rule); }
.desk-top .story-lg { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 1.6rem; align-items: center; }
.desk-top .story-lg .media { grid-row: 1 / 6; margin: 0; }
.desk-top .h-lg { font-size: 1.7rem; }

/* Pager */
.pager { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: 1.8rem 0 .5rem; }
.pager .key:last-child { justify-self: end; }
.pager-n { font: 500 .85rem var(--sans); color: var(--muted); }

/* ---------- Series band (front page) ---------- */
.pp-band { background: var(--carpet); color: var(--on-carpet); padding: 1.5rem 1.5rem 1.2rem; margin-bottom: .5rem; border-top: 4px solid var(--partition); --pp-accent: #8fcfc4; }
.pp-band-head { display: flex; align-items: baseline; justify-content: space-between; gap: .6rem 1.5rem; flex-wrap: wrap; padding-bottom: 1rem; border-bottom: 1px solid var(--carpet-2); }
.pp-band-head h2 { margin: 0; }
.pp-band-head a { text-decoration: none; color: var(--on-carpet); }
.pp-band-head p { margin: 0; max-width: 40ch; font: 400 .98rem/1.45 var(--text); color: var(--on-carpet-muted); }
.pp-band-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pp-entry { padding: 1rem 1.2rem 0; border-left: 1px solid var(--carpet-2); }
.pp-entry:first-child { padding-left: 0; border-left: 0; }
.pp-entry time { font: 500 .74rem/1 var(--sans); color: var(--on-carpet-muted); }
.pp-entry h3 { margin: .4rem 0 .4rem; font: 700 1.05rem/1.25 var(--head); }
.pp-entry h3 a { color: var(--on-carpet); text-decoration: none; }
.pp-entry h3 a:hover { text-decoration: underline; }
.pp-entry p { margin: 0; font: 400 .9rem/1.45 var(--text); color: var(--on-carpet-muted); }
.pp-band-more { margin: 1.1rem 0 0; font: 700 .82rem var(--sans); }
.pp-band-more a { color: var(--on-carpet); }

/* ---------- Series page ---------- */
.pp-head { padding: 2rem var(--gut) 1.8rem; border-bottom: 1px solid var(--rule); background: var(--paper-2); --pp-accent: var(--accent); }
.pp-title { margin: .2rem 0 1rem; line-height: 1; }
.pp-dek { margin: 0; max-width: 58ch; font: 400 1.2rem/1.5 var(--text); }
.pp-key { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; max-width: 820px; margin: 1.5rem 0 0; }
.pp-key div { border-top: 2px solid var(--ink); padding-top: .55rem; }
.pp-key dt { font: 800 .9rem/1.2 var(--head); letter-spacing: .03em; text-transform: uppercase; }
.pp-key dd { margin: .25rem 0 0; font: 400 .92rem/1.45 var(--sans); color: var(--muted); }

/* Series strip on articles */
.pp-strip { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .7rem 1rem; margin-bottom: 1.4rem; background: var(--carpet); color: var(--on-carpet); text-decoration: none; --pp-accent: #8fcfc4; }
.pp-strip-note { font: 500 .78rem var(--sans); color: var(--on-carpet-muted); }
.pp-strip:hover .pp-strip-note { color: var(--on-carpet); text-decoration: underline; }

/* ---------- Article ---------- */
.article { min-width: 0; }
.a-title { font: 800 clamp(1.9rem, 4vw, 2.9rem)/1.08 var(--head); letter-spacing: -.02em; margin: .2rem 0 .8rem; text-wrap: balance; }
.a-dek { font: 400 1.22rem/1.5 var(--text); color: var(--muted); margin: 0 0 1.2rem; max-width: 56ch; }
.cable { display: flex; flex-wrap: wrap; gap: .35rem 1.8rem; margin: 0; padding: .75rem 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); font: 400 .82rem/1.3 var(--sans); }
.cable div { display: flex; gap: .4rem; }
.cable dt { color: var(--muted); }
.cable dd { margin: 0; font-weight: 600; }
.cable a { text-decoration: none; color: var(--link); }
.share { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; margin: .9rem 0 0; font: 600 .76rem/1 var(--sans); }
.share-h { color: var(--muted); font-weight: 500; margin-right: .3rem; }
.share a, .share button { font: inherit; color: var(--ink); background: var(--paper-2); border: 1px solid var(--rule-2); border-radius: 2px; padding: .4rem .6rem; text-decoration: none; cursor: pointer; }
.share a:hover, .share button:hover { border-color: var(--link); color: var(--link); }
.a-fig { margin: 1.8rem 0 0; }
.a-fig img { width: 100%; border: 1px solid var(--rule); }
.a-fig figcaption, .gh-content figcaption { font: 400 .8rem/1.4 var(--sans); color: var(--muted); margin-top: .5rem; }
.a-body { margin: 2rem 0 0; font: 400 1.12rem/1.72 var(--text); }
.a-body > * { max-width: 680px; }
.article-page { max-width: 820px; margin: 0 auto; padding: 2rem var(--gut) 3rem; }
.article-page .a-head { margin-bottom: 0; }
.a-body-solo { max-width: 820px; margin: 2rem auto 0; padding: 0 var(--gut); }
.gh-content > p:first-of-type::first-letter { float: left; font: 800 3.4em/.82 var(--head); margin: .08em .1em 0 0; color: var(--accent); }
.gh-content h2 { font: 700 1.55rem/1.2 var(--head); margin: 2.4rem 0 .6rem; letter-spacing: -.01em; }
.gh-content h3 { font: 700 1.12rem/1.3 var(--head); margin: 1.9rem 0 .4rem; }
.gh-content a { color: var(--link); }
.gh-content blockquote:not(.kg-blockquote-alt) { margin: 1.8rem 0; padding: .2rem 0 .2rem 1.1rem; border-left: 3px solid var(--accent); font-style: italic; }
.gh-content .kg-blockquote-alt { font: 600 1.45rem/1.35 var(--head); text-align: left; padding: 1rem 0; margin: 2.2rem 0; border-top: 2px solid var(--ink); border-bottom: 1px solid var(--rule); color: var(--ink); font-style: normal; }
.gh-content .kg-callout-card { border-radius: 2px; border: 1px solid var(--rule-2); border-left: 4px solid var(--accent); font: 400 .98rem/1.55 var(--sans); }
.gh-content pre { background: var(--screen); color: var(--glyph); padding: 1rem 1.2rem; border-radius: 6px; overflow-x: auto; font: 400 1.05rem/1.4 var(--crt); box-shadow: inset 0 0 24px rgba(0, 0, 0, .5); }
.gh-content :not(pre) > code { background: var(--paper-2); border: 1px solid var(--rule); padding: .05em .3em; border-radius: 2px; font-size: .86em; }
.gh-content figure { margin: 1.8rem 0; }
.gh-content ul, .gh-content ol { padding-left: 1.3rem; }
.gh-content li { margin: .3rem 0; }
.gh-content hr { border: 0; border-top: 1px solid var(--rule); margin: 2.4rem 0; }
.gh-content table { border-collapse: collapse; display: block; overflow-x: auto; font: .88rem var(--sans); }
.gh-content th, .gh-content td { border: 1px solid var(--rule); padding: .45rem .65rem; text-align: left; }
.gh-content th { background: var(--paper-2); }
.kg-width-wide, .kg-width-full { position: relative; width: 100%; max-width: none !important; }
.kg-width-wide img, .kg-width-full img { width: 100%; }
.article-page .kg-width-wide { width: min(1100px, 92vw) !important; left: 50%; transform: translateX(-50%); }
.article-page .kg-width-full { width: min(var(--page), 100vw) !important; left: 50%; transform: translateX(-50%); }
.src-n { font: 600 .65em/0 var(--sans); vertical-align: super; margin-left: .1em; }
.src-n a { text-decoration: none; color: var(--muted); }
.sources, .author-box, .a-comments, .related { margin-top: 2.2rem; }
.sources h2 { font: 700 .86rem/1 var(--sans); margin: 0 0 .6rem; padding-top: 1rem; border-top: 2px solid var(--ink); max-width: 680px; }
.sources ol { margin: 0; padding-left: 1.4rem; font: 400 .8rem/1.6 var(--sans); color: var(--muted); max-width: 680px; }
.sources li { overflow-wrap: anywhere; }
.sources a { color: var(--muted); }
.sources :target { background: color-mix(in srgb, var(--partition) 18%, transparent); }
.author-box { display: flex; gap: 1rem; align-items: flex-start; max-width: 680px; padding: 1rem; border: 1px solid var(--rule); background: var(--paper-2); }
.author-box img { border-radius: 50%; width: 64px; height: 64px; object-fit: cover; }
.author-box p { margin: 0; font: 400 .88rem/1.5 var(--sans); color: var(--muted); }
.author-box .ab-name { font-weight: 700; color: var(--ink); margin-bottom: .2rem; }
.widget-locator .crt-mini { margin-left: .8rem; margin-right: .8rem; padding: 8px 8px 16px; border-radius: 10px; }
.crt-mini .crt-screen { padding: .3rem; border-radius: 10px / 12px; }
.loc-cap { margin-top: .6rem !important; font-weight: 600; color: var(--ink) !important; }

/* Reading readout */
.readout { position: fixed; right: 18px; bottom: 18px; z-index: 40; display: flex; align-items: center; gap: .45rem; padding: 5px 6px 5px 10px; background: var(--bezel); border: 1px solid var(--bezel-edge); border-radius: 5px; box-shadow: 0 2px 8px rgba(0, 0, 0, .15); font: 600 .7rem/1 var(--sans); color: var(--bezel-ink); opacity: 0; transform: translateY(8px); transition: opacity .25s, transform .25s; pointer-events: none; }
.readout.on { opacity: 1; transform: none; }
.readout-v { min-width: 3.4em; text-align: right; padding: .18rem .4rem; background: var(--screen); color: var(--glyph); border-radius: 3px; font: 400 1.1rem/1 var(--crt); text-shadow: 0 0 5px rgba(168, 220, 227, .5); }

/* ---------- Bands (desk, author, experts) ---------- */
.band { padding: 2rem var(--gut) 1.8rem; background: var(--paper-2); border-bottom: 1px solid var(--rule); }
.band-title { font: 800 clamp(2.1rem, 5vw, 3.4rem)/1 var(--head); margin: 0; letter-spacing: -.025em; }
.band-dek { margin: .8rem 0 0; font: 400 1.12rem/1.5 var(--text); max-width: 58ch; color: var(--muted); }
.band-meta { margin: .5rem 0 0; font: .84rem var(--sans); color: var(--muted); }
.band-person { display: flex; gap: 1.5rem; align-items: center; }
.band-person img { border-radius: 50%; width: 96px; height: 96px; object-fit: cover; border: 1px solid var(--rule-2); }

/* Roster */
.roster { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.4rem; padding: 1.5rem var(--gut) 3rem; }
.person { display: grid; gap: .25rem; text-decoration: none; padding: 1rem; border: 1px solid var(--rule); border-top: 3px solid var(--accent); background: var(--paper); }
.person img, .person-mono { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; margin-bottom: .4rem; }
.person-mono { background: var(--partition); }
.p-name { font: 700 1.1rem/1.2 var(--head); }
.p-meta { font: 500 .78rem var(--sans); color: var(--muted); }
.p-bio { font: 400 .86rem/1.45 var(--sans); color: var(--muted); }
.person:hover .p-name { text-decoration: underline; color: var(--link); }

/* Error */
.err { padding: 3rem var(--gut) 4rem; max-width: 860px; }
.err-actions { display: flex; gap: .6rem; flex-wrap: wrap; }

/* ---------- Footer ---------- */
.foot { background: var(--carpet); color: var(--on-carpet); font: 400 .88rem/1.5 var(--sans); }
.foot-in { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 2rem; padding: 2.4rem var(--gut) 1.6rem; }
.foot-word { font: 800 1.7rem/1 var(--head); margin: 0 0 .6rem; letter-spacing: -.02em; }
.foot-brand p:not(.foot-word) { color: var(--on-carpet-muted); max-width: 40ch; margin: 0; }
.foot h2 { font: 700 .8rem/1 var(--sans); color: var(--on-carpet-muted); margin: 0 0 .7rem; }
.foot .foot-h2 { margin-top: 1.4rem; }
.foot ul, .foot .nav { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; }
.foot a { color: var(--on-carpet); text-decoration: none; }
.foot a:hover { text-decoration: underline; }
.foot-end { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: .9rem var(--gut); border-top: 1px solid var(--carpet-2); color: var(--on-carpet-muted); font-size: .78rem; }
.foot-end p { margin: 0; display: flex; gap: 1.2rem; }

/* ---------- Responsive ---------- */
@media (max-width: 1240px) { .page { box-shadow: none; } }
@media (max-width: 1020px) {
  .cols { grid-template-columns: minmax(0, 1fr); }
  .side { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
  .console-body { grid-template-columns: minmax(0, 1fr); }
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .ticker { display: none; }
}
@media (max-width: 760px) {
  :root { --gut: 16px; }
  body { font-size: 15px; }
  .today, .head .nav { display: none; }
  .head { padding-top: 1.1rem; }
  .head-side { justify-items: start; }
  .head-line { text-align: left; }
  .top { grid-template-columns: minmax(0, 1fr); }
  .top-side { border-left: 0; padding-left: 0; }
  .grid-3, .desk-grid, .pp-band-list, .pp-key { grid-template-columns: minmax(0, 1fr); }
  .pp-entry { padding-left: 0; border-left: 0; border-top: 1px solid var(--carpet-2); padding-bottom: .9rem; }
  .pp-entry:first-child { border-top: 0; }
  .story-row { grid-template-columns: 50px minmax(0, 1fr); gap: .9rem; }
  .story-row .thumb { display: none; }
  .story-row .dek { display: none; }
  .desk-top .story-lg { grid-template-columns: minmax(0, 1fr); }
  .desk-top .story-lg .media { grid-row: auto; }
  .foot-in { grid-template-columns: minmax(0, 1fr); }
  .ref-band { grid-template-columns: minmax(0, 1fr); }
  .dossier-dl div { grid-template-columns: minmax(0, 1fr); }
  .desks-pp { margin-left: 0; order: -1; }
  .desks li:first-child { order: -2; }
  .pp-strip { flex-wrap: wrap; }
  .readout { right: 10px; bottom: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .worldmap .ping { display: none; }
}
@media print {
  .topbar, .desks, .share, .side, .foot, .readout, .console, .ref-band { display: none; }
  .cols { grid-template-columns: 1fr; }
  .page { box-shadow: none; }
}

/* Small adjustments */
.pp-strip + .a-head .kicker a[href*="preach-practice"] { display: none; }
.related .h-lg { font-size: 1.05rem; line-height: 1.28; }
.related .dek { display: none; }

/* ---------- Masthead additions ---------- */
.wordmark-t { display: block; }
.wordmark-s { display: block; margin-top: .45rem; font: 600 .82rem/1.2 var(--sans); letter-spacing: 0; color: var(--muted); }
.topbar-parent { color: var(--on-carpet-muted) !important; }
@media (max-width: 1020px) { .topbar-parent { display: none; } }

/* ---------- Footer additions ---------- */
.foot-parent { display: inline-block; margin: 1rem 0 .4rem; background: #fff; padding: 4px; border-radius: 2px; }
.foot-parent img { width: 72px; height: 72px; }
.foot-mail { margin: .3rem 0 0 !important; }
.foot .foot-social { display: flex; flex-wrap: wrap; gap: .3rem .9rem; margin-top: .7rem; }

/* ---------- Sidebar course box ---------- */
.widget-course { border-top: 3px solid var(--stamp); }

/* ---------- Empty desk ---------- */
.empty-desk { padding: 1.4rem 1.5rem; border: 1px dashed var(--rule-2); background: var(--paper-2); }
.empty-desk-h { margin: 0 0 .3rem; font: 700 1.1rem/1.3 var(--head); }
.empty-desk p:not(.empty-desk-h) { margin: 0; color: var(--muted); font: 400 .95rem/1.5 var(--text); }
.empty-desk a { color: var(--link); }

/* ---------- Fixed pages served by routes ---------- */
.info-body { max-width: 860px; padding: 1.8rem var(--gut) 3rem; }
.info-body.gh-content { margin-top: 0; }
.info-body.gh-content > p:first-of-type::first-letter { float: none; font: inherit; margin: 0; color: inherit; }
.info-after { padding-top: 0; }
.info-narrow { max-width: 460px; }
.info-note { margin: 1.4rem 0 0; font: 400 .9rem/1.5 var(--sans); color: var(--muted); }
.info-note a, .info-body a:not(.btn) { color: var(--link); }
.desk-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.2rem; }
.desk-card { display: grid; align-content: start; gap: .6rem; padding: 1.1rem; border: 1px solid var(--rule); border-top: 3px solid var(--accent); background: var(--paper); }
.desk-card h2 { margin: 0; font: 700 1.05rem/1.25 var(--head); }
.desk-card p { margin: 0; font: 400 .9rem/1.5 var(--sans); color: var(--muted); }
.desk-card .btn { justify-self: start; margin-top: .3rem; }
.desk-index { margin: 0; display: grid; gap: 0; }
.desk-index div { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 1rem; padding: .85rem 0; border-bottom: 1px solid var(--rule); }
.desk-index dt { font: 700 1.02rem/1.3 var(--head); }
.desk-index dt a { text-decoration: none; color: var(--ink) !important; }
.desk-index dt a:hover { color: var(--link) !important; text-decoration: underline; }
.desk-index dd { margin: 0; font: 400 .95rem/1.5 var(--text); color: var(--muted); }
@media (max-width: 760px) { .desk-index div { grid-template-columns: minmax(0, 1fr); gap: .2rem; } }

/* ---------- Reference band (front page) ---------- */
.ref-band { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin: 1rem var(--gut) 0; }
.ref-tile { display: grid; gap: .35rem; padding: 1rem 1.1rem 1.05rem; text-decoration: none; color: var(--glyph); border-radius: 6px;
  background: radial-gradient(ellipse at 30% 20%, #15405a 0%, var(--screen) 70%); border: 1px solid #061219; box-shadow: inset 0 0 26px rgba(0, 0, 0, .55); position: relative; overflow: hidden; }
.ref-tile::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: repeating-linear-gradient(to bottom, transparent 0 2px, rgba(0, 0, 0, .18) 2px 3px); }
.ref-t { font: 400 1.6rem/1 var(--crt); text-shadow: 0 0 6px rgba(168, 220, 227, .45); }
.ref-d { font: 400 .9rem/1.45 var(--sans); color: #c9e6ea; max-width: 52ch; }
.ref-tile:hover .ref-t { text-decoration: underline; text-underline-offset: 4px; }

/* ---------- Reference pages ---------- */
.band-ref .crumbs a { color: var(--link); }
.ref-meta { margin: .9rem 0 0; font: 400 .84rem/1.4 var(--sans); color: var(--muted); }
.ref-meta a { color: var(--link); }
.ref-draft { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; margin: 1.2rem var(--gut) 0; padding: .65rem .9rem; background: var(--slip); border: 1px solid var(--key-edge); font: 400 .88rem/1.45 var(--sans); }
.chk { display: inline-grid; place-items: center; width: 1.05em; height: 1.05em; margin-left: .35em; border-radius: 50%; font: 700 .72rem/1 var(--sans); color: var(--stamp); border: 1px solid currentColor; vertical-align: .1em; cursor: help; }

.worldmap .c.k1 { fill: var(--k1); } .worldmap .c.k2 { fill: var(--k2); } .worldmap .c.k3 { fill: var(--k3); } .worldmap .c.k4 { fill: var(--k4); }
.worldmap .c.hit:hover, .worldmap .c.hit:focus-visible { stroke: #fff; stroke-width: 1; }
.worldmap .c-dot { stroke-width: .8; }
.crt-key { list-style: none; display: flex; flex-wrap: wrap; gap: .2rem 1rem; margin: .4rem 0 0; padding: 0; font: 400 .98rem/1.1 var(--crt); color: var(--glyph-dim); }
.crt-key li { display: flex; align-items: center; gap: .35rem; }
.crt-key i { width: 16px; height: 8px; display: inline-block; border: 1px solid rgba(255, 255, 255, .15); }
.crt-key .k0 { background: var(--land); } .crt-key .k1 { background: var(--k1); } .crt-key .k2 { background: var(--k2); } .crt-key .k3 { background: var(--k3); } .crt-key .k4 { background: var(--k4); }
.crt-key .l-coop { height: 0; border: 0; border-top: 2px solid var(--glyph); }
.crt-key .l-attr { height: 0; border: 0; border-top: 2px dashed var(--attr); }

.worldmap .rel-coop { stroke: var(--glyph); stroke-opacity: .6; stroke-width: 1.4px; }
.worldmap .rel-attr { stroke: var(--attr); stroke-opacity: .65; stroke-width: 1.3px; stroke-dasharray: 5 3; }
.worldmap .rel-head { fill: var(--attr); }
.worldmap .arc.dim { stroke-opacity: .12; }
.worldmap .rel-coop.on { stroke: #fff; stroke-opacity: 1; stroke-width: 2px; }
.worldmap .rel-attr.on { stroke: #f4d08e; stroke-opacity: 1; stroke-width: 2px; }

.dossier { min-height: 220px; }
.dossier-dl { margin: .2rem 0 .5rem; }
.dossier-dl div { display: grid; grid-template-columns: 98px minmax(0, 1fr); gap: .6rem; padding: .38rem 0; border-top: 1px dashed var(--rule-2); }
.dossier-dl dt { font: 600 .74rem/1.35 var(--sans); color: var(--muted); }
.dossier-dl dd { margin: 0; font: 400 .9rem/1.35 var(--text); }
.dossier-notes { margin: .2rem 0 .5rem; padding-left: 1.1rem; font: 400 .84rem/1.45 var(--sans); }
.dossier-src { margin: .4rem 0 0; font: 400 .78rem/1.4 var(--sans); color: var(--muted); }
.dossier-src a { color: var(--link); }
.dossier-sub { margin: .8rem 0 .1rem; font: 700 .76rem/1.2 var(--sans); color: var(--muted); }
.dossier-note { margin: .2rem 0 .3rem; font: 400 .88rem/1.45 var(--sans); color: var(--muted); }
.rel-list li { display: grid; gap: .15rem; }
.rel-t { font: 400 .9rem/1.35 var(--text); }
.rel-resp { font: italic 400 .8rem/1.3 var(--sans); color: var(--muted); }
.rel-src { font: 400 .74rem/1.3 var(--sans); }
.rel-src a { color: var(--link); }
.relations .chips { max-height: 132px; overflow-y: auto; }

.ledger-filter { width: 100%; max-width: 420px; font: 400 .95rem var(--sans); padding: .6rem .75rem; margin: 0 0 .9rem; border: 1px solid var(--field); border-radius: 2px; background: var(--paper); color: var(--ink); }
.ledger-wrap { overflow-x: auto; border: 1px solid var(--rule); }
.ledger { width: 100%; border-collapse: collapse; font: 400 .86rem/1.4 var(--sans); }
.ledger th, .ledger td { text-align: left; vertical-align: top; padding: .6rem .7rem; border-bottom: 1px solid var(--rule); }
.ledger thead th { background: var(--paper-2); font-weight: 700; font-size: .78rem; white-space: nowrap; }
.ledger tbody tr:hover { background: color-mix(in srgb, var(--paper-2) 70%, transparent); }
.ledger tbody th small { display: block; font-weight: 400; color: var(--muted); }
.ledger td small { color: var(--muted); }
.ledger td a { color: var(--link); }
.ledger-c { font: 700 .9rem/1.3 var(--sans); color: var(--ink); background: none; border: 0; padding: 0; cursor: pointer; text-align: left; }
.ledger-c:hover { color: var(--link); text-decoration: underline; }
.ledger-h { font: 700 1.05rem/1.2 var(--head); margin: 1.6rem 0 .6rem; }
.ledger-h:first-child { margin-top: 0; }
.method { margin-top: 2.6rem; }
.method .sec-h { padding-bottom: .5rem; border-bottom: 2px solid var(--ink); margin-bottom: .4rem; }
.method dl { margin: 0; }
.method div { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 1rem; padding: .8rem 0; border-bottom: 1px solid var(--rule); }
.method dt { font: 700 .9rem/1.35 var(--sans); }
.method dd { margin: 0; font: 400 .98rem/1.55 var(--text); color: var(--muted); max-width: 64ch; }
@media (max-width: 760px) { .method div { grid-template-columns: minmax(0, 1fr); gap: .2rem; } }

/* ==========================================================================
   CyberDiplomacy Observatory
   Atlas hub, country files, document register, comparison, glossary.
   ========================================================================== */
.obs-wrap { padding: 1.8rem var(--gut) 3rem; }
.obs-wrap > section + section, .obs-wrap > .method { margin-top: 2.6rem; }
.obs-wrap .sec-head { margin-top: 0; }
.obs-read { max-width: 860px; }
.obs-read .gh-content, .obs-wrap .gloss-body { margin-top: 0; }
.obs-read .gh-content > p:first-of-type::first-letter, .tag-hash-doc .gh-content > p:first-of-type::first-letter, .gh-content.cmp-c > p:first-of-type::first-letter, .gloss-body > p:first-of-type::first-letter { float: none; font: inherit; margin: 0; color: inherit; }
.panel-label { font: 700 .76rem/1 var(--sans); }
.files-empty { margin: 0; padding: 1.2rem 1.4rem; border: 1px dashed var(--rule-2); background: var(--paper-2); font: 400 .95rem/1.5 var(--sans); color: var(--muted); }
.obs-wrap [hidden], .file [hidden], .console [hidden] { display: none !important; }

/* Section index: numbered like the dividers of a ring binder */
.obs-nav { margin: 1.5rem 0 -1.8rem; }
.obs-nav ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; border-top: 1px solid var(--rule-2); }
.obs-nav a { display: flex; align-items: baseline; gap: .5rem; padding: .7rem 1.3rem .75rem 0; margin-right: 1.3rem; font: 600 .88rem/1 var(--sans); text-decoration: none; color: var(--muted); border-top: 3px solid transparent; margin-top: -2px; }
.obs-nav a:hover { color: var(--ink); }
.obs-nav a[aria-current="page"] { color: var(--ink); border-top-color: var(--accent); }
.obs-n { font: 400 1.1rem/1 var(--crt); color: var(--accent); }

/* Marks: official text, plain terms, analysis */
.mark { display: inline-block; font: 700 .66rem/1 var(--sans); padding: .22rem .4rem .2rem; border: 1px solid currentColor; border-radius: 2px; font-style: normal; white-space: nowrap; }
.mark-off { color: var(--accent); }
.mark-plain { color: var(--muted); border-style: dashed; }
.mark-an { color: var(--stamp); }
.marks-key { list-style: none; margin: 1.6rem 0 0; padding: .9rem 0 0; border-top: 1px solid var(--rule); display: grid; gap: .5rem; font: 400 .84rem/1.45 var(--sans); color: var(--muted); max-width: 760px; }
.marks-key .mark { margin-right: .5rem; min-width: 8.2em; text-align: center; }

/* Atlas: two states, lit and hatched */
.worldmap .c.av { fill: var(--q3); }
.worldmap .c.na { fill: url(#na-hatch); }
.worldmap .na-bg { fill: var(--land); }
.worldmap .na-ln { stroke: var(--screen); stroke-width: 1.5; }
.worldmap .c.na:hover { stroke: var(--glyph-dim); stroke-width: 1; }
.worldmap .c.av.on { fill: var(--q4); stroke: var(--q4); }
.crt-key .av-yes { background: var(--q3); }
.crt-key .av-no { background: repeating-linear-gradient(45deg, var(--land) 0 2px, var(--screen) 2px 4px); }
.av-line { display: flex; align-items: center; gap: .45rem; margin: 0 0 .5rem; font: 700 .78rem/1 var(--sans); }
.av-line::before { content: ""; width: 14px; height: 10px; border: 1px solid var(--key-edge); }
.av-line.is-av::before { background: var(--q3); }
.av-line.is-na::before { background: repeating-linear-gradient(45deg, var(--land) 0 2px, var(--screen) 2px 4px); }
.av-line.is-na { color: var(--muted); }
.dossier .btn { margin: .5rem 0 .3rem; }

/* Country files: index cards with a numbered tab */
.files { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 1.4rem 1.1rem; }
.file-card a { position: relative; display: grid; gap: .3rem; align-content: start; height: 100%; margin-top: 1.3rem; padding: .9rem 1rem 1rem; background: var(--slip); border: 1px solid var(--rule-2); border-top-left-radius: 0; text-decoration: none; }
.file-card-n { position: absolute; left: -1px; bottom: 100%; padding: .12rem .6rem 0; font: 400 1.1rem/1.25 var(--crt); background: var(--carpet); color: var(--on-carpet); border-radius: 4px 9px 0 0; }
.file-card-t { font: 700 1.1rem/1.2 var(--head); }
.file-card-d { font: 400 .86rem/1.45 var(--sans); color: var(--muted); }
.file-card-m { font: 500 .72rem/1.3 var(--sans); color: var(--muted); margin-top: .2rem; }
.file-card a:hover { border-color: var(--accent); }
.file-card a:hover .file-card-t { color: var(--link); text-decoration: underline; }

/* Doors to the other parts */
.obs-doors { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 2px solid var(--ink); border-bottom: 1px solid var(--rule); }
.door { display: grid; gap: .35rem; align-content: start; padding: 1.1rem 1.1rem 1.2rem; text-decoration: none; border-left: 1px solid var(--rule); }
.door:first-of-type { border-left: 0; padding-left: 0; }
.door-n { font: 400 1.5rem/1 var(--crt); color: var(--accent); }
.door-t { font: 700 1.02rem/1.25 var(--head); }
.door-d { font: 400 .86rem/1.45 var(--sans); color: var(--muted); }
.door:hover .door-t { color: var(--link); text-decoration: underline; }

/* Country file page */
.file-head { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 2rem; align-items: center; padding: 2rem var(--gut) 1.6rem; background: var(--paper-2); border-bottom: 1px solid var(--rule); }
.file-no { display: flex; align-items: center; gap: .6rem; margin: 0 0 .6rem; font: 600 .78rem/1 var(--sans); color: var(--muted); }
.stamp-av { color: var(--accent); }
.file-head .cable { margin-top: 1.2rem; border-bottom: 0; padding-bottom: 0; }
.file-map { padding: 8px 8px 16px; border-radius: 10px; }
.file-cols { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 2.6rem; padding: 2rem var(--gut) 3rem; align-items: start; }
.file-tabs { position: sticky; top: 64px; }
.file-tabs ol { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--rule-2); }
.file-tabs a { display: flex; gap: .55rem; align-items: baseline; padding: .5rem 0 .5rem .8rem; margin-left: -1px; border-left: 3px solid transparent; font: 500 .86rem/1.25 var(--sans); color: var(--muted); text-decoration: none; }
.file-tabs a:hover { color: var(--ink); }
.file-tabs a[aria-current] { color: var(--ink); font-weight: 700; border-left-color: var(--accent); }
.file-tab-n { font: 400 1rem/1 var(--crt); color: var(--accent); }
.file-body { margin-top: 0; }
.file-body > * { max-width: none; }
.file-body .sec > * { max-width: 700px; }
.file-body .sec > .parallel, .file-body .sec > .kg-width-wide { max-width: none; }
.file-body .sec + .sec { margin-top: 2.4rem; padding-top: 1.6rem; border-top: 2px solid var(--ink); }
.file-body .sec > h2 { margin-top: 0; }
.file-body .sec-lede { font-size: 1.18rem; }
.sec-analysis { padding: 1.4rem 1.3rem 1rem !important; border: 1px dashed var(--stamp) !important; background: color-mix(in srgb, var(--stamp) 4%, transparent); }
.sec-analysis > .mark { margin-bottom: .6rem; }
.file-foot { margin-top: 2.4rem; }
.file .sources h2, .file .sources ol { max-width: none; }

/* Official wording beside its plain explanation, set like a parallel text */
.gh-content blockquote.is-off { font-style: normal; margin: 1.4rem 0; padding: .8rem 1rem .7rem; background: var(--paper-2); border-left: 3px solid var(--accent); }
.gh-content .kg-callout-card.is-plain { display: block; margin: 1.4rem 0; padding: .8rem 1rem .7rem; background: transparent; border: 1px dashed var(--rule-2); border-left: 3px dashed var(--muted); color: var(--ink); }
.is-plain .kg-callout-emoji { display: none; }
.is-off > .mark, .is-plain > .mark { display: table; margin-bottom: .55rem; }
.is-off > :last-child, .is-plain .kg-callout-text > :last-child { margin-bottom: 0; }
.parallel { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); margin: 1.6rem 0; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--rule-2); }
.parallel > * { margin: 0 !important; max-width: none; font-size: .98rem; line-height: 1.6; }
.gh-content .parallel > blockquote.is-off { border-left: 0; padding: 1rem 1.2rem 1rem 1rem; }
.gh-content .parallel > .kg-callout-card.is-plain { border: 0; border-left: 1px solid var(--rule-2); border-radius: 0; padding: 1rem 0 1rem 1.2rem; }

/* Document register */
.exp-bar { display: grid; grid-template-columns: minmax(200px, 2fr) repeat(4, minmax(0, 1fr)) auto; gap: .8rem; align-items: end; padding: 1rem 1.1rem 1.1rem; background: linear-gradient(var(--bezel), var(--bezel-2)); border: 1px solid var(--bezel-edge); border-radius: 6px; color: var(--bezel-ink); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25); }
.exp-bar label { display: block; font: 700 .72rem/1 var(--sans); margin-bottom: .4rem; }
.exp-bar input[type="search"] { width: 100%; font: 400 .92rem/1 var(--sans); padding: .52rem .7rem; border: 1px solid var(--key-edge); border-radius: 4px; background: var(--slip); color: var(--ink); }
.cmp-bar { grid-template-columns: repeat(3, minmax(0, 1fr)) auto; }
.exp-count { margin: 1rem 0 0; font: 400 .86rem/1.45 var(--sans); color: var(--muted); max-width: 80ch; }
.reg-list { list-style: none; margin: 1rem 0 0; padding: 0; border-top: 2px solid var(--ink); }
.reg { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: .2rem 1.6rem; padding: 1rem 0 1.05rem; border-bottom: 1px solid var(--rule); }
.reg-facets { grid-row: span 2; margin: .1rem 0 0; display: flex; flex-wrap: wrap; align-content: start; align-items: baseline; gap: .3rem .55rem; }
.reg-t { margin: 0; font: 700 1.12rem/1.3 var(--head); }
.reg-t a { text-decoration: none; }
.reg-t a:hover { color: var(--link); text-decoration: underline; }
.reg-d { margin: 0; font: 400 .95rem/1.5 var(--text); color: var(--muted); max-width: 70ch; }
.facet { font: 500 .76rem/1.2 var(--sans); color: var(--muted); }
.facet-c { flex-basis: 100%; font: 700 .86rem/1.2 var(--sans); color: var(--ink); }
.facet-dt { color: var(--accent); border: 1px solid currentColor; border-radius: 2px; padding: .16rem .34rem .14rem; font-weight: 700; font-size: .68rem; }
.facet-y { font: 400 1.12rem/1 var(--crt); color: var(--ink); }
.facet-t::before { content: "/ "; color: var(--rule-2); }

/* Document record (single post) */
.reg-card { padding: 1.3rem 1.4rem 1.2rem; background: var(--paper-2); border: 1px solid var(--rule-2); border-top: 4px double var(--ink); }
.reg-no { margin: 0 0 .8rem; }
.reg-card .cable { border-bottom: 0; padding-bottom: 0; margin-top: 1rem; }
.reg-card .marks-key { margin-top: 1rem; }
.tag-hash-doc .author-box, .tag-hash-doc .related, .tag-hash-doc .a-comments, .tag-hash-doc .widget-locator { display: none; }

/* Comparison */
.cmp { margin-top: 1.2rem; border-top: 2px solid var(--ink); }
.cmp-row { display: grid; grid-template-columns: 150px repeat(var(--n, 2), minmax(0, 1fr)); border-bottom: 1px solid var(--rule-2); }
.cmp-k { margin: 0; padding: 1rem .8rem 1rem 0; font: 700 .86rem/1.3 var(--sans); }
.cmp-c { padding: 1rem 1rem 1rem 1.1rem; border-left: 1px solid var(--rule); font: 400 .95rem/1.6 var(--text); min-width: 0; }
.cmp-c > :first-child { margin-top: 0; } .cmp-c > :last-child { margin-bottom: 0; }
.cmp-c h3 { font-size: 1rem; }
.cmp-c .parallel { grid-template-columns: minmax(0, 1fr); }
.gh-content.cmp-c .parallel > .kg-callout-card.is-plain { border-left: 0; border-top: 1px dashed var(--rule-2); padding: .8rem 0 1rem 1rem; }
.cmp-head { position: sticky; top: 46px; z-index: 5; background: var(--paper-2); }
.cmp-head .cmp-c { display: grid; gap: .25rem; font-family: var(--sans); }
.cmp-name { font: 800 1.2rem/1.15 var(--head); text-decoration: none; }
.cmp-name:hover { color: var(--link); text-decoration: underline; }
.cmp-upd { font: 500 .72rem/1.2 var(--sans); color: var(--muted); }
.na-cell { display: inline-flex; align-items: center; gap: .45rem; margin: 0; font: 700 .78rem/1 var(--sans); color: var(--muted); }
.na-cell::before { content: ""; width: 14px; height: 10px; border: 1px solid var(--rule-2); background: repeating-linear-gradient(45deg, var(--rule-2) 0 2px, transparent 2px 4px); }

/* Glossary */
.gloss-bar { display: flex; flex-wrap: wrap; align-items: center; gap: .8rem 1.2rem; margin-bottom: .6rem; }
.gloss-bar .ledger-filter { margin: 0; }
.gloss-az { display: flex; flex-wrap: wrap; gap: .25rem; }
.gloss-az a { display: grid; place-items: center; min-width: 1.7rem; height: 1.7rem; font: 400 1.15rem/1 var(--crt); text-decoration: none; color: var(--key-ink); background: var(--key); border: 1px solid var(--key-edge); border-bottom-width: 2px; border-radius: 3px; }
.gloss-az a:hover { background: var(--key-on); color: var(--key-on-ink); }
.gloss-body > * { max-width: none; }
.gloss-body .term { padding: 1.3rem 0 1.1rem; border-top: 1px solid var(--rule-2); }
.gloss-body .term:first-of-type { border-top: 2px solid var(--ink); }
.gloss-body .term > * { max-width: 760px; }
.gloss-body .term > .parallel { max-width: none; }
.gloss-body .term h3 { margin: 0 0 .5rem; font-size: 1.3rem; }
.gloss-body .term:target { background: color-mix(in srgb, var(--accent) 8%, transparent); }

@media (max-width: 1020px) {
  .obs-doors { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .door:nth-of-type(odd) { border-left: 0; padding-left: 0; }
  .door:nth-of-type(n+3) { border-top: 1px solid var(--rule); }
  .file-head { grid-template-columns: minmax(0, 1fr); }
  .file-map { max-width: 340px; }
  .exp-bar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .exp-q { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .obs-nav a { padding-right: .2rem; margin-right: 1rem; }
  .obs-doors { grid-template-columns: minmax(0, 1fr); }
  .door { border-left: 0; padding-left: 0; }
  .door + .door { border-top: 1px solid var(--rule); }
  .file-cols { grid-template-columns: minmax(0, 1fr); gap: 1.2rem; }
  .file-tabs { position: static; }
  .file-tabs ol { display: flex; flex-wrap: wrap; gap: 0 1rem; border-left: 0; border-bottom: 1px solid var(--rule-2); }
  .file-tabs a { padding-left: 0; border-left: 0; }
  .parallel { grid-template-columns: minmax(0, 1fr); }
  .gh-content .parallel > .kg-callout-card.is-plain { border-left: 0; border-top: 1px dashed var(--rule-2); padding: .9rem 0 1rem 1rem; }
  .reg { grid-template-columns: minmax(0, 1fr); }
  .reg-facets { grid-row: auto; }
  .facet-c { flex-basis: auto; }
  .exp-bar, .cmp-bar { grid-template-columns: minmax(0, 1fr); }
  .cmp-row { grid-template-columns: minmax(0, 1fr); }
  .cmp-head { position: static; }
  .cmp-head .cmp-k { display: none; }
  .cmp-k { padding-bottom: 0; }
  .cmp-c { border-left: 0; padding-left: 0; }
  .cmp-row:not(.cmp-head) .cmp-c::before { content: attr(data-country); display: block; margin-bottom: .4rem; font: 700 .74rem/1 var(--sans); color: var(--accent); }
  .cmp-row:not(.cmp-head) .cmp-c + .cmp-c { border-top: 1px dashed var(--rule-2); }
}
@media print {
  .obs-nav, .file-tabs, .exp-bar, .file-map { display: none; }
  .file-cols { grid-template-columns: 1fr; }
}
