:root {
  --bg: #0f172a;
  --card: rgba(255, 255, 255, 0.08);
  --card-strong: rgba(255, 255, 255, 0.13);
  --text: #f8fafc;
  --muted: #cbd5e1;
  --line: rgba(255, 255, 255, 0.16);
  --accent: #38bdf8;
  --accent-2: #22c55e;
  --danger: #fb7185;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(56, 189, 248, 0.30), transparent 32rem),
    radial-gradient(circle at bottom right, rgba(34, 197, 94, 0.18), transparent 34rem),
    var(--bg);
}

button, input {
  font: inherit;
}

.app {
  width: min(1040px, calc(100% - 32px));
  margin: 0 auto;
  padding: 42px 0;
}

.hero {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: start;
  margin-bottom: 24px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: .16em;
  font-size: 12px;
  font-weight: 800;
}

h1 {
  margin: 0;
  font-size: clamp(34px, 6vw, 64px);
  line-height: 0.95;
  letter-spacing: -0.05em;
}

.subtitle {
  max-width: 650px;
  margin: 16px 0 0;
  color: var(--muted);
  line-height: 1.6;
  font-size: 17px;
}

.brand-box {
  width: 205px;
  height: 205px;
  border-radius: 24px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.24);
  padding: 12px;
}

.brand-logo {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.player-card,
.playlist-card,
.upload-zone,
.search-box {
  border: 1px solid var(--line);
  border-radius: 28px;
  background: var(--card);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}

.player-card {
  padding: 24px;
  margin-bottom: 18px;
}

.now-playing {
  display: flex;
  gap: 18px;
  align-items: center;
  margin-bottom: 20px;
}

.cover {
  width: 86px;
  height: 86px;
  border-radius: 24px;
  display: grid;
  place-items: center;
  font-size: 42px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #07111f;
  font-weight: 900;
  flex: 0 0 auto;
}

.label {
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: .12em;
}

#trackTitle {
  margin: 0 0 6px;
  font-size: clamp(22px, 3vw, 34px);
  letter-spacing: -0.03em;
}

#trackMeta {
  margin: 0;
  color: var(--muted);
}

audio {
  width: 100%;
  margin: 6px 0 18px;
  accent-color: var(--accent);
}

.buttons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

button {
  border: 1px solid var(--line);
  background: var(--card-strong);
  color: var(--text);
  padding: 12px 16px;
  border-radius: 999px;
  cursor: pointer;
  transition: transform .15s ease, background .15s ease;
}

button:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.18);
}

button.primary {
  border-color: transparent;
  background: var(--accent);
  color: #07111f;
  font-weight: 800;
}



.options {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  margin-top: 18px;
  color: var(--muted);
}

.options label {
  display: flex;
  gap: 8px;
  align-items: center;
}

.tools {
  display: grid;
  grid-template-columns: 1.3fr .7fr;
  gap: 18px;
  margin-bottom: 18px;
}

.upload-zone {
  display: grid;
  gap: 8px;
  padding: 24px;
  cursor: pointer;
  border-style: dashed;
}

.upload-zone.dragover {
  background: rgba(56, 189, 248, 0.18);
  border-color: var(--accent);
}

.upload-zone span {
  color: var(--muted);
}

.upload-zone input {
  display: none;
}

.search-box {
  padding: 16px;
  display: flex;
  align-items: center;
}

.search-box input {
  width: 100%;
  border: 0;
  outline: 0;
  border-radius: 18px;
  padding: 14px 16px;
  color: var(--text);
  background: rgba(15, 23, 42, 0.55);
  border: 1px solid var(--line);
}

.playlist-card {
  padding: 18px;
}

.playlist-header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 14px;
}

.playlist-header h2 {
  margin: 0;
  letter-spacing: -0.03em;
}

#clearLocalBtn {
  color: var(--danger);
}

.playlist {
  display: grid;
  gap: 10px;
}

.track {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.34);
  cursor: pointer;
}

.track:hover,
.track.active {
  background: rgba(56, 189, 248, 0.14);
  border-color: rgba(56, 189, 248, 0.55);
}

.track-number {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, 0.12);
  color: var(--muted);
  font-weight: 800;
}

.track-title {
  margin: 0 0 4px;
  font-weight: 800;
}

.track-meta {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.badge {
  color: #07111f;
  background: var(--accent-2);
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.empty {
  color: var(--muted);
  padding: 22px;
  text-align: center;
  border: 1px dashed var(--line);
  border-radius: 20px;
}

footer {
  color: var(--muted);
  line-height: 1.6;
  margin-top: 18px;
}

code {
  background: rgba(255, 255, 255, 0.11);
  padding: 2px 6px;
  border-radius: 8px;
}

@media (max-width: 760px) {
  .hero,
  .tools {
    grid-template-columns: 1fr;
  }

  .brand-box {
    width: 100%;
    height: 90px;
  }

  .track {
    grid-template-columns: auto 1fr;
  }

  .badge {
    grid-column: 2;
    width: fit-content;
  }
}
