/* Theme Colors as CSS Variables */
:root {
  --bg-primary: #020617;
  --bg-secondary: #0f172a;
  --bg-tertiary: #1e293b;
  --bg-card: #111827;
  --text-primary: #e5e7eb;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;
  --border-color: rgba(148, 163, 184, 0.2);
  --accent-primary: #ec4899;
  --accent-secondary: #fb7185;
  --success: #22c55e;
  --link-color: #38bdf8;
}

[data-theme="light"] {
  --bg-primary: #ffffff;
  --bg-secondary: #f8fafc;
  --bg-tertiary: #e2e8f0;
  --bg-card: #f1f5f9;
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;
  --border-color: rgba(15, 23, 42, 0.1);
  --accent-primary: #db2777;
  --accent-secondary: #ec4899;
  --success: #16a34a;
  --link-color: #0284c7;
}

/* Basic page styling */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text",
    "Segoe UI", sans-serif;
  background: var(--bg-secondary);
  color: var(--text-primary);
  transition: background-color 0.3s, color 0.3s;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* Prevent text size adjustments on mobile */
  -webkit-text-size-adjust: 100%;
  /* Smooth scrolling */
  scroll-behavior: smooth;
  /* Prevent horizontal scroll on mobile */
  overflow-x: hidden;
}

/* Layout */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.5rem;
}

/* Page Title Section */
.page-title-section {
  text-align: center;
  margin-bottom: 2rem;
}

.page-title {
  font-size: 2.5rem;
  margin: 0;
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.page-subtitle {
  font-size: 1.15rem;
  color: var(--text-secondary);
  margin-top: 0.5rem;
  margin-bottom: 0;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--bg-primary);
  border-bottom: 1px solid var(--border-color);
  backdrop-filter: blur(16px);
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  position: relative;
}

.site-header h1 {
  margin: 0;
  font-size: 1.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  flex: 1;
}

/* Theme Toggle */
.theme-toggle {
  padding: 0.5rem;
  border: none;
  background: var(--bg-card);
  color: var(--text-primary);
  border-radius: 0.5rem;
  cursor: pointer;
  font-size: 1.2rem;
  transition: all 0.2s;
}

.theme-toggle:hover {
  background: var(--bg-tertiary);
  transform: scale(1.1);
}

/* Navigation links */
.nav-links {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.nav-links a {
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all 0.2s;
}

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

.nav-links a.active {
  color: var(--text-primary);
  background: rgba(236, 72, 153, 0.2);
  font-weight: 600;
}

/* Subscribe link highlight */
.nav-links a.subscribe-link {
  background: var(--accent-primary);
  color: white;
  font-weight: 600;
  border: 1px solid var(--accent-primary);
}

.nav-links a.subscribe-link:hover {
  background: var(--accent-secondary);
  border-color: var(--accent-secondary);
  color: white;
}

/* Search form */
.search-form {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.search-form input[type="text"] {
  padding: 0.6rem 0.9rem;
  border-radius: 999px;
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-primary);
  min-width: 260px;
}

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

.search-form button {
  padding: 0.6rem 1.3rem;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  font-weight: 600;
  background: linear-gradient(135deg, var(--accent-secondary), var(--accent-primary));
  color: white;
  box-shadow: 0 8px 24px rgba(236, 72, 153, 0.5);
}

/* Alerts */
.alert {
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  margin-bottom: 1rem;
}

.alert-error {
  background: rgba(127, 29, 29, 0.6);
  border: 1px solid rgba(239, 68, 68, 0.7);
}

/* Grid of cards */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
  margin-bottom: 2rem;
}

/* Loading Skeleton */
.skeleton {
  animation: skeleton-loading 1s linear infinite alternate;
  background: linear-gradient(90deg, var(--bg-card) 0%, var(--bg-tertiary) 50%, var(--bg-card) 100%);
  background-size: 200% 100%;
}

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

.skeleton-card {
  border-radius: 1.5rem;
  overflow: hidden;
  background: var(--bg-card);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.85);
}

.skeleton-image {
  width: 100%;
  height: 200px;
  background: var(--bg-tertiary);
}

.skeleton-body {
  padding: 1.2rem 1.4rem 1.4rem;
}

.skeleton-title {
  height: 1.5rem;
  width: 80%;
  margin-bottom: 0.5rem;
  border-radius: 0.25rem;
}

.skeleton-text {
  height: 1rem;
  width: 100%;
  margin-bottom: 0.3rem;
  border-radius: 0.25rem;
}

.skeleton-text:last-child {
  width: 60%;
}

/* Cards */
.card {
  display: flex;
  flex-direction: column;
  border-radius: 1.5rem;
  overflow: hidden;
  background: var(--bg-card);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.25);
  color: var(--text-primary);
  position: relative;
  transition: transform 0.2s, box-shadow 0.2s;
  /* Prevent cards from breaking layout on mobile */
  max-width: 100%;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.35);
}

/* Improve touch feedback on mobile */
@media (hover: none) and (pointer: coarse) {
  .card:active {
    transform: scale(0.98);
  }
}

/* Bookmark button */
.bookmark-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  border: none;
  padding: 0.5rem;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.2rem;
  z-index: 2;
  transition: all 0.2s;
}

.bookmark-btn:hover {
  background: rgba(0, 0, 0, 0.8);
  transform: scale(1.1);
}

.bookmark-btn.bookmarked {
  color: #fbbf24;
}

/* Image wrapper: keeps consistent height even on failure */
.card-image {
  position: relative;
  width: 100%;
  padding-top: 56.25%; /* 16:9 aspect ratio */
  background: var(--bg-primary);
  overflow: hidden;
}

/* Normal image style */
.card-image img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Fallback state when image is missing / broken */
.card-image--fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 0; /* remove aspect ratio padding */
  height: 220px;
  background: var(--bg-secondary);
}

/* Fallback text */
.fallback-text {
  color: var(--text-secondary);
  font-size: 0.85rem;
  text-align: center;
  padding: 0 1rem;
}

/* Card body */
.card-body {
  padding: 1.2rem 1.4rem 1.4rem;
}

.card-title {
  margin: 0 0 0.4rem;
  font-size: 1rem;
  font-weight: 700;
}

.card-title a {
  color: inherit;
  text-decoration: none;
}

.card-title a:hover {
  text-decoration: underline;
}

.card-meta {
  margin: 0 0 0.6rem;
  font-size: 0.8rem;
  color: var(--text-secondary);
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.card-description {
  margin: 0 0 0.8rem;
  font-size: 0.9rem;
  color: var(--text-primary);
}

/* Social Share Buttons */
.share-buttons {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--border-color);
}

.share-btn {
  padding: 0.3rem 0.6rem;
  border: none;
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  border-radius: 0.25rem;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.2s;
  text-decoration: none;
  display: inline-block;
}

.share-btn:hover {
  background: var(--accent-primary);
  color: white;
  transform: translateY(-2px);
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border-color);
  padding: 1rem 0 2rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.site-footer a {
  color: var(--link-color);
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

/* Releases page styles */
.releases-intro {
  margin: 0.5rem auto 1rem;
  text-align: center;
  max-width: 800px;
  padding: 0 1rem;
}

.releases-intro p {
  color: var(--text-secondary);
  margin: 0;
  font-size: 1rem;
}

.releases-form {
  margin: 1.5rem auto;
  padding: 1.5rem;
  max-width: 800px;
  background: var(--bg-card);
  border-radius: 0.75rem;
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
  text-align: center;
}

.form-row {
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.form-row-compact {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  margin-bottom: 1rem;
}

.form-row-inline {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.form-field-inline {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
}

.form-field-inline label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
}

.form-field-inline input {
  width: auto;
  min-width: 120px;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
  color: var(--text-primary);
  font-size: 0.9rem;
}

.form-field-inline input[type="text"] {
  min-width: 150px;
}

.form-field-inline input[type="number"] {
  min-width: 80px;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  flex: 1;
  min-width: 150px;
}

.form-field label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

.form-field input {
  width: 100%;
}

.releases-form label {
  display: inline-block;
  min-width: 80px;
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.9rem;
}

.releases-form input[type="date"],
.releases-form input[type="number"] {
  padding: 0.6rem 0.85rem;
  border-radius: 0.5rem;
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
  color: var(--text-primary);
  font-size: 0.95rem;
  flex: 1;
  min-width: 140px;
}

.releases-form input[type="date"]:focus,
.releases-form input[type="number"]:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(236, 72, 153, 0.1);
}

.releases-form .chip {
  display: inline-block;
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  font-size: 0.8rem;
  background: #1d4ed8;
  color: #e5e7eb;
  font-weight: 500;
}

.submit-btn {
  padding: 0.65rem 1.75rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.95rem;
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  color: white;
  box-shadow: 0 6px 18px rgba(236, 72, 153, 0.35);
  transition: all 0.2s;
  margin-top: 0.25rem;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(236, 72, 153, 0.5);
}

.submit-btn:active {
  transform: translateY(0);
}

.summary {
  margin: 1.5rem auto 1rem;
  font-weight: 600;
  font-size: 1.1rem;
  text-align: center;
  max-width: 1200px;
}

.table-wrapper {
  overflow-x: auto;
  margin: 1.5rem auto 2rem;
  width: fit-content;
  max-width: 90%;
  border-radius: 1rem;
  background: var(--bg-primary);
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.releases-table {
  border-collapse: collapse;
  width: 100%;
  background: var(--bg-primary);
}

.releases-table th,
.releases-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.9rem;
  text-align: left;
}

.releases-table th {
  background: var(--bg-card);
  color: var(--text-primary);
  font-weight: 600;
}

.releases-table tr:nth-child(even) td {
  background: var(--bg-primary);
}

.releases-table tr:nth-child(odd) td {
  background: var(--bg-secondary);
}

.releases-table a {
  color: var(--link-color);
  text-decoration: none;
}

.releases-table a:hover {
  text-decoration: underline;
}

.cover-cell {
  width: 100px;
  padding: 0.75rem !important;
}

.album-cover {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 0.5rem;
  display: block;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  transition: transform 0.2s;
}

.album-cover:hover {
  transform: scale(1.05);
}

.no-cover {
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-tertiary);
  border-radius: 0.5rem;
  color: var(--text-muted);
  font-size: 2rem;
}

/* Search Groups with Icons */
.search-group {
  background: var(--bg-secondary);
  border-radius: 12px;
  padding: 1.25rem;
  margin-bottom: 1rem;
}

.search-group-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  font-weight: 600;
  font-size: 1rem;
  color: var(--text-primary);
}

.search-icon {
  font-size: 1.5rem;
}

.search-label {
  font-size: 0.95rem;
}

/* OR Separator */
.or-separator {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 1.5rem 0;
}

.or-line {
  flex: 1;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--border-color), transparent);
}

.or-text {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text-secondary);
  padding: 0.25rem 0.75rem;
  background: var(--bg-card);
  border-radius: 999px;
  border: 2px solid var(--border-color);
}

/* Enhanced Table Row Hover */
.release-row {
  transition: all 0.2s;
  cursor: pointer;
}

.release-row:hover {
  background: var(--bg-card) !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* Table Cell Styling */
.year-cell {
  font-weight: 600;
  color: var(--accent-primary);
}

.artist-cell {
  font-weight: 500;
}

.title-cell {
  font-weight: 400;
  color: var(--text-secondary);
}

.actions-cell {
  white-space: nowrap;
}

/* Action Buttons */
.action-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.4rem 0.75rem;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s;
  margin-right: 0.5rem;
}

.view-btn {
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  color: white;
}

.view-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(236, 72, 153, 0.4);
}

.streaming-btn {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  padding: 0.4rem;
}

.streaming-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.spotify-btn:hover {
  background: #1DB954;
  color: white;
  border-color: #1DB954;
}

.apple-btn:hover {
  background: #FA243C;
  color: white;
  border-color: #FA243C;
}

/* Mobile Card View - Hidden on Desktop */
.releases-cards {
  display: none;
}

@media (max-width: 768px) {
  .table-wrapper {
    display: none;
  }

  .releases-cards {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin: 1.5rem 0;
  }

  .release-card {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 1rem;
    display: flex;
    gap: 1rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: all 0.2s;
  }

  .release-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
  }

  .release-card-cover {
    flex-shrink: 0;
  }

  .card-album-cover {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  }

  .card-no-cover {
    width: 100px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-tertiary);
    border-radius: 8px;
    color: var(--text-muted);
    font-size: 2.5rem;
  }

  .release-card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
  }

  .release-card-year {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--accent-primary);
  }

  .release-card-artist {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
  }

  .release-card-title {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
  }

  .release-card-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: auto;
  }

  .card-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.65rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
    transition: all 0.2s;
  }

  .card-action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(236, 72, 153, 0.4);
  }

  .streaming-links {
    display: flex;
    gap: 0.75rem;
  }

  .streaming-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    transition: all 0.2s;
  }

  .streaming-icon:hover {
    transform: scale(1.1);
  }

  .spotify-icon:hover {
    background: #1DB954;
    border-color: #1DB954;
    color: white;
  }

  .apple-icon:hover {
    background: #FA243C;
    border-color: #FA243C;
    color: white;
  }

  /* Mobile search groups */
  .search-group {
    padding: 1rem;
  }

  .form-row-inline {
    flex-direction: column;
    gap: 0.75rem;
  }
}

/* Article Page */
.article-content {
  max-width: 800px;
  margin: 0 auto;
}

.article-header {
  margin-bottom: 2rem;
}

.back-link {
  color: var(--link-color);
  text-decoration: none;
  display: inline-block;
  margin-bottom: 1rem;
}

.back-link:hover {
  text-decoration: underline;
}

.article-title {
  margin: 0 0 1rem;
  font-size: 2rem;
  line-height: 1.2;
}

.article-meta {
  color: var(--text-secondary);
  margin: 0.5rem 0;
}

.article-source {
  color: var(--text-secondary);
  margin: 0.5rem 0;
}

.article-source a {
  color: var(--link-color);
}

.article-image {
  margin: 2rem 0;
  border-radius: 1rem;
  overflow: hidden;
}

.article-image img {
  width: 100%;
  height: auto;
  display: block;
}

.article-body {
  line-height: 1.7;
  font-size: 1.05rem;
}

.article-body p {
  margin: 1rem 0;
}

.article-body img {
  max-width: 100%;
  height: auto;
  border-radius: 0.5rem;
  margin: 1.5rem 0;
}

.article-body a {
  color: var(--link-color);
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin: 2rem 0;
}

.page-btn {
  padding: 0.5rem 1rem;
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-primary);
  border-radius: 0.5rem;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
}

.page-btn:hover:not(.disabled) {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
}

.page-btn.active {
  background: var(--accent-primary);
  color: white;
  border-color: var(--accent-primary);
}

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

/* Responsive tweaks */
@media (max-width: 640px) {
  /* Typography & spacing adjustments */
  body {
    font-size: 0.95rem;
  }

  .container {
    padding: 1rem;
  }

  /* Header improvements */
  .site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: var(--bg-primary);
  }
  
  .header-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 1rem;
  }

  .site-header h1 {
    font-size: 1.25rem;
    flex: 0 1 auto;
  }

  /* Page title responsive */
  .page-title {
    font-size: 1.75rem;
  }

  .page-subtitle {
    font-size: 1rem;
  }
  
  /* Form compact rows stack on mobile */
  .form-row-compact {
    flex-direction: column;
    gap: 0.75rem;
  }

  /* Inline form fields stack on mobile */
  .form-row-inline {
    flex-direction: column;
    gap: 0.75rem;
    align-items: stretch;
  }

  .form-field-inline {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
  }

  .form-field-inline input {
    width: 100%;
    min-width: 100%;
  }
  
  .form-field {
    min-width: 100%;
  }
  
  /* Show mobile menu toggle button */
  .mobile-menu-toggle {
    display: block !important;
  }
  
  .theme-toggle {
    display: block !important;
  }
  
  /* Hide search/filters wrapper on mobile */
  .search-filters-wrapper {
    display: none !important;
  }
  
  /* Mobile search form */
  .search-form {
    flex-direction: column;
    width: 100%;
    gap: 0.75rem;
  }
  
  .search-form input[type="text"] {
    width: 100%;
    min-width: auto;
  }
  
  .search-form button {
    width: 100%;
  }
    letter-spacing: 0.05em;
  }

  .header-inner {
    gap: 0.75rem;
    padding: 0.75rem 0;
  }

  .nav-links {
    width: 100%;
    justify-content: space-around;
    gap: 0.5rem;
    flex-wrap: wrap;
  }

  .nav-links a {
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
    white-space: nowrap;
  }

  .theme-toggle {
    padding: 0.4rem 0.6rem;
    font-size: 1rem;
  }

  /* Search form mobile optimization */
  .search-form {
    width: 100%;
    flex-direction: column;
  }

  .search-form input[type="text"] {
    flex: 1;
    min-width: 0;
    width: 100%;
    font-size: 1rem;
  }

  .search-form button {
    width: 100%;
    padding: 0.75rem;
  }

  /* Grid adjustments */
  .grid {
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-top: 1rem;
  }

  /* Card improvements */
  .card {
    border-radius: 1rem;
  }

  .card-img {
    height: 180px;
  }

  .card-body {
    padding: 1rem;
  }

  .card-title {
    font-size: 1.1rem;
    line-height: 1.4;
  }

  .card-description {
    font-size: 0.9rem;
    line-height: 1.5;
    -webkit-line-clamp: 3;
  }

  .card-meta {
    font-size: 0.8rem;
  }

  /* Bookmark button mobile */
  .bookmark-btn {
    top: 0.75rem;
    right: 0.75rem;
    width: 36px;
    height: 36px;
    font-size: 1.1rem;
  }

  /* Share buttons mobile */
  .share-buttons {
    gap: 0.5rem;
  }

  .share-btn {
    padding: 0.4rem 0.7rem;
    font-size: 0.85rem;
  }

  /* Filter bar mobile */
  .filter-bar {
    gap: 0.75rem;
    padding: 0.75rem 0;
  }

  .filter-section {
    width: 100%;
  }

  .filter-section label {
    font-size: 0.9rem;
  }

  .filter-section select,
  .filter-section input {
    font-size: 1rem;
    padding: 0.6rem;
  }

  /* Releases form mobile */
  .releases-form {
    padding: 1.5rem 1rem;
    margin: 0.5rem 0;
  }
  
  .releases-intro p {
    font-size: 0.95rem;
  }

  .form-row {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    margin-bottom: 1rem;
  }

  .form-row label {
    margin: 0;
    font-size: 0.9rem;
    min-width: auto;
  }

  .form-row input,
  .form-row select {
    font-size: 1rem;
    width: 100%;
    min-width: auto;
  }
  
  .releases-form .chip {
    margin-left: 0;
    margin-top: 0.5rem;
  }
  
  .submit-btn {
    width: 100%;
    padding: 1rem;
    font-size: 1.1rem;
  }

  .table-wrapper {
    width: 100%;
    max-width: 100%;
    margin: 1rem 0;
  }

  /* Releases table mobile */
  .releases-table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .releases-table th,
  .releases-table td {
    padding: 0.5rem;
    font-size: 0.85rem;
  }

  /* Article page mobile */
  .article-title {
    font-size: 1.4rem;
    line-height: 1.3;
  }

  .article-meta {
    font-size: 0.85rem;
  }

  .article-content {
    font-size: 1rem;
    line-height: 1.7;
  }

  .article-content p {
    margin-bottom: 1rem;
  }

  /* Artist page mobile */
  .artist-header {
    padding: 1.5rem 1rem;
  }

  .artist-title {
    font-size: 1.8rem;
  }

  .artist-image {
    width: 100px;
    height: 100px;
  }

  /* Newsletter section mobile */
  .newsletter-section {
    padding: 2rem 1rem;
  }

  .newsletter-section h2 {
    font-size: 1.5rem;
  }

  .signup-container {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .newsletter-form {
    flex-direction: column;
    gap: 0.75rem;
  }

  .newsletter-form input {
    min-width: 0;
    width: 100%;
  }

  .newsletter-form button {
    width: 100%;
    padding: 1rem;
  }

  /* Pagination mobile */
  .pagination {
    gap: 0.5rem;
  }

  .page-btn {
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
  }

  /* Genre tags mobile */
  .genre-tags {
    gap: 0.4rem;
  }

  .genre-tag {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
  }

  /* Stat boxes mobile */
  .stats-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .stat-box {
    padding: 1rem;
  }

  /* Loading state mobile */
  .skeleton-image {
    height: 180px;
  }

  /* Improve touch targets */
  button,
  .btn,
  a {
    min-height: 44px;
    min-width: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  /* Fix overflow issues */
  .card-title,
  .card-description {
    overflow-wrap: break-word;
    word-wrap: break-word;
    hyphens: auto;
  }
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
  display: none;
  padding: 0.5rem;
  border: none;
  background: var(--bg-card);
  color: var(--text-primary);
  border-radius: 0.5rem;
  cursor: pointer;
  font-size: 1.5rem;
  transition: all 0.2s;
  line-height: 1;
}

.mobile-menu-toggle:hover {
  background: var(--bg-tertiary);
}

/* Search and Filters Wrapper */
.search-filters-wrapper {
  transition: max-height 0.3s ease-out, opacity 0.3s ease-out;
  overflow: hidden;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
  display: none;
  padding: 0.5rem 0.75rem;
  border: none;
  background: var(--bg-card);
  color: var(--text-primary);
  border-radius: 0.5rem;
  cursor: pointer;
  font-size: 1.5rem;
  transition: all 0.2s;
  line-height: 1;
  border: 1px solid var(--border-color);
}

.mobile-menu-toggle:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
}

/* Search and Filters Wrapper */
.search-filters-wrapper {
  transition: max-height 0.3s ease-out, opacity 0.3s ease-out;
  overflow: hidden;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
  display: none;
  padding: 0.6rem 0.85rem;
  border: none;
  background: var(--bg-card);
  color: var(--text-primary);
  border-radius: 0.5rem;
  cursor: pointer;
  font-size: 1.4rem;
  transition: all 0.2s;
  line-height: 1;
  border: 1px solid var(--border-color);
  position: absolute;
  left: 0;
  z-index: 1000;
}

.mobile-menu-toggle:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
}

.theme-toggle {
  position: absolute;
  right: 0;
  z-index: 1000;
}

/* Mobile Navigation Wrapper */
.mobile-nav-wrapper {
  transition: max-height 0.4s ease-out, opacity 0.3s ease-out;
  overflow: hidden;
}

/* Desktop: Always show navigation */
@media (min-width: 641px) {
  .mobile-nav-wrapper {
    max-height: none !important;
    opacity: 1 !important;
  }
  
  .mobile-nav-wrapper.collapsed,
  .mobile-nav-wrapper.expanded {
    max-height: none !important;
    opacity: 1 !important;
  }
  
  .nav-links {
    display: flex;
    justify-content: center;
    padding: 1rem 0;
  }
}

/* Mobile: Collapsible navigation */
@media (max-width: 640px) {
  .mobile-nav-wrapper {
    position: relative;
    z-index: 99;
  }
  
  .mobile-nav-wrapper.collapsed {
    max-height: 0;
    opacity: 0;
  }

  .mobile-nav-wrapper.expanded {
    max-height: 500px;
    opacity: 1;
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
  }
  
  .mobile-nav-wrapper .nav-links {
    flex-direction: column;
    width: 100%;
    gap: 0;
    padding: 0;
  }
  
  .mobile-nav-wrapper .nav-links a {
    width: 100%;
    text-align: center;
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    border-radius: 0;
    display: block;
  }
  
  .mobile-nav-wrapper .nav-links a:last-child {
    border-bottom: none;
  }
}

/* Search and Filters Wrapper */
.search-filters-wrapper {
  transition: max-height 0.4s ease-out, opacity 0.3s ease-out, padding 0.3s ease-out;
  overflow: hidden;
}

/* Collapsed by default on all screen sizes */
.search-filters-wrapper.collapsed {
  max-height: 0;
  opacity: 0;
  padding: 0;
}

.search-filters-wrapper.expanded {
  max-height: 1200px;
  opacity: 1;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

/* Filter Bar */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border-color);
}

.filter-section {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.filter-section label {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.filter-btn {
  padding: 0.4rem 0.8rem;
  background: var(--bg-card);
  color: var(--text-primary);
  text-decoration: none;
  border: 1px solid var(--border-color);
  border-radius: 0.4rem;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s;
}

.filter-btn:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
}

.filter-btn.active {
  background: var(--accent-primary);
  color: white;
  border-color: var(--accent-primary);
  font-weight: 600;
}

/* Artist Page */
.artist-header {
  margin: 2rem 0;
  text-align: center;
}

.artist-title {
  font-size: 2.5rem;
  margin: 0.5rem 0;
  color: var(--accent-primary);
}

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

.back-link {
  display: inline-block;
  color: var(--link-color);
  text-decoration: none;
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

.back-link:hover {
  text-decoration: underline;
}

.article-count {
  text-align: center;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

/* Artist Link in Cards */
.card-artist {
  margin: 0.5rem 0 0;
}

.artist-link {
  color: var(--accent-secondary);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  transition: color 0.2s;
}

.artist-link:hover {
  color: var(--accent-primary);
  text-decoration: underline;
}

/* Genre Tags */
.genres {
  display: inline-flex;
  gap: 0.4rem;
  margin-left: 0.5rem;
  flex-wrap: wrap;
}

.genre-tag {
  padding: 0.15rem 0.5rem;
  background: var(--bg-tertiary);
  color: var(--text-secondary);
  border-radius: 0.3rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Infinite Scroll Loading Indicator */
#infinite-scroll-loader {
  text-align: center;
  padding: 2rem;
  color: var(--text-secondary);
}

#infinite-scroll-loader.hidden {
  display: none;
}

/* Responsive adjustments for filter bar */
@media (max-width: 768px) {
  /* Container spacing */
  .container {
    padding: 1.25rem;
  }

  /* Header tablet adjustments */
  .site-header h1 {
    font-size: 1.5rem;
  }

  /* Navigation tablet */
  .nav-links {
    gap: 0.75rem;
  }

  /* Search form tablet */
  .search-form input[type="text"] {
    min-width: 200px;
  }

  /* Filter bar tablet */
  .filter-bar {
    flex-direction: column;
    gap: 1rem;
  }
  
  .filter-section {
    width: 100%;
  }

  /* Grid tablet */
  .grid {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.25rem;
  }

  /* Artist page tablet */
  .artist-title {
    font-size: 2rem;
  }

  .artist-info {
    flex-direction: column;
    text-align: center;
  }

  .artist-image {
    margin: 0 auto;
  }

  /* Newsletter tablet */
  .signup-container {
    grid-template-columns: 1fr;
  }

  /* Stats grid tablet */
  .stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  }

  /* Releases table tablet */
  .releases-table {
    font-size: 0.9rem;
  }
}

/* Advanced Filters */
.advanced-filters {
  margin: 1.5rem 0 0 0;
  padding: 0;
  background: transparent;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  overflow: hidden;
}

.advanced-filters summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--text-primary);
  padding: 1rem;
  user-select: none;
  background: var(--bg-tertiary);
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.advanced-filters summary::before {
  content: '▶';
  display: inline-block;
  transition: transform 0.2s;
  font-size: 0.8rem;
}

.advanced-filters[open] summary::before {
  transform: rotate(90deg);
}

.advanced-filters summary:hover {
  background: var(--bg-card);
  color: var(--accent-primary);
}

.filter-group {
  padding: 1.5rem 1rem 1rem;
  display: grid;
  gap: 1rem;
  background: var(--bg-card);
}

.filter-note {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-style: italic;
  margin-top: 0.5rem;
  padding: 0.75rem;
  background: rgba(236, 72, 153, 0.05);
  border-radius: 0.5rem;
  border-left: 3px solid var(--accent-primary);
}

.releases-form select {
  padding: 0.75rem 1rem;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  font-size: 1rem;
  width: 100%;
  cursor: pointer;
}

.releases-form select:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(236, 72, 153, 0.1);
}

/* PWA Install Button - DISABLED */
/* .pwa-install-btn {
  display: none;
  padding: 0.5rem 1rem;
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  color: white;
  border: none;
  border-radius: 0.5rem;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(236, 72, 153, 0.3);
  transition: all 0.3s;
  animation: pulse 2s infinite;
}

.pwa-install-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(236, 72, 153, 0.4);
}

@keyframes pulse {
  0%, 100% {
    box-shadow: 0 2px 8px rgba(236, 72, 153, 0.3);
  }
  50% {
    box-shadow: 0 2px 16px rgba(236, 72, 153, 0.5);
  }
} */

/* Artist Image */
.artist-image {
  width: 100%;
  max-width: 300px;
  height: 300px;
  margin: 2rem auto;
  border-radius: 50%;
  overflow: hidden;
  border: 4px solid var(--accent-primary);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

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

/* Music Player Integration */
.music-links {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin: 1.5rem 0;
  flex-wrap: wrap;
}

.music-link-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.2rem;
  background: var(--bg-card);
  color: var(--text-primary);
  text-decoration: none;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  font-weight: 600;
  transition: all 0.2s;
}

.music-link-btn:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
  transform: translateY(-2px);
}

.music-link-btn.spotify {
  background: #1DB954;
  color: white;
  border-color: #1DB954;
}

.music-link-btn.apple {
  background: #FC3C44;
  color: white;
  border-color: #FC3C44;
}

/* YouTube Video Embed */
.video-embed {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
  margin: 2rem 0;
  background: var(--bg-card);
  border-radius: 0.5rem;
  overflow: hidden;
}

.video-embed iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* Newsletter Signup */
.newsletter-section {
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  padding: 3rem 1.5rem;
  margin: 3rem 0;
  border-radius: 1rem;
  text-align: center;
  color: white;
}

.newsletter-section h2 {
  margin: 0 0 0.5rem;
  font-size: 2rem;
}

.newsletter-section p {
  margin: 0 0 1.5rem;
  opacity: 0.9;
}

.signup-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  max-width: 900px;
  margin: 0 auto;
}

.signup-box {
  background: rgba(255, 255, 255, 0.1);
  padding: 1.5rem;
  border-radius: 0.75rem;
  backdrop-filter: blur(10px);
}

.signup-box h3 {
  margin: 0 0 1rem;
  font-size: 1.3rem;
  font-weight: 600;
}

.newsletter-form {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.newsletter-form input {
  flex: 1;
  min-width: 200px;
  padding: 0.8rem 1rem;
  border: none;
  border-radius: 0.5rem;
  font-size: 1rem;
}

.newsletter-form button {
  padding: 0.8rem 1.5rem;
  background: white;
  color: var(--accent-primary);
  border: none;
  border-radius: 0.5rem;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s;
}

.newsletter-form button:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.newsletter-message {
  margin-top: 1rem;
  font-size: 0.9rem;
  font-weight: 600;
}

.sms-note {
  margin-top: 0.75rem !important;
  font-size: 0.75rem;
  opacity: 0.7;
}

/* ===============================
   MOBILE-FIRST UTILITY CLASSES
   =============================== */

/* Safe area insets for notched devices (iPhone X+) */
@supports (padding: max(0px)) {
  body {
    padding-left: max(0px, env(safe-area-inset-left));
    padding-right: max(0px, env(safe-area-inset-right));
  }

  .site-header {
    padding-top: max(0px, env(safe-area-inset-top));
  }
}

/* Improve tap targets on mobile */
@media (max-width: 640px) {
  a, button, input, select, textarea {
    /* Minimum tap target size */
    min-height: 44px;
  }

  /* Increase spacing between interactive elements */
  .nav-links a {
    margin: 0.25rem;
  }

  /* Improve form controls */
  input[type="text"],
  input[type="email"],
  input[type="tel"],
  input[type="search"],
  select,
  textarea {
    font-size: 16px; /* Prevents zoom on iOS */
    padding: 0.75rem;
  }

  /* Better focus states for accessibility */
  *:focus-visible {
    outline: 3px solid var(--accent-primary);
    outline-offset: 2px;
  }
}

/* Hide elements on mobile */
.desktop-only {
  display: initial;
}

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

/* Show only on mobile */
.mobile-only {
  display: none;
}

@media (max-width: 640px) {
  .mobile-only {
    display: initial;
  }
}

/* Prevent content from being cut off on small screens */
img {
  max-width: 100%;
  height: auto;
}

/* Improve readability on mobile */
@media (max-width: 640px) {
  p {
    line-height: 1.6;
  }

  h1, h2, h3 {
    line-height: 1.2;
  }
}
