/* 山海卷 · B 风格皮肤（手绘卡通：粗黑描边、平涂、夸张剪影）
 * 覆盖 style.css 的视觉，布局与交互不变。 */
:root {
  --line: #1a120c;
  --ui: 'ZCOOL QingKe HuangYou', 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --body: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --parch: #f3e4c0; --parch2: #e2c993;
}
body { font-family: var(--body); }
.btn { font-family: var(--ui); letter-spacing: .04em; border: 3px solid var(--line); border-radius: 12px; background: linear-gradient(#6b5a48, #4a3c2f); box-shadow: 0 4px 0 var(--line), inset 0 2px 0 #9a856c; color: #fff6e6; font-size: 18px; text-shadow: 0 2px 0 var(--line); }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--line), inset 0 2px 0 #9a856c; }
.btn.primary { background: linear-gradient(#f0743f, #c23a1c); box-shadow: 0 4px 0 var(--line), inset 0 2px 0 #ffb08a; border-color: var(--line); }
.btn.gold { background: linear-gradient(#f6cf5a, #d18e1c); box-shadow: 0 4px 0 var(--line), inset 0 2px 0 #fff0b0; color: #3a2204; text-shadow: none; }
.btn.plain { background: transparent; box-shadow: none; border-color: transparent; }
.panel { background: linear-gradient(#3b2f25, #2a211a); border: 3px solid var(--line); border-radius: 14px; box-shadow: 0 6px 0 #000a, inset 0 0 0 2px #5a4a3a; }
.paper, .evtext { background: linear-gradient(var(--parch), var(--parch2)); border: 3px solid var(--line); color: #2a1a0e; box-shadow: 0 5px 0 #000a; }
.title-sm, .veil .mhead h2, .dialog h3, .hero h3 { font-family: var(--ui); letter-spacing: .04em; text-shadow: 0 3px 0 var(--line); }
.opt, .rw, .restopt { border: 3px solid var(--line); border-radius: 12px; background: linear-gradient(#4d3e31, #34291f); box-shadow: 0 4px 0 #000a; }
.opt:hover, .rw:hover, .restopt:hover { background: linear-gradient(#5d4b3b, #3e3126); }
.restopt .g { font-family: var(--ui); color: #ffb14a; text-shadow: 0 3px 0 var(--line); }

/* 顶栏 */
.hud { background: linear-gradient(#2b2119, #1c1510); border-bottom: 3px solid var(--line); box-shadow: 0 3px 0 #0008; }
.hud .stat b { font-family: var(--ui); font-size: 18px; text-shadow: 0 2px 0 var(--line); }
.hud .who { border: 2px solid var(--line); box-shadow: 0 2px 0 var(--line); overflow: hidden; }
.hud .who img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 15%; }
.relic { border: 2px solid var(--line); box-shadow: 0 2px 0 var(--line); border-radius: 8px; font-family: var(--ui); }
.pot.has { border: 2px solid var(--line); box-shadow: 0 2px 0 var(--line); font-family: var(--ui); }
.jade { display: inline-block; width: 1em; height: 1em; vertical-align: -.14em; border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%; background: radial-gradient(circle at 35% 30%, #c8ffe6, #3fbf8a 55%, #136b4a); box-shadow: 0 0 0 1.5px var(--line); }

/* 卡牌：粗描边 + 名称飘带 + 宝石费用 */
.card { border-radius: calc(var(--cw) * .08); background: linear-gradient(#5a4a3a, #3b2f25); color: #fff6e6; box-shadow: 0 0 0 calc(var(--cw) * .028) var(--line), inset 0 0 0 calc(var(--cw) * .045) var(--tc), 0 5px 0 #000a; padding: calc(var(--cw) * .06); }
.card.t-atk { --tc: #c23a1c; } .card.t-skl { --tc: #2f6fb0; } .card.t-pow { --tc: #d7a12a; } .card.t-sts { --tc: #6b6b6b; } .card.t-cur { --tc: #6b2a7a; }
.card .cname { position: relative; z-index: 2; margin-top: calc(var(--cw) * .02); padding: calc(var(--cw) * .012) calc(var(--cw) * .1); max-width: 100%; border: calc(var(--cw) * .018) solid var(--line); border-radius: calc(var(--cw) * .04); background: linear-gradient(#f6e6c0, #ddc28a); color: #2a1a0e; font-family: var(--ui); font-weight: 400; font-size: calc(var(--cw) * .12); box-shadow: 0 calc(var(--cw) * .02) 0 var(--line); }
.card.up .cname { color: #1b7a3a; }
.card .cost { width: calc(var(--cw) * .27); height: calc(var(--cw) * .27); left: calc(var(--cw) * -.02); top: calc(var(--cw) * -.02); border: calc(var(--cw) * .022) solid var(--line); background: radial-gradient(circle at 35% 30%, #ffd36b, #e0741a 55%, #8a3206); font-family: var(--ui); font-size: calc(var(--cw) * .17); text-shadow: 0 2px 0 var(--line); box-shadow: 0 calc(var(--cw) * .02) 0 var(--line); z-index: 3; }
.card .art { margin-top: calc(var(--cw) * -.02); height: calc(var(--cw) * .56); border: calc(var(--cw) * .02) solid var(--line); border-radius: calc(var(--cw) * .05) calc(var(--cw) * .05) calc(var(--cw) * .02) calc(var(--cw) * .02); background: radial-gradient(ellipse at 50% 40%, color-mix(in srgb, var(--tc) 45%, #f3e4c0), color-mix(in srgb, var(--tc) 70%, #2a1a0e)); box-shadow: none; }
.card .art span { color: #fff6e6; opacity: 1; font-family: var(--ui); text-shadow: 0 calc(var(--cw) * .025) 0 var(--line), 0 0 calc(var(--cw) * .08) #0006; -webkit-text-stroke: calc(var(--cw) * .012) var(--line); }
.card .ctype { margin-top: calc(var(--cw) * -.06); border: calc(var(--cw) * .014) solid var(--line); border-radius: calc(var(--cw) * .1); background: var(--tc); font-size: calc(var(--cw) * .08); padding: 0 calc(var(--cw) * .07); }
.card .cdesc { margin-top: calc(var(--cw) * .03); width: 100%; border-radius: calc(var(--cw) * .04); background: linear-gradient(#f3e4c0, #e6cf9c); color: #2a1a0e; border: calc(var(--cw) * .014) solid var(--line); padding: calc(var(--cw) * .03); font-size: calc(var(--cw) * .095); font-weight: 500; }
.card .cdesc b { color: #1a120c; }
.card .gem { display: none; }
.card.r-uncommon { box-shadow: 0 0 0 calc(var(--cw) * .028) var(--line), inset 0 0 0 calc(var(--cw) * .045) var(--tc), 0 5px 0 #000a, 0 0 0 calc(var(--cw) * .05) #6fb6ff inset; }
.card.r-rare { box-shadow: 0 0 0 calc(var(--cw) * .028) var(--line), inset 0 0 0 calc(var(--cw) * .045) var(--tc), 0 5px 0 #000a, 0 0 14px #ffd36b; }
.card.r-rare .cname { background: linear-gradient(#ffe89a, #e7b43c); }
.hand .card.playable { box-shadow: 0 0 0 calc(var(--cw) * .028) var(--line), inset 0 0 0 calc(var(--cw) * .045) var(--tc), 0 5px 0 #000a, 0 0 0 calc(var(--cw) * .06) #7cf0a4, 0 0 16px #7cf0a4aa; }

/* ---------- 横版战斗舞台 ---------- */
.stage { background: var(--bg, none) center 60% / cover no-repeat; overflow: hidden; }
.stage::after { content: ''; position: absolute; inset: 0; background: linear-gradient(#0000 55%, #0006 100%); pointer-events: none; }
/* 有 AI 背景图时稍微压暗、四周加暗角，让角色从画面里跳出来 */
.stage::before { content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: radial-gradient(ellipse 80% 75% at 50% 62%, #0000 40%, #0007 100%), #0002; }
.stage .foes, .stage .me { z-index: 2; }
.stage .foes { position: absolute; top: auto; height: auto; left: 34%; right: 2%; bottom: var(--gy, 14%); display: flex; align-items: flex-end; justify-content: space-evenly; gap: 24px; padding: 0; }
.stage .me { position: absolute; left: 3%; width: 28%; max-width: none; bottom: var(--gy, 14%); display: flex; flex-direction: column; align-items: center; gap: 0; }
.unit { display: flex; flex-direction: column; align-items: center; position: relative; transition: opacity .6s, transform .3s; min-width: 0; flex: 0 1 auto; }
.unit .sprite img { max-width: var(--sw, 260px); width: auto; }
.unit.dead { opacity: 0; transform: translateY(20px) scale(.8); pointer-events: none; }
.sprite { position: relative; display: flex; align-items: flex-end; justify-content: center; transform-origin: 50% 100%; animation: idle 3s ease-in-out infinite; }
.sprite img { display: block; height: var(--sh, 140px); max-width: var(--sw, 260px); object-fit: contain; object-position: 50% 100%; filter: drop-shadow(0 0 2px #000c) drop-shadow(0 6px 0 #0005); pointer-events: none; -webkit-user-drag: none; }
.sprite::before { content: ''; position: absolute; left: 15%; right: 15%; bottom: -6px; height: 14px; border-radius: 50%; background: #0007; filter: blur(2px); z-index: -1; }
.sprite .disk { --es: min(calc(var(--sh, 140px) * .7), var(--sw, 200px)); }
.unit .intent { height: 30px; margin-bottom: 2px; font-family: var(--ui); font-size: 19px; text-shadow: 0 2px 0 var(--line), 0 0 4px #000; }
.unit .uinfo { width: min(150px, 100%); margin-top: 6px; }
.unit .fname { font-family: var(--ui); font-size: 14px; text-align: center; color: #fff; text-shadow: 0 2px 0 var(--line); margin-top: 2px; }
.stage .hpbar { height: 15px; border: 2px solid var(--line); border-radius: 8px; background: #2a1410; }
.stage .hpbar b { font-family: var(--ui); font-weight: 400; font-size: 12px; line-height: 12px; text-shadow: 0 1px 0 var(--line); }
.stage .pws { min-height: 0; }
.unit.targetable .sprite img { filter: drop-shadow(0 0 0 #fff) drop-shadow(0 0 6px #ffe27a) drop-shadow(0 0 2px #ffe27a); }
.unit.targetable .sprite .disk { box-shadow: 0 0 0 4px #ffe27a, 0 0 20px #ffe27a; }
.unit.hot .sprite { transform: scale(1.06); }
.unit.hot .sprite img { filter: drop-shadow(0 0 3px #fff) drop-shadow(0 0 10px #ff6a3a); }
.sprite.hit img, .sprite.hit .disk { animation: hitflash calc(.25s / var(--spd)); }
.unit.lunge .sprite { animation: lungeL calc(.35s / var(--spd)); }
.me.lunge .sprite { animation: lungeR calc(.3s / var(--spd)); }
@keyframes idle { 50% { transform: scaleY(1.025) scaleX(.99); } }
@keyframes hitflash { 0% { filter: brightness(3) saturate(0); } 100% { filter: none; } }
@keyframes lungeL { 40% { transform: translateX(-34px) scale(1.06); } }
@keyframes lungeR { 40% { transform: translateX(34px) scale(1.04); } }
.stage .incoming { z-index: 3; color: #fff; text-shadow: 0 2px 0 var(--line); right: 10px; bottom: 8px; }
.stage .hint { z-index: 6; font-family: var(--ui); font-size: 15px; border: 2px solid var(--line); background: #000b; }
.movename { font-family: var(--ui); border: 2px solid var(--line); background: #c23a1c; box-shadow: 0 3px 0 var(--line); }
.energy { border: 3px solid var(--line); box-shadow: 0 4px 0 var(--line), 0 0 18px #ff9a3a88; font-family: var(--ui); font-weight: 400; font-size: 22px; text-shadow: 0 2px 0 var(--line); }
.pile { border: 2px solid var(--line); background: #2b2119; box-shadow: 0 3px 0 var(--line); }
.pile b { font-family: var(--ui); font-weight: 400; }
.float { font-family: var(--ui); font-weight: 400; -webkit-text-stroke: 2px var(--line); paint-order: stroke fill; text-shadow: 0 3px 0 var(--line); }
.banner { font-family: var(--ui); text-shadow: 0 4px 0 var(--line); }
.ctrl { background: linear-gradient(#0000, #0008); }

/* ---------- 城塔地图 ---------- */
.towerwrap { flex: 1; position: relative; min-height: 0; background: #111 var(--bg, none) center / cover no-repeat; }
.towerwrap::before { content: ''; position: absolute; inset: 0; background: linear-gradient(#0009, #0004 30%, #0007); pointer-events: none; }
.towerscroll { position: absolute; inset: 0; overflow-y: auto; overscroll-behavior: contain; padding: 70px 0 40px; }
.tower { position: relative; width: min(560px, 94%); margin: 0 auto; display: flex; flex-direction: column-reverse; }
.tfloor { position: relative; display: flex; align-items: flex-end; justify-content: center; gap: clamp(8px, 4vw, 26px); height: 112px; padding: 0 44px 10px; border-left: 4px solid var(--line); border-right: 4px solid var(--line);
  background: repeating-linear-gradient(0deg, #0000 0 26px, #0000003a 26px 29px), repeating-linear-gradient(90deg, #0000 0 52px, #0000002a 52px 55px), linear-gradient(90deg, #6d5a45, #8a7356 30%, #8a7356 70%, #5d4c3a); }
.act-2 .tfloor { background: repeating-linear-gradient(0deg, #0000 0 26px, #0000003a 26px 29px), repeating-linear-gradient(90deg, #0000 0 52px, #0000002a 52px 55px), linear-gradient(90deg, #3d5a6d, #56798a 30%, #56798a 70%, #344c5d); }
.act-3 .tfloor { background: repeating-linear-gradient(0deg, #0000 0 26px, #0000003a 26px 29px), repeating-linear-gradient(90deg, #0000 0 52px, #0000002a 52px 55px), linear-gradient(90deg, #8a6a5a, #c9ad92 30%, #c9ad92 70%, #7a5a4a); }
.tfloor::after { content: ''; position: absolute; left: -14px; right: -14px; bottom: -8px; height: 14px; background: linear-gradient(#a08868, #6b5640); border: 3px solid var(--line); border-radius: 4px; z-index: 1; }
.act-2 .tfloor::after { background: linear-gradient(#6a9ab0, #3d6070); } .act-3 .tfloor::after { background: linear-gradient(#f0d9a8, #b89060); }
.tfloor .fnum { position: absolute; left: 8px; top: 8px; font-family: var(--ui); font-size: 16px; color: #fff; text-shadow: 0 2px 0 var(--line); }
.tfloor.past { filter: brightness(.6) saturate(.6); }
.tfloor.next { filter: none; }
.tfloor.next::before { content: ''; position: absolute; inset: 0; background: radial-gradient(ellipse at 50% 100%, #ffd36b33, #0000 70%); pointer-events: none; }
.door { position: relative; z-index: 2; width: 62px; height: 80px; padding: 0; border: 3px solid var(--line); border-radius: 31px 31px 4px 4px; background: linear-gradient(#3a2a1e, #1e150f); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; color: #fff; box-shadow: inset 0 0 0 4px #00000055, 0 3px 0 var(--line); cursor: default; }
.door .ico { font-family: var(--ui); font-size: 28px; line-height: 1; text-shadow: 0 2px 0 var(--line); }
.door .lb { font-family: var(--ui); font-size: 12px; text-shadow: 0 1px 0 var(--line); }
.door.t-fight { --dc: #d0503a; } .door.t-elite { --dc: #ff3d2e; } .door.t-event { --dc: #4aa3ff; } .door.t-shop { --dc: #f3c44a; } .door.t-rest { --dc: #ff9a3a; } .door.t-chest { --dc: #f3c44a; } .door.t-boss { --dc: #ff3d2e; }
.door .ico { color: var(--dc); }
.door.t-elite { background: linear-gradient(#5a1a12, #2a0a06); }
.door.avail { cursor: pointer; background: linear-gradient(#ffcf6a, #e08a2a); animation: doorPulse 1.2s ease-in-out infinite; }
.door.avail .ico { color: #2a1206; text-shadow: 0 2px 0 #fff6; } .door.avail .lb { color: #2a1206; text-shadow: none; }
.door.chosen { background: linear-gradient(#c23a1c, #7a1a08); }
.door.chosen .ico, .door.chosen .lb { color: #fff; }
@keyframes doorPulse { 50% { transform: translateY(-4px); box-shadow: inset 0 0 0 4px #fff6, 0 7px 0 var(--line), 0 0 18px #ffd36b; } }
.climber { position: absolute; z-index: 3; bottom: 6px; width: 56px; height: 72px; pointer-events: none; transition: left .4s; }
.climber img { width: 100%; height: 100%; object-fit: contain; object-position: 50% 100%; filter: drop-shadow(0 3px 0 #0008); }
.roof { position: relative; height: 210px; display: flex; align-items: flex-end; justify-content: center; }
.roof .top { position: absolute; left: -26px; right: -26px; bottom: 0; height: 120px; clip-path: polygon(50% 0, 100% 78%, 100% 100%, 0 100%, 0 78%); background: linear-gradient(#c23a1c, #7a1a08); border-bottom: 6px solid var(--line); }
.act-2 .roof .top { background: linear-gradient(#2f6fb0, #173a66); } .act-3 .roof .top { background: linear-gradient(#f3c44a, #a8761a); }
.roof .boss { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: center; cursor: default; padding: 0; border: 0; background: none; }
.roof .boss img { height: 150px; max-width: 260px; object-fit: contain; filter: drop-shadow(0 4px 0 #000a) brightness(.35); transition: filter .3s; }
.roof .boss.avail img { filter: drop-shadow(0 0 12px #ff3d2e) drop-shadow(0 4px 0 #000a); cursor: pointer; animation: doorPulse 1.2s infinite; }
.roof .boss .disk { --es: 110px; }
.roof .boss .lb { font-family: var(--ui); font-size: 18px; color: #fff; text-shadow: 0 2px 0 var(--line); margin-top: -6px; background: #c23a1c; border: 2px solid var(--line); border-radius: 8px; padding: 0 10px; }
.base { height: 40px; margin: 0 -30px; background: linear-gradient(#5a4a3a, #3b2f25); border: 4px solid var(--line); border-radius: 6px; }
.towertitle { position: absolute; z-index: 3; top: 0; left: 0; right: 0; padding: 10px; text-align: center; font-family: var(--ui); font-size: 24px; color: #fff; text-shadow: 0 3px 0 var(--line); background: linear-gradient(#000c, #0000); pointer-events: none; }
.towertitle small { display: block; font-size: 14px; color: #ffd9a0; }
@media (max-width: 420px) { .tfloor { height: 100px; padding: 0 30px 10px; } .door { width: 54px; height: 72px; } .door .ico { font-size: 24px; } }

/* ---------- 标题主视觉 / 商城 ---------- */
.title.keyart { background: var(--bg) center / cover no-repeat; }
.title.keyart::before { content: ''; position: absolute; inset: 0; background: linear-gradient(#0002, #0000 35%, #0007 80%); }
.title > * { position: relative; }
.logo h1 { font-family: var(--brush); -webkit-text-stroke: 3px var(--line); paint-order: stroke fill; text-shadow: 0 6px 0 var(--line); color: #fff1d0; }
.tagline { text-shadow: 0 2px 0 var(--line); font-family: var(--ui); }
.jadebar { position: absolute; top: calc(var(--safe-t) + 10px); right: 12px; z-index: 3; display: flex; align-items: center; gap: 6px; padding: 4px 12px; border: 3px solid var(--line); border-radius: 20px; background: #2b2119; font-family: var(--ui); font-size: 18px; box-shadow: 0 3px 0 var(--line); }
.mall { width: min(760px, 100%); display: flex; flex-direction: column; gap: 14px; }
.mallgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.prod { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 10px 12px; border: 3px solid var(--line); border-radius: 14px; background: linear-gradient(#4d3e31, #34291f); box-shadow: 0 4px 0 #000a; text-align: center; }
.prod .big { font-size: 40px; line-height: 1; font-family: var(--ui); }
.prod b { font-family: var(--ui); font-size: 17px; font-weight: 400; }
.prod .d { font-size: 12px; color: #d9c8a8; min-height: 2.6em; }
.prod .own { font-size: 12px; color: #9fe0b8; }
.prod .ribbon { position: absolute; top: -8px; right: -6px; background: #c23a1c; color: #fff; font-size: 12px; padding: 1px 8px; border: 2px solid var(--line); border-radius: 6px; font-family: var(--ui); }
.prod .gem3 { width: 54px; height: 54px; display: grid; place-items: center; font-family: var(--ui); font-size: 30px; color: #fff; border: 3px solid var(--line); border-radius: 14px; background: radial-gradient(circle at 35% 30%, #a98bff, #4a2a9a 70%); box-shadow: 0 3px 0 var(--line); text-shadow: 0 2px 0 var(--line); }
.testnote { font-size: 13px; color: #ffcf8a; text-align: center; padding: 6px 10px; border: 2px dashed #a07a3a; border-radius: 8px; }
.loadout { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.lo { display: flex; align-items: center; gap: 8px; padding: 6px 12px 6px 6px; border: 3px solid var(--line); border-radius: 12px; background: #2b2119; min-height: 48px; }
.lo.on { background: linear-gradient(#2f7a52, #1d4d33); }
.lo .gem3 { width: 36px; height: 36px; font-size: 20px; border-radius: 10px; }
.lo[disabled] { opacity: .4; }
.stage.nobg::before { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: calc(var(--gy, 14%) + 8px); background: linear-gradient(#4a3a2a, #241b13); border-top: 3px solid var(--line); box-shadow: 0 -6px 18px #0006; }
#app[data-act="2"] .stage.nobg::before { background: linear-gradient(#2c4a5a, #13222b); }
#app[data-act="3"] .stage.nobg::before { background: linear-gradient(#8a6a4a, #3a2a1c); }
.stage > .scene { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; }
.title.keyart { background-position: center bottom; }
/* ---------- 特效 ---------- */
.vfx { position: absolute; width: 0; height: 0; pointer-events: none; z-index: 41; }
.vfx > svg { position: absolute; left: 0; top: 0; overflow: visible; }
.vfx-star { position: absolute; left: 0; top: 0; width: 120px; height: 120px; background: var(--c); clip-path: polygon(50% 0, 60% 38%, 100% 50%, 60% 62%, 50% 100%, 40% 62%, 0 50%, 40% 38%); filter: drop-shadow(0 0 6px var(--c)); }
.vfx-dot { position: absolute; left: 0; top: 0; width: 10px; height: 10px; border-radius: 50%; border: 2px solid #1a120c; }
.vfx-ring { position: absolute; left: 0; top: 0; width: 120px; height: 120px; border: 5px solid #fff; border-radius: 50%; box-shadow: 0 0 10px #fff8; }
.vfx-tali { width: 26px; height: 40px; margin: -20px 0 0 -13px; background: linear-gradient(#ffe27a, #e7a82a); border: 3px solid #1a120c; border-radius: 3px; box-shadow: 0 0 14px #ffd36b; position: relative; }
.vfx-tali::after { content: '敕'; position: absolute; inset: 0; display: grid; place-items: center; font: 16px var(--ui); color: #b5361f; }
.vfx-orb { width: 30px; height: 30px; margin: -15px 0 0 -15px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #fff, var(--c) 45%, #1a120c 100%); border: 3px solid #1a120c; box-shadow: 0 0 16px var(--c); }
.vfx-shield { position: absolute; left: 0; top: 0; clip-path: polygon(50% 0, 100% 18%, 100% 58%, 50% 100%, 0 58%, 0 18%); background: radial-gradient(circle at 50% 40%, #cfe6ffcc, #5b8fd088 60%, #2f5f9e66); }
.vfx-plus, .vfx-arrow, .vfx-bub { position: absolute; left: 0; top: 0; }
.vfx-plus { width: 18px; height: 18px; background: var(--c); clip-path: polygon(35% 0, 65% 0, 65% 35%, 100% 35%, 100% 65%, 65% 65%, 65% 100%, 35% 100%, 35% 65%, 0 65%, 0 35%, 35% 35%); filter: drop-shadow(0 0 4px var(--c)); }
.vfx-arrow { width: 16px; height: 22px; background: var(--c); clip-path: polygon(50% 0, 100% 50%, 68% 50%, 68% 100%, 32% 100%, 32% 50%, 0 50%); filter: drop-shadow(0 0 4px var(--c)); }
.vfx-bub { width: 14px; height: 14px; border-radius: 50%; border: 2px solid #1a120c; background: radial-gradient(circle at 35% 30%, #fff, var(--c) 50%); }
.vfx-flash { position: absolute; inset: 0; pointer-events: none; z-index: 42; mix-blend-mode: screen; }
.vfx-sweep { position: absolute; left: 0; top: 0; height: 26px; border-radius: 13px; background: linear-gradient(90deg, transparent, var(--c) 30%, #fff 50%, var(--c) 70%, transparent); box-shadow: 0 0 20px var(--c); border-top: 3px solid #1a120c; border-bottom: 3px solid #1a120c; }
.relics .pots { display: flex; gap: 4px; flex: none; }
.relics .rsep { flex: none; width: 2px; height: 26px; background: #ffffff22; margin: 0 4px; }
.relics .pot { width: 30px; height: 30px; }
.hud .jadebtn { width: auto; min-width: 38px; padding: 0 6px; display: flex; gap: 4px; align-items: center; }
.hud .jadebtn .jade { font-size: 18px; }
.hud .jadebtn .cnt { position: static; background: none; font-family: var(--ui); font-size: 15px; color: #c8ffe6; padding: 0; }
.runshop .prod[disabled], .runshop .prod.off { opacity: .45; }
.runshop .left { font-size: 12px; color: #ffd9a0; }
/* 新手引导 */
.tutor { position: absolute; inset: 0; z-index: 55; }
.tutor .hole { position: absolute; border-radius: 14px; box-shadow: 0 0 0 4px #ffe27a, 0 0 0 9999px #000b; transition: all .25s; pointer-events: none; }
.tutor .bubble { position: absolute; left: 50%; transform: translateX(-50%); width: min(420px, 92%); padding: 14px 16px 12px; border: 3px solid var(--line); border-radius: 14px; background: linear-gradient(var(--parch), var(--parch2)); color: #2a1a0e; box-shadow: 0 6px 0 #000a; font-size: 15px; line-height: 1.65; }
.tutor .bubble p { margin: 0 0 10px; }
.tutor .bubble b { color: #b5361f; }
.tutor .bubble .sn { display: inline-block; font-family: var(--ui); background: #c23a1c; color: #fff; border-radius: 8px; padding: 0 8px; margin-right: 4px; }
.tutor .bubble .row { justify-content: flex-end; }
.tutor .bubble .btn.plain { color: #6b5a45; text-shadow: none; }
.achtoast { position: absolute; z-index: 65; top: calc(var(--safe-t) + 60px); left: 50%; transform: translateX(-50%); display: flex; gap: 10px; align-items: center; padding: 8px 16px; border: 3px solid var(--line); border-radius: 14px; background: linear-gradient(#3b6e52, #1f4030); color: #fff; box-shadow: 0 5px 0 #000a; animation: achIn 3.2s forwards; white-space: nowrap; }
.achtoast .jade { font-size: 28px; } .achtoast span { font-size: 13px; color: #d6f5e2; }
@keyframes achIn { 0% { opacity: 0; transform: translate(-50%, -20px); } 10%, 85% { opacity: 1; transform: translate(-50%, 0); } 100% { opacity: 0; } }
.signrow { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.sday { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px; border: 2px solid var(--line); border-radius: 10px; background: #2b2119; font-size: 12px; }
.sday b { font-family: var(--ui); font-weight: 400; font-size: 16px; }
.sday.got { opacity: .45; } .sday.now { background: linear-gradient(#f6cf5a, #d18e1c); color: #3a2204; box-shadow: 0 0 12px #ffd36b; }
.veil { background: #0e0b09ee; }
@media (max-aspect-ratio: 3/4) { .title.keyart { background-position: 30% center; } }
@media (max-width: 600px) { .stage .foes { left: 30%; gap: 4px; justify-content: space-around; } }

/* ---------- 卡牌品阶：凡 / 灵 / 仙 / 神（右上角印章 + 卡框颜色） ---------- */
.card .grade { position: absolute; z-index: 3; left: calc(var(--cw) * .02); top: calc(var(--cw) * .27); width: calc(var(--cw) * .2); height: calc(var(--cw) * .2); display: grid; place-items: center; border: calc(var(--cw) * .018) solid var(--line); border-radius: calc(var(--cw) * .04); transform: rotate(-8deg); font-family: var(--ui); font-size: calc(var(--cw) * .12); line-height: 1; color: #fff; text-shadow: 0 1px 0 var(--line); background: #8a7a66; box-shadow: 0 calc(var(--cw) * .015) 0 var(--line); }
.card.r-uncommon .grade { background: linear-gradient(#6fc0ff, #2a64c0); }
.card.r-rare .grade { background: linear-gradient(#ffe48a, #d0901c); color: #3a2200; text-shadow: none; }
.card.r-legend .grade { background: linear-gradient(#ff8ad8, #8a2ad0); }
.card.r-uncommon { background: linear-gradient(#3e5470, #24324a); box-shadow: 0 0 0 calc(var(--cw) * .028) var(--line), inset 0 0 0 calc(var(--cw) * .045) var(--tc), 0 5px 0 #000a, 0 0 10px #6fb6ffaa; }
.card.r-rare { background: linear-gradient(#7a6230, #4a3812); box-shadow: 0 0 0 calc(var(--cw) * .028) var(--line), inset 0 0 0 calc(var(--cw) * .045) var(--tc), 0 5px 0 #000a, 0 0 16px #ffd36bcc; }
.card.r-legend { background: linear-gradient(#6a2a6e, #2c1040); box-shadow: 0 0 0 calc(var(--cw) * .028) var(--line), inset 0 0 0 calc(var(--cw) * .045) var(--tc), 0 5px 0 #000a, 0 0 18px #ff7ad8; animation: legendGlow 2.4s ease-in-out infinite; }
.card.r-legend .cname { background: linear-gradient(#ffd0f0, #e08ad8); }
@keyframes legendGlow { 50% { box-shadow: 0 0 0 calc(var(--cw) * .028) var(--line), inset 0 0 0 calc(var(--cw) * .045) var(--tc), 0 5px 0 #000a, 0 0 26px #b07aff; } }
.card.up .cname::after { content: ''; }
.card.up { outline: calc(var(--cw) * .02) solid #7cf0a488; outline-offset: calc(var(--cw) * -.01); }
.hand .card.r-legend.playable { animation: none; }
.card.r-uncommon .cname { background: linear-gradient(#d6ecff, #8fc2f0); }
.card.r-rare .cname { background: linear-gradient(#ffe89a, #e7b43c); }
/* ---------- v1.5 伙伴队伍 + 站在地面上 ---------- */
.stage .team { position: absolute; left: 1.5%; width: 32%; bottom: var(--gy, 14%); display: flex; align-items: flex-end; justify-content: flex-end; z-index: 2; pointer-events: none; }
.stage .team > * { pointer-events: auto; }
.stage .me { position: relative; left: auto; bottom: auto; width: auto; flex: none; }
.stage .allies { display: flex; align-items: flex-end; flex-direction: row-reverse; margin-right: -6%; z-index: 1; }
.stage .ally { margin-left: -14px; flex: none; }
.ally .sprite.flip img { transform: scaleX(-1); }
.ally.lunge .sprite { animation: lungeR calc(.3s / var(--spd)); }
.ally.appear { animation: allyIn calc(.45s / var(--spd)) ease-out; }
@keyframes allyIn { from { opacity: 0; translate: 0 30px; scale: .6; } }
.ally .fname { font-size: 12px; }
.ally .hpbar { height: 12px; }
/* 血条和名字挂在脚下，立绘的脚正好踩在地面线上，不再“浮空” */
.stage .unit .uinfo { position: absolute; top: 100%; left: 50%; transform: translateX(-50%); width: clamp(76px, 100%, 150px); margin-top: 3px; }
@media (max-width: 600px) { .stage .team { width: 29%; } .stage .ally { margin-left: -18px; } }
.stage .ally .uinfo { width: 64px; }
.stage .me .uinfo { width: clamp(80px, 100%, 140px); }
@media (max-width: 600px) { .stage .team { left: 0; width: 36%; } .stage.has-allies .foes { left: 36%; } .stage .ally { margin-left: -40px; } .stage .allies { margin-right: -14%; } .stage .ally .uinfo { width: 52px; } .stage .ally .fname { display: none; } }
/* 伙伴面板 */
.ib.partybtn .pg { font-family: var(--ui); font-size: 17px; line-height: 1; }
.party .prow { display: flex; align-items: center; gap: 10px; padding: 8px; margin: 6px 0; border: 2px solid var(--line); border-radius: 10px; background: #0003; text-align: left; }
.party .pimg { width: 64px; height: 56px; display: grid; place-items: center; flex: none; }
.party .pimg img { max-width: 64px; max-height: 56px; transform: scaleX(-1); }
.party .pimg span { font-family: var(--ui); font-size: 28px; }
.party .pinfo { flex: 1; line-height: 1.4; }
.party .sub { white-space: pre-line; font-size: 13px; }
/* v1.6 拉开双方距离：我方靠左，敌方靠右，中间留出空地 */
.stage .team { left: 3%; width: 28%; }
.stage .foes { left: 46%; right: 3%; justify-content: space-around; gap: 16px; }
@media (max-width: 600px) { .stage .team { left: 1%; width: 30%; } .stage .foes { left: 36%; right: 1%; gap: 4px; } .stage.has-allies .team { width: 34%; } .stage.has-allies .foes { left: 38%; } }
.hero .hportrait { width: 90px; height: 110px; display: grid; place-items: end center; flex: none; }
.hero .hportrait img { max-width: 90px; max-height: 110px; }
/* 奖励自动收下 */
.rw.done { cursor: default; opacity: .92; }
.rw .okmark { margin-left: auto; font-size: 13px; color: #9fe8b0; padding: 2px 8px; border: 1px solid #9fe8b066; border-radius: 10px; }
.rwcards { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 6px 0; }
.rwcards .card { position: relative; cursor: pointer; transition: transform .15s; }
.rwcards .card:hover { transform: translateY(-6px) scale(1.04); }
.ctrl .shopbtn { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.offer .big { font-size: 15px; margin: 6px 0 12px; }
