/* Arena — shared battle view (bv1). Extracted from campaign.css .bstage (behind-the-hero camera). Used by the Siege Climb for now. */
.bv-stage { position: relative; width: 100%; height: 100%; min-height: 420px; overflow: hidden; color: #fbe7bf; background: #1a120a; font-family: "Crimson", Georgia, serif; user-select: none; }
.bv-bg { position: absolute; inset: -2%; background: center bottom / cover no-repeat; transform: scale(1.04); transition: transform 1.6s ease-out; }
.bv-stage.entering .bv-bg { transform: scale(1.12); }
.bv-air { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(180deg, rgba(0,0,0,.34), transparent 22%, transparent 70%, rgba(0,0,0,.22)); }
.bv-units { position: absolute; inset: 0; }
.bv-front { position: absolute; left: 0; right: 0; bottom: 0; height: 12%; pointer-events: none; background: linear-gradient(180deg, transparent, rgba(10,6,2,.45)); z-index: 40; }
.bv-unit { position: absolute; transition: left .7s ease-in-out, bottom .7s ease-in-out, height .7s, width .7s, opacity .9s, transform .9s ease-out, filter .6s; }
.bv-stage.entering .bv-unit.hero { opacity: 0; transform: translateY(22%) scale(1.06); }
.bv-stage.entering .bv-unit.foe { opacity: 0; transform: translateY(-3%) scale(.86); }
.bv-move, .bv-body { position: absolute; inset: 0; transform-origin: 50% 100%; }
.bv-art { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; object-position: bottom; pointer-events: none; }
.bv-shadow { position: absolute; left: 8%; right: 8%; bottom: -3%; height: 7%; border-radius: 50%; background: radial-gradient(ellipse at 50% 50%, rgba(0,0,0,.62), rgba(0,0,0,.25) 55%, transparent 72%); }
.bv-unit.hero .bv-shadow { left: 2%; right: 2%; bottom: -4%; height: 9%; background: radial-gradient(ellipse at 50% 50%, rgba(0,0,0,.7), rgba(0,0,0,.3) 55%, transparent 72%); }
.bv-unit.fly .bv-shadow { bottom: -60%; opacity: .45; transform: scale(.55); }
.bv-unit.hero .bv-art { filter: drop-shadow(0 0 1px rgba(0,0,0,.45)) saturate(.92) brightness(.93) contrast(1.03); }
.bv-unit.hero.partner .bv-body { filter: brightness(.82) saturate(.88); }
.bv-unit.hero.fb-front .bv-art { transform: scaleX(-1); filter: brightness(.38) saturate(.5) contrast(1.1); }
.bv-stage[data-field="ruined_keep"] .bv-unit .bv-art { filter: saturate(.9) sepia(.12) brightness(.9); }
.bv-stage[data-field="keep_night"] .bv-unit .bv-art { filter: saturate(.75) brightness(.78) hue-rotate(-8deg); }
.bv-stage[data-field="hollow_hall"] .bv-unit .bv-art, .bv-stage[data-field="frost_hall"] .bv-unit .bv-art { filter: saturate(.72) brightness(.74) contrast(1.05); }
.bv-stage[data-field="dragon_lair"] .bv-unit .bv-art { filter: saturate(.95) sepia(.18) brightness(.82) contrast(1.05); }
.bv-unit.acting { z-index: 35 !important; }
.bv-unit.hero.acting .bv-body { filter: brightness(1.12) saturate(1.05) drop-shadow(0 0 10px rgba(255,222,150,.55)); }
.bv-unit.foe.acting { z-index: 27 !important; }
.bv-unit.hero.down .bv-body { filter: grayscale(1) brightness(.6); transform: translateY(10%) scaleY(.62) rotate(-11deg); opacity: .78; }
.bv-unit.foe.dead { opacity: 0; pointer-events: none; }
.bv-tag { position: absolute; left: 50%; bottom: calc(100% + 4px); transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 2px; pointer-events: none; transition: opacity .4s; }
.bv-unit.tag-in .bv-tag { bottom: auto; top: var(--tagTop); }
.bv-tag b { font: 700 .86rem "Crimson", serif; color: #fff3d6; text-shadow: 0 1px 2px #000, 0 0 6px rgba(0,0,0,.7); white-space: nowrap; }
.bv-unit.hero.front .bv-tag b { padding: 2px 12px; border-radius: 6px; color: #3a220e; text-shadow: none; font-size: .95rem; background: linear-gradient(180deg, #fbeccb, #e2c58c); border: 2px solid #8a6230; }
.bv-hp { position: relative; display: block; width: min(130px, 90%); min-width: 60px; height: 11px; border-radius: 6px; background: #2a160c; border: 2px solid #c9a052; box-shadow: 0 2px 4px rgba(0,0,0,.6); overflow: hidden; }
.bv-hp i { position: absolute; left: 0; top: 0; bottom: 0; width: 100%; background: linear-gradient(180deg, #8fe07a, #3a9a3a); transition: width .35s ease-out; }
.bv-unit.foe .bv-hp i { background: linear-gradient(180deg, #ee7a5a, #a8261c); }
.bv-unit.hero.front .bv-hp { width: 150px; height: 13px; }
.bv-unit.foe.boss .bv-tag b { font-size: 1.05rem; }
.bv-unit.foe.boss .bv-hp { width: min(210px, 80%); height: 14px; }
.bv-unit.down .bv-tag, .bv-unit.dead .bv-tag, .bv-unit.ko .bv-tag { opacity: 0; }
.bv-fx { position: absolute; inset: 0; pointer-events: none; z-index: 50; }
.bv-dmg { position: absolute; transform: translate(-50%, 0); font: 700 1.8rem "Cinzel Deco", Georgia, serif; color: #fff1c4; white-space: nowrap; pointer-events: none;
  text-shadow: 0 2px 0 #3a1a08, 0 0 8px rgba(0,0,0,.8); animation: bvDmg 1.3s ease-out forwards; }
.bv-dmg.big { color: #ffd84a; font-size: 2.3rem; }
.bv-dmg.hurt { color: #ff8a70; }
.bv-dmg.heal { color: #a9f5a0; font-size: 2rem; }
.bv-dmg.shield { color: #bfe0ff; font-size: 1.4rem; }
.bv-dmg.ko-stamp { font: 900 1.7rem "Cinzel Deco", Georgia, serif; color: #fff4dc; background: radial-gradient(circle at 40% 35%, #c8402c, #7e1a10 70%); padding: .1em .45em; border-radius: 40% 46% 42% 48%; border: 3px solid #e9c27a; }
@keyframes bvDmg { 0% { transform: translate(-50%, 12px) scale(.6); opacity: 0; } 15% { transform: translate(-50%, 0) scale(1.15); opacity: 1; } 70% { opacity: 1; } 100% { transform: translate(-50%, -30px) scale(1); opacity: 0; } }
.bv-proj { position: absolute; width: 0; height: 0; transform-origin: 0 0; }
.bv-proj.arrow::before, .bv-proj.arrow-foe::before { content: ""; position: absolute; left: -26px; top: -2px; width: 52px; height: 4px; border-radius: 2px; background: linear-gradient(90deg, #d8d0c0 0 14%, #6b4a2a 14% 86%, #cfd4da 86%); box-shadow: 0 0 4px rgba(0,0,0,.5); }
.bv-proj.arrow-foe::before { background: linear-gradient(90deg, #cfd4da 0 14%, #3a3228 14% 86%, #9bff5a 86%); }
.bv-proj.orb::before, .bv-proj.bolt-foe::before { content: ""; position: absolute; left: -16px; top: -16px; width: 32px; height: 32px; border-radius: 50%;
  background: radial-gradient(circle, #fff 0 18%, #c9b8ff 34%, rgba(120,90,255,.6) 56%, transparent 72%); box-shadow: 0 0 22px 8px rgba(150,120,255,.55); }
.bv-proj.bolt-foe::before { background: radial-gradient(circle, #fff 0 16%, #d7a8ff 32%, rgba(170,60,220,.6) 55%, transparent 72%); box-shadow: 0 0 20px 6px rgba(190,90,255,.5); }
.bv-burst { position: absolute; width: 0; height: 0; transform: scale(var(--bs, 1)); }
.bv-burst::before { content: ""; position: absolute; left: -60px; top: -60px; width: 120px; height: 120px; border-radius: 50%; animation: bvBurst .5s ease-out forwards; animation-duration: inherit; }
.bv-burst.slash::before { background: none; border-top: 6px solid #fff6e0; border-radius: 50% 50% 0 0; box-shadow: 0 -4px 14px rgba(255,240,200,.8); }
.bv-burst.magic::before { background: radial-gradient(circle, rgba(255,255,255,.95) 0 12%, rgba(190,170,255,.8) 28%, rgba(120,90,255,.3) 50%, transparent 68%); }
.bv-burst.gold::before { background: radial-gradient(circle, rgba(255,250,220,.95) 0 14%, rgba(255,210,90,.75) 32%, rgba(255,170,40,.25) 52%, transparent 70%); }
.bv-burst.heal::before { background: radial-gradient(circle, rgba(240,255,240,.95) 0 12%, rgba(140,240,160,.7) 30%, rgba(60,200,120,.25) 52%, transparent 70%); }
.bv-burst.ward::before { background: radial-gradient(circle, rgba(230,245,255,.95) 0 12%, rgba(140,190,255,.7) 30%, rgba(60,120,255,.25) 52%, transparent 70%); }
@keyframes bvBurst { from { transform: scale(.3) rotate(-35deg); opacity: 1; } to { transform: scale(1.35) rotate(-20deg); opacity: 0; } }
.bv-top { position: absolute; left: 0; right: 0; top: 0; z-index: 60; display: flex; align-items: center; gap: 8px; padding: 10px 12px; }
.bv-title { font: 700 1rem "Cinzel Deco", serif; padding: 6px 12px; border-radius: 8px; color: #3a220e; background: linear-gradient(180deg, #fbeccb, #e2c58c); border: 2px solid #8a6230; box-shadow: 0 3px 8px rgba(0,0,0,.5); max-width: 58%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bv-round { color: #fff3d6; text-shadow: 0 1px 3px #000; font-weight: 700; white-space: nowrap; }
.bv-ctrl { margin-left: auto; display: flex; gap: 6px; }
.bv-btn { font: 700 1rem "Crimson", serif; min-width: 52px; min-height: 44px; padding: 6px 12px; border-radius: 10px; border: 2px solid #b8893a; color: #fbe7bf; background: linear-gradient(180deg, #8a5a33, #5e3a1c); box-shadow: 0 3px 0 #2d1b0b; cursor: pointer; }
.bv-btn:active { transform: translateY(2px); box-shadow: 0 1px 0 #2d1b0b; }
.bv-banner { position: absolute; left: 0; right: 0; top: 18%; z-index: 62; display: flex; justify-content: center; pointer-events: none; }
.bv-banner p { margin: 0; padding: 10px 40px; font: 700 2.2rem "Cinzel Deco", serif; color: #4a2a0c; background: linear-gradient(180deg, #fbeccb, #e2c58c); border: 3px solid #8a6230; border-radius: 10px; box-shadow: 0 8px 22px rgba(0,0,0,.55); animation: bvWin .5s cubic-bezier(.2,1.6,.4,1) both; }
.bv-banner p.lose { color: #fbe7bf; background: radial-gradient(circle at 35% 30%, #a8342c, #6a1410 70%); border-color: #e9c27a; }
.bv-banner p.hold { font-size: 1.8rem; }
@keyframes bvWin { from { transform: scale(.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.bv-caption { position: absolute; right: 12px; bottom: 14px; z-index: 60; max-width: min(56%, 520px); padding: 8px 16px; border-radius: 10px; font-size: 1.05rem; color: #3a220e; text-align: center;
  background: linear-gradient(180deg, #fbeccb, #e2c58c); border: 2px solid #8a6230; box-shadow: 0 4px 10px rgba(0,0,0,.45); opacity: 0; transition: opacity .2s; }
.bv-caption:empty { display: none; }
.bv-caption.show { opacity: 1; }
.bv-caption .back { color: #7a2a1e; }
.bv-stage.skipping .bv-unit, .bv-stage.skipping .bv-hp i { transition: none; }
.bv-dock { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 64; width: min(92%, 420px); display: flex; flex-direction: column; gap: 8px; }
.bv-dock:empty { display: none; }
.bv-stage[data-kind="scene"] .bv-caption { right: auto; left: 50%; transform: translateX(-50%); bottom: auto; top: 64px; max-width: 90%; }
/* scene props: chest / shrine / trap */
.bv-prop { position: absolute; z-index: 20; }
.bv-prop .p-base, .bv-prop .p-lid { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; object-position: bottom; filter: drop-shadow(0 10px 10px rgba(0,0,0,.55)); }
.bv-prop .p-lid { transform-origin: 50% 46%; transition: transform .6s cubic-bezier(.3,1.6,.5,1); }
.bv-prop.open .p-lid { transform: translateY(-26%) rotate(-14deg) scale(1.02); }
.bv-prop .p-glow { position: absolute; left: 10%; right: 10%; top: 25%; bottom: 15%; border-radius: 50%; opacity: 0; transition: opacity .6s; background: radial-gradient(ellipse at 50% 60%, rgba(255,230,140,.95), rgba(255,190,60,.35) 45%, transparent 70%); pointer-events: none; }
.bv-prop.open .p-glow, .bv-prop.lit .p-glow { opacity: 1; }
.bv-prop .p-glow.heal { background: radial-gradient(ellipse at 50% 45%, rgba(190,255,210,.95), rgba(90,220,150,.35) 45%, transparent 70%); }
.bv-prop .p-glow.trap { background: radial-gradient(ellipse at 50% 70%, rgba(255,120,90,.8), rgba(200,40,20,.3) 45%, transparent 70%); }
.bv-prop.sprung .p-glow.trap { opacity: 1; }
.bv-prop.sprung .p-base { animation: bvJolt .35s ease-out 2; }
.bv-prop.blocked .p-base { filter: drop-shadow(0 0 16px rgba(140,190,255,.9)) grayscale(.4); }
@keyframes bvJolt { 50% { transform: translateY(-6%); } }
.bv-prop .p-loot { position: absolute; left: 50%; bottom: 95%; transform: translate(-50%, 30px) scale(.4); opacity: 0; display: flex; flex-direction: column; align-items: center; gap: 2px; white-space: nowrap; transition: transform .6s cubic-bezier(.2,1.5,.4,1), opacity .4s; }
.bv-prop .p-loot.show { transform: translate(-50%, 0) scale(1); opacity: 1; }
.bv-prop .loot-ico { width: 84px; height: 84px; display: grid; place-items: center; font-size: 3.2rem; border-radius: 50%; background: radial-gradient(circle, rgba(255,245,210,.95), rgba(255,210,110,.6) 55%, transparent 72%); filter: drop-shadow(0 4px 8px rgba(0,0,0,.5)); }
.bv-prop .loot-ico img { width: 64px; height: 64px; object-fit: contain; }
.bv-prop .p-loot b { font: 700 1.2rem "Cinzel Deco", serif; color: #3a220e; background: linear-gradient(180deg, #fbeccb, #e2c58c); border: 2px solid #8a6230; border-radius: 8px; padding: 3px 12px; box-shadow: 0 4px 10px rgba(0,0,0,.45); }
.bv-prop .p-loot small { color: #fff3d6; text-shadow: 0 1px 3px #000; font-weight: 700; }
@media (max-width: 640px) {
  .bv-title { font-size: .86rem; padding: 5px 9px; }
  .bv-round { font-size: .88rem; }
  .bv-btn { min-width: 46px; min-height: 42px; padding: 5px 9px; font-size: .92rem; }
  .bv-dmg { font-size: 1.4rem; } .bv-dmg.big { font-size: 1.75rem; }
  .bv-caption { max-width: 64%; font-size: .88rem; padding: 6px 10px; line-height: 1.2; }
  .bv-tag b { font-size: .74rem; }
  .bv-unit.hero.front .bv-hp { width: 110px; }
  .bv-banner p { font-size: 1.7rem; padding: 8px 26px; }
}
