:root {
  --paper: #fff0cc;
  --paper-deep: #ffc97b;
  --ink: #20132d;
  --muted: #67506f;
  --wood: #eb6c48;
  --wood-deep: #8a2d16;
  --vinyl: #111112;
  --vinyl-sheen: rgba(255, 255, 255, 0.08);
  --copper: #ff8b2f;
  --copper-bright: #ffe065;
  --screen: #0d1422;
  --screen-line: rgba(111, 181, 255, 0.24);
  --electric: #2ac4ff;
  --electric-deep: #1171d4;
  --berry: #ff5d99;
  --mist: rgba(255, 248, 236, 0.68);
  --shadow-lg: 0 34px 70px rgba(34, 19, 45, 0.22);
  --shadow-sm: 0 18px 38px rgba(34, 19, 45, 0.14);
  --radius-xl: 36px;
  --radius-lg: 28px;
  --radius-md: 22px;
  --radius-sm: 16px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: "Avenir Next", "Trebuchet MS", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(255, 108, 79, 0.48), transparent 24%),
    radial-gradient(circle at 82% 18%, rgba(42, 196, 255, 0.28), transparent 22%),
    radial-gradient(circle at 50% 115%, rgba(255, 93, 153, 0.2), transparent 28%),
    linear-gradient(180deg, #ffecc6 0%, #ffd193 46%, #ffb06e 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.3;
  background:
    linear-gradient(90deg, rgba(35, 23, 15, 0.05) 0 1px, transparent 1px 120px),
    linear-gradient(180deg, rgba(35, 23, 15, 0.04) 0 1px, transparent 1px 120px);
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

img {
  display: block;
  max-width: 100%;
}

[hidden] {
  display: none !important;
}

.room-shell {
  width: min(1400px, calc(100% - 24px));
  margin: 16px auto 28px;
  padding: 22px;
  border-radius: 42px;
  background:
    radial-gradient(circle at top right, rgba(42, 196, 255, 0.16), transparent 24%),
    radial-gradient(circle at 12% 12%, rgba(235, 108, 72, 0.16), transparent 22%),
    linear-gradient(180deg, rgba(255, 247, 230, 0.95), rgba(255, 230, 184, 0.92));
  border: 1px solid rgba(28, 17, 48, 0.12);
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.room-shell::after {
  content: "";
  position: absolute;
  inset: 14px;
  border-radius: 30px;
  border: 1px solid rgba(77, 43, 28, 0.08);
  pointer-events: none;
}

.room-topbar,
.room-intro,
.stage-grid,
.playlist-panel {
  position: relative;
  z-index: 1;
}

.room-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.room-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.room-link:hover {
  color: var(--wood);
}

.room-logo {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  box-shadow: 0 10px 26px rgba(46, 24, 30, 0.2);
}

.room-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.topbar-pill,
.panel-chip,
.overlay-chip,
.channel-pill {
  display: inline-flex;
  align-items: center;
  padding: 9px 14px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(235, 108, 72, 0.18), rgba(42, 196, 255, 0.14));
  border: 1px solid rgba(28, 17, 48, 0.12);
  color: var(--ink);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.room-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  gap: 18px;
  align-items: end;
  margin-bottom: 18px;
}

.eyebrow,
.panel-kicker {
  margin: 0 0 10px;
  color: var(--wood);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.room-intro h1,
.panel h2,
.panel h3 {
  margin: 0;
  font-family: "Baskerville", "Times New Roman", serif;
  letter-spacing: 0.02em;
}

.room-intro h1 {
  font-size: clamp(2.9rem, 5vw, 5.4rem);
  line-height: 0.94;
}

.intro-copy,
.playlist-copy,
.screen-note,
.track-meta,
.track-file,
.track-tagline {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.stage-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
  margin-bottom: 18px;
}

.panel {
  padding: 22px;
  border-radius: var(--radius-xl);
  border: 1px solid rgba(28, 17, 48, 0.12);
  background:
    linear-gradient(180deg, rgba(255, 248, 236, 0.96), rgba(255, 232, 194, 0.9)),
    linear-gradient(135deg, rgba(255, 255, 255, 0.34), transparent 34%);
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}

.screen-panel {
  background:
    radial-gradient(circle at top right, rgba(42, 196, 255, 0.24), transparent 28%),
    radial-gradient(circle at 16% 18%, rgba(255, 93, 153, 0.14), transparent 22%),
    linear-gradient(180deg, rgba(236, 246, 255, 0.97), rgba(209, 228, 255, 0.9));
}

.deck-panel {
  background:
    radial-gradient(circle at top left, rgba(235, 108, 72, 0.22), transparent 28%),
    radial-gradient(circle at 82% 18%, rgba(255, 225, 100, 0.2), transparent 24%),
    linear-gradient(180deg, rgba(255, 242, 221, 0.98), rgba(255, 211, 153, 0.9));
}

.playlist-panel {
  background:
    radial-gradient(circle at 10% 16%, rgba(235, 108, 72, 0.14), transparent 22%),
    radial-gradient(circle at 90% 20%, rgba(42, 196, 255, 0.18), transparent 24%),
    linear-gradient(180deg, rgba(255, 244, 223, 0.98), rgba(255, 226, 180, 0.92));
}

.panel::before {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: calc(var(--radius-xl) - 10px);
  border: 1px solid rgba(28, 17, 48, 0.08);
  pointer-events: none;
}

.panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.panel-head h2 {
  font-size: clamp(1.55rem, 3vw, 2.25rem);
}

.panel-head--playlist {
  align-items: end;
}

.turntable-shell {
  display: grid;
  grid-template-columns: minmax(300px, 420px) minmax(0, 1fr);
  gap: 24px;
  align-items: center;
}

.turntable {
  position: relative;
  min-height: 430px;
  padding: 22px;
  border-radius: 32px;
  background:
    radial-gradient(circle at 28% 18%, rgba(255, 225, 100, 0.26), transparent 24%),
    radial-gradient(circle at 80% 18%, rgba(255, 93, 153, 0.18), transparent 22%),
    linear-gradient(145deg, #ff8846, #d5552a 55%, #702204);
  box-shadow:
    inset 0 2px 0 rgba(255, 255, 255, 0.16),
    inset 0 -12px 24px rgba(0, 0, 0, 0.28),
    0 18px 32px rgba(34, 19, 11, 0.32);
}

.platter-shadow {
  position: absolute;
  inset: 58px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0, 0, 0, 0.45), transparent 64%);
  filter: blur(18px);
}

.record {
  position: absolute;
  inset: 52px;
  margin: auto;
  width: min(100%, 320px);
  aspect-ratio: 1;
  border: 0;
  border-radius: 50%;
  background:
    radial-gradient(circle at 45% 35%, rgba(255, 255, 255, 0.1), transparent 18%),
    linear-gradient(145deg, #1f1c1d, #090909 65%);
  box-shadow:
    inset 0 0 0 4px rgba(255, 255, 255, 0.04),
    inset 0 0 110px rgba(255, 255, 255, 0.04),
    0 22px 28px rgba(0, 0, 0, 0.35);
  display: grid;
  place-items: center;
  isolation: isolate;
  transition: transform 200ms ease;
}

.record:hover {
  transform: scale(1.01);
}

.record-ring {
  position: absolute;
  inset: 0;
  margin: auto;
  border-radius: 50%;
  border: 1px solid var(--vinyl-sheen);
}

.record-ring--outer {
  width: calc(100% - 18px);
  height: calc(100% - 18px);
}

.record-ring--mid {
  width: calc(100% - 72px);
  height: calc(100% - 72px);
}

.record-ring--inner {
  width: calc(100% - 126px);
  height: calc(100% - 126px);
}

.record::after {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 50%;
  background: repeating-radial-gradient(circle, rgba(255, 255, 255, 0.025) 0 2px, transparent 2px 7px);
  opacity: 0.45;
}

.record-center {
  position: relative;
  z-index: 1;
  width: 108px;
  height: 108px;
  border-radius: 50%;
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.2), transparent 35%),
    linear-gradient(145deg, #ff5d91, #ff8d2e);
  display: grid;
  place-items: center;
  text-align: center;
  color: #fffaf0;
  box-shadow:
    inset 0 0 0 8px rgba(255, 255, 255, 0.14),
    0 8px 18px rgba(0, 0, 0, 0.28);
}

.record-center strong {
  display: block;
  font-size: 1.6rem;
  line-height: 1;
}

.record-center small {
  display: block;
  width: 74px;
  margin-top: 6px;
  font-size: 0.66rem;
  line-height: 1.25;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.tonearm {
  position: absolute;
  top: 56px;
  right: 72px;
  width: 180px;
  height: 14px;
  border-radius: 999px;
  background: linear-gradient(90deg, #d8d3cf, #8d8987 60%, #4d4b4b);
  transform-origin: 12px 50%;
  transform: rotate(-26deg);
  transition: transform 320ms ease;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22);
}

.tonearm::before {
  content: "";
  position: absolute;
  left: -18px;
  top: 50%;
  width: 34px;
  height: 34px;
  transform: translateY(-50%);
  border-radius: 50%;
  background: linear-gradient(145deg, #eee5dc, #a8a19a);
  box-shadow: inset 0 0 0 3px rgba(0, 0, 0, 0.05);
}

.tonearm-head {
  position: absolute;
  right: -10px;
  top: 50%;
  width: 22px;
  height: 28px;
  transform: translateY(-50%);
  border-radius: 8px;
  background: linear-gradient(180deg, #efe8dc, #9e968e);
}

body.is-playing .record {
  animation: record-spin 5.2s linear infinite;
}

body.is-playing .tonearm {
  transform: rotate(10deg);
}

.deck-copy {
  display: grid;
  gap: 14px;
}

.deck-copy h3,
.screen-overlay h3 {
  font-size: clamp(1.6rem, 3vw, 2.35rem);
}

.track-file {
  font-size: 0.92rem;
  word-break: break-word;
}

.control-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.control-row button,
.track-card,
.channel-pill {
  border: 1px solid rgba(28, 17, 48, 0.12);
  color: var(--ink);
}

.control-row button {
  min-height: 46px;
  padding: 0 16px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(235, 108, 72, 0.96), rgba(255, 141, 46, 0.92));
  color: #fff7ef;
  box-shadow: 0 8px 18px rgba(54, 31, 20, 0.12);
}

.control-row button:last-child {
  background: linear-gradient(135deg, rgba(42, 196, 255, 0.96), rgba(17, 113, 212, 0.92));
}

.control-row button:hover,
.track-card:hover,
.channel-pill:hover,
.room-link:focus-visible,
.record:focus-visible {
  outline: 2px solid rgba(198, 132, 71, 0.7);
  outline-offset: 2px;
}

.progress-wrap {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) 54px;
  gap: 12px;
  align-items: center;
  font-variant-numeric: tabular-nums;
}

.progress-wrap input {
  width: 100%;
  accent-color: var(--copper);
}

.screen-frame {
  position: relative;
  min-height: 520px;
  border-radius: 30px;
  overflow: hidden;
  background:
    radial-gradient(circle at top, rgba(24, 181, 255, 0.22), transparent 28%),
    radial-gradient(circle at 82% 18%, rgba(255, 79, 142, 0.16), transparent 22%),
    linear-gradient(180deg, #101d31, #07101b 65%);
  border: 1px solid var(--screen-line);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.screen-image,
.screen-bars,
.screen-video,
.fallback-visual {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.screen-video {
  object-fit: cover;
  background: #090d12;
}

.screen-image {
  object-fit: cover;
  opacity: 0.86;
}

.screen-bars {
  display: flex;
  align-items: end;
  gap: 10px;
  justify-content: center;
  padding-bottom: 126px;
  background: linear-gradient(180deg, transparent, rgba(7, 9, 13, 0.38));
}

.screen-bars span {
  width: 16px;
  border-radius: 999px 999px 0 0;
  background: linear-gradient(180deg, var(--copper-bright), var(--berry));
  animation: equalize 1.25s ease-in-out infinite alternate;
  opacity: 0.85;
}

.screen-bars span:nth-child(2n) {
  animation-duration: 0.95s;
}

.screen-bars span:nth-child(3n) {
  animation-duration: 1.5s;
}

.fallback-visual {
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 24px;
  background:
    radial-gradient(circle at center, rgba(240, 184, 112, 0.18), transparent 26%),
    linear-gradient(180deg, rgba(12, 16, 22, 0.96), rgba(6, 8, 12, 0.98));
}

.fallback-poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
}

.fallback-bars {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: end;
  gap: 10px;
  height: 170px;
}

.fallback-bars span {
  width: 18px;
  border-radius: 999px 999px 0 0;
  background: linear-gradient(180deg, var(--copper-bright), var(--berry));
  animation: equalize 1.2s ease-in-out infinite alternate;
}

.fallback-bars span:nth-child(2n) {
  animation-duration: 0.95s;
}

.fallback-bars span:nth-child(3n) {
  animation-duration: 1.5s;
}

.fallback-copy {
  position: absolute;
  inset: auto 24px 28px;
  max-width: 440px;
  color: #fffaf0;
  z-index: 1;
}

.fallback-copy h3 {
  margin: 0 0 10px;
  font-size: 1.8rem;
}

.screen-overlay {
  position: absolute;
  inset: auto 0 0 0;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  padding: 22px;
  background: linear-gradient(180deg, transparent, rgba(8, 11, 16, 0.8) 46%, rgba(8, 11, 16, 0.94));
  color: #fffaf0;
}

.overlay-stack {
  display: grid;
  gap: 10px;
  justify-items: end;
}

.overlay-chip {
  color: #fffaf0;
  background: linear-gradient(135deg, rgba(42, 196, 255, 0.24), rgba(255, 93, 153, 0.22));
  border-color: rgba(255, 255, 255, 0.18);
}

.screen-note {
  margin-top: 14px;
}

.channel-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
}

.channel-pill {
  padding: 12px 16px;
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 247, 230, 0.96), rgba(255, 220, 171, 0.9));
}

.channel-pill.is-active {
  border-color: rgba(235, 108, 72, 0.72);
  box-shadow: inset 0 0 0 1px rgba(42, 196, 255, 0.16);
}

.playlist-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.track-card {
  width: 100%;
  padding: 16px;
  border-radius: 24px;
  background:
    radial-gradient(circle at top right, rgba(42, 196, 255, 0.12), transparent 24%),
    linear-gradient(180deg, rgba(255, 247, 230, 0.96), rgba(255, 220, 171, 0.9)),
    linear-gradient(135deg, rgba(255, 255, 255, 0.26), transparent 44%);
  display: grid;
  gap: 10px;
  text-align: left;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    border-color 180ms ease;
}

.track-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 26px rgba(31, 17, 10, 0.12);
}

.track-card.is-active {
  border-color: rgba(235, 108, 72, 0.72);
  box-shadow:
    0 18px 28px rgba(31, 17, 10, 0.18),
    inset 0 0 0 1px rgba(42, 196, 255, 0.22);
}

.track-order {
  color: var(--wood);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.track-main {
  display: grid;
  gap: 6px;
}

.track-main strong {
  font-size: 1.08rem;
}

.track-tagline {
  font-size: 0.92rem;
}

.track-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 0.86rem;
}

@keyframes record-spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

@keyframes equalize {
  from {
    height: 28px;
  }

  to {
    height: 160px;
  }
}

@media (max-width: 1080px) {
  .room-intro,
  .stage-grid,
  .turntable-shell {
    grid-template-columns: 1fr;
  }

  .playlist-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .room-shell {
    width: min(100% - 12px, 100%);
    padding: 16px;
    border-radius: 28px;
  }

  .room-topbar,
  .room-intro,
  .panel-head,
  .screen-overlay {
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: flex-start;
  }

  .room-badges,
  .overlay-stack {
    justify-content: flex-start;
  }

  .playlist-grid {
    grid-template-columns: 1fr;
  }

  .screen-frame,
  .turntable {
    min-height: 420px;
  }

  .record {
    width: min(100%, 270px);
  }
}
