/* One bottom-right HUD group: auto-hunt above slot 4 of the lowered 4×2 quickbar.
   Auto-potion sliders remain exclusively in the potion item popup. */
.bv-quickslots-stack[hidden],.bv-auto-potions[hidden]{display:none!important}
.bv-combat-controls{--bv-combat-safe-bottom:env(safe-area-inset-bottom);--bv-combat-safe-right:env(safe-area-inset-right);
  position:absolute;right:calc(18px + var(--bv-combat-safe-right));bottom:calc(56px + var(--bv-combat-safe-bottom));
  z-index:6;display:flex;flex-direction:column;align-items:flex-end;gap:8px;pointer-events:none;}
/* The fourth slot center is 32.5px from the right edge (27px on mobile);
   the auto-hunt button is 64px wide (54px on mobile). Right-alignment
   therefore centers the button directly above slot 4 at every viewport size. */
.bv-combat-controls>.auto-hunt-wrap{flex:0 0 auto;align-self:flex-end;pointer-events:auto;}
.bv-quickslots-stack{position:relative;display:flex;flex-direction:column;align-items:stretch;pointer-events:auto;}
html.bv-nekoland .bv-combat-controls{--bv-combat-safe-bottom:var(--bv-neko-safe-bottom);--bv-combat-safe-right:var(--bv-neko-safe-right);}

.bv-quickslots[hidden]{display:none!important}
.bv-quickslots{display:grid;grid-template-columns:repeat(4,49px);grid-template-rows:repeat(2,49px);gap:5px;pointer-events:auto;
  padding:7px;border:1px solid #705738;border-radius:6px;background:linear-gradient(150deg,#1c201bdc,#090d0bea);box-shadow:0 8px 22px #000c,inset 0 1px #cdb37a20}
.bv-quickslot{width:49px;height:49px;min-width:0;position:relative;display:flex;justify-content:center;align-items:center;overflow:hidden;
  border:1px solid #62533b;border-radius:3px;padding:1px;background:linear-gradient(145deg,#2b2a21,#121612);color:#ead7b0;touch-action:manipulation}
.bv-quickslot.is-filled{border-color:#b49661}
.bv-quickslot:not(:disabled):hover{border-color:#ecc58c;box-shadow:0 0 9px #aa8c5b75}
.bv-quickslot:disabled{cursor:default}
.bv-quickslot.is-skill-pending .bv-quickslot-icon{filter:grayscale(.35) brightness(.72)}
.bv-quickslot.is-skill-pending .bv-quickslot-seconds{font-size:11px;color:#f3d399}
.bv-quickslot.is-cooldown .bv-quickslot-seconds{color:#fff3d0;z-index:1}
.bv-quickslot.is-empty-stock .bv-quickslot-icon{filter:grayscale(1) brightness(.45)}
.bv-quickslot-icon{width:95%;height:95%;object-fit:contain;pointer-events:none;filter:drop-shadow(0 0 5px #be9f4e3c)}
.bv-quickslot-shade{position:absolute;bottom:0;left:0;right:0;background:#050707ad;pointer-events:none}
.bv-quickslot-key{position:absolute;top:0;left:2px;font:600 10px/1.4 'Cinzel',Georgia,serif;color:#d6c298;text-shadow:1px 1px 3px #000}
.bv-quickslot-qty{position:absolute;right:3px;bottom:1px;font:700 11px/1.2 var(--bv-font-ui);color:#f7e1b0;text-shadow:0 1px 3px #000,0 0 4px #000}
.bv-quickslot-seconds{position:absolute;left:0;right:0;top:50%;transform:translateY(-50%);font:700 14px/1 var(--bv-font-ui);text-align:center;text-shadow:0 1px 4px #000,0 -1px 4px #000}
.bv-quickslot:focus-visible{outline:2px solid #f3ca89;outline-offset:2px}
.bv-potion-bind-title{font:600 11px var(--bv-font-ui);color:#d8b985;flex-basis:100%}
.bv-potion-bind-choice{flex:0 0 34px!important;min-width:34px!important;min-height:33px;border:1px solid #856e48;background:#241d14;color:#ebd5ac;border-radius:3px}
.bv-potion-bind-choice:hover{background:#44361f}
.bv-potion-bind-choice.is-registered{border-color:#c9b270;color:#f6e7b4;background:#405039;box-shadow:inset 0 0 0 1px #8eab71}
@media(max-width:650px){.bv-combat-controls{right:calc(9px + var(--bv-combat-safe-right));bottom:calc(125px + var(--bv-combat-safe-bottom))}.bv-quickslots{
 grid-template-columns:repeat(4,42px);grid-template-rows:repeat(2,42px);gap:3px;padding:5px}.bv-quickslot{width:42px;height:42px}.bv-quickslot-key{font-size:9px}}

.bv-auto-potions{padding:7px 9px 8px;border:1px solid #705738;border-radius:5px;
  background:linear-gradient(150deg,#1b1e19ed,#0a0d0aed);color:#e4d2ad;
  box-shadow:0 5px 14px #000b;display:flex;flex-direction:column;gap:5px;}
.bv-auto-potion-heading{font:600 9px/1.3 var(--bv-font-ui);letter-spacing:.01em;color:#c5aa78;text-align:center;}
.bv-auto-potion-row{display:flex;align-items:center;gap:7px;min-height:22px;}
.bv-auto-potion-label{width:21px;font:700 11px/1 var(--bv-font-ui);color:#d6c69b;}
.bv-auto-potion-slider{flex:1;min-width:0;max-width:160px;height:18px;accent-color:#ad7956;cursor:pointer;touch-action:none;}
.bv-auto-potion-row:first-of-type .bv-auto-potion-slider{accent-color:#b45e55;}
.bv-auto-potion-value{width:39px;text-align:right;font:700 11px/1 var(--bv-font-ui);font-variant-numeric:tabular-nums;color:#f1d8ae;}
.bv-auto-potion-slider:disabled{opacity:.4;cursor:not-allowed;}
/* Align auto thresholds beneath the potion popup's eight quickslot registration buttons. */
.bv-auto-potions-popup{box-sizing:border-box;width:100%;max-width:100%;margin-top:12px;padding:10px 12px 11px;
  background:linear-gradient(150deg,#1b1e19,#10140f);}
.bv-auto-potions-popup .bv-auto-potion-heading{font-size:10px;text-align:left;margin-bottom:3px;}
.bv-auto-potions-popup .bv-auto-potion-row{min-height:28px;gap:10px;}
.bv-auto-potions-popup .bv-auto-potion-label{width:24px;}
.bv-auto-potions-popup .bv-auto-potion-slider{max-width:none;width:100%;}
@media(max-width:650px){.bv-auto-potions-popup{padding:8px 9px;gap:5px}.bv-auto-potions-popup .bv-auto-potion-heading{font-size:9px}
  .bv-auto-potions-popup .bv-auto-potion-slider{max-width:none}.bv-auto-potions-popup .bv-auto-potion-row{min-height:26px}}
/* The bottom inset reserves the mobile attack/run area; scaling applies to both HUD controls together. */
@media (pointer:coarse) and (min-width:651px){.bv-combat-controls{bottom:calc(143px + var(--bv-combat-safe-bottom))}}
@media (max-height:560px){.bv-combat-controls{bottom:calc(72px + var(--bv-combat-safe-bottom));transform:scale(.88);transform-origin:bottom right}}
@media (max-height:560px) and (max-width:780px), (max-height:560px) and (pointer:coarse){
  .bv-combat-controls{bottom:calc(139px + var(--bv-combat-safe-bottom));transform:scale(.82);transform-origin:bottom right}}
@media (max-height:420px){.bv-combat-controls{bottom:calc(102px + var(--bv-combat-safe-bottom));transform:scale(.78);transform-origin:bottom right}}
