/* ==========================================================================
   World Music Encyclopedia — LOOK: THE FESTIVAL PROGRAM
   An international music festival's printed program. Warm uncoated stock,
   two plates (near-black + vermilion), a drawn column module, and the map
   as the poster's image plate. Depth is paper, ink and rule — no grey fills,
   no shadows with blur, no rounded corners.
   ========================================================================== */

/* ------------------------------------------------------------ tokens */
:root {
  color-scheme: light;

  --paper: #fbfaf7;
  --ink: #14110f;
  --ink-2: #4f4941;
  --muted: #837b70;
  --accent: #d1462f;          /* the one hot plate */
  --accent-dk: #ab3624;
  --green: #1f4d3f;           /* the second plate: quiet, structural */
  --rule: #e3ded4;            /* hairline: divides */
  --rule-ink: #14110f;        /* strong rule: heads and things you can act on */

  --on-accent: #fbfaf7;
  --border-mesh: rgba(251, 250, 247, .85);   /* country borders read as paper gaps */

  --font-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --t-xs: .75rem;
  --t-sm: .875rem;
  --t-base: 1rem;
  --t-md: 1.125rem;
  --t-lg: 1.375rem;
  --t-xl: 1.75rem;
  --t-2xl: clamp(2rem, 3.4vw, 2.9rem);
  --t-3xl: clamp(3rem, 7.5vw, 6.5rem);

  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 24px;
  --s-6: 32px; --s-7: 48px; --s-8: 64px; --s-9: 96px;

  --map-mark: #14110f;
  --map-line: rgba(20, 17, 15, .16);
  --map-line-faint: rgba(20, 17, 15, .07);
  --on-media: #ffffff;
  --scrim: rgba(20, 17, 15, .42);
  --scrim-strong: rgba(20, 17, 15, .82);
  --player-void: #14110f;

  /* Squared off. A program is printed, cut and stapled — nothing is rounded. */
  --r-xs: 0; --r-sm: 0; --r-md: 0; --r-lg: 0;

  --shadow-dock: 7px 7px 0 var(--ink);   /* flat offset, never a blur */

  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --dur: 200ms;

  --max: 1240px;
  --gutter: clamp(1rem, 4vw, 3rem);
}

/* ------------------------------------------------------------- base */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--t-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  padding-bottom: env(safe-area-inset-bottom);
  counter-reset: part;
}
body.has-dock { padding-bottom: calc(var(--dock-h, 0px) + env(safe-area-inset-bottom)); }

::selection { background: var(--accent); color: var(--on-accent); }
::placeholder { color: var(--muted); opacity: 1; }
html { scrollbar-color: var(--ink) var(--paper); scrollbar-width: thin; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--ink); border: 3px solid var(--paper); }
::-webkit-scrollbar-track { background: var(--paper); }
input, select, textarea, button { caret-color: var(--accent); accent-color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

a { color: var(--accent); text-decoration: none; text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-variation-settings: "wdth" 78, "wght" 700;
  font-weight: 700;
  line-height: .96;
  letter-spacing: -.015em;
  text-transform: uppercase;
  margin: 0;
  text-wrap: balance;
}
h1 { font-size: var(--t-3xl); line-height: .9; letter-spacing: -.025em; }
h2 { font-size: var(--t-2xl); }
h3 { font-size: var(--t-lg); }
h4 { font-size: var(--t-md); }
p { margin: 0; }
p + p { margin-top: 1em; }
small { font-size: var(--t-sm); }
code { font-family: ui-monospace, Consolas, "SF Mono", monospace; font-size: .92em; background: transparent; border: 1px solid var(--rule); padding: .05em .35em; }
[hidden] { display: none !important; }
.muted { color: var(--muted); }
.lede { font-size: var(--t-md); line-height: 1.55; color: var(--ink-2); max-width: 60ch; text-wrap: pretty; }
.place-note { font-size: var(--t-sm); line-height: 1.55; color: var(--muted); max-width: 68ch;
  border-left: 2px solid var(--accent); padding-left: var(--s-4); text-wrap: pretty; }
.crumb { font-size: var(--t-xs); color: var(--muted); display: flex; flex-wrap: wrap; gap: 0 .45em; align-items: baseline;
  text-transform: uppercase; letter-spacing: .1em; font-weight: 600; }
.crumb a { color: var(--ink); }
.crumb .sep { color: var(--accent); }
.count { font-variant-numeric: tabular-nums; color: var(--muted); font-size: var(--t-sm); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.skip-link { position: absolute; left: var(--s-4); top: -100px; background: var(--accent); color: var(--on-accent); padding: .6rem .9rem; z-index: 200; font-weight: 600; }
.skip-link:focus { top: var(--s-3); }

.i { width: 1em; height: 1em; display: inline-block; vertical-align: -.14em; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.i-sm { width: .9em; height: .9em; }

/* ---------------------------------------------------------- header */
/* The bill's masthead: paper, a heavy ink rule under it, nothing floating. */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: var(--paper);
  border-bottom: 2px solid var(--ink);
}
.header-inner {
  max-width: var(--max); margin: 0 auto; padding: var(--s-3) var(--gutter);
  display: flex; align-items: center; justify-content: space-between; gap: var(--s-5);
}
.brand { display: flex; align-items: baseline; gap: var(--s-3); color: var(--ink); min-width: 0; }
.brand:hover { text-decoration: none; }
.brand-name {
  font-family: var(--font-display); font-variation-settings: "wdth" 68, "wght" 800;
  font-size: 1.5rem; text-transform: uppercase; letter-spacing: -.01em; white-space: nowrap; line-height: 1;
}
.brand-sub { font-size: var(--t-xs); color: var(--muted); letter-spacing: .12em; text-transform: uppercase; white-space: nowrap; }
.site-nav { display: flex; gap: var(--s-5); font-size: var(--t-xs); text-transform: uppercase; letter-spacing: .1em; font-weight: 600; }
.site-nav a { color: var(--ink); padding: .35rem 0; border-bottom: 3px solid transparent; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--ink); text-decoration: none; border-bottom-color: var(--accent); }

/* ---------------------------------------------------------- layout */
.wrap { max-width: var(--max); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.section { padding-top: var(--s-9); scroll-margin-top: 76px; }
.section:last-of-type { padding-bottom: var(--s-9); }

/* The program of parts: each section head is numbered off a counter and hung
   on the same drawn rule, so the page reads as a printed running order. */
.section-head { max-width: 68ch; display: grid; gap: var(--s-3); margin-bottom: var(--s-6);
  border-top: 2px solid var(--ink); padding-top: var(--s-3); }
.section-head h2 { counter-increment: part; display: flex; align-items: baseline; gap: var(--s-4); }
.section-head h2::before {
  content: counter(part, decimal-leading-zero);
  font-size: var(--t-sm); font-variation-settings: "wdth" 100, "wght" 700;
  color: var(--accent); letter-spacing: .04em; flex: none;
  font-variant-numeric: tabular-nums;
}
.section-head p { color: var(--ink-2); text-wrap: pretty; }
.page-head { padding-top: var(--s-8); display: grid; gap: var(--s-4); max-width: 72ch; }
.page-head .lede { margin-top: var(--s-2); }

/* ------------------------------------------------------------ intro */
.intro { padding: var(--s-7) 0 var(--s-6); }
.intro-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 460px); gap: var(--s-6) var(--s-7); align-items: end; }
.intro h1 { font-size: var(--t-3xl); }
.intro h1 em { font-style: normal; font-weight: 700; color: var(--accent); }
.intro-aside { display: grid; gap: var(--s-4); padding-bottom: .4rem; }
.search-form { display: flex; gap: 0; }
.search-form input { flex: 1; border-right: 0; }
.intro-hint { font-size: var(--t-sm); color: var(--muted); }
.intro-hint button { font: inherit; color: var(--ink); background: none; border: 0; padding: 0; cursor: pointer; text-decoration: underline; text-underline-offset: .18em; text-decoration-color: var(--accent); }
.intro-hint button:hover { color: var(--accent); }

/* ----------------------------------------------------------- inputs */
input[type="search"], input[type="text"], select {
  font: inherit; color: var(--ink);
  background: transparent; border: 1px solid var(--ink); border-radius: 0;
  padding: .72rem .9rem; min-width: 0; height: 48px;
  transition: border-color var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease-out);
}
input:hover, select:hover { border-color: var(--accent); }
input:focus-visible, select:focus-visible { outline-offset: 0; border-color: var(--accent); }
select {
  cursor: pointer; padding-right: 2.2rem; appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2314110f' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right .7rem center; background-size: 1rem;
}
input[type="search"]::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; width: 14px; height: 14px; cursor: pointer;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23837b70' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M18 6 6 18M6 6l12 12'/%3E%3C/svg%3E") center / contain no-repeat; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  font: inherit; font-size: var(--t-xs); font-weight: 700; line-height: 1; cursor: pointer; white-space: nowrap;
  text-transform: uppercase; letter-spacing: .1em;
  color: var(--ink); background: transparent; border: 1px solid var(--ink); border-radius: 0;
  padding: 0 1.1rem; height: 48px;
  transition: background var(--dur) var(--ease-out), color var(--dur) var(--ease-out), border-color var(--dur) var(--ease-out);
}
.btn:hover { text-decoration: none; background: var(--ink); color: var(--paper); }
.btn:active { transform: translateY(1px); }
.btn:disabled, .btn[aria-busy="true"] { opacity: .5; cursor: progress; transform: none; }
/* The one hot plate holds a whole block, not a hairline. */
.btn-primary { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.btn-primary:hover { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.btn-quiet { background: transparent; border-color: var(--rule); color: var(--ink-2); }
.btn-quiet:hover { color: var(--paper); background: var(--ink); border-color: var(--ink); }
.btn-sm { height: 38px; padding: 0 .8rem; }
.btn .i { width: 1.05em; height: 1.05em; }

.icon-btn {
  width: 38px; height: 38px; display: inline-grid; place-items: center; cursor: pointer;
  background: var(--paper); color: var(--ink); border: 1px solid var(--ink); border-radius: 0;
  transition: background var(--dur) var(--ease-out), color var(--dur) var(--ease-out);
}
.icon-btn:hover { background: var(--ink); color: var(--paper); }
.icon-btn .i { width: 18px; height: 18px; }

/* chips & tags — listing entries, cut square. Never pills. */
.chip, .tag {
  display: inline-flex; align-items: center; gap: .4rem; text-decoration: none;
  font: inherit; font-size: var(--t-xs); line-height: 1; cursor: pointer;
  text-transform: uppercase; letter-spacing: .07em; font-weight: 600;
  color: var(--ink); background: transparent; border: 1px solid var(--rule);
  border-radius: 0; padding: .55rem .7rem; min-height: 32px;
  transition: color var(--dur) var(--ease-out), border-color var(--dur) var(--ease-out), background var(--dur) var(--ease-out);
}
.chip:hover, .tag:hover { color: var(--paper); background: var(--ink); border-color: var(--ink); text-decoration: none; }
.chip[aria-pressed="true"], .chip.active { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.tag-genre { color: var(--accent); border-color: var(--accent); }
.tag-genre:hover { background: var(--accent); color: var(--on-accent); }
.tag-place { color: var(--ink-2); }
/* A culture crosses borders, so its edge is drawn as one that does not close. */
.tag-culture { color: var(--ink-2); border-style: dashed; }
.tag .n { color: var(--muted); font-variant-numeric: tabular-nums; }
.tag:hover .n { color: inherit; }
.tag-row { display: flex; flex-wrap: wrap; gap: var(--s-2); }
.tag-row.lg .tag { font-size: var(--t-sm); padding: .65rem .9rem; min-height: 40px; }
.chip-row { display: flex; flex-wrap: wrap; gap: var(--s-2); align-items: center; }
.chip-row .label { font-size: var(--t-xs); color: var(--muted); margin-right: var(--s-1); text-transform: uppercase; letter-spacing: .1em; font-weight: 600; }

/* -------------------------------------------------------------- map */
/* The poster's image plate: land printed straight onto the stock, no dark box. */
.map-section { padding-top: 0; }
.map-caption { display: flex; justify-content: space-between; gap: var(--s-4); align-items: baseline;
  margin-bottom: var(--s-3); font-size: var(--t-xs); color: var(--muted); flex-wrap: wrap;
  text-transform: uppercase; letter-spacing: .1em; font-weight: 600; }
.map-caption strong { color: var(--ink); font-weight: 700; }
.map-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0; }
.map-frame {
  position: relative; background: var(--paper); border: 2px solid var(--ink);
  overflow: hidden; aspect-ratio: 2 / 1.05; min-height: 360px;
}
.world-map { width: 100%; height: 100%; display: block; }
.world-map svg { width: 100%; height: 100%; display: block; cursor: grab; touch-action: none; }
.world-map svg:active { cursor: grabbing; }
.country, .borders, .graticule, .sphere, .culture-outline, .culture-hit { vector-effect: non-scaling-stroke; }
.country { stroke: var(--paper); stroke-width: .6; fill-opacity: .9; cursor: pointer; transition: fill-opacity var(--dur) var(--ease-out), opacity 600ms var(--ease-out); }
.country:hover { fill-opacity: 1; stroke: var(--map-mark); stroke-width: 1; }
.country.dim { fill-opacity: .14; }
.country.selected { fill-opacity: 1; stroke: var(--map-mark); stroke-width: 1.6; }
.country.unmapped { fill: #e8e3d9; cursor: default; }
.world-map.entering .country { opacity: 0; }
.borders { stroke: var(--border-mesh); }

.cultures { transition: opacity 600ms var(--ease-out); }
.world-map.entering .cultures { opacity: 0; }
.culture-outline {
  fill: none; stroke-width: 1.5; stroke-dasharray: 2 3.4; stroke-linecap: round;
  opacity: .95; pointer-events: none;
  filter: drop-shadow(0 0 1.2px rgba(251, 250, 247, .95));
  transition: opacity var(--dur) var(--ease-out), stroke-width var(--dur) var(--ease-out);
}
.culture-outline.hover, .culture-outline.selected { opacity: 1; stroke-width: 2.2; stroke-dasharray: 3 3; }
.culture-outline.dim { opacity: .18; }
.culture-hit { fill: none; stroke: transparent; stroke-width: 7; pointer-events: stroke; cursor: pointer; }
.graticule { fill: none; stroke: var(--map-line-faint); stroke-width: .5; }
.sphere { fill: none; stroke: var(--map-line); }
.map-tooltip {
  position: absolute; pointer-events: none; z-index: 5; white-space: nowrap;
  background: var(--ink); color: var(--paper); border: 0; border-radius: 0;
  padding: .45rem .7rem; font-size: var(--t-xs); line-height: 1.3;
  text-transform: uppercase; letter-spacing: .08em; font-weight: 600;
  transform: translate(-50%, calc(-100% - 12px));
}
.map-tooltip small { display: block; color: rgba(251, 250, 247, .68); font-size: var(--t-xs); margin-top: .1rem; text-transform: none; letter-spacing: 0; font-weight: 400; }
.map-controls { position: absolute; top: 0; right: 0; display: flex; flex-direction: column; gap: 0; }
.map-controls .icon-btn { border-top: 0; border-right: 0; }
.map-legend { position: absolute; left: 0; bottom: 0; display: flex; flex-wrap: wrap; gap: 0; max-width: 100%; }
.legend-item {
  display: inline-flex; align-items: center; gap: .45rem; font: inherit; font-size: var(--t-xs); cursor: pointer; line-height: 1;
  text-transform: uppercase; letter-spacing: .08em; font-weight: 600;
  background: var(--paper); color: var(--ink); border: 1px solid var(--ink); border-left: 0; border-bottom: 0; border-radius: 0;
  padding: .55rem .75rem; min-height: 32px;
  transition: color var(--dur) var(--ease-out), background var(--dur) var(--ease-out);
}
.legend-item:first-child { border-left: 0; }
.legend-item:hover { background: var(--ink); color: var(--paper); }
.legend-item[aria-pressed="true"] { background: var(--c); color: var(--paper); }
.swatch { width: 10px; height: 10px; background: var(--c); display: inline-block; flex: none; }
.map-status { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font-size: var(--t-sm); padding: var(--s-5); text-align: center; }

/* explore panel — ruled, never boxed and never filled */
.explore { background: transparent; border: 0; border-bottom: 2px solid var(--ink); padding: var(--s-5) 0; }
.explore-body { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr) minmax(0, 1fr); gap: var(--s-5) var(--s-7); align-items: start; }
.explore-col { display: grid; gap: var(--s-4); align-content: start; min-width: 0; }
.explore-col.quick { align-self: center; }
.explore h3 { font-size: var(--t-xl); }
.explore .lead { color: var(--ink-2); font-size: var(--t-sm); line-height: 1.55; }
.explore-picker { display: grid; gap: var(--s-2); }
.explore-picker label, .explore-list h4, .quick .label {
  font-family: var(--font-body); font-size: var(--t-xs); font-weight: 700; text-transform: uppercase; letter-spacing: .12em; color: var(--accent); }
.explore-actions { display: flex; flex-wrap: wrap; gap: var(--s-2); }
.explore-list h4 { margin-bottom: var(--s-2); }
.mini { display: block; padding: var(--s-3) 0; border-top: 1px solid var(--rule); color: var(--ink); font-size: var(--t-sm); line-height: 1.4; }
.mini:last-child { border-bottom: 1px solid var(--rule); }
.mini:hover { color: var(--accent); text-decoration: none; }
.mini small { display: block; color: var(--muted); font-size: var(--t-xs); margin-top: .15rem; }
.quick { display: flex; flex-wrap: wrap; gap: var(--s-2); align-items: center; }

/* ------------------------------------------------------------ listen */
.listen-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-6); align-items: start; }
.pane { display: flex; flex-direction: column; gap: var(--s-4); background: transparent;
  border: 0; border-top: 2px solid var(--ink); border-radius: 0; padding: var(--s-4) 0 0; min-width: 0; }
.pane-head { display: flex; align-items: baseline; justify-content: space-between; gap: var(--s-4); }
.pane-head h3 { display: flex; align-items: center; gap: .55rem; font-size: var(--t-lg); }
.pane-note { font-size: var(--t-xs); color: var(--muted); text-align: right; text-wrap: pretty; }
.pane-note.warn { color: var(--accent); }
.source-dot { width: 10px; height: 10px; display: inline-block; background: var(--c); }
.pane-form { display: flex; gap: 0; }
.pane-form input { flex: 1 1 200px; border-right: 0; }
.pane-form select { flex: 0 0 auto; width: 118px; border-right: 0; }

.results { min-height: 96px; display: grid; gap: 0; }
.results-empty { color: var(--muted); font-size: var(--t-sm); padding: var(--s-3) 0; line-height: 1.55; }
.result {
  display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: var(--s-4); align-items: center; text-align: left;
  width: 100%; padding: var(--s-3) var(--s-2); margin: 0; font: inherit; color: var(--ink); cursor: pointer;
  background: transparent; border: 0; border-bottom: 1px solid var(--rule); border-radius: 0;
  transition: background var(--dur) var(--ease-out), color var(--dur) var(--ease-out);
}
.result:hover { background: var(--ink); color: var(--paper); }
.result:hover .meta, .result:hover .meta b { color: rgba(251, 250, 247, .72); }
.result:focus-visible { outline-offset: -2px; }
.result .thumb { position: relative; aspect-ratio: 16 / 9; border-radius: 0; background: #e8e3d9 center / cover no-repeat; overflow: hidden; }
.result .thumb.square { background-size: contain; background-color: #e8e3d9; }
.result .thumb .dur { position: absolute; right: 0; bottom: 0; background: var(--scrim-strong); color: var(--on-media); font-size: var(--t-xs); padding: .1rem .35rem; font-variant-numeric: tabular-nums; }
.result .thumb .go { position: absolute; inset: 0; display: grid; place-items: center; color: var(--on-media); background: var(--accent); opacity: 0; transition: opacity var(--dur) var(--ease-out); }
.result .thumb .go .i { width: 22px; height: 22px; stroke-width: 2; }
.result:hover .thumb .go, .result:focus-visible .thumb .go { opacity: 1; }
.result .body { display: grid; gap: .2rem; min-width: 0; }
.result .title { font-size: var(--t-sm); font-weight: 600; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.result .meta { font-size: var(--t-xs); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-transform: uppercase; letter-spacing: .07em; }
.result .meta b { font-weight: 700; color: var(--ink-2); }
.results-foot { display: flex; justify-content: space-between; align-items: center; gap: var(--s-4); margin-top: var(--s-3); font-size: var(--t-xs); color: var(--muted); flex-wrap: wrap; text-transform: uppercase; letter-spacing: .1em; font-weight: 600; }
.results-foot a { display: inline-flex; align-items: center; gap: .35rem; }

.notice { display: grid; gap: var(--s-3); font-size: var(--t-sm); line-height: 1.5; padding: var(--s-4);
  border-radius: 0; background: transparent; border: 1px solid var(--ink); color: var(--ink-2); }
/* The errata slip: the one place the hot plate becomes a full field. */
.notice.error { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.notice.error a, .notice.error .btn, .notice.error strong { color: var(--on-accent); border-color: var(--on-accent); }
.notice.error .btn:hover { background: var(--on-accent); color: var(--accent); }
.notice .actions { display: flex; flex-wrap: wrap; gap: var(--s-2); }
.notice strong { color: var(--ink); font-weight: 700; }

.spinner { display: inline-block; width: 14px; height: 14px; border: 2px solid var(--rule); border-top-color: var(--accent); border-radius: 50%; animation: spin .8s linear infinite; vertical-align: -2px; margin-right: .45rem; }
@keyframes spin { to { transform: rotate(360deg); } }

/* --------------------------------------------------------- geography */
.geo-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-7) var(--s-6); }
.continent { min-width: 0; }
.continent-head { display: flex; align-items: baseline; gap: var(--s-3); padding-bottom: var(--s-3); border-bottom: 2px solid var(--ink); }
.continent-head .swatch { width: 12px; height: 12px; align-self: center; }
.continent-head h3 { font-size: var(--t-lg); }
.continent-head h3 a { color: var(--ink); }
.continent-head h3 a:hover { color: var(--accent); text-decoration: none; }
.continent-head .count { margin-left: auto; }
.region { border-bottom: 1px solid var(--rule); }
.region summary { display: flex; align-items: center; gap: var(--s-3); padding: var(--s-3) 0; cursor: pointer; list-style: none; color: var(--ink); }
.region summary::-webkit-details-marker { display: none; }
.region summary .i { margin-left: auto; color: var(--muted); transition: transform var(--dur) var(--ease-out); }
.region[open] summary .i { transform: rotate(180deg); }
.region summary a { color: var(--ink); font-weight: 600; text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 2px; text-underline-offset: .22em; }
.region summary a:hover { color: var(--accent); }
.region-body { display: grid; gap: var(--s-3); padding: 0 0 var(--s-4) 0; font-size: var(--t-sm); color: var(--ink-2); line-height: 1.55; }
.region-body .tag-row .tag { font-size: var(--t-xs); min-height: 28px; padding: .4rem .6rem; }

.tagcloud { margin-top: var(--s-7); display: grid; gap: var(--s-3); }
.tagcloud h3 { font-size: var(--t-xs); font-family: var(--font-body); font-weight: 700; color: var(--accent); text-transform: uppercase; letter-spacing: .12em; }

/* ---------------------------------------------------------- entries */
/* The running order: numbered, ruled, never boxed. */
.entries { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 0; border-top: 2px solid var(--ink); counter-reset: entry; }
.entry { display: grid; gap: var(--s-3); padding: var(--s-5) var(--s-6) var(--s-5) 0; border-bottom: 1px solid var(--rule); align-content: start; min-width: 0; }
.entry h3 { font-size: var(--t-lg); counter-increment: entry; display: flex; gap: var(--s-3); align-items: baseline; }
.entry h3::before { content: counter(entry, decimal-leading-zero); font-size: var(--t-xs); color: var(--accent); flex: none; font-variant-numeric: tabular-nums; font-variation-settings: "wdth" 100, "wght" 700; }
.entry h3 a { color: var(--ink); }
.entry h3 a:hover { color: var(--accent); text-decoration: none; }
.entry .dek { color: var(--ink-2); font-size: var(--t-sm); line-height: 1.55; text-wrap: pretty; }
.entry .tag-row .tag { font-size: var(--t-xs); min-height: 28px; padding: .4rem .6rem; }
.entry-hero { display: block; aspect-ratio: 16 / 9; border-radius: 0; background: #e8e3d9 center / cover; }
.empty-hint { color: var(--muted); font-size: var(--t-sm); padding: var(--s-5) 0; border-top: 2px solid var(--ink); border-bottom: 1px solid var(--rule); line-height: 1.6; }

/* -------------------------------------------------------- resources */
.resources { border-top: 2px solid var(--ink); }
.resource {
  display: grid; grid-template-columns: 180px minmax(0, 1fr) auto; gap: var(--s-5); align-items: baseline;
  padding: var(--s-4) var(--s-2); border-bottom: 1px solid var(--rule); color: var(--ink);
  transition: background var(--dur) var(--ease-out), color var(--dur) var(--ease-out);
}
.resource:hover { text-decoration: none; background: var(--ink); color: var(--paper); }
.resource:hover .resource-name, .resource:hover .resource-kind, .resource:hover .resource-desc, .resource:hover .resource-host { color: var(--paper); }
.resource-kind { font-size: var(--t-xs); text-transform: uppercase; letter-spacing: .12em; color: var(--accent); font-weight: 700; }
.resource-name { font-family: var(--font-display); font-variation-settings: "wdth" 78, "wght" 700; font-size: var(--t-lg); text-transform: uppercase; display: block; margin-bottom: .2rem; }
.resource-desc { color: var(--ink-2); font-size: var(--t-sm); line-height: 1.55; text-wrap: pretty; }
.resource-host { font-size: var(--t-xs); color: var(--muted); white-space: nowrap; display: inline-flex; align-items: center; gap: .35rem; }

/* ------------------------------------------------------------ place */
.place-children { display: grid; gap: var(--s-3); }
.place h2 { font-size: var(--t-xl); margin-top: var(--s-7); }

/* ---------------------------------------------------------- article */
.article { max-width: 72ch; margin: 0 auto; padding: var(--s-8) var(--gutter) var(--s-9); display: grid; gap: var(--s-5); }
.article-head { display: grid; gap: var(--s-4); }
.article-head h1 { font-size: clamp(2.4rem, 5.5vw, 4.2rem); }
.byline { color: var(--muted); font-size: var(--t-xs); text-transform: uppercase; letter-spacing: .1em; font-weight: 600; }
.article-hero { aspect-ratio: 21 / 9; border-radius: 0; background: #e8e3d9 center / cover; border: 1px solid var(--ink); }
.prose { font-size: 1.0625rem; line-height: 1.75; color: var(--ink); }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { font-size: var(--t-xl); margin-top: 2.2em; }
.prose h3 { font-size: var(--t-lg); margin-top: 1.8em; }
.prose h2 + *, .prose h3 + * { margin-top: .6em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: .35em; }
.prose blockquote { border-left: 3px solid var(--accent); margin: 1.5em 0; padding: .1em 0 .1em 1.2em; color: var(--ink-2);
  font-family: var(--font-display); font-variation-settings: "wdth" 92, "wght" 500; font-size: 1.2em; text-transform: none; line-height: 1.35; }
.prose img { max-width: 100%; border-radius: 0; }
.prose .table-wrap, .prose table { display: block; overflow-x: auto; }
.prose table { border-collapse: collapse; width: 100%; font-size: var(--t-sm); line-height: 1.45; }
.prose th, .prose td { border-bottom: 1px solid var(--rule); padding: .6em .8em .6em 0; text-align: left; vertical-align: top; }
.prose th { color: var(--accent); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; font-size: var(--t-xs); }
.prose .toc { display: flex; flex-wrap: wrap; gap: .4em 1.2em; align-items: baseline; padding: var(--s-3) 0; border-top: 2px solid var(--ink); border-bottom: 1px solid var(--rule); font-size: var(--t-sm); }
.prose .toc::before { content: "In this entry:"; color: var(--accent); text-transform: uppercase; letter-spacing: .1em; font-size: var(--t-xs); font-weight: 700; }
.prose .toc ul { display: contents; list-style: none; padding: 0; margin: 0; }
.prose .toc li { display: inline; }
.prose .toc li + li { margin-top: 0; }
.prose .toc a { color: var(--ink); }
.prose .toc a:hover { color: var(--accent); }
.article-listen { display: grid; gap: var(--s-3); padding: var(--s-5) 0; border-top: 2px solid var(--ink); border-bottom: 1px solid var(--rule); }
.article-listen h2 { font-size: var(--t-lg); }
.related h2 { font-size: var(--t-xl); margin-bottom: var(--s-4); }

/* ----------------------------------------------------------- footer */
/* The colophon: the one full block of the second plate. */
.site-footer { border-top: 0; margin-top: var(--s-9); padding: var(--s-7) 0 var(--s-8);
  background: var(--green); color: rgba(251, 250, 247, .8); font-size: var(--t-sm); line-height: 1.6; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: var(--s-7); }
.footer-grid strong { color: var(--paper); font-weight: 700; }
.site-footer code { border-color: rgba(251, 250, 247, .3); color: var(--paper); }
.footer-links { display: grid; gap: var(--s-2); }
.footer-links a { color: var(--paper); text-transform: uppercase; letter-spacing: .08em; font-size: var(--t-xs); font-weight: 600; }

/* ------------------------------------------------------------- dock */
.dock {
  position: fixed; right: var(--s-5); bottom: var(--s-5); z-index: 90;
  width: min(440px, calc(100vw - 2 * var(--s-5)));
  background: var(--paper); border: 2px solid var(--ink); border-radius: 0;
  box-shadow: var(--shadow-dock); overflow: hidden;
  transform: translateY(0); opacity: 1;
  transition: transform 300ms var(--ease-out), opacity 300ms var(--ease-out);
}
.dock[hidden] { display: block !important; transform: translateY(24px); opacity: 0; pointer-events: none; visibility: hidden; transition: transform 300ms var(--ease-out), opacity 300ms var(--ease-out), visibility 0s 300ms; }
.dock-head { display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto; align-items: center; gap: 0; padding: 0 0 0 var(--s-4); border-bottom: 2px solid var(--ink); }
.dock-title { font-size: var(--t-xs); color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  text-transform: uppercase; letter-spacing: .1em; font-weight: 700; padding: var(--s-2) 0; }
.dock-title small { display: block; color: var(--muted); font-size: var(--t-xs); text-transform: none; letter-spacing: 0; font-weight: 400; }
.dock .icon-btn { width: 38px; height: 38px; border: 0; border-left: 1px solid var(--rule); background: transparent; }
.dock .icon-btn:hover { background: var(--accent); color: var(--on-accent); }
.dock-frame { aspect-ratio: 16 / 9; background: var(--player-void); }
.dock-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.dock.min .dock-frame { display: none; }

/* ------------------------------------------------------- responsive */
@media (max-width: 1080px) {
  .geo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .explore-body { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
}
@media (max-width: 900px) {
  .intro-grid { grid-template-columns: 1fr; gap: var(--s-5); align-items: start; }
  .explore-body { grid-template-columns: 1fr; }
  .listen-grid { grid-template-columns: 1fr; }
  .resource { grid-template-columns: minmax(0, 1fr); gap: var(--s-1); }
  .resource-kind { order: 2; }
  .resource-host { display: none; }
  .footer-grid { grid-template-columns: 1fr; gap: var(--s-5); }
}
@media (max-width: 640px) {
  .header-inner { flex-wrap: wrap; gap: var(--s-2) var(--s-4); padding-bottom: var(--s-2); }
  .brand-sub { display: none; }
  .site-nav { width: 100%; gap: var(--s-4); overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .site-nav::-webkit-scrollbar { display: none; }
  .search-form { flex-direction: column; }
  .search-form input { border-right: 1px solid var(--ink); border-bottom: 0; }
  .pane-form { flex-wrap: wrap; }
  .pane-form input { flex-basis: 100%; border-right: 1px solid var(--ink); border-bottom: 0; }
  .pane-form select { flex: 1; width: auto; }
  .map-frame { aspect-ratio: auto; min-height: 0; display: flex; flex-direction: column; }
  .world-map { flex: none; height: auto; aspect-ratio: 2 / 1.05; }
  .map-controls { position: static; order: 3; flex-direction: row; justify-content: flex-end; border-top: 1px solid var(--ink); }
  .map-controls .icon-btn { border: 0; border-left: 1px solid var(--rule); }
  .map-legend { position: static; order: 2; border-top: 2px solid var(--ink); }
  .legend-item { border-top: 0; border-bottom: 0; border-left: 0; border-right: 1px solid var(--rule); }
  .geo-grid { grid-template-columns: 1fr; gap: var(--s-6); }
  .result { grid-template-columns: 96px minmax(0, 1fr); gap: var(--s-3); }
  .dock { right: 0; bottom: 0; width: 100%; border-radius: 0; border-left: 0; border-right: 0; border-bottom: 0; box-shadow: none; }
  .section { padding-top: var(--s-8); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0ms !important; animation-duration: 0ms !important; }
  .world-map.entering .country { opacity: 1; }
}
