/* PULSE local-only adapters layered over the pinned Mineradio stylesheet. */
:root {
  --font-sans: "Segoe UI Variable", "MiSans", "Microsoft YaHei UI", "HarmonyOS Sans SC", "PingFang SC", "Noto Sans SC", system-ui, sans-serif;
  --font-display: "Segoe UI Variable Display", "Segoe UI Variable", "MiSans", "Microsoft YaHei UI", system-ui, sans-serif;
  --font-mono: "Cascadia Mono", "JetBrains Mono", "SF Mono", ui-monospace, monospace;
  --pulse-cover-primary: #159b80;
  --pulse-cover-secondary: #6de7b0;
  --pulse-cover-contrast: #ffbf69;
  --pulse-cover-primary-rgb: 21,155,128;
  --pulse-cover-secondary-rgb: 109,231,176;
  --pulse-cover-contrast-rgb: 255,191,105;
  --studio-safe-left: clamp(48px, 6vw, 96px);
  --studio-safe-right: clamp(310px, 38vw, 560px);
}

#canvas-container {
  overflow: hidden;
}

html,
body,
button,
input,
textarea,
select {
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

button,
input,
textarea,
select {
  font-family: var(--font-sans);
}

#pulse-legacy-adapter[hidden] {
  display: none !important;
}

#soundstage-entry {
  position: fixed;
  inset: 0;
  z-index: 900;
  transition: opacity .62s cubic-bezier(.16, 1, .3, 1), visibility .62s;
}

body:not(.soundstage-locked) #soundstage-entry {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

#splash .splash-enter {
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  opacity: 1;
  pointer-events: auto;
  cursor: pointer;
}

.pulse-source-line {
  margin-top: 15px;
  color: rgba(255, 255, 255, .36);
  font: 500 9px/1.4 var(--font-mono);
  letter-spacing: .08em;
  text-transform: uppercase;
}

.splash-word-mine {
  animation-name: pulse-word-left;
}

.splash-word-radio {
  animation-name: pulse-word-right;
}

@keyframes pulse-word-left {
  0% {
    opacity: 0;
    clip-path: inset(48% 0 49% 0);
    transform: translate(calc(-50% - 12px), -42%) skewX(-10deg) scaleX(1.08);
  }
  28% {
    opacity: 1;
    clip-path: inset(0);
    transform: translate(-50%, -50%) skewX(0) scaleX(1);
  }
  58% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
  100% {
    opacity: 1;
    transform: translate(calc(-50% - clamp(112px, 15.5vw, 206px)), -50%);
  }
}

@keyframes pulse-word-right {
  0%,
  38% {
    opacity: 0;
    clip-path: inset(52% 0 44% 0);
    transform: translate(calc(-50% + 24px), -50%) skewX(9deg) scaleX(1.06);
  }
  68% {
    opacity: 1;
    clip-path: inset(0);
    transform: translate(calc(-50% + clamp(116px, 16vw, 214px)), -50%) scale(1);
  }
  100% {
    opacity: 1;
    transform: translate(calc(-50% + clamp(116px, 16vw, 214px)), -50%) scale(1);
    background-position: 100% 0;
  }
}

#portfolio-back,
#source-license {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(255, 255, 255, .11);
  border-radius: 50%;
  background: rgba(8, 12, 16, .34);
  color: rgba(235, 245, 249, .72);
  backdrop-filter: blur(16px) saturate(1.15);
  -webkit-backdrop-filter: blur(16px) saturate(1.15);
  cursor: pointer;
}

#portfolio-back {
  position: fixed;
  /* Keep the escape hatch above the entry splash so it is usable from both
     Studio and Classic, including before the first soundstage click. */
  z-index: 950;
  top: 22px;
  left: 24px;
}

#portfolio-back svg,
#source-license svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

#portfolio-back:hover,
#source-license:hover,
#portfolio-back:focus-visible,
#source-license:focus-visible {
  border-color: rgba(var(--fc-accent-rgb), .5);
  color: #fff;
  outline: none;
}

#top-right {
  min-width: 40px;
  z-index: 620;
}

body:not(.soundstage-locked) #bottom-bar {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0) scale(1);
}

body:not(.soundstage-locked) #thumb-wrap {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

#fx-panel[aria-hidden="true"],
#playlist-panel[aria-hidden="true"],
#mini-queue-popover[aria-hidden="true"] {
  pointer-events: none;
}

.source-dialog {
  width: min(520px, calc(100vw - 32px));
  border: 1px solid rgba(var(--fc-accent-rgb), .32);
  border-radius: 22px;
  padding: 0;
  background: rgba(8, 10, 13, .94);
  color: var(--fc-ink);
  box-shadow: 0 30px 100px rgba(0, 0, 0, .62);
  backdrop-filter: blur(26px) saturate(1.18);
}

.source-dialog::backdrop {
  background: rgba(0, 0, 0, .72);
  backdrop-filter: blur(8px);
}

.source-dialog form {
  padding: 24px;
}

.dialog-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, .1);
}

.dialog-heading p {
  color: rgba(255, 255, 255, .52);
  font: 600 10px var(--font-mono);
}

.dialog-close {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .07);
  color: #fff;
  cursor: pointer;
}

.source-dialog h2 {
  margin: 26px 0 10px;
  font-size: 34px;
}

.source-dialog > form > p {
  color: rgba(255, 255, 255, .58);
  font-size: 13px;
  line-height: 1.7;
}

.source-dialog nav {
  display: grid;
  gap: 8px;
  margin-top: 22px;
}

.source-dialog nav a {
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 12px;
  color: rgba(255, 255, 255, .8);
  text-decoration: none;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
[role="slider"]:focus-visible {
  outline: 2px solid rgba(var(--fc-accent-rgb), .82);
  outline-offset: 3px;
}

@media (max-width: 720px) {
  #portfolio-back {
    top: 14px;
    left: 12px;
  }

  #bottom-bar,
  body:not(.soundstage-locked) #bottom-bar {
    width: calc(100dvw - 20px);
    max-width: calc(100dvw - 20px);
    box-sizing: border-box;
  }

  #controls,
  .control-cluster.actions,
  .control-track,
  .control-meta {
    min-width: 0;
  }

  #control-title,
  #control-title-text {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  #status-toast {
    max-width: min(560px, calc(100dvw - 24px));
    overflow-wrap: anywhere;
  }

  @supports (padding: max(0px)) {
    #bottom-bar,
    body:not(.soundstage-locked) #bottom-bar {
      width: calc(100dvw - 20px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px));
      bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    }
  }
}

@media (prefers-reduced-motion: reduce) {
  #soundstage-entry,
  #bottom-bar,
  #thumb-wrap,
  #fx-panel,
  #playlist-panel {
    transition: none !important;
  }
}

/* PULSE ROOM browser-only visual console. */
#fx-panel {
  z-index: 620;
  top: 24px;
  bottom: 104px;
  width: min(448px, calc(100vw - 32px));
  max-height: none;
  padding: 0 18px 24px;
  border-radius: 6px;
  border-color: rgba(var(--fc-accent-rgb), .28) !important;
  background: rgba(5, 6, 8, .93) !important;
  box-shadow: 0 28px 90px rgba(0, 0, 0, .58), inset 0 1px 0 rgba(255, 255, 255, .08) !important;
}

#fx-panel.show {
  right: 24px;
}

.pulse-settings-head {
  position: sticky;
  z-index: 4;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  margin: 0 -18px;
  padding: 0 18px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  background: #050608;
}

.pulse-settings-head .fx-title {
  color: #f5f7f8;
  font: 750 13px/1.2 var(--font-sans);
  letter-spacing: 0;
}

.pulse-settings-head .fx-sub {
  margin-top: 5px;
  color: rgba(255, 255, 255, .42);
  font: 600 9px/1 var(--font-mono);
  letter-spacing: .08em;
}

.pulse-settings-icon-btn {
  display: inline-flex;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, .11);
  border-radius: 4px;
  background: rgba(255, 255, 255, .04);
  color: rgba(255, 255, 255, .72);
  cursor: pointer;
}

.pulse-settings-icon-btn:hover {
  border-color: rgba(var(--fc-accent-rgb), .46);
  color: #fff;
  background: rgba(var(--fc-accent-rgb), .10);
}

.pulse-settings-icon-btn svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.pulse-settings-tabs {
  position: sticky;
  z-index: 3;
  top: 72px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0 -18px;
  padding: 8px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  background: #050608;
}

.pulse-settings-tabs button {
  height: 34px;
  border: 0;
  border-right: 1px solid rgba(255, 255, 255, .08);
  background: transparent;
  color: rgba(255, 255, 255, .42);
  font: 700 10px/1 var(--font-mono);
  letter-spacing: .08em;
  cursor: pointer;
}

.pulse-settings-tabs button:last-child {
  border-right: 0;
}

.pulse-settings-tabs button.active {
  color: var(--fc-accent);
  background: rgba(var(--fc-accent-rgb), .08);
}

#fx-panel .fx-tab-page {
  display: none;
}

#fx-panel .fx-tab-page.active {
  display: block;
}

.pulse-settings-group {
  padding: 22px 0 24px;
  border-bottom: 1px solid rgba(255, 255, 255, .095);
}

.pulse-settings-group-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 17px;
}

.pulse-settings-group-head strong {
  color: rgba(255, 255, 255, .9);
  font: 720 11px/1.2 var(--font-mono);
  letter-spacing: .08em;
}

.pulse-settings-group-head span {
  color: rgba(var(--fc-accent-rgb), .72);
  font: 650 9px/1 var(--font-mono);
  letter-spacing: .08em;
}

#fx-panel .preset-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  margin: 0;
}

#fx-panel .preset-card {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  grid-template-rows: auto auto;
  min-width: 0;
  min-height: 68px;
  padding: 11px 10px;
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 4px;
  background: rgba(255, 255, 255, .025);
  color: rgba(255, 255, 255, .76);
  text-align: left;
  cursor: pointer;
}

#fx-panel .preset-card:hover,
#fx-panel .preset-card.active {
  border-color: rgba(var(--fc-accent-rgb), .44);
  background: rgba(var(--fc-accent-rgb), .08);
}

#fx-panel .preset-card .pc-icon {
  grid-row: 1 / 3;
  align-self: center;
}

#fx-panel .preset-card .pc-icon svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
}

#fx-panel .preset-card .pc-name {
  min-width: 0;
  overflow: hidden;
  color: rgba(255, 255, 255, .92);
  font: 700 10px/1.2 var(--font-mono);
  letter-spacing: .04em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#fx-panel .preset-card .pc-desc {
  min-width: 0;
  margin-top: 5px;
  overflow: hidden;
  color: rgba(255, 255, 255, .42);
  font: 500 10px/1.2 var(--font-sans);
  letter-spacing: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pulse-color-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.pulse-color-control {
  display: grid;
  min-width: 0;
  gap: 7px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 4px;
  color: rgba(255, 255, 255, .58);
  font: 600 10px/1.2 var(--font-sans);
}

.pulse-color-control input[type=color] {
  width: 100%;
  height: 28px;
  padding: 0;
  border: 0;
  border-radius: 2px;
  background: transparent;
  cursor: pointer;
}

.pulse-color-control output {
  overflow: hidden;
  color: rgba(255, 255, 255, .42);
  font: 600 9px/1 var(--font-mono);
  text-overflow: ellipsis;
}

#fx-panel .fx-slider {
  display: grid;
  grid-template-columns: 116px minmax(0, 1fr) 54px;
  align-items: center;
  min-height: 42px;
  margin: 0;
  padding: 0;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, .055);
  border-radius: 0;
  background: transparent;
}

#fx-panel .fx-slider label {
  min-width: 0;
  color: rgba(255, 255, 255, .58);
  font: 550 11px/1.2 var(--font-sans);
  letter-spacing: 0;
}

#fx-panel .fx-slider output {
  color: rgba(var(--fc-accent-rgb), .74);
  font: 600 9px/1 var(--font-mono);
  text-align: right;
}

#fx-panel input[type=range] {
  min-width: 0;
  accent-color: var(--fc-accent);
}

#fx-panel .fx-toggle-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 8px;
}

#fx-panel .fx-toggle {
  min-width: 0;
  min-height: 38px;
  border-radius: 4px;
}

#fx-panel .pulse-settings-seg {
  display: flex;
  width: 100%;
  margin: 0 0 8px;
  border-radius: 4px;
}

#fx-panel .pulse-settings-seg button {
  min-width: 0;
  flex: 1 1 0;
  padding: 0 8px;
  letter-spacing: .04em;
}

#fx-panel .pulse-settings-seg-wrap {
  flex-wrap: wrap;
}

#fx-panel .pulse-settings-seg-wrap button {
  flex-basis: 20%;
}

.pulse-settings-hint {
  margin: -4px 0 16px;
  color: rgba(255, 255, 255, .46);
  font: 500 11px/1.6 var(--font-sans);
  letter-spacing: .02em;
}

.pulse-settings-control-label {
  margin: 14px 0 7px;
  color: rgba(255, 255, 255, .68);
  font: 650 10px/1.2 var(--font-sans);
  letter-spacing: .04em;
}

#fx-panel .pulse-settings-group-head strong,
#fx-panel .pulse-settings-tabs button,
#fx-panel .preset-card .pc-name {
  font-family: var(--font-sans);
  letter-spacing: .02em;
}

#fx-panel .pulse-settings-group-head strong {
  font-size: 13px;
  font-weight: 740;
}

#fx-panel .pulse-settings-group-head span {
  font-size: 10px;
  letter-spacing: .06em;
}

#fx-panel .pulse-settings-seg {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 8px;
  background: rgba(255, 255, 255, .025);
}

#fx-panel .pulse-settings-seg button {
  min-height: 36px;
  border-right: 1px solid rgba(255, 255, 255, .10);
  color: rgba(255, 255, 255, .54);
  font: 650 11px/1.25 var(--font-sans);
  letter-spacing: .01em;
  white-space: normal;
}

#fx-panel .pulse-settings-seg button:last-child {
  border-right: 0;
}

#fx-panel .pulse-settings-seg button:hover,
#fx-panel .pulse-settings-seg button.active {
  color: #f7fff9;
  background: rgba(var(--fc-accent-rgb), .13);
}

#fx-panel .pulse-settings-seg-wrap button {
  min-height: 34px;
  line-height: 1.2;
}

#fx-panel .fx-slider {
  grid-template-columns: 132px minmax(0, 1fr) 58px;
  min-height: 48px;
}

#fx-panel .fx-slider label {
  color: rgba(255, 255, 255, .68);
  font-size: 11px;
  line-height: 1.4;
}

#fx-panel .fx-slider output {
  font-size: 10px;
}

#fx-panel .bg-media-preview {
  width: 100%;
  aspect-ratio: 16 / 6;
  margin-top: 10px;
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 4px;
  background-color: rgba(255, 255, 255, .025);
}

.pulse-media-actions {
  display: flex;
  gap: 6px;
  margin-top: 7px;
}

.pulse-immersive-command {
  display: flex;
  width: 100%;
  min-height: 64px;
  align-items: center;
  justify-content: space-between;
  padding: 0 18px;
  border: 1px solid rgba(var(--fc-accent-rgb), .34);
  border-radius: 4px;
  background: rgba(var(--fc-accent-rgb), .07);
  color: #f6f8f9;
  font: 720 11px/1 var(--font-mono);
  letter-spacing: .08em;
  cursor: pointer;
}

.pulse-immersive-command svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: var(--fc-accent);
  stroke-width: 1.6;
}

.pulse-immersive-command.active {
  background: rgba(var(--fc-accent-rgb), .16);
}

.pulse-settings-reset {
  padding: 22px 0 2px;
}

.pulse-settings-reset .fx-mini-btn {
  width: 100%;
  min-height: 38px;
  border-radius: 4px;
}

@media (max-width: 600px) {
  #fx-panel {
    top: 10px;
    right: -100vw;
    bottom: calc(244px + env(safe-area-inset-bottom, 0px));
    left: 10px;
    width: auto;
    padding-right: 14px;
    padding-left: 14px;
  }

  #fx-panel.show {
    right: 10px;
  }

  .pulse-settings-head,
  .pulse-settings-tabs {
    margin-right: -14px;
    margin-left: -14px;
    padding-right: 14px;
    padding-left: 14px;
  }

  #fx-panel .preset-grid,
  .pulse-color-grid {
    grid-template-columns: 1fr;
  }

  #fx-panel .fx-slider {
    grid-template-columns: 102px minmax(0, 1fr) 48px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #fx-panel,
  #fx-panel.show {
    animation: none !important;
    transition: none !important;
  }
}

/* PULSE ROOM dual-mode product surface. */
#view-mode-btn {
  display: inline-flex;
  min-width: 112px;
  height: 40px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 999px;
  background: rgba(7, 10, 12, .58);
  color: rgba(245, 248, 249, .68);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05), 0 10px 30px rgba(0, 0, 0, .16);
  backdrop-filter: blur(18px) saturate(1.18);
  -webkit-backdrop-filter: blur(18px) saturate(1.18);
  font: 700 9px/1 var(--font-mono);
  letter-spacing: .14em;
  cursor: pointer;
  transition: border-color .2s ease, color .2s ease, background-color .2s ease, transform .2s ease;
}

#view-mode-btn:hover,
#view-mode-btn:focus-visible {
  border-color: rgba(var(--fc-accent-rgb), .55);
  background: rgba(var(--fc-accent-rgb), .1);
  color: #fff;
}

#view-mode-btn:active {
  transform: scale(.97);
}

.view-mode-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--fc-accent);
  box-shadow: 0 0 0 4px rgba(var(--fc-accent-rgb), .1), 0 0 16px rgba(var(--fc-accent-rgb), .66);
}

body[data-app-mode="classic"] #view-mode-btn {
  border-color: rgba(255, 191, 105, .42);
  color: rgba(255, 229, 194, .9);
}

body[data-app-mode="classic"] .view-mode-dot {
  background: #ffbf69;
  box-shadow: 0 0 0 4px rgba(255, 191, 105, .1), 0 0 16px rgba(255, 191, 105, .58);
}

/* The first Studio frame now has a readable arrival: the shared field blooms
   in, the chrome follows, and a short radial flare makes the transition
   perceptible even when the splash itself is dismissed quickly. */
body.studio-entry-active #canvas-container {
  animation: studio-entry-space 1.45s cubic-bezier(.16, 1, .3, 1) both;
}

body.studio-entry-active #canvas-container::before {
  position: absolute;
  z-index: 5;
  inset: -18%;
  background:
    radial-gradient(circle at 50% 50%, transparent 0 8%, rgba(var(--fc-accent-rgb), .62) 8.3% 8.7%, transparent 9.4%),
    conic-gradient(from -82deg at 50% 50%, transparent 0 13%, rgba(var(--fc-accent-rgb), .26) 20%, transparent 31%, rgba(var(--pulse-cover-secondary-rgb), .20) 43%, transparent 56%, rgba(var(--fc-accent-rgb), .16) 72%, transparent 86%);
  content: "";
  mix-blend-mode: screen;
  opacity: 0;
  pointer-events: none;
  animation: studio-entry-iris 1.48s cubic-bezier(.16, 1, .3, 1) .02s both;
}

body.studio-entry-active #canvas-container::after {
  position: absolute;
  z-index: 6;
  inset: -12%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, rgba(216, 255, 57, .28), rgba(89, 230, 185, .12) 24%, transparent 66%);
  content: "";
  opacity: 0;
  pointer-events: none;
  animation: studio-entry-flare 1.25s cubic-bezier(.16, 1, .3, 1) .08s both;
}

body.studio-entry-active #bottom-bar {
  animation: studio-entry-chrome .86s cubic-bezier(.16, 1, .3, 1) .32s both;
}

body.studio-entry-active #top-right {
  animation: studio-entry-chrome .72s cubic-bezier(.16, 1, .3, 1) .46s both;
}

#studio-track-spotlight {
  position: fixed;
  z-index: 6;
  left: var(--studio-safe-left);
  bottom: clamp(148px, 22vh, 230px);
  display: grid;
  width: min(400px, calc(100vw - var(--studio-safe-left) - var(--studio-safe-right)));
  width: min(400px, calc(100dvw - var(--studio-safe-left) - var(--studio-safe-right)));
  min-width: 0;
  box-sizing: border-box;
  gap: 6px;
  pointer-events: none;
  mix-blend-mode: screen;
  transition: opacity .42s ease, transform .42s cubic-bezier(.16, 1, .3, 1);
}

#studio-track-spotlight::before {
  position: absolute;
  top: 2px;
  bottom: 2px;
  left: -16px;
  width: 1px;
  background: linear-gradient(to bottom, transparent, rgba(var(--fc-accent-rgb), .78) 24%, rgba(var(--fc-accent-rgb), .18) 78%, transparent);
  content: "";
}

.studio-spotlight-kicker {
  display: flex;
  align-items: center;
  gap: 9px;
  color: rgba(214, 255, 226, .68);
  font: 700 9px/1 var(--font-mono);
  letter-spacing: .18em;
}

.studio-spotlight-kicker span:first-child {
  color: var(--fc-accent);
  font-size: 11px;
  letter-spacing: .08em;
}

#studio-spotlight-title {
  display: -webkit-box;
  max-width: 100%;
  overflow: hidden;
  overflow-wrap: anywhere;
  color: rgba(246, 250, 248, .95);
  font: 750 clamp(28px, 3.1vw, 52px)/.92 var(--font-sans);
  letter-spacing: -.075em;
  white-space: normal;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  text-shadow: 0 0 28px rgba(142, 255, 176, .12);
}

#studio-spotlight-artist {
  color: rgba(235, 247, 239, .54);
  font: 600 11px/1.3 var(--font-mono);
  letter-spacing: .06em;
  text-transform: uppercase;
}

body.studio-entry-active #studio-track-spotlight {
  animation: studio-entry-spotlight .88s cubic-bezier(.16, 1, .3, 1) .28s both;
}

@keyframes studio-entry-spotlight {
  from { opacity: 0; transform: translate3d(-38px, 20px, 0) scale(.88); clip-path: inset(0 100% 0 0); filter: blur(10px); }
  68% { opacity: 1; clip-path: inset(0 0 0 0); }
  to { opacity: 1; transform: none; filter: none; }
}

@keyframes studio-entry-space {
  from { opacity: .16; transform: scale(1.035); filter: blur(12px) saturate(.72); }
  62% { opacity: 1; transform: scale(1.005); filter: blur(1px) saturate(1.12); }
  to { opacity: 1; transform: none; filter: none; }
}

@keyframes studio-entry-flare {
  0% { opacity: 0; transform: scale(.72); }
  32% { opacity: .92; transform: scale(.92); }
  100% { opacity: 0; transform: scale(1.22); }
}

@keyframes studio-entry-iris {
  0% { opacity: 0; transform: scale(.34) rotate(-18deg); filter: blur(16px); }
  18% { opacity: .92; }
  58% { opacity: .38; transform: scale(1.06) rotate(16deg); filter: blur(2px); }
  100% { opacity: 0; transform: scale(1.42) rotate(38deg); filter: blur(0); }
}

@keyframes studio-entry-chrome {
  from { opacity: 0; translate: 0 18px; filter: blur(6px); }
  to { opacity: 1; translate: 0; filter: none; }
}

/* Classic is a secondary player surface: the Studio renderer stays mounted,
   but its chrome leaves the stage so the turntable owns the screen cleanly. */
body.classic-route-open #canvas-container,
body.classic-route-open #album-bg,
body.classic-route-open #album-bg-next,
body.classic-route-open #custom-bg,
body.classic-route-open #bottom-bar,
body.classic-route-open #studio-track-spotlight,
body.classic-route-open #fx-fab,
body.classic-route-open #top-right,
body.classic-route-open #hint {
  opacity: 0 !important;
  pointer-events: none !important;
  visibility: hidden !important;
}

/* Keep a quiet, blurred cover wash behind Studio even when the custom
   background adapter is active. This prevents a track switch from leaving a
   dead black side of the composition while the fluid field settles. */
body.custom-background-override #album-bg.visible,
body.custom-background-override #album-bg-next.visible {
  opacity: .12 !important;
  filter: blur(112px) brightness(.26) saturate(1.35);
}

#controls .control-cover {
  position: relative;
  width: 56px;
  height: 56px;
  flex: 0 0 56px;
  border: 1px solid rgba(var(--pulse-cover-secondary-rgb), .46);
  border-radius: 50%;
  background-position: center;
  background-size: cover;
  box-shadow: 0 8px 22px rgba(0, 0, 0, .34), inset 0 1px 0 rgba(255, 255, 255, .18), 0 0 0 4px rgba(var(--pulse-cover-primary-rgb), .06);
  transition: transform .28s cubic-bezier(.16, 1, .3, 1), border-color .28s ease;
}

#controls .control-cover:hover {
  transform: translateY(-2px) scale(1.03);
  border-color: rgba(var(--pulse-cover-secondary-rgb), .68);
}

/* Align the transport as a single rhythm: fixed label columns prevent the
   sliders, values, and utility buttons from drifting between settings tabs. */
#controls {
  align-items: center;
  gap: clamp(18px, 2.4vw, 42px);
}

#controls .control-cluster {
  min-width: 0;
}

#controls .control-cluster.actions {
  flex: 1 1 250px;
}

#controls .control-cluster.transport {
  flex: 0 0 auto;
}

#controls .control-cluster.modes {
  flex: 1 1 250px;
  justify-content: flex-end;
}

#control-title-text,
#control-artist,
#time-display {
  font-family: var(--font-sans);
  line-height: 1.25;
}

#control-title-text {
  font-size: 13px;
  font-weight: 720;
  letter-spacing: -.01em;
}

#control-artist {
  font-size: 10px;
  font-weight: 560;
  letter-spacing: .04em;
}

#fx-panel,
#fx-panel button,
#fx-panel input,
#fx-panel output {
  box-sizing: border-box;
}

#fx-panel .pulse-settings-group-head,
#fx-panel .fx-slider,
#fx-panel .pulse-settings-seg {
  align-items: center;
}

#fx-panel .pulse-settings-group-head {
  min-height: 18px;
}

#fx-panel .fx-slider label {
  overflow: hidden;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#fx-panel .fx-slider output {
  min-width: 0;
  line-height: 1.2;
}

@media (prefers-reduced-motion: reduce) {
  #classic-turntable-disc {
    animation-duration: 48s;
  }
}

/* One renderer remains mounted in both modes; these classes animate the
   presentation layers around it so switching feels like a deliberate view
   change instead of a hard visibility toggle. */
body.pulse-mode-transition #canvas-container,
body.pulse-mode-transition #classic-home {
  transition-duration: .52s;
}

body.pulse-mode-to-classic #canvas-container {
  opacity: .16;
  filter: saturate(.6) contrast(.9);
}

body.pulse-mode-to-studio #canvas-container {
  opacity: 1;
  filter: saturate(1.04) contrast(1.02);
}

body.pulse-mode-to-studio #classic-home {
  opacity: 0;
  transform: translateY(18px) scale(.988);
  filter: blur(7px);
  pointer-events: none;
}

body.pulse-mode-to-classic #classic-home {
  opacity: 1;
  transform: translateY(0) scale(1);
  filter: blur(0);
}

@media (prefers-reduced-motion: reduce) {
  body.pulse-mode-transition #canvas-container,
  body.pulse-mode-transition #classic-home {
    transition-duration: .16s;
  }

  body.pulse-mode-to-studio #classic-home,
  body.pulse-mode-to-classic #classic-home {
    transform: none;
    filter: none;
  }
}

#classic-home {
  position: fixed;
  z-index: 860;
  inset: 0;
  overflow: auto;
  padding: 30px 36px 54px;
  color: #f2f6f6;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity .32s ease, transform .42s cubic-bezier(.16, 1, .3, 1), visibility .32s ease;
  visibility: hidden;
  background:
    radial-gradient(circle at 78% 12%, rgba(50, 154, 139, .13), transparent 32%),
    linear-gradient(135deg, #05090a 0%, #071012 52%, #101116 100%);
}

body[data-app-mode="classic"]:not(.soundstage-locked) #classic-home {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
  visibility: visible;
}

.classic-shell {
  width: min(1400px, 100%);
  margin: 0 auto;
}

.classic-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  padding: 18px 0 28px;
}

.classic-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.classic-back-btn {
  min-height: 34px;
  padding: 0 13px;
  border: 1px solid rgba(142, 255, 176, .22);
  border-radius: 999px;
  background: rgba(142, 255, 176, .06);
  color: rgba(216, 255, 226, .8);
  font: 700 10px/1 var(--font-sans);
  cursor: pointer;
  transition: border-color .2s ease, background-color .2s ease, transform .2s ease;
}

.classic-back-btn:hover,
.classic-back-btn:focus-visible {
  border-color: rgba(142, 255, 176, .62);
  background: rgba(142, 255, 176, .14);
}

.classic-back-btn:active {
  transform: translateY(1px);
}

.classic-header h1 {
  max-width: 620px;
  margin: 7px 0 0;
  color: rgba(245, 249, 247, .96);
  font: 650 clamp(38px, 5.2vw, 76px)/.94 var(--font-sans);
  letter-spacing: -.06em;
}

.classic-eyebrow {
  margin: 0;
  color: rgba(173, 255, 207, .62);
  font: 700 9px/1.2 var(--font-mono);
  letter-spacing: .16em;
  text-transform: uppercase;
}

.classic-status {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 9px 12px;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 999px;
  background: rgba(255, 255, 255, .035);
  color: rgba(255, 255, 255, .45);
  font: 650 9px/1 var(--font-mono);
  letter-spacing: .11em;
}

.classic-status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #8effb0;
  box-shadow: 0 0 0 4px rgba(142, 255, 176, .08), 0 0 14px rgba(142, 255, 176, .55);
}

.classic-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 0 18px;
  border-bottom: 1px solid rgba(255, 255, 255, .1);
}

.classic-nav button {
  min-height: 30px;
  padding: 0 11px;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, .42);
  font: 700 10px/1 var(--font-mono);
  letter-spacing: .14em;
  cursor: pointer;
  transition: color .2s ease, background-color .2s ease;
}

.classic-nav button:hover,
.classic-nav button.active {
  border-radius: 3px;
  background: rgba(142, 255, 176, .08);
  color: #a9ffc0;
}

.classic-nav-rule {
  width: 1px;
  height: 18px;
  margin-left: 4px;
  background: rgba(255, 255, 255, .12);
}

.classic-nav-note {
  margin-left: auto;
  color: rgba(255, 255, 255, .3);
  font: 600 9px/1 var(--font-mono);
  letter-spacing: .12em;
}

.classic-main {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(340px, .9fr) minmax(250px, .68fr);
  gap: 22px;
  padding-top: 14px;
}

.classic-hero,
.classic-library,
.classic-now-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .1);
  background: linear-gradient(145deg, rgba(255, 255, 255, .075), rgba(255, 255, 255, .02));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 24px 80px rgba(0, 0, 0, .2);
  backdrop-filter: blur(24px) saturate(1.16);
  -webkit-backdrop-filter: blur(24px) saturate(1.16);
}

.classic-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(270px, .78fr);
  align-items: center;
  min-height: 430px;
  padding: clamp(24px, 4vw, 48px);
  isolation: isolate;
  border-color: transparent;
  background: linear-gradient(145deg, rgba(255, 255, 255, .025), transparent 64%);
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.classic-hero::before {
  position: absolute;
  z-index: 0;
  inset: 8% 11% 7% 38%;
  border: 1px solid rgba(142, 255, 176, .1);
  border-radius: 48% 52% 54% 46%;
  content: "";
  opacity: .18;
  transform: rotate(-12deg) scale(.94);
  animation: classic-hero-orbit 14s linear infinite;
  pointer-events: none;
}

.classic-hero::after {
  position: absolute;
  right: -5%;
  bottom: -18%;
  width: 68%;
  height: 70%;
  border: 1px solid rgba(142, 255, 176, .14);
  border-radius: 48% 52% 56% 44%;
  content: "";
  opacity: .42;
  transform: rotate(-14deg);
  box-shadow: 0 0 0 22px rgba(142, 255, 176, .028), 0 0 0 54px rgba(255, 191, 105, .018);
}

.classic-hero-glow {
  position: absolute;
  top: -26%;
  right: -4%;
  width: 70%;
  height: 86%;
  border-radius: 50%;
  background: radial-gradient(circle at 45% 48%, rgba(70, 234, 188, .22), rgba(25, 81, 88, .06) 42%, transparent 70%);
  filter: blur(20px);
  animation: classic-hero-breathe 7s ease-in-out infinite alternate;
}

@keyframes classic-hero-breathe {
  from { transform: translate3d(-2%, 1%, 0) scale(.92) rotate(-4deg); opacity: .58; }
  to { transform: translate3d(4%, -3%, 0) scale(1.08) rotate(6deg); opacity: .92; }
}

@keyframes classic-hero-orbit {
  from { transform: rotate(-12deg) scale(.94); opacity: .24; }
  50% { transform: rotate(8deg) scale(1.02); opacity: .62; }
  to { transform: rotate(18deg) scale(.96); opacity: .26; }
}

.classic-turntable-stage {
  position: relative;
  grid-column: 2;
  grid-row: 1;
  justify-self: end;
  z-index: 2;
  width: min(320px, 100%);
  aspect-ratio: 1;
  pointer-events: none;
  translate: 14px 0;
  animation: classic-enter-disc .96s cubic-bezier(.16, 1, .3, 1) .1s both;
}

.classic-turntable-aura {
  position: absolute;
  inset: 8%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(var(--pulse-cover-primary-rgb), .28), rgba(var(--pulse-cover-secondary-rgb), .10) 44%, transparent 72%);
  filter: blur(16px);
  animation: classic-turntable-aura 5.6s ease-in-out infinite alternate;
}

@keyframes classic-turntable-aura {
  from { opacity: .52; transform: scale(.9); }
  to { opacity: .92; transform: scale(1.08); }
}

.classic-turntable-disc {
  position: absolute;
  inset: 13%;
  overflow: hidden;
  border: 1px solid rgba(var(--pulse-cover-secondary-rgb), .76);
  border-radius: 50%;
  background-color: rgba(4, 8, 11, .94);
  background-position: center;
  background-size: cover;
  background-blend-mode: screen, normal;
  box-shadow: 0 24px 54px rgba(0, 0, 0, .4), 0 0 0 12px rgba(var(--pulse-cover-primary-rgb), .08), 0 0 0 24px rgba(var(--pulse-cover-secondary-rgb), .035), inset 0 0 34px rgba(0, 0, 0, .45);
  animation: classic-record-spin 18s linear infinite;
  will-change: transform;
}

.classic-turntable-disc::before {
  position: absolute;
  inset: 7%;
  border: 1px solid rgba(255, 255, 255, .24);
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .32), inset 0 0 20px rgba(0, 0, 0, .48), 0 0 0 1px rgba(255, 255, 255, .08);
  content: "";
}

.classic-turntable-groove {
  position: absolute;
  inset: 19%;
  border: 1px dashed rgba(255, 255, 255, .2);
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .09), inset 0 0 0 13px rgba(0, 0, 0, .09);
}

.classic-turntable-label {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 19%;
  aspect-ratio: 1;
  border: 3px solid rgba(255, 255, 255, .78);
  border-radius: 50%;
  background: rgba(var(--pulse-cover-contrast-rgb), .92);
  box-shadow: 0 0 0 6px rgba(4, 8, 11, .54), 0 0 20px rgba(var(--pulse-cover-secondary-rgb), .42);
  transform: translate(-50%, -50%);
}

.classic-turntable-arm {
  display: none;
  position: absolute;
  z-index: 2;
  top: 2%;
  right: 6%;
  width: 30%;
  height: 44%;
  border-top: 2px solid rgba(234, 255, 245, .72);
  border-right: 2px solid rgba(234, 255, 245, .72);
  border-radius: 0 92% 0 0;
  opacity: .72;
  transform: rotate(9deg);
  transform-origin: top right;
}

.classic-turntable-arm span {
  position: absolute;
  right: -5px;
  bottom: -5px;
  width: 11px;
  height: 18px;
  border-radius: 2px;
  background: #dfffea;
  box-shadow: 0 0 14px rgba(142, 255, 176, .42);
  transform: rotate(18deg);
}

.classic-turntable-caption {
  position: absolute;
  right: 1%;
  bottom: 3%;
  color: rgba(255, 255, 255, .46);
  font: 700 9px/1 var(--font-mono);
  letter-spacing: .16em;
}

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

body[data-playing="true"] .classic-turntable-disc {
  animation-duration: 7.4s;
}

.classic-hero-copy {
  position: relative;
  grid-column: 1;
  grid-row: 1;
  z-index: 1;
  max-width: 520px;
}

.classic-hero-copy h2 {
  margin: 15px 0 4px;
  color: #f5f8f7;
  font: 750 clamp(46px, 5.6vw, 88px)/.88 var(--font-sans);
  letter-spacing: -.075em;
  text-shadow: 0 0 30px rgba(142, 255, 176, .12);
}

.classic-hero-artist {
  margin: 0;
  color: rgba(255, 255, 255, .55);
  font: 600 13px/1.4 var(--font-mono);
  letter-spacing: .04em;
}

.classic-progress {
  width: min(100%, 410px);
  margin-top: 24px;
}

.classic-progress-time {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 9px;
  color: rgba(255, 255, 255, .42);
  font: 650 9px/1 var(--font-mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: .1em;
}

.classic-progress-bar {
  position: relative;
  height: 18px;
  cursor: pointer;
  touch-action: none;
  outline: none;
}

.classic-progress-rail,
.classic-progress-fill {
  position: absolute;
  top: 50%;
  left: 0;
  height: 2px;
  border-radius: 999px;
  transform: translateY(-50%);
}

.classic-progress-rail {
  width: 100%;
  background: rgba(255, 255, 255, .14);
  box-shadow: inset 0 1px rgba(255, 255, 255, .08);
}

.classic-progress-fill {
  width: 0%;
  background: linear-gradient(90deg, rgba(255, 255, 255, .88), rgb(var(--pulse-cover-secondary-rgb, 142, 255, 176)));
  box-shadow: 0 0 16px rgba(var(--pulse-cover-primary-rgb, 142, 255, 176), .28);
}

.classic-progress-thumb {
  position: absolute;
  top: 50%;
  left: 0%;
  width: 9px;
  height: 9px;
  border: 2px solid rgba(7, 12, 10, .84);
  border-radius: 50%;
  background: #f5fff8;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .28), 0 0 18px rgba(var(--pulse-cover-secondary-rgb, 142, 255, 176), .44);
  opacity: .76;
  transform: translate(-50%, -50%) scale(.82);
  transition: opacity .18s ease, transform .18s ease;
}

.classic-progress-bar:hover .classic-progress-thumb,
.classic-progress-bar.is-dragging .classic-progress-thumb,
.classic-progress-bar:focus-visible .classic-progress-thumb {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.classic-progress-bar:focus-visible .classic-progress-rail {
  box-shadow: 0 0 0 2px rgba(var(--pulse-cover-secondary-rgb, 142, 255, 176), .25);
}

.classic-progress-bar[aria-disabled="true"] {
  cursor: default;
  opacity: .46;
}

.classic-hero-caption {
  max-width: 360px;
  margin: 18px 0 0;
  color: rgba(255, 255, 255, .45);
  font: 500 13px/1.65 var(--font-sans);
}

.classic-hero-actions {
  display: flex;
  gap: 8px;
  margin-top: 26px;
}

.classic-primary-btn,
.classic-ghost-btn {
  display: inline-flex;
  height: 38px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  border-radius: 3px;
  font: 700 10px/1 var(--font-mono);
  letter-spacing: .1em;
  cursor: pointer;
  transition: transform .2s ease, background-color .2s ease, border-color .2s ease, color .2s ease;
}

.classic-primary-btn {
  border: 1px solid rgba(142, 255, 176, .52);
  background: #9bffb6;
  color: #07110d;
  box-shadow: 0 0 24px rgba(142, 255, 176, .1);
}

.classic-ghost-btn {
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(255, 255, 255, .035);
  color: rgba(255, 255, 255, .7);
}

.classic-primary-btn:hover,
.classic-ghost-btn:hover {
  transform: translateY(-2px);
}

.classic-ghost-btn:hover {
  border-color: rgba(142, 255, 176, .42);
  color: #c8ffd5;
}

.classic-play-mark {
  font-size: 10px;
}

.classic-hero-signal {
  position: absolute;
  z-index: 1;
  top: 34px;
  right: 34px;
  display: flex;
  width: min(44%, 240px);
  height: 120px;
  align-items: center;
  justify-content: space-between;
  opacity: .62;
}

.classic-hero-signal span {
  width: 1px;
  height: calc(18px + var(--signal-height, 20px));
  background: linear-gradient(to bottom, transparent, rgba(142, 255, 176, .9), transparent);
  animation: classic-signal 1.6s ease-in-out infinite alternate;
}

.classic-hero-signal span:nth-child(2n) { animation-delay: -.46s; --signal-height: 38px; }
.classic-hero-signal span:nth-child(3n) { animation-delay: -.82s; --signal-height: 64px; }
.classic-hero-signal span:nth-child(4n) { animation-delay: -.18s; --signal-height: 26px; }

@keyframes classic-signal {
  from { transform: scaleY(.4); opacity: .28; }
  to { transform: scaleY(1); opacity: .9; }
}

body[data-app-mode="classic"]:not(.soundstage-locked) .classic-header {
  animation: classic-enter-header .72s cubic-bezier(.16, 1, .3, 1) both;
}

body[data-app-mode="classic"]:not(.soundstage-locked) .classic-nav {
  animation: classic-enter-header .72s cubic-bezier(.16, 1, .3, 1) .06s both;
}

body[data-app-mode="classic"]:not(.soundstage-locked) .classic-hero-copy {
  animation: classic-enter-copy .86s cubic-bezier(.16, 1, .3, 1) .08s both;
}

body[data-app-mode="classic"]:not(.soundstage-locked) .classic-library,
body[data-app-mode="classic"]:not(.soundstage-locked) .classic-now-card {
  animation: classic-enter-panel .78s cubic-bezier(.16, 1, .3, 1) .18s both;
}

@keyframes classic-enter-header {
  from { opacity: 0; transform: translateY(-18px); filter: blur(8px); }
  to { opacity: 1; transform: translateY(0); filter: blur(0); }
}

@keyframes classic-enter-copy {
  from { opacity: 0; transform: translate3d(-28px, 18px, 0) scale(.96); filter: blur(10px); }
  72% { opacity: 1; transform: translate3d(4px, -2px, 0) scale(1.01); filter: blur(0); }
  to { opacity: 1; transform: none; filter: blur(0); }
}

@keyframes classic-enter-disc {
  from { opacity: 0; transform: translate3d(42px, 18px, 0) scale(.72) rotate(-18deg); filter: blur(12px); }
  70% { opacity: 1; transform: translate3d(-4px, -2px, 0) scale(1.03) rotate(2deg); filter: blur(0); }
  to { opacity: 1; transform: none; filter: blur(0); }
}

@keyframes classic-enter-panel {
  from { opacity: 0; transform: translateY(24px); filter: blur(8px); }
  to { opacity: 1; transform: none; filter: blur(0); }
}

.classic-library {
  min-height: 430px;
  padding: 24px 22px 18px;
}

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

.classic-section-head h2 {
  margin: 8px 0 0;
  color: rgba(255, 255, 255, .92);
  font: 650 22px/1 var(--font-sans);
  letter-spacing: -.04em;
}

.classic-section-head > span {
  color: rgba(255, 255, 255, .32);
  font: 600 9px/1 var(--font-mono);
  letter-spacing: .1em;
}

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

.classic-track-item {
  display: grid;
  grid-template-columns: 34px 42px minmax(0, 1fr) auto;
  min-width: 0;
  align-items: center;
  gap: 11px;
  padding: 8px 9px;
  border: 1px solid transparent;
  border-radius: 4px;
  background: rgba(255, 255, 255, .018);
  color: rgba(255, 255, 255, .68);
  text-align: left;
  cursor: pointer;
  transition: border-color .18s ease, background-color .18s ease, transform .18s ease;
}

.classic-track-item:hover {
  border-color: rgba(142, 255, 176, .22);
  background: rgba(142, 255, 176, .06);
  transform: translateX(2px);
}

.classic-track-item.selected {
  border-color: rgba(142, 255, 176, .34);
  background: linear-gradient(90deg, rgba(142, 255, 176, .1), rgba(255, 191, 105, .035));
  color: #f5fff7;
}

.classic-track-number {
  color: rgba(255, 255, 255, .24);
  font: 600 10px/1 var(--font-mono);
  text-align: center;
}

.classic-track-item.selected .classic-track-number {
  color: #9bffb6;
}

.classic-track-cover-wrap {
  display: block;
  width: 42px;
  height: 42px;
  border-radius: 3px;
  background: var(--track-cover-tint, linear-gradient(135deg, rgba(142, 255, 176, .22), rgba(255, 191, 105, .08)));
  box-shadow: inset 0 0 0 1px var(--track-cover-glow, rgba(255, 255, 255, .18)), 0 0 14px rgba(0, 0, 0, .22);
  overflow: hidden;
}

.classic-track-cover {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: cover;
  filter: brightness(1.42) saturate(1.4) contrast(1.08);
  mix-blend-mode: screen;
  opacity: .88;
}

.classic-track-copy {
  min-width: 0;
}

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

.classic-track-title {
  color: inherit;
  font: 650 12px/1.25 var(--font-sans);
}

.classic-track-artist {
  margin-top: 5px;
  color: rgba(255, 255, 255, .38);
  font: 500 10px/1.2 var(--font-mono);
}

.classic-track-duration {
  color: rgba(255, 255, 255, .32);
  font: 600 9px/1 var(--font-mono);
}

.classic-now-card {
  display: flex;
  min-height: 430px;
  flex-direction: column;
  padding: 18px;
}

.classic-now-cover-wrap {
  position: relative;
}

.classic-now-cover {
  width: 100%;
  aspect-ratio: 1;
  border-radius: 4px;
  background: radial-gradient(circle at 34% 28%, rgba(142, 255, 176, .24), transparent 38%), linear-gradient(135deg, #192b29, #111518 64%, #2b2118);
  background-position: center;
  background-size: cover;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .1), 0 18px 40px rgba(0, 0, 0, .32);
}

.classic-now-index {
  position: absolute;
  top: 9px;
  left: 9px;
  padding: 5px 7px;
  border: 1px solid rgba(255, 255, 255, .18);
  background: rgba(6, 9, 10, .5);
  color: rgba(255, 255, 255, .68);
  font: 700 8px/1 var(--font-mono);
  letter-spacing: .12em;
}

.classic-now-copy {
  margin-top: 18px;
}

.classic-now-copy h2 {
  margin: 9px 0 4px;
  overflow: hidden;
  color: rgba(255, 255, 255, .92);
  font: 650 20px/1.05 var(--font-sans);
  letter-spacing: -.04em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.classic-now-copy > p:last-child {
  margin: 0;
  overflow: hidden;
  color: rgba(255, 255, 255, .42);
  font: 550 10px/1.3 var(--font-mono);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.classic-now-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 18px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  color: rgba(255, 255, 255, .36);
  font: 600 9px/1 var(--font-mono);
  letter-spacing: .06em;
}

.classic-now-meta span:first-child {
  color: #9bffb6;
}

.classic-queue-preview {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 24px;
}

.classic-queue-preview strong {
  display: block;
  max-width: 170px;
  margin-top: 8px;
  overflow: hidden;
  color: rgba(255, 255, 255, .68);
  font: 600 11px/1.35 var(--font-sans);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.classic-queue-preview button {
  border: 0;
  background: transparent;
  color: #9bffb6;
  font: 700 9px/1 var(--font-mono);
  letter-spacing: .1em;
  cursor: pointer;
}

@media (max-width: 1180px) {
  #classic-home {
    padding-right: 24px;
    padding-left: 24px;
  }

  .classic-main {
    grid-template-columns: minmax(0, 1.05fr) minmax(300px, .95fr);
  }

  .classic-now-card {
    grid-column: 1 / -1;
    min-height: 0;
    display: grid;
    grid-template-columns: 132px minmax(0, 1fr) minmax(180px, .7fr);
    align-items: center;
    gap: 18px;
  }

  .classic-now-copy {
    margin-top: 0;
  }

  .classic-now-meta {
    margin-top: 0;
  }

  .classic-queue-preview {
    grid-column: 2 / -1;
    margin-top: 0;
    padding-top: 0;
  }

  .classic-now-cover-wrap {
    grid-row: 1 / 3;
  }
}

@media (min-width: 721px) and (max-width: 960px) {
  :root {
    --studio-safe-left: clamp(34px, 5vw, 48px);
    --studio-safe-right: clamp(240px, 30vw, 300px);
  }

  #studio-track-spotlight {
    bottom: clamp(150px, 18vh, 196px);
  }

  #studio-spotlight-title {
    font-size: clamp(30px, 4.6vw, 42px);
  }
}

@media (max-width: 720px) {
  #studio-track-spotlight {
    display: none;
  }

  #view-mode-btn {
    min-width: 40px;
    width: 40px;
    padding: 0;
  }

  #view-mode-label {
    display: none;
  }

  #classic-home {
    z-index: 860;
    padding: 20px 14px 36px;
  }

  .classic-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 14px;
    padding-top: 24px;
  }

  .classic-header-actions {
    width: 100%;
    justify-content: space-between;
  }

  .classic-header h1 {
    font-size: 34px;
  }

  .classic-nav {
    overflow-x: auto;
    padding-bottom: 12px;
  }

  .classic-nav-note,
  .classic-nav-rule {
    display: none;
  }

  .classic-main {
    display: block;
  }

  .classic-hero {
    grid-template-columns: 1fr;
    min-height: 520px;
    padding: 24px;
  }

  .classic-turntable-stage {
    grid-column: 1;
    grid-row: 1;
    justify-self: center;
    width: 190px;
    opacity: .86;
    translate: 0;
  }

  .classic-hero-copy {
    grid-column: 1;
    grid-row: 2;
    max-width: 100%;
    align-self: end;
  }

  .classic-hero-signal {
    top: 20px;
    right: 24px;
    width: 45%;
    height: 76px;
  }

  .classic-library {
    min-height: 0;
    margin-top: 10px;
    padding: 18px 12px 12px;
  }

  .classic-now-card {
    display: none;
  }

  .classic-track-item {
    grid-template-columns: 26px 38px minmax(0, 1fr) auto;
  }

  .classic-track-cover-wrap {
    width: 38px;
    height: 38px;
  }
}

@media (prefers-reduced-motion: reduce) {
  #classic-home,
  #classic-home * {
    animation: none !important;
    transition-duration: .01ms !important;
  }
}

/* Final visual-console pass: an instrument panel with a calmer type scale,
   consistent rhythm, and controls that read as one system. */
#fx-panel {
  box-sizing: border-box;
  width: min(472px, calc(100vw - 36px));
  top: 18px;
  bottom: 88px;
  padding: 0 22px 28px;
  border: 1px solid rgba(255, 255, 255, .14) !important;
  border-radius: 18px;
  background:
    linear-gradient(155deg, rgba(26, 39, 43, .88), rgba(5, 8, 11, .94) 56%),
    rgba(5, 6, 8, .94) !important;
  box-shadow: 0 28px 90px rgba(0, 0, 0, .62), 0 0 0 1px rgba(var(--fc-accent-rgb), .05), inset 0 1px 0 rgba(255, 255, 255, .09) !important;
  -webkit-backdrop-filter: blur(24px) saturate(1.2);
  backdrop-filter: blur(24px) saturate(1.2);
  scrollbar-color: rgba(var(--fc-accent-rgb), .42) transparent;
  scrollbar-width: thin;
}

#fx-panel.show {
  right: 18px;
}

.pulse-settings-head {
  min-height: 82px;
  margin: 0 -22px;
  padding: 0 22px;
  border-bottom-color: rgba(255, 255, 255, .10);
  background: linear-gradient(180deg, rgba(18, 28, 31, .92), rgba(7, 10, 12, .86));
}

.pulse-settings-head .fx-title {
  color: #f5faf7;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 720;
  letter-spacing: -.02em;
}

.pulse-settings-head .fx-sub {
  margin-top: 7px;
  color: rgba(229, 244, 236, .48);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: .12em;
}

.pulse-settings-icon-btn {
  width: 38px;
  height: 38px;
  flex-basis: 38px;
  border-color: rgba(255, 255, 255, .14);
  border-radius: 11px;
  background: rgba(255, 255, 255, .06);
  transition: border-color .2s ease, background-color .2s ease, transform .2s ease;
}

.pulse-settings-icon-btn:hover,
.pulse-settings-icon-btn:focus-visible {
  transform: translateY(-1px);
}

.pulse-settings-tabs {
  top: 82px;
  gap: 6px;
  margin: 0 -22px;
  padding: 10px 22px;
  border-bottom-color: rgba(255, 255, 255, .08);
  background: rgba(7, 11, 13, .88);
}

.pulse-settings-tabs button {
  position: relative;
  height: 38px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: rgba(235, 247, 240, .52);
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0;
  transition: color .2s ease, background-color .2s ease, border-color .2s ease;
}

.pulse-settings-tabs button.active {
  border-color: rgba(var(--fc-accent-rgb), .25);
  color: #f8fff9;
  background: rgba(var(--fc-accent-rgb), .13);
}

.pulse-settings-tabs button.active::after {
  position: absolute;
  right: 22%;
  bottom: -11px;
  left: 22%;
  height: 2px;
  border-radius: 2px;
  background: var(--fc-accent);
  box-shadow: 0 0 12px rgba(var(--fc-accent-rgb), .55);
  content: "";
}

.pulse-settings-group {
  padding: 26px 0 28px;
  border-bottom-color: rgba(255, 255, 255, .10);
}

.pulse-settings-group-head {
  align-items: center;
  margin-bottom: 18px;
}

#fx-panel .pulse-settings-group-head strong {
  color: rgba(248, 253, 250, .92);
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 720;
  letter-spacing: -.015em;
}

#fx-panel .pulse-settings-group-head span {
  color: rgba(var(--fc-accent-rgb), .74);
  font-family: var(--font-mono);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  letter-spacing: .08em;
}

#fx-panel .preset-grid {
  gap: 10px;
}

#fx-panel .preset-card {
  min-height: 86px;
  padding: 13px 12px;
  border-color: rgba(255, 255, 255, .12);
  border-radius: 12px;
  background: linear-gradient(145deg, rgba(255, 255, 255, .065), rgba(255, 255, 255, .018));
  grid-template-columns: minmax(0, 1fr) 30px;
  grid-template-rows: auto auto;
  transition: border-color .2s ease, background-color .2s ease, transform .2s ease, box-shadow .2s ease;
}

#fx-panel .preset-card:hover,
#fx-panel .preset-card:focus-visible,
#fx-panel .preset-card.active {
  border-color: rgba(var(--fc-accent-rgb), .52);
  background: linear-gradient(145deg, rgba(var(--fc-accent-rgb), .17), rgba(var(--fc-accent-rgb), .045));
  box-shadow: 0 10px 24px rgba(0, 0, 0, .18);
  transform: translateY(-1px);
}

#fx-panel .preset-card .pc-icon {
  display: grid;
  width: 30px;
  height: 30px;
  grid-column: 2;
  grid-row: 1 / 3;
  place-items: center;
  border: 1px solid rgba(var(--fc-accent-rgb), .25);
  border-radius: 9px;
  color: var(--fc-accent);
  background: rgba(var(--fc-accent-rgb), .08);
}

#fx-panel .preset-card .pc-name,
#fx-panel .preset-card .pc-desc {
  grid-column: 1;
}

#fx-panel .preset-card .pc-name {
  color: rgba(250, 255, 252, .94);
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  overflow: visible;
  text-overflow: clip;
}

#fx-panel .preset-card .pc-desc {
  margin-top: 6px;
  color: rgba(231, 245, 237, .48);
  font-size: 11px;
  line-height: 1.4;
}

.pulse-color-grid {
  gap: 10px;
}

.pulse-color-control {
  gap: 9px;
  padding: 12px;
  border-color: rgba(255, 255, 255, .11);
  border-radius: 12px;
  background: rgba(255, 255, 255, .03);
  font-size: 11px;
}

.pulse-color-control input[type=color] {
  height: 34px;
  border-radius: 8px;
  overflow: hidden;
}

#fx-panel .fx-slider {
  grid-template-columns: 112px minmax(0, 1fr) 58px;
  min-height: 52px;
  border-bottom-color: rgba(255, 255, 255, .075);
}

#fx-panel .fx-slider label {
  color: rgba(237, 248, 241, .70);
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 550;
  line-height: 1.35;
}

#fx-panel .fx-slider output {
  color: rgba(var(--fc-accent-rgb), .86);
  font-family: var(--font-mono);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
}

#fx-panel input[type=range] {
  width: 100%;
  height: 28px;
  margin: 0;
  appearance: none;
  background: transparent;
  cursor: pointer;
}

#fx-panel input[type=range]::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 4px;
  background: linear-gradient(90deg, rgba(var(--fc-accent-rgb), .78), rgba(var(--fc-accent-rgb), .18));
}

#fx-panel input[type=range]::-webkit-slider-thumb {
  width: 15px;
  height: 15px;
  margin-top: -5.5px;
  appearance: none;
  border: 2px solid rgba(5, 9, 10, .92);
  border-radius: 50%;
  background: var(--fc-accent);
  box-shadow: 0 0 0 3px rgba(var(--fc-accent-rgb), .16), 0 0 12px rgba(var(--fc-accent-rgb), .55);
}

#fx-panel input[type=range]::-moz-range-track {
  height: 4px;
  border-radius: 4px;
  background: rgba(var(--fc-accent-rgb), .22);
}

#fx-panel input[type=range]::-moz-range-progress {
  height: 4px;
  border-radius: 4px;
  background: rgba(var(--fc-accent-rgb), .78);
}

#fx-panel input[type=range]::-moz-range-thumb {
  width: 11px;
  height: 11px;
  border: 2px solid rgba(5, 9, 10, .92);
  border-radius: 50%;
  background: var(--fc-accent);
  box-shadow: 0 0 0 3px rgba(var(--fc-accent-rgb), .16), 0 0 12px rgba(var(--fc-accent-rgb), .55);
}

@media (prefers-reduced-motion: reduce) {
  body.studio-entry-active #canvas-container,
  body.studio-entry-active #canvas-container::before,
  body.studio-entry-active #canvas-container::after,
  body.studio-entry-active #bottom-bar,
  body.studio-entry-active #top-right,
  body.studio-entry-active #studio-track-spotlight {
    animation: none !important;
    filter: none !important;
    transform: none !important;
  }
}

#fx-panel .pulse-settings-seg {
  gap: 3px;
  padding: 3px;
  border-color: rgba(255, 255, 255, .13);
  border-radius: 11px;
  background: rgba(0, 0, 0, .16);
}

#fx-panel .pulse-settings-seg button {
  min-height: 38px;
  border: 0;
  border-radius: 8px;
  color: rgba(235, 247, 240, .58);
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0;
  transition: color .2s ease, background-color .2s ease, box-shadow .2s ease;
}

#fx-panel .pulse-settings-seg button:hover,
#fx-panel .pulse-settings-seg button:focus-visible,
#fx-panel .pulse-settings-seg button.active {
  color: #f8fff9;
  background: rgba(var(--fc-accent-rgb), .17);
  box-shadow: inset 0 0 0 1px rgba(var(--fc-accent-rgb), .20);
}

.pulse-settings-hint {
  margin-top: -3px;
  color: rgba(231, 245, 237, .52);
  font-size: 12px;
  line-height: 1.65;
}

.pulse-settings-control-label {
  margin-top: 17px;
  color: rgba(235, 248, 239, .70);
  font-size: 11px;
  font-weight: 650;
}

#fx-panel .fx-toggle {
  min-height: 44px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 11px;
  background: rgba(255, 255, 255, .035);
  font-family: var(--font-sans);
  font-size: 12px;
  transition: border-color .2s ease, background-color .2s ease, transform .2s ease;
}

#fx-panel .fx-toggle:hover,
#fx-panel .fx-toggle:focus-visible {
  transform: translateY(-1px);
}

.pulse-immersive-command {
  min-height: 68px;
  padding: 0 18px;
  border-radius: 13px;
  background: linear-gradient(135deg, rgba(var(--fc-accent-rgb), .16), rgba(var(--fc-accent-rgb), .04));
  font-family: var(--font-sans);
  font-size: 12px;
  letter-spacing: 0;
}

.pulse-settings-reset .fx-mini-btn {
  min-height: 44px;
  border-radius: 11px;
  font-family: var(--font-sans);
  font-size: 12px;
  letter-spacing: 0;
}

@media (max-width: 720px) {
  #fx-panel {
    width: calc(100vw - 20px);
    right: -100vw;
    left: 10px;
    border-radius: 16px;
  }

  #fx-panel.show {
    right: 10px;
  }

  #fx-panel .fx-slider {
    grid-template-columns: 96px minmax(0, 1fr) 52px;
  }
}
