/* Complete original NewInventory.dat panel; live controls occupy native pixels. */
body #inventory{position:fixed;inset:16px 16px auto auto;width:493.5px;height:538.5px;max-width:none;max-height:none;display:block;overflow:visible;padding:0;margin:0;flex:none;z-index:15;background:transparent;border:0;border-image:none;border-radius:0;box-shadow:none;color:#e2d5b6}
body #inventory[hidden]{display:none}
#inventory .inventory-surface{position:relative;width:329px;height:359px;transform:scale(var(--inventory-scale,1.5));transform-origin:top left;background:url('../inventory-ui/panel-clean-textless-no-underline.png') 0 0/329px 359px no-repeat}
#inventory[data-sex=male] .inventory-surface:before{content:'';position:absolute;left:132px;top:46px;width:177px;height:147px;background:url('../inventory-ui/male-figure.png') no-repeat;pointer-events:none}
body #inventory .panel-heading,body #inventory .inventory-layout,body #inventory .inventory-content{position:static;display:block;padding:0;margin:0;border:0;background:none;min-height:0}
body #inventory .panel-heading h2,body #inventory .character-summary{display:none}
body #inventory .equipment-stage{position:static;min-height:0;margin:0;padding:0;border:0;background:none;box-shadow:none}
#inventory .equipment-stage:before{display:none}
#inventory #equipment-slots{position:absolute;inset:0;display:block;pointer-events:none}
#inventory .equipment-slot{position:absolute;inset:auto!important;width:40px;height:40px;pointer-events:auto}
#inventory .equipment-slot.slot-ring1{left:29px!important;top:68px!important;width:37px;height:37px}
#inventory .equipment-slot.slot-ring2{left:65px!important;top:68px!important;width:37px;height:37px}
#inventory .equipment-slot.slot-necklace{left:23px!important;top:126px!important;width:37px;height:37px}
#inventory .equipment-slot.slot-boots{left:71px!important;top:126px!important;width:37px;height:37px}
#inventory .equipment-slot.slot-weapon{left:153px!important;top:64px!important}
#inventory .equipment-slot.slot-helmet{left:257px!important;top:65px!important}
#inventory .equipment-slot.slot-chest{left:210px!important;top:108px!important}
#inventory .equipment-slot.slot-shield{left:258px!important;top:150px!important}
/* Dedicated Symbol quick[5] cell; mantles use the neck cell. */
#inventory .equipment-slot.slot-symbol{left:154px!important;top:153px!important;width:35px;height:35px;background:url('../inventory-ui/extra-slot.png') no-repeat}
#inventory .slot-symbol{cursor:help}
#inventory .slot-symbol:focus-visible{outline:1px solid #ffe2a0}
#inventory .slot-symbol:is(:hover,:focus-within){z-index:30}
#inventory .slot-symbol .symbol-slot-bonuses{visibility:hidden}
#inventory .slot-symbol:is(:hover,:focus-within) .symbol-slot-bonuses{visibility:visible}
#inventory .symbol-slot-bonuses{position:absolute;right:-30px;top:35px;width:210px;padding:8px;box-sizing:border-box;background:#161510;border:1px solid #b29b6a;color:#f5e9cd;font:11px/1.5 Tahoma,sans-serif;box-shadow:0 3px 10px #000b;max-height:190px;overflow:auto;user-select:text}
#inventory .symbol-slot-bonuses p{margin:0 0 5px;overflow-wrap:anywhere}
body #inventory .item-cell{position:relative;width:100%;height:100%;min-width:0;min-height:0;margin:0;padding:1px;display:flex;align-items:center;justify-content:center;border:0;border-radius:0;background:none;box-shadow:none;transition:none;cursor:pointer}
body #inventory .item-cell.equipped{background:transparent}
body #inventory .item-cell:hover:not(:disabled){background:#e4cd9020;box-shadow:inset 0 0 0 1px #dcc58e}
body #inventory .item-cell.selected{outline:1px solid #ead597;outline-offset:-2px;background:#e4cd9018;box-shadow:none}
body #inventory .item-cell:focus-visible{outline:1px solid #ffe2a0;outline-offset:-2px}
#inventory .slot-name,#inventory .empty-slot-mark{display:none}
#inventory .real-icon{max-width:32px;max-height:32px;transform:none;image-rendering:pixelated}
#inventory .two-hand-reserved .real-icon{opacity:.35}
body #inventory #item-grid{position:absolute;left:23px;top:204px;width:280px;height:105px;display:grid;grid-template-columns:repeat(8,35px);grid-template-rows:repeat(3,35px);gap:0;padding:0;border:0;background:none;box-shadow:none}
body #inventory #item-grid .item-cell{width:35px;height:35px}
body #inventory .section-caption,body #inventory #grid-caption{position:static;margin:0;padding:0;border:0;display:block}
body #inventory #bag-count{position:absolute;left:23px;top:312px;width:280px;text-align:right;font:7px/9px Tahoma;color:#ddcda4;white-space:nowrap}
/* The Weight section is removed; the underlying item-weight calculation remains live. */
#inventory #inventory-weight{display:none}
body #inventory #close-bag,body #inventory #inventory-spell,body #inventory #grid-caption button{position:absolute;min-height:0;min-width:0;margin:0;padding:0;border:0;border-radius:0;box-shadow:none;background-color:transparent;background-size:100% 100%;font-size:0;cursor:pointer;transition:none}
/* Cover the entire baked button, including its old edge, with one continuous frame. */
body #inventory :is(#close-bag,#inventory-spell){top:323px;width:72px;height:26px;box-sizing:border-box;border:1px solid;border-color:#e0cda6 #ab9270 #aa916e #d2bc94;background:linear-gradient(135deg,#8b7a60,#74634f);box-shadow:inset 1px 1px 0 #bca883,inset -1px -1px 0 #65543f;transform:none;filter:none;transition:background .12s,color .12s}
body #inventory #close-bag{left:244px}
body #inventory #inventory-spell{left:13px}
body #inventory :is(#close-bag,#inventory-spell):hover{background:linear-gradient(135deg,#9b896b,#827056);border-color:#f0dfb8 #c2a780 #bca17a #e5cea3;box-shadow:inset 1px 1px 0 #cbb78e,inset -1px -1px 0 #756047;transform:none;filter:none}
body #inventory :is(#close-bag,#inventory-spell):active{background:linear-gradient(135deg,#74634e,#817058);border-color:#b9a17c #d4bc92 #d4bc92 #b9a17c;box-shadow:inset 1px 1px 0 #65533e,inset -1px -1px 0 #ab9471;transform:none;filter:none}
body #inventory #grid-caption button{top:324px;width:35px;height:23px}
body #inventory #bag-prev{left:132px;background-image:url('../inventory-ui/up.png')}
body #inventory #bag-next{left:168px;background-image:url('../inventory-ui/down.png')}
body #inventory #bag-prev:hover:enabled{background-image:url('../inventory-ui/up-hover.png')}
body #inventory #bag-next:hover:enabled{background-image:url('../inventory-ui/down-hover.png')}
body #inventory #bag-prev:active:enabled{background-image:url('../inventory-ui/up-pressed.png')}
body #inventory #bag-next:active:enabled{background-image:url('../inventory-ui/down-pressed.png')}
body #inventory #grid-caption button:disabled{opacity:1;filter:grayscale(1) brightness(.45);cursor:default}
body #inventory :is(#close-bag,#inventory-spell,#bag-prev,#bag-next):focus-visible{outline:1px solid #ffe2a0;outline-offset:-2px}
body #item-hover{position:fixed;inset:auto;z-index:51;width:312px;max-width:calc(100vw - 16px);max-height:calc(100dvh - 16px);overflow:auto;margin:0;min-height:0;pointer-events:none}
body #item-hover[hidden]{display:none}
body #item-hover .potion-box-exchange-actions{pointer-events:auto;margin-top:8px}
body #item-hover .potion-box-exchange-actions button{padding:6px 10px;color:#f5ead0;background:#302a20;border:1px solid #a39470;cursor:pointer}
/* Bag drag & drop: the ghost follows the pointer; drop targets glow; the world shows a drop cursor. */
body #inventory .item-cell[data-key]:not([data-key=""]){touch-action:none}
.item-drag-ghost{position:fixed;left:0;top:0;z-index:9999;pointer-events:none;margin:-18px 0 0 -18px;width:36px;height:36px;display:flex;align-items:center;justify-content:center;opacity:.85;filter:drop-shadow(0 2px 3px #000a)}
body.item-dragging,body.item-dragging *{cursor:grabbing!important}
body #inventory .item-cell.drag-over,body [data-quick].drag-over{background:#e4cd9030;box-shadow:inset 0 0 0 1px #ffe2a0}
body #inventory .drag-over:is(#bag-prev,#bag-next){filter:brightness(1.4)}
.inventory-label{position:absolute;display:block;color:#f5ead0;text-shadow:1px 1px #17130d;font:12px/17px Tahoma,sans-serif;text-align:center;pointer-events:none}
.inventory-title{left:78px;top:10px;width:171px;font-size:20px;line-height:26px}
.inventory-unique{left:20px;top:48px;width:93px}
.inventory-neck{left:15px;top:109px;width:50px;font-size:8px;line-height:17px;white-space:nowrap}
.inventory-shoes{left:65px;top:109px;width:49px;font-size:10px}
body #inventory :is(#close-bag,#inventory-spell){font:13px/25px Tahoma,sans-serif;color:#f5ead0;text-shadow:1px 1px #17130d}

#inventory .inventory-symbol-text{display:flex;align-items:center;justify-content:center;height:100%;font:9px Tahoma;color:#e2d5b6}
#inventory .inventory-symbol-text{position:relative}#inventory .inventory-symbol-text img{max-width:32px;max-height:32px;image-rendering:pixelated}#inventory .inventory-symbol-text>span{position:absolute;right:1px;bottom:0;font:8px Tahoma;text-shadow:1px 1px #000}
