/* ============================================================================
 * VibeDial — "Cinematic Vinyl" bold visual redesign layer (2026-07)
 * ----------------------------------------------------------------------------
 * Loaded AFTER vibedial.css. Deliberately a visual layer: it elevates depth,
 * typography, the album-art presence, and the controls — WITHOUT changing the
 * responsive grid structure the base stylesheet carefully tunes. Easy to tune
 * or disable (remove the one <link>). Everything degrades to the base look.
 * ========================================================================= */

/* ---- 1. Richer, deeper canvas + refined tokens --------------------------- */
:root {
  --bg-deep: #04050d;
  --bg-mid:  #0b0e1e;
  --bg-high: #141a35;
  --line: rgba(255, 255, 255, .12);
  --line-strong: rgba(255, 255, 255, .22);
  --shadow: 0 30px 100px rgba(0, 0, 0, .58);
  --r-glow: color-mix(in srgb, var(--c2) 60%, transparent);
}

body {
  background:
    radial-gradient(1200px 900px at 15% -10%, color-mix(in srgb, var(--c1) 10%, transparent), transparent 60%),
    radial-gradient(1000px 800px at 110% 20%, color-mix(in srgb, var(--c2) 12%, transparent), transparent 55%),
    radial-gradient(900px 900px at 50% 120%, color-mix(in srgb, var(--c3) 8%, transparent), transparent 60%),
    var(--bg-deep);
}

/* Panels: deeper glass, crisper edge, more presence. */
.panel {
  border: 1px solid var(--line);
  box-shadow:
    var(--shadow),
    inset 0 1px 0 rgba(255, 255, 255, .05);
}

/* ---- 2. Cinematic album-art backdrop ------------------------------------- */
.np-art-backdrop { filter: blur(58px) saturate(1.5); transform: scale(1.25); }
.np-art-backdrop.is-visible { opacity: .42; }
.np-art-backdrop::after {
  background:
    radial-gradient(120% 90% at 32% 26%, transparent, color-mix(in srgb, var(--bg-deep) 82%, transparent) 72%),
    linear-gradient(180deg, transparent 30%, var(--bg-deep));
}

/* ---- 3. Hero typography --------------------------------------------------- */
/* Playing state: bigger, more confident station title. */
.panel.player .station-title {
  font-size: clamp(2rem, 5cqi, 3.4rem);
  letter-spacing: -0.05em;
  line-height: 0.98;
}
/* Landing wordmark: dramatic hero with a soft glow. */
body.landing-mode .station-title {
  font-size: clamp(2.8rem, 6.2cqi, 4.6rem) !important;
  letter-spacing: -0.03em !important;
  filter: drop-shadow(0 6px 40px color-mix(in srgb, var(--c2) 35%, transparent));
}
.station-sub { color: color-mix(in srgb, var(--text) 72%, transparent); }

/* Eyebrow: a refined, lit kicker. */
.eyebrow { color: color-mix(in srgb, var(--c1) 82%, var(--muted)); }

/* ---- 4. Now-playing track — a real feature (overrides the flattened block) */
#nowMeta.now-meta {
  margin-top: 4px !important;
  padding: 14px 16px !important;
  border-radius: 18px !important;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--c2) 12%, transparent), transparent 70%),
    rgba(255, 255, 255, .04) !important;
  border: 1px solid color-mix(in srgb, var(--c2) 26%, var(--line)) !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
#nowMeta .now-meta-kicker {
  color: var(--c1) !important;
  font-size: 10px !important;
  font-weight: 900 !important;
  letter-spacing: .18em !important;
  text-transform: uppercase !important;
}
#nowMeta strong {
  font-family: var(--font-display) !important;
  font-size: 1.15rem !important;
  font-weight: 800 !important;
  letter-spacing: -0.02em !important;
  line-height: 1.15 !important;
  color: var(--text) !important;
  background: none !important;
  -webkit-text-fill-color: currentColor !important;
}

/* ---- 5. Premium transport ------------------------------------------------ */
.primary {
  box-shadow:
    0 12px 40px color-mix(in srgb, var(--c2) 45%, transparent),
    0 2px 0 rgba(255, 255, 255, .25) inset,
    0 -8px 20px rgba(0, 0, 0, .25) inset;
  transition: transform 140ms cubic-bezier(.2, .8, .2, 1), box-shadow 200ms ease, filter 160ms ease;
}
.primary:hover { transform: translateY(-2px) scale(1.03); filter: brightness(1.06); }
.primary:active { transform: scale(.96); }

.icon-btn, .nav-btn, .tool-btn {
  transition: transform 140ms cubic-bezier(.2, .8, .2, 1), background 180ms ease, border-color 180ms ease;
}
.icon-btn:hover, .nav-btn:hover, .tool-btn:hover {
  transform: translateY(-1px);
  border-color: color-mix(in srgb, var(--c1) 45%, var(--line));
}

/* Volume slider: brand-lit track + glowing thumb. */
#volume { accent-color: var(--c1); }

/* ---- 6. Station cards — crisper, more tactile ---------------------------- */
.station-card {
  border: 1px solid var(--line);
  transition: transform 160ms cubic-bezier(.2, .8, .2, 1), border-color 180ms ease, background 180ms ease, box-shadow 180ms ease;
}
.station-card:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--c1) 45%, var(--line));
  box-shadow: 0 14px 40px rgba(0, 0, 0, .35);
}

/* Lanes / chips: a touch more life on the active pill. */
.genre.is-active, .genre[aria-selected="true"] {
  box-shadow: 0 6px 22px color-mix(in srgb, var(--c2) 40%, transparent);
}

/* ---- 7. Landing actions — bolder CTA ------------------------------------- */
.primary-landing {
  box-shadow: 0 14px 44px color-mix(in srgb, var(--c2) 42%, transparent);
  transition: transform 160ms cubic-bezier(.2, .8, .2, 1), box-shadow 220ms ease, filter 160ms ease;
}
.primary-landing:hover { transform: translateY(-2px) scale(1.02); filter: brightness(1.05); }

/* ---- 8. Mobile dock — more premium --------------------------------------- */
.mobile-dock-btn.active {
  box-shadow: 0 8px 30px color-mix(in srgb, var(--c2) 40%, transparent);
}

/* ---- 9. RADICAL: large album cover as the now-playing centerpiece -------- */
/* When a track has cover art, a big album cover eases in over the turntable
 * area and the vinyl slides out behind it — a record leaving its sleeve. */
.np-cover {
  position: absolute;
  inset: 3%;
  border-radius: 20px;
  overflow: hidden;
  opacity: 0;
  transform: scale(.82) translateY(8px);
  transition: opacity .55s ease, transform .6s cubic-bezier(.2, .9, .25, 1.1);
  box-shadow:
    0 30px 70px rgba(0, 0, 0, .6),
    0 0 0 1px rgba(255, 255, 255, .08) inset,
    0 0 60px -10px var(--r-glow);
  z-index: 4;
  pointer-events: none;
}
.np-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.np-cover::after {          /* subtle sheen across the cover */
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, .14), transparent 42%);
  pointer-events: none;
}

body.has-cover-art .np-cover { opacity: 1; transform: scale(1) translateY(0); }
/* Vinyl eases out from behind the cover, upper-right, and keeps spinning. */
body.has-cover-art .disc {
  transform: translate(30%, -12%) scale(.9);
  transition: transform .6s cubic-bezier(.2, .9, .25, 1.1);
  z-index: 1;
}
body.has-cover-art.is-playing .disc,
body.has-cover-art.is-buffering .disc {
  animation: vd-spin-offset 5s linear infinite;
}
@keyframes vd-spin-offset {
  from { transform: translate(30%, -12%) scale(.9) rotate(0deg); }
  to   { transform: translate(30%, -12%) scale(.9) rotate(360deg); }
}
body.has-cover-art .disc-art { display: none; }   /* label redundant behind cover */
/* Tonearm rests further out so it doesn't cross the cover. */
body.has-cover-art .arm { z-index: 5; }

/* ---- 10. Motion: tonearm drop + landing↔playing transitions -------------- */
.arm { transition: transform .7s cubic-bezier(.34, 1.3, .5, 1) !important; }
.station-title, .station-sub, .now-meta, .status-pill { transition: opacity .4s ease; }
.turntable, .disc-wrap { transition: transform .5s cubic-bezier(.2, .8, .2, 1); }

/* ---- 11. Quick vibes on the landing (fills empty space) ------------------ */
.landing-quickvibes {
  display: none;
  margin-top: 22px;
  width: 100%;
  max-width: 440px;
}
body.landing-mode .landing-quickvibes { display: block; }
.landing-quickvibes-label {
  font-size: var(--text-xs); letter-spacing: .16em; text-transform: uppercase;
  color: var(--muted); font-weight: 800; margin: 0 0 10px;
}
.landing-quickvibes-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.quickvibe {
  border: 1px solid var(--line);
  background: linear-gradient(135deg, color-mix(in srgb, var(--c1) 8%, transparent), rgba(255, 255, 255, .04));
  color: var(--text);
  border-radius: var(--radius-pill);
  padding: 10px 16px; min-height: 44px;
  font: inherit; font-size: 13px; font-weight: 600; cursor: pointer;
  transition: transform 140ms cubic-bezier(.2, .8, .2, 1), border-color 160ms ease, background 160ms ease;
}
.quickvibe:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--c1) 55%, var(--line)); }
.quickvibe:active { transform: scale(.97); }
@container vd-player (min-width: 480px) {
  .landing-quickvibes { text-align: start; }
  .landing-quickvibes-grid { justify-content: flex-start; }
}

/* ---- 12. Vibe readout — visible confirmation of the interpreted mood ----- */
.vibe-readout {
  display: flex; align-items: center; flex-wrap: wrap; gap: 8px;
  padding: 4px 2px 2px;
  animation: vibe-readout-in .35s ease;
}
@keyframes vibe-readout-in { from { opacity: 0; transform: translateY(-3px); } to { opacity: 1; transform: none; } }
.vibe-readout-kicker {
  font-size: 11px; font-weight: 900; letter-spacing: .12em; text-transform: uppercase;
  color: var(--c1);
}
.vibe-readout-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.vibe-readout-chip {
  font-size: 12px; font-weight: 600; color: var(--text);
  padding: 4px 10px; border-radius: var(--radius-pill);
  background: linear-gradient(135deg, color-mix(in srgb, var(--c1) 22%, transparent), color-mix(in srgb, var(--c2) 18%, transparent));
  border: 1px solid color-mix(in srgb, var(--c1) 30%, var(--line));
}
.vibe-readout-via { font-size: 11px; color: var(--muted); font-style: italic; margin-left: auto; }

@media (prefers-reduced-motion: reduce) {
  .primary, .primary-landing, .station-card, .icon-btn, .nav-btn, .tool-btn,
  .np-cover, .disc, .arm, .turntable, .disc-wrap, .quickvibe { transition: none !important; animation: none !important; }
  body.has-cover-art .np-cover { transform: none; }
  body.has-cover-art .disc { transform: translate(30%, -12%) scale(.9); }
  .vibe-readout { animation: none; }
}
