/* ArenaPass.tv Design System & Stylesheet */

/* Google Fonts Import */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800;900&display=swap');

/* --- CSS Variables & Tokens --- */
:root {
  --font-primary: 'Outfit', sans-serif;
  
  /* Color Palette */
  --bg-primary: #090b0f;
  --bg-secondary: #12151c;
  --bg-tertiary: #191e27;
  
  --accent-orange: #ff6b00;
  --accent-orange-glow: rgba(255, 107, 0, 0.45);
  
  --accent-cyan: #00f0ff;
  --accent-cyan-glow: rgba(0, 240, 255, 0.35);
  
  --color-live: #ef4444;
  --color-upcoming: #f59e0b;
  --color-finished: #6b7280;
  
  --text-primary: #f3f4f6;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;
  
  --border-color: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(0, 240, 255, 0.15);
  --glass-bg: rgba(18, 21, 28, 0.7);
  --glass-blur: backdrop-filter: blur(12px) saturate(180%);
  
  /* Layout & Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --shadow-neon: 0 0 20px rgba(0, 240, 255, 0.15);
  --shadow-card: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* --- Base Reset & Scrollbar --- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  outline: none;
}

body {
  font-family: var(--font-primary);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  overflow-x: hidden;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
  background: var(--bg-tertiary);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-orange);
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-fast);
}

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: var(--font-primary);
  transition: var(--transition-fast);
}

input, select, textarea {
  font-family: var(--font-primary);
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  transition: var(--transition-fast);
}
input:focus, select:focus, textarea:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.2);
}

/* --- Layout Wrappers --- */
.app-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main {
  flex-grow: 1;
  padding-top: 80px; /* Space for fixed header */
  position: relative;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* --- Animations --- */
@keyframes pulse-live {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 8px rgba(239, 68, 68, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

@keyframes ticker {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-50%, 0, 0); }
}

@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
  100% { transform: translateY(0px); }
}

@keyframes slide-in {
  from { transform: translateY(20px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes glow-pulse {
  0% { box-shadow: 0 0 5px var(--accent-cyan-glow); }
  50% { box-shadow: 0 0 20px var(--accent-cyan-glow); }
  100% { box-shadow: 0 0 5px var(--accent-cyan-glow); }
}

@keyframes goal-flash {
  0% { background-color: transparent; }
  25% { background-color: rgba(255, 107, 0, 0.8); }
  50% { background-color: transparent; }
  75% { background-color: rgba(255, 107, 0, 0.8); }
  100% { background-color: transparent; }
}

.animate-slide-in {
  animation: slide-in var(--transition-normal) forwards;
}

.animate-fade-in {
  animation: fade-in var(--transition-normal) forwards;
}

/* --- Premium Navigation Header --- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 80px;
  z-index: 1000;
  background: var(--glass-bg);
  backdrop-filter: blur(12px) saturate(180%);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  transition: var(--transition-normal);
}

.site-header.scrolled {
  height: 70px;
  background: rgba(9, 11, 15, 0.95);
  box-shadow: var(--shadow-neon);
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.5rem;
  letter-spacing: -0.5px;
}
.brand-logo span.accent {
  color: var(--accent-orange);
}
.brand-logo i {
  color: var(--accent-cyan);
  font-size: 1.7rem;
  filter: drop-shadow(0 0 8px var(--accent-cyan-glow));
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 30px;
  align-items: center;
}

.nav-item a {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-secondary);
  position: relative;
  padding: 6px 0;
}
.nav-item a:hover,
.nav-item.active a {
  color: var(--text-primary);
}
.nav-item a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent-cyan);
  transition: var(--transition-fast);
  box-shadow: 0 0 8px var(--accent-cyan-glow);
}
.nav-item a:hover::after,
.nav-item.active a::after {
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 15px;
}

/* Premium Buttons */
.btn-premium {
  padding: 10px 20px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-orange) 0%, #d45900 100%);
  color: white;
  box-shadow: 0 4px 15px rgba(255, 107, 0, 0.3);
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 107, 0, 0.45);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
}
.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--accent-cyan);
}

.btn-outline {
  border: 1px solid var(--accent-cyan);
  color: var(--accent-cyan);
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.1);
}
.btn-outline:hover {
  background: var(--accent-cyan);
  color: var(--bg-primary);
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.3);
}

/* Mobile Menu Button */
.menu-toggle {
  display: none;
  font-size: 1.5rem;
  color: var(--text-primary);
}

/* --- Hero Banner Section --- */
.hero-section {
  padding: 30px 0 50px;
}

.hero-banner {
  width: 100%;
  height: 420px;
  background: linear-gradient(rgba(9, 11, 15, 0.4) 0%, rgba(9, 11, 15, 0.9) 100%), 
              radial-gradient(ellipse at center, rgba(255, 107, 0, 0.15) 0%, transparent 70%),
              url('https://images.unsplash.com/photo-1508098682722-e99c43a406b2?q=80&w=1200&auto=format&fit=crop') no-repeat center center;
  background-size: cover;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  padding: 40px;
  box-shadow: var(--shadow-card);
}

.hero-banner::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, rgba(9, 11, 15, 0.85) 0%, rgba(9, 11, 15, 0.2) 60%, transparent 100%);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 600px;
}

.hero-badge {
  background: var(--accent-orange);
  color: white;
  padding: 6px 12px;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 15px;
}
.hero-badge.live {
  background: var(--color-live);
  animation: glow-pulse 2s infinite;
}
.hero-badge i {
  font-size: 0.6rem;
}

.hero-title {
  font-size: 2.8rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 15px;
  letter-spacing: -1px;
}

.hero-desc {
  color: var(--text-secondary);
  font-size: 1.05rem;
  margin-bottom: 25px;
}

.hero-meta {
  display: flex;
  gap: 20px;
  margin-bottom: 25px;
  color: var(--text-primary);
  font-size: 0.9rem;
}
.hero-meta span {
  display: flex;
  align-items: center;
  gap: 8px;
}
.hero-meta i {
  color: var(--accent-cyan);
}

.hero-actions-container {
  display: flex;
  gap: 15px;
}

/* --- Ticker / Informative bar --- */
.ticker-wrap {
  width: 100%;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
  overflow: hidden;
  height: 40px;
  display: flex;
  align-items: center;
}

.ticker-inner {
  display: flex;
  white-space: nowrap;
  animation: ticker 25s linear infinite;
}
.ticker-inner:hover {
  animation-play-state: paused;
}

.ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0 40px;
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 500;
}
.ticker-item i {
  color: var(--accent-cyan);
}
.ticker-item strong {
  color: var(--text-primary);
}

/* --- Event Finder: Search & Filters --- */
.filter-section {
  padding: 40px 0 20px;
}

.filter-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 30px;
}

.filter-categories {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 5px;
}
/* Hide scrollbar for categories mobile */
.filter-categories::-webkit-scrollbar {
  display: none;
}

.filter-pill {
  padding: 8px 18px;
  border-radius: var(--radius-lg);
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.9rem;
  white-space: nowrap;
}
.filter-pill:hover {
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, 0.2);
}
.filter-pill.active {
  background: var(--accent-cyan);
  color: var(--bg-primary);
  font-weight: 600;
  border-color: var(--accent-cyan);
  box-shadow: 0 0 12px rgba(0, 240, 255, 0.3);
}

.search-box {
  position: relative;
  width: 320px;
}
.search-box input {
  width: 100%;
  padding-left: 40px;
  border-radius: var(--radius-md);
  background: var(--bg-secondary);
}
.search-box i {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-secondary);
}

/* --- Event Grid Section --- */
.events-section {
  padding-bottom: 80px;
}

.events-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 30px;
}

/* Event Card Styles */
.event-card {
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: var(--transition-normal);
  box-shadow: var(--shadow-card);
  position: relative;
}

.event-card:hover {
  transform: translateY(-8px);
  border-color: var(--accent-cyan);
  box-shadow: var(--shadow-neon), var(--shadow-card);
}

.card-media {
  position: relative;
  width: 100%;
  height: 200px;
  background-size: cover;
  background-position: center;
  overflow: hidden;
}
.card-media::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, transparent 40%, rgba(18, 21, 28, 0.95) 100%);
}

.card-status-badge {
  position: absolute;
  top: 15px;
  left: 15px;
  z-index: 5;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: white;
}

.card-status-badge.live {
  background: var(--color-live);
}
.card-status-badge.live::before {
  content: '';
  width: 6px;
  height: 6px;
  background: white;
  border-radius: 50%;
  display: inline-block;
  animation: pulse-live 1.5s infinite;
}

.card-status-badge.upcoming {
  background: var(--color-upcoming);
}
.card-status-badge.finished {
  background: var(--color-finished);
}

.card-price-badge {
  position: absolute;
  top: 15px;
  right: 15px;
  z-index: 5;
  background: rgba(9, 11, 15, 0.85);
  border: 1px solid var(--border-color);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--accent-cyan);
}

.card-info {
  padding: 20px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.card-channel {
  color: var(--accent-orange);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 5px;
  letter-spacing: 1px;
}

.card-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 12px;
  line-height: 1.3;
}

.card-details {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 20px;
  color: var(--text-secondary);
  font-size: 0.85rem;
}
.card-details span {
  display: flex;
  align-items: center;
  gap: 8px;
}
.card-details i {
  color: var(--accent-cyan);
  width: 14px;
}

.card-actions {
  margin-top: auto;
}
.card-actions .btn-premium {
  width: 100%;
  justify-content: center;
}

/* --- Interactive Live Stream Section --- */
.stream-section {
  padding: 20px 0 60px;
}

.stream-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 30px;
  align-items: start;
}

@media (max-width: 992px) {
  .stream-layout {
    grid-template-columns: 1fr;
  }
}

.stream-player-container {
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-card);
}

.video-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  background: #000;
}

/* Fake Stream Player Elements */
.fake-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.video-overlay-static {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  pointer-events: none;
  padding: 15px;
  z-index: 10;
}

/* Premium Interactive Scoreboard Overlay */
.stream-scoreboard {
  background: rgba(9, 11, 15, 0.85);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  backdrop-filter: blur(8px);
  padding: 8px 15px;
  display: inline-flex;
  align-items: center;
  gap: 15px;
  align-self: flex-start;
  pointer-events: auto;
}

.scoreboard-team {
  font-weight: 700;
  font-size: 0.9rem;
}
.scoreboard-score {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: var(--accent-cyan);
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 1rem;
}
.scoreboard-time {
  font-size: 0.85rem;
  color: var(--text-secondary);
  border-left: 1px solid rgba(255, 255, 255, 0.15);
  padding-left: 15px;
  display: flex;
  align-items: center;
  gap: 5px;
}
.scoreboard-time.blinking::before {
  content: '';
  width: 5px;
  height: 5px;
  background: var(--color-live);
  border-radius: 50%;
  display: inline-block;
  animation: pulse-live 1.5s infinite;
}

/* Animated Screen Flash Events */
.stream-event-alert {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.8);
  background: rgba(0, 0, 0, 0.85);
  border: 2px solid var(--accent-orange);
  box-shadow: 0 0 30px var(--accent-orange-glow);
  padding: 20px 45px;
  border-radius: var(--radius-md);
  text-align: center;
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  z-index: 100;
  pointer-events: none;
}
.stream-event-alert.active {
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
}
.alert-title {
  color: var(--accent-orange);
  font-size: 2rem;
  font-weight: 900;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.alert-subtitle {
  color: var(--text-primary);
  font-size: 1.1rem;
  margin-top: 5px;
}

.flash-screen {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 50;
  pointer-events: none;
}
.flash-screen.flash-active {
  animation: goal-flash 2.5s ease-out;
}

/* Video Control bar */
.video-controls {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
  padding: 10px 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: auto;
}
.control-btn {
  color: white;
  font-size: 1.1rem;
}
.control-btn:hover {
  color: var(--accent-cyan);
}
.right-controls {
  display: flex;
  align-items: center;
  gap: 15px;
}
.live-indicator {
  background: var(--color-live);
  color: white;
  padding: 2px 8px;
  font-size: 0.75rem;
  font-weight: 700;
  border-radius: 3px;
  text-transform: uppercase;
}

/* Stream Info Area */
.stream-meta-info {
  padding: 20px;
}
.stream-title-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 15px;
}
.stream-title {
  font-size: 1.5rem;
  font-weight: 800;
}
.stream-viewers {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  padding: 5px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--accent-cyan);
}
.stream-desc {
  color: var(--text-secondary);
  font-size: 0.95rem;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 20px;
}

/* Stream Stats/Incidents Tabs */
.stream-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 20px;
}
.stream-tab-btn {
  padding: 10px 20px;
  color: var(--text-secondary);
  font-weight: 600;
  border-bottom: 2px solid transparent;
}
.stream-tab-btn.active {
  color: var(--accent-cyan);
  border-bottom-color: var(--accent-cyan);
}
.stream-tab-content {
  display: none;
}
.stream-tab-content.active {
  display: block;
}

/* Stats Progress bars */
.stats-row {
  display: flex;
  flex-direction: column;
  gap: 15px;
}
.stat-item {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.stat-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  font-weight: 600;
}
.stat-name {
  color: var(--text-secondary);
}
.stat-bar-container {
  display: flex;
  height: 8px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  overflow: hidden;
}
.stat-bar-left {
  background: var(--accent-orange);
  transition: width 0.5s ease-out;
}
.stat-bar-right {
  background: var(--accent-cyan);
  margin-left: auto;
  transition: width 0.5s ease-out;
}

/* Timeline Log */
.timeline-list {
  display: flex;
  flex-direction: column;
  gap: 15px;
  padding-left: 10px;
  border-left: 2px solid var(--bg-tertiary);
  margin-left: 10px;
}
.timeline-item {
  position: relative;
  padding-left: 15px;
  font-size: 0.9rem;
}
.timeline-item::before {
  content: '';
  position: absolute;
  left: -17px;
  top: 6px;
  width: 8px;
  height: 8px;
  background: var(--accent-cyan);
  border-radius: 50%;
}
.timeline-item.goal::before {
  background: var(--accent-orange);
  box-shadow: 0 0 8px var(--accent-orange-glow);
}
.timeline-time {
  font-weight: 700;
  color: var(--accent-cyan);
  margin-right: 5px;
}

/* --- Live Chat Section --- */
.stream-chat-container {
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  height: 600px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.chat-header {
  padding: 15px 20px;
  background: var(--bg-tertiary);
  border-bottom: 1px solid var(--border-color);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.chat-status {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  color: var(--color-live);
}
.chat-status::before {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--color-live);
  border-radius: 50%;
  animation: pulse-live 1.5s infinite;
}

.chat-messages {
  flex-grow: 1;
  padding: 20px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.chat-message-bubble {
  display: flex;
  flex-direction: column;
  gap: 2px;
  animation: slide-in 0.25s ease forwards;
}

.chat-user {
  font-size: 0.8rem;
  font-weight: 700;
}
.chat-text {
  background: var(--bg-tertiary);
  padding: 8px 12px;
  border-radius: 0 var(--radius-md) var(--radius-md) var(--radius-md);
  font-size: 0.85rem;
  border: 1px solid var(--border-color);
  align-self: flex-start;
  word-break: break-word;
}
.chat-message-bubble.mine {
  align-items: flex-end;
}
.chat-message-bubble.mine .chat-text {
  background: linear-gradient(135deg, rgba(0, 240, 255, 0.15), rgba(0, 240, 255, 0.05));
  border-color: rgba(0, 240, 255, 0.3);
  border-radius: var(--radius-md) 0 var(--radius-md) var(--radius-md);
  align-self: flex-end;
}

.chat-input-area {
  padding: 15px 20px;
  background: var(--bg-tertiary);
  border-top: 1px solid var(--border-color);
  display: flex;
  gap: 10px;
}
.chat-input-area input {
  flex-grow: 1;
  border-radius: var(--radius-lg);
  background: var(--bg-secondary);
}
.chat-input-area .btn-send {
  background: var(--accent-cyan);
  color: var(--bg-primary);
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.2);
}
.chat-input-area .btn-send:hover {
  transform: scale(1.05);
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.4);
}

/* --- Checkout / Payment Modal --- */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: var(--transition-normal);
}
.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.checkout-modal {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-card);
  position: relative;
  transform: translateY(30px);
  transition: var(--transition-normal);
}
.modal-overlay.active .checkout-modal {
  transform: translateY(0);
}

.modal-close-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  color: var(--text-secondary);
  font-size: 1.5rem;
}
.modal-close-btn:hover {
  color: var(--text-primary);
}

.modal-header {
  padding: 30px 30px 20px;
  border-bottom: 1px solid var(--border-color);
}
.modal-title {
  font-size: 1.4rem;
  font-weight: 800;
}
.modal-subtitle {
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin-top: 5px;
}

.modal-body {
  padding: 30px;
}

/* Form Steps */
.checkout-step {
  display: none;
}
.checkout-step.active {
  display: block;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 20px;
}
.form-group label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-secondary);
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

/* Payment Selectors */
.payment-selectors {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.payment-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 15px 20px;
  cursor: pointer;
  transition: var(--transition-fast);
}
.payment-option:hover {
  border-color: var(--accent-cyan);
}
.payment-option.selected {
  border-color: var(--accent-cyan);
  background: rgba(0, 240, 255, 0.05);
}
.payment-left {
  display: flex;
  align-items: center;
  gap: 15px;
}
.payment-left i {
  font-size: 1.5rem;
  color: var(--accent-cyan);
  width: 25px;
  text-align: center;
}
.payment-title {
  font-weight: 700;
  font-size: 0.95rem;
}
.payment-desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: 2px;
}
.payment-radio {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
}
.payment-option.selected .payment-radio::after {
  content: '';
  width: 10px;
  height: 10px;
  background: var(--accent-cyan);
  border-radius: 50%;
}

.checkout-summary {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 15px;
  margin-bottom: 25px;
  font-size: 0.9rem;
}
.summary-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
}
.summary-row.total {
  border-top: 1px solid var(--border-color);
  padding-top: 10px;
  margin-bottom: 0;
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--accent-orange);
}

/* Spinner Loader */
.loader-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 0;
  text-align: center;
}
.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid rgba(0, 240, 255, 0.1);
  border-top-color: var(--accent-cyan);
  border-radius: 50%;
  animation: ticker 1s linear infinite;
  margin-bottom: 20px;
}

/* Success Card with QR */
.success-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.success-icon {
  width: 60px;
  height: 60px;
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  margin-bottom: 20px;
  border: 1px solid rgba(16, 185, 129, 0.3);
}
.ticket-card-mock {
  background: white;
  color: black;
  border-radius: var(--radius-md);
  width: 100%;
  max-width: 320px;
  padding: 20px;
  margin: 20px 0;
  box-shadow: 0 10px 25px rgba(0,0,0,0.15);
  display: flex;
  flex-direction: column;
  align-items: center;
  border-bottom: 4px dashed var(--accent-orange);
}
.ticket-qr {
  width: 140px;
  height: 140px;
  margin: 15px 0;
}
.ticket-code {
  font-family: monospace;
  font-weight: 800;
  background: #f3f4f6;
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 1rem;
  letter-spacing: 1px;
}
.ticket-event-name {
  font-weight: 800;
  font-size: 1.05rem;
  text-align: center;
  margin-top: 5px;
}

/* --- Admin / Organizer Dashboard --- */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 30px;
  align-items: start;
}

@media (max-width: 992px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

.dashboard-panel {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 25px;
  box-shadow: var(--shadow-card);
}
.panel-title {
  font-size: 1.25rem;
  font-weight: 800;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 10px;
}

/* Organizer Controllers */
.control-section {
  margin-bottom: 25px;
}
.control-section h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.score-control-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  padding: 15px;
  border-radius: var(--radius-md);
  margin-bottom: 15px;
}
.control-team-name {
  font-weight: 700;
  max-width: 120px;
}
.score-adjuster {
  display: flex;
  align-items: center;
  gap: 12px;
}
.btn-adjust {
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border-color);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}
.btn-adjust:hover {
  background: var(--accent-cyan);
  color: var(--bg-primary);
}
.score-display-val {
  font-size: 1.3rem;
  font-weight: 800;
  min-width: 25px;
  text-align: center;
}

.timer-controls {
  display: flex;
  gap: 10px;
  margin-bottom: 15px;
}
.timer-controls .btn-premium {
  flex-grow: 1;
  justify-content: center;
}

.incident-buttons {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.incident-buttons button {
  justify-content: center;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
}
.incident-buttons button:hover {
  border-color: var(--accent-orange);
  color: var(--accent-orange);
}

.dashboard-stats-summary {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  margin-bottom: 30px;
}
.stat-card {
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 15px;
  text-align: center;
}
.stat-card-val {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--accent-cyan);
}
.stat-card-lbl {
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-top: 5px;
}

/* Event List table inside dashboard */
.dash-events-table {
  width: 100%;
  border-collapse: collapse;
}
.dash-events-table th,
.dash-events-table td {
  padding: 12px 15px;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}
.dash-events-table th {
  font-size: 0.8rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  font-weight: 700;
}
.dash-events-table tr:hover {
  background: rgba(255,255,255,0.02);
}

/* OBS Link Display */
.obs-link-box {
  background: var(--bg-tertiary);
  border: 1px solid var(--accent-cyan);
  border-radius: var(--radius-md);
  padding: 15px;
  margin-top: 25px;
}
.obs-link-title {
  color: var(--accent-cyan);
  font-weight: 700;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 8px;
}
.obs-url-row {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}
.obs-url-input {
  flex-grow: 1;
  background: var(--bg-primary);
  border-color: var(--border-color);
  font-family: monospace;
  font-size: 0.8rem;
  padding: 6px 10px;
  color: var(--text-secondary);
}
.btn-copy {
  padding: 6px 12px;
}

/* --- Floating WhatsApp Widget --- */
.wsp-widget {
  position: fixed;
  bottom: 25px;
  right: 25px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  font-family: var(--font-primary);
}

.wsp-banner {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  width: 320px;
  padding: 20px;
  box-shadow: var(--shadow-card);
  margin-bottom: 15px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  animation: slide-in 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
  transform-origin: bottom right;
}
.wsp-banner.hidden {
  display: none;
}

.wsp-banner-close {
  position: absolute;
  top: 10px;
  right: 15px;
  color: var(--text-muted);
  font-size: 1.2rem;
}
.wsp-banner-close:hover {
  color: var(--text-primary);
}

.wsp-banner-header {
  display: flex;
  align-items: center;
  gap: 10px;
}
.wsp-avatar {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  background: var(--accent-cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bg-primary);
}
.wsp-name {
  font-weight: 700;
  font-size: 0.95rem;
}
.wsp-status {
  font-size: 0.75rem;
  color: #10b981;
}

.wsp-banner-text {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

.wsp-chat-btn {
  background: #25d366;
  color: black;
  font-weight: 700;
  font-size: 0.85rem;
  padding: 8px 15px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 5px 15px rgba(37, 211, 102, 0.25);
}
.wsp-chat-btn:hover {
  box-shadow: 0 8px 20px rgba(37, 211, 102, 0.4);
  transform: translateY(-1px);
}

.wsp-trigger-btn {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: #25d366;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  box-shadow: 0 8px 25px rgba(37, 211, 102, 0.35);
  animation: float 4s ease-in-out infinite;
}
.wsp-trigger-btn:hover {
  transform: scale(1.08);
}
.wsp-trigger-btn.active {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-card);
}

/* --- Footer --- */
.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 60px 0 30px;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

.footer-info-col {
  display: flex;
  flex-direction: column;
  gap: 15px;
}
.footer-logo {
  font-weight: 800;
  font-size: 1.4rem;
  color: var(--text-primary);
}
.footer-logo span {
  color: var(--accent-orange);
}
.footer-socials {
  display: flex;
  gap: 15px;
  margin-top: 10px;
}
.social-link {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-tertiary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
}
.social-link:hover {
  background: var(--accent-cyan);
  color: var(--bg-primary);
  border-color: var(--accent-cyan);
  transform: translateY(-2px);
}

.footer-col h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 20px;
}
.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.footer-col a:hover {
  color: var(--accent-cyan);
}

.footer-bottom {
  border-top: 1px solid var(--border-color);
  padding-top: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  font-size: 0.8rem;
}

/* --- OBS Transparent Screen Overlay --- */
.obs-overlay-body {
  background: transparent !important;
  color: white;
  overflow: hidden;
}

.obs-canvas {
  width: 1920px;
  height: 1080px;
  position: relative;
  overflow: hidden;
  transform-origin: top left;
}

.obs-hud {
  position: absolute;
  top: 40px;
  left: 50px;
  z-index: 10;
  background: rgba(9, 11, 15, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 15px 30px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 30px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.6);
  font-family: var(--font-primary);
}

.obs-hud-team {
  font-weight: 800;
  font-size: 1.6rem;
  letter-spacing: -0.5px;
}
.obs-hud-team.home {
  text-align: right;
}
.obs-hud-score {
  background: #000;
  border: 2px solid rgba(0, 240, 255, 0.4);
  color: var(--accent-cyan);
  font-weight: 900;
  font-size: 2.2rem;
  padding: 4px 18px;
  border-radius: 6px;
  min-width: 80px;
  text-align: center;
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.2);
}
.obs-hud-meta {
  border-left: 2px solid rgba(255, 255, 255, 0.2);
  padding-left: 25px;
}
.obs-hud-period {
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--accent-orange);
}
.obs-hud-time {
  font-size: 1.4rem;
  font-weight: 800;
}

.obs-alert {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.7);
  background: rgba(9, 11, 15, 0.95);
  border: 3px solid var(--accent-orange);
  box-shadow: 0 0 50px rgba(255, 107, 0, 0.5);
  padding: 40px 80px;
  border-radius: var(--radius-lg);
  text-align: center;
  opacity: 0;
  transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  z-index: 100;
}
.obs-alert.active {
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
}
.obs-alert-title {
  color: var(--accent-orange);
  font-size: 5rem;
  font-weight: 900;
  letter-spacing: 6px;
  text-shadow: 0 0 20px var(--accent-orange-glow);
  margin-bottom: 10px;
}
.obs-alert-subtitle {
  font-size: 2.2rem;
  font-weight: 600;
}

.obs-bg-flash {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 5;
  pointer-events: none;
}
.obs-bg-flash.active {
  animation: goal-flash 3s ease-out;
}

/* Responsiveness adjustments for smaller devices */
@media (max-width: 768px) {
  main {
    padding-top: 70px;
  }
  .hero-banner {
    height: auto;
    min-height: 380px;
    padding: 25px;
    align-items: center;
  }
  .hero-title {
    font-size: 2rem;
  }
  .hero-actions-container {
    flex-direction: column;
  }
  .site-header {
    height: 70px;
  }
  .nav-links {
    display: none; /* Add JS toggling in html later if needed, otherwise dashboard/my tickets are accessible */
  }
  .menu-toggle {
    display: block;
  }
}
