/* 
 * BK365 Premium Responsive Web Design System
 * File: styles.css
 * Author: Antigravity AI
 */

/* ==========================================
   1. VARIABLES & DESIGN SYSTEM TOKENS
   ========================================== */
:root {
  /* Color Palette - Premium Dark Gaming Mode */
  --bg-primary: #0b0c10;
  --bg-secondary: #12131a;
  --bg-card: #171923;
  --bg-card-hover: #1f2231;
  --border-color: #222533;
  --border-glow: rgba(114, 9, 183, 0.25);
  
  /* Text Colors */
  --text-primary: #ffffff;
  --text-secondary: #8e94a5;
  --text-muted: #53586a;
  
  /* Accent Colors */
  --primary-purple: #7209b7;
  --primary-purple-light: #8f00ff;
  --primary-purple-glow: rgba(114, 9, 183, 0.45);
  
  --primary-gold: #c9a063;
  --primary-gold-light: #e5ba73;
  --primary-gold-glow: rgba(201, 160, 99, 0.4);
  
  --primary-red: #b7092b;
  --primary-red-light: #e63946;
  --primary-red-glow: rgba(183, 9, 43, 0.4);

  --primary-green: #10b981;
  --primary-green-glow: rgba(16, 185, 129, 0.3);
  
  /* Gradients */
  --grad-purple: linear-gradient(135deg, #7209b7 0%, #3f37c9 100%);
  --grad-gold: linear-gradient(135deg, #c9a063 0%, #8a642d 100%);
  --grad-red: linear-gradient(135deg, #b7092b 0%, #720000 100%);
  --grad-dark: linear-gradient(180deg, #171923 0%, #12131a 100%);
  --grad-glass: linear-gradient(135deg, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0.01) 100%);
  
  /* Sizing and Layout */
  --sidebar-width: 240px;
  --right-sidebar-width: 280px;
  --header-height: 90px;
  --border-radius-sm: 4px;
  --border-radius-md: 8px;
  --border-radius-lg: 16px;
  --border-radius-xl: 24px;
  
  /* Shadows */
  --shadow-neon-purple: 0 0 15px rgba(114, 9, 183, 0.3);
  --shadow-neon-gold: 0 0 15px rgba(201, 160, 99, 0.25);
  --shadow-card: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
  
  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ==========================================
   2. RESET & BASE ELEMENTS
   ========================================== */
*, *::before, *::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: 'Outfit', 'Inter', 'Microsoft YaHei', sans-serif;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Scrollbar styling */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: #1f2231;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-purple);
  box-shadow: var(--shadow-neon-purple);
}

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

button {
  background: none;
  border: none;
  color: inherit;
  font: inherit;
  cursor: pointer;
  outline: none;
  transition: var(--transition-fast);
}

input, select {
  font: inherit;
  background: none;
  border: none;
  outline: none;
}

/* ==========================================
   3. APP CONTAINER LAYOUT
   ========================================== */
.app-container {
  display: flex;
  min-height: 100vh;
  position: relative;
  overflow: hidden;
}

/* Left Sidebar */
.sidebar {
  width: var(--sidebar-width);
  background-color: var(--bg-secondary);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 100;
  transition: var(--transition-normal);
  overflow-y: auto;
  scrollbar-width: none; /* Firefox */
}

.sidebar::-webkit-scrollbar {
  display: none; /* Safari & Chrome */
}

/* Brand Logo Box */
.brand-box {
  height: 70px;
  display: flex;
  align-items: center;
  padding: 0 24px;
  gap: 10px;
  border-bottom: 1px solid var(--border-color);
}

.brand-logo-icon {
  font-size: 24px;
  background: var(--grad-gold);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 5px rgba(201, 160, 99, 0.4));
}

.brand-name {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 1px;
  background: linear-gradient(to right, #ffffff, #c9a063);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Nav Section Wrapper */
.nav-section {
  padding: 20px 0;
  border-bottom: 1px solid var(--border-color);
}

.nav-section-title {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 0 24px;
  margin-bottom: 12px;
}

/* Nav Lists */
.nav-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.nav-item a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  border-left: 3px solid transparent;
  transition: var(--transition-normal);
}

.nav-item-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-item-content i {
  font-size: 16px;
  width: 20px;
  text-align: center;
  transition: var(--transition-fast);
}

.nav-item-arrow {
  font-size: 10px;
  color: var(--text-muted);
  transition: var(--transition-fast);
}

/* Nav Item Hover and Active States */
.nav-item:hover a,
.nav-item.active a {
  color: var(--text-primary);
  background-color: rgba(255, 255, 255, 0.02);
}

.nav-item:hover .nav-item-content i,
.nav-item.active .nav-item-content i {
  color: var(--primary-purple-light);
  text-shadow: 0 0 8px var(--primary-purple-glow);
}

.nav-item:hover .nav-item-arrow {
  color: var(--text-primary);
  transform: translateX(3px);
}

.nav-item.active a {
  border-left-color: var(--primary-purple);
  background: linear-gradient(to right, rgba(114, 9, 183, 0.06), transparent);
}

/* Main Wrapper */
.main-wrapper {
  margin-left: var(--sidebar-width);
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

/* ==========================================
   4. HEADER COMPONENTS
   ========================================== */
.header {
  height: var(--header-height);
  background-color: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 90;
  display: flex;
  flex-direction: column;
}

/* Header Announcement Ticker */
.header-ticker {
  height: 30px;
  background-color: #0d0e14;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  font-size: 12px;
  color: var(--text-secondary);
}

.ticker-left {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.ticker-left i {
  color: var(--primary-gold);
}

.ticker-marquee-box {
  flex: 1;
  overflow: hidden;
  position: relative;
  white-space: nowrap;
}

.ticker-marquee {
  display: inline-block;
  padding-left: 100%;
  animation: marquee 25s linear infinite;
}

.ticker-marquee span {
  font-weight: 500;
  padding-right: 50px;
}

.ticker-marquee span strong {
  color: var(--primary-gold);
}

.ticker-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.ticker-right a {
  color: var(--text-muted);
}

.ticker-right a:hover {
  color: var(--text-primary);
}

/* Header Main Bar */
.header-main {
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
}

/* Horizontal Nav Links */
.header-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 100%;
}

.header-nav-link {
  padding: 0 16px;
  height: 100%;
  display: flex;
  align-items: center;
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 14px;
  position: relative;
  transition: var(--transition-fast);
}

.header-nav-link:hover,
.header-nav-link.active {
  color: var(--text-primary);
}

.header-nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 3px;
  background-color: var(--primary-purple);
  box-shadow: var(--shadow-neon-purple);
  transition: var(--transition-fast);
}

.header-nav-link:hover::after,
.header-nav-link.active::after {
  width: 70%;
}

/* Highlight Navigation Button in Purple Pill */
.nav-purple-pill {
  background: var(--grad-purple);
  color: var(--text-primary) !important;
  border-radius: 50px;
  height: 36px !important;
  padding: 0 20px !important;
  box-shadow: var(--shadow-neon-purple);
}

.nav-purple-pill::after {
  display: none !important;
}

.nav-purple-pill:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 20px rgba(114, 9, 183, 0.6);
}

/* Header Actions / User Panel */
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-login {
  background-color: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 8px 18px;
  border-radius: var(--border-radius-md);
  font-size: 14px;
  font-weight: 600;
}

.btn-login:hover {
  border-color: var(--text-secondary);
  color: var(--text-primary);
}

.btn-register {
  background: var(--grad-red);
  color: var(--text-primary);
  padding: 8px 20px;
  border-radius: var(--border-radius-md);
  font-size: 14px;
  font-weight: 600;
  box-shadow: var(--shadow-neon-red);
}

.btn-register:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 20px rgba(183, 9, 43, 0.6);
}

/* Logged In User Status UI (Simulated) */
.user-panel {
  display: none; /* Toggled via JavaScript */
  align-items: center;
  gap: 20px;
}

.user-balance-box {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.balance-title {
  font-size: 10px;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
}

.balance-amount {
  font-size: 16px;
  font-weight: 700;
  color: var(--primary-gold);
  font-family: 'Outfit', sans-serif;
}

.btn-deposit {
  background: var(--grad-purple);
  color: var(--text-primary);
  padding: 8px 18px;
  border-radius: var(--border-radius-md);
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-deposit:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-neon-purple);
}

.user-profile-dropdown {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  position: relative;
  padding: 4px 8px;
  border-radius: var(--border-radius-md);
}

.user-profile-dropdown:hover {
  background-color: rgba(255, 255, 255, 0.04);
}

.user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: var(--primary-purple);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  border: 2px solid var(--border-color);
}

.user-profile-info {
  display: flex;
  flex-direction: column;
}

.profile-username {
  font-size: 13px;
  font-weight: 600;
}

.profile-vip-tag {
  font-size: 9px;
  background: var(--grad-gold);
  color: #000;
  font-weight: 800;
  padding: 1px 4px;
  border-radius: 3px;
  width: max-content;
  margin-top: 1px;
}

.dropdown-caret {
  font-size: 10px;
  color: var(--text-muted);
}

/* User dropdown popup menu */
.profile-menu {
  position: absolute;
  top: 100%;
  right: 0;
  width: 180px;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-md);
  box-shadow: var(--shadow-card);
  padding: 8px 0;
  margin-top: 8px;
  display: none;
  flex-direction: column;
  z-index: 120;
  animation: fadeIn 0.2s ease-out;
}

.profile-menu-item {
  padding: 10px 16px;
  font-size: 13px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 10px;
  transition: var(--transition-fast);
}

.profile-menu-item:hover {
  color: var(--text-primary);
  background-color: var(--bg-card-hover);
}

.profile-menu-item i {
  width: 16px;
  text-align: center;
}

.profile-menu-item.logout {
  border-top: 1px solid var(--border-color);
  color: var(--primary-red-light);
}

.profile-menu-item.logout:hover {
  background-color: rgba(183, 9, 43, 0.05);
}

/* Mobile Toggle Menu Icon */
.mobile-nav-toggle {
  display: none;
  font-size: 22px;
  color: var(--text-primary);
}

/* ==========================================
   5. CONTENT GRID & SIDEBARS
   ========================================== */
.content-layout {
  display: flex;
  padding: 24px;
  gap: 24px;
  flex: 1;
}

.main-content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 36px;
}

.right-sidebar {
  width: var(--right-sidebar-width);
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* ==========================================
   6. MAIN CONTENT CARDS & SECTIONS
   ========================================== */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.section-title {
  font-size: 18px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: 0.5px;
}

.section-title i {
  color: var(--primary-purple-light);
}

.section-title span.brand-tag {
  font-size: 11px;
  font-weight: 800;
  color: var(--primary-gold);
  background-color: rgba(201, 160, 99, 0.08);
  padding: 3px 8px;
  border-radius: 4px;
  border: 1px solid rgba(201, 160, 99, 0.15);
  text-transform: uppercase;
}

.section-more-btn {
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}

.section-more-btn:hover {
  color: var(--text-primary);
  transform: translateX(3px);
}

/* ==========================================
   HERO BANNER CAROUSEL
   ========================================== */
.hero-carousel {
  position: relative;
  height: 350px;
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-card);
}

.carousel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity var(--transition-slow) ease-in-out, transform var(--transition-slow) ease-in-out;
  transform: scale(1.02);
  pointer-events: none;
  background-size: cover;
  background-position: center;
}

.carousel-slide.active {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

/* Dark overlay for text readability */
.carousel-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, rgba(11, 12, 16, 0.9) 0%, rgba(11, 12, 16, 0.4) 50%, rgba(0,0,0,0) 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 60px;
  z-index: 10;
}

/* Custom Ribbon Badges */
.carousel-badge {
  background: var(--grad-red);
  color: var(--text-primary);
  font-size: 11px;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 4px;
  width: max-content;
  margin-bottom: 16px;
  letter-spacing: 1px;
  text-transform: uppercase;
  box-shadow: 0 0 10px rgba(183, 9, 43, 0.4);
}

.carousel-title {
  font-size: 38px;
  font-weight: 800;
  line-height: 1.2;
  margin: 0 0 12px 0;
  letter-spacing: -0.5px;
  text-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
  background: linear-gradient(to right, #ffffff, #eaeaea, #c9a063);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.carousel-desc {
  font-size: 15px;
  color: var(--text-secondary);
  margin-bottom: 24px;
  max-width: 500px;
  line-height: 1.5;
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.5);
}

.carousel-cta-btn {
  background: var(--grad-purple);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 700;
  padding: 12px 30px;
  border-radius: var(--border-radius-md);
  width: max-content;
  box-shadow: var(--shadow-neon-purple);
}

.carousel-cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 25px rgba(114, 9, 183, 0.7);
}

/* Slide Indicator Dots */
.carousel-dots {
  position: absolute;
  bottom: 20px;
  left: 60px;
  display: flex;
  gap: 8px;
  z-index: 20;
}

.carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.3);
  transition: var(--transition-fast);
}

.carousel-dot.active {
  width: 24px;
  border-radius: 10px;
  background-color: var(--primary-purple-light);
  box-shadow: var(--shadow-neon-purple);
}

/* Prev/Next Navigation Controls */
.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background-color: rgba(18, 19, 26, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(5px);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  z-index: 20;
  opacity: 0;
  transition: var(--transition-normal);
}

.hero-carousel:hover .carousel-btn {
  opacity: 1;
}

.carousel-btn:hover {
  background-color: var(--primary-purple);
  border-color: var(--primary-purple-light);
  box-shadow: var(--shadow-neon-purple);
  transform: translateY(-50%) scale(1.05);
}

.carousel-btn-prev { left: 20px; }
.carousel-btn-next { right: 20px; }

/* ==========================================
   POPULAR SPORTS GRID
   ========================================== */
.sports-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.sports-card {
  position: relative;
  height: 170px;
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  background: var(--grad-dark);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-card);
  display: flex;
  transition: var(--transition-normal);
}

.sports-card:hover {
  transform: translateY(-5px);
  border-color: var(--primary-purple-glow);
  box-shadow: 0 10px 25px rgba(114, 9, 183, 0.15);
}

.sports-card-info {
  flex: 1.2;
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  z-index: 2;
}

.sports-card-badge {
  font-size: 10px;
  font-weight: 800;
  color: var(--primary-gold);
  text-transform: uppercase;
  margin-bottom: 6px;
  letter-spacing: 1px;
}

.sports-card-title {
  font-size: 22px;
  font-weight: 800;
  margin: 0 0 6px 0;
  background: linear-gradient(to right, #ffffff, #cccccc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.sports-card-subtitle {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
}

.sports-card-btn {
  background-color: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 700;
  padding: 6px 16px;
  border-radius: 30px;
  width: max-content;
  display: flex;
  align-items: center;
  gap: 6px;
}

.sports-card:hover .sports-card-btn {
  background: var(--grad-purple);
  border-color: var(--primary-purple-light);
  color: var(--text-primary);
  box-shadow: var(--shadow-neon-purple);
}

.sports-card-graphics {
  flex: 1;
  position: relative;
  overflow: hidden;
  background-size: cover;
  background-position: center;
}

/* CSS-based player graphics masking for 3D effects */
.sports-card-graphics::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, #12131a 0%, transparent 100%);
}

.sports-card-image {
  position: absolute;
  right: -10px;
  bottom: -10px;
  height: 110%;
  object-fit: contain;
  transition: var(--transition-slow);
  filter: drop-shadow(0 5px 15px rgba(0,0,0,0.5));
}

.sports-card:hover .sports-card-image {
  transform: scale(1.08) rotate(-1deg);
  filter: drop-shadow(0 10px 20px rgba(114, 9, 183, 0.3));
}

/* ==========================================
   PG SOFT SLOT GAMES GRID
   ========================================== */
.games-grid-6 {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
}

.game-card-rounded {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-lg);
  padding: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: var(--transition-normal);
  cursor: pointer;
  position: relative;
}

.game-card-rounded:hover {
  transform: translateY(-5px);
  background-color: var(--bg-card-hover);
  border-color: var(--primary-purple-glow);
  box-shadow: 0 8px 24px rgba(114, 9, 183, 0.15);
}

.game-icon-box {
  width: 100%;
  aspect-ratio: 1;
  border-radius: var(--border-radius-md);
  overflow: hidden;
  position: relative;
  margin-bottom: 12px;
  border: 1px solid var(--border-color);
  background-color: #0b0c10;
}

.game-icon-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition-normal);
}

.game-card-rounded:hover .game-icon-image {
  transform: scale(1.1);
}

/* Game Branding Badge (PG tag in the bottom right corner of icon) */
.game-brand-tag {
  position: absolute;
  bottom: 6px;
  right: 6px;
  background-color: rgba(0, 0, 0, 0.85);
  color: var(--primary-gold);
  border: 1px solid rgba(201, 160, 99, 0.4);
  font-size: 8px;
  font-weight: 800;
  padding: 2px 5px;
  border-radius: 3px;
  letter-spacing: 0.5px;
  z-index: 5;
}

.game-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  width: 100%;
}

.game-hover-play {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(11, 12, 16, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: var(--transition-fast);
  border-radius: var(--border-radius-md);
  z-index: 10;
}

.game-icon-box:hover .game-hover-play {
  opacity: 1;
}

.play-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--grad-purple);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 18px;
  box-shadow: var(--shadow-neon-purple);
  transform: scale(0.8);
  transition: var(--transition-fast);
}

.game-icon-box:hover .play-circle {
  transform: scale(1);
}

.play-circle:hover {
  background: var(--primary-purple-light);
  transform: scale(1.1) !important;
}

/* ==========================================
   KY CHESS & CARDS GRID
   ========================================== */
.games-grid-5 {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
}

.game-card-wide {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: var(--transition-normal);
  cursor: pointer;
  height: 180px;
}

.game-card-wide:hover {
  transform: translateY(-5px);
  background-color: var(--bg-card-hover);
  border-color: var(--primary-gold-glow);
  box-shadow: 0 8px 24px rgba(201, 160, 99, 0.1);
}

.game-wide-image-box {
  flex: 1;
  position: relative;
  overflow: hidden;
  background-color: #0b0c10;
}

.game-wide-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition-normal);
}

.game-card-wide:hover .game-wide-image {
  transform: scale(1.08) rotate(1deg);
}

.game-card-wide-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to top, rgba(11, 12, 16, 0.9) 0%, rgba(11, 12, 16, 0.2) 60%, transparent 100%);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 12px;
}

.game-wide-title-badge {
  background-color: rgba(201, 160, 99, 0.9);
  color: #000;
  font-weight: 800;
  font-size: 11px;
  padding: 4px 12px;
  border-radius: 30px;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
  text-shadow: none;
}

.game-card-wide:hover .game-wide-title-badge {
  background: var(--grad-gold);
  transform: scale(1.05);
}

.game-card-wide-footer {
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-top: 1px solid var(--border-color);
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 600;
}

.game-card-wide:hover .game-card-wide-footer {
  color: var(--text-primary);
}

/* ==========================================
   ALLBET LIVE CASINO ROUND BADGES
   ========================================== */
.live-allbet-grid {
  display: flex;
  justify-content: space-around;
  gap: 16px;
}

.live-badge-circle {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: var(--transition-normal);
}

.badge-circle-outer {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1f2231 0%, #0b0c10 100%);
  border: 2px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  box-shadow: var(--shadow-card);
  transition: var(--transition-normal);
}

.badge-circle-outer::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  border-radius: 50%;
  background: var(--grad-gold);
  z-index: -1;
  opacity: 0;
  transition: var(--transition-normal);
}

.live-badge-circle:hover .badge-circle-outer {
  transform: translateY(-5px) scale(1.05);
  border-color: transparent;
  box-shadow: var(--shadow-neon-gold);
}

.live-badge-circle:hover .badge-circle-outer::before {
  opacity: 1;
}

.badge-circle-icon {
  font-size: 32px;
  background: var(--grad-gold);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
}

.badge-circle-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-secondary);
  transition: var(--transition-fast);
}

.live-badge-circle:hover .badge-circle-title {
  color: var(--primary-gold-light);
  text-shadow: var(--shadow-neon-gold);
}

/* ==========================================
   DB LIVE DEALERS GRID
   ========================================== */
.dealers-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
}

.dealer-card {
  height: 230px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
  cursor: pointer;
  transition: var(--transition-normal);
}

.dealer-card:hover {
  transform: translateY(-6px);
  border-color: var(--primary-purple-glow);
  box-shadow: 0 10px 25px rgba(114, 9, 183, 0.18);
}

.dealer-photo-box {
  flex: 1;
  position: relative;
  overflow: hidden;
  background: #090a0f;
}

.dealer-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: var(--transition-slow);
}

.dealer-card:hover .dealer-photo {
  transform: scale(1.06);
}

/* Glowing green pulse for live dealers */
.dealer-live-pulse {
  position: absolute;
  top: 10px;
  left: 10px;
  background-color: rgba(16, 185, 129, 0.85);
  color: #fff;
  font-size: 9px;
  font-weight: 800;
  padding: 2px 8px 2px 18px;
  border-radius: 20px;
  backdrop-filter: blur(2px);
  z-index: 5;
  text-transform: uppercase;
}

.dealer-live-pulse::before {
  content: '';
  position: absolute;
  left: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: #fff;
  animation: pulse 1.2s infinite;
}

.dealer-card-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(11, 12, 16, 0.95) 0%, rgba(11, 12, 16, 0.4) 70%, transparent 100%);
  padding: 16px 12px 12px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.dealer-name {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.dealer-game {
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
}

.dealer-card:hover .dealer-game {
  color: var(--primary-gold-light);
}

/* ==========================================
   PREMIUM LOTTERY GRID
   ========================================== */
.lottery-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
}

.lottery-badge {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  cursor: pointer;
  transition: var(--transition-normal);
}

.lottery-badge:hover {
  transform: translateY(-5px) scale(1.02);
  background-color: var(--bg-card-hover);
  border-color: var(--primary-purple-glow);
  box-shadow: 0 8px 24px rgba(114, 9, 183, 0.12);
}

.lottery-spherical-icon {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  margin-bottom: 12px;
  box-shadow: inset -5px -5px 15px rgba(0,0,0,0.6), 0 5px 15px rgba(0,0,0,0.4);
  position: relative;
  overflow: hidden;
  transition: var(--transition-normal);
}

/* Color codes for spheres */
.sphere-orange { background: radial-gradient(circle at 30% 30%, #ff9e00 0%, #e85d04 50%, #6a040f 100%); }
.sphere-purple { background: radial-gradient(circle at 30% 30%, #9d4edd 0%, #7b2cbf 50%, #240046 100%); }
.sphere-blue   { background: radial-gradient(circle at 30% 30%, #00b4d8 0%, #0077b6 50%, #03045e 100%); }
.sphere-red    { background: radial-gradient(circle at 30% 30%, #ff4d6d 0%, #c9184a 50%, #590d22 100%); }
.sphere-pink   { background: radial-gradient(circle at 30% 30%, #ff85a1 0%, #f72585 50%, #7209b7 100%); }
.sphere-teal   { background: radial-gradient(circle at 30% 30%, #2ec4b6 0%, #0f968c 50%, #014f47 100%); }

.lottery-spherical-icon::after {
  content: '';
  position: absolute;
  top: 4px;
  left: 10px;
  width: 50%;
  height: 25%;
  background: linear-gradient(to bottom, rgba(255,255,255,0.4), transparent);
  border-radius: 50%;
}

.lottery-badge:hover .lottery-spherical-icon {
  transform: rotate(15deg) scale(1.05);
}

.lottery-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.lottery-desc {
  font-size: 10px;
  color: var(--text-muted);
  font-weight: 600;
}

/* ==========================================
   7. RIGHT SIDEBAR COMPONENTS
   ========================================== */

/* Static Promotional Link Cards */
.sidebar-promo-card {
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  height: 80px;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-card);
  display: flex;
  align-items: center;
  padding: 0 20px;
  position: relative;
  cursor: pointer;
  transition: var(--transition-normal);
}

.sidebar-promo-card:hover {
  transform: translateY(-3px);
}

.sidebar-promo-card.green-card {
  background: linear-gradient(135deg, #0c2b18 0%, #06170c 100%);
  border-color: rgba(16, 185, 129, 0.2);
}

.sidebar-promo-card.green-card:hover {
  box-shadow: 0 5px 20px rgba(16, 185, 129, 0.2);
  border-color: var(--primary-green);
}

.sidebar-promo-card.red-card {
  background: linear-gradient(135deg, #3d0d0f 0%, #200506 100%);
  border-color: rgba(183, 9, 43, 0.2);
}

.sidebar-promo-card.red-card:hover {
  box-shadow: 0 5px 20px rgba(183, 9, 43, 0.2);
  border-color: var(--primary-red-light);
}

.promo-card-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--border-radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  margin-right: 14px;
  z-index: 2;
}

.green-card .promo-card-icon {
  background-color: rgba(16, 185, 129, 0.1);
  color: var(--primary-green);
}

.red-card .promo-card-icon {
  background-color: rgba(183, 9, 43, 0.1);
  color: var(--primary-red-light);
}

.promo-card-info {
  display: flex;
  flex-direction: column;
  z-index: 2;
}

.promo-card-title {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 2px;
}

.promo-card-desc {
  font-size: 11px;
  color: var(--text-secondary);
}

.sidebar-promo-card::after {
  content: '';
  position: absolute;
  right: -20px;
  bottom: -20px;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.02);
  z-index: 1;
}

/* System Announcement Widget */
.announcement-widget {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.widget-header {
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 700;
}

.announcement-widget .widget-header {
  background: linear-gradient(to right, #45090f, #1e0507);
  border-bottom: 1px solid rgba(183, 9, 43, 0.15);
  color: var(--primary-red-light);
}

.widget-body {
  padding: 16px 20px;
}

.announcement-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.announcement-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  border-bottom: 1px dashed var(--border-color);
  padding-bottom: 10px;
}

.announcement-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.announcement-item-date {
  font-size: 10px;
  color: var(--text-muted);
  font-weight: 600;
}

.announcement-item-text {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.announcement-item:hover .announcement-item-text {
  color: var(--text-primary);
}

/* ==========================================
   MOBILE APP PHONE SHOWCASE WIDGET
   ========================================== */
.mobile-app-widget {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Realistic 3D Mobile Phone Mockup */
.phone-mockup {
  width: 170px;
  height: 330px;
  background-color: #000;
  border: 4px solid #1f212a;
  border-radius: 28px;
  position: relative;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6), inset 0 0 10px rgba(255,255,255,0.05);
  overflow: hidden;
  margin-bottom: 16px;
}

/* Phone Speaker/Camera Notch */
.phone-notch {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 70px;
  height: 14px;
  background-color: #1f212a;
  border-bottom-left-radius: 10px;
  border-bottom-right-radius: 10px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.notch-speaker {
  width: 25px;
  height: 2px;
  background-color: #333;
  border-radius: 2px;
}

.notch-camera {
  width: 4px;
  height: 4px;
  background-color: #1e3a8a;
  border-radius: 50%;
}

/* Phone Screen Slide Area */
.phone-screen {
  width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden;
}

.phone-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.05);
  transition: opacity var(--transition-slow) ease-in-out, transform var(--transition-slow) ease-in-out;
}

.phone-slide.active {
  opacity: 1;
  transform: scale(1);
}

.phone-screen-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.4) 60%, transparent 100%);
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.phone-game-title {
  font-size: 11px;
  font-weight: 800;
  color: var(--primary-gold);
  margin-bottom: 2px;
  text-transform: uppercase;
}

.phone-game-desc {
  font-size: 9px;
  color: var(--text-secondary);
}

/* Mobile Showcase Brand Headers */
.app-showcase-title {
  font-size: 14px;
  font-weight: 800;
  color: #fff;
  margin-bottom: 4px;
  text-align: center;
}

.app-showcase-desc {
  font-size: 11px;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 16px;
}

/* Download App CTAs */
.app-download-btn {
  width: 100%;
  background: var(--grad-purple);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 10px 0;
  border-radius: var(--border-radius-md);
  text-align: center;
  margin-bottom: 12px;
  box-shadow: var(--shadow-neon-purple);
}

.app-download-btn:hover {
  background: var(--primary-purple-light);
  transform: translateY(-2px);
  box-shadow: 0 0 20px rgba(114, 9, 183, 0.5);
}

.download-badges {
  display: flex;
  gap: 8px;
  justify-content: center;
  width: 100%;
}

.download-badge-icon {
  flex: 1;
  background-color: #0b0c10;
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  border-radius: var(--border-radius-sm);
  padding: 6px 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 10px;
  font-weight: 600;
}

.download-badge-icon i {
  font-size: 14px;
}

.download-badge-icon:hover {
  border-color: var(--text-secondary);
  color: var(--text-primary);
}

/* ==========================================
   8. FOOTER COMPONENT
   ========================================== */
.footer {
  background-color: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 48px 24px 24px 24px;
  margin-top: 48px;
}

.footer-top {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 36px;
  margin-bottom: 24px;
}

.footer-brand {
  flex: 1.5;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.footer-brand-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 20px;
  font-weight: 800;
  color: #fff;
}

.footer-brand-title i {
  color: var(--primary-gold);
}

.footer-brand-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Gold Certificate Badge Shield */
.footer-badge-box {
  display: flex;
  align-items: center;
  gap: 12px;
  background-color: rgba(201, 160, 99, 0.03);
  border: 1px solid rgba(201, 160, 99, 0.08);
  padding: 10px 16px;
  border-radius: var(--border-radius-md);
  width: max-content;
}

.footer-badge-icon {
  font-size: 20px;
  color: var(--primary-gold);
  filter: drop-shadow(0 0 4px var(--primary-gold-glow));
}

.footer-badge-info {
  display: flex;
  flex-direction: column;
}

.badge-label {
  font-size: 9px;
  font-weight: 800;
  color: var(--primary-gold);
  text-transform: uppercase;
}

.badge-val {
  font-size: 12px;
  font-weight: 600;
  color: #fff;
}

/* Links Columns */
.footer-links-container {
  flex: 2.5;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.footer-column {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.footer-column-title {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.5px;
}

.footer-column-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-column-links a {
  font-size: 12px;
  color: var(--text-secondary);
}

.footer-column-links a:hover {
  color: var(--text-primary);
  transform: translateX(3px);
}

/* Contact Social Icon buttons */
.footer-social-row {
  display: flex;
  gap: 10px;
}

.footer-social-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}

.footer-social-btn:hover {
  background: var(--grad-purple);
  border-color: var(--primary-purple-light);
  color: #fff;
  box-shadow: var(--shadow-neon-purple);
  transform: scale(1.08);
}

/* Footer Bottom Bar */
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--text-muted);
}

.footer-copyright {
  font-weight: 500;
}

/* Odds System Dropdown Selection Selector */
.footer-odds-selector {
  position: relative;
}

.odds-select {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--border-radius-sm);
  cursor: pointer;
}

.odds-select:hover {
  border-color: var(--text-secondary);
  color: var(--text-primary);
}

/* ==========================================
   9. INTERACTIVE MODALS & PANELS (POPUP WINDOWS)
   ========================================== */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(11, 12, 16, 0.85);
  backdrop-filter: blur(8px);
  z-index: 200;
  display: none; /* Controlled via JS */
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: fadeIn 0.3s ease-out;
}

.modal-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-lg);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(114, 9, 183, 0.1);
  width: 100%;
  max-width: 440px;
  overflow: hidden;
  position: relative;
  animation: modalScaleUp 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-header-accent {
  height: 4px;
  background: var(--grad-purple);
  width: 100%;
}

.modal-body {
  padding: 32px;
}

.modal-close-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 20px;
  color: var(--text-muted);
}

.modal-close-btn:hover {
  color: #fff;
}

.modal-title {
  font-size: 24px;
  font-weight: 800;
  margin: 0 0 6px 0;
  background: linear-gradient(to right, #ffffff, #c9a063);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.modal-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

/* Custom form elements */
.form-group {
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.input-container {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 14px;
  font-size: 16px;
  color: var(--text-muted);
  pointer-events: none;
  transition: var(--transition-fast);
}

.form-input {
  width: 100%;
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: #fff;
  font-size: 14px;
  padding: 12px 14px 12px 42px;
  border-radius: var(--border-radius-md);
  transition: var(--transition-normal);
}

.form-input::placeholder {
  color: var(--text-muted);
}

.form-input:focus {
  border-color: var(--primary-purple);
  box-shadow: 0 0 10px rgba(114, 9, 183, 0.15), inset 0 0 5px rgba(0,0,0,0.5);
}

.form-input:focus ~ .input-icon {
  color: var(--primary-purple-light);
}

.form-options {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.remember-me {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.remember-me input {
  cursor: pointer;
}

.forgot-pwd-link {
  color: var(--primary-purple-light);
  font-weight: 600;
}

.forgot-pwd-link:hover {
  text-decoration: underline;
}

.btn-submit {
  width: 100%;
  background: var(--grad-purple);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  padding: 12px 0;
  border-radius: var(--border-radius-md);
  box-shadow: var(--shadow-neon-purple);
  margin-bottom: 20px;
}

.btn-submit:hover {
  background: var(--primary-purple-light);
  transform: translateY(-2px);
  box-shadow: 0 0 20px rgba(114, 9, 183, 0.6);
}

.modal-footer-text {
  font-size: 13px;
  color: var(--text-secondary);
  text-align: center;
}

.modal-footer-link {
  color: var(--primary-gold);
  font-weight: 700;
  margin-left: 4px;
}

.modal-footer-link:hover {
  text-decoration: underline;
  color: var(--primary-gold-light);
}

/* ==========================================
   DYNAMIC RECHARGE CENTER MODAL
   ========================================== */
.modal-card.recharge-card {
  max-width: 580px;
}

.recharge-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 24px;
}

.recharge-tab {
  flex: 1;
  padding: 12px 0;
  text-align: center;
  font-weight: 700;
  font-size: 14px;
  color: var(--text-secondary);
  position: relative;
}

.recharge-tab.active {
  color: var(--primary-purple-light);
}

.recharge-tab.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 2px;
  background-color: var(--primary-purple);
  box-shadow: var(--shadow-neon-purple);
}

.recharge-panel {
  display: none;
}

.recharge-panel.active {
  display: block;
}

.payment-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 20px;
}

.payment-item {
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-md);
  padding: 14px 10px;
  text-align: center;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  transition: var(--transition-fast);
}

.payment-item i {
  font-size: 20px;
  color: var(--text-secondary);
}

.payment-item span {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-secondary);
}

.payment-item.active {
  border-color: var(--primary-purple);
  background-color: rgba(114, 9, 183, 0.05);
}

.payment-item.active i,
.payment-item.active span {
  color: var(--primary-purple-light);
}

.amount-shortcut-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin-top: 8px;
}

.amount-btn {
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 700;
  padding: 8px 0;
  border-radius: var(--border-radius-sm);
}

.amount-btn:hover,
.amount-btn.active {
  border-color: var(--primary-gold);
  color: var(--primary-gold);
  background-color: rgba(201, 160, 99, 0.05);
}

/* ==========================================
   10. ANIMATION KEYFRAMES
   ========================================== */
@keyframes marquee {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-100%, 0, 0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes modalScaleUp {
  from { opacity: 0; transform: scale(0.9); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes pulse {
  0% { transform: translateY(-50%) scale(0.9); opacity: 0.6; }
  50% { transform: translateY(-50%) scale(1.3); opacity: 1; }
  100% { transform: translateY(-50%) scale(0.9); opacity: 0.6; }
}

/* ==========================================
   11. MEDIA QUERIES (RESPONSIVENESS)
   ========================================== */

/* Breakpoint 1200px: Right Sidebar Wraps Under Main Content */
@media (max-width: 1200px) {
  .content-layout {
    flex-direction: column;
    padding: 20px;
    gap: 20px;
  }
  
  .right-sidebar {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
  
  .mobile-app-widget {
    grid-column: span 2;
    flex-direction: row;
    justify-content: space-around;
    padding: 30px;
  }
  
  .phone-mockup {
    margin-bottom: 0;
  }
  
  .app-showcase-info {
    max-width: 320px;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }
  
  .app-showcase-title {
    text-align: left;
    font-size: 16px;
  }
  
  .app-showcase-desc {
    text-align: left;
    margin-bottom: 20px;
  }
}

/* Breakpoint 992px: Stacking cards grid columns slightly */
@media (max-width: 992px) {
  .games-grid-6 {
    grid-template-columns: repeat(4, 1fr);
  }
  
  .games-grid-5 {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .dealers-grid {
    grid-template-columns: repeat(4, 1fr);
  }
  
  .lottery-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Breakpoint 900px: Left Sidebar becomes hidden mobile drawer drawer */
@media (max-width: 900px) {
  .sidebar {
    transform: translateX(-100%);
    box-shadow: 10px 0 30px rgba(0,0,0,0.5);
  }
  
  .sidebar.mobile-open {
    transform: translateX(0);
  }
  
  .main-wrapper {
    margin-left: 0;
  }
  
  .mobile-nav-toggle {
    display: block;
    margin-right: 16px;
    cursor: pointer;
  }
  
  .header-main {
    justify-content: flex-start;
  }
  
  .header-nav {
    display: none; /* Hide top nav links, placed in sidebar or drawer */
  }
  
  .header-actions,
  .user-panel {
    margin-left: auto;
  }
  
  .hero-carousel {
    height: 280px;
  }
  
  .carousel-title {
    font-size: 28px;
  }
  
  .carousel-desc {
    font-size: 13px;
  }
}

/* Breakpoint 768px: Sports grid and others adjust */
@media (max-width: 768px) {
  .sports-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  
  .games-grid-6 {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .games-grid-5 {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .dealers-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .lottery-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .right-sidebar {
    grid-template-columns: 1fr;
  }
  
  .mobile-app-widget {
    grid-column: span 1;
    flex-direction: column;
    padding: 20px;
  }
  
  .phone-mockup {
    margin-bottom: 20px;
  }
  
  .app-showcase-info {
    max-width: 100%;
    align-items: center;
  }
  
  .app-showcase-title {
    text-align: center;
  }
  
  .app-showcase-desc {
    text-align: center;
  }
  
  .footer-top {
    flex-direction: column;
    gap: 30px;
  }
  
  .footer-links-container {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Breakpoint 576px: Ultra mobile adjustments */
@media (max-width: 576px) {
  .header-main {
    padding: 0 16px;
  }
  
  .content-layout {
    padding: 12px;
  }
  
  .hero-carousel {
    height: 220px;
  }
  
  .carousel-overlay {
    padding: 0 30px;
  }
  
  .carousel-dots,
  .carousel-dot {
    left: 30px;
  }
  
  .carousel-title {
    font-size: 22px;
  }
  
  .carousel-desc {
    display: none;
  }
  
  .carousel-badge {
    font-size: 9px;
    padding: 2px 8px;
    margin-bottom: 10px;
  }
  
  .games-grid-6 {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  
  .dealers-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  
  .lottery-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  
  .live-allbet-grid {
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .footer-links-container {
    grid-template-columns: 1fr;
  }
  
  .footer-bottom {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
}

/* ==========================================
   12. PRELOADER SYSTEM
   ========================================== */
.preloader {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #08090d;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.5s ease-out;
}

.preloader-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  max-width: 300px;
  width: 100%;
}

.preloader-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 28px;
  font-weight: 800;
  color: #fff;
  letter-spacing: 1px;
}

.preloader-logo i {
  background: var(--grad-gold);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 8px var(--primary-gold-glow));
  font-size: 32px;
}

.preloader-logo span {
  background: linear-gradient(to right, #ffffff, #c9a063);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.preloader-spinner-box {
  position: relative;
  width: 80px;
  height: 80px;
}

.preloader-spinner {
  position: absolute;
  width: 100%;
  height: 100%;
  border: 3px solid rgba(114, 9, 183, 0.1);
  border-top-color: var(--primary-purple);
  border-bottom-color: var(--primary-gold);
  border-radius: 50%;
  animation: preloader-spin 1.5s cubic-bezier(0.53, 0.21, 0.29, 0.67) infinite;
  box-shadow: 0 0 15px rgba(114, 9, 183, 0.1);
}

.preloader-progress-bar {
  width: 100%;
  height: 4px;
  background-color: rgba(255, 255, 255, 0.05);
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
}

.preloader-progress {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0;
  background: var(--grad-purple);
  box-shadow: var(--shadow-neon-purple);
  border-radius: 20px;
  transition: width 0.08s linear;
}

.preloader-text {
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

#preloaderPercent {
  color: var(--primary-gold);
  font-family: 'Outfit', sans-serif;
  margin-left: 4px;
}

@keyframes preloader-spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* ==========================================
   13. 3D CARD FLIP EFFECTS SYSTEM
   ========================================== */
.flip-card {
  perspective: 1000px;
  background-color: transparent;
  width: 100%;
  position: relative;
  transition: transform var(--transition-normal);
}

.flip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  transform-style: preserve-3d;
}

/* Cards hover Zoom-in lift and border glows (no hover flip, front remains visible!) */
.flip-card {
  perspective: 1000px;
  background-color: transparent;
  width: 100%;
  position: relative;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  will-change: transform;
}

.flip-card:hover {
  transform: translateY(-10px) scale(1.06) !important;
  z-index: 10;
}

/* Sections specific glowing hover borders on zoom */
.slot-flip-card:hover .flip-card-front,
.dealer-flip-card:hover .flip-card-front {
  border-color: var(--primary-purple-light) !important;
  box-shadow: 0 0 20px rgba(143, 0, 255, 0.5) !important;
}

.ky-flip-card:hover .flip-card-front,
.lottery-flip-card:hover .flip-card-front {
  border-color: var(--primary-gold) !important;
  box-shadow: 0 0 20px rgba(201, 160, 99, 0.45) !important;
}

.flip-card-front, .flip-card-back {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden; /* Safari */
  backface-visibility: hidden;
  border-radius: var(--border-radius-lg);
  border: 1px solid var(--border-color);
  overflow: hidden;
}

.flip-card-front {
  background-color: var(--bg-card);
  color: white;
  z-index: 2;
  transform: rotateY(0deg);
}

.flip-card-back {
  background: #000000 !important; /* Pure solid black background */
  color: #ffffff !important;
  transform: rotateY(180deg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px;
  border: 1px solid var(--primary-purple);
  box-shadow: var(--shadow-neon-purple);
  z-index: 1;
}

/* Categories specific heights */
.slot-flip-card {
  height: 190px;
}

.ky-flip-card {
  height: 180px;
}

.dealer-flip-card {
  height: 230px;
}

.lottery-flip-card {
  height: 150px;
}

/* Sub-card adjustments inside 3D absolute fronts */
.flip-card-front.game-card-rounded,
.flip-card-front.game-card-wide,
.flip-card-front.dealer-card,
.flip-card-front.lottery-badge {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  margin: 0 !important;
  border: none !important;
  box-shadow: none !important;
  transform: none !important;
}

/* Old hover tilt lift removed - upgraded to scale zoom-in */

/* Back Face Content Layouts */
.card-back-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  gap: 12px;
}

.card-back-brand {
  font-size: 10px;
  font-weight: 800;
  color: var(--primary-gold);
  text-transform: uppercase;
  letter-spacing: 1.5px;
}

.card-back-title {
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  margin: 0;
}

.card-back-stats {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 11px;
  color: var(--text-secondary);
  align-items: flex-start;
}

.card-back-stat-item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.card-back-stat-item i {
  color: var(--primary-purple-light);
  width: 12px;
  text-align: center;
}

.btn-card-back-play {
  background: var(--grad-purple);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 6px 16px;
  border-radius: 30px;
  box-shadow: var(--shadow-neon-purple);
  text-transform: uppercase;
  margin-top: 4px;
}

.btn-card-back-play:hover {
  transform: scale(1.05);
  box-shadow: 0 0 15px rgba(114, 9, 183, 0.6);
}

/* ==========================================
   14. POKER DEAL CASCADE REVEAL STYLES
   ========================================== */
/* Set transitional properties on standard elements */
.sports-card,
.live-badge-circle,
.sidebar-promo-card,
.announcement-widget,
.mobile-app-widget {
  transition: transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.8s ease;
  transform-origin: center left;
  will-change: transform, opacity;
}

/* 3D Double Flip Animation (0deg -> 180deg -> 360deg) */
@keyframes poker-double-flip-kf {
  0% {
    transform: rotateY(0deg);
  }
  35% {
    transform: rotateY(180deg); /* 1st flip: show back stats */
  }
  65% {
    transform: rotateY(180deg); /* Pause/hold to read stats */
  }
  100% {
    transform: rotateY(360deg); /* 2nd flip: return to front logo */
  }
}

.poker-double-flipping {
  animation: poker-double-flip-kf 1.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* 2. Right-side panels & standard widget cards swinging foldout state (-90deg rotation) */
.poker-dealing-widget {
  transform: rotateY(-90deg) scale(0.9) !important;
  opacity: 0 !important;
  pointer-events: none !important;
  transition: none !important;
}

/* ==========================================
   15. LIGHT MODE THEME OVERRIDES & TOGGLE BUTTON
   ========================================== */
/* Theme Toggle Button Style */
.theme-toggle-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  width: 38px;
  height: 38px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: var(--shadow-card);
  margin-right: 12px;
  outline: none;
  z-index: 10;
  position: relative;
}

.theme-toggle-btn:hover {
  transform: scale(1.1) rotate(20deg);
  border-color: var(--primary-gold);
  box-shadow: 0 0 10px var(--primary-gold-glow);
}

.theme-toggle-btn .icon-sun {
  display: block;
  color: var(--primary-gold);
}

.theme-toggle-btn .icon-moon {
  display: none;
  color: var(--primary-purple);
}

/* Light Theme Variables Override */
body.light-mode {
  --bg-primary: #f4f5f8;       /* Clean soft light-gray background */
  --bg-secondary: #ffffff;     /* White sidebar & header */
  --bg-card: #ffffff;          /* Pure white cards */
  --bg-card-hover: #f9fafc;    /* Clean off-white card hover */
  --border-color: #e2e8f0;     /* Soft slate border */
  --border-glow: rgba(114, 9, 183, 0.08);
  
  /* Text Colors */
  --text-primary: #1a1e29;     /* Deep slate for high contrast */
  --text-secondary: #5a647a;   /* Clean charcoal */
  --text-muted: #94a3b8;       /* Soft slate muted */
  
  /* Accent Adjustments */
  --primary-gold: #ab8249;     /* Deep gold for light mode text */
  --primary-gold-light: #c29c62;
  
  /* Shadows */
  --shadow-card: 0 10px 30px rgba(0, 0, 0, 0.04);
  --shadow-neon-purple: 0 4px 20px rgba(114, 9, 183, 0.12);
  --shadow-neon-gold: 0 4px 20px rgba(171, 130, 73, 0.1);
}

/* Display sun/moon depending on theme state */
body.light-mode .theme-toggle-btn .icon-sun {
  display: none;
}

body.light-mode .theme-toggle-btn .icon-moon {
  display: block;
}

body.light-mode .theme-toggle-btn:hover {
  border-color: var(--primary-purple);
  box-shadow: 0 0 10px var(--primary-purple-glow);
}

/* Extra Light Mode Layout Adjustments */
/* Light mode card back settings removed - card backs are universally solid black */

body.light-mode .brand-box,
body.light-mode .nav-section-title,
body.light-mode .user-avatar,
body.light-mode .profile-menu {
  border-color: var(--border-color);
}

body.light-mode .profile-menu {
  background-color: #ffffff;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
}

body.light-mode .profile-menu-item {
  color: #5a647a;
}

body.light-mode .profile-menu-item:hover {
  background-color: #f4f5f8;
  color: var(--primary-purple);
}

body.light-mode .mobile-app-widget,
body.light-mode .announcement-widget {
  background-color: #ffffff;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04);
}

body.light-mode .user-balance-box {
  background-color: #f4f5f8;
}

body.light-mode .btn-deposit {
  box-shadow: 0 4px 15px rgba(114, 9, 183, 0.15);
}

body.light-mode .recharge-modal-content {
  background: #ffffff;
  color: #1a1e29;
}

body.light-mode .payment-item {
  background-color: #f4f5f8;
  border-color: #e2e8f0;
}

body.light-mode .payment-item.active {
  border-color: var(--primary-purple);
  background-color: rgba(114, 9, 183, 0.03);
}

body.light-mode .amount-btn {
  background-color: #f4f5f8;
  color: #5a647a;
}

body.light-mode .amount-btn.active {
  background: var(--grad-purple);
  color: #ffffff;
}

body.light-mode .input-amount-box input {
  background-color: #f4f5f8;
  border-color: #e2e8f0;
  color: #1a1e29;
}
