/* ?redesign=1 (owner 10/28, phase 1 desktop): cover is the single subject (55%), the star moves right at full size,
   a machine shell around the cover with nameplate + LCD (the only track number), one solid play row under it.
   Everything here is scoped to html[data-redesign]; without the flag the site is unchanged. */
html[data-redesign] .site-header nav a b{display:none}
html[data-redesign] .site-header nav a{font-size:16px}
html[data-redesign] .site-header nav a[aria-current]::before{content:'▶';margin-right:8px;font-size:9px;vertical-align:1px;color:var(--purple)}
@media(min-width:901px){
 html[data-redesign] body .h24{--sx:420;--l:calc(312*var(--u));--vw:calc(1056*var(--u));--vh:calc(var(--vw)*9/16)}
 html[data-redesign] body .h24 .tipv{left:var(--rd-left,calc(312*var(--u)))!important;width:var(--rd-w,var(--vw))!important;height:var(--rd-h,var(--vh))!important;top:var(--rd-top,calc(50% - var(--vh)/2 + 40*var(--u)))!important}
 html[data-redesign] .h24 .tipv .cap,html[data-redesign] .h24 .sel,html[data-redesign] .h24 .tipv .needle,html[data-redesign] .h24 .onote2{display:none}
 html[data-redesign] .h24 .mks .n{font-size:16px}html[data-redesign] .h24 .mks .mk.on .n{font-size:20px}
 html[data-redesign] .h24 .mks .s{font-size:12px}html[data-redesign] .h24 .mk.on .s{fill:rgba(212,215,224,.75)}
 html[data-redesign] .h24 .info .role span{font-size:16px}
}
html[data-redesign] .mk-shell{position:absolute;inset:-14px -14px -58px -14px;z-index:-1;border-radius:6px;
 background:linear-gradient(180deg,#2a2735,#14121c 40%,#0d0c13);
 box-shadow:inset 0 1px 0 rgba(255,255,255,.55),inset 0 -1px 0 rgba(0,0,0,.6),inset 1px 0 0 rgba(255,255,255,.12),inset -1px 0 0 rgba(0,0,0,.5),0 0 0 1px #3a3548,0 30px 60px -20px rgba(0,0,0,.9),0 0 40px -10px rgba(185,140,255,.25)}
html[data-redesign] .mk-shell::before{content:'';position:absolute;inset:10px 10px 54px 10px;border-radius:3px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.8),inset 0 2px 6px rgba(0,0,0,.9),0 1px 0 rgba(255,255,255,.18)}
html[data-redesign] .mk-plate{position:absolute;left:24px;right:24px;bottom:-46px;height:34px;display:flex;align-items:center;justify-content:space-between;gap:16px;z-index:4;pointer-events:none}
html[data-redesign] .mk-name{padding:6px 14px;font:700 10px/1 Manrope,sans-serif;letter-spacing:.24em;color:#1a1822;border-radius:2px;white-space:nowrap;
 background:linear-gradient(180deg,#f4f4f8,#b9b8c4 48%,#e8e8ef 52%,#a6a5b2);box-shadow:inset 0 1px 0 #fff,inset 0 -1px 0 rgba(0,0,0,.35),0 0 0 1px #57536a}
html[data-redesign] .mk-lcd{padding:6px 12px;font:600 12px/1 'Courier New',ui-monospace,monospace;letter-spacing:.18em;color:#b8ffe8;text-shadow:0 0 6px rgba(140,255,220,.6);white-space:nowrap;
 background:linear-gradient(180deg,#0b1513,#06100d);border-radius:2px;box-shadow:inset 0 0 0 1px #1d3a33,inset 0 2px 6px rgba(0,0,0,.8)}
html[data-redesign] .mk-row{position:absolute;left:0;top:calc(100% + 70px);display:flex;align-items:center;gap:18px;white-space:nowrap;z-index:4}
html[data-redesign] .mk-play{display:inline-flex;align-items:center;gap:10px;min-height:44px;padding:0 20px;font:600 16px Manrope,sans-serif;color:#0b0812;background:var(--purple);border:0;cursor:pointer;clip-path:polygon(0 0,calc(100% - 10px) 0,100% 10px,100% 100%,0 100%);box-shadow:0 0 24px rgba(185,140,255,.45)}
html[data-redesign] .mk-play:focus-visible{outline:2px solid #fff;outline-offset:3px}
html[data-redesign] .mk-role{font-size:16px;color:var(--mut)}
/* texture variant (?tex=1): Codex shell metal + nameplate as material only (blended, clipped to the shell / plate) */
html[data-redesign][data-tex] .mk-shell{background:linear-gradient(180deg,rgba(42,39,53,.5),rgba(13,12,19,.62) 45%,rgba(13,12,19,.7)),url('./assets/gen/redesign/shell-metal.webp') center/520px auto}
html[data-redesign][data-tex] .mk-name{background:linear-gradient(180deg,rgba(244,244,248,.32),rgba(185,184,196,.22) 48%,rgba(232,232,239,.28) 52%,rgba(166,165,178,.34)),url('./assets/gen/redesign/nameplate.webp') 50% 50%/330% auto}
/* phase 1 is desktop only; phones keep the current composition until phase 2 */
/* phase 2 — phone / small tablet (≤900px): own composition. Name → full-width cover in its shell → play row → six track keys.
   No thin lines behind the cover; only a small corner crosshair on the cover. */
@media(max-width:900px){
 html[data-redesign] body .h24{--l:16px;--vw:calc(100vw - 32px);--vh:calc(var(--vw)*9/16);height:auto!important;min-height:0!important;display:flex;flex-direction:column;padding:0 0 28px}
 html[data-redesign] .h24 .tipv .brk,html[data-redesign] .h24 .tipv .pt,html[data-redesign] .h24 .tipv .gl,html[data-redesign] .h24 .tipv .f25, html[data-redesign] .h24 .art,html[data-redesign] .h24 .mo-rings,html[data-redesign] .h24 .mks,html[data-redesign] .h24 .sel,html[data-redesign] .h24 .tipv .cap,html[data-redesign] .h24 .tipv .needle{display:none!important}
 html[data-redesign] .h24 .info{order:-1;position:relative!important;inset:auto!important;transform:none!important;padding:28px 16px 12px;margin:0}
 html[data-redesign] body .h24 .tipv{position:relative!important;left:auto!important;top:auto!important;margin:22px 16px 0;width:auto!important;height:calc((100vw - 32px)*9/16)!important}
 html[data-redesign] .mk-shell{inset:-8px -8px -48px -8px}html[data-redesign] .mk-shell::before{inset:6px 6px 46px 6px}
 html[data-redesign] .mk-plate{left:12px;right:12px;bottom:-40px;gap:8px}
 html[data-redesign] .mk-name{font-size:10px;letter-spacing:.1em;padding:5px 7px;min-width:0;overflow:hidden;text-overflow:ellipsis}html[data-redesign] .mk-lcd{font-size:11px;letter-spacing:.06em;padding:5px 7px;flex:none}
 html[data-redesign] .mk-row{position:static;margin:66px 16px 0;flex-wrap:wrap;white-space:normal;gap:10px 16px}
 html[data-redesign] .mk-x{position:absolute;right:6px;top:6px;width:18px;height:18px;z-index:5;pointer-events:none}
 html[data-redesign] .mk-x::before,html[data-redesign] .mk-x::after{content:'';position:absolute;background:rgba(246,241,226,.8)}
 html[data-redesign] .mk-x::before{left:8px;top:0;width:1px;height:18px}html[data-redesign] .mk-x::after{top:8px;left:0;height:1px;width:18px}
 html[data-redesign] .mk-keys{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin:18px 16px 0}
 html[data-redesign] .mk-key{position:relative;min-height:52px;padding:8px 12px;text-align:left;font:600 16px/20px Manrope,sans-serif;color:var(--ink);background:#120f1b;border:1px solid var(--line);cursor:pointer}
 html[data-redesign] .mk-key[aria-pressed="true"]{border-color:var(--purple);color:#fff}
 html[data-redesign] .mk-key[aria-pressed="true"]::before,html[data-redesign] .mk-key[aria-pressed="true"]::after{content:'';position:absolute;width:8px;height:8px;border:1px solid var(--purple)}
 html[data-redesign] .mk-key[aria-pressed="true"]::before{left:-4px;top:-4px;border-right:0;border-bottom:0}html[data-redesign] .mk-key[aria-pressed="true"]::after{right:-4px;bottom:-4px;border-left:0;border-top:0}
 html[data-redesign] .mk-key small{display:block;font-size:12px;line-height:16px;font-weight:500;color:var(--mut)}
}
@media(min-width:901px){html[data-redesign] .mk-keys,html[data-redesign] .mk-x{display:none}}

/* R19: the old corner crescent (e10-c) peeks out of the new shell as a sliver; the shell replaces it */
html[data-redesign] .h24 .tipv::after{display:none}
/* track labels are clickable: never below 12px on screen or .45 opacity (font size set from the drawing scale in redesign.js) */
@media(min-width:901px){
 html[data-redesign] .h24 .mk{opacity:1!important}
 html[data-redesign] .h24 .mks .n{font-size:var(--rd-n,16px);fill:rgba(238,237,244,.74)}
 html[data-redesign] .h24 .mks .mk.on .n{font-size:var(--rd-on,20px);fill:#fff}
 html[data-redesign] .h24 .mks .s{font-size:var(--rd-s,12px);fill:rgba(212,215,224,.66)}
}

/* ===== strip under the cover: owner picked plate 2 (one-piece instrument strip), 10/28; data-plate="2" is set by default in redesign.js =====
   common: no purple brackets on non-clickables (cool white, low), no stray grey dash (f25 frame tick), 20px air above the play row */
html[data-plate] .h24 .tipv .brk,html[data-plate] .h24.h24-lock .tipv .brk{border-color:rgba(233,236,255,.28)!important}
html[data-plate] .h24 .tipv .f25{display:none}
html[data-plate] .mk-row{top:calc(100% + 70px)}
/* 2 one-piece instrument strip: a recessed groove across the shell, pale violet-white LED readout, hairline ticks between */
html[data-plate="2"] .h24 .tipv .brk{display:none}
html[data-plate="2"] .mk-plate{left:10px;right:10px;bottom:-48px;height:36px;padding:0 16px;background:linear-gradient(180deg,#0b0a10,#121019);box-shadow:inset 0 2px 5px rgba(0,0,0,.85),inset 0 1px 0 rgba(0,0,0,.9),0 1px 0 rgba(255,255,255,.08);border-top:1px solid rgba(233,236,255,.1);border-bottom:1px solid rgba(233,236,255,.06)}
html[data-plate="2"] .mk-plate::before{content:'';position:absolute;left:max(30%,310px);right:22%;top:50%;height:8px;margin-top:-4px;background:repeating-linear-gradient(90deg,rgba(233,236,255,.22) 0 1px,transparent 1px 24px);pointer-events:none}
html[data-plate="2"] .mk-name{background:none!important;box-shadow:none;padding:0;font-size:10px;letter-spacing:.22em;color:rgba(233,236,255,.5)}
html[data-plate="2"] .mk-lcd{background:none;box-shadow:none;padding:0;font-size:12px;color:#e7deff;text-shadow:0 0 6px rgba(200,180,255,.55)}
@media(max-width:900px){
 html[data-plate] .mk-row{margin-top:64px}
 html[data-plate="2"] .mk-plate{left:6px;right:6px;bottom:-42px;height:32px;padding:0 10px}
 html[data-plate="2"] .mk-plate::before{left:52%;right:30%}
 html[data-plate="2"] .mk-name{font-size:9px;letter-spacing:.16em}
}

/* the details link under the cover (same solid purple, it is clickable); a short lock-on flash on the card it opens */
html[data-redesign] a.mk-play{text-decoration:none}
html[data-redesign] a.mk-play[hidden]{display:none}
.rd-flash{animation:rd-flash 1.2s ease-out}
@keyframes rd-flash{0%,30%{outline:2px solid #b98cff;outline-offset:6px}100%{outline:2px solid transparent;outline-offset:12px}}
@media(prefers-reduced-motion:reduce){.rd-flash{animation:none;outline:2px solid #b98cff;outline-offset:6px}}
/* R19: never a white cover — black behind the video and the poster stays until the player reports playing */
.h24 .tipv .scr,.h24 .tipv .scr iframe{background:#000}
/* R19: while the hero is on screen the floating mini video stays out of the way of the clickable track titles */
@media(min-width:761px){body.hero-in .player-media.is-mini{opacity:0;pointer-events:none;transform:translateY(12px);transition:opacity .25s,transform .25s}}
/* R19: phones — the last row can scroll above the fixed player bar */
@media(max-width:760px){body:has(#player:not([hidden])) main{padding-bottom:calc(var(--dock-h,102px) + 16px)}}

/* R20: plate 2 ticks read as stray bars when only a few fit, so drop them on narrow plates */
@media(max-width:900px){html[data-plate="2"] .mk-plate::before{display:none}}
/* R20: reserve two lines for the work note on phones so the keys below never jump between tracks */
@media(max-width:900px){html[data-redesign] .mk-role{min-height:2lh;flex-basis:100%}}

/* name as a quiet signature, not the subject (owner 10/28): ~64px at 1920, ~48px at 1280, 34px on phones/tablets */
html[data-redesign] .h24 .info h1{font-size:clamp(40px,calc(2.5vw + 16px),64px)!important;margin-bottom:14px}
html[data-redesign] .h24 .info .role span{font-size:14px}
@media(max-width:900px){html[data-redesign] .h24 .info h1{font-size:34px!important}}
/* the work note may wrap to two lines beside the button; the row keeps one fixed height so switching tracks never shifts it */
@media(min-width:901px){html[data-redesign] .mk-row{white-space:normal}html[data-redesign] .mk-role{display:flex;align-items:center;min-height:48px;line-height:24px}html[data-redesign] .mk-play{flex:none}}
/* small desktop cover: the strip keeps only the track readout (model text and ticks would not fit) */
html[data-redesign] .h24.rd-narrow .mk-name,html[data-redesign] .h24.rd-narrow .mk-plate::before{display:none}html[data-redesign] .h24.rd-narrow .mk-plate{justify-content:flex-end}
html[data-redesign] .h24.rd-narrow .mk-role{font-size:13px;white-space:nowrap}
/* desktop: the signature sits 24px under the header so the cover gets the height */
@media(min-width:901px){html[data-redesign] .h24 .info{top:var(--rd-itop,24px)!important;bottom:auto!important}}
/* CJK titles on the arc render visibly smaller than latin at the same size; give them ~15% more so all six read alike */
html[data-redesign] .h24 .mks .mk .n.cjk{font-size:calc(var(--rd-n,16px) * 1.15)}html[data-redesign] .h24 .mks .mk.on .n.cjk{font-size:calc(var(--rd-on,20px) * 1.15)}
