:root {
  color-scheme: dark;
  --ink: #f1efe7;
  --muted: #aaa99f;
  --line: #4d4e48;
  --night: #141512;
  --signal: #d8ff3e;
}

* { box-sizing: border-box; }
html, body { width: 100%; min-height: 100%; }
body {
  margin: 0;
  overflow: hidden;
  background:
    linear-gradient(rgba(241, 239, 231, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(241, 239, 231, .035) 1px, transparent 1px),
    var(--night);
  background-size: 28px 28px;
  color: var(--ink);
  font-family: "Manrope", sans-serif;
}

button { font: inherit; }
.player-board { width: min(1440px, calc(100% - 56px)); height: 100vh; margin: 0 auto; display: grid; grid-template-rows: 74px minmax(0, 1fr) 42px; }
header { display: flex; align-items: center; justify-content: space-between; border-top: 2px solid var(--ink); border-bottom: 1px solid var(--line); }
.player-label, header button, footer { font: 500 9px "DM Mono", monospace; letter-spacing: .1em; }
.player-label { display: flex; align-items: center; gap: 10px; }
.live-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--signal); box-shadow: 0 0 0 4px rgba(216, 255, 62, .12); animation: pulse 2s infinite; }
header button { padding: 7px 9px; border: 1px solid var(--line); background: transparent; color: var(--ink); cursor: pointer; }
header button:hover, header button:focus-visible { border-color: var(--ink); outline: 1px solid var(--ink); outline-offset: 3px; }

.player-stage { min-height: 0; display: grid; grid-template-columns: minmax(280px, 48vh) minmax(0, 1fr); align-items: center; gap: clamp(36px, 7vw, 110px); padding: clamp(24px, 5vh, 70px) 4vw; }
.artwork-frame { position: relative; width: 100%; aspect-ratio: 1; margin: 0; overflow: hidden; background: #252620; box-shadow: 20px 20px 0 rgba(241, 239, 231, .055); }
.artwork-frame img { width: 100%; height: 100%; display: block; object-fit: cover; }
.artwork-frame img[hidden], .artwork-placeholder[hidden] { display: none; }
.artwork-placeholder { width: 100%; height: 100%; display: grid; place-items: center; color: var(--line); font: 400 clamp(90px, 15vw, 220px)/1 "Manrope", sans-serif; }
.player-copy { min-width: 0; }
.player-copy > p:first-child { margin: 0 0 18px; color: var(--signal); font: 500 10px "DM Mono", monospace; letter-spacing: .1em; }
.player-copy h1 { max-width: 880px; margin: 0; font-size: clamp(42px, 6vw, 88px); line-height: .94; letter-spacing: -.065em; overflow-wrap: anywhere; }
.player-copy h2 { margin: 24px 0 0; color: var(--ink); font-size: clamp(22px, 2.5vw, 38px); line-height: 1; letter-spacing: -.035em; }
.album { margin: 12px 0 0; color: var(--muted); font: 500 11px "DM Mono", monospace; letter-spacing: .04em; }
.progress-wrap { max-width: 760px; margin-top: clamp(32px, 6vh, 70px); }
.progress-wrap[hidden] { display: none; }
.progress-track { height: 3px; overflow: hidden; background: var(--line); }
.progress-track span { width: 0; height: 100%; display: block; background: var(--signal); transition: width 1s linear; }
.progress-time { display: flex; justify-content: space-between; margin-top: 9px; color: var(--muted); font: 500 9px "DM Mono", monospace; }
footer { display: flex; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); color: var(--muted); }
footer span:first-child { color: var(--ink); }

@keyframes pulse { 50% { opacity: .35; } }

@media (max-width: 700px) {
  .player-board { width: calc(100% - 24px); grid-template-rows: 58px minmax(0, 1fr) 34px; }
  .player-stage { grid-template-columns: 1fr; align-content: center; gap: 24px; padding: 18px 7vw; }
  .artwork-frame { width: min(58vw, 330px); justify-self: center; }
  .player-copy { text-align: center; }
  .player-copy h1 { font-size: clamp(30px, 10vw, 52px); }
  .player-copy h2 { margin-top: 14px; font-size: 20px; }
  .progress-wrap { margin-top: 24px; }
}

@media (width: 800px) and (height: 480px) {
  .player-board { width: 784px; grid-template-rows: 42px minmax(0, 1fr) 24px; }
  header { border-top-width: 1px; }
  .player-label, header button, footer { font-size: 6px; }
  header button { padding: 4px 6px; }
  .live-dot { width: 6px; height: 6px; box-shadow: none; }
  .player-stage { grid-template-columns: 360px minmax(0, 1fr); gap: 32px; padding: 18px 24px; }
  .artwork-frame { width: 360px; box-shadow: 8px 8px 0 rgba(241, 239, 231, .055); }
  .player-copy { text-align: left; }
  .player-copy > p:first-child { margin-bottom: 10px; font-size: 6px; }
  .player-copy h1 { font-size: 37px; }
  .player-copy h2 { margin-top: 14px; font-size: 18px; }
  .album { margin-top: 7px; font-size: 7px; }
  .progress-wrap { margin-top: 28px; }
  .progress-time { font-size: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  .live-dot { animation: none; }
  .progress-track span { transition: none; }
}
