:root {
  --bg: #0b0b0c;
  --case: #161617;
  --case-light: #1d1d1f;
  --case-shadow: #050505;
  --screen-bg: #1a160f;
  --screen-bg-2: #221d12;
  --amber: #e08a2a;
  --amber-dim: #8a5418;
  --amber-bright: #f7a93f;
  --rec: #ef3a2c;
  --text-mute: #6a6a6a;
  --btn-bg: #1c1c1e;
  --btn-edge: #2a2a2c;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: var(--bg);
  font-family: 'Share Tech Mono', ui-monospace, monospace;
  color: #ddd;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

.stage {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 24px;
}

.radio {
  position: relative;
  width: min(600px, 68vw);
  aspect-ratio: 16 / 9;
  background:
    radial-gradient(ellipse at 30% 20%, #1f1f21 0%, #131314 55%, #0a0a0b 100%);
  border-radius: 28px;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.04),
    inset 0 -2px 12px rgba(0,0,0,0.6),
    0 30px 80px rgba(0,0,0,0.8),
    0 6px 18px rgba(0,0,0,0.6);
  border: 1px solid #2a2a2c;
  padding: 28px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 175px 1fr auto;
  gap: 14px;
}

/* SCREEN ---------------------------------------------------------- */
.screen {
  grid-column: 1;
  grid-row: 1;
  background:
    repeating-linear-gradient(0deg, rgba(0,0,0,0.18) 0 1px, transparent 1px 3px),
    linear-gradient(180deg, var(--screen-bg-2), var(--screen-bg));
  border-radius: 10px;
  padding: 14px 18px 12px 18px;
  color: var(--amber);
  font-family: 'Share Tech Mono', monospace;
  letter-spacing: 1px;
  box-shadow:
    inset 0 0 0 1px #0c0a06,
    inset 0 2px 12px rgba(0,0,0,0.7),
    0 1px 0 rgba(255,255,255,0.03);
  position: relative;
  height: 175px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-shadow: 0 0 6px rgba(224,138,42,0.35);
  overflow: hidden;
}

.screen-row > * {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: clip;
}

.screen-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 14px;
}

.screen-row.top { font-size: 18px; }
.screen-row.top .status { color: var(--amber-bright); font-weight: bold; }
.screen-row.top .band { margin-left: 8px; flex: 1; font-weight: bold; }
.screen-row.top .time { color: var(--amber-bright); }

.screen-row.sub .show-name {
  font-size: 16px;
  text-transform: uppercase;
}
.screen-row.sub .st { color: var(--amber); font-size: 14px; }

.title-row {
  font-size: 20px;
  line-height: 1.1;
  text-transform: uppercase;
  color: var(--amber-bright);
  min-height: 24px;
  overflow: hidden;
  white-space: nowrap;
}
.title-text {
  display: inline-block;
  white-space: nowrap;
}
.title-text.marquee {
  animation: marquee 16s linear infinite;
}
@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.artist-row {
  border-bottom: 1px solid var(--amber-dim);
  padding-bottom: 8px;
  font-size: 15px;
  text-transform: uppercase;
}

.progress {
  margin-top: auto;
  height: 1px;
  background: var(--amber-dim);
  position: relative;
}
.progress-bar {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0%;
  background: var(--amber-bright);
  box-shadow: 0 0 6px var(--amber-bright);
}

.screen-row.times {
  font-size: 14px;
  color: var(--amber-bright);
}

/* VINYL ----------------------------------------------------------- */
.vinyl-area {
  grid-column: 2;
  grid-row: 1 / span 2;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.vinyl {
  position: relative;
  width: 78%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, #1c1c1e 0%, #131314 40%, #0a0a0b 75%, #050505 100%);
  box-shadow:
    inset 0 0 0 1px #2a2a2c,
    inset 0 12px 40px rgba(0,0,0,0.7),
    0 18px 50px rgba(0,0,0,0.7);
  animation: spin 8s linear infinite;
  animation-play-state: paused;
  cursor: grab;
  touch-action: none;
  user-select: none;
}
.vinyl.spinning { animation-play-state: running; }
.vinyl.dragging { cursor: grabbing; animation: none; }

.seek-hint {
  position: absolute;
  bottom: 6%;
  left: 50%;
  transform: translateX(-50%);
  pointer-events: none;
  font-family: 'VT323', monospace;
  font-size: 22px;
  letter-spacing: 2px;
  color: var(--amber-bright);
  text-shadow: 0 0 10px var(--amber);
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.12s;
  z-index: 10;
}
.seek-hint.visible { opacity: 1; }

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.vinyl-grooves {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background:
    repeating-radial-gradient(circle at 50% 50%,
      rgba(255,255,255,0.02) 0 1px,
      transparent 1px 3px);
  mask: radial-gradient(circle at 50% 50%, transparent 18%, black 19%, black 95%, transparent 100%);
  -webkit-mask: radial-gradient(circle at 50% 50%, transparent 18%, black 19%, black 95%, transparent 100%);
}
/* Cross hairs */
.vinyl::before, .vinyl::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background:
    linear-gradient(90deg, transparent 49.7%, rgba(255,255,255,0.05) 49.7% 50.3%, transparent 50.3%),
    linear-gradient(0deg, transparent 49.7%, rgba(255,255,255,0.05) 49.7% 50.3%, transparent 50.3%);
  pointer-events: none;
}
.vinyl::after {
  transform: rotate(45deg);
}

.vinyl-center {
  position: absolute;
  inset: 38% 38% 38% 38%;
  border-radius: 50%;
  background: radial-gradient(circle, #181818 0%, #0a0a0a 70%);
  box-shadow: inset 0 0 0 1px #2a2a2c, 0 4px 12px rgba(0,0,0,0.7);
  display: flex;
  align-items: center;
  justify-content: center;
}
.vinyl-hole {
  width: 22%;
  height: 22%;
  border-radius: 50%;
  background: #050505;
  box-shadow: inset 0 0 4px rgba(0,0,0,0.9);
}
.vinyl-dot {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--rec);
  top: 50%;
  right: 8%;
  transform: translateY(-50%);
  box-shadow: 0 0 8px var(--rec);
}

/* SPEAKER --------------------------------------------------------- */
.speaker {
  grid-column: 1;
  grid-row: 2;
  display: flex;
  align-items: center;
  padding-left: 6px;
}
.speaker-dots {
  width: 130px;
  height: 80px;
  background-image: radial-gradient(circle, rgba(255,255,255,0.08) 1px, transparent 1.4px);
  background-size: 9px 9px;
  background-position: 0 0;
}

/* BOTTOM ROW ------------------------------------------------------ */
.divider {
  grid-column: 1 / -1;
  grid-row: 3;
  height: 1px;
  background: linear-gradient(90deg, transparent, #2c2c2e 30%, #2c2c2e 70%, transparent);
  margin-top: 6px;
  align-self: end;
}

.label-line {
  position: absolute;
  bottom: 58px;
  left: 28px;
  color: var(--text-mute);
  font-size: 12px;
  letter-spacing: 1px;
}

.controls {
  position: absolute;
  bottom: 18px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
}

.btn {
  appearance: none;
  border: 1px solid #2a2a2c;
  background: linear-gradient(180deg, #232325, #161618);
  color: #cfcfcf;
  width: 56px;
  height: 36px;
  border-radius: 10px;
  font-family: 'Share Tech Mono', monospace;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.05),
    inset 0 -2px 4px rgba(0,0,0,0.5),
    0 2px 4px rgba(0,0,0,0.6);
  transition: transform 0.05s ease, background 0.15s ease;
  user-select: none;
}
.btn:hover { background: linear-gradient(180deg, #2a2a2c, #1a1a1c); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }

.btn.play { width: 64px; }

/* RESPONSIVE ------------------------------------------------------ */
@media (max-width: 640px) {
  body { overflow: auto; }
  .radio {
    aspect-ratio: auto;
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto auto;
    padding: 20px;
  }
  .vinyl-area { grid-column: 1; grid-row: 2; height: 220px; }
  .vinyl { width: 200px; }
  .speaker { grid-column: 1; grid-row: 3; justify-content: center; }
  .label-line { position: static; margin-top: 12px; }
  .controls { position: static; margin-top: 18px; flex-wrap: wrap; }
}
