/* ==========================================================================
   VishvaX v1.0.0 - Design System & Modern Aesthetics
   Obsidian Dark Mode, Neon Violet/Cyan Accents, Glassmorphism
   ========================================================================== */

:root {
  /* VishvaX Obsidian Dark Theme Color Palette */
  --bg-dark: #07080e;
  --bg-surface: #10121d;
  --bg-surface-elevated: #161928;
  --bg-surface-highlight: #1f2338;
  --bg-glass: rgba(16, 18, 29, 0.85);
  --bg-glass-heavy: rgba(22, 25, 40, 0.96);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(16, 185, 129, 0.4);

  /* VishvaX Restrained Teal-Green Accents */
  --accent-teal: #10b981;
  --accent-teal-hover: #34d399;
  --accent-teal-active: #059669;
  --accent-teal-subtle: rgba(16, 185, 129, 0.12);
  --accent-teal-glow: rgba(16, 185, 129, 0.35);
  --accent-gradient: linear-gradient(135deg, #10b981 0%, #059669 100%);
  --accent-gradient-glow: linear-gradient(135deg, #10b981 0%, #14b8a6 100%);
  --accent-gradient-subtle: linear-gradient(135deg, rgba(16, 185, 129, 0.18) 0%, rgba(5, 150, 105, 0.18) 100%);

  /* Backward Compatibility Aliases for components */
  --spotify-green: #10b981;
  --spotify-green-hover: #34d399;
  --spotify-green-active: #059669;
  --spotify-black: #07080e;
  --spotify-dark-grey: #10121d;
  --spotify-grey: #161928;
  --spotify-light-grey: #94a3b8;
  --spotify-white: #ffffff;

  --accent-violet: #10b981;
  --accent-purple: #10b981;
  --accent-cyan: #14b8a6;
  --accent-magenta: #ec4899;

  /* Typography Colors */
  --text-primary: #ffffff;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-dim: #475569;

  /* Sizing & Transitions */
  --sidebar-width: 250px;
  --player-height: 86px;
  --header-height: 72px;
  --mobile-nav-height: 64px;
  --mobile-player-height: 58px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  --radius-full: 9999px;

  --transition-fast: 0.15s ease;
  --transition-normal: 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.35s cubic-bezier(0.16, 1, 0.3, 1);

  --font-main: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

/* AMOLED Ultra Pitch-Black Dark Mode */
body.theme-amoled {
  --bg-dark: #000000;
  --bg-surface: #09090c;
  --bg-surface-elevated: #111115;
  --bg-surface-highlight: #18181e;
  --bg-glass: rgba(0, 0, 0, 0.92);
  --bg-glass-heavy: rgba(0, 0, 0, 0.98);
  --border-subtle: rgba(255, 255, 255, 0.12);
  --border-glow: rgba(16, 185, 129, 0.5);
  background-color: #000000 !important;
}

/* ==========================================================================
   THEME SELECTION SYSTEM (VISUAL CARDS & PREVIEWS)
   ========================================================================== */
.theme-picker-container {
  width: 100%;
  margin-top: 10px;
}
.theme-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 12px;
  width: 100%;
}
.theme-card-option {
  background: var(--bg-surface-elevated);
  border: 2px solid var(--border-subtle);
  border-radius: 12px;
  padding: 10px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  outline: none;
  user-select: none;
  position: relative;
}
.theme-card-option:hover {
  transform: translateY(-2px);
  border-color: rgba(16, 185, 129, 0.4);
}
.theme-card-option.active {
  border-color: var(--accent-teal);
  background: rgba(16, 185, 129, 0.08);
  box-shadow: 0 0 16px rgba(16, 185, 129, 0.2);
}
.theme-preview-box {
  width: 100%;
  height: 52px;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.preview-obsidian {
  background: #07080e;
}
.preview-obsidian .theme-preview-topbar {
  height: 10px;
  background: #10121d;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.preview-obsidian .theme-preview-body {
  flex: 1;
  padding: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.preview-obsidian .theme-preview-card {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  background: #161928;
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.preview-obsidian .theme-preview-accent {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
}

.preview-amoled {
  background: #000000;
  border-color: rgba(255, 255, 255, 0.12);
}
.preview-amoled .theme-preview-topbar {
  height: 10px;
  background: #0a0a0a;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.preview-amoled .theme-preview-body {
  flex: 1;
  padding: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.preview-amoled .theme-preview-card {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  background: #111111;
  border: 1px solid rgba(255, 255, 255, 0.15);
}
.preview-amoled .theme-preview-accent {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
}

.preview-light {
  background: #f8fafc;
  border-color: rgba(0, 0, 0, 0.1);
}
.preview-light .theme-preview-topbar {
  height: 10px;
  background: #ffffff;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
.preview-light .theme-preview-body {
  flex: 1;
  padding: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.preview-light .theme-preview-card {
  width: 24px;
  height: 24px;
  border-radius: 4px;
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}
.preview-light .theme-preview-accent {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #059669;
}

.preview-system {
  display: flex;
  flex-direction: row;
}
.preview-system .theme-preview-split-left {
  flex: 1;
  height: 100%;
  background: #07080e;
  border-right: 1px solid rgba(255, 255, 255, 0.1);
}
.preview-system .theme-preview-split-right {
  flex: 1;
  height: 100%;
  background: #f8fafc;
}

.theme-card-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.theme-card-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.theme-card-sub {
  font-size: 0.70rem;
  color: var(--text-secondary);
  line-height: 1.2;
}
.theme-active-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: transparent;
  transition: all 0.2s ease;
}
.theme-card-option.active .theme-active-dot {
  background: var(--accent-teal);
  box-shadow: 0 0 8px var(--accent-teal);
}

/* Header Quick Theme Toggle */
.header-theme-btn {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  cursor: pointer;
  transition: all var(--transition-fast);
}
.header-theme-btn:hover {
  border-color: var(--accent-teal);
  transform: scale(1.05);
  background: var(--bg-surface-highlight);
}
.header-theme-btn:active {
  transform: scale(0.95);
}

/* ==========================================================================
   COMPREHENSIVE MODERN PORCELAIN LIGHT MODE (ALL SCREENS & COMPONENTS)
   ========================================================================== */
body.theme-light {
  --bg-dark: #f8fafc;
  --bg-surface: #ffffff;
  --bg-surface-elevated: #f1f5f9;
  --bg-surface-highlight: #e2e8f0;
  --bg-glass: rgba(255, 255, 255, 0.92);
  --bg-glass-heavy: rgba(255, 255, 255, 0.98);
  --border-subtle: #e2e8f0;
  --border-glow: rgba(16, 185, 129, 0.4);

  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;
  --text-dim: #94a3b8;
  background-color: #f8fafc !important;
  color: #0f172a !important;
}

body.theme-light .app-container {
  background: radial-gradient(circle at 10% 20%, rgba(16, 185, 129, 0.05) 0%, transparent 40%),
              radial-gradient(circle at 90% 80%, rgba(20, 184, 166, 0.05) 0%, transparent 40%),
              #f8fafc !important;
}
body.theme-light .app-header {
  background: rgba(255, 255, 255, 0.9) !important;
  border-bottom: 1px solid #e2e8f0 !important;
  backdrop-filter: blur(20px);
}
body.theme-light .app-sidebar {
  background: #ffffff !important;
  border-right: 1px solid #e2e8f0 !important;
}
body.theme-light .desktop-player-bar {
  background: rgba(255, 255, 255, 0.97) !important;
  border-top: 1px solid #e2e8f0 !important;
  box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.06);
}
body.theme-light .bottom-nav {
  background: rgba(255, 255, 255, 0.96) !important;
  border-top: 1px solid #e2e8f0 !important;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.05);
}

body.theme-light h1,
body.theme-light h2,
body.theme-light h3,
body.theme-light h4,
body.theme-light .view-main-title,
body.theme-light .section-title,
body.theme-light .greeting-user,
body.theme-light .hero-title,
body.theme-light .details-title,
body.theme-light .artist-name,
body.theme-light .library-title,
body.theme-light .liked-title,
body.theme-light .modal-title,
body.theme-light .profile-name,
body.theme-light .auth-title,
body.theme-light .drawer-title,
body.theme-light .drawer-song-title,
body.theme-light .expanded-title,
body.theme-light .expanded-song-title,
body.theme-light .stat-val,
body.theme-light .setting-label,
body.theme-light .settings-group-title,
body.theme-light .brand-name {
  color: #0f172a !important;
}

body.theme-light .view-sub-desc,
body.theme-light .section-subtitle,
body.theme-light .hero-subtitle,
body.theme-light .details-meta-line,
body.theme-light .details-type-tag,
body.theme-light .artist-listeners,
body.theme-light .liked-stats-text,
body.theme-light .stat-lbl,
body.theme-light .setting-sublabel,
body.theme-light .drawer-song-artist,
body.theme-light .expanded-artist-name,
body.theme-light .sidebar-heading,
body.theme-light .sidebar-playlist-item,
body.theme-light .search-empty-sub {
  color: #64748b !important;
}

body.theme-light .nav-item {
  color: #334155 !important;
}
body.theme-light .nav-item:hover {
  background: #f1f5f9 !important;
  color: #0f172a !important;
}
body.theme-light .nav-item.active {
  background: rgba(16, 185, 129, 0.12) !important;
  color: #059669 !important;
}
body.theme-light .bottom-nav-item {
  color: #64748b !important;
}
body.theme-light .bottom-nav-item.active {
  color: #059669 !important;
}

body.theme-light .hero-card {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.12) 0%, #ffffff 85%) !important;
  border: 1px solid rgba(16, 185, 129, 0.25) !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06) !important;
}
body.theme-light .hero-badge {
  background: rgba(16, 185, 129, 0.15);
  border-color: #059669;
  color: #047857;
}
body.theme-light .hero-secondary-btn {
  background: #ffffff;
  border-color: #cbd5e1;
  color: #0f172a;
}
body.theme-light .hero-secondary-btn:hover {
  background: #f1f5f9;
}

body.theme-light .square-card,
body.theme-light .playlist-card,
body.theme-light .media-card,
body.theme-light .music-card,
body.theme-light .track-card,
body.theme-light .genre-card {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04) !important;
}
body.theme-light .square-card:hover,
body.theme-light .playlist-card:hover,
body.theme-light .media-card:hover,
body.theme-light .music-card:hover,
body.theme-light .track-card:hover {
  background: #f8fafc !important;
  border-color: rgba(16, 185, 129, 0.35) !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08) !important;
}
body.theme-light .square-card-title,
body.theme-light .playlist-card-title,
body.theme-light .media-card-title,
body.theme-light .music-card-title,
body.theme-light .track-card-title {
  color: #0f172a !important;
}
body.theme-light .square-card-subtitle,
body.theme-light .playlist-card-subtitle,
body.theme-light .media-card-sub,
body.theme-light .music-card-subtitle,
body.theme-light .track-card-artist {
  color: #64748b !important;
}
body.theme-light .track-card-badge {
  background: #f1f5f9 !important;
  color: #059669 !important;
  border: 1px solid #d1fae5 !important;
}
body.theme-light .square-card-like-btn svg,
body.theme-light .track-card-heart svg {
  stroke: #64748b;
}

body.theme-light .pill-item,
body.theme-light .lib-tab-pill {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  color: #334155 !important;
}
body.theme-light .pill-item:hover,
body.theme-light .lib-tab-pill:hover {
  background: #f1f5f9 !important;
  color: #0f172a !important;
}
body.theme-light .pill-item.active,
body.theme-light .lib-tab-pill.active {
  background: var(--accent-teal) !important;
  color: #ffffff !important;
  border-color: var(--accent-teal) !important;
}

body.theme-light .search-input-box,
body.theme-light .view-search-box {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04) !important;
}
body.theme-light .search-input-box input,
body.theme-light .view-search-box input {
  color: #0f172a !important;
}
body.theme-light .search-input-box input::placeholder,
body.theme-light .view-search-box input::placeholder {
  color: #94a3b8 !important;
}
body.theme-light .search-tab-pill {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  color: #475569 !important;
}
body.theme-light .search-tab-pill.active {
  background: var(--accent-teal) !important;
  color: #ffffff !important;
  border-color: var(--accent-teal) !important;
}
body.theme-light .search-quick-chip {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  color: #1e293b !important;
}
body.theme-light .search-suggestions-dropdown {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1) !important;
}
body.theme-light .suggestion-item {
  color: #0f172a !important;
  border-bottom: 1px solid #f1f5f9 !important;
}
body.theme-light .suggestion-item:hover {
  background: #f1f5f9 !important;
}

body.theme-light .tracks-table th {
  color: #64748b !important;
  border-bottom: 1px solid #e2e8f0 !important;
}
body.theme-light .tracks-table tr:hover {
  background: #f1f5f9 !important;
}
body.theme-light .tracks-table td {
  color: #0f172a !important;
  border-bottom: 1px solid #f1f5f9 !important;
}
body.theme-light .track-index,
body.theme-light .track-time-col,
body.theme-light .table-sub-text {
  color: #64748b !important;
}

body.theme-light .details-hero,
body.theme-light .artist-hero {
  background: linear-gradient(180deg, rgba(16, 185, 129, 0.08) 0%, #f8fafc 100%) !important;
}
body.theme-light .btn-secondary {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  color: #0f172a !important;
}
body.theme-light .btn-outline {
  background: transparent !important;
  border: 1px solid #cbd5e1 !important;
  color: #334155 !important;
}

body.theme-light .player-title {
  color: #0f172a !important;
}
body.theme-light .player-artist {
  color: #64748b !important;
}
body.theme-light .ctrl-btn,
body.theme-light .tool-action-btn {
  color: #475569 !important;
}
body.theme-light .ctrl-btn:hover,
body.theme-light .tool-action-btn:hover {
  color: #0f172a !important;
}
body.theme-light .ctrl-btn.active,
body.theme-light .tool-action-btn.active {
  color: #059669 !important;
}
body.theme-light .ctrl-btn-play {
  background: var(--accent-teal) !important;
  color: #ffffff !important;
}
body.theme-light .progress-track {
  background: #e2e8f0 !important;
}
body.theme-light .progress-time-row span,
body.theme-light .current-time,
body.theme-light .duration-time {
  color: #64748b !important;
}
body.theme-light .stream-quality-pill {
  background: #f1f5f9 !important;
  color: #059669 !important;
  border: 1px solid #d1fae5 !important;
}

body.theme-light .mini-player {
  background: rgba(255, 255, 255, 0.96) !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1) !important;
}
body.theme-light .mini-title {
  color: #0f172a !important;
}
body.theme-light .mini-artist {
  color: #64748b !important;
}
body.theme-light .expanded-player-modal {
  background: #ffffff !important;
}
body.theme-light .expanded-tab-btn {
  color: #64748b !important;
}
body.theme-light .expanded-tab-btn.active {
  color: #0f172a !important;
  border-bottom-color: var(--accent-teal) !important;
}

body.theme-light .lyrics-drawer,
body.theme-light .queue-drawer {
  background: #ffffff !important;
  border-left: 1px solid #e2e8f0 !important;
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.08) !important;
}
body.theme-light .drawer-header {
  border-bottom: 1px solid #e2e8f0 !important;
}
body.theme-light .drawer-close-btn {
  color: #64748b !important;
}
body.theme-light .lyric-line {
  color: #94a3b8 !important;
}
body.theme-light .lyric-line.active {
  color: #059669 !important;
}
body.theme-light .queue-item:hover {
  background: #f1f5f9 !important;
}
body.theme-light .queue-item-title {
  color: #0f172a !important;
}
body.theme-light .queue-item-artist {
  color: #64748b !important;
}
body.theme-light .profile-modal-body,
body.theme-light .create-playlist-box,
body.theme-light .auth-card {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.18) !important;
}
body.theme-light .profile-card {
  background: #f8fafc !important;
  border: 1px solid #e2e8f0 !important;
}
body.theme-light .settings-group {
  border-bottom: 1px solid #f1f5f9 !important;
}
body.theme-light .setting-select,
body.theme-light .modal-input {
  background: #f1f5f9 !important;
  border: 1px solid #cbd5e1 !important;
  color: #0f172a !important;
}
body.theme-light .btn-google-signin {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  color: #1e293b !important;
}
body.theme-light .btn-google-signin:hover {
  background: #f8fafc !important;
  border-color: #94a3b8 !important;
}
body.theme-light .theme-card-option {
  background: #f8fafc !important;
  border-color: #e2e8f0 !important;
}
body.theme-light .theme-card-option:hover {
  background: #f1f5f9 !important;
  border-color: #cbd5e1 !important;
}
body.theme-light .theme-card-option.active {
  background: rgba(16, 185, 129, 0.08) !important;
  border-color: var(--accent-teal) !important;
}
body.theme-light .header-theme-btn {
  background: #ffffff !important;
  border-color: #cbd5e1 !important;
  color: #0f172a !important;
}
body.theme-light .header-theme-btn:hover {
  background: #f1f5f9 !important;
  border-color: var(--accent-teal) !important;
}

/* ==========================================================================
   AMOLED PITCH BLACK MODE (PURE #000000 OLED)
   ========================================================================== */
body.theme-amoled {
  --bg-dark: #000000;
  --bg-surface: #0a0a0a;
  --bg-surface-elevated: #111111;
  --bg-surface-highlight: #181818;
  --bg-glass: rgba(0, 0, 0, 0.95);
  --bg-glass-heavy: rgba(0, 0, 0, 0.98);
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(16, 185, 129, 0.4);
  background-color: #000000 !important;
  color: #f8fafc !important;
}

body.theme-amoled .app-container {
  background: #000000 !important;
}

body.theme-amoled .app-sidebar,
body.theme-amoled .desktop-player-bar,
body.theme-amoled .bottom-nav,
body.theme-amoled .app-header {
  background: #000000 !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

body.theme-amoled .square-card,
body.theme-amoled .playlist-card,
body.theme-amoled .music-card,
body.theme-amoled .track-card {
  background: #080808 !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

body.theme-amoled .square-card:hover,
body.theme-amoled .playlist-card:hover,
body.theme-amoled .music-card:hover,
body.theme-amoled .track-card:hover {
  background: #121212 !important;
  border-color: rgba(16, 185, 129, 0.3) !important;
}

body.theme-amoled .hero-card {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.16) 0%, #000000 80%) !important;
  border-color: rgba(16, 185, 129, 0.3) !important;
}

body.theme-amoled .mini-player {
  background: rgba(0, 0, 0, 0.96) !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}

body.theme-amoled .expanded-player-modal,
body.theme-amoled .lyrics-drawer,
body.theme-amoled .queue-drawer,
body.theme-amoled .profile-modal-body,
body.theme-amoled .create-playlist-box,
body.theme-amoled .auth-card {
  background: #000000 !important;
  border-color: rgba(255, 255, 255, 0.1) !important;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-primary);
  font-family: var(--font-main);
  line-height: 1.5;
  overflow-x: hidden;
  overflow-y: auto;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* Custom Scrollbars */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

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

::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(168, 85, 247, 0.4);
}

/* Base Layout Structure */
.app-container {
  display: flex;
  min-height: 100vh;
  width: 100%;
  position: relative;
  background: radial-gradient(circle at 10% 20%, rgba(29, 185, 84, 0.08) 0%, transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(30, 215, 96, 0.06) 0%, transparent 40%),
    var(--bg-dark);
}

/* ==========================================================================
   SIDEBAR
   ========================================================================== */
.app-sidebar {
  width: var(--sidebar-width);
  height: calc(100vh - var(--player-height));
  background: var(--bg-surface);
  border-right: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  padding: 1.25rem 1rem;
  z-index: 50;
  position: fixed;
  top: 0;
  left: 0;
  overflow-y: auto;
  transition: transform var(--transition-normal);
}

.sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.75rem;
  padding: 0 0.5rem;
}

.brand-logo-container {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
}

.brand-logo-img {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  box-shadow: 0 0 16px rgba(168, 85, 247, 0.4);
  transition: transform var(--transition-normal);
}

.brand-logo-container:hover .brand-logo-img {
  transform: scale(1.06) rotate(-2deg);
}

.brand-name {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #fff;
}

.brand-accent {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-badge {
  font-size: 0.65rem;
  font-family: var(--font-mono);
  background: rgba(168, 85, 247, 0.15);
  color: var(--accent-purple);
  padding: 2px 6px;
  border-radius: 4px;
  margin-left: 6px;
  border: 1px solid rgba(168, 85, 247, 0.3);
}

.sidebar-close-btn {
  display: none;
}

/* Navigation Items */
.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.nav-section-title {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--text-dim);
  padding: 0.75rem 0.75rem 0.25rem;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-md);
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-family: var(--font-main);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-align: left;
  width: 100%;
}

.nav-item svg {
  transition: transform var(--transition-fast);
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}

.nav-item:hover svg {
  transform: translateX(2px);
  color: var(--accent-purple);
}

.nav-item.active {
  background: var(--accent-gradient-subtle);
  color: #fff;
  font-weight: 600;
  border: 1px solid var(--border-glow);
  box-shadow: 0 4px 12px rgba(168, 85, 247, 0.15);
}

.nav-item.active svg {
  color: var(--accent-purple);
}

.nav-counter {
  margin-left: auto;
  font-size: 0.75rem;
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 7px;
  border-radius: var(--radius-full);
  color: var(--text-muted);
}

.btn-spotify-importer {
  border: 1px dashed rgba(29, 185, 84, 0.4);
}

.btn-spotify-importer:hover {
  background: rgba(29, 185, 84, 0.1);
  color: #1ed760;
  border-color: #1ed760;
}

.importer-pill {
  margin-left: auto;
  font-size: 0.65rem;
  font-weight: 700;
  background: #1db954;
  color: #000;
  padding: 2px 6px;
  border-radius: 4px;
}

/* Sidebar Playlists Section */
.sidebar-playlists-section {
  margin-top: 1.25rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.sidebar-playlist-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--text-dim);
  padding: 0.5rem 0.75rem;
}

.mini-add-btn {
  color: var(--text-muted);
  padding: 2px;
}

.mini-add-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.sidebar-playlists-list {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.sidebar-pl-item {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 0.85rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-pl-item:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}

.sidebar-footer {
  margin-top: auto;
  padding-top: 1rem;
}

.stream-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.03);
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
}

.stream-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
}

/* ==========================================================================
   MAIN VIEWPORT & HEADER
   ========================================================================== */
.app-main {
  flex: 1;
  margin-left: var(--sidebar-width);
  min-height: 100vh;
  min-width: 0;
  display: flex;
  flex-direction: column;
  position: relative;
  padding-bottom: calc(var(--player-height) + 40px);
}

.app-header {
  height: var(--header-height);
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-subtle);
  background: rgba(18, 18, 18, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  position: sticky;
  top: 0;
  z-index: 40;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex: 1;
  max-width: 680px;
}

.mobile-menu-toggle {
  display: none;
}

.history-nav-group {
  display: flex;
  gap: 0.35rem;
}

.nav-history-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.nav-history-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

/* Search Bar & Auto-Suggestions Dropdown */
.header-search-wrapper {
  position: relative;
  flex: 1;
}

.search-input-box {
  display: flex;
  align-items: center;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 0.45rem 1rem;
  gap: 0.75rem;
  transition: all var(--transition-fast);
}

.search-input-box:focus-within {
  border-color: var(--accent-purple);
  box-shadow: 0 0 16px rgba(168, 85, 247, 0.25);
  background: rgba(26, 26, 38, 0.95);
}

.search-icon {
  color: var(--text-muted);
}

.search-input-box input {
  flex: 1;
  background: transparent;
  border: none;
  color: #fff;
  font-family: var(--font-main);
  font-size: 0.9rem;
  outline: none;
}

.search-input-box input::placeholder {
  color: var(--text-muted);
}

.clear-search-btn {
  color: var(--text-muted);
}

.clear-search-btn:hover {
  color: #fff;
}

/* Live Instant Suggestions Dropdown (Apple iTunes API) */
.search-suggestions-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(20px);
  max-height: 380px;
  overflow-y: auto;
  z-index: 100;
  padding: 0.5rem;
}

.suggestion-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background var(--transition-fast);
}

.suggestion-item:hover,
.suggestion-item.selected {
  background: rgba(255, 255, 255, 0.12);
  outline: 1px solid var(--accent-purple);
}

.suggestion-thumb {
  width: 36px;
  height: 36px;
  border-radius: 6px;
  object-fit: cover;
}

.suggestion-meta {
  flex: 1;
  min-width: 0;
}

.suggestion-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.suggestion-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.suggestion-badge {
  font-size: 0.65rem;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-muted);
  text-transform: uppercase;
}

/* Header Right Actions */
.header-right {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.region-selector-wrapper {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 0.35rem 0.75rem;
  color: var(--text-secondary);
  font-size: 0.8rem;
}

.region-selector-wrapper select {
  background: transparent;
  border: none;
  color: #fff;
  font-family: var(--font-main);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  outline: none;
}

.region-selector-wrapper select option {
  background: var(--bg-surface-elevated);
  color: #fff;
}

.header-action-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  position: relative;
}

.header-action-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border-color: var(--accent-purple);
}

.sleep-timer-indicator {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-cyan);
  box-shadow: 0 0 8px var(--accent-cyan);
}

/* ==========================================================================
   CONTENT CONTAINER & VIEWS
   ========================================================================== */
.views-container {
  flex: 1;
  width: 100%;
  min-width: 0;
}

.view-panel {
  display: none;
  width: 100%;
  padding: 1.75rem 2.25rem 3rem;
  box-sizing: border-box;
}

.view-panel.active {
  display: block;
  animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Hero Banner */
.hero-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.25) 0%, rgba(236, 72, 153, 0.15) 50%, rgba(6, 182, 212, 0.15) 100%),
    var(--bg-surface);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  margin-bottom: 2.5rem;
  position: relative;
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

.hero-content {
  max-width: 600px;
  z-index: 2;
}

.hero-tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.12);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  margin-bottom: 0.75rem;
  border: 1px solid rgba(6, 182, 212, 0.3);
}

.hero-title {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -1px;
  line-height: 1.15;
  margin-bottom: 0.75rem;
  background: linear-gradient(to right, #ffffff, #e2e8f0);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 1.75rem;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
}

.hero-artwork-glow {
  position: relative;
  z-index: 2;
}

.hero-artwork-glow img {
  width: 190px;
  height: 190px;
  border-radius: var(--radius-lg);
  object-fit: cover;
  box-shadow: 0 12px 36px rgba(168, 85, 247, 0.4), 0 0 60px rgba(6, 182, 212, 0.2);
  transition: transform var(--transition-slow);
}

.hero-banner:hover .hero-artwork-glow img {
  transform: scale(1.04) rotate(1.5deg);
}

/* Sections & Grids */
.section-container {
  margin-bottom: 3rem;
}

.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.section-title {
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  color: #fff;
}

.section-subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.section-more-link {
  background: transparent;
  border: none;
  color: var(--accent-purple);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}

.section-more-link:hover {
  text-decoration: underline;
}

/* Tracks Grid (Home trending) */
.tracks-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.track-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.65rem 0.85rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  position: relative;
  overflow: hidden;
}

.track-card:hover {
  background: var(--bg-surface-elevated);
  border-color: var(--border-glow);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.track-card.playing {
  border-color: var(--accent-purple);
  background: rgba(168, 85, 247, 0.1);
}

.track-card-thumb-wrap {
  position: relative;
  width: 52px;
  height: 52px;
  flex-shrink: 0;
}

.track-card-thumb {
  width: 100%;
  height: 100%;
  border-radius: var(--radius-sm);
  object-fit: cover;
}

.track-card-play-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-fast);
  color: #fff;
}

.track-card:hover .track-card-play-overlay {
  opacity: 1;
}

.track-card-info {
  flex: 1;
  min-width: 0;
}

.track-card-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.track-card-artist {
  font-size: 0.8rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.track-card-badge {
  font-size: 0.65rem;
  color: var(--accent-cyan);
  font-family: var(--font-mono);
}

.track-card-actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.track-card-like-btn {
  color: var(--text-dim);
  transition: color var(--transition-fast);
}

.track-card-like-btn.liked {
  color: var(--accent-magenta);
}

/* ==========================================================================
   PREMIUM SQUARE CARD DESIGN SYSTEM (VishvaX Distinctive Aesthetic)
   ========================================================================== */
.cards-carousel {
  display: flex !important;
  gap: 16px !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  scroll-snap-type: x mandatory;
  padding: 6px 2px 14px !important;
  scrollbar-width: none !important;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
}

.cards-carousel::-webkit-scrollbar {
  display: none !important;
}

/* Responsive Grid Variant for full catalogs */
.cards-grid,
.playlist-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 1.25rem;
  width: 100%;
  box-sizing: border-box;
}

/* Unified Square Card (Song, Playlist, Album, Recommendation, Recently Played) */
.square-card,
.playlist-card,
.media-card,
.music-card {
  flex: 0 0 170px;
  width: 170px;
  max-width: 170px;
  scroll-snap-align: start;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  padding: 10px;
  cursor: pointer;
  position: relative;
  display: flex;
  flex-direction: column;
  transition: transform 0.22s cubic-bezier(0.16, 1, 0.3, 1),
              background 0.2s ease,
              border-color 0.2s ease,
              box-shadow 0.22s ease;
  user-select: none;
  box-sizing: border-box;
  outline: none;
}

.cards-carousel > .square-card,
.cards-carousel > .playlist-card,
.cards-carousel > .media-card,
.cards-carousel > .music-card {
  flex: 0 0 170px !important;
  width: 170px !important;
  min-width: 170px !important;
  max-width: 170px !important;
  box-sizing: border-box !important;
}

.cards-grid > .square-card,
.cards-grid > .playlist-card,
.cards-grid > .media-card,
.cards-grid > .music-card,
.playlist-cards-grid > .square-card,
.playlist-cards-grid > .playlist-card,
.playlist-cards-grid > .media-card,
.playlist-cards-grid > .music-card {
  flex: initial;
  width: 100%;
  max-width: 100%;
}

.square-card:hover,
.playlist-card:hover,
.media-card:hover,
.music-card:hover {
  background: var(--bg-surface-elevated);
  border-color: var(--border-glow);
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.5), 0 0 16px var(--accent-teal-subtle);
}

.square-card:active,
.playlist-card:active,
.media-card:active,
.music-card:active {
  transform: translateY(-2px) scale(0.99);
}

/* Active / Playing State with Emerald Highlight Strip */
.square-card.playing,
.playlist-card.playing,
.media-card.playing,
.music-card.playing {
  border-color: var(--accent-teal);
  background: rgba(16, 185, 129, 0.08);
  box-shadow: 0 0 20px var(--accent-teal-subtle);
}

.square-card.playing::after {
  content: '';
  position: absolute;
  top: 0;
  left: 20%;
  right: 20%;
  height: 2px;
  background: var(--accent-teal);
  box-shadow: 0 0 8px var(--accent-teal);
  border-radius: 2px;
}

/* 1:1 Aspect Ratio Cover Artwork Wrapper */
.square-card-art-wrap,
.playlist-card-art-wrap,
.media-card-img-wrap,
.music-card-art {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-surface-highlight);
  margin-bottom: 10px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.square-card-art,
.playlist-card-art,
.media-card-img,
.music-card-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.square-card:hover .square-card-art,
.playlist-card:hover .playlist-card-art,
.media-card:hover .media-card-img,
.music-card:hover .music-card-art img {
  transform: scale(1.05);
}

/* Circular artist avatar variant */
.square-card.artist-card .square-card-art-wrap,
.music-card.artist-card-round .music-card-art {
  border-radius: 50% !important;
}
.square-card.artist-card .square-card-meta,
.music-card.artist-card-round .music-card-title,
.music-card.artist-card-round .music-card-subtitle {
  text-align: center;
}

/* Floating Quick-Play Button */
.square-card-play-btn,
.playlist-card-quick-play,
.media-card-play-btn {
  position: absolute;
  bottom: 8px;
  right: 8px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent-gradient);
  color: #000000;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: translateY(8px) scale(0.9);
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4), 0 0 12px var(--accent-teal-glow);
  cursor: pointer;
  z-index: 3;
}

.square-card:hover .square-card-play-btn,
.playlist-card:hover .playlist-card-quick-play,
.media-card:hover .media-card-play-btn {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.square-card-play-btn:hover,
.playlist-card-quick-play:hover,
.media-card-play-btn:hover {
  transform: translateY(0) scale(1.08) !important;
  background: var(--accent-teal-hover);
}

/* Quick Like Button (top-right of artwork) */
.square-card-like-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: scale(0.85);
  transition: all 0.2s ease;
  cursor: pointer;
  z-index: 3;
}

.square-card:hover .square-card-like-btn,
.square-card-like-btn.liked {
  opacity: 1;
  transform: scale(1);
}

.square-card-like-btn.liked {
  color: #ec4899;
  background: rgba(236, 72, 153, 0.22);
  border-color: rgba(236, 72, 153, 0.45);
}

.square-card-like-btn:hover {
  transform: scale(1.12);
}

/* Soundwave Badge / Playing Indicator */
.square-card-badge {
  position: absolute;
  bottom: 8px;
  left: 8px;
  background: rgba(16, 185, 129, 0.92);
  color: #07080e;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  padding: 3px 7px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 4px;
  text-transform: uppercase;
  z-index: 2;
}

/* Card Typography & Text Hierarchy */
.square-card-meta,
.playlist-card-meta {
  display: flex;
  flex-direction: column;
  width: 100%;
  min-width: 0;
}

.square-card-title,
.playlist-card-title,
.media-card-title,
.music-card-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.35;
  margin-bottom: 3px;
}

.square-card-subtitle,
.playlist-card-subtitle,
.media-card-sub,
.music-card-subtitle {
  font-size: 0.76rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}

/* Skeleton Loading Card for Smooth Transitions */
.square-card.skeleton,
.playlist-card.skeleton,
.media-card.skeleton,
.music-card.skeleton {
  pointer-events: none;
}

.square-card.skeleton .square-card-art-wrap,
.music-card.skeleton,
.track-card.skeleton {
  background: linear-gradient(90deg, var(--bg-surface-elevated) 25%, var(--bg-surface-highlight) 50%, var(--bg-surface-elevated) 75%);
  background-size: 200% 100%;
  animation: skeletonShimmer 1.5s infinite;
}

@keyframes skeletonShimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ==========================================================================
   PLAYLIST & TRACKLIST DETAIL VIEW (Compact, High-Performance, Rich Dark UI)
   ========================================================================== */
#view-details {
  padding: 1.25rem 2rem 3rem;
  max-width: 100%;
  box-sizing: border-box;
}

/* Compact Playlist Header (No wasted vertical/horizontal space) */
.playlist-detail-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 1rem 0;
  width: 100%;
  box-sizing: border-box;
}

.playlist-cover-wrap {
  position: relative;
  width: 136px;
  height: 136px;
  min-width: 136px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.08);
  flex-shrink: 0;
  background: var(--bg-surface, #18181b);
}

.playlist-cover-art {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.playlist-cover-play-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
  border: none;
  color: #fff;
  cursor: pointer;
}

.playlist-cover-wrap:hover .playlist-cover-play-overlay {
  opacity: 1;
}

.playlist-header-meta {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.playlist-type-tag {
  display: inline-block;
  align-self: flex-start;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: var(--accent-purple, #a855f7);
  text-transform: uppercase;
  margin-bottom: 0.35rem;
}

.playlist-title {
  font-size: 1.95rem;
  font-weight: 800;
  line-height: 1.15;
  color: #ffffff;
  letter-spacing: -0.5px;
  margin: 0 0 0.4rem 0;
  word-break: break-word;
}

.playlist-artist-sub {
  font-size: 0.92rem;
  color: var(--text-secondary, rgba(255, 255, 255, 0.7));
  margin-bottom: 0.3rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.playlist-stats {
  font-size: 0.82rem;
  color: var(--text-muted, rgba(255, 255, 255, 0.45));
  font-weight: 500;
}

/* Compact Controls Bar: ▶ Play All | 🔀 Shuffle | + Add to Queue */
.playlist-controls-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 0 1rem;
  margin-bottom: 0.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  width: 100%;
  box-sizing: border-box;
}

.playlist-ctl-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 40px;
  padding: 0 1.25rem;
  border-radius: 20px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: nowrap;
  user-select: none;
  font-family: inherit;
}

.playlist-ctl-btn.btn-primary {
  background: linear-gradient(135deg, #a855f7 0%, #ec4899 100%);
  color: #fff;
  border: none;
  box-shadow: 0 4px 14px rgba(168, 85, 247, 0.35);
}

.playlist-ctl-btn.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(168, 85, 247, 0.5);
  filter: brightness(1.1);
}

.playlist-ctl-btn.btn-primary:active {
  transform: translateY(0);
}

.playlist-ctl-btn.btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
}

.playlist-ctl-btn.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.22);
  transform: translateY(-1px);
}

.playlist-ctl-btn.btn-secondary:active {
  transform: translateY(0);
}

/* ==========================================================================
   COMPACT PLAYLIST SONG LIST TABLE (Desktop: # | Cover | Song + Artist | Album | Duration | ⋮)
   ========================================================================== */
.playlist-table-container {
  width: 100%;
  margin-top: 0.25rem;
  overflow-x: hidden;
  box-sizing: border-box;
}

.tracks-table.playlist-tracks-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.playlist-tracks-table thead th {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 1px;
  color: var(--text-muted, rgba(255, 255, 255, 0.45));
  text-align: left;
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  user-select: none;
}

.playlist-tracks-table tbody tr.table-row {
  height: 64px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.035);
  cursor: pointer;
  transition: background 0.15s ease;
  content-visibility: auto;
  contain-intrinsic-size: 0 64px;
}

.playlist-tracks-table tbody tr.table-row:hover {
  background: rgba(255, 255, 255, 0.045);
}

.playlist-tracks-table tbody tr.table-row.playing {
  background: rgba(168, 85, 247, 0.11);
  box-shadow: inset 3px 0 0 var(--accent-purple, #a855f7);
}

.playlist-tracks-table tbody tr.table-row.playing .track-title-text {
  color: var(--accent-purple, #a855f7);
  font-weight: 600;
}

.playlist-tracks-table td {
  padding: 0.45rem 0.75rem;
  vertical-align: middle;
}

/* Col 1: Num / Eq / Play btn */
.playlist-tracks-table .col-num {
  width: 48px;
  text-align: center;
  position: relative;
  font-size: 0.88rem;
  color: var(--text-muted, rgba(255, 255, 255, 0.45));
}

.playlist-tracks-table .col-num .num-index {
  display: inline-block;
  font-variant-numeric: tabular-nums;
}

.playlist-tracks-table .col-num .row-play-btn,
.playlist-tracks-table .col-num .row-pause-btn {
  display: none;
  background: none;
  border: none;
  color: #fff;
  cursor: pointer;
  padding: 0;
  line-height: 1;
}

.playlist-tracks-table .col-num .eq-bars {
  display: none;
}

/* Desktop Hover States for Row Play / Pause */
@media (hover: hover) and (pointer: fine) {
  .playlist-tracks-table .table-row:hover .col-num .num-index {
    display: none;
  }
  .playlist-tracks-table .table-row:hover:not(.playing) .col-num .row-play-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
  .playlist-tracks-table .table-row.playing:hover .col-num .eq-bars {
    display: none;
  }
  .playlist-tracks-table .table-row.playing:hover .col-num .row-pause-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }
}

/* Playing State Indicator */
.playlist-tracks-table .table-row.playing .col-num .num-index {
  display: none;
}
.playlist-tracks-table .table-row.playing .col-num .eq-bars {
  display: inline-flex;
}

/* Animated Audio Playing Wave Bars */
.eq-bars {
  display: inline-flex;
  align-items: flex-end;
  gap: 2.5px;
  height: 15px;
  width: 14px;
  vertical-align: middle;
}

.eq-bar {
  width: 2.5px;
  background: var(--accent-purple, #a855f7);
  border-radius: 1px;
  animation: eqJump 0.8s ease-in-out infinite alternate;
}

.eq-bar:nth-child(1) { height: 40%; animation-delay: 0.1s; }
.eq-bar:nth-child(2) { height: 100%; animation-delay: 0.3s; }
.eq-bar:nth-child(3) { height: 60%; animation-delay: 0.15s; }
.eq-bar:nth-child(4) { height: 85%; animation-delay: 0.4s; }

@keyframes eqJump {
  0% { height: 25%; }
  100% { height: 100%; }
}

.table-row.playing.paused .eq-bar {
  animation-play-state: paused;
}

/* Col 2: Square Artwork (44-48px) */
.playlist-tracks-table .col-cover {
  width: 56px;
  text-align: center;
  padding-left: 0.25rem !important;
  padding-right: 0.25rem !important;
}

.track-thumb-wrap {
  position: relative;
  width: 46px;
  height: 46px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.05);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.35);
  margin: 0 auto;
}

.track-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.track-thumb-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.48);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.15s ease;
  color: #fff;
}

@media (hover: hover) and (pointer: fine) {
  .table-row:hover .track-thumb-overlay {
    opacity: 1;
  }
}

/* Col 3: Song Title + Artist Underneath */
.playlist-tracks-table .col-title {
  min-width: 0;
}

.track-meta {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.track-title-text {
  font-size: 0.92rem;
  font-weight: 500;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}

.track-artist-text {
  font-size: 0.8rem;
  color: var(--text-secondary, rgba(255, 255, 255, 0.65));
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Col 4: Album Name */
.playlist-tracks-table .col-album {
  font-size: 0.85rem;
  color: var(--text-secondary, rgba(255, 255, 255, 0.6));
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 220px;
}

/* Col 5: Duration */
.playlist-tracks-table .col-duration {
  font-size: 0.82rem;
  color: var(--text-muted, rgba(255, 255, 255, 0.5));
  font-family: var(--font-mono, monospace);
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
  width: 75px;
}

/* Col 6: More ⋮ Button */
.playlist-tracks-table .col-actions {
  width: 48px;
  text-align: center;
}

.track-more-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  color: var(--text-muted, rgba(255, 255, 255, 0.5));
  cursor: pointer;
  transition: all 0.15s ease;
}

.track-more-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

/* ==========================================================================
   FLOATING SONG CONTEXT MENU (⋮)
   ========================================================================== */
.song-context-menu {
  position: fixed;
  z-index: 1000;
  min-width: 220px;
  background: rgba(22, 22, 26, 0.96);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.06);
  padding: 6px;
  display: none;
  opacity: 0;
  transform: scale(0.96);
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.song-context-menu.open {
  display: block;
  opacity: 1;
  transform: scale(1);
}

.scm-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px 10px;
}

.scm-thumb {
  width: 36px;
  height: 36px;
  border-radius: 6px;
  object-fit: cover;
  flex-shrink: 0;
  background: rgba(255, 255, 255, 0.05);
}

.scm-info {
  flex: 1;
  min-width: 0;
}

.scm-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.scm-artist {
  font-size: 0.74rem;
  color: var(--text-secondary, rgba(255, 255, 255, 0.65));
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.scm-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin: 4px 6px;
}

.scm-item {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border: none;
  background: transparent;
  color: var(--text-primary, #fff);
  font-size: 0.85rem;
  font-weight: 500;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.12s ease;
  text-align: left;
  font-family: inherit;
}

.scm-item:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.scm-item svg {
  color: var(--text-secondary, rgba(255, 255, 255, 0.7));
  flex-shrink: 0;
}

.scm-item:hover svg {
  color: var(--accent-purple, #a855f7);
}

.scm-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(2px);
  z-index: 999;
  display: none;
}

.scm-backdrop.open {
  display: block;
}

/* Playlist Picker Modal Dialog */
.playlist-picker-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 280px;
  overflow-y: auto;
  margin-top: 10px;
}

.playlist-picker-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  cursor: pointer;
  transition: background 0.15s ease;
  width: 100%;
  text-align: left;
  color: #fff;
  font-family: inherit;
}

.playlist-picker-item:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.12);
}

.picker-thumb {
  width: 40px;
  height: 40px;
  border-radius: 6px;
  object-fit: cover;
  flex-shrink: 0;
}

.picker-info {
  flex: 1;
  min-width: 0;
}

.picker-name {
  font-size: 0.88rem;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.picker-count {
  font-size: 0.75rem;
  color: var(--text-muted, rgba(255, 255, 255, 0.45));
}


/* Filter Chips (Search) */
.search-view-header {
  margin-bottom: 1.75rem;
}

.search-results-heading {
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.filter-chips-row {
  display: flex;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.filter-chip {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-family: var(--font-main);
  font-size: 0.85rem;
  font-weight: 500;
  padding: 0.45rem 1rem;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.filter-chip:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.filter-chip.active {
  background: var(--accent-purple);
  color: #fff;
  border-color: var(--accent-purple);
  box-shadow: 0 0 14px rgba(168, 85, 247, 0.35);
}

.search-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 5rem 1rem;
  color: var(--text-muted);
  gap: 1rem;
}

/* ==========================================================================
   BOTTOM PERSISTENT PLAYER BAR
   ========================================================================== */
.app-player-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--player-height);
  background: var(--bg-glass-heavy);
  backdrop-filter: blur(24px);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.5rem;
  z-index: 50;
  box-shadow: 0 -8px 28px rgba(0, 0, 0, 0.4);
}

/* Left Track Info */
.player-track-info {
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 280px;
  min-width: 220px;
}

.player-thumbnail-wrap {
  position: relative;
  width: 54px;
  height: 54px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.player-thumbnail-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.player-thumb-hover-icon {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-fast);
  color: #fff;
}

.player-thumbnail-wrap:hover .player-thumb-hover-icon {
  opacity: 1;
}

.player-text-meta {
  flex: 1;
  min-width: 0;
}

.player-track-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}

.player-track-subline {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player-track-artist {
  font-size: 0.8rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player-status-sep {
  color: var(--text-dim);
  font-size: 0.75rem;
}

.player-play-state {
  font-size: 0.68rem;
  font-weight: 600;
  padding: 1px 7px;
  border-radius: 4px;
  letter-spacing: 0.3px;
  transition: all var(--transition-fast);
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.player-play-state.playing {
  background: rgba(6, 182, 212, 0.15);
  color: #22d3ee;
  border: 1px solid rgba(6, 182, 212, 0.35);
}

.player-play-state.paused {
  background: rgba(148, 163, 184, 0.12);
  color: var(--text-secondary);
  border: 1px solid rgba(148, 163, 184, 0.2);
}

.player-play-state.unable {
  background: rgba(239, 68, 68, 0.18);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.35);
}

.player-play-state.buffering {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.fs-title-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  width: 100%;
}

.player-like-btn {
  color: var(--text-dim);
}

.player-like-btn.liked {
  color: var(--accent-magenta);
}

/* Center Controls */
.player-center-controls {
  flex: 1;
  max-width: 580px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.45rem;
}

.player-buttons-row {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.control-btn {
  color: var(--text-secondary);
  position: relative;
}

.control-btn:hover {
  color: #fff;
}

.control-btn.active {
  color: var(--accent-cyan);
}

.repeat-one-badge {
  position: absolute;
  top: -2px;
  right: -4px;
  font-size: 0.6rem;
  font-weight: 800;
  background: var(--accent-cyan);
  color: #000;
  border-radius: 50%;
  width: 12px;
  height: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-play-pause {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #fff;
  color: #000;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform var(--transition-fast), background var(--transition-fast);
  box-shadow: 0 4px 16px rgba(255, 255, 255, 0.2);
}

.btn-play-pause:hover {
  transform: scale(1.08);
  background: #f1f5f9;
}

/* Seekbar */
.player-seekbar-row {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.time-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  width: 40px;
  text-align: center;
}

.seekbar-track {
  flex: 1;
  height: 5px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-full);
  position: relative;
  cursor: pointer;
  transition: height var(--transition-fast);
}

.seekbar-track:hover {
  height: 8px;
}

.seekbar-progress {
  height: 100%;
  width: 0%;
  background: var(--accent-gradient);
  border-radius: var(--radius-full);
  position: relative;
}

.seekbar-handle {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #fff;
  position: absolute;
  top: 50%;
  right: -6px;
  transform: translateY(-50%) scale(0);
  transition: transform var(--transition-fast);
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.6);
}

.seekbar-track:hover .seekbar-handle {
  transform: translateY(-50%) scale(1);
}

.seekbar-hover-time {
  position: absolute;
  top: -24px;
  transform: translateX(-50%);
  background: var(--bg-surface-elevated);
  color: #fff;
  font-size: 0.7rem;
  font-family: var(--font-mono);
  padding: 2px 6px;
  border-radius: 4px;
  pointer-events: none;
  display: none;
  border: 1px solid var(--border-subtle);
}

/* Right Controls */
.player-right-controls {
  display: flex;
  align-items: center;
  gap: 1rem;
  width: 280px;
  justify-content: flex-end;
}

/* Quality Switcher Badge */
.quality-badge-wrap {
  position: relative;
}

.quality-badge {
  background: rgba(168, 85, 247, 0.15);
  color: var(--accent-purple);
  border: 1px solid var(--border-glow);
  font-size: 0.7rem;
  font-weight: 700;
  font-family: var(--font-mono);
  padding: 4px 8px;
  border-radius: 6px;
  cursor: pointer;
}

.quality-badge:hover {
  background: rgba(168, 85, 247, 0.25);
}

.quality-menu {
  position: absolute;
  bottom: calc(100% + 12px);
  right: 0;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.4rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  width: 170px;
  z-index: 100;
}

.quality-option {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  padding: 0.45rem 0.65rem;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  text-align: left;
  cursor: pointer;
  font-family: var(--font-main);
}

.quality-option:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.quality-option.active {
  background: var(--accent-purple);
  color: #fff;
  font-weight: 600;
}

/* Volume Slider */
.player-volume-wrapper {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.volume-btn {
  color: var(--text-secondary);
}

.volume-btn:hover {
  color: #fff;
}

.volume-slider-track {
  width: 80px;
  height: 4px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-full);
  position: relative;
  cursor: pointer;
  transition: height var(--transition-fast);
}

.volume-slider-track:hover {
  height: 6px;
}

.volume-slider-progress {
  height: 100%;
  background: #fff;
  border-radius: var(--radius-full);
}

/* ==========================================================================
   FULLSCREEN / EXPANSIVE PLAYER MODAL
   ========================================================================== */
.fullscreen-player-modal {
  position: fixed;
  inset: 0;
  background: var(--bg-dark);
  z-index: 200;
  display: none;
  flex-direction: column;
  overflow: hidden;
}

.fullscreen-player-modal.active {
  display: flex;
  animation: modalSlideUp 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalSlideUp {
  from {
    transform: translateY(100%);
  }

  to {
    transform: translateY(0);
  }
}

.fs-player-bg {
  position: absolute;
  inset: -50px;
  background-size: cover;
  background-position: center;
  filter: blur(80px) brightness(0.22);
  z-index: 1;
  transition: background-image 1s ease;
}

.fs-player-header {
  position: relative;
  z-index: 10;
  padding: 1.5rem 2.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.fs-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 700;
  font-size: 1.1rem;
}

.fs-logo {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

.fs-tabs {
  display: flex;
  background: rgba(255, 255, 255, 0.06);
  padding: 4px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
}

.fs-tab-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-family: var(--font-main);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.4rem 1.25rem;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.fs-tab-btn.active {
  background: #fff;
  color: #000;
}

.fs-player-body {
  position: relative;
  z-index: 10;
  flex: 1;
  display: flex;
  padding: 2.5rem 4rem 4rem;
  gap: 4rem;
  overflow: hidden;
}

.fs-artwork-column {
  width: 42%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.fs-artwork-container {
  width: min(380px, 75vw);
  aspect-ratio: 1;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(168, 85, 247, 0.25);
  margin-bottom: 2rem;
}

.fs-artwork-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.fs-meta {
  text-align: center;
  margin-bottom: 1.5rem;
}

.fs-title {
  font-size: 1.8rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #fff;
  margin-bottom: 0.35rem;
}

.fs-artist {
  font-size: 1.1rem;
  color: var(--text-secondary);
}

.fs-album {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.fs-visualizer-wrap {
  width: 100%;
  max-width: 380px;
  height: 60px;
}

#audio-visualizer-canvas {
  width: 100%;
  height: 100%;
}

/* Right Content: Synced Lyrics & Queue */
.fs-content-column {
  flex: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.fs-panel-tab {
  display: none;
  height: 100%;
  overflow: hidden;
}

.fs-panel-tab.active {
  display: flex;
  flex-direction: column;
}

/* Synchronized Lyrics Container */
.lyrics-container {
  flex: 1;
  overflow-y: auto;
  padding: 3rem 1.5rem;
  display: flex;
  flex-direction: column;
  scroll-behavior: smooth;
}

.lyrics-lines-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.lyric-line {
  font-size: 1.55rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.25);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  line-height: 1.4;
  padding: 0.25rem 0;
}

.lyric-line:hover {
  color: rgba(255, 255, 255, 0.6);
  transform: translateX(4px);
}

.lyric-line.active {
  color: #fff;
  font-size: 2.1rem;
  text-shadow: 0 0 24px rgba(168, 85, 247, 0.7), 0 0 40px rgba(6, 182, 212, 0.5);
  transform: scale(1.02);
}

.lyric-line.passed {
  color: rgba(255, 255, 255, 0.4);
}

.lyrics-placeholder,
.lyrics-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: var(--text-muted);
  gap: 1rem;
  text-align: center;
}

.plain-lyrics-view pre {
  font-family: var(--font-main);
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--text-secondary);
  white-space: pre-wrap;
}

/* Queue List Container */
.queue-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.queue-list-container {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.queue-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.65rem 1rem;
  background: rgba(255, 255, 255, 0.03);
  border-radius: var(--radius-md);
  transition: background var(--transition-fast);
}

.queue-item:hover {
  background: rgba(255, 255, 255, 0.08);
}

.queue-item.current {
  background: rgba(168, 85, 247, 0.15);
  border: 1px solid var(--border-glow);
}

.queue-item-thumb {
  width: 40px;
  height: 40px;
  border-radius: 6px;
  object-fit: cover;
}

.queue-item-meta {
  flex: 1;
  min-width: 0;
}

.queue-item-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.queue-item-artist {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ==========================================================================
   MODALS (Spotify Importer, Create Playlist, Sleep Timer, Shortcuts)
   ========================================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(12px);
  z-index: 300;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal-overlay.active {
  display: flex;
  animation: fadeIn 0.2s ease;
}

.modal-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  width: 100%;
  max-width: 520px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.7);
  overflow: hidden;
}

.modal-card.mini-modal {
  max-width: 400px;
}

.modal-header {
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-subtle);
}

.modal-title-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.modal-header h2 {
  font-size: 1.2rem;
  font-weight: 700;
}

.modal-body {
  padding: 1.5rem;
}

.modal-hint {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

.input-with-button {
  display: flex;
  gap: 0.5rem;
}

.input-with-button input {
  flex: 1;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.65rem 1rem;
  color: #fff;
  font-family: var(--font-main);
  outline: none;
}

.input-with-button input:focus {
  border-color: var(--accent-purple);
}

.spotify-preview {
  margin-top: 1.5rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1rem;
}

.spotify-preview-header {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.spotify-preview-img {
  width: 70px;
  height: 70px;
  border-radius: var(--radius-md);
  object-fit: cover;
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 0.4rem;
}

.form-group input {
  width: 100%;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.65rem 1rem;
  color: #fff;
  font-family: var(--font-main);
  outline: none;
}

.form-group input:focus {
  border-color: var(--accent-purple);
}

.sleep-options-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.sleep-btn {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: #fff;
  font-family: var(--font-main);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.75rem;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.sleep-btn:hover {
  background: rgba(168, 85, 247, 0.15);
  border-color: var(--accent-purple);
}

.sleep-btn.danger {
  grid-column: span 2;
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.3);
}

.sleep-btn.danger:hover {
  background: rgba(239, 68, 68, 0.1);
}

.shortcuts-table {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.shortcut-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.key-badge {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  padding: 2px 8px;
  border-radius: 4px;
  color: #fff;
}

/* Toast Notifications */
.toasts-container {
  position: fixed;
  bottom: calc(var(--player-height) + 16px);
  right: 24px;
  z-index: 400;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  pointer-events: none;
}

.toast {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-glow);
  color: #fff;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-md);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  animation: toastIn 0.3s ease;
  pointer-events: auto;
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ==========================================================================
   BUTTONS & GENERAL UTILITIES
   ========================================================================== */
.btn-primary {
  background: var(--accent-gradient);
  border: none;
  color: #fff;
  font-family: var(--font-main);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.65rem 1.4rem;
  border-radius: var(--radius-full);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  box-shadow: 0 4px 16px rgba(168, 85, 247, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(168, 85, 247, 0.45);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-subtle);
  color: #fff;
  font-family: var(--font-main);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.65rem 1.4rem;
  border-radius: var(--radius-full);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.2);
}

.btn-icon {
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
  border-radius: 50%;
  transition: all var(--transition-fast);
}

.badge {
  font-size: 0.75rem;
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

/* Skeletons */
.skeleton {
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.03) 25%, rgba(255, 255, 255, 0.07) 50%, rgba(255, 255, 255, 0.03) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  height: 64px;
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }

  100% {
    background-position: -200% 0;
  }
}

/* Responsive Media Queries */
@media (max-width: 960px) {
  .app-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: var(--player-height);
    transform: translateX(-100%);
    box-shadow: 12px 0 32px rgba(0, 0, 0, 0.8);
  }

  .app-sidebar.open {
    transform: translateX(0);
  }

  .sidebar-close-btn {
    display: flex;
  }

  .mobile-menu-toggle {
    display: flex;
  }

  .content-scroll-container {
    padding: 1.25rem 1rem 3rem;
  }

  .hero-banner {
    flex-direction: column-reverse;
    text-align: center;
    gap: 1.5rem;
    padding: 1.75rem;
  }

  .hero-buttons {
    justify-content: center;
  }

  .fs-player-body {
    flex-direction: column;
    padding: 1.5rem;
    overflow-y: auto;
  }

  .fs-artwork-column {
    width: 100%;
  }

  .fs-artwork-container {
    width: 200px;
  }
}

@media (max-width: 640px) {
  .player-right-controls {
    display: none;
  }

  .player-track-info {
    width: auto;
    max-width: 50%;
  }

  .time-label {
    display: none;
  }
}

/* ==========================================================================
   FUTURE-PROOF ULTRA FEATURES: Speed, Autoplay Unlock & Downloads
   ========================================================================== */

/* Playback Speed Badge */
.playback-speed-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.playback-speed-btn:hover {
  background: rgba(168, 85, 247, 0.2);
  color: #fff;
  border-color: var(--border-glow);
}

/* Autoplay Unlocker Floating Banner */
.autoplay-unlock-banner {
  position: fixed;
  bottom: 96px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 1rem;
  background: rgba(22, 22, 34, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 0.65rem 1.25rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-glow);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.6), 0 0 20px rgba(168, 85, 247, 0.4);
  animation: floatBounce 3s ease-in-out infinite;
}

@keyframes floatBounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(-6px); }
}

.autoplay-unlock-banner span {
  font-size: 0.88rem;
  font-weight: 600;
  color: #fff;
}

.btn-unlock-play {
  background: var(--accent-gradient);
  color: #fff;
  border: none;
  border-radius: var(--radius-full);
  padding: 0.4rem 1.1rem;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(168, 85, 247, 0.5);
  transition: transform var(--transition-fast);
}

.btn-unlock-play:hover {
  transform: scale(1.05);
}

/* ==========================================================================
   MULTI-THEME ENGINE (Obsidian, AMOLED, Midnight, Aurora, Violet, Ocean)
   ========================================================================== */
body.theme-amoled {
  --bg-dark: #000000;
  --bg-surface: #0a0a0a;
  --bg-surface-elevated: #141414;
  --bg-glass: rgba(10, 10, 10, 0.9);
  --border-subtle: rgba(255, 255, 255, 0.12);
  --border-glow: rgba(255, 255, 255, 0.25);
}

body.theme-midnight {
  --bg-dark: #060a14;
  --bg-surface: #0c1222;
  --bg-surface-elevated: #131b31;
  --bg-glass: rgba(12, 18, 34, 0.85);
  --accent-purple: #38bdf8;
  --border-glow: rgba(56, 189, 248, 0.35);
  --accent-gradient: linear-gradient(135deg, #38bdf8 0%, #6366f1 100%);
}

body.theme-aurora {
  --bg-dark: #05120c;
  --bg-surface: #0b1e15;
  --bg-surface-elevated: #112a1e;
  --bg-glass: rgba(11, 30, 21, 0.85);
  --accent-purple: #10b981;
  --border-glow: rgba(16, 185, 129, 0.35);
  --accent-gradient: linear-gradient(135deg, #10b981 0%, #06b6d4 100%);
}

body.theme-violet {
  --bg-dark: #0e0517;
  --bg-surface: #180928;
  --bg-surface-elevated: #240e3b;
  --bg-glass: rgba(24, 9, 40, 0.85);
  --accent-purple: #c084fc;
  --border-glow: rgba(192, 132, 252, 0.4);
  --accent-gradient: linear-gradient(135deg, #c084fc 0%, #f43f5e 100%);
}

body.theme-ocean {
  --bg-dark: #040e14;
  --bg-surface: #081a24;
  --bg-surface-elevated: #0e2736;
  --bg-glass: rgba(8, 26, 36, 0.85);
  --accent-purple: #06b6d4;
  --border-glow: rgba(6, 182, 212, 0.4);
  --accent-gradient: linear-gradient(135deg, #06b6d4 0%, #3b82f6 100%);
}

/* Dynamic Greeting Banner */
.greeting-header-wrap {
  margin-bottom: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.greeting-title {
  font-size: 1.85rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  background: linear-gradient(135deg, #ffffff 30%, var(--text-secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.greeting-subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Mood Pills Carousel */
.mood-pills-row {
  display: flex;
  gap: 0.65rem;
  overflow-x: auto;
  padding-bottom: 0.75rem;
  margin-bottom: 1.5rem;
  scrollbar-width: none;
}

.mood-pills-row::-webkit-scrollbar {
  display: none;
}

.mood-pill {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 0.5rem 1.1rem;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.mood-pill:hover, .mood-pill.active {
  background: var(--accent-gradient-subtle);
  border-color: var(--border-glow);
  color: #fff;
  transform: translateY(-2px);
}

/* Mobile Bottom Navigation Bar */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: var(--bg-glass-heavy);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--border-subtle);
  z-index: 100;
  justify-content: space-around;
  align-items: center;
}

@media (max-width: 768px) {
  .mobile-bottom-nav {
    display: flex;
  }
  .app-player-bar {
    bottom: 60px;
  }
  .app-container {
    padding-bottom: 150px;
  }
}

.mobile-nav-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.7rem;
  font-weight: 600;
  cursor: pointer;
  min-width: 54px;
  min-height: 44px;
  justify-content: center;
}

.mobile-nav-btn.active, .mobile-nav-btn:hover {
  color: var(--accent-purple);
}

/* Admin Diagnostics Modal */
.diagnostics-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-top: 1rem;
}

.diagnostic-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1rem;
}

.diagnostic-card-title {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 4px;
}

.diagnostic-card-value {
  font-size: 1.25rem;
  font-weight: 800;
  font-family: var(--font-mono);
  color: var(--accent-cyan);
}

/* Theme Selector Grid in Settings */
.themes-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.65rem;
  margin-top: 1rem;
}

.theme-card-btn {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  padding: 0.6rem 0.85rem;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.theme-card-btn:hover, .theme-card-btn.active {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--border-glow);
  color: #fff;
}

.theme-swatch {
  width: 14px;
  height: 14px;
  border-radius: 50%;
}

/* ==========================================================================
   SPOTIFY MOBILE INTERFACE & MODERN APP COMPONENTS
   ========================================================================== */

/* 1. Mobile Bottom Navigation Bar */
.mobile-bottom-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--mobile-nav-height);
  background: rgba(18, 18, 18, 0.98);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  z-index: 1000;
  padding: 0 0.5rem;
  padding-bottom: env(safe-area-inset-bottom, 0);
}

.mobile-bottom-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-around;
  height: 100%;
  width: 100%;
  max-width: 500px;
  margin: 0 auto;
}

.mobile-nav-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  background: transparent;
  border: none;
  color: #b3b3b3;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  -webkit-tap-highlight-color: transparent;
  flex: 1;
}

.mobile-nav-btn svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  stroke-width: 2;
  transition: transform 0.2s ease, stroke 0.2s ease, fill 0.2s ease;
}

.mobile-nav-btn span {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.1px;
}

.mobile-nav-btn:hover {
  color: #ffffff;
}

.mobile-nav-btn.active {
  color: var(--spotify-green);
}

.mobile-nav-btn.active svg {
  stroke: var(--spotify-green);
  transform: translateY(-1px);
}

.mobile-nav-btn:active {
  transform: scale(0.9);
}

/* 2. Spotify Floating Mini Player */
.mobile-mini-player {
  display: none;
  position: fixed;
  bottom: calc(var(--mobile-nav-height) + 8px);
  left: 8px;
  right: 8px;
  height: var(--mobile-player-height);
  background: rgba(36, 36, 36, 0.96);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  border-radius: 8px;
  z-index: 998;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.7), 0 2px 6px rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  overflow: hidden;
  touch-action: pan-y;
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease;
}

.mobile-mini-player-inner {
  display: flex;
  align-items: center;
  height: 100%;
  padding: 0 10px;
  position: relative;
  width: 100%;
}

.mini-art-wrapper {
  width: 42px;
  height: 42px;
  border-radius: 6px;
  overflow: hidden;
  flex-shrink: 0;
  background: #242424;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.mini-art-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.mini-info-wrapper {
  flex: 1;
  min-width: 0;
  padding: 0 10px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.mini-title {
  font-size: 13px;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}

.mini-artist {
  font-size: 11px;
  font-weight: 500;
  color: #b3b3b3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.3;
}

.mini-controls-wrapper {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.mini-btn {
  background: transparent;
  border: none;
  color: #b3b3b3;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.15s ease, color 0.15s ease;
  -webkit-tap-highlight-color: transparent;
}

.mini-btn:hover {
  color: #ffffff;
}

.mini-btn:active {
  transform: scale(0.88);
}

.mini-btn-play {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
}

.mini-btn-play:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
}

.mini-btn-like.liked {
  color: var(--spotify-green);
}

.mini-btn-like.liked svg {
  fill: var(--spotify-green);
  stroke: var(--spotify-green);
}

.mini-progress-bar-wrap {
  position: absolute;
  bottom: 0;
  left: 6px;
  right: 6px;
  height: 2.5px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 2px;
  overflow: hidden;
}

.mini-progress-fill {
  height: 100%;
  width: 0%;
  background: var(--spotify-green);
  border-radius: 2px;
  transition: width 0.15s linear;
}

/* 3. Spotify Quick 6-Grid (Home Top Section) */
.spotify-quick-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin: 1.25rem 0 1.75rem 0;
}

@media (min-width: 1024px) {
  .spotify-quick-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }
}

.quick-card {
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  overflow: hidden;
  height: 56px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.15s ease;
  position: relative;
  text-decoration: none;
}

.quick-card:hover {
  background: rgba(255, 255, 255, 0.16);
}

.quick-card:active {
  transform: scale(0.98);
}

.quick-card-art {
  width: 56px;
  height: 56px;
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: 2px 0 8px rgba(0, 0, 0, 0.3);
}

.quick-card-art-fallback {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: linear-gradient(135deg, #450af5, #c4efd9);
  color: #ffffff;
}

.quick-card-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: #ffffff;
  padding: 0 12px;
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.quick-card-play-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--spotify-green);
  color: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 10px;
  opacity: 0;
  transform: translateY(4px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  transition: opacity 0.2s ease, transform 0.2s ease;
  flex-shrink: 0;
}

.quick-card:hover .quick-card-play-btn {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 768px) {
  .quick-card-play-btn {
    display: none;
  }
}

/* 4. Spotify Browse All Genre Tiles (Search View) */
.browse-section-heading {
  font-size: 1.35rem;
  font-weight: 800;
  color: #ffffff;
  margin: 1.5rem 0 1rem 0;
  letter-spacing: -0.02em;
}

.browse-categories-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 2rem;
}

@media (min-width: 640px) {
  .browse-categories-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .browse-categories-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
  }
}

@media (min-width: 1280px) {
  .browse-categories-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

.browse-category-card {
  height: 110px;
  border-radius: 8px;
  padding: 14px;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.2s ease;
  user-select: none;
}

.browse-category-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.browse-category-card:active {
  transform: scale(0.97);
}

.browse-category-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.2;
  letter-spacing: -0.01em;
  max-width: 65%;
  word-break: break-word;
}

.browse-category-sticker {
  position: absolute;
  bottom: -4px;
  right: -8px;
  width: 64px;
  height: 64px;
  border-radius: 6px;
  transform: rotate(25deg) translate(10%, -5%);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  object-fit: cover;
}

/* Category Background Palettes */
.cat-bollywood { background: linear-gradient(135deg, #E13300, #FA6400); }
.cat-punjabi { background: linear-gradient(135deg, #1E3264, #3B5FA8); }
.cat-pop { background: linear-gradient(135deg, #8D67AB, #C899DE); }
.cat-hiphop { background: linear-gradient(135deg, #BA5D07, #E87A1E); }
.cat-romance { background: linear-gradient(135deg, #E8115B, #F4558D); }
.cat-party { background: linear-gradient(135deg, #E91429, #FF4560); }
.cat-chill { background: linear-gradient(135deg, #283EA3, #5070D6); }
.cat-workout { background: linear-gradient(135deg, #503750, #7E577E); }
.cat-indie { background: linear-gradient(135deg, #0D73EC, #4DA5F5); }
.cat-devotional { background: linear-gradient(135deg, #477D95, #70A9C2); }
.cat-rock { background: linear-gradient(135deg, #E61E32, #6B111A); }
.cat-dance { background: linear-gradient(135deg, #D84000, #F77926); }

/* 5. Mobile Fullscreen Player Polish */
.fs-down-btn {
  background: transparent;
  border: none;
  color: #ffffff;
  padding: 8px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s ease;
}

.fs-down-btn:active {
  transform: translateY(2px);
}

.fs-lyrics-card-preview {
  margin-top: 1.25rem;
  background: linear-gradient(180deg, rgba(29, 185, 84, 0.25) 0%, rgba(20, 20, 20, 0.8) 100%);
  border-radius: 12px;
  padding: 1rem;
  border: 1px solid rgba(29, 185, 84, 0.3);
  cursor: pointer;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.fs-lyrics-card-preview:hover {
  transform: translateY(-2px);
  border-color: var(--spotify-green);
}

.fs-lyrics-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.fs-lyrics-preview-title {
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: #ffffff;
  text-transform: uppercase;
}

.fs-lyrics-preview-lines {
  font-size: 1.05rem;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.4;
  opacity: 0.95;
}

/* ==========================================================================
   UNIFIED RESPONSIVE SYSTEM: MOBILE, TABLET & DESKTOP
   ========================================================================== */

/* Mobile Header Brand */
.mobile-header-brand {
  display: none;
  align-items: center;
  gap: 8px;
}
.mobile-brand-icon {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  object-fit: cover;
}
.mobile-brand-title {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: #ffffff;
}

/* Mobile Search Button */
.mobile-search-trigger {
  display: none;
}


/* User Profile Button */
.user-profile-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  overflow: hidden;
  padding: 0;
  border: 2px solid var(--border-subtle);
  cursor: pointer;
  transition: border-color var(--transition-fast);
}
.user-profile-btn:hover {
  border-color: var(--spotify-green);
}
.user-avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ==========================================================================
   DYNAMIC ANIMATED GREETING POPUP TOAST (Auto-dismisses in 8s with close btn)
   Obsidian Black Glassmorphism, Emerald Accent, Smooth Slide-Down Animation
   ========================================================================== */
.greeting-popup-toast {
  position: fixed;
  top: 18px;
  left: 50%;
  transform: translateX(-50%) translateY(-35px) scale(0.95);
  z-index: 99999;
  width: min(92vw, 440px);
  background: rgba(10, 11, 16, 0.94);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: 14px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.8), 0 0 24px rgba(16, 185, 129, 0.18);
  opacity: 0;
  pointer-events: none;
  overflow: hidden;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}

.greeting-popup-toast.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0) scale(1);
}

.greeting-popup-toast.hide {
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%) translateY(-25px) scale(0.94);
  transition: transform 0.35s cubic-bezier(0.4, 0, 1, 1), opacity 0.28s ease;
}

.greeting-popup-content {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
}

.greeting-popup-icon-wrap {
  position: relative;
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #10b981;
}

.greeting-popup-pulse {
  position: absolute;
  top: -1px;
  right: -1px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 6px #10b981;
  animation: featuredPulse 2s infinite ease-in-out;
}

.greeting-popup-text-wrap {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.greeting-popup-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.greeting-popup-subtitle {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.65);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.greeting-popup-close-btn {
  width: 26px;
  height: 26px;
  flex: 0 0 26px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.greeting-popup-close-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff;
  transform: scale(1.08);
}

.greeting-popup-progress-track {
  height: 2.5px;
  width: 100%;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.greeting-popup-progress-bar {
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, #10b981, #00f5d4);
  transform-origin: left center;
}

/* ==========================================================================
   FEATURED SONG SHOWCASE — PREMIUM AUTO-SWIPING CARD (1 Card, 10 Songs)
   Deep Black Theme, Smooth 60 FPS Transitions, Touch/Swipe Gestures
   ========================================================================== */
.featured-showcase-card {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  background: #090a0f;
  border: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 28px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.65), 0 0 20px rgba(16, 185, 129, 0.08);
  outline: none;
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}

.featured-showcase-card:focus-visible {
  border-color: rgba(16, 185, 129, 0.5);
  box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.35);
}

/* Ambient Artwork Backdrop */
.featured-ambient-backdrop {
  position: absolute;
  inset: -15%;
  background-size: cover;
  background-position: center;
  filter: blur(54px) brightness(0.35) saturate(1.5);
  opacity: 0.4;
  transition: opacity 0.8s ease, background-image 0.8s ease;
  pointer-events: none;
  z-index: 0;
  transform: translateZ(0);
}

/* Dark Charcoal Cinematic Overlay */
.featured-dark-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(7, 8, 12, 0.94) 0%, rgba(10, 11, 16, 0.88) 50%, rgba(5, 5, 8, 0.96) 100%);
  pointer-events: none;
  z-index: 1;
}

/* Inner Slide Content Grid */
.featured-showcase-inner {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 20px 24px 16px;
  width: 100%;
  transition: transform 0.28s cubic-bezier(0.2, 0.9, 0.3, 1), opacity 0.25s ease;
  will-change: transform, opacity;
}

.featured-showcase-inner.transitioning {
  opacity: 0.35;
  transform: scale(0.985);
}

/* Left / Cover Art Column */
.featured-art-col {
  flex: 0 0 160px;
  max-width: 160px;
  aspect-ratio: 1;
}

.featured-art-frame {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.75), 0 0 24px rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: #111218;
}

.featured-art-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s cubic-bezier(0.2, 0.9, 0.3, 1), filter 0.3s ease;
}

.featured-showcase-card:hover .featured-art-img {
  transform: scale(1.04);
}

.featured-live-badge {
  position: absolute;
  bottom: 8px;
  left: 8px;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 3px 8px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.65rem;
  font-weight: 700;
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  pointer-events: none;
}

.live-pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: featuredPulse 2s infinite ease-in-out;
}

@keyframes featuredPulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.4); opacity: 0.5; }
}

/* Right / Info Column */
.featured-info-col {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
}

.featured-meta-header {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

.featured-tag-badge {
  display: none !important;
}

.featured-counter {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-variant-numeric: tabular-nums;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.05);
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.featured-counter .counter-curr {
  color: #ffffff;
  font-weight: 800;
}

.featured-song-meta {
  display: flex;
  flex-direction: column;
}

.featured-title {
  font-size: clamp(1.35rem, 2.4vw, 1.85rem);
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.025em;
  line-height: 1.22;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.featured-artist {
  font-size: clamp(0.88rem, 1.4vw, 1.02rem);
  font-weight: 500;
  color: rgba(255, 255, 255, 0.75);
  margin-top: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.featured-sub-details {
  display: none !important;
}

.featured-quality-pill {
  background: rgba(255, 255, 255, 0.06);
  padding: 1px 7px;
  border-radius: 4px;
  font-size: 0.68rem;
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.2);
  font-weight: 600;
  flex-shrink: 0;
}

/* Controls Row */
.featured-controls-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 6px;
  flex-wrap: wrap;
}

.featured-play-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #000000;
  font-weight: 800;
  font-size: 0.9rem;
  padding: 10px 22px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 18px rgba(16, 185, 129, 0.35);
  transition: transform 0.18s cubic-bezier(0.2, 0.9, 0.3, 1), box-shadow 0.18s ease;
}

.featured-play-btn:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 8px 24px rgba(16, 185, 129, 0.5);
}

.featured-play-btn:active {
  transform: translateY(1px) scale(0.98);
}

.featured-play-btn.playing {
  background: #ffffff;
  color: #000000;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.4);
}

.featured-like-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.7);
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease, border-color 0.18s ease;
}

.featured-like-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  transform: scale(1.06);
}

.featured-like-btn.liked {
  color: #10b981;
  border-color: rgba(16, 185, 129, 0.4);
  background: rgba(16, 185, 129, 0.1);
}

.featured-like-btn.liked svg {
  fill: #10b981;
}

.featured-nav-group {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.featured-nav-arrow {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.8);
  cursor: pointer;
  transition: background 0.18s, color 0.18s, transform 0.18s;
}

.featured-nav-arrow:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  transform: scale(1.06);
}

.featured-nav-arrow:active {
  transform: scale(0.95);
}

/* Bottom Slide Indicators Wrap */
.featured-indicators-wrap {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  padding: 0 24px 14px;
}

.featured-indicators {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: rgba(0, 0, 0, 0.4);
  border-radius: 999px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.featured-indicator-dot {
  position: relative;
  width: 18px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: width 0.3s cubic-bezier(0.2, 0.9, 0.3, 1), background 0.3s ease;
  overflow: hidden;
}

.featured-indicator-dot:hover {
  background: rgba(255, 255, 255, 0.4);
}

.featured-indicator-dot.active {
  width: 36px;
  background: #10b981;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}

/* 10-Second Auto-Rotation Progress Bar */
.featured-progress-track {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: rgba(255, 255, 255, 0.05);
  z-index: 3;
  overflow: hidden;
}

.featured-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #10b981, #00f5d4);
  transform-origin: left center;
}

/* Mobile Layout (< 860px) — Compact, Sleek, Mobile-First Fit */
@media (max-width: 859px) {
  .featured-showcase-card.hero-card,
  .featured-showcase-card {
    width: 100% !important;
    padding: 0 !important;
    border-radius: 16px !important;
    margin-bottom: 16px !important;
    background: #090a0f !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6), 0 0 16px rgba(16, 185, 129, 0.08) !important;
  }

  .featured-showcase-inner {
    flex-direction: row !important;
    align-items: center !important;
    gap: 14px !important;
    padding: 12px 14px 8px !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  /* Compact Artwork Column */
  .featured-art-col {
    flex: 0 0 96px !important;
    width: 96px !important;
    max-width: 96px !important;
    height: 96px !important;
    aspect-ratio: 1 !important;
    display: block !important;
  }

  .featured-art-frame {
    width: 100% !important;
    height: 100% !important;
    border-radius: 12px !important;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.65), 0 0 12px rgba(16, 185, 129, 0.12) !important;
    margin: 0 !important;
    position: relative !important;
  }

  .featured-art-img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
  }

  .featured-live-badge {
    bottom: 5px !important;
    left: 5px !important;
    padding: 2px 6px !important;
    font-size: 0.55rem !important;
    gap: 4px !important;
    border-radius: 999px !important;
    backdrop-filter: blur(6px) !important;
    -webkit-backdrop-filter: blur(6px) !important;
  }

  .live-pulse-dot {
    width: 5px !important;
    height: 5px !important;
  }

  /* Info Column */
  .featured-info-col {
    flex: 1 !important;
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    gap: 3px !important;
    overflow: hidden !important;
  }

  .featured-meta-header {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 8px !important;
    margin-bottom: 2px !important;
  }

  .featured-tag-badge {
    display: none !important;
  }

  .featured-counter {
    font-size: 0.7rem !important;
    font-family: 'JetBrains Mono', monospace !important;
    font-weight: 600 !important;
    color: rgba(255, 255, 255, 0.6) !important;
    letter-spacing: 0.04em !important;
  }

  .featured-counter .counter-curr {
    color: #10b981 !important;
    font-weight: 700 !important;
  }

  .featured-song-meta {
    display: flex !important;
    flex-direction: column !important;
    gap: 1px !important;
    min-width: 0 !important;
    overflow: hidden !important;
  }

  .featured-title.hero-title {
    font-size: 0.98rem !important;
    font-weight: 700 !important;
    color: #ffffff !important;
    line-height: 1.25 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    margin: 0 !important;
  }

  .featured-artist.hero-subtitle {
    font-size: 0.78rem !important;
    color: rgba(255, 255, 255, 0.68) !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    line-height: 1.2 !important;
    margin: 0 !important;
  }

  .featured-sub-details {
    display: none !important;
  }

  /* Controls Row */
  .featured-controls-row {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    width: 100% !important;
    margin-top: 3px !important;
  }

  .featured-play-btn.hero-play-btn {
    flex: 0 0 auto !important;
    height: 30px !important;
    padding: 0 12px !important;
    font-size: 0.74rem !important;
    font-weight: 700 !important;
    border-radius: 999px !important;
    gap: 5px !important;
  }

  .featured-play-btn svg {
    width: 13px !important;
    height: 13px !important;
  }

  .featured-like-btn {
    width: 30px !important;
    height: 30px !important;
    flex: 0 0 30px !important;
    border-radius: 50% !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: rgba(255, 255, 255, 0.06) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: rgba(255, 255, 255, 0.75) !important;
  }

  .featured-like-btn svg {
    width: 14px !important;
    height: 14px !important;
  }

  .featured-nav-group {
    display: flex !important;
    align-items: center !important;
    gap: 4px !important;
    margin-left: auto !important;
  }

  .featured-nav-arrow {
    width: 28px !important;
    height: 28px !important;
    flex: 0 0 28px !important;
    border-radius: 50% !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: rgba(255, 255, 255, 0.06) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: rgba(255, 255, 255, 0.8) !important;
  }

  .featured-nav-arrow svg {
    width: 13px !important;
    height: 13px !important;
  }

  /* Compact Bottom Indicators */
  .featured-indicators-wrap {
    padding: 2px 14px 6px !important;
    display: flex !important;
    justify-content: center !important;
  }

  .featured-indicators {
    gap: 4px !important;
  }

  .featured-indicator-dot {
    height: 3px !important;
    width: 8px !important;
    border-radius: 2px !important;
    background: rgba(255, 255, 255, 0.22) !important;
    transition: all 0.25s ease !important;
  }

  .featured-indicator-dot.active {
    width: 18px !important;
    background: #10b981 !important;
    box-shadow: 0 0 6px rgba(16, 185, 129, 0.5) !important;
  }

  .featured-progress-track {
    height: 2px !important;
  }
}

/* Extra small mobile (< 380px) */
@media (max-width: 379px) {
  .featured-art-col {
    flex: 0 0 84px !important;
    width: 84px !important;
    max-width: 84px !important;
    height: 84px !important;
  }
  .featured-showcase-inner {
    gap: 10px !important;
    padding: 10px 10px 6px !important;
  }
  .featured-title.hero-title {
    font-size: 0.9rem !important;
  }
  .featured-play-btn.hero-play-btn {
    padding: 0 10px !important;
    font-size: 0.7rem !important;
  }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
  .featured-ambient-backdrop,
  .featured-showcase-inner,
  .featured-art-img,
  .live-pulse-dot,
  .featured-indicator-dot {
    transition: opacity 0.1s ease !important;
    animation: none !important;
    transform: none !important;
  }
}

/* Language & Mood Pills */
.pills-scroll {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 6px;
  margin-bottom: 24px;
  scrollbar-width: none;
}
.pills-scroll::-webkit-scrollbar {
  display: none;
}
.pill-item {
  white-space: nowrap;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 8px 16px;
  border-radius: var(--radius-full);
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
  flex-shrink: 0;
}
.pill-item:hover, .pill-item.active {
  background: var(--spotify-green);
  color: #000000;
  border-color: var(--spotify-green);
}

/* Sections */
.section-container {
  margin-bottom: 28px;
}
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.section-title {
  font-size: 1.3rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.01em;
}
.section-action-btn {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--spotify-green);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: color var(--transition-fast);
}
.section-action-btn:hover {
  color: var(--spotify-green-hover);
  text-decoration: underline;
}

/* Cards Carousel */
.cards-carousel {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 8px;
  scrollbar-width: none;
}
.cards-carousel::-webkit-scrollbar {
  display: none;
}

/* Music Card */
.music-card {
  flex: 0 0 170px;
  width: 170px;
  max-width: 170px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  padding: 10px;
  cursor: pointer;
  transition: transform var(--transition-fast), background var(--transition-fast), box-shadow var(--transition-fast);
  display: flex;
  flex-direction: column;
}
.music-card:hover {
  background: var(--bg-surface-elevated);
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}
.music-card-art {
  width: 100%;
  aspect-ratio: 1/1;
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin-bottom: 10px;
  background: var(--bg-surface-elevated);
  position: relative;
}
.music-card-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.music-card-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}
.music-card-subtitle {
  font-size: 0.78rem;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ==========================================================================
   ADVANCED SEARCH VIEW
   ========================================================================== */
.search-view-header {
  margin-bottom: 20px;
}
.view-main-title {
  font-size: 1.8rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}
.search-view-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 0 18px;
  max-width: 600px;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}
.search-view-input-wrap:focus-within {
  border-color: var(--spotify-green);
  box-shadow: 0 0 0 2px rgba(29, 185, 84, 0.2);
}
.search-view-input-wrap svg {
  color: var(--text-muted);
  margin-right: 12px;
  flex-shrink: 0;
}
.search-view-input-wrap input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  padding: 14px 0;
  font-size: 1rem;
  color: #ffffff;
  font-family: inherit;
}
.search-view-input-wrap input::placeholder {
  color: var(--text-muted);
}
.search-loading-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-top-color: var(--spotify-green);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-left: 8px;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Search Category Tabs */
.search-category-tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
  margin-bottom: 20px;
  scrollbar-width: none;
}
.search-category-tabs::-webkit-scrollbar {
  display: none;
}
.search-tab-pill {
  padding: 8px 18px;
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: var(--radius-full);
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}
.search-tab-pill:hover, .search-tab-pill.active {
  background: #ffffff;
  color: #000000;
  border-color: #ffffff;
}

.search-results-heading-row {
  margin-bottom: 16px;
}
.search-results-heading {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.search-empty-state {
  text-align: center;
  padding: 48px 24px;
  color: var(--text-muted);
  max-width: 450px;
  margin: 0 auto;
}
.search-empty-state svg {
  margin-bottom: 14px;
  opacity: 0.5;
}
.search-empty-state p {
  font-size: 0.95rem;
  line-height: 1.5;
}

/* World-Class Search Discover & Quick Chips */
.search-empty-state-lux {
  padding: 2rem 0.5rem 3.5rem;
  max-width: 900px;
  margin: 0 auto;
}
.search-empty-icon-wrap {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(168, 85, 247, 0.12);
  border: 1px solid rgba(168, 85, 247, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
  color: var(--accent-purple, #a855f7);
  box-shadow: 0 8px 24px rgba(168, 85, 247, 0.2);
}
.search-empty-title {
  font-size: 1.5rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 0.5rem;
  text-align: center;
  letter-spacing: -0.02em;
}
.search-empty-desc {
  font-size: 0.95rem;
  color: var(--text-muted, #94a3b8);
  max-width: 520px;
  margin: 0 auto 2.2rem;
  line-height: 1.5;
  text-align: center;
}
.search-quick-tags-wrap {
  margin-bottom: 2.25rem;
  text-align: left;
}
.search-quick-tags-label {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-secondary, #cbd5e1);
  margin-bottom: 0.85rem;
  display: flex;
  align-items: center;
  gap: 6px;
}
.search-quick-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.search-quick-chip {
  padding: 8px 16px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.search-quick-chip:hover {
  background: rgba(255, 255, 255, 0.18);
  border-color: rgba(255, 255, 255, 0.35);
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}
.search-genre-explore-wrap {
  text-align: left;
}
.search-genre-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 0.85rem;
}
.search-genre-card {
  padding: 1.25rem 1rem;
  border-radius: 12px;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  min-height: 82px;
  display: flex;
  align-items: flex-end;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
  user-select: none;
}
.search-genre-card:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.5);
}
.genre-card-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: #ffffff;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.artist-card-round {
  cursor: pointer;
  transition: transform var(--transition-fast), filter var(--transition-fast);
}
.artist-card-round:hover {
  transform: translateY(-4px);
}
.artist-card-round .music-card-art {
  border-radius: 50% !important;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}
.artist-card-round img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}


/* ==========================================================================
   DESKTOP PLAYER BAR (>= 900px)
   ========================================================================== */
.desktop-player-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--player-height);
  background: #181818;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  z-index: 1000;
}
.player-left-col {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 200px;
  max-width: 280px;
}
.player-art-wrap {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  flex-shrink: 0;
  background: #242424;
}
.player-art-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.player-track-meta {
  min-width: 0;
  flex: 1;
}
.player-track-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.player-track-artist {
  font-size: 0.78rem;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.track-like-btn {
  color: var(--text-muted);
  cursor: pointer;
  transition: color var(--transition-fast), transform var(--transition-fast);
}
.track-like-btn:hover {
  color: #ffffff;
}
.track-like-btn.liked {
  color: var(--spotify-green);
}
.track-like-btn.liked svg {
  fill: currentColor;
}

.player-center-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex: 1;
  max-width: 600px;
  margin: 0 24px;
}
.player-controls-row {
  display: flex;
  align-items: center;
  gap: 16px;
}
.control-btn {
  color: var(--text-secondary);
  cursor: pointer;
  transition: color var(--transition-fast), transform var(--transition-fast);
}
.control-btn:hover {
  color: #ffffff;
}
.control-btn.active {
  color: var(--spotify-green);
}
.player-play-circle-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #ffffff;
  color: #000000;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform var(--transition-fast), background var(--transition-fast);
}
.player-play-circle-btn:hover {
  transform: scale(1.06);
  background: var(--spotify-green-hover);
}
.player-timeline-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
}
.time-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  min-width: 32px;
  text-align: center;
}
.seekbar-track {
  position: relative;
  flex: 1;
  height: 4px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 2px;
  cursor: pointer;
  transition: height var(--transition-fast);
}
.seekbar-track:hover {
  height: 6px;
}
.seekbar-progress {
  height: 100%;
  width: 0%;
  background: #ffffff;
  border-radius: 2px;
  position: relative;
}
.seekbar-track:hover .seekbar-progress {
  background: var(--spotify-green);
}
.seekbar-progress::after {
  content: '';
  position: absolute;
  right: -5px;
  top: 50%;
  transform: translateY(-50%);
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #ffffff;
  opacity: 0;
  transition: opacity var(--transition-fast);
}
.seekbar-track:hover .seekbar-progress::after {
  opacity: 1;
}
.seekbar-hover-time {
  position: absolute;
  top: -24px;
  background: #000000;
  color: #ffffff;
  font-size: 0.7rem;
  font-family: var(--font-mono);
  padding: 2px 6px;
  border-radius: 4px;
  pointer-events: none;
  display: none;
  transform: translateX(-50%);
}

.player-right-col {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 200px;
  justify-content: flex-end;
}
.stream-quality-pill {
  font-size: 0.7rem;
  font-weight: 800;
  color: var(--spotify-green);
  border: 1px solid rgba(29, 185, 84, 0.5);
  background: rgba(29, 185, 84, 0.1);
  padding: 3px 8px;
  border-radius: var(--radius-full);
}
.volume-slider-group {
  display: flex;
  align-items: center;
  gap: 8px;
}
.volume-slider {
  width: 86px;
  height: 4px;
  accent-color: var(--spotify-green);
  cursor: pointer;
}

/* ==========================================================================
   MOBILE MINI-PLAYER (< 900px)
   ========================================================================== */
.mini-player {
  display: none;
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: calc(64px + env(safe-area-inset-bottom, 0px) + 8px);
  height: 60px;
  background: rgba(18, 20, 32, 0.94);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.7), 0 0 16px var(--accent-teal-subtle);
  align-items: center;
  padding: 0 12px;
  gap: 12px;
  z-index: 1200;
  cursor: pointer;
  overflow: hidden;
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease, box-shadow 0.2s ease;
}
.mini-player.hidden {
  transform: translateY(120%);
  opacity: 0;
  pointer-events: none;
}
.mini-player:active {
  transform: scale(0.985);
}
.mini-progress-bar {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2.5px;
  background: rgba(255, 255, 255, 0.1);
}
.mini-progress-fill {
  height: 100%;
  width: 0%;
  background: var(--accent-teal);
  box-shadow: 0 0 8px var(--accent-teal);
  transition: width 0.15s linear;
}
.mini-player-art {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--bg-surface-highlight);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}
.mini-player-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.mini-player-info {
  flex: 1;
  min-width: 0;
}
.mini-song-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.25;
}
.mini-song-artist {
  font-size: 0.76rem;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}
.mini-player-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.mini-ctrl-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  color: #ffffff;
  cursor: pointer;
  transition: transform var(--transition-fast), background var(--transition-fast);
}
.mini-ctrl-btn:active {
  transform: scale(0.9);
}
.mini-play-btn {
  background: var(--accent-gradient);
  color: #000000;
  box-shadow: 0 4px 12px var(--accent-teal-subtle);
}
.mini-play-btn svg {
  fill: #000000;
}

/* ==========================================================================
   MOBILE BOTTOM NAVIGATION BAR (< 900px)
   ========================================================================== */
.bottom-nav {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: calc(64px + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0px);
  background: rgba(18, 18, 18, 0.96);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  align-items: center;
  justify-content: space-around;
  z-index: 1100;
}
.nav-tab-item {
  flex: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  color: var(--text-muted);
  cursor: pointer;
  transition: color var(--transition-fast), transform var(--transition-fast);
  min-height: 48px;
}
.nav-tab-item:active {
  transform: scale(0.92);
}
.nav-tab-item.active {
  color: var(--spotify-green);
}
.nav-tab-item.active .nav-icon {
  transform: translateY(-2px);
}
.nav-icon {
  width: 22px;
  height: 22px;
  transition: transform var(--transition-fast);
}
.nav-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.2px;
}

/* ==========================================================================
   MOBILE FULL-SCREEN EXPANDED PLAYER SHEET (< 900px)
   Ultra Sonic Spotify Mobile Vibe, Synced Lyrics & Pro Touch Controls
   ========================================================================== */
.expanded-player-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100vw;
  height: 100%;
  height: 100dvh;
  background: #08090f;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  transform: translateY(100%);
  transition: transform 0.36s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease;
  overflow: hidden;
  touch-action: pan-y;
}
.expanded-player-modal.open {
  transform: translateY(0);
}

/* Ambient Backdrop & Ultra Sonic Aura */
.player-ambient-bg {
  position: absolute;
  top: -20%;
  left: -20%;
  width: 140%;
  height: 140%;
  object-fit: cover;
  filter: blur(65px) saturate(1.8) brightness(0.28);
  opacity: 0.85;
  pointer-events: none;
  z-index: 1;
  transition: opacity 0.6s ease;
}

.ultrasonic-ambient-aura {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 30%, rgba(16, 185, 129, 0.22) 0%, rgba(11, 14, 25, 0.7) 65%, #08090f 100%);
  pointer-events: none;
  z-index: 2;
  animation: ultrasonicAuraPulse 4s ease-in-out infinite alternate;
}

@keyframes ultrasonicAuraPulse {
  0% {
    opacity: 0.7;
    filter: hue-rotate(0deg);
  }
  50% {
    opacity: 0.95;
    filter: hue-rotate(15deg);
  }
  100% {
    opacity: 0.75;
    filter: hue-rotate(-15deg);
  }
}

.player-content-wrap {
  position: relative;
  z-index: 3;
  height: 100%;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: calc(env(safe-area-inset-top, 12px) + 6px) clamp(16px, 4.5vw, 24px) calc(env(safe-area-inset-bottom, 16px) + 12px);
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  box-sizing: border-box;
}

/* Native Pull Down Drag Handle */
.player-drag-handle {
  width: 42px;
  height: 4.5px;
  background: rgba(255, 255, 255, 0.28);
  border-radius: 99px;
  margin: 0 auto 10px auto;
  flex-shrink: 0;
  cursor: grab;
  transition: background 0.2s ease, transform 0.2s ease;
}
.player-drag-handle:active {
  background: rgba(16, 185, 129, 0.8);
  transform: scaleX(1.15);
}

/* Top Header Row */
.player-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: clamp(6px, 1.5vh, 12px);
  flex-shrink: 0;
  gap: 8px;
}
.player-dismiss-btn,
.player-more-btn,
.player-top-action-btn {
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: #ffffff;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}
.player-dismiss-btn:active,
.player-more-btn:active,
.player-top-action-btn:active {
  transform: scale(0.92);
  background: rgba(255, 255, 255, 0.16);
}
.player-top-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.player-header-meta {
  text-align: center;
  min-width: 0;
  flex: 1;
}
.player-header-lbl {
  font-size: 0.64rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--spotify-green);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.player-header-album {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  max-width: 200px;
  margin: 0 auto;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* View Switcher Tabs (Playing / Lyrics / Queue) */
.expanded-player-tabs {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin: 0 auto clamp(6px, 1.2vh, 10px) auto;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 3px;
  border-radius: 999px;
  flex-shrink: 0;
}
.expanded-tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 12px;
  border-radius: 999px;
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}
.expanded-tab-btn.active {
  background: var(--spotify-green);
  color: #07090e;
  box-shadow: 0 2px 10px rgba(16, 185, 129, 0.35);
}

/* Ultra Sonic Audio Engine Pill Badge */
.ultrasonic-sound-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3.5px 10px;
  border-radius: 999px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--spotify-green);
  margin: 0 auto clamp(6px, 1.2vh, 10px) auto;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s ease;
}
.ultrasonic-sound-badge:active {
  transform: scale(0.96);
  background: rgba(16, 185, 129, 0.22);
}
.ultrasonic-pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: dotPulse 1.8s ease-in-out infinite;
}
@keyframes dotPulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.4); opacity: 0.6; }
}
.ultrasonic-badge-fx {
  background: rgba(255, 255, 255, 0.1);
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.58rem;
  color: #ffffff;
}

/* Tab Panes */
.expanded-tab-pane {
  display: none;
  width: 100%;
  flex: 1;
  min-height: 0;
}
.expanded-tab-pane.active {
  display: flex;
  flex-direction: column;
}

/* Pane 1: Now Playing Artwork Frame */
#paneNowPlaying {
  align-items: center;
  justify-content: center;
}
.player-art-frame {
  width: min(72vw, 290px);
  max-height: 38vh;
  aspect-ratio: 1/1;
  margin: 0 auto clamp(6px, 1.5vh, 12px) auto;
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.85), 0 0 35px rgba(16, 185, 129, 0.2);
  background: #12141f;
  border: 1px solid rgba(255, 255, 255, 0.08);
  flex-shrink: 1;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
}
.player-art-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Mobile Canvas Visualizer inside Cover Art */
.mobile-sonic-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
  background: rgba(8, 10, 16, 0.82);
  backdrop-filter: blur(4px);
}
.mobile-sonic-canvas.hidden {
  display: none !important;
}

/* Double-Tap Seek Feedback Ripple Overlays */
.seek-ripple-overlay {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: rgba(16, 185, 129, 0.25);
  backdrop-filter: blur(8px);
  z-index: 4;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.seek-ripple-overlay.left {
  left: 0;
  border-radius: 20px 0 0 20px;
}
.seek-ripple-overlay.right {
  right: 0;
  border-radius: 0 20px 20px 0;
}
.seek-ripple-overlay.show {
  opacity: 1;
  animation: seekRippleFlash 0.5s ease-out forwards;
}
@keyframes seekRippleFlash {
  0% { opacity: 0; transform: scale(0.85); }
  35% { opacity: 1; transform: scale(1.05); }
  100% { opacity: 0; transform: scale(1); }
}
.ripple-icon {
  font-size: 1.6rem;
  font-weight: 900;
}
.ripple-text {
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.05em;
}

/* Floating Sonic Vibe Button */
.art-visualizer-toggle-btn {
  position: absolute;
  bottom: 10px;
  right: 10px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(7, 9, 15, 0.75);
  border: 1px solid rgba(16, 185, 129, 0.4);
  backdrop-filter: blur(10px);
  color: var(--spotify-green);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: all 0.2s ease;
}
.art-visualizer-toggle-btn:active {
  transform: scale(0.92);
}
.art-visualizer-toggle-btn.active {
  background: var(--spotify-green);
  color: #000000;
  border-color: #34d399;
}
.vibe-bars {
  display: inline-flex;
  align-items: flex-end;
  gap: 2px;
  height: 10px;
}
.vibe-b {
  width: 2px;
  background: currentColor;
  border-radius: 1px;
  animation: vibeBounce 0.8s ease-in-out infinite alternate;
}
.vibe-b:nth-child(1) { height: 4px; animation-delay: 0.1s; }
.vibe-b:nth-child(2) { height: 9px; animation-delay: 0.3s; }
.vibe-b:nth-child(3) { height: 6px; animation-delay: 0.5s; }
.vibe-b:nth-child(4) { height: 10px; animation-delay: 0.2s; }
@keyframes vibeBounce {
  from { height: 3px; }
  to { height: 10px; }
}

/* Track Title & Like Row */
.player-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: clamp(6px, 1.4vh, 12px);
  flex-shrink: 0;
  gap: 12px;
}
.player-track-info {
  min-width: 0;
  flex: 1;
}
.player-song-title {
  font-size: clamp(1.15rem, 4vw, 1.35rem);
  font-weight: 800;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -0.01em;
}
.player-song-artist {
  font-size: clamp(0.82rem, 3vw, 0.92rem);
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}
.player-title-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}
.player-quick-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}
.player-quick-btn:active {
  transform: scale(0.9);
  color: #ffffff;
}
.player-heart-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.player-heart-btn.liked {
  color: var(--spotify-green);
  animation: heartPop 0.32s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.player-heart-btn.liked svg {
  fill: currentColor;
}
@keyframes heartPop {
  0% { transform: scale(1); }
  50% { transform: scale(1.35); }
  100% { transform: scale(1); }
}

/* Progress Scrub Bar (Spotify Style) */
.progress-container {
  margin-bottom: clamp(6px, 1.4vh, 12px);
  flex-shrink: 0;
}
.progress-slider-wrap {
  position: relative;
  height: 20px;
  display: flex;
  align-items: center;
}
.progress-track {
  position: relative;
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.16);
  border-radius: 99px;
  overflow: hidden;
}
.progress-buffer {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0%;
  background: rgba(255, 255, 255, 0.32);
  border-radius: 99px;
  transition: width 0.2s linear;
}
.progress-filled {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0%;
  background: var(--spotify-green);
  border-radius: 99px;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}
.progress-scrub-input {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
  z-index: 5;
}
.progress-time-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  color: var(--text-muted);
  font-family: var(--font-mono, monospace);
  margin-top: 3px;
  user-select: none;
}
#timeDuration {
  cursor: pointer;
  transition: color 0.15s ease;
}
#timeDuration:hover {
  color: #ffffff;
}

/* Primary Playback Controls Row */
.player-controls-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: clamp(6px, 1.5vh, 12px);
  flex-shrink: 0;
  padding: 0 4px;
}
.ctrl-btn {
  position: relative;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}
.ctrl-btn:active {
  transform: scale(0.9);
}
.ctrl-btn.active {
  color: var(--spotify-green);
}
.ctrl-active-dot {
  display: none;
  position: absolute;
  bottom: 0;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--spotify-green);
}
.ctrl-btn.active .ctrl-active-dot {
  display: block;
}
.ctrl-seek-btn {
  color: #94a3b8;
}
.ctrl-seek-btn:hover {
  color: #ffffff;
}
.ctrl-nav-btn {
  color: #ffffff;
}
.ctrl-btn-play {
  width: clamp(56px, 14vw, 66px);
  height: clamp(56px, 14vw, 66px);
  border-radius: 50%;
  background: var(--spotify-green);
  color: #07090e;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 6px 22px rgba(16, 185, 129, 0.45);
  transition: transform 0.18s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.2s ease;
  flex-shrink: 0;
}
.ctrl-btn-play:active {
  transform: scale(0.92);
  box-shadow: 0 2px 10px rgba(16, 185, 129, 0.6);
}
.repeat-one-indicator {
  position: absolute;
  top: 4px;
  right: 4px;
  font-size: 0.6rem;
  font-weight: 800;
  color: var(--spotify-green);
}

/* Secondary "MORE REQUIRED BUTTONS" Spotify Toolbar */
.player-spotify-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  margin-bottom: clamp(6px, 1.4vh, 12px);
  flex-shrink: 0;
  gap: 4px;
}
.speed-toggle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.06);
}
.speed-badge {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--spotify-green);
  font-family: var(--font-mono, monospace);
}
.ctrl-tool-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: transparent;
  border: none;
  color: #94a3b8;
  padding: 5px 6px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.72rem;
  font-weight: 600;
}
.ctrl-tool-btn:active {
  transform: scale(0.92);
  background: rgba(255, 255, 255, 0.08);
}
.ctrl-tool-btn.active {
  color: var(--spotify-green);
}
.tool-chip {
  font-size: 0.68rem;
  color: var(--text-secondary);
}
.tool-badge-count {
  font-size: 0.65rem;
  font-weight: 800;
  background: rgba(16, 185, 129, 0.2);
  color: var(--spotify-green);
  padding: 1px 5px;
  border-radius: 99px;
  font-family: var(--font-mono, monospace);
}

/* Mobile Dedicated Master Volume Slider (AMOLED Glass Design) */
.mobile-volume-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  margin-bottom: clamp(6px, 1.4vh, 12px);
  flex-shrink: 0;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.mobile-volume-mute-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  border-radius: 6px;
  flex-shrink: 0;
}
.mobile-volume-mute-btn:active {
  transform: scale(0.9);
  color: #ffffff;
}
.mobile-volume-slider-wrap {
  position: relative;
  flex: 1;
  height: 20px;
  display: flex;
  align-items: center;
}
.mobile-volume-track {
  position: relative;
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.14);
  border-radius: 99px;
  overflow: hidden;
}
.mobile-volume-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 85%;
  background: linear-gradient(90deg, #10b981 0%, #06b6d4 100%);
  border-radius: 99px;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.5);
  transition: width 0.08s linear;
}
.mobile-volume-range {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
  z-index: 5;
  margin: 0;
}
.mobile-volume-badge {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text-muted);
  font-family: var(--font-mono, monospace);
  min-width: 32px;
  text-align: right;
  flex-shrink: 0;
}

/* Spotify Floating Synchronized Lyrics Preview Card */
.spotify-lyrics-preview-card {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.16) 0%, rgba(16, 19, 32, 0.92) 100%);
  border: 1px solid rgba(16, 185, 129, 0.28);
  border-radius: 18px;
  padding: 12px 14px;
  cursor: pointer;
  flex-shrink: 0;
  backdrop-filter: blur(16px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.spotify-lyrics-preview-card:hover,
.spotify-lyrics-preview-card:active {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.24) 0%, rgba(20, 24, 40, 0.96) 100%);
  border-color: rgba(16, 185, 129, 0.5);
  transform: translateY(-2px);
}
.lyrics-preview-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.lyrics-preview-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--spotify-green);
}
.lyrics-preview-expand-btn {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: rgba(255, 255, 255, 0.12);
  border: none;
  border-radius: 999px;
  padding: 3px 10px;
  color: #ffffff;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  cursor: pointer;
}
.lyrics-preview-lines {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.lyrics-preview-line.active {
  font-size: 0.95rem;
  font-weight: 800;
  color: #ffffff;
  text-shadow: 0 0 12px rgba(16, 185, 129, 0.5);
  line-height: 1.35;
}
.lyrics-preview-line.upcoming {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.3;
}

/* Fullscreen Synchronized Lyrics View Mode (#paneLyrics) */
.lyrics-fullscreen-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 8px 10px 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 8px;
  flex-shrink: 0;
}
.lyrics-fs-info {
  display: flex;
  align-items: center;
  gap: 8px;
}
.lyrics-fs-badge {
  font-size: 0.68rem;
  font-weight: 700;
  background: rgba(16, 185, 129, 0.15);
  color: var(--spotify-green);
  border: 1px solid rgba(16, 185, 129, 0.3);
  padding: 2px 8px;
  border-radius: 999px;
}
.lyrics-fs-hint {
  font-size: 0.68rem;
  color: var(--text-muted);
}
.lyrics-fs-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}
.lyrics-fs-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 999px;
  padding: 4px 10px;
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}
.lyrics-fs-btn:active {
  transform: scale(0.92);
}

.mobile-lyrics-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 16px 12px 60px 12px;
  mask-image: linear-gradient(to bottom, transparent 0%, black 8%, black 88%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 8%, black 88%, transparent 100%);
  -webkit-overflow-scrolling: touch;
}
.mobile-lyrics-scroll .lyric-line {
  font-size: 1.35rem;
  font-weight: 700;
  padding: 12px 14px;
  text-align: left;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.35);
  border-radius: 12px;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  user-select: none;
}
.mobile-lyrics-scroll .lyric-line:active {
  background: rgba(255, 255, 255, 0.08);
}
.mobile-lyrics-scroll .lyric-line.active {
  font-size: 1.65rem;
  font-weight: 900;
  color: #ffffff;
  text-shadow: 0 0 24px rgba(16, 185, 129, 0.65);
  background: linear-gradient(90deg, rgba(16, 185, 129, 0.2) 0%, transparent 100%);
  transform: translateX(6px);
}
.mobile-lyrics-scroll .lyric-line.passed {
  color: rgba(255, 255, 255, 0.68);
}

/* Queue Tab (#paneQueue) */
.queue-mobile-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 6px 8px 6px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 6px;
  flex-shrink: 0;
}
.queue-mobile-title {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-secondary);
}
.queue-clear-btn {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.25);
  color: #ef4444;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.queue-clear-btn:active {
  transform: scale(0.92);
}
.mobile-queue-scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 6px 4px 40px 4px;
  -webkit-overflow-scrolling: touch;
}

/* Intelligent Recommended Queue Section */
.mobile-queue-recos-section {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px dashed rgba(255, 255, 255, 0.12);
}
.mobile-recos-header {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 12px;
  padding: 0 4px;
}
.recos-title-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
}
.recos-sparkle {
  font-size: 0.95rem;
  color: #10b981;
  animation: sparkleRotate 3s ease-in-out infinite;
}
@keyframes sparkleRotate {
  0%, 100% { transform: scale(1) rotate(0deg); }
  50% { transform: scale(1.2) rotate(15deg); }
}
.recos-title {
  font-size: 0.88rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.01em;
}
.recos-subtitle {
  font-size: 0.7rem;
  color: var(--text-muted);
}
.mobile-recos-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.reco-loading-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 1.5rem 0;
  color: var(--text-muted);
  font-size: 0.8rem;
}
.reco-item-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.reco-item-card:active {
  background: rgba(16, 185, 129, 0.12);
  border-color: rgba(16, 185, 129, 0.3);
  transform: scale(0.985);
}
.reco-item-thumb {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}
.reco-item-meta {
  flex: 1;
  min-width: 0;
}
.reco-item-title {
  font-size: 0.84rem;
  font-weight: 700;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.reco-item-artist {
  font-size: 0.72rem;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 1px;
}
.reco-item-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}
.reco-add-queue-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: 999px;
  color: #10b981;
  font-size: 0.68rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}
.reco-add-queue-btn:active {
  transform: scale(0.92);
  background: #10b981;
  color: #000;
}

/* Tab Layout Adaptive Display */
.expanded-player-modal.tab-lyrics .player-art-frame,
.expanded-player-modal.tab-lyrics .player-title-row,
.expanded-player-modal.tab-lyrics .progress-container,
.expanded-player-modal.tab-lyrics .player-controls-row,
.expanded-player-modal.tab-lyrics .player-spotify-toolbar,
.expanded-player-modal.tab-lyrics .mobile-volume-row,
.expanded-player-modal.tab-lyrics .spotify-lyrics-preview-card,
.expanded-player-modal.tab-queue .player-art-frame,
.expanded-player-modal.tab-queue .player-title-row,
.expanded-player-modal.tab-queue .progress-container,
.expanded-player-modal.tab-queue .player-controls-row,
.expanded-player-modal.tab-queue .player-spotify-toolbar,
.expanded-player-modal.tab-queue .mobile-volume-row,
.expanded-player-modal.tab-queue .spotify-lyrics-preview-card {
  display: none !important;
}

/* ==========================================================================
   MOBILE BOTTOM SHEET MODALS
   (Sleep Timer, Devices, More Menu, Lyrics Quote)
   ========================================================================== */
.mobile-sheet-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.25s ease;
}
.mobile-sheet-modal.open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}
.mobile-sheet-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 6, 12, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
.mobile-sheet-card {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 500px;
  background: linear-gradient(180deg, #161825 0%, #0d0f18 100%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-bottom: none;
  border-radius: 28px 28px 0 0;
  padding: 14px 20px calc(env(safe-area-inset-bottom, 20px) + 16px) 20px;
  box-shadow: 0 -15px 45px rgba(0, 0, 0, 0.85);
  transform: translateY(100%);
  transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
}
.mobile-sheet-modal.open .mobile-sheet-card {
  transform: translateY(0);
}
.mobile-sheet-handle {
  width: 36px;
  height: 4px;
  background: rgba(255, 255, 255, 0.25);
  border-radius: 99px;
  margin: 0 auto 12px auto;
}
.mobile-sheet-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.mobile-sheet-title {
  display: flex;
  align-items: center;
  gap: 10px;
}
.sheet-title-icon {
  font-size: 1.3rem;
}
.mobile-sheet-title h3 {
  font-size: 1.15rem;
  font-weight: 800;
  color: #ffffff;
  margin: 0;
}
.mobile-sheet-subtitle {
  font-size: 0.72rem;
  color: var(--spotify-green);
  font-weight: 600;
}
.mobile-sheet-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: #ffffff;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

/* Sleep Timer Grid */
.sleep-timer-options-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.sleep-option-btn {
  padding: 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #ffffff;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}
.sleep-option-btn:active {
  transform: scale(0.96);
  background: rgba(16, 185, 129, 0.2);
  border-color: var(--spotify-green);
}
.sleep-option-btn.danger {
  grid-column: span 2;
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.25);
  color: #f87171;
}

/* Device Connect Sheet */
.device-active-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: 16px;
  padding: 14px;
  margin-bottom: 14px;
}
.device-icon-pulse {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(16, 185, 129, 0.2);
  color: var(--spotify-green);
  display: flex;
  align-items: center;
  justify-content: center;
}
.device-info {
  flex: 1;
}
.device-name {
  font-size: 0.95rem;
  font-weight: 800;
  color: #ffffff;
}
.device-status {
  font-size: 0.74rem;
  color: var(--spotify-green);
  margin-top: 2px;
}
.device-check {
  font-size: 1.1rem;
  font-weight: 900;
  color: var(--spotify-green);
}
.device-system-note {
  font-size: 0.74rem;
  color: var(--text-muted);
  line-height: 1.45;
  padding: 0 4px;
}

/* 3-Dots More Options Sheet */
.sheet-song-preview {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 1;
}
.sheet-preview-img {
  width: 46px;
  height: 46px;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
}
.sheet-preview-text {
  min-width: 0;
  flex: 1;
}
.sheet-preview-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sheet-preview-artist {
  font-size: 0.78rem;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sheet-action-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.sheet-action-item {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 12px 14px;
  background: transparent;
  border: none;
  border-radius: 12px;
  color: #ffffff;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease;
  text-align: left;
}
.sheet-action-item:active {
  background: rgba(255, 255, 255, 0.08);
}
.sheet-action-item svg {
  color: var(--spotify-green);
  flex-shrink: 0;
}

/* Lyrics Quote Share Card */
.lyrics-quote-card {
  position: relative;
  background: linear-gradient(145deg, #10b981 0%, #047857 100%);
  border-radius: 20px;
  padding: 24px 20px;
  color: #ffffff;
  margin-bottom: 16px;
  box-shadow: 0 10px 30px rgba(16, 185, 129, 0.4);
}
.quote-watermark {
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  opacity: 0.8;
  margin-bottom: 10px;
}
.quote-text {
  font-size: 1.15rem;
  font-weight: 800;
  line-height: 1.4;
  margin: 0 0 14px 0;
}
.quote-track-meta {
  font-size: 0.75rem;
  opacity: 0.9;
  font-weight: 600;
}
.quote-share-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.btn-copy-quote,
.btn-native-share {
  padding: 12px;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
}
.btn-copy-quote {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}
.btn-native-share {
  background: var(--spotify-green);
  color: #07090e;
}

/* ==========================================================================
   MODALS: PROFILE, PLAYLIST, QUEUE, LYRICS
   ========================================================================== */
.profile-modal, .create-playlist-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 5000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.profile-modal:not(.open) {
  display: none !important;
}
.profile-modal-body, .create-playlist-box {
  background: #181818;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 24px;
  width: 100%;
  max-width: 480px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.8);
}
.modal-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 14px;
}
.modal-input {
  width: 100%;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  font-size: 0.95rem;
  color: #ffffff;
  font-family: inherit;
  margin-bottom: 12px;
  outline: none;
}
.modal-input:focus {
  border-color: var(--spotify-green);
}
.modal-buttons-row {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 8px;
}

.profile-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  background: var(--bg-surface-elevated);
  border-radius: var(--radius-md);
  margin-bottom: 20px;
}
.profile-avatar-large {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid var(--spotify-green);
  flex-shrink: 0;
}
.profile-avatar-large img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.profile-name {
  font-size: 1.1rem;
  font-weight: 800;
  color: #ffffff;
}
.profile-badge {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--spotify-green);
  letter-spacing: 0.05em;
}
.profile-stats-row {
  display: flex;
  gap: 16px;
  margin-top: 8px;
}
.stat-item {
  display: flex;
  flex-direction: column;
}
.stat-val {
  font-size: 1rem;
  font-weight: 800;
  color: #ffffff;
}
.stat-lbl {
  font-size: 0.68rem;
  color: var(--text-muted);
  text-transform: uppercase;
}

.settings-group {
  background: var(--bg-surface-elevated);
  border-radius: var(--radius-md);
  padding: 14px;
  margin-bottom: 14px;
}
.settings-group-title {
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.setting-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-subtle);
}
.setting-row:last-child {
  border-bottom: none;
}
.setting-label {
  font-size: 0.88rem;
  font-weight: 600;
  color: #ffffff;
}
.setting-sublabel {
  font-size: 0.74rem;
  color: var(--text-muted);
}
.setting-select {
  background: #181818;
  border: 1px solid var(--border-subtle);
  color: #ffffff;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
}

/* Toast */
.toast-notice {
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(-100px);
  background: #ffffff;
  color: #000000;
  padding: 10px 20px;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 700;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  z-index: 10000;
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.2s ease;
  pointer-events: none;
  opacity: 0;
}
.toast-notice.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

/* ==========================================================================
   RESPONSIVE BREAKPOINTS (MOBILE VS DESKTOP)
   ========================================================================== */
@media (max-width: 899px) {
  /* Hide Desktop Exclusive Layout */
  .app-sidebar {
    display: none !important;
  }
  .desktop-player-bar {
    display: none !important;
  }
  .header-search-wrapper {
    display: none !important;
  }
  .history-nav-group {
    display: none !important;
  }

  /* Show Mobile Layout */
  .mobile-header-brand {
    display: flex !important;
  }
  .mobile-search-trigger {
    display: flex !important;
  }
  .bottom-nav {
    display: flex !important;
  }
  .mini-player:not(.hidden) {
    display: flex !important;
  }

  /* Ensure content padding clears floating mini-player & bottom nav */
  .app-main {
    margin-left: 0 !important;
    width: 100vw !important;
  }
  .views-container {
    padding: 16px !important;
    padding-bottom: 155px !important;
  }
  .tracks-table th.col-album,
  .tracks-table td.col-album {
    display: none !important;
  }
}

@media (min-width: 900px) {
  .app-sidebar {
    display: flex !important;
  }
  .desktop-player-bar {
    display: flex !important;
  }
  .bottom-nav {
    display: none !important;
  }
  .mini-player {
    display: none !important;
  }
  .expanded-player-modal {
    display: none !important;
  }
  .mobile-search-trigger {
    display: none !important;
  }
  .mobile-header-brand {
    display: none !important;
  }
  .views-container {
    padding-bottom: calc(var(--player-height) + 40px) !important;
  }
}

/* ==========================================================================
   PROGRESSIVE WEB APP (PWA) DESIGN SYSTEM & CONTROLS
   ========================================================================== */

/* --- Header Install Button --- */
.header-install-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.25), rgba(217, 70, 239, 0.25));
  border: 1px solid rgba(168, 85, 247, 0.5);
  color: #f3e8ff;
  border-radius: 9999px;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 2px 10px rgba(139, 92, 246, 0.2);
  margin-right: 6px;
  user-select: none;
}
.header-install-btn:hover {
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  border-color: #c084fc;
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(168, 85, 247, 0.45);
}
.header-install-btn:active {
  transform: scale(0.97);
}
.header-install-btn svg {
  flex-shrink: 0;
  stroke: currentColor;
}

/* --- Sidebar Install Button --- */
.sidebar-install-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(217, 70, 239, 0.15));
  border: 1px solid rgba(168, 85, 247, 0.35);
  color: #f5f3ff;
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  margin-bottom: 12px;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
}
.sidebar-install-btn:hover {
  background: linear-gradient(135deg, #7c3aed, #9333ea);
  border-color: #c084fc;
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(124, 58, 237, 0.4);
}
.sidebar-install-btn:active {
  transform: scale(0.98);
}

/* --- Profile Modal Install Badge & Button --- */
.btn-primary-mini {
  background: linear-gradient(135deg, #7c3aed, #9333ea);
  border: none;
  color: #ffffff;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.btn-primary-mini:hover {
  background: linear-gradient(135deg, #6d28d9, #7e22ce);
  box-shadow: 0 2px 10px rgba(124, 58, 237, 0.4);
}
.pwa-badge-operational {
  font-size: 12px;
  font-weight: 700;
  color: #10b981;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
  padding: 3px 10px;
  border-radius: 9999px;
  letter-spacing: 0.5px;
}

/* --- iOS Add to Home Screen Instructions Modal --- */
.ios-install-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
  transition: visibility 0.3s ease, opacity 0.3s ease;
}
.ios-install-modal.open {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
}
.ios-install-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.ios-install-sheet {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 460px;
  background: #101122;
  border: 1px solid rgba(168, 85, 247, 0.25);
  border-bottom: none;
  border-radius: 24px 24px 0 0;
  padding: 24px 22px calc(24px + env(safe-area-inset-bottom, 0px));
  box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.7), 0 0 30px rgba(139, 92, 246, 0.15);
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.ios-install-modal.open .ios-install-sheet {
  transform: translateY(0);
}
@media (min-width: 600px) {
  .ios-install-modal {
    align-items: center;
    padding: 20px;
  }
  .ios-install-sheet {
    border-bottom: 1px solid rgba(168, 85, 247, 0.25);
    border-radius: 24px;
    padding: 24px 24px;
    transform: translateY(20px) scale(0.97);
  }
  .ios-install-modal.open .ios-install-sheet {
    transform: translateY(0) scale(1);
  }
}
.ios-install-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.ios-install-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.ios-brand-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}
.ios-install-title {
  font-size: 17px;
  font-weight: 700;
  color: #ffffff;
}
.ios-install-subtitle {
  font-size: 12px;
  color: #94a3b8;
  margin-top: 2px;
}
.ios-install-close {
  background: rgba(255, 255, 255, 0.08);
  border: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s ease;
}
.ios-install-close:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}
.ios-install-steps {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.ios-step-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 14px;
  padding: 12px 14px;
}
.ios-step-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, #7c3aed, #9333ea);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.ios-step-content {
  flex: 1;
}
.ios-step-label {
  font-size: 14px;
  font-weight: 600;
  color: #f1f5f9;
}
.ios-step-sub {
  font-size: 12px;
  color: #94a3b8;
  margin-top: 2px;
  line-height: 1.35;
}
.ios-step-icon {
  color: #c084fc;
  flex-shrink: 0;
}
.btn-primary-block {
  width: 100%;
  background: linear-gradient(135deg, #7c3aed, #9333ea);
  border: none;
  color: #ffffff;
  font-size: 15px;
  font-weight: 600;
  padding: 13px;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 16px rgba(124, 58, 237, 0.35);
}
.btn-primary-block:hover {
  background: linear-gradient(135deg, #6d28d9, #7e22ce);
}

/* --- PWA Update Notification Floating Banner --- */
.pwa-update-toast {
  position: fixed;
  bottom: calc(var(--player-height, 90px) + 20px);
  right: 24px;
  z-index: 9999;
  background: #111226;
  border: 1px solid rgba(168, 85, 247, 0.5);
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7), 0 0 24px rgba(139, 92, 246, 0.3);
  padding: 14px 18px;
  max-width: 440px;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  animation: pwaSlideUp 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes pwaSlideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.pwa-update-body {
  display: flex;
  align-items: center;
  gap: 14px;
}
.pwa-update-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: rgba(168, 85, 247, 0.18);
  border: 1px solid rgba(168, 85, 247, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #c084fc;
  flex-shrink: 0;
}
.pwa-update-info {
  flex: 1;
}
.pwa-update-title {
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
}
.pwa-update-text {
  font-size: 12px;
  color: #94a3b8;
  margin-top: 2px;
}
.pwa-update-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.pwa-update-btn {
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  border: none;
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
  padding: 8px 14px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 2px 10px rgba(124, 58, 237, 0.4);
}
.pwa-update-btn:hover {
  background: linear-gradient(135deg, #6d28d9, #9333ea);
  transform: translateY(-1px);
}
.pwa-dismiss-btn {
  background: rgba(255, 255, 255, 0.08);
  border: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  color: #94a3b8;
  font-size: 16px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}
.pwa-dismiss-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
}

/* --- Standalone Native PWA Experience Enhancements --- */
body.pwa-standalone {
  overscroll-behavior-y: contain;
  -webkit-user-select: none;
  user-select: none;
}
body.pwa-standalone input,
body.pwa-standalone textarea {
  -webkit-user-select: text;
  user-select: text;
}
@media all and (display-mode: standalone) {
  body {
    overscroll-behavior-y: contain;
  }
}

/* ==========================================================================
   JIOSAAVN-INSPIRED PLAYLIST & ALBUM CARD DESIGN SYSTEM (PHASE 3)
   ========================================================================== */
.playlist-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 18px;
  width: 100%;
}

.playlist-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  padding: 10px;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
  position: relative;
  min-width: 0;
  box-sizing: border-box;
  scroll-snap-align: start;
}

.cards-carousel .playlist-card,
.cards-carousel .music-card {
  flex: 0 0 170px !important;
  width: 170px !important;
  min-width: 170px !important;
  max-width: 170px !important;
}

.playlist-cards-grid .playlist-card,
.playlist-cards-grid .music-card {
  flex: none;
  width: 100%;
}

.playlist-card:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.12);
  transform: translateY(-3px);
}

.playlist-card:focus-visible {
  outline: 2px solid var(--accent-purple, #8b5cf6);
  outline-offset: 2px;
}

.playlist-card-art-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 10px;
  overflow: hidden;
  background: #151722;
  flex-shrink: 0;
}

.playlist-card-art {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.playlist-card-quick-play {
  position: absolute;
  right: 8px;
  bottom: 8px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #10b981;
  color: #ffffff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: translateY(6px);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.45);
}

.playlist-card:hover .playlist-card-quick-play,
.playlist-card:focus-within .playlist-card-quick-play {
  opacity: 1;
  transform: translateY(0);
}

.playlist-card-quick-play:hover {
  transform: scale(1.08) !important;
  background: #059669;
}

.playlist-card-meta {
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.playlist-card-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: #ffffff;
  line-height: 1.35;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 2.7em;
}

.playlist-card-subtitle {
  font-size: 0.78rem;
  color: #94a3b8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

/* Desktop Drawer Toggle Buttons */
#btn-toggle-lyrics,
#btn-toggle-queue {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 6px;
  border-radius: 50%;
  transition: all 0.2s ease;
}
#btn-toggle-lyrics:hover,
#btn-toggle-queue:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}
#btn-toggle-lyrics.active,
#btn-toggle-queue.active {
  color: #10b981;
  background: rgba(16, 185, 129, 0.15);
}

.lyrics-drawer,
.queue-drawer {
  position: fixed;
  right: 24px;
  bottom: 86px;
  width: 420px;
  height: calc(100vh - 120px);
  max-height: 640px;
  background: rgba(13, 15, 24, 0.96);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.75);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
  transform: translateX(120%);
  opacity: 0;
  pointer-events: none;
}

.lyrics-drawer.open,
.queue-drawer.open {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  flex-shrink: 0;
}

.drawer-header-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.drawer-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff;
}

.lyrics-provider-badge {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 12px;
  background: rgba(168, 85, 247, 0.2);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.4);
}

.drawer-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.drawer-close-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  padding: 6px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}
.drawer-close-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

.clear-queue-btn {
  background: transparent;
  border: none;
  color: #ef4444;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
}
.clear-queue-btn:hover {
  background: rgba(239, 68, 68, 0.1);
}

.drawer-song-meta {
  padding: 12px 20px;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  flex-shrink: 0;
}
.drawer-song-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.drawer-song-artist {
  font-size: 0.8rem;
  color: #94a3b8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lyrics-scroll-container,
.queue-scroll-container {
  flex: 1;
  overflow-y: auto;
  padding: 20px 24px;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.lyrics-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 250px;
  text-align: center;
  color: #64748b;
  gap: 12px;
}
.lyrics-placeholder p {
  font-size: 0.9rem;
  max-width: 240px;
}

.lyrics-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 200px;
  gap: 12px;
  color: #94a3b8;
}

.lyrics-spinner {
  width: 32px;
  height: 32px;
  border: 3px solid rgba(255, 255, 255, 0.1);
  border-top-color: var(--accent-purple, #8b5cf6);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.lyrics-lines-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.lyric-line {
  padding: 10px 14px;
  font-size: 1.15rem;
  line-height: 1.55;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.35);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}
.lyric-line:hover {
  color: rgba(255, 255, 255, 0.85);
  background: rgba(255, 255, 255, 0.04);
}
.lyric-line.passed {
  color: rgba(255, 255, 255, 0.6);
}
.lyric-line.active {
  font-size: 1.35rem;
  font-weight: 700;
  color: #ffffff;
  background: rgba(168, 85, 247, 0.18);
  border-left: 3px solid #a855f7;
  transform: translateX(4px);
  text-shadow: 0 0 20px rgba(168, 85, 247, 0.4);
}

.plain-lyrics-view {
  padding: 8px 0;
}
.plain-lyrics-badge {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  color: #94a3b8;
  margin-bottom: 12px;
}
.plain-lyrics-text {
  font-family: inherit;
  font-size: 1.05rem;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.85);
  white-space: pre-wrap;
  word-break: break-word;
}

/* Queue Drawer Song Items */
.queue-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 8px;
  transition: background 0.15s ease;
  cursor: pointer;
}
.queue-item:hover {
  background: rgba(255, 255, 255, 0.05);
}
.queue-item.current {
  background: rgba(168, 85, 247, 0.12);
  border: 1px solid rgba(168, 85, 247, 0.3);
}
.queue-item-thumb {
  width: 40px;
  height: 40px;
  border-radius: 4px;
  object-fit: cover;
  flex-shrink: 0;
}
.queue-item-info {
  flex: 1;
  min-width: 0;
}
.queue-item-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.queue-item-artist {
  font-size: 0.76rem;
  color: #94a3b8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.queue-item-remove-btn {
  background: transparent;
  border: none;
  color: #64748b;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
}
.queue-item-remove-btn:hover {
  color: #ef4444;
}

/* ==========================================================================
   MOBILE EXPANDED PLAYER VIEW MODES (PHASE 8 & 9)
   ========================================================================== */
.expanded-player-tabs {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 8px 0 14px;
  background: rgba(255, 255, 255, 0.07);
  padding: 4px;
  border-radius: 20px;
  width: fit-content;
  align-self: center;
}

.expanded-tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 16px;
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}
.expanded-tab-btn.active {
  background: #ffffff;
  color: #0b0c15;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.expanded-tab-pane {
  display: none;
  width: 100%;
  flex: 1;
  min-height: 0;
}
.expanded-tab-pane.active {
  display: flex;
  flex-direction: column;
}

.mobile-lyrics-scroll {
  flex: 1;
  overflow-y: auto;
  max-height: 40vh;
  padding: 10px 14px;
  mask-image: linear-gradient(to bottom, transparent 0%, black 10%, black 90%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 10%, black 90%, transparent 100%);
}

.mobile-lyrics-scroll .lyric-line {
  font-size: 1.15rem;
  padding: 10px 12px;
  text-align: center;
}
.mobile-lyrics-scroll .lyric-line.active {
  font-size: 1.35rem;
  border-left: none;
  border-radius: 12px;
}

.mobile-queue-scroll {
  flex: 1;
  overflow-y: auto;
  max-height: 40vh;
  padding: 6px 10px;
}

/* ==========================================================================
   MINIMAL SIGN IN POPUP (REQUIRED FOR PLAYBACK)
   ========================================================================== */
.auth-gate-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100vw;
  height: 100vh;
  z-index: 99999999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(5, 7, 16, 0.72);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  padding: 20px;
  box-sizing: border-box;
  opacity: 1;
  visibility: visible;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.25s ease;
}

.auth-gate-modal.hidden {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

/* Minimal Luxury Glassmorphic Card */
.auth-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 360px;
  margin: auto;
  background: linear-gradient(175deg, rgba(22, 26, 45, 0.95) 0%, rgba(12, 14, 25, 0.98) 100%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 28px;
  padding: 36px 28px 30px;
  text-align: center;
  box-shadow: 0 35px 80px -15px rgba(0, 0, 0, 0.85),
              0 0 1px 1px rgba(255, 255, 255, 0.12),
              inset 0 1px 1px rgba(255, 255, 255, 0.2);
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow: hidden;
  animation: authCardEntrance 0.32s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes authCardEntrance {
  0% {
    opacity: 0;
    transform: translateY(18px) scale(0.96);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.auth-close-btn {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.08);
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  z-index: 2;
}

.auth-close-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  color: #ffffff;
  transform: scale(1.08);
}

.auth-card-glow {
  position: absolute;
  top: 0;
  left: 20%;
  right: 20%;
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, rgba(16, 185, 129, 0.85) 30%, rgba(168, 85, 247, 0.95) 70%, transparent 100%);
  filter: blur(1px);
}

.auth-icon-circle {
  width: 60px;
  height: 60px;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.16), rgba(168, 85, 247, 0.16));
  border: 1px solid rgba(255, 255, 255, 0.14);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.4);
}

.auth-icon-img {
  width: 34px;
  height: 34px;
  border-radius: 8px;
}

.auth-title {
  font-size: 1.45rem;
  font-weight: 700;
  color: #ffffff;
  margin: 0 0 20px;
  letter-spacing: -0.025em;
  font-family: 'Plus Jakarta Sans', var(--font-main);
}

/* Sign In with Google Button */
.btn-google-signin {
  position: relative;
  width: 100%;
  height: 50px;
  border-radius: 9999px;
  background: #ffffff;
  color: #0f172a;
  border: none;
  font-size: 0.98rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(255, 255, 255, 0.2);
  overflow: hidden;
}

.btn-google-signin:hover {
  background: #f8fafc;
  transform: translateY(-1.5px);
  box-shadow: 0 8px 24px rgba(255, 255, 255, 0.2), 0 4px 14px rgba(0, 0, 0, 0.4);
}

.btn-google-signin:active {
  transform: translateY(0) scale(0.985);
}

.btn-google-signin:disabled {
  opacity: 0.75;
  cursor: not-allowed;
  transform: none;
}

.google-icon-svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.btn-spinner {
  width: 15px;
  height: 15px;
  border: 2px solid rgba(0, 0, 0, 0.2);
  border-top-color: #0f172a;
  border-radius: 50%;
  animation: authSpin 0.7s linear infinite;
}

@keyframes authSpin {
  to { transform: rotate(360deg); }
}

/* Dynamic Error Banner */
.auth-error-banner {
  display: none;
  width: 100%;
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: #fca5a5;
  font-size: 0.82rem;
  padding: 8px 12px;
  border-radius: 12px;
  margin-bottom: 16px;
  text-align: center;
  line-height: 1.4;
}

/* Profile Modal Logout Button */
.btn-logout {
  width: 100%;
  margin-top: 20px;
  padding: 12px 18px;
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.25);
  border-radius: 14px;
  color: #ef4444;
  font-size: 0.9rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-logout:hover {
  background: rgba(239, 68, 68, 0.16);
  border-color: rgba(239, 68, 68, 0.45);
  color: #ff6b6b;
}

@media (max-width: 520px) {
  .auth-card {
    padding: 30px 20px 24px;
    border-radius: 24px;
    max-width: 320px;
  }
  .auth-title {
    font-size: 1.3rem;
  }
  .btn-google-signin {
    height: 48px;
    font-size: 0.94rem;
  }
}

/* ==========================================================================
   SEAMLESS IN-APP SETTINGS STUDIO OVERLAY (CONTINUOUS PLAYBACK ENGINE)
   ========================================================================== */
.settings-app-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  z-index: 10000;
  background: var(--bg-primary, #000000);
  display: flex;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.24s cubic-bezier(0.16, 1, 0.3, 1), transform 0.24s cubic-bezier(0.16, 1, 0.3, 1);
  transform: translateY(10px);
}

.settings-app-overlay.open {
  display: flex !important;
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.settings-app-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 18px;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
  height: 54px;
  box-sizing: border-box;
  flex-shrink: 0;
  z-index: 20;
}

body.theme-light .settings-app-topbar {
  background: rgba(255, 255, 255, 0.94);
  border-bottom-color: rgba(0, 0, 0, 0.08);
}

.settings-app-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-primary, #ffffff);
  font-family: inherit;
  font-size: 0.88rem;
  font-weight: 600;
  padding: 7px 14px;
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

body.theme-light .settings-app-back-btn {
  background: rgba(0, 0, 0, 0.05);
  border-color: rgba(0, 0, 0, 0.1);
  color: #0f172a;
}

.settings-app-back-btn:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.24);
  transform: translateX(-2px);
}

.settings-app-playing-indicator {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.28);
  border-radius: 9999px;
  padding: 4px 12px 4px 10px;
  max-width: 55vw;
}

.playing-bars {
  display: flex;
  align-items: flex-end;
  gap: 2.5px;
  height: 14px;
  width: 14px;
}

.playing-bars .bar {
  width: 3px;
  background: var(--accent-teal, #10b981);
  border-radius: 2px;
  animation: settingsBarWave 1.2s ease-in-out infinite alternate;
}

.playing-bars .bar-1 { height: 40%; animation-delay: 0.1s; }
.playing-bars .bar-2 { height: 100%; animation-delay: 0.35s; }
.playing-bars .bar-3 { height: 60%; animation-delay: 0.2s; }

.settings-app-overlay.is-paused .playing-bars .bar {
  animation: none !important;
  height: 3px !important;
}

@keyframes settingsBarWave {
  0% { height: 20%; }
  50% { height: 100%; }
  100% { height: 40%; }
}

.playing-song-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary, #ffffff);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 180px;
}

body.theme-light .playing-song-name {
  color: #0f172a;
}

.settings-mini-playpause-btn {
  background: none;
  border: none;
  color: var(--accent-teal, #10b981);
  cursor: pointer;
  padding: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: transform 0.15s ease;
}

.settings-mini-playpause-btn:hover {
  transform: scale(1.15);
}

.settings-app-frame-wrapper {
  flex: 1;
  width: 100%;
  height: calc(100% - 54px);
  position: relative;
  overflow: hidden;
  background: var(--bg-primary, #000000);
}

.settings-app-frame {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
  background: var(--bg-primary, #000000);
}

/* ==========================================================================
   WORLD-CLASS PLAYER ENGINE STYLES (60 FPS, IMMERSIVE & ULTRA-PREMIUM)
   ========================================================================== */

/* Playback Speed Badge & Button */
.speed-toggle-btn {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  padding: 3px 8px !important;
  border-radius: 8px !important;
  background: rgba(255, 255, 255, 0.08) !important;
  border: 1px solid rgba(255, 255, 255, 0.14) !important;
  color: var(--text-secondary, #94a3b8) !important;
  font-family: var(--font-mono, 'JetBrains Mono', monospace) !important;
  font-size: 0.76rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.3px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
  user-select: none;
}

.speed-toggle-btn:hover {
  background: rgba(255, 255, 255, 0.18) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.3) !important;
  transform: scale(1.05);
}

.speed-toggle-btn.custom-speed {
  background: rgba(16, 185, 129, 0.15) !important;
  border-color: var(--accent-teal, #10b981) !important;
  color: var(--accent-teal, #10b981) !important;
}

/* Enhanced Seekbar Buffer & Hover Tooltip */
.seekbar-buffer {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0%;
  background: rgba(255, 255, 255, 0.28);
  border-radius: 2px;
  pointer-events: none;
  transition: width 0.2s linear;
  z-index: 1;
}

.seekbar-progress {
  z-index: 2;
}

.seekbar-hover-time {
  z-index: 10;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: 6px;
  padding: 3px 7px;
  font-weight: 600;
  pointer-events: none;
  transition: opacity 0.12s ease;
}

/* Like Heart Spring Pop Animation */
@keyframes heartPop {
  0% { transform: scale(1); }
  40% { transform: scale(1.36); }
  75% { transform: scale(0.92); }
  100% { transform: scale(1); }
}

.track-like-btn.liked svg,
.player-heart-btn.liked svg,
.mini-heart-btn.liked svg,
.immersive-heart-btn.liked svg {
  animation: heartPop 0.36s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  color: var(--accent-teal, #10b981) !important;
  fill: currentColor !important;
}

.mini-heart-btn {
  background: none;
  border: none;
  color: var(--text-muted, rgba(255, 255, 255, 0.5));
  cursor: pointer;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: color 0.2s ease, transform 0.2s ease;
}

.mini-heart-btn:hover {
  color: #ffffff;
  transform: scale(1.1);
}

/* ==========================================================================
   IMMERSIVE FULL-SCREEN DESKTOP PLAYER
   ========================================================================== */
.desktop-immersive-player {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100vw;
  height: 100vh;
  z-index: 9990;
  background: #000000;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  transform: scale(0.98);
}

.desktop-immersive-player.open {
  display: flex !important;
  opacity: 1;
  pointer-events: auto;
  transform: scale(1);
}

.immersive-ambient-backdrop {
  position: absolute;
  top: -20%;
  left: -20%;
  width: 140%;
  height: 140%;
  background-size: cover;
  background-position: center;
  filter: blur(80px) saturate(180%) brightness(0.28);
  -webkit-filter: blur(80px) saturate(180%) brightness(0.28);
  opacity: 0.85;
  pointer-events: none;
  transform: scale(1.1);
  transition: background-image 0.8s ease;
  z-index: 1;
}

.immersive-container {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 24px 40px;
  box-sizing: border-box;
}

/* Immersive Top Bar */
.immersive-top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
  flex-shrink: 0;
}

.immersive-brand-meta {
  display: flex;
  align-items: center;
  gap: 12px;
}

.immersive-brand-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

.immersive-meta-titles {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.immersive-eyebrow {
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 1.2px;
  color: var(--accent-teal, #10b981);
}

.immersive-context-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #ffffff;
}

.immersive-top-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.immersive-exit-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #ffffff;
  padding: 8px;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.2s ease;
}

.immersive-exit-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.1);
}

/* Immersive Center Stage */
.immersive-stage {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 60px;
  min-height: 0;
  padding: 20px 0;
}

/* Left Column: Vinyl + Glow Artwork */
.immersive-art-column {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 480px;
}

.immersive-art-viewport {
  position: relative;
  width: 360px;
  height: 360px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.immersive-art-glow {
  position: absolute;
  top: 10%;
  left: 10%;
  width: 80%;
  height: 80%;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent-teal, #10b981) 0%, transparent 70%);
  filter: blur(40px);
  opacity: 0.45;
  animation: artGlowPulse 4s ease-in-out infinite alternate;
}

@keyframes artGlowPulse {
  0% { transform: scale(0.9); opacity: 0.3; }
  100% { transform: scale(1.15); opacity: 0.6; }
}

.immersive-vinyl-disc {
  position: absolute;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: radial-gradient(circle, #111 25%, #050505 50%, #151515 75%, #000 100%);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8), inset 0 0 10px rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  right: -30px;
  top: 20px;
  z-index: 1;
  animation: vinylSpin 14s linear infinite;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.desktop-immersive-player.is-paused .immersive-vinyl-disc {
  animation-play-state: paused;
}

@keyframes vinylSpin {
  to { transform: rotate(360deg); }
}

.vinyl-center-label {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid #111;
}

.immersive-main-art {
  position: relative;
  z-index: 2;
  width: 340px;
  height: 340px;
  border-radius: 20px;
  object-fit: cover;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.1);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.immersive-main-art:hover {
  transform: scale(1.02);
}

.immersive-track-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  margin-top: 28px;
  padding: 0 10px;
}

.immersive-track-details {
  min-width: 0;
  flex: 1;
}

.immersive-song-title {
  font-size: 1.6rem;
  font-weight: 800;
  color: #ffffff;
  margin: 0 0 6px 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -0.5px;
}

.immersive-song-artist {
  font-size: 1.05rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.7);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Right Column: Synced Lyrics Viewport */
.immersive-lyrics-column {
  flex: 1.2;
  height: 100%;
  display: flex;
  flex-direction: column;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  padding: 24px 32px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.immersive-lyrics-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.lyrics-header-tag {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 1.5px;
  color: var(--accent-teal, #10b981);
}

.immersive-lyrics-scroll {
  flex: 1;
  overflow-y: auto;
  scroll-behavior: smooth;
  padding: 20px 0;
  mask-image: linear-gradient(to bottom, transparent 0%, black 15%, black 85%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 15%, black 85%, transparent 100%);
}

.immersive-lyrics-scroll .lyric-line {
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.4);
  padding: 10px 0;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  transform-origin: left center;
}

.immersive-lyrics-scroll .lyric-line:hover {
  color: rgba(255, 255, 255, 0.85);
  transform: translateX(4px);
}

.immersive-lyrics-scroll .lyric-line.active {
  font-size: 1.65rem;
  color: #ffffff;
  text-shadow: 0 0 20px rgba(16, 185, 129, 0.6);
  transform: scale(1.04);
}

.immersive-lyrics-scroll .lyric-line.passed {
  color: rgba(255, 255, 255, 0.6);
}

/* Immersive Bottom Controls */
.immersive-bottom-bar {
  display: flex;
  flex-direction: column;
  gap: 16px;
  flex-shrink: 0;
  padding-top: 10px;
}

.immersive-controls-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.immersive-left-tools,
.immersive-right-tools {
  width: 200px;
  display: flex;
  align-items: center;
}

.immersive-right-tools {
  justify-content: flex-end;
}

.immersive-center-controls {
  display: flex;
  align-items: center;
  gap: 24px;
}

.immersive-play-circle-btn {
  width: 52px !important;
  height: 52px !important;
  background: #ffffff !important;
  color: #000000 !important;
  border-radius: 50% !important;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), background 0.2s ease !important;
}

.immersive-play-circle-btn:hover {
  transform: scale(1.08) !important;
  background: var(--accent-teal, #10b981) !important;
  color: #ffffff !important;
}

/* Responsiveness for Immersive Player */
@media (max-width: 1080px) {
  .immersive-stage {
    flex-direction: column;
    overflow-y: auto;
  }
  .immersive-art-viewport {
    width: 260px;
    height: 260px;
  }
  .immersive-main-art {
    width: 240px;
    height: 240px;
  }
  .immersive-vinyl-disc {
    width: 220px;
    height: 220px;
  }
  .immersive-lyrics-column {
    width: 100%;
    min-height: 280px;
  }
}

/* ==========================================================================
   QUEUE MANAGEMENT & REORDERING SUITE (60 FPS Hardware-Accelerated)
   ========================================================================== */
.queue-header-summary {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent-teal, #10b981);
  padding: 0.5rem 0.75rem 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 0.5rem;
}

.queue-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.18s cubic-bezier(0.16, 1, 0.3, 1), transform 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

.queue-item:hover {
  background: rgba(255, 255, 255, 0.06);
  transform: translateX(2px);
}

.queue-item.current {
  background: rgba(16, 185, 129, 0.12);
  border-left: 3px solid var(--accent-teal, #10b981);
}

.queue-item-thumb {
  width: 44px;
  height: 44px;
  border-radius: 6px;
  object-fit: cover;
  flex-shrink: 0;
}

.queue-item-info {
  flex: 1;
  min-width: 0;
}

.queue-item-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.queue-item-artist {
  font-size: 0.75rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.queue-reorder-actions {
  display: flex;
  flex-direction: column;
  gap: 2px;
  opacity: 0.5;
  transition: opacity 0.2s ease;
}

.queue-item:hover .queue-reorder-actions {
  opacity: 1;
}

.queue-move-btn {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.7);
  font-size: 9px;
  width: 22px;
  height: 18px;
  padding: 0;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.queue-move-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
}

.queue-item-remove-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  padding: 6px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s ease, transform 0.15s ease;
}

.queue-item-remove-btn:hover {
  color: #ef4444;
  transform: scale(1.1);
}

/* Playing indicator wave inside Queue */
.queue-playing-wave {
  display: flex;
  align-items: flex-end;
  gap: 2.5px;
  height: 14px;
  padding: 0 4px;
}

.qwave-bar {
  width: 2.5px;
  height: 100%;
  background: var(--accent-teal, #10b981);
  border-radius: 2px;
  animation: qWaveAnim 1.2s ease-in-out infinite alternate;
}

.qwave-bar:nth-child(1) { animation-delay: 0s; height: 40%; }
.qwave-bar:nth-child(2) { animation-delay: 0.3s; height: 95%; }
.qwave-bar:nth-child(3) { animation-delay: 0.6s; height: 60%; }

@keyframes qWaveAnim {
  0% { height: 25%; }
  100% { height: 100%; }
}





/* ==========================================================================
   VISHVAX MUSIC — MINIMAL REDESIGNED PLAYER & SLEEP TIMER MODAL STYLES
   ========================================================================== */

/* Secondary Controls Row (Only 1x Speed & Sleep Timer) */
.player-secondary-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  margin: 10px 0 6px 0;
  flex-shrink: 0;
}

.player-secondary-controls .ctrl-btn.speed-toggle-btn,
.player-secondary-controls .ctrl-secondary-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  color: #d1d5db;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
  user-select: none;
}

.player-secondary-controls .ctrl-btn.speed-toggle-btn:hover,
.player-secondary-controls .ctrl-secondary-btn:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.2);
}

.player-secondary-controls .ctrl-btn.speed-toggle-btn:active,
.player-secondary-controls .ctrl-secondary-btn:active {
  transform: scale(0.95);
}

.player-secondary-controls .ctrl-btn.speed-toggle-btn.active,
.player-secondary-controls .ctrl-secondary-btn.active {
  background: rgba(29, 185, 84, 0.15);
  border-color: #1db954;
  color: #1db954;
}

.speed-badge {
  font-family: var(--font-mono, monospace);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.secondary-btn-text {
  font-size: 0.8rem;
  font-weight: 600;
}

/* Sleep Timer Modal (Universal Desktop & Mobile Minimal Modal) */
.sleep-timer-modal {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  box-sizing: border-box;
}

.sleep-timer-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  animation: sleepFadeIn 0.2s ease forwards;
}

.sleep-timer-sheet {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 360px;
  background: #121212;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  padding: 22px 20px 20px 20px;
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.85);
  box-sizing: border-box;
  animation: sleepPopIn 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes sleepFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes sleepPopIn {
  from { opacity: 0; transform: scale(0.95) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.sleep-timer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}

.sleep-timer-title-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #ffffff;
}

.sleep-timer-heading {
  font-size: 1.15rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.01em;
}

.sleep-timer-close {
  background: rgba(255, 255, 255, 0.08);
  border: none;
  color: #ffffff;
  font-size: 1.4rem;
  line-height: 1;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.sleep-timer-close:hover {
  background: rgba(255, 255, 255, 0.16);
}

.sleep-timer-status {
  font-size: 0.82rem;
  color: #9ca3af;
  margin-bottom: 18px;
  line-height: 1.4;
}

.sleep-timer-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sleep-option-btn {
  width: 100%;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  color: #ffffff;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
  transition: all 0.18s ease;
  box-sizing: border-box;
}

.sleep-option-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.18);
  color: #ffffff;
}

.sleep-option-btn:active {
  transform: scale(0.98);
  background: rgba(29, 185, 84, 0.18);
  border-color: #1db954;
  color: #1db954;
}

.sleep-option-btn.cancel-option {
  margin-top: 6px;
  background: rgba(239, 68, 68, 0.08);
  border-color: rgba(239, 68, 68, 0.2);
  color: #f87171;
  text-align: center;
}

.sleep-option-btn.cancel-option:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.35);
}

/* Sleep timer badges in top bars */
.sleep-timer-badge,
.sleep-timer-chip {
  font-family: var(--font-mono, monospace);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 7px;
  background: rgba(29, 185, 84, 0.2);
  border: 1px solid #1db954;
  color: #1db954;
  border-radius: 999px;
  margin-left: 6px;
  vertical-align: middle;
}

/* Dedicated Lyrics Tab Header & Typography (Supports Hindi & English) */
.lyrics-tab-header {
  padding: 12px 14px 6px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  flex-shrink: 0;
}

.lyrics-tab-song {
  font-size: 1.05rem;
  font-weight: 800;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lyrics-tab-hint {
  font-size: 0.72rem;
  color: #9ca3af;
  margin-top: 2px;
}

.mobile-lyrics-scroll {
  font-family: 'Plus Jakarta Sans', 'Inter', 'Noto Sans Devanagari', -apple-system, sans-serif;
  line-height: 1.85;
  letter-spacing: -0.01em;
}

.mobile-lyrics-scroll .lyric-line {
  padding: 8px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: text;
}

.mobile-lyrics-scroll .lyric-line:hover {
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.75);
}

.mobile-lyrics-scroll .lyric-line.active {
  color: #1db954 !important;
  font-weight: 800;
  background: rgba(29, 185, 84, 0.08);
}

/* Dedicated Queue Tab Header */
.queue-tab-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px 10px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  flex-shrink: 0;
}

.queue-tab-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #ffffff;
}

.queue-clear-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #d1d5db;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.queue-clear-btn:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.3);
  color: #f87171;
}

.queue-empty-text {
  color: #9ca3af;
  text-align: center;
  padding: 3rem 1rem;
  font-size: 0.9rem;
}

@media (max-width: 600px) {
  .sleep-timer-modal {
    align-items: flex-end;
    padding: 0;
  }

  .sleep-timer-sheet {
    max-width: 100%;
    border-radius: 24px 24px 0 0;
    padding: 20px 18px calc(env(safe-area-inset-bottom, 16px) + 16px) 18px;
    animation: sheetSlideUp 0.28s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  }
}

/* ==========================================================================
   DYNAMIC SERVER-DRIVEN DISCOVERY & PAGINATION SECTION
   ========================================================================== */
.discovery-section {
  margin-top: 1.5rem;
  margin-bottom: 3rem;
}

.discovery-pills-scroll {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 8px;
  margin-bottom: 20px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.discovery-pills-scroll::-webkit-scrollbar {
  display: none;
}

.discovery-pill {
  white-space: nowrap;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 8px 18px;
  border-radius: var(--radius-full, 999px);
  background: var(--bg-surface-elevated, #161922);
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.08));
  color: var(--text-secondary, #94a3b8);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
  user-select: none;
}

.discovery-pill:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.discovery-pill.active {
  background: var(--spotify-green, #1db954);
  color: #000000;
  font-weight: 800;
  border-color: var(--spotify-green, #1db954);
  box-shadow: 0 4px 14px rgba(29, 185, 84, 0.35);
}

.discovered-playlists-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 1.25rem;
  width: 100%;
  box-sizing: border-box;
  margin-bottom: 1.5rem;
}

@media (max-width: 600px) {
  .discovered-playlists-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
}

.discovery-pagination-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 1.5rem 0 2.5rem 0;
  width: 100%;
}

.btn-load-more-playlists {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: var(--bg-surface-elevated, #161922);
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.12));
  color: #ffffff;
  font-size: 0.9rem;
  font-weight: 700;
  padding: 12px 28px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.22s ease;
  min-width: 200px;
}

.btn-load-more-playlists:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--spotify-green, #1db954);
  color: var(--spotify-green, #1db954);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.btn-load-more-playlists:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.load-more-spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-top-color: var(--spotify-green, #1db954);
  border-radius: 50%;
  animation: loadMoreSpin 0.75s linear infinite;
}

@keyframes loadMoreSpin {
  to { transform: rotate(360deg); }
}

.discovery-end-message {
  color: var(--text-muted, #64748b);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 12px 24px;
  text-align: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

