/* UI4_6: one action row. No independent backdrop or sidebar. */
.app:has(#battle:not([hidden]))>.bar{display:none!important}
#battle:not([hidden]){grid-template-rows:auto auto auto minmax(0,1fr) auto!important}
#battle .battlebar{grid-row:1;flex-wrap:nowrap!important;justify-content:center;gap:clamp(2px,.45vw,8px)!important;padding:4px 6px 2px!important;min-width:0}
#battle .battlebar .stat{flex:0 0 auto;min-width:0;max-width:none!important;white-space:nowrap;font-size:clamp(10px,1.15vw,15px);padding:4px 7px;line-height:1.2}
#battle .battlebar #stageLabel{flex:0 1 auto;overflow:hidden;text-overflow:ellipsis;display:block;max-width:40%!important}
#battle .battlebar #stageLabel .ui-icon{vertical-align:middle}
#battle .battlebar .hpbar.asset-gauge{width:clamp(34px,7vw,100px)}
#battle .controls{grid-row:2;display:flex!important;flex-wrap:nowrap!important;align-items:center;justify-content:center;gap:clamp(3px,.55vw,9px)!important;width:min(100%,980px);padding:1px 6px 2px!important;position:relative;z-index:8;min-width:0}
#battle .controls>button{flex:0 1 auto;min-width:0!important;min-height:clamp(34px,5.4dvh,48px)!important;padding:6px clamp(12px,1.8vw,23px)!important;white-space:nowrap!important;line-height:1.15;font-size:clamp(11px,1.4vw,15px)!important;color:#fff8df!important;text-shadow:0 1px 2px #173b37;background:var(--reg-secondary) center/100% 100% no-repeat!important}
#battle .controls>#start,#battle .controls>#special{background-image:var(--reg-primary)!important;min-width:clamp(104px,15vw,172px)!important;padding-inline:clamp(18px,2.6vw,31px)!important;text-shadow:0 1px 2px #48290e;}
#battle .controls>#speed{min-width:48px!important;font-variant-numeric:tabular-nums}
#battle .controls>button[aria-pressed=true],#battle .controls>#battleMenuToggle[aria-expanded=true]{background-image:var(--reg-tab)!important;color:#392309!important;text-shadow:none;outline:0}
#battle #battleHint{grid-row:3;grid-column:1;align-self:start;justify-self:center;z-index:2;pointer-events:none;display:block;text-align:center;margin:0 6px;padding:0;min-width:0;max-width:calc(100% - 12px);color:#fff9e4;font-size:clamp(10px,1.15vw,14px);font-weight:800;line-height:1.2;text-shadow:0 1px 2px #241b0f,0 0 4px #241b0f,0 0 7px #241b0f}
#battle #battleSpace{grid-row:4}#battle .battle-roster{grid-row:5}
#battle #battleMenu{position:absolute;top:100%;left:50%;transform:translateX(-50%);width:min(calc(100% - 12px),410px);max-height:min(54dvh,320px);overflow:auto;pointer-events:auto;z-index:10;padding:12px 15px;background:#fff0d8;border:2px solid #bd9451;border-radius:10px;box-shadow:0 4px 12px #59482d50;color:#3a3023}
#battle .battle-menu-options{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px}
#battle #battleMenu button{min-width:0;min-height:36px;padding:5px 12px;white-space:normal;color:#fff7dc;background:var(--reg-secondary) center/100% 100% no-repeat;text-shadow:0 1px 2px #143432;font-size:12px;line-height:1.2}
#battle #battleMenu #autoSpecial[aria-pressed=true]{background-image:var(--reg-tab);color:#392309;text-shadow:none}
#battle #battleMenu #roleFilterBar{margin-top:6px;flex-wrap:wrap;color:#443522;text-shadow:none;justify-content:center}
#battle #battleMenu #roleFilterStatus{color:#443522;text-shadow:none;white-space:normal}
@media(max-width:720px){#battle .battlebar .stat{font-size:10px;padding:3px 4px}#battle .battlebar .hpbar.asset-gauge{width:40px}#battle .battlebar .ui-icon{width:13px;height:13px;margin:0 2px 0 0}#battle .controls>button{font-size:11px!important;padding:5px 10px!important}#battle .controls>#start,#battle .controls>#special{min-width:108px!important;padding-inline:16px!important}#battle .controls>#speed{min-width:39px!important}}
@media(max-width:510px){#battle .controls>button{font-size:10px!important;padding:5px 8px!important}#battle .controls>#start,#battle .controls>#special{min-width:90px!important;padding-inline:12px!important}#battle .battlebar .stat{font-size:9px;padding:2px 3px}#battle .battlebar .hpbar.asset-gauge{width:29px}#battle .battlebar .ui-icon{width:11px;height:11px}}
