/* =============================================================================
   repentitive — stylesheet
   -----------------------------------------------------------------------------
   1.  Design tokens
   2.  Reset
   3.  Base & typography
   4.  Utilities
   5.  Backdrop
   6.  Profile card
   7.  Links
   8.  Buttons
   9.  Player shell
   10. Seek & volume ranges
   11. Queue
   12. Toasts & unmute
   13. Responsive
   14. Motion & accessibility preferences
   ========================================================================== */

/* -----------------------------------------------------------------------------
   1. Design tokens
   -------------------------------------------------------------------------- */
:root {
  /* Accent is written by assets/js/theme.js as space separated RGB channels,
     so it can be used as rgb(var(--accent) / <alpha>). */
  --accent: 176 178 184;
  --accent-ink: 215 216 220;

  --bg: #050505;
  --surface: 12 12 14;
  --text: #f2f2f4;
  --text-muted: #9b9ba4;
  --text-faint: #6b6b74;

  --border: rgb(255 255 255 / 0.08);
  --border-strong: rgb(var(--accent) / 0.28);

  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-pill: 999px;

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 2.75rem;

  --shadow-card: 0 24px 70px rgb(0 0 0 / 0.55);
  --shadow-player: 0 18px 50px rgb(0 0 0 / 0.5);
  --shadow-accent: 0 0 28px rgb(var(--accent) / 0.16);

  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast: 160ms;
  --dur: 280ms;
  --dur-slow: 900ms;

  --content-width: 30rem;
  --player-width: 34rem;

  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial,
    sans-serif;
}

/* -----------------------------------------------------------------------------
   2. Reset
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  height: 100%;
}

img,
svg,
video,
canvas {
  display: block;
  max-width: 100%;
}

button,
input {
  font: inherit;
  color: inherit;
}

button {
  background: none;
  border: 0;
  cursor: pointer;
}

ol,
ul {
  list-style: none;
}

/* -----------------------------------------------------------------------------
   3. Base & typography
   -------------------------------------------------------------------------- */
body {
  min-height: 100svh;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background: rgb(var(--accent) / 0.28);
  color: #fff;
}

:focus-visible {
  outline: 2px solid rgb(var(--accent-ink) / 0.9);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* -----------------------------------------------------------------------------
   4. Utilities
   -------------------------------------------------------------------------- */
.skip-link {
  position: fixed;
  top: var(--space-2);
  left: 50%;
  z-index: 100;
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-pill);
  background: rgb(var(--surface));
  border: 1px solid var(--border-strong);
  color: var(--text);
  font-size: 0.85rem;
  text-decoration: none;
  transform: translate(-50%, -200%);
  transition: transform var(--dur) var(--ease);
}

.skip-link:focus-visible {
  transform: translate(-50%, 0);
}

/* -----------------------------------------------------------------------------
   5. Backdrop
   -------------------------------------------------------------------------- */
.backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: var(--bg);
}

.backdrop__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.06);
  filter: saturate(1.05);
}

/* Vignette + top/bottom fade so text stays readable over any frame. */
.backdrop__scrim {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(120% 90% at 50% 40%, transparent 0%, rgb(0 0 0 / 0.62) 100%),
    linear-gradient(180deg, rgb(0 0 0 / 0.55) 0%, rgb(0 0 0 / 0.28) 32%, rgb(0 0 0 / 0.86) 100%);
}

/* Soft colour wash pulled from the current track. */
.backdrop__glow {
  position: absolute;
  inset: -20%;
  background: radial-gradient(45% 40% at 50% 88%, rgb(var(--accent) / 0.22), transparent 70%);
  transition: background var(--dur-slow) linear;
  pointer-events: none;
}

/* -----------------------------------------------------------------------------
   6. Profile card
   -------------------------------------------------------------------------- */
.stage {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  min-height: 100svh;
  padding: var(--space-6) var(--space-4) calc(15rem + env(safe-area-inset-bottom));
}

.card {
  width: 100%;
  max-width: var(--content-width);
  padding: var(--space-7) var(--space-5) var(--space-6);
  text-align: center;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgb(var(--surface) / 0.78), rgb(6 6 8 / 0.72));
  backdrop-filter: blur(28px) saturate(1.2);
  -webkit-backdrop-filter: blur(28px) saturate(1.2);
  box-shadow: var(--shadow-card);
  animation: rise 700ms var(--ease) both;
  transition: border-color var(--dur-slow) linear;
}

.card__avatar {
  position: relative;
  width: 128px;
  height: 128px;
  margin: 0 auto var(--space-4);
}

.card__image {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background: #111;
  box-shadow: 0 12px 34px rgb(0 0 0 / 0.6);
}

/* Accent ring that tints with the track. */
.card__ring {
  position: absolute;
  inset: -5px;
  border-radius: 50%;
  border: 1.5px solid rgb(var(--accent) / 0.45);
  box-shadow: var(--shadow-accent);
  transition: border-color var(--dur-slow) linear, box-shadow var(--dur-slow) linear;
  pointer-events: none;
}

.card__name {
  font-size: clamp(1.6rem, 6vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.card__handle {
  margin-top: var(--space-1);
  font-size: 0.875rem;
  font-weight: 500;
  color: rgb(var(--accent-ink) / 0.75);
  transition: color var(--dur-slow) linear;
}

.card__bio {
  margin-top: var(--space-3);
  font-size: 0.9rem;
  color: var(--text-muted);
  text-wrap: pretty;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(24px) scale(0.97);
  }
}

/* -----------------------------------------------------------------------------
   7. Links
   -------------------------------------------------------------------------- */
.links {
  display: grid;
  gap: var(--space-2);
  margin-top: var(--space-5);
}

.link {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--space-3);
  padding: 0.8rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: rgb(255 255 255 / 0.035);
  color: var(--text-muted);
  font-size: 0.925rem;
  font-weight: 500;
  text-align: left;
  text-decoration: none;
  transition: transform var(--dur) var(--ease), background var(--dur) var(--ease),
    border-color var(--dur) var(--ease), color var(--dur) var(--ease),
    box-shadow var(--dur) var(--ease);
  animation: rise 520ms var(--ease) both;
}

.link:nth-child(1) { animation-delay: 120ms; }
.link:nth-child(2) { animation-delay: 180ms; }
.link:nth-child(3) { animation-delay: 240ms; }
.link:nth-child(4) { animation-delay: 300ms; }
.link:nth-child(5) { animation-delay: 360ms; }

.link:hover,
.link:focus-visible {
  transform: translateY(-2px);
  color: var(--text);
  background: rgb(var(--accent) / 0.1);
  border-color: rgb(var(--accent) / 0.32);
  box-shadow: 0 12px 28px rgb(0 0 0 / 0.4), var(--shadow-accent);
}

.link:active {
  transform: translateY(0);
}

.link__icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  background: rgb(255 255 255 / 0.05);
  color: var(--text);
  transition: background var(--dur) var(--ease);
}

.link__icon svg {
  width: 18px;
  height: 18px;
}

.link:hover .link__icon {
  background: rgb(var(--accent) / 0.18);
}

/* Brand tints, only strong enough to hint at the platform. */
.link--discord .link__icon { color: #98a5f8; }
.link--telegram .link__icon { color: #7fc4ef; }
.link--roblox .link__icon { color: #f08f8f; }

.link__chevron {
  display: grid;
  place-items: center;
  color: var(--text-faint);
  transition: transform var(--dur) var(--ease), color var(--dur) var(--ease);
}

.link__chevron svg {
  width: 16px;
  height: 16px;
}

.link:hover .link__chevron {
  transform: translateX(3px);
  color: rgb(var(--accent-ink) / 0.9);
}

/* -----------------------------------------------------------------------------
   8. Buttons
   -------------------------------------------------------------------------- */
.icon-btn {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  color: var(--text-muted);
  transition: color var(--dur-fast) var(--ease), background var(--dur-fast) var(--ease),
    transform var(--dur-fast) var(--ease);
}

.icon-btn svg {
  width: 20px;
  height: 20px;
}

.icon-btn:hover:not(:disabled) {
  color: var(--text);
  background: rgb(255 255 255 / 0.08);
}

.icon-btn:active:not(:disabled) {
  transform: scale(0.94);
}

.icon-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.icon-btn--sm {
  width: 32px;
  height: 32px;
}

.icon-btn--sm svg {
  width: 16px;
  height: 16px;
}

.icon-btn.is-active {
  color: rgb(var(--accent-ink) / 0.95);
  background: rgb(var(--accent) / 0.16);
}

.icon-btn--primary {
  width: 50px;
  height: 50px;
  color: #fff;
  background: rgb(var(--accent) / 0.2);
  border: 1px solid rgb(var(--accent) / 0.4);
  box-shadow: var(--shadow-accent);
  transition: background var(--dur-slow) linear, border-color var(--dur-slow) linear,
    transform var(--dur-fast) var(--ease);
}

.icon-btn--primary svg {
  width: 22px;
  height: 22px;
}

.icon-btn--primary:hover {
  background: rgb(var(--accent) / 0.3);
  transform: scale(1.06);
}

/* -----------------------------------------------------------------------------
   9. Player shell
   -------------------------------------------------------------------------- */
.player {
  position: fixed;
  bottom: max(var(--space-5), env(safe-area-inset-bottom));
  left: 50%;
  z-index: 10;
  width: min(var(--player-width), calc(100% - 2 * var(--space-4)));
  transform: translateX(-50%);
  animation: rise 700ms var(--ease) 200ms both;
}

.player__viz {
  height: 46px;
  overflow: hidden;
  border: 1px solid rgb(var(--accent) / 0.14);
  border-bottom: 0;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  background: linear-gradient(180deg, rgb(var(--accent) / 0.1), rgb(0 0 0 / 0.35));
  transition: border-color var(--dur-slow) linear, background var(--dur-slow) linear;
}

.player__canvas {
  width: 100%;
  height: 100%;
}

.player__body {
  position: relative;
  padding: var(--space-3) var(--space-4) var(--space-3);
  border: 1px solid rgb(var(--accent) / 0.18);
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  background: linear-gradient(180deg, rgb(16 16 19 / 0.94), rgb(5 5 7 / 0.94));
  backdrop-filter: blur(28px) saturate(1.2);
  -webkit-backdrop-filter: blur(28px) saturate(1.2);
  box-shadow: var(--shadow-player);
  transition: border-color var(--dur-slow) linear;
}

.player__meta {
  position: relative;
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: var(--space-2);
  min-height: 1.5rem;
  padding: 0 1.75rem;
}

.player__title {
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player__artist {
  flex-shrink: 0;
  font-size: 0.78rem;
  color: var(--text-faint);
  white-space: nowrap;
}

.player__artist:not(:empty)::before {
  content: '·';
  margin-right: var(--space-2);
}

/* Buffering indicator, shown via .is-loading on .player */
.player__spinner {
  position: absolute;
  top: 50%;
  right: 0;
  width: 14px;
  height: 14px;
  margin-top: -7px;
  border: 2px solid rgb(var(--accent) / 0.25);
  border-top-color: rgb(var(--accent-ink) / 0.95);
  border-radius: 50%;
  opacity: 0;
  transition: opacity var(--dur) var(--ease);
}

.player.is-loading .player__spinner {
  opacity: 1;
  animation: spin 720ms linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.player__seek {
  display: grid;
  grid-template-columns: 2.5rem 1fr 2.5rem;
  align-items: center;
  gap: var(--space-2);
  margin: var(--space-2) 0 var(--space-1);
}

.player__time {
  font-size: 0.7rem;
  font-variant-numeric: tabular-nums;
  color: var(--text-faint);
}

.player__time:last-of-type {
  text-align: right;
}

.player__controls {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--space-2);
}

.player__group {
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

.player__group--center {
  gap: var(--space-2);
}

.player__group--end {
  justify-content: flex-end;
}

/* -----------------------------------------------------------------------------
   10. Seek & volume ranges
   -------------------------------------------------------------------------- */

/* Track wrapper carries the buffered progress behind the input. */
.seek {
  --fill: 0%;
  --buffered: 0%;
  position: relative;
  height: 16px;
  display: grid;
  align-items: center;
}

.seek::before,
.seek::after {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  z-index: 0;
  height: 4px;
  border-radius: var(--radius-pill);
  transform: translateY(-50%);
  pointer-events: none;
}

.seek::before {
  width: 100%;
  background: rgb(255 255 255 / 0.1);
}

.seek::after {
  width: var(--buffered);
  background: rgb(255 255 255 / 0.14);
  transition: width var(--dur) linear;
}

.seek__input,
.volume__input {
  --fill: 0%;
  -webkit-appearance: none;
  appearance: none;
  position: relative;
  z-index: 1;
  width: 100%;
  height: 16px;
  background: transparent;
  cursor: pointer;
}

/* Filled portion is painted on the track pseudo-element. */
.seek__input::-webkit-slider-runnable-track,
.volume__input::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: var(--radius-pill);
  background: linear-gradient(
    90deg,
    rgb(var(--accent) / 0.95) var(--fill),
    transparent var(--fill)
  );
}

.volume__input::-webkit-slider-runnable-track {
  background: linear-gradient(
    90deg,
    rgb(var(--accent) / 0.85) var(--fill),
    rgb(255 255 255 / 0.12) var(--fill)
  );
}

.seek__input::-moz-range-track,
.volume__input::-moz-range-track {
  height: 4px;
  border-radius: var(--radius-pill);
  background: rgb(255 255 255 / 0.12);
}

.seek__input::-moz-range-progress,
.volume__input::-moz-range-progress {
  height: 4px;
  border-radius: var(--radius-pill);
  background: rgb(var(--accent) / 0.95);
}

.seek__input::-webkit-slider-thumb,
.volume__input::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 12px;
  height: 12px;
  margin-top: -4px;
  border: 0;
  border-radius: 50%;
  background: rgb(var(--accent-ink));
  box-shadow: 0 0 12px rgb(var(--accent) / 0.5);
  transition: transform var(--dur-fast) var(--ease);
}

.seek__input::-moz-range-thumb,
.volume__input::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 50%;
  background: rgb(var(--accent-ink));
  box-shadow: 0 0 12px rgb(var(--accent) / 0.5);
}

.seek__input:hover::-webkit-slider-thumb,
.volume__input:hover::-webkit-slider-thumb {
  transform: scale(1.25);
}

.volume {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  padding: 2px 8px 2px 2px;
  border: 1px solid rgb(var(--accent) / 0.12);
  border-radius: var(--radius-pill);
  background: rgb(255 255 255 / 0.035);
  transition: border-color var(--dur-slow) linear;
}

.volume__input {
  width: 62px;
  height: 14px;
}

/* -----------------------------------------------------------------------------
   11. Queue
   -------------------------------------------------------------------------- */
.queue {
  margin-bottom: 1px;
  border: 1px solid rgb(var(--accent) / 0.18);
  border-bottom: 0;
  background: linear-gradient(180deg, rgb(14 14 17 / 0.96), rgb(9 9 11 / 0.96));
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  animation: queue-in var(--dur) var(--ease) both;
  transition: border-color var(--dur-slow) linear;
}

@keyframes queue-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
}

.queue__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-2) var(--space-2) var(--space-2) var(--space-4);
  border-bottom: 1px solid var(--border);
}

.queue__heading {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.queue__list {
  max-height: min(42svh, 20rem);
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgb(var(--accent) / 0.35) transparent;
}

.queue__list::-webkit-scrollbar {
  width: 6px;
}

.queue__list::-webkit-scrollbar-thumb {
  border-radius: var(--radius-pill);
  background: rgb(var(--accent) / 0.3);
}

.queue__button {
  display: grid;
  grid-template-columns: 1.5rem 1fr auto;
  align-items: center;
  gap: var(--space-3);
  width: 100%;
  padding: 0.55rem var(--space-4);
  text-align: left;
  transition: background var(--dur-fast) var(--ease);
}

.queue__button:hover:not(:disabled) {
  background: rgb(255 255 255 / 0.05);
}

.queue__index {
  font-size: 0.72rem;
  font-variant-numeric: tabular-nums;
  color: var(--text-faint);
}

/* Equaliser glyph replaces the index on the active row. */
.queue__bars {
  display: none;
  grid-column: 1;
  align-items: flex-end;
  gap: 2px;
  height: 12px;
}

.queue__bars i {
  width: 3px;
  height: 40%;
  border-radius: 1px;
  background: rgb(var(--accent-ink) / 0.9);
}

.queue__item.is-current .queue__index {
  display: none;
}

.queue__item.is-current .queue__bars {
  display: flex;
}

.queue__item.is-playing .queue__bars i {
  animation: eq 900ms var(--ease) infinite alternate;
}

.queue__item.is-playing .queue__bars i:nth-child(2) {
  animation-delay: 150ms;
}

.queue__item.is-playing .queue__bars i:nth-child(3) {
  animation-delay: 300ms;
}

@keyframes eq {
  from { height: 25%; }
  to { height: 100%; }
}

.queue__text {
  min-width: 0;
}

.queue__title,
.queue__meta {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.queue__title {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-muted);
}

.queue__item.is-current .queue__title {
  color: rgb(var(--accent-ink));
  font-weight: 600;
}

.queue__meta {
  font-size: 0.72rem;
  color: var(--text-faint);
}

.queue__meta:empty {
  display: none;
}

.queue__duration {
  font-size: 0.72rem;
  font-variant-numeric: tabular-nums;
  color: var(--text-faint);
}

.queue__item.is-unavailable .queue__title {
  color: var(--text-faint);
  text-decoration: line-through;
}

.queue__item.is-unavailable .queue__duration {
  color: #d98b8b;
  text-transform: uppercase;
  font-size: 0.65rem;
  letter-spacing: 0.08em;
}

/* -----------------------------------------------------------------------------
   12. Toasts & unmute
   -------------------------------------------------------------------------- */
.toasts {
  position: fixed;
  bottom: calc(15rem + env(safe-area-inset-bottom));
  left: 50%;
  z-index: 20;
  display: grid;
  gap: var(--space-2);
  width: min(26rem, calc(100% - 2 * var(--space-4)));
  transform: translateX(-50%);
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0.65rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: rgb(18 18 21 / 0.96);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: var(--shadow-player);
  color: var(--text-muted);
  font-size: 0.8rem;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease);
}

.toast.is-in {
  opacity: 1;
  transform: translateY(0);
}

.toast__icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: #e0b062;
}

.toast__icon svg {
  width: 15px;
  height: 15px;
}

.toast--warn {
  border-color: rgb(224 176 98 / 0.28);
}

.unmute {
  position: fixed;
  top: var(--space-4);
  left: 50%;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0.5rem 1rem;
  border: 1px solid rgb(var(--accent) / 0.32);
  border-radius: var(--radius-pill);
  background: rgb(18 18 21 / 0.9);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  color: var(--text);
  font-size: 0.8rem;
  font-weight: 500;
  transform: translateX(-50%);
  animation: rise 400ms var(--ease) both;
  transition: background var(--dur) var(--ease), border-color var(--dur-slow) linear;
}

.unmute:hover {
  background: rgb(var(--accent) / 0.2);
}

.unmute[hidden] {
  display: none;
}

/* -----------------------------------------------------------------------------
   13. Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 34rem) {
  :root {
    --space-7: 2rem;
  }

  .stage {
    padding-bottom: calc(16rem + env(safe-area-inset-bottom));
  }

  .card {
    padding: var(--space-6) var(--space-4);
    border-radius: var(--radius-lg);
  }

  .card__avatar {
    width: 100px;
    height: 100px;
  }

  .player {
    bottom: max(var(--space-3), env(safe-area-inset-bottom));
    width: calc(100% - 2 * var(--space-3));
  }

  .player__viz {
    height: 38px;
  }

  .player__body {
    padding: var(--space-3);
  }

  /* Volume slider costs more than it earns on a phone; the toggle stays. */
  .volume__input {
    display: none;
  }

  .volume {
    padding: 2px;
    border-color: transparent;
    background: none;
  }

  .toasts {
    bottom: calc(16rem + env(safe-area-inset-bottom));
  }
}

@media (max-height: 34rem) and (orientation: landscape) {
  .stage {
    padding-bottom: calc(12rem + env(safe-area-inset-bottom));
  }

  .card__avatar {
    width: 76px;
    height: 76px;
  }

  .player__viz {
    height: 26px;
  }
}

/* -----------------------------------------------------------------------------
   14. Motion & accessibility preferences
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .backdrop__video {
    transform: none;
  }
}

@media (prefers-contrast: more) {
  :root {
    --text-muted: #d6d6dc;
    --text-faint: #a9a9b2;
    --border: rgb(255 255 255 / 0.24);
  }

  .backdrop__scrim {
    background: rgb(0 0 0 / 0.8);
  }
}

/* Fallback for browsers without backdrop-filter: lean on opacity instead. */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .card,
  .player__body,
  .queue {
    background: rgb(8 8 10 / 0.97);
  }
}

/* No-JS fallback list */
.noscript {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-content: center;
  gap: var(--space-4);
  padding: var(--space-6);
  text-align: center;
  background: var(--bg);
}

.noscript a {
  color: var(--text);
}

/* Discourage casual dragging of media */
img,
video {
  -webkit-user-drag: none;
  user-select: none;
}
