/* Use the available screen for the room, not for page-level game headings. */
.ward-ux-page .rpg-shell{width:100%!important;max-width:1760px!important;--ward-stage-height:calc(100dvh - 128px)}
.ward-ux-page .rpg-stage{height:var(--ward-stage-height);border-radius:14px}
.ward-ux-page .rpg-hud-content{display:contents}
.ward-ux-page .rpg-hud .rpg-patient-head{align-items:center}
.ward-ux-page .rpg-hud>.rpg-register-cta{position:static;display:flex;align-items:center;justify-content:center;gap:6px;grid-column:1/-1;max-width:none;width:100%;min-height:29px;margin:8px 0 0;padding:6px 0 0;border:0;border-top:1px solid #9ac7b539;border-radius:0;background:none;color:var(--u-mint);font-size:11px;font-weight:600;line-height:1.3;text-align:center}
.ward-ux-page .rpg-hud>.rpg-register-cta:hover{background:#9de8ce0b;color:#c6f7e5}
.ward-ux-page .rpg-register-cta>svg{display:block;flex:none;width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.ward-ux-page .rpg-stage-tools{position:absolute;top:10px;right:12px;z-index:30;display:flex;align-items:center;gap:4px;padding:3px;border:1px solid #8d957864;border-radius:9px;background:linear-gradient(145deg,#28312cef,#0d171fed);box-shadow:inset 0 0 0 1px #0007,0 3px 9px #0005}
.ward-ux-page .rpg-stage-tools .rpg-utility{display:grid;place-items:center;min-height:34px;width:34px;height:34px;border:1px solid #94a08250;border-radius:6px;background:radial-gradient(circle at 35% 25%,#4651448c,#15211b);color:#d5dbc8;box-shadow:inset 0 1px #dde9cb12;line-height:0!important}
.ward-ux-page .rpg-stage-tools .rpg-utility:hover{border-color:#d8c383;background:#35473a}
.ward-ux-page .rpg-stage-tools .rpg-utility[aria-pressed=true]{border-color:#c4b976;color:#f1d894;background:#42513b}
.ward-ux-page .rpg-stage-tools .rpg-utility>svg{width:18px;height:18px}
.ward-ux-page .rpg-stage:not([data-mode=battle]) .rpg-commands{left:50%;right:auto;width:min(760px,calc(100% - 36px));transform:translateX(-50%)}
.ward-ux-page .rpg-overlay[data-panel=profile]{top:73px;bottom:auto;height:min(620px,calc(100% - 176px))}
/* A side drawer keeps the hero anchored and leaves the home action row uncovered. */
.ward-ux-page .rpg-overlay[data-panel=inventory]{top:73px;bottom:168px;height:auto;max-height:none}
.ward-ux-page .rpg-stage[data-view=inventory]:not([data-mode=battle]) .rpg-commands{visibility:visible}
.ward-ux-page .rpg-shell:fullscreen{width:100vw!important;max-width:none!important;height:100dvh;padding:0;display:block;overflow:hidden;background:#080f19}
.ward-ux-page .rpg-shell:fullscreen .rpg-stage{width:100%;height:100dvh;max-width:none;border-radius:0;border:0}
@media(min-width:701px){
 .ward-ux-page .rpg-hud{width:210px;padding:12px}
 .ward-ux-page .rpg-patient-head strong{font-size:15px}
 .ward-ux-page .rpg-resource>div:first-child,.ward-ux-page .rpg-resource strong{font-size:13px}
 .ward-ux-page .rpg-stage[data-mode=home] .rpg-player{height:clamp(350px,calc(var(--ward-stage-height)*.63),600px);bottom:158px}
 .ward-ux-page .rpg-stage:not([data-mode=home]) .rpg-player{height:clamp(300px,calc(var(--ward-stage-height)*.5),490px)}
 .ward-ux-page .rpg-stage .rpg-enemy{height:clamp(170px,calc(var(--ward-stage-height) - 400px),490px)}
 .ward-ux-page .rpg-stage #rpg-wallet{top:clamp(150px,calc(var(--ward-stage-height)*.27),260px);width:200px;padding:13px}
 .ward-ux-page .rpg-nav:has([data-panel=shop]){left:50%;right:auto;transform:translateX(-50%);max-width:calc(100% - 350px)}
 .ward-ux-page .rpg-stage[data-view=profile] .rpg-player{height:clamp(350px,calc(var(--ward-stage-height)*.58),560px);bottom:114px;left:40%}
}
@media(min-width:701px) and (max-width:1100px){
 .ward-ux-page .rpg-hud{width:190px;padding:10px}
 .ward-ux-page .rpg-nav:has([data-panel=shop]){left:215px;right:104px;max-width:none;transform:none;justify-content:center;gap:3px}
 .ward-ux-page .rpg-nav:has([data-panel=shop]) .rpg-nav-button{min-width:34px;width:34px;flex-basis:34px;height:36px;min-height:36px;padding:3px}
 .ward-ux-page .rpg-nav .rpg-nav-button>.rpg-art{width:26px;height:26px}
 .ward-ux-page .rpg-stage[data-view=profile] .rpg-player{left:29%;height:350px}
}
@media(min-width:1280px){
 /* The home doll is 2:3: reserve half its width plus 12px on each side of the drawer. */
 .ward-ux-page .rpg-stage[data-mode=home] .rpg-overlay[data-panel=inventory]{width:min(440px,calc(50% - clamp(116.667px,calc(var(--ward-stage-height)*.21),200px) - 24px))}
}
@media(max-width:700px){
 .ward-ux-page .rpg-stage{height:810px}
 .ward-ux-page .rpg-stage-tools{top:10px;right:8px;padding:2px;gap:3px}
 .ward-ux-page .rpg-stage-tools .rpg-utility{width:29px;height:30px;min-height:30px}
 .ward-ux-page .rpg-stage-tools .rpg-utility>svg{width:16px;height:16px}
 .ward-ux-page .rpg-nav:has([data-panel=shop]){left:8px;right:86px;top:10px;max-width:none;justify-content:flex-start;gap:4px;padding:2px;overflow-x:auto;overflow-y:hidden;scrollbar-width:none;scroll-padding:2px}
 .ward-ux-page .rpg-nav:has([data-panel=shop]) .rpg-nav-button{min-width:34px;flex-basis:34px;width:34px;height:34px;min-height:34px;padding:2px}
 .ward-ux-page .rpg-nav .rpg-nav-button>.rpg-art{width:26px;height:26px}
 .ward-ux-page .rpg-nav .rpg-nav-button::after{display:none}
 .ward-ux-page .rpg-hud>.rpg-register-cta{min-height:26px;font-size:11px;margin-top:5px;padding-top:5px}
 .ward-ux-page .rpg-stage:not([data-mode=battle]) .rpg-commands{width:calc(100% - 20px)}
 .ward-ux-page .rpg-overlay[data-panel=inventory]{top:252px;bottom:168px;height:auto}
 .ward-ux-page .rpg-overlay[data-panel=profile]{top:252px;bottom:103px;height:auto}
}
