:root {
  color-scheme: light;
  --bg: #fff8f1;
  --cream: #fffaf3;
  --milk: rgba(255, 255, 255, 0.78);
  --panel: rgba(255, 255, 255, 0.72);
  --panel-strong: rgba(255, 255, 255, 0.92);
  --line: rgba(116, 91, 104, 0.14);
  --text: #4d4050;
  --muted: #8f7f8d;
  --dim: #b6a8b1;
  --peach: #ffb7a7;
  --pink: #ffc6d9;
  --mint: #bff4da;
  --blue: #b8e7ff;
  --lavender: #d9c8ff;
  --banana: #ffe99d;
  --green: #64c99d;
  --danger: #ef7f8f;
  --shadow: 0 22px 60px rgba(178, 135, 152, 0.2);
  --soft-shadow: 0 12px 32px rgba(178, 135, 152, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 12% 10%, rgba(255, 198, 217, 0.78), transparent 20rem),
    radial-gradient(circle at 88% 8%, rgba(184, 231, 255, 0.72), transparent 22rem),
    radial-gradient(circle at 72% 82%, rgba(191, 244, 218, 0.72), transparent 24rem),
    linear-gradient(135deg, #fff9ef 0%, #fff5fa 48%, #f3fff9 100%);
  color: var(--text);
  font-family: "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC", "Segoe UI", sans-serif;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.aurora {
  position: fixed;
  width: 27rem;
  height: 27rem;
  border-radius: 42% 58% 63% 37% / 45% 37% 63% 55%;
  filter: blur(18px);
  opacity: 0.66;
  pointer-events: none;
  animation: blobFloat 14s ease-in-out infinite alternate;
}

.aurora-one {
  top: -9rem;
  left: 12%;
  background: linear-gradient(135deg, var(--pink), var(--banana));
}

.aurora-two {
  right: -9rem;
  bottom: 10%;
  background: linear-gradient(135deg, var(--blue), var(--mint));
  animation-delay: -5s;
}

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.28;
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.78) 1px, transparent 1px),
    radial-gradient(circle, rgba(255, 198, 217, 0.24) 1px, transparent 1px);
  background-position: 0 0, 18px 18px;
  background-size: 36px 36px;
}

.app-shell {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 17.5rem minmax(0, 1fr);
  gap: 1.1rem;
  min-height: 100vh;
  padding: 1.1rem;
}

.sidebar,
.main-panel,
.side-card,
.hero,
.playlist-hero,
.search-panel,
.settings-card,
.now-playing-card,
.player-controls-card,
.lyrics-card,
.song-row,
.chart-card,
.load-more-state {
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: var(--soft-shadow);
  backdrop-filter: blur(18px);
}

.sidebar {
  position: sticky;
  top: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  height: calc(100vh - 2.2rem);
  padding: 1rem;
  border-radius: 2rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(255, 246, 250, 0.74));
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.brand-mark {
  display: grid;
  width: 3.3rem;
  height: 3.3rem;
  place-items: center;
  border-radius: 1.25rem 1.75rem 1.25rem 1.75rem;
  background: linear-gradient(135deg, var(--peach), var(--pink) 52%, var(--lavender));
  color: #7b5264;
  font-size: 1.65rem;
  font-weight: 900;
  box-shadow: 0 14px 30px rgba(255, 183, 167, 0.38);
}

.brand h1,
.brand p,
.topbar h2,
.topbar p,
.hero h3,
.hero p,
.section-head h3,
.section-head p,
.playlist-hero h3,
.playlist-hero p,
.now-playing-card h3,
.now-playing-card p,
.settings-card h3,
.settings-card p,
.player-controls-card h3 {
  margin: 0;
}

.brand h1 {
  font-size: 1.08rem;
  letter-spacing: 0.07em;
}

.brand p,
.eyebrow {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.nav {
  display: grid;
  gap: 0.55rem;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 0.58rem;
  width: 100%;
  border: 0;
  border-radius: 1.35rem;
  padding: 0.92rem 1rem;
  background: transparent;
  color: var(--muted);
  text-align: left;
  transition: 0.22s ease;
}

.iconfont {
  font-size: 1.05em;
  line-height: 1;
}

.nav-item:hover,
.nav-item.active {
  background: linear-gradient(135deg, rgba(255, 198, 217, 0.56), rgba(191, 244, 218, 0.5));
  color: #604457;
  transform: translateX(4px);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.66), 0 10px 24px rgba(178, 135, 152, 0.12);
}

.side-card {
  width: 100%;
  margin-top: auto;
  padding: 1rem;
  border-radius: 1.55rem;
  text-align: left;
  justify-items: start;
  background: linear-gradient(135deg, rgba(255, 233, 157, 0.44), rgba(184, 231, 255, 0.44));
}

.side-card span {
  display: block;
  color: var(--muted);
  font-size: 0.82rem;
}

.side-card strong {
  display: block;
  margin: 0.35rem 0 0.75rem;
  font-size: 1.15rem;
}

.main-panel {
  min-width: 0;
  padding: 1rem;
  border-radius: 2.1rem;
  background: rgba(255, 255, 255, 0.54);
  box-shadow: var(--shadow);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.topbar h2 {
  font-size: clamp(1.7rem, 3vw, 2.7rem);
  color: #604457;
}

.quick-search,
.search-panel,
.settings-form,
.settings-actions,
.hero-actions,
.control-row,
.volume-row,
.time-row,
.player-topline,
.song-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.quick-search {
  min-width: min(32rem, 52vw);
  padding: 0.38rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: var(--soft-shadow);
}

.quick-search input,
.search-panel input,
.settings-form input {
  min-width: 0;
  border: 1px solid rgba(116, 91, 104, 0.12);
  outline: none;
  border-radius: 1.2rem;
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
}

.quick-search input {
  flex: 1;
  border: 0;
  padding: 0.78rem 1rem;
  background: transparent;
}

.quick-search input::placeholder,
.search-panel input::placeholder,
.settings-form input::placeholder {
  color: #b7a7b2;
}

.quick-search button,
.primary-btn,
.secondary-btn,
.ghost-btn,
.text-btn,
.play-btn,
.round-btn,
.queue-next-btn {
  border: 0;
  border-radius: 999px;
  color: var(--text);
  transition: transform 0.2s ease, filter 0.2s ease, box-shadow 0.2s ease;
}

.quick-search button,
.primary-btn,
.play-btn {
  padding: 0.82rem 1.15rem;
  background: linear-gradient(135deg, var(--peach), var(--pink));
  color: #70465a;
  font-weight: 900;
  box-shadow: 0 12px 26px rgba(255, 183, 167, 0.28);
}

.secondary-btn,
.ghost-btn,
.round-btn,
.queue-next-btn {
  padding: 0.72rem 1rem;
  background: linear-gradient(135deg, rgba(184, 231, 255, 0.7), rgba(191, 244, 218, 0.7));
  color: #526072;
  font-weight: 800;
}

.queue-next-btn {
  position: relative;
  z-index: 2;
  padding: 0.5rem 0.82rem;
  font-size: 0.82rem;
  white-space: nowrap;
}

.queue-next-btn:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.text-btn {
  background: transparent;
  color: #d57891;
  font-weight: 900;
}

.small {
  padding: 0.65rem 0.9rem;
  font-size: 0.9rem;
}

button:hover {
  filter: brightness(1.02) saturate(1.04);
  transform: translateY(-2px);
  box-shadow: 0 16px 30px rgba(178, 135, 152, 0.18);
}

.notice {
  margin-bottom: 1rem;
  padding: 0.95rem 1rem;
  border: 1px solid rgba(100, 201, 157, 0.3);
  border-radius: 1.25rem;
  background: rgba(191, 244, 218, 0.58);
  color: #4e8a72;
  font-weight: 800;
}

.notice.error {
  border-color: rgba(239, 127, 143, 0.34);
  background: rgba(255, 198, 217, 0.58);
  color: #b75e71;
}

.view {
  display: none;
  animation: rise 0.36s ease both;
}

.view.active {
  display: block;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) 23rem;
  gap: 1rem;
  min-height: 23rem;
  overflow: hidden;
  padding: clamp(1.4rem, 4vw, 3rem);
  border-radius: 2rem;
  background:
    radial-gradient(circle at 82% 18%, rgba(255, 233, 157, 0.7), transparent 15rem),
    linear-gradient(135deg, rgba(255, 198, 217, 0.68), rgba(184, 231, 255, 0.48) 52%, rgba(191, 244, 218, 0.56));
}

.hero-copy {
  align-self: center;
}

.hero h3 {
  max-width: 45rem;
  font-size: clamp(2rem, 5vw, 4.35rem);
  line-height: 1.06;
  letter-spacing: -0.055em;
  color: #664659;
}

.hero p:not(.eyebrow) {
  max-width: 42rem;
  margin-top: 1rem;
  color: #7e6876;
  line-height: 1.85;
}

.hero-actions {
  margin-top: 1.4rem;
  flex-wrap: wrap;
}

.hero-disc {
  position: relative;
  display: grid;
  place-items: center;
}

.disc-ring {
  width: min(20rem, 52vw);
  aspect-ratio: 1;
  border-radius: 46% 54% 51% 49% / 45% 48% 52% 55%;
  background:
    radial-gradient(circle, rgba(255, 255, 255, 0.86) 0 19%, transparent 20%),
    conic-gradient(from 110deg, var(--pink), var(--banana), var(--mint), var(--blue), var(--lavender), var(--pink));
  box-shadow: 0 30px 65px rgba(178, 135, 152, 0.2);
  animation: spin 20s linear infinite;
}

.disc-core {
  position: absolute;
  display: grid;
  width: 7rem;
  aspect-ratio: 1;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.82);
  color: #895b70;
  font-size: 1.2rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  box-shadow: inset 0 0 0 1px rgba(116, 91, 104, 0.08);
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin: 1.45rem 0 0.85rem;
}

.section-head h3 {
  font-size: 1.35rem;
  color: #604457;
}

.section-head.tight {
  margin-top: 0;
}

.chart-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.8rem;
}

.chart-card {
  position: relative;
  overflow: hidden;
  min-height: 9.5rem;
  padding: 1rem;
  border-radius: 1.6rem;
  text-align: left;
  background: rgba(255, 255, 255, 0.66);
}

.chart-card:nth-child(1) {
  background: linear-gradient(135deg, rgba(255, 198, 217, 0.72), rgba(255, 233, 157, 0.58));
}

.chart-card:nth-child(2) {
  background: linear-gradient(135deg, rgba(184, 231, 255, 0.74), rgba(217, 200, 255, 0.58));
}

.chart-card:nth-child(3) {
  background: linear-gradient(135deg, rgba(191, 244, 218, 0.78), rgba(184, 231, 255, 0.58));
}

.chart-card:nth-child(4) {
  background: linear-gradient(135deg, rgba(255, 233, 157, 0.7), rgba(255, 183, 167, 0.58));
}

.chart-card::after {
  content: "";
  position: absolute;
  right: -2.2rem;
  bottom: -2.2rem;
  width: 7.2rem;
  aspect-ratio: 1;
  border-radius: 48% 52% 43% 57% / 52% 38% 62% 48%;
  background: rgba(255, 255, 255, 0.38);
}

.chart-card strong {
  display: block;
  font-size: 1.35rem;
  color: #604457;
}

.chart-card span {
  display: block;
  margin-top: 0.5rem;
  color: #7e6876;
  line-height: 1.5;
}

.playlist-hero {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  border-radius: 1.8rem;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.78), rgba(255, 246, 250, 0.72));
}

.cover,
.vinyl-wrap {
  flex: 0 0 auto;
  width: 8rem;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 1.6rem;
  background: linear-gradient(135deg, var(--pink), var(--blue));
}

.cover img,
.vinyl-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.placeholder-cover,
.vinyl-fallback {
  display: grid;
  place-items: center;
  color: #895b70;
  font-weight: 900;
}

.playlist-hero p:not(.eyebrow) {
  margin-top: 0.45rem;
  color: var(--muted);
}

.song-list {
  display: grid;
  gap: 0.68rem;
}

.song-row {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr) minmax(12rem, auto);
  align-items: center;
  gap: 0.85rem;
  padding: 0.8rem 0.95rem;
  border-radius: 1.35rem;
  background: rgba(255, 255, 255, 0.72);
  transition: 0.2s ease;
}

.song-row:hover {
  border-color: rgba(255, 183, 167, 0.42);
  background: linear-gradient(135deg, rgba(255, 246, 250, 0.9), rgba(243, 255, 249, 0.82));
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.song-index {
  width: 2.2rem;
  color: #b898a8;
  font-weight: 900;
  text-align: center;
}

.song-cover {
  width: 3.25rem;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 1rem;
  background: linear-gradient(135deg, var(--lavender), var(--mint));
}

.song-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.song-cover-placeholder {
  display: grid;
  place-items: center;
  color: #8f7f8d;
  font-size: 1.2rem;
  font-weight: 900;
}

.song-main {
  min-width: 0;
}

.song-main-left {
  text-align: left;
}

.song-side {
  display: grid;
  justify-items: end;
  gap: 0.35rem;
  min-width: 0;
}

.song-name,
.song-meta,
.song-album {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.song-name {
  color: #554252;
  font-weight: 900;
}

.song-meta,
.song-album {
  color: var(--muted);
  font-size: 0.88rem;
}

.song-album {
  max-width: 16rem;
}

.song-actions {
  justify-content: flex-end;
  flex-wrap: wrap;
}

.song-duration {
  color: var(--dim);
  font-variant-numeric: tabular-nums;
}

.compact .song-row:nth-child(n+9) {
  display: none;
}

.search-panel {
  padding: 1rem;
  border-radius: 1.6rem;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.74), rgba(184, 231, 255, 0.34));
}

.search-panel input {
  flex: 1;
  padding: 0.95rem 1rem;
}

.load-more-state {
  margin-top: 0.9rem;
  padding: 0.95rem 1rem;
  border-radius: 1.35rem;
  color: var(--muted);
  text-align: center;
  background: rgba(255, 255, 255, 0.62);
}

.player-layout {
  display: grid;
  grid-template-columns: minmax(21rem, 0.95fr) minmax(0, 1.05fr);
  gap: 1rem;
  align-items: stretch;
}

.player-main-column {
  display: grid;
  gap: 1rem;
}

.now-playing-card,
.player-controls-card,
.lyrics-card,
.settings-card {
  padding: 1.2rem;
  border-radius: 1.8rem;
  background: rgba(255, 255, 255, 0.72);
}

.now-playing-card {
  display: grid;
  grid-template-rows: auto auto 2.6rem 2.4rem auto;
  align-items: center;
  min-height: 30rem;
  text-align: center;
  background: linear-gradient(135deg, rgba(255, 198, 217, 0.5), rgba(255, 255, 255, 0.72));
}

.vinyl-wrap {
  display: grid;
  width: 18rem;
  max-width: 70vw;
  height: 18rem;
  margin: 0 auto 1.2rem;
  place-items: center;
  border-radius: 50%;
  border: 0.8rem solid rgba(255, 255, 255, 0.58);
  box-shadow: inset 0 0 0 2rem rgba(255, 255, 255, 0.22), 0 24px 54px rgba(178, 135, 152, 0.2);
}

.vinyl-wrap.playing {
  animation: spin 12s linear infinite;
}

.vinyl-fallback {
  width: 100%;
  height: 100%;
  border-radius: 50%;
}

.now-playing-card h3 {
  display: -webkit-box;
  overflow: hidden;
  margin: 0;
  color: #604457;
  font-size: 1.65rem;
  line-height: 1.3;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.now-playing-card p:not(.eyebrow) {
  display: -webkit-box;
  overflow: hidden;
  margin: 0.45rem 0 0;
  color: var(--muted);
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.pay-pill {
  display: inline-flex;
  margin-top: 1rem;
  padding: 0.45rem 0.82rem;
  border-radius: 999px;
  background: rgba(191, 244, 218, 0.68);
  color: #4e8a72;
  font-size: 0.85rem;
  font-weight: 900;
}

.soft-pill {
  margin-top: 0;
  background: rgba(255, 233, 157, 0.62);
  color: #8a6c3f;
}

.player-controls-card {
  align-self: start;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.74), rgba(217, 200, 255, 0.34));
}

.player-topline {
  justify-content: space-between;
  align-items: start;
  margin-bottom: 1rem;
}

.time-row {
  justify-content: space-between;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.progress-line {
  display: grid;
  grid-template-columns: 4.2rem minmax(12rem, 30rem) 4.2rem;
  align-items: center;
  justify-content: center;
  column-gap: 0.85rem;
  width: 100%;
  margin: 0.9rem auto 1.15rem;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.progress-line span {
  display: flex;
  align-items: center;
  height: 1.25rem;
  line-height: 1.25rem;
  white-space: nowrap;
}

.progress-line span:first-child {
  justify-content: flex-end;
}

.progress-line span:last-child {
  justify-content: flex-start;
}

input[type="range"] {
  width: 100%;
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  accent-color: #ee9bb4;
  --range-progress: 0%;
}

input[type="range"]::-webkit-slider-runnable-track {
  height: 0.48rem;
  border-radius: 999px;
  background: linear-gradient(to right, #ee9bb4 0, #ee9bb4 var(--range-progress), #ffffff var(--range-progress), #ffffff 100%);
  box-shadow: inset 0 0 0 1px rgba(116, 91, 104, 0.08);
}

input[type="range"]::-webkit-slider-thumb {
  width: 1rem;
  height: 1rem;
  margin-top: -0.26rem;
  border: 0;
  border-radius: 50%;
  background: #ee9bb4;
  box-shadow: 0 4px 12px rgba(238, 155, 180, 0.38);
  -webkit-appearance: none;
}

input[type="range"]::-moz-range-track {
  height: 0.48rem;
  border-radius: 999px;
  background: #ffffff;
  box-shadow: inset 0 0 0 1px rgba(116, 91, 104, 0.08);
}

input[type="range"]::-moz-range-progress {
  height: 0.48rem;
  border-radius: 999px;
  background: #ee9bb4;
}

input[type="range"]::-moz-range-thumb {
  width: 1rem;
  height: 1rem;
  border: 0;
  border-radius: 50%;
  background: #ee9bb4;
  box-shadow: 0 4px 12px rgba(238, 155, 180, 0.38);
}

#progressRange {
  align-self: center;
  width: 100%;
  height: 1.25rem;
  margin: 0;
  display: block;
}

.control-row {
  justify-content: center;
  flex-wrap: wrap;
}

.play-btn {
  min-width: 0;
  padding: 0;
}

.icon-control {
  display: inline-grid;
  width: 3.5rem;
  height: 3.5rem;
  place-items: center;
  padding: 0;
  font-size: 1.2rem;
}

.main-control {
  width: 4.25rem;
  height: 4.25rem;
  font-size: 1.45rem;
}

.icon-control svg {
  width: 1.35rem;
  height: 1.35rem;
  fill: currentColor;
  pointer-events: none;
}

.main-control svg {
  width: 1.6rem;
  height: 1.6rem;
}

.volume-row {
  width: fit-content;
  margin: 1.15rem 0 0 auto;
  color: var(--muted);
  justify-content: flex-end;
  gap: 0.7rem;
  align-self: flex-end;
}

.volume-row input {
  width: 9rem;
}

.lyrics-card {
  display: flex;
  flex-direction: column;
  height: 36rem;
  min-height: 36rem;
  max-height: 36rem;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.76), rgba(184, 231, 255, 0.24));
}

.lyrics {
  flex: 1;
  min-height: 0;
  max-height: none;
  overflow: hidden;
  overscroll-behavior: auto;
  padding: 0.5rem;
  scroll-behavior: smooth;
  -ms-overflow-style: none;
  scrollbar-width: none;
  touch-action: pan-y;
}

.lyrics::-webkit-scrollbar {
  display: none;
}

.queue-page-head,
.together-hero {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.together-hero {
  padding: 1.2rem;
  border: 1px solid var(--line);
  border-radius: 1.6rem;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.78), rgba(184, 231, 255, 0.28));
  box-shadow: var(--soft-shadow);
  backdrop-filter: blur(18px);
}

.queue-page-head h3,
.queue-page-head p,
.together-hero h3,
.together-hero p {
  margin: 0;
}

.queue-page-head p:not(.eyebrow),
.together-hero p:not(.eyebrow) {
  margin-top: 0.45rem;
  color: var(--muted);
}

.switch-row {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  min-width: max-content;
  color: var(--muted);
}

.switch-row input {
  width: 3rem;
  height: 1.55rem;
  accent-color: #ee9bb4;
}

.queue-current {
  border-color: rgba(255, 183, 167, 0.55);
  background: linear-gradient(135deg, rgba(255, 198, 217, 0.56), rgba(191, 244, 218, 0.5));
}

.lyric-line {
  margin: 0;
  padding: 0.58rem 0.78rem;
  border-radius: 1rem;
  color: var(--muted);
  line-height: 1.6;
  transition: 0.22s ease;
}

.lyric-line.active {
  background: linear-gradient(135deg, rgba(255, 198, 217, 0.68), rgba(191, 244, 218, 0.58));
  color: #604457;
  font-size: 1.08rem;
  font-weight: 900;
}

.empty-state {
  margin: 0;
  color: var(--muted);
}

.settings-card + .settings-card {
  margin-top: 1rem;
}

.settings-card p:not(.eyebrow) {
  margin-top: 0.65rem;
  color: var(--muted);
  line-height: 1.8;
}

.settings-form {
  align-items: end;
  margin-top: 1.1rem;
  flex-wrap: wrap;
}

.settings-form label {
  display: grid;
  flex: 1;
  min-width: min(22rem, 100%);
  gap: 0.45rem;
  color: var(--muted);
}

.settings-form input {
  padding: 0.95rem 1rem;
}

.note-list {
  margin: 1rem 0 0;
  padding-left: 1.2rem;
  color: var(--muted);
  line-height: 1.9;
}

.muted-card {
  background: linear-gradient(135deg, rgba(191, 244, 218, 0.34), rgba(255, 255, 255, 0.68));
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes blobFloat {
  to {
    transform: translate3d(4rem, 2rem, 0) scale(1.06) rotate(14deg);
    border-radius: 58% 42% 39% 61% / 38% 53% 47% 62%;
  }
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 1020px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
  }

  .nav {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .nav-item {
    text-align: center;
  }

  .side-card {
    margin-top: 0;
  }

  .hero,
  .player-layout {
    grid-template-columns: 1fr;
  }

  .chart-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .lyrics {
    min-height: 22rem;
  }
}

@media (max-width: 700px) {
  .app-shell,
  .main-panel,
  .sidebar {
    padding: 0.7rem;
  }

  .topbar,
  .quick-search,
  .search-panel,
  .playlist-hero,
  .settings-form,
  .settings-actions,
  .player-topline,
  .queue-page-head {
    align-items: stretch;
    flex-direction: column;
  }

  .quick-search {
    min-width: 0;
    border-radius: 1.2rem;
  }

  .nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero {
    min-height: auto;
  }

  .hero h3 {
    font-size: 2.35rem;
  }

  .chart-grid {
    grid-template-columns: 1fr;
  }

  .song-row {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: start;
  }

  .song-cover {
    grid-row: span 2;
  }

  .song-side {
    grid-column: 2;
    justify-items: start;
  }

  .song-actions {
    justify-content: flex-start;
  }

  .song-album {
    max-width: 100%;
  }

  .cover {
    width: 6rem;
  }
}

@media (max-width: 1180px) {
  body {
    padding: 1rem;
  }

  .app-shell {
    grid-template-columns: 6rem minmax(0, 1fr);
    gap: 1rem;
  }

  .sidebar {
    padding: 1rem 0.75rem;
  }

  .brand-copy {
    display: none;
  }

  .brand {
    justify-content: center;
  }

  .brand-mark {
    width: 3.25rem;
    height: 3.25rem;
  }

  .nav-item {
    justify-content: center;
    padding: 0.85rem;
    font-size: 0;
  }

  .nav-item .iconfont {
    font-size: 1.35rem;
  }

  .quick-search {
    min-width: 0;
    flex: 1;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr) 16rem;
    min-height: 18rem;
  }

  .chart-grid,
  .playlist-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .player-layout {
    grid-template-columns: minmax(18rem, 0.9fr) minmax(0, 1.1fr);
  }

  .vinyl-wrap {
    width: 14.5rem;
    height: 14.5rem;
  }

  .now-playing-card {
    min-height: 25rem;
  }

  .lyrics-card {
    height: 30rem;
    min-height: 30rem;
    max-height: 30rem;
  }
}

@media (max-width: 900px) {
  body {
    padding: 0;
    background-attachment: fixed;
  }

  .app-shell {
    display: flex;
    flex-direction: column;
    min-height: 100dvh;
    border-radius: 0;
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 20;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.75rem;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    border-radius: 0 0 1.4rem 1.4rem;
    backdrop-filter: blur(20px);
  }

  .brand {
    margin: 0;
  }

  .brand-copy {
    display: block;
  }

  .brand-copy h1 {
    font-size: 1rem;
  }

  .brand-copy p {
    display: none;
  }

  .side-nav {
    display: flex;
    gap: 0.45rem;
    overflow-x: auto;
    padding: 0.25rem 0.1rem;
    scrollbar-width: none;
  }

  .side-nav::-webkit-scrollbar {
    display: none;
  }

  .nav-item {
    flex: 0 0 auto;
    justify-content: center;
    min-width: 4.6rem;
    padding: 0.68rem 0.75rem;
    font-size: 0.78rem;
    white-space: nowrap;
  }

  .nav-item .iconfont {
    font-size: 1rem;
  }

  .main-panel {
    padding: 1rem;
  }

  .topbar {
    position: sticky;
    top: 5.3rem;
    z-index: 15;
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
    margin: -1rem -1rem 1rem;
    padding: 0.9rem 1rem;
    border-bottom: 1px solid var(--line);
    background: rgba(255, 249, 245, 0.86);
    backdrop-filter: blur(18px);
  }

  .quick-search {
    width: 100%;
    min-width: 0;
  }

  .quick-search button {
    padding-inline: 1rem;
  }

  .topbar-actions {
    justify-content: space-between;
  }

  .hero,
  .playlist-hero {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .hero-disc {
    display: none;
  }

  .section-head,
  .queue-page-head,
  .together-hero {
    align-items: flex-start;
    flex-direction: column;
  }

  .switch-row {
    width: 100%;
    justify-content: space-between;
  }

  .player-layout {
    grid-template-columns: 1fr;
  }

  .player-main-column {
    order: 2;
  }

  .now-playing-card {
    order: 1;
    min-height: 0;
  }

  .vinyl-wrap {
    width: min(15rem, 58vw);
    height: min(15rem, 58vw);
  }

  .lyrics-card {
    height: 24rem;
    min-height: 24rem;
    max-height: 24rem;
  }

  .song-row {
    grid-template-columns: 2.2rem minmax(0, 1fr);
    align-items: flex-start;
  }

  .song-cover {
    display: none;
  }

  .song-side {
    grid-column: 2;
    width: 100%;
    align-items: flex-start;
    margin-top: 0.45rem;
  }

  .song-actions {
    width: 100%;
    flex-wrap: wrap;
  }
}

@media (max-width: 640px) {
  html {
    font-size: 15px;
  }

  .sidebar {
    grid-template-columns: 1fr;
    gap: 0.55rem;
  }

  .brand {
    justify-content: flex-start;
  }

  .brand-mark {
    width: 2.75rem;
    height: 2.75rem;
  }

  .side-nav {
    margin-inline: -0.2rem;
  }

  .nav-item {
    min-width: auto;
    flex: 1 0 auto;
    padding: 0.62rem 0.68rem;
  }

  .main-panel {
    padding: 0.85rem;
  }

  .topbar {
    top: 7.15rem;
    margin: -0.85rem -0.85rem 0.85rem;
    padding: 0.75rem 0.85rem;
  }

  .quick-search {
    border-radius: 1.15rem;
  }

  .quick-search input {
    padding: 0.7rem 0.8rem;
  }

  .quick-search button {
    padding: 0.7rem 0.9rem;
  }

  .topbar-actions {
    gap: 0.55rem;
  }

  .hero,
  .playlist-hero,
  .search-panel,
  .settings-form,
  .settings-card,
  .now-playing-card,
  .player-controls-card,
  .lyrics-card,
  .together-hero {
    padding: 1rem;
    border-radius: 1.25rem;
  }

  .hero h3 {
    font-size: clamp(1.85rem, 12vw, 3rem);
  }

  .chart-grid,
  .playlist-grid {
    grid-template-columns: 1fr;
  }

  .section-head h3 {
    font-size: 1.15rem;
  }

  .song-row {
    gap: 0.65rem;
    padding: 0.78rem;
    border-radius: 1rem;
  }

  .song-index {
    width: 2rem;
    font-size: 0.82rem;
  }

  .song-name {
    font-size: 0.96rem;
  }

  .song-meta,
  .song-album,
  .song-duration {
    font-size: 0.78rem;
  }

  .queue-next-btn {
    flex: 1 1 auto;
    min-height: 2.4rem;
    padding: 0.62rem 0.78rem;
  }

  .player-topline {
    flex-direction: column;
    align-items: flex-start;
  }

  .progress-line {
    grid-template-columns: 3.2rem minmax(0, 1fr) 3.2rem;
    column-gap: 0.55rem;
  }

  .control-row {
    gap: 0.55rem;
  }

  .icon-control {
    width: 3.1rem;
    height: 3.1rem;
  }

  .main-control {
    width: 3.85rem;
    height: 3.85rem;
  }

  .volume-row {
    width: 100%;
    margin-left: 0;
    justify-content: space-between;
  }

  .volume-row input {
    flex: 1;
    width: auto;
  }

  .lyrics-card {
    height: 20rem;
    min-height: 20rem;
    max-height: 20rem;
  }

  .settings-form {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 430px) {
  .nav-item {
    font-size: 0.72rem;
    gap: 0.28rem;
    padding: 0.55rem 0.58rem;
  }

  .topbar {
    top: 6.9rem;
  }

  .quick-search {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .quick-search button {
    min-width: 4.2rem;
  }

  .topbar-actions .ghost-btn,
  .topbar-actions .secondary-btn {
    flex: 1;
    padding-inline: 0.75rem;
  }

  .hero p:not(.eyebrow),
  .playlist-hero p:not(.eyebrow),
  .together-hero p:not(.eyebrow) {
    line-height: 1.65;
  }

  .now-playing-card h3 {
    font-size: 1.28rem;
  }

  .vinyl-wrap {
    width: min(12.5rem, 66vw);
    height: min(12.5rem, 66vw);
    border-width: 0.55rem;
  }

  .song-row {
    grid-template-columns: 1.7rem minmax(0, 1fr);
  }

  .song-side {
    grid-column: 1 / -1;
  }

  .song-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .song-duration {
    grid-column: 1 / -1;
  }

  .queue-list .song-actions {
    grid-template-columns: 1fr;
  }

  .progress-line {
    grid-template-columns: 2.8rem minmax(0, 1fr) 2.8rem;
    font-size: 0.78rem;
  }

  .lyrics-card {
    height: 18rem;
    min-height: 18rem;
    max-height: 18rem;
  }
}

.sidebar-toggle,
.sidebar-backdrop {
  display: none;
}

@media (max-width: 900px) {
  :root {
    --drawer-width: min(21rem, 84vw);
  }

  body.sidebar-open {
    overflow: hidden;
  }

  .sidebar-toggle {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    z-index: 110;
    display: inline-grid;
    width: 3.1rem;
    height: 3.1rem;
    place-items: center;
    gap: 0.24rem;
    padding: 0.72rem;
    border: 1px solid rgba(116, 91, 104, 0.12);
    border-radius: 1.05rem;
    background: rgba(255, 255, 255, 0.82);
    box-shadow: var(--soft-shadow);
    backdrop-filter: blur(18px);
  }

  .sidebar-toggle span {
    display: block;
    width: 1.25rem;
    height: 0.14rem;
    border-radius: 999px;
    background: #7b5469;
    transition: transform 0.24s ease, opacity 0.24s ease;
  }

  body.sidebar-open .sidebar-toggle span:nth-child(1) {
    transform: translateY(0.38rem) rotate(45deg);
  }

  body.sidebar-open .sidebar-toggle span:nth-child(2) {
    opacity: 0;
  }

  body.sidebar-open .sidebar-toggle span:nth-child(3) {
    transform: translateY(-0.38rem) rotate(-45deg);
  }

  .sidebar-backdrop {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: var(--drawer-width);
    z-index: 60;
    display: block;
    background: rgba(69, 47, 59, 0.28);
    opacity: 0;
    pointer-events: none;
    backdrop-filter: blur(6px);
    transition: opacity 0.24s ease;
  }

  body.sidebar-open .sidebar-backdrop {
    opacity: 1;
    pointer-events: auto;
  }

  .app-shell {
    display: block;
    min-height: 100dvh;
    border-radius: 0;
  }

  .sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 100;
    display: flex;
    width: var(--drawer-width);
    padding: 5rem 1rem 1rem;
    border-right: 1px solid var(--line);
    border-bottom: 0;
    border-radius: 0 1.8rem 1.8rem 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(255, 249, 245, 0.9));
    box-shadow: 24px 0 64px rgba(116, 91, 104, 0.2);
    transform: translateX(-108%);
    transition: transform 0.28s cubic-bezier(.2,.8,.2,1);
    overflow-y: auto;
    backdrop-filter: blur(24px);
  }

  body.sidebar-open .sidebar {
    transform: translateX(0);
  }

  .sidebar .brand {
    justify-content: flex-start;
    margin-bottom: 1rem;
  }

  .sidebar .brand-copy,
  .sidebar .brand > div:not(.brand-mark) {
    display: block;
  }

  .sidebar .brand p {
    display: block;
  }

  .sidebar .nav,
  .sidebar .side-nav {
    display: grid;
    gap: 0.5rem;
    overflow: visible;
    padding: 0;
  }

  .sidebar .nav-item {
    justify-content: flex-start;
    width: 100%;
    min-width: 0;
    padding: 0.9rem 1rem;
    font-size: 0.95rem;
    white-space: normal;
  }

  .sidebar .nav-item .iconfont {
    font-size: 1.05rem;
  }

  .side-card {
    display: grid;
  }

  .main-panel {
    min-height: 100dvh;
    padding: 1rem;
    padding-top: 1rem;
  }

  .topbar {
    position: static;
    margin: 0 0 1rem;
    padding: 0;
    border-bottom: 0;
    background: transparent;
    backdrop-filter: none;
  }
}

@media (max-width: 640px) {
  .sidebar-toggle {
    right: 0.75rem;
    bottom: 0.75rem;
    width: 2.85rem;
    height: 2.85rem;
    border-radius: 0.95rem;
  }

  .sidebar-backdrop {
    left: min(19rem, 86vw);
  }

  .sidebar {
    width: min(19rem, 86vw);
    padding: 4.6rem 0.85rem 0.85rem;
    border-radius: 0 1.45rem 1.45rem 0;
  }

  .main-panel {
    padding: 0.85rem;
    padding-top: 1rem;
  }

  .topbar {
    top: auto;
    margin: 0 0 0.85rem;
    padding: 0;
  }
}

@media (max-width: 900px) {
  .sidebar nav.nav {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.55rem;
    width: 100%;
    overflow: visible;
  }

  .sidebar nav.nav .nav-item {
    display: flex;
    flex: 0 0 auto;
    width: 100%;
    justify-content: flex-start;
    text-align: left;
  }
}

@media (max-width: 900px) {
  .lyrics-card {
    height: 22rem;
    min-height: 22rem;
    max-height: 22rem;
    overflow: hidden;
  }

  .lyrics {
    height: 100%;
    max-height: 100%;
    overflow: hidden;
    touch-action: pan-y;
  }

  .sidebar .side-card {
    align-items: start;
    justify-items: start;
    text-align: left;
  }
}

@media (max-width: 640px) {
  .lyrics-card {
    height: 18rem;
    min-height: 18rem;
    max-height: 18rem;
    overflow: hidden;
  }
}
