:root {
  color-scheme: dark;
  --bg: #181917;
  --side: #121311;
  --panel: #262723;
  --ink: #f3f1ec;
  --muted: #afb0a8;
  --line: #363733;
  --accent: #ff895b;
  --rail: 240px;
  font:
    15px/1.45 "Inter",
    "Segoe UI",
    Arial,
    sans-serif;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
}
[data-theme="light"] {
  color-scheme: light;
  --bg: #f7f5f1;
  --side: #eeeae4;
  --panel: #fff;
  --ink: #211f20;
  --muted: #635e61;
  --line: #dcd6d3;
}
button,
a,
input,
textarea,
select {
  font: inherit;
}
button,
a {
  color: inherit;
}
a {
  text-decoration: none;
}
button {
  border: 0;
  background: none;
  cursor: pointer;
}
button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
button:enabled:hover,
a:hover {
  filter: brightness(1.12);
}
strong,
small {
  display: block;
}
small,
.muted {
  color: var(--muted);
}
small {
  font-size: 12px;
}
h1,
h2,
p {
  margin: 0;
}
h1 {
  font-size: clamp(33px, 3vw, 48px);
  line-height: 1.05;
  letter-spacing: -0.045em;
  font-weight: 650;
}
h2 {
  font-size: clamp(21px, 2vw, 28px);
  letter-spacing: -0.045em;
  line-height: 1.15;
  font-weight: 620;
}
section {
  margin: 32px 0;
}
.sidebar {
  position: fixed;
  z-index: 4;
  top: 0;
  bottom: 89px;
  width: var(--rail);
  background: var(--side);
  border-right: 1px solid var(--line);
  padding: 28px 16px;
  overflow: auto;
  display: flex;
  flex-direction: column;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 21px;
  letter-spacing: -1.1px;
  font-weight: 720;
  line-height: 1;
  margin: 0 8px 32px;
}
.brand em {
  display: block;
  font-style: normal;
  font-size: 11px;
  line-height: 1.6;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}
.brandmark {
  width: 39px;
  height: 39px;
  display: grid;
  place-items: center;
  background: var(--accent);
  border-radius: 12px;
  color: #251710;
}
.brandimage {
  object-fit: contain;
  background: #140d14;
}
.navcap {
  font-size: 12px;
  font-weight: 550;
  color: var(--muted);
  padding: 0 12px;
  margin: 28px 0 8px;
}
.brand + .navcap {
  margin-top: 0;
}
.navlink {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 36px;
  padding: 8px 12px;
  border-radius: 7px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 520;
}
.navlink:hover,
.ib:hover,
.plain:hover {
  background: var(--panel);
}
.navlink.selected {
  color: var(--ink);
}
.navmarker {
  position: absolute;
  top: 0;
  pointer-events: none;
  border-radius: 7px;
  background: var(--panel);
  box-shadow: inset 3px 0 var(--accent);
}
.sidebar .navlink { position: relative; }
.sidebar .navlink.selected { background: transparent; }
@media (prefers-reduced-motion: no-preference) {
  .navmarker { transition: transform 330ms cubic-bezier(.22,.75,.2,1); }
}
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .navlink > span, .navlink > svg { transition: transform 180ms cubic-bezier(.22,.75,.2,1); }
  .navlink:hover > span { transform: translateX(4px); }
  .navlink:hover > svg { transform: translateX(2px) scale(1.08); }
}
[data-theme="light"] .ib.active {
  color: #943c22;
}
.sidebottom {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
main {
  margin-left: var(--rail);
  min-height: 100vh;
  padding: 0 clamp(24px, 3.5vw, 62px) 140px;
}
header,
.content {
  max-width: 1440px;
  margin: auto;
}
header {
  height: 72px;
  display: flex;
  align-items: center;
  gap: 14px;
  border-bottom: 1px solid var(--line);
}
.searchbox {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--muted);
  width: min(430px, 70%);
  padding: 8px 13px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--panel);
  height: 38px;
}
.searchbox input {
  flex: 1;
  min-width: 0;
  background: none;
  border: none;
  color: var(--ink);
  outline: none;
}
.searchbox input::placeholder {
  color: var(--muted);
  font-size: 13px;
}
kbd {
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 0 6px;
  font-size: 11px;
}
.profile {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 30px;
  padding: 8px 13px;
}
.profile img {
  width: 20px;
  height: 20px;
  border-radius: 50%;
}
.pagehead,
.sectionhead,
.actions,
.heroactions,
.setting,
.tracksummary {
  display: flex;
  align-items: center;
  gap: 12px;
}
.pagehead,
.sectionhead,
.setting {
  justify-content: space-between;
}
.pagehead {
  margin: 24px 0 16px;
}
.sectionhead {
  margin-bottom: 17px;
}
.textbtn,
.pill,
.primary,
.heroextra,
.ib,
.plain {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.textbtn {
  font-size: 12px;
  color: var(--muted);
}
.primary {
  background: var(--accent);
  color: #24140f;
  font-size: 13px;
  font-weight: 700;
  border-radius: 30px;
  min-height: 38px;
  padding: 0 18px;
}
.tiles {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: clamp(10px, 1.5vw, 24px);
}
.tile {
  min-width: 0;
  text-align: left;
  padding: 0;
}
.sleeve {
  width: 100%;
  aspect-ratio: 1;
  position: relative;
  overflow: hidden;
  border-radius: 4px;
  background: var(--panel);
  margin-bottom: 8px;
}
.art {
  display: block;
  width: 44px;
  height: 44px;
  object-fit: cover;
  border-radius: 5px;
  flex-shrink: 0;
}
.sleeve > .art {
  width: 100%;
  height: 100%;
  border-radius: 0;
}
.fallback {
  display: grid;
  place-items: center;
  background: var(--panel);
  color: var(--muted);
}
.tile strong,
.row strong,
.now strong,
.orderrow strong,
.listcards strong {
  font-size: 14px;
  font-weight: 620;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tile small {
  margin-top: 2px;
}
.tileplay {
  position: absolute;
  right: 9px;
  bottom: 9px;
  display: grid;
  place-items: center;
  background: var(--accent);
  color: #211710;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  opacity: 0;
  transition: opacity 0.14s;
}
.tile:hover .tileplay,
.tile:focus-visible .tileplay {
  opacity: 1;
}
.rows {
  width: 100%;
}
.row,
.orderrow {
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  min-height: 60px;
}
.rowmain {
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left;
  min-width: 0;
  flex: 1;
  padding: 4px 0;
}
.rowmain span:not(.art) {
  min-width: 0;
}
.rindex,
.duration {
  color: var(--muted);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.rindex {
  width: 22px;
}
.rowalbum {
  color: var(--muted);
  font-size: 12px;
  flex: 0 1 23%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.duration {
  margin-left: auto;
}
.ib {
  height: 38px;
  width: 36px;
  color: var(--muted);
  border-radius: 8px;
  flex-shrink: 0;
}
.ib.active,
.current .rindex {
  color: var(--accent);
}
.pill,
.plain {
  background: var(--panel);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 25px;
  padding: 8px 14px;
  font-size: 13px;
}
.actions,
.tabs {
  flex-wrap: wrap;
}
.actions {
  margin: 12px 0 20px;
}
.tabs {
  display: flex;
  gap: 5px;
  margin: 13px 0 21px;
}
.tabs button {
  border: 1px solid var(--line);
  border-radius: 22px;
  color: var(--muted);
  padding: 7px 13px;
  font-size: 13px;
}
.tabs .sel {
  background: var(--ink);
  color: var(--bg);
}
.empty,
.notice {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 20px;
  color: var(--muted);
}
.notice {
  overflow-wrap: anywhere;
}
.listcards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr));
  gap: 12px;
}
.listcards button {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  display: flex;
  align-items: center;
  text-align: left;
  gap: 12px;
  padding: 12px;
  min-width: 0;
}
.listcards button svg:last-child {
  margin-left: auto;
}
.round {
  border-radius: 50%;
}
.setting,
.sort {
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}
.setting {
  min-height: 46px;
}
.eq {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}
.eq label {
  text-align: center;
}
.eq input {
  width: 100%;
}
.sort {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
}
.setting select,
select {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 7px;
  color: var(--ink);
  padding: 7px 9px;
}
input[type="checkbox"],
input[type="range"] {
  accent-color: var(--accent);
}
input[type="range"] {
  cursor: pointer;
  height: 4px;
}
.orderrow .ib {
  width: 30px;
}
.orderrow strong,
.rowmain strong {
  font-size: 14px;
}
footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 5;
  height: 89px;
  border-top: 1px solid var(--line);
  background: var(--side);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 1.04fr) minmax(0, 1fr);
  align-items: center;
  padding: 8px 23px;
  gap: 20px;
}
.now,
.playerend,
.transport > div {
  display: flex;
  align-items: center;
  gap: 10px;
}
.now {
  min-width: 0;
}
.now span:not(.art) {
  min-width: 0;
}
.now .art {
  height: 48px;
  width: 48px;
}
.now small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.player-artist-link { color: inherit; }
.player-artist-link:hover, .player-artist-link:focus-visible {
  color: var(--ink);
  text-decoration: underline;
}
.transport > div {
  justify-content: center;
}
.transport .ib {
  height: 32px;
}
.mainplay {
  background: var(--ink);
  color: var(--bg);
  border-radius: 50%;
  height: 36px !important;
  width: 36px;
}
.mainplay svg {
  fill: currentColor;
}
.transport .progress {
  margin-top: 7px;
  gap: 10px;
}
.progress input {
  min-width: 30px;
  width: 100%;
}
.progress small {
  font-size: 10px;
  font-variant-numeric: tabular-nums;
}
.playerend {
  justify-content: flex-end;
}
.playerend input {
  width: 76px;
}
.mobilemenu,
.scrim {
  display: none;
}
dialog {
  background: var(--panel);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 0;
  width: min(460px, calc(100% - 24px));
  max-height: 85dvh;
  box-shadow: 0 20px 70px #0005;
}
dialog::backdrop {
  background: #000a;
}
.modal {
  padding: 22px;
  animation: arrive 0.16s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.modal h2 {
  font-size: 23px;
}
.modal p {
  margin: 12px 0;
}
.modal form {
  display: grid;
  gap: 13px;
}
.modal label {
  display: grid;
  gap: 5px;
  font-size: 13px;
  color: var(--muted);
}
.modal label.check {
  display: flex;
  align-items: center;
}
.modal input:not([type="checkbox"]),
.modal textarea {
  background: var(--bg);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 10px;
  width: 100%;
}
.modal .primary {
  justify-self: start;
}
.modal textarea {
  resize: vertical;
}
.modal iframe {
  width: 100%;
  min-height: 260px;
  border: 0;
}
.playerinfo {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
}
.playerinfo .muted {
  margin: 0;
  font-size: 13px;
}
.choices {
  display: grid;
}
.choices button,
.choices a {
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: left;
  padding: 10px 5px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.choices svg {
  width: 17px;
  height: 17px;
  color: var(--muted);
}
.tracksummary {
  margin-bottom: 12px;
}
.toast {
  position: fixed;
  bottom: 106px;
  right: 20px;
  z-index: 10;
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: 0 6px 18px #0004;
  border-radius: 10px;
  padding: 12px 18px;
  max-width: min(440px, 92vw);
  overflow-wrap: anywhere;
}
.modal .notice {
  user-select: all;
}
.setting input[type="checkbox"] {
  width: 20px;
  height: 20px;
}
@keyframes arrive {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@media (min-width: 1700px) {
  :root {
    --rail: 264px;
  }
}
@media (max-width: 1050px) {
  :root {
    --rail: 196px;
  }
  .sidebar {
    padding-left: 10px;
    padding-right: 10px;
  }
  .tiles {
    gap: 12px;
  }
  .rowalbum {
    flex-basis: 15%;
  }
  .playerend {
    gap: 2px;
  }
}
@media (max-width: 760px) {
  :root {
    --rail: 0px;
  }
  .sidebar {
    width: min(264px, 84vw);
    bottom: 0;
    transform: translateX(-102%);
    z-index: 8;
    transition: transform 0.16s cubic-bezier(0.2, 0.8, 0.2, 1);
  }
  .sidebar:not(.open) {
    visibility: hidden;
  }
  .sidebar.open {
    transform: none;
    visibility: visible;
  }
  .scrim {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 7;
    background: #0008;
  }
  .mobilemenu {
    display: flex;
  }
  .brand {
    margin-bottom: 18px;
  }
  main {
    padding: 0 17px 116px;
  }
  header {
    height: 60px;
    gap: 8px;
  }
  .searchbox {
    flex: 1;
    width: auto;
    height: 36px;
  }
  .profile {
    padding: 8px;
  }
  .profile span,
  kbd {
    display: none;
  }
  .pagehead {
    margin: 23px 0 17px;
  }
  .tiles {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  section {
    margin: 24px 0;
  }
  .rowalbum,
  .rindex {
    display: none;
  }
  .row {
    gap: 4px;
  }
  .rowmain {
    gap: 8px;
  }
  .row .ib {
    width: 32px;
  }
  .row .art {
    width: 37px;
    height: 37px;
  }
  footer {
    height: 78px;
    grid-template-columns: minmax(0, 1fr) auto auto;
    padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
    gap: 5px;
  }
  .playerend .ib:not(:first-child),
  .playerend input,
  .transport .ib:first-child,
  .transport .ib:last-child,
  .transport .ib:nth-child(2),
  .now > .ib {
    display: none;
  }
  .transport .progress {
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    margin: 0;
  }
  .progress small {
    display: none;
  }
  .progress input {
    margin: 0;
  }
  .transport > div {
    gap: 2px;
  }
  .now .art {
    height: 39px;
    width: 39px;
  }
  .toast {
    bottom: 90px;
  }
  .eq {
    gap: 6px;
  }
  .eq label {
    font-size: 11px;
  }
  .navlink {
    padding: 10px 12px;
    min-height: 44px;
  }
  .setting {
    gap: 16px;
  }
  .orderrow {
    gap: 2px;
  }
}
@media (max-width: 460px) {
  .tiles {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px 12px;
  }
  .row .ib {
    width: 29px;
  }
  .sectionhead {
    gap: 7px;
  }
  .textbtn {
    font-size: 11px;
  }
  .setting {
    font-size: 13px;
  }
  .eq {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

.sectionhead h2 { font-weight: 600; }
.searchfilters, .searchfilters label { display: flex; align-items: center; gap: 8px; }
.searchfilters { flex-wrap: wrap; gap: 12px 24px; color: var(--muted); font-size: 13px; }
.searchfilters input { accent-color: var(--accent); }
.widgetnote { margin: 0 0 12px; font-size: 13px; color: var(--muted); }
.rowmain small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sectionhead .textbtn { min-height: 32px; }
.progress input:disabled { cursor: default; }
.progress input[type="range"] {
  appearance: none;
  height: 16px;
  margin-block: 0;
  background: transparent;
}
.progress input::-webkit-slider-runnable-track {
  height: 3px;
  border-radius: 2px;
  background: linear-gradient(to right, var(--accent) var(--elapsed), var(--line) var(--elapsed));
}
.progress input::-moz-range-track { height: 3px; background: var(--line); }
.progress input::-moz-range-progress { height: 3px; background: var(--accent); }
.progress input::-webkit-slider-thumb {
  appearance: none;
  width: 9px;
  height: 9px;
  margin-top: -3px;
  border-radius: 50%;
  background: var(--accent);
}
.progress input::-moz-range-thumb { width: 9px; height: 9px; border: 0; background: var(--accent); }
.progress input:disabled::-webkit-slider-thumb { opacity: 0; }
.progress input:disabled::-moz-range-thumb { opacity: 0; }
@media (max-width: 760px) {
  .transport .progress { top: -8px; }
  .progress input[type="range"] { height: 20px; }
}
.row.current { background-color: color-mix(in srgb, var(--ink) 5%, var(--bg)); }
.row:focus-within { outline: 1px solid var(--line); outline-offset: 2px; }
.mainplay:hover { background-color: var(--ink); color: var(--bg); }
@media (max-width: 560px) {
  .album-shelf {
    display: grid;
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: 43%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x proximity;
    padding: 4px 4px 8px;
    margin: -4px;
    scrollbar-width: thin;
    scrollbar-color: var(--line) transparent;
  }
  .album-shelf .tile { scroll-snap-align: start; }
}

/* Availability labels, per-source status notes and the official YouTube player. */
.accessbadge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 7px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: color-mix(in srgb, var(--panel) 72%, transparent);
  color: var(--muted);
  font-size: 10px;
  font-weight: 600;
  line-height: 1.5;
  letter-spacing: 0.01em;
  vertical-align: middle;
  white-space: nowrap;
}
.accessbadge.access-full {
  border-color: color-mix(in srgb, var(--accent) 55%, var(--line));
  color: var(--ink);
}
.accessbadge.access-full::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
}
.accessbadge.access-preview {
  border-style: dashed;
  color: var(--muted);
}
.accessbadge.access-player {
  color: var(--ink);
}
.accessbadge.access-link {
  opacity: 0.85;
}
.choices.sourceversions {
  margin: 14px 0 6px;
}
.sourceversions h3 {
  margin: 0 0 2px;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.sourceversions .versionlabel {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  min-width: 0;
}
.sourceversions small {
  margin-left: auto;
  text-align: right;
}
.sourcedetails {
  display: grid;
  gap: 7px;
  margin: 18px 0 6px;
}
.sourcedetails small {
  display: block;
  padding-left: 10px;
  border-left: 2px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  overflow-wrap: anywhere;
}
.sourcedetails small[data-state="disabled"] {
  border-left-color: color-mix(in srgb, var(--muted) 45%, var(--line));
}
.sourcedetails small[data-state="error"] {
  border-left-color: color-mix(in srgb, var(--accent) 65%, var(--line));
}
.youtubeplayer {
  display: grid;
  gap: 10px;
}
.youtubeplayer iframe {
  width: 100%;
  min-height: 0;
  aspect-ratio: 16 / 9;
  border: 0;
  border-radius: 9px;
  background: #000;
}
.youtubeplayer .ytstatus {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  font-size: 12px;
  color: var(--muted);
}
.youtubeplayer .ytstatus.playing {
  color: var(--ink);
}
.youtubeplayer .ytstatus.playing::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
.ytfail {
  display: grid;
  justify-items: start;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  padding: 13px;
}
.ytfail p {
  margin: 0;
  font-size: 13px;
}
.ytfailactions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.youtubeplayer .ytopen {
  margin: 0;
  font-size: 12px;
}
.ytopen a {
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}
dialog:has(.youtubeplayer) {
  width: min(620px, calc(100% - 24px));
}

/* Keep the availability label readable on narrow search rows. */
@media (max-width: 760px) {
  .rowmain small {
    white-space: normal;
    overflow: visible;
  }
  .rowmain small .accessbadge {
    margin-left: 2px;
  }
}
