html body dialog.boss-hall{width:min(1100px,calc(100vw - 24px));max-width:none;max-height:calc(100dvh - 24px);padding:0;border:1px solid #b98a43;border-radius:22px;background:#111d31;color:#f8f2e8;box-shadow:0 24px 80px #0009;overflow:auto}
html body dialog.boss-hall::backdrop{background:#071321c9;backdrop-filter:blur(3px)}
.boss-hall-shell{padding:16px;display:grid;gap:12px}
.boss-hall-head{display:flex;justify-content:space-between;align-items:center;gap:12px}
.boss-hall-head small{display:block;color:#f3c970;font-size:12px;font-weight:800;letter-spacing:.13em}
.boss-hall-head h2{margin:2px 0 0;color:#fff;font-size:clamp(22px,3vw,32px)}
html body dialog.boss-hall button{font:inherit;cursor:pointer}
.boss-hall-close{width:42px;height:42px;flex:none;border:1px solid #8d9db5;border-radius:50%;background:#263a57;color:#fff}
.boss-hall-tabs{display:flex;gap:8px}
.boss-hall-tabs button{flex:1;min-height:42px;border:1px solid #637997;border-radius:11px;background:#263a57;color:#e8f1ff;font-weight:800}
.boss-hall-tabs button[aria-selected="true"]{border-color:#f3bf59;background:#f8df9f;color:#332817}
.boss-hall-live{display:inline-block;margin-left:5px;padding:2px 5px;border-radius:5px;background:#af271e;color:#fff;font-size:10px;vertical-align:middle}
.boss-hall-scene{position:relative;display:grid;grid-template-columns:minmax(0,1.1fr) minmax(320px,.9fr);min-height:340px;overflow:hidden;border:1px solid #5b7292;border-radius:16px;background:linear-gradient(90deg,#132039aa,#14213fe8),url('../img/transitions/06-boss-battle.webp') center/cover}
.boss-hall-scene.boss-hall-world{min-height:460px;background:linear-gradient(90deg,#160d08a0 0%,#22100a40 48%,#160d0be8 64%,#160d0bf5 100%),url('../img/world-boss/wb-01-bg.webp') center 54%/cover}
.boss-hall-world .boss-hall-art{min-height:420px}
.boss-hall-world .boss-hall-art img{width:min(88%,420px);height:400px;filter:drop-shadow(0 16px 22px #100600dd)}
.boss-hall-world .boss-hall-info{background:linear-gradient(90deg,#1a0d0a82,#170c0ace)}
.boss-hall-scene.boss-hall-festival{background:linear-gradient(90deg,#4a1f21a8,#40202ce8),url('../img/transitions/06-boss-battle.webp') center/cover}
.boss-hall-art{position:relative;display:grid;place-items:center;min-height:270px}
.boss-hall-art img{width:min(82%,350px);height:300px;object-fit:contain;filter:drop-shadow(0 12px 25px #0009)}
.boss-hall-art span{position:absolute;left:12px;bottom:10px;padding:4px 9px;border-radius:20px;background:#09172ad9;color:#dbe5f3;font-size:11px}
.boss-hall-info{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:12px;padding:28px;color:#fff}
.boss-hall-info h3{margin:0;font-size:clamp(24px,3vw,36px);color:#fff}
.boss-hall-info p{margin:0;line-height:1.65;color:#e9f1fb}
.boss-hall-info small{color:#f8ddb0;line-height:1.5}
.boss-hall-status{display:inline-block;padding:5px 10px;border:1px solid #e5b862;border-radius:99px;background:#45351c;color:#ffe1a0;font-size:13px;font-weight:800}
.boss-hall-status.is-live{border-color:#91dba2;background:#153b2b;color:#bbf1c5}
.boss-hall-facts,.boss-hall-actions{display:flex;flex-wrap:wrap;gap:8px}
.boss-hall-facts span{padding:7px 10px;border:1px solid #7c90aa;border-radius:8px;background:#20334d;color:#dce9f9;font-size:13px}
.boss-hall-actions button{min-height:42px;padding:7px 14px;border:1px solid #f1bf61;border-radius:9px;background:#f6d388;color:#34260d;font-weight:800}
.boss-hall-actions button:hover{background:#ffe7af}
html body dialog.boss-hall button:focus-visible{outline:3px solid #fff;outline-offset:2px}
@media(max-width:700px){.boss-hall-shell{padding:10px;gap:8px}.boss-hall-scene{grid-template-columns:1fr}.boss-hall-art{min-height:150px}.boss-hall-art img{height:170px}.boss-hall-info{padding:16px;gap:9px}.boss-hall-info h3{font-size:24px}}
@media(max-width:700px){.boss-hall-scene.boss-hall-world{min-height:0;background-position:center 56%}.boss-hall-world .boss-hall-art{min-height:230px}.boss-hall-world .boss-hall-art img{height:225px;width:min(75%,270px)}.boss-hall-world .boss-hall-info{background:#180d0cde}}
@media(max-height:520px) and (min-width:701px){.boss-hall-shell{padding:8px 12px;gap:7px}.boss-hall-head h2{font-size:24px}.boss-hall-tabs button{min-height:36px}.boss-hall-scene{min-height:270px}.boss-hall-art{min-height:250px}.boss-hall-art img{height:235px}.boss-hall-info{padding:13px 20px;gap:7px}.boss-hall-info h3{font-size:25px}.boss-hall-info p{line-height:1.35}}
@media(max-height:520px) and (min-width:701px){.boss-hall-scene.boss-hall-world{min-height:300px}.boss-hall-world .boss-hall-art{min-height:290px}.boss-hall-world .boss-hall-art img{height:285px}}
.boss-preview-shell{display:grid;gap:10px;padding:14px;background:#111a29}
.boss-preview-head{display:flex;align-items:center;gap:12px}.boss-preview-head>div{flex:1}.boss-preview-head small{color:#ffcb73;font-weight:800;letter-spacing:.08em}.boss-preview-head h2{margin:2px 0;color:#fff;font-size:clamp(20px,3vw,28px)}
.boss-preview-head [data-preview-back],.boss-preview-switch{min-height:42px;padding:7px 12px;border:1px solid #a6b8d1;border-radius:9px;background:#273952;color:#fff}
.boss-preview-top{display:flex;flex-wrap:wrap;gap:8px}.boss-preview-top span{padding:5px 10px;border:1px solid #739a83;border-radius:99px;background:#173a2b;color:#ddf8e5;font-size:13px;font-weight:800}.boss-preview-top span+span{border-color:#73859d;background:#25344a;color:#e7eef9}
.boss-preview-hp{display:grid;grid-template-columns:auto minmax(50px,1fr) auto auto;align-items:center;gap:10px;font-size:13px}.boss-preview-hp b{color:#ffdb9d}.boss-preview-hp>div{height:16px;border:1px solid #c89058;border-radius:99px;background:#241b20;overflow:hidden}.boss-preview-hp>div span{display:block;width:100%;height:100%;background:repeating-linear-gradient(105deg,#744b32 0 12px,#85543b 12px 24px);opacity:.55}.boss-preview-hp strong{font-variant-numeric:tabular-nums}.boss-preview-hp small{color:#b8c6d8}
.boss-preview-layout{display:grid;grid-template-columns:minmax(0,1fr) 235px;gap:10px}.boss-preview-stage{position:relative;min-height:390px;overflow:hidden;border:1px solid #9a6848;border-radius:14px;background:linear-gradient(0deg,#190c0bcc,#220b0800 35%),url('../img/world-boss/wb-01-bg.webp') center/cover;display:grid;place-items:center}.boss-preview-stage>img{width:min(62%,380px);max-height:355px;object-fit:contain;filter:drop-shadow(0 18px 15px #180806cc)}
.boss-preview-warning{position:absolute;z-index:2;top:8%;left:50%;width:max-content;max-width:90%;padding:9px 16px;border:2px solid #ffd778;border-radius:9px;background:#870e0eea;color:#fff5d8;font-size:clamp(17px,3vw,27px);font-weight:900;text-align:center;transform:translateX(-50%);opacity:0;pointer-events:none}.boss-preview-barrage{position:absolute;z-index:1;top:25%;right:0;padding:5px 12px;background:#230d0dcf;color:#ffe3a0;font-weight:800;white-space:nowrap;opacity:0;pointer-events:none}.boss-preview-floor{position:absolute;bottom:8px;left:8px;right:8px;padding:6px 10px;border-radius:8px;background:#1b1827d9;text-align:center;color:#ffe1b0;font-size:12px;font-weight:800}
.boss-preview-stage.is-opening{animation:boss-preview-shake .5s ease-in-out 2}.boss-preview-stage.is-opening .boss-preview-warning{animation:boss-preview-alert 2.2s ease-out both}.boss-preview-stage.is-opening .boss-preview-barrage{animation:boss-preview-barrage 2.2s linear both}
@keyframes boss-preview-shake{0%,100%{transform:translateX(0)}20%{transform:translateX(-5px)}40%{transform:translateX(5px)}60%{transform:translateX(-3px)}80%{transform:translateX(3px)}}@keyframes boss-preview-alert{0%,100%{opacity:0;transform:translate(-50%,-10px)}12%,82%{opacity:1;transform:translate(-50%,0)}}@keyframes boss-preview-barrage{0%{opacity:0;transform:translateX(45%)}15%,75%{opacity:1}100%{opacity:0;transform:translateX(-65%)}}
.boss-preview-side{padding:14px;border:1px solid #556d89;border-radius:12px;background:#1b2c41}.boss-preview-side h3{margin:0 0 14px;color:#ffe0a0}.boss-preview-side p{display:flex;justify-content:space-between;gap:8px;margin:0;padding:10px 0;border-bottom:1px solid #42546c;color:#e7eff9}.boss-preview-side small{display:block;margin-top:16px;color:#bbcbdf;line-height:1.5}
.boss-preview-controls{display:grid;gap:6px}.boss-preview-cta{display:grid;place-items:center;min-height:60px;border:2px solid #ffe3a0;border-radius:12px;background:linear-gradient(#df9c28,#a65216);color:#fff;text-shadow:0 1px 2px #713714}.boss-preview-cta b{font-size:22px}.boss-preview-cta small{font-weight:800}.boss-preview-disclaimer{color:#c1cede;font-size:12px;text-align:center}.boss-preview-skills{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:6px}.boss-preview-skills>span{grid-column:1/-1;color:#fff}.boss-preview-skills button{min-height:52px;padding:5px;border:1px solid #8b9fb8;border-radius:9px;background:#35465c;color:#e4eaf3;opacity:1;cursor:not-allowed}
@media(max-width:700px){.boss-preview-head{flex-wrap:wrap}.boss-preview-head>div{order:-1;flex-basis:calc(100% - 54px)}.boss-preview-head .boss-hall-close{order:-1}.boss-preview-head [data-preview-back]{flex-basis:100%}.boss-preview-hp{grid-template-columns:auto 1fr auto}.boss-preview-hp small{grid-column:1/-1}.boss-preview-layout{grid-template-columns:1fr}.boss-preview-stage{min-height:300px}.boss-preview-stage>img{max-height:270px}.boss-preview-side{display:grid;grid-template-columns:repeat(3,1fr);gap:5px}.boss-preview-side h3,.boss-preview-side small{grid-column:1/-1;margin:0}.boss-preview-side p{display:grid;font-size:11px}.boss-preview-skills{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(prefers-reduced-motion:reduce){.boss-preview-stage.is-opening,.boss-preview-stage.is-opening .boss-preview-barrage{animation:none}.boss-preview-stage.is-opening .boss-preview-warning{animation:none;opacity:1;transform:translateX(-50%)}}
.reduced-motion .boss-preview-stage.is-opening,.reduced-motion .boss-preview-stage.is-opening .boss-preview-barrage{animation:none}.reduced-motion .boss-preview-stage.is-opening .boss-preview-warning{animation:none;opacity:1;transform:translateX(-50%)}
.boss-preview-stage>.boss-preview-boss{position:relative;z-index:1}.boss-preview-actors{position:absolute;z-index:3;left:4%;bottom:30px;display:flex;align-items:flex-end;gap:4px;pointer-events:none}.boss-preview-hero{width:130px;height:160px;object-fit:contain;filter:drop-shadow(0 7px 8px #180b0b)}.boss-preview-pets{display:flex;align-items:end;gap:2px;padding-bottom:3px}.boss-preview-pets img{width:42px;height:45px;object-fit:contain;filter:drop-shadow(0 4px 5px #180b0b)}.boss-preview-pets b{max-width:100px;padding:3px 5px;border-radius:6px;background:#111b2cdb;color:#ffe0a5;font-size:10px}.boss-preview-lava{position:absolute;z-index:2;inset:auto 0 28px;height:34%;background:linear-gradient(0deg,#f44336b8,#d11b1b35 55%,transparent);opacity:0;pointer-events:none}.boss-preview-stage.is-lava-warning .boss-preview-lava{opacity:1}/* 11-08 老闆：左上角「熔岩危險區」被頭像蓋住 → 拿掉，改由整排橫幅提醒（.boss-spatial-hint） */.boss-preview-stage.is-lava-impact .boss-preview-lava{opacity:1;background:linear-gradient(0deg,#ffb232dd,#f64c1c85 65%,transparent)}.boss-preview-stage.is-shielded .boss-preview-hero{filter:drop-shadow(0 0 12px #61caff)}.boss-preview-stage.is-dodging .boss-preview-hero{opacity:.55}.boss-preview-stage.is-weakness>.boss-preview-boss{filter:drop-shadow(0 0 18px #ffe35e)}.boss-preview-stage.is-cannon:before{content:'';position:absolute;z-index:3;left:22%;bottom:40%;width:45%;height:8px;border-radius:99px;background:#ffe188;box-shadow:0 0 15px 6px #ff7b16;transform:rotate(-18deg);pointer-events:none}
.boss-preview-demo-hud{display:grid;grid-template-columns:auto minmax(80px,1fr) auto;align-items:center;gap:7px;color:#fff;font-size:13px}.boss-preview-demo-hud>span{font-weight:800}.boss-preview-demo-hp{height:12px;overflow:hidden;border:1px solid #bf8d80;border-radius:99px;background:#3d2229}.boss-preview-demo-hp span{display:block;width:100%;height:100%;background:linear-gradient(90deg,#b7383d,#f3a259)}.boss-preview-demo-hud strong{color:#ffd391}.boss-preview-demo-hud output{grid-column:1/-1;min-height:20px;color:#dceafd}.boss-preview-skills button{display:grid;align-content:center;gap:3px;cursor:pointer}.boss-preview-skills button:disabled{opacity:.62;cursor:not-allowed}.boss-preview-skills button small{color:#ffe1a3}.boss-preview-demo-actions{display:flex;gap:6px}.boss-preview-demo-actions button{min-height:42px;flex:1;padding:6px 10px;border:1px solid #99afc8;border-radius:9px;background:#263b55;color:#fff}.boss-preview-demo-actions [data-demo-hazard]{border-color:#e9b767;background:#6a3522}
@media(max-width:700px){.boss-preview-hero{width:83px;height:104px}.boss-preview-pets img{width:29px;height:34px}.boss-preview-pets b{max-width:74px;font-size:9px}.boss-preview-demo-hud{grid-template-columns:auto 1fr}.boss-preview-demo-hud strong{grid-column:1/-1}.boss-preview-demo-actions{flex-wrap:wrap}.boss-preview-demo-actions button{flex-basis:100%}}
@media(prefers-reduced-motion:reduce){.boss-preview-stage.is-lava-impact .boss-preview-lava{background:linear-gradient(0deg,#d54727bd,transparent)}}.reduced-motion .boss-preview-stage.is-lava-impact .boss-preview-lava{background:linear-gradient(0deg,#d54727bd,transparent)}
.boss-live-stage .boss-preview-warning{opacity:1;top:8px;font-size:16px;transform:translateX(-50%)}
.boss-live-rank{padding:10px;border:1px solid #627a96;border-radius:10px;background:#15253a;color:#f3f6fc}
.boss-live-rank h3{margin:0 0 6px;font-size:16px;color:#ffe0a0}.boss-live-rank ol{margin:0;padding:0;list-style:none;max-height:180px;overflow:auto}.boss-live-rank li{display:flex;justify-content:space-between;gap:14px;padding:3px 0;border-bottom:1px solid #ffffff22}.boss-live-rank p{margin:6px 0;font-size:12px;color:#d9e4f3}.boss-live-rank small{color:#ffe0a0}
.boss-preview-controls [data-live-finish],.boss-preview-controls [data-live-back]{min-height:44px;padding:8px 14px;border:1px solid #f3ca7c;border-radius:9px;background:#8b481e;color:#fff;font-weight:800}
.boss-combat-mode{display:flex;align-items:center;justify-content:space-between;gap:10px;color:#ffe5b4;font-size:13px;font-weight:700}.boss-combat-mode button,.boss-preview-demo-actions [data-demo-auto]{min-height:42px;padding:6px 12px;border:1px solid #d8b16d;border-radius:9px;background:#283d57;color:#fff;font-weight:800;cursor:pointer}.boss-combat-mode button[aria-pressed="true"],.boss-preview-demo-actions [data-demo-auto][aria-pressed="true"]{background:#9b5422;border-color:#ffd477}.boss-preview-skills button small{font-size:11px}
.boss-opening-film{position:absolute;z-index:20;inset:0;display:grid;grid-template-rows:minmax(0,1fr) auto;overflow:hidden;border-radius:21px;background:#100b0b;color:#fff}
.boss-opening-scene{position:relative;overflow:hidden;background:radial-gradient(circle at 50% 70%,#ad290e99,transparent 42%),url('../img/world-boss/wb-01-bg.webp') center/cover}
.boss-opening-scene:before{content:'';position:absolute;inset:0;background:linear-gradient(90deg,#080607c9,#270c0755,#080607c9);animation:boss-opening-pulse 3s ease-in-out infinite}
.boss-opening-core{position:absolute;left:67%;bottom:24%;width:13%;aspect-ratio:1;border-radius:50%;background:#ff5b1b;filter:blur(24px);transform:translateX(-50%) scale(var(--core-scale, .3));opacity:.7}
.boss-opening-scene .boss-opening-boss{position:absolute;z-index:1;left:67%;bottom:16%;height:75%;max-width:46%;object-fit:contain;filter:drop-shadow(0 8px 22px #ff6c22);transform:translateX(-50%) scale(var(--opening-scale, .75));transform-origin:center bottom;opacity:0;transition:opacity .5s}
.boss-opening-film[data-phase="1"] .boss-opening-boss,.boss-opening-film[data-phase="2"] .boss-opening-boss,.boss-opening-film[data-phase="3"] .boss-opening-boss{opacity:1}
.boss-opening-party{position:absolute;z-index:2;left:6%;bottom:5%;width:48%;height:39%;display:flex;align-items:flex-end;gap:3%;opacity:0;transition:opacity .5s;pointer-events:none}
.boss-opening-film[data-party-visible="true"] .boss-opening-party{opacity:1}
.boss-opening-hero{height:100%;max-width:36%;object-fit:contain;object-position:bottom;filter:drop-shadow(0 7px 8px #080505)}
.boss-opening-pets{display:flex;flex:1;align-items:flex-end;justify-content:flex-start;flex-wrap:wrap;gap:2px;max-height:75%;overflow:hidden}
.boss-opening-pets img{width:clamp(26px,4.5vw,53px);height:clamp(30px,5.5vw,62px);object-fit:contain;object-position:bottom;filter:drop-shadow(0 4px 5px #080505)}
.boss-opening-content{display:grid;justify-items:center;gap:8px;padding:12px 16px 18px;background:linear-gradient(#33120d,#170d0d);text-align:center}
.boss-opening-content strong{color:#ffd477;font-size:clamp(18px,3vw,30px)}.boss-opening-content p{min-height:1.5em;margin:0;font-size:clamp(16px,2.5vw,24px);font-weight:800}.boss-opening-content span{color:#ffe0ac;font-variant-numeric:tabular-nums}
.boss-opening-content button{min-width:130px;min-height:42px;border:1px solid #ffd477;border-radius:9px;background:#7c351d;color:#fff;font-weight:800}
@keyframes boss-opening-pulse{50%{opacity:.4}}
@media(max-width:700px){.boss-opening-scene .boss-opening-boss{left:70%;bottom:20%;height:68%;max-width:56%}.boss-opening-core{left:70%;bottom:28%}.boss-opening-party{left:2%;bottom:5%;width:61%;height:33%;gap:1%}.boss-opening-hero{max-width:35%}.boss-opening-pets{max-height:78%}.boss-opening-pets img{width:clamp(27px,7vw,39px);height:clamp(32px,8vw,45px)}}
@media(prefers-reduced-motion:reduce){.boss-opening-scene:before{animation:none}.boss-opening-boss,.boss-opening-party,.boss-opening-core{transition:none!important}}
.reduced-motion .boss-opening-scene:before{animation:none}.reduced-motion .boss-opening-boss,.reduced-motion .boss-opening-party,.reduced-motion .boss-opening-core{transition:none!important}
/* World Boss uses the dungeon battle anchors: hero 23%/18%, first pet 19%/45%, boss 61%/23%. */
.boss-opening-scene .boss-opening-boss{left:61%;bottom:20%;width:34%;height:auto;max-width:none;transform:scale(var(--opening-scale,.75));transform-origin:left bottom}
.boss-opening-core{left:77%;bottom:32%}
.boss-opening-party{inset:0;width:100%;height:100%;display:block}
.boss-opening-hero{position:absolute;z-index:2;left:23%;bottom:18%;width:22%;height:auto;max-width:none;object-fit:contain}
.boss-opening-pet{position:absolute;z-index:1;width:11%;aspect-ratio:1;animation:boss-opening-pet-idle 1.6s ease-in-out infinite;animation-delay:var(--pet-delay,0s);filter:drop-shadow(0 4px 6px #080505)}
.boss-opening-pet:first-of-type{width:15%}
.boss-opening-pet img{position:absolute;inset:0;width:100%;height:100%;object-fit:contain}
.boss-opening-pet .pet-attack{opacity:0}
.boss-opening-film[data-phase="2"] .boss-opening-pet.has-action{animation:boss-opening-pet-lunge 2.5s ease-in-out infinite;animation-delay:var(--pet-delay,0s)}
.boss-opening-film[data-phase="2"] .boss-opening-pet .pet-attack{animation:boss-opening-pet-frame 2.5s steps(1,end) infinite;animation-delay:var(--pet-delay,0s)}
@keyframes boss-opening-pet-idle{50%{transform:translateY(-7%) rotate(-2deg)}}
@keyframes boss-opening-pet-lunge{0%,48%,100%{transform:translate(0,0)}65%{transform:translate(13%,-11%)}}
@keyframes boss-opening-pet-frame{0%,55%,78%,100%{opacity:0}56%,77%{opacity:1}}
.boss-preview-stage>.boss-preview-boss{position:absolute;left:61%;bottom:20%;width:34%;height:auto;max-height:70%;object-fit:contain}
.boss-preview-actors{inset:0;display:block}
.boss-preview-hero{position:absolute;left:23%;bottom:18%;width:22%;height:auto}
.boss-preview-pets{position:absolute;left:19%;bottom:25%;width:42%;height:auto;display:flex;align-items:end;gap:2%}
.boss-preview-pets img{width:23%;height:auto;aspect-ratio:1;animation:boss-opening-pet-idle 1.6s ease-in-out infinite}
.boss-preview-pets img:nth-child(2){animation-delay:-.45s}.boss-preview-pets img:nth-child(3){animation-delay:-.9s}
.boss-live-stage .boss-preview-pets span{position:relative;display:block;width:23%}
.boss-live-stage .boss-preview-pets span img{width:100%}
.boss-live-stage .boss-preview-pets span small{position:absolute;left:0;right:0;bottom:-17px;text-align:center;color:#fff;background:#11253fdc;border-radius:6px;font-size:10px;white-space:nowrap}
.boss-live-stage .boss-preview-pets span.is-down img{filter:grayscale(1);opacity:.48;animation:none}
.boss-live-stage .boss-preview-pets span[hidden]{display:none}
.boss-rank-tabs{display:flex;gap:5px;margin:6px 0}.boss-rank-tabs button{flex:1;min-height:32px;border:1px solid #d6ae64;border-radius:8px;background:#1b314b;color:#f8e9c8;font-weight:800}.boss-rank-tabs button[aria-pressed="true"]{background:#e6b957;color:#18233b}.boss-auction-entry{display:flex;align-items:center;gap:8px;width:100%;min-height:39px;margin-top:7px;padding:5px 9px;border:1px solid #b89c69;border-radius:9px;background:#273747;color:#fff4d3;font-weight:800}.boss-auction-entry img{width:28px;height:28px}.boss-auction-entry:disabled{opacity:.7;cursor:not-allowed}
@media(max-width:700px){.boss-opening-scene .boss-opening-boss{left:61%;bottom:20%;width:34%;height:auto;max-width:none}.boss-opening-party{inset:0;width:100%;height:100%}.boss-opening-hero{left:23%;bottom:18%;width:22%;height:auto;max-width:none}.boss-preview-hero{width:22%;height:auto}.boss-preview-pets img{width:23%;height:auto}}
@media(prefers-reduced-motion:reduce){.boss-opening-pet,.boss-opening-film[data-phase="2"] .boss-opening-pet.has-action,.boss-opening-film[data-phase="2"] .boss-opening-pet .pet-attack,.boss-preview-pets img{animation:none!important}.boss-opening-pet .pet-attack{opacity:0!important}}
.reduced-motion .boss-opening-pet,.reduced-motion .boss-opening-film[data-phase="2"] .boss-opening-pet.has-action,.reduced-motion .boss-opening-film[data-phase="2"] .boss-opening-pet .pet-attack,.reduced-motion .boss-preview-pets img{animation:none!important}

.boss-preview-skills{grid-template-columns:repeat(4,minmax(0,1fr))}.boss-loadout{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;margin:8px 0;color:#ffe5b4}.boss-loadout>strong{grid-column:1/-1}.boss-loadout label{display:grid;gap:3px;font-weight:700}.boss-loadout select{min-width:0;width:100%;min-height:44px;border:1px solid #d8b16d;border-radius:8px;background:#283d57;color:#fff;padding:5px}@media(max-width:700px){.boss-preview-skills,.boss-loadout{grid-template-columns:repeat(2,minmax(0,1fr))}}

/* Dungeon-style combat HUD: player skills stay inside the arena. */
.boss-preview-stage:has(>.boss-preview-skills){min-height:440px;align-content:center}
.boss-preview-stage>.boss-preview-demo-hud{position:absolute;z-index:5;top:10px;left:10px;right:10px;display:grid;grid-template-columns:auto 1fr auto;padding:7px 9px;border-radius:10px;background:#172438df}
.boss-preview-stage>[data-demo-auto]{position:absolute;z-index:6;right:10px;bottom:112px;min-height:38px;padding:5px 10px;border:1px solid #d8b16d;border-radius:8px;background:#283d57;color:#fff;font-weight:800}
.boss-preview-stage>.boss-combat-mode{position:absolute;z-index:6;left:10px;right:10px;bottom:112px;padding:5px 9px;border-radius:9px;background:#172438e8}
.boss-preview-stage>.boss-preview-skills{position:absolute;z-index:6;left:10px;right:10px;bottom:10px;padding:7px;border:1px solid #b8d6e6;border-radius:12px;background:#f0f9ffeb}
.boss-preview-stage>.boss-preview-skills button{min-height:56px;background:linear-gradient(#fff8cf,#ffd66a);border-color:#d9ad44;color:#26425a;font-weight:800}
.boss-preview-skills button b:has(>.ability-icon){display:flex;align-items:center;justify-content:center;gap:6px}
.boss-preview-skills .ability-icon{width:32px;height:32px;flex:none;object-fit:contain}
.boss-preview-stage>.boss-preview-skills button small{color:#5d4a29}
.boss-preview-stage:has(>.boss-preview-skills) .boss-preview-actors{bottom:115px}
.boss-preview-stage:has(>.boss-preview-skills)>.boss-preview-boss{bottom:27%;max-height:55%}
.boss-preview-stage:has(>.boss-preview-skills) .boss-preview-floor{bottom:167px}
@media(max-width:700px){.boss-preview-stage:has(>.boss-preview-skills){min-height:440px}.boss-preview-stage>.boss-preview-skills{grid-template-columns:repeat(2,minmax(0,1fr))}.boss-preview-stage>.boss-combat-mode{bottom:137px;font-size:11px}.boss-preview-stage>[data-demo-auto]{bottom:137px}.boss-preview-stage:has(>.boss-preview-skills) .boss-preview-actors{bottom:180px}.boss-preview-stage:has(>.boss-preview-skills)>.boss-preview-boss{bottom:42%;max-height:42%}.boss-preview-stage:has(>.boss-preview-skills) .boss-preview-floor{bottom:198px}}
/* Confirmed waiting-gauge dungeon battle: preview only. */
html body dialog.boss-hall.boss-atb-preview{width:min(1220px,calc(100vw - 12px))}
.boss-atb-preview .boss-preview-layout{grid-template-columns:1fr}
.boss-atb-preview .boss-preview-side{display:flex;align-items:center;gap:12px;padding:7px 12px}
.boss-atb-preview .boss-preview-side h3{margin:0;font-size:14px}
.boss-atb-preview .boss-preview-side p{padding:0;border:0;font-size:12px}
.boss-atb-preview .boss-preview-side small{margin:0}
.boss-atb-preview .boss-preview-controls{display:none}
.boss-atb-preview .boss-preview-stage.boss-atb-stage{min-height:620px;display:block;isolation:isolate;border:2px solid #b9ddeb;background-position:center;background-size:cover}
.boss-atb-stage>.boss-preview-boss{left:67%;bottom:16%;width:28%;max-height:54%;z-index:2;cursor:pointer}
.boss-atb-stage.is-atb-targeting>.boss-preview-boss,.boss-atb-stage.is-atb-targeting .boss-atb-enemy{filter:drop-shadow(0 0 11px #ffe464);outline:3px solid #ffd24a}
.boss-atb-stage>.boss-preview-floor{display:none}
.boss-atb-ui{position:absolute;z-index:5;inset:0;pointer-events:none;font-family:system-ui,sans-serif}
.boss-atb-ui button{pointer-events:auto}
.boss-atb-party{position:absolute;top:12px;left:12px;width:min(310px,35%);display:grid;gap:7px;z-index:7}
.boss-atb-card,.boss-atb-enemy{display:flex;align-items:center;gap:9px;text-align:left;padding:6px;border:2px solid #e6bd5f;border-radius:16px;background:linear-gradient(#e8f5ff 0 28%,#fffdf4 29%);color:#174560;box-shadow:0 3px 9px #142f4233}
.boss-atb-card{width:100%;min-height:60px}
.boss-atb-pet-row{display:grid;grid-template-columns:minmax(0,1fr) auto 24px;align-items:center;gap:5px;width:100%;min-height:26px;padding:3px 6px;border:1px solid #afd9eb;border-radius:8px;background:#edf9ffe8;color:#174560;text-align:left;font-size:10px}.boss-atb-pet-row b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.boss-atb-pet-row span{white-space:nowrap}.boss-atb-pet-row.is-ready{outline:2px solid #64ecff}.boss-atb-pet-gauge{width:24px;height:5px;border-radius:8px;background:linear-gradient(90deg,#00c9f4 var(--atb-gauge),#496276 var(--atb-gauge))}
.boss-atb-card.is-ready,.boss-atb-enemy:focus-visible{box-shadow:0 0 0 3px #64ecff,0 0 17px #00cfff}
.boss-atb-portrait{--atb-gauge:0deg;position:relative;flex:0 0 47px;width:47px;height:47px;border-radius:50%;padding:4px;background:conic-gradient(from -90deg,#00c9f4 var(--atb-gauge),#496276 var(--atb-gauge));box-shadow:0 0 0 2px #e9c86b}
.boss-atb-portrait img{width:100%;height:100%;object-fit:contain;border-radius:50%;background:#fdf6dd}
.boss-atb-card-info{flex:1;min-width:0;display:grid;gap:2px}.boss-atb-card-info b,.boss-atb-enemy b{font-size:13px}.boss-atb-card-info small,.boss-atb-enemy small{font-size:10px}
.boss-atb-hp,.boss-atb-mp{height:8px;border-radius:9px;background:#d9e4eb;overflow:hidden}.boss-atb-hp em,.boss-atb-mp em{display:block;height:100%;background:linear-gradient(#ff7873,#e63732)}.boss-atb-mp em{background:linear-gradient(#45caff,#147fc6)}
.boss-atb-enemy{position:absolute;z-index:7;top:12px;right:12px;width:min(175px,24%);min-height:60px;display:grid;grid-template-columns:47px 1fr;gap:4px 8px}.boss-atb-enemy .boss-atb-portrait{grid-row:1/4}.boss-atb-enemy>span:last-child{min-width:0;display:grid;gap:3px}
.boss-atb-actors{position:absolute;inset:0;z-index:4}.boss-atb-figure{position:absolute;border:0;background:none;padding:0;cursor:pointer}.boss-atb-figure img{width:100%;height:100%;object-fit:contain;filter:drop-shadow(0 8px 5px #120c0baa)}.boss-atb-figure.is-hero{left:28%;bottom:15%;width:19%;height:38%}.boss-atb-figure.is-pet{left:calc(7% + (var(--atb-index) - 1)*9%);bottom:calc(18% + (var(--atb-index) - 1)*6%);width:13%;height:23%}.boss-atb-figure.is-down{filter:grayscale(1);opacity:.4}.boss-atb-figure:focus-visible{outline:3px solid #64ecff;border-radius:12px}
.boss-atb-wheel{position:absolute;z-index:12;left:16%;bottom:19%;width:270px;height:270px;pointer-events:auto}.boss-atb-wheel[hidden]{display:none}
.boss-atb-wheel-face{position:relative;width:100%;height:100%;border-radius:50%;background:radial-gradient(circle,#13384b 0 27%,#72ecff 28% 29%,#0a608c 30% 34%,#e7c266 35% 37%,#31414d 38% 43%,#54dfff 44% 45%,transparent 47%)}
.boss-atb-wheel-face>button{position:absolute;width:100px;height:100px;display:grid;place-content:center;gap:1px;border-radius:50%;border:6px solid #f3c65b;color:#fff;text-shadow:0 2px 2px #000;font-size:24px;font-weight:900;box-shadow:inset 0 0 0 3px #fff2a5,inset 0 0 15px #0009,0 3px 5px #17334088}.boss-atb-wheel-face>button span{font-size:16px}.boss-atb-wheel-face .is-attack{top:0;left:85px;background:radial-gradient(circle at 35% 25%,#ffdc72,#f32b0a 45%,#8e0906 85%)}.boss-atb-wheel-face .is-items{top:85px;left:0;background:radial-gradient(circle at 35% 25%,#cfff8e,#31ce10 45%,#076211 85%)}.boss-atb-wheel-face .is-defend{top:85px;right:0;background:radial-gradient(circle at 35% 25%,#fff7b0,#ffbb09 45%,#a96500 85%)}.boss-atb-wheel-face .is-skills{bottom:0;left:85px;background:radial-gradient(circle at 35% 25%,#9effff,#00a2ed 45%,#093eae 85%)}
.boss-atb-mode{position:absolute;left:91px;top:98px;width:88px;height:76px;display:grid;overflow:hidden;border:4px solid #e9bd60;border-radius:50%;background:#223648;z-index:3}.boss-atb-mode button{border:0;background:#354252;color:#e5eef6;font-size:11px}.boss-atb-mode button[aria-pressed=true]{background:linear-gradient(#53eaff,#007ec5);color:#fff}
.boss-atb-submenu{display:grid;gap:5px;width:210px;padding:10px;border:2px solid #e9bd60;border-radius:13px;background:#f6fcff;color:#174560;box-shadow:0 5px 16px #112b4288}.boss-atb-submenu button{min-height:34px;border:1px solid #dcb952;border-radius:8px;background:linear-gradient(#fff2a9,#ffdc65);color:#254664}.boss-atb-submenu button:disabled{opacity:.5}
.boss-atb-prompt{position:absolute;left:50%;bottom:7px;transform:translateX(-50%);min-width:40%;max-width:80%;margin:0;padding:5px 10px;border-radius:8px;background:#f3fbffec;color:#174867;font-size:12px;font-weight:800;text-align:center}.boss-atb-tip{position:absolute;top:10px;left:50%;transform:translateX(-50%);margin:0;padding:4px 8px;border-radius:7px;background:#173c58cc;color:#fff;font-size:11px}
.boss-atb-stage[data-atb-move=hero] .boss-atb-figure.is-hero,.boss-atb-stage[data-atb-move=pet] .boss-atb-figure.is-pet:first-of-type{animation:boss-atb-lunge .65s ease-in-out}.boss-atb-stage[data-atb-move=boss]>.boss-preview-boss{animation:boss-atb-boss-lunge .65s ease-in-out}@keyframes boss-atb-lunge{40%{transform:translateX(55%) scale(1.08)}}@keyframes boss-atb-boss-lunge{40%{transform:translateX(-25%) scale(1.04)}}
@media(max-width:700px){.boss-atb-preview .boss-preview-side{display:block}.boss-atb-preview .boss-preview-side small{display:none}.boss-atb-preview .boss-preview-stage.boss-atb-stage{min-height:600px}.boss-atb-party{top:7px;left:7px;width:43%;gap:4px}.boss-atb-card{min-height:44px;padding:3px;gap:4px}.boss-atb-portrait{flex-basis:32px;width:32px;height:32px;padding:2px}.boss-atb-card-info b{font-size:10px}.boss-atb-card-info small{font-size:8px}.boss-atb-enemy{top:7px;right:7px;width:34%;grid-template-columns:32px 1fr;min-height:44px;padding:3px}.boss-atb-enemy .boss-atb-portrait{width:32px;height:32px}.boss-atb-enemy b{font-size:10px}.boss-atb-enemy small{font-size:8px}.boss-atb-stage>.boss-preview-boss{left:66%;bottom:24%;width:30%;max-height:37%}.boss-atb-figure.is-hero{left:26%;bottom:20%;width:27%;height:32%}.boss-atb-figure.is-pet{left:calc(3% + (var(--atb-index) - 1)*7%);bottom:calc(25% + (var(--atb-index) - 1)*5%);width:17%;height:18%}.boss-atb-wheel{left:3%;bottom:19%;transform:scale(.68);transform-origin:bottom left}.boss-atb-prompt{min-width:75%;max-width:95%;font-size:10px}.boss-atb-tip{top:172px;font-size:9px}}
@media(max-width:700px){.boss-atb-party{width:52%;max-height:145px;overflow:auto}.boss-atb-pet-row{font-size:8px;grid-template-columns:minmax(0,1fr) auto 18px;min-height:21px}.boss-atb-pet-gauge{width:18px}.boss-atb-enemy{width:34%}}
@media(prefers-reduced-motion:reduce){.boss-atb-stage[data-atb-move] .boss-atb-figure,.boss-atb-stage[data-atb-move]>.boss-preview-boss{animation:none}}
.boss-raid-stage>.boss-preview-boss{left:50%;bottom:24%;transform:translateX(-50%);width:38%;max-height:58%;z-index:3}.boss-raid-stage .boss-atb-actors{z-index:4;pointer-events:none}.boss-raid-stage .boss-atb-figure.is-hero{left:14%;bottom:23%;width:17%;height:31%}.boss-raid-stage .boss-atb-figure.is-pet{left:calc(4% + (var(--atb-index) - 1)*10%);bottom:calc(17% - (var(--atb-index) - 1)*3%);width:11%;height:17%}.boss-raid-stage .boss-atb-enemy{left:50%;right:auto;transform:translateX(-50%);width:175px}.boss-raid-stage .boss-atb-party{width:min(265px,30%)}.boss-raid-stage .boss-atb-pet-row{grid-template-columns:minmax(0,1fr) auto}.boss-raid-actions{position:absolute;z-index:10;right:12px;bottom:50px;display:grid;justify-items:end;gap:5px}.boss-raid-actions>button,.boss-raid-skill-list button{min-height:44px;padding:7px 14px;border:2px solid #e9bd60;border-radius:10px;background:linear-gradient(#fff2a9,#ffdc65);color:#254664;font-weight:800}.boss-raid-skill-list{display:grid;gap:4px;padding:7px;border-radius:12px;background:#effaffec}.boss-raid-skill-list[hidden]{display:none}.boss-raid-skill-list button:disabled{opacity:.55}.boss-raid-stage .boss-atb-tip{top:auto;bottom:10px;left:10px;transform:none}.boss-raid-stage .boss-atb-prompt{bottom:10px;max-width:38%}
@media(max-width:700px){.boss-raid-stage>.boss-preview-boss{left:52%;bottom:27%;width:47%;max-height:48%}.boss-raid-stage .boss-atb-enemy{left:66%;right:auto;width:32%}.boss-raid-stage .boss-atb-party{width:44%;max-height:145px}.boss-raid-stage .boss-atb-figure.is-hero{left:11%;bottom:26%;width:24%;height:29%}.boss-raid-stage .boss-atb-figure.is-pet{left:calc(1% + (var(--atb-index) - 1)*7%);bottom:calc(17% - (var(--atb-index) - 1)*2%);width:15%;height:16%}.boss-raid-actions{right:6px;bottom:48px}.boss-raid-skill-list{max-width:175px}.boss-raid-stage .boss-atb-prompt{bottom:5px;left:50%;max-width:65%;min-width:45%}.boss-raid-stage .boss-atb-tip{font-size:8px;bottom:40px}}
.boss-raid-stage .boss-atb-party{max-height:none;overflow:visible}.boss-raid-stage .boss-atb-pet-row{min-width:0;width:100%;overflow:hidden}.boss-raid-stage .boss-atb-pet-row span{overflow:hidden;text-overflow:ellipsis}
.boss-atb-preview .boss-preview-stage.boss-raid-stage{min-height:720px}.boss-raid-pet-portraits{display:flex;flex-wrap:wrap;gap:5px;max-width:100%;padding:2px 3px}.boss-raid-pet-portrait{position:relative;display:block;flex:0 0 39px;width:39px;height:39px;padding:3px;border:2px solid #e6bd5f;border-radius:50%;background:#e8f5ff;box-shadow:0 2px 5px #142f4277}.boss-raid-pet-portrait img{width:100%;height:100%;object-fit:contain}.boss-raid-pet-portrait small{position:absolute;right:-3px;bottom:-3px;padding:0 3px;border-radius:5px;background:#174560;color:white;font-size:9px}.boss-raid-pet-portrait.is-down{filter:grayscale(1);opacity:.55}
@media(max-width:700px){.boss-atb-preview .boss-preview-stage.boss-raid-stage{min-height:690px}.boss-raid-pet-portrait{flex-basis:30px;width:30px;height:30px;padding:2px}.boss-raid-pet-portrait small{font-size:8px}.boss-raid-stage>.boss-preview-boss{bottom:30%;max-height:46%}.boss-raid-stage .boss-atb-figure.is-hero{bottom:31%}.boss-raid-stage .boss-atb-figure.is-pet{bottom:calc(28% - (var(--atb-index) - 1)*2%)}}
.boss-preview-stage.boss-public-stage{min-height:570px;background-position:center 45%;perspective:850px;isolation:isolate}.boss-public-stage>.boss-preview-boss{left:50%;bottom:30%;width:34%;max-height:51%;transform:translateX(-50%);z-index:4}.boss-public-ground{position:absolute;z-index:2;left:-16%;right:-16%;bottom:-16%;height:49%;border-radius:50%;background:radial-gradient(ellipse at 50% 25%,#ff9b3c30 0 4%,transparent 48%),repeating-linear-gradient(90deg,transparent 0 11%,#f5a84c29 11.2% 11.5%,transparent 11.8% 22%),repeating-linear-gradient(0deg,transparent 0 14%,#f5a84c27 14.2% 14.5%,transparent 14.8% 28%);transform:rotateX(57deg);transform-origin:center bottom;box-shadow:inset 0 45px 55px #1b080500;pointer-events:none}.boss-public-party{position:absolute;z-index:6;left:8%;bottom:18%;width:23%;height:33%;pointer-events:none}.boss-public-player{position:absolute;left:20%;bottom:4%;width:54%;height:90%;animation:boss-public-idle 2.6s ease-in-out infinite}.boss-public-player:after,.boss-public-pet:after{content:'';position:absolute;left:10%;right:10%;bottom:-2%;height:9%;border-radius:50%;background:#130a0aba;filter:blur(4px)}.boss-public-player img{width:100%;height:100%;object-fit:contain;filter:drop-shadow(0 10px 4px #130802b0)}.boss-public-player span{position:absolute;top:-12px;left:50%;transform:translateX(-50%);white-space:nowrap;padding:2px 6px;border-radius:6px;background:#14233bcf;color:#fff6dc;font-size:10px}.boss-public-pet{position:absolute;bottom:0;width:28%;height:43%;object-fit:contain;filter:drop-shadow(0 7px 4px #130802a0);animation:boss-public-idle 2.4s ease-in-out infinite alternate}.boss-public-pet-1{left:-13%;bottom:2%;animation-delay:-.4s}.boss-public-pet-2{left:69%;bottom:3%;animation-delay:-1s}.boss-public-pet-3{left:42%;bottom:-12%;animation-delay:-1.5s}.boss-public-crowd{position:absolute;z-index:3;right:8%;bottom:26%;width:25%;height:30%;pointer-events:none}.boss-public-crowd i{position:absolute;bottom:0;width:17%;height:34%;border-radius:48% 48% 15% 15%;background:linear-gradient(#506071,#253048);box-shadow:0 7px 8px #0c0809b8;opacity:.65;animation:boss-public-idle 3s ease-in-out infinite}.boss-public-crowd i:before{content:'';position:absolute;left:18%;top:-23%;width:64%;height:33%;border-radius:50%;background:#8e7662}.boss-public-crowd i:nth-child(1){left:12%;transform:scale(.85);animation-delay:-1s}.boss-public-crowd i:nth-child(2){left:47%;bottom:7%;transform:scale(.7);animation-delay:-1.7s}.boss-public-crowd i:nth-child(3){left:78%;transform:scale(.9)}.boss-public-depth-note{position:absolute;z-index:7;left:8px;top:8px;padding:4px 7px;border-radius:6px;background:#172438cf;color:#fff0d5;font-size:10px}.boss-public-stage .boss-preview-floor{z-index:8}@keyframes boss-public-idle{50%{translate:0 -5px}}
@media(max-width:700px){.boss-preview-stage.boss-public-stage{min-height:530px}.boss-public-stage>.boss-preview-boss{bottom:31%;width:48%;max-height:45%}.boss-public-party{left:1%;bottom:19%;width:38%;height:29%}.boss-public-crowd{right:1%;bottom:23%;width:25%;height:25%}.boss-public-depth-note{font-size:8px;max-width:62%}}
@media(prefers-reduced-motion:reduce){.boss-public-player,.boss-public-pet,.boss-public-crowd i{animation:none}}
.boss-public-visitors{position:absolute;inset:0;z-index:5;pointer-events:none}.boss-public-visitor{position:absolute;left:var(--visitor-x);bottom:var(--visitor-y);width:var(--visitor-size,9%);height:22%;object-fit:contain;object-position:bottom;filter:drop-shadow(0 6px 4px #150902b9);animation:boss-public-idle 2.7s ease-in-out infinite;animation-delay:var(--visitor-delay,0s)}.boss-public-visitor-1{--visitor-x:16%;--visitor-y:39%;--visitor-size:8%;--visitor-delay:-.4s;z-index:1}.boss-public-visitor-2{--visitor-x:31%;--visitor-y:43%;--visitor-size:7%;--visitor-delay:-1.2s;z-index:1}.boss-public-visitor-3{--visitor-x:69%;--visitor-y:44%;--visitor-size:7%;--visitor-delay:-.8s;z-index:1}.boss-public-visitor-4{--visitor-x:82%;--visitor-y:39%;--visitor-size:8%;--visitor-delay:-1.5s;z-index:1}.boss-public-visitor-5{--visitor-x:6%;--visitor-y:30%;--visitor-size:9%;--visitor-delay:-2s;z-index:2}.boss-public-visitor-6{--visitor-x:88%;--visitor-y:28%;--visitor-size:9%;--visitor-delay:-.2s;z-index:2}.boss-public-visitor-7{--visitor-x:32%;--visitor-y:16%;--visitor-size:10%;--visitor-delay:-1.8s;z-index:6}.boss-public-visitor-8{--visitor-x:71%;--visitor-y:15%;--visitor-size:10%;--visitor-delay:-.6s;z-index:6}.boss-public-visitor-9{--visitor-x:88%;--visitor-y:12%;--visitor-size:11%;--visitor-delay:-1.1s;z-index:6}
.boss-public-party{z-index:7}.boss-public-stage>.boss-preview-boss{z-index:4}.boss-public-stage .boss-public-visitors{z-index:5}.boss-public-stage .boss-public-visitor:nth-child(-n+4){filter:brightness(.72) drop-shadow(0 4px 3px #150902aa)}
@media(max-width:700px){.boss-public-visitor{height:18%;width:var(--visitor-size,9%)}.boss-public-visitor-7{--visitor-x:34%}.boss-public-visitor-8{--visitor-x:68%}.boss-public-visitor-9{--visitor-x:86%}.boss-public-depth-note{max-width:78%}}
@media(prefers-reduced-motion:reduce){.boss-public-visitor{animation:none}}
.boss-public-stage .boss-public-visitors{display:contents}.boss-public-stage .boss-public-visitor:nth-child(-n+6){z-index:3}.boss-public-stage .boss-public-visitor:nth-child(n+7){z-index:6}
.boss-public-visitor[hidden]{display:none!important}.boss-public-visitor-player{display:block;width:100%;height:100%;object-fit:contain;object-position:bottom}.boss-public-visitor-pet{position:absolute;right:-20%;bottom:0;width:47%;height:38%;object-fit:contain;filter:drop-shadow(0 3px 2px #160802a8)}.boss-public-stage.hide-other-pets .boss-public-visitor-pet{display:none}.boss-public-settings{position:absolute;z-index:12;top:7px;right:7px;width:min(225px,48%);color:#203a50;font-size:12px}.boss-public-settings summary{display:block;float:right;min-height:32px;padding:6px 9px;border:1px solid #ffe0a3;border-radius:8px;background:#283a4ded;color:#fff4d8;font-weight:800;cursor:pointer;list-style:none}.boss-public-settings summary::-webkit-details-marker{display:none}.boss-public-settings[open] summary{float:none;text-align:center}.boss-public-settings>div{clear:both;display:grid;gap:8px;margin-top:5px;padding:10px;border:1px solid #e9bd60;border-radius:9px;background:#f5fbffed;box-shadow:0 8px 18px #15100e88}.boss-public-settings label{display:flex;align-items:center;justify-content:space-between;gap:5px}.boss-public-settings input{width:18px;height:18px;flex:none}.boss-public-settings select{min-height:32px;padding:3px 5px;border:1px solid #9bafc3;border-radius:6px;background:#fff;color:#203a50}.boss-public-settings small{color:#426077}.boss-public-depth-note{top:47px}
.boss-public-stage.is-raid-active .boss-public-visitor{animation:boss-public-assault 2.4s ease-in-out infinite;animation-delay:var(--visitor-delay,0s)}.boss-public-stage.is-raid-active .boss-public-player{animation:boss-public-assault 2.2s ease-in-out infinite}.boss-public-stage.is-raid-active .boss-public-pet{animation:boss-public-assault 2s ease-in-out infinite}.boss-public-stage.is-raid-active>.boss-preview-boss{animation:boss-public-boss-hit 2.4s ease-in-out infinite}.boss-public-stage.is-raid-active .boss-public-ground:after{content:'';position:absolute;left:47%;top:16%;width:6%;height:20%;border-radius:50%;background:#ffdc78aa;filter:blur(15px);animation:boss-public-flash 1.2s ease-out infinite}@keyframes boss-public-assault{0%,100%{transform:translate(0,0) scale(1)}35%{transform:translate(7px,-6px) scale(1.06)}60%{transform:translate(0,0) scale(1)}}@keyframes boss-public-boss-hit{0%,55%,100%{transform:translateX(-50%);filter:drop-shadow(0 18px 15px #180806cc)}62%{transform:translateX(-50%) scale(1.025);filter:brightness(1.4) drop-shadow(0 0 18px #ffb129)}}@keyframes boss-public-flash{0%,100%{opacity:0}35%{opacity:.85}}
.boss-raid-effects{position:absolute;inset:0;z-index:7;pointer-events:none}.boss-raid-effect{position:absolute;left:49%;top:52%;width:10%;aspect-ratio:1;border-radius:50%;border:4px solid #ffd46b;box-shadow:0 0 18px #ff8a20;animation:boss-raid-burst .55s ease-out forwards}.boss-raid-effect.is-pet-skill{border-color:#5beeff;box-shadow:0 0 22px #02aeff}.boss-raid-effect.is-hero-skill{border-color:#fff495;box-shadow:0 0 25px #ffed54}.boss-raid-effect.is-heal,.boss-raid-effect.is-guard{left:19%;top:60%;border-color:#78f7c0;box-shadow:0 0 23px #36d798}.boss-raid-effect.is-boss-hit{left:25%;top:65%;border-color:#f25d3f;box-shadow:0 0 22px #f32a12}@keyframes boss-raid-burst{0%{opacity:0;transform:scale(.2)}25%{opacity:1}100%{opacity:0;transform:scale(2)}}
@media(prefers-reduced-motion:reduce){.boss-public-stage.is-raid-active .boss-public-visitor,.boss-public-stage.is-raid-active .boss-public-player,.boss-public-stage.is-raid-active .boss-public-pet,.boss-public-stage.is-raid-active>.boss-preview-boss,.boss-public-stage.is-raid-active .boss-public-ground:after,.boss-raid-effect{animation:none}}
/* 10-28 正式戰鬥：攻擊數字＋普攻／寵物／技能動作 */
.boss-live-stage .boss-live-num{position:absolute;z-index:9;left:calc(55% + var(--dx,0%));top:28%;font-weight:900;font-size:22px;color:#fff3c4;text-shadow:0 2px 0 #7a2b00,0 0 8px #ff8a1c;pointer-events:none;white-space:nowrap;animation:boss-live-num 1.1s ease-out forwards}
.boss-live-stage .boss-live-num.is-pets{font-size:17px;color:#bff4ff;text-shadow:0 2px 0 #12476b,0 0 7px #35b6ff}
.boss-live-stage .boss-live-num.is-cannon{font-size:30px;color:#ffe35e}
.boss-live-stage .boss-live-num.is-skill{left:12%;top:38%;font-size:18px;color:#fff;background:#d98a00;padding:3px 9px;border-radius:8px;text-shadow:none}
.boss-live-stage .boss-live-num.is-hurt{left:calc(14% + var(--dx,0%));top:46%;color:#ff6a5c;text-shadow:0 2px 0 #4a0000}
@keyframes boss-live-num{0%{opacity:0;transform:translateY(10px) scale(.7)}15%{opacity:1;transform:translateY(0) scale(1.15)}100%{opacity:0;transform:translateY(-46px) scale(1)}}
.boss-live-stage.is-hero-attack .boss-preview-hero{animation:boss-atb-lunge .6s ease-in-out}
.boss-live-stage.is-pet-attack .boss-preview-pets img{animation:boss-atb-lunge .6s ease-in-out}
.boss-live-stage.is-boss-hurt>.boss-preview-boss{filter:brightness(1.5) drop-shadow(0 0 14px #ffb129)}
.boss-live-stage.is-boss-attack>.boss-preview-boss{animation:boss-atb-boss-lunge .6s ease-in-out}
.boss-live-stage.is-hero-hurt .boss-preview-hero{filter:brightness(1.6) sepia(1) hue-rotate(-40deg) saturate(4)}
.boss-live-stage.is-repair .boss-preview-hero{filter:drop-shadow(0 0 14px #5dff8a)}

/* 3D 疊層：載入成功才加 is-3d，2D 圖藏起來；失敗就維持 2D */
.boss-3d-canvas{position:absolute;inset:0;width:100%;height:100%;z-index:2;pointer-events:none}.boss-live-stage.is-3d>.boss-preview-boss,.boss-live-stage.is-3d .boss-preview-hero{visibility:hidden}
/* 10-28 老闆「前面30秒畫面太大、不需要顯示技能」：開場動畫固定蓋住整個視窗（下面技能配置不露出），角色與寵物縮小 */
dialog:has(.boss-opening-film){overflow:hidden}
dialog:has(.boss-opening-film) .boss-loadout{visibility:hidden}
.boss-opening-film{position:fixed;inset:0;border-radius:0}
.boss-opening-scene .boss-opening-boss{width:26%}
.boss-opening-hero{width:15%;left:26%}
.boss-opening-pet{width:8%}.boss-opening-pet:first-of-type{width:11%}
/* 10-28 老闆：選擇四格技能拿掉（沿用預設四招） */
.boss-loadout{display:none!important}
/* 10-28 老闆：淺底上左上標題要深字 */
.boss-hall-head small{color:#9a4b00!important}.boss-hall-head h2{color:#1d2b3a!important}
/* 10-28 老闆截圖：3D 模式寵物疊在玩家身上，寵物移到左側 */
.boss-live-stage.is-3d .boss-preview-pets{left:1%!important;width:20%!important;top:92px!important;bottom:auto!important}
/* 10-28 老闆：寵物擋住3D玩家——移到左上HP下方、縮小 */
/* 10-28 老闆：排名（姓名＋輸出量）疊在戰鬥畫面右上角，淺底深字 */
.boss-live-stage>.boss-stage-rank{position:absolute;z-index:7;top:10px;right:10px;width:min(230px,40%)}
.boss-stage-rank .boss-live-rank{padding:6px 9px;border:1px solid #f0c060;background:#fffaf0ee;color:#2a1d10}
.boss-stage-rank .boss-live-rank h3{font-size:13px;margin:0 0 3px;color:#8a4b00}
.boss-stage-rank .boss-live-rank ol{max-height:none;overflow:visible}
.boss-stage-rank .boss-live-rank li{font-size:12px;padding:1px 0;border-bottom-color:#00000014}
/* 11-08 老闆「個人排名只看見第一名，至少要前10名」：原本只顯示前 5 名 → 改 10 名，列高壓小不必捲動 */
.boss-stage-rank .boss-live-rank li:nth-child(n+11){display:none}
.boss-stage-rank .boss-live-rank small{font-size:11px;color:#8a4b00}
.boss-stage-rank .boss-live-rank>:not(h3):not(ol):not(small):not(p):not(.boss-rank-tabs):not([data-boss-reward-claim]):not(.boss-board-open){display:none}
.boss-stage-rank .boss-rank-tabs{margin:3px 0;pointer-events:auto}.boss-stage-rank .boss-rank-tabs button{min-height:26px;font-size:12px;pointer-events:auto}
/* 10-28 老闆：左上角 HP／MP，下方位子空出來 */
.boss-live-stage>.boss-stage-vitals{position:absolute;z-index:7;top:10px;left:10px;width:min(230px,40%);display:grid;gap:4px;padding:6px 9px;border:1px solid #f0c060;border-radius:9px;background:#fffaf0ee;color:#2a1d10;font-size:12px}
.boss-stage-vitals p{display:grid;grid-template-columns:24px 1fr auto;align-items:center;gap:6px;margin:0}
.boss-stage-vitals b{color:#b3261e}.boss-stage-vitals p+p b{color:#1f5fbf}
.boss-stage-vitals i{height:8px;border-radius:5px;background:#00000018;overflow:hidden}.boss-stage-vitals em{display:block;height:100%;background:#e0443a;transition:width .3s}.boss-stage-vitals .is-mp em{background:#3b82f6}
.boss-stage-vitals>.boss-combat-mode{position:static;padding:0;background:none;color:#2a1d10}.boss-stage-vitals>.boss-combat-mode>span{display:none}.boss-stage-vitals>.boss-combat-mode button{min-height:30px;padding:3px 10px;font-size:12px}
.boss-live-clean .boss-preview-controls>p{display:none}
/* 10-28 老闆：寵物改成小頭像，排在左上 HP／MP 框下方 */
.boss-live-stage.is-3d .boss-preview-pets{width:auto!important;height:auto!important;gap:6px!important;flex-wrap:nowrap}
.boss-live-stage.is-3d .boss-preview-pets>*{flex:none;width:46px!important;height:46px!important;max-width:none!important;margin:0!important;transform:none!important}
.boss-live-stage.is-3d .boss-preview-pets img{width:46px!important;height:46px!important;object-fit:cover;object-position:center 20%;border:2px solid #f0c060;border-radius:50%;background:#fffaf0;box-shadow:0 2px 5px #0006}
.boss-live-stage.is-3d .boss-preview-pets :is(span,small,b,figcaption){display:none}
/* 10-28 老闆：圓形頭像居中，左 MP、右 HP；技能列隱藏 */
.boss-live-stage>.boss-stage-vitals{width:min(420px,58%);grid-template-columns:1fr 54px 1fr;align-items:center;gap:8px}
.boss-stage-vitals p{grid-template-columns:22px 1fr;row-gap:1px}.boss-stage-vitals p span{grid-column:1/-1;text-align:center;font-size:11px}
.boss-stage-vitals b{color:#b3261e}.boss-stage-vitals p.is-mp-side b{color:#1f5fbf}
.boss-vitals-avatar{width:54px;height:54px;object-fit:cover;object-position:50% 12%;border:2px solid #f0c060;border-radius:50%;background:#fff3d6}
.boss-live-stage>.boss-preview-skills[hidden]{display:none}
/* 10-28 老闆附圖：圓框頭像＋左藍 MP 弧＋右紅 HP 弧（弧長跟著數值） */
.boss-live-stage>.boss-stage-vitals{width:auto;grid-template-columns:auto auto;grid-template-rows:auto auto;column-gap:8px;row-gap:2px;padding:6px 10px 6px 6px;border-radius:14px}
.boss-vitals-ring{grid-row:1/3;position:relative;width:76px;height:76px;border-radius:50%;padding:7px;box-sizing:border-box;
  background:radial-gradient(circle,transparent 30px,#f0c060 30px,#f0c060 32px,transparent 32px),
    conic-gradient(from 200deg,#3b82f6 0 calc(var(--mp)*140deg),#00000022 0 140deg,transparent 0 160deg,#00000022 0 calc(300deg - var(--hp)*140deg),#e0443a 0 300deg,transparent 0);
  box-shadow:0 0 0 2px #c8962e,0 2px 6px #0004}
.boss-vitals-ring::after{content:'';position:absolute;left:50%;top:-5px;width:10px;height:10px;margin-left:-5px;background:#e0443a;border:2px solid #f0c060;transform:rotate(45deg)}
.boss-vitals-ring img{width:100%;height:100%;object-fit:cover;object-position:50% 12%;border-radius:50%;border:2px solid #f0c060;background:#fff3d6;box-sizing:border-box}
.boss-stage-vitals>p{display:flex;gap:6px;align-items:baseline;grid-template-columns:none}.boss-stage-vitals>p span{grid-column:auto;font-size:12px}
.boss-stage-vitals>p:not(.is-mp-side) b{color:#b3261e}
/* 10-28 老闆：只留圓形頭像（照附圖），不放文字列 */
.boss-live-stage>.boss-stage-vitals{display:block;padding:6px;background:none;border:0;box-shadow:none}
.boss-live-stage .boss-vitals-ring{width:92px;height:92px;padding:11px;
  background:radial-gradient(circle,transparent 34px,#f0c060 34px,#f0c060 36px,transparent 36px),
    conic-gradient(from 200deg,#3b82f6 0 calc(var(--mp)*140deg),#00000033 0 140deg,transparent 0 160deg,#00000033 0 calc(300deg - var(--hp)*140deg),#e0443a 0 300deg,transparent 0);
  box-shadow:0 0 0 3px #c8962e,0 0 0 5px #fff3d6,0 3px 8px #0005}
.boss-live-stage .boss-vitals-ring::after{top:-8px;width:14px;height:14px;margin-left:-7px}
.boss-live-stage .boss-vitals-ring::before{content:'';position:absolute;left:50%;bottom:-9px;width:18px;height:18px;margin-left:-9px;border-radius:50%;z-index:1;
  background:radial-gradient(circle,#555 0 3px,#c9ccd1 3px 6px,#8a8f96 6px 7px,#c9ccd1 7px);border:2px solid #c8962e;box-sizing:border-box}
/* 10-28 老闆：直接用老闆給的頭像圖；藍弧(MP)、紅弧(HP)用到的部分由上往下變暗 */
.boss-live-stage .boss-vitals-ring{width:110px;height:110px;padding:0;background:none;box-shadow:none;border-radius:0}
.boss-live-stage .boss-vitals-ring::before,.boss-live-stage .boss-vitals-ring::after{content:none}
.boss-live-stage .boss-vitals-ring img{border:0;border-radius:0;background:none;object-fit:contain;filter:drop-shadow(0 3px 5px #0006)}
.boss-vitals-ring>i{position:absolute;inset:0;pointer-events:none;
  background:conic-gradient(transparent 0 25deg,#2b2b2b 0 calc(25deg + (1 - var(--hp))*120deg),transparent 0 calc(335deg - (1 - var(--mp))*120deg),#2b2b2b 0 335deg,transparent 0);
  -webkit-mask:radial-gradient(circle closest-side,transparent 70%,#000 71% 93%,transparent 94%),url(../img/combat/hero-hud-frame.webp) center/contain no-repeat;-webkit-mask-composite:source-in;
  mask:radial-gradient(circle closest-side,transparent 70%,#000 71% 93%,transparent 94%),url(../img/combat/hero-hud-frame.webp) center/contain no-repeat;mask-composite:intersect}
/* 10-28 實戰截圖：排名內文淺字看不到、警示條被排名蓋住 */
.boss-stage-rank .boss-live-rank p{margin:2px 0;font-size:12px;color:#5a3a12}
.boss-stage-rank .boss-live-rank p:last-child{display:none}
.boss-live-clean .boss-live-stage .boss-preview-warning{animation:boss-live-warn-out 4s ease-out forwards}
@keyframes boss-live-warn-out{0%,70%{opacity:1}100%{opacity:0;visibility:hidden}}
/* 10-28 老闆：左邊擋住了——頭像縮小、寵物縮成一列小圓貼左邊 */
.boss-live-stage .boss-vitals-ring{width:78px;height:78px}
.boss-live-stage>.boss-stage-vitals{top:6px;left:6px;padding:0}
.boss-live-stage.is-3d .boss-preview-pets{top:86px!important;left:6px!important;gap:3px!important}
.boss-live-stage.is-3d .boss-preview-pets>*,.boss-live-stage.is-3d .boss-preview-pets img{width:30px!important;height:30px!important}
/* 10-29 老闆：世界 BOSS 要像進入獨立場地，不是疊在大地圖上——全螢幕、背景完全遮住 */
html body dialog.boss-hall,html body dialog.boss-hall.boss-atb-preview{width:100vw;height:100dvh;max-width:none;max-height:none;margin:0;inset:0;border:0;border-radius:0}
html body dialog.boss-hall::backdrop{background:#071321;backdrop-filter:none}
/* 10-29 老闆「特效都還是2D」：3D 模式下關掉 2D 疊圖特效（大砲光柱、熔岩漸層、發光濾鏡），改由 3D 場景畫 */
.boss-live-stage.is-3d:before,.boss-live-stage.is-3d .boss-preview-lava{display:none}.boss-live-stage.is-3d{cursor:pointer;touch-action:none}
.boss-live-stage>.boss-stage-mode{position:absolute;right:10px;bottom:10px;z-index:5;padding:6px 12px;border-radius:999px;border:1px solid #f0c060;background:#fffaf0ee;color:#2a1d10;font-weight:700}
.boss-live-stage.is-3d-loading{background:#2a120c}
.boss-live-stage.is-3d-loading>:is(.boss-preview-boss,.boss-preview-lava,.boss-preview-actors){visibility:hidden}
.boss-live-stage.is-3d-loading::after{content:"3D 場地載入中…";position:absolute;inset:0;display:grid;place-items:center;color:#ffe0a0;font-weight:700;font-size:18px;z-index:4;pointer-events:none}
.boss-live-stage>.boss-stage-mode{bottom:108px}
.boss-live-stage>.boss-render-mode{position:absolute;z-index:7;left:10px;bottom:110px;padding:4px 8px;border:1px solid #e5bd73;border-radius:7px;background:#10283bdc;color:#fff4cc;font-size:11px;font-weight:800;pointer-events:none}
.boss-live-stage>.boss-device-notice{position:absolute;z-index:8;left:50%;top:74px;transform:translateX(-50%);max-width:80%;padding:7px 12px;border:1px solid #f0c060;border-radius:9px;background:#10283be8;color:#fff4cc;font-size:13px;font-weight:800;text-align:center;pointer-events:none}
@media(max-width:700px){.boss-live-stage>.boss-stage-mode{bottom:137px}.boss-live-stage>.boss-render-mode{bottom:140px}}
/* 10-31 老闆「將畫面空出來」：戰鬥畫面撐高吃掉下方空白；結算後控制區整塊收掉，結果浮在畫面下緣 */
html body dialog.boss-hall.boss-live-clean>.boss-preview-shell{height:100dvh;box-sizing:border-box;grid-template-rows:auto auto minmax(0,1fr) auto}
html body dialog.boss-hall.boss-live-clean .boss-live-stage{min-height:0;height:100%}
.boss-live-done .boss-preview-controls{display:none}
.boss-live-stage>.boss-stage-result{position:absolute;z-index:7;left:50%;bottom:14px;transform:translateX(-50%);padding:8px 16px;border:1px solid #f3ca7c;border-radius:10px;background:#1b1209e6;color:#ffe9b8;font-size:15px;font-weight:800;white-space:nowrap}

/* 每次進場先看爐心王從地洞爬出，結束後才接正式戰鬥。 */
.boss-entry-shell{min-height:min(76vh,680px)}
.boss-entry-stage{min-height:clamp(320px,60vh,600px);background:radial-gradient(circle at 50% 78%,#47332f 0,#17263a 42%,#101a2b 100%);overflow:hidden}
.boss-entry-stage>.boss-preview-boss{left:50%;bottom:16%;width:min(44%,310px);max-height:70%;transform:translateX(-50%);opacity:0}
.boss-entry-stage .boss-entry-pit{position:absolute;z-index:1;left:50%;bottom:9%;width:min(56%,390px);height:18%;transform:translateX(-50%);border-radius:50%;background:#050b14;box-shadow:0 0 0 8px #d7924a,0 0 36px 15px #f6a84877;opacity:0}
.boss-entry-stage.is-emerging.boss-entry-2d .boss-entry-pit{animation:boss-entry-hole 3.6s ease-out both}
.boss-entry-stage.is-emerging.boss-entry-2d>.boss-preview-boss{animation:boss-entry-climb 3.6s ease-out both}
.boss-entry-stage.is-3d .boss-entry-pit{display:none}
.boss-entry-stage [data-entry-status]{position:absolute;z-index:6;left:50%;bottom:6px;transform:translateX(-50%);width:min(90%,600px);padding:8px 12px;border-radius:9px;background:#101a2bd9;color:#ffe6ae;text-align:center;font-weight:800}
@keyframes boss-entry-hole{0%{opacity:0;transform:translateX(-50%) scale(.25)}15%,78%{opacity:1;transform:translateX(-50%) scale(1)}100%{opacity:0;transform:translateX(-50%) scale(.8)}}
@keyframes boss-entry-climb{0%,12%{opacity:0;transform:translate(-50%,80%) scale(.65)}35%{opacity:1}80%{transform:translate(-50%,0) scale(1.03)}100%{opacity:1;transform:translate(-50%,0) scale(1)}}
@media(prefers-reduced-motion:reduce){.boss-entry-stage.is-emerging.boss-entry-2d .boss-entry-pit{animation:none;opacity:0}.boss-entry-stage.is-emerging.boss-entry-2d>.boss-preview-boss{animation:none;opacity:1;transform:translateX(-50%)}}
.reduced-motion .boss-entry-stage.is-emerging.boss-entry-2d .boss-entry-pit{animation:none;opacity:0}
.reduced-motion .boss-entry-stage.is-emerging.boss-entry-2d>.boss-preview-boss{animation:none;opacity:1;transform:translateX(-50%)}
/* 10-31 老闆：血條不要變暗、要真的變少——扣掉的那段弧直接挖掉（外圈帶以外照常顯示） */
.boss-vitals-ring>i{display:none}
.boss-live-stage .boss-vitals-ring img,.boss-vitals-ring img{
  -webkit-mask:radial-gradient(circle closest-side,#000 70%,transparent 71% 93%,#000 94%),conic-gradient(#000 0 25deg,transparent 0 calc(25deg + (1 - var(--hp))*120deg),#000 0 calc(335deg - (1 - var(--mp))*120deg),transparent 0 335deg,#000 0);
  -webkit-mask-composite:source-over;
  mask:radial-gradient(circle closest-side,#000 70%,transparent 71% 93%,#000 94%),conic-gradient(#000 0 25deg,transparent 0 calc(25deg + (1 - var(--hp))*120deg),#000 0 calc(335deg - (1 - var(--mp))*120deg),transparent 0 335deg,#000 0);
  mask-composite:add}

/* 10-31 世界BOSS共用：場上人數（淺底深字、公會金色） */
/* 11-08 老闆：場上人數／公會標籤跟左上血量框疊在一起 → 移到頭像右邊 */
.boss-live-stage>.boss-stage-crowd{position:absolute;left:96px;top:10px;z-index:5;padding:4px 12px;border-radius:999px;border:1px solid #f0c060;background:#fffaf0ee;color:#2a1d10;font-size:14px;font-weight:700}
.boss-stage-crowd b{color:#b06a00}.boss-stage-crowd em{font-style:normal;color:#8a5a00;background:#ffe39a;border-radius:999px;padding:0 6px}
/* 11-08 老闆：人像下小狀態標籤（公會加成），取代條列字樣；場上人數併進排行榜標題 */
.boss-live-stage>.boss-hud-buffs{position:absolute;left:10px;top:96px;z-index:5;display:flex;gap:4px;pointer-events:auto}
.battle-portrait>.boss-hud-buffs{position:static;width:max-content;margin-top:4px;display:flex;gap:6px;pointer-events:auto}
.boss-rank-crowd{margin-left:6px;font-size:11px;font-weight:700;color:#6a5030;white-space:nowrap}
.boss-rank-crowd:empty{display:none}

/* Numeric vitals make the two ring gauges unambiguous. */
.boss-live-stage>.boss-stage-vitals{background:#10263de8;color:#fff;border-radius:10px;max-width:42%;font-size:10px}
.boss-stage-vitals>p{margin:2px 3px;line-height:1.3}.boss-stage-vitals>p span{font-size:10px}.boss-stage-vitals>p:not(.is-mp-side) b{color:#ffada7}
/* 11-06 世界首領排行榜：依老闆參考圖 */
.boss-board-open{width:100%;min-height:30px;margin:5px 0 2px;border:1px solid #d6ae64;border-radius:8px;background:#fff4d8;color:#6d3f08;font-weight:800;pointer-events:auto}
.boss-board{width:min(560px,calc(100vw - 24px));max-height:calc(100dvh - 24px);box-sizing:border-box;padding:18px 16px 14px;overflow:auto;border:3px solid #c9a970;border-radius:14px;background:#fbf6ea;color:#2b2118;box-shadow:0 12px 36px #000a}
.boss-board::backdrop{background:#0a0e16b8}
.boss-board h2{margin:0;padding:0 30px;text-align:center;font-size:clamp(21px,5.5vw,30px);color:#2b2118;font-family:serif}
.boss-board-sub{margin:4px 0 10px;text-align:center;color:#5a4730;letter-spacing:2px;font-size:14px}
.boss-board-close{position:absolute;top:10px;right:12px;width:36px;height:36px;border:0;background:none;color:#6b5a40;font-size:28px;line-height:1}
.boss-board-tabs{display:flex;gap:6px;border-bottom:1px solid #d9c9a6}
.boss-board-tabs button{flex:1;min-height:44px;border:1px solid #d9d2c2;border-bottom:0;border-radius:10px 10px 0 0;background:#ece8df;color:#4a4034;font-size:17px;font-weight:800}
.boss-board-tabs button[aria-pressed="true"]{background:linear-gradient(#fbe7b8,#fff6e0);box-shadow:inset 0 -3px #c28a1e;color:#2b2118}
.boss-board-head,.boss-board-list li{display:grid;grid-template-columns:52px 46px minmax(0,1fr) auto;align-items:center;gap:8px}
.boss-board-head{grid-template-columns:52px minmax(0,1fr) auto;margin:10px 0 2px;padding:7px 10px;border-radius:6px;background:#efe6d2;font-weight:800;font-size:14px;color:#3f3324}
.boss-board-head span:nth-child(2){text-align:center}
.boss-board-head.is-guild{grid-template-columns:52px minmax(0,1fr) 48px 96px}.boss-board-head span:last-child{text-align:right}
.boss-board-list{margin:0;padding:0;list-style:none}
.boss-board-list li{min-height:62px;padding:6px 10px;border-bottom:1px solid #e5dcc8}
.boss-board-list.is-guild li{grid-template-columns:52px 46px minmax(0,1fr) 48px 96px}
.boss-board-list li.is-me{background:#dbe7f8}
.boss-board-list img{width:46px;height:46px;border-radius:6px;object-fit:cover;background:#e8dfcd}
.boss-board-list b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:17px}
.boss-board-list span{text-align:center;font-size:14px}
.boss-board-list strong{text-align:right;font-size:18px;font-variant-numeric:tabular-nums}
.boss-board-medal,.boss-board-rank{display:grid;place-items:center;width:38px;height:38px;margin:auto;font-style:normal;font-weight:900;font-size:19px}
.boss-board-medal{border-radius:50%;color:#fff;text-shadow:0 1px 1px #0006}
.boss-board-medal.m1{background:radial-gradient(#ffe48a,#c98f12);color:#5a3a00}.boss-board-medal.m2{background:radial-gradient(#f1f4f8,#8d9aab);color:#39424f}.boss-board-medal.m3{background:radial-gradient(#f0bd8d,#a8622c);color:#4a2408}
.boss-board-crest{display:grid;place-items:center;width:42px;height:46px;font-style:normal;font-size:22px;color:#ffe9a8;clip-path:polygon(50% 0,100% 12%,100% 62%,50% 100%,0 62%,0 12%)}
.boss-board-crest.c0{background:#1e3f7a}.boss-board-crest.c1{background:#8a1f24}.boss-board-crest.c2{background:#1f5a48}.boss-board-crest.c3{background:#5a3b8a}.boss-board-crest.c4{background:#7a4a14}
.boss-board-note,.boss-board-empty{margin:8px 0 0;text-align:center;color:#6b5a40;font-size:13px}
.boss-board-foot{margin-top:10px;padding:12px;border:1px solid #c9a970;border-radius:8px;background:#fff9ea;text-align:center;font-size:16px}
.boss-board-foot b{color:#16307a;font-size:20px}
@media (max-width:420px){.boss-board-list.is-guild li,.boss-board-head.is-guild{grid-template-columns:42px 40px minmax(0,1fr) 38px 78px}.boss-board-head.is-guild{grid-template-columns:42px minmax(0,1fr) 38px 78px}.boss-board-list li{gap:5px;padding:5px}.boss-board-list strong{font-size:15px}.boss-board-list b{font-size:15px}}

/* 11-06 世界首領寵物介面：顯示版 */
.boss-pets-list{margin:0;padding:0;list-style:none;display:grid;gap:6px}
.boss-pets-list button{display:grid;grid-template-columns:56px minmax(0,1fr) auto auto;align-items:center;gap:8px;width:100%;min-height:64px;padding:4px 8px;border:1px solid #e0d4bb;border-radius:10px;background:#fffaf0;color:#2b2118;text-align:left}
.boss-pets-list button[aria-pressed="true"]{border:2px solid #d9a93a;background:#fff3cf}
.boss-pets-list img{width:54px;height:54px;border-radius:8px;object-fit:contain;background:#e8dfcd}
.boss-pets-list b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:17px}
.boss-pets-list span{font-weight:700;color:#4a3a26}
.boss-pets-list em{padding:5px 10px;border-radius:999px;background:#e7e2d6;color:#4f4636;font-style:normal;font-size:13px;font-weight:800}
.boss-pets-list em.is-active{background:#1f5fae;color:#fff}
.boss-pets-detail{display:grid;grid-template-columns:112px minmax(0,1fr);gap:12px;margin-top:10px;padding:10px;border:1px solid #c9a970;border-radius:10px;background:#fff9ea}
.boss-pets-detail>img{width:112px;height:112px;border-radius:10px;object-fit:contain;background:#e8dfcd}
.boss-pets-detail h3{margin:0;color:#2b2118;font-size:19px}.boss-pets-detail h3 span{font-size:14px;color:#5a4730}
.boss-pets-detail p{margin:6px 0 4px;color:#5a4730;font-size:13px;font-weight:800}
.boss-pets-skills{display:flex;flex-wrap:wrap;gap:8px;color:#5a4730;font-size:13px}
.boss-pets-skill{display:grid;justify-items:center;gap:2px;width:64px;text-align:center}.boss-pets-skill img{width:46px;height:46px;border-radius:8px}.boss-pets-skill small{font-size:11px;line-height:1.2;color:#2b2118}
.boss-live-stage>.boss-preview-skills.battle-wheel{left:auto;right:1%;bottom:2%;width:28%;aspect-ratio:1100/940;min-height:0;display:block;padding:0;border:0;background:none;z-index:8}
.boss-live-stage>.battle-pad{z-index:8}
.boss-live-stage:has(>.battle-wheel)>.boss-stage-mode{left:35%;right:35%;bottom:2%;width:30%;min-height:28px;font-size:10px;z-index:8}

/* Authoritative lava warning: fixed ground position, never follows the hero. */
.boss-spatial-danger{position:absolute;transform:translate(-50%,-50%);border:3px solid #ff3926;border-radius:50%;background:#ff271f55;box-shadow:0 0 14px #ff321c;pointer-events:none;z-index:2}
.boss-spatial-danger[hidden],.boss-live-stage.is-3d .boss-spatial-danger{display:none}
.boss-live-stage[data-spatial]>.boss-preview-actors{position:absolute;inset:0;pointer-events:none;transform:none}
.boss-live-stage[data-spatial] .boss-preview-hero{position:absolute;transform:translate(-50%,-85%);bottom:auto}
.boss-live-stage[data-spatial].is-lava-warning>.boss-preview-lava,.boss-live-stage[data-spatial].is-lava-impact>.boss-preview-lava{display:none}

.boss-live-stage[data-spatial]:not(.is-3d) .boss-preview-hero{transition:left .22s linear,top .22s linear}

/* 11-08 老闆「BOSS 大招要用整個畫面的橫幅，讓人知道要發大招了」：橫跨整個戰場、閃爍 */
.boss-spatial-hint{position:absolute;top:22%;left:0;right:0;z-index:9;display:block;padding:10px 12px;background:linear-gradient(90deg,#9b181800,#b3140fee 12%,#d01f14f5 50%,#b3140fee 88%,#9b181800);border-top:2px solid #ffd778;border-bottom:2px solid #ffd778;color:#fff6dc;font-size:clamp(18px,3.2vw,30px);font-weight:900;letter-spacing:.08em;text-align:center;white-space:nowrap;text-shadow:0 2px 4px #000a;pointer-events:none;animation:boss-ult-banner .7s ease-in-out infinite alternate}.boss-spatial-hint[hidden]{display:none}
@keyframes boss-ult-banner{from{opacity:.82;transform:scaleY(.96)}to{opacity:1;transform:scaleY(1.04)}}
@media(prefers-reduced-motion:reduce){.boss-spatial-hint{animation:none}}

/* Boss lobby occupies one viewport; full rankings remain in their own dialog. */
html body dialog.boss-hall:has(>.boss-hall-shell){overflow:hidden;overscroll-behavior:none}
html body dialog.boss-hall>.boss-hall-shell{height:100%;min-height:0;box-sizing:border-box;grid-template-rows:auto minmax(0,1fr);overflow:hidden}
.boss-hall-shell>.boss-hall-scene{min-height:0;grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);align-items:stretch}
.boss-hall-shell>.boss-hall-scene:has(>[data-live-rank]){grid-template-columns:minmax(0,.85fr) minmax(0,1fr) minmax(220px,.8fr)}
.boss-hall-shell .boss-hall-art{min-height:0;overflow:hidden}
.boss-hall-shell .boss-hall-art img{width:90%;height:100%;max-height:100%;min-height:0;object-fit:contain}
.boss-hall-shell .boss-hall-info{min-width:0;min-height:0;padding:12px;gap:8px;justify-content:center}
.boss-hall-shell .boss-hall-info h3{font-size:clamp(22px,2.5vw,32px)}
.boss-hall-shell .boss-hall-info p{font-size:13px;line-height:1.4}
.boss-hall-shell .boss-hall-facts{gap:5px}
.boss-hall-shell .boss-hall-facts span{padding:4px 6px;font-size:12px}
.boss-hall-shell .boss-hall-actions{gap:5px}
.boss-hall-shell .boss-hall-actions button{min-height:36px;padding:5px 8px;font-size:13px}
.boss-hall-scene>[data-live-rank]{min-width:0;min-height:0;align-self:center;padding:10px;box-sizing:border-box}
.boss-hall-scene>[data-live-rank] .boss-live-rank{font-size:13px}
.boss-hall-scene>[data-live-rank] ol{max-height:100px;overflow:hidden}
.boss-hall-scene>[data-live-rank] li:nth-child(n+4){display:none}
/* 11-08 老闆：領取獎勵按鈕跟「累計徽記」黏在一起看起來被蓋住；同一行留空隙、垂直置中，不加高度（手機橫向才放得下），太窄時文字自動換行 */
.boss-hall-scene>[data-live-rank] [data-boss-reward-claim]{margin:0 10px 0 0;vertical-align:middle}
.boss-hall-scene>[data-live-rank] [data-boss-reward-claim]+small{display:inline-block;vertical-align:middle;white-space:nowrap}
@media(max-width:700px) and (orientation:portrait){
 .boss-hall-shell>.boss-hall-scene,.boss-hall-shell>.boss-hall-scene:has(>[data-live-rank]){grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(70px,1fr) auto auto}
 .boss-hall-shell .boss-hall-art img{position:absolute;inset:0;margin:auto;width:80%}
 .boss-hall-shell .boss-hall-info{padding:8px;gap:5px}
 .boss-hall-scene>[data-live-rank]{padding:0 8px 8px}
 .boss-hall-scene>[data-live-rank] .boss-live-rank{display:grid;grid-template-columns:1fr 1fr;gap:3px 8px;padding:7px}
 .boss-hall-scene>[data-live-rank] .boss-live-rank :is(h3,ol){grid-column:1/-1}
 .boss-hall-scene>[data-live-rank] .boss-live-rank :is(p,small){margin:0;font-size:11px}
 .boss-hall-scene>[data-live-rank] .boss-rank-tabs{margin:0}
 .boss-hall-scene>[data-live-rank] .boss-board-open{margin:0}
}
@media(max-height:460px) and (orientation:landscape){
 .boss-hall-shell{padding:6px;gap:5px}
 .boss-hall-shell .boss-hall-head h2{font-size:20px}
 .boss-hall-shell .boss-hall-head button{width:30px;height:30px}
 .boss-hall-shell .boss-hall-tabs button{min-height:30px}
 .boss-hall-shell .boss-hall-info{padding:6px;gap:4px}
 .boss-hall-shell .boss-hall-info p{font-size:11px;line-height:1.2}
 .boss-hall-shell .boss-hall-facts span{font-size:10px;padding:2px 4px}
 .boss-hall-shell .boss-hall-actions button{min-height:30px;font-size:11px;padding:3px 5px}
 .boss-hall-scene>[data-live-rank]{padding:5px}
 .boss-hall-scene>[data-live-rank] .boss-live-rank{padding:5px}
 .boss-hall-scene>[data-live-rank] .boss-live-rank p:last-child{font-size:10px;margin:2px 0}
}
html body dialog.boss-hall.boss-live-clean .boss-live-stage{width:100%;min-width:0;max-width:none;min-height:0!important;aspect-ratio:auto;box-sizing:border-box}
/* 11-10 本機排查：對話框被 v654 通用規則改成淺底，白字標題看不見 → 照 10-28 老闆「淺底上左上標題要深字」 */
html body dialog.boss-hall>.boss-hall-shell .boss-hall-head h2{color:#1d2b3a!important}
/* Preserve the live directional pad and server movement; keep controls in separate lanes. */
html body dialog.boss-live-clean .boss-live-stage>.boss-stage-rank{right:6px;top:6px;width:150px;max-height:calc(100% - 16px);overflow:hidden;box-sizing:border-box}
/* 11-08 排行榜改窄：名字太長就省略號，數字靠右不換行 */
html body dialog.boss-live-clean .boss-stage-rank .boss-live-rank{padding:5px 6px}
html body dialog.boss-live-clean .boss-stage-rank .boss-live-rank li{gap:4px}
html body dialog.boss-live-clean .boss-stage-rank .boss-live-rank li span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
html body dialog.boss-live-clean .boss-stage-rank .boss-live-rank li b{flex:none;white-space:nowrap}
html body dialog.boss-live-clean .boss-stage-rank .boss-live-rank small{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
/* 11-08 老闆：技能盤擋人物 → 貼最右下角、排行榜讓出底部；技能盤和方向鍵 75% 透明（不透明度 .25），人物看得到、按鈕照樣能點 */
html body dialog.boss-live-clean .boss-live-stage>.boss-preview-skills.battle-wheel{right:8px;left:auto;bottom:8px;width:180px;height:154px;aspect-ratio:1100/940;z-index:8;opacity:1;transition:opacity .15s}
html body dialog.boss-live-clean .boss-live-stage>:is(.battle-wheel,.battle-pad):is(:hover,:active,:focus-within){opacity:1}
html body dialog.boss-live-clean .boss-live-stage>.boss-stage-rank{max-height:calc(100% - 178px)}
html body dialog.boss-live-clean .boss-live-stage.battle-interface{--battle-skill-right:8px}
html body dialog.boss-live-clean .boss-live-stage>.battle-pad{opacity:.25!important}
html body dialog.boss-live-clean .boss-live-stage>:is(.battle-wheel,.battle-pad):is(:hover,:active,:focus-within){opacity:1!important}
html body dialog.boss-live-clean .boss-live-stage>.battle-pad{left:10px;bottom:10px;width:112px;height:112px;aspect-ratio:1;z-index:8;opacity:.62;transition:opacity .15s}
html body dialog.boss-live-clean .boss-live-stage:has(>.battle-wheel)>.boss-stage-mode{left:140px;right:auto;bottom:8px;width:auto;max-width:calc(100% - 340px);box-sizing:border-box;padding:3px 8px}
html body dialog.boss-live-clean .boss-stage-mode button{min-height:32px;font-size:12px;padding:3px 8px}
html body dialog.boss-live-clean .boss-live-stage>.battle-mode [data-live-potion]{min-height:32px;padding:3px 7px;background:#fffaf0;color:#2a1d10;border:1px solid #e5bd73;border-radius:8px;font-weight:700;white-space:nowrap}
html body dialog.boss-live-clean .boss-live-stage>.battle-mode [data-live-potion]:disabled{opacity:.5}
html body dialog.boss-live-clean .boss-live-stage>.boss-render-mode{bottom:132px}
@media(max-width:700px){
 html body dialog.boss-live-clean .boss-live-stage>.boss-stage-rank{width:min(150px,40%);max-height:calc(100% - 178px)}
 html body dialog.boss-live-clean .boss-live-stage>.boss-preview-skills.battle-wheel{right:8px}
 html body dialog.boss-live-clean .boss-live-stage:has(>.battle-wheel)>.boss-stage-mode{left:8px;bottom:130px;max-width:calc(100% - 204px)}
 html body dialog.boss-live-clean .boss-live-stage>.boss-render-mode{bottom:172px}
}
@media(max-width:700px) and (orientation:landscape){
 html body dialog.boss-live-clean .boss-live-stage>.boss-stage-rank{width:136px;max-height:calc(100% - 152px)}
 html body dialog.boss-live-clean .boss-live-stage>.boss-preview-skills.battle-wheel{right:8px;width:154px;height:132px}
 html body dialog.boss-live-clean .boss-live-stage:has(>.battle-wheel)>.boss-stage-mode{left:132px;bottom:8px;max-width:calc(100% - 300px)}
 html body dialog.boss-live-clean .boss-live-stage>.boss-render-mode{bottom:132px}
}
/* 11-08 矮手機：排行榜縮在戰場內，名單太長只截名單，「領取獎勵」按鈕一定整顆露出 */
html body dialog.boss-live-clean .boss-live-stage>.boss-stage-rank{display:flex;flex-direction:column}
html body dialog.boss-live-clean .boss-stage-rank .boss-live-rank{flex:0 1 auto;min-height:0;display:flex;flex-direction:column;overflow:hidden}
html body dialog.boss-live-clean .boss-stage-rank .boss-live-rank>*{flex:none}
html body dialog.boss-live-clean .boss-stage-rank .boss-live-rank>ol{flex:0 1 auto;min-height:1.5em;overflow:hidden}
@media(orientation:landscape) and (max-height:430px){
 html body dialog.boss-live-clean .boss-stage-rank .boss-live-rank h3{margin:0 0 2px}
 html body dialog.boss-live-clean .boss-stage-rank .boss-rank-tabs button{min-height:24px;padding:1px 6px;font-size:12px}
 html body dialog.boss-live-clean .boss-stage-rank :is(.boss-board-open,[data-boss-reward-claim]){min-height:26px;padding:2px 6px;margin:2px 0;font-size:13px}
 html body dialog.boss-live-clean .boss-stage-rank .boss-live-rank p{margin:1px 0;font-size:11px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
}
/* Pet vitals remain outside the arena, so models and controls cannot hide them. */
html body dialog.boss-live-clean .boss-live-pet-hud{display:flex;flex-wrap:wrap;gap:4px;min-width:0;align-self:center}
html body dialog.boss-live-clean .boss-live-pet-hud>[data-live-pet-vitals]{display:flex;align-items:center;gap:4px;width:108px;min-height:34px;padding:3px 5px;box-sizing:border-box;border:1px solid #b7cbbd;border-radius:8px;background:#f6fbf7;color:#243c32}
.boss-live-pet-hud img{width:28px;height:28px;object-fit:contain;border-radius:5px;flex:none}
.boss-live-pet-hud [data-live-pet-vitals]>div{min-width:0;flex:1}
.boss-live-pet-hud b,.boss-live-pet-hud small{display:block;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-size:10px;line-height:1.2}
.boss-live-pet-hud [role=meter]{display:block;height:4px;margin-top:2px;overflow:hidden;border-radius:4px;background:#c8d7cd}
.boss-live-pet-hud [role=meter][hidden]{display:none}
.boss-live-pet-hud [role=meter] em{display:block;height:100%;background:#319967;transition:width .2s}
html body dialog.boss-live-clean .boss-live-pet-hud [data-pet-vital-state=down]{background:#fff1ed;border-color:#d9aaa0;color:#8c342a}
html body dialog.boss-live-clean .boss-live-pet-hud [data-pet-vital-state=display]{background:#f3f4f5;border-color:#c7cdd3;color:#526070}
@media(orientation:landscape) and (max-height:460px){
 html body dialog.boss-live-clean>.boss-preview-shell{padding:6px;gap:5px}
 html body dialog.boss-live-clean .boss-preview-head h2{font-size:20px}
 html body dialog.boss-live-clean .boss-preview-head small{font-size:10px}
 html body dialog.boss-live-clean .boss-preview-head .boss-hall-close{width:30px;height:30px}
 html body dialog.boss-live-clean .boss-preview-top{gap:4px}
 html body dialog.boss-live-clean .boss-preview-top>span{padding:3px 6px;font-size:11px}
 html body dialog.boss-live-clean .boss-preview-controls>[data-live-finish]{min-height:34px;padding:4px 8px}
}
html body dialog.boss-live-clean .boss-damage-summary{display:flex;align-items:center;flex-wrap:wrap;gap:4px;color:#263c51;font-size:11px}
.boss-damage-summary>span{padding:4px 6px;border:1px solid #c8d5df;border-radius:6px;background:#f2f7fb;white-space:nowrap}.boss-damage-summary>span:last-child{background:#fff3d1;border-color:#dbb85f}
html body dialog.boss-live-clean .boss-live-pet-hud{flex-wrap:nowrap;overflow-x:auto;max-width:100%;padding-bottom:2px}
html body dialog.boss-live-clean .boss-live-pet-hud>[data-live-pet-vitals]{flex:none}
html body dialog.boss-live-clean>.boss-preview-shell{min-width:0;grid-template-columns:minmax(0,1fr)}
html body dialog.boss-live-clean .boss-preview-top{min-width:0;max-width:100%}
html body dialog.boss-live-clean .boss-live-pet-hud{width:max-content;max-width:100%;min-width:0}

/* 11-06 世界首領等待復活：依老闆參考圖 */
.boss-revive{position:absolute;inset:0;z-index:12;display:grid;grid-template-columns:minmax(0,1fr) min(46%,380px);align-items:center;padding:12px 16px 58px;background:#050b1466;box-sizing:border-box}
.boss-revive-pad{justify-self:center;align-self:end;width:min(34%,170px);aspect-ratio:3/1;border:3px solid #6ff0ff;border-radius:50%;box-shadow:0 0 22px #36d9ff,inset 0 0 18px #36d9ff;animation:boss-revive-pad 1.4s ease-in-out infinite}
@keyframes boss-revive-pad{50%{opacity:.55;transform:scale(1.08)}}
.boss-revive-card{grid-column:2;padding:16px 14px;border:1px solid #7fe4ff;border-radius:18px;background:#071a2dea;color:#eafcff;text-align:center;box-shadow:0 0 22px #1fb7e066}
.boss-revive-card h3{margin:0 0 10px;color:#eafcff;font-size:clamp(22px,4.6vw,38px);font-family:serif;letter-spacing:3px}
.boss-revive-ring{--left:1;position:relative;display:grid;grid-auto-flow:column;place-content:center;align-items:baseline;gap:3px;width:min(150px,42vw);aspect-ratio:1;margin:0 auto 10px;border-radius:50%;background:radial-gradient(closest-side,#071a2d 84%,transparent 86%),conic-gradient(#39e4ff calc(var(--left)*360deg),#2a4560 0)}
.boss-revive-ring b{font-size:clamp(46px,10vw,72px);font-style:italic;line-height:1;color:#fff}.boss-revive-ring small{font-size:18px;color:#d7f7ff}
.boss-revive-card strong{display:block;font-size:clamp(15px,3vw,20px);color:#d7f7ff}.boss-revive-card p{margin:4px 0 0;color:#a8cfdd;font-size:13px}
.boss-revive-bar{position:absolute;left:50%;bottom:10px;display:flex;gap:18px;max-width:calc(100% - 150px);padding:8px 16px;transform:translateX(-50%);border:1px solid #7fe4ff;border-radius:999px;background:#071a2dea;color:#eafcff;font-size:14px;white-space:nowrap}
.boss-revive-bar b{color:#39e4ff;font-size:17px}
.boss-revive-leave{position:absolute;right:12px;bottom:10px;min-height:40px;padding:6px 16px;border:1px solid #cfefff;border-radius:12px;background:#071a2dea;color:#fff;font-weight:800}
@media (max-width:560px){.boss-revive{grid-template-columns:1fr;padding:8px 8px 96px}.boss-revive-pad{display:none}.boss-revive-card{grid-column:1}.boss-revive-bar{bottom:54px;max-width:calc(100% - 16px);font-size:12px;gap:10px}.boss-revive-leave{left:50%;right:auto;transform:translateX(-50%)}}
/* Guild rankings share the skill wheel's gold accents without its strong glow. */
html body dialog.boss-hall .boss-stage-rank .boss-live-rank{border:1px solid #d2ac61;background:linear-gradient(#fffaf0f5,#f7edd8f5);box-shadow:0 3px 12px #321d1733;color:#3d2b19;border-radius:12px}
html body dialog.boss-hall .boss-stage-rank .boss-live-rank h3{color:#80500f}
html body dialog.boss-hall .boss-stage-rank .boss-live-rank li{padding:2px 2px;line-height:1.25;border-bottom-color:#d7c8aa;color:#3d2b19}
html body dialog.boss-hall .boss-stage-rank .boss-live-rank li.is-me{background:#e0edfb;border-radius:6px;padding:2px 5px}
html body dialog.boss-hall .boss-stage-rank .boss-live-rank li b{color:#684719;font-variant-numeric:tabular-nums}
html body dialog.boss-hall .boss-rank-tabs button{background:#fffaf0;color:#6e532d;border-color:#d9c595}
html body dialog.boss-hall .boss-rank-tabs button[aria-pressed=true]{background:linear-gradient(#f9dfa3,#e4ba62);color:#5b3a0c;border-color:#bf913c;box-shadow:inset 0 -2px #b88b3944}
/* Player portrait followed by a single row of pet face portraits and health. */
html body dialog.boss-live-clean .boss-live-stage{container-type:size;container-name:bossBattle battleViewport}
html body dialog.boss-live-clean .boss-live-stage>.boss-stage-vitals{width:188px;max-width:calc(50% - 16px);background:none}
html body dialog.boss-live-clean .boss-stage-vitals>p{width:78px;box-sizing:border-box;margin:0;padding:1px 3px;background:#10263de8}
html body dialog.boss-live-clean .boss-stage-vitals .boss-pet-portrait-strip{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:3px;width:100%;max-width:none;margin:4px 0 0;padding:0;overflow:visible}
html body dialog.boss-live-clean .boss-pet-portrait-strip>[data-live-pet-vitals]{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:0;width:auto;min-width:0;min-height:0;height:60px;padding:0 1px;border:0;border-radius:0;background:transparent;box-shadow:none}
html body dialog.boss-live-clean .boss-pet-portrait-strip .boss-pet-face{position:relative;display:block;flex:none;width:min(38px,100%);aspect-ratio:1;overflow:hidden;border:1px solid #d2b56e;border-radius:50%;background:transparent;box-sizing:border-box;box-shadow:0 1px 4px #07132188}
html body dialog.boss-live-clean .boss-pet-portrait-strip .boss-pet-face>img{position:absolute;left:50%;top:50%;width:var(--pet-face-scale,230%);height:auto;max-width:none;min-width:0;margin:0;padding:0;border:0;border-radius:0;background:none;filter:none;transform:translate(calc(-1 * var(--pet-face-x,50%)),calc(-1 * var(--pet-face-y,55%)))}
html body dialog.boss-live-clean .boss-pet-portrait-strip [data-live-pet-vitals]>div{width:100%;min-width:0;flex:none;margin-top:2px;padding:2px 2px 3px;box-sizing:border-box;border-radius:5px;background:#14283cbd}
html body dialog.boss-live-clean .boss-pet-portrait-strip b{display:none}
html body dialog.boss-live-clean .boss-pet-portrait-strip small{font-size:8px;line-height:9px;text-align:center;color:#fff;text-shadow:0 1px 2px #000b}
html body dialog.boss-live-clean .boss-pet-portrait-strip [role=meter]{height:3px;margin-top:2px;background:#14362b;box-shadow:0 0 0 1px #ffffff18}
html body dialog.boss-live-clean .boss-pet-portrait-strip [role=meter] em{background:#58cd8a}
html body dialog.boss-live-clean .boss-pet-portrait-strip>[data-pet-vital-state=down] .boss-pet-face{filter:grayscale(.85) brightness(.8);border-color:#929ca6}
html body dialog.boss-live-clean .boss-damage-summary>span{background:#f2f7fb;border-color:#c8d5df;color:#263c51}
html body dialog.boss-live-clean .boss-damage-summary>span b{color:#264b39}
html body dialog.boss-live-clean .boss-damage-summary>span:last-child{background:#fff3d1;border-color:#dbb85f}
html body dialog.boss-live-clean .boss-damage-summary>span:last-child b{color:#8a5200}
@media(orientation:landscape) and (max-height:460px){
 html body dialog.boss-live-clean .boss-live-stage>.boss-stage-vitals{width:164px}
 html body dialog.boss-live-clean .boss-stage-vitals>p{width:60px;line-height:9px;font-size:8px;padding:0 2px}
 html body dialog.boss-live-clean .boss-stage-vitals>p span{font-size:8px}
 html body dialog.boss-live-clean .boss-vitals-ring{width:44px;height:44px}
 html body dialog.boss-live-clean .boss-pet-portrait-strip>[data-live-pet-vitals]{height:44px}
 html body dialog.boss-live-clean .boss-pet-portrait-strip .boss-pet-face{width:min(27px,100%)}
 html body dialog.boss-live-clean .boss-pet-portrait-strip [data-live-pet-vitals]>div{margin-top:1px;padding:1px 2px 2px}
 html body dialog.boss-live-clean .boss-pet-portrait-strip small{font-size:7px;line-height:7px}
 html body dialog.boss-live-clean .boss-pet-portrait-strip [role=meter]{height:2px;margin-top:1px}
 html body dialog.boss-live-clean .boss-live-stage>.battle-pad{width:80px;height:80px}
 html body dialog.boss-live-clean .boss-live-stage>.boss-render-mode{left:104px;top:8px;bottom:auto}
}
@container bossBattle (max-height:190px){
 html body dialog.boss-live-clean .boss-stage-vitals>p{font-size:7px;line-height:8px;padding:0 2px}
 html body dialog.boss-live-clean .boss-stage-vitals>p span{font-size:7px}
 html body dialog.boss-live-clean .boss-vitals-ring{width:26px;height:26px}
 html body dialog.boss-live-clean .boss-pet-portrait-strip>[data-live-pet-vitals]{height:32px}
 html body dialog.boss-live-clean .boss-pet-portrait-strip .boss-pet-face{width:min(18px,100%)}
 html body dialog.boss-live-clean .boss-live-stage>.battle-pad{width:64px;height:64px}
}
/* 11-08 MP 不足時技能鈕仍可點（點了問要不要喝／買藥水） */
html body dialog .is-mp-low{opacity:.6}
html body dialog.boss-mp-ask{background:#fffaf0;color:#2a2016;border:2px solid #e8a91c;border-radius:14px;padding:16px 18px;max-width:360px;box-shadow:0 10px 30px rgba(0,0,0,.35)}
html body dialog.boss-mp-ask::backdrop{background:rgba(0,0,0,.35)}
html body dialog.boss-mp-ask p{margin:0 0 12px;white-space:pre-line;font-size:16px;line-height:1.5;color:#2a2016}
html body dialog.boss-mp-ask .boss-mp-ask-row{display:flex;gap:10px;justify-content:flex-end}
html body dialog.boss-mp-ask button{min-height:40px;padding:6px 16px;border-radius:10px;font-weight:700;font-size:15px;border:1px solid #c9b48a}
html body dialog.boss-mp-ask .boss-mp-ok{background:linear-gradient(#ffd75e,#e8a91c);color:#3a2600}
html body dialog.boss-mp-ask .boss-mp-no{background:#f1ede4;color:#3a3226}
/* 11-08 老闆：手機戰鬥中排行榜不往下長，只列前 5 名（440 高以下前 3 名）＋我的排名＋完整排行榜 */
@media(max-height:500px){
 html body dialog.boss-live-clean .boss-stage-rank .boss-live-rank.is-fighting li:nth-child(n+6){display:none}
}
@media(max-height:440px){
 html body dialog.boss-live-clean .boss-stage-rank .boss-live-rank.is-fighting li:nth-child(n+4){display:none}
}
/* 11-08 世界王開場快速進入：淺底深字小卡、10 秒倒數，不捲動 */
html body dialog.wb-quick-join{width:min(440px,calc(100vw - 32px));max-height:calc(100dvh - 24px);box-sizing:border-box;padding:14px;border:2px solid #e3a93a;border-radius:16px;background:#fffaf0;color:#2a1a00;display:none;grid-template-columns:96px 1fr;gap:6px 12px;align-items:center;overflow:hidden;box-shadow:0 12px 32px #0006}
html body dialog.wb-quick-join[open]{display:grid}
html body dialog.wb-quick-join::backdrop{background:#0813228c}
.wb-quick-join>img{width:96px;height:96px;object-fit:cover;border-radius:12px;background:#3a1a08}
.wb-quick-copy b{display:block;font-size:20px;color:#9a3412}
.wb-quick-copy p{margin:4px 0 0;font-size:15px;line-height:1.35}
.wb-quick-count{font-weight:800;color:#0c4a6e}
.wb-quick-count span{display:inline-block;min-width:1.6em;padding:0 4px;border-radius:8px;background:#e0f2fe;text-align:center;font-size:18px}
.wb-quick-join footer{grid-column:1/-1;display:flex;gap:10px;justify-content:flex-end}
.wb-quick-join footer button{min-height:42px;padding:0 18px;border:1px solid #0284c7;border-radius:10px;background:#e0f2fe;color:#0c4a6e;font-size:16px;font-weight:800}
.wb-quick-join footer button.gold{border-color:#b7791f;background:linear-gradient(#ffe08a,#f2b33d);color:#3a2200}
/* 11-08 通用狀態圖示（js/status-badges.js）：只放圖＋角落小數字，點開才看說明；淺底深字 */
.status-badges{display:flex;gap:4px}
.status-badge{position:relative;width:28px;height:28px;padding:0;border:0;background:none;cursor:pointer;flex:none}
.status-badge>img{width:28px;height:28px;display:block;filter:drop-shadow(0 1px 2px #0006)}
.status-badge>small{position:absolute;right:-6px;bottom:-4px;padding:0 3px;border-radius:6px;background:#fffdf5;color:#5a2a00;border:1px solid #e0a83a;font-size:9px;font-weight:900;line-height:12px;white-space:nowrap}
.status-tip{position:absolute;left:0;top:calc(100% + 6px);z-index:20;display:grid;gap:2px;min-width:max-content;padding:6px 9px;border-radius:8px;border:1px solid #e0a83a;background:#fffdf5;color:#3a2410;text-align:left;box-shadow:0 3px 10px #0004;font-size:12px;line-height:1.35}
.status-tip[hidden]{display:none}
.status-tip>b{color:#8a4a00;font-size:12px}
.status-tip>em{font-style:normal;font-weight:700}
/* 11-09 BOSS 技能書入場選盤：只在持有書時出現；淺底深字、選中金色、不捲動 */
.boss-book-loadout{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:6px;margin:8px 0;padding:8px;border:2px solid #e2b85c;border-radius:10px;background:#fffaf0;color:#3a2a12;overflow:hidden}
.boss-book-loadout>strong{grid-column:1/-1;font-size:15px}
.boss-book-loadout label{display:grid;justify-items:center;gap:4px;min-width:0;font-weight:700}
.boss-book-loadout img{width:40px;height:40px;object-fit:contain}
.boss-book-loadout select{width:100%;min-width:0;min-height:40px;border:2px solid #d8b16d;border-radius:8px;background:#fff;color:#2a1f0e;font-weight:700;padding:2px 4px}
.boss-book-loadout select:focus{border-color:#f0b429;background:#fff3cc;outline:none}
.boss-book-loadout>small{grid-column:1/-1;min-height:1em;color:#b4231d;font-weight:700}
dialog:has(.boss-opening-film) .boss-book-loadout{visibility:hidden}
