/* ============================================================
   ORBITAL · bridge.css — sci-fi mission-console design system
   ============================================================ */

:root {
  --bg: #04060b;
  --bg-1: #070c14;
  --bg-2: #0a1119;
  --panel: rgba(9, 16, 26, 0.78);
  --panel-2: rgba(13, 22, 34, 0.9);
  --line: rgba(56, 225, 255, 0.16);
  --line-2: rgba(56, 225, 255, 0.34);
  --line-3: rgba(56, 225, 255, 0.6);
  --cyan: #38e1ff;
  --cyan-2: #7defff;
  --cyan-dim: #16788f;
  --amber: #ffb347;
  --amber-dim: #8a5d20;
  --green: #46f5a0;
  --red: #ff5f7e;
  --text: #d5e5f2;
  --text-2: #9db2c6;
  --muted: #64798e;
  --muted-2: #44566a;

  --mono: ui-monospace, "Cascadia Mono", "SFMono-Regular", "JetBrains Mono", Menlo, Consolas, monospace;
  --sans: system-ui, -apple-system, "Segoe UI", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;

  --gut: 22px;
  --maxw: 1320px;
  --rad: 2px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
  background-image:
    radial-gradient(1100px 620px at 78% -12%, rgba(20, 90, 130, 0.30), transparent 62%),
    radial-gradient(900px 520px at 8% 108%, rgba(60, 24, 90, 0.28), transparent 60%),
    linear-gradient(180deg, #04060b 0%, #050910 46%, #04060b 100%);
  background-attachment: fixed;
}

/* ---------- fixed atmosphere layers ---------- */
#stars {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  opacity: 0.85;
}

.grid-overlay {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(56, 225, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(56, 225, 255, 0.045) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(circle at 50% 22%, #000 0%, transparent 78%);
  -webkit-mask-image: radial-gradient(circle at 50% 22%, #000 0%, transparent 78%);
}

.scanlines {
  position: fixed;
  inset: 0;
  z-index: 9;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.024) 0px,
    rgba(255, 255, 255, 0.024) 1px,
    transparent 1px,
    transparent 3px
  );
  mix-blend-mode: overlay;
  opacity: 0.55;
}

.vignette {
  position: fixed;
  inset: 0;
  z-index: 8;
  pointer-events: none;
  background: radial-gradient(ellipse at 50% 42%, transparent 42%, rgba(0, 0, 0, 0.62) 100%);
}

/* ---------- shell ---------- */
.wrap {
  position: relative;
  z-index: 2;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--gut) 64px;
}

/* ---------- top bar ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 13px 0 12px;
  margin-bottom: 22px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(4, 6, 11, 0.96), rgba(4, 6, 11, 0.72) 70%, transparent);
  backdrop-filter: blur(9px);
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
}

.brand__mark {
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.34em;
  color: var(--cyan);
  text-shadow: 0 0 18px rgba(56, 225, 255, 0.55);
}

.brand__zh {
  font-size: 11px;
  letter-spacing: 0.3em;
  color: var(--muted);
}

.nav {
  display: flex;
  gap: 4px;
  margin-left: auto;
  flex-wrap: wrap;
}

.nav a {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-2);
  text-decoration: none;
  padding: 7px 11px;
  border: 1px solid transparent;
  border-radius: var(--rad);
  transition: color 0.15s, border-color 0.15s, background 0.15s;
}

.nav a:hover { color: var(--cyan); border-color: var(--line-2); background: rgba(56, 225, 255, 0.05); }
.nav a[aria-current="page"] { color: var(--cyan); border-color: var(--line-2); }

.clock {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--muted);
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 7px;
}
.clock b { color: var(--cyan-2); font-weight: 500; }
.dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 9px var(--green);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.25; } }

/* ---------- hero ---------- */
.hero { padding: 22px 0 8px; position: relative; }

.eyebrow {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--cyan-dim);
  margin: 0 0 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.eyebrow::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--line-2), transparent);
}

h1.headline {
  font-size: clamp(30px, 5.2vw, 58px);
  line-height: 1.03;
  margin: 0 0 16px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: #eaf5ff;
}
h1.headline em {
  font-style: normal;
  color: var(--cyan);
  text-shadow: 0 0 34px rgba(56, 225, 255, 0.42);
}

.sub {
  color: var(--text-2);
  font-size: 15px;
  line-height: 1.62;
  max-width: 62ch;
  margin: 0 0 30px;
}

/* ---------- countdown block ---------- */
.countdown {
  position: relative;
  border: 1px solid var(--line-2);
  border-radius: var(--rad);
  background:
    linear-gradient(120deg, rgba(56, 225, 255, 0.07), transparent 42%),
    var(--panel);
  padding: 20px 22px 18px;
  margin-bottom: 16px;
  overflow: hidden;
}
.countdown::before,
.countdown::after {
  content: "";
  position: absolute;
  width: 16px; height: 16px;
  border: 2px solid var(--cyan);
  opacity: 0.85;
}
.countdown::before { top: -2px; left: -2px; border-right: 0; border-bottom: 0; }
.countdown::after { bottom: -2px; right: -2px; border-left: 0; border-top: 0; }

.cd-head {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.tag {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--amber);
  border: 1px solid var(--amber-dim);
  padding: 4px 8px;
  border-radius: var(--rad);
}
.cd-mission {
  font-size: 13px;
  color: var(--text-2);
  letter-spacing: 0.02em;
}

.cd-digits {
  font-family: var(--mono);
  font-size: clamp(38px, 7.6vw, 76px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.02em;
  color: #f2fbff;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 48px rgba(56, 225, 255, 0.4);
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}
.cd-digits .lbl {
  font-size: 11px;
  letter-spacing: 0.3em;
  color: var(--cyan-dim);
  text-shadow: none;
}
.cd-digits .sep { color: var(--cyan-dim); }

.cd-meta {
  margin-top: 12px;
  display: flex;
  gap: 22px;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.cd-meta b { color: var(--text-2); font-weight: 500; }

/* ---------- metric strip ---------- */
.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 26px;
}
.metric {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: var(--rad);
  padding: 13px 14px;
  position: relative;
}
.metric__k {
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}
.metric__v {
  font-family: var(--mono);
  font-size: 21px;
  font-weight: 500;
  color: #eaf7ff;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}
.metric__v small { font-size: 11px; color: var(--muted); margin-left: 3px; letter-spacing: 0.06em; }
.metric__n { font-size: 11px; color: var(--muted); margin-top: 5px; }

/* ---------- tonight summary ---------- */
.tonight {
  border-left: 2px solid var(--cyan);
  background: linear-gradient(90deg, rgba(56, 225, 255, 0.07), transparent 70%);
  padding: 14px 18px;
  margin: 0 0 26px;
}
.tonight__k {
  display: block;
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--cyan-dim);
  margin-bottom: 7px;
}
.tonight__t {
  margin: 0;
  font-size: 15.5px;
  line-height: 1.66;
  color: var(--text);
  max-width: 92ch;
}

/* ---------- panels ---------- */
.grid2 {
  display: grid;
  grid-template-columns: 1.55fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}
.grid2.rev { grid-template-columns: 1fr 1.55fr; }

.panel {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: var(--rad);
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
}
.panel__hd {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  background: rgba(56, 225, 255, 0.035);
}
.panel__t {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--cyan);
}
.panel__hint {
  margin-left: auto;
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.14em;
  color: var(--muted-2);
  text-transform: uppercase;
}
.panel__bd { padding: 14px; flex: 1; min-width: 0; }

/* ---------- world map ---------- */
.mapbox { position: relative; width: 100%; }
.mapbox svg { display: block; width: 100%; height: auto; }
#map .land {
  fill: rgba(122, 202, 236, 0.15);
  stroke: rgba(132, 226, 255, 0.55);
  stroke-width: 0.5;
  vector-effect: non-scaling-stroke;
}
#map .graticule {
  stroke: rgba(56, 225, 255, 0.075);
  stroke-width: 0.5;
  fill: none;
  vector-effect: non-scaling-stroke;
}
#map .track {
  fill: none;
  stroke: var(--green);
  stroke-width: 1.3;
  stroke-dasharray: 3 3;
  opacity: 0.9;
  vector-effect: non-scaling-stroke;
}
#map .track-fade { fill: none; stroke: rgba(70, 245, 160, 0.18); stroke-width: 6; vector-effect: non-scaling-stroke; }
#map .iss-ring {
  fill: none; stroke: var(--cyan); stroke-width: 1; opacity: 0.6;
  vector-effect: non-scaling-stroke;
  transform-box: fill-box; transform-origin: center;
  animation: ringpulse 2.6s ease-out infinite;
}
@keyframes ringpulse {
  0% { transform: scale(0.5); opacity: 0.85; }
  70% { transform: scale(1.9); opacity: 0; }
  100% { transform: scale(1.9); opacity: 0; }
}
#map .iss-dot { fill: #d8fbff; filter: drop-shadow(0 0 4px var(--cyan)); }
#map .terminator {
  fill: rgba(2, 4, 14, 0.62);
  stroke: rgba(120, 200, 255, 0.34);
  stroke-width: 0.6;
  stroke-dasharray: 2 2;
  vector-effect: non-scaling-stroke;
}
#map .sun-dot { fill: var(--amber); filter: drop-shadow(0 0 5px rgba(255, 179, 71, 0.9)); }

/* stacked side column so panels share one height */
.col { display: grid; grid-template-rows: auto minmax(0, 1fr); gap: 12px; min-width: 0; }
.qwrap { margin-top: 12px; }

.map-legend {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 10px;
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.14em;
  color: var(--muted);
  text-transform: uppercase;
}
.map-legend span { display: flex; align-items: center; gap: 6px; }
.sw { width: 14px; height: 2px; display: inline-block; }

/* ---------- moon ---------- */
.moonwrap { display: flex; gap: 16px; align-items: center; }
.moon-disc {
  width: 92px; height: 92px;
  border-radius: 50%;
  flex: 0 0 auto;
  box-shadow: 0 0 34px rgba(200, 225, 255, 0.16), inset 0 0 22px rgba(0, 0, 0, 0.55);
  position: relative;
}
.moon-facts { display: grid; gap: 7px; min-width: 0; }
.fact { display: flex; justify-content: space-between; gap: 14px; font-size: 12px; }
.fact dt { color: var(--muted); font-family: var(--mono); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; }
.fact dd { margin: 0; font-family: var(--mono); color: var(--text); font-variant-numeric: tabular-nums; }

/* ---------- planet list ---------- */
.plist { display: grid; gap: 2px; }
.prow {
  display: grid;
  grid-template-columns: 62px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 7px 5px;
  border-bottom: 1px solid rgba(56, 225, 255, 0.07);
  font-size: 12px;
}
.prow:last-child { border-bottom: 0; }
.prow__n { font-family: var(--mono); font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--text-2); }
.prow__bar { height: 3px; background: rgba(255,255,255,0.06); position: relative; overflow: hidden; }
.prow__bar i { position: absolute; left: 0; top: 0; bottom: 0; background: linear-gradient(90deg, var(--cyan-dim), var(--cyan)); }
.prow__v { font-family: var(--mono); font-size: 10.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.prow--pass { grid-template-columns: 78px 92px 1fr 74px 92px; }
@media (max-width: 720px) {
  .prow--pass { grid-template-columns: 64px 1fr 66px; }
  .prow--pass .prow__v:nth-child(2), .prow--pass .prow__v:nth-child(5) { display: none; }
}

/* ---------- tables / rows ---------- */
.rows { display: grid; }
.row {
  display: grid;
  grid-template-columns: 96px 1fr auto 22px;
  gap: 14px;
  align-items: center;
  padding: 11px 8px;
  border-bottom: 1px solid rgba(56, 225, 255, 0.08);
  text-decoration: none;
  color: inherit;
  transition: background 0.14s, padding 0.14s;
}
.row:hover { background: rgba(56, 225, 255, 0.05); padding-left: 14px; }
.row__cd {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--cyan-2);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}
.row__main { min-width: 0; }
.row__name {
  display: block;              /* inline spans ignore overflow/text-overflow */
  font-size: 13.5px;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.row__sub {
  display: block;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--muted);
  letter-spacing: 0.06em;
  margin-top: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.row__when { font-family: var(--mono); font-size: 10.5px; color: var(--muted); text-align: right; white-space: nowrap; }
.row__go { color: var(--cyan-dim); font-family: var(--mono); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--cyan);
  border: 1px solid var(--line-2);
  background: rgba(56, 225, 255, 0.06);
  padding: 9px 14px;
  border-radius: var(--rad);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.12s;
}
.btn:hover { background: rgba(56, 225, 255, 0.13); border-color: var(--line-3); }
.btn:active { transform: translateY(1px); }
.btn--sm { padding: 6px 10px; font-size: 10px; }

/* ---------- sections ---------- */
.section { margin-top: 34px; }
.section__hd {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}
.section__t {
  font-size: 19px;
  font-weight: 550;
  margin: 0;
  letter-spacing: -0.01em;
}
.section__t small {
  display: block;
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.3em;
  color: var(--cyan-dim);
  text-transform: uppercase;
  margin-top: 6px;
  font-weight: 400;
}
.section__more { margin-left: auto; }

.obsrow {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 13px;
  padding-top: 11px;
  border-top: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
.obsrow .btn { margin-left: auto; }

/* reduced-scale locator map used on pad pages (background image, so the
   117 KB coastline is fetched once and cached across every pad page) */
.locator {
  position: relative;
  aspect-ratio: 2 / 1;
  background-color: #0a1b2e;
  background-size: 100% 100%;
  background-repeat: no-repeat;
  border: 1px solid var(--line);
}
.locator .pin {
  position: absolute;
  width: 9px; height: 9px;
  margin: -4.5px 0 0 -4.5px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 12px var(--cyan), 0 0 26px rgba(56, 225, 255, 0.5);
}
.locator .pin::after {
  content: "";
  position: absolute;
  inset: -7px;
  border: 1px solid rgba(56, 225, 255, 0.45);
  border-radius: 50%;
}

/* ---------- night timeline ---------- */
.night { position: relative; padding: 4px 0 0; }
.night__band { position: absolute; left: 0; right: 0; top: 0; bottom: 24px; pointer-events: none; }
.night__band i {
  position: absolute; top: 0; bottom: 0;
  background: rgba(56, 225, 255, 0.055);
  border-left: 1px solid rgba(56, 225, 255, 0.22);
  border-right: 1px solid rgba(56, 225, 255, 0.22);
}
.nrow {
  position: relative;
  display: grid;
  grid-template-columns: 72px 1fr 88px;
  gap: 12px;
  align-items: center;
  padding: 5px 0;
  z-index: 1;
}
.nrow__n {
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--text-2);
}
.nrow__track {
  position: relative; height: 9px;
  background: rgba(255, 255, 255, 0.035);
  border-left: 1px solid rgba(56, 225, 255, 0.1);
  border-right: 1px solid rgba(56, 225, 255, 0.1);
}
.nrow__bar {
  position: absolute; top: 0; bottom: 0;
  background: linear-gradient(90deg, rgba(56, 225, 255, 0.22), rgba(56, 225, 255, 0.72));
}
.nrow__bar--moon { background: linear-gradient(90deg, rgba(255, 179, 71, 0.25), rgba(255, 179, 71, 0.8)); }
.nrow__peak {
  position: absolute; top: -3px; width: 2px; height: 15px;
  background: #eaf7ff; box-shadow: 0 0 9px rgba(56, 225, 255, 0.9);
  transform: translateX(-1px);
}
.nrow__v {
  font-family: var(--mono); font-size: 10.5px; color: var(--text-2);
  text-align: right; font-variant-numeric: tabular-nums;
}
.night__axis { position: relative; height: 20px; margin: 6px 100px 0 84px; }
.night__axis span {
  position: absolute; transform: translateX(-50%);
  font-family: var(--mono); font-size: 9px; letter-spacing: 0.1em; color: var(--muted-2);
}

/* ---------- best targets ---------- */
.tlist { display: grid; gap: 2px; }
.trow {
  display: grid;
  grid-template-columns: 24px 1.15fr 0.95fr 0.7fr 1.25fr;
  gap: 10px;
  align-items: baseline;
  padding: 9px 4px;
  border-bottom: 1px solid rgba(56, 225, 255, 0.07);
}
.trow__i { font-family: var(--mono); font-size: 10px; color: var(--cyan-dim); }
.trow__n { font-size: 13.5px; color: var(--text); }
.trow__note {
  display: block; font-family: var(--mono); font-style: normal;
  font-size: 9px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--amber); margin-top: 2px;
}
.trow__t, .trow__a, .trow__w {
  font-family: var(--mono); font-size: 10.5px; color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.trow__a { color: var(--cyan-2); }
@media (max-width: 720px) {
  /* five grid children would wrap into a second row and the row would read as
     two unrelated lines; keep the two that matter (name, peak) */
  .trow { grid-template-columns: 20px 1fr auto; }
  .trow__t, .trow__w { display: none; }
  .night__axis { margin-right: 90px; }
}

/* long-form reading measure — the computed pages use .prose, articles need more room */
.article {
  max-width: 74ch;
  font-size: 16.5px;
  line-height: 1.78;
  color: var(--text-2);
}
.article h2 {
  font-size: 21px; line-height: 1.3; font-weight: 600;
  color: var(--text); margin: 40px 0 14px;
  padding-top: 18px; border-top: 1px solid var(--line);
}
.article h2:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.article p { margin: 0 0 17px; }
.article ul { margin: 0 0 20px; padding-left: 22px; }
.article li { margin-bottom: 8px; }
.article strong { color: var(--text); font-weight: 600; }
.article em { color: var(--text); font-style: italic; }
.article a { color: var(--cyan); text-decoration: none; border-bottom: 1px solid var(--line-2); }
.article a:hover { border-bottom-color: var(--cyan); }
.article code {
  font-family: var(--mono); font-size: 13.5px;
  background: rgba(56, 225, 255, 0.08);
  border: 1px solid var(--line);
  padding: 1px 6px; border-radius: 2px; color: var(--cyan-2);
}

/* ---------- answers ---------- */
.answers { display: grid; gap: 2px; max-width: 88ch; }
.qa {
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}
.qa:last-child { border-bottom: 0; }
.qa__q {
  margin: 0 0 8px;
  font-size: 17px;
  font-weight: 550;
  line-height: 1.35;
  color: var(--text);
}
.qa__a {
  margin: 0 0 8px;
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-2);
}
.qa__l {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cyan-dim);
  text-decoration: none;
}
.qa__l:hover { color: var(--cyan); }

/* ---------- city cards ---------- */
.citygrid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 8px;
}
.citycard {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: var(--rad);
  text-decoration: none;
  transition: border-color 0.15s, background 0.15s, transform 0.12s;
}
.citycard:hover {
  border-color: var(--line-3);
  background: rgba(56, 225, 255, 0.06);
  transform: translateY(-1px);
}
.citycard__n { font-size: 14.5px; color: var(--text); }
.citycard__s {
  font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--muted);
}
.citycard__p { font-family: var(--mono); font-size: 10.5px; color: var(--cyan-dim); }

/* ---------- prose ---------- */
.prose { max-width: 74ch; color: var(--text-2); font-size: 14.5px; line-height: 1.72; }
.prose h2 { color: var(--text); font-size: 18px; margin: 30px 0 10px; font-weight: 550; }
.prose h3 { color: var(--text); font-size: 15px; margin: 22px 0 8px; }
.prose a { color: var(--cyan); text-decoration: none; border-bottom: 1px solid var(--line-2); }
.prose a:hover { border-bottom-color: var(--cyan); }
.prose code {
  font-family: var(--mono);
  font-size: 12px;
  background: rgba(56, 225, 255, 0.08);
  border: 1px solid var(--line);
  padding: 1px 5px;
  border-radius: 2px;
  color: var(--cyan-2);
}

/* ---------- cta / footer ---------- */
.cta {
  border: 1px solid var(--line-2);
  background: linear-gradient(120deg, rgba(56, 225, 255, 0.09), transparent 55%), var(--panel);
  padding: 26px;
  margin-top: 40px;
  border-radius: var(--rad);
  display: flex;
  gap: 24px;
  align-items: center;
  flex-wrap: wrap;
}
.cta h2 { margin: 0 0 6px; font-size: 20px; font-weight: 550; }
.cta p { margin: 0; color: var(--text-2); font-size: 13.5px; }
.cta .btn { margin-left: auto; }

footer {
  margin-top: 46px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  align-items: center;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--muted-2);
  text-transform: uppercase;
}
footer a { color: var(--muted); text-decoration: none; }
footer a:hover { color: var(--cyan); }

/* ---------- misc ---------- */
.nowrap { white-space: nowrap; }
.mono { font-family: var(--mono); }
.dim { color: var(--muted); }
.err { color: var(--red); }
.badge {
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 3px 6px;
  border: 1px solid var(--line-2);
  color: var(--cyan-2);
  border-radius: 2px;
}
.badge--ok { color: var(--green); border-color: rgba(70,245,160,0.4); }
.badge--warn { color: var(--amber); border-color: var(--amber-dim); }

.skeleton { color: var(--muted-2); }

/* the per-city paragraph: same visual language as the console's TONIGHT line,
   because it is the same kind of claim */
.citylead {
  margin: 16px 0 0;
  padding: 14px 18px;
  border-left: 2px solid var(--cyan);
  background: linear-gradient(90deg, rgba(56, 225, 255, 0.07), transparent 70%);
  font-size: 15px;
  line-height: 1.66;
  color: var(--text);
  max-width: 88ch;
}

@media (max-width: 980px) {
  .grid2, .grid2.rev { grid-template-columns: 1fr; }
  .metrics { grid-template-columns: repeat(2, 1fr); }
  /* at ~768 px the nav wrapped onto a second line with "ABOUT" stranded alone;
     a single scrollable row reads better than a two-line bar */
  .nav {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    /* without a fade the cut-off item looks broken rather than scrollable */
    mask-image: linear-gradient(to right, #000 calc(100% - 26px), transparent);
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 26px), transparent);
  }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { flex: 0 0 auto; }
  /* the CJK brand name wrapped to one character per line at ~768 px */
  .brand { white-space: nowrap; flex: 0 0 auto; }
}
@media (max-width: 620px) {
  :root { --gut: 14px; }
  /* Hiding the nav left mobile visitors with no way in except the footer.
     Instead: let the bar wrap and make the nav a scrollable strip. */
  .topbar { flex-wrap: wrap; gap: 10px; padding-bottom: 6px; }
  .nav {
    display: flex;
    width: 100%;
    order: 3;
    margin-left: 0;
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    gap: 6px;
    padding-bottom: 2px;
  }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { flex: 0 0 auto; }
  .row { grid-template-columns: 78px 1fr 16px; }
  .row__when { display: none; }
  .metrics { grid-template-columns: repeat(2, 1fr); }
  .hero { padding-top: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
  #stars { display: none; }
}

/* shown only when the page is served from the storage bucket (see bridge.js) */
.prelaunch {
  max-width: 78ch;
  margin: 40px auto 0;
  padding: 12px 16px;
  border-left: 2px solid var(--amber, #ffb648);
  background: rgba(255, 182, 72, 0.06);
  color: var(--text-2);
  font-size: 12.5px;
  line-height: 1.6;
}


/* language switch: a two-pill segmented control, not a subtle text link.
   The active language is filled; the other is outlined and hoverable. */
.langswitch {
  display: inline-flex;
  align-items: stretch;
  margin-left: 10px;
  border: 1px solid rgba(56, 225, 255, 0.45);
  border-radius: 4px;
  overflow: hidden;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.langswitch a {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  color: var(--cyan);
  text-decoration: none;
  background: transparent;
  transition: background 0.15s ease, color 0.15s ease;
}
.langswitch a + a { border-left: 1px solid rgba(56, 225, 255, 0.35); }
.langswitch a:hover { background: rgba(56, 225, 255, 0.16); color: #eafcff; }
.langswitch a.is-on {
  background: rgba(56, 225, 255, 0.9);
  color: #04212a;
  font-weight: 700;
}
@media (max-width: 720px) {
  .langswitch { margin-left: 6px; }
  .langswitch a { padding: 5px 9px; font-size: 11px; }
}
