:root {
  color-scheme: light;
  --panel: #fffaf0;
  --panel-border: #d6c7ab;
  --text: #2b2318;
  --muted: #73644f;
  --accent: #a64b2a;
  --accent-strong: #7d361c;
  --shadow: rgba(58, 38, 18, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.6), transparent 35%),
    linear-gradient(135deg, #f3ead7, #e7d8b5);
  color: var(--text);
  min-height: 100vh;
}

.page {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 32px 20px;
}

.player-card {
  width: min(100%, 1080px);
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: 24px;
  box-shadow: 0 20px 60px var(--shadow);
  padding: 28px;
}

.runtime-notice {
  margin-bottom: 18px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid #e0ae67;
  background: #fff1dc;
  color: #6b4311;
  font-size: 0.95rem;
}

.hidden {
  display: none;
}

h1,
h2,
p {
  margin-top: 0;
}

.player-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.player-frame {
  padding: 14px;
  border: 1px solid var(--panel-border);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.45);
}

.player-label {
  margin-bottom: 10px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.8rem;
}

.player-shell {
  overflow: hidden;
  border-radius: 18px;
  background: #000;
  border: 1px solid #1f1f1f;
  aspect-ratio: 16 / 9;
}

.player-shell > div,
.player-shell iframe {
  width: 100%;
  height: 100%;
}

.empty-state {
  margin: 0;
  padding: 24px;
  border: 1px dashed var(--panel-border);
  border-radius: 18px;
  color: var(--muted);
}

.playlist {
  border-top: 1px solid var(--panel-border);
  padding-top: 18px;
}

.playlist-header {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

#playlistList {
  margin: 0;
  padding-left: 22px;
  display: grid;
  gap: 10px;
}

#playlistList li {
  padding: 10px 12px;
  border-radius: 12px;
  color: var(--muted);
}

#playlistList li.active {
  background: rgba(166, 75, 42, 0.1);
  color: var(--text);
  font-weight: 700;
}

@media (max-width: 640px) {
  .player-card {
    padding: 20px;
  }

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