:root{
  --ink:#121212;--muted:#7a756c;--bg:#f4f2ee;--floor:#e2ded6;--line:rgba(18,18,18,.14);--accent:#b2532f;
  --ease-out:cubic-bezier(.22,1,.36,1);--ease-io:cubic-bezier(.7,0,.2,1);
  font-family:Heebo,"Segoe UI",Arial,sans-serif;color:var(--ink);
}
*{box-sizing:border-box}
html,body{margin:0;height:100%;overflow:hidden;background:var(--bg)}
button{font:inherit;color:inherit;background:none;border:0;cursor:pointer;padding:0}
button:focus-visible,a:focus-visible{outline:2px solid var(--ink);outline-offset:4px}
#scene{position:fixed;inset:0;width:100%;height:100%;touch-action:none;outline:none;display:block}
body[data-state=intro] #scene{cursor:pointer}
body[data-state=room] #scene{cursor:grab}
body[data-state=room] #scene.dragging{cursor:grabbing}
body[data-state=room] #scene.over{cursor:zoom-in}

/* Warm light that floods through the opening doors (reference: radial glow 0→1→0 over ~1.4s). */
#flash{position:fixed;inset:0;pointer-events:none;opacity:0;
  background:radial-gradient(34% 58% at 50% 44%,rgba(255,250,240,.55),rgba(255,250,240,.12) 55%,transparent)}

.top{position:fixed;top:0;left:0;right:0;z-index:3;display:flex;justify-content:space-between;align-items:center;
  padding:22px clamp(16px,3vw,40px);pointer-events:none}
.top>*{pointer-events:auto}
.brand{display:flex;align-items:baseline;gap:10px;text-decoration:none;color:inherit}
.brand b{font-weight:800;font-size:22px;letter-spacing:-.02em}
.brand small{font-size:10px;letter-spacing:.24em;color:var(--muted)}
.show{font-size:10px;letter-spacing:.24em;color:var(--muted)}

/* Intro sits on the floor strip under the doors, like the reference's 20% floor band. */
#intro-ui{position:fixed;left:0;right:0;bottom:0;height:20svh;z-index:3;display:flex;flex-direction:column;align-items:center;
  justify-content:flex-start;gap:14px;padding-top:max(18px,3.2svh);text-align:center;transition:opacity .25s ease}
#enter{background:var(--ink);color:#fff;font-size:13px;font-weight:500;padding:10px 20px;border-radius:2px;
  margin-top:-38px;opacity:0;transform:translateY(8px);transition:opacity .4s ease,transform .6s var(--ease-out)}
#enter:not([disabled]){opacity:1;transform:none}
#enter:hover{background:#000}
#intro-ui p{margin:0;font-size:13px;color:#4c4943;max-width:46ch;line-height:1.5}
#progress{font-size:10px;letter-spacing:.14em;color:var(--muted)}
body:not([data-state=intro]) #intro-ui{opacity:0;pointer-events:none}

#room-ui{position:fixed;left:0;right:0;bottom:0;z-index:3;display:grid;grid-template-columns:1fr auto 1fr;align-items:end;gap:16px;
  padding:0 clamp(16px,3vw,40px) 22px;opacity:0;transform:translateY(12px);pointer-events:none;
  transition:opacity .6s ease,transform .9s var(--ease-out)}
body[data-state=room] #room-ui{opacity:1;transform:none;pointer-events:auto}
.now{display:flex;flex-direction:column;gap:6px}
#count{font-size:10px;letter-spacing:.2em;color:var(--muted);text-align:right}
#name{font-weight:400;font-size:clamp(20px,2vw,28px);letter-spacing:-.02em;line-height:1}
#dots{display:flex;gap:6px}
#dots button{font-size:11px;letter-spacing:.08em;width:38px;padding:10px 0 8px;color:var(--muted);border-top:1px solid var(--line);
  transition:color .3s,border-color .3s}
#dots button[aria-current=true]{color:var(--ink);border-top:2px solid var(--accent)}
#dots button:hover{color:var(--ink)}
.actions{display:flex;gap:22px;justify-content:flex-end;font-size:12px}
.actions button{padding:8px 0;border-bottom:1px solid var(--line)}
kbd{font:inherit;font-size:10px;color:var(--muted);margin-inline-start:4px}
#hint{position:fixed;top:64px;left:0;right:0;text-align:center;margin:0;font-size:10px;letter-spacing:.06em;color:var(--muted);
  z-index:3;opacity:0;transition:opacity .6s ease 1s;pointer-events:none}
body[data-state=room] #hint{opacity:1}

/* Caption anchored under the active work; lines reveal from a mask (reference: 0.9s, 60ms stagger). */
.caption{position:fixed;left:0;top:0;width:280px;margin-left:-140px;text-align:center;z-index:2;pointer-events:none;will-change:transform}
.ln{display:block;overflow:hidden;padding-bottom:.08em}
.li{display:inline-block;transform:translateY(110%);transition:transform .5s cubic-bezier(.55,0,.45,1)}
.caption.in .li{transform:none;transition:transform .9s var(--ease-out)}
.caption.in .ln:nth-child(2) .li{transition-delay:.06s}
.caption.in .ln:nth-child(3) .li{transition-delay:.12s}
.num{font-size:10px;letter-spacing:.2em;color:var(--muted)}
.title{font-size:22px;font-weight:500;letter-spacing:-.02em;margin-top:4px}
.note{font-size:12px;color:#55524c;margin-top:4px;line-height:1.45}

#error{position:fixed;inset:0;display:grid;place-content:center;text-align:center;background:var(--bg);z-index:9}
#error[hidden]{display:none}

@media (max-width:760px){
  .brand b{font-size:19px}.show{display:none}
  #room-ui{grid-template-columns:1fr;justify-items:center;gap:12px;padding-bottom:max(16px,env(safe-area-inset-bottom))}
  .now{align-items:center}#count{text-align:center}
  .actions{justify-content:center}
  #hint{display:none}
  .title{font-size:19px}
}
@media (prefers-reduced-motion:reduce){*:not(#flash){transition:none!important;animation:none!important}}

/* ---- Premium layer (from modern-web-design principles: fluid type, restrained palette, purposeful micro-motion) ---- */
:root{--serif:"Frank Ruhl Libre",Georgia,serif;--paper:rgba(250,249,246,.88)}
button:focus-visible,a:focus-visible{outline-width:3px}

/* Loading line across the top, then gone. */
#bar{position:fixed;top:0;left:0;right:0;height:2px;background:var(--ink);transform:scaleX(0);transform-origin:100% 50%;z-index:6;transition:transform .3s ease,opacity .6s ease .3s}
body.ready #bar{opacity:0}

/* Entrance button: quiet weight, wide tracking, magnetic pull (translate set from JS). */
#enter{letter-spacing:.04em;padding:13px 26px;border-radius:999px;min-height:44px;transition:opacity .4s ease,transform .6s var(--ease-out),translate .45s var(--ease-out),background .25s}
#enter::after{content:"←";display:inline-block;margin-inline-start:10px;transition:transform .35s var(--ease-out)}
#enter:hover::after{transform:translateX(-4px)}
#enter:active{transform:scale(.97)}

/* Custom cursor: a ring that trails the pointer and names the action. */
#cursor{position:fixed;left:0;top:0;z-index:20;pointer-events:none;opacity:0;transition:opacity .3s}
#cursor.on{opacity:1}
#cursor::before{content:"";position:absolute;width:10px;height:10px;left:-5px;top:-5px;border-radius:50%;background:var(--ink);
  transition:width .35s var(--ease-out),height .35s var(--ease-out),left .35s var(--ease-out),top .35s var(--ease-out),background .3s,border-color .3s}
#cursor span{position:absolute;left:0;top:0;transform:translate(-50%,-50%);font-size:11px;font-weight:500;letter-spacing:.06em;color:#fff;white-space:nowrap;opacity:0;transition:opacity .2s}
#cursor[data-mode=link]::before{width:44px;height:44px;left:-22px;top:-22px;background:transparent;border:1px solid var(--ink)}
#cursor[data-mode=enter]::before,#cursor[data-mode=zoom]::before,#cursor[data-mode=turn]::before{width:88px;height:88px;left:-44px;top:-44px;background:rgba(18,18,18,.86);backdrop-filter:blur(6px)}
#cursor[data-mode=enter] span,#cursor[data-mode=zoom] span,#cursor[data-mode=turn] span{opacity:1}
body.has-cursor #scene,body.has-cursor #scene.over,body.has-cursor #scene.dragging{cursor:none}

/* Museum wall label for the inspected work (wide screens). */
#plaque{position:fixed;left:clamp(24px,5vw,80px);top:50%;width:min(340px,28vw);z-index:3;translate:0 -50%;
  padding:30px 30px 24px;background:var(--paper);backdrop-filter:blur(14px) saturate(160%);-webkit-backdrop-filter:blur(14px) saturate(160%);
  border:1px solid rgba(255,255,255,.6);box-shadow:0 30px 60px -30px rgba(40,34,24,.25);
  opacity:0;transform:translateY(16px);pointer-events:none;transition:opacity .45s ease,transform .7s var(--ease-out)}
#plaque.in{opacity:1;transform:none;transition-delay:.25s}
.p-head{display:flex;justify-content:space-between;align-items:baseline;border-bottom:1px solid var(--line);padding-bottom:14px}
.p-num{font-family:var(--serif);font-size:44px;line-height:.8;font-weight:400}
.p-en{font-size:9px;letter-spacing:.22em;color:var(--muted)}
#plaque h2{font-family:var(--serif);font-weight:500;font-size:clamp(30px,1.6rem + 1.2vw,44px);letter-spacing:-.01em;margin:20px 0 8px;line-height:1.05}
#plaque p{margin:0 0 20px;font-size:14px;line-height:1.6;color:#4d4a44}
#plaque dl{margin:0;display:grid;gap:0}
#plaque dl div{display:flex;justify-content:space-between;align-items:center;padding:9px 0;border-top:1px solid var(--line);font-size:12px}
#plaque dt{color:var(--muted)}
#plaque dd{margin:0;display:flex;align-items:center;gap:8px}
#p-swatch{width:12px;height:12px;border-radius:50%;box-shadow:inset 0 0 0 1px rgba(0,0,0,.15)}
#p-hex{font-size:10px;letter-spacing:.08em;color:var(--muted)}
#plaque small{display:block;margin-top:18px;font-size:10px;line-height:1.6;color:var(--muted)}

/* Editorial serif for names; fluid sizes. */
#name,.title{font-family:var(--serif);font-weight:500}
#name{font-size:clamp(24px,1.2rem + 1.2vw,36px)}
.title{font-size:clamp(20px,1.1rem + .6vw,26px)}
#dots button{min-height:44px;transition:color .3s,border-color .3s,transform .3s var(--ease-out)}
#dots button:hover{transform:translateY(-2px)}
.actions button{min-height:44px;transition:border-color .3s}
.actions button:hover{border-color:var(--ink)}
@media (max-width:960px){#plaque{display:none}}

/* ---- Apple HIG pass: legible minimums (desktop ≥ 12px), 4.5:1 contrast for small text, reduced transparency ---- */
:root{--muted:#68635b}
.brand small,.show,#count,#progress,.num,.p-en,#p-hex,kbd{font-size:12px}
#hint{font-size:12px;color:#5f5a53}
#dots button{font-size:12px}
#plaque small{font-size:12px}
@media (prefers-reduced-transparency:reduce){#plaque{background:#faf9f6;backdrop-filter:none;-webkit-backdrop-filter:none}
  #cursor[data-mode=enter]::before,#cursor[data-mode=zoom]::before,#cursor[data-mode=turn]::before{backdrop-filter:none;background:#121212}}
@media (prefers-contrast:more){:root{--muted:#3f3b35;--line:rgba(18,18,18,.4)}}

/* Entrance framing now shows the whole portal: keep the call to action low and compact on the floor. */
#intro-ui{height:auto;bottom:max(14px,2.2svh);padding-top:0;gap:8px}
#enter{margin-top:0;box-shadow:0 10px 30px -10px rgba(30,20,10,.5)}
#intro-ui p{display:none}
#progress{color:#4f4a43}

/* Orders: a pill in the header, and a panel beside the studio corner. */
.top{gap:18px}
.order-pill{margin-inline-start:auto;margin-inline-end:24px;background:var(--accent);color:#fff;font-size:13px;font-weight:500;letter-spacing:.04em;
  padding:10px 20px;min-height:44px;border-radius:999px;box-shadow:0 8px 24px -10px rgba(120,50,20,.6);transition:transform .3s var(--ease-out),background .25s}
.order-pill:hover{background:#9a4526;transform:translateY(-1px)}
#orders{position:fixed;left:clamp(24px,5vw,80px);top:50%;width:min(360px,30vw);z-index:3;translate:0 -50%;padding:32px 30px 26px;
  background:var(--paper);backdrop-filter:blur(14px) saturate(160%);-webkit-backdrop-filter:blur(14px) saturate(160%);border:1px solid rgba(255,255,255,.6);
  box-shadow:0 30px 60px -30px rgba(40,34,24,.3);opacity:0;transform:translateY(16px);pointer-events:none;transition:opacity .45s ease,transform .7s var(--ease-out)}
#orders.in{opacity:1;transform:none;pointer-events:auto;transition-delay:.35s}
#orders h2{font-family:var(--serif);font-weight:500;font-size:clamp(32px,1.6rem + 1.2vw,46px);margin:16px 0 10px;line-height:1}
#orders p{margin:0 0 22px;font-size:14px;line-height:1.65;color:#4d4a44}
.cta{display:inline-flex;align-items:center;min-height:48px;padding:0 26px;border-radius:999px;background:var(--ink);color:#fff;text-decoration:none;font-weight:500;cursor:pointer;
  transition:transform .3s var(--ease-out),background .25s}
.cta:hover{transform:translateY(-2px);background:#000}
.cta[aria-disabled=true]{opacity:.45;cursor:not-allowed;transform:none}
#orders small{display:block;margin-top:14px;font-size:12px;color:var(--muted)}
@media (max-width:960px){
  #orders{left:16px;right:16px;width:auto;top:auto;bottom:150px;translate:none;padding:22px}
  .order-pill{margin-inline-end:0;padding:9px 16px}
}
@media (prefers-reduced-transparency:reduce){#orders{background:#faf9f6;backdrop-filter:none;-webkit-backdrop-filter:none}}

/* Music toggle: a quiet round button beside the orders pill; a diagonal line when muted. */
.sound{width:44px;height:44px;border-radius:50%;border:1px solid var(--line);background:rgba(250,249,246,.7);backdrop-filter:blur(8px);font-size:18px;position:relative;
  margin-inline-end:10px;transition:background .25s,transform .3s var(--ease-out)}
.sound:hover{background:#fff;transform:translateY(-1px)}
.sound.off::after{content:"";position:absolute;left:11px;right:11px;top:50%;height:1.5px;background:var(--ink);transform:rotate(-45deg)}
.sound[hidden]{display:none}

/* Phones: the orders panel is a compact card at the bottom, and the index row steps aside while it is open. */
@media (max-width:960px){
  #orders{bottom:max(14px,env(safe-area-inset-bottom));padding:16px 18px 14px}
  #orders .p-en{display:none}
  #orders h2{font-size:26px;margin:0 0 6px}
  #orders p{font-size:13px;line-height:1.5;margin:0 0 12px}
  #orders small:empty{display:none}
  .cta{min-height:44px;padding:0 20px;font-size:14px}
  body.in-corner #room-ui{opacity:0;pointer-events:none}
}

.orders-back{display:inline-flex;align-items:center;min-height:44px;margin-inline-start:16px;font-size:13px;color:var(--muted);border-bottom:1px solid var(--line)}
.orders-back:hover{color:var(--ink);border-color:var(--ink)}

/* The work's note sits under its name in the bottom bar on phones (wide screens show it on the plaque). */
#note{display:none;font-size:13px;color:#4d4a44;line-height:1.4;max-width:34ch}
@media (max-width:960px){#note:not(:empty){display:block;text-align:center}}

#cursor[data-mode=studio]::before{width:88px;height:88px;left:-44px;top:-44px;background:rgba(18,18,18,.86);backdrop-filter:blur(6px)}
#cursor[data-mode=studio] span{opacity:1}

/* ---- Finish & size picker: inside the plaque on wide screens, a bottom sheet on phones ---- */
#custom{display:none}
body.can-custom #custom{display:block}
#plaque #custom{margin-top:18px;padding-top:16px;border-top:1px solid var(--line);pointer-events:auto}
#plaque.in{pointer-events:auto}
.c-head{display:flex;align-items:baseline;gap:10px;margin-bottom:10px}
.c-head b{font-family:var(--serif);font-weight:500;font-size:18px}
.c-summary{font-size:12px;color:var(--muted)}
.c-close{margin-inline-start:auto;width:44px;height:44px;font-size:22px;color:var(--muted);display:none}
.c-row{display:flex;align-items:center;gap:12px;margin:8px 0}
.c-label{font-size:12px;color:var(--muted);min-width:34px}
.c-finishes,.c-sizes{display:flex;flex-wrap:wrap;gap:8px}
.c-swatch{width:30px;height:30px;border-radius:50%;background:var(--c);box-shadow:inset 0 0 0 1px rgba(0,0,0,.18);position:relative;transition:transform .25s var(--ease-out)}
.c-swatch.own{background:conic-gradient(#d2d6d8,#f3cbd3,#c8b08c,#2a2b2d,#d2d6d8)}
.c-swatch:hover{transform:scale(1.08)}
.c-swatch[aria-pressed=true]{box-shadow:0 0 0 2px var(--paper),0 0 0 3.5px var(--ink)}
.c-size{font-size:12px;padding:8px 12px;min-height:36px;border:1px solid var(--line);border-radius:999px;transition:border-color .25s,background .25s}
.c-size[aria-pressed=true]{border-color:var(--ink);background:var(--ink);color:#fff}
.c-actions{display:flex;flex-wrap:wrap;align-items:center;gap:12px;margin-top:14px}
.c-ar{min-height:44px;font-size:13px;border-bottom:1px solid var(--ink);padding:0 2px}
.custom-toggle{display:none;margin-top:8px;font-size:13px;font-weight:500;min-height:40px;padding:0 16px;border-radius:999px;background:var(--ink);color:#fff}
@media (max-width:960px){
  body.can-custom .custom-toggle{display:inline-flex;align-items:center;align-self:center}
  body.can-custom #custom{display:none}
  body.can-custom.custom-open #custom{display:block;position:fixed;left:12px;right:12px;bottom:max(12px,env(safe-area-inset-bottom));z-index:6;padding:14px 16px 16px;
    background:rgba(250,249,246,.96);backdrop-filter:blur(14px);border:1px solid rgba(255,255,255,.6);box-shadow:0 20px 50px -20px rgba(40,34,24,.45)}
  body.custom-open #room-ui{opacity:0;pointer-events:none}
  .c-close{display:inline-flex;align-items:center;justify-content:center}
  .c-swatch{width:34px;height:34px}
}
/* AR dialog */
.ar-dialog{width:min(560px,94vw);border:0;padding:16px;background:#faf9f6;color:var(--ink);box-shadow:0 30px 80px -20px rgba(0,0,0,.5)}
.ar-dialog::backdrop{background:rgba(20,16,12,.55);backdrop-filter:blur(6px)}
.ar-head{display:flex;align-items:center;justify-content:space-between}
.ar-head b{font-family:var(--serif);font-size:22px;font-weight:500}
.ar-head .c-close{display:inline-flex;align-items:center;justify-content:center}
.ar-host model-viewer{width:100%;height:min(62vh,520px);background:#efe9df;--poster-color:#efe9df}
.ar-host .cta{position:absolute;bottom:14px;left:50%;transform:translateX(-50%)}
.ar-note{font-size:13px;color:#4d4a44;margin:10px 0 0;text-align:center}

/* "On my wall" preview: the visitor's photo with the flame placed over it */
.wall-stage{position:relative;overflow:hidden;margin:10px auto 0;touch-action:none;user-select:none;-webkit-user-select:none;
  background:#e9e3d8 center/100% 100% no-repeat;background-image:linear-gradient(180deg,#efe9df,#e2dacd)}
.wall-stage model-viewer{position:absolute;background:transparent;--poster-color:transparent;pointer-events:none;filter:drop-shadow(6px 14px 14px rgba(30,20,10,.38))}
.wall-hint{position:absolute;inset:auto 0 12px;text-align:center;font-size:12px;color:#6d675e}
.wall-stage.has-photo .wall-hint{display:none}
.wall-tools{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:12px;margin-top:12px}
.wall-photo{cursor:pointer}
.wall-size{flex:1 1 120px;accent-color:var(--ink)}

/* Studio photo, full size */
.project-dialog{width:min(1100px,96vw);max-height:94vh;border:0;padding:12px;background:#faf9f6;color:var(--ink);box-shadow:0 30px 80px -20px rgba(0,0,0,.5)}
.project-dialog::backdrop{background:rgba(20,16,12,.7);backdrop-filter:blur(6px)}
.project-dialog img{display:block;width:100%;max-height:80vh;object-fit:contain;background:#efe9df}
.project-dialog p{margin:10px 4px 2px;font-size:14px}
.project-dialog #project-place{color:var(--muted)}
.project-dialog .c-close{display:inline-flex;align-items:center;justify-content:center;position:absolute;top:14px;left:14px;background:rgba(250,249,246,.9);border-radius:50%}

/* Contact remains available when WebGL or the primary model cannot load. */
#error{gap:14px;padding:24px}#error h2,#error p{margin:0}#error .cta{min-height:44px;display:flex;align-items:center;justify-content:center;text-decoration:none}

/* --- Walk mode --- */
.game-btn{color:var(--accent)!important}
#game-ui{position:fixed;inset:0;z-index:4;pointer-events:none;opacity:0;transition:opacity .35s ease}
body.game-on #game-ui{opacity:1}
body.game-on #game-ui>*{pointer-events:auto}
body.game-on #room-ui,body.game-on #hint,body.game-on #plaque,body.game-on #custom{opacity:0!important;pointer-events:none!important}
body.game-on #cursor,body.game-on .top .order-pill{display:none}
#game-pad{position:absolute;inset:0;touch-action:none;cursor:grab}
#game-pad:active{cursor:grabbing}
#game-stick{position:absolute;left:0;top:0;width:120px;height:120px;margin:-60px 0 0 -60px;border-radius:50%;
  border:1.5px solid rgba(255,255,255,.75);background:rgba(18,18,18,.18);backdrop-filter:blur(4px);opacity:0;transition:opacity .15s;pointer-events:none!important}
#game-stick.on{opacity:1}
#game-knob{position:absolute;left:50%;top:50%;width:48px;height:48px;margin:-24px 0 0 -24px;border-radius:50%;background:rgba(255,255,255,.9);box-shadow:0 2px 10px rgba(0,0,0,.25)}
.game-exit{position:absolute;top:max(70px,calc(env(safe-area-inset-top) + 58px));left:16px;background:rgba(18,18,18,.82);color:#fff;font-size:12px;font-weight:500;
  padding:9px 14px;border-radius:999px;backdrop-filter:blur(6px)}
.game-use{position:absolute;bottom:max(26px,env(safe-area-inset-bottom));left:50%;transform:translateX(-50%);background:var(--ink);color:#fff;
  font-size:14px;font-weight:500;padding:12px 20px;border-radius:999px;box-shadow:0 6px 20px rgba(0,0,0,.2);white-space:nowrap}
.game-use[hidden]{display:none}
.game-jump{position:absolute;right:22px;bottom:max(30px,env(safe-area-inset-bottom));width:68px;height:68px;border-radius:50%;
  background:rgba(18,18,18,.55);color:#fff;font-size:26px;backdrop-filter:blur(6px);display:none}
.game-hint{position:absolute;top:max(118px,calc(env(safe-area-inset-top) + 106px));left:0;right:0;margin:0 auto;max-width:92vw;text-align:center;
  font-size:12px;color:#fff;text-shadow:0 1px 6px rgba(0,0,0,.55);transition:opacity .8s ease;pointer-events:none!important}
.game-hint.gone{opacity:0}
.touch-only{display:none}
@media (pointer:coarse){
  .game-jump{display:block}
  .touch-only{display:inline}.fine-only{display:none}
  .game-use{bottom:max(112px,calc(env(safe-area-inset-bottom) + 96px))}
}

/* --- Radio pill: what is playing, tap for the next song --- */
.radio{display:flex;align-items:center;gap:9px;height:44px;max-width:min(260px,46vw);padding:0 14px 0 12px;margin-inline-end:10px;border-radius:999px;
  border:1px solid var(--line);background:rgba(250,249,246,.7);backdrop-filter:blur(8px);transition:background .2s,transform .2s}
.radio:hover{background:#fff;transform:translateY(-1px)}
.radio[hidden]{display:none}
.r-txt{display:flex;flex-direction:column;align-items:flex-start;min-width:0;line-height:1.15}
.r-txt small{font-size:9px;letter-spacing:.14em;color:var(--muted)}
#radio-name{font-size:12px;font-weight:500;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}
.radio.tick #radio-name{animation:r-in .6s var(--ease-out)}
@keyframes r-in{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:none}}
.r-next{font-size:12px;color:var(--muted)}
.r-bars{display:flex;align-items:flex-end;gap:2px;height:14px;flex:none}
.r-bars b{width:3px;background:var(--accent);border-radius:1px;animation:r-bar 1s ease-in-out infinite}
.r-bars b:nth-child(2){animation-delay:-.35s}.r-bars b:nth-child(3){animation-delay:-.7s}
@keyframes r-bar{0%,100%{height:4px}50%{height:14px}}
.sound.off~.radio .r-bars b,.radio:has(~.sound.off) .r-bars b{animation:none;height:4px}
@media (max-width:700px){.radio{max-width:none;flex:none;padding:0 10px;gap:6px;margin-inline-end:6px}.r-txt small,.r-next{display:none}#radio-name{font-size:11px}}
@media (prefers-reduced-motion:reduce){.r-bars b{animation:none;height:8px}}

/* --- Game-mode button: dark pill, a slow flame-coloured ring running round it, gamepad icon --- */
@property --spin{syntax:'<angle>';inherits:false;initial-value:0deg}
.game-cta{position:relative;display:inline-flex;align-items:center;gap:10px;color:#fff;background:#141210;border-radius:999px;isolation:isolate;
  box-shadow:0 8px 26px rgba(178,83,47,.35),0 2px 6px rgba(0,0,0,.25);transition:transform .25s var(--ease-out),box-shadow .25s}
.game-cta::before{content:"";position:absolute;inset:-2px;border-radius:inherit;z-index:-1;
  background:conic-gradient(from var(--spin),#b2532f,#f0a23a,#ffe0a0,#e2541b,#b2532f);animation:cta-spin 3.2s linear infinite}
.game-cta::after{content:"";position:absolute;inset:0;border-radius:inherit;z-index:-1;background:#141210}
.game-cta:hover{transform:translateY(-2px) scale(1.03);box-shadow:0 12px 34px rgba(226,84,27,.45),0 2px 6px rgba(0,0,0,.25)}
.game-cta:active{transform:scale(.97)}
@keyframes cta-spin{to{--spin:360deg}}
.pad-ico{width:26px;height:18px;flex:none;fill:#f0a23a;filter:drop-shadow(0 0 6px rgba(240,162,58,.55));animation:pad-bob 2.4s ease-in-out infinite}
.pad-mark{stroke:#141210;stroke-width:1.9;stroke-linecap:round;fill:none}
.pad-dot{fill:#141210}
@keyframes pad-bob{0%,100%{transform:rotate(-6deg)}50%{transform:rotate(6deg) translateY(-1px)}}
.game-intro{font-size:13px;font-weight:500;padding:10px 18px 10px 16px;opacity:0;pointer-events:none;transition:opacity .5s ease .2s,transform .25s var(--ease-out)}
body.ready .game-intro{opacity:1;pointer-events:auto}
.game-fab{position:fixed;z-index:4;top:max(76px,calc(env(safe-area-inset-top) + 64px));left:16px;padding:9px 18px 9px 14px;
  opacity:0;pointer-events:none;transform:translateY(-6px);transition:opacity .5s ease,transform .5s var(--ease-out)}
body[data-state=room]:not(.game-on):not(.custom-open) .game-fab{opacity:1;pointer-events:auto;transform:none}
.fab-txt{display:flex;flex-direction:column;align-items:flex-start;line-height:1.1}
.fab-txt b{font-size:14px;font-weight:700;letter-spacing:.01em}
.fab-txt small{font-size:10px;color:#e9c9a0;letter-spacing:.04em}
@media (max-width:700px){.game-fab{padding:8px 15px 8px 12px}.fab-txt b{font-size:13px}}
@media (prefers-reduced-motion:reduce){.game-cta::before,.pad-ico{animation:none}}
