:root {
  --primary-color: #1A2B4C;
  --secondary-color: #FFD700;

  --neon-primary: var(--secondary-color); /* Intelligent choice for neon primary */
  --neon-secondary: #FF6600; /* A vibrant orange */
  --neon-accent: #FF00FF; /* A vibrant magenta */
}

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

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: #f0f0f0;
  background-color: #0a0a0a; /* Dark background for overall site */
}

/* Animations */
@keyframes neon-flicker {
  0%, 19%, 21%, 23%, 25%, 54%, 56%, 100% {
    opacity: 1;
    box-shadow:
      0 0 10px currentColor,
      0 0 20px currentColor,
      0 0 30px currentColor,
      inset 0 0 15px currentColor;
  }
  20%, 24%, 55% {
    opacity: 0.8;
    box-shadow:
      0 0 5px currentColor,
      0 0 10px currentColor,
      0 0 15px currentColor,
      inset 0 0 10px currentColor;
  }
}

@keyframes pulse-glow {
  from {
    box-shadow:
      0 0 5px currentColor,
      0 0 10px currentColor;
  }
  to {
    box-shadow:
      0 0 15px currentColor,
      0 0 30px currentColor,
      0 0 45px currentColor;
  }
}

@keyframes led-blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0.3; }
}

@keyframes text-glow-flow {
  0% {
    text-shadow:
      0 0 5px var(--neon-primary, #ff00ff),
      0 0 10px var(--neon-primary, #ff00ff),
      0 0 15px var(--neon-primary, #ff00ff);
    color: #ffffff;
  }
  50% {
    text-shadow:
      0 0 5px var(--neon-secondary, #00ffff),
      0 0 10px var(--neon-secondary, #00ffff),
      0 0 15px var(--neon-secondary, #00ffff);
    color: #ffffff;
  }
  100% {
    text-shadow:
      0 0 5px var(--neon-accent, #ffff00),
      0 0 10px var(--neon-accent, #ffff00),
      0 0 15px var(--neon-accent, #ffff00);
    color: #ffffff;
  }
}

@keyframes theme-colors {
  0%, 100% {
    border-color: var(--neon-primary, #667eea);
    box-shadow:
      0 0 10px var(--neon-primary, #667eea),
      0 0 20px var(--neon-primary, #667eea),
      inset 0 0 10px rgba(102, 126, 234, 0.3);
  }
  33% {
    border-color: var(--neon-secondary, #764ba2);
    box-shadow:
      0 0 10px var(--neon-secondary, #764ba2),
      0 0 20px var(--neon-secondary, #764ba2),
      inset 0 0 10px rgba(118, 75, 162, 0.3);
  }
  66% {
    border-color: var(--neon-accent, #f093fb);
    box-shadow:
      0 0 10px var(--neon-accent, #f093fb),
      0 0 20px var(--neon-accent, #f093fb),
      inset 0 0 10px rgba(240, 147, 251, 0.3);
  }
}

/* Header Styles (Desktop First) */
.site-header {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
}

.header-top {
  background: linear-gradient(135deg, #0a0a0a, #1a1a2e, #16213e);
  border-bottom: 2px solid var(--neon-primary);
  animation: theme-colors 4s ease-in-out infinite; /* Dynamic border glow for header-top */
  padding: 15px 0;
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 20px;
}

.logo {
  font-size: 2.2em;
  font-weight: bold;
  text-decoration: none;
  color: #ffffff;
  position: relative;
  animation: text-glow-flow 3s ease-in-out infinite alternate; /* Dynamic text glow for logo */
  padding: 0 5px; /* Ensure glow isn't cut off */
}

.desktop-nav-buttons {
  display: flex;
  gap: 12px;
}

.btn {
  position: relative;
  background: linear-gradient(135deg, var(--neon-primary), var(--neon-secondary));
  padding: 12px 30px;
  color: #ffffff;
  text-decoration: none;
  border-radius: 5px;
  border: 2px solid;
  animation: theme-colors 4s ease-in-out infinite; /* Dynamic border glow for buttons */
  text-shadow:
    0 0 5px #ffffff,
    0 0 10px var(--neon-primary);
  transition: all 0.3s ease;
  font-weight: bold;
  white-space: nowrap;
}

.btn:hover {
  animation-duration: 2s; /* Speed up glow on hover */
  transform: translateY(-2px);
  box-shadow:
    0 0 15px var(--neon-primary),
    0 0 30px var(--neon-primary),
    inset 0 0 15px rgba(255, 255, 255, 0.2);
}

.main-nav {
  background: linear-gradient(135deg, #1a1a2e, #16213e, #0f3460);
  border-top: 2px solid var(--neon-secondary);
  border-bottom: 2px solid var(--neon-secondary);
  animation: theme-colors 4s ease-in-out infinite reverse; /* Dynamic border glow for main-nav, different animation direction */
  width: 100%;
  display: flex;
  padding: 10px 0;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  padding: 0 20px;
  flex-wrap: wrap;
}

.nav-link {
  color: #f0f0f0;
  text-decoration: none;
  padding: 8px 15px;
  font-weight: 600;
  transition: color 0.3s ease, background-color 0.3s ease;
  white-space: nowrap;
}

.nav-link:hover,
.nav-link.active {
  color: var(--neon-primary);
  background-color: rgba(255, 255, 255, 0.05);
  border-radius: 3px;
}

.hamburger-menu,
.mobile-nav-buttons,
.mobile-menu-overlay {
  display: none;
}

/* Footer Styles */
.site-footer {
  background-color: #1a1a2e;
  color: #b0b0b0;
  padding: 40px 20px 20px;
  font-size: 0.9em;
  border-top: 1px solid #333;
}

.footer-top-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto 40px;
}

.footer-col h4 {
  color: #ffffff;
  margin-bottom: 15px;
  font-size: 1.1em;
}

.footer-logo {
  font-size: 1.8em;
  font-weight: bold;
  text-decoration: none;
  color: #ffffff;
  margin-bottom: 15px;
  display: block;
}

.footer-description {
  line-height: 1.6;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.footer-nav,
.footer-legal-nav {
  list-style: none;
}

.footer-nav li,
.footer-legal-nav li {
  margin-bottom: 8px;
}

.footer-nav a,
.footer-legal-nav a {
  color: #b0b0b0;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-nav a:hover,
.footer-legal-nav a:hover {
  color: #ffffff;
}

.payment-icons,
.game-providers-icons,
.social-media-icons {
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  align-items: flex-start;
  gap: 8px;
  width: 100%;
}

.payment-icons img,
.game-providers-icons img,
.social-media-icons img {
  max-height: 50px;
  height: auto;
  width: auto;
  object-fit: contain;
  filter: brightness(0.8) contrast(1.2);
  transition: filter 0.3s ease;
}

.payment-icons img:hover,
.game-providers-icons img:hover,
.social-media-icons img:hover {
  filter: brightness(1) contrast(1.5);
}

.game-providers-section,
.social-media-section {
  max-width: 1200px;
  margin: 0 auto 30px;
  padding: 20px 0;
  border-top: 1px solid #333;
}

.game-providers-section h4,
.social-media-section h4 {
  margin-bottom: 15px;
  color: #ffffff;
}

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  border-top: 1px solid #333;
  padding-top: 20px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  text-align: center;
}

.footer-bottom p {
  flex: 1 1 100%;
  margin-bottom: 10px;
}

.footer-legal-nav {
  flex: 1 1 100%;
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
}

/* Hamburger Menu Icon */
.hamburger-menu {
  width: 30px;
  height: 22px;
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  z-index: 1001;
  padding: 0;
  /* Neon glow for hamburger */
  animation: theme-colors 4s linear infinite;
}

.hamburger-menu .bar {
  display: block;
  width: 100%;
  height: 3px;
  background-color: var(--neon-primary);
  border-radius: 2px;
  transition: all 0.3s ease;
  box-shadow: 0 0 5px var(--neon-primary), 0 0 10px var(--neon-primary);
}

.hamburger-menu.active .bar:nth-child(1) {
  transform: translateY(9px) rotate(45deg);
}

.hamburger-menu.active .bar:nth-child(2) {
  opacity: 0;
}

.hamburger-menu.active .bar:nth-child(3) {
  transform: translateY(-9px) rotate(-45deg);
}

/* Mobile Styles */
@media (max-width: 768px) {
  body {
    /* Adjust padding-top based on actual header-top and mobile-nav-buttons heights */
    padding-top: 130px; /* Estimated: header-top (60px) + mobile-buttons (60px) + gap */
  }

  .site-header {
    min-height: unset;
  }

  .header-top {
    padding: 10px 0;
  }

  .header-container {
    width: 100%;
    max-width: none;
    padding: 0 15px;
    justify-content: space-between;
  }

  .hamburger-menu {
    display: flex; /* Show hamburger menu on mobile */
    order: 1;
    margin-right: auto;
  }

  .logo {
    order: 2;
    flex: 1;
    text-align: center;
    font-size: 1.8em;
    margin-left: -30px; /* Counteract hamburger width to truly center */
  }

  .desktop-nav-buttons {
    display: none; /* Hide desktop buttons on mobile */
  }

  .main-nav {
    display: none; /* Hidden by default on mobile */
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    width: 70%;
    height: 100%;
    background: linear-gradient(180deg, #1a1a2e, #0a0a0a); /* Dark background for mobile menu */
    padding-top: 80px;
    transform: translateX(-100%); /* Slide out from left */
    transition: transform 0.3s ease-out;
    z-index: 1000; /* Ensure menu is above overlay */
    border-right: 2px solid var(--neon-primary);
    animation: theme-colors 4s ease-in-out infinite; /* Dynamic border glow for mobile menu */
    overflow-y: auto;
  }

  .main-nav.active {
    display: flex; /* Show menu when active */
    transform: translateX(0); /* Slide in */
  }

  .nav-container {
    flex-direction: column;
    align-items: flex-start;
    padding: 0 20px;
    width: 100%;
    max-width: none;
  }

  .nav-link {
    width: 100%;
    padding: 12px 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }

  .mobile-nav-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 10px 15px;
    background: linear-gradient(135deg, #0a0a0a, #1a1a2e);
    border-bottom: 2px solid var(--neon-accent);
    animation: theme-colors 4s ease-in-out infinite reverse;
    position: fixed; /* Fixed below header-top */
    top: 60px; /* Assuming header-top is ~60px height (10px padding + logo height) */
    z-index: 990; /* Below main-nav but above content */
  }

  .mobile-nav-buttons .btn {
    flex: 1 1 auto;
    max-width: calc(100% - 20px); /* Account for padding */
    min-width: unset;
    white-space: normal;
    word-wrap: break-word;
    font-size: 14px;
    padding: 10px 15px;
  }

  .mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 999;
    transition: opacity 0.3s ease;
    opacity: 0;
  }

  .mobile-menu-overlay.active {
    display: block;
    opacity: 1;
  }

  .footer-top-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .footer-legal-nav {
    margin-top: 15px;
  }
}

/* Body scroll lock for mobile menu */
body.no-scroll {
  overflow: hidden;
}
