@font-face {
  font-family: Orbitron;
  src: url("/fonts/Orbitron.ttf") format("truetype");
  font-weight: 400 900;
  font-display: swap;
}
:root {
  color-scheme: dark;
  --pink: #ff78d6;
  --cyan: #69ede7;
  --muted: #a29ab8;
  --ink: #0b071b;
  font:
    14px/1.4 system-ui,
    sans-serif;
  background: var(--ink);
  color: #f3e7ff;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
a {
  -webkit-tap-highlight-color: transparent;
}
button,
input {
  font: inherit;
  color: inherit;
}
button,
a,
input {
  touch-action: manipulation;
}
button,
a {
  cursor: pointer;
}
a {
  color: inherit;
  text-decoration: none;
}
button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 5px;
}
button {
  border: 0;
}
button:disabled {
  opacity: 0.5;
  cursor: wait;
}
[hidden] {
  display: none !important;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}
#screens {
  height: 100dvh;
  overflow-y: auto;
  scroll-snap-type: y mandatory;
  scroll-behavior: smooth;
}
.screen {
  height: 100dvh;
  min-height: 560px;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  padding: 24px max(24px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom))
    max(24px, env(safe-area-inset-left));
  position: relative;
  isolation: isolate;
  overflow: hidden;
}
.radio-screen {
  display: grid;
  grid-template-rows: auto minmax(140px, 1fr) auto;
  background: radial-gradient(ellipse at 50% 38%, #1a1034 0%, #0b071b 65%);
}
.radio-screen::after {
  content: "";
  position: absolute;
  z-index: -1;
  bottom: -25%;
  left: -50%;
  width: 200%;
  height: 45%;
  background:
    linear-gradient(#ca64ff12 1px, transparent 1px),
    linear-gradient(90deg, #ca64ff12 1px, transparent 1px);
  background-size: 44px 32px;
  transform: perspective(150px) rotateX(45deg);
  mask-image: linear-gradient(transparent, #000);
}
.masthead {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
  z-index: 2;
}
.masthead > p {
  font:
    500 11px Orbitron,
    sans-serif;
  letter-spacing: 0.65em;
  margin: 0 0 1px;
  padding-left: 0.65em;
  color: #d3a3e5;
}
.masthead h1 {
  font:
    900 clamp(43px, 12.3vw, 92px) / 1.12 Orbitron,
    sans-serif;
  letter-spacing: 0.04em;
  margin: 0;
  transform: skew(-7deg);
  background: linear-gradient(
    #fff2ff 9%,
    #d9b5f5 36%,
    #8a8dda 48%,
    #290d4b 50%,
    #fd8cdd 53%,
    #ba4baa 70%,
    #ffc3ed
  );
  background-clip: text;
  color: transparent;
  filter: drop-shadow(2px 3px 0 #6e285a) drop-shadow(0 0 18px #ef7add30);
}
.frequency {
  display: flex;
  align-items: center;
  gap: 8px;
  font:
    9px ui-monospace,
    monospace;
  color: #ac9cc1;
  letter-spacing: 0.08em;
  text-align: left;
  margin-top: 20px;
  white-space: nowrap;
}
.frequency-line {
  height: 1px;
  background: #9884b638;
  flex: 1;
}
.signal-dot {
  width: 5px;
  height: 5px;
  background: #706a7e;
  border-radius: 50%;
}
body[data-signal="sound"] .signal-dot {
  background: var(--cyan);
  box-shadow: 0 0 10px var(--cyan);
}
.vortex-stage {
  position: relative;
  width: 100%;
  max-width: 650px;
  min-height: 0;
  margin: 0 auto;
  display: grid;
  place-items: center;
}
#vortex {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.vortex-fallback {
  position: absolute;
  width: min(76vw, 330px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: repeating-conic-gradient(from 20deg, #716687 0deg, transparent 25deg, #465c6b 60deg);
  filter: blur(8px);
  mask-image: radial-gradient(transparent 13%, black 25%, black 50%, transparent 72%);
  animation: turn 6000s linear infinite;
}
body[data-signal="sound"] .vortex-fallback {
  background: repeating-conic-gradient(#ff56cc 0deg, transparent 25deg, #60eadd 60deg);
}
.vortex-stage.webgl .vortex-fallback {
  display: none;
}
.orbit-caption {
  position: absolute;
  bottom: 6px;
  letter-spacing: 0.23em;
  font:
    8px ui-monospace,
    monospace;
  color: #b293c1;
  opacity: 0.6;
}
#play {
  z-index: 1;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 35% 25%, #2e203d, #100b1d 70%);
  border: 1px solid #b8a0ca70;
  box-shadow:
    0 0 0 8px #140b2680,
    0 0 35px #b94ec430,
    inset 0 1px 15px #ca9df215;
  transition:
    transform 0.2s,
    border-color 0.5s;
}
#play:active {
  transform: scale(0.94);
}
body[data-signal="sound"] #play {
  border-color: #a8ded5aa;
  box-shadow:
    0 0 0 8px #1b0b2680,
    0 0 40px #51d8cd35;
}
.play-icon {
  display: block;
  width: 0;
  height: 0;
  border-top: 13px solid transparent;
  border-bottom: 13px solid transparent;
  border-left: 20px solid #fce8ff;
  margin-left: 6px;
  filter: drop-shadow(0 0 6px #ff7ddd80);
}
body[data-requested="true"] .play-icon {
  width: 20px;
  height: 25px;
  border: 0;
  border-left: 6px solid #fce8ff;
  border-right: 6px solid #fce8ff;
  margin-left: 0;
}
.track {
  text-align: center;
  margin: 12px 0 16px;
  z-index: 1;
}
.track > p:first-child {
  font:
    9px Orbitron,
    sans-serif;
  color: var(--cyan);
  letter-spacing: 0.17em;
  text-transform: uppercase;
  margin: 0 0 6px;
}
.track h2 {
  font-size: 17px;
  font-weight: 500;
  letter-spacing: 0.02em;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.track #player-state {
  font-size: 11px;
  color: var(--muted);
  margin: 6px 0 0;
}
.player-footer {
  width: 100%;
  max-width: 520px;
  margin: auto;
  z-index: 1;
}
#announcement {
  padding: 10px 14px;
  background: #d181ff0a;
  border-left: 2px solid #c57abd;
  margin-bottom: 12px;
}
#announcement > span {
  font:
    8px Orbitron,
    sans-serif;
  color: #d8a7d6;
  letter-spacing: 0.15em;
}
#message {
  font-size: 12px;
  line-height: 1.5;
  margin: 4px 0 0;
  max-height: 72px;
  overflow: auto;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.volume-row {
  display: flex;
  align-items: center;
  gap: 14px;
  color: #bdaccb;
  font:
    10px ui-monospace,
    monospace;
}
.volume-row input {
  width: 100%;
  accent-color: #d9a6d8;
  height: 32px;
}
.room-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid #ad86c433;
  margin-top: 10px;
  padding: 15px 0 0;
  letter-spacing: 0.18em;
  font:
    10px Orbitron,
    sans-serif;
  color: #efc0ea;
}
.room-link span {
  font-size: 24px;
  color: var(--cyan);
  line-height: 1;
}
.tiny {
  font-size: 9px;
  color: #9888ac;
  margin: 5px 0 0;
}
.chat-screen {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto auto;
  gap: 16px;
  background: radial-gradient(ellipse at 90% 20%, #1a1027, #0b071b 65%);
  max-width: 900px;
  margin: auto;
}
.room-header {
  display: flex;
  align-items: center;
  gap: 16px;
}
.room-header > a {
  display: grid;
  place-items: center;
  border: 1px solid #b18bc442;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  font-size: 23px;
  color: var(--cyan);
}
.room-header p {
  font:
    8px Orbitron,
    sans-serif;
  letter-spacing: 0.17em;
  color: var(--muted);
  margin: 0 0 5px;
}
.room-header h2 {
  font:
    700 clamp(18px, 5vw, 28px) Orbitron,
    sans-serif;
  margin: 0;
  letter-spacing: 0.02em;
}
.room-header h2 span {
  color: var(--pink);
}
.room-live {
  margin-left: auto;
  font:
    8px ui-monospace,
    monospace;
  color: var(--cyan);
  border: 1px solid #66d7bd33;
  border-radius: 3px;
  padding: 6px;
  white-space: nowrap;
}
.room-intro {
  font:
    11px/1.6 ui-monospace,
    monospace;
  color: var(--muted);
  margin: 0;
}
.chat-messages {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 12px;
  overflow: hidden;
  min-height: 0;
  border-top: 1px solid #95729c30;
  border-bottom: 1px solid #95729c30;
  padding: 14px 0;
  font:
    13px/1.5 ui-monospace,
    monospace;
}
.chat-entry {
  flex-shrink: 0;
  overflow-wrap: anywhere;
}
.chat-entry header {
  display: flex;
  gap: 10px;
  align-items: baseline;
}
.chat-entry b {
  font-weight: 500;
  color: var(--cyan);
}
.chat-entry time {
  font-size: 9px;
  color: #9683a9;
}
.chat-entry p {
  margin: 2px 0 0;
  color: #e3d6eb;
}
.chat-empty {
  color: #9785a9;
}
#chat-form label {
  display: block;
  font:
    9px ui-monospace,
    monospace;
  letter-spacing: 0.1em;
  color: var(--pink);
}
#chat-name {
  display: inline-block;
  width: 160px;
  margin-left: 15px;
  background: transparent;
  border: 0;
  border-bottom: 1px solid #88639266;
  padding: 7px;
  font:
    13px ui-monospace,
    monospace;
  border-radius: 0;
}
.chat-compose {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}
#chat-text {
  width: 100%;
  min-width: 0;
  border: 1px solid #af79ba50;
  border-radius: 5px;
  background: #1b1029;
  padding: 14px;
  font:
    14px ui-monospace,
    monospace;
}
#chat-send {
  width: 50px;
  flex-shrink: 0;
  background: #deacd7;
  color: #241130;
  border-radius: 5px;
  font-size: 24px;
}
#chat-status {
  font:
    10px ui-monospace,
    monospace;
  color: var(--muted);
  min-height: 1.4em;
  margin: 7px 0 0;
}
.room-footer {
  display: flex;
  justify-content: space-between;
  font:
    10px ui-monospace,
    monospace;
  color: #b793bf;
}
.update {
  position: fixed;
  bottom: 18px;
  left: 20px;
  right: 20px;
  padding: 15px;
  background: #352143;
  border: 1px solid #b796c1;
  z-index: 10;
}
.update button {
  padding: 8px;
  background: #d7add9;
  color: #241130;
  border-radius: 5px;
}
@keyframes turn {
  to {
    transform: rotate(360deg);
  }
}
@media (min-width: 700px) {
  .screen {
    padding-top: 35px;
    padding-bottom: 24px;
  }
  .radio-screen {
    grid-template-rows: auto minmax(180px, 1fr) auto;
  }
  .masthead > p {
    font-size: 13px;
  }
  .track h2 {
    font-size: 20px;
  }
  .vortex-stage {
    max-width: 720px;
  }
  .chat-screen {
    padding: 50px 60px;
  }
  .room-intro {
    font-size: 13px;
  }
  .chat-messages {
    font-size: 16px;
    gap: 18px;
  }
  .frequency {
    margin-top: 16px;
  }
}
@media (max-height: 680px) {
  .screen {
    padding-top: 16px;
    gap: 8px;
  }
  .masthead h1 {
    font-size: 46px;
  }
  .masthead > p {
    font-size: 9px;
  }
  .frequency {
    margin-top: 10px;
  }
  .track {
    margin: 4px 0 8px;
  }
  .track h2 {
    font-size: 14px;
  }
  #play {
    width: 74px;
    height: 74px;
  }
  .tiny {
    display: none;
  }
  .room-intro {
    font-size: 10px;
  }
  .chat-messages {
    gap: 8px;
  }
  .orbit-caption {
    display: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  #screens {
    scroll-behavior: auto;
  }
  * {
    animation: none !important;
    transition: none !important;
  }
}
.chat-screen {
  min-height: 0;
}

/* The signal has one visible indicator; programme text is screen-reader-only. */
.frequency {
  justify-content: center;
  margin-top: 20px;
}
#announcement {
  background: none;
  border: 0;
  text-align: center;
  padding: 8px 0;
  margin-bottom: 16px;
}
#message {
  font-size: 18px;
  line-height: 1.45;
  margin: 0;
  max-height: 100px;
}
.room-link {
  justify-content: center;
  border: 0;
  padding: 10px;
  min-height: 44px;
  margin-top: 6px;
}
