/* ============================================================
   MOISES COLACCI — repertorio.html Styles (Spotify Dark Player)
   ============================================================ */

/* ── PLAYER SECTION ──────────────────────────────────────── */
.player-section {
  background: var(--black);
  padding-bottom: 160px; /* room for sticky player */
}

/* ── GENRE TABS ──────────────────────────────────────────── */
.genre-tabs {
  display: flex;
  gap: 0;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
  border-bottom: 1px solid var(--border);
}

.genre-tab {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  padding: 0.9rem 1.5rem;
  font-family: var(--body-font);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gray);
  cursor: pointer;
  transition: all 0.3s;
  margin-bottom: -1px;
  white-space: nowrap;
}
.genre-tab:hover { color: var(--white); }
.genre-tab.active {
  color: var(--gold);
  border-bottom-color: var(--gold);
}

/* ── GENRE PANELS ────────────────────────────────────────── */
.genre-panel { display: none; }
.genre-panel.active { display: block; }

/* ── SONG LIST ───────────────────────────────────────────── */
.song-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.song-item {
  display: grid;
  grid-template-columns: 56px 1fr auto auto;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1rem;
  border-radius: 4px;
  transition: background 0.2s;
  cursor: pointer;
  border: 1px solid transparent;
}
.song-item:hover {
  background: var(--dark-2);
  border-color: var(--border);
}
.song-item.playing {
  background: rgba(201,169,110,0.06);
  border-color: rgba(201,169,110,0.2);
}

.song-cover {
  width: 56px;
  height: 56px;
  border-radius: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 1.3rem;
  color: rgba(255,255,255,0.3);
  position: relative;
  overflow: hidden;
}
.song-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.song-info { min-width: 0; }
.song-title {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--white);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 0.25rem;
}
.song-item.playing .song-title { color: var(--gold); }
.song-artist {
  font-size: 0.78rem;
  color: var(--gray);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.song-tag {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gray);
  border: 1px solid var(--border);
  padding: 0.25rem 0.6rem;
  white-space: nowrap;
}

.song-play-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(201,169,110,0);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray);
  transition: all 0.25s;
  flex-shrink: 0;
}
.song-play-btn svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}
.song-item:hover .song-play-btn {
  background: rgba(201,169,110,0.15);
  color: var(--gold);
}
.song-item.playing .song-play-btn {
  background: var(--gold);
  color: var(--black);
}

/* ── REPERTOIRE NOTE ─────────────────────────────────────── */
.repertorio-note {
  text-align: center;
  margin-top: 3rem;
  font-size: 0.85rem;
  color: var(--gray);
}
.repertorio-note a {
  color: var(--gold);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ── STICKY AUDIO PLAYER ─────────────────────────────────── */
.audio-player {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 998;
  height: 90px;
  background: #0d0d0d;
  border-top: 1px solid #222;
  display: grid;
  grid-template-columns: 90px 1fr auto auto auto;
  align-items: center;
  gap: 1.5rem;
  padding: 0 1.5rem;
  transform: translateY(100%);
  transition: transform 0.4s var(--ease);
}
.audio-player.visible { transform: translateY(0); }

.player-cover {
  width: 58px;
  height: 58px;
  border-radius: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: rgba(255,255,255,0.25);
  flex-shrink: 0;
  overflow: hidden;
  background: var(--dark-3);
  transition: background 0.4s;
}

.player-info {
  min-width: 0;
  flex: 1;
}
.player-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--white);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 0.2rem;
}
.player-artist {
  font-size: 0.75rem;
  color: var(--gray);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.player-controls {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.player-btn {
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray);
  cursor: pointer;
  transition: color 0.2s, background 0.2s;
}
.player-btn svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}
.player-btn:hover { color: var(--white); }

.player-play {
  width: 44px;
  height: 44px;
  background: var(--gold);
  color: var(--black);
}
.player-play:hover { background: var(--gold-light); }
.player-play svg { width: 18px; height: 18px; }

.player-progress-wrap {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.player-time {
  font-size: 0.7rem;
  color: var(--gray);
  white-space: nowrap;
  min-width: 2.5rem;
}
#timeDuration { text-align: right; }

.player-progress {
  flex: 1;
  height: 4px;
  background: var(--dark-3);
  border-radius: 2px;
  position: relative;
  cursor: pointer;
}
.player-progress:hover .player-progress-thumb { opacity: 1; }

.player-progress-bar {
  height: 100%;
  background: var(--gold);
  border-radius: 2px;
  width: 0%;
  transition: width 0.1s linear;
  pointer-events: none;
}

.player-progress-thumb {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 12px;
  height: 12px;
  background: var(--gold-light);
  border-radius: 50%;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
  left: 0%;
}

.player-vol-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
  width: 130px;
}
.vol-icon {
  width: 18px;
  height: 18px;
  fill: var(--gray);
  flex-shrink: 0;
}

.player-volume {
  -webkit-appearance: none;
  appearance: none;
  flex: 1;
  height: 4px;
  background: var(--dark-3);
  border-radius: 2px;
  outline: none;
  cursor: pointer;
}
.player-volume::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px;
  height: 12px;
  background: var(--gold);
  border-radius: 50%;
}
.player-volume::-moz-range-thumb {
  width: 12px;
  height: 12px;
  background: var(--gold);
  border-radius: 50%;
  border: none;
}

/* Equalizer animation for playing state */
.song-item.playing .song-cover::after {
  content: '▶';
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
  font-size: 1rem;
  background: rgba(0,0,0,0.4);
}

/* ── RESPONSIVE ──────────────────────────────────────────── */
@media (max-width: 900px) {
  .audio-player {
    grid-template-columns: 60px 1fr auto;
    grid-template-rows: auto auto;
    height: auto;
    padding: 0.75rem 1rem;
    gap: 0.75rem;
  }
  .player-cover { width: 48px; height: 48px; }
  .player-vol-wrap { display: none; }
  .player-progress-wrap {
    grid-column: 1 / -1;
    gap: 0.5rem;
  }
  .player-progress-wrap .player-time { min-width: 2rem; }
}

@media (max-width: 600px) {
  .song-item { grid-template-columns: 48px 1fr auto; }
  .song-tag { display: none; }
  .genre-tab { padding: 0.8rem 0.9rem; font-size: 0.65rem; }
  .player-section { padding-bottom: 140px; }
}

@media (max-width: 400px) {
  .song-item { grid-template-columns: 44px 1fr; }
  .song-play-btn { display: none; }
}
