/* Live events (js/live-events.js, Gage 10-29): the LIVE takeover over the whole app, cinematic letterbox, a banner that slams in,
   the caption strip, Skip after a few seconds; and the live event test button's menu (test mode only). Field-journal look:
   red, black and bone, inked frames. Reduced motion / calm: nothing animates. */
.lv { position: fixed; inset: 0; z-index: 9800; background: #0b0d10; color: #f2eee6; overflow: hidden; font-family: var(--display, sans-serif); touch-action: none; }
.lv-stage { position: absolute; inset: 0; }
.lv-stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.lv::after { content: ''; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(ellipse at 50% 46%, rgba(0,0,0,0) 52%, rgba(0,0,0,.55) 100%); }
.lv-bar { position: absolute; left: 0; right: 0; height: calc(var(--lvb, 52px) + env(safe-area-inset-top, 0px)); background: #050506; z-index: 2; transition: height .7s cubic-bezier(.2,.8,.2,1); }
.lv-bar.t { top: 0; }
.lv-bar.b { bottom: 0; height: calc(var(--lvb, 52px) + env(safe-area-inset-bottom, 0px)); }
.lv.intro .lv-bar { --lvb: 96px; }
.lv-top { position: absolute; z-index: 3; top: calc(env(safe-area-inset-top, 0px) + 10px); left: 12px; right: 12px; display: flex; align-items: center; gap: 10px; }
.lv-live { display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px 3px; background: #c4271f; color: #fff; border: 1.5px solid #0d0b09; box-shadow: 2px 2px 0 #0d0b09; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; }
.lv-live i, .lv-kick i { width: 8px; height: 8px; border-radius: 50%; background: #fff; animation: lvBlink 1s steps(2, start) infinite; }
.lv-title { display: flex; flex-direction: column; min-width: 0; line-height: 1; }
.lv-title small { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: #e8b36a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lv-title b { font-weight: 400; font-size: 19px; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lv-clock { margin-left: auto; font-size: 15px; letter-spacing: .08em; color: #d9d2c4; font-variant-numeric: tabular-nums; }
.lv-banner { position: absolute; z-index: 4; left: 0; right: 0; top: 34%; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; pointer-events: none; opacity: 0; transform: scale(1.35); transition: opacity .25s, transform .45s cubic-bezier(.2,1.4,.3,1); }
.lv.intro .lv-banner { opacity: 1; transform: scale(1); }
.lv-banner b { display: block; max-width: 92vw; padding: 8px 16px 6px; font-weight: 400; font-size: clamp(26px, 8.4vw, 54px); line-height: .95; letter-spacing: .03em; text-transform: uppercase; background: #16130f; border: 2px solid #0d0b09; outline: 2px solid #c4271f; outline-offset: -7px; box-shadow: 4px 5px 0 #000; transform: rotate(-2deg); }
.lv-banner em { font-style: normal; font-size: clamp(18px, 5.4vw, 30px); letter-spacing: .1em; text-transform: uppercase; color: #ffd36e; text-shadow: 0 2px 0 #000, 0 0 18px rgba(0,0,0,.8); }
.lv-banner small { font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: #cfc6b4; text-shadow: 0 1px 0 #000; }
.lv-kick { display: inline-flex; align-items: center; gap: 7px; padding: 5px 12px 4px; background: #c4271f; border: 2px solid #0d0b09; box-shadow: 3px 3px 0 #000; font-size: 16px; letter-spacing: .2em; text-transform: uppercase; }
.lv-cap { position: absolute; z-index: 3; left: 14px; right: 14px; bottom: calc(env(safe-area-inset-bottom, 0px) + 62px); margin: 0; text-align: center; font-size: 17px; letter-spacing: .05em; text-transform: uppercase; text-shadow: 0 2px 0 #000, 0 0 14px rgba(0,0,0,.9); opacity: 0; transform: translateY(6px); transition: opacity .35s, transform .35s; }
.lv-cap.on { opacity: 1; transform: none; }
.lv.aft .lv-cap { color: #ffd36e; }
/* the result card: the Test button's "In a real strike: ..." and a landed strike's "+312 cells, Canada's meter at Winnipeg -18%" */
.lv.aft .lv-cap.on.card { left: 50%; right: auto; width: min(92vw, 520px); transform: translateX(-50%); padding: 10px 12px 8px; background: rgba(13,11,9,.88); border: 1.5px solid #ffd36e; box-shadow: 3px 3px 0 #000; line-height: 1.25; text-shadow: none; }
.lv-foot { position: absolute; z-index: 3; left: 12px; right: 12px; bottom: calc(env(safe-area-inset-bottom, 0px) + 12px); display: flex; align-items: center; gap: 10px; }
.lv-prog { flex: 1; height: 4px; background: rgba(255,255,255,.14); border: 1px solid #0d0b09; }
.lv-prog i { display: block; height: 100%; width: 0; background: #c4271f; }
.lv-skip { min-width: 74px; min-height: 36px; padding: 6px 14px 4px; font: inherit; font-size: 15px; letter-spacing: .12em; text-transform: uppercase; color: #f2eee6; background: #16130f; border: 1.5px solid #8a7a66; box-shadow: 2px 2px 0 #000; cursor: pointer; }
.lv-skip:active { transform: translate(1px, 1px); box-shadow: 1px 1px 0 #000; }
.lv.test .lv-live { background: #6a5a2a; }
.lv.calm .lv-banner, .lv.calm .lv-cap, .lv.calm .lv-bar { transition: none; }
.lv.calm .lv-live i, .lv.calm .lv-kick i { animation: none; }
@keyframes lvBlink { to { visibility: hidden; } }
@media (prefers-reduced-motion: reduce) { .lv-banner, .lv-cap, .lv-bar { transition: none; } .lv-live i, .lv-kick i { animation: none; } }

/* the live event test button: the War Room's button sits under Test battle types; its menu and the Command sheet's block */
.wr .wr-lab.wr-live { bottom: calc(var(--safe-b, 0px) + 140px); }
@media (max-height: 700px) { .wr .wr-lab.wr-live { bottom: calc(var(--safe-b, 0px) + 118px); } }
.lv-menu { position: fixed; inset: 0; z-index: 9700; display: flex; align-items: flex-end; justify-content: center; background: rgba(0,0,0,.45); }
.lv-menu-box { width: min(520px, 100%); max-height: 78vh; overflow: auto; padding: 14px 14px calc(14px + env(safe-area-inset-bottom, 0px)); background: #1a1713; border-top: 2px solid #c4271f; box-shadow: 0 -6px 24px rgba(0,0,0,.6); }
.lv-menu-box header { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin-bottom: 10px; font-family: var(--display, sans-serif); }
.lv-menu-box header b { font-weight: 400; font-size: 20px; letter-spacing: .06em; text-transform: uppercase; color: #f2eee6; }
.lv-menu-box header small { flex: 1 1 100%; order: 3; font-size: 12px; color: #b8ad98; }
.lv-menu-x { margin-left: auto; width: 36px; height: 36px; padding: 6px; background: none; border: 1px solid #4a4036; }
.lv-menu-x svg { width: 100%; height: 100%; }
.lv-tests { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.lv-tests button { display: grid; grid-template-columns: 34px 1fr; grid-template-rows: auto auto; align-items: center; column-gap: 8px; min-height: 52px; padding: 8px 10px; text-align: left; color: #f2eee6; background: #241f19; border: 1.5px solid #4a4036; box-shadow: 2px 2px 0 #000; cursor: pointer; font-family: var(--display, sans-serif); }
.lv-tests button:active { transform: translate(1px, 1px); box-shadow: 1px 1px 0 #000; }
.lv-tests button > svg, .lv-tests button > .wg-arm, .lv-tests button > span:first-child { grid-row: 1 / span 2; width: 34px; height: 34px; }
.lv-tests button b { font-weight: 400; font-size: 15px; letter-spacing: .04em; text-transform: uppercase; line-height: 1.05; }
.lv-tests button small { font-size: 11px; color: #b8ad98; line-height: 1.15; }
.lv-tests button:nth-child(-n + 4) { border-color: #8a3a2a; background: #2c1d17; }
.cc-test .lv-tests { margin-top: 6px; }
