/* The backpack's original PC frame is the complete window. */
dialog.inventory-window{width:299px;max-width:calc(100vw - 16px);max-height:calc(100dvh - 135px);padding:0;border:0;border-radius:0;background:transparent;box-shadow:none;overflow:visible;top:110px;right:18px}
.inventory-window .dialog-top{position:absolute;inset:0 0 auto;height:38px;padding:0;background:none;border:0;pointer-events:none;z-index:2}
.inventory-window .dialog-top>div{display:none}
.inventory-window .dialog-top>button{position:absolute;right:14px;top:9px;width:24px;height:24px;padding:0;line-height:20px;border:2px solid #3196ad;border-radius:50%;color:#523a1e;background:radial-gradient(circle,#ffebbd,#cfac70);pointer-events:auto;font-size:19px}
.inventory-window #modal-body{padding:0;overflow:auto;max-height:calc(100dvh - 135px);border-radius:18px;scrollbar-width:thin}
.inventory-window .pc-inventory{display:block}
.inventory-window .pc-bag{margin:0;width:299px;height:426px}
.inventory-window .pc-bag-title{font-weight:400}
.inventory-window .pc-bag-count{display:none}
.inventory-window .pc-bag-grid .pc-slot{width:38px;height:38px}
.floating-item-tooltip{position:fixed;z-index:30;display:flex;flex-direction:column;align-items:stretch;gap:7px;width:max-content;max-width:min(290px,calc(100vw - 16px));min-height:0;margin:0;padding:14px 16px;border:2px solid #cfb54b;border-radius:3px;background:linear-gradient(120deg,#8b6c2ae8,#97763ae8);box-shadow:inset 0 0 0 1px #f2d96f,0 3px 14px #0005;color:#fff9df}
.floating-item-tooltip>.item-icon{display:none}
.floating-item-tooltip strong{font-size:17px;font-weight:400;color:#fffbe7;line-height:1.4}
.floating-item-tooltip small{font-size:14px;line-height:1.6;color:#fff3d7}
.floating-item-tooltip .requirement{color:#ffb46a}
.floating-item-tooltip button{align-self:start;font-size:13px;color:#fff6d5;background:#795c2d;border-color:#d9b567;padding:6px 12px}
dialog.character-window{width:290px;max-height:calc(100dvh - 140px);top:110px}
.character-window #modal-body{padding:12px}
.character-window .pc-inventory{display:block}
.character-window .pc-character-stats{display:grid}
@media(max-width:700px){dialog.inventory-window{top:120px;right:8px;width:299px;max-height:calc(100dvh - 130px)}.inventory-window #modal-body{padding:0;max-height:calc(100dvh - 130px)}dialog.character-window{top:120px;right:8px;max-height:calc(100dvh - 130px)}.floating-item-tooltip{max-width:min(240px,calc(100vw - 16px));padding:10px 12px}.floating-item-tooltip strong{font-size:15px}.floating-item-tooltip small{font-size:12px}.character-window .pc-character-stats{display:grid}}

/* Character window uses the original cyan/gold PC panel, like the backpack. */
dialog.character-window{width:299px;padding:0;border:0;border-radius:17px;background:transparent url('../assets/ui/bag-frame.png') center/100% 100% no-repeat;box-shadow:none;color:#493619;overflow:auto;scrollbar-width:thin}
.character-window .dialog-top{position:relative;padding:0;height:43px;background:none;border:0}
.character-window .dialog-top>div{position:absolute;left:54px;right:50px;top:8px;text-align:center}
.character-window .dialog-top small{display:none}
.character-window .dialog-top h2{margin:0;font-size:16px;line-height:24px;font-weight:400;color:#5c3e1d;text-shadow:0 1px #f5deb0}
.character-window .dialog-top>button{position:absolute;right:14px;top:9px;width:24px;height:24px;padding:0;line-height:20px;border:2px solid #3196ad;border-radius:50%;color:#523a1e;background:radial-gradient(circle,#ffebbd,#cfac70);font-size:19px}
.character-window #modal-body{padding:0 22px 20px}
.character-window .pc-character-name{margin:6px 0 8px;padding:5px 0;color:#fff1c8;background:linear-gradient(#99753099,#7a592977);border:1px solid #c7ac66;border-radius:6px;font-weight:400;font-size:12px;text-shadow:0 1px #523a1e}
.character-window .pc-character-stats{margin:10px 3px 0;padding:7px 8px;background:#987b42ed;border:1px solid #d0b157;border-radius:3px}
.character-window .pc-turns button{color:#fff0b0;border-color:#b99c57;background:#795b2cc9}
.character-window .pc-character-stats>div{border-bottom-color:#73552033}
.character-window .pc-character-stats span{color:#fff0b6}
.character-window .pc-character-stats strong{color:#5cfa25;text-shadow:0 1px #5c542c;font-weight:400}

/* Three vertical PC-style character categories, kept inside the viewport. */
dialog.character-window{width:333px;max-width:calc(100vw - 16px);background-position:right center;background-size:calc(100% - 34px) 100%;border-radius:0}
.character-window .dialog-top{margin-left:34px}
.character-window #modal-body{position:relative;margin-left:34px;overflow:visible}
.pc-character-tabs{position:absolute;left:-34px;top:25px;width:36px;display:flex;flex-direction:column;gap:3px;z-index:2}
.pc-character-tabs button{width:36px;height:85px;padding:6px 8px;border:2px solid #3fc7e5;border-right-color:#0a566d;border-radius:7px 0 0 7px;background:linear-gradient(90deg,#087ca7,#20c0e8 45%,#1689b6);box-shadow:inset 0 0 0 1px #7ad9ea,1px 2px 3px #10272e80;color:#fff3b1;text-shadow:0 1px #295461;writing-mode:vertical-rl;text-orientation:mixed;font-size:13px;letter-spacing:0;line-height:16px;white-space:nowrap}
.pc-character-tabs button.selected{border-color:#efc987;border-right-color:#b18a48;background:linear-gradient(90deg,#b98137,#ecc98a 48%,#c59650);color:#fff8d4;text-shadow:0 1px #91682c}
.pc-character-tabs button:focus-visible{outline:2px solid #fff2ad;outline-offset:2px}
.pc-character-tab-note{text-align:center;color:#fff2bd;font-size:12px;margin:6px 0}

.character-window .pc-artifact{background:none;display:flex;flex-direction:column;height:292px;gap:4px;border:0}
.pc-artifact>img{width:252px;height:246px;object-fit:contain}
.pc-artifact-actions{display:flex;justify-content:space-between;gap:2px}.pc-artifact-actions button{padding:3px 4px;font-size:10px;color:#fff2b0;background:linear-gradient(#886625,#be983b);border:1px solid #e2c360;border-radius:10px}.pc-artifact-actions button:disabled{opacity:.65}
