/* =========================================================
   v8.1 介面重製層
   =========================================================
   章節選擇／關卡地圖／儲藏庫／基地／選單／設定／說明／信箱 的新版面。
   載在 polish.css 之後；拿掉 index.html 那一行就會看到**沒有樣式的新 DOM**（不是回到舊版），
   因為這幾個畫面的 DOM 本身也換掉了。

   設計語彙沿用全站：Minecraft 像素方鈕（灰面＋4px 黑框＋內嵌斜角＋硬底陰影）、
   木紋橫條、奶油色面板、厚黑描邊的白字，圖示一律用 .pxi 像素圖示。
   ========================================================= */

/* ---------- 共用零件 ---------- */
/* 像素方鈕：跟 screens.css 末段那套全站按鈕一模一樣的外觀，給這一層新增的按鈕用
   （那套是用 class 清單 + !important 套上去的，新按鈕不想再往清單裡塞，所以另開一個 class） */
.px-btn{
  --f1:#d4d4d4; --f2:#b8b8b8; --hi:#efefef; --lo:#8a8a8a;
  background:linear-gradient(var(--f1),var(--f2));border:4px solid #000;border-radius:0;
  box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo),0 4px 0 #00000055;
  color:#1c1c1c;text-shadow:0 1px 0 #ffffff88;font-weight:900;font-family:inherit;cursor:pointer;
}
.px-btn:hover:not(:disabled){filter:brightness(1.07)}
.px-btn:active:not(:disabled){transform:translateY(3px);box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo)}
.px-btn.gold{--f1:#ffd98a; --f2:#f0b429; --hi:#fff3c4; --lo:#a9761a}
.px-btn.green{--f1:#c3f293; --f2:#77c72e; --hi:#e3ffcb; --lo:#4c8a15}
.px-btn.blue{--f1:#bcd8f5; --f2:#5f8cc4; --hi:#e2f0ff; --lo:#365f8f}
.px-btn.purple{--f1:#d2a9f5; --f2:#8b47cf; --hi:#efdcff; --lo:#5a2a91; color:#fff; text-shadow:0 2px 0 #00000066}
.px-btn.red{--f1:#f0a09b; --f2:#c2372f; --hi:#ffd0cc; --lo:#7d1f19; color:#fff; text-shadow:0 2px 0 #00000066}
.px-btn:disabled{--f1:#b9b9b9; --f2:#9a9a9a; --hi:#cfcfcf; --lo:#6f6f6f; color:#383838; text-shadow:none; cursor:not-allowed}
.px-btn .pxi{width:1.25em;height:1.25em;vertical-align:-.28em}
/* 厚黑描邊白字（標題畫面那種） */
.px-out{color:#fff;filter:drop-shadow(2px 0 0 #000) drop-shadow(-2px 0 0 #000) drop-shadow(0 2px 0 #000) drop-shadow(0 -2px 0 #000)}

/* =========================================================
   章節／模式選擇
   ========================================================= */
#scr-chapter::before{display:none}               /* 舊版底部那條白色雲霧：在 Minecraft 背景上像一層霧，拿掉 */
#scr-chapter .ch-screen-title{
  top:16px;font-size:27px;letter-spacing:6px;line-height:1;text-shadow:none;
  filter:drop-shadow(3px 0 0 #000) drop-shadow(-3px 0 0 #000) drop-shadow(0 3px 0 #000) drop-shadow(0 -3px 0 #000) drop-shadow(0 5px 0 #00000055);
}
.chx-crumb{font-size:15px;letter-spacing:2px;color:#ffe27a;margin-right:10px;vertical-align:4px}

.chx-stage{position:absolute;left:0;right:0;top:56px;height:372px;z-index:2;
  display:flex;align-items:center;justify-content:center;gap:8px;padding:0 12px}
.chx-rail{display:flex;align-items:center;gap:24px;overflow-x:auto;overflow-y:hidden;max-width:832px;
  padding:38px 16px 22px;scroll-behavior:smooth;scrollbar-width:none}
.chx-rail::-webkit-scrollbar{display:none}
.chx-arrow{flex:0 0 auto;width:42px;height:62px;padding:0;font-size:18px}
.chx-arrow:disabled{opacity:.35}

.chx-card{position:relative;flex:0 0 auto;width:232px;height:300px;padding:0;cursor:pointer;
  border:4px solid #000;background:#1d1a2e;color:#fff;font-family:inherit;text-align:center;
  box-shadow:inset 0 0 0 2px #ffffff2e,0 6px 0 #0000008c,0 14px 26px #0007;
  transform:scale(.93);filter:brightness(.74) saturate(.85);
  transition:transform .18s cubic-bezier(.2,1.4,.4,1),filter .18s,box-shadow .18s;
  animation:chx-in .42s cubic-bezier(.2,1.3,.4,1) var(--d,0s) both}
@keyframes chx-in{from{opacity:0;transform:translateY(26px) scale(.9)}}
.chx-card:hover:not(.on){filter:brightness(.9) saturate(.95)}
.chx-card.on{transform:translateY(-8px) scale(1);filter:none;z-index:2;
  box-shadow:inset 0 0 0 2px #ffffff66,0 0 0 4px #ffd75e,0 0 26px 4px #ffd75e88,0 10px 0 #0000008c,0 20px 36px #000a}
.chx-card.locked{cursor:not-allowed}
.chx-card.nope{animation:chx-nope .32s ease}
@keyframes chx-nope{20%{transform:translateX(-7px) scale(.93)}45%{transform:translateX(6px) scale(.93)}70%{transform:translateX(-3px) scale(.93)}}
.chx-scene{position:absolute;left:0;top:0;width:224px;height:196px;display:block}
/* 場景上緣一道細高光、下緣淡淡壓暗，接到下面的木牌 */
.chx-card::before{content:"";position:absolute;left:0;right:0;top:0;height:196px;z-index:1;pointer-events:none;
  background:linear-gradient(#ffffff26,#fff0 18%,#fff0 70%,#00000059)}
/* 選到的卡：一道反光掃過場景。⚠ 用「背景位置」做動畫而不是移動元素 ——
   卡片本身不能 overflow:hidden（箭頭、徽章要凸出去），移動元素的話反光會掃到隔壁那張卡上 */
.chx-card.on::after{content:"";position:absolute;left:0;right:0;top:0;height:196px;z-index:1;pointer-events:none;
  background:linear-gradient(105deg,#fff0 42%,#ffffff5e 50%,#fff0 58%) no-repeat;background-size:300% 100%;
  animation:chx-shine 3.4s ease-in-out infinite}
@keyframes chx-shine{0%,55%{background-position:100% 0}100%{background-position:0 0}}

/* 左上角的章節牌 */
.chx-no{position:absolute;left:-4px;top:12px;z-index:3;display:flex;align-items:center;gap:6px;
  padding:5px 12px 5px 10px;border:3px solid #000;font-size:16px;font-weight:900;letter-spacing:2px;color:#3d2308;
  background:linear-gradient(#fff6d8,#f0c86a);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #c9921e,0 3px 0 #0006}
.chx-no .pxi{width:22px;height:22px}
/* 全破徽章 */
.chx-clear{position:absolute;right:-8px;top:-12px;z-index:4;display:flex;align-items:center;gap:3px;
  padding:3px 9px 3px 5px;border:3px solid #000;font-size:12px;font-weight:900;letter-spacing:1px;color:#3d2308;
  background:linear-gradient(#fff3c4,#ffca4a);box-shadow:0 3px 0 #0006;transform:rotate(6deg)}
.chx-clear .pxi{width:20px;height:20px}
/* 下半部：木牌（名稱＋進度條） */
.chx-plate{position:absolute;left:0;right:0;bottom:0;height:96px;z-index:2;border-top:4px solid #000;
  display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;
  background:
    linear-gradient(#ffffff1f,#fff0 30%,#0000 70%,#00000033),
    repeating-linear-gradient(92deg,var(--wood) 0 7px,var(--wood-d) 7px 11px,var(--wood-l) 11px 15px)}
.chx-name{font-size:20px;font-weight:900;letter-spacing:2px;color:#fff6dd;line-height:1.1;
  filter:drop-shadow(2px 0 0 #2a1605) drop-shadow(-2px 0 0 #2a1605) drop-shadow(0 2px 0 #2a1605) drop-shadow(0 -2px 0 #2a1605)}
/* 進度條：Minecraft 經驗條的綠色 */
.chx-bar{position:relative;width:176px;height:12px;border:2px solid #000;background:#1c1206;box-shadow:inset 0 2px 3px #000a}
.chx-bar i{position:absolute;left:0;top:0;bottom:0;background:linear-gradient(#d8ff8a,#8fdc3c 45%,#4c9a1c);box-shadow:inset 0 1px 0 #fff8}
.chx-card.done .chx-bar i{background:linear-gradient(#fff3c4,#ffd75c 45%,#e0951e)}
.chx-count,.chx-note{font-size:12px;font-weight:900;letter-spacing:1px;color:#ffe9a8;text-shadow:0 2px 0 #000a}
/* 鎖住：場景已經壓暗，這裡只放鎖頭＋條件 */
.chx-lock{position:absolute;left:10px;right:10px;top:58px;z-index:3;display:flex;flex-direction:column;align-items:center;gap:8px;
  font-size:12.5px;font-weight:900;letter-spacing:1px;color:#fff;text-shadow:0 2px 0 #000}
.chx-lock .pxi{width:46px;height:46px;filter:drop-shadow(0 3px 0 #000a)}
.chx-lock span{background:#000000b3;border:2px solid #ffffff3d;padding:4px 10px}
/* 選到的那張上方有一顆跳動的箭頭 */
.chx-pick{position:absolute;left:50%;top:-34px;z-index:4;display:none;font-size:22px;line-height:1;color:#ffd75e;
  filter:drop-shadow(2px 0 0 #000) drop-shadow(-2px 0 0 #000) drop-shadow(0 2px 0 #000) drop-shadow(0 -2px 0 #000);
  animation:chx-bob .9s ease-in-out infinite}
.chx-card.on .chx-pick{display:block}
@keyframes chx-bob{0%,100%{transform:translate(-50%,0)}50%{transform:translate(-50%,-6px)}}

/* 底部：說明 + 進入 */
.chx-foot{position:absolute;left:0;right:0;bottom:20px;z-index:2;display:flex;align-items:center;justify-content:center;gap:14px}
#scr-chapter .ch-hint{max-width:520px;min-height:52px;display:flex;flex-direction:column;justify-content:center;gap:1px;
  text-align:left;padding:7px 14px;border:3px solid #000;border-radius:0;
  background:linear-gradient(#fffaea,#f3e3bb);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #d8c18a,0 4px 0 #00000055;color:#4a2a08}
#scr-chapter .ch-hint b{font-size:14px;font-weight:900;color:#3d2308;letter-spacing:1px}
#scr-chapter .ch-hint span{font-size:12px;font-weight:700;line-height:1.5;color:#6b4a1e}
.chx-go{min-width:170px;padding:11px 20px;font-size:19px;letter-spacing:3px}

/* =========================================================
   關卡地圖（v8.1）：左邊像素地形、右邊關卡情報
   ========================================================= */
#scr-stage .scr-head{position:relative;z-index:3;padding-top:8px;padding-bottom:8px}
.stx-head{display:flex;align-items:center;gap:10px}
#stage-head-title{min-width:230px;display:flex;flex-direction:column;align-items:center;line-height:1.08;font-size:21px}
#stage-head-title small{font-size:11px;letter-spacing:4px;color:#ffe9a8;
  text-shadow:1px 1px 0 #3d2308,-1px 1px 0 #3d2308,1px -1px 0 #3d2308,-1px -1px 0 #3d2308}
.stx-chnav{width:32px;height:32px;padding:0;font-size:12px}
.stx-chnav:disabled{opacity:.3}
.stx-body{position:relative;flex:1;min-height:0;display:flex}
/* 地圖四周壓暗一圈（蓋在地形上、節點下） */
.stx-body::before{content:"";position:absolute;left:0;top:0;bottom:0;right:300px;z-index:1;pointer-events:none;
  box-shadow:inset 0 0 50px #000000a0,inset 0 10px 14px -8px #000c}
#scr-stage .stage-map-wrap{flex:1;min-width:0;height:100%;background:#1d1a2e;cursor:grab;overflow-x:auto;overflow-y:hidden;
  scrollbar-width:thin;scrollbar-color:#8a5423 #1d1a2e}
#scr-stage .stage-map{position:relative;min-height:0}
.stx-terrain{position:absolute;left:0;top:0;display:block;image-rendering:pixelated}

/* ---- 節點：方框頭像 ---- */
.stn{position:absolute;z-index:2;transform:translate(-50%,-50%);padding:0;border:0;background:none;cursor:pointer;line-height:0;
  animation:stn-in .42s cubic-bezier(.2,1.5,.4,1) var(--d,0s) both}
@keyframes stn-in{from{opacity:0;transform:translate(-50%,-80%) scale(.5)}}
.stn-frame{display:block;border:4px solid #000;background:#000;transition:transform .12s;
  box-shadow:inset 0 0 0 2px #ffffff5c,0 4px 0 #0000009a,0 9px 12px #0007}
.stn-frame canvas{display:block}
.stn:hover:not(.locked) .stn-frame{transform:translateY(-3px)}
.stn.cleared .stn-frame{box-shadow:inset 0 0 0 2px #ffd75e,0 4px 0 #0000009a,0 9px 12px #0007}
.stn.boss .stn-frame{border-color:#2a0508;box-shadow:inset 0 0 0 3px #e0392b,0 4px 0 #0000009a,0 0 18px 2px #e0392b99}
.stn.locked{cursor:not-allowed}
.stn.locked .stn-frame{box-shadow:inset 0 0 0 2px #ffffff1c,0 4px 0 #0000009a}
.stn.nope{animation:stn-nope .3s ease}
@keyframes stn-nope{25%{transform:translate(-56%,-50%)}60%{transform:translate(-45%,-50%)}}
.stn-name{position:absolute;left:50%;top:100%;transform:translateX(-50%);margin-top:5px;padding:2px 9px;white-space:nowrap;line-height:1.2;
  font-size:12.5px;font-weight:900;letter-spacing:1px;color:#fff6dd;border:2px solid #000;box-shadow:0 2px 0 #0009;
  background:repeating-linear-gradient(92deg,var(--wood) 0 7px,var(--wood-d) 7px 11px,var(--wood-l) 11px 15px);
  text-shadow:1px 1px 0 #2a1605,-1px 1px 0 #2a1605,1px -1px 0 #2a1605,-1px -1px 0 #2a1605}
.stn.locked .stn-name{color:#a49cc0;background:#2a2638;text-shadow:none}
.stn.boss .stn-name{background:linear-gradient(#e0493b,#9e1f16);color:#fff}
.stn-star,.stn-skull{position:absolute;top:-11px;width:22px;height:22px;filter:drop-shadow(0 2px 0 #000c)}
.stn-star{right:-11px}
.stn-skull{left:-11px}
.stn-lock{position:absolute;left:50%;top:50%;width:26px;height:26px;transform:translate(-50%,-62%);filter:drop-shadow(0 2px 0 #000)}
/* 目前該打的那一關：金框脈動（v8.3：頭上的夥伴改成會走路的 .stx-walker，這裡只剩 NEXT! 旗子，見 deluxe.css） */
.stn.current .stn-frame{animation:stn-pulse 1.3s ease-in-out infinite}
@keyframes stn-pulse{50%{box-shadow:inset 0 0 0 2px #ffd75e,0 4px 0 #0000009a,0 0 0 4px #ffd75e88,0 0 24px 4px #ffd75ecc}}
/* 選取框：Minecraft 物品欄那種四個角 */
.stn-sel{position:absolute;inset:-10px;pointer-events:none;display:none}
.stn.sel .stn-sel{display:block;animation:stn-sel .7s ease-in-out infinite alternate}
@keyframes stn-sel{to{inset:-14px}}
.stn-sel i{position:absolute;width:13px;height:13px;border:4px solid #fff;filter:drop-shadow(0 0 1px #000) drop-shadow(0 2px 0 #0008)}
.stn-sel i:nth-child(1){left:0;top:0;border-right:0;border-bottom:0}
.stn-sel i:nth-child(2){right:0;top:0;border-left:0;border-bottom:0}
.stn-sel i:nth-child(3){left:0;bottom:0;border-right:0;border-top:0}
.stn-sel i:nth-child(4){right:0;bottom:0;border-left:0;border-top:0}

/* ---- 右側：關卡情報面板 ---- */
.stx-panel{position:relative;z-index:2;flex:0 0 300px;display:flex;flex-direction:column;gap:6px;padding:0 12px 12px;overflow:hidden;
  background:linear-gradient(#fdf2d8,#ecd6a6);border-left:4px solid #000;box-shadow:-6px 0 16px #0007;color:#3d2308}
.stp-head{position:relative;display:flex;align-items:center;gap:6px;margin:0 -12px 2px;padding:8px 10px 9px;border-bottom:4px solid #000;
  background:repeating-linear-gradient(92deg,var(--wood) 0 7px,var(--wood-d) 7px 11px,var(--wood-l) 11px 15px)}
.stp-head.boss{background:linear-gradient(#b8322a,#6e1410)}
.stp-nav{flex:0 0 auto;width:28px;height:36px;padding:0;font-size:11px;cursor:pointer;font-weight:900;
  --f1:#d4d4d4; --f2:#b8b8b8; --hi:#efefef; --lo:#8a8a8a;
  background:linear-gradient(var(--f1),var(--f2));border:3px solid #000;box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo),0 3px 0 #0006}
.stp-nav:active{transform:translateY(2px)}
.stp-title{flex:1;display:flex;flex-direction:column;align-items:center;line-height:1.1}
.stp-no{display:flex;align-items:center;gap:5px;font-size:11px;font-weight:900;letter-spacing:2px;color:#ffe9a8;text-shadow:0 1px 0 #000}
.stp-no em{font-style:normal;font-size:9.5px;letter-spacing:1px;color:#fff;background:#e0392b;border:2px solid #000;padding:0 4px}
.stp-name{font-size:27px;font-weight:900;letter-spacing:3px;color:#fff;
  filter:drop-shadow(2px 0 0 #000) drop-shadow(-2px 0 0 #000) drop-shadow(0 2px 0 #000) drop-shadow(0 -2px 0 #000)}
.stp-clear{position:absolute;right:38px;bottom:-12px;z-index:2;display:flex;align-items:center;gap:2px;padding:1px 7px 1px 3px;
  font-size:11px;font-weight:900;letter-spacing:1px;color:#3d2308;background:linear-gradient(#fff3c4,#ffca4a);border:2px solid #000;
  transform:rotate(-6deg);box-shadow:0 2px 0 #0007}
.stp-clear .pxi{width:16px;height:16px}
.stp-desc{font-size:12.5px;font-weight:800;line-height:1.45;color:#5a3512;min-height:36px}
.stp-sec{display:flex;align-items:center;justify-content:space-between;margin-top:1px;padding-bottom:2px;
  font-size:11px;font-weight:900;letter-spacing:2px;color:#8a5a12;border-bottom:2px solid #00000026}
.stp-link{border:0;background:none;padding:0;cursor:pointer;font-family:inherit;font-size:11px;font-weight:900;letter-spacing:1px;color:#1f5fb0}
.stp-link:hover{text-decoration:underline}
.stx-panel>*{flex-shrink:0}
.stp-foes{display:flex;gap:6px;min-height:46px;align-items:flex-end}
.stp-foe{position:relative;width:var(--fs,46px);height:var(--fs,46px);border:3px solid #000;line-height:0;
  background:linear-gradient(#fffdf5,#ead7ab);box-shadow:inset 0 0 0 1px #fff,0 2px 0 #0004}
.stp-foe.boss{border-color:#4a0a0e;background:linear-gradient(#ffe0da,#f0a094)}
.stp-foe.unseen{background:linear-gradient(#3a3550,#26223a)}
.stp-crown{position:absolute;right:-9px;top:-10px;width:18px;height:18px;filter:drop-shadow(0 1px 0 #000)}
.stp-traits{display:flex;flex-wrap:wrap;gap:4px}
.stp-trait{font-style:normal;font-size:10.5px;font-weight:900;padding:1px 7px;color:var(--c);background:#2c1c08;border:2px solid #000;text-shadow:0 1px 1px #000}
.stp-stats{display:grid;grid-template-columns:1fr 1fr;gap:6px}
.stp-stats div{display:flex;flex-direction:column;align-items:center;padding:2px 0 3px;background:#1c1206;border:2px solid #000;box-shadow:inset 0 2px 3px #000a}
.stp-stats span{font-size:9.5px;font-weight:800;letter-spacing:1px;color:#e8cf98}
.stp-stats b{font-size:15px;font-weight:900;color:#ffd75c;line-height:1.15}
.stp-rewards{display:flex;gap:5px}
.stp-rewards span{flex:1;display:flex;align-items:center;justify-content:center;gap:3px;padding:3px 2px;
  background:#fffdf5;border:2px solid #000;box-shadow:0 2px 0 #0003}
.stp-rewards .pxi{width:18px;height:18px}
.stp-rewards b{font-size:12.5px;font-weight:900;color:#b4530a}
/* 攜帶道具：Minecraft 物品欄的格子（深灰凹槽、數量印在右下角） */
.stp-items{display:flex;gap:5px}
.stp-item{position:relative;flex:1;height:46px;padding:0;cursor:pointer;border:3px solid #000;background:#8b8b8b;
  box-shadow:inset 3px 3px 0 #373737,inset -3px -3px 0 #ffffffb0;transition:transform .08s}
.stp-item .pxi{display:block;width:28px;height:28px;margin:6px auto 0;filter:drop-shadow(0 2px 0 #0006)}
.stp-item b{position:absolute;right:3px;bottom:1px;font-size:12px;font-weight:900;color:#fff;text-shadow:2px 2px 0 #3f3f3f;line-height:1}
.stp-item:hover{background:#9e9e9e}
.stp-item.on{background:#7ccf52;box-shadow:inset 3px 3px 0 #3e7f22,inset -3px -3px 0 #d8ffb8,0 0 0 2px #fff,0 0 10px #8ef07a}
.stp-item.empty{cursor:default}
.stp-item.empty .pxi{opacity:.35;filter:grayscale(1)}
.stp-item.empty b{color:#d0d0d0}
.stp-check{position:absolute;right:-8px;top:-9px;width:20px;height:20px;margin:0!important;filter:drop-shadow(0 1px 0 #000)}
/* 戰鬥開始：放在最底下的大顆金色方鈕 */
#scr-stage .sl-go{margin-top:auto;display:flex;flex-direction:column;align-items:center;gap:1px;
  padding:9px 6px 8px;font-size:22px;font-weight:900;letter-spacing:4px;cursor:pointer;color:#3d2308;border-radius:0;
  --f1:#ffe39a; --f2:#f0b429; --hi:#fff6d0; --lo:#a9761a;
  background:linear-gradient(var(--f1),var(--f2));border:4px solid #000;
  box-shadow:inset 3px 3px 0 var(--hi),inset -3px -3px 0 var(--lo),0 5px 0 #0000008c;text-shadow:0 1px 0 #fff9;
  animation:slgo-glow 1.6s ease-in-out infinite}
#scr-stage .sl-go:hover{filter:brightness(1.06)}
#scr-stage .sl-go:active{transform:translateY(4px);box-shadow:inset 3px 3px 0 var(--hi),inset -3px -3px 0 var(--lo)}
#scr-stage .sl-go small{font-size:10.5px;letter-spacing:1px;color:#6b3a00}
@keyframes slgo-glow{50%{box-shadow:inset 3px 3px 0 var(--hi),inset -3px -3px 0 var(--lo),0 5px 0 #0000008c,0 0 16px 2px #ffd75ecc}}

/* =========================================================
   儲藏庫（v8.1）：戰鬥道具
   ========================================================= */
.sto-body{flex:1;min-height:0;display:flex;gap:14px;padding:12px 14px 14px}
.sto-main{flex:1;min-width:0;display:flex;flex-direction:column;gap:10px}
.sto-side{flex:0 0 318px;display:flex;flex-direction:column;gap:8px}
.sto-cap{display:flex;align-items:baseline;gap:10px;flex-wrap:wrap}
.sto-cap b{display:flex;align-items:center;gap:6px;font-size:18px;font-weight:900;letter-spacing:3px;color:#fff6dd;
  text-shadow:2px 2px 0 #1d4a41,-2px 2px 0 #1d4a41,2px -2px 0 #1d4a41,-2px -2px 0 #1d4a41}
.sto-cap b .pxi{width:24px;height:24px}
.sto-cap span{font-size:11.5px;font-weight:800;color:#d8efe8}
.sto-grid{display:grid;grid-template-columns:repeat(5,1fr);gap:10px}
@keyframes sto-in{from{opacity:0;transform:translateY(14px) scale(.92)}}
/* 選到的道具：說明 + 攜帶 + 購買 */
.sto-info{flex:1;min-height:0;display:flex;align-items:center;gap:14px;padding:12px 14px;border:4px solid #000;color:#3d2308;
  background:linear-gradient(#fffaea,#f3e3bb);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #d8c18a,0 5px 0 #00000059}
.sti-ico{flex:0 0 auto;width:84px;height:84px;display:flex;align-items:center;justify-content:center;
  background:#8b8b8b;border:3px solid #000;box-shadow:inset 3px 3px 0 #373737,inset -3px -3px 0 #ffffffb0}
.sti-ico .pxi{width:56px;height:56px;filter:drop-shadow(0 3px 0 #0006)}
.sti-txt{flex:1;min-width:0}
.sti-txt b{display:flex;align-items:center;gap:8px;font-size:18px;font-weight:900;letter-spacing:1px}
.sti-txt b em{font-style:normal;font-size:11.5px;color:#fff;background:#1c1206;border:2px solid #000;padding:0 7px;letter-spacing:0}
.sti-on{font-style:normal;font-size:11px;color:#fff;background:#3f9c48;border:2px solid #1f5a2c;padding:0 6px}
.sti-txt p{margin:4px 0 6px;font-size:12.5px;font-weight:700;line-height:1.55;color:#5a3512}
.sti-carry{font-size:11.5px;font-weight:900;color:#8a5a12}
.sti-carry span{color:#2c6a3a}
.sti-btns{flex:0 0 150px;display:flex;flex-direction:column;gap:8px}
.sti-btns .px-btn{padding:9px 6px;font-size:14px}
.sti-btns .pxi{width:18px;height:18px;vertical-align:-4px}
.sto-how{display:flex;gap:8px}
.sto-how span{flex:1;display:flex;align-items:center;gap:6px;padding:6px 8px;font-size:11px;font-weight:800;line-height:1.35;
  color:#e8f6f2;background:#00000038;border:2px solid #ffffff26}
.sto-how .pxi{width:22px;height:22px}
.sto-how b{flex:0 0 auto;width:18px;height:18px;display:grid;place-items:center;font-size:11px;color:#3d2308;background:#ffd75e;border:2px solid #000}
/* 右側：資源 */
.sto-res{flex:1;display:flex;flex-direction:column;gap:8px}
.sto-r{display:flex;align-items:center;gap:10px;padding:8px 10px;border:3px solid #000;color:#3d2308;
  background:linear-gradient(#fdf2d8,#ecd6a6);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #c9ab72,0 4px 0 #00000059}
.sto-r.coll{background:linear-gradient(#e8f2ff,#c6d9f0);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #93aecf,0 4px 0 #00000059}
.sto-r-ico .pxi{width:38px;height:38px;filter:drop-shadow(0 2px 0 #0005)}
.sto-r-txt{flex:1;min-width:0}
.sto-r-txt div{display:flex;align-items:baseline;justify-content:space-between;gap:6px}
.sto-r-txt b{font-size:14px;font-weight:900}
.sto-r-txt strong{font-size:17px;font-weight:900;color:#b4530a;font-variant-numeric:tabular-nums}
.sto-r.coll .sto-r-txt strong{color:#1f5fb0}
.sto-r-txt span{display:block;font-size:10.5px;font-weight:700;line-height:1.45;color:#6b4a1e}
.sto-go{flex:0 0 auto;padding:6px 8px;font-size:12px}
/* 基地「儲藏庫」按鈕上的小綠牌（勾選了幾個道具） */
.bag-badge{position:absolute;top:-9px;right:-10px;padding:0 5px;font-style:normal;font-size:10px;font-weight:900;line-height:16px;
  color:#fff;background:#3f9c48;border:2px solid #000;white-space:nowrap}

/* =========================================================
   基地（v8.1）：章節進度、下一關、夥伴背後的戰場窗景
   ========================================================= */
.base-top{position:relative}
.base-ch{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);display:flex;align-items:center;gap:8px;
  padding:4px 12px 5px;border:3px solid #000;background:linear-gradient(#1c1206,#0d0803);cursor:pointer;font-family:inherit;
  box-shadow:inset 0 2px 4px #000a,0 2px 0 #2c1806}
.base-ch:hover{filter:brightness(1.18)}
.base-ch span{font-size:11px;font-weight:900;letter-spacing:2px;color:#ffd75c}
.base-ch b{font-size:14px;font-weight:900;letter-spacing:2px;color:#fff6dd}
.bch-bar{position:relative;display:block;width:92px;height:10px;border:2px solid #000;background:#3a2a14}
.bch-bar i{position:absolute;left:0;top:0;bottom:0;background:linear-gradient(#d8ff8a,#8fdc3c 45%,#4c9a1c)}
.base-ch em{font-style:normal;font-size:12px;font-weight:900;color:#ffe9a8;font-variant-numeric:tabular-nums}
/* ⚠ 左欄是固定高度的 flex 直欄，按鈕預設會被壓扁 —— 戰鬥開始多了一行「下一關」，不能讓它縮（改由升級／編成讓位） */
#base-battle{flex:0 0 auto;display:flex;flex-direction:column;align-items:center;justify-content:center;line-height:1.1;padding:8px 12px 7px;min-height:70px}
#base-battle small{flex:0 0 auto;display:block;max-width:100%;margin-top:3px;font-size:11.5px;line-height:1.2;font-weight:800;letter-spacing:1px;color:#6b3a00;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
/* 窗景：畫布鋪滿右半邊，外面一圈黑框、裡面四周壓暗；對話框與夥伴浮在上面 */
.base-scene{position:absolute;left:0;top:0;z-index:0;display:block;box-shadow:0 0 0 4px #000,0 6px 0 4px #00000059}
.base-right::after{content:"";position:absolute;inset:0;z-index:0;pointer-events:none;
  box-shadow:inset 0 0 46px #000000a6,inset 0 -40px 40px -20px #0000008c}
#scr-base .base-bubble{position:relative;z-index:2;width:auto;align-self:stretch;margin:12px 12px 0;min-height:96px}
#scr-base .base-cat-btn{z-index:2;right:6px;bottom:-4px}
/* 商店的「每日禮」小牌子 */
.base-shop{position:relative}
.daily-badge{position:absolute;top:-12px;right:-14px;padding:0 6px;font-style:normal;font-size:10.5px;font-weight:900;line-height:17px;
  letter-spacing:1px;color:#fff;background:#e0392b;border:2px solid #000;white-space:nowrap;animation:daily-bob 1s ease-in-out infinite}
@keyframes daily-bob{50%{transform:translateY(-3px)}}

/* ---------- 小提示條（uiToast） ---------- */
.ui-toast{position:absolute;left:50%;top:14px;z-index:95;transform:translateX(-50%);max-width:660px;padding:9px 16px;cursor:pointer;white-space:pre-line;
  font-size:13px;font-weight:800;line-height:1.5;color:#3d2308;border:3px solid #000;
  background:linear-gradient(#fffaea,#f3e3bb);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #d8c18a,0 5px 0 #0006,0 10px 24px #0008;
  animation:toast-in .4s cubic-bezier(.2,1.4,.4,1)}
.ui-toast.out{animation:toast-out .4s ease forwards}
@keyframes toast-in{from{opacity:0;transform:translate(-50%,-30px)}}
@keyframes toast-out{to{opacity:0;transform:translate(-50%,-30px)}}

/* =========================================================
   選單（v8.1）：兩欄三列的像素大按鈕
   ========================================================= */
#scr-menu .menu-screen{gap:18px}
.mnx-grid{display:grid;grid-template-columns:repeat(2,262px);gap:12px}
.mnx-btn{position:relative;display:grid;grid-template-columns:48px 1fr;grid-template-rows:auto auto;column-gap:12px;align-items:center;
  padding:10px 14px;text-align:left;cursor:pointer;font-family:inherit;color:#1c1c1c;
  --f1:#d4d4d4; --f2:#b8b8b8; --hi:#efefef; --lo:#8a8a8a;
  background:linear-gradient(var(--f1),var(--f2));border:4px solid #000;
  box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo),0 4px 0 #00000059}
.mnx-btn .pxi{grid-row:1/3;width:44px;height:44px;filter:drop-shadow(0 2px 0 #0005)}
.mnx-btn b{font-size:18px;font-weight:900;letter-spacing:2px;text-shadow:0 1px 0 #fff8;line-height:1.2}
.mnx-btn span{font-size:11px;font-weight:800;color:#4a4a4a}
.mnx-btn:hover{filter:brightness(1.06)}
.mnx-btn:active{transform:translateY(3px);box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo)}
.mnx-btn.lab{--f1:#a8ece3; --f2:#2fb3a6; --hi:#d8fff9; --lo:#177269}
.mnx-btn.lab span{color:#0f4a44}
.mnx-btn .mail-badge{top:-9px;right:-9px}

/* =========================================================
   設定（v8.1）：兩欄、奶油色面板、像素滑桿與分段鈕
   ========================================================= */
#scr-settings .settings-body{display:grid;grid-template-columns:1fr 1fr;gap:14px;padding:14px 16px;overflow-y:auto;align-items:start}
.set-col{display:flex;flex-direction:column;gap:12px}
.set-group{display:flex;flex-direction:column;gap:14px;padding:12px 14px 14px;border:4px solid #000;color:#3d2308;
  background:linear-gradient(#fdf2d8,#ecd6a6);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #c9ab72,0 5px 0 #00000059}
#scr-settings .set-label{display:flex;align-items:center;justify-content:flex-start;gap:8px;font-size:14px;font-weight:900;color:#3d2308}
#scr-settings .set-label .pxi{width:24px;height:24px;flex:0 0 auto}
#scr-settings .set-label span{margin-left:auto;font-size:15px;font-weight:900;color:#b4530a}
#scr-settings .set-label small{font-size:10.5px;font-weight:800;color:#8a5a12}
.set-row.inline{flex-direction:row;gap:10px}
.set-row.inline .big-btn{flex:1}
.set-row.inline .pxi{width:18px;height:18px;vertical-align:-4px}
/* 滑桿：深灰凹槽 + 金色方塊把手 */
#scr-settings input[type=range]{height:14px;border-radius:0;background:#8b8b8b;border:3px solid #000;box-shadow:inset 2px 2px 0 #373737,inset -2px -2px 0 #c6c6c6}
#scr-settings input[type=range]::-webkit-slider-thumb{width:18px;height:26px;border-radius:0;
  background:linear-gradient(#ffe39a,#f0b429);border:3px solid #000;box-shadow:inset 2px 2px 0 #fff6d0,inset -2px -2px 0 #a9761a}
#scr-settings input[type=range]::-moz-range-thumb{width:14px;height:22px;border-radius:0;background:#f0b429;border:3px solid #000}
#scr-settings .seg{gap:6px}
#scr-settings .seg button{flex:1;padding:7px 0;cursor:pointer;font-family:inherit;font-size:13px;font-weight:900;color:#1c1c1c;border-radius:0;
  --f1:#d4d4d4; --f2:#b8b8b8; --hi:#efefef; --lo:#8a8a8a;
  background:linear-gradient(var(--f1),var(--f2));border:3px solid #000;box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo),0 3px 0 #0006}
#scr-settings .seg button:hover{filter:brightness(1.06)}
#scr-settings .seg button.on{--f1:#ffd98a; --f2:#f0b429; --hi:#fff3c4; --lo:#a9761a;color:#3d2308}
/* 危險區：紅底，按鈕放右邊 */
.set-group.danger{flex-direction:row;align-items:center;gap:10px;
  background:linear-gradient(#ffe7e3,#f3c1ba);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #d88d84,0 5px 0 #00000059}
.set-group.danger .set-label{flex:1;flex-wrap:wrap;row-gap:2px}
.set-group.danger .set-label small{flex-basis:100%;padding-left:32px;color:#8c2018}
#scr-settings #btn-reset{flex:0 0 auto;width:auto;padding:9px 14px}
#scr-settings .set-note{margin:0;font-size:11px;line-height:1.6;color:#d8efe8}

/* =========================================================
   遊戲說明（v8.1）：五個分頁 + 奶油色內頁
   ========================================================= */
#scr-help .help-body{padding:12px 16px 14px;display:flex;flex-direction:column;gap:10px;overflow:hidden;text-shadow:none;color:#3d2308}
.hlp-tabs{display:flex;gap:8px;flex:0 0 auto}
.hlp-tab{display:flex;align-items:center;gap:6px;padding:7px 14px;cursor:pointer;font-family:inherit;font-size:14px;font-weight:900;color:#1c1c1c;
  --f1:#d4d4d4; --f2:#b8b8b8; --hi:#efefef; --lo:#8a8a8a;
  background:linear-gradient(var(--f1),var(--f2));border:3px solid #000;box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo),0 3px 0 #0006}
.hlp-tab:hover{filter:brightness(1.06)}
.hlp-tab.on{--f1:#ffd98a; --f2:#f0b429; --hi:#fff3c4; --lo:#a9761a;color:#3d2308}
.hlp-tab .pxi{width:20px;height:20px}
.hlp-page{flex:1;min-height:0;overflow-y:auto;padding:14px 20px;border:4px solid #000;font-size:13.5px;line-height:1.8;color:#4a2a08;
  background:linear-gradient(#fffaea,#f3e3bb);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #d8c18a,0 5px 0 #00000059}
.hlp-page h3{display:flex;align-items:center;gap:8px;margin:14px 0 4px;font-size:15px;font-weight:900;letter-spacing:2px;color:#8a5a12}
.hlp-page h3:first-child{margin-top:0}
.hlp-page h3 .pxi{width:22px;height:22px}
.hlp-page ul{padding-left:20px}
.hlp-page li .pxi{width:18px;height:18px;vertical-align:-4px;margin-right:3px}
.hlp-page b{color:#3d2308}
.hlp-page code{padding:0 6px;font-size:12px;color:#ffd75c;background:#1c1206;border:1px solid #000}
.hlp-note{margin-top:14px;font-size:11.5px;color:#8a7856}
.hl-red{color:#c2372f;font-weight:900}
.hl-float{color:#1f7ab0;font-weight:900}
.hl-alien{color:#2c8a55;font-weight:900}

/* =========================================================
   信箱（v8.1）：信紙 + 附件標籤 + 全部領取
   ========================================================= */
#scr-mail .mail-body{flex:1;min-height:0;max-height:none;margin:12px 16px 14px;gap:10px}
.mail-top{display:flex;align-items:center;justify-content:space-between;padding:8px 12px;flex:0 0 auto;
  font-size:13px;font-weight:800;color:#e8f6f2;background:#00000038;border:2px solid #ffffff26}
.mail-top b{color:#ffd75c}
.mail-top .px-btn{padding:7px 18px;font-size:14px}
#scr-mail .mail-item{flex:0 0 auto;padding:12px 14px;border:4px solid #000;border-radius:0;color:#3d2308;
  background:linear-gradient(#fffaea,#f3e3bb);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #d8c18a,0 5px 0 #00000059}
#scr-mail .mail-item.got{opacity:.6;filter:saturate(.55)}
#scr-mail .mi-icon{width:26px;height:26px}
#scr-mail .mi-title{font-size:16px;color:#3d2308}
#scr-mail .mi-from{font-weight:800;color:#8a5a12}
#scr-mail .mi-body{font-size:13px;color:#5a3512}
.mi-foot{display:flex;align-items:flex-end;justify-content:space-between;gap:10px;margin-top:8px}
#scr-mail .mi-reward{display:flex;flex-wrap:wrap;gap:6px;margin:0}
.mi-chip{display:inline-flex;align-items:center;gap:4px;padding:2px 8px;font-size:12px;font-weight:900;color:#3d2308;background:#fffdf5;border:2px solid #000;box-shadow:0 2px 0 #0003}
.mi-chip.unit{background:#fff0fb}
.mi-chip .pxi{width:18px;height:18px}
#scr-mail .mi-claim{flex:0 0 auto;padding:7px 22px;font-size:14px}
#scr-mail .mi-done{flex:0 0 auto;font-size:12px;font-weight:900;color:#2c6a3a;border:2px solid #2c6a3a;padding:2px 10px;transform:rotate(-4deg)}

/* 商店區塊標題的像素圖示 */
.shop-section-title .pxi{width:20px;height:20px;vertical-align:-4px;margin-right:6px}

/* 戰鬥：這場帶的道具（計時器下面一排小圖示）與開場橫幅上的「道具發動」 */
#battle-items{display:flex;gap:3px;justify-content:center;margin-top:2px;pointer-events:auto}
#battle-items .pxi{width:18px;height:18px;filter:drop-shadow(0 1px 0 #000) drop-shadow(0 0 3px #ffd75e88)}
.bb-items .pxi{width:16px;height:16px;vertical-align:-3px;margin-right:3px}

/* 結算：首通多送一個道具時變成四格 */
.res-rewards.four{grid-template-columns:repeat(4,1fr)}
.res-rewards.four .rw b{font-size:19px}
.rw.it{background:linear-gradient(#f0fff0,#cdeebc)}
.rw.it span{white-space:nowrap}

/* （v8.1 的「強化」卡片樣式已移除：v8.3 升級畫面整個重做，新樣式在 deluxe.css 的 .upx-*） */

/* 標題：Minecraft 風的黃色跳動標語 */
/* 位置對齊標題字的右下角（標題圖 title_bg 上的字在 x≈276..768、y≈90..198；換圖要重量） */
.mc-splash{position:absolute;left:688px;top:164px;z-index:2;white-space:nowrap;pointer-events:none;transform-origin:0 50%;
  font-size:19px;font-weight:900;letter-spacing:1px;color:#ffff55;text-shadow:2px 2px 0 #3f3f15;
  transform:rotate(-17deg);animation:mc-splash .52s ease-in-out infinite alternate}
@keyframes mc-splash{from{transform:rotate(-17deg) scale(.92)}to{transform:rotate(-17deg) scale(1.06)}}

/* =========================================================
   劇情回顧（v8.1）：像素分頁 + 奶油色列
   ========================================================= */
#scr-storylog .storylog-tabs{padding:12px 16px 0;gap:8px}
#scr-storylog .sl-tab{padding:6px 16px;border-radius:0;font-family:inherit;font-size:13px;font-weight:900;color:#1c1c1c;cursor:pointer;
  --f1:#d4d4d4; --f2:#b8b8b8; --hi:#efefef; --lo:#8a8a8a;
  background:linear-gradient(var(--f1),var(--f2));border:3px solid #000;box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo),0 3px 0 #0006}
#scr-storylog .sl-tab.on{--f1:#ffd98a; --f2:#f0b429; --hi:#fff3c4; --lo:#a9761a;color:#3d2308}
#scr-storylog .storylog-body{flex:1;min-height:0;max-height:none;margin:10px 16px 14px;gap:7px}
#scr-storylog .sl-row{flex:0 0 auto;border-radius:0;padding:7px 12px;border:3px solid #000;color:#3d2308;
  background:linear-gradient(#fdf2d8,#ecd6a6);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #c9ab72,0 3px 0 #00000059}
#scr-storylog .sl-row.none{opacity:.5}
#scr-storylog .sl-stage{min-width:48px;padding:1px 6px;text-align:center;font-size:13px;color:#ffd75c;background:#1c1206;border:2px solid #000}
#scr-storylog .sl-desc{font-size:12.5px;font-weight:800;color:#5a3512}
#scr-storylog .sl-btns i{color:#a08a62}

/* 編成／圖鑑頁籤上的 emoji 換成像素圖示（v8.1） */
.dex-tab .pxi{width:18px;height:18px;vertical-align:-4px}
.bb-combos .pxi{width:16px;height:16px;vertical-align:-3px;margin-right:3px}

/* 設定：背景音樂的開關小分段鈕（v8.2，跟音量放同一列） */
#scr-settings .set-label .seg.mini{flex:0 0 auto;margin-left:8px;gap:4px}
#scr-settings .seg.mini button{flex:0 0 auto;padding:2px 9px;font-size:11px;box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo),0 2px 0 #0006}

/* =========================================================
   轉蛋：錢包晃一下（錢不夠）、機率／紀錄／收集覆蓋面板
   （v8.6：頁面本體改成「卡牌商店」，樣式在 summon.css；v8.2 的海報／扭蛋機／抽的按鈕已刪除）
   ========================================================= */
#scr-gacha .dev-bar{flex:0 0 auto}
.tk-chip.shake,.xp-chip.shake{animation:chip-shake .4s}
@keyframes chip-shake{20%{transform:translateX(-5px)}40%{transform:translateX(5px)}60%{transform:translateX(-3px)}80%{transform:translateX(3px)}}
/* ---- 機率／紀錄／收集面板 ---- */
.gx-panel{position:absolute;inset:0;z-index:30;display:flex;align-items:center;justify-content:center;background:#000000b3}
.gx-panel.hidden{display:none}
.gxp-card{width:860px;height:440px;display:flex;flex-direction:column;border:4px solid #000;color:#3d2308;
  background:linear-gradient(#fdf2d8,#ecd6a6);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #c9ab72,0 8px 0 #0000008c,0 20px 50px #000c}
.gxp-head{display:flex;align-items:center;justify-content:space-between;padding:8px 10px;border-bottom:4px solid #000;
  background:repeating-linear-gradient(92deg,var(--wood) 0 7px,var(--wood-d) 7px 11px,var(--wood-l) 11px 15px)}
.gxp-tabs{display:flex;gap:6px}
.gxp-tab{padding:5px 14px;cursor:pointer;font-family:inherit;font-size:13px;font-weight:900;color:#1c1c1c;
  --f1:#d4d4d4; --f2:#b8b8b8; --hi:#efefef; --lo:#8a8a8a;
  background:linear-gradient(var(--f1),var(--f2));border:3px solid #000;box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo)}
.gxp-tab.on{--f1:#ffd98a; --f2:#f0b429; --hi:#fff3c4; --lo:#a9761a}
.gxp-head .px-btn{padding:3px 10px;font-size:14px}
.gxp-body{flex:1;min-height:0;overflow-y:auto;padding:12px 14px}
.gxr-cols{display:grid;grid-template-columns:1fr 1fr;gap:14px}
.gxr-col h4{display:flex;align-items:center;gap:6px;margin:0 0 6px;font-size:15px;font-weight:900;letter-spacing:2px;color:#8a5a12}
.gxr-col h4 .pxi{width:22px;height:22px}
.gxr-row{display:grid;grid-template-columns:62px 58px 1fr;align-items:center;gap:6px;padding:4px 6px;margin-bottom:4px;background:#fffdf5;border:2px solid #000}
.gxr-row b{font-size:14px;font-weight:900;color:#b4530a;text-align:right}
.gxr-row em{font-style:normal;font-size:11px;font-weight:700;color:#6b4a1e;line-height:1.35}
.gxr-tag{font-size:11.5px;font-weight:900;text-align:center;padding:1px 0;color:var(--c,#fff);background:#1c1206;border:2px solid #000}
.gxr-tag.t-bronze{color:#ffc58a}.gxr-tag.t-silver{color:#f2f6ff}.gxr-tag.t-gold{color:#ffd75e}
.gxr-col p{margin-top:6px;font-size:11.5px;font-weight:700;line-height:1.7;color:#6b4a1e}
.gxp-body .gacha-stats{margin:0}
.gs-basic{margin-left:auto;font-size:12px;font-weight:800;color:#6b4a1e}
.gxp-body .collection-title{margin-bottom:8px;color:#3d2308}
.gxp-body .coll-more{margin-left:auto;padding:4px 10px;font-size:12px}

/* 收集面板的格子：奶油底＋稀有度內框（原本是深藍底配深色字，放進奶油色面板裡讀不到） */
.gxp-body .collection-grid{grid-template-columns:repeat(auto-fill,minmax(88px,1fr));gap:8px}
.gxp-body .coll-cell{border-radius:0;border:3px solid #000;background:linear-gradient(#fffdf5,#ecdcb4);
  box-shadow:inset 0 0 0 2px var(--rc,#ccc),0 3px 0 #0004}
.gxp-body .coll-cell.locked{filter:none;opacity:1;background:linear-gradient(#5a5670,#3a3650)}
.gxp-body .coll-cell .cc-name{color:#3d2308;font-weight:900}
.gxp-body .coll-cell.locked .cc-name{color:#d9d5e6}
.gxp-body .coll-tab{border-radius:0;border:2px solid #000;background:#1c1206}
.gxp-body .coll-tab.on{background:#3d2a10;box-shadow:0 0 0 2px #ffd75e}

/* =========================================================
   商店（v8.2 重做）：左邊店員＋每日禮＋今日特賣，右邊分類頁籤＋商品格子
   ========================================================= */
.shx-body{flex:1;min-height:0;display:flex;gap:12px;padding:12px 14px 14px}
.shx-left{flex:0 0 300px;display:flex;flex-direction:column;gap:8px}
.shx-right{flex:1;min-width:0;display:flex;flex-direction:column;gap:8px}
/* 店員：站在木頭櫃檯後面，頭上有對話泡泡 */
.shx-keeper-box{position:relative;flex:1;min-height:0;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;
  border:4px solid #000;overflow:hidden;
  background:radial-gradient(70% 60% at 50% 70%,#ffe9a044,#0000 70%),repeating-linear-gradient(0deg,#6b4420 0 22px,#5e3c1c 22px 24px),#6b4420;
  box-shadow:inset 0 0 30px #0009,0 5px 0 #00000059}
.shx-keeper{position:relative;z-index:1;cursor:pointer;margin-bottom:-4px;filter:drop-shadow(0 6px 8px #0008);transition:transform .12s}
.shx-keeper:hover{transform:translateY(-3px)}
.shx-counter{position:relative;z-index:2;align-self:stretch;height:34px;display:flex;align-items:center;justify-content:center;
  border-top:4px solid #000;background:repeating-linear-gradient(92deg,var(--wood) 0 7px,var(--wood-d) 7px 11px,var(--wood-l) 11px 15px)}
.shx-counter span{padding:1px 10px;font-size:12px;font-weight:900;letter-spacing:2px;color:#3d2308;background:linear-gradient(#fff6d8,#f0c86a);border:2px solid #000}
.shx-bubble{position:absolute;left:10px;right:10px;top:10px;z-index:3;padding:7px 10px;font-size:12.5px;font-weight:800;line-height:1.5;color:#3d2308;
  background:#fffdf5;border:3px solid #000;box-shadow:0 3px 0 #0006}
.shx-bubble::after{content:"";position:absolute;left:50%;bottom:-11px;margin-left:-8px;border:8px solid transparent;border-top-color:#000;border-bottom:0}
.shx-bubble.pop{animation:shx-pop .3s cubic-bezier(.2,1.6,.4,1)}
@keyframes shx-pop{from{transform:scale(.85);opacity:.4}}
/* 每日禮與今日特賣 */
.shx-daily,.shx-deal{position:relative;flex:0 0 auto;display:flex;align-items:center;gap:8px;padding:8px 10px;border:4px solid #000;color:#3d2308;
  background:linear-gradient(#fffaea,#f3e3bb);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #d8c18a,0 4px 0 #00000059}
.shx-daily:not(.done){background:linear-gradient(#fff6c9,#ffd98a)}
.shx-chest{width:40px;height:40px;flex:0 0 auto}
.shx-daily:not(.done) .shx-chest{animation:shx-chest 1s ease-in-out infinite}
@keyframes shx-chest{0%,100%{transform:translateY(0) rotate(0)}30%{transform:translateY(-4px) rotate(-6deg)}60%{transform:translateY(0) rotate(5deg)}}
.shx-dtxt{flex:1;min-width:0;display:flex;flex-direction:column;line-height:1.35}
.shx-dtxt b{font-size:13.5px;font-weight:900}
.shx-dtxt span{font-size:10.5px;font-weight:800;color:#6b4a1e}
.shx-dtxt span .pxi{width:13px;height:13px;vertical-align:-2px}
.shx-dtxt em{font-style:normal;display:flex;align-items:center;gap:3px;margin-top:2px;font-size:10.5px;font-weight:900;color:#c2372f}
.shx-dtxt em .pxi{width:13px;height:13px}
.shx-dtxt em i{font-style:normal;font-variant-numeric:tabular-nums}
.shx-daily .px-btn{flex:0 0 auto;padding:6px 12px;font-size:13px}
.shx-deal{background:linear-gradient(#fff0e6,#f6d0c0);padding-top:16px}
.shx-ribbon{position:absolute;left:-4px;top:-10px;padding:1px 9px;font-size:10.5px;font-weight:900;letter-spacing:1px;color:#fff;
  background:linear-gradient(#f0736f,#c2372f);border:2px solid #000}
.shx-ico{position:relative;flex:0 0 auto;width:52px;height:52px;display:grid;place-items:center;
  background:#8b8b8b;border:3px solid #000;box-shadow:inset 3px 3px 0 #373737,inset -3px -3px 0 #ffffffb0}
.shx-ico .pxi{width:34px;height:34px;filter:drop-shadow(0 2px 0 #0006)}
.shx-ico b{position:absolute;right:2px;bottom:0;font-size:11px;font-weight:900;color:#fff;text-shadow:2px 2px 0 #3f3f3f;line-height:1.1}
/* 價格鈕 */
.shx-buy{flex:0 0 auto;display:flex;align-items:center;gap:3px;padding:7px 10px;cursor:pointer;font-family:inherit;font-size:14px;font-weight:900;color:#3d2308;
  --f1:#ffd98a; --f2:#f0b429; --hi:#fff3c4; --lo:#a9761a;
  background:linear-gradient(var(--f1),var(--f2));border:3px solid #000;box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo),0 3px 0 #0006}
.shx-buy .pxi{width:17px;height:17px}
.shx-buy s{font-size:11px;color:#8a6a3a;margin-right:2px}
.shx-buy:hover{filter:brightness(1.07)}
.shx-buy:active{transform:translateY(2px);box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo)}
.shx-buy.off{--f1:#cfcfcf; --f2:#a5a5a5; --hi:#e2e2e2; --lo:#6f6f6f;color:#4a4a4a}
.shx-buy.deal{--f1:#ffb3a8; --f2:#e0493b; --hi:#ffd9d4; --lo:#8e1f16;color:#fff;text-shadow:0 1px 0 #0006}
.shx-buy.deal s{color:#ffe0dc}
/* 右邊：分類頁籤＋商品格子 */
.shx-tabs{display:flex;gap:6px;flex:0 0 auto}
.shx-tab{display:flex;align-items:center;gap:5px;padding:6px 12px;cursor:pointer;font-family:inherit;font-size:13.5px;font-weight:900;color:#1c1c1c;
  --f1:#d4d4d4; --f2:#b8b8b8; --hi:#efefef; --lo:#8a8a8a;
  background:linear-gradient(var(--f1),var(--f2));border:3px solid #000;box-shadow:inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo),0 3px 0 #0006}
.shx-tab .pxi{width:18px;height:18px}
.shx-tab.on{--f1:#ffd98a; --f2:#f0b429; --hi:#fff3c4; --lo:#a9761a;transform:translateY(-2px)}
.shx-grid{flex:1;min-height:0;overflow-y:auto;display:grid;grid-template-columns:1fr 1fr;gap:8px;align-content:start;padding:2px}
.shx-item{display:flex;align-items:center;gap:8px;padding:8px 10px;border:3px solid #000;color:#3d2308;
  background:linear-gradient(#fdf2d8,#ecd6a6);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #c9ab72,0 3px 0 #00000059;
  animation:sto-in .3s cubic-bezier(.2,1.4,.4,1) var(--d,0s) both}
.shx-info{flex:1;min-width:0;display:flex;flex-direction:column;line-height:1.35}
.shx-info b{font-size:14px;font-weight:900}
.shx-info span{font-size:11px;font-weight:700;color:#6b4a1e}
.shx-item.nope,.shx-deal.nope{animation:shx-nope .3s ease}
@keyframes shx-nope{25%{transform:translateX(-5px)}60%{transform:translateX(4px)}}
#scr-shop .shop-wallet .cur,#scr-storage .shop-wallet .cur{background:linear-gradient(#1c1206,#0d0803);border:2.5px solid var(--gold-d);border-radius:22px;color:#ffe9a8;font-weight:900;padding:4px 12px}
#scr-shop .shop-wallet .cur .pxi,#scr-storage .shop-wallet .cur .pxi{width:16px;height:16px;vertical-align:-3px}

/* =========================================================
   圖鑑（v8.2 重做）：物品欄格子＋右邊的角色卡（展示台／名牌／三個分頁）
   ========================================================= */
#scr-dex .dex-body{height:auto;flex:1;min-height:0;gap:12px;padding:10px 14px 14px}
#scr-dex .dex-left{min-height:0}
#scr-dex .dex-filters{gap:6px;margin-bottom:8px}
#scr-dex .dex-f{display:flex;align-items:center;gap:4px;padding:4px 7px;border-radius:0;font-size:12px;cursor:pointer}
#scr-dex .dex-f em{font-style:normal;font-size:10.5px;font-weight:900;padding:0 4px;color:#fff;background:#1c1206;border:1.5px solid #000}
#scr-dex .dex-f[style]{box-shadow:inset 0 -4px 0 var(--fc),inset 2px 2px 0 var(--hi),inset -2px -2px 0 var(--lo),0 3px 0 #0006!important}
#scr-dex .dex-grid{gap:8px;grid-template-columns:repeat(auto-fill,minmax(80px,1fr));align-content:start;padding:3px}
/* 格子：物品欄的深灰凹槽，上緣一條稀有度色 */
/* 右邊：角色卡 */
#scr-dex .dex-detail{width:380px;padding:0;overflow:hidden;border:4px solid #000;border-radius:0;background:linear-gradient(#fdf2d8,#ecd6a6);
  box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #c9ab72,0 5px 0 #00000059}
.dxx{height:100%;display:flex;flex-direction:column}
.dxx-plate{flex:0 0 auto;display:flex;align-items:center;justify-content:space-between;gap:8px;row-gap:4px;flex-wrap:wrap;padding:7px 12px;border-bottom:3px solid #00000026}
/* v9.9 名字長、徽章又多（例：瑟琴槍叔＋幹超瑟 ★★★★＋Lv.30＋1/1）→ 徽章換到第二行，不要把名字擠成「瑟琴…」 */
.dxx-name{flex:1 0 auto;max-width:100%;font-size:20px;font-weight:900;letter-spacing:1px;color:#3d2308;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.dxx-badges{display:flex;gap:4px;flex:0 0 auto}
.dxx-chip{font-style:normal;padding:1px 7px;font-size:11px;font-weight:900;color:var(--c,#fff);background:#1c1206;border:2px solid #000;white-space:nowrap}
.dxx-chip.lv{color:#3d2308;background:#fffdf5}
.dxx-chip.gold{color:#3d2308;background:linear-gradient(#fff3c4,#ffca4a)}
.dxx-chip.boss{color:#fff;background:#c2372f}
.dxx-chip.dark{color:#c9c5d6;background:#3a3650}
.dxx-tabs{flex:0 0 auto;display:flex;gap:4px;padding:6px 10px 0}
.dxx-tab{flex:1;padding:4px 0;cursor:pointer;font-family:inherit;font-size:12.5px;font-weight:900;color:#6b4a1e;
  background:#0000000f;border:2px solid #0000002e;border-bottom:0}
.dxx-tab.on{color:#3d2308;background:#fffdf5;border-color:#000}
.dxx-page{flex:1;min-height:0;overflow-y:auto;margin:0 10px 10px;padding:8px 10px;background:#fffdf5;border:2px solid #000}
#scr-dex .dx-sec{margin:6px 0 4px;font-size:11px;letter-spacing:2px;color:#8a5a12;border-bottom:2px solid #0000001f}
#scr-dex .dx-sec:first-child{margin-top:0}
#scr-dex .dx-desc{font-size:12px;line-height:1.7;color:#4a2a08}
#scr-dex .dx-stat .dxs-bar{height:12px;border-radius:0;background:#2a2638;border:2px solid #000}
#scr-dex .dx-stat .dxs-bar i{border-radius:0;box-shadow:inset 0 2px 0 #ffffff66}
#scr-dex .dx-mini{margin-top:6px;gap:4px 12px;font-size:11px}
.dxx-hint{height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;text-align:center;font-size:12.5px;font-weight:800;line-height:1.6;color:#6b4a1e}
.dxx-hint .pxi{width:42px;height:42px}
.dxx-evo{display:flex;align-items:center;justify-content:center;gap:8px;margin:2px 0 8px}
.dxx-evo span{display:flex;flex-direction:column;align-items:center;padding:3px;background:linear-gradient(#fdf2d8,#ecd6a6);border:2px solid #000}
.dxx-evo span.got{background:linear-gradient(#fff6c9,#ffd98a);box-shadow:0 0 10px #ffd75e}
.dxx-evo span b{font-size:11px;font-weight:900;color:#3d2308}
.dxx-evo em{font-style:normal;font-size:10.5px;font-weight:900;color:#b4530a;text-align:center;max-width:70px}
.dxx-evo em::after{content:"▶";display:block;font-size:18px;color:#3d2308}

/* =========================================================
   基地夥伴互動（v8.2）：點他會動、冒愛心；左下角名牌＋好感度；換夥伴按鈕
   ========================================================= */
#scr-base .base-cat-btn{rotate:var(--lean,0deg);transform-origin:50% 100%;transition:rotate .25s ease-out}
#scr-base .base-cat-btn:hover{transform:none;filter:brightness(1.05)}
#scr-base .base-cat-btn::before{bottom:6px}
.base-cat-btn.m-hop{animation:m-hop .5s cubic-bezier(.3,1.6,.5,1)}
@keyframes m-hop{30%{transform:translateY(-26px) scaleY(1.05)}60%{transform:translateY(0) scale(1.05,.92)}80%{transform:translateY(-6px)}}
.base-cat-btn.m-wiggle{animation:m-wiggle .5s ease-in-out}
@keyframes m-wiggle{20%{transform:rotate(-7deg)}40%{transform:rotate(6deg)}60%{transform:rotate(-4deg)}80%{transform:rotate(2deg)}}
.base-cat-btn.m-squash{animation:m-squash .45s ease-out}
@keyframes m-squash{25%{transform:scale(1.12,.84)}55%{transform:scale(.94,1.08)}80%{transform:scale(1.03,.97)}}
.base-cat-btn.m-spin{animation:m-spin .6s cubic-bezier(.4,1.4,.5,1)}
@keyframes m-spin{0%{transform:perspective(600px) rotateY(0)}100%{transform:perspective(600px) rotateY(360deg)}}
.base-cat-btn.m-look{animation:m-look 1.4s ease-in-out}
@keyframes m-look{15%,45%{transform:scaleX(-1)}60%,100%{transform:none}}
.base-cat-btn.m-dizzy{animation:m-dizzy 1.4s ease-in-out}
@keyframes m-dizzy{0%{transform:rotate(0)}20%{transform:rotate(-12deg) translateX(-8px)}40%{transform:rotate(10deg) translateX(8px)}
  60%{transform:rotate(-8deg) translateX(-5px)}80%{transform:rotate(5deg)}100%{transform:none}}
.mz-p{position:absolute;z-index:5;width:24px;height:24px;pointer-events:none;filter:drop-shadow(0 2px 0 #0008);
  animation:mz-p 1.1s ease-out both}
@keyframes mz-p{0%{opacity:0;transform:translate(0,0) scale(.4)}15%{opacity:1;transform:translate(calc(var(--dx)*.2),calc(var(--dy)*.2)) scale(1.2)}
  100%{opacity:0;transform:translate(var(--dx),var(--dy)) scale(.9) rotate(var(--r))}}
/* 左下角：名牌＋好感度愛心＋換夥伴 */
.base-mbar{position:absolute;left:14px;bottom:12px;z-index:3;display:flex;align-items:center;gap:8px}
.base-plate{display:flex;align-items:center;gap:8px;padding:4px 10px;border:3px solid #000;
  background:linear-gradient(#fffaea,#f3e3bb);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #d8c18a,0 3px 0 #0006}
.base-plate:empty{display:none}
.base-plate b{font-size:14px;font-weight:900;color:#3d2308}
.bp-hearts{display:flex;gap:2px}
.bp-hearts .pxi{width:15px;height:15px;opacity:.3;filter:grayscale(1)}
.bp-hearts .pxi.on{opacity:1;filter:drop-shadow(0 1px 0 #0006)}
#base-swap{padding:5px 12px;font-size:13px}

/* =========================================================
   雜項（v8.2）：確認視窗改成全站一致的奶油色像素面板
   ========================================================= */
#confirm-overlay .confirm-card{width:400px;padding:18px 20px 16px;border-radius:0;border:4px solid #000;color:#3d2308;
  background:linear-gradient(#fffaea,#f3e3bb);box-shadow:inset 2px 2px 0 #fff,inset -2px -2px 0 #d8c18a,0 6px 0 #0000008c,0 18px 40px #000c;
  animation:cf-in .22s cubic-bezier(.2,1.5,.4,1)}
@keyframes cf-in{from{opacity:0;transform:scale(.85)}}
#confirm-overlay .confirm-msg{font-size:15px;font-weight:800;line-height:1.7;color:#3d2308;white-space:pre-line}
/* v9.0 設定：畫面震動／閃光效果並排在同一列 */
#scr-settings .set-row.two{flex-direction:row;gap:16px}
#scr-settings .set-row.two .set-label{flex:1}
#scr-settings .set-label small{margin-left:4px}
#scr-settings .set-group.fx{gap:10px;padding-top:9px;padding-bottom:10px}
#scr-settings .set-group.fx .set-label .seg.mini{margin-left:auto}
/* v9.0：確認視窗永遠在最上面（養成機 74、召喚 70 的覆蓋層裡也會叫它：銷毀卡槽） */
#confirm-overlay{z-index:95}

/* v9.13 已領取的信留著（變淡），由玩家決定刪不刪：上面「刪除已領取」、每封一顆「刪除」 */
.mail-top .mt-btns{display:flex;gap:8px;flex:0 0 auto}
.mail-top .px-btn .pxi{width:16px;height:16px;vertical-align:-3px;margin-right:4px}
#scr-mail .mail-item.got .mi-reward{flex:1;min-width:0}
#scr-mail .mi-del{flex:0 0 auto;display:inline-flex;align-items:center;gap:3px;padding:4px 10px;font:inherit;font-size:12px;font-weight:900;color:#7a2a20;
  background:#fff3ee;border:2px solid #000;box-shadow:0 2px 0 #0003;cursor:pointer}
#scr-mail .mi-del .pxi{width:16px;height:16px}
#scr-mail .mi-del:hover{background:#ffe0d6}

/* v9.13.1 圖鑑「說明」放角色簡介（下面另有「能力說明」） */
#scr-dex .dx-desc.dx-bio{font-size:13px;font-weight:800;color:#3d2308}
