:root {
  color-scheme: dark;
  --bg: #000000;
  --panel: #121212;
  --panel-raised: #1c1c1e;
  --panel-soft: #242426;
  --text: #ffffff;
  --muted: #a1a1a6;
  --line: #2c2c2e;
  --accent: #0071e3;
  --accent-hover: #0077ed;
  --danger: #ff453a;
  --sidebar: 208px;
  --queue: 308px;
  --player: 92px;
  font-family: "SF Pro Text", "Helvetica Neue", Helvetica, Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-width: 320px;
  min-height: 100%;
  margin: 0;
  background: var(--bg);
  color: var(--text);
}

body {
  min-height: 100vh;
  overflow-x: hidden;
}

button,
input {
  font: inherit;
}

button {
  color: inherit;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  display: block;
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  pointer-events: none;
}

button:focus-visible,
input:focus-visible,
a:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.app-shell {
  display: grid;
  grid-template-columns: var(--sidebar) minmax(0, 1fr) var(--queue);
  min-height: calc(100vh - var(--player));
  padding-bottom: var(--player);
}

.sidebar {
  position: fixed;
  inset: 0 auto var(--player) 0;
  z-index: 20;
  width: var(--sidebar);
  display: flex;
  flex-direction: column;
  padding: 28px 16px 20px;
  border-right: 1px solid var(--line);
  background: #090909;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 10px 28px;
  color: var(--text);
  font-family: "SF Pro Display", "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 7px;
  overflow: hidden;
  flex-shrink: 0;
  background: transparent;
  font-size: 17px;
}

.brand-mark img {
  display: block;
  width: 30px;
  height: 30px;
  object-fit: cover;
  border-radius: 7px;
}

.nav-list {
  display: grid;
  gap: 4px;
}

.nav-item {
  display: grid;
  grid-template-columns: 24px 1fr;
  align-items: center;
  min-height: 44px;
  padding: 0 12px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  text-align: left;
  cursor: pointer;
}

.nav-item:hover,
.nav-item.is-active {
  background: var(--panel-raised);
  color: var(--text);
}

.nav-item.is-active span:first-child {
  color: var(--accent);
}

.nav-item.is-active .icon {
  color: var(--accent);
}

.sidebar-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  padding: 12px;
  color: var(--muted);
  font-size: 12px;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #ff9f0a;
}

.status-dot.is-ok {
  background: #30d158;
}

.status-dot.is-error {
  background: var(--danger);
}

.content {
  grid-column: 2;
  min-width: 0;
  background: #0b0b0b;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 12;
  display: flex;
  align-items: center;
  gap: 14px;
  height: 76px;
  padding: 14px 32px;
  border-bottom: 1px solid rgba(44, 44, 46, 0.8);
  background: rgba(11, 11, 11, 0.94);
  backdrop-filter: blur(18px);
}

.mobile-brand {
  display: none;
  font-weight: 700;
  white-space: nowrap;
}

.search {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) 36px;
  align-items: center;
  width: min(620px, 100%);
  min-height: 44px;
  padding-left: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-raised);
  color: var(--muted);
}

.search:focus-within {
  border-color: var(--accent);
}

.search input {
  min-width: 0;
  height: 42px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-size: 15px;
}

.search input::placeholder {
  color: #77777b;
}

.search button {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.search button:hover {
  background: var(--panel-soft);
  color: var(--text);
}

.queue-toggle {
  display: none;
  margin-left: auto;
}

.queue-count {
  position: absolute;
  top: -3px;
  right: -5px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 9px;
  background: var(--accent);
  color: #ffffff;
  font-size: 10px;
  line-height: 17px;
}

.library {
  width: min(1220px, 100%);
  margin: 0 auto;
  padding: 34px 32px 64px;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.eyebrow {
  margin: 0 0 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0;
  font-family: "SF Pro Display", "Helvetica Neue", Helvetica, Arial, sans-serif;
  letter-spacing: 0;
}

h1 {
  font-size: 32px;
  line-height: 1.15;
}

h2 {
  font-size: 22px;
}

.text-button {
  min-height: 36px;
  padding: 0 8px;
  border: 0;
  background: transparent;
  color: var(--accent);
  cursor: pointer;
}

.text-button:hover {
  color: #2997ff;
}

.track-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(166px, 1fr));
  gap: 24px 18px;
}

.track-card {
  min-width: 0;
}

.cover-wrap {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 8px;
  background: var(--panel-raised);
}

.cover-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cover-fallback {
  display: grid;
  width: 100%;
  height: 100%;
  place-items: center;
  color: var(--muted);
}

.cover-fallback .icon {
  width: 36px;
  height: 36px;
}

.cover-actions {
  position: absolute;
  inset: auto 8px 8px auto;
  display: flex;
  gap: 7px;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 160ms ease, transform 160ms ease;
}

.track-card:hover .cover-actions,
.track-card:focus-within .cover-actions {
  opacity: 1;
  transform: translateY(0);
}

.cover-action {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.78);
  color: #ffffff;
  cursor: pointer;
}

.cover-action.primary {
  background: var(--accent);
}

.track-duration {
  position: absolute;
  top: 8px;
  right: 8px;
  min-width: 42px;
  padding: 3px 6px;
  border-radius: 5px;
  background: rgba(0, 0, 0, 0.76);
  color: #ffffff;
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  line-height: 14px;
  text-align: center;
}

.track-copy {
  padding-top: 10px;
}

.track-title,
.track-artist {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.track-title {
  color: var(--text);
  font-size: 14px;
  line-height: 20px;
}

.track-artist {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
  line-height: 18px;
}

.track-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.meta-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: 100%;
  min-height: 24px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel-raised);
  color: var(--muted);
  font-size: 11px;
  line-height: 1;
  cursor: pointer;
}

.meta-badge:hover,
.meta-badge:focus-visible {
  color: var(--text);
  border-color: #3a3a3c;
}

.meta-icon {
  width: 12px;
  height: 12px;
  flex: 0 0 auto;
}

.meta-badge span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.loading-state,
.empty-state {
  display: flex;
  min-height: 280px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 10px;
  color: var(--muted);
}

.empty-state[hidden],
.loading-state[hidden] {
  display: none;
}

.empty-state strong {
  color: var(--text);
}

.spinner {
  width: 22px;
  height: 22px;
  border: 2px solid var(--line);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 800ms linear infinite;
}

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

.queue-panel {
  position: fixed;
  inset: 0 0 var(--player) auto;
  z-index: 25;
  display: flex;
  flex-direction: column;
  width: var(--queue);
  padding: 28px 18px;
  border-left: 1px solid var(--line);
  background: var(--panel);
  overflow: hidden;
}

.queue-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.queue-head > div:first-child {
  min-width: 0;
}

#active-queue-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.queue-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 4px 8px;
  max-width: min(100%, 220px);
}

.queue-actions .text-button {
  white-space: nowrap;
}

.icon-button.queue-close {
  display: none;
}

.queue-library {
  flex: 0 0 auto;
  margin-top: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.queue-library-head,
.queue-track-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 11px;
}

.queue-library-head h3 {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
}

.queue-library-list {
  display: grid;
  gap: 3px;
  max-height: min(210px, 28vh);
  margin: 8px 0 0;
  padding: 0;
  overflow-y: auto;
  list-style: none;
}

.queue-library-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 30px;
  align-items: center;
  min-height: 44px;
  border-radius: 6px;
}

.queue-library-item:first-child {
  grid-template-columns: minmax(0, 1fr);
}

.queue-library-item:hover,
.queue-library-item.is-active {
  background: var(--panel-raised);
}

.queue-library-item.is-active {
  box-shadow: inset 2px 0 0 var(--accent);
}

.queue-library-select {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  min-width: 0;
  min-height: 44px;
  padding: 5px 8px;
  border: 0;
  background: transparent;
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.queue-library-select .icon {
  width: 17px;
  height: 17px;
  color: var(--muted);
}

.queue-library-item.is-active .queue-library-select .icon {
  color: var(--accent);
}

.queue-library-copy,
.queue-library-copy strong,
.queue-library-copy span {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.queue-library-copy strong {
  font-size: 12px;
  font-weight: 600;
}

.queue-library-copy span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
}

.queue-library-remove {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.queue-library-remove .icon {
  width: 15px;
  height: 15px;
}

.queue-library-remove:hover {
  background: var(--panel-soft);
  color: var(--text);
}

.queue-library-select:focus-visible,
.queue-library-remove:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.queue-track-head {
  flex: 0 0 auto;
  margin-top: 14px;
}

.queue-list {
  display: grid;
  flex: 1 1 auto;
  align-content: start;
  gap: 4px;
  grid-auto-rows: min-content;
  min-height: 0;
  max-height: none;
  margin: 8px 0 0;
  padding: 0;
  overflow-y: auto;
  list-style: none;
}

.queue-item {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 32px;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 6px;
  border-radius: 7px;
}

.queue-item:hover,
.queue-item.is-current {
  background: var(--panel-raised);
}

.queue-cover {
  width: 42px;
  height: 42px;
  border-radius: 5px;
  background: var(--panel-soft);
  object-fit: cover;
}

.queue-copy {
  min-width: 0;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.queue-copy strong,
.queue-copy span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.queue-copy strong {
  font-size: 13px;
}

.queue-copy span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.remove-button {
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}

.remove-button:hover {
  background: var(--panel-soft);
  color: var(--text);
}

.queue-empty {
  padding: 50px 0;
  color: var(--muted);
  text-align: center;
  font-size: 13px;
}

.scrim {
  display: none;
}

.browse-panel {
  position: fixed;
  inset: 0 0 var(--player) auto;
  z-index: 28;
  display: flex;
  width: min(380px, 100vw);
  max-width: 100%;
  flex-direction: column;
  padding: 24px 16px 18px;
  border-left: 1px solid var(--line);
  background: var(--panel);
  transform: translateX(100%);
  transition: transform 180ms ease;
  pointer-events: none;
}

.browse-panel.is-open {
  transform: translateX(0);
  pointer-events: auto;
}

.browse-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
}

.browse-heading {
  min-width: 0;
}

.browse-heading h2 {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 18px;
}

.browse-bulk {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
}

.browse-bulk[hidden] {
  display: none;
}

.browse-bulk-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel-raised);
}

.browse-bulk-button .icon {
  width: 15px;
  height: 15px;
}

.browse-bulk-button:hover {
  border-color: rgba(255, 255, 255, 0.18);
}

.browse-bulk-button:focus-visible,
.queue-actions .text-button:focus-visible,
.browse-more:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.browse-bulk-button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.browse-bulk-status {
  margin-top: 10px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.browse-bulk-status[hidden] {
  display: none;
}

.browse-list {
  display: grid;
  gap: 4px;
  flex: 1 1 auto;
  max-height: calc(100vh - var(--player) - 210px);
  margin: 14px 0 0;
  padding: 0;
  overflow-x: hidden;
  overflow-y: auto;
  list-style: none;
}

.browse-item {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  min-height: 56px;
  padding: 6px;
  border-radius: 7px;
}

.browse-item:hover {
  background: var(--panel-raised);
}

.browse-cover {
  width: 42px;
  height: 42px;
  border-radius: 5px;
  background: var(--panel-soft);
  object-fit: cover;
}

.browse-copy {
  min-width: 0;
}

.browse-copy strong,
.browse-copy span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.browse-copy strong {
  font-size: 13px;
}

.browse-copy span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.browse-actions {
  display: flex;
  align-items: center;
  gap: 2px;
  flex: 0 0 auto;
}

.browse-loading,
.browse-empty {
  display: flex;
  min-height: 120px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
}

.browse-loading[hidden],
.browse-empty[hidden],
.browse-more[hidden] {
  display: none;
}

.browse-more {
  align-self: center;
  margin-top: 12px;
}

.browse-scrim {
  z-index: 27;
}

.browse-scrim.is-open {
  display: block;
  position: fixed;
  inset: 0 0 var(--player);
  border: 0;
  background: rgba(0, 0, 0, 0.58);
}

.player {
  position: fixed;
  inset: auto 0 0;
  z-index: 40;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(360px, 1.4fr) minmax(160px, 1fr);
  align-items: center;
  height: var(--player);
  padding: 10px 22px;
  border-top: 1px solid var(--line);
  background: #111111;
}

.now-playing {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) 40px;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.now-cover {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  overflow: hidden;
  border-radius: 6px;
  background: var(--panel-soft);
  color: var(--muted);
  background-position: center;
  background-size: cover;
}

.now-cover.has-image span {
  display: none;
}

.now-cover.has-image .icon {
  display: none;
}

.now-copy {
  min-width: 0;
}

.now-copy strong,
.now-copy span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.now-copy .playback-status {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  line-height: 14px;
}

.now-copy .playback-status[hidden] {
  display: none;
}

.player.has-playback-status #now-artist {
  display: none;
}

.player[data-playback-state="error"] .playback-status {
  color: var(--danger);
}

.now-copy strong {
  font-size: 14px;
}

.now-copy span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.icon-button,
.play-button {
  position: relative;
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
}

.icon-button:hover {
  background: var(--panel-soft);
}

.icon-button.subtle {
  color: var(--muted);
}

.icon-button.is-active {
  color: var(--accent);
}

.play-button {
  width: 42px;
  height: 42px;
  background: #ffffff;
  color: #000000;
}

.play-button .icon {
  width: 19px;
  height: 19px;
}

.play-button.is-loading .icon {
  visibility: hidden;
}

.play-button.is-loading::after {
  position: absolute;
  width: 17px;
  height: 17px;
  border: 2px solid rgba(0, 0, 0, 0.22);
  border-top-color: #000000;
  border-radius: 50%;
  content: "";
  animation: spin 800ms linear infinite;
}

.favorite-button.is-active .icon {
  fill: currentColor;
}

.repeat-one {
  position: absolute;
  top: 7px;
  right: 5px;
  display: none;
  width: 10px;
  height: 10px;
  border-radius: 5px;
  background: #111111;
  color: currentColor;
  font-size: 8px;
  font-weight: 700;
  line-height: 10px;
  text-align: center;
}

.repeat-button.is-one .repeat-one {
  display: block;
}

.play-button:hover {
  background: #e5e5ea;
}

.transport {
  display: grid;
  gap: 8px;
}

.transport-buttons,
.timeline,
.volume {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
}

.timeline {
  gap: 10px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  font-size: 10px;
}

.timeline input {
  width: min(420px, 70%);
}

input[type="range"] {
  height: 4px;
  margin: 0;
  border-radius: 2px;
  accent-color: var(--accent);
  cursor: pointer;
}

input[type="range"]:disabled {
  cursor: default;
  opacity: 0.45;
}

.volume {
  justify-content: flex-end;
}

.volume input {
  width: 100px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(var(--player) + 18px);
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: min(440px, calc(100vw - 32px));
  padding: 10px 14px;
  border-radius: 7px;
  background: #f5f5f7;
  color: #1d1d1f;
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.28);
  font-size: 13px;
  line-height: 1.35;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 8px);
  transition: opacity 160ms ease, transform 160ms ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.toast.is-actionable {
  pointer-events: auto;
}

.toast-message {
  min-width: 0;
  flex: 1 1 auto;
}

.toast-action {
  flex: 0 0 auto;
  margin: 0;
  padding: 4px 10px;
  border: 0;
  border-radius: 999px;
  background: #0071e3;
  color: #ffffff;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  white-space: nowrap;
}

.toast-action:hover {
  background: #0077ed;
}

.toast-action:focus-visible {
  outline: 2px solid #0071e3;
  outline-offset: 2px;
  box-shadow: 0 0 0 3px rgba(0, 113, 227, 0.28);
}

.toast-action[hidden] {
  display: none;
}

@media (max-width: 1100px) {
  :root { --queue: 320px; }

  .app-shell {
    grid-template-columns: var(--sidebar) minmax(0, 1fr);
  }

  .queue-toggle {
    display: grid;
  }

  .queue-panel {
    transform: translateX(100%);
    transition: transform 180ms ease;
  }

  .queue-panel.is-open {
    transform: translateX(0);
  }

  .icon-button.queue-close {
    display: grid;
  }

  .scrim {
    position: fixed;
    inset: 0 0 var(--player);
    z-index: 23;
    border: 0;
    background: rgba(0, 0, 0, 0.58);
  }

  .scrim.is-open {
    display: block;
  }

  .browse-scrim.is-open {
    display: block;
  }
}

@media (max-width: 760px) {
  :root {
    --sidebar: 0px;
    --player: 132px;
  }

  .app-shell {
    display: block;
    padding-bottom: var(--player);
  }

  .sidebar {
    display: none;
  }

  .content {
    width: 100%;
  }

  .topbar {
    height: auto;
    min-height: 70px;
    flex-wrap: wrap;
    padding: 12px 16px;
  }

  .mobile-brand {
    display: block;
  }

  .search {
    order: 3;
    width: 100%;
  }

  .library {
    padding: 26px 16px 54px;
  }

  h1 {
    font-size: 27px;
  }

  .track-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px 12px;
  }

  .cover-actions {
    opacity: 1;
    transform: none;
  }

  .queue-panel {
    inset: 0 0 var(--player) auto;
    width: min(88vw, 340px);
  }

  .browse-panel {
    width: min(92vw, 360px);
    padding: 18px 12px 14px;
  }

  .browse-bulk {
    gap: 6px;
  }

  .browse-bulk-button {
    min-height: 32px;
    padding: 5px 10px;
    font-size: 12px;
  }

  .queue-actions {
    max-width: min(100%, 200px);
  }

  .browse-item {
    grid-template-columns: 40px minmax(0, 1fr) auto;
    gap: 8px;
  }

  .browse-actions .icon-button {
    width: 34px;
    height: 34px;
  }

  .player {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: 62px 58px;
    height: var(--player);
    padding: 6px 12px;
  }

  .now-playing {
    grid-column: 1;
    grid-row: 1;
    grid-template-columns: 48px minmax(0, 1fr) 36px;
    gap: 9px;
  }

  .now-cover {
    width: 48px;
    height: 48px;
  }

  .transport {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .transport-buttons {
    position: absolute;
    top: 13px;
    right: 10px;
  }

  .transport-buttons .subtle,
  .transport-buttons #previous-button {
    display: none;
  }

  .timeline input {
    width: 100%;
  }

  .volume {
    display: none;
  }

  .favorite-button {
    display: none;
  }

  .now-copy {
    padding-right: 92px;
  }

  .toast {
    bottom: calc(var(--player) + 12px);
  }
}

@media (max-width: 380px) {
  .track-grid {
    grid-template-columns: 1fr;
  }

  .track-card {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 12px;
  }

  .track-copy {
    align-self: center;
    padding-top: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
