@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@600;700;900&family=Montserrat:wght@400;600;700;800;900&family=Orbitron:wght@600;800;900&display=swap');

:root {
  --bb-gold: #f59e0b;
  --bb-gold-light: #fde68a;
  --bb-gold-dark: #b45309;
  --bb-gold-metallic: linear-gradient(135deg, #bf953f 0%, #fcf6ba 25%, #b38728 50%, #fbf5b7 75%, #aa771c 100%);
  --bb-red: #ef4444;
  --bb-red-glow: rgba(239, 68, 68, 0.7);
  --bb-safe: #10b981;
  --bb-safe-glow: rgba(16, 185, 129, 0.6);
  --bb-cyan: #06b6d4;
  --bb-dark-bg: #07090e;
  --bb-card-bg: rgba(13, 16, 26, 0.9);
  --bb-border-gold: rgba(245, 158, 11, 0.4);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: var(--bb-dark-bg);
  color: #ffffff;
  font-family: 'Montserrat', sans-serif;
  overflow: hidden;
  height: 100vh;
  width: 100vw;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  position: relative;
}

/* Background canvas for golden embers */
#particles-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

/* Ambient studio lighting */
.ambient-glow {
  position: fixed;
  width: 750px;
  height: 750px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  filter: blur(140px);
  opacity: 0.16;
}

.ambient-gold {
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  background: radial-gradient(circle, #f59e0b, #b45309 60%, transparent);
}

.ambient-red {
  bottom: -200px;
  right: -100px;
  background: radial-gradient(circle, #dc2626, transparent 70%);
}

.ambient-blue {
  bottom: -200px;
  left: -100px;
  background: radial-gradient(circle, #2563eb, transparent 70%);
}

/* Studio Header Wrapper */
.studio-header-wrap {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 10px 16px 4px;
  z-index: 100;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.studio-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  background: rgba(18, 22, 34, 0.95);
  backdrop-filter: blur(20px);
  padding: 6px 16px;
  border-radius: 40px;
  border: 1px solid rgba(245, 158, 11, 0.35);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.7);
}

.studio-toolbar.hidden {
  display: none !important;
}

.toolbar-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Cinzel', serif;
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--bb-gold-light);
  letter-spacing: 1px;
  padding-right: 8px;
  border-right: 1px solid rgba(255, 255, 255, 0.15);
}

.eye-icon {
  width: 18px;
  height: 18px;
}

.btn-group {
  display: flex;
  gap: 6px;
}

.tool-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #e2e8f0;
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 0.76rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
  font-family: 'Montserrat', sans-serif;
  text-decoration: none;
}

.tool-btn:hover {
  background: rgba(245, 158, 11, 0.2);
  border-color: var(--bb-gold);
  color: #ffffff;
  transform: translateY(-1px);
}

.tool-btn.active {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #000000;
  font-weight: 800;
  border-color: #fde68a;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.5);
}

.tool-btn.sim-active {
  background: linear-gradient(135deg, #ef4444, #b91c1c);
  color: #ffffff;
  border-color: #fca5a5;
  box-shadow: 0 0 14px rgba(239, 68, 68, 0.6);
  animation: simPulse 1.6s infinite alternate;
}

@keyframes simPulse {
  0% { box-shadow: 0 0 8px rgba(239, 68, 68, 0.4); }
  100% { box-shadow: 0 0 18px rgba(239, 68, 68, 0.9); }
}

/* Reveal Toolbar Button when hidden */
#btn-reveal-toolbar {
  position: fixed;
  top: 12px;
  right: 12px;
  z-index: 999;
  background: rgba(10, 14, 23, 0.88);
  backdrop-filter: blur(10px);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.6);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.7);
  transition: all 0.2s ease;
}

#btn-reveal-toolbar:hover {
  background: #f59e0b;
  color: #000000;
}

/* ========================================================
   MAIN STAGE VIEWPORT (PERFECT FIT IN OBS)
   ======================================================== */
.stage-viewport {
  position: relative;
  z-index: 10;
  flex: 1;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 4px 16px 12px;
  min-height: 0;
  overflow: hidden;
}

/* When toolbar is hidden (Clean Mode / Stream Capture) */
body.clean-stream-mode .studio-header-wrap,
body.clean-stream-mode #studio-toolbar {
  display: none !important;
}

body.clean-stream-mode .stage-viewport {
  padding: 0 !important;
  margin: 0 !important;
  height: 100vh !important;
  width: 100vw !important;
}

body.clean-stream-mode .broadcast-panel.mode-16-9 {
  width: 100vw !important;
  height: 100vh !important;
  max-width: 100vw !important;
  max-height: 100vh !important;
  border-radius: 0 !important;
  border: none !important;
}

body.clean-stream-mode .broadcast-panel.mode-9-16 {
  width: min(100vw, calc(100vh * 9 / 16)) !important;
  height: 100vh !important;
  max-width: 100vw !important;
  max-height: 100vh !important;
  border-radius: 0 !important;
  border: none !important;
}

/* 16:9 Landscape Frame (Maximized to screen height & width preserving 16:9) */
.broadcast-panel.mode-16-9 {
  width: min(calc(100vw - 32px), calc((100vh - 72px) * 16 / 9));
  height: min(calc(100vh - 72px), calc((100vw - 32px) * 9 / 16));
  max-width: 1920px;
  max-height: 1080px;
  aspect-ratio: 16 / 9;
  border-radius: 16px;
}

/* 9:16 Shorts Frame */
.broadcast-panel.mode-9-16 {
  width: min(calc(100vw - 32px), calc((100vh - 72px) * 9 / 16));
  height: min(calc(100vh - 72px), calc((100vw - 32px) * 16 / 9));
  max-width: 608px;
  max-height: 1080px;
  aspect-ratio: 9 / 16;
  border-radius: 18px;
}

/* Broadcast Panel Container */
.broadcast-panel {
  position: relative;
  background: radial-gradient(circle at 50% 25%, #181d2d 0%, #0d101a 60%, #07080d 100%);
  border: 2px solid rgba(245, 158, 11, 0.45);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.85), inset 0 0 35px rgba(245, 158, 11, 0.12);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Scanline Overlay */
.broadcast-panel::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.22) 50%);
  background-size: 100% 4px;
  pointer-events: none;
  opacity: 0.2;
  z-index: 5;
}

/* Corner Golden Bracket Ornaments */
.panel-corner {
  position: absolute;
  width: 24px;
  height: 24px;
  border: 3px solid var(--bb-gold);
  z-index: 6;
  pointer-events: none;
  box-shadow: 0 0 8px rgba(245, 158, 11, 0.6);
}
.corner-tl { top: 8px; left: 8px; border-right: none; border-bottom: none; }
.corner-tr { top: 8px; right: 8px; border-left: none; border-bottom: none; }
.corner-bl { bottom: 8px; left: 8px; border-right: none; border-top: none; }
.corner-br { bottom: 8px; right: 8px; border-left: none; border-top: none; }

/* ========================================================
   BROADCAST HEADER & EYE ANIMATIONS
   ======================================================== */
.panel-header {
  position: relative;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 22px;
  background: linear-gradient(180deg, rgba(20, 26, 42, 0.98) 0%, rgba(13, 16, 26, 0.85) 100%);
  border-bottom: 1.5px solid rgba(245, 158, 11, 0.35);
  flex-shrink: 0;
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.eye-wrapper-anim {
  position: relative;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bb-eye-logo {
  width: 42px;
  height: 42px;
  filter: drop-shadow(0 0 10px rgba(245, 158, 11, 0.85));
}

/* Continuous Orbiting Dashed Ring Animation */
.outer-orbit-ring {
  transform-origin: 50px 50px;
  animation: orbitRingRotate 16s linear infinite;
}

@keyframes orbitRingRotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Iris Pulse Animation */
.iris-anim {
  transform-origin: 50px 50px;
  animation: irisContract 4s ease-in-out infinite;
}

@keyframes irisContract {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.12); }
}

.brand-titles h1 {
  font-family: 'Cinzel', serif;
  font-size: 1.25rem;
  font-weight: 900;
  letter-spacing: 2px;
  background: var(--bb-gold-metallic);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 2px 10px rgba(245, 158, 11, 0.3);
  line-height: 1.1;
}

.brand-titles .season-tag {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 2.5px;
  color: #e2e8f0;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 8px;
}

.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(16, 185, 129, 0.2);
  border: 1px solid rgba(16, 185, 129, 0.7);
  color: #6ee7b7;
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 1px;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.4);
}

.live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: liveBlink 1s infinite alternate;
}

@keyframes liveBlink {
  0% { opacity: 0.3; transform: scale(0.85); }
  100% { opacity: 1; transform: scale(1.25); }
}

.header-meta {
  display: flex;
  align-items: center;
  gap: 14px;
}

.meta-box {
  text-align: right;
  background: rgba(0, 0, 0, 0.5);
  padding: 5px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.meta-label {
  font-size: 0.62rem;
  color: #94a3b8;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  font-weight: 700;
}

.meta-value {
  font-family: 'Orbitron', monospace;
  font-size: 1.05rem;
  font-weight: 800;
  color: #fde68a;
  letter-spacing: 1px;
}

.meta-value.timer {
  color: #fbbf24;
  font-size: 0.95rem;
}

/* Announcement Subbar */
.broadcast-subbar {
  position: relative;
  z-index: 10;
  background: linear-gradient(90deg, #b45309 0%, #f59e0b 50%, #b45309 100%);
  color: #000;
  font-weight: 900;
  font-size: 0.74rem;
  letter-spacing: 2px;
  text-align: center;
  padding: 4px 12px;
  text-transform: uppercase;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.subbar-pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ffffff;
  display: inline-block;
  margin-right: 6px;
  animation: beaconBlink 1s infinite alternate;
}

@keyframes beaconBlink {
  0% { transform: scale(0.8); opacity: 0.4; }
  100% { transform: scale(1.3); opacity: 1; }
}

/* ========================================================
   16:9 LANDSCAPE VIEW (Side-by-side Battle Cards)
   ======================================================== */
.cards-container-16-9 {
  position: relative;
  z-index: 10;
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  padding: 10px 18px;
  align-items: stretch;
  overflow: hidden;
}

.contestant-card {
  position: relative;
  background: #090c14;
  border-radius: 16px;
  border: 2px solid var(--bb-border-gold);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.7);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease, border-color 0.3s ease;
  min-height: 0;
  height: 100%;
}

.contestant-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.85), 0 0 20px rgba(245, 158, 11, 0.35);
}

/* Full Bleed Poster Image Background */
.card-bg-wrap {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 1;
}

.card-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 10%;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.contestant-card:hover .card-bg-img {
  transform: scale(1.05);
}

.card-lighting-glow {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 50% 25%, transparent 25%, rgba(7, 9, 14, 0.4) 85%);
  pointer-events: none;
}

.card-gradient-scrim {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 70%;
  background: linear-gradient(180deg, transparent 0%, rgba(9, 12, 20, 0.5) 25%, rgba(7, 9, 14, 0.94) 75%, #07090e 100%);
  pointer-events: none;
}

/* Rank 1: Golden Shimmer Animation */
.card-shimmer-anim {
  position: relative;
}

.card-shimmer-anim::after {
  content: '';
  position: absolute;
  top: 0;
  left: -120%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(254, 240, 138, 0.25), transparent);
  transform: skewX(-25deg);
  pointer-events: none;
  z-index: 15;
  animation: goldCardSweep 4.5s infinite cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes goldCardSweep {
  0% { left: -120%; }
  30%, 100% { left: 180%; }
}

/* Rank 3: Pulsing Danger Neon Alarm */
.danger-alarm-anim {
  border-color: rgba(239, 68, 68, 0.95) !important;
  animation: dangerNeonAlarm 1.8s infinite ease-in-out !important;
}

@keyframes dangerNeonAlarm {
  0%, 100% {
    border-color: rgba(239, 68, 68, 0.7);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7), 0 0 18px rgba(239, 68, 68, 0.4);
  }
  50% {
    border-color: #ef4444;
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.85), 0 0 35px rgba(239, 68, 68, 0.8), inset 0 0 15px rgba(239, 68, 68, 0.25);
  }
}

/* Card Header Badges */
.card-top-tags {
  position: relative;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 12px 0;
}

.rank-badge {
  font-family: 'Orbitron', sans-serif;
  font-size: 0.7rem;
  font-weight: 900;
  background: rgba(0, 0, 0, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fde68a;
  padding: 3px 9px;
  border-radius: 10px;
}

.badge-glow-gold {
  border-color: #f59e0b;
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.7);
}

.badge-danger-tag {
  border-color: #ef4444;
  color: #fca5a5;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.7);
}

.status-badge {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 10px;
  border: 1px solid transparent;
}

.status-safe-glow {
  background: linear-gradient(135deg, #10b981, #059669);
  color: #ffffff;
  border-color: #6ee7b7;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.75);
}

.status-borderline-glow {
  background: linear-gradient(135deg, #059669, #10b981);
  color: #ffffff;
  border-color: #6ee7b7;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.6);
}

.status-danger-glow {
  background: linear-gradient(135deg, #ef4444, #b91c1c);
  color: #ffffff;
  border-color: #fca5a5;
  box-shadow: 0 0 14px rgba(239, 68, 68, 0.85);
}

/* Lower Third Broadcast HUD */
.card-broadcast-hud {
  position: relative;
  z-index: 10;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  background: linear-gradient(180deg, rgba(13, 16, 26, 0.4) 0%, rgba(9, 12, 20, 0.9) 40%, rgba(7, 9, 14, 0.98) 100%);
  border-top: 1px solid rgba(245, 158, 11, 0.25);
  border-radius: 0 0 16px 16px;
  padding: 8px 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.name-plate {
  text-align: center;
}

.name-plate h2 {
  font-family: 'Cinzel', serif;
  font-size: 1.15rem;
  font-weight: 900;
  letter-spacing: 1.5px;
  background: var(--bb-gold-metallic);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.9);
}

.name-plate .alias-sub {
  font-size: 0.68rem;
  font-weight: 800;
  color: #cbd5e1;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

/* Vote Statistics Section */
.stats-section {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.vote-numbers-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.percentage-display {
  font-family: 'Orbitron', monospace;
  font-size: 1.75rem;
  font-weight: 900;
  color: #ffffff;
  line-height: 1;
  text-shadow: 0 0 12px rgba(245, 158, 11, 0.5);
}

.percentage-display span {
  font-size: 1rem;
  color: var(--bb-gold-light);
}

.percentage-display.leader-pct {
  color: #fbbf24;
  text-shadow: 0 0 14px rgba(251, 191, 36, 0.7);
}

.percentage-display.danger-pct {
  color: #f87171;
  text-shadow: 0 0 14px rgba(248, 113, 113, 0.75);
}

.total-votes-count {
  text-align: right;
}

.total-votes-count .votes-num {
  font-family: 'Orbitron', monospace;
  font-size: 0.88rem;
  font-weight: 700;
  color: #e2e8f0;
}

.total-votes-count .votes-label {
  font-size: 0.58rem;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Progress Bar with Sweep Light Animation */
.progress-track {
  width: 100%;
  height: 10px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.progress-fill {
  height: 100%;
  border-radius: 10px;
  background: linear-gradient(90deg, #d97706, #f59e0b, #fef08a);
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.7);
  transition: width 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
}

.progress-fill.fill-shimmer {
  overflow: hidden;
}

.progress-fill.fill-shimmer::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
  animation: progressLightGlide 2.5s infinite linear;
}

@keyframes progressLightGlide {
  0% { left: -100%; }
  100% { left: 100%; }
}

.btn-vote-now {
  width: 100%;
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.25), rgba(217, 119, 6, 0.35));
  border: 1.5px solid var(--bb-gold);
  color: #fde68a;
  padding: 6px 12px;
  border-radius: 10px;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.btn-vote-now:hover {
  background: var(--bb-gold);
  color: #000000;
  box-shadow: 0 0 15px rgba(245, 158, 11, 0.8);
}

.btn-vote-danger {
  border-color: #ef4444 !important;
  color: #fca5a5 !important;
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.25), rgba(185, 28, 28, 0.35)) !important;
}

.btn-vote-danger:hover {
  background: #ef4444 !important;
  color: #ffffff !important;
  box-shadow: 0 0 18px rgba(239, 68, 68, 0.85) !important;
}

/* ========================================================
   9:16 SHORTS VIEW (Vertical Stack Rows)
   ======================================================== */
.mode-9-16 .panel-header {
  padding: 8px 12px;
  gap: 8px;
}

.mode-9-16 .header-brand {
  gap: 8px;
}

.mode-9-16 .bb-eye-logo {
  width: 32px;
  height: 32px;
}

.mode-9-16 .brand-titles h1 {
  font-size: 1rem;
}

.mode-9-16 .brand-titles .season-tag {
  font-size: 0.58rem;
  letter-spacing: 1px;
}

.mode-9-16 .header-meta {
  display: flex;
  flex-direction: column;
  gap: 3px;
  align-items: flex-end;
}

.mode-9-16 .meta-box {
  padding: 2px 8px;
}

.mode-9-16 .meta-label {
  font-size: 0.52rem;
  letter-spacing: 0.8px;
}

.mode-9-16 .meta-value {
  font-size: 0.78rem;
}

.mode-9-16 .meta-value.timer {
  font-size: 0.74rem;
}

.mode-9-16 .broadcast-subbar {
  font-size: 0.62rem;
  padding: 3px 8px;
  letter-spacing: 1px;
}

.mode-9-16 .cards-container-16-9 {
  display: none !important;
}

.cards-container-9-16 {
  display: none;
}

.mode-9-16 .cards-container-9-16 {
  position: relative;
  z-index: 10;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 8px 12px;
  justify-content: space-evenly;
  overflow: hidden;
}

.contestant-card-shorts {
  position: relative;
  background: var(--bb-card-bg);
  border-radius: 14px;
  border: 1.5px solid var(--bb-border-gold);
  display: flex;
  align-items: center;
  padding: 8px 10px;
  gap: 10px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.6);
  overflow: hidden;
  flex: 1;
  min-height: 0;
}

.shorts-portrait-wrap {
  position: relative;
  width: 85px;
  height: 100%;
  max-height: 130px;
  flex-shrink: 0;
  border-radius: 10px;
  overflow: hidden;
  border: 2px solid rgba(245, 158, 11, 0.6);
}

.shorts-portrait-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 10%;
}

.shorts-rank-badge {
  position: absolute;
  bottom: 4px;
  left: 4px;
  font-family: 'Orbitron', monospace;
  font-size: 0.65rem;
  font-weight: 900;
  background: rgba(0, 0, 0, 0.85);
  color: #fde68a;
  padding: 2px 6px;
  border-radius: 6px;
}

.shorts-info-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.shorts-name-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.shorts-name-row h3 {
  font-family: 'Cinzel', serif;
  font-size: 0.95rem;
  font-weight: 900;
  color: #fde68a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.shorts-percent {
  font-family: 'Orbitron', monospace;
  font-size: 1.15rem;
  font-weight: 900;
  color: #ffffff;
}

.shorts-status-tag {
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 2px 6px;
  border-radius: 6px;
  display: inline-block;
  align-self: flex-start;
}

.shorts-status-safe {
  background: rgba(16, 185, 129, 0.2);
  border: 1px solid #10b981;
  color: #6ee7b7;
}

.shorts-status-mid {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid #10b981;
  color: #6ee7b7;
}

.shorts-status-danger {
  background: rgba(239, 68, 68, 0.2);
  border: 1px solid #ef4444;
  color: #fca5a5;
}

.shorts-action-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 2px;
}

.shorts-votes-count {
  font-family: 'Orbitron', monospace;
  font-size: 0.75rem;
  color: #cbd5e1;
}

.btn-shorts-vote {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: #000000;
  border: none;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 800;
  cursor: pointer;
}

/* ========================================================
   BOTTOM BROADCAST TICKER
   ======================================================== */
.panel-ticker {
  position: relative;
  z-index: 10;
  height: 36px;
  background: rgba(8, 11, 19, 0.96);
  border-top: 1px solid rgba(245, 158, 11, 0.3);
  display: flex;
  align-items: center;
  overflow: hidden;
  flex-shrink: 0;
}

.ticker-tag {
  background: linear-gradient(135deg, #dc2626, #991b1b);
  color: #ffffff;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 0 12px;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 6px;
  z-index: 5;
  box-shadow: 4px 0 12px rgba(0, 0, 0, 0.6);
  flex-shrink: 0;
}

.ticker-beacon {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #ffffff;
  animation: beaconBlink 1s infinite alternate;
}

.ticker-viewport {
  flex: 1;
  overflow: hidden;
  position: relative;
  height: 100%;
}

.ticker-content-track {
  display: flex;
  align-items: center;
  white-space: nowrap;
  height: 100%;
  gap: 30px;
  animation: tickerMarquee 25s linear infinite;
  padding-left: 100%;
}

@keyframes tickerMarquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-100%); }
}

.ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.76rem;
  color: #e2e8f0;
}

.ticker-item .highlight {
  color: #fde68a;
  font-weight: 800;
}

.ticker-item .ticker-real-tag {
  color: #10b981;
  font-weight: 800;
}

/* ========================================================
   MODAL DIALOG
   ======================================================== */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(8px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
}

.modal-backdrop.open {
  display: flex;
}

.modal-card {
  background: #0f1320;
  border: 2px solid var(--bb-gold);
  border-radius: 16px;
  padding: 24px;
  width: 420px;
  max-width: 90vw;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.9);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.modal-card h2 {
  font-family: 'Cinzel', serif;
  font-size: 1.15rem;
  color: var(--bb-gold-light);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 0.78rem;
  font-weight: 700;
  color: #cbd5e1;
}

.form-group input {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  color: #ffffff;
  padding: 8px 12px;
  font-family: 'Orbitron', monospace;
  font-size: 0.95rem;
  font-weight: 700;
  outline: none;
}

.form-group input:focus {
  border-color: var(--bb-gold);
  box-shadow: 0 0 10px rgba(245, 158, 11, 0.5);
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 8px;
}
