:root{
  --bgTop:#432b86;
  --bgMid:#2b1b5a;
  --bgBot:#1b0f3f;

  --cardBg: rgba(255,255,255,.10);
  --cardBorder: rgba(255,255,255,.18);

  --radius: 20px;
  --shadow: 0 18px 45px rgba(0,0,0,.30);
}

*{ box-sizing:border-box; }

html, body { height:100%; }

body{
  margin:0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color:#fff;
  padding-bottom: 56px; /* Höhe des Footers */

  /* smooth gradient (fixed verhindert "Scroll-Banding") */
  background: linear-gradient(180deg, var(--bgTop) 0%, var(--bgMid) 55%, var(--bgBot) 100%);
  background-attachment: fixed;
  position: relative;
  overflow-x: hidden;
}

/* Noise/Glow Overlay gegen Streifen */
body::before{
  content:"";
  position:fixed;
  inset:0;
  pointer-events:none;

  /* weiches Licht + minimal “noise” durch viele Radials */
  background:
    radial-gradient(900px 500px at 50% -120px, rgba(255,255,255,.18), transparent 60%),
    radial-gradient(1200px 800px at 10% 20%, rgba(0,0,0,.14), transparent 55%),
    radial-gradient(1000px 700px at 90% 40%, rgba(0,0,0,.16), transparent 60%),
    radial-gradient(2px 2px at 10% 20%, rgba(255,255,255,.08), transparent 60%),
    radial-gradient(2px 2px at 30% 80%, rgba(255,255,255,.06), transparent 60%),
    radial-gradient(2px 2px at 70% 30%, rgba(255,255,255,.05), transparent 60%),
    radial-gradient(2px 2px at 90% 70%, rgba(255,255,255,.06), transparent 60%);
  opacity:.9;
  filter: blur(0.2px);
}

/* Header */
header{
  text-align:center;
  padding: 54px 16px 18px;
  position: relative;
  z-index: 1;
}

h1{
  margin:0;
  font-size:42px;
  letter-spacing:.4px;
}

.subtitle{
  margin-top:10px;
  opacity:.85;
  font-size:15px;
}

/* Layout */
.container{
  max-width:1100px;
  margin:0 auto;
  padding: 14px 18px 56px;
  position: relative;
  z-index: 1;
}

/* Grid größer */
.grid{
  display:grid;
  gap:22px;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}

/* Card */
.song-card{
  background: var(--cardBg);
  border: 1px solid var(--cardBorder);
  border-radius: var(--radius);
  padding: 14px;
  cursor:pointer;
  transition: transform .12s ease, background .12s ease, border-color .12s ease;
  backdrop-filter: blur(6px);
}

.song-card:hover{
  transform: translateY(-5px);
  background: rgba(255,255,255,.14);
  border-color: rgba(255,255,255,.28);
}

/* Cover */
.cover{
  width:100%;
  aspect-ratio:1/1;
  object-fit:cover;
  display:block;
  border-radius: 16px;
  box-shadow: var(--shadow);
  background: rgba(0,0,0,.18);
}

/* Text */
.song-meta{
  text-align:center;
  padding: 12px 6px 4px;
}

.song-title{
  margin:0;
  font-weight:900;
  font-size:17px;
  line-height:1.25;
}

.song-sub{
  margin:8px 0 0;
  display:flex;
  justify-content:center;
  gap:10px;
  flex-wrap:wrap;
  opacity:.88;
  font-size:13px;
}

.badge{
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.22);
  background: rgba(255,255,255,.08);
}

/* helpers */
.row{ display:flex; gap:12px; flex-wrap:wrap; align-items:center; }
a.btn, button.btn{
  display:inline-block;
  padding:10px 12px;
  border-radius:12px;
  border:1px solid rgba(255,255,255,.25);
  text-decoration:none;
  color:#fff;
  background: rgba(255,255,255,.10);
  cursor:pointer;
}
audio{ width:100%; }
.lyrics{
  white-space: pre-wrap;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.18);
  border-radius: var(--radius);
  padding: 14px;
}
hr{ border:none; border-top:1px solid rgba(255,255,255,.18); margin:18px 0; }
small.muted{ opacity:.8; }


.player{
  display:flex;
  align-items:center;
  gap:12px;
  padding:12px 14px;
  border-radius: 18px;
  background: rgba(255,255,255,.10);
  border:1px solid rgba(255,255,255,.18);
  backdrop-filter: blur(6px);
}

.pbtn{
  width:44px;
  height:44px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.22);
  background: rgba(255,255,255,.10);
  color:#fff;
  cursor:pointer;
  font-size:18px;
}

.pbtn:hover{ background: rgba(255,255,255,.16); }

.pmeta{ flex:1; min-width: 180px; }
.ptime{ display:flex; gap:8px; opacity:.9; font-size:13px; margin-bottom:8px; }
.sep{ opacity:.6; }

.seek{
  width:100%;
  accent-color: #ffffff; /* in Chrome/Edge */
}

.vol{
  display:flex;
  align-items:center;
  gap:8px;
}

.volrange{
  width:90px;
  accent-color:#ffffff;
}
.lyrics-line{
  padding: 8px 10px;
  border-radius: 12px;
  opacity: .6;
  transition: all .2s ease;
}

.lyrics-line.active{
  background: rgba(255,255,255,.18);
  border: 1px solid rgba(255,255,255,.25);
  opacity: 1;
  transform: scale(1.03);
}

/* Karaoke Viewport */
.karaoke{
  position: relative;
  border-radius: 20px;
  padding: 18px 16px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.18);
  backdrop-filter: blur(6px);
  overflow: hidden;
}

/* weiche Fade oben/unten */
.karaoke:before,
.karaoke:after{
  content:"";
  position:absolute;
  left:0; right:0;
  height:54px;
  pointer-events:none;
  z-index:2;
}
.karaoke:before{
  top:0;
  background: linear-gradient(180deg, rgba(40,22,80,.95), rgba(40,22,80,0));
}
.karaoke:after{
  bottom:0;
  background: linear-gradient(0deg, rgba(40,22,80,.95), rgba(40,22,80,0));
}

.klist{
  position: relative;
  z-index:1;
  height: 260px;              /* Sichtfenster */
  overflow: hidden;           /* kein scrollbar */
  display:flex;
  flex-direction:column;
  justify-content:center;
  gap: 10px;
}

/* Zeilen Styles */
.kline{
  text-align:center;
  opacity:.35;
  font-size: 16px;
  line-height: 1.4;
  transition: opacity .18s ease, transform .18s ease, font-size .18s ease, filter .18s ease;
  filter: blur(.15px);
}

.kline.prev, .kline.next{
  opacity:.55;
  font-size: 18px;
}


.kline.active{
  opacity: 1;
  font-size: 28px;
  font-weight: 900;
  filter: none;
  text-shadow: 0 10px 22px rgba(0,0,0,.28);
}

.fullbox{
  height: 260px;
  overflow-y: auto;
  padding: 10px 14px;

  white-space: pre-wrap;   /* WICHTIG */
  word-break: break-word;
  line-height: 1.8;
  font-size: 16px;

  opacity: .95;
}



/* optional: schöner Scrollbar (Chromium) */
.fullbox::-webkit-scrollbar{ width: 10px; }
.fullbox::-webkit-scrollbar-thumb{
  background: rgba(255,255,255,.18);
  border-radius: 999px;
}
.fullbox::-webkit-scrollbar-track{
  background: rgba(255,255,255,.06);
  border-radius: 999px;
}

/* Active Button Optik */
.btn.active{
  background: rgba(255,255,255,.18);
  border-color: rgba(255,255,255,.35);
}

.site-footer{
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;

  padding: 12px 16px;
  text-align: center;

  border-top: 1px solid rgba(255,255,255,.12);
  background: linear-gradient(
    180deg,
    rgba(25,15,55,.85),
    rgba(15,10,35,.95)
  );

  color: rgba(255,255,255,.75);
  font-size: 14px;
  backdrop-filter: blur(6px);
}

.site-footer a{
  color: rgba(255,255,255,.85);
  text-decoration: none;
}
.site-footer a:hover{
  text-decoration: underline;
}

.site-footer .footer-inner{
  display:flex;
  justify-content:center;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}

.site-footer .sep{
  opacity:.4;
}

.share-info{
  position: fixed;
  bottom: 70px; /* über dem Footer */
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0,0,0,.7);
  color: #fff;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
}
.share-info.show{
  opacity: 1;
}

.pbtn.active{
  background: rgba(255,255,255,.28) !important;
  border-color: rgba(255,255,255,.55) !important;
  box-shadow:
    0 0 0 2px rgba(255,255,255,.25),
    0 10px 26px rgba(0,0,0,.35);
  transform: translateY(-1px);
}

.loopbtn{
  position: relative;
}

.loopbtn.active::after{
  content: "ON";
  position: absolute;
  top: -6px;
  right: -6px;
  font-size: 10px;
  font-weight: 900;
  padding: 2px 6px;
  border-radius: 999px;
  background: rgba(255,255,255,.92);
  color: #1b0f3f;
  border: 1px solid rgba(0,0,0,.12);
}

/* ===== Mobile Player Tuning ===== */
@media (max-width: 640px){

  /* Player darf umbrechen und nutzt volle Breite */
  .player{
    flex-wrap: wrap;
    gap: 10px;
    padding: 14px;
  }

  /* Buttons größer und touch-friendly */
  .player .pbtn{
    width: 48px;
    height: 48px;
    border-radius: 14px;
    font-size: 18px;
  }

  /* Meta-Block (Zeit + Seek) auf volle Breite in Zeile 2 */
  .player .pmeta{
    order: 10;
    flex: 1 1 100%;
    min-width: 100%;
  }

  /* Seekbar volle Breite */
  .player .seek{
    width: 100%;
  }

  /* Zeit etwas größer */
  .player .ptime{
    font-size: 14px;
    opacity: .95;
    margin-bottom: 6px;
  }

  /* Volume-Block bleibt rechts oben, Slider kürzer */
  .player .vol{
    margin-left: auto;
    gap: 8px;
  }
  .player .volrange{
    width: 110px;
  }
}

@media (max-width: 640px){
  .cover{
    max-width: 100% !important;
  }
  h1{
    font-size: 40px; /* optional */
    line-height: 1.05;
  }
}