/* ── Bandstand MP3 Player — player.css ────────────────────────────────── */
/* Font inheritance across player, modals, and mini player                  */
/* Body font — !important beats theme stylesheets; display-font rules also
   use !important so they win over this blanket rule. */
.bs-wrap, .bs-wrap *, #bs-mini, #bs-mini *,
#bs-share-modal, #bs-share-modal *,
#bs-info-modal,  #bs-info-modal *,
#bs-dl-modal,    #bs-dl-modal * { font-family: var(--bs-font-body, inherit) !important; }

/* ── Design Tokens ─────────────────────────────────────────────────────── */
.bs-wrap {
  /* New design system */
  --bg:        #0a0b0e85;
  --bg-1:      #101217;
  --bg-2:      #161922;
  --bg-3:      #1d2230;
  --line:      rgba(255,255,255,.07);
  --line-2:    rgba(255,255,255,.12);
  --fg:        #f5f6f8;
  --fg-1:      rgba(245,246,248,.78);
  --fg-2:      rgba(245,246,248,.55);
  --fg-3:      rgba(245,246,248,.38);
  --accent:    #22d3c5;
  --accent-ink:#0a0b0e;
  --radius:    14px;
  --radius-sm: 8px;
  --shadow-1:  0 1px 0 rgba(255,255,255,.04) inset, 0 8px 24px rgba(0,0,0,.4);

  /* Legacy aliases — JS sets these via setProperty; keep in sync */
  --bs-bg:      var(--bg);
  --bs-surface: var(--bg-1);
  --bs-surf2:   var(--bg-2);
  --bs-surf3:   var(--bg-3);
  --bs-border:  var(--line);
  --bs-border2: var(--line-2);
  --bs-text:    var(--fg);
  --bs-muted:   var(--fg-2);
  --bs-accent:  var(--accent);
  --bs-adim:    rgba(34,211,197,0.12);
  --bs-radius:  var(--radius);
  --bs-rsm:     var(--radius-sm);
  --bs-font-body: inherit;
  --bs-font-display: inherit;

  /* Shell */
  background: var(--bg);
  border: 1px solid #3a3a3a;
  color: var(--fg);
  font-family: inherit;
  box-sizing: border-box;
  writing-mode: horizontal-tb !important;
  text-orientation: mixed;
  direction: ltr;
  word-break: normal;
  overflow-wrap: normal;
  border-radius: 18px;
  overflow: hidden;
}
.bs-wrap *, .bs-wrap *::before, .bs-wrap *::after {
  box-sizing: border-box; margin: 0; padding: 0; writing-mode: horizontal-tb;
}

/* ── App Shell: single column — sidebar hidden ──────────────────────────── */
.app {
  display: block;
  min-height: 520px;
}

/* ── Card toolbar: sits above hero card, full width of .main ─────────────── */
.bs-card-toolbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 0 8px;
}
.bs-toolbar-actions { display: flex; gap: 4px; align-items: center; }

/* Toolbar icon buttons — subtle, not accent-coloured */
.bs-toolbar-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border-radius: 8px; border: none; cursor: pointer;
  background: rgba(255,255,255,.07); color: var(--fg-1);
  transition: background .15s, color .15s;
}
.bs-toolbar-btn:hover { background: rgba(255,255,255,.14); color: var(--fg); }
/* Cast button — accent tint when a session is active */
.bs-toolbar-btn.bs-cast-active { color: var(--accent); background: rgba(34,211,197,.15); }
.bs-toolbar-btn.bs-cast-active:hover { background: rgba(34,211,197,.25); }

/* ── Sidebar — hidden ───────────────────────────────────────────────────── */
.side { display: none !important; }

/* Brand bar — always visible, logo left + track actions right */
.bs-brand-bar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 0 10px; min-height: 36px;
}
/* #bs-logo — JS may inject <img> or <span class="bs-logo-text"> here */
.bs-logo { display: flex; align-items: center; gap: 8px; }
.bs-logo-img  { max-height: 40px; width: auto; display: block; object-fit: contain; }
.bs-logo-text { font-family: var(--bs-font-display, inherit) !important; font-size: 1.05rem; font-weight: 700; color: var(--fg); }

/* Nav */
.nav { display: flex; flex-direction: column; gap: 1px; }
.nav__item {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 10px; border-radius: 8px;
  color: var(--fg-1); font-weight: 500; font-size: 13.5px;
  cursor: pointer; transition: background .12s, color .12s;
  border: none; background: transparent; text-align: left; width: 100%;
}
.nav__item:hover { background: var(--bg-2); color: var(--fg); }
.nav__item--on {
  background: var(--bg-2); color: var(--fg);
  box-shadow: inset 2px 0 0 var(--accent), inset 0 0 0 1px var(--line);
}

/* Section label above tracklist in sidebar */
.bs-section-label {
  font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--fg-3); margin: 8px 10px 0;
}

/* ── Main column ────────────────────────────────────────────────────────── */
.main { padding: 20px 24px 60px; min-width: 0; display: flex; flex-direction: column; }

/* ── Hero (Now-Playing Card) — full-width bleed, no radius ──────────────── */
.hero, .bs-card {
  position: relative;
  border-radius: 0;
  overflow: hidden;
  border: none;
  background: var(--bg-1);
  /* Bleed past .main's 24px side padding to reach the wrap edges */
  margin-left: -24px;
  margin-right: -24px;
  padding: 20px 24px 20px;
  display: flex; flex-direction: column;
  min-height: 460px;
  flex-shrink: 0;
}

/* Art layer */
.hero__art { position: absolute; inset: 0; z-index: 0; overflow: hidden; }

/* Gradient-only background when no image/video */
.hero__artInner {
  position: absolute; inset: -10%;
  background:
    radial-gradient(ellipse at 20% 110%, color-mix(in oklab, var(--accent) 50%, transparent), transparent 55%),
    radial-gradient(ellipse at 90% 0%, rgba(167,139,250,.45), transparent 55%),
    linear-gradient(135deg, #1a2438 0%, #2a1730 60%, #0e1620 100%);
  filter: saturate(1.05);
  transition: opacity .4s;
}
/* Hide the artInner gradient once real artwork loads */
.hero.has-image .hero__artInner,
.hero.has-video .hero__artInner { opacity: 0; }

/* Image background */
.hero__artBg, .bs-card-bg {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  z-index: 1;
  opacity: 0; transition: opacity .5s;
}
.hero.has-image .hero__artBg,
.hero.has-image .bs-card-bg { opacity: 1; }

/* Video background */
.bs-card-video { position: absolute; inset: 0; z-index: 1; display: none; }
.bs-card-video video { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero.has-video .bs-card-video { display: block; }

/* Scrim / overlay */
.hero__scrim {
  position: absolute; inset: 0; z-index: 2;
  background: linear-gradient(180deg,
    rgba(10,11,14,.15) 0%,
    rgba(10,11,14,.4)  60%,
    rgba(10,11,14,.82) 100%);
}
/* Deeper scrim when artwork is loaded */
.hero.has-image .hero__scrim,
.hero.has-video .hero__scrim {
  background: linear-gradient(180deg,
    rgba(0,0,0,.25) 0%,
    rgba(0,0,0,.0)  35%,
    rgba(0,0,0,.65) 75%,
    rgba(0,0,0,.95) 100%);
}

/* Content children sit above all art layers.
   NOTE: Do NOT apply position:relative to absolutely-positioned layer children
   (.bs-eq-wrap, .bs-gradient-overlay) — they need to keep position:absolute. */
.hero__top,
.hero__meta,
.hero__transport { position: relative; z-index: 4; }

/* Gradient overlay — user-configured, between art and EQ */
.bs-gradient-overlay {
  position: absolute; inset: 0; z-index: 2;
  pointer-events: none;
  /* background set by JS from admin config */
}

/* EQ canvas — anchored to bottom of hero, full width, 55% of card height */
.bs-eq-wrap   { position: absolute; bottom: 0; left: 0; right: 0; height: 55%; z-index: 3; pointer-events: none; }
.bs-eq-canvas { position: absolute; bottom: 0; left: 0; width: 100%; height: 100%; display: block; }

/* ── Hero Top row — status left, like right ──────────────────────────────── */
.hero__top {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
}
.hero__crumb, .bs-status {
  font-size: 11px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--fg-1); display: flex; align-items: center; gap: 5px;
}
.dot, .bs-pulse {
  width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0;
  background: var(--accent); box-shadow: 0 0 10px var(--accent);
  animation: bsPulse 1.4s ease-in-out infinite;
}
@keyframes bsPulse { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:.4;transform:scale(.7)} }

.hero__topActions { display: flex; gap: 8px; align-items: center; }

/* ── Hero Meta ────────────────────────────────────────────────────────── */
.hero__meta { margin-top: auto; padding-top: 28px; }
.hero__title {
  font-family: var(--bs-font-display, inherit) !important;
  font-size: clamp(1.6rem, 5vw, 2.6rem);
  font-weight: 700; letter-spacing: -.025em; line-height: 1.15;
  /* Tight shadow — close blur so it hugs the letterforms */
  text-shadow: 0 1px 3px rgba(0,0,0,1), 0 2px 6px rgba(0,0,0,.85);
  white-space: nowrap; overflow: visible; text-overflow: clip;
  padding-bottom: 0.1em; /* room for descenders */
}
/* bs-title alias */
.bs-title { font-family: var(--bs-font-display, inherit) !important; font-size: clamp(1.3rem,5vw,1.9rem); font-weight: 700; line-height: 1.1; letter-spacing: -0.02em; margin-bottom: 0.25rem; text-shadow: 0 2px 14px rgba(0,0,0,.8); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.hero__artist {
  display: flex; align-items: center; gap: 8px;
  margin-top: -8px; margin-left: 5px;color: var(--fg-1); font-size: 16px;
}
.avatar {
  width: 22px; height: 22px; border-radius: 50%; flex-shrink: 0;
  background: linear-gradient(135deg, #f472b6, #a78bfa);
  border: 1.5px solid rgba(255,255,255,.2);
}
/* bs-artist alias */
.bs-artist { font-family: var(--bs-font-body, inherit); font-size: 0.78rem; color: var(--fg-1); }

/* ── Hero Transport ───────────────────────────────────────────────────── */
.hero__transport { display: flex; flex-direction: column; gap: 14px; margin-top: 18px; }

/* Scrubber */
.scrub { display: flex; align-items: center; gap: 12px; }
.t { font-size: 11px; font-variant-numeric: tabular-nums; color: var(--fg-2); min-width: 34px; }
.t--cur { }
.t--dur { text-align: right; }

.scrub__bar {
  position: relative; flex: 1; height: 4px;
  background: rgba(255,255,255,.12); border-radius: 99px;
  cursor: pointer;
}
.scrub__fill, .bs-prog-fill {
  position: absolute; inset: 0 auto 0 0;
  border-radius: inherit; background: var(--accent);
  pointer-events: none;
}
.scrub__knob {
  position: absolute; top: 50%; transform: translate(-50%,-50%);
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(255,255,255,.06);
  opacity: 0; transition: opacity .15s; pointer-events: none;
}
.scrub__bar:hover .scrub__knob { opacity: 1; }
.scrub__input {
  position: absolute; inset: -14px 0; opacity: 0; width: 100%;
  cursor: pointer; -webkit-appearance: none;
}

/* Controls */
.controls {
  display: flex; align-items: center; justify-content: center; gap: 6px;
}
/* New design .ctl */
.ctl {
  position: relative; width: 38px; height: 38px; border-radius: 21px;
  color: var(--fg); display: inline-flex; align-items: center; justify-content: center;
  border: none; background: transparent; cursor: pointer;
  transition: background .12s, transform .12s;
  -webkit-tap-highlight-color: transparent;
  flex-shrink: 0;
}
.ctl:hover { background: rgba(255,255,255,.08); }
.ctl--on { color: var(--accent); }
.ctl--on::after {
  content: ""; position: absolute; bottom: 5px; left: 50%; transform: translateX(-50%);
  width: 4px; height: 4px; border-radius: 50%; background: var(--accent);
}
.ctl--play {
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--accent); color: var(--accent-ink);
  box-shadow: 0 0 0 1px rgba(255,255,255,.1) inset, 0 8px 24px rgba(34,211,197,.35);
}
.ctl--play:hover { transform: scale(1.04); background: var(--accent); }

/* Old bs-ctrl aliases — kept for JS backward compat */
.bs-ctrl { cursor: pointer; display: inline-flex; align-items: center; justify-content: center; transition: all .15s; flex-shrink: 0; -webkit-tap-highlight-color: transparent; }
.bs-ctrl svg { display: block; }
.bs-ctrl.bs-sm { width: 38px; height: 38px; }
.bs-ctrl.bs-lg { width: 48px; height: 48px; }
.bs-ctrl.bs-on { color: var(--accent); }

/* ── Like pill (card top) ─────────────────────────────────────────────── */
.pill, .bs-card-like {
  display: none; align-items: center; gap: 7px;
  height: 34px; padding: 0 12px; border-radius: 99px;
  background: rgba(0,0,0,.45); border: 1px solid var(--line);
  color: var(--fg); font-weight: 600; font-size: 12.5px;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  cursor: pointer; transition: all .2s;
  -webkit-tap-highlight-color: transparent;
}
.pill:hover, .bs-card-like:hover { background: rgba(0,0,0,.65); }
.pill--on, .bs-card-like.liked {
  background: color-mix(in oklab, var(--accent) 12%, rgba(0,0,0,.45));
  border-color: color-mix(in oklab, var(--accent) 50%, transparent);
  color: var(--accent);
}
.bs-card-like.visible { display: flex; }
/* Heart icon (card + row) — text-character, replaces old SVG */
.bs-card-like .bs-like-icon {
  display: inline-block; font-size: 15px; line-height: 1;
  transition: transform .25s cubic-bezier(.34,1.56,.64,1);
}
.bs-card-like.liked .bs-like-icon { transform: scale(1.25); }
@keyframes bsHeartPop { 0%{transform:scale(1)} 40%{transform:scale(1.7)} 70%{transform:scale(.9)} 100%{transform:scale(1.25)} }
.bs-card-like.pop .bs-like-icon { animation: bsHeartPop .4s ease forwards; }
/* Row like icon sizing */
.row__like .bs-like-icon { font-size: 16px; line-height: 1; }

/* Icon buttons (top-right card actions) */
.iconBtn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 10px;
  background: rgba(255,255,255,.06); color: var(--fg);
  border: 1px solid var(--line); cursor: pointer;
  transition: background .15s, border-color .15s;
  -webkit-tap-highlight-color: transparent;
}
.iconBtn:hover { background: rgba(255,255,255,.12); border-color: var(--line-2); }
.iconBtn--ghost { background: rgba(0,0,0,.25); color: var(--fg); }
.iconBtn--ghost:hover { background: rgba(0,0,0,.4); }
.iconBtn--sm { width: 30px; height: 30px; border-radius: 8px; }
/* bs-card-action-btn — solid accent fill, dark icon */
.bs-card-action-btn {
  width: 34px; height: 34px; border-radius: 10px;
  background: var(--accent) !important;
  border-color: var(--accent) !important;
  color: var(--accent-ink) !important;
}
.bs-card-action-btn:hover { filter: brightness(1.12); }

/* ── Lyrics ───────────────────────────────────────────────────────────── */
.bs-lyrics-wrap {
  text-align: center; pointer-events: none;
  padding: 0 1rem; margin-top: 14px; min-height: 1.6em;
}
.bs-lyrics-line {
  display: block; color: #fff;
  font-family: var(--bs-font-body, inherit);
  font-size: clamp(.88rem, 3.5vw, 1.05rem);
  font-weight: 600; line-height: 1.5; word-break: break-word;
  text-align: center;
  text-shadow: 0 0 6px rgba(0,0,0,1), 0 1px 3px rgba(0,0,0,1), 0 2px 10px rgba(0,0,0,.9);
  transition: opacity .25s;
}
.bs-lyrics-line.fade { opacity: 0; }

/* ── Tracklist ────────────────────────────────────────────────────────── */
.list { margin-top: 20px; flex: 1; }

.rows { font-size: 13.5px; }

/* Simplified grid for music player: lead | title+artist | like | time | actions */
.rows__header, .row {
  display: grid;
  grid-template-columns: 36px 1fr 32px 50px auto;
  align-items: center;
  column-gap: 12px;
  padding: 0 10px;
}
.rows__header {
  height: 32px;
  font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--fg-3);
  border-bottom: 1px solid var(--line);
}

.row {
  position: relative; border-radius: 8px; cursor: default;
  color: var(--fg-1); transition: background .12s ease;
  height: 52px;
}
.row + .row { border-top: 1px solid var(--line); }
.row:hover { background: rgba(255,255,255,.035); }
.row:hover + .row { border-top-color: transparent; }
.row:hover { border-top-color: transparent !important; }

.row--current {
  background: linear-gradient(90deg, color-mix(in oklab, var(--accent) 10%, transparent), transparent 70%);
  border-top-color: transparent;
}
.row--current::before {
  content: ""; position: absolute; left: 0; top: 8px; bottom: 8px;
  width: 2px; border-radius: 2px; background: var(--accent);
}
.row--current + .row { border-top-color: transparent; }

/* Lead cell: shows track number, play icon on hover, EQ animation when playing */
.row__lead {
  display: flex; align-items: center; justify-content: center; height: 100%;
  color: var(--fg-3); font-variant-numeric: tabular-nums; font-size: 12.5px;
}

/* EQ animation — shown in .row--current when playing */
.eq {
  display: none; align-items: flex-end; gap: 2px; height: 14px; color: var(--accent);
}
.row--current .eq { display: inline-flex; }
.row--current .row__num { display: none; }
.eq span {
  width: 2px; background: currentColor; border-radius: 1px;
  height: 100%; transform-origin: bottom;
  animation: eqBar 900ms ease-in-out infinite;
}
.eq span:nth-child(1){animation-delay:-100ms}
.eq span:nth-child(2){animation-delay:-300ms}
.eq span:nth-child(3){animation-delay:-500ms}
.eq span:nth-child(4){animation-delay:-700ms}
@keyframes eqBar {
  0%,100%{transform:scaleY(.35)}
  50%{transform:scaleY(1)}
}

/* Title cell */
.row__title { min-width: 0; display: flex; flex-direction: column; gap: 0; }
.row__name {
  font-family: var(--bs-font-display, inherit) !important;
  color: var(--fg); font-weight: 500; letter-spacing: -.005em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  line-height: 1.2;
}
.row--current .row__name { color: var(--accent); }
.row__artist {
  color: var(--fg-2); font-size: 11.5px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  line-height: 1.2; margin-top: 1px;
}

/* Like button (per row) — always visible at 65%, full on current/hover */
.row__like {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; border-radius: 6px;
  opacity: 0.65; transition: opacity .15s ease, background .15s, color .15s;
  color: var(--fg-3); border: none; background: transparent; cursor: pointer;
  transition: all .15s; -webkit-tap-highlight-color: transparent;
}
.row:hover .row__like,
.row--current .row__like { opacity: 1; }
.row__like:hover { background: rgba(255,255,255,.06); color: var(--fg-1); }
.row__like--on { color: var(--accent); }
.row__like--on:hover { background: color-mix(in oklab, var(--accent) 14%, transparent); }

/* Duration */
.row__time {
  color: var(--fg-2); font-variant-numeric: tabular-nums;
  font-size: 12.5px; text-align: right;
}

/* Actions (info, share, download) — always visible at 65%, full on current/hover */
.row__actions {
  display: flex; gap: 2px; align-items: center; justify-content: flex-end;
  opacity: 0.65; transition: opacity .15s ease;
}
.row:hover .row__actions, .row--current .row__actions { opacity: 1; }
.row__actions .iconBtn {
  background: transparent; border-color: transparent; color: var(--fg-2);
  width: 28px; height: 28px;
}
.row__actions .iconBtn:hover {
  background: rgba(255,255,255,.1); color: var(--fg); border-color: transparent;
}

/* ── Empty state ──────────────────────────────────────────────────────── */
.bs-empty { text-align: center; padding: 3rem 1rem; color: var(--fg-2); }
.bs-empty p { font-size: 0.85rem; margin-top: 0.5rem; line-height: 1.6; }

/* ── Donate section ───────────────────────────────────────────────────── */
.bs-donate-wrap {
  margin-top: 1.5rem;
  display: flex; flex-direction: column; align-items: center;
  gap: 0.85rem; width: 100%;
}
.bs-donate-caption {
  font-family: var(--bs-font-body, inherit);
  font-size: 0.95rem; color: var(--fg-1);
  text-align: center; letter-spacing: .02em;
  margin: 0; line-height: 1.55; display: block; width: 100%;
}
.bs-donate-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  background: var(--accent);
  border: 1.5px solid var(--accent); color: #fff;
  border-radius: 999px; padding: 13px 24px;
  font-family: var(--bs-font-body, inherit); font-size: .88rem; font-weight: 500;
  cursor: pointer; transition: all .2s; -webkit-tap-highlight-color: transparent;
  width: 100%; max-width: 400px; text-align: center; line-height: 1.4;
  word-break: break-word;
}
.bs-donate-btn:hover  { background: #2a2a2a; border-color: #2a2a2a; color: #fff; transform: translateY(-1px); }
.bs-donate-btn:active { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ── EQ mode buttons ──────────────────────────────────────────────────── */
.bs-tracklist-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: .75rem; }
.bs-eq-modes { display: none; gap: 4px; }
.bs-eq-modes.visible { display: flex; }
.bs-eq-mode-btn {
  font-size: .58rem; letter-spacing: .08em; text-transform: uppercase;
  padding: 5px 10px; background: var(--bg-2); border: 1px solid var(--line);
  border-radius: 5px; color: var(--fg-3); cursor: pointer; transition: all .15s;
}
.bs-eq-mode-btn:hover { border-color: var(--accent); color: var(--accent); }
.bs-eq-mode-btn.active { background: var(--bs-adim); border-color: var(--accent); color: var(--accent); }
.bs-section-label.side__section { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--fg-3); }

/* ── Modals ───────────────────────────────────────────────────────────── */
.bs-modal-overlay {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,.8);
  display: flex; align-items: center; justify-content: center;
  z-index: 99999;
  opacity: 0; pointer-events: none;
  transition: opacity .25s;
  transform: translateZ(0);
  padding: 1rem;
  box-sizing: border-box;
}
.bs-modal-overlay.open { opacity: 1; pointer-events: all; }
.bs-modal {
  position: relative;
  background: #18181d;
  border: 1px solid rgba(255,255,255,.22);
  border-radius: 20px;
  padding: 1.5rem 1.25rem;
  width: 100%; max-width: 520px;
  transform: translateY(16px);
  opacity: 0;
  transition: transform .3s cubic-bezier(.32,.72,0,1), opacity .25s;
  font-family: var(--bs-font-body, inherit);
  max-height: calc(100vh - 2rem); overflow-y: auto; -webkit-overflow-scrolling: touch;
  box-sizing: border-box;
}
.bs-modal-overlay.open .bs-modal { transform: translateY(0); opacity: 1; }
.bs-modal-handle { display: none; }
.bs-modal-title  { font-family: var(--bs-font-display, inherit) !important; font-size: 1.15rem; font-weight: 700; color: var(--fg); margin-bottom: .2rem; }
.bs-modal-sub    { font-size: .75rem; color: var(--fg-2); margin-bottom: 1.25rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bs-modal-x {
  position: absolute; top: 1rem; right: 1rem;
  background: var(--bg-3); border: 1px solid var(--line);
  color: var(--fg-2); border-radius: 50%;
  width: 30px !important; height: 30px !important; min-width: 30px !important; min-height: 30px !important;
  padding: 0 !important; font-size: .8rem; line-height: 1; box-sizing: border-box !important;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: all .15s; flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
}
.bs-modal-x:hover { background: rgba(34,211,197,.2); color: var(--accent); border-color: var(--accent); }
.bs-modal-close {
  width: 100%; background: transparent; border: 1px solid var(--line);
  color: var(--fg-2); border-radius: var(--radius-sm);
  padding: 13px; font-family: var(--bs-font-body, inherit);
  font-size: .78rem; cursor: pointer; transition: all .15s; margin-top: .5rem;
}
.bs-modal-close:hover { background: var(--bg-3); color: var(--fg); border-color: var(--line-2); }

/* Share modal */
.bs-share-link-box { display: flex; gap: 8px; margin-bottom: 1.25rem; }
.bs-share-link-box input {
  flex: 1; min-width: 0; background: var(--bg-2); border: 1px solid var(--line);
  color: var(--fg-2); border-radius: var(--radius-sm);
  padding: 11px 12px; font-size: .7rem; outline: none;
}
.bs-copy-btn {
  background: var(--accent); color: var(--accent-ink); border: none;
  border-radius: var(--radius-sm); padding: 11px 16px;
  font-size: .72rem; font-weight: 500; cursor: pointer; white-space: nowrap; flex-shrink: 0;
}
.bs-copy-btn:hover  { filter: brightness(1.1); }
.bs-copy-btn.copied { background: #3aaa6e; color: #fff; }
.bs-social-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 8px; margin-bottom: 1.25rem; }
.bs-social-btn  {
  background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 14px 6px; display: flex; flex-direction: column; align-items: center;
  gap: 7px; font-size: .6rem; color: var(--fg-2); cursor: pointer;
  -webkit-tap-highlight-color: transparent; transition: all .15s;
}
.bs-social-btn:hover { background: var(--bg-3); color: var(--fg); }
.bs-social-btn svg { width: 22px; height: 22px; display: block; }

/* Info modal */
.bs-info-modal-inner { display: flex; gap: 1.75rem; align-items: flex-start; }
#bs-info-thumb-wrap { flex-shrink: 0; }
.bs-info-thumb { width: 180px; border-radius: 10px; overflow: hidden; background: var(--bg-3); }
.bs-info-thumb img { width: 100%; height: auto; display: block; border-radius: 10px; }
.bs-info-thumb-placeholder { width: 180px; height: 180px; display: flex; align-items: center; justify-content: center; font-size: 3rem; color: var(--fg-2); background: var(--bg-3); border-radius: 10px; }
.bs-info-body  { flex: 1; min-width: 0; }
.bs-info-title  { font-family: var(--bs-font-display, inherit) !important; font-size: 1.4rem; font-weight: 700; color: var(--fg); margin-bottom: .25rem; line-height: 1.2; }
.bs-info-artist { font-size: .82rem; color: var(--accent); margin-bottom: .4rem; letter-spacing: .04em; text-transform: uppercase; }
.bs-info-meta   { font-size: .72rem; color: var(--fg-2); margin-bottom: 1rem; }
.bs-info-divider{ height: 1px; background: var(--line); margin: .85rem 0; }
.bs-info-notes  { font-size: .85rem; color: var(--fg-1); line-height: 1.75; word-break: break-word; }
.bs-info-notes p { margin: 0 0 .75em; }
.bs-info-notes p:last-child { margin-bottom: 0; }
.bs-info-notes strong, .bs-info-notes b { color: var(--fg); font-weight: 600; }
.bs-info-notes em, .bs-info-notes i { font-style: italic; }
.bs-info-notes a { color: var(--accent); text-decoration: underline; }
.bs-info-notes a:hover { filter: brightness(1.15); }
.bs-info-empty  { font-size: .82rem; color: var(--fg-2); font-style: italic; }

/* Download modal */
.bs-dl-modal-body { text-align: center; padding: .5rem 0 .25rem; }
.bs-dl-modal-thumb {
  width: 90px; height: 90px; border-radius: 10px; overflow: hidden;
  background: var(--bg-3); margin: 0 auto 1rem;
  display: flex; align-items: center; justify-content: center; font-size: 2.2rem;
}
.bs-dl-modal-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 10px; }
.bs-dl-modal-msg { font-size: .82rem; color: var(--fg-2); line-height: 1.6; margin-bottom: 1.5rem; }
.bs-dl-donate-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%;
  background: var(--accent); color: #fff;
  border: 2px solid var(--accent); border-radius: 999px; padding: 14px 24px;
  font-size: .92rem; font-weight: 700; cursor: pointer; transition: all .2s;
  word-break: break-word; line-height: 1.4; margin-bottom: .75rem;
}
.bs-dl-donate-btn:hover  { background: #2a2a2a; border-color: #2a2a2a; color: #fff; }
.bs-dl-donate-btn:active { background: var(--accent); border-color: var(--accent); color: #fff; }
.bs-dl-reveal-btn {
  display: none; align-items: center; justify-content: center; gap: 8px;
  width: 100%; background: var(--accent); color: var(--accent-ink);
  border: none; border-radius: 999px; padding: 13px 24px;
  font-size: .88rem; font-weight: 500; cursor: pointer; transition: all .2s; margin-bottom: .75rem;
}
.bs-dl-reveal-btn.show { display: flex; }
.bs-dl-reveal-btn:hover { filter: brightness(1.1); }
.bs-dl-honesty { font-size: .68rem; color: var(--fg-2); margin-bottom: 1rem; line-height: 1.5; }
.bs-dl-honesty a { color: var(--fg-2); text-decoration: underline; cursor: pointer; }
.bs-dl-honesty a:hover { color: var(--fg); }

/* ── Toast ────────────────────────────────────────────────────────────── */
.bs-toast {
  position: fixed; bottom: calc(1.5rem + env(safe-area-inset-bottom));
  left: 50%; transform: translateX(-50%) translateY(20px);
  background: var(--accent); color: var(--accent-ink);
  font-size: .75rem; font-weight: 500; padding: 10px 20px;
  border-radius: 999px; opacity: 0; transition: all .25s;
  z-index: 100000; white-space: nowrap; pointer-events: none;
}
.bs-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── Mini Player ──────────────────────────────────────────────────────── */
.bs-mini {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 99998;
  background: #0a0b0e; border-top: 1px solid rgba(255,255,255,.12);
  box-shadow: 0 -4px 24px rgba(0,0,0,.55);
  transform: translateY(100%);
  transition: transform .35s cubic-bezier(.32,.72,0,1);
  padding-bottom: env(safe-area-inset-bottom, 0px);
  --bs-accent: #22d3c5; --accent: #22d3c5; --accent-ink: #0a0b0e;
  --fg: #f5f6f8; --fg-2: rgba(245,246,248,.55); --bg-3: #1d2230;
}
.bs-mini.visible { transform: translateY(0); }
.bs-mini-progress { position: absolute; top: 0; left: 0; right: 0; height: 2px; background: rgba(255,255,255,.08); }
.bs-mini-prog-fill { height: 100%; width: 0%; background: var(--accent); transition: width .25s linear; }
.bs-mini-inner {
  display: flex; align-items: center; gap: 10px; padding: 9px 14px;
  max-width: 820px; margin: 0 auto; box-sizing: border-box; width: 100%;
}
.bs-mini-thumb {
  width: 40px; height: 40px; border-radius: 7px; flex-shrink: 0;
  background: var(--bg-3); overflow: hidden;
  display: flex; align-items: center; justify-content: center; font-size: 1.1rem; cursor: pointer;
}
.bs-mini-thumb img, .bs-mini-thumb video { width: 100%; height: 100%; object-fit: cover; display: block; }
.bs-mini-info { flex: 1; min-width: 0; overflow: hidden; cursor: pointer; }
.bs-mini-title  { font-size: .82rem; font-weight: 600; color: var(--fg); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bs-mini-artist { font-size: .68rem; color: var(--fg-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
.bs-mini-eq   { width: 64px; height: 28px; flex-shrink: 0; display: none; opacity: .75; }
.bs-mini-controls { display: flex; align-items: center; gap: 2px; flex-shrink: 0; }
.bs-mini-btn {
  background: transparent; border: 1px solid rgba(255,255,255,.18); color: var(--fg);
  width: 38px !important; height: 38px !important; min-width: 38px !important; min-height: 38px !important;
  padding: 0 !important; border-radius: 50%; box-sizing: border-box !important;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: all .15s; -webkit-tap-highlight-color: transparent; flex-shrink: 0;
}
.bs-mini-btn:hover { background: rgba(255,255,255,.08); }
.bs-mini-play {
  background: var(--accent); color: var(--accent-ink); border-color: transparent;
  width: 42px !important; height: 42px !important; min-width: 42px !important; min-height: 42px !important;
}
.bs-mini-play:hover { filter: brightness(1.1); }

/* ── Responsive ───────────────────────────────────────────────────────── */
@media (max-width: 700px) {
  .app { grid-template-columns: 1fr; }
  .side {
    position: relative; height: auto; border-right: 0;
    border-bottom: 1px solid var(--line); flex-direction: row;
    align-items: center; flex-wrap: wrap; gap: 10px;
    padding: 12px 16px; min-height: auto;
  }
  .side__section { display: none; }
  .nav { flex-direction: row; }
  .main { padding: 16px 14px 50px; }
  /* Full-width bleed for mobile (14px side padding) */
  .hero, .bs-card { margin-left: -14px; margin-right: -14px; padding: 16px 14px 16px; min-height: 280px; }
  .hero__title { font-size: clamp(1.4rem, 6vw, 2rem); }
  /* Tracklist: drop lead + time columns — title | ♥ | actions */
  .rows__header, .row { grid-template-columns: 0 1fr 32px 88px !important; }
  .row__lead { overflow: hidden; min-width: 0; padding: 0; }
  .row__time  { display: none !important; }
  .row__like  { display: inline-flex !important; grid-column: 3; }
  /* Keep actions always visible on mobile at same 65% — no hiding */
  .row:not(.row--current) .row__actions { opacity: 0.65 !important; pointer-events: auto; }
  /* Hero card buttons — smaller on mobile */
  .bs-card-like       { height: 28px; padding: 0 9px; font-size: 11px; gap: 5px; }
  .bs-card-like .bs-like-icon { font-size: 13px; }
  .bs-card-action-btn { width: 28px; height: 28px; border-radius: 8px; }
  .bs-card-action-btn svg { width: 12px; height: 12px; }
  .hero__topActions   { gap: 5px; }
  .bs-modal-overlay { align-items: flex-end; }
  .bs-mini-eq { display: none; }
}

@media (min-width: 701px) {
  .bs-mini-eq { display: block; }
  .bs-mini-inner { padding: 10px 24px; gap: 14px; }
  .bs-mini-thumb { width: 46px; height: 46px; }
  .bs-modal-overlay { align-items: center; }
  .bs-modal {
    border-radius: 20px; max-width: 420px; padding: 2rem;
    transform: translateY(20px);
  }
  .bs-modal-overlay.open .bs-modal { transform: translateY(0); }
  .bs-modal-handle { display: none; }
  #bs-info-modal .bs-modal { max-width: 840px; min-height: 520px; }
}

@media (max-width: 600px) {
  .bs-info-modal-inner { flex-direction: column; gap: 1rem; }
  .bs-info-thumb, .bs-info-thumb-placeholder { width: 100%; height: auto; }
  .bs-info-thumb img { width: 100%; max-height: 220px; object-fit: cover; border-radius: 10px; }
  .bs-info-thumb-placeholder { width: 100%; min-height: 140px; }
}
