/* =========================================================
   ROOT DESIGN TOKENS
   ========================================================= */
:root {
  --scene-accent: var(--accent-cyan);
  --scene-glow: rgba(79, 209, 197, 0.35);
  --card-playing-edge: rgba(79, 209, 197, 0.85);
  --card-playing-glow: rgba(79, 209, 197, 0.28);
  --mask-ink: #000;
}

:root {
  --bg-0: #0b0e11;
  --bg-1: #11151a;
  --bg-2: #1a1f26;
  --bg-3: #242b34;

  --panel: #12161c;
  --panel-border: #2a323d;

  --text-primary: #f1f3f5;
  --text-secondary: #a7b0bb;
  --text-muted: #6e7783;

  --accent-ember: #e06c3f;
  --accent-cyan: #4fd1c5;
  --accent-gold: #f2c94c;

  --danger: #ef4444;

  --player-bg: #0b0f14;
  --player-surface: #121821;
  --player-surface-strong: #171f2a;
  --player-border: #263141;
  --player-track: #1f2a38;
  --player-rail: #2b394c;
  --player-thumb: #f2f5f7;
  --player-accent: #4fd1c5;
  --player-accent-strong: #6ef3e3;
  --player-glow: rgba(79, 209, 197, 0.3);
  --player-muted: #7e8794;
  --player-text: #f4f7fb;
  --player-danger: #ef4444;
  --player-offset: 260px;

  --tabs-bar: var(--bg-1);
  --tabs-border: var(--panel-border);
  --tabs-pill: rgba(255, 255, 255, 0.06);
  --tabs-pill-active: rgba(79, 209, 197, 0.2);
  --tabs-pill-text: var(--text-secondary);
  --tabs-pill-text-active: var(--accent-cyan);
  --tabs-panel: var(--panel);
  --tabs-card-bg: var(--bg-2);
  --tabs-card-border: var(--panel-border);
  --tabs-card-highlight: rgba(79, 209, 197, 0.2);
  --tabs-card-muted: var(--text-muted);
  --tabs-panel-shadow: rgba(0, 0, 0, 0.5);
  --tabs-card-shadow: rgba(0, 0, 0, 0.4);
  --tabs-icon: #e4e8ee;

  --board-header-bg: var(--bg-2);
  --board-section-bg: var(--bg-1);
  --board-border: var(--panel-border);
  --board-empty-bg: rgba(0, 0, 0, 0.2);
  --board-title-overlay: linear-gradient(180deg, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.7));
  --board-row-bg: rgba(12, 18, 24, 0.6);
  --board-row-hover: rgba(12, 18, 24, 0.85);
  --board-row-border: rgba(255, 255, 255, 0.06);
  --board-remove-bg: rgba(8, 12, 16, 0.7);
  --board-remove-border: rgba(255, 255, 255, 0.12);
  --board-picker-bg: var(--overlay-panel);
  --board-picker-border: var(--overlay-border);
  --board-picker-list-bg: rgba(9, 13, 18, 0.6);
  --board-picker-row-hover: rgba(79, 209, 197, 0.08);

  --filter-input-bg: rgba(0, 0, 0, 0.35);
  --cover-empty-bg: rgba(0, 0, 0, 0.25);

  --overlay-backdrop: rgba(7, 9, 12, 0.78);
  --overlay-panel: #151b24;
  --overlay-border: #2b3645;
  --overlay-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  --progress-track: #1f2a38;
  --progress-fill: var(--accent-cyan);

  --app-bg-accent: #141922;
  --app-bg-base: var(--bg-0);
  --header-bg-top: #0f141b;
  --header-bg-bottom: #0b0e11;
  --button-bg-top: #1e2530;
  --button-bg-bottom: #151a22;
  --button-bg-hover-top: #252d39;
  --button-bg-hover-bottom: #1a2029;
  --scrollbar-thumb: #2a323d;

  --card-sheen-top: rgba(255, 255, 255, 0.04);
  --card-sheen-bottom: rgba(255, 255, 255, 0.01);
  --card-surface-top: #1a2029;
  --card-surface-bottom: #12161c;
  --image-wrap-top: rgba(0, 0, 0, 0.2);
  --image-wrap-bottom: rgba(0, 0, 0, 0.6);
  --image-wrap-border: rgba(255, 255, 255, 0.04);
  --image-placeholder-bg: rgba(6, 10, 14, 0.45);
  --image-action-border: rgba(255, 255, 255, 0.15);
  --image-action-bg: rgba(10, 14, 18, 0.75);
  --queue-btn-bg: rgba(10, 14, 18, 0.7);
  --card-hover-shadow: 0 12px 28px rgba(0, 0, 0, 0.6);

  --meta-input-bg: rgba(0, 0, 0, 0.35);
  --dialog-confirm-top: #22303e;
  --dialog-confirm-bottom: #1a242f;
  --menu-shadow: 0 16px 36px rgba(0, 0, 0, 0.45);
  --landing-shell-bg: linear-gradient(
    135deg,
    rgba(18, 24, 33, 0.96),
    rgba(12, 16, 22, 0.98)
  );
  --landing-shell-border: rgba(79, 209, 197, 0.18);
  --landing-shell-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  --landing-shell-glow: rgba(79, 209, 197, 0.2);
  --landing-shell-border-strong: rgba(79, 209, 197, 0.6);
  --landing-card-bg: linear-gradient(160deg, rgba(26, 31, 38, 0.9), rgba(14, 18, 24, 0.95));
  --landing-card-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
  --landing-bg-accent-a: rgba(79, 209, 197, 0.15);
  --landing-bg-accent-b: rgba(224, 108, 63, 0.18);

  --tab-cover-placeholder-bg: rgba(6, 10, 14, 0.5);

  --player-shadow: 0 -20px 60px rgba(3, 7, 12, 0.75);
  --player-shell-top: rgba(18, 24, 33, 0.9);
  --player-shell-bottom: rgba(12, 16, 22, 0.95);
  --player-control-top: var(--player-surface-strong);
  --player-control-bottom: #0f141b;
  --player-control-ring: 0 0 0 2px rgba(79, 209, 197, 0.16);
  --player-play-top: #1b2531;
  --player-play-bottom: #0f141b;
  --player-play-shadow: 0 10px 26px rgba(0, 0, 0, 0.4);
  --player-thumb-ring: 0 0 0 4px rgba(79, 209, 197, 0.2);
  --player-ring: 0 0 0 2px rgba(79, 209, 197, 0.2);
  --player-ring-strong: 0 0 0 2px rgba(79, 209, 197, 0.25);
  --queue-panel-top: rgba(10, 14, 18, 0.96);
  --queue-panel-bottom: rgba(7, 9, 12, 0.98);
  --queue-panel-shadow: 0 16px 32px rgba(3, 7, 12, 0.45);
  --queue-item-bg: rgba(18, 24, 33, 0.4);
  --queue-item-active-bg: rgba(18, 32, 38, 0.85);
  --queue-item-active-edge: rgba(79, 209, 197, 0.9);
  --queue-item-next-bg: rgba(14, 24, 30, 0.7);
  --queue-item-drop: rgba(79, 209, 197, 0.6);
  --player-panel-bg: rgba(12, 18, 24, 0.95);
  --player-panel-shadow: 0 12px 24px rgba(3, 7, 12, 0.35);
  --player-volume-bg: rgba(12, 18, 24, 0.7);

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;

  --transition-fast: 120ms ease;
  --transition-med: 220ms ease;
}

/* =========================================================
   BASE RESET
   ========================================================= */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: radial-gradient(circle at top, var(--app-bg-accent), var(--app-bg-base));
  color: var(--text-primary);
  overflow: hidden;
}

#app {
  height: 100%;
  display: flex;
  flex-direction: column;
  padding-bottom: 0;
}

/* =========================================================
   APP LAYOUT
   ========================================================= */

header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: linear-gradient(to bottom, var(--header-bg-top), var(--header-bg-bottom));
  border-bottom: 1px solid var(--panel-border);
}

.app-brand {
  font-size: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

main {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: 16px;
  padding-bottom: calc(16px + var(--player-offset));
}

/* =========================================================
   BUTTONS
   ========================================================= */

button {
  background: linear-gradient(to bottom, var(--button-bg-top), var(--button-bg-bottom));
  color: var(--text-primary);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-sm);
  padding: 8px 14px;
  font-size: 13px;
  cursor: pointer;
  transition: background var(--transition-fast),
              border var(--transition-fast),
              transform var(--transition-fast);
}

button:hover {
  background: linear-gradient(to bottom, var(--button-bg-hover-top), var(--button-bg-hover-bottom));
  border-color: var(--accent-cyan);
}

button:active {
  transform: translateY(1px);
}

/* =========================================================
   SOUND CARDS
   ========================================================= */

.card {
  position: relative;
  display: inline-flex;
  flex-direction: column;
  justify-content: space-between;
  width: 140px;
  height: 140px;
  margin: 8px;
  padding: 10px;
  background: linear-gradient(to bottom right, var(--card-surface-top), var(--card-surface-bottom));
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: transform var(--transition-med),
              border var(--transition-med),
              box-shadow var(--transition-med);
}

.card:hover {
  transform: translateY(-3px);
  border-color: var(--accent-ember);
  box-shadow: var(--card-hover-shadow);
}

.card img {
  width: 100%;
  height: 72px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  margin-bottom: 6px;
}

.card span {
  text-align: center;
  color: var(--text-secondary);
}

/* =========================================================
   SCROLLBARS
   ========================================================= */

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-thumb {
  background: var(--scrollbar-thumb);
  border-radius: 10px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

/* =========================================================
   UTILITIES
   ========================================================= */

.hidden {
  display: none !important;
}
