/* ===== 创世盲盒 占位美术样式 (正式素材到位后逐项替换) ===== */

/* ---- 品牌字体体系 (免费商用, 双语就绪) ----
   展示层: 站酷快乐体(中文卡通) + Baloo 2(英文/数字圆胖卡通)
   正文层: Noto Sans SC 兜底 */
body { font-family: 'Baloo 2', 'Noto Sans SC', system-ui, sans-serif; }
h1, h2, h3, .brand-font, .nav-btn, .open-btn, .el-name {
  font-family: 'Baloo 2', 'ZCOOL KuaiLe', 'Noto Sans SC', sans-serif;
}
h1 { letter-spacing: .08em; }

.holo-text {
  background: linear-gradient(120deg, #f6d078, #fff6d8, #b48cff, #7de3ff, #f6d078);
  background-size: 300% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: holo-slide 6s linear infinite;
}
@keyframes holo-slide { to { background-position: 300% 0; } }

.nav-btn { color: #9ca3af; transition: color .2s; position: relative; padding-bottom: 2px; }
.nav-btn:hover, .nav-btn.active { color: #fcd34d; }
.nav-btn.active::after {
  content: ''; position: absolute; left: 10%; right: 10%; bottom: -4px; height: 2px;
  border-radius: 2px; background: linear-gradient(90deg, transparent, #fcd34d, transparent);
}

.stat-chip {
  display: inline-flex; align-items: center;
  padding: .35rem .85rem; border-radius: 9999px;
  background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.1);
  color: #cbd5e1; backdrop-filter: blur(4px);
}

/* 稀有度图例卡 (接入 gem_{rarity}.png 宝石素材) */
.legend-card {
  border: 1px solid rgba(255,255,255,.09); border-radius: .8rem;
  padding: .8rem .4rem .7rem; background: rgba(255,255,255,.03);
  backdrop-filter: blur(4px); transition: transform .15s, border-color .2s;
}
.legend-card:hover { transform: translateY(-3px); border-color: rgba(252,211,77,.4); }
.legend-card img { width: 2.1rem; height: 2.1rem; object-fit: contain; margin: 0 auto .35rem; filter: drop-shadow(0 2px 8px rgba(0,0,0,.5)); }

.open-btn {
  padding: 0.9rem 2.4rem;
  border-radius: 9999px;
  font-weight: 700;
  letter-spacing: .05em;
  color: #1a1206;
  background: linear-gradient(135deg, #f6d078, #e8b04b, #f9e8b0);
  box-shadow: 0 0 30px rgba(246, 208, 120, .35), inset 0 1px 0 rgba(255,255,255,.5);
  transition: transform .15s, box-shadow .2s;
}
.open-btn:hover { transform: translateY(-2px) scale(1.02); box-shadow: 0 0 50px rgba(246,208,120,.55); }
.open-btn:disabled { opacity: .5; pointer-events: none; }
.ghost-btn {
  padding: .5rem 1.4rem; border-radius: 9999px; font-size: .85rem;
  border: 1px solid rgba(255,255,255,.2); color: #d1d5db; transition: all .2s;
}
.ghost-btn:hover { border-color: #fcd34d; color: #fcd34d; }

/* ---- 盒体 v7 (第三批赛博素材 img2/box_closed.webp + box_glow_*.webp) ---- */
.box-cube {
  --box-img: url('/static/img2/box_closed.webp');
  width: 16rem; height: 16rem; margin: 0 auto;
  background: var(--box-img) center / contain no-repeat;
  animation: box-idle 6s ease-in-out infinite, box-breathe 3.6s ease-in-out infinite;
  position: relative;
}
.box-cube .face { display: none; }
/* 活体流光: 以盒子自身为 mask, 一道斜向光带周期性扫过棱缝 → "活过来"的核心 */
.box-cube::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  -webkit-mask: var(--box-img) center / contain no-repeat;
          mask: var(--box-img) center / contain no-repeat;
  background: linear-gradient(115deg,
    transparent 34%, rgba(255,255,255,0) 42%,
    var(--sheen-c, rgba(140,245,255,.5)) 50%,
    rgba(255,255,255,0) 58%, transparent 66%);
  background-size: 300% 300%;
  animation: sheen-flow var(--sheen-t, 4.6s) linear infinite;
  mix-blend-mode: screen;
}
@keyframes sheen-flow {
  0%   { background-position: 120% 120%; }
  100% { background-position: -20% -20%; }
}
/* 呼吸光晕: 盒上氖光随呼吸收放 */
@keyframes box-breathe {
  0%,100% { filter: drop-shadow(0 22px 44px rgba(0,0,0,.6)) drop-shadow(0 0 16px rgba(90,220,255,.14)); }
  50%     { filter: drop-shadow(0 22px 44px rgba(0,0,0,.6)) drop-shadow(0 0 34px rgba(90,220,255,.34)); }
}
@keyframes box-idle {
  0%,100% { transform: translateY(0) rotate(-1.5deg); }
  50%     { transform: translateY(-14px) rotate(1.5deg); }
}
.box-cube.summoning { animation: box-summon .85s ease-in-out infinite; --sheen-t: 1.15s; }
@keyframes box-summon {
  0%,100% { transform: translateY(0) rotate(0deg) scale(1); }
  20% { transform: translateY(-6px) rotate(-3deg) scale(1.03); }
  50% { transform: translateY(-18px) rotate(2.5deg) scale(1.06); }
  80% { transform: translateY(-4px) rotate(-2deg) scale(1.02); }
}
/* 稀有度充能 (JS 加 class): 换发光盒体 + 流光变色 (不再限定 .summoning, opening 阶段也保持) */
.box-cube.charge-common    { --box-img: url('/static/img2/box_glow_common.webp');    --sheen-c: rgba(240,246,255,.6);  filter: drop-shadow(0 0 36px rgba(210,225,245,.55)); }
.box-cube.charge-rare      { --box-img: url('/static/img2/box_glow_rare.webp');      --sheen-c: rgba(125,235,255,.65); filter: drop-shadow(0 0 42px rgba(80,215,255,.6)); }
.box-cube.charge-epic      { --box-img: url('/static/img2/box_glow_epic.webp');      --sheen-c: rgba(210,160,255,.68); filter: drop-shadow(0 0 48px rgba(180,110,255,.65)); }
.box-cube.charge-legendary { --box-img: url('/static/img2/box_glow_legendary.webp'); --sheen-c: rgba(255,225,140,.72); filter: drop-shadow(0 0 54px rgba(255,195,80,.7)); }
.box-cube.charge-mythic    { --box-img: url('/static/img2/box_glow_mythic.webp');    --sheen-c: rgba(255,140,120,.75); filter: drop-shadow(0 0 64px rgba(255,90,70,.75)); }
.box-cube.summoning.charge-mythic { animation: box-summon .85s ease-in-out infinite, mythic-flicker .35s linear infinite; }
@keyframes mythic-flicker { 50% { opacity: .88; } }

/* 开盒关键帧 v7: 不再换 fx 贴图, 保持充能盒体 + 提亮, 爆发交给 canvas 粒子 */
.box-cube.opening-mid {
  animation: none; transform: scale(1.05);
  filter: brightness(1.3) saturate(1.15) drop-shadow(0 0 52px rgba(220,235,255,.55));
}
.box-cube.opening-mid::after { animation-duration: .4s; }
.box-cube.opening-burst {
  animation: burst-pop .55s cubic-bezier(.25,1.4,.4,1) both;
  filter: brightness(1.55) saturate(1.2) drop-shadow(0 0 80px rgba(230,240,255,.65));
}
@keyframes burst-pop {
  from { transform: scale(.98); opacity: .85; }
  55%  { transform: scale(1.2); }
  to   { transform: scale(1.12); opacity: 1; }
}
/* 爆发粒子画布 (代码光效, 替代 fx_*.png) */
#burst-fx {
  position: absolute; left: 50%; top: 50%;
  width: 46rem; height: 46rem; max-width: 96vw; max-height: 96vw;
  transform: translate(-50%, -50%);
  pointer-events: none; z-index: 3; mix-blend-mode: screen;
}

/* 幕一环境粒子 (P1 素材 particles_dust, 缓慢漂浮) */
.act-particles {
  position: absolute; inset: 0; pointer-events: none; z-index: 0;
  background: url('/static/opt/particles_dust.webp') center / 620px repeat;
  opacity: .22; animation: dust-drift 26s linear infinite;
}
@keyframes dust-drift { to { background-position: 310px -620px; } }

/* ---- 幕二: 元素条目 ---- */
.element-row {
  display: flex; flex-direction: column; gap: .38rem;
  padding: .72rem 1rem .68rem; border-radius: .8rem;
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.025));
  border: 1px solid rgba(255,255,255,.09);
  opacity: 0; transform: translateY(14px) scale(.98);
  animation: el-in .45s cubic-bezier(.2,.9,.3,1.2) forwards;
}
@keyframes el-in { to { opacity: 1; transform: none; } }
.el-top { display: flex; align-items: center; gap: .6rem; min-width: 0; }
.el-bot {
  display: flex; align-items: center; gap: .7rem;
  padding-top: .34rem; border-top: 1px dashed rgba(255,255,255,.08);
}
.element-row .slot-tag { font-size: .68rem; color: #9ca3af; flex: none; display: inline-flex; align-items: center; gap: .35rem; }
.slot-icon { width: 1.05rem; height: 1.05rem; object-fit: contain; opacity: .85; flex: none; filter: drop-shadow(0 0 4px rgba(160,190,255,.35)); }
.element-row .el-name { font-weight: 800; font-size: 1rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.el-rbadge {
  margin-left: auto; flex: none;
  font-size: .62rem; font-weight: 800; letter-spacing: .1em;
  padding: .14rem .5rem; border-radius: .4rem;
}
.rb-common    { color: #cbd5e1; background: rgba(203,213,225,.12); border: 1px solid rgba(203,213,225,.25); }
.rb-rare      { color: #5eead4; background: rgba(94,234,212,.1);  border: 1px solid rgba(94,234,212,.3); }
.rb-epic      { color: #c084fc; background: rgba(192,132,252,.12); border: 1px solid rgba(192,132,252,.32); }
.rb-legendary { color: #f6d078; background: rgba(246,208,120,.12); border: 1px solid rgba(246,208,120,.38); }
.rb-mythic    { color: #ff8a7a; background: rgba(255,122,110,.13); border: 1px solid rgba(255,122,110,.4); }
.element-row .el-price { margin-left: auto; font-variant-numeric: tabular-nums; font-size: 1rem; font-weight: 800; flex: none; }
.el-unit { font-size: .68rem; color: #9ca3af; font-weight: 600; }

.r-common    { color: #cbd5e1; }
.r-rare      { color: #7de3ff; }
.r-epic      { color: #c9a4ff; }
.r-legendary { color: #f6d078; }
.r-mythic    { color: #ff7a6e; text-shadow: 0 0 12px rgba(255,120,90,.6); }
.row-legendary { border-color: rgba(246,208,120,.45); background: rgba(246,208,120,.06); }
.row-mythic { border-color: rgba(255,110,90,.55); background: rgba(255,90,70,.08); box-shadow: 0 0 24px rgba(255,100,80,.15); }

/* 首铸徽章 (正式素材 assets/badge_first_mint.png; 文字由 font-size:0 隐藏) */
.first-mint-badge {
  display: inline-block; flex: none;
  width: 2.4rem; height: 2.8rem;
  background: url('/static/opt/badge_first_mint.webp') center / contain no-repeat;
  font-size: 0; color: transparent;
  filter: drop-shadow(0 0 12px rgba(255,215,120,.55));
  animation: fm-pop .5s cubic-bezier(.3,1.6,.5,1) both;
}
@keyframes fm-pop { from { transform: scale(0); } }

/* ---- 幕三: 结算卡 (5:7 匹配卡框素材 750×1050) ---- */
/* 幕三 v17: HoloCard 引擎接管 — .final-card 只剩外壳定位, 旧翻卡三层结构已退役 */
/* v27 放大: 与 L2 同法 — 宽 = min(视口 88%, 可用高×5/7, 360px); 可用高 = 视口 − 鉴定按钮区(≈9.4rem) − 状态行/边距(≈4.6rem)。
   鉴定后按钮区隐藏, 显示 final-stats + 按钮 (≈14rem) 时卡稍收以保持同屏 (见 #act3.identified) */
.final-card { --a3-avail: calc(100dvh - 14rem - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px));
  width: min(88vw, calc(var(--a3-avail) * 5 / 7), 360px); position: relative; z-index: 1;
  transition: width .5s cubic-bezier(.2,.8,.3,1); }
@supports not (height: 100dvh) { .final-card { --a3-avail: calc(100vh - 14rem - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px)); } }
#act3.identified .final-card { --a3-avail: calc(100dvh - 17.5rem - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px)); }
#act3 { padding-top: 1rem !important; padding-bottom: 1rem !important; }
#final-card-status { margin-top: .35rem !important; }
#act3-identify { margin-top: .25rem !important; }
#final-stats { margin-top: .9rem !important; }
.act3-btns { margin-top: 1rem !important; }
#final-hc { width: 100%; animation: hc-drop-in .7s cubic-bezier(.2,1.1,.3,1); }
@keyframes hc-drop-in { from { transform: translateY(-36px) scale(.86); opacity: 0; } }
/* 铸造中占位: spinner 图不铺满, 居中呼吸 */
#final-hc .l-art img.minting {
  object-fit: contain; inset: 30%; width: 40%; height: 40%;
  animation: minting-pulse 1.6s ease-in-out infinite;
}
@keyframes minting-pulse { 50% { opacity: .45; } }
/* 鉴定按钮: 金色主按钮 + 呼吸光晕 */
.identify-btn {
  padding: .8rem 2.6rem; border-radius: 999px; border: 1px solid rgba(246,208,120,.55);
  background: linear-gradient(160deg, #6e4e14, #3a2a0c);
  color: #ffe9b0; font-weight: 900; font-size: 1rem; letter-spacing: .35em; text-indent: .35em;
  cursor: pointer; transition: transform .15s;
  box-shadow: 0 0 24px rgba(246,208,120,.28), inset 0 1px 0 rgba(255,255,255,.15);
  animation: identify-glow 2.2s ease-in-out infinite;
}
.identify-btn:active { transform: scale(.95); }
@keyframes identify-glow {
  50% { box-shadow: 0 0 40px rgba(246,208,120,.5), inset 0 1px 0 rgba(255,255,255,.15); }
}
/* 卡框: v22 起列表卡统一走 .rcard + holo/frame_{tier}.webp (symlink→card-site, 见文件末尾); 旧 assets/frame_*.png 已删除 */
.fc-common    { background: linear-gradient(160deg,#1d232e,#2b3442); }
.fc-rare      { background: linear-gradient(160deg,#0e2733,#155066); box-shadow: 0 0 40px rgba(125,227,255,.25); }
.fc-epic      { background: linear-gradient(160deg,#221436,#432575); box-shadow: 0 0 50px rgba(180,140,255,.3); }
.fc-legendary { background: linear-gradient(160deg,#2e2210,#6e4e14); box-shadow: 0 0 60px rgba(246,208,120,.4); }
.fc-mythic    { background: linear-gradient(160deg,#330f14,#7a1f1a); box-shadow: 0 0 80px rgba(255,110,80,.5); }

/* 品相印章 (正式素材 assets/stamp_{condition}.png; 文字由 font-size:0 隐藏) */
.cond-stamp {
  display: inline-block; width: 4.8rem; height: 4.8rem;
  background: center / contain no-repeat;
  font-size: 0; color: transparent;
  transform: rotate(-8deg);
  filter: drop-shadow(0 4px 10px rgba(0,0,0,.5));
  animation: stamp-in .4s cubic-bezier(.3,1.8,.4,1) both;
}
@keyframes stamp-in { from { transform: rotate(-8deg) scale(2.4); opacity: 0; } }
.cond-flawless { background-image: url('/static/opt/stamp_flawless.webp'); filter: drop-shadow(0 0 14px rgba(255,220,140,.7)); }
.cond-pristine { background-image: url('/static/opt/stamp_pristine.webp'); }
.cond-fine     { background-image: url('/static/opt/stamp_fine.webp'); }
.cond-standard { background-image: url('/static/opt/stamp_standard.webp'); }

/* ---- 画廊卡片 (套用 fc-{rarity} 卡框素材) ---- */
.gallery-card {
  border-radius: .9rem; padding: 1.2rem 1.1rem 1.6rem; aspect-ratio: 5/7;
  display: flex; flex-direction: column; justify-content: space-between;
  cursor: pointer; transition: transform .15s;
  position: relative; overflow: hidden;
}
.gallery-card > * { position: relative; z-index: 1; }
.gallery-card:hover { transform: translateY(-4px); }

/* 幕三高稀有度彩带/星火飘落 (P1 素材 particles_spark / particles_foil) */
#act3 { position: relative; overflow: hidden; }
#act3-fx { position: absolute; inset: 0; pointer-events: none; z-index: 0; display: none; }
#act3-fx.on { display: block; }
#act3-fx.on::before, #act3-fx.on::after {
  content: ''; position: absolute; left: 0; right: 0; top: -100%; height: 200%;
  background-repeat: repeat; background-size: 430px;
}
#act3-fx.on::before { background-image: url('/static/opt/particles_spark.webp'); opacity: .4; animation: fx-fall 11s linear infinite; }
#act3-fx.on::after  { background-image: url('/static/opt/particles_foil.webp');  opacity: .5; animation: fx-fall 15s linear infinite; }
@keyframes fx-fall { to { transform: translateY(50%); } }
#act3 > *:not(#act3-fx) { position: relative; z-index: 1; }

/* ---- 图鉴 ---- */
.codex-item {
  padding: .8rem 1rem; border-radius: .7rem;
  background: rgba(255,255,255,.03); border: 1px solid rgba(255,255,255,.07);
  display: flex; gap: .8rem; align-items: flex-start;
}
.codex-item .codex-body { flex: 1; min-width: 0; }
/* 未解锁条目缩略卡 (P1 素材 codex_unknown) */
.codex-thumb {
  width: 2.9rem; aspect-ratio: 5/7; flex: none; border-radius: .35rem;
  object-fit: cover; opacity: .85;
  box-shadow: 0 2px 8px rgba(0,0,0,.45);
}
.codex-item.owned { border-color: rgba(246,208,120,.4); background: rgba(246,208,120,.05); }
.codex-item.locked { opacity: .45; filter: grayscale(.6); }
.filter-chip {
  padding: .25rem .8rem; border-radius: 9999px; font-size: .75rem;
  border: 1px solid rgba(255,255,255,.15); color: #9ca3af; cursor: pointer;
}
.filter-chip.active { border-color: #fcd34d; color: #fcd34d; }

.view.hidden, .act.hidden { display: none; }

/* 全站背景 (正式素材 assets/bg_main.jpg + 压暗遮罩保文字对比度) */
body::before {
  content: ''; position: fixed; inset: 0; z-index: -1;
  background:
    linear-gradient(rgba(7,6,11,.68), rgba(7,6,11,.85)),
    url('/static/assets/bg_main.jpg') center / cover no-repeat;
}

/* 卡图 (mock/真实通道生成) */
.card-art-img { width: 100%; max-width: 190px; border-radius: 10px; box-shadow: 0 4px 24px rgba(0,0,0,.5); }

/* ===== 全息闪卡引擎 (holo.js 驱动, 技术参考 simeydotme/pokemon-cards-css) =====
   指针位置写入 CSS 变量: --mx/--my 光斑中心, --posx/--posy 箔纹偏移,
   --rx/--ry 3D 倾角, --hyp 距中心距离, --o 激活透明度 */
.holo-card-fx {
  --mx: 50%; --my: 50%; --posx: 50%; --posy: 50%;
  --rx: 0deg; --ry: 0deg; --hyp: 0; --o: 0;
  transform: perspective(900px) rotateX(var(--rx)) rotateY(var(--ry));
  transform-style: preserve-3d;
  transition: transform .55s cubic-bezier(.2,.8,.3,1);
  will-change: transform;
}
.holo-card-fx.holo-active { transition: transform .12s ease-out; }

/* 闪箔层: 彩虹线性折射 × 径向光斑, color-dodge 提亮 */
.holo-shine {
  position: absolute; inset: 0; z-index: 5; pointer-events: none;
  border-radius: inherit; overflow: hidden;
  opacity: calc(var(--o) * .75);
  transition: opacity .4s;
  background:
    radial-gradient(circle at var(--mx) var(--my), rgba(255,255,255,.9) 0%, rgba(255,255,255,0) 42%),
    repeating-linear-gradient(
      calc(60deg + var(--ry) * 2),
      rgba(255, 90, 120, .55) calc(var(--posx) * .1 + 0%),
      rgba(255, 200, 80, .55) calc(var(--posx) * .1 + 4%),
      rgba(120, 255, 160, .55) calc(var(--posx) * .1 + 8%),
      rgba(90, 200, 255, .55) calc(var(--posx) * .1 + 12%),
      rgba(190, 120, 255, .55) calc(var(--posx) * .1 + 16%),
      rgba(255, 90, 120, .55) calc(var(--posx) * .1 + 20%)
    );
  background-blend-mode: overlay;
  mix-blend-mode: color-dodge;
  filter: brightness(calc(.65 + var(--hyp) * .3)) contrast(1.6) saturate(1.15);
}
/* 眩光层: 跟随指针的高光扫过 */
.holo-glare {
  position: absolute; inset: 0; z-index: 6; pointer-events: none;
  border-radius: inherit; overflow: hidden;
  opacity: calc(var(--o) * .5);
  transition: opacity .4s;
  background: radial-gradient(farthest-corner circle at var(--mx) var(--my),
    rgba(255,255,255,.75) 5%, rgba(255,255,255,.15) 32%, rgba(0,0,0,.45) 90%);
  mix-blend-mode: overlay;
}
/* 稀有度调味: 高稀有闪箔更浓 */
.fc-legendary .holo-shine { opacity: calc(var(--o) * .9); filter: brightness(calc(.7 + var(--hyp) * .35)) contrast(1.8) saturate(1.4) hue-rotate(-12deg); }
.fc-mythic .holo-shine    { opacity: calc(var(--o) * .95); filter: brightness(calc(.75 + var(--hyp) * .4)) contrast(2) saturate(1.6) hue-rotate(160deg); }
.fc-common .holo-shine    { opacity: calc(var(--o) * .45); }
/* 画廊卡 hover 抬升与倾斜共存 */
.gallery-card.holo-card-fx:hover { transform: perspective(900px) rotateX(var(--rx)) rotateY(var(--ry)) translateY(-4px); }

/* ============================================================
   ===== 二期换装 · 卡通乐园资产接线 (img2/, 覆盖上方占位) =====
   ============================================================ */

/* ---- 全站背景: 乐园夜景 (轻压暗保对比度) ---- */
body::before {
  background:
    linear-gradient(rgba(12,8,28,.52), rgba(9,6,22,.78)),
    url('/static/img2/bg_park_night.webp') center / cover no-repeat;
}

/* ---- 主按钮: btn_main2 (第三批金色霓虹框) 九宫格 border-image ----
   素材 688×347, 实测可拉伸区: 列 308~371 / 行 168~229 → slice 上168 右317 下118 左308 */
.open-btn {
  border: 0; border-radius: 0; background: none; box-shadow: none;
  border-image-source: url('/static/img2/btn_main2.webp');
  border-image-slice: 168 317 118 308 fill;
  border-image-width: 34px 64px 24px 62px;
  border-image-repeat: stretch;
  padding: 1rem 4.2rem 1.1rem;
  color: #5b3708;
  text-shadow: 0 1px 0 rgba(255,240,200,.7);
  filter: drop-shadow(0 6px 18px rgba(0,0,0,.45)) drop-shadow(0 0 22px rgba(246,208,120,.28));
  transition: transform .12s, filter .2s;
}
.open-btn:hover {
  transform: translateY(-2px) scale(1.02);
  filter: drop-shadow(0 8px 22px rgba(0,0,0,.5)) drop-shadow(0 0 34px rgba(246,208,120,.5));
}
.open-btn:active {
  filter: brightness(.88) drop-shadow(0 3px 10px rgba(0,0,0,.5));
  transform: translateY(2px) scale(.99);
}
.open-btn:disabled { opacity: .55; pointer-events: none; }

/* ---- 次按钮: btn_secondary (紫全息) 九宫格 ---- */
.ghost-btn {
  border: 0; border-radius: 0;
  border-image-source: url('/static/img2/btn_secondary.webp');
  border-image-slice: 116 150 120 150 fill;
  border-image-width: 26px 36px 28px 36px;
  border-image-repeat: stretch;
  padding: .68rem 1.7rem .74rem;
  color: #e8e4ff;
  text-shadow: 0 1px 3px rgba(0,0,0,.55);
  filter: drop-shadow(0 4px 12px rgba(0,0,0,.4));
  transition: transform .12s, filter .2s;
}
.ghost-btn:hover {
  color: #fff; transform: translateY(-1px);
  filter: drop-shadow(0 5px 14px rgba(0,0,0,.45)) drop-shadow(0 0 18px rgba(150,140,255,.45));
}

/* ---- 统计 chips: chip_stat 九宫格 (深紫金边) ---- */
.stat-chip {
  border: 0; border-radius: 0; background: none; backdrop-filter: none;
  border-image-source: url('/static/img2/chip_stat.webp');
  border-image-slice: 72 96 76 96 fill;
  border-image-width: 14px 22px 15px 22px;
  border-image-repeat: stretch;
  padding: .5rem 1.15rem .55rem;
  color: #ddd6f3;
  filter: drop-shadow(0 3px 8px rgba(0,0,0,.35));
}

/* ---- 声音按钮: btn_round_sound 圆形宝石底 ---- */
#sound-btn {
  width: 2.6rem; height: 2.6rem; border: 0;
  background: url('/static/img2/btn_round_sound.webp') center / contain no-repeat;
  color: #f3ead0; font-size: .8rem;
  filter: drop-shadow(0 3px 8px rgba(0,0,0,.5));
  transition: transform .15s, filter .2s;
}
#sound-btn:hover { transform: scale(1.08); filter: drop-shadow(0 3px 10px rgba(0,0,0,.5)) drop-shadow(0 0 14px rgba(160,150,255,.55)); }

/* ---- 筛选 chips: 选中态改为简洁变色（v12 去掉金色美术素材） ---- */
.filter-chip { transition: all .18s; }
.filter-chip.active {
  border-color: rgba(252,211,77,.75);
  background: rgba(252,211,77,.12);
  color: #fcd34d; font-weight: 700;
  box-shadow: 0 0 10px rgba(252,211,77,.12) inset;
}

/* ---- 稀有度图例: 精灵替换宝石 ---- */
.legend-card {
  border: 0; border-radius: 1rem; background: rgba(20,14,44,.55);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.08), 0 4px 14px rgba(0,0,0,.3);
  padding: .9rem .4rem .75rem;
}
.legend-card:hover { transform: translateY(-4px); box-shadow: inset 0 0 0 1px rgba(252,211,77,.35), 0 8px 20px rgba(0,0,0,.4); }
.legend-card img {
  width: 3.4rem; height: 3.4rem; object-fit: contain; margin: 0 auto .3rem;
  filter: drop-shadow(0 3px 10px rgba(0,0,0,.4));
  transition: transform .25s cubic-bezier(.3,1.5,.5,1);
}
.legend-card:hover img { transform: scale(1.18) translateY(-3px); }

/* ---- 主页盒台: 云朵平台垫底 ---- */
#box-stage::after {
  content: ''; position: absolute; left: 50%; bottom: -3.4rem; z-index: -1;
  width: 21rem; height: 9rem; transform: translateX(-50%);
  background: url('/static/img2/platform.webp') center / contain no-repeat;
  opacity: .95; pointer-events: none;
  animation: cloud-bob 6s ease-in-out infinite;
}
@keyframes cloud-bob {
  0%,100% { transform: translateX(-50%) translateY(0); }
  50%     { transform: translateX(-50%) translateY(-7px); }
}

/* ---- 主标题绸带 + 星星分隔线 ---- */
.ribbon-wrap {
  display: inline-block; position: relative;
  padding: 1.1rem 3.2rem 1.5rem;
  background: url('/static/img2/ribbon_title.webp') center / 100% 100% no-repeat;
  filter: drop-shadow(0 6px 16px rgba(0,0,0,.45));
}
.sparkle-divider {
  height: 44px; margin: 0 auto; max-width: 560px;
  background: url('/static/img2/divider_sparkle.webp') center / contain no-repeat;
  opacity: .9;
}

/* ---- MOMO 迎宾/角色位 ---- */
.box-figure {
  pointer-events: none; user-select: none;
  filter: drop-shadow(0 10px 26px rgba(0,0,0,.55));
}
.box-hero-welcome {
  position: absolute; right: -1rem; bottom: -2.2rem; width: 11.5rem; z-index: 2;
  animation: box-bob 5s ease-in-out infinite;
}
@keyframes box-bob { 0%,100% { transform: translateY(0) rotate(-1deg); } 50% { transform: translateY(-9px) rotate(1.2deg); } }
@media (max-width: 768px) { .box-hero-welcome { width: 8rem; right: -.8rem; bottom: -1.6rem; } }

/* 三幕守护角色 */
.act-box { position: absolute; width: 9rem; z-index: 1; pointer-events: none; filter: drop-shadow(0 8px 22px rgba(0,0,0,.6)); }
#act1 .act-box { left: 6%; bottom: 8%; animation: box-bob 4.5s ease-in-out infinite; }
#act2-box { position: sticky; top: 4.5rem; float: right; width: 7.5rem; margin: -1rem -1rem 0 0; z-index: 5; pointer-events: none; filter: drop-shadow(0 8px 20px rgba(0,0,0,.6)); animation: box-bob 5s ease-in-out infinite; }
#act3 .act-box { right: 5%; top: 12%; animation: box-bob 4s ease-in-out infinite; }
@media (max-width: 900px) { .act-box, #act2-box { display: none; } }

/* ---- 空画廊: 睡觉 MOMO ---- */
#gallery-empty img { filter: drop-shadow(0 10px 24px rgba(0,0,0,.5)); }

/* ---- 加载精灵星星圈 spinner ---- */
.box-spinner {
  width: 3.4rem; height: 3.4rem; display: inline-block;
  background: url('/static/img2/loading_spinner.webp') center / contain no-repeat;
  animation: spin-steps 1.1s steps(8) infinite;
}
@keyframes spin-steps { to { transform: rotate(360deg); } }

/* ---- 页面标题票根/锦旗装饰 ---- */
.page-ticket {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 15rem; padding: 1.05rem 2.6rem 1.15rem;
  background: url('/static/img2/ticket_banner.webp') center / 100% 100% no-repeat;
  color: #6b4a12; text-shadow: 0 1px 0 rgba(255,248,224,.8);
  filter: drop-shadow(0 5px 14px rgba(0,0,0,.4));
}
.tab-flag {
  display: inline-flex; align-items: center; justify-content: center;
  padding: .9rem 2.6rem 1.25rem 2.2rem;
  background: url('/static/img2/tab_active.webp') center / 100% 100% no-repeat;
  color: #5b3708; text-shadow: 0 1px 0 rgba(255,240,200,.6);
  filter: drop-shadow(0 5px 12px rgba(0,0,0,.4));
}

/* ---- 相框: 结算卡图鉴/画廊头像用 ---- */
.photo-frame {
  position: relative;
  background: url('/static/img2/frame_photo.webp') center / 100% 100% no-repeat;
  padding: 9%;
}

/* ---- 路牌步骤区 ---- */
.signpost-img { width: 15rem; filter: drop-shadow(0 8px 20px rgba(0,0,0,.5)); }

/* ---- 开盒动画切换黑洞宇宙背景 ---- */
#reveal-overlay {
  background:
    linear-gradient(rgba(5,3,14,.6), rgba(5,3,14,.78)),
    url('/static/img2/bg_park_night2.webp') center / cover no-repeat fixed;
}

/* ---- 导航 logo 金币旋转入场 ---- */
#nav-logo img { transition: transform .4s cubic-bezier(.3,1.4,.4,1); }
#nav-logo:hover img { transform: rotate(-12deg) scale(1.1); }

/* --- 玩法三步 & 品牌字 --- */
.brand-word { font-family: 'ZCOOL KuaiLe', 'Baloo 2', sans-serif; text-shadow: 0 0 12px rgba(240,180,41,.35); }
.howto-step { display: flex; align-items: flex-start; gap: .9rem; }
.howto-num {
  flex: 0 0 auto; width: 2.2rem; height: 2.2rem; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Baloo 2', sans-serif; font-weight: 800; font-size: 1.1rem; color: #1a1230;
  background: radial-gradient(circle at 32% 28%, #ffe9a8, #f0b429 62%, #c98a12);
  box-shadow: 0 3px 10px rgba(240,180,41,.4), inset 0 -2px 4px rgba(120,70,0,.45);
}

/* ================= v3 「玩起来」大改造 ================= */

/* --- 全局提亮一档: 乐园感 --- */
body::before {
  background: linear-gradient(rgba(16,10,36,.30), rgba(10,7,26,.55)),
    url('/static/img2/bg_park_night.webp') center/cover no-repeat !important;
}

/* --- 卡通描边大标题 (弃彩带图) --- */
.ribbon-wrap { background: none !important; padding: 0 !important; }
.toon-title {
  font-family: 'ZCOOL KuaiLe', 'Baloo 2', sans-serif;
  color: #fff7e6;
  -webkit-text-stroke: 2px #3b1d6e;
  paint-order: stroke fill;
  text-shadow: 0 4px 0 #3b1d6e, 0 7px 18px rgba(0,0,0,.45),
    0 0 32px rgba(255,214,120,.35);
  letter-spacing: .06em;
}
.toon-title .tt-star { -webkit-text-stroke: 0; font-size: .55em; vertical-align: .5em; display: inline-block; animation: star-twinkle 1.6s ease-in-out infinite; }
.toon-title .tt-star:last-child { animation-delay: .8s; }
@keyframes star-twinkle { 0%,100%{ transform: scale(1) rotate(0); opacity:.85;} 50%{ transform: scale(1.35) rotate(18deg); opacity:1;} }

/* --- 跑马灯 (出货播报, 赌场氛围) --- */
#ticker-bar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 35;
  height: 1.9rem; overflow: hidden; pointer-events: none;
  background: linear-gradient(90deg, #2a1650, #1a0f38);  /* v18: 实色, = theme-color, iOS 状态栏透出区与安卓一致 */
  border-bottom: 1px solid rgba(255,214,120,.25);
}
#ticker-track {
  display: inline-flex; gap: 3.5rem; white-space: nowrap; align-items: center; height: 100%;
  padding-left: 100vw; animation: ticker-roll 38s linear infinite;
  font-size: .72rem; color: #e8dcff;
}
#ticker-track .tk-hot { color: #ffd678; font-weight: 700; }
#ticker-track .tk-mythic { color: #ff8a7a; font-weight: 800; text-shadow: 0 0 8px rgba(255,80,60,.6); }
@keyframes ticker-roll { to { transform: translateX(-100%); } }
.view { padding-top: 2.4rem !important; }

/* --- 小圆钮 (玩法/概率, 虾算算式) --- */
.pill-btn {
  display: inline-flex; align-items: center; gap: .35rem;
  padding: .42rem .95rem; border-radius: 999px; font-size: .78rem; font-weight: 700;
  color: #ffe9b8; background: rgba(59,29,110,.75);
  border: 1.5px solid rgba(255,214,120,.4);
  box-shadow: 0 2px 8px rgba(0,0,0,.35), inset 0 1px 0 rgba(255,255,255,.12);
  cursor: pointer; transition: transform .15s, box-shadow .15s;
}
.pill-btn:hover { transform: translateY(-2px) scale(1.04); box-shadow: 0 5px 14px rgba(240,180,41,.3); }
.pill-btn:active { transform: scale(.96); }

/* --- 弹窗 --- */
.box-modal { position: fixed; inset: 0; z-index: 60; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.box-modal.hidden { display: none; }
.box-modal-mask { position: absolute; inset: 0; background: rgba(8,5,20,.72); backdrop-filter: blur(3px); }
.box-modal-box {
  position: relative; max-width: 34rem; width: 100%; max-height: 82vh; overflow-y: auto;
  background: linear-gradient(165deg, #2a1856, #1a0f38);
  border: 2px solid rgba(255,214,120,.45); border-radius: 1.4rem;
  padding: 1.6rem 1.5rem; box-shadow: 0 18px 60px rgba(0,0,0,.6), 0 0 40px rgba(150,90,255,.18);
  animation: modal-pop .28s cubic-bezier(.34,1.56,.64,1);
}
@keyframes modal-pop { from { transform: scale(.85); opacity: 0; } }
.box-modal-close {
  position: absolute; top: .7rem; right: .9rem; width: 2rem; height: 2rem; border-radius: 50%;
  background: rgba(255,255,255,.08); color: #cbb8ff; font-size: 1rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center; transition: all .15s;
}
.box-modal-close:hover { background: rgba(255,100,80,.3); color: #fff; transform: rotate(90deg); }

/* --- 幕一动效 v3: 呼吸膨胀 + 盒缝漏光 + 白闪 + 冲击波 --- */
#summon-wrap { position: relative; }
#leak-glow {
  position: absolute; inset: -18%; border-radius: 50%; opacity: 0; pointer-events: none; z-index: -1;
  background: radial-gradient(circle, var(--leak-c1, rgba(230,235,255,.9)) 0%, var(--leak-c2, rgba(180,200,255,.35)) 42%, transparent 70%);
  filter: blur(14px);
  animation: leak-pulse 1s ease-in-out infinite;
}
@keyframes leak-pulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.12); } }
#leak-glow.leak-common    { --leak-c1: rgba(235,240,255,.95); --leak-c2: rgba(190,205,240,.4); }
#leak-glow.leak-rare      { --leak-c1: rgba(140,230,255,.95); --leak-c2: rgba(60,180,255,.45); }
#leak-glow.leak-epic      { --leak-c1: rgba(200,150,255,.95); --leak-c2: rgba(140,80,255,.5); }
#leak-glow.leak-legendary { --leak-c1: rgba(255,225,140,1);   --leak-c2: rgba(255,180,60,.55); animation: leak-pulse .7s ease-in-out infinite; }
#leak-glow.leak-mythic {
  background: conic-gradient(from 0deg, rgba(255,90,90,.9), rgba(255,200,80,.85), rgba(120,255,180,.8), rgba(100,180,255,.85), rgba(220,110,255,.9), rgba(255,90,90,.9));
  filter: blur(18px) saturate(1.4);
  animation: leak-pulse .5s ease-in-out infinite, leak-spin 2.4s linear infinite;
}
@keyframes leak-spin { to { filter: blur(18px) saturate(1.4) hue-rotate(360deg); } }
/* 盒缝溢光细线 */
#summon-box.seam-lit::before {
  content: ''; position: absolute; left: 12%; right: 12%; top: 46%; height: 3px;
  background: linear-gradient(90deg, transparent, var(--leak-c1, #fff) 30%, #fff 50%, var(--leak-c1, #fff) 70%, transparent);
  filter: blur(1.5px); opacity: .9;
  box-shadow: 0 0 18px 4px var(--leak-c2, rgba(200,210,255,.6));
  animation: seam-flicker .28s linear infinite;
}
@keyframes seam-flicker { 0%,100% { opacity: .95; } 50% { opacity: .55; } }
#flash-white {
  position: fixed; inset: 0; z-index: 70; background: #fff; opacity: 0; pointer-events: none;
}
#shockwave {
  position: fixed; z-index: 69; left: 50%; top: 50%; width: 10px; height: 10px;
  margin: -5px 0 0 -5px; border-radius: 50%; opacity: 0; pointer-events: none;
  border: 3px solid rgba(255,255,255,.9);
  box-shadow: 0 0 30px 6px rgba(255,220,140,.55), inset 0 0 20px rgba(255,255,255,.4);
}

/* --- 背包 (原画廊) --- */
.pack-stat {
  background: linear-gradient(160deg, rgba(59,29,110,.7), rgba(28,14,60,.85));
  border: 1.5px solid rgba(255,214,120,.35); border-radius: 1rem;
  padding: .9rem 1rem; text-align: center;
}
.pack-stat .ps-num { font-family: 'Baloo 2', sans-serif; font-weight: 800; font-size: 1.55rem; color: #ffd678; line-height: 1.1; }
.pack-stat .ps-label { font-size: .68rem; color: #b9a8e0; margin-top: .15rem; }
.gallery-card { position: relative; }
.corner-badge {
  position: absolute; top: -.5rem; right: -.5rem; z-index: 3;
  padding: .2rem .55rem; border-radius: 999px; font-size: .62rem; font-weight: 800;
  transform: rotate(8deg); pointer-events: none;
}
.corner-badge.cb-legendary { background: linear-gradient(135deg,#ffe9b0,#f0b429); color: #4a2c00; box-shadow: 0 0 14px rgba(246,208,120,.8); animation: badge-glow 1.6s ease-in-out infinite; }
.corner-badge.cb-mythic { background: linear-gradient(135deg,#ff9a8a,#e5342a); color: #fff; box-shadow: 0 0 16px rgba(255,80,60,.85); animation: badge-glow 1.1s ease-in-out infinite; }
@keyframes badge-glow { 0%,100% { transform: rotate(8deg) scale(1); } 50% { transform: rotate(8deg) scale(1.12); } }

/* 首页收纳: 底部图例已迁入弹窗 */
#modal-odds .legend-card img { width: 4.2rem; height: 4.2rem; object-fit: contain; }

/* ================= v4 正规化: 厚边质感 + 底部Tab + 空间层次 ================= */

/* --- 设计令牌: 虾算算式厚边 (粗深色描边 + 底部厚阴影"墩"感 + 内高光) --- */
:root {
  --ink: #2a1650;            /* 深紫描边 */
  --ink-heavy: #1c0e38;      /* 更深的底阴影 */
  --panel-bg: linear-gradient(170deg, #342060, #241448);
  --gold: #f0b429;
}
.chunky {
  border: 3px solid var(--ink);
  border-radius: 1.1rem;
  box-shadow: 0 5px 0 var(--ink-heavy), 0 9px 18px rgba(0,0,0,.4),
    inset 0 2px 0 rgba(255,255,255,.14);
}

/* pill-btn 升级厚边 */
.pill-btn {
  border: 2.5px solid var(--ink) !important;
  box-shadow: 0 4px 0 var(--ink-heavy), 0 7px 12px rgba(0,0,0,.35), inset 0 1.5px 0 rgba(255,255,255,.18) !important;
  background: linear-gradient(180deg, #4a2c8a, #38206a) !important;
  transition: transform .12s, box-shadow .12s !important;
}
.pill-btn:hover { transform: translateY(-1px) !important; }
.pill-btn:active { transform: translateY(3px) !important; box-shadow: 0 1px 0 var(--ink-heavy), 0 3px 6px rgba(0,0,0,.3), inset 0 1.5px 0 rgba(255,255,255,.18) !important; }

/* 弹窗厚边化 */
.box-modal-box {
  border: 3px solid var(--ink) !important;
  box-shadow: 0 6px 0 var(--ink-heavy), 0 22px 60px rgba(0,0,0,.65), inset 0 2px 0 rgba(255,255,255,.12) !important;
}

/* 统计块厚边化 */
.pack-stat {
  border: 2.5px solid var(--ink) !important;
  box-shadow: 0 4px 0 var(--ink-heavy), 0 8px 14px rgba(0,0,0,.35), inset 0 1.5px 0 rgba(255,255,255,.1) !important;
}

/* --- 底部 Tab 导航 (微信小游戏风) --- */
#bottom-tab {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 45;
  display: flex; justify-content: center; gap: .6rem;
  padding: .5rem .8rem calc(.6rem + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(30,16,58,.92), rgba(20,10,42,.98));
  border-top: 2.5px solid var(--ink);
  backdrop-filter: blur(10px);
  box-shadow: 0 -6px 24px rgba(0,0,0,.45);
}
.tab-item {
  flex: 1; max-width: 9rem;
  display: flex; flex-direction: column; align-items: center; gap: .12rem;
  padding: .45rem 0 .4rem; border-radius: .95rem;
  border: 2.5px solid transparent;
  color: #8f7fc0; font-weight: 700; font-size: .72rem;
  transition: all .15s; cursor: pointer; position: relative;
}
.tab-item .tab-icon {
  width: 2.3rem; height: 2.3rem; border-radius: .8rem;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.05rem;
  background: rgba(255,255,255,.06);
  border: 2px solid rgba(255,255,255,.08);
  transition: all .15s;
}
.tab-item.active {
  color: #ffe9b8;
  background: linear-gradient(180deg, #4a2c8a, #362063);
  border-color: var(--ink);
  box-shadow: 0 4px 0 var(--ink-heavy), inset 0 2px 0 rgba(255,255,255,.15);
  transform: translateY(-4px);
}
.tab-item.active .tab-icon {
  background: radial-gradient(circle at 35% 30%, #ffe9a8, var(--gold) 68%, #c98a12);
  border-color: var(--ink); color: #3a2400;
  box-shadow: 0 3px 8px rgba(240,180,41,.5);
}
.tab-item:active { transform: translateY(0); }
/* 顶部导航只留 logo+声音; 视图底部给 tab 留空间 */
.view { padding-bottom: 6.5rem !important; }

/* --- 云朵底座 v2: 与盒子同组浮动, 形成上下层空间 --- */
#box-stage::after { display: none !important; } /* 弃用旧的独立云朵 */
#float-group { position: relative; width: 20rem; height: 21rem; margin: 0 auto; animation: group-bob 5.5s ease-in-out infinite; }
@keyframes group-bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
#float-group .box-cube {
  position: absolute; left: 50%; top: .4rem; margin: 0 0 0 -8rem; transform: none;
  /* 关键: 禁用自身 box-idle 动画(其 transform 会覆盖居中偏移导致盒子跑到云朵斜上方), 浮动交给 group-bob */
  animation: none; z-index: 2;
}
#cloud-base {
  position: absolute; left: 50%; bottom: 0; transform: translateX(-50%);
  width: 19rem; height: 7.6rem; z-index: 1;
  background: url('/static/img2/platform.webp') center / contain no-repeat;
  filter: drop-shadow(0 10px 18px rgba(0,0,0,.45));
}
/* 盒子在云朵上的接触阴影 → 视觉锚定"坐在云上" */
#float-group .box-cube::before {
  content: ''; position: absolute; left: 14%; right: 14%; bottom: -1.2rem; height: 1.6rem;
  border-radius: 50%; background: rgba(20,10,40,.5); filter: blur(7px); z-index: -1;
}

/* --- 品相条 (百分比可视化, 关联价格) --- */
.cond-bar-wrap { display: flex; align-items: center; gap: .5rem; }
.cond-bar { flex: 1; height: .55rem; border-radius: 999px; background: rgba(255,255,255,.1); border: 1.5px solid var(--ink); overflow: hidden; }
.cond-bar > i {
  display: block; height: 100%; border-radius: 999px;
  background: linear-gradient(90deg, #7dd3fc, #4ade80 55%, #ffd678);
  transition: width .8s cubic-bezier(.34,1.3,.64,1);
}
.cond-pct { font-family: 'Baloo 2', sans-serif; font-weight: 800; }
.cond-pct.hi { color: #ffd678; } .cond-pct.mid { color: #4ade80; } .cond-pct.lo { color: #9ca3af; }

/* --- 背包卡片可点 --- */
.gallery-card { cursor: pointer; transition: transform .15s, box-shadow .15s; }
.gallery-card:hover { transform: translateY(-4px); }
.gallery-card:active { transform: scale(.97); }

/* --- 卡详情弹窗内部 --- */
.card-detail-el {
  display: flex; align-items: center; gap: .5rem;
  padding: .42rem .6rem; border-radius: .6rem;
  background: rgba(255,255,255,.045); border: 1.5px solid rgba(255,255,255,.07);
  font-size: .72rem;
}
.card-detail-el .cd-slot { color: #8f7fc0; width: 3.2rem; flex: none; }
.card-detail-el .cd-price { margin-left: auto; font-family: 'Baloo 2', sans-serif; font-weight: 700; }

/* --- 图鉴: 每行3小方格 --- */
#codex-grid { display: grid !important; grid-template-columns: repeat(3, 1fr) !important; gap: .65rem !important; }
.codex-item {
  display: flex !important; flex-direction: column !important; align-items: center;
  padding: .7rem .5rem .6rem !important; text-align: center;
  border: 2.5px solid var(--ink) !important; border-radius: .9rem !important;
  background: var(--panel-bg) !important;
  box-shadow: 0 4px 0 var(--ink-heavy), 0 7px 12px rgba(0,0,0,.3), inset 0 1.5px 0 rgba(255,255,255,.08) !important;
  transition: transform .15s;
}
.codex-item:hover { transform: translateY(-3px); }
.codex-item .codex-thumb {
  width: 3.4rem !important; height: 3.4rem !important; border-radius: .7rem !important;
  object-fit: contain !important; background: rgba(0,0,0,.25) !important;
  border: 2px solid rgba(255,255,255,.08); padding: .3rem !important;
}
.codex-item .codex-body { width: 100%; margin-top: .45rem; }
.codex-item.locked { opacity: .55; filter: saturate(.4); }
.codex-item.owned { border-color: rgba(240,180,41,.65) !important; }
.codex-item.owned::after {
  content: '✓'; position: absolute; top: .3rem; right: .45rem;
  width: 1.15rem; height: 1.15rem; border-radius: 50%; font-size: .7rem; font-weight: 900;
  background: var(--gold); color: #3a2400; display: flex; align-items: center; justify-content: center;
}
.codex-item { position: relative !important; }
@media (max-width: 640px) { #codex-grid { grid-template-columns: repeat(3, 1fr) !important; gap: .5rem !important; } .codex-item .codex-thumb { width: 2.8rem !important; height: 2.8rem !important; } }

/* ================= v5: 声音提示 + 登录 ================= */
#sound-hint {
  position: fixed; top: 4.2rem; left: 50%; transform: translateX(-50%);
  z-index: 45; padding: .5rem 1.1rem; font-size: .78rem; font-weight: 700;
  color: #ffe9b0; background: rgba(30,16,60,.92);
  border: 2px solid var(--ink); border-radius: 999px;
  box-shadow: 0 3px 0 var(--ink-heavy), 0 6px 14px rgba(0,0,0,.4);
  transition: opacity .4s; animation: hint-pulse 2s ease-in-out infinite;
}
@keyframes hint-pulse { 0%,100% { transform: translateX(-50%) scale(1); } 50% { transform: translateX(-50%) scale(1.04); } }

/* 登录弹窗 */
#modal-auth .auth-input {
  width: 100%; padding: .7rem 1rem; border-radius: .8rem;
  background: rgba(0,0,0,.35); color: #fff; font-size: .9rem;
  border: 2.5px solid var(--ink); outline: none;
  box-shadow: inset 0 2px 5px rgba(0,0,0,.3);
}
#modal-auth .auth-input:focus { border-color: var(--gold); }
#auth-user-chip { display: inline-flex; align-items: center; gap: .4rem; max-width: 9rem; }
#auth-user-chip .au-mail { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .68rem; }

/* ================= v6 赛博精致化 (参考虾算算设计体系, 换皮为赛博) =================
   虾算算做法: 纯色底 + 高饱和主色按钮(色块+深一档底沿+墨线描边) + 贴纸投影
   我们的映射: 深空纯色底 + 霓虹金/青按钮 + 网格微光特效 + 硬朗字体 */

/* --- 字体: 站酷庆科黄油体(粗壮平直, 不歪) + Rajdhani(赛博数字) --- */
body { font-family: 'Noto Sans SC', system-ui, sans-serif !important; }
.toon-title, .brand-word, .tab-label, .cond-stamp, .page-ticket {
  font-family: 'Noto Sans SC', system-ui, sans-serif !important; font-weight: 900 !important;
  letter-spacing: .04em !important;
}
.cond-pct, .pack-stat .ps-num, .card-detail-el .cd-price, .howto-num, #final-jv,
.el-price, .ticker-item b {
  font-family: 'Rajdhani', 'Noto Sans SC', sans-serif !important;
  font-weight: 700 !important; letter-spacing: .02em;
}
.open-btn, .pill-btn, .ghost-btn, .filter-chip {
  font-family: 'ZCOOL QingKe HuangYou', 'Noto Sans SC', sans-serif !important;
  letter-spacing: .05em;
}

/* --- 标题: 去卡通描边, 改霓虹渐变 + 干净辉光 --- */
.toon-title {
  -webkit-text-stroke: 0 !important;
  color: transparent !important;
  background: linear-gradient(180deg, #fff 8%, #ffe9b0 45%, #f0b429 90%);
  -webkit-background-clip: text; background-clip: text;
  text-shadow: none !important;
  filter: drop-shadow(0 2px 0 rgba(59,29,110,.9)) drop-shadow(0 0 22px rgba(240,180,41,.30));
}
.toon-title .tt-star { animation: none !important; opacity: .9; }

/* --- 纯色深空背景: 弃照片底图, 网格 + 顶部极光 + 扫描线 --- */
body { background: #0a0918 !important; }
body::before {
  background:
    radial-gradient(ellipse 90% 40% at 50% -8%, rgba(124,92,214,.28), transparent 60%),
    radial-gradient(ellipse 55% 30% at 82% 4%, rgba(78,205,196,.12), transparent 65%),
    linear-gradient(rgba(148,120,255,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148,120,255,.05) 1px, transparent 1px),
    #0a0918 !important;
  background-size: auto, auto, 44px 44px, 44px 44px, auto !important;
}
/* 开盒覆盖层: 同体系更深一档 */
#reveal-overlay {
  background:
    radial-gradient(ellipse 80% 45% at 50% 0%, rgba(124,92,214,.22), transparent 62%),
    linear-gradient(rgba(148,120,255,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148,120,255,.04) 1px, transparent 1px),
    #070613 !important;
  background-size: auto, 44px 44px, 44px 44px, auto !important;
}

/* --- 描边体系: 墨线换成霓虹紫黑, 底沿保留(虾算算的立体按压感) --- */
:root {
  --ink: #17123a;
  --ink-heavy: #0c0a24;
  --gold: #f0b429;
  --cyan: #4ecdc4;
  --panel-bg: linear-gradient(180deg, rgba(30,24,64,.92), rgba(19,15,44,.96));
}
.pill-btn, .ghost-btn {
  border: 2.5px solid rgba(148,120,255,.35) !important;
  background: linear-gradient(180deg, rgba(44,34,88,.9), rgba(28,22,60,.95)) !important;
  box-shadow: 0 4px 0 #0c0a24, 0 8px 16px rgba(0,0,0,.35), inset 0 1.5px 0 rgba(255,255,255,.10) !important;
  color: #d8ccff !important;
}
.pill-btn:hover, .ghost-btn:hover { border-color: rgba(240,180,41,.6) !important; color: #ffe9b0 !important; }
.pill-btn:active, .ghost-btn:active { transform: translateY(3px); box-shadow: 0 1px 0 #0c0a24, 0 3px 8px rgba(0,0,0,.35) !important; }

/* --- 底部 Tab: 精致化 (毛玻璃 + 霓虹上沿) --- */
#bottom-tab {
  background: rgba(13,10,32,.88) !important;
  backdrop-filter: blur(14px);
  border-top: 1px solid rgba(148,120,255,.25) !important;
  box-shadow: 0 -8px 32px rgba(0,0,0,.5), 0 -1px 0 rgba(148,120,255,.12) !important;
}
.tab-item.active .tab-icon { box-shadow: 0 0 18px rgba(240,180,41,.55), 0 4px 0 #0c0a24 !important; }

/* --- 卡片/弹窗: 收紧圆角与投影, 精致化 --- */
.box-modal-box, .pack-stat, .codex-item, .gallery-card {
  border: 2px solid rgba(148,120,255,.28) !important;
  box-shadow: 0 4px 0 #0c0a24, 0 12px 32px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.07) !important;
}
.codex-item.owned { border-color: rgba(240,180,41,.55) !important; }

/* --- 干掉歪斜: 全站禁止倾斜类动画残留 --- */
#act2-box, .act-box { animation: none !important; }
@keyframes box-bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }


/* ================= v7: 第三批素材接线 + 活体光效 ================= */
/* --- 底部 tab 换正式图标 --- */
.tab-item .tab-icon { background: none !important; border: 0 !important; box-shadow: none !important; }
.tab-item .tab-icon img {
  width: 2.1rem; height: 2.1rem; object-fit: contain;
  filter: grayscale(.55) brightness(.75); transition: filter .2s, transform .2s;
}
.tab-item.active .tab-icon { box-shadow: none !important; }
.tab-item.active .tab-icon img {
  filter: none; transform: scale(1.16) translateY(-2px);
  animation: tabpop .3s cubic-bezier(.3,1.6,.5,1);
}
@keyframes tabpop { from { transform: scale(.9); } to { transform: scale(1.16) translateY(-2px); } }

/* --- 主页盒子点击特效: 绿色充能盒闪现 + 能量环 --- */
#box-cube { cursor: pointer; }
#box-cube.tapped {
  /* --box-img / --sheen-c / --tap-rgb 由 JS 随机注入 (v7.1 随机充能色) */
  --tap-rgb: 110,255,180;
  --sheen-t: .8s;
  animation: tap-jolt .5s cubic-bezier(.3,1.5,.4,1);
  filter: drop-shadow(0 0 44px rgba(var(--tap-rgb), .6)) !important;
}
@keyframes tap-jolt {
  0% { transform: scale(1); } 30% { transform: scale(1.09) rotate(-2deg); }
  60% { transform: scale(.97) rotate(1.4deg); } 100% { transform: scale(1); }
}
#box-cube .tap-ring {
  --tap-rgb: 110,255,180;
  position: absolute; left: 50%; top: 52%; width: 4rem; height: 4rem;
  margin: -2rem 0 0 -2rem; border-radius: 50%; pointer-events: none;
  border: 3px solid rgba(var(--tap-rgb), .85);
  box-shadow: 0 0 24px rgba(var(--tap-rgb), .6), inset 0 0 16px rgba(var(--tap-rgb), .4);
  animation: tap-ring .6s ease-out forwards;
}
@keyframes tap-ring { to { transform: scale(4.6); opacity: 0; } }

/* --- 底座能量涟漪: platform 自带光环, 叠加脉冲让它"通电" --- */
#cloud-base::after {
  content: ''; position: absolute; left: 50%; bottom: .4rem;
  width: 68%; height: 34%; transform: translateX(-50%);
  border-radius: 50%; pointer-events: none;
  background: radial-gradient(ellipse, rgba(80,230,255,.28) 0%, transparent 68%);
  animation: base-pulse 2.8s ease-in-out infinite;
}
@keyframes base-pulse {
  0%,100% { opacity: .35; transform: translateX(-50%) scale(.92); }
  50%     { opacity: .9;  transform: translateX(-50%) scale(1.06); }
}

/* --- 主按钮呼吸金光 + 周期流光扫过 --- */
.open-btn { position: relative; overflow: hidden; animation: btn-breathe 3.2s ease-in-out infinite; }
@keyframes btn-breathe {
  0%,100% { filter: drop-shadow(0 6px 18px rgba(0,0,0,.45)) drop-shadow(0 0 16px rgba(246,208,120,.25)); }
  50%     { filter: drop-shadow(0 6px 18px rgba(0,0,0,.45)) drop-shadow(0 0 30px rgba(246,208,120,.5)); }
}
.open-btn::before {
  content: ''; position: absolute; top: 8%; bottom: 10%; left: -60%; width: 34%;
  background: linear-gradient(105deg, transparent, rgba(255,255,255,.55) 50%, transparent);
  transform: skewX(-18deg); pointer-events: none;
  animation: btn-sheen 3.2s ease-in-out infinite;
}
@keyframes btn-sheen { 0%, 55% { left: -60%; } 85%, 100% { left: 130%; } }

/* --- 主页待机盒: 悬停提亮挑逗 --- */
/* 主页盒: box-breathe 只动 filter, 不碰 transform, 可安全恢复(v4 曾因 transform 冲突禁用动画) */
#float-group .box-cube { animation: box-breathe 3.6s ease-in-out infinite; }
#float-group .box-cube.tapped { animation: tap-jolt .5s cubic-bezier(.3,1.5,.4,1); }
/* hover 用 transform 提示(filter 被 breathe 动画占用) */
#box-cube:hover:not(.tapped) { transform: scale(1.035); transition: transform .25s; }


/* ================= v8: 11点体验修订 ================= */

/* --- pt3: 锁死页面上下滑动 (桌面 webapp), 保留下拉刷新 --- */
html, body {
  height: 100%;
  overflow: hidden;               /* 页面本体不滚, 上下滑不动 */
  overscroll-behavior-y: contain; /* v17: 原生下拉刷新关闭, 改自绘 #ptr (app.js) */
}
/* 内容改为各视图内部滚动 (背包/图鉴长列表可滚, 开盒页整屏固定) */
.view {
  position: fixed; inset: 0;
  overflow-y: auto; -webkit-overflow-scrolling: touch;
  overscroll-behavior-y: contain; /* v17: 交给自绘下拉刷新 */
}
#view-open { overflow-y: auto; } /* 小屏内容超高时仍可达, 大屏天然不滚 */
#reveal-overlay { overscroll-behavior-y: contain; }

/* --- pt1: 主按钮两行文案 + 收紧 --- */
.open-btn { line-height: 1.15; }
#open-btn {
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center;
  gap: .22rem;
  padding: 1.35rem 2.8rem 1.45rem;
  min-width: 16.5rem; max-width: 20rem;
}
#open-btn .ob-l1 {
  font-size: 1.5rem; font-weight: 900; letter-spacing: .06em;
  display: block;
}
#open-btn .ob-l2 {
  font-size: .88rem; font-weight: 700; letter-spacing: .14em;
  color: #7a4d10; opacity: .95; display: block;
  font-family: 'Rajdhani', 'Noto Sans SC', sans-serif;
}

/* --- pt6: 顶栏品牌标 (立方体图标替代旧logo) --- */
.brand-mark {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.1rem; height: 2.1rem; border-radius: .65rem;
  background: linear-gradient(150deg, #f6d078, #b8792a);
  color: #2a1650; font-size: 1.05rem;
  box-shadow: 0 0 14px rgba(246,208,120,.4), inset 0 1px 0 rgba(255,255,255,.5);
}

/* --- pt4: 钱包登录 --- */
.wallet-head-icon {
  width: 3.2rem; height: 3.2rem; margin: 0 auto; border-radius: 1rem;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(150deg, rgba(246,208,120,.2), rgba(150,90,255,.18));
  border: 1.5px solid rgba(246,208,120,.4);
  color: #f6d078; font-size: 1.3rem;
  box-shadow: 0 0 22px rgba(246,208,120,.25);
}
.wallet-opt {
  display: flex; align-items: center; gap: .8rem; width: 100%;
  padding: .68rem .9rem; border-radius: .85rem; text-align: left;
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(255,255,255,.02));
  border: 1.5px solid rgba(255,255,255,.12);
  font-weight: 700; font-size: .88rem; color: #e9e6f5;
  transition: border-color .15s, transform .12s, background .15s;
}
.wallet-opt:hover { border-color: rgba(246,208,120,.55); transform: translateY(-1px); background: rgba(246,208,120,.06); }
.wallet-opt:active { transform: scale(.985); }
.wallet-opt .w-icon {
  width: 2rem; height: 2rem; border-radius: .6rem; flex: none;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: .8rem; font-weight: 900; font-family: 'Rajdhani', sans-serif;
}
.wallet-opt > i.fa-chevron-right { margin-left: auto; font-size: .7rem; color: rgba(255,255,255,.3); }
.wallet-coming {
  width: 4rem; height: 4rem; margin: 0 auto; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 35% 30%, rgba(246,208,120,.35), rgba(150,90,255,.15));
  border: 2px solid rgba(246,208,120,.5); color: #ffd678; font-size: 1.5rem;
  animation: base-pulse 2.2s ease-in-out infinite;
}

/* --- pt2: 说明弹窗排版 --- */
.modal-title { font-size: 1.15rem; font-weight: 900; color: #ffe9b0; text-align: left; }
.odds-sec-title {
  font-size: .78rem; font-weight: 800; color: #f6d078; letter-spacing: .1em;
  margin-bottom: .45rem; padding-left: .6rem; border-left: 3px solid #f0b429;
}
.odds-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: .4rem; }
.odds-cell {
  display: flex; flex-direction: column; align-items: center; gap: .1rem;
  padding: .5rem .2rem; border-radius: .6rem; font-size: .72rem;
  background: rgba(255,255,255,.04); border: 1.5px solid rgba(255,255,255,.1);
}
.odds-cell b { font-family: 'Rajdhani', sans-serif; font-size: .92rem; color: #fff; }
.odds-text { font-size: .76rem; line-height: 1.65; color: #b9b3cc; }
.cond-row { display: flex; align-items: center; gap: .7rem; }
.cond-tag {
  flex: none; width: 8.6rem; text-align: center;
  padding: .32rem .4rem; border-radius: .55rem;
  font-size: .68rem; font-weight: 900; letter-spacing: .04em;
}
.cond-t-flawless { background: linear-gradient(135deg,#ffe9b0,#f0b429); color: #4a2c00; box-shadow: 0 0 12px rgba(246,208,120,.45); }
.cond-t-pristine { background: linear-gradient(135deg,#d6ccff,#8f7bef); color: #241356; }
.cond-t-fine     { background: linear-gradient(135deg,#a8ecd9,#3eb894); color: #06392b; }
.cond-t-standard { background: rgba(255,255,255,.12); color: #cfcadd; border: 1px solid rgba(255,255,255,.18); }
.cond-desc { font-size: .72rem; color: #a9a3bd; line-height: 1.5; }

/* --- pt5: 幕三按钮排版 --- */
.act3-btns {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: .8rem 1rem; max-width: 26rem;
}
.act3-btns .ghost-btn { font-size: .82rem; white-space: nowrap; }
.act3-btns.hidden { display: none; } /* v17: 幕三鉴定前隐藏, 防 display:flex 压过 tw .hidden */

/* --- pt7: 背包筛选两行布局 --- */
#pack-sort .sort-row { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
#pack-sort .sort-sub {
  margin-top: .55rem; padding: .55rem .6rem; border-radius: .8rem;
  background: rgba(255,255,255,.04); border: 1.5px dashed rgba(246,208,120,.3);
  animation: sub-drop .18s ease-out;
}
@keyframes sub-drop { from { opacity: 0; transform: translateY(-4px); } }
#pack-sort .filter-chip { user-select: none; }

/* --- pt8: 卡框不挡编号/价格 --- */
.gallery-card { padding: 1.5rem 1.35rem 1.7rem; } /* 内容整体让开边框描边区 */
.gallery-card .gc-meta, .gallery-card .gc-price { position: relative; z-index: 5; } /* 压过 ::before 卡框(z3)与流光(z4) */
.gallery-card .gc-meta {
  background: rgba(10,8,24,.72); backdrop-filter: blur(2px);
  border-radius: .5rem; padding: .18rem .45rem; margin: -.35rem -.3rem 0;
}
.gallery-card .gc-price {
  background: rgba(10,8,24,.72); backdrop-filter: blur(2px);
  border-radius: .5rem; padding: .15rem .4rem; margin: 0 -.3rem -.35rem;
}
.corner-badge { z-index: 6; }

/* ============================================================
   v9 — APP 化首页 / 四底栏 / 我的 / 交易所 / 排行榜 / 说明Tab
   ============================================================ */

/* --- 首页三段式布局: 标题区 / 盒台(居中偏下) / CTA --- */
.hero-app {
  display: flex; flex-direction: column;
  min-height: calc(100vh - 2.4rem - 6.5rem); /* 减 ticker + 底栏 */
  min-height: calc(100dvh - 2.4rem - 6.5rem);
  padding-top: .8rem; padding-bottom: .5rem;
}
#title-zone {
  display: grid; grid-template-columns: 1fr auto 1fr;
  align-items: center; gap: .5rem;
}
#home-title { text-align: center; padding-top: .3rem; }
.title-art-text {
  font-family: 'ZCOOL QingKe HuangYou', 'Noto Sans SC', sans-serif;
  font-size: 2.6rem; line-height: 1.1; letter-spacing: .04em;
  background: linear-gradient(175deg, #fff3c4 8%, #f6d078 38%, #e89b3c 62%, #b8611d 92%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 3px 0 rgba(90,40,10,.85)) drop-shadow(0 6px 16px rgba(246,160,60,.35));
}
#title-art { max-width: 15rem; margin: 0 auto; display: block; }
.title-sub { margin-top: .45rem; font-size: .68rem; letter-spacing: .32em; color: rgba(255,225,160,.62); }
.tz-side { display: flex; flex-direction: column; gap: .7rem; align-items: center; align-self: center; }
.tz-side:first-child { align-items: flex-start; }
.tz-side:last-child { align-items: flex-end; }
.side-btn {
  display: flex; flex-direction: column; align-items: center; gap: .28rem;
  width: 3.6rem; cursor: pointer;
  transition: transform .15s;
}
.side-btn:hover { transform: translateY(-2px) scale(1.06); }
.side-btn:active { transform: scale(.94); }
.sb-icon {
  width: 2.7rem; height: 2.7rem; border-radius: .9rem;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.05rem; color: #ffe9b8;
  background: linear-gradient(160deg, rgba(90,50,160,.9), rgba(45,22,90,.92));
  border: 1.5px solid rgba(255,214,120,.45);
  box-shadow: 0 3px 0 rgba(20,8,45,.9), 0 5px 14px rgba(0,0,0,.4), inset 0 1px 0 rgba(255,255,255,.18);
}
.sb-label { font-size: .62rem; font-weight: 700; color: rgba(255,233,184,.85); letter-spacing: .05em; white-space: nowrap; }

#stage-zone {
  flex: 1; display: flex; align-items: center; justify-content: center;
  padding: .5rem 0; min-height: 16rem;
}
#stage-zone #box-stage { margin-top: 6%; } /* 视觉重心稍偏下 */
#cta-zone { flex: none; text-align: center; padding-bottom: .8rem; }

/* --- 幕三: 再开一盒 青色高亮描边 (与炫耀战报同系但更醒目) --- */
.act3-cyan {
  border-color: rgba(94,234,212,.65) !important;
  color: #8ff5e2 !important;
  box-shadow: 0 3px 0 #0c2a24, 0 6px 14px rgba(94,234,212,.22), inset 0 1px 0 rgba(255,255,255,.14) !important;
  background: linear-gradient(180deg, rgba(94,234,212,.14), rgba(94,234,212,.05)) !important;
}
.act3-cyan:hover { border-color: #5eead4 !important; color: #b8fff1 !important; }

/* --- 钱包登录成功 --- */
.wallet-success {
  width: 3.6rem; height: 3.6rem; margin: 0 auto; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle, rgba(52,211,153,.22), rgba(52,211,153,.06));
  border: 2px solid rgba(52,211,153,.55);
  color: #34d399; font-size: 1.7rem;
  box-shadow: 0 0 26px rgba(52,211,153,.35);
  animation: ws-pop .5s cubic-bezier(.2,1.4,.4,1);
}
@keyframes ws-pop { from { transform: scale(.3); opacity: 0; } }

/* --- 说明/排行 Tab --- */
#guide-tabs, #rank-tabs, #codex-tabs { display: flex; gap: .5rem; }
#codex-tabs { margin-top: .2rem; }
.gtab, .ctab {
  flex: 1; padding: .5rem .6rem; border-radius: .7rem;
  font-size: .82rem; font-weight: 800; letter-spacing: .04em;
  color: #9ca3af; background: rgba(255,255,255,.045);
  border: 1.5px solid rgba(255,255,255,.1);
  cursor: pointer; transition: all .18s;
}
.ctab { flex: none; padding: .55rem 1.3rem; }
.gtab.active, .ctab.active {
  color: #ffe9b8; background: linear-gradient(180deg, rgba(246,208,120,.16), rgba(246,208,120,.06));
  border-color: rgba(246,208,120,.55);
  box-shadow: 0 0 12px rgba(246,208,120,.15), inset 0 1px 0 rgba(255,255,255,.1);
}

/* --- 排行榜 --- */
.rank-row {
  display: flex; align-items: center; gap: .7rem;
  padding: .55rem .8rem; border-radius: .7rem;
  background: rgba(255,255,255,.035); border: 1px solid rgba(255,255,255,.07);
}
.rank-row.rank-top { background: linear-gradient(90deg, rgba(246,208,120,.1), rgba(255,255,255,.03)); border-color: rgba(246,208,120,.28); }
.rk-no { width: 1.8rem; text-align: center; font-weight: 900; color: #cbd5e1; flex: none; }
.rk-name { font-size: .85rem; font-weight: 700; color: #e5e7eb; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rk-val { font-size: .85rem; font-weight: 800; color: #f6d078; font-variant-numeric: tabular-nums; }
.rk-val i { font-style: normal; font-size: .62rem; color: #9ca3af; }

/* --- 交易所 --- */
.market-card {
  position: relative; border-radius: 1rem; padding: .8rem .75rem .75rem;
  background: rgba(255,255,255,.04);
  display: flex; flex-direction: column; gap: .4rem; align-items: center;
}
.mc-top { display: flex; align-items: center; justify-content: space-between; width: 100%; position: relative; z-index: 5; }
.mc-top .el-rbadge { margin-left: 0; }
.mc-cond { font-size: .62rem; }
.mc-icon { font-size: 1.7rem; color: rgba(255,255,255,.3); padding: .55rem 0 .1rem; }
.mc-name { font-size: .85rem; font-weight: 800; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; position: relative; z-index: 5; }
.mc-meta { font-size: .6rem; color: rgba(255,255,255,.4); position: relative; z-index: 5; }
.mc-price { font-size: 1.05rem; font-weight: 900; color: #ffe9b8; font-variant-numeric: tabular-nums; position: relative; z-index: 5; }
.mc-price span { font-size: .6rem; color: #9ca3af; font-weight: 600; }
.mc-buy {
  width: 100%; padding: .42rem 0; border-radius: .6rem; margin-top: .1rem;
  font-size: .75rem; font-weight: 800; color: #2a1650;
  background: linear-gradient(180deg, #f9dc90, #e8a94a);
  box-shadow: 0 2px 0 rgba(120,70,10,.7), inset 0 1px 0 rgba(255,255,255,.5);
  cursor: pointer; transition: transform .12s; position: relative; z-index: 5;
}
.mc-buy:active { transform: translateY(2px); box-shadow: none; }

/* --- 我的页 --- */
.me-head {
  display: flex; align-items: center; gap: .9rem;
  padding: 1rem 1.1rem; border-radius: 1.1rem;
  background: linear-gradient(160deg, rgba(90,50,160,.35), rgba(30,14,66,.55));
  border: 1.5px solid rgba(255,214,120,.3);
}
.me-avatar {
  width: 3.6rem; height: 3.6rem; border-radius: 1rem; overflow: hidden; flex: none;
  border: 2px solid rgba(246,208,120,.5); box-shadow: 0 0 16px rgba(246,208,120,.2);
}
.me-avatar img { width: 100%; height: 100%; object-fit: cover; }
.me-addr {
  margin-top: .15rem; font-size: .72rem; font-family: 'Rajdhani', monospace; font-weight: 700;
  color: #c9b6ff; cursor: pointer; letter-spacing: .03em;
}
.me-addr:hover { color: #ffe9b8; }
.me-logout {
  width: 2.3rem; height: 2.3rem; border-radius: .7rem; flex: none;
  color: #9ca3af; border: 1px solid rgba(255,255,255,.15);
  cursor: pointer; transition: all .15s;
}
.me-logout:hover { color: #ff8a7a; border-color: rgba(255,122,110,.5); }
.me-menu {
  border-radius: 1.1rem; overflow: hidden;
  border: 1px solid rgba(255,255,255,.09);
  background: rgba(255,255,255,.03);
}
.me-item {
  display: flex; align-items: center; gap: .8rem; width: 100%;
  padding: .85rem 1rem; text-align: left;
  font-size: .85rem; font-weight: 700; color: #e5e7eb;
  border-bottom: 1px solid rgba(255,255,255,.06);
  cursor: pointer; transition: background .15s;
}
.me-item:last-child { border-bottom: none; }
.me-item:hover { background: rgba(255,255,255,.05); }
.me-item > .fa-chevron-right { margin-left: auto; font-size: .7rem; color: rgba(255,255,255,.3); }
.mi-icon {
  width: 2rem; height: 2rem; border-radius: .6rem; flex: none;
  display: flex; align-items: center; justify-content: center;
  font-size: .85rem; color: #f6d078;
  background: rgba(246,208,120,.1); border: 1px solid rgba(246,208,120,.22);
}
.mi-note { margin-left: auto; font-size: .65rem; color: rgba(255,255,255,.35); }
.me-item .mi-note + .fa-chevron-right { margin-left: .5rem; }
.me-login-btn { min-width: 13rem !important; padding: 1rem 2.2rem !important; }

/* --- 交易记录行 --- */
.order-row {
  display: flex; align-items: center; gap: .7rem;
  padding: .55rem .7rem; border-radius: .65rem;
  background: rgba(255,255,255,.035); border: 1px solid rgba(255,255,255,.07);
}
.or-icon {
  width: 1.9rem; height: 1.9rem; border-radius: .55rem; flex: none;
  display: flex; align-items: center; justify-content: center;
  font-size: .8rem; color: #c9b6ff; background: rgba(150,90,255,.12);
}

/* --- toast 轻提示 --- */
#toast {
  position: fixed; left: 50%; bottom: 8.5rem; transform: translateX(-50%) translateY(8px);
  z-index: 80; padding: .6rem 1.2rem; border-radius: 999px;
  font-size: .8rem; font-weight: 700; color: #ffe9b8;
  background: rgba(28,16,58,.95); border: 1.5px solid rgba(255,214,120,.45);
  box-shadow: 0 8px 24px rgba(0,0,0,.5);
  opacity: 0; transition: opacity .25s, transform .25s;
  pointer-events: none; max-width: 85vw; text-align: center;
}
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* --- 底栏 FA 图标兜底 (交易所/我的暂无美术素材) --- */
.tab-icon-fa {
  display: flex; align-items: center; justify-content: center;
  font-size: 1.35rem; color: #b9a8e8; height: 100%;
}
.tab-item.active .tab-icon-fa { color: #ffe9b8; filter: drop-shadow(0 0 8px rgba(246,208,120,.5)); }

/* 首页禁止自身滚动 (内容已按视口设计) */
#view-open { overflow-y: hidden; }
@media (max-height: 700px) {
  #view-open { overflow-y: auto; }
  .title-art-text { font-size: 2.1rem; }
  #stage-zone { min-height: 13rem; }
  #stage-zone #box-stage { transform: scale(.85); }
}


/* ================= v10: 新素材 + 全面精致化 ================= */

/* --- v10-5 字体: 全站黑体系 (Noto Sans SC 900), 粗壮醒目不歪扭 --- */
h1, h2, h3, .brand-font, .nav-btn, .open-btn, .el-name,
.gtab, .ctab, .pill-btn, .ghost-btn, .side-btn, .modal-title {
  font-family: 'Noto Sans SC', system-ui, sans-serif !important;
}
.tab-label { font-weight: 900 !important; font-size: .72rem !important; letter-spacing: .02em; }
.title-art-text { font-family: 'Noto Sans SC', sans-serif; font-weight: 900; } /* 兜底(已被图替代) */

/* --- v10-1 标题美术图 --- */
#title-art {
  max-width: 11.5rem; margin: 0 auto; display: block;
  filter: drop-shadow(0 6px 18px rgba(140,80,255,.35));
  animation: title-float 4s ease-in-out infinite;
}
@keyframes title-float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }

/* --- v10-6 主按钮: 美术图三态 (蓝/红交替呼吸 + 按压红) --- */
.img-open-btn {
  position: relative; display: block; margin: 0 auto;
  width: min(21.5rem, 84vw); aspect-ratio: 640/229;
  background: none; border: none; padding: 0; cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  animation: none; overflow: visible;
  transform: perspective(620px) rotateX(9deg) scaleY(1.06);
  transform-origin: 50% 100%;
}
/* 地面椭圆投影: 把按钮"垫"在台前, 视觉更靠近用户 */
.img-open-btn::after {
  content: ''; position: absolute; left: 8%; right: 8%; bottom: -14%;
  height: 26%; border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(0,0,0,.55), rgba(0,0,0,0) 68%);
  z-index: -1; pointer-events: none;
}
.img-open-btn:active { transform: perspective(620px) rotateX(9deg) scaleY(1.02) translateY(3px); }
.img-open-btn .ob-img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: contain; pointer-events: none; user-select: none;
  transition: opacity 1.4s ease-in-out;
}
/* 蓝红交替: JS 控制 .phase-red; 按压: .pressing */
.img-open-btn .ob-blue    { opacity: 1; filter: drop-shadow(0 0 18px rgba(94,234,212,.45)) drop-shadow(0 8px 20px rgba(0,0,0,.5)); animation: glow-blue 2.6s ease-in-out infinite; }
.img-open-btn .ob-red     { opacity: 0; filter: drop-shadow(0 0 18px rgba(255,90,80,.5)) drop-shadow(0 8px 20px rgba(0,0,0,.5)); animation: glow-red 2.6s ease-in-out infinite; }
.img-open-btn .ob-pressed { opacity: 0; transition: opacity .06s; filter: drop-shadow(0 0 26px rgba(255,90,80,.75)); }
.img-open-btn.phase-red .ob-blue { opacity: 0; }
.img-open-btn.phase-red .ob-red  { opacity: 1; }
.img-open-btn.pressing .ob-blue,
.img-open-btn.pressing .ob-red { opacity: 0 !important; transition: opacity .06s; }
.img-open-btn.pressing .ob-pressed { opacity: 1; }
.img-open-btn.pressing #ob-bang { transform: translate(-50%,-38%) scale(.9); opacity: .85; }
@keyframes glow-blue {
  0%,100% { filter: drop-shadow(0 0 12px rgba(94,234,212,.35)) drop-shadow(0 8px 20px rgba(0,0,0,.5)); }
  50%     { filter: drop-shadow(0 0 30px rgba(94,234,212,.75)) drop-shadow(0 8px 20px rgba(0,0,0,.5)); }
}
@keyframes glow-red {
  0%,100% { filter: drop-shadow(0 0 12px rgba(255,90,80,.4)) drop-shadow(0 8px 20px rgba(0,0,0,.5)); }
  50%     { filter: drop-shadow(0 0 30px rgba(255,110,90,.8)) drop-shadow(0 8px 20px rgba(0,0,0,.5)); }
}
/* 主按钮文字「开盒」: 金面板正中的深棕黑体 */
#ob-bang {
  position: absolute; left: 50%; top: 40%;
  transform: translate(-50%,-50%);
  font-family: 'Noto Sans SC', sans-serif;
  font-weight: 900; font-size: 1.9rem; letter-spacing: .5em; text-indent: .5em;
  color: #6b3a08;
  text-shadow: 0 1px 0 rgba(255,240,190,.75), 0 2px 3px rgba(120,60,0,.25);
  pointer-events: none; transition: transform .08s, opacity .08s;
}
.img-open-btn:disabled { opacity: .55; pointer-events: none; }
#cta-zone { padding-bottom: 1.4rem; position: relative; z-index: 6; margin-top: -.6rem; }

/* --- v10-3 交易所筛选: 单行滚动 + 排序独立右侧 --- */
#market-filters .mk-bar {
  display: flex; align-items: center; gap: .45rem;
}
#market-filters .mk-chips {
  display: flex; gap: .4rem; overflow-x: auto; flex: 1;
  scrollbar-width: none; -webkit-overflow-scrolling: touch;
  padding: .15rem 0;
}
#market-filters .mk-chips::-webkit-scrollbar { display: none; }
#market-filters .filter-chip { flex: none; white-space: nowrap; padding: .32rem .78rem; }
.mk-sort-btn {
  flex: none; display: inline-flex; align-items: center; gap: .3rem;
  padding: .32rem .7rem; border-radius: 9999px; font-size: .72rem; font-weight: 700;
  color: #ffe9b8; background: rgba(60,35,120,.75);
  border: 1px solid rgba(255,214,120,.4); cursor: pointer;
  white-space: nowrap;
}
.mk-sort-btn:active { transform: scale(.95); }

/* 出售 悬浮按钮 (虾算算式 FAB) */
.sell-fab {
  position: fixed; right: 1.1rem; bottom: 6.8rem; z-index: 40;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .1rem;
  width: 3.6rem; height: 3.6rem; border-radius: 50%;
  background: linear-gradient(160deg, #f6d078, #cf8a2b);
  color: #4a2c00; font-size: .95rem; font-weight: 900;
  border: 2px solid rgba(255,240,190,.75);
  box-shadow: 0 4px 0 rgba(90,50,10,.55), 0 8px 24px rgba(0,0,0,.5), 0 0 20px rgba(246,208,120,.35);
  cursor: pointer; transition: transform .15s;
}
.sell-fab span { font-size: .58rem; letter-spacing: .06em; }
.sell-fab:active { transform: scale(.92); }

/* --- v10-4 品相5档 徽章色: 完美金 极品紫 精良蓝 优秀绿 标准灰 --- */
.cond-t-fine     { background: linear-gradient(135deg,#bcd8ff,#4a8ce8) !important; color: #082a5c !important; }
.cond-t-good     { background: linear-gradient(135deg,#a8ecd9,#3eb894); color: #06392b; }
.cond-good { background-image: url('/static/opt/stamp_fine.webp'); } /* 优秀暂复用fine素材 */
.cond-fine { filter: hue-rotate(-25deg) saturate(1.3) drop-shadow(0 4px 10px rgba(0,0,0,.5)); } /* 印章调蓝 */

/* --- v10 二级页面 (sub-page): 全屏覆盖 + 顶部返回 --- */
#sub-page {
  position: fixed; inset: 0; z-index: 45;
  background: linear-gradient(rgba(7,6,11,.92), rgba(7,6,11,.97)), #0a0812;
  display: flex; flex-direction: column;
  animation: sub-in .22s ease-out;
}
#sub-page.hidden { display: none; }
@keyframes sub-in { from { transform: translateX(28px); opacity: 0; } }
#sub-head {
  flex: none; display: flex; align-items: center; gap: .6rem;
  padding: 1rem 1rem .8rem;
  border-bottom: 1px solid rgba(255,255,255,.07);
}
#sub-back {
  width: 2.4rem; height: 2.4rem; border-radius: .8rem; flex: none;
  display: flex; align-items: center; justify-content: center;
  color: #ffe9b8; font-size: 1rem; cursor: pointer;
  background: rgba(60,35,120,.6); border: 1px solid rgba(255,214,120,.35);
}
#sub-back:active { transform: scale(.92); }
#sub-title { font-size: 1.05rem; font-weight: 900; color: #ffe9b8; }
#sub-body { flex: 1; overflow-y: auto; padding: 1rem 1rem 5rem; -webkit-overflow-scrolling: touch; }

/* 二级页通用: 分段 Tab */
.seg-tabs { display: flex; gap: .4rem; margin-bottom: 1rem; }
.seg-tab {
  flex: 1; text-align: center; padding: .5rem .4rem; border-radius: .7rem;
  font-size: .78rem; font-weight: 700; color: #9ca3af; cursor: pointer;
  background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.1);
}
.seg-tab.active { color: #ffd678; background: rgba(246,208,120,.1); border-color: rgba(246,208,120,.5); }

/* 我的挂单卡片 */
.mylist-row {
  display: flex; align-items: center; gap: .7rem;
  padding: .7rem .8rem; border-radius: .8rem; margin-bottom: .55rem;
  background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.09);
}
.mylist-row .ml-thumb {
  width: 2.6rem; height: 3.4rem; border-radius: .4rem; flex: none;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.35); color: rgba(255,255,255,.3); font-size: 1.1rem;
  border: 1px solid rgba(255,255,255,.12); overflow: hidden;
}
.mylist-row .ml-thumb img { width: 100%; height: 100%; object-fit: cover; }
.ml-status { font-size: .6rem; padding: .1rem .45rem; border-radius: 999px; font-weight: 700; }
.ml-on   { background: rgba(94,234,212,.14); color: #5eead4; border: 1px solid rgba(94,234,212,.4); }
.ml-sold { background: rgba(246,208,120,.14); color: #ffd678; border: 1px solid rgba(246,208,120,.4); }
.ml-off  { background: rgba(255,255,255,.08); color: #9ca3af; border: 1px solid rgba(255,255,255,.18); }
.ml-act {
  flex: none; padding: .32rem .7rem; border-radius: .6rem; font-size: .68rem; font-weight: 700;
  color: #ffe9b8; background: rgba(60,35,120,.7); border: 1px solid rgba(255,214,120,.4); cursor: pointer;
}
.ml-act:active { transform: scale(.94); }

/* 出售藏品: 可选卡片 */
.sell-card { position: relative; cursor: pointer; }
.sell-card.selected::after {
  content: '\2713'; position: absolute; top: .4rem; right: .4rem;
  width: 1.5rem; height: 1.5rem; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: #f6d078; color: #4a2c00; font-weight: 900; font-size: .8rem;
  box-shadow: 0 2px 8px rgba(0,0,0,.5);
}
.sell-card.selected { outline: 2px solid #f6d078; outline-offset: 2px; border-radius: .8rem; }
.sell-bar {
  position: sticky; bottom: 0; margin: 1rem -1rem 0; padding: .9rem 1rem calc(.9rem + env(safe-area-inset-bottom));
  background: rgba(12,8,26,.97); border-top: 1px solid rgba(255,214,120,.25);
  display: flex; align-items: center; gap: .8rem;
}
.sell-bar input {
  flex: 1; min-width: 0; padding: .55rem .8rem; border-radius: .7rem;
  background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.15);
  color: #fff; font-size: .85rem; font-family: 'Rajdhani', sans-serif; font-weight: 700;
}
.sell-bar input:focus { outline: none; border-color: rgba(246,208,120,.6); }
.sell-submit {
  flex: none; padding: .55rem 1.2rem; border-radius: .7rem; font-weight: 900; font-size: .82rem;
  background: linear-gradient(160deg, #f6d078, #cf8a2b); color: #4a2c00;
  border: 1.5px solid rgba(255,240,190,.7); cursor: pointer;
}
.sell-submit:disabled { opacity: .45; pointer-events: none; }

/* 交易记录: 双类型徽标 */
.or-type { font-size: .58rem; padding: .08rem .4rem; border-radius: .3rem; font-weight: 700; flex: none; }
.or-open  { background: rgba(192,132,252,.15); color: #c084fc; border: 1px solid rgba(192,132,252,.4); }
.or-trade { background: rgba(94,234,212,.13); color: #5eead4; border: 1px solid rgba(94,234,212,.4); }

/* 手气统计 (我的收藏替代入口) */
.luck-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.luck-cell {
  padding: .8rem; border-radius: .8rem; text-align: center;
  background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.09);
}
.luck-cell .lc-num { font-family: 'Rajdhani', sans-serif; font-weight: 700; font-size: 1.45rem; color: #ffd678; line-height: 1.15; }
.luck-cell .lc-label { font-size: .62rem; color: #9ca3af; margin-top: .15rem; }
.luck-bar-row { display: flex; align-items: center; gap: .55rem; margin-bottom: .45rem; }
.luck-bar-row .lb-name { width: 2.6rem; flex: none; font-size: .68rem; font-weight: 700; text-align: right; }
.luck-bar-row .lb-track { flex: 1; height: .55rem; border-radius: 999px; background: rgba(255,255,255,.07); overflow: hidden; }
.luck-bar-row .lb-fill { height: 100%; border-radius: 999px; }
.luck-bar-row .lb-val { width: 3.4rem; flex: none; font-size: .64rem; color: #9ca3af; font-family: 'Rajdhani', sans-serif; font-weight: 700; }

/* 故事 Tab */
.story-hero { text-align: center; }
.story-img { width: 5.5rem; margin: 0 auto .6rem; border-radius: 1.2rem; }
.story-lead { font-size: .85rem; color: #d1d5db; line-height: 1.7; }
.story-point { display: flex; gap: .7rem; align-items: flex-start; }
.sp-icon {
  flex: none; width: 2.1rem; height: 2.1rem; border-radius: .7rem; margin-top: .1rem;
  display: flex; align-items: center; justify-content: center; font-size: .85rem;
  color: #ffd678; background: rgba(246,208,120,.1); border: 1px solid rgba(246,208,120,.35);
}

/* toast 防换行(短文案) + 长文案居中收窄 */
#toast { white-space: nowrap; }
@media (max-width: 380px) { #toast { white-space: normal; max-width: 78vw; line-height: 1.5; } }

/* 说明弹窗4个Tab缩窄防换行 */
#guide-tabs { display: flex; gap: .3rem; }
#guide-tabs .gtab { flex: 1; padding: .42rem .2rem; font-size: .72rem; white-space: nowrap; }

/* v10: 幕三结算页大号品相徽章 */
.cond-tag-big {
  display: inline-block; width: auto; min-width: 10.5rem;
  padding: .5rem 1.3rem; border-radius: .8rem;
  font-size: .95rem; font-weight: 900; letter-spacing: .08em;
  margin: .35rem 0 .15rem;
  animation: condPop .45s cubic-bezier(.2,1.4,.4,1) both;
}
@keyframes condPop {
  0% { transform: scale(.5); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}


/* ================= v11 ================= */

/* --- v11-1 玩法 Tab: 去序号 · 图标卡片式条目 --- */
.howto-item {
  display: flex; align-items: flex-start; gap: .8rem;
  padding: .7rem .8rem; border-radius: .9rem;
  background: rgba(255,255,255,.035);
  border: 1px solid rgba(255,214,120,.14);
}
.hi-icon {
  flex: none; width: 2.15rem; height: 2.15rem; border-radius: .7rem; margin-top: .1rem;
  display: flex; align-items: center; justify-content: center; font-size: .9rem;
  color: #ffd678; background: rgba(246,208,120,.1); border: 1px solid rgba(246,208,120,.35);
}

/* --- v11-2 说明弹窗排版微调: pane 统一留白节奏 --- */
.gpane { padding-bottom: .3rem; }
#gp-story .story-hero { padding: .2rem 0 .1rem; }
#gp-story .story-img { width: 6rem; box-shadow: 0 6px 20px rgba(0,0,0,.45); }
#gp-story .odds-text, #gp-story .story-lead { line-height: 1.75; }

/* --- v12 我们 Tab 排版升级: 条目卡片化, 对齐 玩法/概率/品相 的视觉语法 --- */
#gp-story .story-point {
  padding: .7rem .8rem; border-radius: .9rem;
  background: rgba(255,255,255,.035);
  border: 1px solid rgba(255,214,120,.14);
  gap: .8rem;
}
#gp-story .story-point b { font-size: .8rem; }
#gp-story .story-point .sp-icon { width: 2.15rem; height: 2.15rem; font-size: .9rem; }
#gp-story .odds-text {
  padding: 0 .15rem;
}
.story-cta {
  text-align: center; font-size: .8rem; font-weight: 700; color: #d1d5db;
  padding: .65rem .8rem; border-radius: .9rem; margin-top: .1rem;
  background: linear-gradient(135deg, rgba(246,208,120,.12), rgba(240,180,41,.06));
  border: 1px solid rgba(246,208,120,.4);
  box-shadow: 0 0 16px rgba(246,208,120,.12) inset;
}

/* --- v11-3 图鉴/交易所: 卡图统一展示框 (真图铺满, 占位同尺寸不跳动) --- */
.card-face-box {
  position: relative; width: 100%; aspect-ratio: 2/3;
  border-radius: .7rem; overflow: hidden;
  background: linear-gradient(160deg, rgba(255,255,255,.05), rgba(0,0,0,.25));
  border: 1px solid rgba(255,255,255,.09);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
}
.card-face-box > img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; display: block;
}
.cfb-ph { font-size: 1.6rem; color: rgba(255,255,255,.28); }
.cfb-ph-label { font-size: .58rem; color: rgba(255,255,255,.4); margin-top: .3rem; letter-spacing: .05em; }
.market-card .card-face-box { margin-top: .1rem; }
.market-card .card-face-box > img { object-fit: cover; }

/* --- v11-4 iOS 刘海安全区 (standalone PWA) --- */
@supports (padding-top: env(safe-area-inset-top)) {
  #ticker-bar { height: calc(1.9rem + env(safe-area-inset-top)); padding-top: env(safe-area-inset-top); }
  .view { padding-top: calc(2.4rem + env(safe-area-inset-top)) !important; }
  .hero-app {
    min-height: calc(100vh - 2.4rem - 6.5rem - env(safe-area-inset-top));
    min-height: calc(100dvh - 2.4rem - 6.5rem - env(safe-area-inset-top));
  }
  #sub-head { padding-top: calc(1rem + env(safe-area-inset-top)); }
  #reveal-overlay { padding-top: env(safe-area-inset-top); }
}

/* v11-3b 交易所徽章: 悬浮在卡图内部顶端 (原顶栏被华丽边框遮挡) */
.market-card .card-face-box .mc-top {
  position: absolute; top: .35rem; left: .4rem; right: .4rem; z-index: 6;
}
.market-card .card-face-box .mc-top .el-rbadge,
.market-card .card-face-box .mc-top .mc-cond {
  background: rgba(10,6,22,.72); border-radius: .45rem; padding: .12rem .4rem;
  backdrop-filter: blur(2px);
}


/* ================= v12: 幕一状态文字特效 ================= */
.summon-hint {
  font-family: 'ZCOOL QingKe HuangYou', 'Noto Sans SC', sans-serif;
  font-size: 1.45rem; font-weight: 900;
  letter-spacing: .55em; text-indent: .55em; /* 光学居中 */
  color: #cbd5e1; text-align: center; min-height: 2.2rem;
  --hc: rgba(190,200,225,.55); /* 默认辉光色 */
}
.summon-hint .hline { display: block; }
.summon-hint.h-multi { font-size: 1.2rem; letter-spacing: .32em; text-indent: .32em; line-height: 1.75; }   /* v31.4 两行等待句略收字距 */
/* v31.5 等待句彩虹: 每字一个色相 (JS 内联), 整块缓慢 hue 流转; 省光效/静态档 (fxauto lvl≥2) 不转 */
.summon-hint.h-rainbow { animation: hint-hue 6s linear infinite; }
.summon-hint.h-rainbow .hchar { text-shadow: 0 0 10px currentColor, 0 0 28px var(--hc), 0 2px 3px rgba(0,0,0,.6); }
@keyframes hint-hue { to { filter: hue-rotate(360deg); } }
body.fx-lvl-2 .summon-hint.h-rainbow, body.fx-lvl-3 .summon-hint.h-rainbow { animation: none; }
/* 稀有度同色辉光 (与盒体充能色一致, 强化"泄露天机") */
.summon-hint.h-common    { color: #e8eefc; --hc: rgba(210,225,245,.6); }
.summon-hint.h-rare      { color: #8fe8ff; --hc: rgba(80,215,255,.75); }
.summon-hint.h-epic      { color: #d6a9ff; --hc: rgba(180,110,255,.8); }
.summon-hint.h-legendary { color: #ffdf8e; --hc: rgba(255,195,80,.85); }
.summon-hint.h-mythic    { color: #ff9d8a; --hc: rgba(255,90,70,.9); }

/* 逐字显影: 下方浮起 + 模糊聚焦 + 微缩放 */
.summon-hint .hchar {
  display: inline-block; opacity: 0;
  text-shadow: 0 0 12px var(--hc), 0 0 34px var(--hc), 0 2px 3px rgba(0,0,0,.6);
  animation: hchar-in .5s cubic-bezier(.2,.9,.3,1.2) forwards;
}
@keyframes hchar-in {
  0%   { opacity: 0; transform: translateY(14px) scale(.7); filter: blur(6px); }
  60%  { opacity: 1; filter: blur(0); }
  100% { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}
/* 显影完成后持续呼吸辉光 */
.summon-hint:not(.h-burst) .hchar { animation: hchar-in .5s cubic-bezier(.2,.9,.3,1.2) forwards, hint-breathe 2.4s ease-in-out .6s infinite; }
@keyframes hint-breathe {
  0%, 100% { text-shadow: 0 0 10px var(--hc), 0 0 26px var(--hc), 0 2px 3px rgba(0,0,0,.6); }
  50%      { text-shadow: 0 0 18px var(--hc), 0 0 46px var(--hc), 0 2px 3px rgba(0,0,0,.6); }
}

/* 奇点爆发: 大字冲击 — 从 2.6 倍炸缩落位 + 过曝白闪 + 余震 */
.summon-hint.h-burst { font-size: 1.9rem; letter-spacing: .3em; text-indent: .3em; }
.summon-hint.h-burst .hchar { animation: hchar-burst .62s cubic-bezier(.15,1.3,.35,1) forwards; }
@keyframes hchar-burst {
  0%   { opacity: 0; transform: scale(2.6); filter: blur(8px) brightness(3); }
  45%  { opacity: 1; transform: scale(.92); filter: blur(0) brightness(1.8); }
  70%  { transform: scale(1.06); filter: brightness(1.25); }
  100% { opacity: 1; transform: scale(1); filter: brightness(1);
         text-shadow: 0 0 16px var(--hc), 0 0 44px var(--hc), 0 0 90px var(--hc), 0 2px 3px rgba(0,0,0,.65); }
}


/* ================= v14: 弹性叙事 + 编排重构 ================= */
/* 交叠转场遮罩 (盖住幕间切换缝) */
#act-veil {
  position: fixed; inset: 0; z-index: 58; pointer-events: none; opacity: 0;
  background: radial-gradient(circle at 50% 45%, rgba(255,255,255,.96), rgba(220,215,255,.85) 45%, rgba(120,100,220,.5) 75%, rgba(20,10,46,.2));
}

/* 幕二: 鉴定悬念行 */
.element-tease {
  padding: .7rem 1rem; border-radius: .8rem; text-align: center;
  font-size: .8rem; letter-spacing: .25em; color: #fcd34d;
  border: 1px dashed rgba(252,211,77,.4); background: rgba(252,211,77,.06);
  animation: tease-blink .35s ease-in-out infinite alternate;
}
@keyframes tease-blink { from { opacity: .55; } to { opacity: 1; } }

/* 幕二: 传说/神话彩蛋句 */
.element-egg {
  padding: 1rem; text-align: center; font-size: 1.15rem; font-weight: 900;
  font-family: 'ZCOOL QingKe HuangYou', 'Noto Sans SC', sans-serif;
  letter-spacing: .4em; text-indent: .4em;
  animation: hchar-in .6s cubic-bezier(.2,.9,.3,1.2) both;
}
.element-egg.h-legendary { color: #ffdf8e; text-shadow: 0 0 14px rgba(255,195,80,.8), 0 0 40px rgba(255,195,80,.5); }
.element-egg.h-mythic    { color: #ff9d8a; text-shadow: 0 0 14px rgba(255,90,70,.85), 0 0 40px rgba(255,90,70,.55); }

/* 幕二半: 星铸旋涡 */
.forge-vortex { position: relative; width: 180px; height: 180px; }
.fv-ring {
  position: absolute; inset: 0; border-radius: 50%;
  border: 2px solid transparent;
  border-top-color: rgba(160,140,255,.85); border-right-color: rgba(160,140,255,.25);
  animation: fv-spin 1.6s linear infinite;
}
.fv-ring.fv-r2 {
  inset: 18px;
  border-top-color: rgba(255,210,120,.85); border-right-color: rgba(255,210,120,.2);
  animation: fv-spin 1.1s linear infinite reverse;
}
.fv-core {
  position: absolute; inset: 52px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.95), rgba(190,170,255,.75) 45%, rgba(120,90,230,.25) 75%, transparent);
  animation: fv-pulse 1.8s ease-in-out infinite;
  filter: blur(1px);
}
@keyframes fv-spin { to { transform: rotate(360deg); } }
@keyframes fv-pulse { 0%,100% { transform: scale(.88); opacity: .8; } 50% { transform: scale(1.12); opacity: 1; } }
#forge-skip { transition: opacity .2s; }
#forge-skip:active { opacity: 1; }
#forge-text { min-height: 2.4rem; }


/* --- v15: 我的页未登录态 (IP 吉祥物 + 四色随机霓虹登录按钮) --- */
.me-guest { padding: 2.2rem 0 3rem; display: flex; flex-direction: column; align-items: center; }
.mg-mascot {
  width: min(13.5rem, 56vw); height: auto;
  filter: drop-shadow(0 10px 26px rgba(0,0,0,.5));
  animation: mascot-float 4.2s ease-in-out infinite;
  pointer-events: none; user-select: none;
}
@keyframes mascot-float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }
.img-login-btn {
  position: relative; display: block; margin: 0 auto;
  width: min(19rem, 78vw); aspect-ratio: 720/400;
  background: none; border: none; padding: 0; cursor: pointer;
  -webkit-tap-highlight-color: transparent; overflow: visible;
}
.img-login-btn:active { transform: translateY(3px) scale(.99); }
.img-login-btn .lb-img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: contain; pointer-events: none; user-select: none;
}
.img-login-btn .lb-c { opacity: 1; filter: drop-shadow(0 8px 20px rgba(0,0,0,.5)); animation: lb-breathe 2.8s ease-in-out infinite; }
.img-login-btn .lb-n { opacity: 0; transition: opacity 1.4s ease-in-out; filter: drop-shadow(0 8px 20px rgba(0,0,0,.5)); }
.img-login-btn.lb-swap .lb-n { opacity: 1; }
.img-login-btn .lb-pressed { opacity: 0; transition: opacity .06s; filter: drop-shadow(0 0 24px rgba(200,120,255,.6)); }
.img-login-btn.pressing .lb-c,
.img-login-btn.pressing .lb-n { opacity: 0 !important; transition: opacity .06s; }
.img-login-btn.pressing .lb-pressed { opacity: 1; }
.img-login-btn.pressing .lb-text { transform: translate(-50%,-46%) scale(.92); opacity: .85; }
@keyframes lb-breathe {
  0%,100% { filter: drop-shadow(0 8px 20px rgba(0,0,0,.5)) brightness(1); }
  50%     { filter: drop-shadow(0 8px 26px rgba(0,0,0,.55)) brightness(1.09); }
}
.lb-text {
  position: absolute; left: 50%; top: 47%;
  transform: translate(-50%,-50%);
  font-family: 'Noto Sans SC', sans-serif;
  font-weight: 900; font-size: 1.45rem; letter-spacing: .42em; text-indent: .42em;
  color: #6b3a08; white-space: nowrap;
  text-shadow: 0 1px 0 rgba(255,240,190,.75), 0 2px 3px rgba(120,60,0,.25);
  pointer-events: none; transition: transform .08s, opacity .08s;
}

/* ---------- L2 全息鉴赏入口按钮 (卡详情弹窗) ---------- */
.holo-view-btn {
  display: flex; align-items: center; justify-content: center; gap: 5px;
  width: 6rem; padding: 6px 0; border-radius: 9px;
  background: linear-gradient(135deg, rgba(252,211,77,.18), rgba(180,120,30,.14));
  border: 1px solid rgba(252,211,77,.45);
  color: #fde68a; font-size: 10px; font-weight: 800; letter-spacing: .08em;
  text-decoration: none; transition: background .2s, transform .1s;
}
.holo-view-btn:active { transform: scale(.96); }
.holo-view-btn i { font-size: 9px; }

/* ---------- 修复: 从 L2 返回后开盒按钮掉底 (iOS bfcache 恢复时 vh/dvh 不重算, hero 被旧"大视口"值撑高压进底栏) ----------
   根治: hero 高度不再锚 100vh/dvh, 改锚定父容器 #view-open (fixed inset:0 且 padding 已减 ticker+底栏, 内容高天生正确) */
.hero-app { min-height: 100%; }
@supports (padding-top: env(safe-area-inset-top)) {
  .hero-app { min-height: 100%; }
}


/* ================= 重置卡池 (我的页, 演示用) ================= */
.me-menu-danger { border-color: rgba(255,122,110,.22); background: rgba(255,90,70,.04); }
.me-menu-danger .me-item { color: #ffb4a8; }
.me-menu-danger .me-item:hover { background: rgba(255,90,70,.08); }
.mi-icon.mi-danger { color: #ff8a7a; background: rgba(255,90,70,.12); border-color: rgba(255,122,110,.3); }
.reset-icon {
  width: 3.4rem; height: 3.4rem; margin: 0 auto; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; font-size: 1.4rem; color: #ff8a7a;
  background: radial-gradient(circle at 40% 32%, rgba(255,110,90,.28), rgba(120,30,30,.35) 70%);
  border: 1.5px solid rgba(255,122,110,.45); box-shadow: 0 0 22px rgba(255,90,70,.3);
}
.danger-btn {
  padding: .6rem 1rem; border-radius: .8rem; font-size: .85rem; font-weight: 800; color: #fff;
  background: linear-gradient(180deg, #ff7a6a, #d43a2c);
  border: 1.5px solid rgba(255,170,160,.35);
  box-shadow: 0 4px 0 #6e1410, inset 0 1px 0 rgba(255,255,255,.3);
  cursor: pointer; transition: transform .12s, box-shadow .12s;
}
.danger-btn:active { transform: translateY(3px); box-shadow: 0 1px 0 #6e1410, inset 0 1px 0 rgba(255,255,255,.3); }


/* v16 .fcard 块已于 v22 删除 (被 .rcard 取代, 见文件末尾) */

/* ================= v17: 自绘下拉刷新 #ptr ================= */
#ptr {
  position: fixed; left: 50%; top: calc(1.9rem + env(safe-area-inset-top, 0px) + .3rem); z-index: 40;
  display: flex; align-items: center; gap: .5rem; padding: .3rem .75rem .3rem .35rem;
  border-radius: 999px; pointer-events: none;
  background: rgba(20,12,44,.92); border: 1px solid rgba(148,120,255,.4);
  box-shadow: 0 6px 18px rgba(0,0,0,.5), inset 0 1px 0 rgba(255,255,255,.1);
  opacity: 0; transform: translate(-50%, -10px); transition: opacity .18s;
  --p: 0;
}
#ptr.show { opacity: calc(.35 + var(--p) * .65); }
#ptr .ptr-ring {
  width: 1.7rem; height: 1.7rem; border-radius: 50%; flex: none; position: relative;
  display: flex; align-items: center; justify-content: center; font-size: .8rem; color: #cbd5ff;
}
/* 进度环走伪元素 (mask 挖空), 图标独立不受 mask 影响 */
#ptr .ptr-ring::before { content: ''; position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(#8b7bff calc(var(--p) * 360deg), rgba(255,255,255,.1) 0);
  -webkit-mask: radial-gradient(circle, transparent 58%, #000 60%); mask: radial-gradient(circle, transparent 58%, #000 60%); }
#ptr .ptr-ring i { position: relative; transition: transform .1s; }
#ptr.ready .ptr-ring::before { background: conic-gradient(#ffd76e 360deg, #ffd76e 0); }
#ptr.ready .ptr-ring i { color: #ffd76e; }
#ptr.loading .ptr-ring::before { background: conic-gradient(#8b7bff 0 25%, rgba(255,255,255,.1) 25%); animation: ptr-spin .7s linear infinite; }
#ptr.loading .ptr-ring i { opacity: 0; }
@keyframes ptr-spin { to { transform: rotate(360deg); } }
#ptr .ptr-txt { font-size: .7rem; font-weight: 700; letter-spacing: .08em; color: #d6cffb; white-space: nowrap; }
#ptr.ready .ptr-txt { color: #ffe9b8; }


/* ================= v18: iOS PWA 顶部白边修复 / 性能 ================= */
html { background: #1a0f38; }            /* 状态栏透出区 + 启动瞬间 + 回弹露底 全部深色 */
body { background: #0a0918 !important; }
/* standalone 模式: 状态栏区域用跑马灯同色填满, 消灭白边/断层 */
@media (display-mode: standalone) {
  html { background: #1a0f38; }
}
@supports (-webkit-touch-callout: none) {
  /* iOS 专属: fixed 元素在橡皮筋回弹时露出 html 底色 → 已由上方 html 背景兜底 */
  .view { -webkit-overflow-scrolling: touch; }
}


/* ================= v20: 图像鉴定按钮 (幕三) ================= */
.img-ident-btn {
  position: relative; display: block; margin: 0 auto;
  width: min(7.6rem, 34vw); aspect-ratio: 1;
  background: none; border: none; padding: 0; cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  animation: ident-bob 3.2s ease-in-out infinite;
  transition: transform .1s;
}
@keyframes ident-bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
.img-ident-btn .ib-img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: contain; pointer-events: none; user-select: none;
  transition: opacity 1.4s ease-in-out;
  filter: drop-shadow(0 0 16px var(--ib-glow, rgba(94,234,212,.45))) drop-shadow(0 10px 18px rgba(0,0,0,.55));
}
/* 三色交替: .ib-c 当前色 / .ib-n 下一色, JS 换 src 后加 .ib-swap 交叉淡入 (同登录按钮机制) */
.img-ident-btn .ib-c { opacity: 1; animation: ident-glow 2.6s ease-in-out infinite; }
.img-ident-btn .ib-n { opacity: 0; }
.img-ident-btn.ib-swap .ib-c { opacity: 0; }
.img-ident-btn.ib-swap .ib-n { opacity: 1; }
.img-ident-btn .ib-pressed { opacity: 0; transition: opacity .06s; filter: drop-shadow(0 0 22px rgba(120,255,180,.7)) drop-shadow(0 4px 8px rgba(0,0,0,.6)); }
.img-ident-btn.pressing { transform: translateY(3px) scale(.97); animation: none; }
.img-ident-btn.pressing .ib-c, .img-ident-btn.pressing .ib-n { opacity: 0 !important; transition: opacity .06s; }
.img-ident-btn.pressing .ib-pressed { opacity: 1; }
@keyframes ident-glow {
  0%,100% { filter: drop-shadow(0 0 10px var(--ib-glow, rgba(94,234,212,.35))) drop-shadow(0 10px 18px rgba(0,0,0,.55)); }
  50%     { filter: drop-shadow(0 0 28px var(--ib-glow, rgba(94,234,212,.8)))  drop-shadow(0 10px 18px rgba(0,0,0,.55)); }
}
/* 色相同步辉光 (JS 写 --ib-glow) */
.ident-label {
  margin-top: .1rem; font-family: 'Noto Sans SC', sans-serif; font-weight: 900; font-size: 1.15rem;
  letter-spacing: .45em; text-indent: .45em;
  background: linear-gradient(175deg, #fffbe8 8%, #ffe58a 32%, #f5b93c 55%, #b4791d 78%, #ffd76e 96%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,.8));
}
/* 跳过提示: 屏幕底部, 延迟 1.5s 淡入, 不抢首眼 */
.act3-skip-hint {
  position: fixed; z-index: 60; left: 0; right: 0; bottom: calc(1.6rem + env(safe-area-inset-bottom, 0px));
  text-align: center; font-size: .7rem; letter-spacing: .14em; color: rgba(255,255,255,.42);
  pointer-events: none; opacity: 0; animation: skip-in .6s ease 1.5s forwards;
}
.act3-skip-hint.hidden { display: none; }
@keyframes skip-in { to { opacity: 1; } }
/* 旧 CSS 鉴定按钮样式保留 (identify-btn) 但已无 DOM 引用 */

/* 矮屏 (SE/折叠屏) 幕三: 卡稍收, 保证鉴定按钮+跳过提示同屏 */
@media (max-height: 700px) {
  .final-card { --a3-avail: calc(100dvh - 12.5rem - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px)); }
  #act3.identified .final-card { --a3-avail: calc(100dvh - 15.5rem - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px)); }
  .img-ident-btn { width: min(6.6rem, 30vw); }
  .act3-skip-hint { bottom: calc(.9rem + env(safe-area-inset-bottom, 0px)); }
}

/* ============================================================
   v22 真实闪卡列表卡 (.rcard) = 五档卡框 + card agent 真卡 (用户: "我的伙伴/交易所 卡牌都需要带着边框")
   框: /static/holo/frame_{tier}.webp (symlink → card-site/static/holo, 与 L2 引擎同源, card 侧迭代后重部署即同步)
   几何 (750×1050): 窗口 x50-698 y120-932 → left 6.67% top 11.43% w 86.4% h 77.33%
                    铭牌槽 x228-521 y949-1023 → left 30.4% top 90.4% w 39.1% h 7%
   容器锁 5:7 与框同比 → contain 永不拉伸; 卡面 896×1200 在窗内 cover (窗 648×812 ≈ 0.798 vs 0.747, 上下微裁)
   ============================================================ */
.rcard { position: relative; aspect-ratio: 5/7; width: 100%; padding: 0 !important; display: block;
  overflow: visible; border-radius: 0; background: none !important; border: 0 !important; box-shadow: none !important;
  filter: drop-shadow(0 10px 18px rgba(0,0,0,.6)); }
.rcard::before { content: ''; position: absolute; inset: 0; z-index: 3; pointer-events: none; background: center / contain no-repeat; }
.rc-common.rcard::before    { background-image: url('/static/holo/frame_common.webp?v7'); }
.rc-rare.rcard::before      { background-image: url('/static/holo/frame_rare.webp?v7'); }
.rc-epic.rcard::before      { background-image: url('/static/holo/frame_epic.webp?v7'); }
.rc-legendary.rcard::before { background-image: url('/static/holo/frame_legend.webp?v7'); }
.rc-mythic.rcard::before    { background-image: url('/static/holo/frame_mythic.webp?v7'); }
.rc-rare.rcard      { filter: drop-shadow(0 10px 18px rgba(0,0,0,.6)) drop-shadow(0 0 10px rgba(127,177,187,.28)); }
.rc-epic.rcard      { filter: drop-shadow(0 10px 18px rgba(0,0,0,.6)) drop-shadow(0 0 12px rgba(150,90,220,.35)); }
.rc-legendary.rcard { filter: drop-shadow(0 10px 18px rgba(0,0,0,.6)) drop-shadow(0 0 14px rgba(246,190,90,.4)); }
.rc-mythic.rcard    { filter: drop-shadow(0 10px 18px rgba(0,0,0,.6)) drop-shadow(0 0 16px rgba(255,80,70,.45)); }
.gallery-card.rcard { aspect-ratio: 5/7; justify-content: initial; }
/* 卡面窗口 */
.rcard .rc-face { position: absolute; left: 6.67%; top: 11.43%; width: 86.4%; height: 77.33%; z-index: 1; overflow: hidden;
  border-radius: 2px; background: radial-gradient(ellipse at 50% 40%, #171a2c, #08090f 80%);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .35rem; }
.rcard .rc-face > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.rcard .rc-face .cfb-ph { font-size: 1.6rem; color: rgba(255,255,255,.35); }
.rcard .rc-face .cfb-ph-label { font-size: .6rem; color: rgba(255,255,255,.5); padding: 0 .5rem; text-align: center; }
.rcard .holo-shine, .rcard .holo-glare { z-index: 4; border-radius: 3.2% / 2.3%; }
.rcard .holo-glare { z-index: 5; }
/* 窗内顶部: SN/徽章 + 品相 */
.rcard .rc-top { position: absolute; left: 9.5%; right: 9.5%; top: 13.2%; z-index: 6; margin: 0;
  display: flex; justify-content: space-between; align-items: center; gap: .3rem;
  font-size: .58rem; color: rgba(255,255,255,.75); padding: .16rem .4rem;
  background: rgba(8,6,20,.66); backdrop-filter: blur(3px); border-radius: .4rem; border: 1px solid rgba(255,255,255,.08); }
.rcard .rc-top .el-rbadge { margin: 0; }
/* 窗内底部: 卡名 + 星; 铭牌槽: 价格 */
.rcard .rc-bot { position: absolute; inset: 0; z-index: 6; pointer-events: none; }
.rcard .rc-name { position: absolute; left: 9.5%; right: 9.5%; bottom: 13.2%; text-align: center;
  font-size: .66rem; font-weight: 800; letter-spacing: .05em; padding: .16rem .3rem; border-radius: .4rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  background: rgba(8,6,20,.66); backdrop-filter: blur(3px); border: 1px solid rgba(255,255,255,.08); }
.rcard .rc-name small { font-size: .55rem; opacity: .85; margin-left: .1rem; }
.rcard .rc-price { position: absolute; left: 30.4%; width: 39.1%; top: 90.4%; height: 7%;
  display: flex; align-items: center; justify-content: center; gap: .18rem; white-space: nowrap;
  font-family: 'Rajdhani', 'Noto Sans SC', sans-serif; font-weight: 900; font-size: .78rem; line-height: 1; font-variant-numeric: tabular-nums; }
.rcard .rc-price .gp-num { background: linear-gradient(175deg, #fffbe8 8%, #ffe58a 32%, #f5b93c 55%, #b4791d 78%, #ffd76e 96%);
  -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 1px 1px rgba(0,0,0,.8)); }
.rcard .rc-price small { font-size: .5rem; font-weight: 800; color: #e8c565; letter-spacing: .04em; }
.rcard .rc-price em { font-style: normal; font-size: .5rem; font-weight: 800; color: #ffd27a; margin-left: .1rem; }
.rcard .corner-badge { top: 7.5%; right: -.3rem; z-index: 7; }
/* 悬浮/倾斜 */
.gallery-card.rcard:hover  { transform: perspective(900px) rotateX(var(--rx)) rotateY(var(--ry)) translateY(-4px); }
.gallery-card.rcard:active { transform: perspective(900px) rotateX(var(--rx)) rotateY(var(--ry)) scale(.97); }
/* 交易所: 框内 徽章+品相+价格(铭牌); 名称/卖家/购买在框外; 整卡可点 */
.market-card .rcard { flex: none; margin-bottom: .25rem; cursor: pointer; }
.market-card .rcard:active { transform: scale(.97); }
.market-card .mc-name { margin-top: .15rem; }
/* 出售小卡 (3 列): 只留框+卡面 */
.rcard-mini .rc-top, .rcard-mini .rc-bot { display: none; }
.sell-card.selected { outline: none; border-radius: 0; }
.sell-card.selected .rcard { filter: drop-shadow(0 0 0 2px #f6d078) drop-shadow(0 6px 12px rgba(0,0,0,.6)); }
.sell-card.selected::after { top: .1rem; right: .1rem; z-index: 8; }
@media (max-width: 420px) {
  .rcard .rc-top { font-size: .52rem; }
  .rcard .rc-name { font-size: .6rem; }
  .rcard .rc-price { font-size: .72rem; }
}

/* ---- v31 测试员模式 (实时生成通道) ---- */
.lab-card { margin: 0 0 14px; padding: 12px 14px; border-radius: 14px; border: 1px dashed rgba(94,234,212,.35); background: rgba(20,184,166,.06); color: #ccfbf1; font-size: .8rem; }
.lab-card.lab-on { border-style: solid; border-color: rgba(94,234,212,.55); background: rgba(20,184,166,.10); }
.lab-row { display: flex; align-items: center; gap: 8px; cursor: pointer; list-style: none; }
.lab-row::-webkit-details-marker { display: none; }
.lab-row b { color: #99f6e4; }
.lab-row .fa-flask { color: #5eead4; }
.lab-user { margin-left: auto; font-family: ui-monospace, monospace; color: #5eead4; }
.lab-note { margin: 6px 0 0; color: rgba(204,251,241,.7); font-size: .74rem; line-height: 1.5; }
.lab-row .lab-note { margin: 0 0 0 auto; }
.lab-form { display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px; margin-top: 10px; }
.lab-in { min-width: 0; padding: 8px 10px; border-radius: 9px; border: 1px solid rgba(94,234,212,.3); background: rgba(0,0,0,.35); color: #ecfeff; font-size: .82rem; outline: none; }
.lab-in:focus { border-color: #5eead4; }
.lab-btn { padding: 8px 14px; border-radius: 9px; border: 0; background: linear-gradient(135deg, #14b8a6, #0d9488); color: #022c22; font-weight: 800; font-size: .8rem; }
.lab-btn-ghost { margin-top: 10px; background: transparent; border: 1px solid rgba(94,234,212,.4); color: #99f6e4; font-weight: 700; }
.lab-err { margin-top: 8px; color: #fca5a5; font-size: .74rem; }
.lab-badge { position: fixed; top: calc(env(safe-area-inset-top, 0px) + 8px); left: 50%; transform: translateX(-50%); z-index: 45; padding: 4px 10px; border-radius: 999px; border: 1px solid rgba(94,234,212,.5); background: rgba(6,78,59,.85); color: #99f6e4; font-size: .68rem; font-weight: 700; backdrop-filter: blur(6px); }
