/* ============================================
   XRP Music - Main Stylesheet
   Clean vanilla CSS, no frameworks
   ============================================ */

/* CSS Variables */
:root {
  /* Colors - Dark Theme (default) */
  --bg-primary: #000000;
  --bg-secondary: #0a0a0a;
  --bg-card: #18181b;
  --bg-hover: #27272a;
  --bg-input: #1a1a1d;
  
  --text-primary: #ffffff;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  
  --border-color: #27272a;
  --border-light: #3f3f46;
  
  --accent: #3b82f6;
  --accent-hover: #60a5fa;
  --accent-gradient: linear-gradient(135deg, #3b82f6, #8b5cf6);
  
  --success: #22c55e;
  --warning: #f97316;
  --error: #ef4444;
  
  /* Spacing */
  --sidebar-width: 256px;
  --header-height: 64px;
  --player-height: 80px;
  --player-height-mobile: 72px;
   
  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-normal: 200ms ease;
  --transition-slow: 300ms ease;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.6);
  
  /* Border Radius */
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-2xl: 20px;
  --radius-full: 9999px;
}

/* Light Theme */
.light {
  --bg-primary: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-card: #ffffff;
  --bg-hover: #f1f5f9;
  --bg-input: #f1f5f9;
  
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  
  --border-color: #e2e8f0;
  --border-light: #cbd5e1;
  
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.15);
}

/* Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

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

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

::-webkit-scrollbar-thumb:hover {
  background: var(--border-light);
}

/* Utility Classes */
.hidden { display: none !important; }
.desktop-only { display: flex; }
.mobile-only { display: none !important; }

@media (max-width: 1024px) {
  .desktop-only { display: none !important; }
  .mobile-only { display: flex !important; }
}

/* ============================================
   Sidebar
   ============================================ */
.sidebar {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--sidebar-width);
  background: var(--bg-secondary);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: transform var(--transition-slow);
}

@media (max-width: 1024px) {
  .sidebar {
    transform: translateX(-100%);
  }
  
  .sidebar.open {
    transform: translateX(0);
  }
}

.sidebar-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  z-index: 99;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition-normal), visibility var(--transition-normal);
}

.sidebar-overlay.visible {
  opacity: 1;
  visibility: visible;
}

.sidebar-header {
  padding: 24px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-lg);
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.logo-text {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.sidebar-nav {
  flex: 1;
  padding: 0 16px;
  overflow-y: auto;
}

.nav-item {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border: none;
  border-radius: var(--radius-lg);
  background: transparent;
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-align: left;
}

.nav-item:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.nav-item.active {
  background: rgba(59, 130, 246, 0.1);
  color: var(--accent);
}

.nav-item svg {
  flex-shrink: 0;
}

.nav-item-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.nav-item-info .track-count {
  font-size: 12px;
  color: var(--text-muted);
}

.liked-icon {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, #a855f7, #ec4899);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.playlist-icon {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-md);
  background: var(--bg-hover);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--text-muted);
}

.playlist-icon.browse {
  color: var(--accent);
}

.create-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 16px;
  margin-top: 16px;
  border: none;
  border-radius: var(--radius-lg);
  background: var(--accent-gradient);
  color: white;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}

.create-btn:hover {
  transform: scale(1.02);
  opacity: 0.9;
}

/* Library Section */
.library-section {
  margin-top: 24px;
}

.library-header {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 16px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  cursor: pointer;
}

.library-header .chevron {
  transition: transform var(--transition-fast);
}

.library-header.collapsed .chevron {
  transform: rotate(-90deg);
}

.library-content {
  margin-top: 8px;
}

/* Sidebar Footer */
.sidebar-footer {
  padding: 16px;
  border-top: 1px solid var(--border-color);
}

.theme-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  margin-bottom: 12px;
  border: none;
  border-radius: var(--radius-lg);
  background: var(--bg-hover);
  color: var(--text-secondary);
  cursor: pointer;
  transition: background var(--transition-fast);
}

.theme-toggle:hover {
  background: var(--border-color);
}

.theme-toggle-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  font-weight: 500;
}

.toggle-switch {
  width: 40px;
  height: 24px;
  border-radius: var(--radius-full);
  background: var(--border-color);
  padding: 2px;
  transition: background var(--transition-fast);
}

.light .toggle-switch {
  background: var(--border-light);
}

body:not(.light) .toggle-switch {
  background: var(--accent);
}

.toggle-knob {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: white;
  transition: transform var(--transition-fast);
}

body:not(.light) .toggle-knob {
  transform: translateX(16px);
}

.connect-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 16px;
  border: none;
  border-radius: var(--radius-lg);
  background: var(--bg-hover);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background var(--transition-fast);
}

.connect-btn:hover {
  background: var(--border-color);
}

.user-card {
  padding: 12px;
  border-radius: var(--radius-lg);
  background: var(--bg-hover);
}

.user-info {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  color: white;
  font-size: 16px;
  overflow: hidden;
}

.user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

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

.user-name {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-address {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.logout-btn {
  width: 100%;
  padding: 8px;
  border: none;
  border-radius: var(--radius-md);
  background: transparent;
  color: var(--error);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background var(--transition-fast);
}

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

/* ============================================
   Main Content
   ============================================ */
.main-content {
  margin-left: var(--sidebar-width);
  min-height: 100vh;
  padding-bottom: calc(var(--player-height) + 32px);
}

@media (max-width: 1024px) {
  .main-content {
    margin-left: 0;
    padding-bottom: calc(var(--player-height-mobile) + 16px);
  }
}

/* Header */
.header {
  position: sticky;
  top: 0;
  height: var(--header-height);
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 24px;
  background: var(--bg-primary);
  border-bottom: 1px solid var(--border-color);
  z-index: 50;
  backdrop-filter: blur(12px);
  background: rgba(0, 0, 0, 0.8);
}

.light .header {
  background: rgba(255, 255, 255, 0.8);
}

@media (max-width: 1024px) {
  .header {
    padding: 0 16px;
  }
}

.menu-btn {
  display: none;
  padding: 8px;
  border: none;
  border-radius: var(--radius-md);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
}

.menu-btn:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

@media (max-width: 1024px) {
  .menu-btn {
    display: flex;
  }
}

.search-container {
  flex: 1;
  max-width: 480px;
  position: relative;
}

@media (max-width: 640px) {
  .search-container {
    display: none;
  }
}

.search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

.search-input {
  width: 100%;
  padding: 10px 40px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  background: var(--bg-input);
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
  transition: border-color var(--transition-fast);
}

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

.search-input:focus {
  border-color: var(--accent);
}

.search-clear {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  padding: 4px;
  border: none;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
}

.search-clear:hover {
  color: var(--text-primary);
}

/* ============================================
   Search Results Dropdown
   ============================================ */
.search-results {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  margin-top: 8px;
  max-height: 480px;
  overflow-y: auto;
  z-index: 1000;
  box-shadow: var(--shadow-xl);
}

.search-section {
  padding: 8px 0;
}

.search-section:not(:last-child) {
  border-bottom: 1px solid var(--border-color);
}

.search-section-title {
  padding: 8px 16px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
}

.search-result-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  cursor: pointer;
  transition: background var(--transition-fast);
}

.search-result-item:hover {
  background: var(--bg-hover);
}

.search-result-cover {
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  border-radius: var(--radius-md);
  object-fit: cover;
  flex-shrink: 0;
  background: var(--bg-hover);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  overflow: hidden;
}

.search-result-cover.artist-avatar {
  border-radius: 50%;
}

.search-result-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.search-result-info {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.search-result-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.search-result-subtitle {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}

.search-result-price {
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  white-space: nowrap;
  flex-shrink: 0;
}

.search-empty {
  padding: 40px 20px;
  text-align: center;
  color: var(--text-muted);
}

.search-empty svg {
  opacity: 0.5;
  margin-bottom: 12px;
}

.search-empty p {
  font-size: 14px;
  margin: 0;
}

/* ============================================
   Header Actions
   ============================================ */
.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-btn {
  position: relative;
  padding: 8px;
  border: none;
  border-radius: var(--radius-lg);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.header-btn:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.notification-dot {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.mobile-connect-btn {
  display: none;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border: none;
  border-radius: var(--radius-lg);
  background: var(--accent-gradient);
  color: white;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

@media (max-width: 640px) {
  .mobile-connect-btn:not(.hidden) {
    display: flex;
  }
}

/* Page Content */
.page-content {
  padding: 24px;
}

@media (max-width: 640px) {
  .page-content {
    padding: 16px;
  }
}

/* Loading Spinner */
.loading-spinner {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 300px;
}

.spinner {
  width: 32px;
  height: 32px;
  border: 3px solid var(--border-color);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

/* ============================================
   Player Bar - 3-COLUMN LAYOUT
   ============================================ */
.player-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--player-height);
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  z-index: 1100;
}

@media (max-width: 1024px) {
  .player-bar {
    height: var(--player-height-mobile);
    left: 0;
  }
}

@media (min-width: 1025px) {
  .player-bar {
    left: var(--sidebar-width);
  }
}

.player-progress {
  height: 4px;
  background: var(--border-color);
  cursor: pointer;
}

.player-progress-fill {
  height: 100%;
  background: var(--accent);
  width: 0%;
  transition: width 100ms linear;
}

.player-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: calc(100% - 4px);
  padding: 0 16px;
}

@media (min-width: 1025px) {
  .player-content {
    padding: 0 24px;
  }
}

/* LEFT COLUMN: Track Info */
.player-left {
  flex: 1;
  min-width: 180px;
  max-width: 300px;
}

.player-track {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.player-cover {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  object-fit: cover;
  background: var(--bg-hover);
  flex-shrink: 0;
}

@media (max-width: 1024px) {
  .player-cover {
    width: 52px;
    height: 52px;
    min-width: 52px;
  }
}

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

.player-title {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player-artist {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player-expand-btn {
  display: none;
  padding: 8px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
}

@media (max-width: 1024px) {
  .player-expand-btn {
    display: block;
  }
}

/* CENTER COLUMN: Main Controls */
.player-center {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

.player-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

/* RIGHT COLUMN: Like, Add, Repeat, Volume */
.player-right {
  flex: 1;
  min-width: 180px;
  max-width: 300px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 4px;
}

.player-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.player-action-btn {
  padding: 8px;
  border: none;
  border-radius: var(--radius-full);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.player-action-btn:hover {
  color: var(--text-primary);
}

.player-action-btn.liked {
  color: var(--error);
}

.player-action-btn.liked svg {
  fill: currentColor;
}

/* Control Buttons */
.control-btn {
  padding: 8px;
  border: none;
  border-radius: var(--radius-full);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
}

.control-btn:hover {
  color: var(--text-primary);
}

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

.control-btn.play-btn {
  width: 40px;
  height: 40px;
  background: var(--accent);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 8px;
}

.control-btn.play-btn:hover {
  background: var(--accent-hover);
  color: white;
  transform: scale(1.05);
}

#repeat-btn,
#expanded-repeat-btn {
  color: var(--text-muted);
  transition: color var(--transition-fast);
}

#repeat-btn:hover,
#expanded-repeat-btn:hover {
  color: var(--text-primary);
}

#repeat-btn.active,
#expanded-repeat-btn.active {
  color: var(--accent) !important;
}

.mobile-play-btn {
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
}

.mobile-play-btn:hover {
  background: var(--accent-hover);
}

/* Volume */
.player-volume {
  display: flex;
  align-items: center;
  gap: 8px;
}

.volume-slider {
  width: 100px;
  height: 4px;
  -webkit-appearance: none;
  appearance: none;
  background: var(--border-color);
  border-radius: 2px;
  outline: none;
  cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  cursor: pointer;
  transition: transform var(--transition-fast);
}

.volume-slider::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}

.volume-slider::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  cursor: pointer;
  border: none;
}

/* ============================================
   Mobile Player Bar
   ============================================ */
@media (max-width: 1024px) {
  .player-bar {
    height: 72px;
  }
  
  .player-content {
    padding: 0 16px;
    gap: 12px;
  }
  
  .player-cover {
    width: 52px;
    height: 52px;
    min-width: 52px;
    border-radius: var(--radius-md);
  }
  
  .player-track-details {
    flex: 1;
    min-width: 0;
    margin-right: 8px;
  }
  
  .player-title {
    font-size: 14px;
    font-weight: 600;
  }
  
  .player-artist {
    font-size: 12px;
  }
  
  .player-center,
  .player-right {
    display: none;
  }
  
  .player-left {
    flex: 1;
    max-width: none;
  }
  
  .player-controls-mobile {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
  }
  
  #mobile-prev-btn,
  #mobile-next-btn {
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  #mobile-play-btn {
    width: 48px;
    height: 48px;
    min-width: 48px;
    min-height: 48px;
    margin: 0 4px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: var(--accent);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  .player-expand-btn {
    width: 40px;
    height: 40px;
    min-width: 40px;
    padding: 0;
    border: none;
    background: transparent;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
  }
}

/* ============================================
   Expanded Mobile Player (legacy)
   ============================================ */
.expanded-player {
  position: fixed;
  inset: 0;
  background: var(--bg-secondary);
  z-index: 200;
  display: flex;
  flex-direction: column;
  padding: 16px;
}

.expanded-player-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  color: var(--text-primary);
  font-weight: 500;
}

.collapse-btn {
  padding: 8px;
  border: none;
  background: transparent;
  color: var(--text-primary);
  cursor: pointer;
}

.expanded-player-cover {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
}

.expanded-player-cover img {
  width: 100%;
  max-width: 320px;
  aspect-ratio: 1;
  border-radius: var(--radius-xl);
  object-fit: cover;
  box-shadow: var(--shadow-xl);
}

.expanded-player-info {
  text-align: center;
  padding: 0 16px;
}

.expanded-player-info h2 {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.expanded-player-info p {
  font-size: 16px;
  color: var(--text-muted);
}

.expanded-player-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 16px;
}

.expanded-action-btn {
  padding: 12px;
  border: none;
  border-radius: 50%;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
}

.expanded-action-btn.liked {
  color: var(--error);
}

.expanded-action-btn.liked svg {
  fill: currentColor;
}

.expanded-player-progress {
  padding: 0 24px;
}

.progress-bar {
  height: 4px;
  background: var(--border-color);
  border-radius: 2px;
  cursor: pointer;
  position: relative;
}

.progress-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 2px;
  position: relative;
}

.progress-knob {
  position: absolute;
  right: -6px;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
}

.progress-times {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 12px;
  color: var(--text-muted);
}

.expanded-player-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 24px;
}

.expanded-control-btn {
  padding: 8px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: color var(--transition-fast);
}

.expanded-control-btn:hover {
  color: var(--text-primary);
}

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

.expanded-play-btn {
  width: 64px;
  height: 64px;
  border: none;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform var(--transition-fast);
}

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

.expanded-player-volume {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding-bottom: 32px;
  color: var(--text-muted);
}

.expanded-player-volume .volume-slider {
  width: 140px;
}

/* ============================================
   Cards & Grids
   ============================================ */
.section-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.release-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
}

@media (min-width: 640px) {
  .release-grid {
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
  }
}

.release-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  overflow: hidden;
  cursor: pointer;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.release-card:hover {
  transform: scale(1.02);
  border-color: var(--border-light);
}

.release-card-cover {
  position: relative;
  aspect-ratio: 1;
}

.release-card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.release-card-cover .placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-hover);
  color: var(--text-muted);
}

.release-type-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 2px 8px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  border-radius: var(--radius-sm);
  color: white;
}

.release-type-badge.single { background: var(--success); }
.release-type-badge.album { background: #a855f7; }
.release-type-badge.ep { background: var(--accent); }

.release-availability {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 500;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  border-radius: var(--radius-full);
  color: white;
}

.release-sold-out {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.5);
}

.release-sold-out span {
  padding: 4px 12px;
  background: var(--error);
  color: white;
  font-size: 11px;
  font-weight: 700;
  border-radius: var(--radius-sm);
}

.release-play-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0);
  opacity: 0;
  transition: all var(--transition-fast);
}

.release-card:hover .release-play-overlay {
  background: rgba(0, 0, 0, 0.4);
  opacity: 1;
}

.release-play-btn {
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: var(--accent);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transform: scale(0.8);
  transition: transform var(--transition-fast);
}

.release-card:hover .release-play-btn {
  transform: scale(1);
}

.release-card-info {
  padding: 12px;
}

.release-card-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 4px;
}

.release-card-artist {
  font-size: 13px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 8px;
}

.release-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.release-card-price {
  font-size: 14px;
  font-weight: 700;
  color: var(--accent);
}

.release-card-tracks {
  font-size: 12px;
  color: var(--text-muted);
}

/* Track List */
.track-list {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  overflow: hidden;
}

.track-item {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 12px;
  cursor: pointer;
  transition: background var(--transition-fast);
  border-bottom: 1px solid var(--border-color);
}

.track-item:last-child {
  border-bottom: none;
}

.track-item:hover {
  background: var(--bg-hover);
}

.track-item.playing {
  background: rgba(59, 130, 246, 0.1);
}

.track-cover {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  overflow: hidden;
  position: relative;
  flex-shrink: 0;
}

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

.track-playing-indicator {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.5);
  border-radius: var(--radius-md);
}

.track-playing-bars {
  display: flex;
  gap: 2px;
  align-items: flex-end;
  height: 16px;
}

.track-playing-bars span {
  width: 3px;
  background: var(--success);
  border-radius: 2px;
  animation: playingBars 0.5s ease infinite alternate;
}

.track-playing-bars span:nth-child(2) { animation-delay: 0.15s; }
.track-playing-bars span:nth-child(3) { animation-delay: 0.3s; }

@keyframes playingBars {
  from { height: 4px; }
  to { height: 16px; }
}

.track-info {
  min-width: 0;
}

.track-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.track-item.playing .track-title {
  color: var(--accent);
}

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

.track-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  text-align: right;
}

.track-price {
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
}

.track-availability {
  font-size: 11px;
  color: var(--text-muted);
}

.track-availability.low {
  color: var(--warning);
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

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

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  padding: 16px;
  text-align: center;
}

.stat-value {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 4px;
}

.stat-label {
  font-size: 13px;
  color: var(--text-muted);
}

/* Empty State */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 64px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  text-align: center;
}

.empty-state svg {
  width: 64px;
  height: 64px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.empty-state h3 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.empty-state p {
  font-size: 14px;
  color: var(--text-muted);
  max-width: 300px;
}

/* ============================================
   Modals
   ============================================ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(4px);
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  padding-bottom: calc(16px + var(--player-height) + 16px);
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-normal);
}

.modal-overlay.visible {
  opacity: 1;
  visibility: visible;
}

.modal {
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-2xl);
  overflow: hidden;
  transform: scale(0.95);
  transition: transform var(--transition-normal);
}

.modal-overlay.visible .modal {
  transform: scale(1);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-color);
}

.modal-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
}

.modal-close {
  padding: 8px;
  border: none;
  border-radius: var(--radius-md);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.modal-close:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.modal-body {
  padding: 24px;
  overflow-y: auto;
  max-height: calc(90vh - 80px);
  padding-bottom: calc(24px + var(--player-height) + 16px);
}

/* When player is visible, ensure modals have enough bottom space */
body:has(#player-bar:not(.hidden)) .modal-body {
  padding-bottom: calc(24px + var(--player-height) + 16px);
}

.modal-body.player-active {
  padding-bottom: calc(24px + var(--player-height) + 16px);
}

/* ============================================
   FIX 1: Player-Aware Modal & Track List Spacing
   When player is active, shrink modal and pad track list
   ============================================ */
body.player-active .release-track-list {
  padding-bottom: calc(24px + var(--player-height, 80px) + 16px) !important;
}

@media (max-width: 640px) {
  body.player-active .release-track-list {
    padding-bottom: calc(24px + var(--player-height-mobile, 72px) + 16px) !important;
  }
  
  body.player-active .modal-overlay .modal {
    max-height: calc(100dvh - 40px - var(--player-height-mobile, 72px)) !important;
  }
}

@media (min-width: 641px) {
  body.player-active .modal-overlay .modal {
    max-height: calc(100vh - 80px - var(--player-height, 80px)) !important;
  }
}

/* ============================================
   FIX 2: Mobile Share Button Per Track Row
   Always visible share icon on mobile track rows
   ============================================ */
.track-share-mobile {
  display: none; /* Hidden on desktop */
}

@media (max-width: 640px) {
  .track-share-mobile {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: none;
    background: none;
    color: var(--text-muted);
    cursor: pointer;
    flex-shrink: 0;
    padding: 0;
    border-radius: 50%;
    transition: all 150ms;
    -webkit-tap-highlight-color: transparent;
  }
  
  .track-share-mobile:active {
    background: var(--bg-hover);
    color: var(--text-primary);
  }
  
  /* Adjust track row grid on mobile to fit share button */
  .release-track-list .track-row {
    grid-template-columns: 40px 1fr 32px auto !important;
    gap: 4px !important;
  }
}

/* ============================================
   FIX 3: Spotify-Style Now Playing View
   Full-screen overlay with album art, controls, buy & share
   ============================================ */
.now-playing-overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: var(--bg-primary);
  display: flex;
  flex-direction: column;
  animation: npSlideUp 300ms cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.now-playing-overlay.closing {
  animation: npSlideDown 250ms ease-in forwards;
}

@keyframes npSlideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

@keyframes npSlideDown {
  from { transform: translateY(0); }
  to { transform: translateY(100%); }
}

/* Blurred album art background */
.np-background {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.np-background::before {
  content: '';
  position: absolute;
  inset: -50%;
  background-image: var(--np-cover-url);
  background-size: cover;
  background-position: center;
  filter: blur(80px) brightness(0.3) saturate(1.5);
  transform: scale(1.5);
}

.np-background::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.3) 0%,
    rgba(0, 0, 0, 0.5) 50%,
    rgba(0, 0, 0, 0.8) 100%
  );
}

/* Header */
.np-header {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  flex-shrink: 0;
}

.np-close-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: none;
  background: none;
  color: white;
  cursor: pointer;
  border-radius: 50%;
  transition: background 150ms;
}

.np-close-btn:hover {
  background: rgba(255, 255, 255, 0.1);
}

.np-header-title {
  font-size: 13px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.7);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.np-header-spacer {
  width: 40px;
}

/* Main content */
.np-content {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 32px;
  gap: 32px;
  overflow: hidden;
}

/* Album art */
.np-cover {
  width: min(70vw, 380px);
  height: min(70vw, 380px);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
  flex-shrink: 0;
}

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

/* Track info */
.np-info {
  text-align: center;
  width: 100%;
  max-width: 400px;
}

.np-title {
  font-size: 22px;
  font-weight: 700;
  color: white;
  margin-bottom: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.np-artist {
  font-size: 15px;
  color: rgba(255, 255, 255, 0.7);
  cursor: pointer;
}

.np-artist:hover {
  color: white;
  text-decoration: underline;
}

/* Progress bar */
.np-progress {
  width: 100%;
  max-width: 400px;
}

.np-progress-bar {
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 2px;
  cursor: pointer;
  position: relative;
}

.np-progress-bar:hover {
  height: 6px;
}

.np-progress-fill {
  height: 100%;
  background: white;
  border-radius: 2px;
  transition: width 100ms linear;
  position: relative;
}

.np-progress-fill::after {
  content: '';
  position: absolute;
  right: -6px;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  background: white;
  border-radius: 50%;
  opacity: 0;
  transition: opacity 150ms;
}

.np-progress-bar:hover .np-progress-fill::after {
  opacity: 1;
}

.np-times {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
  font-variant-numeric: tabular-nums;
}

/* Playback controls */
.np-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
}

.np-ctrl-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  background: none;
  color: white;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  transition: all 150ms;
}

.np-ctrl-btn:hover {
  transform: scale(1.1);
}

.np-ctrl-btn.np-play-btn {
  width: 56px;
  height: 56px;
  background: white;
  color: black;
  border-radius: 50%;
}

.np-ctrl-btn.np-play-btn:hover {
  transform: scale(1.08);
  background: rgba(255, 255, 255, 0.95);
}

/* Action buttons: Buy + Share */
.np-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  max-width: 400px;
  justify-content: center;
}

.np-buy-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: var(--accent, #3b82f6);
  color: white;
  border: none;
  border-radius: 100px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 150ms;
}

.np-buy-btn:hover {
  transform: scale(1.03);
  filter: brightness(1.1);
}

.np-buy-btn svg {
  flex-shrink: 0;
}

.np-share-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.1);
  color: white;
  border-radius: 50%;
  cursor: pointer;
  transition: all 150ms;
}

.np-share-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.5);
}

/* Now Playing toast */
.np-toast {
  position: absolute;
  bottom: 120px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(20px);
  color: white;
  padding: 10px 20px;
  border-radius: 100px;
  font-size: 14px;
  font-weight: 500;
  z-index: 10;
  animation: npToastIn 200ms ease, npToastOut 200ms ease 2s forwards;
}

@keyframes npToastIn {
  from { opacity: 0; transform: translateX(-50%) translateY(10px); }
  to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

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

/* Bottom safe area for phones with gesture bars */
.np-bottom-safe {
  position: relative;
  z-index: 1;
  height: env(safe-area-inset-bottom, 0px);
  flex-shrink: 0;
}

/* Desktop Now Playing adjustments */
@media (min-width: 641px) {
  .np-cover {
    width: min(45vh, 400px);
    height: min(45vh, 400px);
  }
  
  .np-content {
    gap: 24px;
    padding: 0 48px;
  }
  
  .np-title {
    font-size: 28px;
  }
  
  .np-artist {
    font-size: 16px;
  }
}

/* Small phones */
@media (max-height: 700px) {
  .np-cover {
    width: min(55vw, 280px);
    height: min(55vw, 280px);
  }
  
  .np-content {
    gap: 20px;
  }
  
  .np-title {
    font-size: 18px;
  }
}

/* ============================================
   Auth Modal
   ============================================ */
.auth-modal .modal {
  max-width: 420px;
}

.auth-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}

.auth-logo {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-lg);
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.auth-brand {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
}

.auth-title {
  font-size: 20px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.auth-description {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.xaman-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  background: var(--bg-hover);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.xaman-btn:hover {
  border-color: var(--border-light);
  background: var(--border-color);
}

.xaman-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.xaman-btn img {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-lg);
}

.xaman-btn-info {
  text-align: left;
  flex: 1;
}

.xaman-btn-title {
  display: block;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}

.xaman-btn-subtitle {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
}

.xaman-btn .spinner {
  width: 20px;
  height: 20px;
  border-width: 2px;
}

.auth-info {
  margin-top: 24px;
  padding: 16px;
  background: var(--bg-hover);
  border-radius: var(--radius-xl);
}

.auth-info-content {
  display: flex;
  gap: 12px;
}

.auth-info-content svg {
  color: var(--accent);
  flex-shrink: 0;
}

.auth-info-text h4 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.auth-info-text p {
  font-size: 12px;
  color: var(--text-secondary);
}

.auth-info-text a {
  color: var(--accent);
  text-decoration: none;
}

.auth-info-text a:hover {
  text-decoration: underline;
}

/* ============================================
   Buttons
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border: none;
  border-radius: var(--radius-lg);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-primary {
  background: var(--accent-gradient);
  color: white;
}

.btn-primary:hover {
  opacity: 0.9;
  transform: scale(1.02);
}

.btn-secondary {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.btn-secondary:hover {
  background: var(--border-color);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
}

.btn-ghost:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.btn-round {
  width: 48px;
  height: 48px;
  padding: 0;
  border-radius: 50%;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 13px;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ============================================
   Forms
   ============================================ */
.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.form-input {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  background: var(--bg-input);
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
  transition: border-color var(--transition-fast);
}

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

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

.form-textarea {
  resize: vertical;
  min-height: 100px;
}

/* ============================================
   Animations
   ============================================ */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

.animate-fade-in {
  animation: fadeIn var(--transition-normal) ease;
}

.animate-slide-up {
  animation: slideUp var(--transition-slow) ease;
}

/* ============================================
   Collected NFTs Grid
   ============================================ */
.collected-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 20px;
}

.collected-nft-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--transition-fast);
}

.collected-nft-card:hover {
  border-color: var(--accent);
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.collected-nft-cover {
  position: relative;
  aspect-ratio: 1;
  background: var(--bg-hover);
}

.collected-nft-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.collected-nft-overlay {
  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);
}

.collected-nft-card:hover .collected-nft-overlay {
  opacity: 1;
}

.nft-play-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--accent);
  border: none;
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform var(--transition-fast);
}

.nft-play-btn:hover {
  transform: scale(1.1);
}

.collected-nft-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  background: rgba(34, 197, 94, 0.9);
  border-radius: 100px;
  font-size: 11px;
  font-weight: 600;
  color: white;
}

.collected-nft-info {
  padding: 12px;
}

.collected-nft-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 4px;
}

.collected-nft-artist {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.collected-nft-actions {
  margin-top: 8px;
}

.collected-nft-actions .btn-sm {
  width: 100%;
  font-size: 12px;
  padding: 6px 12px;
}

.edition-badge {
  position: absolute;
  bottom: 8px;
  left: 8px;
  padding: 4px 8px;
  background: rgba(0, 0, 0, 0.8);
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
}

.edition-badge.edition-one-of-one {
  background: linear-gradient(135deg, #8b5cf6, #ec4899);
  color: white;
}

.edition-badge.edition-first {
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  color: white;
}

.edition-badge.edition-early {
  background: rgba(59, 130, 246, 0.9);
  color: white;
}

.listing-price-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 6px 12px;
  background: linear-gradient(135deg, #22c55e, #16a34a);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 700;
  color: white;
}

/* ============================================
   Release Modal X Button Fix
   ============================================ */
.release-close-x,
.release-modal .release-close-x,
.release-modal-overlay .release-close-x,
button.release-close-x,
.release-modal button[class*="close"],
.release-modal-overlay button[class*="close"] {
  background: none !important;
  background-color: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  outline: none !important;
  padding: 0 !important;
  width: 32px !important;
  height: 32px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  position: absolute !important;
  top: 16px !important;
  right: 16px !important;
  z-index: 10 !important;
  color: white !important;
  opacity: 0.7;
  cursor: pointer;
  transition: opacity 0.15s ease;
}

.release-close-x:hover,
.release-modal .release-close-x:hover,
.release-modal-overlay .release-close-x:hover,
button.release-close-x:hover {
  background: none !important;
  background-color: transparent !important;
  opacity: 1;
}

.release-close-x svg {
  width: 24px;
  height: 24px;
}

/* TOS Link in Sidebar */
.tos-link {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 12px;
  padding: 8px 16px;
  cursor: pointer;
  text-align: left;
  width: 100%;
  transition: color 150ms;
}
.tos-link:hover {
  color: var(--text-secondary);
}

/* ============================================
   Playlist Context Menu
   ============================================ */
.playlist-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 8px 12px;
  background: none;
  border: none;
  border-radius: var(--radius-md);
  color: var(--text-primary);
  cursor: pointer;
  text-align: left;
  transition: background 0.15s;
  position: relative;
}

.playlist-nav-item:hover {
  background: var(--bg-hover);
}

.playlist-nav-item .nav-item-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.playlist-nav-item .nav-item-info span:first-child {
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.playlist-nav-item .track-count {
  font-size: 12px;
  color: var(--text-muted);
}

.playlist-menu-btn {
  opacity: 0;
  background: none;
  border: none;
  padding: 4px;
  color: var(--text-muted);
  cursor: pointer;
  border-radius: var(--radius-sm);
  transition: all 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.playlist-nav-item:hover .playlist-menu-btn {
  opacity: 1;
}

.playlist-menu-btn:hover {
  color: var(--text-primary);
  background: var(--bg-card);
}

.playlist-context-menu {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  padding: 6px;
  min-width: 180px;
  animation: menuFadeIn 0.15s ease;
}

@keyframes menuFadeIn {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.playlist-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 12px;
  background: none;
  border: none;
  border-radius: var(--radius-md);
  color: var(--text-primary);
  cursor: pointer;
  font-size: 14px;
  transition: background 0.15s;
}

.playlist-menu-item:hover {
  background: var(--bg-hover);
}

.playlist-menu-item svg {
  flex-shrink: 0;
  color: var(--text-muted);
}

.playlist-menu-item.delete {
  color: var(--error);
}

.playlist-menu-item.delete svg {
  color: var(--error);
}

.playlist-menu-item.delete:hover {
  background: rgba(239, 68, 68, 0.1);
}

/* ============================================
   Like Button Styles
   ============================================ */
#player-like-btn.liked {
  color: #ef4444 !important;
}

#expanded-like-btn.liked {
  color: #ef4444 !important;
}

.np-action-btn.liked {
  color: #ef4444 !important;
  border-color: #ef4444 !important;
}

.btn-icon-circle.liked {
  color: #ef4444 !important;
}

.track-action-btn.liked {
  color: #ef4444 !important;
}

/* ============================================
   Mobile Search
   ============================================ */
.mobile-search-btn {
  display: none;
}

@media (max-width: 640px) {
  .mobile-search-btn {
    display: flex;
  }
}

.mobile-search-container {
  display: none;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: var(--bg-primary);
  z-index: 60;
  align-items: center;
  padding: 0 12px;
  gap: 8px;
  border-bottom: 1px solid var(--border-color);
}

.mobile-search-container.active {
  display: flex;
}

.mobile-search-container .search-icon {
  position: static;
  transform: none;
  flex-shrink: 0;
  color: var(--text-muted);
}

.mobile-search-container .search-input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 10px 8px;
  font-size: 16px;
}

.mobile-search-container .search-input:focus {
  border: none;
  outline: none;
}

.mobile-search-close-btn {
  padding: 8px;
  border: none;
  border-radius: var(--radius-md);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mobile-search-close-btn:hover {
  color: var(--text-primary);
}

.mobile-search-container .search-results {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 0;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  max-height: calc(100vh - var(--header-height) - var(--player-height-mobile) - 16px);
}

.light .mobile-search-container {
  background: rgba(255, 255, 255, 0.98);
}
