@font-face {
  font-family: "Signal Song";
  src: url("signal-titles.ttf") format("truetype");
  font-style: normal;
  font-weight: 600;
  font-display: swap;
}
:root {
  --bg: #0b0d0e;
  --ink: #f3efe6;
  --muted: #a9a8a4;
  --display: "Signal Song", "Noto Serif SC", "Songti SC", "SimSun", serif;
  --edge: max(6vw, calc((100vw - 1570px) / 2));
  --warm: #edbd83;
}
body { background: var(--bg); }
.nav, footer { display: flex; justify-content: space-between; align-items: center; }
.nav {
  position: fixed;
  z-index: 6;
  top: 0; left: 0; right: 0;
  padding: 16px var(--edge);
  background: linear-gradient(to bottom, #070a0c8a, transparent);
}
html.scrolled .nav { background: #0b0d0ee8; backdrop-filter: blur(16px); }
.brand { display: inline-flex; align-items: center; gap: 11px; color: #f9f5ec; font-size: 19px; font-weight: 700; letter-spacing: .06em; }
.orbit-logo { position: relative; display: inline-block; height: 32px; width: 31px; transform: rotate(-26deg); }
.orbit-logo::before {
  content: ''; position: absolute; top: 11px; left: 1px; width: 28px; height: 13px;
  border: 2px solid #e9e6de; border-top-width: 1px; border-radius: 50% 50% 56% 56% / 22% 22% 95% 95%;
}
.orbit-logo::after {
  content: ''; position: absolute; left: 14px; top: 1px; width: 1px; height: 11px;
  background: #f0dfc4; box-shadow: 0 21px 0 #f0dfc4;
}
.nav nav { display: flex; align-items: center; gap: clamp(17px, 2.7vw, 43px); }
.nav nav a, footer > a:last-child { color: #deddd7; font-size: 14px; }
.nav nav a { display: inline-flex; align-items: center; min-height: 42px; }
.nav nav a:hover, footer a:hover { color: white; text-decoration: underline; text-underline-offset: 6px; }
.nav button { display: flex; align-items: center; gap: 8px; border: 0; padding: 0; min-height: 44px; font-size: 14px; background: transparent; color: #e6e5df; }
.motion-bars { display: flex; align-items: center; height: 14px; gap: 2px; }
.motion-bars i { width: 2px; height: 6px; background: currentColor; }
.motion-bars i:nth-child(2) { height: 13px; }
.motion-bars i:nth-child(3) { height: 9px; }
#motion-switch[aria-pressed=false] i { height: 2px; }

.hero {
  position: relative; isolation: isolate; overflow: hidden;
  height: max(680px, 100svh); max-height: 1150px;
  background: #070b0e; display: flex; align-items: center;
}
.hero-image {
  position: absolute; z-index: -2; inset: 0;
  background: linear-gradient(0deg, #090b0df5 0%, #070a0c30 20%, transparent 50%),
    linear-gradient(90deg, #06090a5c, transparent 56%), url("observatory.webp") 68% 62% / cover no-repeat;
}
.field-box { position: absolute; width: 42%; height: 52%; left: 32%; top: 1%; }
#signal-field { display: block; width: 100%; height: 100%; pointer-events: none; }
.pulse-target { position: absolute; inset: 8% 3%; border-radius: 50%; border: 0; background: transparent; cursor: grab; touch-action: pan-y; }
.pulse-label { position: absolute; left: 50%; bottom: 8%; translate: -50% 0; white-space: nowrap; pointer-events: none; color: #e9eced; text-shadow: 0 1px 7px #000; opacity: 0; font-size: 13px; transition: opacity .18s; }
.pulse-target:focus-visible .pulse-label, .pulse-target:hover .pulse-label { opacity: 1; }
html[data-motion=still] .pulse-target { visibility: hidden; }
.hero-content { pointer-events: none; position: relative; width: fit-content; margin: 4vh 0 8vh var(--edge); }
#station-title {
  margin: 0; font-family: var(--display); font-weight: 600; color: #f2efe7;
  font-size: clamp(64px, 6.7vw, 118px); line-height: 1.15; letter-spacing: -.055em;
  text-shadow: 0 2px 30px #04060746;
}
#station-title span { display: block; }
.letter-credit { margin: 24px 0 0; color: #d2d1c9; font-size: clamp(15px, 1.15vw, 18px); letter-spacing: .03em; }
.hero-actions { margin-top: 33px; }
.hero-actions a { pointer-events: auto; }
.primary {
  display: inline-flex; min-height: 48px; align-items: center; gap: 11px; border-radius: 4px;
  padding: 0 20px; background: #efebdf; color: #171a18; font-size: 15px; font-weight: 650;
}
.primary:hover { background: #fff9e8; }
.receiver-icon { width: 0; height: 0; border-top: 5px solid transparent; border-bottom: 5px solid transparent; border-left: 8px solid #31342e; }
.tuner {
  position: absolute; left: var(--edge); right: var(--edge); bottom: 3.8%;
  display: flex; align-items: center; gap: 25px; border-top: 1px solid #dae0d842; padding-top: 14px;
}
.tuner-caption { font-size: 14px; color: #e8e4da; }
.channels { display: flex; align-items: stretch; gap: clamp(16px, 2.7vw, 42px); }
.channels button {
  position: relative; background: transparent; border: 0; border-bottom: 1px solid transparent;
  min-height: 44px; color: #b7b9b6; padding: 6px 0; font: 15px var(--mono); font-variant-numeric: tabular-nums;
}
.channels small { color: #aaaead; font-size: 12px; }
.channels button::before { content: ''; position: absolute; top: -18px; left: 0; height: 7px; width: 1px; background: #a9b0ac; }
.channels button[aria-pressed=true] { color: #ffdbac; }
.channels button[aria-pressed=true]::before { height: 13px; width: 3px; background: var(--warm); }
.transit { height: clamp(90px, 15vw, 250px); overflow: hidden; position: relative; }
.beam-stage, #beam-field { display: block; position: absolute; inset: 0; width: 100%; height: 100%; }
footer { padding: 24px var(--edge); background: #111212; border-top: 1px solid #d0ccc02e; }

@media(max-width: 760px) {
  :root { --edge: 6vw; }
  .nav { padding: 7px var(--edge); }
  .brand { font-size: 16px; gap: 8px; }
  .nav nav { gap: 14px; }
  .nav nav a, .nav button { font-size: 13px; }
  .hero { height: max(690px, 100svh); max-height: 1000px; align-items: flex-end; }
  .hero-image {
    inset: 0 0 25%;
    background: linear-gradient(0deg, #070b0e 0%, #070b0e22 26%, transparent 55%),
      url("observatory.webp") 72% 40% / cover no-repeat;
  }
  .field-box { top: 4%; height: 31%; left: 0; width: 70%; }
  .hero-content { margin: 0 var(--edge) 120px; }
  #station-title { font-size: clamp(50px, 9.8vw, 73px); line-height: 1.14; }
  .letter-credit { font-size: 14px; margin-top: 15px; }
  .hero-actions { margin-top: 18px; }
  .tuner { bottom: 12px; gap: 14px; padding-top: 7px; }
  .channels { flex: 1; justify-content: space-between; gap: 5px; }
  .channels button { font-size: 13px; }
  .channels button::before { top: -10px; }
  .channels small { font-size: 11px; }
  .pulse-label { bottom: 3%; font-size: 12px; }
}
@media(prefers-reduced-motion: reduce) { .pulse-label { transition: none; } }
