/* style.css — 《无限塔》深渊黑曜石 + 魔导金 + 余烬橙 */
* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
  --obsidian: #0b0d13;
  --obsidian2: #12141d;
  --panel: #171a26;
  --panel2: #1e2230;
  --gold: #d4a94e;
  --gold-bright: #f0c96a;
  --ember: #ff7a3c;
  --ember-dim: #b34a20;
  --teal: #4fd2c2;
  --red: #e05252;
  --text: #e8e2d5;
  --text-dim: #8b8fa3;
  --line: #3a3f55;
}
html, body { height: 100%; }
body {
  background: radial-gradient(1200px 800px at 50% -10%, #1a1626 0%, var(--obsidian) 55%),
              linear-gradient(180deg, #0e0c15 0%, var(--obsidian) 60%, #05060a 100%);
  color: var(--text);
  font-family: "Microsoft YaHei", "PingFang SC", "Noto Sans SC", sans-serif;
  overflow-x: hidden;
}
#app { min-height: 100vh; }
button { font-family: inherit; }
.dim { color: var(--text-dim); }
/* ---------- 按钮 ---------- */
.btn {
  display: inline-block; padding: 10px 22px; cursor: pointer;
  color: var(--gold-bright); background: linear-gradient(180deg, #2a2418, #1c1810);
  border: 1px solid var(--gold); border-radius: 8px;
  letter-spacing: 2px; font-size: 16px; transition: all .15s;
}
.btn:hover { background: linear-gradient(180deg, #3a3122, #262013); box-shadow: 0 0 12px rgba(212,169,78,.35); }
.btn.big { font-size: 19px; padding: 13px 34px; }
.btn.mini { font-size: 13px; padding: 5px 10px; letter-spacing: 1px; border-radius: 6px; }
.btn.dim { opacity: .45; cursor: not-allowed; }
.clickable { cursor: pointer; }
/* ---------- 大厅 ---------- */
.lobby { display: flex; flex-direction: column; align-items: center; padding: 60px 16px 40px; gap: 22px; }
.title-glow {
  font-size: 74px; font-weight: 900; letter-spacing: 18px; text-indent: 18px;
  background: linear-gradient(180deg, #ffe9b0 0%, var(--gold) 45%, #8a6420 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  text-shadow: 0 0 34px rgba(212,169,78,.35);
  animation: titlePulse 3s ease-in-out infinite;
}
@keyframes titlePulse { 50% { text-shadow: 0 0 60px rgba(255,122,60,.5); } }
.subtitle { color: var(--text-dim); letter-spacing: 4px; font-size: 14px; }
.lobby-classes { display: flex; gap: 26px; margin-top: 10px; flex-wrap: wrap; justify-content: center; }
.cls-card {
  width: 230px; padding: 22px 18px; text-align: center; cursor: pointer;
  background: linear-gradient(180deg, var(--panel2), var(--panel));
  border: 2px solid var(--line); border-radius: 14px; transition: all .15s;
}
.cls-card:hover { border-color: var(--gold); transform: translateY(-3px); }
.cls-card.picked { border-color: var(--ember); box-shadow: 0 0 18px rgba(255,122,60,.4); }
.cls-emoji { font-size: 52px; }
.cls-name { font-size: 22px; color: var(--gold-bright); margin: 8px 0 6px; letter-spacing: 4px; }
.cls-desc { font-size: 13px; color: var(--text-dim); min-height: 36px; }
.cls-hp { margin-top: 8px; color: var(--ember); font-weight: bold; }
.lobby-seed { color: var(--text-dim); font-size: 15px; }
.lobby-seed input {
  background: var(--panel); border: 1px solid var(--line); color: var(--gold-bright);
  padding: 8px 12px; border-radius: 8px; width: 220px; font-size: 15px; outline: none;
}
.lobby-seed input:focus { border-color: var(--gold); }
.lobby-btns { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }
.lobby-stats { color: var(--text-dim); font-size: 14px; border-top: 1px solid var(--line); padding-top: 14px; letter-spacing: 1px; }
.lobby-help { color: #5f6378; font-size: 12px; max-width: 640px; text-align: center; line-height: 1.8; }
/* ---------- HUD ---------- */
.hud {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  padding: 10px 16px; background: rgba(10,12,18,.9);
  border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50;
}
.hud-act { color: var(--gold-bright); font-weight: bold; letter-spacing: 2px; }
.hud-seed { color: var(--text-dim); font-size: 12px; }
.hud-gold { color: var(--gold-bright); }
.hud-hp { color: var(--ember); }
.hud-relics { display: flex; gap: 4px; flex-wrap: wrap; max-width: 300px; }
.relic { font-size: 20px; cursor: help; filter: drop-shadow(0 0 4px rgba(212,169,78,.5)); }
.hud-potions { display: flex; gap: 6px; }
.potion {
  width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 18px; border: 1px solid var(--line); background: var(--panel);
}
.potion.has { border-color: var(--gold); cursor: pointer; }
.potion.has:hover { box-shadow: 0 0 10px rgba(212,169,78,.5); }
.potion.empty { color: var(--line); }
/* ---------- 地图屏 ---------- */
.map-screen { display: flex; flex-direction: column; height: 100vh; }
.map-title { text-align: center; padding: 10px; color: var(--text-dim); letter-spacing: 3px; font-size: 14px; }
.act-banner { text-align: center; color: var(--ember); font-size: 18px; letter-spacing: 6px; padding: 4px; text-shadow: 0 0 12px rgba(255,122,60,.5); }
.map-scroll { flex: 1; overflow-y: auto; position: relative; }
.map-canvas { position: relative; margin: 0 auto; }
.map-lines { position: absolute; left: 0; top: 0; }
.map-node {
  position: absolute; width: 52px; height: 52px; border-radius: 50%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: var(--panel2); border: 2px solid var(--line); font-size: 20px;
  transform: translateZ(0); user-select: none;
}
.map-node .node-label { font-size: 10px; color: var(--text-dim); }
.map-node.done { opacity: .35; border-color: #2a2d3d; }
.map-node.open {
  border-color: var(--gold-bright); cursor: pointer;
  box-shadow: 0 0 16px rgba(240,201,106,.6); animation: nodeGlow 1.6s ease-in-out infinite;
}
@keyframes nodeGlow { 50% { box-shadow: 0 0 28px rgba(255,122,60,.75); } }
.map-node.open:hover { transform: scale(1.12); }
.map-node.future { opacity: .55; }
.map-node.boss-node, .map-node[data-node$="boss"] { width: 64px; height: 64px; }
.floor-tag { position: absolute; color: #55597a; font-size: 12px; letter-spacing: 1px; }
/* ---------- 战斗屏 ---------- */
.battle-screen { display: flex; flex-direction: column; min-height: 100vh; padding-bottom: 255px; }
.battle-stage {
  display: flex; align-items: flex-end; justify-content: space-around;
  padding: 26px 16px 12px; gap: 10px; flex: 1; flex-wrap: wrap;
}
.enemy-area { display: flex; gap: 22px; flex-wrap: wrap; justify-content: center; }
.enemy-card {
  width: 190px; padding: 12px; text-align: center; position: relative;
  background: linear-gradient(180deg, #221733 0%, #14101d 100%);
  border: 1px solid #443355; border-radius: 14px;
}
.enemy-card.elite { border-color: #7a5a99; box-shadow: 0 0 14px rgba(150,90,200,.25); }
.enemy-card.boss { width: 230px; border-color: #993a3a; box-shadow: 0 0 22px rgba(224,82,82,.3); }
.enemy-card.dead { opacity: .25; filter: grayscale(1); }
.enemy-card.targetable { border-color: var(--ember); cursor: crosshair; box-shadow: 0 0 18px rgba(255,122,60,.6); }
.enemy-intent { font-size: 13px; color: #c9b8e8; min-height: 34px; background: rgba(0,0,0,.35); border-radius: 8px; padding: 5px; margin-bottom: 6px; }
.enemy-intent b { color: var(--ember); font-size: 15px; }
.enemy-emoji { font-size: 64px; line-height: 1.15; filter: drop-shadow(0 4px 10px rgba(0,0,0,.7)); }
.enemy-card.boss .enemy-emoji { font-size: 88px; }
.enemy-name { color: #cfc6dd; font-size: 15px; margin: 6px 0 4px; }
.tag-boss { color: var(--red); font-size: 11px; border: 1px solid var(--red); border-radius: 4px; padding: 0 4px; }
.hpbar { height: 9px; background: #0a0a0f; border-radius: 5px; overflow: hidden; border: 1px solid #333; }
.hpbar-fill { height: 100%; background: linear-gradient(90deg, #b3273a, var(--ember)); transition: width .3s; }
.enemy-hp { font-size: 13px; color: var(--text-dim); margin-top: 4px; }
.block-badge { color: #9fc6ff; font-weight: bold; }
.enemy-status, .player-status { min-height: 20px; margin-top: 5px; }
.chip { display: inline-block; font-size: 11px; padding: 1px 6px; margin: 2px; border-radius: 8px; background: #23283a; border: 1px solid var(--line); }
.chip.c-strength { color: #ff9c6a; } .chip.c-weak { color: #b48ad6; } .chip.c-vulnerable { color: #e0c252; }
.chip.c-burn { color: var(--ember); } .chip.c-poison { color: #8fd66a; } .chip.c-thorns { color: #9fc6ff; } .chip.c-regen { color: #6ee7b7; }
.player-area {
  width: 210px; text-align: center; padding: 14px; position: relative;
  background: linear-gradient(180deg, #1b2333 0%, #10141d 100%);
  border: 1px solid #2c4a6e; border-radius: 14px;
}
.player-emoji { font-size: 68px; filter: drop-shadow(0 4px 10px rgba(0,0,0,.7)); }
.player-name { color: var(--gold-bright); margin: 6px 0 4px; font-size: 16px; }
.player-hp { font-size: 13px; color: var(--text-dim); margin-top: 4px; }
.targeting-tip { text-align: center; color: var(--ember); padding: 6px; letter-spacing: 2px; animation: nodeGlow 1.2s infinite; }
.battle-hud { display: flex; align-items: center; justify-content: center; gap: 14px; padding: 8px 0; position: relative; z-index: 45; }
.energy-orb {
  width: 62px; height: 62px; border-radius: 50%; position: relative;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: radial-gradient(circle at 35% 30%, #ffe9b0, var(--gold) 45%, #6b4c14 100%);
  box-shadow: 0 0 22px rgba(240,201,106,.55); color: #221a06; font-weight: 900;
}
.energy-orb span { font-size: 24px; }
/* ---------- 手牌扇形 ---------- */
.hand {
  position: fixed; bottom: -4px; left: 0; right: 0; height: 226px;
  display: flex; justify-content: center; align-items: flex-end;
  pointer-events: none; z-index: 40;
}
.hand-card { pointer-events: auto; margin: 0 -18px; transform-origin: 50% 120%; transition: transform .15s, box-shadow .15s; }
.hand-card.playable { box-shadow: 0 0 14px rgba(240,201,106,.45); animation: cardBreath 2.2s ease-in-out infinite; }
@keyframes cardBreath { 50% { box-shadow: 0 0 24px rgba(255,122,60,.65); } }
.hand-card.playable:hover { transform: translateY(-34px) scale(1.07) rotate(0deg) !important; z-index: 99 !important; box-shadow: 0 0 26px rgba(255,122,60,.6); animation: none; }
.hand-card.unplayable { filter: grayscale(.85) brightness(.65); opacity: .55; }
.hand-card.dimmed { filter: grayscale(.6) brightness(.7); }
/* ---------- 卡牌（鎏金符纸） ---------- */
.card {
  width: 148px; height: 200px; border-radius: 10px; position: relative; flex-shrink: 0;
  background: linear-gradient(165deg, #2b2416 0%, #1c1810 60%, #241d12 100%);
  border: 2px solid #6a5a34; color: var(--text);
  box-shadow: 0 4px 14px rgba(0,0,0,.55); padding: 10px 9px 8px;
  display: flex; flex-direction: column;
}
.card.r-common { border-color: #3f8f85; }
.card.r-uncommon { border-color: var(--gold); }
.card.r-rare { border-color: var(--red); box-shadow: 0 4px 14px rgba(0,0,0,.55), 0 0 12px rgba(224,82,82,.25); }
.card-clickable, .card.clickable { cursor: pointer; }
.card.clickable:hover { transform: translateY(-6px); box-shadow: 0 8px 20px rgba(0,0,0,.6), 0 0 14px rgba(240,201,106,.4); }
.card-cost {
  position: absolute; top: -10px; left: -10px; width: 34px; height: 34px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #ffe9b0, var(--gold) 50%, #6b4c14);
  color: #221a06; font-weight: 900; font-size: 18px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,.6);
}
.card-name { text-align: center; color: var(--gold-bright); font-size: 16px; font-weight: bold; letter-spacing: 2px; margin-top: 8px; }
.card-type { text-align: center; font-size: 10px; color: var(--text-dim); border: 1px solid var(--line); border-radius: 8px; width: fit-content; margin: 5px auto; padding: 1px 8px; }
.card-desc { font-size: 12px; line-height: 1.55; text-align: center; color: #cfc9ba; flex: 1; display: flex; align-items: center; justify-content: center; }
/* ---------- 浮动数字 / toast ---------- */
.float-text {
  position: absolute; left: 50%; top: 30%; transform: translateX(-50%);
  font-size: 22px; font-weight: 900; pointer-events: none; z-index: 60;
  text-shadow: 0 2px 6px rgba(0,0,0,.9); animation: floatUp 1s ease-out forwards;
}
.float-text.f-dmg { color: #ff6b5e; }
.float-text.f-block { color: #9fc6ff; font-size: 18px; }
.float-text.f-heal { color: #6ee7b7; }
.float-text.f-buff { color: var(--gold-bright); font-size: 16px; }
.float-text.f-debuff { color: #b48ad6; font-size: 16px; }
@keyframes floatUp { 0% { opacity: 0; transform: translate(-50%, 14px) scale(.7); } 15% { opacity: 1; transform: translate(-50%, 0) scale(1.15); } 100% { opacity: 0; transform: translate(-50%, -44px) scale(1); } }
#toasts { position: fixed; top: 64px; left: 0; right: 0; display: flex; flex-direction: column; align-items: center; gap: 8px; z-index: 200; pointer-events: none; }
.toast {
  background: rgba(20,16,10,.94); border: 1px solid var(--gold); color: var(--gold-bright);
  padding: 9px 22px; border-radius: 10px; font-size: 14px; letter-spacing: 1px;
  opacity: 0; transform: translateY(-12px); transition: all .3s; max-width: 86vw;
}
.toast.show { opacity: 1; transform: translateY(0); }
/* ---------- 弹窗 ---------- */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(4,5,9,.82); z-index: 150;
  display: flex; align-items: center; justify-content: center; padding: 16px;
}
.modal-box {
  background: linear-gradient(180deg, var(--panel2), var(--panel));
  border: 1px solid var(--gold); border-radius: 14px; padding: 20px;
  max-width: 92vw; max-height: 88vh; overflow-y: auto;
  box-shadow: 0 0 40px rgba(212,169,78,.25);
}
.modal-title { color: var(--gold-bright); letter-spacing: 2px; margin-bottom: 12px; }
.modal-card { transform: scale(1.25); margin: 18px auto; }
.modal-btns { display: flex; gap: 14px; justify-content: center; margin-top: 16px; }
.deck-grid { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; max-width: 760px; }
.deck-grid .card.dimmed { opacity: .4; }
/* ---------- 通用面板 / 奖励 / 篝火 / 事件 / 结算 ---------- */
.panel {
  background: linear-gradient(180deg, var(--panel2), var(--panel));
  border: 1px solid var(--gold); border-radius: 14px; padding: 18px 26px; margin: 0 auto;
  text-align: center; box-shadow: 0 0 24px rgba(0,0,0,.5);
}
.panel-title { font-size: 26px; color: var(--gold-bright); letter-spacing: 6px; text-align: center; padding: 10px 0; text-shadow: 0 0 14px rgba(212,169,78,.4); }
.reward-screen, .camp-screen, .event-screen { padding: 40px 16px; display: flex; flex-direction: column; gap: 18px; align-items: center; }
.reward-gold { color: var(--gold-bright); font-size: 20px; padding: 6px; }
.reward-relic { color: var(--teal); font-size: 15px; padding: 4px; }
.reward-sub { color: var(--text-dim); letter-spacing: 2px; padding: 6px 0 2px; }
.card-row { display: flex; gap: 22px; flex-wrap: wrap; justify-content: center; align-items: flex-start; }
.skip-card {
  width: 148px; height: 200px; border: 2px dashed var(--line); border-radius: 10px;
  display: flex; align-items: center; justify-content: center; color: var(--text-dim);
}
.skip-card:hover { border-color: var(--gold); color: var(--gold-bright); }
.potion-drop { color: var(--teal); border: 1px solid #2c6a62; padding: 10px 18px; border-radius: 10px; background: rgba(20,40,38,.5); }
.potion-drop:hover { box-shadow: 0 0 12px rgba(79,210,194,.4); }
.campfire-emoji { font-size: 80px; filter: drop-shadow(0 0 24px rgba(255,122,60,.6)); animation: titlePulse 2.5s infinite; }
.event-emoji { font-size: 84px; }
.event-desc { max-width: 620px; text-align: center; color: #bdb6a6; line-height: 1.9; background: var(--panel); border: 1px solid var(--line); padding: 18px 22px; border-radius: 12px; }
.event-msg { max-width: 620px; color: var(--gold-bright); line-height: 1.8; text-align: center; padding: 10px; }
.event-opts { display: flex; flex-direction: column; gap: 12px; width: min(480px, 90vw); }
.event-opt { width: 100%; text-align: left; }
/* ---------- 商店 ---------- */
.shop-screen { padding: 0 0 40px; }
.shop-relics { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; padding: 8px 16px; }
.shop-relic {
  width: 230px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
  padding: 12px; cursor: pointer; transition: all .15s; font-size: 13px;
}
.shop-relic:hover { border-color: var(--gold); }
.shop-relic.poor { opacity: .5; cursor: not-allowed; }
.shop-relic .r-emoji { font-size: 26px; margin-right: 6px; }
.shop-relic .r-name { color: var(--gold-bright); font-weight: bold; }
.shop-relic .r-desc { display: block; color: var(--text-dim); margin-top: 6px; min-height: 34px; line-height: 1.5; }
.price-tag { color: var(--gold-bright); font-weight: bold; text-align: center; display: block; margin-top: 6px; }
.price-tag.poor { color: var(--red); }
/* ---------- 结算屏 ---------- */
.end-screen { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; padding: 30px 16px; }
.end-emoji { font-size: 110px; }
.end-screen.win .end-emoji { filter: drop-shadow(0 0 30px rgba(240,201,106,.7)); }
.end-screen.dead .end-emoji { filter: drop-shadow(0 0 30px rgba(120,120,140,.5)); }
.end-title { font-size: 40px; letter-spacing: 10px; color: var(--gold-bright); text-shadow: 0 0 24px rgba(212,169,78,.5); }
.end-screen.dead .end-title { color: #9aa0b4; text-shadow: none; }
.end-sub { color: var(--text-dim); letter-spacing: 2px; }
.end-stats { display: grid; grid-template-columns: repeat(3, auto); gap: 10px 34px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 18px 30px; font-size: 15px; }
.end-history { color: var(--text-dim); font-size: 13px; }
/* ---------- 移动端 ---------- */
@media (max-width: 720px) {
  .title-glow { font-size: 46px; letter-spacing: 10px; text-indent: 10px; }
  .card { width: 116px; height: 164px; }
  .card-name { font-size: 13px; }
  .card-desc { font-size: 10.5px; }
  .skip-card { width: 116px; height: 164px; }
  .hand { height: 178px; }
  .enemy-card { width: 150px; }
  .enemy-emoji { font-size: 48px; }
  .enemy-card.boss .enemy-emoji { font-size: 64px; }
  .hud { gap: 8px; font-size: 13px; }
  .hud-relics { max-width: 160px; }
  .end-stats { grid-template-columns: repeat(2, auto); }
  .map-node { width: 46px; height: 46px; font-size: 17px; }
}
/* ---------- v2：大厅扩展 ---------- */
.lobby-top { position: fixed; top: 12px; right: 14px; display: flex; gap: 8px; z-index: 90; }
.lobby-asc { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; justify-content: center; }
.asc-label { color: var(--text-dim); font-size: 14px; letter-spacing: 1px; }
.asc-btn { min-width: 46px; }
.asc-btn.picked { border-color: var(--ember); color: var(--ember); box-shadow: 0 0 10px rgba(255,122,60,.4); }
.cls-card.locked { opacity: .55; }
.cls-card.locked:hover { border-color: var(--line); transform: none; }
.lock-hint { color: var(--red); font-size: 12px; }
.hud-asc { color: var(--ember); font-weight: bold; border: 1px solid var(--ember); border-radius: 6px; padding: 0 6px; font-size: 12px; }
.hud-daily { color: var(--teal); font-size: 12px; border: 1px solid #2c6a62; border-radius: 6px; padding: 0 6px; }
/* ---------- v2：状态徽章 / 二阶段 ---------- */
.chip .chip-n { margin-left: 3px; font-weight: 900; }
.chip.c-stun { color: #c9b8e8; border-color: #7a5a99; }
.chip.c-inkmark { color: #6a7bd6; border-color: #3f4f99; }
.chip.c-pendingEnergy { color: #ffd76a; }
.tag-p2 { color: var(--ember); font-size: 11px; border: 1px solid var(--ember); border-radius: 4px; padding: 0 4px; animation: nodeGlow 1.4s infinite; cursor: help; }
/* ---------- v2：战斗日志 ---------- */
.battle-log {
  position: fixed; right: 10px; top: 56px; width: 250px; max-height: 46vh; overflow-y: auto;
  background: rgba(8,10,15,.92); border: 1px solid var(--line); border-radius: 10px;
  padding: 8px 10px; z-index: 55; font-size: 12px; color: var(--text-dim);
}
.battle-log .bl-title { color: var(--gold); text-align: center; letter-spacing: 1px; margin-bottom: 6px; font-size: 11px; }
.battle-log .bl-line { padding: 2px 0; border-bottom: 1px dashed #23263a; line-height: 1.5; }
/* ---------- v2：能量脉冲 / 卡牌飞行动画 ---------- */
.energy-orb.pulse { animation: orbPulse .45s ease-out; }
@keyframes orbPulse { 30% { transform: scale(1.18); box-shadow: 0 0 34px rgba(240,201,106,.9); } }
.fly-card {
  position: fixed; width: 44px; height: 44px; border-radius: 8px; z-index: 130;
  background: linear-gradient(165deg, #2b2416, #1c1810); border: 2px solid var(--gold);
  display: flex; align-items: center; justify-content: center; font-size: 20px;
  transition: transform .34s ease-in, opacity .34s ease-in; pointer-events: none;
  box-shadow: 0 0 14px rgba(240,201,106,.5);
}
/* ---------- v2：受击反馈 ---------- */
.hit-flash { animation: hitFlash .36s ease-out; }
@keyframes hitFlash {
  0% { filter: none; transform: translateX(0); }
  25% { filter: brightness(2) sepia(1) hue-rotate(-45deg); transform: translateX(-7px); }
  55% { transform: translateX(6px); }
  100% { filter: none; transform: translateX(0); }
}
#vignette {
  position: fixed; inset: 0; pointer-events: none; z-index: 120; opacity: 0;
  box-shadow: inset 0 0 120px 40px rgba(200,30,30,.55);
}
#vignette.on { animation: vignetteFlash .36s ease-out; }
@keyframes vignetteFlash { 20% { opacity: 1; } 100% { opacity: 0; } }
/* ---------- v2：Boss 登场 / 二阶段横幅 ---------- */
.boss-banner {
  position: fixed; left: 0; right: 0; top: 34%; text-align: center; z-index: 140;
  opacity: 0; transform: translateX(-60px); transition: all .35s ease-out; pointer-events: none;
}
.boss-banner.show { opacity: 1; transform: translateX(0); }
.boss-banner .bb-sub { color: var(--red); letter-spacing: 8px; font-size: 15px; }
.boss-banner .bb-name {
  font-size: 56px; font-weight: 900; letter-spacing: 14px; color: var(--gold-bright);
  text-shadow: 0 0 30px rgba(224,82,82,.7), 0 4px 10px rgba(0,0,0,.8);
}
.phase2-banner {
  position: fixed; left: 0; right: 0; top: 30%; text-align: center; z-index: 140;
  opacity: 0; transform: scale(.8); transition: all .35s ease-out; pointer-events: none;
  background: rgba(60,8,8,.75); padding: 18px 0;
  border-top: 1px solid var(--ember); border-bottom: 1px solid var(--ember);
}
.phase2-banner.show { opacity: 1; transform: scale(1); }
.phase2-banner .pb-line { color: var(--ember); letter-spacing: 10px; font-size: 16px; }
.phase2-banner .pb-name { color: var(--gold-bright); font-size: 34px; font-weight: 900; letter-spacing: 8px; margin-top: 6px; }
/* ---------- v2：地图涟漪 / tooltip ---------- */
.map-node.open::after {
  content: ''; position: absolute; inset: -6px; border-radius: 50%;
  border: 2px solid rgba(240,201,106,.7); animation: nodeRipple 1.8s ease-out infinite; pointer-events: none;
}
@keyframes nodeRipple { 0% { transform: scale(.9); opacity: .9; } 100% { transform: scale(1.45); opacity: 0; } }
.game-tip {
  position: fixed; display: none; max-width: 280px; z-index: 300; pointer-events: none;
  background: rgba(12,14,20,.96); border: 1px solid var(--gold); border-radius: 8px;
  padding: 8px 12px; font-size: 12px; line-height: 1.6; color: var(--text);
  box-shadow: 0 4px 18px rgba(0,0,0,.6);
}
/* ---------- v2：诅咒牌 ---------- */
.card.curse-card { border-color: #6b4a99; background: linear-gradient(165deg, #1c1426 0%, #120d18 60%, #1a1024 100%); }
.card.curse-card .card-name { color: #b48ad6; }
/* ---------- v2：评级徽章 / 结算 ---------- */
.rating-badge {
  width: 92px; height: 92px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 52px; font-weight: 900; border: 3px solid var(--gold); color: var(--gold-bright);
  background: radial-gradient(circle at 35% 30%, #2a2418, #12100a);
  box-shadow: 0 0 26px rgba(212,169,78,.4);
}
.rating-badge.r-S { color: #ffe9b0; border-color: #ffe9b0; box-shadow: 0 0 40px rgba(255,233,176,.75); animation: titlePulse 2s infinite; }
.rating-badge.r-A { color: var(--gold-bright); }
.rating-badge.r-B { color: var(--teal); border-color: var(--teal); box-shadow: 0 0 20px rgba(79,210,194,.4); }
.rating-badge.r-C { color: #9aa0b4; border-color: #9aa0b4; }
.rating-badge.r-D { color: var(--red); border-color: var(--red); box-shadow: 0 0 20px rgba(224,82,82,.35); }
.end-unlocks { color: var(--teal); letter-spacing: 1px; border: 1px dashed #2c6a62; border-radius: 10px; padding: 8px 20px; }
.daily-note { color: var(--teal); font-size: 14px; margin-top: 8px; }
/* ---------- v2：图鉴屏 ---------- */
.codex-screen { padding: 30px 16px 60px; display: flex; flex-direction: column; gap: 14px; align-items: center; }
.codex-body { display: flex; flex-direction: column; gap: 22px; width: min(1100px, 96vw); }
.codex-sec-title { color: var(--gold); letter-spacing: 3px; margin-bottom: 8px; text-align: center; }
.codex-grid { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.codex-cell {
  width: 128px; min-height: 74px; background: var(--panel); border: 1px solid var(--line);
  border-radius: 10px; padding: 8px; text-align: center; cursor: default;
}
.codex-cell .cx-emoji { font-size: 26px; }
.codex-cell .cx-name { color: var(--gold-bright); font-size: 13px; margin-top: 3px; }
.codex-cell .cx-sub { color: var(--text-dim); font-size: 11px; margin-top: 2px; }
.codex-cell.unknown { opacity: .5; border-style: dashed; }
.codex-cell.curse-card { border-color: #6b4a99; }
/* ---------- v2：成就屏 ---------- */
.ach-screen { padding: 30px 16px 60px; display: flex; flex-direction: column; gap: 18px; align-items: center; }
.ach-wall { display: grid; grid-template-columns: repeat(4, minmax(200px, 240px)); gap: 12px; justify-content: center; }
.ach-cell { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 14px; text-align: center; opacity: .6; }
.ach-cell.got { opacity: 1; border-color: var(--gold); box-shadow: 0 0 16px rgba(212,169,78,.3); background: linear-gradient(180deg, #241d10, var(--panel)); }
.ach-cell .ach-name { color: var(--gold-bright); font-size: 15px; letter-spacing: 1px; }
.ach-cell:not(.got) .ach-name { color: var(--text-dim); }
.ach-cell .ach-desc { color: var(--text-dim); font-size: 12px; margin-top: 6px; line-height: 1.5; }
@media (max-width: 720px) {
  .ach-wall { grid-template-columns: repeat(2, minmax(140px, 1fr)); }
  .battle-log { width: 200px; top: 100px; }
  .boss-banner .bb-name { font-size: 34px; letter-spacing: 8px; }
  .codex-cell { width: 104px; }
}