/* ==========================================================================
   Sonamp — Theme Studio
   Layered on styles.css. Two halves: the Studio's own chrome (uses the site's
   tokens) and the app preview (uses the style being designed, via --t-* vars).
   ========================================================================== */

body.studio .aurora { opacity: .32; height: 80vh; }

/* --------------------------------------------------------------------------
   1. Page head
   -------------------------------------------------------------------------- */

.studio-head { padding-top: clamp(1.5rem, 3vw, 2.5rem); padding-bottom: var(--sp-4); }
.studio-head h1 { font-size: var(--step-4); letter-spacing: -.035em; margin-top: var(--sp-3); max-width: 18ch; }
.studio-head h1 em { font-style: italic; background: var(--grad-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
.studio-head > p { color: var(--ink-muted); font-size: var(--step-0); max-width: 74ch; margin-top: var(--sp-3); }

.studio-how { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; margin-top: var(--sp-4);
  border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: var(--line-faint); }
.studio-how div { background: var(--surface-1); padding: var(--sp-3) var(--sp-4); display: grid; grid-template-columns: auto 1fr; gap: .2rem .9rem; align-items: start; }
.studio-how i { grid-row: span 2; font-style: normal; font-family: var(--font-mono); font-size: var(--step--2); color: var(--blue);
  width: 28px; height: 28px; display: grid; place-items: center; border: 1px solid var(--line-strong); border-radius: 50%; }
.studio-how b { font-weight: 600; font-size: var(--step-0); }
.studio-how span { font-size: var(--step--1); color: var(--ink-muted); }
@media (max-width: 820px) { .studio-how { grid-template-columns: 1fr; } }

/* --------------------------------------------------------------------------
   2. Workbench
   -------------------------------------------------------------------------- */

.studio-app {
  width: min(100% - 2rem, 1500px); margin-inline: auto; position: relative; z-index: 2;
  display: grid; grid-template-columns: 232px minmax(0, 1fr) 372px; gap: clamp(1rem, 2vw, 2rem);
  align-items: start; padding-bottom: var(--sp-6);
}

/* Rail -------------------------------------------------------------------- */
.st-rail { position: sticky; top: 76px; max-height: calc(100vh - 92px); overflow-y: auto; scrollbar-width: thin; padding-right: .3rem; }
.st-rail h4 { font-family: var(--font-mono); font-size: .62rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--ink-faint); font-weight: 500; margin: 1.1rem 0 .4rem .7rem; }
.st-rail h4:first-child { margin-top: 0; }
.st-rail button {
  display: flex; align-items: center; gap: .6rem; width: 100%; text-align: left; cursor: pointer;
  padding: .46rem .7rem; border: 0; border-left: 2px solid transparent; border-radius: 8px; background: none;
  font-size: var(--step--1); color: var(--ink-muted); transition: color .2s, background .2s;
}
.st-rail button:hover { color: var(--ink); background: var(--surface-glass); }
.st-rail button.on { color: var(--ink); background: var(--accent-soft); border-left-color: var(--blue); font-weight: 550; }
.st-rail button small { margin-left: auto; font-family: var(--font-mono); font-size: .6rem; color: var(--blue); }

/* Panel ------------------------------------------------------------------- */
.st-panel { min-width: 0; }
.st-panel-head { margin-bottom: var(--sp-4); }
.st-panel-head small { font-family: var(--font-mono); font-size: var(--step--2); letter-spacing: .14em; text-transform: uppercase; color: var(--blue); }
.st-panel-head h2 { font-size: var(--step-3); margin-top: .4rem; }
.st-panel-head p { color: var(--ink-muted); margin-top: .5rem; max-width: 64ch; }

.st-card { border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface-1); margin-bottom: var(--sp-3); overflow: hidden; }
.st-card > header { padding: 1rem 1.2rem .2rem; }
.st-card > header h3 { font-size: var(--step-1); }
.st-card > header p { font-size: var(--step--1); color: var(--ink-muted); margin-top: .25rem; max-width: 66ch; }
.st-card-body { padding: .6rem 1.2rem 1.1rem; display: grid; gap: 1.05rem; }

.st-field { display: grid; gap: .45rem; min-width: 0; }
.st-field > label, .st-label { font-size: var(--step--1); font-weight: 550; color: var(--ink); display: flex; align-items: baseline; gap: .6rem; flex-wrap: wrap; }
.st-label code, .st-field > label code { font-family: var(--font-mono); font-size: .62rem; color: var(--ink-faint); font-weight: 400; margin-left: auto; }
.st-help { font-size: var(--step--2); color: var(--ink-muted); line-height: 1.5; max-width: 70ch; }
.st-field.off { opacity: .45; }
.st-field.off .st-seg, .st-field.off .st-switch { pointer-events: none; }
.st-why { font-size: var(--step--2); color: var(--amber); }

/* Segmented choice */
.st-seg { display: flex; flex-wrap: wrap; gap: .35rem; }
.st-seg button {
  border: 1px solid var(--line); background: var(--surface-glass); color: var(--ink-soft);
  border-radius: var(--r-pill); padding: .42rem .85rem; font-size: var(--step--1); cursor: pointer;
  transition: border-color .2s, background .2s, color .2s, transform .2s var(--ease);
}
.st-seg button:hover { border-color: var(--line-strong); color: var(--ink); }
.st-seg button.on { border-color: color-mix(in srgb, var(--blue) 60%, transparent); background: var(--accent-soft); color: var(--ink); font-weight: 550; }
.st-seg-note { font-size: var(--step--2); color: var(--ink-muted); min-height: 1.2em; }

/* Switch */
.st-switch { display: grid; grid-template-columns: 1fr auto; gap: .2rem 1rem; align-items: center; cursor: pointer; }
.st-switch b { font-size: var(--step--1); font-weight: 550; }
.st-switch span { grid-column: 1; font-size: var(--step--2); color: var(--ink-muted); line-height: 1.5; }
.st-switch i { grid-row: 1 / span 2; grid-column: 2; width: 42px; height: 25px; border-radius: 999px; background: var(--line-strong); position: relative; transition: background .25s; }
.st-switch i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 19px; height: 19px; border-radius: 50%; background: #fff; transition: transform .25s var(--ease); box-shadow: 0 1px 3px rgba(0,0,0,.35); }
.st-switch input { position: absolute; opacity: 0; pointer-events: none; }
.st-switch input:checked + i { background: var(--mint); }
.st-switch input:checked + i::after { transform: translateX(17px); }
.st-switch input:focus-visible + i { outline: 2px solid var(--blue); outline-offset: 3px; }

/* Select / text / range */
.st-select, .st-text {
  width: 100%; border: 1px solid var(--line); background: var(--surface-glass); color: var(--ink);
  border-radius: var(--r-sm); padding: .55rem .75rem; font: inherit; font-size: var(--step--1);
}
.st-select:focus, .st-text:focus { outline: none; border-color: color-mix(in srgb, var(--blue) 60%, transparent); }
.st-range { display: grid; grid-template-columns: 1fr auto; gap: .8rem; align-items: center; }
.st-range input { width: 100%; accent-color: var(--blue); }
.st-range output { font-family: var(--font-mono); font-size: var(--step--2); color: var(--ink-soft); min-width: 4.5ch; text-align: right; }
.st-two { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 620px) { .st-two { grid-template-columns: 1fr; } }

/* Colour well */
.st-color { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.st-well { position: relative; width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line-strong); overflow: hidden; flex: none;
  background-image: linear-gradient(45deg, #8884 25%, transparent 25% 75%, #8884 75%), linear-gradient(45deg, #8884 25%, transparent 25% 75%, #8884 75%);
  background-size: 10px 10px; background-position: 0 0, 5px 5px; }
.st-well u { position: absolute; inset: 0; }
.st-well input { position: absolute; inset: -6px; width: calc(100% + 12px); height: calc(100% + 12px); opacity: 0; cursor: pointer; }
.st-color .st-text { width: 9.5ch; font-family: var(--font-mono); text-transform: uppercase; padding-inline: .6rem; }
.st-alpha { display: flex; align-items: center; gap: .4rem; font-family: var(--font-mono); font-size: var(--step--2); color: var(--ink-muted); }
.st-alpha input { width: 84px; accent-color: var(--blue); }
.st-swatches { display: flex; gap: .3rem; flex-wrap: wrap; }
.st-swatches button { width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--line-strong); cursor: pointer; padding: 0; transition: transform .2s var(--ease); }
.st-swatches button:hover { transform: scale(1.15); }
.st-linkbtn { background: none; border: 0; padding: 0; color: var(--blue); font-size: var(--step--2); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }

.st-roles { display: grid; gap: .1rem; }
.st-role { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .4rem 1rem; align-items: center; padding: .6rem 0; border-top: 1px solid var(--line-faint); }
.st-role:first-child { border-top: 0; }
.st-role b { font-size: var(--step--1); font-weight: 550; display: block; }
.st-role small { font-size: var(--step--2); color: var(--ink-muted); }

/* Preset gallery */
.st-presets { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: .7rem; }
.st-preset { border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface-glass); cursor: pointer; text-align: left; padding: 0; overflow: hidden;
  transition: transform .3s var(--ease), border-color .25s, box-shadow .3s; display: flex; flex-direction: column; }
.st-preset:hover { transform: translateY(-3px); border-color: var(--line-strong); box-shadow: var(--shadow-md); }
.st-preset.on { border-color: var(--blue); box-shadow: 0 0 0 1px var(--blue); }
.st-preset-shot { aspect-ratio: 402 / 500; overflow: hidden; position: relative; border-bottom: 1px solid var(--line-faint); }
.st-preset-shot > .pv { position: absolute; top: 0; left: 0; transform-origin: top left; }
.st-preset b { display: block; padding: .65rem .8rem 0; font-size: var(--step--1); font-weight: 600; }
.st-preset span { display: block; padding: .15rem .8rem .8rem; font-size: var(--step--2); color: var(--ink-muted); line-height: 1.45; }

/* Row arranger */
.st-rows { display: grid; gap: .4rem; }
.st-row { border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface-glass); }
.st-row.hidden-row { opacity: .55; }
.st-row-top { display: flex; align-items: center; gap: .5rem; padding: .5rem .6rem; }
.st-row-top b { font-size: var(--step--1); font-weight: 550; }
.st-row-top small { font-size: var(--step--2); color: var(--ink-muted); display: block; }
.st-row-top .grow { flex: 1; min-width: 0; }
.st-iconbtn { width: 30px; height: 30px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface-glass); color: var(--ink-soft);
  display: grid; place-items: center; cursor: pointer; flex: none; font-size: .8rem; transition: background .2s, color .2s; }
.st-iconbtn:hover:not(:disabled) { background: var(--surface-glass-strong); color: var(--ink); }
.st-iconbtn:disabled { opacity: .3; cursor: default; }
.st-iconbtn.on { background: var(--accent-soft); color: var(--ink); border-color: color-mix(in srgb, var(--blue) 50%, transparent); }
.st-row-opts { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; padding: .1rem .6rem .6rem 3.1rem; font-size: var(--step--2); color: var(--ink-muted); }
.st-row-opts label { display: inline-flex; align-items: center; gap: .35rem; }
.st-row-opts select, .st-row-opts input[type="number"] { border: 1px solid var(--line); background: var(--surface-1); color: var(--ink); border-radius: 7px; padding: .2rem .35rem; font: inherit; font-size: var(--step--2); }
.st-row-opts input[type="number"] { width: 4.6ch; }
.st-grip { cursor: grab; color: var(--ink-faint); padding: 0 .1rem; user-select: none; font-size: 1rem; line-height: 1; }
.st-row.dragging { opacity: .4; }
.st-row.drop-above { box-shadow: 0 -2px 0 var(--blue); }

/* Icon chips */
.st-chips { display: flex; flex-wrap: wrap; gap: .35rem; }
.st-chips .st-chip { display: inline-flex; align-items: center; gap: .3rem; border: 1px solid var(--line); border-radius: var(--r-pill); padding: .15rem .2rem .15rem .7rem; font-size: var(--step--1); background: var(--surface-glass); color: var(--ink-muted); }
.st-chips .st-chip.on { color: var(--ink); background: var(--accent-soft); border-color: color-mix(in srgb, var(--blue) 45%, transparent); }
.st-chips .st-chip button { border: 0; background: none; color: inherit; cursor: pointer; width: 24px; height: 24px; border-radius: 50%; }
.st-chips .st-chip button:hover:not(:disabled) { background: var(--surface-glass-strong); }
.st-chips .st-chip button:disabled { opacity: .25; cursor: default; }
.st-chips .st-chip .name { cursor: pointer; background: none; border: 0; color: inherit; font: inherit; padding: 0 .2rem 0 0; width: auto; height: auto; border-radius: 0; }

/* Stage ------------------------------------------------------------------- */
.st-stage { position: sticky; top: 76px; display: grid; gap: .8rem; justify-items: center; }
.st-tabs { display: inline-flex; padding: 3px; border: 1px solid var(--line); border-radius: var(--r-pill); background: var(--surface-glass); }
.st-tabs button { border: 0; background: none; color: var(--ink-muted); padding: .38rem .85rem; border-radius: var(--r-pill); font-size: var(--step--2); cursor: pointer; font-weight: 550; }
.st-tabs button.on { background: var(--ink); color: var(--bg); }

.st-device {
  --s: .82; width: calc(402px * var(--s) + 18px); height: calc(874px * var(--s) + 18px);
  border-radius: calc(58px * var(--s) + 9px); padding: 9px; position: relative; flex: none;
  background: linear-gradient(160deg, #3b3d47, #101117 45%, #2a2b33); box-shadow: var(--shadow-lg), inset 0 0 0 1px rgba(255,255,255,.14);
}
.st-device::after { content: ""; position: absolute; left: 50%; top: calc(9px + 11px * var(--s)); transform: translateX(-50%);
  width: calc(124px * var(--s)); height: calc(36px * var(--s)); border-radius: 999px; background: #000; z-index: 5; pointer-events: none; }
.st-screen { width: 100%; height: 100%; border-radius: calc(58px * var(--s)); overflow: hidden; position: relative; background: #000; }
.st-screen > .pv { transform: scale(var(--s)); transform-origin: top left; }

.st-covers { display: flex; gap: .4rem; align-items: center; font-size: var(--step--2); color: var(--ink-muted); }
.st-covers button { width: 26px; height: 26px; border-radius: 7px; border: 1px solid var(--line-strong); background-size: cover; cursor: pointer; padding: 0; }
.st-covers button.on { outline: 2px solid var(--blue); outline-offset: 2px; }
.st-note { font-size: var(--step--2); color: var(--ink-faint); text-align: center; max-width: 36ch; line-height: 1.5; }

.st-checks { width: 100%; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface-1); padding: .7rem .9rem; display: grid; gap: .35rem; }
.st-checks h4 { font-family: var(--font-mono); font-size: .62rem; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-faint); font-weight: 500; }
.st-check { display: grid; grid-template-columns: 14px 1fr auto; gap: .5rem; align-items: center; font-size: var(--step--2); color: var(--ink-soft); }
.st-check i { width: 8px; height: 8px; border-radius: 50%; background: var(--mint); }
.st-check.bad i { background: var(--amber); }
.st-check b { font-family: var(--font-mono); font-weight: 500; color: var(--ink-muted); }
.st-check.bad b { color: var(--amber); }

/* Export ------------------------------------------------------------------ */
.st-export { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: .8rem; }
.st-file { border: 1px solid var(--line); border-radius: var(--r-md); padding: 1rem 1.1rem; background: var(--surface-glass); display: grid; gap: .6rem; align-content: start; }
.st-file small { font-family: var(--font-mono); font-size: var(--step--2); letter-spacing: .12em; text-transform: uppercase; color: var(--blue); }
.st-file b { font-size: var(--step-1); font-weight: 600; }
.st-file p { font-size: var(--step--1); color: var(--ink-muted); }
.st-file code { font-family: var(--font-mono); font-size: var(--step--2); color: var(--ink-soft); word-break: break-all; }
.st-file .btns { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .2rem; }
.st-json { margin: 0; max-height: 420px; overflow: auto; font-family: var(--font-mono); font-size: .74rem; line-height: 1.55;
  background: var(--bg-deep); border: 1px solid var(--line-faint); border-radius: var(--r-sm); padding: .9rem 1rem; color: var(--ink-soft); white-space: pre; scrollbar-width: thin; }
.st-json .k { color: var(--blue); } .st-json .s { color: var(--mint); } .st-json .n { color: var(--amber); } .st-json .b { color: var(--violet); }
.st-toast { position: fixed; left: 50%; bottom: 28px; transform: translate(-50%, 20px); opacity: 0; z-index: 300; pointer-events: none;
  background: var(--ink); color: var(--bg); padding: .6rem 1.1rem; border-radius: var(--r-pill); font-size: var(--step--1); font-weight: 550;
  transition: opacity .3s, transform .3s var(--ease); box-shadow: var(--shadow-md); }
.st-toast.show { opacity: 1; transform: translate(-50%, 0); }

.st-actions { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.st-name { display: grid; gap: .6rem; }

/* Responsive -------------------------------------------------------------- */
@media (max-width: 1240px) {
  .studio-app { grid-template-columns: 200px minmax(0, 1fr) 320px; }
  .st-device { --s: .7; }
}
@media (max-width: 1020px) {
  .studio-app { grid-template-columns: minmax(0, 1fr) 300px; }
  .st-rail { position: sticky; top: 62px; z-index: 30; grid-column: 1 / -1; max-height: none; display: flex; gap: .3rem; overflow-x: auto; padding: .5rem 0;
    background: color-mix(in srgb, var(--bg) 92%, transparent); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); scrollbar-width: none; }
  .st-rail h4 { display: none; }
  .st-rail button { width: auto; white-space: nowrap; border-left: 0; border: 1px solid var(--line); border-radius: var(--r-pill); padding: .4rem .8rem; }
  .st-rail button.on { border-color: var(--blue); }
  .st-device { --s: .64; }
  .st-stage { top: 122px; }
}
@media (max-width: 760px) {
  .studio-app { grid-template-columns: 1fr; }
  .st-stage { position: static; order: -1; }
  .st-device { --s: .62; }
  .st-checks { display: none; }
}

/* ==========================================================================
   3. The app preview — a 402 × 874 point canvas
   ========================================================================== */

.pv {
  width: 402px; height: 874px; position: relative; overflow: hidden; display: flex; flex-direction: column;
  background: var(--t-bg); color: var(--t-ink); font-family: var(--f-body); font-weight: var(--w-body);
  letter-spacing: var(--tracking); font-size: calc(15px * var(--ts)); line-height: 1.25; -webkit-font-smoothing: antialiased;
  text-align: left;
}
.pv * { box-sizing: border-box; }
.pv b { font-weight: calc(var(--w-body) + 200); }
.pv small { font-size: calc(12.5px * var(--ts)); color: var(--t-ink2); }
.pv h1, .pv h2, .pv h3 { font-family: var(--f-display); font-weight: var(--w-display); letter-spacing: var(--tracking); margin: 0; line-height: 1.1; }
.pv-ico { display: block; flex: none; }
.pv-icons-outline .pv-ico path[fill="currentColor"] { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linejoin: round; }
.pv-pack-materialSharp .pv-ico path, .pv-pack-pixel .pv-ico path { stroke-linejoin: miter; stroke-linecap: square; }
.pv-cover { background-size: cover; background-position: center; border-radius: var(--r-s); flex: none; width: 100%; }

.pv-status { height: 54px; flex: none; display: flex; align-items: flex-end; gap: 6px; padding: 0 30px 9px 38px; font-family: -apple-system, system-ui, sans-serif; font-size: 16px; position: relative; z-index: 4; letter-spacing: 0; }
.pv-status b { font-weight: 600; }
.pv-status i { flex: 1; }
.pv-sig { display: flex; align-items: flex-end; gap: 2px; height: 12px; }
.pv-sig em { width: 3px; background: currentColor; border-radius: 1px; }
.pv-sig em:nth-child(1) { height: 4px; } .pv-sig em:nth-child(2) { height: 6px; } .pv-sig em:nth-child(3) { height: 9px; } .pv-sig em:nth-child(4) { height: 12px; }
.pv-batt { width: 26px; height: 12px; border-radius: 4px; border: 1px solid currentColor; opacity: .9; padding: 1.5px; }
.pv-batt u { display: block; width: 78%; height: 100%; background: currentColor; border-radius: 2px; }

.pv-wall { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.pv-wall-gradient { background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 22%, transparent), transparent 55%); }
.pv-wall-glow { background: radial-gradient(70% 40% at 50% 0%, color-mix(in srgb, var(--accent) 34%, transparent), transparent 70%); }
.pv-wall-grain { opacity: .5; mix-blend-mode: multiply; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)' opacity='.35'/%3E%3C/svg%3E"); }
.pv-dark .pv-wall-grain { mix-blend-mode: overlay; }

.pv-scroll { flex: 1; min-height: 0; overflow: hidden; padding: 0 20px 150px; position: relative; z-index: 1; display: flex; flex-direction: column; gap: 14px; }
.pv-scroll-flush { padding-inline: 0; gap: 0; }
.pv-nav { display: flex; align-items: center; gap: 10px; padding-top: 6px; }
.pv-nav h1 { font-size: calc(32px * var(--ts)); flex: 1; }
.pv-nav .pv-nav-small { font-size: calc(18px * var(--ts)); text-align: center; }
.pv-nav-over { position: absolute; top: 54px; left: 16px; right: 16px; z-index: 5; }
.pv-nav-over i { flex: 1; }
.pv-orb { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--t-card); box-shadow: inset 0 0 0 1px var(--t-div); }
.pv-nav-over .pv-orb { background: rgba(0,0,0,.35); color: #fff; box-shadow: none; }

.pv-card { background: var(--t-card); border-radius: var(--r-m); }
.pv-card-hairline { box-shadow: inset 0 0 0 1px var(--t-div); }
.pv-card-shadow { box-shadow: 0 6px 18px rgba(0,0,0,.18); }
.pv-links { padding: 4px 14px; }
.pv-link { display: flex; align-items: center; gap: 14px; padding: 11px 0; border-top: 1px solid var(--t-div); }
.pv-link:first-child { border-top: 0; }
.pv-link .pv-ico:first-child { color: var(--accent); }
.pv-link span { flex: 1; font-size: calc(16px * var(--ts)); }
.pv-link .pv-ico:last-child { color: var(--t-ink2); }
.pv-links-airy .pv-link { padding: 14px 0; }
.pv-linkgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pv-linkgrid .pv-card { padding: 14px; display: grid; gap: 14px; }
.pv-linkgrid .pv-ico { color: var(--accent); }
.pv-linkcards .pv-card { background: linear-gradient(140deg, var(--accent-soft), var(--t-card)); min-height: 86px; }

.pv-chips { display: flex; gap: 14px; white-space: nowrap; overflow: hidden; font-size: calc(13px * var(--ts)); color: var(--t-ink2); }
.pv-chips .on { color: var(--t-ink); box-shadow: inset 0 -2px 0 var(--accent); padding-bottom: 4px; }
.pv-sec { display: flex; align-items: center; gap: 6px; margin-top: 4px; }
.pv-sec h3 { font-size: calc(21px * var(--ts)); }
.pv-sec .pv-ico { color: var(--t-ink2); }
.pv-sec-ed { display: grid; gap: 4px; }
.pv-sec-ed small { display: flex; align-items: center; gap: 8px; letter-spacing: .14em; font-size: calc(11px * var(--ts)); color: var(--t-ink); }
.pv-sec-ed small i { width: 16px; height: 1px; background: var(--t-ink); }
.pv-sec-ed em { font-style: normal; font-size: calc(10.5px * var(--ts)); letter-spacing: .12em; color: var(--t-ink2); }
.pv-shuffle { display: inline-flex; align-items: center; gap: 6px; color: var(--accent); font-size: calc(12.5px * var(--ts)); }
.pv-counter { font-family: var(--f-display); font-size: 13px; color: var(--t-ink2); margin-top: -6px; }
.pv-counter b { color: var(--t-ink); }

.pv-rail { display: flex; gap: 12px; }
.pv-tile { flex: none; display: grid; gap: 3px; align-content: start; min-width: 0; }
.pv-tile b, .pv-tile small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }
.pv-tile b { font-size: calc(14px * var(--ts)); margin-top: 5px; }
.pv-tile-overlay { position: relative; }
.pv-tile-cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 22px 8px 7px; background: linear-gradient(180deg, transparent, rgba(0,0,0,.75)); border-radius: 0 0 var(--r-s) var(--r-s); }
.pv-tile-cap b, .pv-tile-cap small { color: #fff; }
.pv-grid { display: grid; gap: 14px 12px; }
.pv-grid .pv-tile { width: auto !important; }
.pv-bigcard { flex: none; width: 190px; padding: 10px; display: grid; gap: 3px; }
.pv-bigcard b { margin-top: 6px; }
.pv-wallgrid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 3px; }
.pv-wallgrid .pv-cover { aspect-ratio: 1; border-radius: 0; }

.pv-list { display: grid; }
.pv-row { display: flex; align-items: center; gap: 12px; padding: 9px 0; border-top: 1px solid var(--t-div); }
.pv-row:first-child { border-top: 0; }
.pv-list-compact .pv-row { padding: 5px 0; }
.pv-row-art { width: 46px; height: 46px; }
.pv-list-compact .pv-row-art { width: 36px; height: 36px; }
.pv-row-n { width: 22px; text-align: center; color: var(--t-ink2); font-size: 13px; flex: none; }
.pv-row-text { flex: 1; min-width: 0; display: grid; gap: 1px; }
.pv-row-text b, .pv-row-text small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pv-row.playing b { color: var(--accent); }
.pv-row-time { font-size: 12.5px; color: var(--t-ink2); }
.pv-row > .pv-ico:last-child { color: var(--t-ink2); }
.pv-scroll-flush .pv-list { padding: 6px 20px 0; }

.pv-artists { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; text-align: center; }
.pv-artists .pv-cover { aspect-ratio: 1; margin-bottom: 5px; }
.pv-artist-circle { border-radius: 50%; }
.pv-artists small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.pv-album { position: relative; text-align: center; }
.pv-album-classic { padding: 96px 20px 6px; display: grid; justify-items: center; gap: 16px; }
.pv-album-classic .pv-cover { box-shadow: 0 16px 40px rgba(0,0,0,.35); border-radius: var(--r-m); }
.pv-round { border-radius: 50% !important; }
.pv-album-bleed .pv-cover, .pv-album-immersive > .pv-cover:not(.pv-album-wash) { border-radius: 0; margin-top: -54px; }
.pv-album-immersive > .pv-cover:not(.pv-album-wash) { -webkit-mask-image: linear-gradient(180deg, #000 55%, transparent); mask-image: linear-gradient(180deg, #000 55%, transparent); position: relative; }
.pv-album-wash { position: absolute; inset: -54px 0 auto 0; height: 560px; filter: blur(40px) saturate(1.2); opacity: .5; border-radius: 0; }
.pv-album-immersive .pv-album-meta { margin-top: -70px; position: relative; }
.pv-album-meta { padding: 14px 20px 4px; display: grid; gap: 4px; justify-items: center; }
.pv-album-meta h2 { font-size: calc(24px * var(--ts)); }
.pv-accent { color: var(--accent); margin: 0; font-size: calc(16px * var(--ts)); }
.pv-album-btns { display: flex; gap: 10px; align-items: center; margin-top: 12px; }
.pv-pill-solid { background: var(--accent); color: var(--accent-ink); border-radius: 999px; padding: 11px 44px; display: inline-flex; gap: 8px; align-items: center; font-weight: 600; }
.pv-pill-ghost { width: 44px; height: 44px; border-radius: 50%; background: var(--t-card); display: grid; place-items: center; box-shadow: inset 0 0 0 1px var(--t-div); }

/* Dock: mini player + tabs */
.pv-dock { position: absolute; left: 0; right: 0; bottom: 0; z-index: 6; display: grid; background: var(--t-tab); box-shadow: 0 -1px 0 var(--t-div); padding-bottom: 22px; }
.pv-dock-float { background: linear-gradient(180deg, transparent, var(--t-bg) 46%); box-shadow: none; padding: 26px 16px 24px; gap: 8px; grid-template-columns: 1fr auto; align-items: center; }
.pv-dock-float > .pv-mini, .pv-dock-float > .pv-deck { grid-column: 1 / -1; }
.pv-glass { -webkit-backdrop-filter: blur(18px) saturate(1.6); backdrop-filter: blur(18px) saturate(1.6); background: color-mix(in srgb, var(--t-ink) 12%, color-mix(in srgb, var(--t-bg) 55%, transparent)) !important; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--t-ink) 14%, transparent); }
.pv-mini { display: flex; align-items: center; gap: 11px; padding: 8px 14px 8px 8px; background: var(--t-card); }
.pv-mini-art { width: 40px; height: 40px; border-radius: var(--r-s); }
.pv-mini-text { flex: 1; min-width: 0; display: grid; }
.pv-mini-text b, .pv-mini-text small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pv-mini-btns { display: flex; align-items: center; gap: 14px; }
.pv-mini-flat { border-bottom: 1px solid var(--t-div); background: transparent; }
.pv-mini-float { border-radius: 999px; background: color-mix(in srgb, var(--t-ink) 10%, var(--t-bg)); }
.pv-mini-float .pv-mini-art { border-radius: 50%; }
.pv-mini-line { background: transparent; border-top: 1px solid var(--t-div); border-bottom: 1px solid var(--t-div); padding-inline: 0; }
.pv-mini-tonal { border-radius: var(--r-l); background: var(--accent-soft); }
.pv-mini-pop { border-radius: 999px; background: var(--accent); color: var(--accent-ink); }
.pv-mini-pop small { color: inherit; opacity: .75; }
.pv-mini-squircle { border-radius: var(--r-l); background: color-mix(in srgb, var(--t-ink) 10%, var(--t-bg)); }
.pv-deck { border-radius: var(--r-l); background: var(--t-card); padding: 10px 12px 12px; display: grid; grid-template-columns: auto 1fr; gap: 10px 11px; align-items: center; box-shadow: inset 0 0 0 1px var(--t-div); }
.pv-deck-keys { grid-column: 1 / -1; display: flex; justify-content: center; gap: 44px; color: var(--accent); }
.pv-tabs { display: flex; align-items: center; }
.pv-tab { flex: 1; display: grid; justify-items: center; gap: 2px; color: var(--t-tab-off); padding: 6px 0; }
.pv-tab small { color: inherit; font-size: 10.5px; }
.pv-tab.on { color: var(--accent); }
.pv-tabs-material { padding: 6px 10px 0; }
.pv-tabs-material .pv-tab.on .pv-ico { background: var(--accent-soft); border-radius: 999px; padding: 3px 14px; width: 52px; height: 27px; }
.pv-tabs-float, .pv-tabs-capsule { border-radius: 999px; background: color-mix(in srgb, var(--t-ink) 10%, var(--t-bg)); padding: 4px; }
.pv-tabs-float { grid-column: 1 / -1; justify-self: center; width: 220px; }
.pv-tabs-capsule { width: 190px; }
.pv-tabs-capsule .pv-tab.on { background: color-mix(in srgb, var(--t-ink) 14%, transparent); border-radius: 999px; }
.pv-tab-orb { width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--t-ink) 10%, var(--t-bg)); justify-self: end; }
.pv-tabs-plain { grid-column: 1 / -1; padding: 2px 30px 0; }
.pv-tabs-quiet .pv-tab.on { color: var(--t-ink); }
.pv-tabs-tonal { grid-column: 1 / -1; gap: 8px; }
.pv-tabs-tonal .pv-tab { background: var(--t-card); border-radius: var(--r-m); padding: 9px 0; }
.pv-tabs-tonal .pv-tab.on { background: var(--accent-soft); grid-auto-flow: column; gap: 6px; flex: 1.6; }
.pv-tabs-pop { grid-column: 1 / -1; gap: 10px; justify-content: center; }
.pv-tabs-pop .pv-tab { flex: 0 0 54px; height: 50px; background: var(--t-card); border-radius: var(--r-m); align-content: center; }
.pv-tabs-pop .pv-tab.on { background: var(--accent); color: var(--accent-ink); }

/* Player */
.pv-player-bg, .pv-player-dim { position: absolute; inset: 0; }
.pv-player-dim { background: #000; }
.pv-player { position: relative; z-index: 3; flex: 1; display: flex; flex-direction: column; min-height: 0; }
.pv-player small { color: inherit; opacity: .7; }
.pv-prow { flex: none; min-width: 0; }
.pv-prow-art { flex: 100 1 120px; min-height: 90px; display: flex; }
.pv-gap { min-height: 0; }
.pv-head { height: 26px; display: grid; place-items: center; }
.pv-head i { width: 38px; height: 5px; border-radius: 3px; }
.pv-head-from { height: 44px; display: flex; align-items: center; padding: 0 20px; gap: 10px; }
.pv-head-from div { flex: 1; text-align: center; display: grid; }
.pv-head-from small { font-size: 9.5px; letter-spacing: .16em; }
.pv-head-from b { font-size: 13px; }
.pv-art { width: 100%; height: 100%; display: flex; align-items: center; min-height: 0; margin: auto 0; padding-inline: 20px; }
.pv-art-box { height: 100%; aspect-ratio: 1; position: relative; display: flex; }
.pv-art-box .pv-cover { height: 100%; }
.pv-art-framed .pv-art-box { padding: 12px; box-shadow: inset 0 0 0 1px currentColor; border-radius: 4px; opacity: .98; }
.pv-on-art, .pv-zone { display: flex; justify-content: space-around; align-items: center; gap: 18px; }
.pv-on-art { position: absolute; left: 0; right: 0; bottom: 0; padding: 26px 16px 12px; color: #fff; background: linear-gradient(180deg, transparent, rgba(0,0,0,.6)); border-radius: inherit; }
.pv-art-box > .pv-zone { position: absolute; left: 10px; right: 10px; top: 10px; justify-content: flex-end; color: #fff; }
.pv-zone { justify-content: center; padding: 6px 0; }
.pv-line .pv-zone { display: inline-flex; padding: 0 0 0 8px; vertical-align: middle; }
.pv-quality { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.pv-format { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 10.5px; letter-spacing: .06em; opacity: .72; }
.pv-badge { display: inline-flex; align-items: center; gap: 4px; border-radius: 999px; padding: 3px 8px; line-height: 1.2; white-space: nowrap; vertical-align: middle; }
.pv-badge i { width: 9px; height: 6px; border-radius: 2px; background: currentColor; opacity: .85; -webkit-mask: linear-gradient(90deg, #000 20%, transparent 20% 40%, #000 40% 60%, transparent 60% 80%, #000 80%); mask: linear-gradient(90deg, #000 20%, transparent 20% 40%, #000 40% 60%, transparent 60% 80%, #000 80%); }
.pv-titles { display: flex; align-items: center; gap: 10px; }
.pv-lines { flex: 1; min-width: 0; display: grid; gap: 3px; }
.pv-line { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1.22; letter-spacing: 0; }
.pv-title-chip { border-radius: 7px; padding: 1px 8px; margin-left: -8px; }
.pv-title-mark { display: inline-flex; align-items: flex-end; gap: 2px; height: 12px; margin-left: 8px; vertical-align: baseline; }
.pv-title-mark i { width: 2.5px; background: currentColor; border-radius: 1px; height: 100%; }
.pv-title-mark i:nth-child(1) { height: 55%; } .pv-title-mark i:nth-child(3) { height: 75%; }
.pv-mark-waveform i:nth-child(2) { height: 45%; } .pv-mark-waveform i { border-radius: 2px; align-self: center; }
.pv-mark-spatial i { width: 9px; height: 9px; border-radius: 50%; background: none; box-shadow: inset 0 0 0 1.5px currentColor; margin-left: -6px; }
.pv-inline-actions { display: flex; align-items: center; gap: 12px; flex: none; }
.pv-stars { display: inline-flex; gap: 5px; }
.pv-route-row { display: flex; }
.pv-route { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; border-radius: 999px; padding: 4px 9px; }
.pv-route i { width: 6px; height: 6px; border-radius: 50%; }
.pv-actions { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; }
.pv-actions .l, .pv-actions .c, .pv-actions .r { display: flex; align-items: center; gap: 12px; }
.pv-actions .c { justify-content: center; } .pv-actions .r { justify-content: flex-end; }
.pv-scrub { display: block; overflow: visible; }
.pv-times { display: flex; justify-content: space-between; align-items: center; font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 10.5px; margin-top: 7px; opacity: .8; }
.pv-transport { display: flex; align-items: center; padding-inline: 28px; }
.pv-transport-boxed { margin-inline: 24px; padding: 12px 18px; border-radius: 6px; box-shadow: inset 0 0 0 1px currentColor; }
.pv-classic { display: flex; align-items: center; }
.pv-play { display: grid; place-items: center; flex: none; }
.pv-mode { flex: none; }
.pv-cluster { display: flex; align-items: center; gap: 14px; }
.pv-flank { display: flex; align-items: center; gap: 16px; }
.pv-capsule { flex: 1; display: flex; justify-content: space-around; align-items: center; border-radius: 999px; padding: 12px 18px; }
.pv-words { flex: 1; display: flex; justify-content: space-around; font-size: 12px; letter-spacing: .22em; font-weight: 600; }
.pv-pad { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; }
.pv-pad-sq { border-radius: 14px; width: 60px; height: 60px; }
.pv-key { width: 62px; height: 54px; border-radius: 16px; display: grid; place-items: center; }
.pv-key-wide { width: 96px; height: 62px; border-radius: 20px; }
.pv-trio { flex: 1; justify-content: space-around; }
.pv-deckbar { flex: 1; display: flex; align-items: center; justify-content: space-between; border-radius: 18px; padding: 10px 16px; }
.pv-deck-play { width: 62px; height: 46px; border-radius: 12px; display: grid; place-items: center; }
.pv-wheel { border-radius: 50%; position: relative; margin-inline: auto; }
.pv-wheel span { position: absolute; display: grid; place-items: center; }
.pv-wheel .n { top: 12px; left: 50%; transform: translateX(-50%); } .pv-wheel .s { bottom: 12px; left: 50%; transform: translateX(-50%); }
.pv-wheel .w { left: 16px; top: 50%; transform: translateY(-50%); } .pv-wheel .e { right: 16px; top: 50%; transform: translateY(-50%); }
.pv-wheel .c { inset: 31%; border-radius: 50%; }
.pv-vol { display: flex; align-items: center; gap: 10px; }
.pv-vol b { font-family: ui-monospace, Menlo, monospace; font-size: 11px; width: 18px; }
.pv-vol-track { flex: 1; border-radius: 999px; overflow: hidden; }
.pv-vol-track u { display: block; height: 100%; border-radius: 999px; }
.pv-vol-cells { flex: 1; display: flex; gap: 3px; align-items: flex-end; }
.pv-vol-cells i { flex: 1; border-radius: 2px; }
.pv-vol-dots { align-items: center; } .pv-vol-dots i { height: 5px; flex: 0 0 5px; border-radius: 50%; margin: auto; }
.pv-bar { display: flex; align-items: center; justify-content: space-around; padding: 8px 6px; }
.pv-bar span { display: grid; justify-items: center; gap: 2px; }
.pv-bar small { font-size: 9px; }
.pv-bar-pill, .pv-bar-tonal { border-radius: 999px; padding: 11px 10px; }
.pv-bar-tonal { border-radius: 18px; }
.pv-bar-compact { justify-content: center; gap: 30px; }
.pv-bar-space { flex: 1; }
.pv-imm-blur, .pv-imm-full, .pv-imm-top, .pv-edge, .pv-imm-veil { position: absolute; left: 0; right: 0; top: 0; background-size: cover; background-position: center; z-index: 1; }
.pv-imm-blur { bottom: 0; filter: blur(46px) saturate(1.3) brightness(.62); transform: scale(1.3); }
.pv-imm-full { bottom: 0; } .pv-imm-veil { bottom: 0; background: linear-gradient(180deg, rgba(0,0,0,.05) 30%, rgba(0,0,0,.78) 78%); }
.pv-edge { height: 402px; }
.pv-imm-space { flex: none; }

.pv-row-text, .pv-list { text-align: left; }

/* Built-in theme tiles */
.st-themes { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: .5rem; }
.st-theme { border: 1px solid var(--line-strong); border-radius: var(--r-md); padding: .7rem .75rem; cursor: pointer; text-align: left;
  display: grid; grid-template-columns: auto auto 1fr; gap: .45rem .3rem; align-items: center; transition: transform .25s var(--ease), box-shadow .25s; }
.st-theme:hover { transform: translateY(-2px); }
.st-theme.on { box-shadow: 0 0 0 2px var(--blue); }
.st-theme i { width: 18px; height: 18px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(128,128,128,.35); }
.st-theme b { grid-column: 1 / -1; font-size: var(--step--1); font-weight: 600; }
.st-theme small { grid-column: 1 / -1; font-size: var(--step--2); opacity: .7; margin-top: -.35rem; }

/* ==========================================================================
   4. Preview, second pass — every setting visible
   ========================================================================== */

/* Live background layers */
.pv-player-bg { position: absolute; inset: 0; overflow: hidden; }
.pv-bg-flat { position: absolute; inset: 0; }
.pv-bg-art { position: absolute; inset: -18%; background-size: cover; background-position: center; will-change: transform; }
@keyframes pv-drift { 0% { transform: translate3d(-4%, -3%, 0) scale(1.05) rotate(-2deg); } 100% { transform: translate3d(5%, 4%, 0) scale(1.16) rotate(3deg); } }

/* Meter pulse */
.pv-pulse-subtle { animation: pv-pulse 1.1s ease-in-out infinite; --pulse: .85; }
.pv-pulse-standard { animation: pv-pulse .85s ease-in-out infinite; --pulse: .65; }
.pv-pulse-strong { animation: pv-pulse .6s ease-in-out infinite; --pulse: .4; }
@keyframes pv-pulse { 50% { opacity: var(--pulse); transform: scaleY(1.08); } }

/* Home indicator, so the bottom clearance is visible */
.pv-home-ind { position: absolute; left: 50%; bottom: 8px; width: 134px; height: 5px; border-radius: 3px; transform: translateX(-50%); }

/* Featured carousel */
.pv-hero { position: relative; height: 236px; border-radius: var(--r-l); overflow: hidden; flex: none; }
.pv-hero .pv-cover { position: absolute; inset: 0; height: 100%; border-radius: 0; animation: var(--ken) var(--ken-time) ease-in-out infinite alternate; }
@keyframes pv-ken { from { transform: scale(1); } to { transform: scale(1.12) translate(-3%, -2%); } }
.pv-hero-cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 50px 16px 26px; background: linear-gradient(180deg, transparent, rgba(0,0,0,.72)); color: #fff; display: grid; gap: 2px; }
.pv-hero-cap small { color: rgba(255,255,255,.75); letter-spacing: .14em; font-size: 10.5px; }
.pv-hero-cap b { font-family: var(--f-display); font-size: 24px; font-weight: var(--w-display); }
.pv-hero-cap span { font-size: 13px; opacity: .85; }
.pv-hero-dots { position: absolute; bottom: 10px; left: 0; right: 0; display: flex; justify-content: center; gap: 5px; }
.pv-hero-dots i { width: 6px; height: 6px; border-radius: 50%; background: rgba(255,255,255,.4); }
.pv-hero-dots i.on { width: 16px; border-radius: 3px; background: #fff; }
.pv-hero-edge { margin-inline: -20px; border-radius: 0; }
.pv-hero-top { margin-inline: -20px; border-radius: 0; height: 330px; }
.pv-scroll-top { padding-top: 0; }
.pv-status-float { position: absolute; top: 0; left: 0; right: 0; z-index: 7; color: #fff; text-shadow: 0 1px 6px rgba(0,0,0,.35); }
.pv-block { display: grid; gap: 14px; }

/* Library */
.pv-split { display: grid; grid-template-columns: 158px 1fr; gap: 12px; }
.pv-split .pv-row { padding: 7px 8px; border-radius: var(--r-s); border-top: 0; }
.pv-split .pv-row.sel { background: var(--accent-soft); }
.pv-split-detail { display: grid; justify-items: center; align-content: start; gap: 4px; text-align: center; padding-top: 10px; border-left: 1px solid var(--t-div); }
.pv-split-detail .pv-cover { margin-bottom: 6px; }
.pv-split-note { font-size: 10.5px !important; opacity: .75; margin-top: 8px; }
.pv-artists .pv-cover { margin: 0 auto 5px; }
.pv-artist-square { border-radius: var(--r-s); }

/* Artist page */
.pv-artist-hero { position: relative; }
.pv-artist-hero .pv-cover { border-radius: 0; }
.pv-artist-hero-cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 70px 20px 18px; display: flex; align-items: flex-end; gap: 12px; background: linear-gradient(180deg, transparent, rgba(0,0,0,.7)); color: #fff; }
.pv-artist-hero-cap h1 { flex: 1; font-size: 34px; }
.pv-artist-play { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: var(--accent-ink); }
.pv-artist-classic { padding: 100px 20px 4px; display: grid; justify-items: center; gap: 12px; text-align: center; }
.pv-artist-classic .pv-cover { box-shadow: 0 16px 40px rgba(0,0,0,.3); }
.pv-artist-classic h1 { font-size: 28px; }
.pv-pad { padding: 14px 20px 0; display: grid; gap: 12px; }
.pv-stats { display: grid; grid-template-columns: repeat(3, 1fr); text-align: center; padding: 10px 0; border-bottom: 1px solid var(--t-div); }
.pv-stats b { display: block; font-size: 20px; font-family: var(--f-display); }

/* Lyrics */
.pv-prow-lyrics { flex-direction: column; overflow: hidden; gap: 16px; }
.pv-strip { display: flex; align-items: center; gap: 12px; }
.pv-strip div { display: grid; }
.pv-lyrics { display: grid; }
.pv-lyrics-panel { gap: 14px; overflow: hidden; -webkit-mask-image: linear-gradient(180deg, #000 70%, transparent); mask-image: linear-gradient(180deg, #000 70%, transparent); }
.pv-lyrics-panel .pv-lyric { font-size: 25px; font-weight: 700; line-height: 1.18; opacity: .38; letter-spacing: -.01em; }
.pv-lyrics-panel .pv-lyric.on { opacity: 1; }
.pv-lyrics-karaoke .pv-lyric.on { opacity: 1; }
.pv-sweep { color: transparent; -webkit-background-clip: text; background-clip: text; }
.pv-lyrics-cloud .pv-lyric { opacity: .55; font-weight: 600; }
.pv-lyrics-inline { gap: 3px; margin: 6px 0; text-align: inherit; }
.pv-lyrics-inline .pv-lyric { font-size: 15px; font-weight: 600; opacity: .5; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pv-lyrics-inline .pv-lyric.on { opacity: 1; }
.pv-lyrics-inline.pv-lyrics-cloud .pv-lyric { font-size: 15px !important; }

/* Landscape player */
.pv-land { width: 874px; height: 402px; }
.pv-player-land { flex-direction: row; align-items: stretch; padding: 22px 44px 18px; gap: 36px; }
.pv-land-art { flex: 0 0 340px; display: flex; align-items: center; }
.pv-land-art .pv-art { padding: 0; }
.pv-land-rows { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: center; }
.st-device.land { width: calc(874px * var(--s) + 18px); height: calc(402px * var(--s) + 18px); }
.st-device.land::after { top: 50%; left: calc(9px + 11px * var(--s)); transform: translateY(-50%); width: calc(36px * var(--s)); height: calc(124px * var(--s)); }

/* Icon families. The seven bundled families are drawn from the app's own glyphs (studio-icons.js).
   The four System shapes are Apple's SF Symbols, which cannot ship on the web: drawn here as close stand-ins. */
.pv-pack-outline .pv-ico:not(.pv-ico-pack) path[fill="currentColor"] { fill: none; stroke: currentColor; stroke-width: 1.6; }
.pv-pack-circle .pv-link > .pv-ico:first-child, .pv-pack-circle .pv-linkgrid .pv-ico, .pv-pack-circle .pv-tab .pv-ico, .pv-pack-circle .pv-bar .pv-ico { border-radius: 50%; background: color-mix(in srgb, currentColor 22%, transparent); padding: 4px; box-sizing: content-box; }
.pv-pack-square .pv-link > .pv-ico:first-child, .pv-pack-square .pv-linkgrid .pv-ico, .pv-pack-square .pv-tab .pv-ico, .pv-pack-square .pv-bar .pv-ico { border-radius: 5px; background: color-mix(in srgb, currentColor 22%, transparent); padding: 4px; box-sizing: content-box; }
.pv-ico-pack { shape-rendering: geometricPrecision; }
.pv-pack-pixel .pv-ico-pack { shape-rendering: crispEdges; }
/* Motion: hover and press feel follow the motion level */
.pv .pv-tile .pv-cover, .pv .pv-card { transition: transform var(--move) var(--move-ease); }

/* "This changed" highlight */
.pv [data-f].pv-flash { outline: 2px solid var(--st-flash, #b79bff); outline-offset: 3px; border-radius: 8px; animation: pv-flash 1.4s ease-out forwards; }
@keyframes pv-flash { 0%, 55% { outline-color: #b79bff; } 100% { outline-color: transparent; } }
.st-tabs { flex-wrap: wrap; justify-content: center; }
.st-orient { display: inline-flex; gap: .3rem; font-size: var(--step--2); color: var(--ink-muted); align-items: center; }
.st-palette { display: flex; flex-wrap: wrap; gap: 6px; }
.st-palette button { width: 30px; height: 30px; border-radius: 50%; border: 2px solid transparent; cursor: pointer; padding: 0; position: relative; }
.st-palette button.off { opacity: .28; }
.st-palette button.on-now { border-color: var(--ink); }
.st-device.land, .st-stage .st-device.land { --s: .4; }
@media (max-width: 760px) { .st-device.land, .st-stage .st-device.land { --s: .38; } }

/* Home stands on the home background */
.pv-home { background: var(--t-home); }
/* Settings preview */
.pv-settings { position: absolute; inset: 0; padding: 0 16px; display: flex; flex-direction: column; gap: 14px; }
.pv-set-head { display: flex; align-items: center; padding-top: 4px; }
.pv-set-head h1 { flex: 1; font-size: calc(32px * var(--ts)); }
.pv-set-search { display: flex; align-items: center; gap: 8px; border-radius: 12px; padding: 10px 12px; color: var(--t-ink2); }
.pv-set-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pv-set-tile { border-radius: var(--r-l); padding: 12px; display: grid; gap: 10px; min-height: 84px; }
.pv-set-tile span { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; }
.pv-set-tile b { font-size: 13.5px; }
.pv-set-group { border-radius: var(--r-m); padding: 0 14px; }
.pv-set-row { display: flex; align-items: center; justify-content: space-between; padding: 12px 0; border-top: 1px solid var(--t-div); }
.pv-set-row:first-child { border-top: 0; }
.pv-switch { width: 44px; height: 26px; border-radius: 13px; background: color-mix(in srgb, var(--t-ink) 22%, transparent); position: relative; }
.pv-switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; }
.pv-switch.on { background: var(--accent); }
.pv-switch.on::after { left: 21px; }
.pv-set-sheet { position: absolute; right: 18px; top: 104px; width: 236px; border-radius: 14px; box-shadow: 0 18px 50px rgba(0,0,0,.35); padding: 4px 0; }
.pv-set-item { display: flex; justify-content: space-between; align-items: center; padding: 11px 14px; border-top: 1px solid var(--t-div); }
.pv-set-item:first-child { border-top: 0; }

/* Tab Bar Color tints the alternate bar styles */
.pv-tabs-float, .pv-tabs-icons { background: var(--t-bar, color-mix(in srgb, var(--t-ink) 10%, var(--t-bg))) !important; }
.pv-tabs-plain { background: var(--t-bar, transparent); border-radius: 999px; }
.pv-tabs-tonal .pv-tab:not(.on), .pv-tabs-pop .pv-tab:not(.on) { background: var(--t-bar, var(--t-card)); }
.pv-tabs-material { background: var(--t-bar, transparent); }

/* The preview screens scroll (wheel, trackpad or touch) and jump to what you change */
.pv-scroll { overflow-y: auto; scrollbar-width: none; overscroll-behavior: contain; }
.pv-scroll::-webkit-scrollbar { display: none; }
.pv-scroll > * { flex-shrink: 0; }


/* ==========================================================================
   5. iPad and Mac
   ========================================================================== */
.pv-frame { display: flex; flex-direction: row; background: var(--t-bg); }
.pv-pane { position: relative; flex: none; }
.pv-wide-main { position: relative; height: 100%; flex: none; overflow: hidden; }
.pv-dev-mac { flex-direction: column; border-radius: 12px; }
.pv-mac-title { height: 52px; flex: none; display: flex; align-items: center; gap: 16px; padding: 0 16px; border-bottom: 1px solid var(--t-div);
  background: color-mix(in srgb, var(--t-ink) 4%, var(--t-bg)); color: var(--t-ink2); font-size: 14px; }
.pv-mac-title b { color: var(--t-ink); font-weight: 600; }
.pv-mac-flex { flex: 1; }
.pv-lights { display: flex; gap: 8px; margin-right: 8px; }
.pv-lights i { width: 12px; height: 12px; border-radius: 50%; background: #ff5f57; }
.pv-lights i:nth-child(2) { background: #febc2e; } .pv-lights i:nth-child(3) { background: #28c840; }
.pv-mac-search { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 8px; background: var(--t-card); width: 180px; font-size: 13px; }
.pv-mac-body { flex: 1; display: flex; min-height: 0; }

.pv-side { width: 280px; flex: none; height: 100%; padding: 0 14px; display: flex; flex-direction: column; gap: 2px; overflow: hidden;
  background: color-mix(in srgb, var(--t-ink) 4%, var(--t-bg)); border-right: 1px solid var(--t-div); font-size: 15px; }
.pv-side-mac { padding-top: 10px; }
.pv-side-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 8px 14px; }
.pv-side-head b { font-family: var(--f-display); font-weight: var(--w-display); font-size: 22px; }
.pv-side-row { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: var(--r-s); }
.pv-side-row .pv-ico { color: var(--accent); }
.pv-side-row.on { background: var(--accent-soft); font-weight: 600; }
.pv-side-sec { display: flex; align-items: center; justify-content: space-between; padding: 16px 10px 6px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--t-ink2); }
.pv-side-art { width: 28px; height: 28px; border-radius: 6px; }
.pv-side-foot { margin-top: auto; display: flex; gap: 12px; align-items: center; padding: 14px 10px 24px; color: var(--t-ink2); }

.pv-dock-pill { left: 50%; right: auto; width: 440px; transform: translateX(-50%); background: none; padding-bottom: 22px; }
.pv-macbar { position: absolute; left: 0; right: 0; bottom: 0; height: 72px; display: flex; align-items: center; gap: 22px; padding: 0 22px;
  background: color-mix(in srgb, var(--t-ink) 5%, var(--t-bg)); border-top: 1px solid var(--t-div); z-index: 6; }
.pv-macbar .pv-mini-text { flex: 0 0 170px; }
.pv-macbar-keys { display: flex; align-items: center; gap: 18px; color: var(--t-ink); }
.pv-macbar-play { width: 38px; height: 38px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; }
.pv-macbar-prog { flex: 1; display: flex; align-items: center; gap: 10px; font-size: 11px; color: var(--t-ink2); font-family: ui-monospace, Menlo, monospace; }
.pv-macbar-prog i, .pv-macbar-vol i { flex: 1; height: 4px; border-radius: 2px; background: color-mix(in srgb, var(--t-ink) 18%, transparent); overflow: hidden; }
.pv-macbar-prog u, .pv-macbar-vol u { display: block; width: 34%; height: 100%; background: var(--accent); }
.pv-macbar-vol { display: flex; align-items: center; gap: 8px; width: 120px; color: var(--t-ink2); }
.pv-macbar-vol u { width: 62%; background: var(--t-ink2); }
.pv-dev-mac .pv-scroll { padding-bottom: 100px; }

.pv-album-wide { display: flex; align-items: flex-end; gap: 28px; padding: 96px 32px 18px; text-align: left; position: relative; }
.pv-album-wide .pv-cover { box-shadow: 0 18px 44px rgba(0,0,0,.35); border-radius: var(--r-m); position: relative; }
.pv-album-wide .pv-album-meta { justify-items: start; padding: 0; position: relative; }
.pv-album-wide .pv-album-meta h2 { font-size: 34px; }
.pv-album-wide-big .pv-album-wash { position: absolute; inset: 0; height: 100%; filter: blur(50px) saturate(1.3); opacity: .55; border-radius: 0; }
.pv-land-status { position: absolute; top: 0; left: 0; right: 0; }
.pv-player-land { position: relative; }

/* Stage for wide devices */
.studio-app.wide-dev { grid-template-columns: 200px minmax(0, 1fr) minmax(420px, 46vw); }
.st-device.dev-ipad, .st-device.dev-mac { width: calc(var(--fw) * var(--s) + 2 * var(--bz)); height: calc(var(--fh) * var(--s) + 2 * var(--bz)); padding: var(--bz); }
.st-device.dev-ipad { --bz: 10px; border-radius: calc(36px * var(--s) + 10px); }
.st-device.dev-ipad .st-screen { border-radius: calc(36px * var(--s)); }
.st-device.dev-ipad::after { width: 6px; height: 6px; top: 50%; left: 4px; transform: translateY(-50%); }
.st-device.dev-ipad.portrait::after { top: 3px; left: 50%; transform: translateX(-50%); }
.st-device.dev-mac { --bz: 0px; border-radius: 12px; background: none; box-shadow: var(--shadow-lg), 0 0 0 1px rgba(255,255,255,.12); }
.st-device.dev-mac::after { display: none; }
.st-device.dev-mac .st-screen { border-radius: 12px; }
.st-devices { display: inline-flex; padding: 3px; border: 1px solid var(--line); border-radius: var(--r-pill); background: var(--surface-glass); gap: 2px; }
.st-devices button { border: 0; background: none; color: var(--ink-muted); padding: .38rem .9rem; border-radius: var(--r-pill); font-size: var(--step--2); cursor: pointer; font-weight: 600; }
.st-devices button.on { background: linear-gradient(135deg, var(--blue), var(--violet)); color: var(--accent-ink); }
.st-expand { border: 1px solid var(--line); background: var(--surface-glass); color: var(--ink-soft); border-radius: var(--r-pill); padding: .3rem .8rem; font-size: var(--step--2); cursor: pointer; }
.st-stage.zoom { position: fixed; inset: 0; z-index: 250; background: color-mix(in srgb, var(--bg) 94%, transparent); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  padding: 24px; align-content: center; overflow: auto; }
.st-stage.zoom .st-checks, .st-stage.zoom .st-note { display: none; }
@media (max-width: 1240px) { .studio-app.wide-dev { grid-template-columns: 180px minmax(0, 1fr) minmax(380px, 44vw); } }
@media (max-width: 1020px) { .studio-app.wide-dev { grid-template-columns: minmax(0, 1fr) minmax(340px, 46vw); } }
@media (max-width: 760px) { .studio-app.wide-dev { grid-template-columns: 1fr; } }

.pv-dev-mac .pv-status-none { height: 14px; }
.pv-dev-mac .pv-nav-over { top: 14px; }
.pv-dev-mac .pv-album-classic, .pv-dev-mac .pv-album-wide, .pv-dev-mac .pv-artist-classic { padding-top: 60px; }

.st-devnote { margin: 0; font-size: var(--step--2); color: var(--amber); text-align: center; max-width: 46ch; }
.st-devnote button { background: none; border: 0; color: var(--blue); text-decoration: underline; cursor: pointer; font: inherit; padding: 0; }

/* ---- Bars and mini players, measured from the app (points = px here) ---- */
.nb { position: absolute; left: 0; right: 0; bottom: 0; z-index: 6; display: grid; color: var(--t-ink); }
.nb-glass { -webkit-backdrop-filter: blur(20px) saturate(1.8); backdrop-filter: blur(20px) saturate(1.8);
  background: color-mix(in srgb, var(--t-ink) 17%, color-mix(in srgb, var(--t-bg) 78%, transparent));
  box-shadow: inset 0 0 0 .5px color-mix(in srgb, var(--t-ink) 22%, transparent), inset 0 1px 0 color-mix(in srgb, #fff 14%, transparent), 0 8px 24px rgba(0,0,0,.18); }
.nb-mat { -webkit-backdrop-filter: blur(24px) saturate(1.6); backdrop-filter: blur(24px) saturate(1.6);
  background: color-mix(in srgb, var(--t-ink) 13%, var(--t-bar, var(--t-tab)));
  box-shadow: inset 0 0 0 .5px var(--t-div); }
.nb-art { flex: none; }
.nb-text { flex: 1; min-width: 0; display: grid; gap: 2px; }
.nb-text b { font-size: 16px; font-weight: 600; letter-spacing: -.2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nb-text small { font-size: 12px; color: var(--t-ink2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nb-big b { font-size: 17px; } .nb-big small { font-size: 13px; }
.nb-btns { display: flex; align-items: center; margin-right: 8px; }
.nb-btn { display: grid; place-items: center; flex: none; }
.nb-dim { opacity: .75; }
.nb-accent { color: var(--accent); }
/* default · squircle · pop (DynamicPlayerBar) */
.nb-dyn { gap: 4px; padding: 0 0 18px; }
.nb-mini { margin: 0 16px; display: flex; align-items: center; gap: 12px; padding-left: 8px; border-radius: 999px; }
.nb-mini-squircle { border-radius: 22px; }
.nb-mini-pop { background: color-mix(in srgb, var(--accent) 85%, var(--t-bg)); color: var(--accent-ink); box-shadow: inset 0 0 0 .5px var(--t-div); }
.nb-mini-pop .nb-text small { color: inherit; opacity: .7; }
.nb-dynrow { display: flex; align-items: center; gap: 10px; padding: 6px 20px 0; }
.nb-caps { flex: 1; height: 58px; border-radius: 999px; display: flex; padding: 5px; }
.nb-caps-pop { height: 66px; }
.nb-dtab2 { flex: 1; display: grid; justify-items: center; align-content: center; gap: 2px; border-radius: 999px; color: var(--t-ink2); }
.nb-dtab2 small { font-size: 10px; color: inherit; }
.nb-dtab2.on { color: var(--accent); background: color-mix(in srgb, var(--t-ink) 12%, transparent); }
.nb-dtab2.on small { font-weight: 600; }
.nb-caps-pop .nb-dtab2.on { background: none; }
.nb-popdot { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: var(--accent-ink); }
.nb-search { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.nb-search-pop { width: 64px; height: 64px; background: var(--accent); color: var(--accent-ink); }
/* Material */
.nb-material { gap: 8px; }
.nb-mcard { margin: 0 8px; border-radius: 12px; display: flex; align-items: center; gap: 8px; padding: 8px; }
.nb-mbar { display: flex; padding: 6px 0 12px; background: color-mix(in srgb, var(--t-ink) 13%, var(--t-bar, var(--t-tab))); -webkit-backdrop-filter: blur(24px); backdrop-filter: blur(24px); box-shadow: 0 -.5px 0 var(--t-div); }
.nb-mtab { flex: 1; display: grid; justify-items: center; gap: 3px; color: var(--t-ink2); }
.nb-mtab i { width: 56px; height: 30px; border-radius: 999px; display: grid; place-items: center; }
.nb-mtab small { font-size: 11px; font-weight: 500; color: inherit; }
.nb-mtab.on { color: var(--accent); } .nb-mtab.on i { background: color-mix(in srgb, var(--accent) 20%, transparent); }
/* Floating · Tonal */
.nb-stack8 { gap: 8px; padding: 0 0 26px; }
.nb-fpill { margin: 0 8px; display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 999px; }
.nb-frow { margin: 0 8px; border-radius: 999px; display: flex; padding: 0 6px; }
.nb-ftab { flex: 1; height: 50px; display: grid; place-items: center; color: var(--t-ink2); position: relative; }
.nb-ftab.on { color: var(--accent); }
.nb-ftab.on::before { content: ""; position: absolute; width: 42px; height: 42px; border-radius: 50%; background: color-mix(in srgb, var(--accent) 22%, transparent); }
.nb-ftab .pv-ico { position: relative; }
.nb-trow .nb-ftab { height: 52px; } .nb-trow .nb-ftab.on { color: var(--tone); }
.nb-trow .nb-ftab.on::before { width: 44px; height: 44px; background: color-mix(in srgb, var(--tone) 30%, transparent); }
.nb-tcard { margin: 0 8px; border-radius: 14px; background: color-mix(in srgb, var(--tone) 78%, var(--t-bg)); box-shadow: inset 0 0 0 .5px var(--t-div); }
.nb-tcard .nb-text small { color: inherit; opacity: .7; }
.nb-tcard-row { display: flex; align-items: center; gap: 8px; padding: 8px; }
.nb-tprog { margin: 0 8px 6px; height: 3px; border-radius: 3px; background: color-mix(in srgb, currentColor 25%, transparent); overflow: hidden; }
.nb-tprog i { display: block; width: 34%; height: 100%; background: currentColor; }
/* Deck */
.nb-deckwrap { gap: 8px; }
.nb-deck { margin: 0 8px; border-radius: 16px; padding: 12px; display: grid; gap: 8px; }
.nb-deck-top { display: flex; align-items: center; gap: 8px; }
.nb-deck-keys { display: flex; justify-content: space-evenly; }
.nb-deck-keys span { width: 72px; height: 58px; display: grid; place-items: center; }
.nb-deckbar { display: flex; padding-bottom: 16px; background: color-mix(in srgb, color-mix(in srgb, var(--t-ink) 8%, var(--t-bar, var(--t-tab))) 88%, transparent); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); }
.nb-dtab { flex: 1; height: 44px; display: grid; place-items: center; color: var(--t-tab-off); } .nb-dtab.on { color: var(--accent); }
/* Minimal */
.nb-tabless { display: flex; align-items: flex-end; gap: 8px; padding: 0 12px 13px; }
.nb-tabless .nb-fpill { margin: 0; flex: 1; }
.nb-orb48 { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; color: var(--accent); flex: none; }
/* Card Dock */
.nb-carddock { gap: 8px; padding: 0 8px 27px; }
.nb-cdcaps { justify-self: end; display: flex; gap: 8px; padding: 2px 8px; border-radius: 999px; }
.nb-cdtab { width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center; color: var(--t-ink2); }
.nb-cdtab.on { color: var(--accent); background: color-mix(in srgb, var(--accent) 18%, transparent); }
.nb-cdcard { border-radius: 22px; display: flex; align-items: center; gap: 12px; padding: 8px 12px; }
.pv-dock-pill.nb { left: 50%; right: auto; width: 440px; transform: translateX(-50%); }

/* ---- Artist page (ArtistDetailView) ---- */
.ar-photo { position: absolute; inset: 0; border-radius: 0 !important; background-size: cover; background-position: center top; }
.ar-classic { position: relative; height: 300px; flex: none; }
.ar-classic-fade { position: absolute; inset: 0; background: linear-gradient(180deg, transparent, color-mix(in srgb, var(--t-bg) 60%, transparent) 50%, var(--t-bg)); }
.ar-classic-cap { position: absolute; left: 14px; right: 14px; bottom: 12px; display: grid; gap: 4px; }
.ar-classic-cap h1, .ar-hero-cap h1 { font-family: var(--f-display); font-size: 34px; font-weight: var(--w-display); line-height: 1.1; letter-spacing: -.4px; }
.ar-classic-cap small { font-size: 14px; color: var(--t-ink2); }
.ar-hero { position: relative; flex: none; overflow: hidden; }
.ar-hero-scrim { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 0, transparent 50%, rgba(0,0,0,.45)); }
.ar-hero-cap { position: absolute; left: 14px; right: 14px; bottom: 14px; display: flex; align-items: flex-end; gap: 12px; color: #fff; }
.ar-hero-cap h1 { flex: 1; }
.ar-hero-play { width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; flex: none; background: var(--accent); color: var(--accent-ink); }
.ar-nav { position: absolute; top: 54px; left: 16px; right: 16px; z-index: 5; display: flex; align-items: center; }
.ar-nav i { flex: 1; }
.ar-orb, .ar-caps { height: 44px; display: flex; align-items: center; justify-content: center; gap: 18px; border-radius: 999px; color: var(--t-ink);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); background: color-mix(in srgb, var(--t-ink) 12%, color-mix(in srgb, var(--t-bg) 55%, transparent));
  box-shadow: inset 0 0 0 .5px color-mix(in srgb, var(--t-ink) 22%, transparent); }
.ar-orb { width: 44px; } .ar-caps { padding: 0 16px; color: var(--accent); }
.ar-ring { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; box-shadow: inset 0 0 0 1.6px currentColor; }
.ar-body { display: grid; gap: 16px; padding: 14px 0 0; }
.ar-stats { display: flex; align-items: center; margin: 0 14px; }
.ar-stats div { flex: 1; display: grid; justify-items: center; gap: 2px; }
.ar-stats b { font-family: var(--f-display); font-size: 20px; font-weight: var(--w-display); }
.ar-stats small { font-size: 12px; color: var(--t-ink2); }
.ar-stats i { width: 1px; height: 32px; background: var(--t-div); }
.ar-sec { display: grid; gap: 10px; }
.ar-sec h3 { font-family: var(--f-display); font-size: 20px; font-weight: var(--w-display); margin: 0 14px; }
.ar-sec p { margin: 0 14px; font-size: 15px; line-height: 1.32; color: var(--t-ink2); display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.ar-more { margin: -4px 14px 0; font-size: 14px; font-weight: 500; color: var(--accent); }
.ar-card { margin: 0 12px; border-radius: 14px; overflow: hidden; }
.ar-row { display: flex; align-items: center; gap: 12px; padding: 8px 12px; color: var(--t-ink2); }
.ar-row + .ar-row { box-shadow: inset 56px .5px 0 -0 transparent, inset 0 .5px 0 var(--t-div); }
.ar-row-art { width: 40px; height: 40px; border-radius: 6px; flex: none; }
.ar-row-text { flex: 1; min-width: 0; display: grid; gap: 2px; }
.ar-row-text b { font-size: 16px; font-weight: 400; color: var(--t-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ar-row-text small { font-size: 12px; white-space: nowrap; }
.ar-row-text em { font-style: normal; font-size: 9px; font-weight: 700; padding: 1px 4px; border-radius: 3px; color: #34C759; background: rgba(52,199,89,.16); margin-left: 4px; }
.ar-dots { color: var(--accent); }
.ar-albums { display: grid; gap: 14px; margin: 0 14px; }
.ar-mac { display: flex; gap: 20px; align-items: center; padding: 70px 24px 16px; }
.ar-mac h1 { font-family: var(--f-display); font-size: 20px; font-weight: 700; }
.ar-mac small { color: var(--t-ink2); font-size: 13px; }
.ar-mac-btns { display: flex; gap: 8px; margin-top: 12px; }
.ar-mac-btns span { height: 30px; min-width: 38px; padding: 0 10px; border-radius: 6px; display: flex; align-items: center; gap: 6px; justify-content: center; background: color-mix(in srgb, var(--t-ink) 12%, transparent); font-size: 14px; }
.ar-mac-btns .ar-mac-play { background: var(--accent); color: var(--accent-ink); font-weight: 600; padding: 0 16px; }
.ar-classic, .ar-hero { margin-top: -62px; }
.pv-dev-mac .ar-classic, .pv-dev-mac .ar-hero { margin-top: 0; }

/* ---- Album page (AlbumDetailView) ---- */
.al-bg { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.al-bg i { position: absolute; inset: -40px; filter: blur(30px); -webkit-mask: linear-gradient(180deg, #fff 0, rgba(255,255,255,.6) 30%, transparent 58%); mask: linear-gradient(180deg, #fff 0, rgba(255,255,255,.6) 30%, transparent 58%); }
.al-page { position: relative; z-index: 1; }
.al-page .ar-orb, .al-page .ar-caps { color: var(--al-ink); background: color-mix(in srgb, var(--al-ink) 14%, transparent); }
.al-art { display: grid; justify-items: center; padding: 116px 0 14px; }
.al-art .pv-cover { box-shadow: 0 16px 40px rgba(0,0,0,.35); }
.al-bleed { position: relative; margin-bottom: 14px; }
.al-imm { margin-bottom: 12px; }
.al-bleed i { position: absolute; inset: 0; }
.al-title { display: grid; justify-items: center; gap: 6px; padding: 0 16px 26px; text-align: center; }
.al-title h2 { font-family: var(--f-display); font-size: 22px; font-weight: var(--w-display); color: inherit; }
.al-title p { font-size: 16px; font-weight: 500; opacity: .85; margin: 0; }
.al-title small { font-size: 13px; opacity: .6; }
.al-actions { display: flex; align-items: center; gap: 14px; padding: 0 14px 24px; }
.al-circle { width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center; flex: none; background: color-mix(in srgb, var(--al-ink) 14%, transparent); box-shadow: inset 0 0 0 .5px color-mix(in srgb, var(--al-ink) 25%, transparent); }
.al-play { flex: 1; height: 50px; border-radius: 999px; display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 17px; font-weight: 600; }
.al-rows { display: grid; }
.al-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; }
.al-row + .al-row { box-shadow: inset 0 .5px 0 color-mix(in srgb, var(--al-ink) 14%, transparent); }
.al-row .ar-row-text b { color: inherit; } .al-row .ar-row-text small { opacity: .6; }
.al-n { width: 22px; text-align: center; font-size: 15px; opacity: .6; }
.al-time { font-size: 13px; opacity: .6; font-variant-numeric: tabular-nums; }
.al-mac { display: flex; gap: 24px; align-items: center; padding: 60px 24px 24px; }
.al-mac .al-title { justify-items: start; text-align: left; padding: 0 0 14px; }
.al-actions-mac { padding: 0; } .al-actions-mac .al-play { flex: none; padding: 0 22px; height: 32px; font-size: 14px; } .al-actions-mac .al-circle { width: 32px; height: 32px; }

/* ---- Made For You (TasteRailCard) ---- */
.mfy { flex: none; display: grid; gap: 8px; }
.mfy-art { position: relative; display: grid; grid-template-columns: 1fr 1fr; border-radius: 12px; overflow: hidden; }
.mfy-art i { position: absolute; inset: 0; }
.mfy-badge { position: absolute; left: 8px; bottom: 10px; display: flex; align-items: center; gap: 6px; color: #fff; font-size: 11px; font-weight: 600; white-space: nowrap; }
.mfy-play { position: absolute; right: 8px; bottom: 8px; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.92); color: rgba(0,0,0,.85); box-shadow: 0 2px 4px rgba(0,0,0,.25); }
.mfy b { font-size: 13px; font-weight: 500; margin-top: -4px; } .mfy small { font-size: 12px; color: var(--t-ink2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: -8px; }
.al-rows { text-align: left; }

/* ---- Library tab (LibraryHubView): the four Library Style layouts ---- */
.lh-title { flex: 1; font-size: 22px; }
.lh-list { background: var(--t-section); border-radius: 14px; }
.lh-list div { display: flex; align-items: center; gap: 12px; padding: 8px 12px; color: var(--accent); }
.lh-list div + div { box-shadow: inset 54px .5px 0 -54px transparent; border-top: .5px solid var(--t-div); margin-left: 0; }
.lh-list b { flex: 1; font-size: 17px; font-weight: 400; color: var(--t-ink); }
.lh-list .pv-ico:last-child { color: color-mix(in srgb, var(--t-ink2) 50%, transparent); }
.lh-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.lh-grid div { display: grid; justify-items: center; gap: 8px; padding: 16px 0; border-radius: 14px; background: var(--t-section); color: var(--accent); }
.lh-grid b { font-size: 13px; font-weight: 500; color: var(--t-ink); }
.lh-aes { display: grid; gap: 8px; }
.lh-aes div { display: flex; align-items: center; gap: 12px; padding: 14px 12px; color: var(--accent); }
.lh-aes b { font-size: 20px; font-weight: 400; color: var(--t-ink); }
.lh-cards { display: grid; gap: 8px; }
.lh-cards div { height: 84px; display: flex; align-items: center; padding: 0 14px; border-radius: 16px; color: var(--accent);
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 20%, transparent), color-mix(in srgb, var(--accent) 6%, transparent)); box-shadow: inset 0 0 0 .5px color-mix(in srgb, var(--accent) 25%, transparent); }
.lh-cards span { flex: 1; display: grid; gap: 2px; } .lh-cards b { font-size: 17px; font-weight: 600; color: var(--t-ink); } .lh-cards small { font-size: 12px; color: var(--t-ink2); }

/* ---- Player rows at the app's sizes ---- */
.pv-quality-stack { flex-direction: column; gap: 8px; }
.pv-format { font-size: 13px; letter-spacing: .02em; }
.pv-route { font-size: 13px; padding: 6px 12px; gap: 7px; }
.pv-times { font-size: 12px; margin-top: 10px; }
.pv-actions { min-height: 40px; }
.pv-stars { gap: 6px !important; display: inline-flex; }
.pv-bar { padding: 12px 6px; }
.pv-head { height: 39px; }
.pv-route-row { padding-block: 3px; }
.pv-actions { min-height: 52px; }
.pv-transport { padding-block: 6px; }
.pv-vol { padding-block: 4px; }
.pv-bar { padding: 15px 6px; }
