/* ================= 1920x1080 OBS BROADCAST OVERLAY (live.html) ================= */
html, body {
  margin: 0;
  padding: 0;
  width: 1920px;
  height: 1080px;
  overflow: hidden;
  background: transparent !important;
  user-select: none;
}

.stage-root {
  position: relative;
  width: 1920px;
  height: 1080px;
  overflow: hidden;
  font-family: var(--font-ui);
  color: #fff;
}

/* Fullscreen Backdrop (Hidden on Live Match & Caster cutouts!) */
.stage-backdrop {
  position: absolute;
  inset: 0;
  background-color: #080a0e;
  background-image:
    radial-gradient(ellipse 80% 55% at 50% 10%, rgba(var(--accent-rgb), 0.25), transparent 65%),
    radial-gradient(ellipse 60% 50% at 85% 90%, rgba(var(--accent-2-rgb), 0.14), transparent 60%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='420' height='420' viewBox='0 0 420 420'%3E%3Cg fill='none' stroke='rgba(255,255,255,0.045)' stroke-width='1.2'%3E%3Cpath d='M-20,60 C70,10 130,130 220,70 C310,10 360,110 440,60'/%3E%3Cpath d='M-20,140 C80,80 140,200 230,140 C320,80 360,190 440,140'/%3E%3Cpath d='M-20,230 C90,170 150,290 250,225 C340,170 370,280 440,230'/%3E%3Cpath d='M-20,330 C70,280 140,390 230,330 C310,275 370,380 440,330'/%3E%3C/g%3E%3C/svg%3E");
  transition: opacity 0.35s ease;
  z-index: 0;
}
.stage-backdrop.transparent-mode { opacity: 0; }
.stage-backdrop .custom-bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.28;
}

/* Scene Container */
.scene-layer {
  position: absolute;
  inset: 0;
  z-index: 10;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.32s ease;
}
.scene-layer.active {
  opacity: 1;
  pointer-events: auto;
}

/* Top Broadcast Chrome Bar (shared by full-screen scenes) */
.bc-top-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 86px;
  padding: 0 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: linear-gradient(180deg, rgba(8, 10, 14, 0.92), transparent);
  z-index: 20;
}
.bc-brand-lockup { display: flex; align-items: center; gap: 16px; }
.bc-logo-box {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  border: 1.5px solid rgba(var(--accent-rgb), 0.75);
  background: rgba(16, 19, 25, 0.9);
  display: grid;
  place-items: center;
  overflow: hidden;
}
.bc-logo-box img { width: 100%; height: 100%; object-fit: cover; }
.bc-brand-title {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  line-height: 1;
}
.bc-brand-sub {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--accent);
  text-transform: uppercase;
}
.bc-live-clock {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 8px 18px;
  border-radius: 6px;
  background: rgba(12, 15, 20, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.14);
  font-family: var(--font-mono);
  font-size: 24px;
  font-weight: 700;
}
.bc-live-pill {
  padding: 4px 12px;
  border-radius: 4px;
  background: var(--accent);
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.12em;
}

/* Bottom Broadcast Ticker */
.bc-footer-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 54px;
  padding: 0 54px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(8, 10, 14, 0.92);
  border-top: 2px solid var(--accent);
  z-index: 20;
}
.bc-ticker-text {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #e2e8f0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.bc-powered {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: var(--accent);
  text-transform: uppercase;
  flex-shrink: 0;
  margin-left: 24px;
}

/* ================= SCENE 1: STARTING SOON ================= */
.ss-wrap {
  position: absolute;
  inset: 96px 80px 80px;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 54px;
  align-items: center;
}
.ss-kicker {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 700;
  letter-spacing: 0.22em;
  color: var(--accent);
  text-transform: uppercase;
}
.ss-headline {
  font-family: var(--font-display);
  font-size: 146px;
  font-weight: 800;
  line-height: 0.88;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin: 12px 0 20px;
}
.ss-headline span { color: var(--accent); display: block; }
.ss-timer {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 98px;
  font-weight: 700;
  color: var(--accent);
  text-shadow: 0 0 38px rgba(var(--accent-rgb), 0.55);
  margin-top: 10px;
}
.ss-next-card {
  background: rgba(14, 17, 23, 0.92);
  border: 1.5px solid rgba(var(--accent-rgb), 0.65);
  border-radius: 10px;
  padding: 36px 40px;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.65);
}
.ss-team-row {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 18px 22px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.09);
}
.ss-team-name {
  font-family: var(--font-display);
  font-size: 46px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.ss-vs {
  text-align: center;
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 800;
  letter-spacing: 0.2em;
  color: var(--accent);
  margin: 10px 0;
}

/* ================= SCENE 5: LIVE MATCH (TRANSPARENT HUD!) ================= */
.live-hud-top {
  position: absolute;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: stretch;
  background: rgba(9, 11, 16, 0.92);
  border: 1.5px solid rgba(255, 255, 255, 0.16);
  border-bottom: 3px solid var(--accent);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 14px 42px rgba(0, 0, 0, 0.65);
}
.live-hud-top.compact-left {
  left: 28px;
  transform: none;
}

.hud-team {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 26px;
  min-width: 280px;
}
.hud-team.right { flex-direction: row-reverse; text-align: right; }
.hud-team-tag {
  font-family: var(--font-display);
  font-size: 36px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1;
}
.hud-team-sub {
  font-size: 13px;
  color: var(--text-2);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.hud-score-box {
  min-width: 72px;
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-size: 46px;
  font-weight: 700;
  background: rgba(var(--accent-rgb), 0.22);
  border-left: 1px solid rgba(255, 255, 255, 0.12);
  border-right: 1px solid rgba(255, 255, 255, 0.12);
  padding: 0 18px;
  transition: transform 0.25s ease;
}
.hud-score-box.pop {
  animation: scorePop 0.55s ease;
}
@keyframes scorePop {
  0% { transform: scale(1); background: rgba(var(--accent-rgb), 0.22); }
  35% { transform: scale(1.25); background: var(--accent); }
  100% { transform: scale(1); background: rgba(var(--accent-rgb), 0.22); }
}

.hud-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 6px 22px;
  min-width: 170px;
  background: rgba(255, 255, 255, 0.03);
}
.hud-stage {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 800;
  letter-spacing: 0.14em;
  color: var(--accent);
  text-transform: uppercase;
}
.hud-format {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--text-2);
}

.live-hud-bottom {
  position: absolute;
  bottom: 18px;
  left: 28px;
  right: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: none;
}
.hud-corner-pill {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 8px 18px;
  border-radius: 6px;
  background: rgba(9, 11, 16, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-left: 3px solid var(--accent);
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.obs-placeholder-hint {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  padding: 28px 54px;
  border-radius: 10px;
  border: 2px dashed rgba(255, 255, 255, 0.18);
  background: rgba(12, 15, 20, 0.65);
  display: none;
}
body.is-embed .obs-placeholder-hint { display: block; }
body.has-obs-feed .obs-placeholder-hint { display: none !important; }
body.has-obs-feed .caster-cam-window { background: transparent !important; }

/* ================= SCENE 13: CASTER DESK (TRANSPARENT CAM WINDOWS!) ================= */
.caster-desk-stage {
  position: absolute;
  inset: 0;
  /* Drawn with border masks around camera windows so OBS VDO.Ninja Caster sources sit cleanly underneath! */
}
.caster-header-badge {
  position: absolute;
  top: 96px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-display);
  font-size: 56px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-shadow: 0 6px 26px rgba(0, 0, 0, 0.85);
}
.caster-header-badge span { color: var(--accent); }

.caster-frames {
  position: absolute;
  top: 185px;
  left: 90px;
  right: 90px;
  bottom: 110px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 48px;
}
.caster-cam-window {
  position: relative;
  width: 820px;
  height: 540px;
  border: 3px solid var(--accent);
  border-radius: 10px;
  box-shadow: 0 0 0 2000px rgba(8, 10, 14, 0.0);
  background: transparent;
}
.caster-frames.single .caster-cam-window {
  width: 1160px;
  height: 652px;
}
body.is-embed .caster-cam-window {
  background: rgba(5, 7, 10, 0.82);
}
.caster-nameplate {
  position: absolute;
  left: 20px;
  bottom: 20px;
  padding: 10px 26px;
  border-radius: 6px;
  background: linear-gradient(90deg, rgba(10, 12, 17, 0.94), rgba(10, 12, 17, 0.78));
  border-left: 5px solid var(--accent);
  font-family: var(--font-display);
  font-size: 34px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.caster-nameplate small {
  display: block;
  font-size: 14px;
  letter-spacing: 0.18em;
  color: var(--accent);
}

/* ================= SCENE 3: MATCH UP ================= */
.matchup-wrap {
  position: absolute;
  inset: 110px 90px 90px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 36px;
}
.matchup-grid {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 220px 1fr;
  align-items: center;
  gap: 28px;
}
.mu-card {
  background: rgba(14, 17, 23, 0.92);
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-top: 5px solid var(--accent);
  border-radius: 10px;
  padding: 48px 34px;
  text-align: center;
}
.mu-tag {
  font-family: var(--font-display);
  font-size: 86px;
  font-weight: 800;
  letter-spacing: 0.06em;
  line-height: 1;
  margin-top: 18px;
}
.mu-name {
  font-family: var(--font-display);
  font-size: 28px;
  color: var(--text-2);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-top: 6px;
}
.mu-vs {
  text-align: center;
  font-family: var(--font-display);
  font-size: 120px;
  font-weight: 800;
  font-style: italic;
  color: var(--accent);
  text-shadow: 0 0 42px rgba(var(--accent-rgb), 0.65);
}

/* ================= SCENE 11: BREAK + VIDEO AD ================= */
.break-wrap {
  position: absolute;
  inset: 100px 70px 76px;
  display: grid;
  grid-template-columns: 1.35fr 0.65fr;
  gap: 38px;
  align-items: center;
}
.break-video-box {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 10px;
  overflow: hidden;
  border: 2px solid rgba(var(--accent-rgb), 0.7);
  background: #06080b;
  position: relative;
  display: grid;
  place-items: center;
}
.break-video-box video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ================= FULLSCREEN STINGER TRANSITION OVERLAY ================= */
.stinger-layer {
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
  opacity: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.stinger-panel {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 50%, rgba(var(--accent-rgb), 0.35), transparent 65%),
    linear-gradient(125deg, #0b0d12 0%, #170a10 50%, #0b0d12 100%);
  border-top: 8px solid var(--accent);
  border-bottom: 8px solid var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 44px;
}
.stinger-stripe {
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 35%, rgba(var(--accent-rgb), 0.55) 50%, transparent 65%);
  transform: translateX(-100%);
}
.stinger-title {
  font-family: var(--font-display);
  font-size: 168px;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 0.88;
  text-transform: uppercase;
  color: #fff;
  text-shadow: 0 10px 45px rgba(var(--accent-rgb), 0.65);
}
.stinger-sub {
  font-family: var(--font-display);
  font-size: 36px;
  font-weight: 800;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: #fff;
}
.stinger-sub span {
  background: var(--accent);
  padding: 2px 12px;
  border-radius: 4px;
  margin-left: 8px;
}

.stinger-layer.run-logo {
  animation: stingerLogo 0.95s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
.stinger-layer.run-logo .stinger-stripe {
  animation: stingerShine 0.95s ease forwards;
}
@keyframes stingerLogo {
  0% { opacity: 1; clip-path: inset(0 100% 0 0); }
  28% { opacity: 1; clip-path: inset(0 0 0 0); }
  70% { opacity: 1; clip-path: inset(0 0 0 0); }
  100% { opacity: 1; clip-path: inset(0 0 0 100%); }
}
@keyframes stingerShine {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.stinger-layer.run-wipe {
  animation: stingerWipe 0.75s cubic-bezier(0.7, 0, 0.3, 1) forwards;
}
@keyframes stingerWipe {
  0% { opacity: 1; transform: translateY(-100%); }
  35% { opacity: 1; transform: translateY(0%); }
  65% { opacity: 1; transform: translateY(0%); }
  100% { opacity: 1; transform: translateY(100%); }
}

.stinger-layer.run-fade {
  animation: stingerFade 0.65s ease forwards;
}
@keyframes stingerFade {
  0% { opacity: 0; }
  45% { opacity: 1; }
  100% { opacity: 0; }
}
