.msp-player {
  --bg: #0f1117;
  --panel: #151a23;
  --panel-2: #1c2330;
  --line: #2b3445;
  --text: #f4f7ff;
  --muted: #9ca7ba;
  --accent: #1db954;
  --progress: 0%;
  max-width: 940px;
  margin: 28px auto;
  border-radius: 18px;
  border: 1px solid #273041;
  background: radial-gradient(1200px 380px at 20% -15%, #253042 0%, var(--bg) 55%);
  color: var(--text);
  font-family: "Circular Std", "Inter", "Avenir Next", sans-serif;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.4);
  padding: 20px;
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 22px;
}

.msp-now-playing {
  background: linear-gradient(180deg, #1a2130, #121923);
  border: 1px solid #2a3344;
  border-radius: 14px;
  padding: 14px;
}

.msp-now-cover {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  object-fit: cover;
  background: #2a3344;
}

.msp-now-title {
  margin: 14px 0 6px;
  font-size: 30px;
  line-height: 1.15;
  font-weight: 700;
}

.msp-now-artist {
  margin: 0;
  color: var(--muted);
  font-size: 18px;
}

.msp-up-next {
  background: var(--panel);
  border: 1px solid #253044;
  border-radius: 14px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.msp-up-next-label {
  margin: 0 0 10px;
  color: #aab5c9;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 700;
}

.msp-up-next-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 8px;
  max-height: 420px;
  overflow-y: auto;
}

.msp-up-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px;
  border-radius: 10px;
  cursor: pointer;
  transition: background-color 0.16s ease;
}

.msp-up-item:hover {
  background: #1e2736;
}

.msp-up-cover {
  width: 46px;
  height: 46px;
  border-radius: 8px;
  object-fit: cover;
  background: #2b3546;
  flex-shrink: 0;
}

.msp-up-cover-placeholder {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #cad3e3;
  font-size: 10px;
}

.msp-up-meta {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.msp-up-meta strong {
  font-size: 16px;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.msp-up-meta span {
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.msp-progress-block {
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.msp-progress {
  width: 100%;
  appearance: none;
  height: 5px;
  border-radius: 999px;
  background: linear-gradient(to right, var(--accent) 0%, var(--accent) var(--progress), #3a4458 var(--progress), #3a4458 100%);
  outline: none;
}

.msp-progress::-webkit-slider-thumb {
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 0;
  background: #fff;
}

.msp-progress::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 0;
  background: #fff;
}

.msp-time-row {
  margin-top: 8px;
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 12px;
}

.msp-controls {
  margin-top: 14px;
  display: grid;
  grid-template-columns: 1fr 1fr auto 1fr 1fr;
  align-items: center;
}

.msp-control-btn {
  width: 44px;
  height: 44px;
  margin: 0 auto;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #d6deec;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.15s ease, color 0.15s ease, background-color 0.15s ease;
}

.msp-control-btn:hover {
  background: #20293a;
}

.msp-control-btn:active,
.msp-control-btn.is-pulsing {
  transform: scale(0.95);
}

.msp-icon {
  width: 22px;
  height: 22px;
}

.msp-nav-btn .msp-icon {
  width: 27px;
  height: 27px;
}

.msp-play {
  width: 62px;
  height: 62px;
  background: var(--accent);
  color: #07110a;
  box-shadow: 0 8px 18px rgba(29, 185, 84, 0.38);
}

.msp-play:hover {
  background: #2ddb67;
}

.msp-play .msp-icon {
  width: 30px;
  height: 30px;
}

.msp-play .msp-icon-pause {
  display: none;
}

.msp-play.is-playing .msp-icon-play {
  display: none;
}

.msp-play.is-playing .msp-icon-pause {
  display: block;
}

.msp-loop-btn {
  color: #8e9ab0;
}

.msp-loop-btn.is-on {
  color: var(--accent);
}

@media (max-width: 900px) {
  .msp-player {
    grid-template-columns: 1fr;
    max-width: 640px;
    gap: 14px;
    padding: 16px;
  }

  .msp-now-playing {
    padding: 12px;
  }

  .msp-now-cover {
    max-width: 360px;
    margin: 0 auto;
  }

  .msp-up-next {
    padding: 12px;
  }

  .msp-up-next-list {
    max-height: 300px;
  }
}

@media (max-width: 560px) {
  .msp-player {
    margin: 0;
    border: 0;
    border-radius: 0;
    min-height: 100dvh;
    box-shadow: none;
    padding: 12px;
    background: linear-gradient(180deg, #0e131d 0%, #0f1117 30%, #0f1117 100%);
    gap: 10px;
  }

  .msp-now-playing {
    border-radius: 12px;
    padding: 10px;
  }

  .msp-now-cover {
    border-radius: 10px;
    max-width: 300px;
  }

  .msp-now-title {
    margin-top: 10px;
    font-size: 21px;
    line-height: 1.25;
  }

  .msp-now-artist {
    font-size: 14px;
    line-height: 1.3;
  }

  .msp-up-next {
    border-radius: 12px;
    padding: 10px;
  }

  .msp-up-next-label {
    margin-bottom: 8px;
    font-size: 11px;
  }

  .msp-up-next-list {
    max-height: 34vh;
    gap: 6px;
  }

  .msp-up-item {
    padding: 7px;
    border-radius: 8px;
    gap: 10px;
  }

  .msp-up-cover {
    width: 40px;
    height: 40px;
    border-radius: 7px;
  }

  .msp-up-meta strong {
    font-size: 14px;
  }

  .msp-up-meta span {
    font-size: 12px;
  }

  .msp-progress-block {
    margin-top: 10px;
    padding-top: 10px;
  }

  .msp-progress {
    height: 4px;
  }

  .msp-progress::-webkit-slider-thumb {
    width: 13px;
    height: 13px;
  }

  .msp-progress::-moz-range-thumb {
    width: 13px;
    height: 13px;
  }

  .msp-time-row {
    margin-top: 6px;
    font-size: 11px;
  }

  .msp-controls {
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid #232c3c;
  }

  .msp-control-btn {
    width: 40px;
    height: 40px;
  }

  .msp-icon {
    width: 20px;
    height: 20px;
  }

  .msp-nav-btn .msp-icon {
    width: 24px;
    height: 24px;
  }

  .msp-play {
    width: 56px;
    height: 56px;
  }

  .msp-play .msp-icon {
    width: 26px;
    height: 26px;
  }
}
