/* 扭蛋派对 · 深夜收藏家展示间里的巨型 PA 扭蛋机(黑玻璃、铬银、珍珠白、糖果色扭蛋、柠檬黄霓虹边)
   只有素材(展示间、机身两段、玻璃球、扭蛋 / 公仔、奖池空白牌、按键底板、摇杆)是图片,字、操作台、演出全是 CSS。
   尺寸由 capsule.js 的 layoutFor 按画面宽高算好写进变量:--fw 机身宽(盘面窗口 = 70.66%,≥ 画面宽 88%)、--crown-h 玻璃球那一层、
   --dome-h 玻璃球、--jp-w / --jp-h 奖池牌;下面的默认值是 360×640 那一份(变量还没写进来那一帧也排得对)。
   跟着画面宽变的字(cqw)一律另写一条 font-size 接在 font 后面:旧的 iOS WebKit 不认容器单位只丢那一条,前面的 font 照样有效。 */
.capsule {
  position: fixed; inset: 0; z-index: 10; overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain;
  display: flex; flex-direction: column; container: capsule / size;
  padding: var(--safe-t, 0px) 0 var(--safe-b, 0px);
  --bg: #050507; --ink: #fff; --ink-2: #b9b9c4; --ink-3: #85858f;
  --neon: #e5ff3d; --neon-ink: #101108; --gold: #ffd84a; --pearl: #f4f1ea; --bad: #ff5a5a; /* 输掉的钱一律这个红(test/loss-amount.test.js) */
  --sans: system-ui, -apple-system, "PingFang SC", "Noto Sans CJK SC", "Microsoft YaHei", sans-serif;
  /* 扭蛋机自己的字:圆体数字,玩具感(B03 每个游戏有自己的字体) */
  --round: ui-rounded, "SF Pro Rounded", "Nunito", "Arial Rounded MT Bold", var(--sans);
  --fw: 450px; --crown-h: 90px; --dome-h: 88px; --jp-w: 56px; --jp-h: 84px;
  background: var(--bg); color: var(--ink); font-family: var(--sans);
  -webkit-user-select: none; user-select: none; -webkit-tap-highlight-color: transparent;
}
.capsule[hidden] { display: none; }
.capsule *, .capsule *::before, .capsule *::after { box-sizing: border-box; }
.capsule :where(p, h2, h3, figure) { margin: 0; }
/* 用 :where 把重置的权重压到 0:后面单个 class 的按钮样式才盖得过它(button 的 background:none 会吃掉底板) */
.capsule :where(button) { appearance: none; border: 0; margin: 0; padding: 0; font: inherit; color: inherit; background: none; cursor: pointer; touch-action: manipulation; }
.capsule button:focus-visible { outline: 2px solid var(--neon); outline-offset: 2px; }
.capsule img { -webkit-user-drag: none; pointer-events: none; }
.capsule button > *, .capsule button * { pointer-events: none; }

/* ---------- 背景:展示间铺满,四周压暗;免费游戏整个转成彩虹霓虹(J06) ---------- */
.cpx-bg { position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.cpx-bg img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; opacity: .9; }
.cpx-bg::after {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% 42%, transparent 30%, rgba(0,0,0,.62) 100%),
    linear-gradient(rgba(0,0,0,.45), transparent 16%, transparent 64%, rgba(0,0,0,.82));
}
.capsule.is-free .cpx-bg img { animation: cpx-rainbow 5s linear infinite; }
.capsule.is-free .cpx-window { box-shadow: inset 0 0 34px rgba(255, 80, 220, .28), inset 0 0 0 1px rgba(120, 200, 255, .35); }
/* 窗框外圈、操作台的霓虹边、玻璃球、游戏名一起转彩虹(只转边和光,按钮本身的颜色不动) */
.capsule.is-free .cpx-glow { opacity: 1; box-shadow: 0 0 0 2px #ff6bd6, 0 0 22px 6px rgba(120, 200, 255, .5), inset 0 0 26px rgba(255, 80, 220, .3); animation: cpx-rainbow 3s linear infinite; }
.capsule.is-free .cpx-console::before { content: ''; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; box-shadow: inset 0 0 0 2px #ff6bd6, 0 -6px 18px rgba(255, 107, 214, .45); animation: cpx-rainbow 3s linear infinite; }
.capsule.is-free .cpx-dome-art { animation: cpx-rainbow 4s linear infinite; }
.capsule.is-free .cpx-title { background: linear-gradient(90deg, #ff6bd6, #ffe36a, #6bf0ff, #b48cff); -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; filter: drop-shadow(0 0 8px rgba(255, 120, 230, .6)); }
@keyframes cpx-rainbow { from { filter: hue-rotate(0deg) saturate(1.6) brightness(1.08); } to { filter: hue-rotate(360deg) saturate(1.6) brightness(1.08); } }
/* 大奖停格(W04):标题出来前整个画面定住(盘面脉动、倍数章、玻璃球都停),亮一点 */
.capsule.is-freeze :is(.cpx-top, .cpx-stage, .cpx-console), .capsule.is-freeze :is(.cpx-top, .cpx-stage, .cpx-console) * { animation-play-state: paused !important; transition: none !important; }
.capsule.is-freeze .cpx-stage { filter: brightness(1.18) saturate(1.25); }
/* 震屏:只震顶栏、主画面、操作台(特效层不震);BIG / 稀有款轻、MEGA 以上 / 史诗款 / 隐藏款重 */
.capsule.is-shake > :is(.cpx-top, .cpx-stage, .cpx-console) { animation: cpx-shake .55s cubic-bezier(.36, .07, .19, .97) .12s both; }
.capsule.is-shake-hard > :is(.cpx-top, .cpx-stage, .cpx-console) { animation: cpx-shake-hard .8s cubic-bezier(.36, .07, .19, .97) .12s both; }
@keyframes cpx-shake { 10%, 90% { transform: translate3d(-1px, 0, 0); } 20%, 80% { transform: translate3d(3px, -1px, 0); } 30%, 50%, 70% { transform: translate3d(-5px, 2px, 0); } 40%, 60% { transform: translate3d(5px, -2px, 0); } }
@keyframes cpx-shake-hard { 10%, 90% { transform: translate3d(-2px, 1px, 0); } 20%, 80% { transform: translate3d(6px, -3px, 0) rotate(.3deg); } 30%, 50%, 70% { transform: translate3d(-9px, 4px, 0) rotate(-.4deg); } 40%, 60% { transform: translate3d(9px, -4px, 0) rotate(.4deg); } }

/* ---------- 顶栏:返回、游戏名、余额、喇叭、说明(照别的单人游戏;按键 44px) ---------- */
.cpx-top { position: relative; z-index: 6; flex: none; height: 46px; display: flex; align-items: center; gap: 4px; padding: 1px 6px; }
.cpx-ico { position: relative; flex: none; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; color: var(--pearl); }
.cpx-ico::before { content: ''; position: absolute; inset: 3px; border-radius: 50%; background: rgba(10, 10, 14, .74); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); }
.cpx-ico svg { position: relative; width: 20px; height: 20px; }
.cpx-ico[aria-pressed="false"] { color: var(--ink-3); }
.cpx-title {
  flex: 1; min-width: 0; padding-left: 2px; font: 900 16px/1.1 var(--round); letter-spacing: .03em; color: #fff;
  text-shadow: 0 0 10px rgba(255, 216, 74, .55), 0 2px 0 #000; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.cpx-bal {
  flex: none; max-width: 34%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 6px 10px; border-radius: 12px;
  background: rgba(10, 10, 14, .76); box-shadow: inset 0 0 0 1px rgba(255, 216, 74, .45); font: 800 13px/1.2 var(--round); font-variant-numeric: tabular-nums;
}
@container capsule (max-width: 359px) { .cpx-title { font-size: 15px; } .cpx-bal { padding: 5px 8px; font-size: 12px; } }

/* ---------- 主画面:奖池牌 + 玻璃球(crown)、机身上段(图鉴展示条)、窗框 + 5×4 盘面 ---------- */
.cpx-stage { position: relative; z-index: 1; flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
/* 矮的画面(360×640 那种):奖池牌左右各两块夹着玻璃球;够高(is-tall)就奖池牌一排在上、玻璃球大大地站在下面 */
.cpx-crown {
  position: relative; z-index: 3; flex: 1 1 var(--crown-h); min-height: 0;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto minmax(0, 1fr) minmax(0, 1fr);
  grid-template-areas: "c1 c2 dome c3 c4"; align-items: end; justify-items: center; column-gap: 6px; padding: 0 8px;
}
.capsule.is-tall .cpx-crown {
  grid-template-columns: repeat(4, minmax(0, 1fr)); grid-template-rows: auto auto; grid-template-areas: "c1 c2 c3 c4" "dome dome dome dome";
  align-content: end; row-gap: 6px; column-gap: 10px;
}
.cpx-jp[data-jp="common"] { grid-area: c1; }
.cpx-jp[data-jp="rare"] { grid-area: c2; }
.cpx-jp[data-jp="epic"] { grid-area: c3; }
.cpx-jp[data-jp="secret"] { grid-area: c4; }
/* 四块奖池牌(L05 / G04):空白牌是图,档名和金额用 CSS 叠在牌面上(多语言);金额跟注额变,碰到封顶写封顶后的数并亮「封顶」(G03) */
.cpx-jp { position: relative; width: var(--jp-w); height: var(--jp-h); align-self: center; container-type: inline-size; }
.capsule:not(.is-tall) .cpx-jp { margin-bottom: 4px; }
.cpx-jp-art { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .6)); }
.cpx-jp-in { position: absolute; left: -8%; right: -8%; top: 30%; bottom: 18%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; text-align: center; }
.cpx-jp-t { font: 850 10px/1.05 var(--sans); font-size: clamp(8px, 16cqw, 13px); color: #fff; letter-spacing: .02em; white-space: nowrap; text-shadow: 0 1px 2px #000, 0 0 6px rgba(0, 0, 0, .85); }
.cpx-jp-v {
  font: 900 11px/1 var(--round); font-size: min(17px, calc(112cqw / (var(--len, 6) * .6))); font-variant-numeric: tabular-nums; white-space: nowrap; color: #fff;
  text-shadow: 0 1px 0 #000, 0 0 8px rgba(0, 0, 0, .9);
}
.cpx-jp[data-jp="common"] .cpx-jp-t, .cpx-jp[data-jp="common"] .cpx-jp-v { color: #15161a; text-shadow: 0 1px 0 rgba(255, 255, 255, .7); }
.cpx-jp[data-jp="secret"] .cpx-jp-v { color: #ffe36a; text-shadow: 0 0 10px rgba(255, 210, 60, .8), 0 1px 0 #000; }
.cpx-jp-cap { font: 850 8px/1 var(--sans); font-size: clamp(7px, 12cqw, 10px); font-style: normal; color: var(--neon); text-shadow: 0 1px 2px #000; }
.cpx-jp[data-jp="common"] .cpx-jp-cap { color: #3d4a00; text-shadow: none; }

/* 玻璃球:站在图鉴展示条上面;按下 / 免费游戏每一转晃一下,悬念时一直晃(A02);倍数章挂在球的底座上(设计规格 2.1「倍数显示在玻璃球正下方」) */
.cpx-dome { grid-area: dome; position: relative; z-index: 3; height: var(--dome-h); aspect-ratio: 720 / 732; margin-bottom: -3px; }
.cpx-dome-art { display: block; width: 100%; height: 100%; object-fit: contain; transform-origin: 50% 92%; filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .6)); }
.cpx-dome.is-shake .cpx-dome-art { animation: cpx-jiggle .34s ease-in-out 2; }
.cpx-dome.is-tease .cpx-dome-art { animation: cpx-jiggle .2s ease-in-out infinite; filter: drop-shadow(0 0 16px rgba(229, 255, 61, .75)); }
/* 进免费游戏:玻璃球爆开一阵彩带那一下(彩带是粒子层喷的):鼓起来、闪白再落回去 */
.capsule .cpx-dome.is-burst .cpx-dome-art { animation: cpx-dome-burst .6s cubic-bezier(.2, 1.6, .4, 1); }
@keyframes cpx-dome-burst { 0% { transform: none; } 30% { transform: scale(1.18) translateY(-4%); filter: brightness(2) drop-shadow(0 0 30px #fff); } 100% { transform: none; } }
@keyframes cpx-jiggle {
  0%, 100% { transform: none; }
  25% { transform: rotate(-2.4deg) translateY(1px); }
  50% { transform: rotate(1.8deg) translateY(-1px); }
  75% { transform: rotate(-1deg); }
}
.cpx-ladder { position: absolute; left: 50%; bottom: 3%; z-index: 2; display: flex; gap: 3px; transform: translateX(-50%); }
.cpx-step {
  display: none; min-width: 28px; padding: 2px 6px; border-radius: 99px; text-align: center;
  font: 900 11px/1.25 var(--round); color: var(--ink-2); background: rgba(0, 0, 0, .78); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .2);
}
.cpx-step.is-on { display: block; color: var(--neon-ink); background: var(--neon); box-shadow: 0 0 10px rgba(229, 255, 61, .85); }
.capsule.is-tall .cpx-step { display: block; font-size: 12px; }
.cpx-step.is-pop { animation: cpx-badge .45s cubic-bezier(.2, 1.6, .4, 1); }
.cpx-ladder::after { content: ''; position: absolute; left: 50%; top: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px; border-radius: 50%; border: 2px solid var(--neon); opacity: 0; pointer-events: none; }
.cpx-ladder.is-burst::after { animation: cpx-ring .5s ease-out; }
@keyframes cpx-badge { 0% { transform: scale(.6); } 55% { transform: scale(1.45); } 100% { transform: none; } }
@keyframes cpx-ring { 0% { opacity: .95; transform: scale(.3); } 100% { opacity: 0; transform: scale(1.6); } }

/* 机身上段:cab-top 只露图鉴展示条那一段(y 43%–94%),铬圈切掉;机身比屏幕宽,左右被裁,窗口中心对着画面中心 */
.cpx-cab { position: relative; z-index: 2; flex: none; }
.cpx-topbox { position: relative; width: var(--fw); margin-left: calc(50% - var(--fw) * .49275); height: calc(var(--fw) * .17803); overflow: hidden; }
.cpx-top-art { position: absolute; left: 0; top: calc(var(--fw) * -.1501); width: 100%; height: auto; max-width: none; }
/* 图鉴展示条(R01):当前系列 5 格,收到的亮公仔、没收到的暗影 + 「?」;点一下开图鉴页 */
.cpx-album { position: absolute; left: 9.2%; width: 81.6%; top: 8.24%; height: 70.2%; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); grid-template-rows: minmax(0, 1fr); align-items: stretch; padding: 0 3.2% 1.5%; }
/* 格子撑满展示条的高度(stretch = 定高),公仔图才限得住在条里:以前 align-items:end 时格子没有定高,max-height 不生效,图照原尺寸往下溢出、被进度条和窗框切到 */
.cpx-slot { position: relative; min-height: 0; display: flex; align-items: flex-end; justify-content: center; }
.cpx-slot img { display: block; width: auto; height: auto; max-width: 86%; max-height: 96%; object-fit: contain; filter: brightness(0) saturate(0); opacity: .5; transition: filter .25s, opacity .25s; }
.cpx-slot.is-have img { filter: drop-shadow(0 0 5px rgba(255, 216, 74, .55)); opacity: 1; }
.cpx-q { position: absolute; inset: 0; display: grid; place-items: center; padding-bottom: 8%; font: 900 18px/1 var(--round); font-size: clamp(14px, 5cqw, 22px); color: rgba(255, 255, 255, .62); text-shadow: 0 0 8px rgba(0, 0, 0, .9); }
.cpx-slot.is-have .cpx-q { display: none; }
.cpx-slot.is-new img { animation: cpx-slot-in .65s cubic-bezier(.2, 1.5, .4, 1); }
.cpx-slot.is-new::after { content: ''; position: absolute; inset: 6% 8%; border-radius: 12px; box-shadow: 0 0 0 2px var(--neon), 0 0 18px rgba(229, 255, 61, .8); animation: cpx-fade-out .7s ease-out forwards; pointer-events: none; }
.cpx-album.is-full { animation: cpx-full .65s ease-out; }
@keyframes cpx-slot-in { 0% { transform: scale(.2) translateY(30%); opacity: 0; } 60% { transform: scale(1.25); opacity: 1; } 100% { transform: none; } }
@keyframes cpx-full { 0%, 100% { filter: none; } 40% { filter: brightness(1.7) drop-shadow(0 0 12px rgba(229, 255, 61, .9)); } }
.cpx-prog { position: absolute; left: 15.8%; width: 66.4%; top: 83%; height: 5.9%; border-radius: 99px; }
.cpx-prog-bar { position: absolute; left: 0; top: 0; bottom: 0; width: calc(var(--p, 0) * 100%); border-radius: inherit; background: linear-gradient(90deg, #ffe46b, var(--neon)); box-shadow: 0 0 8px rgba(229, 255, 61, .75); transition: width .45s cubic-bezier(.3, 1.3, .5, 1); }
.cpx-prog-n { position: absolute; right: -4px; top: 50%; transform: translate(100%, -50%); font: 850 10px/1 var(--round); font-size: clamp(9px, 2.8cqw, 12px); color: #fff; text-shadow: 0 1px 2px #000; font-variant-numeric: tabular-nums; }

/* 窗框 + 盘面:窗口内框左 13.95%、宽 70.66%、上下各 5.30%(实现规格 §1);格子宽 : 高约 0.82 */
.cpx-framebox { position: relative; width: var(--fw); margin-left: calc(50% - var(--fw) * .49275); aspect-ratio: 1080 / 831; }
.cpx-frame { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; }
.cpx-window, .cpx-over, .cpx-glow { position: absolute; left: 13.95%; width: 70.66%; top: 5.3%; height: 89.4%; }
.cpx-window { overflow: hidden; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); border-radius: 12px; transition: filter .2s; }
.cpx-over { pointer-events: none; z-index: 3; }
.cpx-glow { z-index: 2; border-radius: 14px; opacity: 0; pointer-events: none; box-shadow: 0 0 0 2px rgba(229, 255, 61, .9), 0 0 22px 6px rgba(229, 255, 61, .5), inset 0 0 26px rgba(229, 255, 61, .3); transition: opacity .2s; }
.cpx-framebox.is-tease .cpx-glow { opacity: 1; animation: cpx-glow .5s ease-in-out infinite alternate; }
.cpx-framebox.is-fail .cpx-window { animation: cpx-dim .55s ease-out; }
.cpx-window.is-blank { animation: cpx-dim .45s ease-out; }
@keyframes cpx-glow { from { opacity: .55; } to { opacity: 1; } }
@keyframes cpx-dim { 0% { filter: brightness(.45) saturate(.6); } 100% { filter: none; } }

.cpx-reel { position: relative; }
.cpx-reel + .cpx-reel { box-shadow: inset 1px 0 rgba(255, 255, 255, .045); }
.cpx-strip { position: absolute; inset: 0; }
.cpx-cell { position: absolute; left: 0; right: 0; top: calc(var(--r, 0) * 25%); height: 25%; display: grid; place-items: center; }
.cpx-cell img { display: block; width: auto; height: auto; max-width: 90%; max-height: 92%; object-fit: contain; filter: drop-shadow(0 3px 4px rgba(0, 0, 0, .55)); transition: filter .15s; }
/* 低价扭蛋小一号:小屏幕上一眼分得出高低价(L01) */
.cpx-cell[data-sym^="L"] img { max-width: 80%; max-height: 76%; }
.cpx-reel.is-wait { opacity: .45; }

/* 按下(T03):盘面上的扭蛋往下掉出去,每轴晚 30ms、下面那排先走 */
.cpx-reel.is-out .cpx-cell { animation: cpx-out var(--out, 260ms) cubic-bezier(.5, 0, 1, .6) calc(var(--i) * 30ms + (3 - var(--r, 0)) * 16ms) both; }
@keyframes cpx-out { to { transform: translateY(520%); opacity: .25; } }
/* 等回包:一串糊掉的扭蛋往下冲(J05:拉长变糊),一圈 --loop;悬念那几轴冲慢 */
.cpx-reel.is-spin .cpx-strip { animation: cpx-stream var(--loop, 420ms) linear infinite; filter: blur(1.4px); }
.cpx-reel.is-spin .cpx-cell img { transform: scaleY(1.2); opacity: .85; }
.cpx-reel.is-spin.is-tease .cpx-strip { animation-duration: var(--loop-slow, 1100ms); filter: blur(.8px); }
@keyframes cpx-stream { from { transform: translateY(0); } to { transform: translateY(var(--loop-to, 200%)); } }
.cpx-reel.is-tease { box-shadow: inset 0 0 0 2px rgba(229, 255, 61, .7), inset 0 0 20px rgba(229, 255, 61, .4); }
/* 一轴掉进来(T05):整条从几格之上往下掉,落定往下压 7%(高价那轴 9.5%,A05)再弹回 */
.cpx-reel.is-stop .cpx-strip { animation: cpx-stop var(--dur, 420ms) both; }
.cpx-reel.is-heavy { --over: 2.4%; }
@keyframes cpx-stop {
  0% { transform: translateY(var(--from)); animation-timing-function: cubic-bezier(.5, 0, 1, .55); }
  74% { transform: translateY(var(--over, 1.75%)); animation-timing-function: cubic-bezier(.2, .7, .3, 1); }
  88% { transform: translateY(-.5%); }
  100% { transform: none; }
}
.cpx-reel.is-land .cpx-cell img { animation: cpx-squash .22s ease-out; transform-origin: 50% 100%; }
.cpx-reel.is-land-heavy .cpx-cell img { animation: cpx-squash-heavy .28s ease-out; transform-origin: 50% 100%; }
@keyframes cpx-squash { 0% { transform: scale(1.05, .9); } 100% { transform: none; } }
@keyframes cpx-squash-heavy { 0% { transform: scale(1.1, .84); } 55% { transform: scale(.97, 1.04); } 100% { transform: none; } }
/* 扭蛋币 / 金扭蛋落下闪一下(A03) */
.cpx-cell::after { content: ''; position: absolute; inset: -12%; border-radius: 50%; pointer-events: none; opacity: 0; background: radial-gradient(circle, rgba(255, 246, 170, .95), rgba(255, 216, 74, .45) 38%, transparent 68%); }
.cpx-cell.is-flash::after { animation: cpx-flash .6s ease-out; }
.cpx-cell[data-sym="S"].is-flash img { animation: cpx-coin .6s ease-out; }
@keyframes cpx-flash { 0% { opacity: 0; transform: scale(.4); } 30% { opacity: 1; transform: scale(1.05); } 100% { opacity: 0; transform: scale(1.35); } }
@keyframes cpx-coin { 0% { filter: brightness(2) drop-shadow(0 0 14px #ffe86b); transform: scale(1.18); } 100% { filter: drop-shadow(0 3px 4px rgba(0, 0, 0, .55)); transform: none; } }
/* 彩虹收藏蛋闪彩虹光(开出来的公仔飞进图鉴,见特效层的 .cpx-flyfig) */
.cpx-cell.is-collect img { animation: cpx-collect .65s ease-out; }
@keyframes cpx-collect { 0% { filter: hue-rotate(0) brightness(1.9) drop-shadow(0 0 16px #ff8cf0); transform: scale(1.22); } 100% { filter: hue-rotate(360deg) drop-shadow(0 3px 4px rgba(0, 0, 0, .55)); transform: none; } }

/* 连锁每一步(J02 / W05):中奖格脉动发光、其他格压暗 */
.cpx-window.is-dim .cpx-cell:not(.is-win):not(.is-glow) img { filter: brightness(.3) saturate(.5); }
/* 进免费游戏 / 再加送那几颗扭蛋币:放大发光(其他格压暗) */
.cpx-cell.is-glow { z-index: 2; }
.cpx-cell.is-glow img { filter: drop-shadow(0 0 8px #fff3a0) drop-shadow(0 0 18px rgba(255, 216, 74, .9)); animation: cpx-glowpulse .5s ease-in-out infinite alternate; }
@keyframes cpx-glowpulse { from { transform: scale(1.04); } to { transform: scale(1.16); } }
.cpx-cell.is-win img { animation: cpx-pulse .46s ease-in-out infinite alternate; filter: drop-shadow(0 0 7px rgba(255, 236, 120, .95)) brightness(1.12); }
@keyframes cpx-pulse { from { transform: scale(1); } to { transform: scale(1.1); } }
/* 中奖扭蛋「打开」:上半截(复制的那张)往上翻走,下半截缩掉,中间闪一下 */
.cpx-cell.is-open img { clip-path: inset(46% 0 0 0); animation: cpx-open-b var(--od, 260ms) ease-in forwards; }
.cpx-lid { position: absolute; inset: 0; display: grid; place-items: center; animation: cpx-lid var(--od, 260ms) ease-out forwards; }
.cpx-cell.is-open .cpx-lid img { clip-path: inset(0 0 54% 0); animation: none; }
.cpx-cell::before { content: ''; position: absolute; inset: 8%; border-radius: 50%; pointer-events: none; opacity: 0; background: radial-gradient(circle, #fff, rgba(255, 255, 255, .5) 30%, transparent 64%); }
.cpx-cell.is-open::before { animation: cpx-burst var(--od, 260ms) ease-out; }
@keyframes cpx-open-b { 0% { transform: none; opacity: 1; } 40% { transform: scale(1.1); } 100% { transform: scale(.35) translateY(20%); opacity: 0; } }
@keyframes cpx-lid { 0% { transform: none; opacity: 1; } 100% { transform: translate(-14%, -62%) rotate(-42deg); opacity: 0; } }
@keyframes cpx-burst { 0% { opacity: 0; transform: scale(.3); } 35% { opacity: 1; } 100% { opacity: 0; transform: scale(1.7); } }
/* 剩下的往下掉、新的从上面补进来(照 fill),落到底轻轻弹一下 */
.cpx-cell.is-fall { animation: cpx-fall var(--fd, 240ms) both; }
@keyframes cpx-fall {
  0% { transform: translateY(calc(var(--fy, -1) * 100%)); animation-timing-function: cubic-bezier(.5, 0, 1, .55); }
  80% { transform: translateY(6%); animation-timing-function: ease-out; }
  100% { transform: none; }
}

/* ---------- 盘面上的字:提示、免费游戏那条、这一步赢多少、每一组的说明、L1 / L2 金额、免费游戏卡 ---------- */
.cpx-msg {
  position: absolute; left: 50%; top: 42%; max-width: 90%; transform: translate(-50%, -50%); padding: 9px 14px; border-radius: 14px;
  background: rgba(6, 6, 10, .9); box-shadow: inset 0 0 0 1px rgba(255, 216, 74, .5), 0 8px 20px rgba(0, 0, 0, .55);
  font: 750 13px/1.35 var(--sans); text-align: center; color: #fff;
}
.cpx-msg.is-flash { animation: cpx-fade-in .22s ease-out both; }
.cpx-banner {
  position: absolute; left: 50%; top: 5px; transform: translateX(-50%); display: flex; gap: 12px; padding: 5px 12px; border-radius: 99px; white-space: nowrap;
  background: linear-gradient(90deg, rgba(255, 60, 200, .9), rgba(120, 80, 255, .9), rgba(40, 200, 255, .9)); box-shadow: 0 0 14px rgba(255, 80, 220, .6);
  font: 750 11px/1.2 var(--sans);
}
.cpx-banner-g { display: inline-flex; align-items: baseline; gap: 5px; }
.cpx-banner b { font: 900 13px/1 var(--round); font-variant-numeric: tabular-nums; }
.cpx-banner.is-bump { animation: cpx-badge .4s ease-out; }
.cpx-pop {
  position: absolute; left: 50%; top: 44%; transform: translate(-50%, -50%); white-space: nowrap; font-variant-numeric: tabular-nums;
  font: 900 28px/1 var(--round); font-size: clamp(22px, 8cqw, 34px); color: var(--neon); text-shadow: 0 2px 0 #273000, 0 0 16px rgba(229, 255, 61, .75), 0 0 2px #000;
}
.cpx-pop.is-pop { animation: cpx-amt-in .32s cubic-bezier(.2, 1.5, .4, 1) both; }
.cpx-pop.is-fly { animation: cpx-amt-fly .44s cubic-bezier(.5, 0, .9, .4) forwards; }
.cpx-pop.is-quiet { font-size: 15px; color: var(--ink-2); text-shadow: 0 1px 2px #000; }
@keyframes cpx-amt-in { 0% { transform: translate(-50%, -50%) scale(.4); opacity: 0; } 100% { transform: translate(-50%, -50%); opacity: 1; } }
@keyframes cpx-amt-fly { 0% { transform: translate(-50%, -50%); opacity: 1; } 100% { transform: translate(calc(-50% + var(--tx, 0px)), calc(-50% + var(--ty, 140px))) scale(.4); opacity: 0; } }
.cpx-wins { position: absolute; left: 4px; right: 4px; bottom: 5px; display: flex; flex-wrap: wrap; justify-content: center; gap: 4px; }
.cpx-wc {
  display: inline-flex; align-items: center; gap: 4px; height: 32px; padding: 0 10px 0 4px; border-radius: 99px; white-space: nowrap;
  background: rgba(6, 6, 10, .92); box-shadow: inset 0 0 0 1px rgba(255, 216, 74, .6); font: 850 15px/1 var(--round); color: #fff; animation: cpx-fade-in .16s ease-out both;
}
.cpx-wc-sym { width: auto; height: 26px; }
.cpx-wc small { font: 650 12px/1 var(--sans); color: var(--ink-2); margin-right: 2px; }
.cpx-wc em { font-style: normal; color: var(--neon); font-variant-numeric: tabular-nums; }
.cpx-wc i { font-style: normal; font-size: 10px; padding: 1px 4px; border-radius: 99px; color: var(--neon-ink); background: var(--neon); }
.cpx-wc-more { padding: 0 8px; }
.cpx-wins.is-quiet .cpx-wc em { color: var(--ink-2); }
.cpx-celebrate, .cpx-freecard { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 4px; text-align: center; }
.cpx-celebrate { background: radial-gradient(ellipse at 50% 50%, rgba(0, 0, 0, .74), rgba(0, 0, 0, .3) 64%, transparent); }
.cpx-celebrate small { font: 800 12px/1 var(--sans); letter-spacing: .1em; color: var(--ink-2); }
.cpx-celebrate b { font: 900 38px/1 var(--round); font-size: clamp(30px, 11cqw, 46px); color: var(--neon); font-variant-numeric: tabular-nums; text-shadow: 0 3px 0 #273000, 0 0 22px rgba(229, 255, 61, .8); }
.cpx-celebrate[data-level="l2"] b { font-size: clamp(34px, 12.5cqw, 52px); color: #ffe36a; text-shadow: 0 3px 0 #5a3800, 0 0 26px rgba(255, 210, 60, .9); }
.cpx-celebrate.is-done b { animation: cpx-badge .35s ease-out; }
.cpx-freecard { background: radial-gradient(ellipse at 50% 50%, rgba(40, 0, 60, .86), rgba(0, 0, 0, .55) 70%, transparent); }
.cpx-freecard-title {
  font: 900 32px/1.05 var(--round); font-size: clamp(26px, 9cqw, 40px); letter-spacing: .04em;
  background: linear-gradient(90deg, #ff6bd6, #ffe36a, #6bf0ff, #b48cff); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 3px 0 #2b0040) drop-shadow(0 0 14px rgba(255, 120, 230, .7));
}
.cpx-freecard small { font: 750 13px/1.2 var(--sans); color: #fff; }
.cpx-freecard small:empty { display: none; }
.cpx-freecard-n { font: 900 32px/1 var(--round); font-size: clamp(26px, 9cqw, 38px); color: var(--neon); font-variant-numeric: tabular-nums; text-shadow: 0 0 16px rgba(229, 255, 61, .8); }
.cpx-freecard-n:empty { display: none; }
/* 扭蛋狂欢进场大标题:从上面落下来、过冲回弹,底下「获得 10 次免费游戏」;总结卡:金额滚完弹一下 */
.cpx-freecard[data-kind="intro"] { background: radial-gradient(ellipse at 50% 50%, rgba(60, 0, 80, .78), rgba(0, 0, 0, .35) 70%, transparent); }
.cpx-freecard[data-kind="intro"] .cpx-freecard-title { font-size: 40px; font-size: clamp(32px, 12cqw, 54px); }
.cpx-freecard[data-kind="intro"].is-in .cpx-freecard-title { animation: cpx-title-drop .7s cubic-bezier(.2, 1.5, .4, 1) both; }
.cpx-freecard[data-kind="intro"] small { padding: 4px 12px; border-radius: 99px; font-size: 14px; background: rgba(6, 6, 10, .8); box-shadow: inset 0 0 0 1px rgba(255, 107, 214, .6); }
.cpx-freecard.is-done .cpx-freecard-n { animation: cpx-badge .4s ease-out; }
@keyframes cpx-title-drop { 0% { transform: translateY(-120%) scale(1.3); opacity: 0; } 55% { transform: translateY(6%) scale(.96); opacity: 1; } 100% { transform: none; opacity: 1; } }
.cpx-plus { position: absolute; right: 8%; top: 12%; display: grid; justify-items: center; gap: 2px; text-align: center; color: var(--neon); }
.cpx-plus b { font: 900 30px/1 var(--round); text-shadow: 0 0 14px rgba(229, 255, 61, .85), 0 2px 0 #273000; }
.cpx-plus small { padding: 2px 8px; border-radius: 99px; font: 800 10px/1.2 var(--sans); color: #fff; background: rgba(6, 6, 10, .85); white-space: nowrap; }
.cpx-plus.is-pop { animation: cpx-plus .9s ease-out forwards; }
@keyframes cpx-plus { 0% { transform: scale(.3); opacity: 0; } 25% { transform: scale(1.3); opacity: 1; } 100% { transform: translateY(-40px); opacity: 0; } }
:is(.cpx-celebrate, .cpx-freecard).is-in { animation: cpx-fade-in .22s ease-out both; }
:is(.cpx-celebrate, .cpx-freecard).is-out { animation: cpx-fade-out .24s ease-in forwards; }
@keyframes cpx-fade-in { from { opacity: 0; transform: scale(.94); } to { opacity: 1; transform: none; } }
@keyframes cpx-fade-out { to { opacity: 0; } }

/* ---------- 操作台:CSS 做的同风格底座(黑铬 + 黄霓虹边),往上压住窗框下缘;按钮都 ≥ 44px(L03) ---------- */
.cpx-console {
  position: relative; z-index: 5; flex: none; height: calc(86px + var(--safe-b, 0px)); margin-top: -8px; margin-bottom: calc(-1 * var(--safe-b, 0px));
  padding: 4px 8px var(--safe-b, 0px); display: grid; grid-template-columns: minmax(0, 1fr) 74px minmax(0, 1fr) 34px; grid-template-rows: 34px 44px; gap: 4px 6px;
  border-radius: 22px 22px 0 0;
  background: linear-gradient(180deg, #34343a 0%, #101013 9%, #050506 55%, #141417 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .38), inset 0 0 0 1.5px rgba(255, 216, 74, .6), inset 0 6px 14px rgba(255, 216, 74, .08), 0 -8px 22px rgba(0, 0, 0, .6);
}
.cpx-plate {
  min-width: 0; display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 1px; padding: 2px 8px; border-radius: 12px;
  background: linear-gradient(#0a0a0c, #000); box-shadow: inset 0 0 0 1.5px rgba(255, 216, 74, .9), 0 0 9px rgba(255, 216, 74, .42), inset 0 0 8px rgba(255, 216, 74, .2);
}
.cpx-plate small { font: 700 9.5px/1.1 var(--sans); color: var(--ink-2); white-space: nowrap; }
.cpx-plate b { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 850 14px/1.1 var(--round); font-size: clamp(12px, 4cqw, 16px); font-variant-numeric: tabular-nums; }
.cpx-plate b.is-loss { color: var(--bad); }
.cpx-plate-win { grid-column: 1; grid-row: 1; }
/* 注额牌是按钮(点开快捷注额),但操作台第一行只有 34px:点击区往上借 6px、往下借满 4px 的行距 = 44px(L03),不压到第二行的 − / + */
.cpx-plate-bet { position: relative; grid-column: 3; grid-row: 1; }
.cpx-plate-bet::before { content: ''; position: absolute; left: 0; right: 0; top: -6px; bottom: -4px; }
.cpx-plate-bet:disabled { opacity: .55; }
.cpx-pair { display: flex; justify-content: space-between; align-items: center; gap: 6px; min-width: 0; }
.cpx-pair-l { grid-column: 1; grid-row: 2; }
.cpx-pair-r { grid-column: 3; grid-row: 2; }
.cpx-rnd { position: relative; flex: none; width: 44px; height: 44px; display: grid; place-items: center; }
.cpx-rnd > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.cpx-rnd-i { position: relative; display: grid; width: 20px; height: 20px; color: var(--pearl); }
.cpx-rnd-i svg { width: 100%; height: 100%; }
.cpx-rnd.is-on .cpx-rnd-i { color: var(--neon); filter: drop-shadow(0 0 5px rgba(229, 255, 61, .9)); }
.cpx-rnd:disabled { opacity: .4; }
/* 转动键最大、放下方中间(L03);转的时候图标换成「停」(点一下一起落 / 跳过),自动转着写剩几局 */
.cpx-spin { position: relative; grid-column: 2; grid-row: 1 / span 2; align-self: center; justify-self: center; width: 74px; height: 80px; display: grid; place-items: center; }
.cpx-spin > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 0 10px rgba(255, 216, 74, .55)); }
.cpx-spin-i { position: relative; display: grid; width: 30px; height: 30px; color: var(--neon); filter: drop-shadow(0 0 6px rgba(229, 255, 61, .85)); }
.cpx-spin-i svg { width: 100%; height: 100%; }
.cpx-spin.is-rolling .cpx-spin-i { width: 24px; height: 24px; }
.cpx-spin-n { position: relative; font: 900 22px/1 var(--round); color: var(--neon); text-shadow: 0 0 8px rgba(229, 255, 61, .8); }
.cpx-spin.is-press { animation: cpx-press .28s ease-out; }
.cpx-spin:disabled { filter: grayscale(.7) brightness(.6); }
@keyframes cpx-press { 0% { transform: scale(.88); } 60% { transform: scale(1.06); } 100% { transform: none; } }
/* 摇杆(P8):站在操作台最右边,上半截伸到窗框下缘;往下拉跟着压短,拉到底弹回 */
.cpx-crank { position: relative; grid-column: 4; grid-row: 1 / span 2; width: calc(100% + 10px); margin-right: -10px; height: 100%; touch-action: none; } /* 往下拖要交给页面,别让浏览器拿去卷动 */
.cpx-crank-art { position: absolute; right: 4px; bottom: 0; width: auto; height: 108px; max-width: none; transform-origin: 50% 100%; transform: scaleY(calc(1 - var(--pull, 0) * .28)); transition: transform .08s; filter: drop-shadow(-2px 4px 6px rgba(0, 0, 0, .6)); }
.cpx-crank.is-pull .cpx-crank-art { animation: cpx-pull .42s cubic-bezier(.3, 1.4, .5, 1); }
.cpx-crank:disabled { opacity: .5; }
@keyframes cpx-pull { 0% { transform: scaleY(1); } 35% { transform: scaleY(.7); } 100% { transform: scaleY(1); } }
/* 快捷注额 / 自动转的小选单:浮在操作台上面 */
.cpx-pop-menu {
  position: absolute; left: 8px; right: 8px; bottom: calc(100% + 8px); z-index: 7; display: grid; gap: 8px; padding: 10px; border-radius: 16px;
  background: rgba(8, 8, 12, .95); box-shadow: inset 0 0 0 1px rgba(255, 216, 74, .45), 0 10px 30px rgba(0, 0, 0, .7);
}
.cpx-menu-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.cpx-menu-row small { flex: 1 0 100%; font: 700 11px/1.2 var(--sans); color: var(--ink-2); }
.cpx-chip { min-height: 44px; min-width: 52px; padding: 0 12px; border-radius: 12px; background: #16161b; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14); font: 800 14px/1.1 var(--round); }
.cpx-chip.is-on { background: var(--neon); color: var(--neon-ink); box-shadow: none; }
.cpx-toggle { font: 750 13px/1.2 var(--sans); }
.cpx-go { background: rgba(229, 255, 61, .12); box-shadow: inset 0 0 0 1.5px var(--neon); color: var(--neon); }

/* ---------- 特效层:盖住整页(顶栏、按钮都在下面) ----------
 * 由下往上:挑扭蛋那一层 / 图鉴页(从顶栏下面开始,顶栏的返回、喇叭、说明照样按得到)→ 飞进图鉴的公仔 → 大奖那一层(连顶栏一起盖)→
 * 粒子 canvas(capsule-fx.js,飞在标题、桌面前面)。平常整层点不到;大奖、挑扭蛋、图鉴页出来时那一块点得到 */
.cpx-layer { position: absolute; inset: 0; z-index: 8; pointer-events: none; }
.cpx-layer.is-on { pointer-events: auto; }
.cpx-fx-canvas { position: absolute; inset: 0; z-index: 6; width: 100%; height: 100%; pointer-events: none; }
.cpx-hint { font: 650 12px/1 var(--sans); color: var(--ink-2); opacity: 0; transition: opacity .3s .2s; }
:is(.cpx-tier, .cpx-jw).is-done .cpx-hint { opacity: .8; }
@keyframes cpx-amt-rise { from { transform: translate3d(0, 30px, 0) scale(.6); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes cpx-amt-land { 0% { transform: scale(1); } 35% { transform: scale(1.18); } 100% { transform: scale(1); } }

/* 收藏蛋开出来的公仔:从扭蛋里弹出来放大,再画弧线缩进图鉴展示条那一格(位置、大小由 capsule.js 量好写进变量) */
.cpx-flyers { position: absolute; inset: 0; z-index: 3; pointer-events: none; overflow: hidden; }
.cpx-flyfig { position: absolute; left: 0; top: 0; width: var(--w); height: var(--h); display: grid; place-items: center; transform: translate(var(--x0), var(--y0)); animation: cpx-flyfig var(--d, 640ms) cubic-bezier(.4, 0, .2, 1) forwards; will-change: transform; }
.cpx-flyfig img { width: auto; height: auto; max-width: 100%; max-height: 100%; filter: drop-shadow(0 0 10px rgba(255, 140, 240, .9)) drop-shadow(0 4px 6px rgba(0, 0, 0, .6)); }
@keyframes cpx-flyfig {
  0% { transform: translate(var(--x0), var(--y0)) scale(.3); opacity: 0; }
  22% { transform: translate(var(--x0), calc(var(--y0) - 26px)) scale(1.3); opacity: 1; }
  40% { transform: translate(var(--x0), calc(var(--y0) - 34px)) scale(1.24); }
  100% { transform: translate(var(--x1), var(--y1)) scale(var(--s1, .6)); opacity: 1; }
}

/* 两层反向旋转的光束 + 进场闪白(大奖、挑扭蛋开奖共用;颜色看外层的 data-level / data-tier) */
.cpx-beam {
  position: absolute; left: 50%; top: 42%; width: 170vmax; aspect-ratio: 1; border-radius: 50%; transform: translate(-50%, -50%); pointer-events: none;
  background: repeating-conic-gradient(from 0deg, rgba(229, 255, 61, .22) 0deg 7deg, rgba(229, 255, 61, 0) 7deg 20deg);
  -webkit-mask-image: radial-gradient(circle, #000 0, rgba(0, 0, 0, .6) 30%, rgba(0, 0, 0, 0) 62%); mask-image: radial-gradient(circle, #000 0, rgba(0, 0, 0, .6) 30%, rgba(0, 0, 0, 0) 62%);
  animation: cpx-beam 14s linear infinite;
}
.cpx-beam-2 { background: repeating-conic-gradient(from 10deg, rgba(255, 255, 255, .14) 0deg 3deg, rgba(255, 255, 255, 0) 3deg 15deg); animation: cpx-beam-rev 22s linear infinite; }
@keyframes cpx-beam { to { transform: translate(-50%, -50%) rotate(360deg); } }
@keyframes cpx-beam-rev { to { transform: translate(-50%, -50%) rotate(-360deg); } }
.cpx-flash { position: absolute; left: 50%; top: 42%; width: 140vmax; aspect-ratio: 1; border-radius: 50%; transform: translate(-50%, -50%) scale(.2); opacity: 0; pointer-events: none; background: radial-gradient(circle, rgba(255, 255, 250, .95) 0, rgba(255, 246, 170, .55) 16%, rgba(255, 216, 74, 0) 44%); }
:is(.cpx-tier, .cpx-jw).is-in .cpx-flash { animation: cpx-flash-in .75s ease-out both; }
.cpx-tier.is-boost .cpx-flash, .cpx-jw.is-crack .cpx-flash { animation: cpx-flash-boost .7s ease-out both; }
@keyframes cpx-flash-in { 0% { opacity: 0; transform: translate(-50%, -50%) scale(.2); } 18% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -50%) scale(1.25); } }
@keyframes cpx-flash-boost { 0% { opacity: 0; transform: translate(-50%, -50%) scale(.2); } 18% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -50%) scale(1.25); } }

/* ---------- 大奖(W01 L3–L6):全屏暗角 + 光束 + 标题图从远处飞到镜头前,金额在下面滚;一档一档颜色不同 ---------- */
.cpx-tier {
  position: absolute; inset: 0; z-index: 4; display: flex; align-items: center; justify-content: center; overflow: hidden; pointer-events: auto; perspective: 900px;
  background: radial-gradient(ellipse 75% 60% at 50% 42%, rgba(70, 72, 0, .5), rgba(8, 8, 2, .86) 62%, rgba(0, 0, 0, .95) 100%);
}
.cpx-tier[data-level="mega"] { background: radial-gradient(ellipse 75% 60% at 50% 42%, rgba(120, 10, 96, .55), rgba(16, 2, 14, .87) 62%, rgba(0, 0, 0, .95) 100%); }
.cpx-tier[data-level="mega"] .cpx-beam { background: repeating-conic-gradient(from 0deg, rgba(255, 107, 214, .24) 0deg 7deg, rgba(255, 107, 214, 0) 7deg 20deg); animation-duration: 10s; }
.cpx-tier[data-level="super"], .cpx-tier[data-level="legend"] { background: radial-gradient(ellipse 80% 64% at 50% 42%, rgba(80, 30, 150, .58), rgba(10, 4, 22, .87) 60%, rgba(0, 0, 0, .96) 100%); }
.cpx-tier[data-level="legend"] { background: radial-gradient(ellipse 80% 64% at 50% 42%, rgba(150, 110, 0, .62), rgba(26, 14, 0, .88) 60%, rgba(0, 0, 0, .96) 100%); }
.cpx-tier:is([data-level="super"], [data-level="legend"]) .cpx-beam {
  background: repeating-conic-gradient(from 0deg, rgba(255, 79, 139, .28) 0deg 6deg, rgba(0, 0, 0, 0) 6deg 12deg, rgba(63, 180, 255, .28) 12deg 18deg, rgba(0, 0, 0, 0) 18deg 24deg, rgba(229, 255, 61, .28) 24deg 30deg, rgba(0, 0, 0, 0) 30deg 36deg);
  animation-duration: 7s;
}
.cpx-tier:is([data-level="super"], [data-level="legend"]) .cpx-beam-2 { animation-duration: 12s; }
.cpx-tier[hidden] { display: none; }
.cpx-tier.is-in { animation: cpx-fade-in .3s ease-out both; }
.cpx-tier.is-out { animation: cpx-fade-out .24s ease-in forwards; }
.cpx-tier-main { position: relative; z-index: 2; width: 100%; display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 0 16px; transform-style: preserve-3d; }
/* 标题:从很远(translateZ -1600px、很小、糊)飞到镜头前(+260px,过头)、弹回、带一点 3D 倾斜;落定后自己轻轻摆。升一级(is-up)再弹一下 */
.cpx-tier-fly { position: relative; width: 100%; display: flex; justify-content: center; transform-style: preserve-3d; }
.cpx-tier.is-in .cpx-tier-fly { animation: cpx-tier-fly .95s cubic-bezier(.18, .9, .28, 1) both; }
.cpx-tier.is-in .cpx-tier-fly.is-up { animation: cpx-tier-up .5s cubic-bezier(.2, 1.6, .4, 1) both; }
@keyframes cpx-tier-fly {
  0% { transform: translate3d(0, 8%, -1600px) rotateX(38deg) rotateY(-18deg); opacity: 0; filter: blur(8px); }
  14% { opacity: 1; }
  58% { transform: translate3d(0, -3%, 260px) rotateX(-10deg) rotateY(8deg); filter: blur(0); }
  78% { transform: translate3d(0, 0, -50px) rotateX(4deg) rotateY(-3deg); }
  100% { transform: none; opacity: 1; filter: none; }
}
@keyframes cpx-tier-up { 0% { transform: none; } 35% { transform: scale(1.22) translateZ(80px); filter: brightness(1.6); } 100% { transform: none; filter: none; } }
.cpx-tier-art { display: block; width: min(86%, 440px); height: auto; filter: drop-shadow(0 12px 30px rgba(0, 0, 0, .7)) drop-shadow(0 0 24px rgba(229, 255, 61, .35)); }
.cpx-tier.is-in .cpx-tier-art { animation: cpx-sway 3.4s ease-in-out .95s infinite alternate; }
@keyframes cpx-sway { from { transform: perspective(800px) rotateY(-7deg) rotateX(3deg); } to { transform: perspective(800px) rotateY(7deg) rotateX(-2deg); } }
/* LEGEND:SUPER 那张图下面压一条彩虹金字「传奇大奖」(多语言) */
.cpx-tier-legend {
  position: absolute; left: 50%; bottom: -4%; transform: translateX(-50%) rotate(-4deg); padding: 5px 18px; border-radius: 99px; white-space: nowrap;
  font: 900 22px/1.1 var(--round); font-size: clamp(18px, 6.5cqw, 30px); color: #1a1000; letter-spacing: .04em;
  background: linear-gradient(90deg, #ff6bd6, #ffe36a, #6bf0ff, #b48cff); box-shadow: 0 0 24px rgba(255, 255, 255, .6), 0 4px 0 #3b2400;
}
.cpx-tier-legend[hidden] { display: none; }
.cpx-tier.is-in .cpx-tier-legend { animation: cpx-plate-pop .7s cubic-bezier(.2, 1.5, .4, 1) .3s both; }
/* 档名小字(标题图上是英文,这一行是玩家的语言) */
.cpx-tier-title { font: 800 13px/1.2 var(--sans); letter-spacing: .16em; color: rgba(255, 255, 255, .78); text-shadow: 0 1px 2px #000; }
.cpx-tier-amt { position: relative; font: 900 40px/1.05 var(--round); font-size: clamp(32px, 11cqw, 56px); color: #fff36b; font-variant-numeric: tabular-nums; white-space: nowrap; text-shadow: 0 0 22px rgba(229, 255, 61, .6); }
@supports ((-webkit-background-clip: text) or (background-clip: text)) {
  .cpx-tier-amt { background: linear-gradient(180deg, #ffffff 0%, #f6ff9c 36%, #e5ff3d 60%, #ffd84a 100%); -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; filter: drop-shadow(0 0 10px rgba(229, 255, 61, .55)) drop-shadow(0 3px 0 rgba(40, 40, 0, .9)); }
}
.cpx-tier.is-in .cpx-tier-amt { animation: cpx-amt-rise .5s cubic-bezier(.3, 1.4, .5, 1) .45s both; }
.cpx-tier.is-done .cpx-tier-amt { animation: cpx-amt-land .55s cubic-bezier(.3, 1.6, .5, 1) both; }

/* ---------- 挑扭蛋那一层 / 图鉴页:顶栏下面整块,桌面 / 图鉴柜照原图比例放在正中(点击区的百分比坐标才对得上) ---------- */
.cpx-bonus, .cpx-albumpage {
  position: absolute; left: 0; right: 0; top: calc(var(--safe-t, 0px) + 46px); bottom: 0; z-index: 1; display: grid; place-items: center; overflow: hidden; pointer-events: auto;
  background: radial-gradient(ellipse at 50% 30%, rgba(34, 32, 12, .94), rgba(0, 0, 0, .98) 70%); container-type: size;
}
:is(.cpx-bonus, .cpx-albumpage)[hidden] { display: none; }
:is(.cpx-bonus, .cpx-albumpage).is-in { animation: cpx-fade-in .3s ease-out both; }
.cpx-bn-board, .cpx-ab-board { position: relative; width: 100%; }
.cpx-bn-board { max-width: calc((100vh - 46px) * .5654); aspect-ratio: 1080 / 1910; }
.cpx-ab-board { max-width: calc((100vh - 46px) * .5596); aspect-ratio: 1080 / 1930; }
@supports (width: 1cqh) {
  .cpx-bn-board { width: min(100cqw, 100cqh * .5654); max-width: none; }
  .cpx-ab-board { width: min(100cqw, 100cqh * .5596); max-width: none; }
}
.cpx-bn-bg, .cpx-ab-bg { position: absolute; inset: 0; width: 100%; height: 100%; }
/* 四档颜色:普通款银白、稀有款蓝、史诗款紫、隐藏款金(G07) */
[data-bn-jp="common"], .cpx-ball[data-tier="common"] { --tc: #eef1f7; }
[data-bn-jp="rare"], .cpx-ball[data-tier="rare"] { --tc: #3fb4ff; }
[data-bn-jp="epic"], .cpx-ball[data-tier="epic"] { --tc: #b56bff; }
[data-bn-jp="secret"], .cpx-ball[data-tier="secret"] { --tc: #ffd84a; }
/* 顶上 0–22% 那块空位:四块奖池牌(按奖励局注额),每块下面三颗灯 = 这一档收到几颗;差一颗满的那块跳着,开完赢的那块亮、其余暗 */
.cpx-bn-jps { position: absolute; left: 4%; right: 4%; top: 2.2%; height: 18%; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 2%; }
.cpx-bn-jp { display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 4%; min-width: 0; transition: opacity .3s; }
.cpx-bn-plq { position: relative; width: 80%; aspect-ratio: 2 / 3; container-type: inline-size; transition: transform .3s, filter .3s; }
.cpx-bn-jp[data-bn-jp="common"] :is(.cpx-jp-t, .cpx-jp-v) { color: #15161a; text-shadow: 0 1px 0 rgba(255, 255, 255, .7); }
.cpx-bn-jp[data-bn-jp="common"] .cpx-jp-cap { color: #3d4a00; text-shadow: none; }
.cpx-bn-jp[data-bn-jp="secret"] .cpx-jp-v { color: #ffe36a; text-shadow: 0 0 10px rgba(255, 210, 60, .8), 0 1px 0 #000; }
.cpx-bn-pips { display: flex; gap: 5px; }
.cpx-bn-pips > i { width: 9px; height: 9px; border-radius: 50%; background: rgba(255, 255, 255, .14); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .32); transition: background .2s, box-shadow .2s; }
.cpx-bn-pips > i.is-on { background: var(--tc); box-shadow: 0 0 8px var(--tc), inset 0 0 0 1px rgba(255, 255, 255, .6); }
.cpx-bn-jp.is-near .cpx-bn-plq { animation: cpx-near .6s ease-in-out infinite alternate; }
.cpx-bn-jp.is-win .cpx-bn-plq { transform: scale(1.12); filter: drop-shadow(0 0 14px var(--tc)); }
.cpx-bn-jp.is-lose { opacity: .4; }
@keyframes cpx-near { from { transform: scale(1); filter: drop-shadow(0 0 2px var(--tc)); } to { transform: scale(1.07); filter: drop-shadow(0 0 12px var(--tc)); } }
.cpx-bn-hint { position: absolute; left: 7%; right: 7%; top: 21.6%; text-align: center; font: 750 12px/1.35 var(--sans); color: #fff; text-shadow: 0 1px 3px #000, 0 0 8px #000; }
.cpx-bn-hint[hidden] { display: none; }
/* 12 颗的点击区(扭蛋画在桌面图上):按下去一圈柠檬光;问服务器的时候那一圈一直闪;开出来:里面压暗、那一档的小牌跳出来(带那一档的颜色) */
.cpx-ball { position: absolute; left: var(--x); top: var(--y); width: 18%; height: 10.5%; transform: translate(-50%, -50%); border-radius: 50%; }
.cpx-ball::before { content: ''; position: absolute; inset: 0 8%; border-radius: 50%; pointer-events: none; box-shadow: 0 0 0 0 rgba(229, 255, 61, 0); transition: box-shadow .15s; }
.cpx-ball:not(:disabled):active::before { box-shadow: 0 0 0 3px rgba(229, 255, 61, .9), 0 0 18px rgba(229, 255, 61, .6); }
.cpx-ball.is-asking::before { animation: cpx-ask .42s ease-in-out infinite alternate; }
@keyframes cpx-ask { from { box-shadow: 0 0 0 2px rgba(229, 255, 61, .5), 0 0 8px rgba(229, 255, 61, .3); transform: scale(1); } to { box-shadow: 0 0 0 4px rgba(229, 255, 61, 1), 0 0 22px rgba(229, 255, 61, .8); transform: scale(1.06); } }
.cpx-ball::after { content: ''; position: absolute; inset: -4% 6% 6%; border-radius: 50%; pointer-events: none; opacity: 0; background: radial-gradient(circle at 50% 45%, rgba(14, 14, 18, .94) 0 52%, rgba(0, 0, 0, 0) 72%); }
.cpx-ball:is(.is-open, .is-rest)::after { opacity: 1; }
.cpx-ball.is-pop::after { animation: cpx-ball-burst .45s ease-out both; }
@keyframes cpx-ball-burst { 0% { opacity: 1; box-shadow: 0 0 0 0 var(--tc), 0 0 40px 10px #fff; } 100% { opacity: 1; box-shadow: 0 0 0 10px rgba(0, 0, 0, 0), 0 0 0 0 rgba(255, 255, 255, 0); } }
.cpx-ball-in { position: absolute; inset: -14% -4% 0; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; }
.cpx-ball-plaque { display: block; width: auto; height: 76%; filter: drop-shadow(0 0 8px var(--tc)); }
.cpx-ball-t { font: 850 10px/1.1 var(--sans); color: #fff; white-space: nowrap; text-shadow: 0 1px 2px #000, 0 0 6px #000; }
.cpx-ball.is-pop .cpx-ball-in { animation: cpx-ball-pop .5s cubic-bezier(.2, 1.6, .4, 1) both; }
@keyframes cpx-ball-pop { 0% { transform: scale(.2) translateY(30%); opacity: 0; } 60% { transform: scale(1.18); opacity: 1; } 100% { transform: none; opacity: 1; } }
.cpx-ball.is-win .cpx-ball-plaque { animation: cpx-glowpulse .55s ease-in-out infinite alternate; }
/* 开完:其余没开的一颗一颗翻过来,变暗显示里面原本是什么 */
.cpx-ball.is-rest .cpx-ball-in { opacity: .42; filter: grayscale(.35); }
.cpx-ball.is-reveal .cpx-ball-in { animation: cpx-reveal .45s ease-out var(--d, 0ms) both; }
@keyframes cpx-reveal { 0% { transform: rotateY(90deg); opacity: 0; } 100% { transform: none; opacity: .42; } }
/* 桌子前缘那条(88% 以下):自动开 / 回到扭蛋机 */
.cpx-bn-bar { position: absolute; left: 0; right: 0; top: 88%; display: flex; justify-content: center; gap: 10px; }
.cpx-bn-btn {
  min-height: 44px; padding: 0 20px; border-radius: 99px; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
  background: linear-gradient(#17171c, #050506); box-shadow: inset 0 0 0 1.5px rgba(255, 216, 74, .9), 0 0 12px rgba(255, 216, 74, .4); font: 850 14px/1 var(--round); color: #fff;
}
.cpx-bn-btn[hidden] { display: none; }
.cpx-bn-btn svg { width: 18px; height: 18px; }
.cpx-bn-btn.is-on, .cpx-bn-done { background: var(--neon); color: var(--neon-ink); box-shadow: 0 0 14px rgba(229, 255, 61, .7); }
.cpx-bn-intro {
  position: absolute; left: 6%; right: 6%; top: 50%; transform: translateY(-50%); padding: 14px 12px; border-radius: 18px; text-align: center; pointer-events: none;
  background: rgba(6, 6, 10, .9); box-shadow: inset 0 0 0 1.5px var(--neon), 0 0 30px rgba(229, 255, 61, .4); font: 900 20px/1.25 var(--round); color: var(--neon);
}
.cpx-bn-intro[hidden] { display: none; }
.cpx-bn-intro.is-in { animation: cpx-title-drop .6s cubic-bezier(.2, 1.5, .4, 1) both; }

/* 挑扭蛋开奖(G07):四档共用,颜色照 data-tier 换(银白 / 蓝 / 紫 / 金);普通三档是放大的空白牌 + 档名,隐藏款是巨大金扭蛋裂开 + 底板「隐藏款」 */
.cpx-jw {
  position: absolute; inset: 0; z-index: 3; display: flex; align-items: center; justify-content: center; overflow: hidden; pointer-events: auto; perspective: 900px;
  --jw-glow: rgba(200, 205, 215, .32); --jw-c1: #ffffff; --jw-c2: #c9ced8; --jw-c3: #7d8696;
  background: radial-gradient(ellipse 75% 60% at 50% 42%, var(--jw-glow), rgba(0, 0, 0, .93) 66%);
}
.cpx-jw[data-tier="rare"] { --jw-glow: rgba(40, 140, 255, .45); --jw-c1: #e6f6ff; --jw-c2: #3fb4ff; --jw-c3: #1f4bd0; }
.cpx-jw[data-tier="epic"] { --jw-glow: rgba(150, 70, 255, .5); --jw-c1: #f3e6ff; --jw-c2: #b56bff; --jw-c3: #6a1fd0; }
.cpx-jw[data-tier="secret"] { --jw-glow: rgba(255, 200, 40, .55); --jw-c1: #fffbe0; --jw-c2: #ffd84a; --jw-c3: #f5a300; }
.cpx-jw[hidden] { display: none; }
.cpx-jw.is-in { animation: cpx-fade-in .3s ease-out both; }
.cpx-jw.is-out { animation: cpx-fade-out .24s ease-in forwards; }
.cpx-jw .cpx-beam { background: repeating-conic-gradient(from 0deg, var(--jw-c2) 0deg 6deg, rgba(0, 0, 0, 0) 6deg 18deg); opacity: .24; }
.cpx-jw .cpx-beam-2 { background: repeating-conic-gradient(from 8deg, var(--jw-c1) 0deg 3deg, rgba(0, 0, 0, 0) 3deg 15deg); opacity: .14; }
.cpx-jw-main { position: relative; z-index: 2; width: 100%; display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 0 16px; transform-style: preserve-3d; }
.cpx-jw-badge { position: relative; display: flex; flex-direction: column; align-items: center; }
.cpx-jw-plaque { display: block; width: auto; height: 150px; filter: drop-shadow(0 0 26px var(--jw-c2)); }
.cpx-jw.is-in .cpx-jw-badge { animation: cpx-tier-fly .9s cubic-bezier(.18, .9, .28, 1) both; }
.cpx-jw-name {
  margin-top: -4px; font: 900 36px/1.05 var(--round); font-size: clamp(30px, 11cqw, 48px); letter-spacing: .04em; color: var(--jw-c1);
  background: linear-gradient(var(--jw-c1), var(--jw-c2) 55%, var(--jw-c3)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 3px 0 rgba(0, 0, 0, .65)) drop-shadow(0 0 16px var(--jw-c2));
}
.cpx-jw-sub { font: 800 12px/1 var(--sans); letter-spacing: .24em; color: var(--jw-c1); opacity: .85; }
.cpx-jw-amt { font: 900 40px/1.05 var(--round); font-size: clamp(32px, 11cqw, 54px); color: #fff; font-variant-numeric: tabular-nums; white-space: nowrap; text-shadow: 0 0 18px var(--jw-c2), 0 3px 0 #000; }
.cpx-jw.is-in .cpx-jw-amt { animation: cpx-amt-rise .5s cubic-bezier(.3, 1.4, .5, 1) .4s both; }
.cpx-jw.is-done .cpx-jw-amt { animation: cpx-amt-land .55s cubic-bezier(.3, 1.6, .5, 1) both; }
.cpx-jw-cap { font: 750 12px/1.2 var(--sans); font-style: normal; color: var(--neon); }
.cpx-jw-cap[hidden] { display: none; }
.cpx-jw[data-tier="secret"] .cpx-jw-badge { display: none; }
.cpx-jw:not([data-tier="secret"]) :is(.cpx-jw-egg, .cpx-jw-plate) { display: none; }
/* 隐藏款:secret-plate 底板中间黑色那块(x 21–78%、y 38–59%,量过)叠「隐藏款」彩虹金字;裂开那一下才弹出来 */
.cpx-jw-plate { position: relative; width: min(94%, 430px); }
.cpx-jw-plate-art { display: block; width: 100%; height: auto; }
.cpx-jw-plate-t {
  position: absolute; left: 21%; right: 22%; top: 38%; bottom: 41.3%; display: grid; place-items: center; white-space: nowrap; letter-spacing: .06em;
  font: 900 30px/1 var(--round); font-size: clamp(20px, 8.5cqw, 40px); color: #ffe36a;
  background: linear-gradient(90deg, #ff6bd6, #ffe36a, #6bf0ff, #b48cff); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 10px rgba(255, 230, 120, .6));
}
.cpx-jw[data-tier="secret"]:not(.is-crack) .cpx-jw-plate { opacity: 0; transform: scale(.4); }
.cpx-jw[data-tier="secret"].is-crack .cpx-jw-plate { animation: cpx-plate-pop .7s cubic-bezier(.2, 1.5, .4, 1) both; }
@keyframes cpx-plate-pop { 0% { transform: scale(.3); opacity: 0; } 60% { transform: scale(1.12); opacity: 1; } 100% { transform: none; opacity: 1; } }
/* 巨大金扭蛋(CSS 画的两半 + 柠檬色接缝):先在中间放大、越晃越厉害、越来越亮,裂开时上半往上翻飞、下半往下掉 */
.cpx-jw-egg { position: absolute; left: 50%; top: 42%; z-index: 3; width: min(58%, 260px); aspect-ratio: 1; transform: translate(-50%, -50%); pointer-events: none; }
.cpx-jw-half { position: absolute; left: 0; right: 0; height: 50%; box-shadow: inset 0 0 22px rgba(120, 70, 0, .6), 0 0 40px rgba(255, 210, 60, .7); }
.cpx-jw-top { top: 0; border-radius: 50% 50% 0 0 / 100% 100% 0 0; background: radial-gradient(circle at 34% 40%, #fffbe0 0 8%, #ffe36a 24%, #f5b800 56%, #8a5600 100%); }
.cpx-jw-top::after { content: ''; position: absolute; left: 0; right: 0; bottom: -3px; height: 6px; background: var(--neon); box-shadow: 0 0 12px var(--neon); }
.cpx-jw-bot { bottom: 0; border-radius: 0 0 50% 50% / 0 0 100% 100%; background: radial-gradient(circle at 34% -10%, #fff3b0 0 10%, #ffd84a 32%, #e09a00 62%, #6a4000 100%); }
.cpx-jw[data-tier="secret"].is-in:not(.is-crack) .cpx-jw-egg { animation: cpx-egg 1.1s ease-in both; }
.cpx-jw.is-crack .cpx-jw-top { animation: cpx-egg-top .8s cubic-bezier(.3, .6, .4, 1) forwards; }
.cpx-jw.is-crack .cpx-jw-bot { animation: cpx-egg-bot .8s cubic-bezier(.3, .6, .4, 1) forwards; }
@keyframes cpx-egg {
  0% { transform: translate(-50%, -50%) scale(.3); filter: brightness(.9); }
  30% { transform: translate(-50%, -50%) scale(1); }
  45% { transform: translate(-50%, -50%) rotate(-5deg); }
  60% { transform: translate(-50%, -50%) rotate(6deg); }
  75% { transform: translate(-50%, -50%) rotate(-8deg) scale(1.04); filter: brightness(1.3); }
  90% { transform: translate(-50%, -50%) rotate(9deg) scale(1.08); filter: brightness(1.7) drop-shadow(0 0 30px #fff6b0); }
  100% { transform: translate(-50%, -50%) scale(1.1); filter: brightness(2.2) drop-shadow(0 0 40px #fff); }
}
@keyframes cpx-egg-top { to { transform: translate(-30%, -150%) rotate(-38deg); opacity: 0; } }
@keyframes cpx-egg-bot { to { transform: translate(20%, 140%) rotate(22deg); opacity: 0; } }

/* ---------- 图鉴页:图鉴柜 album-bg,15 格照坐标,每排下面的层板挂系列名和「已收齐 × n」 ---------- */
.cpx-ab-head { position: absolute; left: 9%; width: 41%; top: 9.6%; height: 4.9%; display: flex; align-items: center; justify-content: center; gap: 8px; font: 900 16px/1 var(--round); color: #15161a; text-shadow: 0 1px 0 rgba(255, 255, 255, .7); }
.cpx-ab-head small { font: 850 12px/1 var(--round); font-variant-numeric: tabular-nums; color: #2a2c33; }
.cpx-ab-close { position: absolute; right: 7%; top: 9.2%; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; color: var(--pearl); background: rgba(10, 10, 14, .72); box-shadow: inset 0 0 0 1px rgba(255, 216, 74, .6); }
.cpx-ab-close svg { width: 20px; height: 20px; }
.cpx-ab-cell { position: absolute; left: var(--x); top: var(--y); width: 14.6%; height: 15%; margin: 0; transform: translate(-50%, -50%); display: grid; place-items: center; padding-bottom: 12%; }
.cpx-ab-cell img { display: block; width: auto; height: auto; max-width: 92%; max-height: 74%; filter: brightness(0) saturate(0); opacity: .55; }
.cpx-ab-cell.is-have img { filter: drop-shadow(0 0 6px rgba(255, 216, 74, .75)); opacity: 1; }
.cpx-ab-cell.is-game:active { transform: translate(-50%, -50%) scale(.94); }
.cpx-ab-name { position: absolute; left: -8%; right: -8%; bottom: 3%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: center; font: 750 9px/1.15 var(--sans); color: #fff; text-shadow: 0 1px 2px #000, 0 0 4px #000; }
.cpx-ab-go { position: absolute; right: 0; top: 2%; width: 18px; height: 18px; display: grid; place-items: center; border-radius: 50%; color: var(--neon-ink); background: var(--neon); box-shadow: 0 0 8px rgba(229, 255, 61, .7); }
.cpx-ab-go svg { width: 10px; height: 10px; }
.cpx-ab-cell.is-off .cpx-ab-go { color: #9a9aa2; background: #34343a; box-shadow: none; }
.cpx-ab-row { position: absolute; left: 50%; top: var(--y); transform: translate(-50%, -50%); display: flex; align-items: baseline; gap: 8px; padding: 3px 12px; border-radius: 99px; white-space: nowrap; background: rgba(6, 6, 10, .88); box-shadow: inset 0 0 0 1px rgba(255, 216, 74, .35); font: 800 11px/1.25 var(--sans); color: #fff; }
.cpx-ab-row small { font: 700 10px/1.25 var(--sans); color: var(--ink-2); }
.cpx-ab-row.is-now { box-shadow: inset 0 0 0 1.5px var(--neon), 0 0 10px rgba(229, 255, 61, .4); }
.cpx-ab-note, .cpx-ab-tip { position: absolute; left: 6%; right: 6%; padding: 4px 8px; border-radius: 10px; text-align: center; font: 700 11px/1.35 var(--sans); color: var(--pearl); background: rgba(0, 0, 0, .62); }
.cpx-ab-note { top: 85.2%; }
.cpx-ab-tip { top: 91%; color: var(--neon); }

/* 关了「动态效果」(J08):不冲、不掉、不弹、不闪,结果照样看得清 */
@media (prefers-reduced-motion: reduce) {
  .capsule *, .capsule *::before, .capsule *::after { animation: none !important; transition: none !important; }
  .cpx-beam, .cpx-flash, .cpx-jw-egg, .cpx-flyers { display: none !important; }
  .cpx-jw[data-tier="secret"] .cpx-jw-plate { opacity: 1 !important; transform: none !important; }
}

/* ---------- 说明页(画在全站的弹层里,所以不套 .capsule) ---------- */
.cpx-rules p { margin: 8px 0; line-height: 1.5; }
.cpx-rules-bet { display: flex; align-items: baseline; gap: 6px; }
.cpx-rules-bet b { font-variant-numeric: tabular-nums; }
.cpx-pay td, .cpx-pay th { text-align: center; font-variant-numeric: tabular-nums; }
.cpx-pay-sym { display: flex; align-items: center; gap: 6px; text-align: left !important; }
.cpx-pay-sym img { width: auto; height: 34px; }
.cpx-pay-sym small { font-size: 12px; }
.cpx-rules-f { display: flex; align-items: flex-start; gap: 10px; margin: 12px 0; }
.cpx-rules-f > img { flex: none; width: auto; height: 46px; margin-top: 4px; }
.cpx-rules-f p { margin: 4px 0; }
.cpx-rules-jp { flex-direction: column; }
.cpx-rules-plaques { display: flex; gap: 8px; }
.cpx-rules-plaques img { width: auto; height: 54px; }
.cpx-rules-lad { font-weight: 800; font-variant-numeric: tabular-nums; color: #e5ff3d; }
.cpx-rules-mini { margin: 6px 0; }
.cpx-rules-mini td { text-align: center; font-variant-numeric: tabular-nums; }
.cpx-rules-note { font-size: 12px; opacity: .75; }

/* 对局记录详情的开局盘面(清单 U07):5 轴 × 4 行小图,跟游戏里一样从左到右 */
.cpx-hist { margin-top: 12px; }
.cpx-hist small { display: block; margin-bottom: 6px; opacity: .7; font-size: 12px; }
.cpx-hist-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; max-width: 280px; padding: 8px; border-radius: 12px; background: rgba(255, 255, 255, .06); }
.cpx-hist-grid img { width: 100%; height: auto; aspect-ratio: 44 / 56; object-fit: contain; }
