/* The cabinet is a flex item of <body>, so it sizes to its content - cap it
   here as well as on .jukebox-body, or the body's max-width resolves against
   a parent that is already 480px wide and nothing shrinks. */
[data-skin="classic"] .jukebox {
  max-width: 100%;
}

[data-skin="classic"] .jukebox-body {
  margin-top: -140px;
  width: 480px;
  /* Without this the cabinet keeps its full 480px on a phone-width window and
     the page scrolls sideways. */
  max-width: 100%;
  background: linear-gradient(180deg, #1a0a00 0%, #0d0600 100%);
  border: 3px solid #8b6914;
  border-radius: 20px 20px 40px 40px;
  box-shadow: 0 0 60px rgba(255, 160, 0, 0.3), inset 0 0 40px rgba(0,0,0,0.5);
  padding: 0 0 30px 0;
  overflow: hidden;
}

/* Neon-only furniture. */
[data-skin="classic"] .neon-video,
[data-skin="classic"] .transport,
[data-skin="classic"] .progress,
[data-skin="classic"] .song-title--short,
[data-skin="classic"] .song-album { display: none; }

[data-skin="classic"] .skin-toggle,
[data-skin="classic"] .hide-toggle,
[data-skin="classic"] .viz-btn {
  color: #ff9500;
  border: 1px solid #8b6914;
}
[data-skin="classic"] .skin-toggle:hover,
[data-skin="classic"] .hide-toggle:hover,
[data-skin="classic"] .viz-btn:hover {
  background: rgba(255, 149, 0, 0.15);
  border-color: #ff9500;
  box-shadow: 0 0 10px rgba(255, 149, 0, 0.3);
}

[data-skin="classic"] .jukebox-top {
  background: linear-gradient(180deg, #2a1500 0%, #1a0d00 100%);
  border-bottom: 2px solid #8b6914;
  padding: 20px;
  text-align: center;
}

[data-skin="classic"] .jukebox-title {
  font-family: 'Orbitron', monospace;
  font-size: 22px;
  font-weight: 900;
  color: #ff9500;
  text-shadow: 0 0 20px #ff6600, 0 0 40px #ff3300;
  letter-spacing: 4px;
  text-transform: uppercase;
}

[data-skin="classic"] .display {
  background: #050f05;
  border: 2px solid #1a4a1a;
  border-radius: 8px;
  margin: 20px;
  padding: 20px;
  min-height: 100px;
  box-shadow: inset 0 0 20px rgba(0, 255, 0, 0.1), 0 0 10px rgba(0, 200, 0, 0.2);
}

[data-skin="classic"] .now-playing-label {
  font-family: 'Orbitron', monospace;
  font-size: 10px;
  color: #2a8a2a;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 8px;
}

[data-skin="classic"] .song-title {
  font-family: 'Orbitron', monospace;
  font-size: 20px;
  font-weight: 700;
  color: #00ff44;
  text-shadow: 0 0 10px #00ff44;
  margin-bottom: 4px;
  overflow: hidden;
  white-space: nowrap;
  position: relative;
}

[data-skin="classic"] .eq-bars {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 28px;
  margin-top: 8px;
}
[data-skin="classic"] .eq-bar {
  flex: 1;
  background: linear-gradient(180deg, #00ff44, #ff9500);
  border-radius: 1px;
  min-height: 2px;
  height: 2px;
  transition: height 0.08s linear;
}

[data-skin="classic"] .idle-text {
  font-family: 'Orbitron', monospace;
  font-size: 14px;
  color: #1a4a1a;
  text-align: center;
  padding-top: 15px;
  animation: blink 2s step-end infinite;
}

[data-skin="classic"] .audio-section {
  padding: 0 20px;
  margin-bottom: 16px;
}

[data-skin="classic"] audio {
  width: 100%;
  filter: sepia(100%) saturate(200%) hue-rotate(10deg);
  border-radius: 4px;
}

[data-skin="classic"] .divider {
  height: 2px;
  background: linear-gradient(90deg, transparent, #8b6914, transparent);
  margin: 0 20px 16px;
}

[data-skin="classic"] .queue-section { padding: 0 20px; }

[data-skin="classic"] .queue-label {
  font-family: 'Orbitron', monospace;
  font-size: 10px;
  color: #8b6914;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 10px;
}

[data-skin="classic"] .queue-list {
  list-style: none;
  max-height: 180px;
  overflow-y: auto;
}

[data-skin="classic"] .queue-list::-webkit-scrollbar { width: 4px; }
[data-skin="classic"] .queue-list::-webkit-scrollbar-track { background: #0d0600; }
[data-skin="classic"] .queue-list::-webkit-scrollbar-thumb { background: #8b6914; border-radius: 2px; }

[data-skin="classic"] .queue-item {
  padding: 6px 10px;
  border-left: 2px solid #8b6914;
  margin-bottom: 6px;
  color: #c8902a;
  font-size: 13px;
  background: rgba(139, 105, 20, 0.05);
}

[data-skin="classic"] .queue-item .q-title { color: #e8b040; }
[data-skin="classic"] .queue-item .q-artist { color: #8b6914; font-size: 11px; }

[data-skin="classic"] .q-tag {
  font-family: 'Orbitron', monospace;
  font-size: 8px;
  letter-spacing: 2px;
  color: #0d0600;
  background: #8b6914;
  padding: 1px 5px;
  border-radius: 2px;
  vertical-align: 2px;
  margin-left: 8px;
}

[data-skin="classic"] .queue-empty {
  color: #4a3010;
  font-size: 13px;
  font-style: italic;
  padding: 8px 10px;
}

[data-skin="classic"] .library-count {
  font-family: 'Orbitron', monospace;
  font-size: 9px;
  letter-spacing: 2px;
  color: #6b5010;
  text-transform: uppercase;
  text-align: right;
  padding: 8px 10px 0;
  border-top: 1px solid rgba(139, 105, 20, 0.2);
  margin-top: 10px;
}

[data-skin="classic"] .library-count .lc-num { color: #c8902a; }

[data-skin="classic"] .chrome-bar {
  height: 8px;
  background: linear-gradient(180deg, #d4aa40, #8b6914, #d4aa40);
  margin: 0 20px 16px;
  border-radius: 4px;
}

/* The full-screen visualizer view. Deliberately skin-agnostic: it's a
   black-stage takeover, so both skins share this one look. */
.visualizer-view {
  position: fixed; inset: 0; background: #000;
  display: none; flex-direction: column; z-index: 100;
}
.viz-top {
  display: flex; align-items: center; justify-content: space-between;
  padding: calc(12px + env(safe-area-inset-top)) calc(20px + env(safe-area-inset-right)) 12px calc(20px + env(safe-area-inset-left));
  flex-shrink: 0;
  background: linear-gradient(180deg, #1a0a00 0%, #0d0600 100%);
  border-bottom: 2px solid #8b6914;
}
.viz-brand {
  font-family: 'Orbitron', monospace; font-size: 14px; font-weight: 700;
  color: #ff9500; text-shadow: 0 0 10px #ff6600;
  letter-spacing: 3px; text-transform: uppercase;
}
.viz-back {
  font-family: 'Orbitron', monospace; font-size: 11px; letter-spacing: 1px;
  color: #c8902a; text-decoration: none; text-transform: uppercase;
}
.viz-back:hover { color: #ff9500; }
.viz-stage { position: relative; flex: 1; overflow: hidden; }
#viz-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
#viz-canvas-gl { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.viz-nowplaying {
  display: none;
  position: absolute; left: 16px; bottom: 16px;
  background: #050f05; border: 2px solid #1a4a1a; border-radius: 8px;
  padding: 10px 16px;
  box-shadow: inset 0 0 20px rgba(0, 255, 0, 0.1), 0 0 10px rgba(0, 200, 0, 0.2);
  max-width: 60%;
}
.viz-np-title {
  font-family: 'Orbitron', monospace; font-size: 14px; font-weight: 700;
  color: #00ff44; text-shadow: 0 0 8px #00ff44;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.viz-modes {
  display: flex; gap: 6px; flex-wrap: wrap; flex-shrink: 0;
  padding: 10px calc(16px + env(safe-area-inset-right)) calc(10px + env(safe-area-inset-bottom)) calc(16px + env(safe-area-inset-left));
  background: linear-gradient(180deg, #1a0a00 0%, #0d0600 100%);
  border-top: 2px solid #8b6914;
}
.viz-mode-btn {
  flex: 1; min-width: 90px;
  font-family: 'Orbitron', monospace; font-size: 10px;
  letter-spacing: 1.5px; text-transform: uppercase;
  background: transparent; border: 1px solid #4a3010; color: #8b6914;
  padding: 9px 6px; border-radius: 3px; cursor: pointer; transition: .18s;
}
.viz-mode-btn:hover { border-color: #ff9500; color: #ffb454; }
.viz-mode-btn.active {
  border-color: #00ff44; color: #00ff44;
  background: rgba(0, 255, 68, 0.08);
  text-shadow: 0 0 6px rgba(0, 255, 68, 0.4);
}
