/* ─── DESKTOP SHELL (≥900px) ──────────────────────────────────────────────
 * SoundWave-style shell: left sidebar + top bar + (optional) right rail.
 * Mobile layouts are untouched - every rule below is wrapped in a media
 * query so sub-900px viewports behave exactly as before.
 * Reference implementation lives in love.html (full album detail + right
 * rail + player bar). Pages can include just the shell by linking this
 * file and rendering the sidebar+topbar HTML.
 * -------------------------------------------------------------------- */

.dt-sidebar, .dt-topbar, .dt-rightrail, .dt-player { display: none; }

/* Mobile: hide desktop-only album-detail sections so layout stays clean */
.album-meta, .album-more-by, .section-title { display: none; }
.track-play-icon, .track-more { display: none; }

/* Track download button - visible on both mobile and desktop */
.track-download {
  background: none;
  border: none;
  color: rgba(255,255,255,0.45);
  cursor: pointer;
  padding: 6px 8px;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  flex-shrink: 0;
  transition: color 0.15s, background 0.15s;
}
.track-download:hover { color: #c0a060; background: rgba(255,255,255,0.05); }
.track-download.done { color: #4cd1ab; }

/* Premium / release-notification modal (works on mobile + desktop) */
.premium-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(8px);
  z-index: 2000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.premium-backdrop.show { display: flex; }
.premium-modal {
  background: #0f1420;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 20px;
  max-width: 420px;
  width: 100%;
  padding: 36px 28px 28px;
  text-align: center;
  position: relative;
  box-shadow: 0 20px 60px rgba(0,0,0,0.6), 0 0 80px rgba(76,209,171,0.12);
  font-family: 'Inter', Arial, sans-serif;
}
.premium-close {
  position: absolute;
  top: 12px;
  right: 16px;
  background: none;
  border: none;
  color: rgba(255,255,255,0.5);
  font-size: 1.6em;
  cursor: pointer;
  line-height: 1;
}
.premium-close:hover { color: #fff; }
.premium-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #2a7de1, #4cd1ab);
  margin-bottom: 14px;
  color: #fff;
}
.premium-modal h2 {
  font-size: 1.3em;
  font-weight: 700;
  margin-bottom: 6px;
}
.premium-sub {
  color: rgba(255,255,255,0.55);
  font-size: 0.88em;
  margin-bottom: 22px;
  line-height: 1.5;
}
.premium-modal input[type="email"] {
  width: 100%;
  padding: 12px 16px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.04);
  color: #fff;
  font-size: 0.95em;
  font-family: inherit;
  margin-bottom: 12px;
  outline: none;
  transition: border-color 0.15s;
}
.premium-modal input[type="email"]:focus { border-color: #4cd1ab; }
.premium-submit {
  width: 100%;
  padding: 12px 20px;
  background: linear-gradient(90deg, #2a7de1, #4cd1ab);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 0.95em;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition: filter 0.15s;
}
.premium-submit:hover { filter: brightness(1.1); }
.premium-submit:disabled { opacity: 0.6; cursor: default; }
.premium-note {
  margin-top: 14px;
  font-size: 0.75em;
  color: rgba(255,255,255,0.35);
}
.premium-success {
  color: #4cd1ab;
  font-size: 0.88em;
  margin-top: 12px;
  display: none;
}
.premium-success.show { display: block; }

@media (min-width: 900px) {
  body {
    padding-left: 260px;
    padding-right: 0;
    padding-top: 64px;
  }
  body.dt-has-rail { padding-right: 340px; }

  body > .top-bar { display: none; }
  .bottom-nav { display: none; }

  /* Pages that embed this shell but haven't adopted the full desktop player
     bar yet - hide the mobile mini-player so it doesn't overlap the sidebar. */
  .mini-player, .player-controls { display: none; }

  /* Sidebar */
  .dt-sidebar {
    display: flex;
    flex-direction: column;
    position: fixed;
    left: 0; top: 0; bottom: 0;
    width: 260px;
    background: rgba(10,15,26,0.6);
    border-right: 1px solid rgba(255,255,255,0.05);
    padding: 24px 16px;
    overflow-y: auto;
    z-index: 50;
  }
  .dt-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #c0a060;
    font-family: 'Pacifico', cursive;
    font-size: 1.6em;
    padding: 4px 10px;
    margin-bottom: 28px;
  }
  .dt-nav { list-style: none; padding: 0; margin: 0; }
  .dt-nav li { margin-bottom: 2px; }
  .dt-nav a {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 14px;
    color: rgba(255,255,255,0.6);
    text-decoration: none;
    border-radius: 8px;
    font-size: 0.95em;
    transition: background 0.15s, color 0.15s;
  }
  .dt-nav a:hover { background: rgba(255,255,255,0.06); color: #fff; }
  .dt-nav a.active { background: rgba(192,160,96,0.14); color: #c0a060; }
  .dt-nav svg { width: 20px; height: 20px; flex-shrink: 0; }

  /* Top bar */
  .dt-topbar {
    display: flex;
    align-items: center;
    gap: 24px;
    position: fixed;
    top: 0;
    left: 260px;
    right: 0;
    height: 64px;
    padding: 0 32px;
    background: rgba(6,10,20,0.85);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255,255,255,0.04);
    z-index: 40;
  }
  body.dt-has-rail .dt-topbar { right: 340px; }

  .dt-search {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    max-width: 440px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 22px;
    padding: 8px 18px;
  }
  .dt-search svg { color: rgba(255,255,255,0.4); flex-shrink: 0; }
  .dt-search input {
    flex: 1;
    background: none;
    border: none;
    outline: none;
    color: #fff;
    font-size: 0.92em;
    font-family: inherit;
  }
  .dt-search input::placeholder { color: rgba(255,255,255,0.35); }

  .dt-topbar-actions {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-left: auto;
  }
  .dt-premium {
    display: flex;
    align-items: center;
    gap: 6px;
    background: none;
    border: 1px solid rgba(76,209,171,0.35);
    color: #4cd1ab;
    padding: 6px 16px;
    border-radius: 18px;
    font-size: 0.82em;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
  }
  .dt-bell {
    background: none;
    border: none;
    color: rgba(255,255,255,0.6);
    cursor: pointer;
    padding: 4px;
    display: flex;
  }
  .dt-profile {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4a6ee8, #b85cf0);
    cursor: pointer;
    flex-shrink: 0;
  }

  /* ── Right rail ───────────────────────────────────────────── */
  .dt-rightrail {
    display: block;
    position: fixed;
    right: 0; top: 0; bottom: 0;
    width: 340px;
    background: rgba(6,10,20,0.45);
    border-left: 1px solid rgba(255,255,255,0.04);
    padding: 28px 24px;
    overflow-y: auto;
    z-index: 30;
  }
  .dt-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 14px;
    padding: 20px;
    margin-bottom: 16px;
  }
  .dt-card h3 {
    font-size: 1em;
    font-weight: 700;
    margin-bottom: 10px;
    color: #fff;
  }
  .dt-card p {
    font-size: 0.87em;
    color: rgba(255,255,255,0.6);
    line-height: 1.55;
  }
  .dt-stats {
    display: flex;
    gap: 8px;
    padding: 18px;
    justify-content: space-around;
  }
  .dt-stat { text-align: center; flex: 1; }
  .dt-stat-num {
    font-size: 1.4em;
    font-weight: 700;
    color: #fff;
    margin-bottom: 2px;
  }
  .dt-stat-label {
    font-size: 0.72em;
    color: rgba(255,255,255,0.4);
    text-transform: uppercase;
    letter-spacing: 1px;
  }

  /* Fans Are Saying comments */
  .dt-comment {
    display: flex;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
  }
  .dt-comment:last-child { border-bottom: none; }
  .dt-comment-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4a6ee8, #b85cf0);
    flex-shrink: 0;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7em;
    font-weight: 700;
  }
  .dt-comment-body { flex: 1; min-width: 0; }
  .dt-comment-who {
    font-size: 0.78em;
    font-weight: 600;
    color: #fff;
    margin-bottom: 2px;
  }
  .dt-comment-when {
    font-size: 0.7em;
    color: rgba(255,255,255,0.35);
    margin-left: 6px;
    font-weight: 400;
  }
  .dt-comment-content {
    font-size: 0.82em;
    color: rgba(255,255,255,0.7);
    line-height: 1.45;
    word-wrap: break-word;
  }
  .dt-comment-empty {
    font-style: italic;
    color: rgba(255,255,255,0.35);
    font-size: 0.85em;
  }
  .dt-comment-form {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid rgba(255,255,255,0.05);
  }
  .dt-comment-form textarea {
    width: 100%;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 8px;
    color: #fff;
    padding: 8px 10px;
    font-family: inherit;
    font-size: 0.82em;
    resize: vertical;
    min-height: 54px;
    outline: none;
    transition: border-color 0.15s;
  }
  .dt-comment-form textarea:focus { border-color: #4cd1ab; }
  .dt-comment-form button {
    margin-top: 8px;
    width: 100%;
    background: linear-gradient(90deg, #2a7de1, #4cd1ab);
    color: #fff;
    border: none;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 0.82em;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
  }
  .dt-comment-form button:disabled { opacity: 0.5; cursor: default; }
  .dt-comment-login {
    text-align: center;
    font-size: 0.8em;
    color: rgba(255,255,255,0.4);
    padding-top: 10px;
    border-top: 1px solid rgba(255,255,255,0.05);
    margin-top: 10px;
  }
  .dt-comment-login a { color: #4cd1ab; text-decoration: none; font-weight: 600; }

  /* ── Album detail header ───────────────────────────────────── */
  .album-view { align-items: stretch; padding: 24px 8px 180px; }
  /* Force full width so the rail/tracklist/header don't collapse when
     a page's inline CSS sets align-items: center on .album-view. */
  .album-header, .album-more-by, .tracklist { width: 100%; }
  .album-header {
    display: flex;
    gap: 32px;
    margin-bottom: 36px;
    align-items: flex-end;
  }
  .album-header .cover-container {
    margin-bottom: 0;
    width: 260px;
    height: 260px;
    flex-shrink: 0;
  }
  .album-meta {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    flex: 1;
    min-width: 0;
    gap: 12px;
  }
  .album-label {
    color: #4a9cf0;
    font-size: 0.72em;
    letter-spacing: 3px;
    font-weight: 600;
  }
  .album-title {
    font-size: 3.6em;
    font-weight: 900;
    line-height: 1;
    margin: 0;
  }
  .album-artist-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 4px;
  }
  .album-artist-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background-size: cover;
    background-position: center;
    border: 1px solid rgba(255,255,255,0.1);
  }
  .album-artist-name { font-size: 0.95em; font-weight: 600; }
  .album-artist-verified { color: #4a9cf0; }
  .album-metadata { color: rgba(255,255,255,0.5); font-size: 0.88em; }
  .album-metadata .dot { margin: 0 8px; color: rgba(255,255,255,0.3); }

  .album-actions {
    display: flex;
    gap: 12px;
    margin-top: 10px;
    align-items: center;
  }
  .btn-play-gradient {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(90deg, #2a7de1, #4cd1ab);
    color: #fff;
    border: none;
    padding: 12px 32px;
    border-radius: 26px;
    font-size: 0.95em;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: transform 0.1s, filter 0.15s;
  }
  .btn-play-gradient:hover { filter: brightness(1.1); }
  .btn-play-gradient:active { transform: scale(0.97); }
  .btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.06);
    color: #fff;
    border: 1px solid rgba(255,255,255,0.08);
    padding: 12px 24px;
    border-radius: 26px;
    font-size: 0.9em;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.15s;
  }
  .btn-secondary:hover { background: rgba(255,255,255,0.1); }
  .btn-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255,255,255,0.06);
    color: rgba(255,255,255,0.7);
    border: 1px solid rgba(255,255,255,0.08);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
  }
  .btn-icon:hover { background: rgba(255,255,255,0.1); color: #fff; }

  .section-title {
    display: block;
    font-size: 1.1em;
    font-weight: 700;
    margin-bottom: 16px;
  }

  /* Track list redesign */
  .tracklist { max-width: 100%; }
  .track-row { padding: 12px 18px; gap: 18px; }
  .track-play-icon {
    display: flex;
    width: 24px;
    height: 24px;
    color: rgba(255,255,255,0.5);
    flex-shrink: 0;
  }
  .track-row:hover .track-play-icon,
  .track-row.active .track-play-icon { color: #c0a060; }
  .track-left { gap: 18px; }
  .track-more {
    display: inline-flex;
    background: none;
    border: none;
    color: rgba(255,255,255,0.35);
    cursor: pointer;
    padding: 4px 8px;
    font-size: 1.2em;
    letter-spacing: 2px;
    border-radius: 6px;
  }
  .track-more:hover { color: #fff; background: rgba(255,255,255,0.05); }

  /* More by Artist rail */
  .album-more-by { display: block; margin-top: 40px; }
  .mb-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
  }
  .mb-header .section-title { margin-bottom: 0; }
  .view-all {
    color: rgba(255,255,255,0.5);
    text-decoration: none;
    font-size: 0.85em;
  }
  .view-all:hover { color: #fff; }
  .mb-rail {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 16px;
  }
  .mb-card {
    text-decoration: none;
    color: inherit;
    transition: transform 0.15s;
  }
  .mb-card:hover { transform: translateY(-2px); }
  .mb-cover {
    aspect-ratio: 1;
    border-radius: 10px;
    background-size: cover;
    background-position: center;
    margin-bottom: 10px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.4);
  }
  .mb-title { font-size: 0.92em; font-weight: 600; margin-bottom: 2px; }
  .mb-sub { font-size: 0.78em; color: rgba(255,255,255,0.4); }

  .mb-cover-fh { background: linear-gradient(135deg, #0a0a2e 0%, #1a1040 30%, #0d1b3e 60%, #1e0a3a 100%); }
  .mb-cover-dnl {
    background:
      radial-gradient(ellipse at 25% 30%, rgba(138,43,226,0.7) 0%, transparent 50%),
      radial-gradient(ellipse at 75% 25%, rgba(30,100,220,0.6) 0%, transparent 45%),
      radial-gradient(ellipse at 50% 75%, rgba(0,180,140,0.5) 0%, transparent 50%),
      #0a0a2e;
  }
  .mb-cover-ttd { background-image: url('through-the-dark-cover.jpg'); }
  .mb-cover-love { background-image: url('love-cover.png'); }
  .mb-cover-bh { background-image: url('bravehearts-cover.png'); }
  .mb-cover-flash { background-image: url('the-flash-cover.png'); }
  .mb-cover-se { background-image: url('still-echoing-cover.png'); }
  .mb-cover-crazy { background-image: url('crazy-cover.png'); }
  .mb-cover-brh { background-image: url('butterflies-and-rabbit-holes-cover.png'); }

  /* ── Desktop full-width player bar ─────────────────────────── */
  .dt-player {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 260px;
    right: 340px;
    height: 88px;
    background: rgba(6,10,20,0.95);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(255,255,255,0.06);
    align-items: center;
    padding: 0 24px;
    gap: 24px;
    z-index: 100;
  }
  body:not(.dt-has-rail) .dt-player { right: 0; }
  .dt-player-left { display: flex; align-items: center; gap: 14px; min-width: 220px; max-width: 260px; }
  .dt-player-cover {
    width: 54px; height: 54px;
    border-radius: 8px;
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
  }
  .dt-player-info { min-width: 0; flex: 1; }
  .dt-player-title {
    font-size: 0.88em;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .dt-player-artist { font-size: 0.75em; color: rgba(255,255,255,0.45); }
  .dt-player-center {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
  }
  .dt-player-buttons { display: flex; align-items: center; gap: 18px; }
  .dt-player-btn {
    background: none;
    border: none;
    color: rgba(255,255,255,0.6);
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: color 0.15s;
  }
  .dt-player-btn:hover { color: #fff; }
  .dt-player-btn.active { color: #4cd1ab; }
  .dt-player-playbtn {
    width: 36px; height: 36px;
    background: #fff;
    color: #050810;
  }
  .dt-player-playbtn:hover { color: #050810; background: #fff; transform: scale(1.05); }
  .dt-player-progress-row {
    display: flex; align-items: center; gap: 10px;
    width: 100%; max-width: 540px;
    font-size: 0.72em;
    color: rgba(255,255,255,0.45);
    font-variant-numeric: tabular-nums;
  }
  .dt-player-progress {
    flex: 1;
    height: 4px;
    background: rgba(255,255,255,0.1);
    border-radius: 2px;
    cursor: pointer;
    position: relative;
  }
  .dt-player-progress-fill {
    height: 100%;
    background: #4cd1ab;
    border-radius: 2px;
    width: 0%;
  }
  .dt-player-right {
    display: flex; align-items: center; gap: 12px;
    min-width: 180px;
    justify-content: flex-end;
  }
  .dt-volume { display: flex; align-items: center; gap: 8px; color: rgba(255,255,255,0.5); }
  .dt-volume-slider {
    width: 90px;
    height: 4px;
    background: rgba(255,255,255,0.1);
    border-radius: 2px;
    cursor: pointer;
    position: relative;
  }
  .dt-volume-fill { height: 100%; background: #fff; border-radius: 2px; width: 80%; }
}
