/* ───────────── Reset & Grundlayout ───────────── */
html,
body {
  margin: 0;
  padding: 0;
  overflow: hidden; /* nur der Album-Bereich soll scrollen */
}

/*
  Zentrale Farb­definitionen
  → nur hier anpassen, der Rest zieht automatisch mit
*/
:root {
  --progress-color: rgb(255, 181, 199); /* Farbe des bereits abgespielten Balkens */
  --track-color:    #555;    /* Farbe des noch nicht abgespielten Bereichs */
  --banner-h: 150px;
  --footer-h: 160px;
  --lyrics-space: 410px;   /* reservierter Platz rechts für Lyrics */
  --albums-gap-top: 40px;
  --sbw: 17px;
  /* 1) DAS ist die Covergröße aus deinen Record-Bereichen
     -> setz den Wert auf genau den, den .record-cover bei dir hat */
  --cover-size: 300px;
  /* 2) Cards: nur “Hülle” drum herum (Cover bleibt gleich groß) */
  --side-card-w: calc(var(--cover-size) + 60px);
  --side-card-h: calc(var(--cover-size) + 170px);
}

body {
  background: url(pics/Timeline\ 5.gif);
  font-family: 'Roboto', sans-serif;
  background-attachment: fixed;
}

/* ─────────────────── Banner ──────────────────── */
.banner{
  position: fixed;
  top: 0;
  left: 0;
  right: var(--sbw);        /* lässt rechts Platz für den Scrollbalken */
  height: var(--banner-h);
  z-index: 5000;            /* über den Alben */
}

.banner img {
  width: 100%;
  height: 150px;
  object-fit: cover;
}

.banner-title {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: 'Great Vibes', cursive;
  font-weight: 400;      /* Great Vibes hat nur einen Schnitt */
  font-size: 4rem;       /* nach Geschmack anpassen */
  color: rgb(255, 181, 199);
  margin: 0;
  text-shadow: 2px 2px 4px #000;
}

.now-playing{
  position: fixed;
  left: 50px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 900; /* wie lyrics */
}

.now-playing-title{
  margin: 0 0 14px;
  font-size: 1.5em;
}

.now-playing-cover{
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 14px;
  display: block;
  margin: 0 0 14px;
}

.now-playing-album{
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 6px;
}

.now-playing-song{
  font-size: 1rem;
  opacity: 0.95;
}

/* ─────────────── Record-Blöcke ──────────────── */
#records-container{
  scrollbar-width: none;
  margin-top: 150px;
  position: fixed;
  inset: 0;
  overflow-y: auto;
  overflow-x: hidden;
  z-index: 1;
  padding-bottom: calc(var(--footer-h) + 10px);              /* Abstand über Player */

  padding-left: var(--lyrics-space);
  padding-right: var(--lyrics-space);

  display: grid;
  grid-template-columns: repeat(2, max-content);
  gap: 50px 60px;
  justify-content: center;
}

/* .record braucht jetzt kein margin-left mehr */
.record{
  width: 300px;
  padding: 30px;
  border-radius: 20px;
  background: rgba(255,181,199,.55);
  /* margin: 50px auto;  ← löschen */
}

.record-cover{
  width: var(--cover-size);
  height: var(--cover-size);
  display: block;
  border-radius: 14px;
  margin: 0 auto 14px;
  object-fit: cover;
  aspect-ratio: 1 / 1;   /* macht es immer schön quadratisch */
}

/* Now Playing Cover NICHT mitskalieren */
#now-playing img,
#now-cover{
  width: var(--cover-size) !important;
  height: var(--cover-size) !important;
  object-fit: cover;
}

.record-title {
  margin: 0 0 8px;
  font-size: 1.5em;
  display: flex;
  justify-content: center;
}

/* ───────────── Songliste & Buttons ───────────── */
.song-list {
  list-style: none;
  padding: 0;
  margin: 0 auto;
}

.song-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  border-bottom: 1px solid #000;
  margin: 20px 0px;
}

.song-item-title {
  text-align: center;
}

.playBtn {
  all: unset;
  width: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 20px;
}

.song-list audio {
  display: none;
}

/* ────────────── Footer-Player ──────────────── */
#footer-player {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: #000;
  padding: 20px 0;
  box-shadow: 0 -2px 5px rgba(0, 0, 0, .1);
  z-index: 1000;
}

.footer-controls {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-bottom: 15px;
  align-items: center;
}

.footer-controls button {
  all: unset;
  font-size: 24px;
  cursor: pointer;
}

.footer-controls button:focus {
  outline: none;
}

/* ───────────── Fortschritts-Leiste ───────────── */
.footer-progress-container {
  display: flex;
  align-items: center;
  width: 90%;
  max-width: 800px;
  gap: 10px;
  margin-bottom: 5px;
  color: #fff;
}

/* ersetzt alten Block */
#footer-progress {
  appearance: none;
  flex: 1;
  cursor: pointer;
  height: 4px;
  border-radius: 20px;
  --progress: 0%;

  /* Farbverlauf – nutzt die CSS‑Variablen; JS ändert nur --progress */
  background: linear-gradient(
    to right,
    var(--progress-color) 0%,
    var(--progress-color) var(--progress),
    var(--track-color) var(--progress),
    var(--track-color) 100%
  );

  /* moderner Fallback: färbt Track + Thumb in neuen Browsern */
  accent-color: var(--progress-color);
}

/* WebKit (Chrome, Edge, Safari) */
#footer-progress::-webkit-slider-thumb {
  appearance: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: white;
  border: none;
  box-shadow: 0 0 2px rgba(0, 0, 0, .4);
}

#footer-progress::-webkit-slider-runnable-track {
  background: transparent;
}

/* Firefox */
#footer-progress::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--progress-color);
  border: none;
  box-shadow: 0 0 2px rgba(0, 0, 0, .4);
}

#footer-progress::-moz-range-track {
  background: transparent;
}

#footer-progress.hide-thumb::-webkit-slider-thumb {
  display: none;
}

#footer-progress.hide-thumb::-moz-range-thumb {
  display: none;
}

/* Zeiten & Songtitel */
#footer-current-time,
#footer-duration {
  font-size: 14px;
  width: 40px;
  text-align: center;
}

.footer-title {
  font-size: 16px;
  color: #fff;
}

/* ───────────── Footer-Icon-Buttons ───────────── */
#footer-prev,
#footer-next,
#footer-play-pause {
  width: 32px;
  height: 32px;
  display: inline-flex;
  justify-content: center;
  font-size: 0;
  background: no-repeat center/contain;
  cursor: pointer;
}

#footer-shuffle,
#footer-repeat {
  opacity: .4;
  width: 17.5px;
  height: 17.5px;
  display: inline-flex;
  justify-content: center;
  font-size: 0;
  background: no-repeat center/contain;
  cursor: pointer;
}

#footer-shuffle {
    width: 21px;
  height: 21px;
}

#footer-prev,
#footer-next {
  width: 17.5px;
  height: 17.5px;
  opacity: 0.7;
}

#footer-prev:hover,
#footer-next:hover {
  opacity: 1; /* Volle Deckkraft bei Hover */
}

#footer-prev.disabled,
#footer-next.disabled {
  opacity: .7;
}

.download-button {
  width: 40px;
  height: 40px;
  display: inline-flex;
  justify-content: center;
  font-size: 0;
  overflow: hidden;
  background: no-repeat center/contain;
  cursor: pointer;
  position: relative;
  top: 4px;
}

/* ───────────── Lyrics-Karte (rechts) ───────────── */
.lyrics-layout{
  position: fixed;
  right: 50px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 900;

  /* wichtig: Höhe wird per JS auf Now-Playing-Höhe gesetzt */
  display: flex;
  flex-direction: column;
}

/* Überschrift wie Album-Title */
.lyrics-layout > h3{
  margin: 0 0 14px;
  font-size: 1.5em;
  line-height: 1.1;
}

/* Scrollbereich für Lyrics */
.lyrics-box{
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;

  /* Scrollbar verstecken (Spotify-Feeling) */
  scrollbar-width: none;
}
.lyrics-box::-webkit-scrollbar{
  width: 0;
  height: 0;
}

/* Lyrics-Liste */
#lyrics-display{
  display: flex;
  flex-direction: column;
  gap: 22px;
  /* unten extra Platz, damit die letzte Zeile in die Mitte scrollen kann */
  padding: 10px 0 50vh;
}

/* einzelne Zeile */
.lyric-line{
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.25;
  text-shadow: 2px 2px 4px #000;
  color: #fff;
  opacity: 0.35;
  transition: opacity .18s ease, transform .18s ease;
}

/* aktive Zeile */
.lyric-line.active{
  opacity: 1;
  transform: scale(1.02);
}

/* falls keine Lyrics vorhanden */
.lyrics-empty{
  color: #fff;
  opacity: 0.6;
  font-size: 1rem;
}

/* Now playing + Lyrics: gleiche Außenmaße */
#now-playing,
.record.lyrics-layout{
  width: var(--side-card-w) !important;
  height: var(--side-card-h) !important;
  box-sizing: border-box;

  display: flex;
  flex-direction: column;
}

/* Lyrics sollen im inneren Bereich scrollen */
.record.lyrics-layout .lyrics-box{
  flex: 1;
  min-height: 0;     /* super wichtig für flex + overflow */
  overflow-y: auto;
}