/* ==== Valhalla's Wrath — victory bonus (win with turns to spare) =========================================
   Owner request 2026-10-11 ("win sớm thì cộng điểm các turn còn thừa ... giống Candy Crush").
   Battle: a tap-to-skip layer over the whole screen (inside #fx-layer), the running coin tally in the empty
   battlefield, gold "+N" coin floats on the board. Result: one typographic line under the reward tiles.
   No boxes (game-ui-craft §1): label + numbers on a soft scrim only. Loaded last (index.html). */

#game .vb-layer { position: absolute; inset: 0; z-index: 3; pointer-events: auto; cursor: pointer; background: transparent;
  -webkit-tap-highlight-color: transparent; outline: none; }
#game .vb-tally { position: absolute; left: 50%; transform: translate(-50%, -50%); text-align: center; white-space: nowrap;
  width: max-content; padding: 10px 34px; background: radial-gradient(ellipse closest-side, #07100fcc, #07100f00); pointer-events: none; }
#game .vb-tally small { display: block; font: 700 12px/1.2 var(--ff-body); letter-spacing: .22em; text-transform: uppercase;
  color: #e3bf78; text-shadow: 0 1px 2px #000; }
#game .vb-tally b { display: inline-flex; align-items: center; gap: 6px; margin-top: 2px;
  font: 800 clamp(26px, calc(var(--u) * 8), 40px)/1 var(--ff-body); font-variant-numeric: tabular-nums;
  color: #ffe6a6; text-shadow: 0 2px 0 #4a2a0c, 0 0 14px #f0b45366, 0 2px 6px #000; }
#game .vb-tally b .ui-icon { width: .9em; height: .9em; filter: drop-shadow(0 2px 2px #000a); }
#game .vb-tally.vb-bump b { animation: vbBump .22s cubic-bezier(.2, .9, .3, 1.4); }
#game .vb-layer.vb-done .vb-tally b { color: #fff2c8; text-shadow: 0 2px 0 #4a2a0c, 0 0 22px #ffcf6f99, 0 2px 6px #000; }
#game .vb-skip { display: block; margin-top: 10px; pointer-events: none;
  font: 600 12px/1 var(--ff-body); letter-spacing: .2em; text-transform: uppercase; color: #f1e7cf;
  text-shadow: 0 1px 2px #000, 0 0 8px #000; animation: vbSkipPulse 1.6s ease-in-out infinite; }
#game .vb-layer.vb-instant .vb-skip, #game .vb-layer.vb-done .vb-skip { visibility: hidden; }
/* Input is over while the bonus runs: the skill tray rests (state shown, not written). */
#game #screen-battle.vb-on .b-skills { opacity: .45; filter: saturate(.6); transition: opacity .3s, filter .3s; }

#game .float.vb-coin { display: inline-flex; align-items: center; gap: 2px; z-index: 2;
  font: 800 clamp(16px, calc(var(--u) * 4.8), 22px)/1 var(--ff-body); font-variant-numeric: tabular-nums;
  color: #ffd877; text-shadow: 0 2px 0 #4a2a0c, 0 0 6px #000; }
#game .float.vb-coin .ui-icon { width: 1em; height: 1em; margin: 0; filter: drop-shadow(0 1px 1px #000); }

/* Result screen: one line of type under the reward tiles (no card). */
#game .valhalla-bonus { display: grid; grid-template-columns: 1fr auto; grid-template-rows: auto auto; column-gap: var(--sp-2, 8px);
  align-items: center; margin-top: var(--sp-2, 8px); padding: var(--sp-2, 8px) 2px 0; border-top: 1px solid #e3bf7840; text-align: left; }
#game .valhalla-bonus .vbr-label { font: 700 12px/1.2 var(--ff-body); letter-spacing: .18em; text-transform: uppercase; color: #e3bf78; }
#game .valhalla-bonus .vbr-break { grid-row: 2; font: 500 13px/1.35 var(--ff-body); color: var(--tx-dim, #cfc6b4); font-variant-numeric: tabular-nums; }
#game .valhalla-bonus .vbr-sum { grid-row: 1 / 3; grid-column: 2; display: inline-flex; align-items: center; gap: 4px;
  font: 800 20px/1 var(--ff-body); font-variant-numeric: tabular-nums; color: #ffe6a6; }
#game .valhalla-bonus .vbr-sum .ui-icon { width: 22px; height: 22px; }

@keyframes vbBump { 0% { transform: scale(1.18); } 100% { transform: scale(1); } }
@keyframes vbSkipPulse { 0%, 100% { opacity: .55; } 50% { opacity: .95; } }
@media (prefers-reduced-motion: reduce) {
  #game .vb-tally.vb-bump b, #game .vb-skip { animation: none; }
}
