:root{color-scheme:dark;font:14px/1.45 system-ui,-apple-system,"Noto Sans JP",sans-serif;color:#e5f6ff;background:#060d1b;--accent:#71e8d2;--muted:#91a8b8}
*{box-sizing:border-box}html,body{margin:0;width:100%;height:100%;overflow:hidden;overscroll-behavior:none}button,input{font:inherit;color:inherit}button{border:0;background:none;cursor:pointer;min-height:42px;padding:7px 10px;border-radius:24px;touch-action:manipulation}button:focus-visible,a:focus-visible{outline:2px solid var(--accent);outline-offset:2px}button:disabled{opacity:.42;cursor:default}button:hover:enabled{color:var(--accent)}button[aria-selected=true],button[aria-pressed=true]{color:var(--accent);box-shadow:inset 0 -2px var(--accent)}input{min-width:0;background:#101e30;border:1px solid #344b60;padding:10px 12px;border-radius:15px;max-width:100%}[hidden]{display:none!important}
html{-webkit-text-size-adjust:100%;text-size-adjust:100%}
#product-shell{height:100dvh;height:100svh;display:grid;grid-template-rows:minmax(0,1fr) minmax(318px,39%);overflow:hidden}#stage{position:relative;min-height:0;overflow:hidden;background:radial-gradient(at 50% 60%,#142846,#060d1b)}#room-canvas{width:100%;height:100%;display:block;touch-action:none}.brand{position:absolute;top:max(14px,env(safe-area-inset-top));left:20px;pointer-events:none;text-shadow:0 2px 8px #000}.eyebrow{color:var(--accent);font-size:10px;letter-spacing:.15em}.brand h1{font-size:22px;margin:4px 0}.brand p{font-size:12px;color:#aac6d7;margin:0;max-width:270px}.camera{position:absolute;bottom:8px;left:50%;transform:translateX(-50%);display:flex;align-items:center;gap:3px;white-space:nowrap;background:#091423ba;border-radius:30px;padding:0 4px;font-size:10px}.camera button{font-size:19px;padding:4px 9px}.camera span{color:#acc9d9}.room-label{position:absolute;transform:translate(-50%,-100%);font-size:11px;white-space:nowrap;color:#e5f5ff;text-shadow:0 2px 5px #000;pointer-events:none}.room-label small{display:block;text-align:center;font-size:9px;color:var(--accent)}#toast{position:absolute;bottom:60px;left:16px;right:16px;text-align:center;border-radius:16px;background:#13263be8;font-size:12px;pointer-events:none;padding:10px}#toast:empty{display:none}
#controls{min-height:0;overflow:hidden;background:linear-gradient(145deg,#102236,#0b1425 65%);border-top:1px solid #2b5264;display:grid;grid-template-rows:43px minmax(0,1fr) 22px;padding:0 16px env(safe-area-inset-bottom);z-index:2}.sections{display:flex;justify-content:space-between;border-bottom:1px solid #294052;gap:2px}.sections button{font-size:12px;padding:6px 4px;white-space:nowrap;min-height:42px;border-radius:0}.panel{min-height:0;overflow:hidden;padding:10px 2px 0;display:flex;flex-direction:column;gap:7px}.section-head{display:flex;justify-content:space-between;align-items:center;gap:8px;min-height:32px}.section-head h2{font-size:18px;font-weight:600;margin:0}.section-head button{min-height:34px;font-size:12px;padding:4px 8px}.members{display:flex;gap:7px;min-height:25px}.member{display:flex;align-items:center;gap:6px;font-size:11px}.member i{width:7px;height:7px;border-radius:50%;background:var(--accent)}.member.offline i{background:#8e7687}.member small{color:var(--muted)}.member button{min-height:26px;padding:0 4px;color:#aab3c2}.choice-row{display:flex;gap:6px;align-items:center;font-size:12px;flex-wrap:wrap}.choice-row>span{color:var(--muted);font-size:11px}.choice-row button{min-height:30px;padding:3px 8px}.guidance{font-size:12px;color:#acc2d2;margin:0;line-height:1.5}.primary{background:linear-gradient(100deg,#54d2c2,#7ebadf);color:#071729;font-weight:650;border-radius:30px;min-height:43px;width:100%;margin-top:auto;letter-spacing:.03em}.primary:hover:enabled{color:#03151c;filter:brightness(1.08)}.secondary{display:flex;justify-content:space-between;align-items:center;font-size:10px;color:var(--muted)}.secondary button{font-size:11px;min-height:29px;padding:2px 4px}footer{font-size:9px;color:#8095a9;display:flex;align-items:center;justify-content:space-between;gap:8px;white-space:nowrap}.input-line{display:flex;gap:7px;align-items:center}.input-line input{flex:1;width:60px;font-size:12px}.input-line button{white-space:nowrap}.panel small{font-size:10px;color:var(--muted)}.choice-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px}.choice-grid button{background:#17304470;font-size:12px;min-height:33px}.shop-row{display:flex;justify-content:space-between;align-items:center;padding:8px 0;border-bottom:1px solid #263d52;font-size:12px}.shop-row small{display:block}.shop-row button{font-size:12px;color:var(--accent)}.messages{font-size:11px;min-height:60px}.messages p{margin:0 0 3px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.messages b{color:var(--accent);font-weight:400;margin-right:6px}.pager{margin-top:auto;display:flex;justify-content:space-between}.moments{font-size:11px;color:var(--muted);display:flex;flex-wrap:wrap;gap:4px 10px}#match-choices .choice-row button{font-size:11px}#match-choices .choice-row{gap:3px}#result-panel .primary{margin-bottom:4px}
@media (orientation:landscape) and (min-width:480px){#product-shell{grid-template-rows:minmax(0,1fr);grid-template-columns:minmax(0,1fr) minmax(320px,31%)}#controls{border-top:0;border-left:1px solid #2b5264;padding:8px 18px env(safe-area-inset-bottom);grid-template-rows:43px minmax(0,1fr) 22px}.panel{padding-top:18px;gap:12px}.brand{left:24px}.shop-row{padding:12px 0}}
@media (max-width:450px){.brand{left:15px;top:58px}.brand h1{font-size:21px}.brand .eyebrow{font-size:9px}}
@media (max-height:740px) and (orientation:portrait){#product-shell{grid-template-rows:minmax(0,1fr) 315px}.panel{gap:4px;padding-top:6px}.brand p{display:none}.choice-row button{min-height:28px}}
@media (max-height:450px) and (orientation:landscape){#controls{padding-top:0}.panel{gap:5px;padding-top:6px}.shop-row{padding:6px 0}.brand p{max-width:240px}}
/* The console follows the actual visible controls, never a percentage of the screen. */
#product-shell{grid-template-rows:minmax(0,1fr) var(--controls-height,244px)}
#product-shell{height:100svh;height:100dvh}
#controls{grid-template-rows:36px minmax(0,1fr) 17px;padding-left:12px;padding-right:12px}
#controls,.panel,.sections,.section-head{min-width:0}#controls footer{overflow:hidden;min-width:0}#controls footer span{overflow:hidden;text-overflow:ellipsis}
.brand{max-width:min(270px,calc(100% - 24px));padding:6px 12px 9px;margin:-6px -12px -9px;background:linear-gradient(90deg,#061321f2 10%,#061321d9 68%,transparent);border-radius:8px}
#controls{grid-template-rows:36px minmax(0,1fr) 24px}
#controls footer{font-size:10px;color:#afc4d2;line-height:1.3}
.sections{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(0,1fr)}.sections button{min-width:0;width:100%;font-size:11px;padding:5px 0}
.members{flex-wrap:wrap}
.wardrobe-tabs{display:flex;justify-content:space-between}.wardrobe-tabs button{font-size:11px;min-height:30px;padding:2px 7px}.wardrobe-row{display:flex;align-items:center;justify-content:space-between;font-size:12px;min-height:33px}.wardrobe-row>div{display:flex;align-items:center;gap:4px}.wardrobe-row button{min-width:38px;min-height:33px;font-size:18px;padding:1px 7px;color:var(--accent)}.wardrobe-row div span{min-width:55px;text-align:center;font-size:11px;overflow-wrap:anywhere}
.messages{min-height:68px}.messages p{white-space:normal;overflow-wrap:anywhere;line-height:1.4;min-height:32px}.chat-pages{display:flex;align-items:center;justify-content:space-between;font-size:10px;color:var(--muted)}.chat-pages button{min-height:30px;font-size:11px}
#checkout-panel{min-height:0;overflow:hidden}#checkout-embed{display:flex;flex-direction:column;gap:4px;min-height:0;flex:1;overflow:hidden}#checkout-embed h2{font-size:13px;margin:0}#checkout-embed p{font-size:11px;margin:0;color:var(--muted)}#checkout-embed>button{min-height:36px;flex-shrink:0}#checkout-embed .stripe-test-frame{min-height:0;flex:1;overflow:hidden}#checkout-embed iframe{max-width:100%}
#checkout-embed form{display:flex;flex-direction:column;gap:5px;min-height:0;flex:1}#checkout-embed form input{width:100%;min-height:44px;font-size:16px}#checkout-embed form button{flex-shrink:0;min-height:40px}#checkout-embed form .stripe-test-frame{min-height:0;flex:1}
#checkout-embed .checkout-actions{display:flex;justify-content:space-between;gap:8px;flex-shrink:0}#checkout-embed .checkout-actions button{min-height:38px;font-size:12px}
.panel{gap:5px;padding-top:6px}.panel>*{flex-shrink:0}.panel .primary{margin-top:2px;min-height:39px}
.sections button{min-height:36px}.section-head{min-height:24px}.section-head h2{font-size:16px}
#room-status{display:none}.members{min-height:20px}.choice-row button{min-height:28px}.secondary button{min-height:24px}
.guidance{font-size:11px}
@font-face{
 font-family:"Google Sans";src:url("./assets/auth-google-sans-latin.woff2") format("woff2");
 font-style:normal;font-weight:500;font-display:swap;unicode-range:U+0000-00FF;
}
.account-header-actions{display:flex;align-items:center;gap:4px}
#account-help:empty,#account-error:empty{display:none}
#account-logins{display:grid;gap:7px}
#account-logins .primary{
 position:relative;min-height:44px;margin:0;padding:0 16px 0 52px;border:1px solid transparent;
 border-radius:10px;white-space:nowrap;font-size:14px;line-height:20px;letter-spacing:0;text-align:left;
}
#account-logins .primary::before{
 content:"";position:absolute;inset-block:0;inset-inline-start:0;width:44px;
 background:var(--provider-mark) center / var(--mark-size) no-repeat;pointer-events:none;
}
#account-logins #google-login{
 --provider-mark:url("./assets/auth-google.png");--mark-size:20px auto;
 padding-inline:42px 12px;background:#fff;border-color:#747775;color:#1f1f1f;
 font-family:"Google Sans",system-ui,sans-serif;font-weight:500;
}
#account-logins #line-login{
 --provider-mark:url("./assets/auth-line.png");--mark-size:32px auto;
 padding-inline:67px 24px;background:#06c755;color:#fff;
}
#account-logins #line-login::before{border-inline-end:1px solid rgb(0 0 0 / 8%)}
#account-logins #line-login:hover:enabled{filter:none;background-color:#05b34c}
#account-logins #line-login:active:enabled{background-color:#048b3b}
#account-logins #discord-login{
 --provider-mark:url("./assets/auth-discord.svg");--mark-size:24px auto;
 background:#4352d1;color:#fff;
}
@media (orientation:landscape) and (max-height:360px){
 #account-panel{gap:4px}
 #account-panel:has(#account-logins:not([hidden])) #account-status{display:none}
 #account-logins{gap:6px}
}
@media (orientation:landscape) and (min-width:480px){#product-shell{grid-template-rows:minmax(0,1fr);grid-template-columns:minmax(0,1fr) clamp(264px,29vw,330px)}#controls{align-self:center;max-height:100%;height:var(--controls-height,244px);border:1px solid #2b5264;border-right:0;border-radius:20px 0 0 20px}.panel{padding-top:6px;gap:5px}}
/* When entering free text, shortcuts are restored on blur. The message reader,
   input, send and back remain visible in the keyboard's visual viewport. */
#product-shell.chat-editing{position:fixed;left:0;right:0;top:var(--chat-visible-top,0px);height:var(--chat-visible-height,100dvh)}
#product-shell.chat-editing #preset-list,#product-shell.chat-editing #chat-help{display:none}
#product-shell.chat-editing #chat-panel{gap:3px}
#product-shell.chat-editing #messages{min-height:50px}
#product-shell.chat-editing #messages p{min-height:20px}
#chat-text{font-size:16px}
@media (orientation:landscape) and (max-height:360px){
 #chat-panel{gap:3px}
 #chat-panel #chat-help{display:none}
 #chat-panel #messages{min-height:50px}
 #chat-panel #messages p{min-height:20px}
 #chat-panel #preset-list{gap:2px}
 #chat-panel #preset-list button{min-height:29px;padding:2px 4px}
}
@media (orientation:portrait){#product-shell.checkout-open{grid-template-rows:minmax(100px,23%) minmax(0,1fr)}#product-shell.checkout-open #controls{height:100%}}
@media (orientation:landscape) and (min-width:480px){#product-shell.checkout-open{grid-template-columns:minmax(140px,32%) minmax(0,1fr)}#product-shell.checkout-open #controls{height:100%;border-radius:0}}
/* Test checkout: preserve the room while giving Stripe's actual form room to fit. */
#checkout-embed form{flex:initial}
#checkout-embed .stripe-test-frame,#checkout-embed form .stripe-test-frame{flex:initial;overflow:hidden}
#checkout-embed .checkout-actions{justify-content:space-between;gap:2px}
#checkout-embed .checkout-actions button{flex:1;white-space:nowrap;min-width:0;padding:4px;font-size:11px}
.checkout-open #controls .sections,.checkout-open #controls footer,.checkout-open #checkout-panel>.section-head,#checkout-embed h2{display:none}
.checkout-open #controls{grid-template-rows:minmax(0,1fr);padding:4px 10px max(4px,env(safe-area-inset-bottom))}
.checkout-open #checkout-panel{padding:0;gap:0}
.checkout-open #checkout-embed{gap:3px;flex:initial}
@media (orientation:portrait){#product-shell.checkout-open{grid-template-rows:minmax(96px,1fr) min(430px,calc(100dvh - 96px))}}
@media (orientation:landscape) and (min-width:480px){#product-shell.checkout-open{grid-template-columns:minmax(110px,21%) minmax(0,1fr)}#product-shell.checkout-open #controls{align-self:stretch;max-height:none}}

#checkout-embed .checkout-terms{font-size:11px;color:#ecf6ff;font-weight:650;line-height:1.2}
/* In short landscape screens the provider's form must fit above every action. */
@media (orientation:landscape) and (max-height:450px){
 #checkout-embed .checkout-actions{width:calc(100% - 105px);gap:0}
 #checkout-embed .checkout-actions button{font-size:10px;padding:2px}
}
/* Checkout is read-only: remove unusable HOME camera/navigation overlays. */
@media (orientation:landscape) and (max-height:450px){
 .checkout-open .brand,.checkout-open .camera,.checkout-open .room-label{display:none}
}
/* The entrance is an atmospheric loading state, not a second navigation UI. */
.network-entrance{position:fixed;inset:0;z-index:10000;display:grid;place-items:center;overflow:hidden;background:radial-gradient(ellipse at 50% 38%,#142f48 0%,#08131f 45%,#040810 100%);color:#e5faff;isolation:isolate}
/* The opt-in sits over an unpersonalized view of the same 3D operations room.
   No account or room data is loaded until the consent record is saved. */
body[data-preconsent] #product-shell{display:block}
body[data-preconsent] #stage{height:100%}
body[data-preconsent] #stage>*:not(canvas),body[data-preconsent] #product-shell>:not(#stage){visibility:hidden}
.network-entrance[data-state=consent]{background:#050c18b8}
.network-entrance[data-cinematic=true]:is([data-state=loading],[data-state=gate]) .entrance-atmosphere{background:linear-gradient(#06132a77,#05111d88),url('./assets/network-city.webp') center/cover;transform:none;inset:0;opacity:.8;mask-image:none}
.entrance-atmosphere{position:absolute;inset:-20%;z-index:-1;opacity:.35;background:repeating-linear-gradient(90deg,transparent 0 84px,#4eb8bd18 85px 86px),repeating-linear-gradient(0deg,transparent 0 84px,#4eb8bd18 85px 86px);transform:perspective(420px) rotateX(38deg) scale(1.2);mask-image:radial-gradient(ellipse,#000,transparent 72%)}
.entrance-gateway{position:absolute;left:50%;top:42%;transform:translate(-50%,-50%);width:min(56vw,280px);height:min(48vh,370px);border:2px solid #87fef1bb;border-radius:48% 48% 4px 4px / 18% 18% 4px 4px;padding:8px;background:linear-gradient(145deg,#77fff4a8,#152e43 16%,#0c192a 68%,#8574dba8);box-shadow:0 0 24px #51e0d667,0 0 90px #416ac64a,inset 0 0 18px #75ffef66}
.entrance-gateway-inner{position:relative;display:flex;width:100%;height:100%;overflow:hidden;border:1px solid #91f6ee6e;border-radius:48% 48% 1px 1px / 18% 18% 1px 1px;background:radial-gradient(ellipse at 50% 50%,#55fff0cc,#188bab77 35%,#101c37 74%);box-shadow:inset 0 0 36px #96fff188;perspective:700px}
.entrance-gateway-inner::before{content:'';position:absolute;inset:19% -100% -70%;background:repeating-linear-gradient(90deg,transparent 0 8%,#91fff076 8.3% 8.65%,transparent 9% 13%),repeating-linear-gradient(0deg,#96f7ff80 0 1px,transparent 2px 14%);transform:perspective(140px) rotateX(58deg);transform-origin:center top;mask-image:linear-gradient(transparent,#000 30% 75%,transparent);opacity:.75;pointer-events:none}
.gate-panel{position:relative;display:block;flex:1;height:100%;background:repeating-linear-gradient(0deg,transparent 0 34px,#5bb7c822 35px 36px),linear-gradient(120deg,#0b1a2d 4%,#213b50 47%,#081626 100%);border:1px solid #77d7db66;box-sizing:border-box;transform-origin:left center}
.gate-panel+.gate-panel{transform-origin:right center;background:repeating-linear-gradient(0deg,transparent 0 34px,#5bb7c822 35px 36px),linear-gradient(240deg,#0b1a2d 4%,#213b50 47%,#081626 100%)}
.gate-panel:before,.gate-panel:after{content:'';position:absolute;inset:12% 16%;border:1px solid #75eae499;clip-path:polygon(0 0,80% 0,100% 15%,100% 100%,20% 100%,0 85%);box-shadow:inset 0 0 18px #44d1d335}
.gate-panel:after{inset:18% 22%;border-color:#8a8eea88;opacity:.7}.gate-panel span{position:absolute;left:23%;right:23%;top:25%;height:50%;background:repeating-linear-gradient(0deg,transparent 0 20px,#80eee75c 21px 22px);mask-image:linear-gradient(transparent,#000 25% 75%,transparent)}
.gate-panel span:after{content:'';position:absolute;left:-10%;right:-10%;top:0;height:3px;background:#a8fff5;box-shadow:0 0 8px 2px #62ffea;opacity:.75;animation:entrance-current 3.2s linear infinite}
.gate-circuit{position:absolute;inset:0;width:100%;height:100%;overflow:visible;pointer-events:none;filter:drop-shadow(0 0 3px #55f9ff)}
.gate-right .gate-circuit{transform:scaleX(-1)}
.gate-circuit path{fill:none;vector-effect:non-scaling-stroke;stroke-linecap:round;stroke-linejoin:round}
.gate-circuit .circuit-trace{stroke:#3c9fb8;stroke-width:1;opacity:.62}
.gate-circuit .circuit-current{stroke:#b4fff5;stroke-width:2;stroke-dasharray:7 93;animation:circuit-flow 3s linear infinite}
.gate-circuit .circuit-power-track{stroke:#418ca5;stroke-width:1;opacity:.65}
.gate-circuit .circuit-power{stroke:#dcfffd;stroke-width:2;stroke-dasharray:12 88;animation:circuit-flow 3.8s linear infinite;filter:drop-shadow(0 0 3px #4dfff0)}
.gate-circuit circle{fill:#9ffff1;opacity:.8}
.gate-right .circuit-current,.gate-right .circuit-power{animation-delay:-1.5s}
@keyframes circuit-flow{to{stroke-dashoffset:-100}}
@keyframes entrance-current{0%{transform:translateY(0);opacity:0}12%{opacity:.75}88%{opacity:.75}100%{transform:translateY(min(24vh,170px));opacity:0}}
.gate-sigil{position:absolute;left:50%;top:52%;transform:translate(-50%,-50%);width:82px;height:82px;display:grid;place-content:center;text-align:center;border:1px solid #a4fff7a3;border-radius:50%;background:#10283de8;box-shadow:0 0 22px #67fff487;color:#a8fff8}.gate-sigil b{font:30px/1 system-ui}.gate-sigil em{font:8px/1.5 system-ui;letter-spacing:.12em;font-style:normal}
.entrance-copy{position:absolute;top:calc(42% + min(24vh, 185px) + 28px);width:100%;display:grid;justify-items:center;gap:8px;text-align:center}.entrance-copy small{font:10px/1.3 system-ui;letter-spacing:.22em;color:#7cddd5}.entrance-copy strong{font:500 18px/1.3 system-ui;letter-spacing:.16em}.entrance-copy span{font:12px/1.4 system-ui;color:#b1c8d6}.entrance-copy button{min-height:44px;padding:8px 18px;border-radius:22px;border:1px solid #77e9da;background:#122b3d;color:#e8fffc}
.network-entrance:not([data-cinematic=true]:is([data-state=loading],[data-state=gate])) .entrance-gateway{visibility:hidden}
.network-entrance:not([data-cinematic=true]:is([data-state=loading],[data-state=gate])) .entrance-copy{position:relative;inset:auto;width:auto;padding:0 16px}
.network-entrance:not([data-cinematic=true]:is([data-state=loading],[data-state=gate])) .entrance-copy strong{display:none}
.network-entrance[data-state=opening]{opacity:0;transition:opacity .13s ease;pointer-events:none}
.network-entrance:is([data-state=gate]) .gate-left{transform:rotateY(-82deg);transition:transform .52s ease}
.network-entrance:is([data-state=gate]) .gate-right{transform:rotateY(82deg);transition:transform .52s ease}
.network-entrance:is([data-state=gate]) .gate-sigil{opacity:0;transition:opacity .2s ease .18s}
@media(max-height:480px){.entrance-gateway{top:47%;height:72vh;width:180px}.entrance-copy{top:auto;bottom:6%;left:72%;width:25%}.entrance-copy strong{font-size:14px}}
@media(prefers-reduced-motion:reduce){.gate-panel span:after{animation:none;opacity:.4}.gate-circuit .circuit-current,.gate-circuit .circuit-power{animation:none;stroke-dasharray:none;opacity:.45}.network-entrance[data-state=opening],.network-entrance[data-state=gate] .gate-sigil{transition-duration:.1s;transition-delay:0s}.network-entrance[data-state=gate] .gate-panel{transform:none;transition:none}}
/* Reconfirm changed chat recipients without discarding the text draft. */
#chat-panel.audience-changed #preset-list{display:none}
#product-shell #chat-panel.audience-changed #chat-help{display:flex;align-items:center;flex-wrap:wrap;gap:3px;color:#e5f6ff}
#chat-panel.audience-changed #chat-help button{min-height:40px;padding:4px 8px;color:var(--accent)}
/* A keyboard can leave little height; keep the draft and confirmation visible. */
#product-shell.chat-editing.chat-audience-changed #controls{grid-template-rows:minmax(0,1fr);padding-top:0}
#product-shell.chat-editing.chat-audience-changed #controls .sections,
#product-shell.chat-editing.chat-audience-changed #controls footer{display:none}
#product-shell.chat-editing.chat-audience-changed #messages{min-height:16px}
#product-shell.chat-editing.chat-audience-changed #messages p{min-height:14px}
@media (orientation:landscape) and (max-height:360px){
 #product-shell.chat-editing.chat-audience-changed #messages{display:none}
}
/* Long player names must not push the fixed HOME controls off-screen. */
.members{flex-wrap:nowrap;min-width:0}
.member{flex:1 1 0;min-width:0;gap:2px}
.member i{flex:none}
.member-display{display:flex;align-items:center;gap:2px;min-width:0;min-height:44px;flex:1;cursor:pointer}
.member-display:focus-visible{outline:2px solid var(--accent);outline-offset:2px;border-radius:4px}
.member-name{display:block;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.member small{flex:none;max-width:3.5em;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:9px}
.member button{flex:none;min-width:24px;padding:0 3px}
.member button[data-kick-guest]{min-width:32px;min-height:44px;color:#ffb5b5;font-size:18px}
.defender-row{flex-wrap:nowrap;min-width:0}
.defender-row>span{flex:none}
#match-choices .defender-row button{flex:1 1 0;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.room-label{max-width:90px}
.room-label>span{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.room-label .pose-bubble{position:relative;display:block;width:max-content;max-width:100%;box-sizing:border-box;margin:0 auto 5px;padding:3px 6px;border-radius:5px;background:#eaf8ff;color:#152437;text-align:center;text-shadow:none;font-size:11px;line-height:1.1;}
.room-label .pose-bubble::after{position:absolute;top:100%;left:calc(50% - 3px);border:3px solid transparent;border-top-color:#eaf8ff;content:""}
.room-label>button:is([data-edit-own-name],[data-open-room-profile]){display:block;box-sizing:border-box;min-width:44px;max-width:100%;min-height:30px;padding:4px 7px;pointer-events:auto;font-size:inherit;font-weight:650;color:#f2f8ff;background:#0c1a2ce8;border:1px solid #a6c7e46b;border-radius:7px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.room-label>button:is([data-edit-own-name],[data-open-room-profile]):focus-visible{outline:2px solid var(--accent);outline-offset:2px}
#home-name-dialog{width:min(22rem,calc(100% - 24px));max-height:calc(100dvh - 24px);padding:15px;border:1px solid #78adc5;border-radius:13px;background:#142238;color:#eef7ff}
#home-name-dialog::backdrop{background:#03081065}
#home-name-form{display:grid;gap:8px}
#home-name-form h2,#home-name-error{margin:0}
#home-name-form h2{font-size:17px}
#home-name-form label{display:grid;gap:3px;font-size:12px;color:#d5e7f7}
#home-name-input{width:100%;min-width:0;padding:8px;color:#eef7ff;background:#091626;border:1px solid #779ab4;border-radius:7px;font-size:16px}
#home-name-error{font-size:12px;color:#ffd1d0}
.home-name-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.home-name-actions button{min-height:44px}
#toast{overflow-wrap:anywhere}

/* The equipment shelves keep one concise row per item so that both the
   preview and the purchase state remain visible inside the fixed panel. */
#shop-panel .shop-row{display:grid;grid-template-columns:44px minmax(0,1fr) auto;gap:10px;min-height:54px;border-bottom:1px solid #345168}
#shop-panel .shop-row::before{display:grid;place-items:center;width:42px;height:42px;border-radius:50%;color:#bafaf6;font-size:21px;text-shadow:0 0 12px #70efff;background:radial-gradient(circle at 35% 30%,#347489,#102638 72%);box-shadow:inset 0 0 0 1px #6ab2c460,0 2px 12px #020b15}
#shop-panel .shop-row:has([data-claim])::before{content:'';background-repeat:no-repeat;background-position:center;background-size:40px 40px,100% 100%}
#shop-panel .shop-row:has([data-claim="gpu"])::before{background-image:url('./assets/ability-gpu.svg'),radial-gradient(circle at 35% 30%,#347489,#102638 72%)}
#shop-panel .shop-row:has([data-claim="magnet"])::before{background-image:url('./assets/ability-magnet.svg'),radial-gradient(circle at 35% 30%,#55407b,#161c39 72%)}
#shop-panel .shop-row:has([data-claim="vaccine"])::before{background-image:url('./assets/ability-vaccine.svg'),radial-gradient(circle at 35% 30%,#705a33,#241f23 72%)}
#shop-panel .shop-row:has([data-claim="memo"])::before{background-image:url('./assets/ability-memo.svg'),radial-gradient(circle at 35% 30%,#705a33,#241f23 72%)}
#shop-panel .shop-row:has([data-buy])::before{content:'◇';color:#ffe2a9}
#shop-panel .shop-row b{font-weight:650;letter-spacing:.02em}
#shop-panel .shop-row button{white-space:nowrap;color:#8feada}
#shop-panel .shop-row button:disabled{color:#9fb6c1}
/* Keep the unboxed visual style while giving frequently used HOME controls
   an actual touch target, not a transparent overlay that can steal taps. */
#controls{grid-template-rows:44px minmax(0,1fr) 24px}
#controls .sections button{min-height:44px}
#home-panel .section-head button,#home-panel .choice-row button,
#home-panel .secondary button,#home-panel .primary{min-height:44px}
#home-panel .choice-row button{min-width:44px}
#home-meta{display:flex;flex-direction:column;gap:5px;min-width:0}
#home-panel .secondary{gap:0;min-width:0}
#home-panel .secondary button{flex:1 1 0;min-width:44px;padding:2px 1px;font-size:10px;white-space:nowrap}
#connection[data-state=online]{display:none}
#connection[data-state=reconnecting]{position:fixed;top:max(6px,env(safe-area-inset-top));left:50%;transform:translateX(-50%);z-index:30;padding:5px 9px;border-radius:12px;background:#21354bed;color:#fff;pointer-events:none;white-space:nowrap}
.camera button{min-width:44px;min-height:44px}
@media (orientation:landscape) and (max-height:360px){
 /* Keep role choices on one line on short phones. */
 #home-panel #match-choices .choice-row:not(.defender-row){flex-wrap:nowrap;gap:2px}
 #home-panel #match-choices .choice-row:not(.defender-row) button{flex:1 1 0;min-width:0;white-space:nowrap;font-size:10px;padding:3px 1px}
 #home-panel{gap:0}
 #home-meta{gap:0}
 #home-meta .guidance{line-height:1.2;min-width:0}
 #home-meta.intro-guidance{flex-direction:row;align-items:center;gap:8px}
 #home-meta.intro-guidance #home-guidance{font-size:0;white-space:nowrap}
 #home-meta.intro-guidance #sortie-status{font-size:10px}
}
/* Small, non-modal record card: it does not change the world, take over the
   viewport or expose another player's unearned titles. */
.record-popover{position:fixed;z-index:35;left:50%;top:50%;transform:translate(-50%,-50%);width:min(300px,calc(100vw - 24px));max-height:calc(100dvh - 24px);overflow:hidden;padding:9px 12px 10px;border:1px solid #426b83;border-radius:14px;background:#0a1729f5;box-shadow:0 10px 36px #000a;color:#e2f4fa}
.record-popover header{display:flex;align-items:center;justify-content:space-between;gap:8px;min-width:0}
.record-popover header strong{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:14px}
.record-popover button{min-width:44px;min-height:44px;padding:4px 7px;color:#b8eee9}
.record-popover header button{font-size:22px}
.record-collection{display:grid;justify-items:center;gap:4px;margin:0 0 10px;text-align:center}
.record-collection img{width:min(160px,30dvh,100%);aspect-ratio:1;object-fit:contain;border-radius:10px}
.record-title{font-size:13px;color:#d9eaf2;overflow-wrap:anywhere}
.record-progress-title{margin:0 0 5px;font-size:11px;color:#a7c9d7}
.record-rates{display:grid;grid-template-columns:1fr 1fr;gap:8px;font-size:12px;color:#acc9d5}
.record-rates span{white-space:nowrap}.record-rates b{font-size:14px;color:#f3f8fa;font-weight:650}
.record-rates span:first-child b{color:#d4bbff}.record-rates span:last-child b{color:#ffdd9d}
.record-popover .record-kick{width:100%;margin-top:9px;border:1px solid #b9757b;border-radius:8px;color:#ffc2c2}
.record-own{display:flex;align-items:center;gap:0;margin-top:2px;min-width:0}
.record-own span{flex:1;min-width:0;font-size:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.record-own button{flex:none;font-size:13px}
.member-identity{display:flex;flex-direction:column;min-width:0;line-height:1.2}
.member-title{display:block;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#b9d9e0;font-size:9px}
#shop-pages,#shop-abilities nav{gap:10px}
#shop-looks{display:grid;gap:8px}
.shop-feature{display:grid;grid-template-columns:minmax(100px,38%) minmax(0,1fr);gap:12px;align-items:center}
.shop-feature img{display:block;width:100%;height:90px;object-fit:cover;object-position:center 43%;border-radius:8px;border:1px solid #567487}
.shop-feature>div{display:flex;min-width:0;flex-direction:column;align-items:flex-start;gap:1px}
.shop-feature small,.shop-outfits small{font-size:10px;color:#9bb7c7}
.shop-feature b,.shop-outfits b{font-size:13px;letter-spacing:.02em}
.shop-feature span{font-size:10px;color:#9bb7c7}
.shop-feature button,.shop-outfits button{padding:3px 0;min-height:32px;color:#91eee4;font-size:12px}
.shop-outfits{display:flex;justify-content:space-between;align-items:center;gap:12px;border-top:1px solid #345168;padding-top:5px}
.shop-outfits span{display:flex;flex-direction:column}
/* The actual room preview is the shop's visual, with a dark side for legible
   copy.  The existing label still states explicitly that it is a preview. */
.shop-feature{position:relative;display:grid;grid-template-columns:minmax(0,1fr);height:96px;gap:0;overflow:hidden;border-radius:8px;border:1px solid #65788a}
.shop-feature::after{content:'';position:absolute;inset:0;pointer-events:none;background:linear-gradient(90deg,#101a2a18 8%,#0a1927a8 42%,#081624f5 68%)}
.shop-feature img{grid-area:1/1;width:100%;height:100%;min-height:0;max-height:100%;object-position:center 43%;border:0;border-radius:0}
.shop-feature>div{grid-area:1/1;z-index:1;align-self:center;margin-left:39%;padding:2px 8px;gap:0}
.shop-feature b{white-space:nowrap}
.shop-feature button{white-space:nowrap}
.shop-feature .shop-price-note{display:flex;flex-wrap:wrap;column-gap:.35rem;line-height:1.1}
.shop-feature .shop-price-note>span{white-space:nowrap}
#shop-abilities nav [data-ability-side="intruder"][aria-pressed="true"]{color:#e4baff;box-shadow:inset 0 -2px #cc92ff;text-shadow:0 0 12px #b45aff80}
#shop-abilities nav [data-ability-side="defender"][aria-pressed="true"]{color:#ffe2a1;box-shadow:inset 0 -2px #ffc766;text-shadow:0 0 12px #e4a83e80}
.shop-outfits{border-top-color:#c0a07480}
/* Keep the shop's text-only actions easy to tap without introducing boxes or
   wrapping its three navigation choices onto a second line. */
#shop-pages{gap:2px;flex-wrap:nowrap}
/* A single available section needs no navigation. Restore the tabs as soon
   as either the ability page or the test-checkout page becomes available. */
#shop-pages:has(>[data-shop-page="abilities"][hidden]):has(>[data-shop-page="sortie"][hidden]){display:none}
#shop-pages button{flex:1 1 0;min-width:44px;min-height:44px;padding:2px;white-space:nowrap}
#shop-abilities nav button,#shop-panel .shop-row button,
.shop-feature button,.shop-outfits button{min-width:44px;min-height:44px}
/* An active subscription reveals a second action in the same row. On a short
   landscape display it must not wrap below the fixed panel. */
@media (orientation:landscape) and (max-height:450px){
 #shop-pages button{font-size:10px}
 #shop-panel #shop-sortie .shop-row{grid-template-columns:26px minmax(0,1fr) auto;gap:4px}
 #shop-panel #shop-sortie .shop-row::before{width:24px;height:24px}
}
#shop-panel #shop-sortie .shop-row:has(#subscription-settings:not([hidden])){grid-template-columns:minmax(0,1fr) 44px 44px;gap:2px}
#shop-panel #shop-sortie .shop-row:has(#subscription-settings:not([hidden]))::before{display:none}
#shop-panel #shop-sortie .shop-row:has(#subscription-settings:not([hidden])) b{font-size:11px;letter-spacing:0}
#subscription-settings{font-size:10px;padding:2px}
#pose-panel button{min-width:44px;min-height:44px}
#pose-options{grid-template-columns:repeat(4,minmax(44px,1fr))}
#pose-options button{padding-inline:3px}
#pose-scopes{flex-wrap:nowrap}
#pose-panel .pose-header-actions,#pose-actions{display:flex;align-items:center;gap:4px}
#pose-panel .pose-header-actions{min-width:0;justify-content:flex-end;flex-wrap:wrap}
#pose-panel .pose-header-actions [data-back]{flex:none;white-space:nowrap}
#pose-favorites-page,#pose-page-toggle{white-space:nowrap;font-size:11px;color:#a7c9d7}
#pose-page-toggle{padding-inline:4px}
#pose-panel .section-head h2{min-width:0;line-height:1.25;overflow-wrap:anywhere}
#pose-favorites-page[aria-pressed=true],#pose-save-favorite[aria-pressed=true]{color:#f2d180}
#pose-actions .primary{min-width:0;flex:1 1 0;width:auto}
#pose-actions button{margin-top:0}
#pose-actions:has(> :not([hidden])){min-height:44px}
#pose-save-favorite{font-size:20px}
@media (orientation:landscape) and (max-height:450px){
 #pose-options{grid-template-columns:repeat(4,minmax(44px,1fr));gap:2px}
 #pose-options button{padding:2px;font-size:10px}
}
/* Result controls use full-size touch areas. */
#result-panel .section-head button,#result-panel .choice-row button,#result-panel #return-home{min-height:44px}
#result-moments{display:grid;gap:2px;margin:0;line-height:1.35}
#result-moments:empty{display:none}
#result-moments>div{display:grid;grid-template-columns:5em minmax(0,1fr);gap:6px}
#result-moments dt{color:#b9dbe6;font-weight:600;white-space:nowrap}
#result-moments .decisive-record dt{color:var(--accent)}
#result-moments dd{margin:0;overflow-wrap:anywhere;font-variant-numeric:tabular-nums;text-wrap:balance}
#result-cause,#home-guidance{text-wrap:balance}
.result-heading-actions{display:flex;gap:4px;flex:none}
#result-story-open{border:1px solid var(--console-light,#a5c6da);border-radius:8px;color:var(--console-light,#dbe9f2);white-space:nowrap}
#result-cause[data-story]{color:#d7e5ee;font-size:13px;text-wrap:pretty}
#result-story-dialog{margin:auto;width:min(34rem,calc(100% - 24px));max-height:calc(100dvh - 24px);
 padding:12px 14px 10px;border:1px solid color-mix(in srgb,var(--story-accent,#b6d4ee) 55%,#264159);border-radius:12px;background:linear-gradient(155deg,#192940,#0b1729 68%);
 color:#edf5fc;overflow:hidden;box-shadow:0 16px 50px #000a}
#result-story-dialog[data-side="intruder"]{--story-accent:#d8baff}
#result-story-dialog[data-side="defender"]{--story-accent:#ffde96}
#result-story-dialog::backdrop{background:#050b1599}
#result-story-dialog .section-head{align-items:center;gap:8px;padding-bottom:5px;border-bottom:1px solid #aec9e744}
#result-story-title{font-size:clamp(.95rem,3.5vw,1.2rem);line-height:1.2;overflow-wrap:anywhere}
#result-story-close,#result-story-dialog .result-story-nav button{min-height:44px;min-width:44px;white-space:nowrap}
#result-story-close{border-radius:8px;background:#2a3d55}
#result-story-page{padding:8px 0;font-size:clamp(.875rem,2.5vw,1rem);line-height:1.5}
#result-story-page h3{color:var(--story-accent,#b6d4ee);margin:0 0 4px;font-size:.83em;line-height:1.3}
#result-story-page p{margin:0;overflow-wrap:anywhere}
#result-story-dialog .result-story-nav{display:flex;align-items:center;justify-content:space-between;gap:8px;border-top:1px solid #aec9e744}
#result-story-dialog .result-story-nav button{color:#d8ecff;padding:3px 6px}
#result-story-count{color:#b3c5d4;font-variant-numeric:tabular-nums;font-size:.85rem;white-space:nowrap}
#result-photo-frame{position:absolute;inset:0;width:100%;height:100%;pointer-events:none}
#result-photo-frame[hidden]{display:none}
#stage[data-result-waiting] :is(#result-banner,#room-labels,#result-photo-frame){visibility:hidden}
#product-shell:has(#stage[data-result-waiting]) #result-panel > :is(.section-head,#result-cause,#result-moments){visibility:hidden}
#result-appearance-loading:not([hidden]){
 position:absolute;inset:0;z-index:5;display:flex;flex-direction:column;align-items:center;justify-content:center;
 gap:12px;padding:12px;background:#0b1425;color:#e7f5ff;font-size:14px;text-align:center;
}
#result-appearance-retry{min-height:44px}
#result-image-share{
 position:absolute;z-index:6;bottom:max(8px,env(safe-area-inset-bottom));left:max(8px,env(safe-area-inset-left));
 width:44px;height:44px;padding:0;border-radius:50%;border:1px solid #88bbc590;background:#081625eb;color:#e7f5ff;
}
#result-image-share:not([hidden]){display:grid;place-items:center}
#result-image-share svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
#ending-phase-message[data-recap-cue]{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#home-shortcut-guide{display:grid;grid-template-columns:minmax(0,1fr) 44px;gap:2px;align-items:center;padding:5px 2px 5px 8px;border:1px solid #74818f;border-radius:10px;background:#101b29f5;color:#e8f3fb;font:11px/1.3 system-ui,sans-serif;overflow-wrap:anywhere}
#home-shortcut-title{margin:0 0 2px;color:#b7ecfb;font-size:12px;line-height:1.2}
#home-shortcut-guide p{margin:0}
#home-shortcut-close{min-height:44px;min-width:44px;padding:0;color:inherit;font-size:20px}
#stage #home-shortcut-guide{position:absolute;z-index:12;inset-inline-start:max(8px,env(safe-area-inset-left));bottom:max(58px,calc(env(safe-area-inset-bottom) + 50px));box-sizing:border-box;width:max-content;max-width:min(22rem,calc(100% - 16px - env(safe-area-inset-left) - env(safe-area-inset-right)));pointer-events:none}
#stage #home-shortcut-close{pointer-events:auto}
#product-shell:has(#result-panel[hidden]) #stage #home-shortcut-guide{display:none}
#product-shell[data-result-page] #controls{grid-template-rows:minmax(0,1fr)}
#product-shell[data-result-page] :is(#controls>.sections,#controls>footer,#sortie-status,.brand){display:none}
#result-retry{min-height:44px;padding:3px 8px;color:var(--accent)}
@media (orientation:landscape) and (max-height:360px){
 #controls:has(#result-panel:not([hidden])){padding-inline:10px}
 #result-panel{gap:2px;padding-top:3px}
 #result-panel .primary{margin-bottom:0}
}
.wardrobe-tabs button{border-radius:0;color:#a9bdcb}
.wardrobe-tabs button[aria-selected=true]{color:#a6fff4}
.wardrobe-gallery{display:flex;gap:8px;min-width:0}
.wardrobe-gallery button{display:flex;flex-direction:column;align-items:center;gap:2px;width:68px;padding:2px 3px;min-height:0;border-radius:8px;color:#c9dee8}
.wardrobe-gallery button[aria-pressed=true]{box-shadow:inset 0 0 0 1px #77e9da;color:#e8fffb}
.wardrobe-gallery img{width:48px;height:60px;object-fit:cover;border-radius:5px}
.wardrobe-gallery span{display:block;width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:9px}
@media (max-height:450px) and (orientation:landscape){
 #shop-panel .shop-row{grid-template-columns:34px minmax(0,1fr) auto;min-height:42px;padding:3px 0}
 #shop-panel .shop-row::before{width:30px;height:30px;font-size:18px}
 #shop-panel .shop-row:has([data-claim])::before{background-size:28px 28px,100% 100%}
 .shop-feature{height:86px}
 .shop-feature img{height:100%}
 .shop-feature small{display:none}
 .wardrobe-gallery img{width:36px;height:45px}
}

/* The wardrobe keeps all five categories and each stepper usable by touch.
   On a short landscape screen, a small side rail frees the fixed panel for
   the three face controls and Save without scrolling or hiding a control. */
.wardrobe-tabs button,#wardrobe-back,#wardrobe-save,.section-head .wardrobe-face-page,.wardrobe-row button,
.wardrobe-gallery button,#wardrobe-rows>button{min-width:44px;min-height:44px}
.section-head .wardrobe-face-page{color:var(--console-light);margin-left:auto;white-space:nowrap}
.wardrobe-row{min-height:44px}
@media (orientation:landscape) and (max-height:360px){
 #wardrobe-panel{gap:0}
 #wardrobe-panel #wardrobe-hint{line-height:1.1}
 #wardrobe-panel .wardrobe-tabs{position:fixed;left:auto;right:calc(clamp(264px,29vw,330px) + 4px);top:calc(50% - 4px);transform:translateY(-50%);z-index:4;display:flex;flex-direction:column;align-items:center;gap:0;background:#0a182bd9;border-radius:22px;padding:0}
 #product-shell:has(#wardrobe-panel:not([hidden])) .camera{left:5px;transform:none}
}

/* Shared faction colours for the briefing, queue and assigned seat. */
#product-shell{--console-light:#83dce9;--console-glow:rgba(44,142,185,.17)}
#product-shell[data-ui-faction="intruder"]{--console-light:#d0a6ff;--console-glow:rgba(135,69,206,.2)}
#product-shell[data-ui-faction="defender"]{--console-light:#f4d18d;--console-glow:rgba(189,135,50,.18)}
#controls{background:radial-gradient(ellipse at 85% 0,var(--console-glow),transparent 47%),linear-gradient(145deg,#102235,#071322 74%);border-color:color-mix(in srgb,var(--console-light) 28%,transparent)}
.sections button[aria-selected=true]{color:var(--console-light);box-shadow:inset 0 -2px var(--console-light);text-shadow:0 0 14px var(--console-glow)}
.section-head h2{letter-spacing:.035em}
#room-faction{color:var(--console-light)}
#online:not(:disabled){background:linear-gradient(105deg,#61cfe1,#a9e8f4);box-shadow:0 3px 14px #0005,inset 0 1px #efffff7a}
#product-shell[data-ui-faction="intruder"] #online:not(:disabled){background:linear-gradient(105deg,#8856c7,#c69df3);color:#110d21}
#product-shell[data-ui-faction="defender"] #online:not(:disabled){background:linear-gradient(105deg,#d2a652,#f2db9e);color:#221807}

#invite-panel .section-head{min-height:44px}
#invite-panel .section-head button,
#invite-panel #make-invite,#share-invite,#invite-share-url,#invite-panel .input-line input,
#invite-panel .input-line button{min-width:44px;min-height:44px}
#invite-panel .invite-code-row{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:stretch;gap:7px}
#invite-code{display:grid;place-items:center;padding:5px 8px;border:1px solid #385870;border-radius:9px;background:#0b1c30;color:#ebf7ff;font:650 21px/1.2 ui-monospace,monospace;letter-spacing:.13em;user-select:all;-webkit-user-select:all}
#share-invite{display:flex;align-items:center;gap:5px;padding-inline:9px;color:var(--console-light)}
#share-invite svg{width:17px;height:17px}
#invite-share-url{width:100%;font-size:16px}


/* The outcome remains part of the actual result screen, without covering the
   avatar or being burned into a shared in-world photograph. */
.result-banner{
 position:absolute;z-index:1;left:50%;top:max(10px,env(safe-area-inset-top));transform:translateX(-50%);
 width:max-content;max-width:calc(100% - 1rem);pointer-events:none;padding:4px 14px 5px;
 background:linear-gradient(105deg,color-mix(in srgb,var(--verdict-glow) 24%,#111929f7),#101827f0 80%);
 border-block:1px solid color-mix(in srgb,var(--verdict-accent) 57%,transparent);
 --verdict-corner:9px;
}
.result-banner[data-outcome="loss"],.result-banner[data-outcome="neutral"]{
 background:linear-gradient(105deg,color-mix(in srgb,var(--verdict-glow) 14%,#111929f7),#0e1522f5 80%);
}
.result-banner .operation-verdict-title{font-size:clamp(21px,6vw,29px)}
.result-banner[data-outcome="win"] .operation-verdict-title{
 text-shadow:0 0 15px color-mix(in srgb,var(--verdict-glow) 47%,transparent)
}
#product-shell:has(.result-banner:not([hidden])) .brand{visibility:hidden}
@media (orientation:landscape) and (max-height:450px),(max-height:600px) and (orientation:portrait){
 .result-banner{top:max(6px,env(safe-area-inset-top));padding:3px 12px 4px;--verdict-mark-size:1.95rem}
 .result-banner .operation-verdict-title{font-size:20px}
}
/* Keep private replacement and cancel actions beside the readiness count on
   short landscape screens while retaining the full accessible button names. */
@media (orientation:landscape) and (max-height:360px){
 #home-panel:has(#invite-replacement:not([hidden])) .section-head>div:last-child{display:flex;flex:none;gap:0}
 #home-panel:has(#invite-replacement:not([hidden])) .section-head h2{font-size:14px;white-space:nowrap}
 #home-panel:has(#invite-replacement:not([hidden])) .section-head button{padding:3px;font-size:10px}
 #home-panel:has(#invite-replacement:not([hidden])) #invite-replacement{font-size:0}
 #home-panel #invite-replacement:not([hidden])::after{content:attr(data-compact-title);font-size:10px}
}
/* A private vacancy can briefly reflow to a two-line title during a device
   rotation before JS measures the new height. Reserve the required area so
   the footer never covers the primary action in the intermediate frame. */
@media (orientation:landscape) and (max-height:450px) and (min-width:480px){
 #controls:has(#home-panel:not([hidden]) #invite-replacement:not([hidden])){min-height:min(100%,344px)}
}
/* A member label can abbreviate, but its detail view must show the full name. */
.record-popover header strong{white-space:normal;overflow:visible;overflow-wrap:anywhere;line-height:1.3}

/* Keep the preferred roles and rating directly above the start action. */
#match-choices:empty {display:none;}
#home-panel .faction-preferences{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:3px 5px;align-items:stretch}
#home-panel .faction-preferences>span{grid-column:1/-1;font-size:10px;line-height:1.2}
#home-panel .faction-preferences button{width:100%;min-width:0;min-height:44px;padding:4px 6px;border:1px solid #4e7285;border-radius:11px;background:#0a1829;white-space:nowrap}
#home-panel .faction-preferences [data-faction]{font-size:clamp(11px,3.2vmin,14px);font-weight:650}
#home-panel .faction-preferences [data-faction]::before{width:2.1em;height:2.1em;vertical-align:middle;margin-inline-end:.4em}
#home-panel .faction-preferences [data-faction=intruder]{background:linear-gradient(120deg,#21152e,#120f21);border-color:#9271b1}
#home-panel .faction-preferences [data-faction=defender]{background:linear-gradient(120deg,#332719,#181c23);border-color:#b58f58}
#home-panel .faction-preferences [data-faction][aria-pressed=true]{box-shadow:inset 0 0 0 1px currentColor,0 0 10px #86dcd955}
#product-shell #home-panel #online:not(:disabled){background:linear-gradient(100deg,#55e4e4,#26c4d5);color:#04202b;border-radius:11px}
#product-shell #home-panel #online[data-launch]{
 --launch-accent:#91f8ff;
 position:relative;
 min-height:51px;
 padding-inline:40px;
 border:1px solid color-mix(in srgb,var(--launch-accent) 75%,#1a2640);
 border-radius:12px;
 font-size:clamp(14px,3.8vmin,17px);
 font-weight:750;
 letter-spacing:.055em;
}
#product-shell[data-ui-faction="intruder"] #home-panel #online[data-launch]{--launch-accent:#d6b5ff}
#product-shell[data-ui-faction="defender"] #home-panel #online[data-launch]{--launch-accent:#ffda89}
#product-shell #home-panel #online[data-launch][data-private-launch]{--launch-accent:#d6b5ff}
#product-shell #home-panel #online[data-launch]:is(:not(:disabled),[data-private-launch]){
 background:linear-gradient(105deg,#101829 0%,#17283e 42%,color-mix(in srgb,var(--launch-accent) 31%,#101829) 100%);
 color:#f3f9ff;
 box-shadow:inset 0 1px 0 #eff8ff36,0 5px 16px #0007;
 transition:background-color .18s,box-shadow .18s,transform .18s;
}
#product-shell #home-panel #online[data-private-launch]:disabled{opacity:.78}
#online[data-launch]::before,#online[data-launch]::after{
 content:'';
 position:absolute;
 top:50%;
 pointer-events:none;
 color:var(--launch-accent);
}
#online[data-launch]::before{
 left:17px;
 width:10px;
 height:10px;
 border:1px solid currentColor;
 transform:translateY(-50%) rotate(45deg);
}
#online[data-launch]::after{
 right:19px;
 width:8px;
 height:8px;
 border-right:2px solid currentColor;
 border-top:2px solid currentColor;
 transform:translateY(-50%) rotate(45deg);
}
#product-shell #home-panel #online[data-launch]:not(:disabled):is(:hover,:focus-visible){box-shadow:inset 0 0 18px #d5f6ff2b,0 0 13px #a2d8ff5e}
#product-shell #home-panel #online[data-launch]:not(:disabled):active{transform:translateY(1px)}
.home-play-actions{display:flex;align-items:stretch;gap:6px;margin-top:2px}
#home-panel .home-play-actions .primary{min-width:0;width:auto;margin-top:0}
.home-play-actions #online{flex:3 1 0}
.home-play-actions #online-queue-status{flex:1 1 0}
#home-practice{
 flex:2 1 0;min-width:0;min-height:44px;padding:4px 7px;
 border:1px solid color-mix(in srgb,var(--console-light) 54%,#2e415c);border-radius:11px;
 background:linear-gradient(128deg,#131c2f,color-mix(in srgb,var(--console-light) 14%,#131c2f));
 color:#f2f7fe;font-size:clamp(12px,3.4vmin,15px);font-weight:700;line-height:1.2;text-wrap:balance;
}
#home-practice:is(:hover,:focus-visible){box-shadow:inset 0 0 0 1px var(--console-light)}
#product-shell #home-panel .home-play-actions:has(#home-practice:not([hidden])) #online[data-launch]{
 padding-inline:7px;font-size:clamp(12px,3.6vmin,16px);letter-spacing:.01em;line-height:1.2;text-wrap:balance;
}
.home-play-actions:has(#home-practice:not([hidden])) #online[data-launch]::before,
.home-play-actions:has(#home-practice:not([hidden])) #online[data-launch]::after{display:none}
#home-panel #preparation-outfits:not([hidden]){
 flex:none;min-height:44px;padding:5px 9px;white-space:nowrap;
 border:1px solid #90b7d282;border-radius:9px;background:#122840;color:#d9ecfa;
 font-weight:650;
}
@media (prefers-reduced-motion:reduce){#product-shell #home-panel #online[data-launch]{transition:none}}
@media (orientation:landscape) and (max-height:360px){#product-shell #home-panel #online[data-launch]{min-height:45px}}
#home-panel .secondary button{border:1px solid #355467;border-radius:9px;margin:0 2px;color:#d7eaf3}
@media (orientation:portrait){
 .brand{top:calc(max(10px,env(safe-area-inset-top)) + 45px)}
}
@media (orientation:landscape) and (max-height:450px){
 #home-panel .faction-preferences{grid-template-columns:repeat(2,minmax(0,1fr));gap:2px}
 #home-panel .faction-preferences [data-faction]{font-size:10px;min-height:44px}
 #home-panel .faction-preferences [data-faction]::before{width:1.7em;height:1.7em}
}
@media (orientation:landscape) and (max-height:360px){
 #controls{grid-template-rows:40px minmax(0,1fr) 14px;padding-top:0;padding-bottom:0}
 #controls .sections button{min-height:40px}
 #home-panel{gap:0;padding-top:0}
 #home-meta{gap:0}
 #home-meta .guidance{line-height:1.05;font-size:10px}
 #home-meta.intro-guidance{flex-direction:row;align-items:center;gap:4px}
 #home-meta.intro-guidance #home-guidance{font-size:0;white-space:nowrap}
}
@media (orientation:landscape) and (max-height:360px){
 #home-panel #room-choices{flex-wrap:nowrap;gap:2px}
 #home-panel #room-choices>span{flex:none;font-size:9px}
 #home-panel #room-choices>button{flex:1 1 0;min-width:0;padding:2px 0;font-size:10px;white-space:nowrap}
}
@media (orientation:landscape) and (max-height:450px){
 #home-panel #room-choices{flex-wrap:nowrap;gap:2px}
 #home-panel #room-choices>span{flex:none;font-size:9px}
 #home-panel #room-choices>button{flex:1 1 0;min-width:0;padding:2px 0;font-size:10px;white-space:nowrap}
}
@media (orientation:landscape) and (max-height:450px){
 #home-panel .secondary button{font-size:9px;letter-spacing:-.02em;padding:0;margin:0 1px}
}


.participation-consent{margin:2px 0 0;text-align:center;font-size:10px;line-height:1.25;color:#b2c6d2}.participation-consent a{color:#bdebe8;text-decoration:underline;text-underline-offset:2px}.participation-consent[hidden]{display:none}

/* Three focused HOME destinations. Cards remain compact without a page scroll. */
#home-panel .secondary{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:2px;align-items:stretch}
#home-panel .secondary button{min-width:0;min-height:44px;padding:2px 1px;margin:0;font-size:10px;line-height:1.15;white-space:normal}
#home-panel #connection{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
.room-banners,.outfit-banners{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px;min-height:0;flex:none;height:104px}
.room-banner,.outfit-banner{position:relative;display:flex;align-items:flex-end;min-width:0;min-height:72px;padding:7px;border:1px solid #45677a;border-radius:12px;overflow:hidden;text-align:left;background:#0a1829}
.room-banner img,.outfit-banner img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;opacity:.78;pointer-events:none}
.room-banner::after,.outfit-banner::after{content:'';position:absolute;inset:0;background:linear-gradient(0deg,#07121df5 0%,#07121dbb 40%,#07121d22 100%);pointer-events:none}
.room-banner>span,.outfit-banner>span{position:relative;z-index:1;min-width:0;display:flex;flex-direction:column;align-items:flex-start;line-height:1.25;text-shadow:0 1px 4px #000}
.room-banner b,.outfit-banner b{font-size:12px}.room-banner small,.outfit-banner small{font-size:10px;color:#c9dfe8}
.room-banner[aria-pressed=true]{border-color:#86f1de;box-shadow:inset 0 0 0 1px #86f1de}
.room-banner:disabled{opacity:.65}
:is(.outfit-banner,.room-banner[data-theme="holiday"]) {
 --sales-highlight:#f5cb8b;
 border-color:color-mix(in srgb,var(--sales-highlight) 63%,#223049);
 box-shadow:0 4px 14px #0509138c;
}
.outfit-banner#outfit-high{--sales-highlight:#d5b5ff;grid-column:1/-1}
:is(.outfit-banner,.room-banner[data-theme="holiday"]) img{opacity:.9}
:is(.outfit-banner,.room-banner[data-theme="holiday"])::after {
 background:
  linear-gradient(0deg,#080f1df8 0%,#11182cde 32%,#0b172c25 78%,#09162660 100%),
  linear-gradient(132deg,color-mix(in srgb,var(--sales-highlight) 30%,transparent),transparent 44%);
 box-shadow:inset 0 0 0 2px #0b1020db,inset 0 0 0 3px color-mix(in srgb,var(--sales-highlight) 22%,transparent);
}
:is(.outfit-banner,.room-banner[data-theme="holiday"]) b{color:#f9f5ed}
:is(.outfit-banner,.room-banner[data-theme="holiday"]) small {
 color:color-mix(in srgb,var(--sales-highlight) 62%,#edf4fa);
 overflow-wrap:anywhere;
}
:is(.outfit-banner,.room-banner[data-theme="holiday"]):is(:hover,:focus-visible){
 border-color:var(--sales-highlight);
 box-shadow:0 0 12px color-mix(in srgb,var(--sales-highlight) 28%,transparent);
}
.room-banner[data-theme="holiday"][aria-pressed=true] {
 border-color:#86f1de;
 box-shadow:0 0 12px #86f1de52;
}
/* Both operation tabs occupy the same track. The taller panel sets its size
   without changing the room camera when the selected panel changes. */
#product-shell[data-operation-room] #controls {height:auto;grid-template-areas:"tabs" "panel" "footer";}
#product-shell[data-operation-room] #controls>.sections {grid-area:tabs;}
#product-shell[data-operation-room] #controls>footer {grid-area:footer;}
#product-shell[data-operation-room] :is(#home-panel,#room-panel) {grid-area:panel;}
#product-shell[data-operation-room] :is(#home-panel,#room-panel)[hidden] {
 display:flex!important;visibility:hidden;pointer-events:none;
}
#product-shell[data-operation-room] #room-panel[hidden] img {display:none;}
#product-shell[data-operation-room] #room-panel .room-banners {flex:1 1 auto;}
#controls #home-audio{min-height:44px;font-size:clamp(9px,2.5vw,11px);display:inline-flex;align-items:center;justify-content:center;gap:3px;color:#d2e5f1}
#home-audio span{display:flex;flex-direction:column;align-items:center;line-height:1.13}
#home-audio span b{font-size:.92em}
#home-audio svg{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linejoin:round;stroke-linecap:round;flex:none}
#home-audio[aria-pressed="true"]{color:#a4f2eb}
#home-audio[aria-pressed="true"] .sound-disabled,#home-audio[aria-pressed="false"] .sound-waves{display:none}
#ending-sound-play {
 position:absolute;z-index:6;top:max(10px,env(safe-area-inset-top));left:max(10px,env(safe-area-inset-left));
 width:44px;height:44px;align-items:center;justify-content:center;border:1px solid #638b9f;
 background:#102235e8;border-radius:50%;color:#b9efff;padding:0;
}
#ending-sound-play:not([hidden]){display:grid;place-items:center}
#ending-sound-play svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
#stage[data-fitting] .brand{display:none}
@media (orientation:portrait) {
 #product-shell[data-operation-room] {grid-template-rows:minmax(0,1fr) max-content;}
}
.outfit-banner>span:last-child{margin-left:auto;font-size:20px;color:#a5f3e4}
#outfits-panel .section-head button,#outfit-info-panel .section-head button{min-height:44px;color:#a8f6e5}
#outfits-membership .membership-offer-copy>span:last-child{font-size:10px;color:#e6d5ad}
.outfit-info-head{display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:center;gap:5px}
.outfit-info-head h2{overflow-wrap:anywhere}
#outfit-info-back{grid-column:3}
#outfit-info-text{font-size:12px;line-height:1.45;overflow-wrap:anywhere}
#outfit-info-panel #outfit-sale-membership{
 max-width:13ch;min-height:44px;padding:3px 7px;line-height:1.2;font-size:11px;
 border:1px solid #a38b60;color:#ffe8b7;background:linear-gradient(135deg,#413522,#182339);
 border-radius:8px;overflow-wrap:anywhere;
}
#outfit-sale-membership:is(:hover,:focus-visible){border-color:#ffe7af;color:#fff3d9}
#controls footer{justify-content:center;}
#controls footer nav{display:flex;gap:8px;min-width:0;align-items:center;}
#outfit-catalog-items {
 display:grid;
 grid-template-columns:repeat(2,minmax(0,1fr));
 gap:4px;
 margin:0;
 padding:0;
 list-style:none;
}
#outfit-catalog-items button {
 display:grid;
 grid-template-columns:44px minmax(0,1fr);
 align-items:center;
 gap:5px;
 width:100%;height:100%;min-height:62px;
 text-align:left;
 padding:3px;
 border:1px solid #45627b;
 border-radius:8px;
 background:#101c2b;
}
#outfit-catalog-items button[aria-pressed=true]{border-color:#8ae6d7;background:#173742;}
#outfit-catalog-items button:disabled{opacity:.66;}
.outfit-catalog-thumb {
 display:grid;
 place-items:center;
 height:54px;
 border-radius:4px;
 background:#192f46;
}
.outfit-catalog-thumb[data-unavailable]::after{content:'―';color:#b3c5d6}
.outfit-catalog-thumb img {width:100%;height:100%;object-fit:contain;}
.outfit-catalog-tools{display:flex;align-items:center;gap:5px;min-width:0}
#outfit-catalog-status{flex:1;min-width:0;margin:0;line-height:1.2}
.outfit-catalog-tools button{flex:0 0 auto;min-height:44px;min-width:44px;padding:3px 8px;font-size:11px;white-space:nowrap}
#outfit-catalog-wear{color:#d4fff8;border:1px solid #68b5a8;background:#17404a}
#outfit-catalog-items strong {
 display:block;
 color:#e8f5ff;
 font-size:11px;
 line-height:1.3;
 overflow-wrap:anywhere;
}
#outfit-catalog-items small {display:block;color:#9deee3}
#outfit-catalog-items .outfit-member-badge{color:#f5dfab}
#outfit-info-panel[data-membership-catalog] #outfit-catalog-items button:not([aria-pressed=true]){
 border-color:#856f51;background:linear-gradient(125deg,#1d2b3d,#152033);
}
#outfit-info-panel[data-membership-catalog] #outfit-catalog-items button:enabled:is(:hover,:focus-visible){
 border-color:#f5dfab;
}
@media (orientation:portrait), (min-height:451px){
 #outfit-info-panel[data-membership-catalog] #outfit-catalog-items button{grid-template-columns:56px minmax(0,1fr)}
}
.outfit-catalog-pager {
 display:grid;
 grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);
 align-items:center;
 gap:6px;
 text-align:center;
}
.outfit-catalog-pager button {
 min-height:44px;
 border:1px solid #45627b;
 border-radius:8px;
 font-size:11px;
 background:#10243b;
}
.outfit-catalog-pager button:disabled {opacity:.48;}
#outfit-catalog-retry {grid-column:1/-1;}
#outfit-catalog-count {font:600 11px system-ui;color:#c9dce7;}
@media (orientation:landscape) and (max-height:450px){
 .room-banner,.outfit-banner{min-height:64px;padding:5px}
 .room-banner b,.outfit-banner b{font-size:11px}.room-banner small,.outfit-banner small{font-size:9px}
 #home-panel .secondary button{font-size:9px}
 #outfit-info-panel{gap:3px}
 #outfit-info-text,#outfit-draw-rule{font-size:10px;line-height:1.25}
 #outfit-info-panel #outfit-sale-membership{font-size:10px}
 #outfit-catalog-items{grid-template-columns:repeat(4,minmax(0,1fr));gap:3px;}
 #outfit-catalog-items button{grid-template-columns:minmax(0,1fr);gap:2px;align-content:start}
 .outfit-catalog-thumb{height:38px}
 #outfit-catalog-items strong{font-size:9px}
}

/* Respond to touch immediately without claiming a server action succeeded. */
.sections button:active,.room-banner:active,.outfit-banner:active{filter:brightness(1.22);transform:scale(.985)}
.room-banner[data-pending=true]{filter:brightness(1.2);outline:2px solid #84e9e3;outline-offset:-2px}
.room-banner[data-pending=true]::before{content:attr(data-pending-title);position:absolute;top:4px;right:5px;z-index:2;padding:2px 5px;border-radius:8px;background:#071a2ce8;color:#e5fffc;font-size:9px}
@media (prefers-reduced-motion:reduce){.sections button:active,.room-banner:active,.outfit-banner:active{transform:none}}

@media (orientation:landscape) and (max-height:450px){.room-banners,.outfit-banners{height:86px}}

.room-banner .shop-price-note{display:flex;flex-wrap:wrap;gap:1px 4px}.room-banner .shop-price-note span{white-space:nowrap}
/* Keep the navigation's actual touch target at least 44px, even on a short landscape display. */
#controls .sections button{min-height:44px}
#controls{grid-template-rows:44px minmax(0,1fr) 22px}
@media (orientation:landscape) and (max-height:360px){#controls{grid-template-rows:44px minmax(0,1fr) 14px}}
@media (max-width:360px){#home-panel .secondary button{white-space:nowrap;font-size:9px;letter-spacing:-.05em}}
#controls .sections button{flex:1 1 0;min-width:44px}
/* Brightness gives press feedback without shrinking the accessible touch box. */
.sections button:active{transform:none}

/* Status uses compact network-key symbols; the complete balance, holds and
   recovery are available to assistive technology via the label. */
#stage #sortie-status.sortie-corner{position:absolute;top:max(10px,env(safe-area-inset-top));right:max(10px,env(safe-area-inset-right));z-index:4;max-width:min(46%,180px);margin:0;padding:4px 7px;border-radius:8px;background:#071321dd;color:#e5fff8;font-size:11px;line-height:1.25;text-align:right;pointer-events:none;text-shadow:0 1px 4px #000}
#product-shell:has(#result-panel:not([hidden])) #stage #sortie-status{display:none!important}
.sortie-key-row{display:flex;justify-content:flex-end;align-items:center;gap:4px;min-height:21px}
.sortie-key{display:inline-flex;width:21px;height:21px;align-items:center;justify-content:center}
.sortie-key svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
.sortie-key.available{color:#8cfff0;filter:drop-shadow(0 0 3px #4ae9e0)}
.sortie-key.held{color:#f1cb78;filter:drop-shadow(0 0 2px #daab4c)}
.sortie-key.held svg{stroke-dasharray:2 1.5}
.sortie-key.empty{color:#647b8a}
.sortie-key.locked{color:#b2f3e6}
.sortie-corner-note{display:block;white-space:nowrap;font-size:10px;line-height:1.35;color:#c9e9e4}
.sortie-corner-error{display:block;font-size:10px;line-height:1.25;max-width:136px}
.sortie-extra-count{font-size:12px;font-weight:700;color:#e4fff9}.sortie-infinity{font-size:23px;line-height:21px;color:#8cfff0;text-shadow:0 0 6px #49c9c3}
#stage:has(#sortie-status:not([hidden])) .brand{right:calc(max(10px,env(safe-area-inset-right)) + min(46%,180px) + 6px);max-width:calc(100% - min(46%,180px) - 36px)}
#stage:has(#sortie-status:not([hidden])) .brand h1,#stage:has(#sortie-status:not([hidden])) .brand p,#stage:has(#sortie-status:not([hidden])) .brand .eyebrow{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#stage:has(#sortie-status:not([hidden])) .brand .eyebrow{display:block}
@media (orientation:portrait) and (min-width:451px){#stage #sortie-status.sortie-corner{top:calc(max(14px,env(safe-area-inset-top)) + 48px)}}
@media (orientation:landscape) and (max-height:450px){
 #stage #sortie-status.sortie-corner{max-width:min(44%,150px)}
 #stage:has(#sortie-status:not([hidden])) .brand{right:calc(max(10px,env(safe-area-inset-right)) + min(44%,150px) + 6px);max-width:calc(100% - min(44%,150px) - 36px)}
 #stage .brand h1{font-size:16px}
 #stage .brand p{display:none}
}

/* Normal one-line recovery leaves the HOME heading fully readable. */
@media (orientation:portrait) and (max-width:450px){
 #stage:not(:has(#sortie-status[data-crowded="true"]:not([hidden]))) .brand{right:auto;max-width:none}
}

/* Names stay readable above the actual group without covering their faces. */
.room-label.result-group-label{padding:1px 4px;border-radius:5px;background:#050d19d6;color:#f4f6ff;max-width:90px;font-size:11px;font-weight:600;line-height:1.25}
.room-label.result-group-label small{display:none}
/* Fill the row with visible shortcuts; hidden buttons do not reserve a cell. */
#home-panel .secondary{grid-template-columns:repeat(auto-fit,minmax(44px,1fr))}
/* A label may wrap between its pictogram and word, not inside a Japanese word. */
#home-panel .secondary button{word-break:keep-all;overflow-wrap:normal;font-size:10px}
/* Compact outer padding keeps full-size labels and 44px hit targets with chat. */
@media (orientation:landscape) and (max-height:450px){
 #product-shell:has(#home-panel:not([hidden]) #chat-toggle:not([hidden])){grid-template-columns:minmax(0,1fr) calc(clamp(264px,29vw,330px) + max(0px,env(safe-area-inset-left) - 4px) + max(0px,env(safe-area-inset-right) - 4px))}
 #controls:has(#home-panel:not([hidden]) #chat-toggle:not([hidden])){padding-left:max(4px,env(safe-area-inset-left));padding-right:max(4px,env(safe-area-inset-right))}
 #home-panel .secondary:has(#chat-toggle:not([hidden])) #account-toggle{letter-spacing:-.1em}
}

@media (orientation:landscape) and (max-height:450px){
 #product-shell:has(#home-panel:not([hidden])){grid-template-columns:minmax(0,1fr) calc(clamp(264px,29vw,330px) + max(0px,env(safe-area-inset-left) - 4px) + max(0px,env(safe-area-inset-right) - 4px))}
 #controls:has(#home-panel:not([hidden])){padding-left:max(4px,env(safe-area-inset-left));padding-right:max(4px,env(safe-area-inset-right))}
 #stage .camera{left:calc(50% + env(safe-area-inset-left) / 2)}
 #stage .camera span{position:absolute;left:50%;bottom:100%;transform:translateX(-50%);white-space:nowrap}
 #stage .brand{left:max(20px,env(safe-area-inset-left))}
 #product-shell:has(#invite-panel:not([hidden])){grid-template-columns:minmax(0,1fr) calc(clamp(264px,29vw,330px) + max(0px,env(safe-area-inset-left) - 4px) + max(0px,env(safe-area-inset-right) - 4px))}
 #controls:has(#invite-panel:not([hidden])){padding-left:max(4px,env(safe-area-inset-left));padding-right:max(4px,env(safe-area-inset-right))}
 #invite-panel{gap:3px;padding-top:4px}
 #invite-panel #invite-consent{margin:0;line-height:1.2}
 #invite-panel #invite-consent a{display:inline-block;white-space:nowrap}
}

/* Keep landscape room, outfit, wardrobe and result actions in the safe area. */
@media (orientation:landscape) and (max-height:450px){
 #product-shell:has(#room-panel:not([hidden])),#product-shell:has(#outfits-panel:not([hidden])),#product-shell:has(#outfit-info-panel:not([hidden])),#product-shell:has(#wardrobe-panel:not([hidden])),#product-shell:has(#result-panel:not([hidden])){grid-template-columns:minmax(0,1fr) calc(clamp(264px,29vw,330px) + max(0px,env(safe-area-inset-left) - 4px) + max(0px,env(safe-area-inset-right) - 4px))}
 #controls:has(#room-panel:not([hidden])),#controls:has(#outfits-panel:not([hidden])),#controls:has(#outfit-info-panel:not([hidden])),#controls:has(#wardrobe-panel:not([hidden])),#controls:has(#result-panel:not([hidden])){padding-left:max(4px,env(safe-area-inset-left));padding-right:max(4px,env(safe-area-inset-right))}
}
@media (orientation:landscape) and (max-height:360px){
 #product-shell:has(#wardrobe-panel:not([hidden])) .camera{left:max(5px,env(safe-area-inset-left))}
 #wardrobe-panel .wardrobe-tabs{right:calc(clamp(264px,29vw,330px) + max(0px,env(safe-area-inset-left) - 4px) + max(0px,env(safe-area-inset-right) - 4px) + 4px)}
}

#online-queue-status:not([hidden]){
 display:grid;
 place-items:center;
 min-height:44px;
 border:1px solid #4e7789;
 color:#d6f0f4;
 background:#142d43;
}
#controls footer a {color:#c1dce9;text-underline-offset:2px;}

#stage[data-home-briefing] .brand {
 --briefing-goal:#e3f8ff;
 top:max(12px,env(safe-area-inset-top));
 left:0;
 width:100%;
 max-width:100%;
 padding:0 max(13px,env(safe-area-inset-left)) 12px;
 margin:0;
 z-index:2;
 background:linear-gradient(#060e1ad9,#060e1a99 77%,transparent);
}
#product-shell[data-ui-faction="defender"] #stage[data-home-briefing] .brand {--briefing-goal:#ffe0a7;}
#stage[data-home-briefing] .brand .eyebrow {font-size:9px;letter-spacing:.045em;}
#stage[data-home-briefing] .brand h1 {
 color:var(--briefing-goal);
 font-size:clamp(21px,6.2vmin,33px);
 font-weight:800;
 letter-spacing:.022em;
 line-height:1.25;
 text-align:center;
 text-shadow:0 2px 9px #000,0 0 12px #9bdcff45;
}
#stage[data-home-briefing] .brand p {
 display:block;
 margin-inline:auto;
 color:#d1e4f5;
 font-size:10px;
 text-align:center;
}
#stage[data-home-briefing] #camera-controls {z-index:2;}
#home-image-share {
 position:absolute;
 bottom:8px;
 right:max(8px,env(safe-area-inset-right));
 z-index:2;
 min-height:44px;
 padding:4px 9px;
 border-radius:22px;
 background:#081625dd;
 border:1px solid #88bbc56e;
 color:#e7f5ff;
 font-size:11px;
}
#room-invite-tools{position:absolute;bottom:8px;left:max(8px,env(safe-area-inset-left));z-index:2;display:flex;gap:4px;pointer-events:none}
.invite-scene{position:relative;width:44px;height:44px;display:flex;justify-content:center;align-items:center;gap:1px;padding:0;border:1px solid #88bbc56e;border-radius:22px;background:#081625dd;color:#e7f5ff;pointer-events:auto}
.invite-scene svg{display:block;width:24px;height:24px;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}
.invite-scene span,.invite-scene[data-cancel] svg{display:none}
.invite-scene[data-cancel] span{display:block;font-size:21px}
.home-identity-tools{display:flex;min-width:0;gap:4px}
.home-identity-tools button{pointer-events:auto;min-height:44px;padding:4px 9px;border:1px solid #88bbc56e;border-radius:22px;background:#081625ed;color:#e7f5ff;font-size:11px;line-height:1.15}
#home-title-access{display:grid;place-content:center;justify-items:center;gap:2px;max-width:84px}
#home-title-access strong{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--insignia-ink,#b7ddff)}
#home-membership{
 display:inline-flex;align-items:center;justify-content:center;gap:5px;
 border-color:#baa273;color:#ffefc9;
 background:linear-gradient(142deg,#54432f,#24243d 40%,#111827 79%);
 box-shadow:inset 0 1px 0 #ffefc344,inset 0 -1px 0 #251c15,0 2px 9px #08080caf;
}
#home-membership::before{
 content:'';display:block;flex:none;width:10px;height:13px;
 background:linear-gradient(144deg,#fff6d3 0 30%,#e9ba70 31% 58%,#8d633c 59%);
 clip-path:polygon(50% 0,100% 50%,50% 100%,0 50%);
}
#home-membership:is(:hover,:focus-visible){border-color:#ffe4ae;color:#fff5df}
.membership-offer:not([hidden]){
 --membership-art:url('./assets/membership-missions-20261203.webp');
 --membership-art-position:center;
 --membership-art-size:cover;
 position:relative;isolation:isolate;
 display:flex;align-items:center;justify-content:space-between;gap:14px;
 width:100%;min-height:63px;padding:8px 26px 8px 13px;
 border:1px solid transparent;border-radius:12px;text-align:start;color:#f2f6ff;
 background:
  linear-gradient(90deg,#090f20 0%,#090f20cc 34%,#090f2000 61%,#090f2094 100%) padding-box,
  var(--membership-art) var(--membership-art-position)/var(--membership-art-size) no-repeat padding-box,
  linear-gradient(112deg,#121828,#29334b 59%,#151b2b) padding-box,
  linear-gradient(120deg,#ffebaf,#76614b 31%,#ad8d60 52%,#f2ca87 76%,#8e6a46) border-box;
 box-shadow:inset 0 1px 0 #fff1cb38,inset 0 -1px 0 #070c21,0 4px 12px #020911a8;
}
.membership-offer[data-benefit="emotes"]:not([hidden]){--membership-art:url('./assets/membership-emotes-20261203.webp')}
.membership-offer[data-benefit="outfits"]:not([hidden]){--membership-art:url('./assets/membership-outfits-20261203.webp')}
.membership-offer[data-benefit]:not([hidden]){
 --membership-art-position:right 15% center;
 --membership-art-size:auto 104%;
}
.membership-overview-hero:not([hidden]){min-height:100px;padding:14px}
.membership-overview-hero::after{display:none}
.membership-overview-hero .membership-offer-copy{max-width:50%;line-height:1.25}
.membership-offer::before{
 content:'';position:absolute;inset:3px;border:1px solid #f2cb7d25;border-radius:8px;
 pointer-events:none;
}
.membership-offer::after{
 content:'';position:absolute;right:12px;top:50%;width:7px;height:7px;
 transform:translateY(-50%) rotate(45deg);border-top:1.5px solid #f5d393;border-right:1.5px solid #f5d393;
 filter:drop-shadow(0 0 4px #e2b885a0);pointer-events:none;
}
.membership-offer:is(:focus-visible,:hover){border-color:#ffe4ac;box-shadow:inset 0 0 16px #ffe7bb26,0 0 12px #f3d7974d}
.membership-offer-copy{display:grid;min-width:0;gap:3px;line-height:1.15}
.membership-offer-copy strong{
 color:#fff4d9;font-size:15px;letter-spacing:.055em;text-shadow:0 1px 2px #0a0e1a;
}
.membership-offer-copy>span{font-size:12px;color:#e9edf9;text-shadow:0 1px 2px #030712,0 0 4px #030712}
.membership-offer-price{
 flex:none;max-width:34%;padding:4px 6px;text-align:right;line-height:1.18;font-size:9px;
 color:#e5d9bb;background:#0e1527e8;border-inline-start:1px solid #f4cb805e;
}
.membership-offer-price b{display:block;color:#ffe8af;font-size:20px;font-variant-numeric:tabular-nums}
@media (min-width:960px) and (min-height:600px){
 .membership-offer:not([hidden]){min-height:77px}
 .membership-offer-copy strong{font-size:17px}
}
@media (max-width:450px){
 .membership-offer:not([hidden]){gap:8px}
}
@media (orientation:landscape) and (max-height:360px){
 #pose-panel:has(#emote-plan:not([hidden])){gap:3px;padding-top:3px}
 #pose-panel #pose-actions:not(:has(> :not([hidden]))){display:none}
 .membership-offer:not([hidden]){min-height:44px;padding:2px 19px 2px 8px;gap:4px}
 .membership-offer::after{right:8px}
 .membership-offer-copy{gap:2px}
 .membership-offer-copy strong{font-size:14px}
 .membership-offer-price b{font-size:16px}
}
#membership-dialog{box-sizing:border-box;width:min(calc(100% - 24px),30rem);max-height:calc(100dvh - 24px);overflow:auto;margin:auto;padding:14px;color:#e7f5ff;background:#0c1b2b;border:1px solid #75abbf80;border-radius:14px;box-shadow:0 14px 40px #0009;color-scheme:dark}
#membership-dialog::backdrop{background:#020814a6}
#first-play-followup{
 width:min(calc(100% - 24px),34rem);max-height:calc(100dvh - 24px);overflow:auto;
 padding:clamp(12px,4vw,24px);border:1px solid #8574b4;border-radius:18px;color:#f4efff;
 background:radial-gradient(ellipse at top left,#2b2156,#121932 58%,#0e1429);
 box-shadow:0 20px 72px #02030cdb;
}
#first-play-followup::backdrop{background:#040715b3}
#first-play-title{margin:2px 48px 14px 0;font-size:clamp(20px,4vw,28px);line-height:1.15}
#first-play-close{
 position:absolute;top:6px;right:6px;width:44px;height:44px;padding:0;color:#e6daff;font-size:24px;
}
.first-play-options{display:grid;gap:9px}
.first-play-options section{
 display:grid;grid-template-columns:26px minmax(0,1fr);gap:9px;align-items:start;
 padding:10px;border:1px solid #8072ac6e;border-radius:13px;background:#131d36bd;
}
.first-play-options section:nth-child(2){border-color:#6ab7bb76}
.first-play-options svg{
 width:24px;height:24px;fill:none;stroke:#beabff;stroke-width:1.55;stroke-linecap:round;stroke-linejoin:round;
}
.first-play-options section:nth-child(2) svg{stroke:#82e5dd}
.first-play-options h3{margin:0;font-size:15px;line-height:1.3;overflow-wrap:anywhere}
.first-play-options p{margin:4px 0 7px;color:#ddd9eb;font-size:12px;line-height:1.42;overflow-wrap:anywhere}
.first-play-options button{min-height:44px;text-wrap:balance;padding:5px 14px;border-radius:9px}
#first-play-invite{border:1px solid #6ab7bb;color:#a6eee5;background:#132c3e}
@media (orientation:landscape) and (max-height:480px){
 #first-play-followup{width:min(calc(100% - 24px),46rem)}
 .first-play-options{grid-template-columns:repeat(2,minmax(0,1fr))}
}
#membership-dialog header{display:flex;align-items:center;justify-content:space-between;gap:12px}
#membership-dialog h2{margin:0;font-size:19px}
#membership-dialog p{margin:.48em 0;line-height:1.45}
#membership-dialog .membership-price strong{font-size:26px;color:#b1ecff}
.membership-details{
 margin-block:8px;padding:10px 15px;border:1px solid #9b8055;border-radius:10px;
 background:linear-gradient(90deg,#151b30 8%,#151b30ed 51%,#12152370 85%),url('./assets/membership-signal-20261202.webp') right center/cover;
 box-shadow:inset 0 1px 0 #fff1cb3a;
}
#membership-dialog .membership-details .membership-price{color:#f1ddaf}
#membership-dialog .membership-details .membership-price strong{color:#ffe6ad}
#membership-dialog .membership-details p{position:relative;max-width:28ch;margin-block:2px;color:#eef3ff;text-shadow:0 1px 4px #070b19}
#membership-dialog button{min-height:44px}
#membership-close{width:44px;font-size:22px}
#membership-dialog a{display:inline-block;padding:7px 0;color:#b1d9ff}
.membership-actions{display:flex;flex-wrap:wrap;gap:8px}
#membership-embed form{display:grid;gap:8px}

.briefing-model {
 grid-column:1/-1;
 justify-self:start;
 margin-top:3px;
 pointer-events:none;
 font-size:9px;
 color:#cbdbe8;
 padding:2px 5px;
 border:1px solid #b6d1e054;
 background:#080f20d4;
 border-radius:2px;
}
.home-commander {
 --commander-accent:#d3a7ff;
 position:absolute;
 inset:var(--briefing-top) auto auto var(--briefing-left);
 width:var(--briefing-width);
 height:var(--briefing-height);
 box-sizing:border-box;
 padding-block-start:18px;
 display:grid;
 align-items:center;
 pointer-events:none;
 visibility:hidden;
}
.home-commander[data-projected] {visibility:visible;}
.home-commander[data-role="defender"] {--commander-accent:#ffdf9c;}
#briefing-story-visual:not([hidden]) {display:inline-flex;align-items:center;gap:5px;margin-inline-start:5px;}
.briefing-story-nodes {display:inline-flex;gap:3px;color:var(--accent,#99dafa);}
.briefing-story-nodes i {width:5px;height:5px;border-radius:50%;border:1px solid currentColor;}
#briefing-story-visual[data-step="targets"] i,
#briefing-story-visual[data-step="decisive"] i:nth-child(-n+3) {background:currentColor;}
.home-commander .commander-bubble {
 position:relative;
 display:grid;
 grid-template-columns:minmax(0,1fr) auto;
 align-items:center;
 column-gap:6px;
 padding:2px 8px 6px;
 border:1px solid color-mix(in srgb,var(--commander-accent) 62%,#182334);
 border-radius:9px 9px 3px 9px;
 background:linear-gradient(135deg,#0c1323f5,#141c32f2);
 box-shadow:0 4px 14px #050910b8;
}
.home-commander .commander-bubble::after {
 content:"";
 position:absolute;top:45%;left:100%;
 border-block:5px solid transparent;
 border-inline-start:7px solid var(--commander-accent);
}
.home-commander:is([data-page="1"],[data-page="2"]) #briefing-quote {color:#fff;}
.home-commander .commander-bubble h2 {grid-area:1/1;margin:0;color:var(--commander-accent);font-size:11px;line-height:1.2;}
.home-commander #briefing-quote {grid-column:1/-1;margin:0;font-size:clamp(11px,2.6vmin,14px);line-height:1.29;font-weight:620;white-space:pre-line;overflow-wrap:anywhere;}
.home-commander #briefing-quote strong {color:var(--commander-accent);font-weight:800;}
.home-commander .commander-pages {grid-area:1/2;display:flex;justify-content:flex-end;align-items:center;gap:2px;color:#bcd0df;font-size:10px;font-variant-numeric:tabular-nums;}
.home-commander .commander-pages button {pointer-events:auto;min-width:30px;min-height:28px;padding:0;font-size:17px;line-height:1;color:var(--commander-accent);background:transparent;border:0;}
.home-commander .commander-pages button:disabled {opacity:.3;}
@media (max-width:500px), (max-height:500px) {
 .home-commander #briefing-quote {font-size:clamp(10px,2.55vmin,12px);line-height:1.18;}
 .home-commander .commander-bubble {padding:1px 3px 3px;gap:2px;}
 .home-commander .commander-bubble h2 {font-size:9px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
 .home-commander .commander-pages button {min-width:21px;min-height:22px;}
 .home-commander .commander-pages {gap:0;font-size:8px;}
}
@media (max-width:400px), (orientation:landscape) and (max-height:390px) {
 .home-commander {
  left:max(8px,env(safe-area-inset-left),calc(var(--briefing-left) - 16%));
  right:calc(100% - var(--briefing-left) - var(--briefing-width));
  width:auto;
  height:auto;
  padding-block-start:7px;
 }
 #briefing-story-visual:not([hidden]){flex-wrap:wrap;gap:2px 5px;margin-inline-start:0}
}
@media (orientation:landscape) and (max-height:390px) {
 .home-commander {padding-block-start:16px;}
}
@media (orientation:landscape) and (max-height:460px) {
 #stage[data-home-briefing] .brand {top:max(5px,env(safe-area-inset-top));padding-bottom:0;}
 #stage[data-home-briefing] .brand h1 {margin-block:1px 2px;}
}
#stage[data-home-briefing] .camera {
 left:50%;
 bottom:4px;
 flex-direction:row;
 gap:0;
 padding:0;
 transform:translateX(-50%);
}
#stage[data-home-briefing] .camera button {min-width:44px;min-height:44px;}
#stage[data-home-briefing] .camera span {display:none;}
@media (max-width:460px) {
 #product-shell:not(:has(#result-panel:not([hidden]))) #camera-hint {
  position:absolute;left:50%;bottom:100%;transform:translateX(-50%);pointer-events:none;
 }
}
@media (pointer:coarse) {
 #camera-controls {display:none;}
}
@media (any-pointer:coarse) {
 #product-shell[data-result-page] #camera-controls {display:none;}
}

#home-stage-brief {position:absolute;inset:0;z-index:5;min-height:0;padding:8px;gap:7px;}
#home-stage-brief:not([data-boarding]) .stage-brief-art {height:clamp(44px,24dvh,200px);}
#home-stage-brief[data-boarding] {
 position:fixed;
 z-index:15;
 padding:max(12px,env(safe-area-inset-top)) max(13px,env(safe-area-inset-right))
    max(12px,env(safe-area-inset-bottom)) max(13px,env(safe-area-inset-left));
 gap:clamp(10px,2.5vmin,22px);
}
@media (orientation:portrait) and (max-height:650px){
 #stage[data-home-briefing] .brand h1 {margin-block:1px 2px;}
 #stage[data-home-briefing] .camera {bottom:4px;}
 #home-stage-brief:not([data-boarding]) .stage-brief-art {height:clamp(44px,20dvh,130px);}
}

/* Purchase controls are enabled by the server's Stripe test settings. */
#outfit-purchase-controls {
  display: grid;
  gap: 4px;
  min-width: 0;
}

#outfit-purchase-note {
  color: #b5d9d8;
}

#outfit-purchase-consent {
  margin: 0;
  line-height: 1.3;
}

.outfit-purchase-actions,.outfit-order-actions {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}

.outfit-purchase-actions button,.outfit-transaction button {
  min-height: 44px;
  padding: 3px 10px;
  border: 1px solid #4e657f;
  border-radius: 8px;
  background: #152a41;
  color: #e5f8ff;
  font-size: 12px;
}

.outfit-purchase-actions .outfit-buy,#outfit-payment-next,#outfit-payment-submit {
  color: #fff0cb;
  background: linear-gradient(112deg,#403124,#252236 50%,#1b2436);
  border: 1px solid #be9e70;
  box-shadow: inset 0 1px 0 #ffe1af3b, 0 2px 8px #090d18a0;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.outfit-purchase-actions .outfit-buy:hover:enabled,
#outfit-payment-next:hover:enabled,#outfit-payment-submit:hover:enabled {
  border-color:#ffdc9d;
  color:#fff4d7;
  box-shadow:inset 0 0 12px #ffe4ad26,0 0 8px #ffe4ad35;
}

#holiday-purchase-controls button {
  font-size: 11px;
  padding-inline: 8px;
  white-space: nowrap;
}

.outfit-purchase-actions [id^=outfit-buy] {
  flex: 1;
}

#outfit-purchase-controls[data-has-pending] .outfit-buy {
  display: none;
}

#outfit-info-panel:has(#outfit-purchase-controls:not([hidden])) #outfit-catalog-items button {
  min-height: 44px;
}

#outfit-info-panel:has(#outfit-purchase-controls:not([hidden])) .outfit-catalog-thumb {
  height: 37px;
}

#checkout-panel[data-cosmetic-phase] #checkout-embed {
  align-items: center;
  overflow: visible;
}

.checkout-open:has(#checkout-panel[data-cosmetic-phase]) #controls {
  border-color:#8f775d;
  background:
    radial-gradient(ellipse at 86% 0%,#322942c4,transparent 56%),
    linear-gradient(145deg,#19233a,#111a29 70%);
  box-shadow:inset 1px 0 0 #ffe0ab2d;
}

.checkout-open #checkout-panel[data-cosmetic-phase]>.section-head {
  display: flex;
}

#checkout-panel[data-cosmetic-phase] .section-head h2 {
  color:#f5dfb0;
  overflow-wrap:anywhere;
}

#checkout-panel[data-cosmetic-phase] .section-head button {
  min-height: 44px;
}

@media (orientation:landscape) and (min-width:960px) and (min-height:600px) {
  #product-shell.checkout-open:has(#checkout-panel[data-cosmetic-phase]) {
    grid-template-columns: minmax(0,1fr) clamp(420px,46vw,556px);
  }
  .checkout-open:has(#checkout-panel[data-cosmetic-phase]) #controls {
    padding-inline: 16px max(16px,env(safe-area-inset-right));
  }
  #checkout-panel[data-cosmetic-phase] .outfit-transaction {
    max-width: 480px;
  }
}

.outfit-transaction {
  display: grid;
  align-content: start;
  width: min(100%,520px);
  min-width: 0;
  gap: 5px;
}

.outfit-transaction-content {
  display: grid;
  gap: 5px;
  min-width: 0;
}

#checkout-embed .outfit-order-status {
  font-size: 14px;
  font-weight: 600;
  color: #d8f1ff;
}

#checkout-embed .outfit-payment-price {
  color: #fbedcb;
  font-size: 18px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

#checkout-embed .outfit-transaction form .stripe-test-frame {
  overflow: visible;
  min-height: 40px;
}

/* Keep the surrounding HOME fixed and scroll only within Stripe's full form. */
#checkout-panel:has(.stripe-managed-frame), #checkout-embed:has(.stripe-managed-frame) {
  min-height: 0;
  flex: 1;
}
#checkout-embed form.stripe-managed-form, #checkout-embed .stripe-managed-frame,
#checkout-embed .stripe-managed-form .stripe-managed-frame {
  min-height: 0;
  flex: 1;
}
#checkout-embed .stripe-managed-frame, #checkout-embed .stripe-managed-form .stripe-managed-frame {
  width: 100%;
  overflow: auto;
  overscroll-behavior: contain;
}
#checkout-panel[data-cosmetic-phase] .stripe-managed-frame {
  border:1px solid #967953;
  border-radius:9px;
  box-shadow:0 3px 13px #080f1bb0;
}
.outfit-transaction:has(.stripe-managed-frame) {
  flex: 1;
  min-height: 0;
  grid-template-rows: auto minmax(0,1fr);
  align-content: stretch;
}
.outfit-transaction-content:has(.stripe-managed-frame) {
  grid-template-rows: auto minmax(0,1fr) auto;
}

.stripe-test-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 3px 8px;
  color: #d9e6f3;
  font-size: 12px;
}
.stripe-test-card[hidden] { display: none; }
.stripe-test-card button,.outfit-transaction .stripe-test-card button {
  min-height: 32px;
  font-variant-numeric: tabular-nums;
  border: 1px solid #728aab;
  background: #182942;
  color: #e5f8ff;
  padding-inline: 8px;
  border-radius: 6px;
}

.outfit-result-list {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.outfit-result-list li {
  min-height: 44px;
  display: flex;
  gap: 6px;
  align-items: center;
  min-width: 0;
  padding: 6px 7px;
  border: 1px solid #7267a6;
  border-radius: 8px;
  background: linear-gradient(125deg,#282746,#151d3b);
  color: #f6efff;
}

.outfit-result-list li strong {
  font-size: 12px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.outfit-result-preview {
  position: relative;
  display: grid;
  place-items: center;
  flex: none;
  width: 31px;
  height: 34px;
  border-radius: 4px;
  background: #151829;
}

.outfit-result-preview img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #151829;
  border-radius: 4px;
}

.outfit-result-number {
  color: #caf9ed;
  font: 700 11px/1 monospace;
  letter-spacing: .09em;
}

.outfit-result-pager {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 7px;
  align-items: center;
  color: #a9c8d8;
  font-size: 12px;
}

#outfit-result-close {
  justify-self: start;
}

.outfit-reveal-art {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  min-height: 90px;
  max-height: 150px;
  aspect-ratio: 2.8;
  overflow: hidden;
  border: 1px solid #584888;
  border-radius: 10px;
  background: radial-gradient(ellipse,#33235d,#0e142d 70%);
}

.outfit-reveal-art::before,.outfit-reveal-art::after {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(90deg,transparent 0 18%,#ad91f62d 18.3% 18.5%,transparent 19% 25%);
  mask-image: linear-gradient(0deg,transparent,#000 35% 65%,transparent);
  pointer-events: none;
}

.outfit-reveal-art::after {
  inset: 12% 7%;
  background: repeating-linear-gradient(0deg,transparent 0 26%,#8eecf431 28%,transparent 29% 33%);
  opacity: .8;
}

.outfit-reveal-lock {
  width: 46px;
  aspect-ratio: 1;
  position: relative;
  z-index: 1;
  border: 1px solid #bba8f2;
  background: #443679;
  transform: rotate(45deg);
  box-shadow: 0 0 24px #bba8f288,inset 0 0 12px #8feee9b3;
  animation: outfit-vault-open 1.8s ease-in-out both;
}

.outfit-reveal-lock::after {
  content: '';
  position: absolute;
  inset: 23%;
  border: 1px solid #a6f3ee;
  box-shadow: 0 0 12px #91eed9;
}

.outfit-reveal-scan {
  position: absolute;
  z-index: 2;
  width: 80%;
  height: 2px;
  background: #b6fff4;
  box-shadow: 0 0 14px 3px #b284f0;
  animation: outfit-vault-scan 1.25s ease-out both;
}

@keyframes outfit-vault-open {
  0% {
    transform: rotate(45deg) scale(.72);
    opacity: .55;
  }
  57% {
    transform: rotate(90deg) scale(1);
    opacity: 1;
  }
  100% {
    transform: rotate(135deg) scale(1.55);
    opacity: .25;
  }
}

@keyframes outfit-vault-scan {
  0% {
    transform: translateY(-50px);
    opacity: .12;
  }
  60% {
    opacity: .86;
  }
  100% {
    transform: translateY(50px);
    opacity: 0;
  }
}

@media(prefers-reduced-motion:reduce) {
  .outfit-reveal-lock,.outfit-reveal-scan {
    animation: none;
  }
}

@media(orientation:portrait) and (max-height:650px) {
  #outfit-info-panel:has(#outfit-purchase-controls:not([hidden])) #outfit-catalog-items button {
    grid-template-columns: 33px minmax(0,1fr);
  }
  #outfit-info-panel:has(#outfit-purchase-controls:not([hidden])) .outfit-catalog-thumb {
    height: 33px;
  }
}

@media(orientation:landscape) and (max-height:450px) {
  #outfit-info-panel:has(#outfit-purchase-controls:not([hidden])) #outfit-catalog-items button {
    grid-template-columns: minmax(0,1fr);
  }
  #outfit-info-panel:has(#outfit-purchase-controls:not([hidden])) .outfit-catalog-thumb {
    height: 24px;
  }
  .outfit-reveal-art {
    aspect-ratio: 3.9;
    min-height: 68px;
    max-height: 125px;
  }
}

#controls:where(:has(#player-language)){grid-template-rows:44px minmax(0,1fr) auto}
#player-language{max-width:8.5rem;min-height:34px;padding-inline:4px;background:#102436;color:#e2edf9;
  border:1px solid #567486;border-radius:6px;font:inherit;font-size:11px}
#controls footer nav:has(#player-language){align-items:center;justify-content:center;flex-wrap:wrap;row-gap:0}
#player-language:focus-visible{outline:2px solid #90cfe6;outline-offset:2px}
@media (orientation:landscape) and (max-height:360px){
 #controls footer nav:has(#player-language){display:grid;width:100%;grid-template-columns:minmax(0,.7fr) minmax(0,1.3fr) auto;gap:4px}
 #controls footer nav:has(#player-language)>a{white-space:normal;text-align:center;overflow-wrap:anywhere}
}
.participation-consent a{display:inline-block;max-width:100%;white-space:nowrap}

/* In a wide HOME, the operation controls sit over the same full-size room.
   The untouched left side remains the 3D movement and camera surface. */
@media (orientation:landscape) and (min-width:960px) and (min-height:600px) {
  #product-shell:not([data-result-page],.checkout-open) {
    --home-deck-width: clamp(352px,33.5vw,438px);
    --home-deck-margin: max(18px,calc(env(safe-area-inset-right) + 12px));
    grid-template: minmax(0,1fr) / minmax(0,1fr);
  }
  #product-shell:not([data-result-page],.checkout-open) > #stage,
  #product-shell:not([data-result-page],.checkout-open) > #controls {
    grid-area: 1 / 1;
  }
  #product-shell:not([data-result-page],.checkout-open) > #controls {
    justify-self: end;
    align-self: center;
    width: var(--home-deck-width);
    height: auto;
    max-height: calc(100% - 2 * max(16px,env(safe-area-inset-top),env(safe-area-inset-bottom)));
    margin-inline-end: var(--home-deck-margin);
    padding: 8px 18px 5px;
    grid-template-rows: auto minmax(0,auto) auto;
    border: 1px solid #517587;
    border-radius: 16px;
    background: linear-gradient(145deg,#12283aef,#091628f5 74%);
    box-shadow: 0 14px 40px #0007;
  }
  #product-shell:not([data-result-page],.checkout-open) #home-stage-brief:not([data-boarding]) {
    right: calc(var(--home-deck-width) + var(--home-deck-margin) + 16px);
  }
  #product-shell:not([data-result-page],.checkout-open) #controls .sections button {
    min-height: 48px;
    padding-inline: 5px;
    font-size: 13px;
    white-space: normal;
  }
  #product-shell:not([data-result-page],.checkout-open) #home-audio span{white-space:nowrap}
  #product-shell:not([data-result-page],.checkout-open) #controls .panel {
    padding-top: 10px;
    gap: 8px;
  }
  #product-shell:not([data-result-page],.checkout-open) #controls .section-head button {
    min-height: 44px;
  }
  #product-shell:not([data-result-page],.checkout-open) #controls .guidance,
  #product-shell:not([data-result-page],.checkout-open) #controls .participation-consent {
    font-size: 12px;
    line-height: 1.35;
  }
  #product-shell:not([data-result-page],.checkout-open) #home-panel #online[data-launch] {
    min-height: 56px;
  }
  #product-shell:not([data-result-page],.checkout-open) #home-panel .secondary {
    gap: 5px;
  }
  #product-shell:not([data-result-page],.checkout-open) #home-panel .secondary button {
    min-height: 44px;
    padding: 4px 3px;
    font-size: 12px;
  }
  #product-shell:not([data-result-page],.checkout-open) #controls footer nav {
    flex-wrap: wrap;
    justify-content: center;
    column-gap: 12px;
  }
  #product-shell:not([data-result-page],.checkout-open) #controls footer a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-size: 11px;
    white-space: normal;
  }
}

.account-player-code {display:flex;flex-wrap:wrap;gap:.35em 1em;margin:0;color:#d3e7f6;font-size:.8rem;}
.account-player-code dd {margin:0;overflow-wrap:anywhere;user-select:all;}
#record-milestones {flex-basis:100%;color:#c5dbeb;}
#record-own {flex-wrap:wrap;row-gap:4px;}

/* The wide result deck overlays the stage so the whole 3D scene stays in view. */
@media (orientation:landscape) and (min-width:960px) and (min-height:450px) and (pointer:fine) {
 #product-shell[data-result-page]:has(> #stage) {
  grid-template:minmax(0,1fr) / minmax(0,1fr);
 }
 #product-shell[data-result-page] > :is(#stage,#controls) {grid-area:1 / 1}
 #product-shell[data-result-page] > #controls {
  justify-self:end;align-self:end;width:clamp(336px,29vw,410px);height:auto;
  margin-inline-end:max(18px,calc(env(safe-area-inset-right) + 12px));
  margin-block-end:max(18px,calc(env(safe-area-inset-bottom) + 12px));
  padding:12px 14px;
  border:1px solid color-mix(in srgb,var(--console-light,#a4dfe7) 42%,#2a3949);
  border-radius:16px;
  background:linear-gradient(145deg,#152438ef,#0b1527f5 74%);
  box-shadow:0 10px 30px #020711b3;
 }
 #product-shell[data-result-page] #controls > .panel {gap:8px;padding:0}
 #result-panel .section-head h2 {font-size:clamp(20px,2vw,26px);line-height:1.12}
 #result-panel #return-home {min-height:48px;margin:0;font-size:14px}
}

#membership-dialog .membership-perks {
  display:grid;
  gap:.4rem;
  margin:.65rem 0 0;
  padding-inline-start:1.3rem;
  color:#eef3ff;
}
.membership-perks li::marker {color:#f0ce87}
#outfits-panel #owned-outfits-open {
  align-self:start;
  min-height:44px;
}
#stage[data-outfit-showcase] #room-labels,
#stage[data-outfit-showcase] .brand,
#stage[data-outfit-showcase] .camera {
  display:none;
}
#stage .outfit-showcase {
  position:absolute;
  inset:auto 12px 14px;
  margin-inline:auto;
  width:fit-content;
  max-width:calc(100% - 24px);
  display:grid;
  justify-items:center;
  gap:2px;
  z-index:3;
  pointer-events:none;
  padding:6px 17px;
  border:1px solid #dbb16985;
  color:#fff3d2;
  background:#111a28e8;
  box-shadow:0 0 27px #cc9a4d4d;
  text-align:center;
  overflow-wrap:anywhere;
}
#stage .outfit-showcase[hidden] {display:none}
#stage[data-outfit-showcase] .outfit-showcase {
  border:1px solid #ffdd8499;
  border-radius:12px;
  background:linear-gradient(145deg,#533614ed,#1b130fed 70%);
  box-shadow:0 0 24px #ffb65d66,inset 0 1px #fff1b64d;
}
#outfit-showcase-position {font:600 11px ui-monospace,monospace;color:#e6bd7a}
#stage[data-outfit-showcase] ~ #controls #outfit-order-status {
  color:#ffe5a7;
  text-shadow:0 0 12px #dd9d4660;
}
#stage[data-outfit-showcase] ~ #controls #outfit-result-close {
  border-color:#c49954;
  background:linear-gradient(150deg,#6a451b,#392815);
  color:#fff3d3;
}
#stage[data-outfit-showcase] ~ #controls .outfit-result-list {
  margin-block:0;
  padding:0;
  grid-template-columns:minmax(0, 1fr);
}
#stage[data-outfit-showcase] ~ #controls .outfit-result-list li {
  min-height:0;
  background:transparent;
  border:0;
  padding:0;
}
@media (orientation:portrait) {
  #product-shell.checkout-open:has(#stage[data-outfit-showcase]) {
    grid-template-rows:minmax(0,1fr) minmax(146px,30%);
  }
}
@media (orientation:landscape) {
  #product-shell.checkout-open:has(#stage[data-outfit-showcase]) {
    grid-template-columns:minmax(0,1fr) clamp(235px,34vw,410px);
  }
}

/* Collection pages share the fixed control deck. Only the current page requests art. */
#controls .sections [data-tab="collection"]{flex:1 1 auto;min-width:0;font-size:clamp(9px,2.8vmin,12px);letter-spacing:-.03em}
#product-shell[data-commerce-locked] :is(#home-membership,#outfits-membership,#outfit-sale-membership,#emote-plan,[data-purchase-login])[inert]{opacity:.42;cursor:default}
#collection-panel{--collection-ink:#dfc3ff;--collection-line:#9a68d7;display:grid;align-content:start;gap:5px}
#collection-panel[hidden]{display:none}
:is(#collection-panel,#collection-preview,.collection-reward)[data-collection-tone="defender"]{--collection-ink:#ffe4a8;--collection-line:#ce9f4c}
.collection-heading{min-width:0;align-items:center;gap:4px}
.collection-heading h2{font-size:clamp(12px,4.2vmin,18px);overflow-wrap:anywhere}
.collection-factions{display:flex;gap:3px;flex:none}
.collection-factions button{min-height:32px;min-width:44px;padding:3px 6px;border-radius:6px;color:#bbcede;font-size:10px;font-weight:750}
.collection-factions button[aria-pressed="true"]{background:#1e1a31;color:var(--collection-ink);box-shadow:inset 0 0 0 1px var(--collection-line)}
.collection-factions #collection-owned-filter{
 max-inline-size:8.6em;white-space:normal;overflow-wrap:anywhere;line-height:1.15;
 border:1px solid #536b83;padding-inline:5px;
}
#collection-owned-filter:disabled{opacity:.55}
#collection-status{margin:0;font-size:11px;line-height:1.16;text-wrap:pretty}
#collection-grid:not([hidden]){display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:5px}
.collection-tile{
 position:relative;isolation:isolate;display:grid;align-content:end;min-width:0;min-height:clamp(62px,9dvh,87px);
 padding:3px 4px;overflow:hidden;text-align:left;border:1px solid #476177;border-radius:7px;background:#0f202e;
}
.collection-tile img{position:absolute;inset:0;width:100%;height:100%;z-index:-2;object-fit:cover;object-position:center 43%;filter:grayscale(1) brightness(.83)}
.collection-tile::before{content:"";position:absolute;inset:26% 0 0;background:linear-gradient(transparent,#070c1bf5 82%);z-index:-1}
.collection-tile[data-owned]{border-color:var(--collection-line)}
.collection-tile[data-owned] img{filter:none}
.collection-tile span,.collection-tile small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-shadow:0 1px 3px #020611;font-size:10px;line-height:1.24}
.collection-tile span{font-weight:720;color:#f3f5ff}
.collection-tile small{color:#c2d1de}
.collection-tile[data-owned] small{color:var(--collection-ink)}
.collection-tile[data-mystery]{
 place-items:center;align-content:center;border-style:dashed;
 background:radial-gradient(ellipse at center,#293249,#101a2a 82%);
}
.collection-tile[data-mystery] span{font:700 18px/1 ui-monospace,monospace;color:#ccd8e7;letter-spacing:.1em}
#collection-pager:not([hidden]){display:flex;align-items:center;justify-content:center;gap:10px;min-height:34px}
#collection-pager button{min-height:34px;min-width:44px;padding:0;font-size:21px;color:var(--collection-ink)}
#collection-page{min-width:3em;text-align:center;font-variant-numeric:tabular-nums;color:#c2d1de}
#collection-detail:not([hidden]){display:grid;gap:4px;min-width:0}
#collection-detail-name{color:var(--collection-ink);font-size:clamp(14px,4.3vmin,21px);line-height:1.12;overflow-wrap:anywhere}
#collection-detail-motif{font-size:12px;color:#cfdaea;overflow-wrap:anywhere}
#collection-detail-status{margin:0;line-height:1.21}
.collection-actions{display:flex;gap:4px;flex-wrap:wrap}
.collection-actions button{min-height:36px;padding:5px 8px;font-size:11px;border-radius:8px;white-space:normal}
.collection-actions button:not(.primary){background:#152f43}
#collection-preview:not([hidden]){
 --collection-ink:#dfc3ff;--collection-line:#9a68d7;
 position:absolute;inset:0;z-index:3;display:grid;place-items:center;margin:0;pointer-events:none;
 background:radial-gradient(ellipse at center,#130e22db,#080d19bc 74%,#040811d9);
}
#collection-preview img{display:block;width:min(74%,440px);height:84%;object-fit:contain;filter:drop-shadow(0 0 15px var(--collection-line))}
#collection-preview[data-unowned] img{filter:grayscale(1) drop-shadow(0 0 12px #d4e1f160)}
#result-story-impact{margin:.42rem 0 0;max-width:34em;font-size:clamp(10px,3vmin,15px);line-height:1.27;text-wrap:pretty;color:#f4f7ff}
#result-story-impact strong{color:var(--verdict-accent,#e7caff);font-weight:800;text-shadow:0 0 .5em #09051d}
.collection-reward:not([hidden]){
 --collection-ink:#dfc3ff;--collection-line:#9a68d7;
 display:grid;grid-template-columns:38px minmax(0,1fr);gap:8px;align-items:center;min-height:46px;padding:3px 7px;
 background:linear-gradient(120deg,#172639,#0e1b2b);border:1px solid var(--collection-line);border-radius:9px;
}
.collection-reward img{width:38px;height:38px;object-fit:cover;border-radius:6px}
.collection-reward div{display:flex;align-items:baseline;flex-wrap:wrap;gap:1px 6px;min-width:0;line-height:1.24}
.collection-reward small{width:100%;font-size:9px;color:var(--collection-ink)}
.collection-reward strong,.collection-reward span{white-space:nowrap;text-overflow:ellipsis;overflow:hidden;max-width:100%}
.collection-reward strong{font-size:12px}.collection-reward span{font-size:10px;color:#c1cedc}
.collection-reward[data-new]{box-shadow:inset 0 0 18px #c99ce12a,0 0 12px #b48ad234}
@media (prefers-reduced-motion:no-preference){.collection-reward[data-new]{animation:collection-unlock .55s ease-out}}
@keyframes collection-unlock{from{opacity:.35;transform:translateY(4px)}to{opacity:1;transform:none}}
@media (orientation:landscape) and (max-height:440px){
 #collection-panel{gap:4px}
 .collection-tile{min-height:60px}
 .collection-factions button,#collection-pager button,.collection-actions button{min-height:28px}
 #result-story-impact{max-width:24em;font-size:10px}
}

/* Empty tokens and the collection detail share the same HOME controls as the other tabs. */
#stage #sortie-status[data-empty]{border:1px solid #ebba70;background:#201b24f5;box-shadow:0 0 12px #d59e452d}
#sortie-status[data-empty] .sortie-key.empty{color:#f1c485}
#sortie-status .sortie-offer{pointer-events:auto;display:block;margin-inline-start:auto;max-inline-size:100%;min-block-size:32px;padding:3px 1px;background:none;border:none;color:#ffdb9e;font:700 12px/1.15 system-ui,sans-serif;white-space:normal;text-align:end}
#product-shell[data-commerce-locked] .sortie-offer{display:none}
#collection-back{margin-inline-start:auto;flex:none}
#collection-panel .collection-factions[hidden]{display:none}
