:root {
  --primary-color: #FFD700;
  --secondary-color: #8B0000;
  --neon-primary: var(--primary-color);
  --neon-secondary: #FF4500;
  --neon-accent: #00FFFF;
  --dark-bg-1: #0a0a0a;
  --dark-bg-2: #1a1a2e;
  --dark-bg-3: #16213e;
  --header-height: 0px;
}

/* Animation Keyframes */
@keyframes rainbow-border {
  0% { border-color: #ff0000; box-shadow: 0 0 10px #ff0000, 0 0 20px #ff0000; }
  16.6% { border-color: #ff8000; box-shadow: 0 0 10px #ff8000, 0 0 20px #ff8000; }
  33.3% { border-color: #ffff00; box-shadow: 0 0 10px #ffff00, 0 0 20px #ffff00; }
  50% { border-color: #00ff00; box-shadow: 0 0 10px #00ff00, 0 0 20px #00ff00; }
  66.6% { border-color: #0000ff; box-shadow: 0 0 10px #0000ff, 0 0 20px #0000ff; }
  83.3% { border-color: #8000ff; box-shadow: 0 0 10px #8000ff, 0 0 20px #8000ff; }
  100% { border-color: #ff0000; box-shadow: 0 0 10px #ff0000, 0 0 20px #ff0000; }
}
@keyframes hue-spin {
  0% { filter: hue-rotate(0deg); box-shadow: 0 0 10px var(--neon-primary), 0 0 20px var(--neon-primary); }
  100% { filter: hue-rotate(360deg); box-shadow: 0 0 10px var(--neon-primary), 0 0 20px var(--neon-primary); }
}
@keyframes alternate-colors {
  0% { border-color: var(--neon-primary); box-shadow: 0 0 10px var(--neon-primary), 0 0 20px var(--neon-primary); }
  100% { border-color: var(--neon-accent); box-shadow: 0 0 10px var(--neon-accent), 0 0 20px var(--neon-accent); }
}
@keyframes gradient-flow {
  0% { background-position: 0% 50%; box-shadow: 0 0 10px #ff0000, 0 0 20px #ff8000; }
  50% { background-position: 100% 50%; box-shadow: 0 0 10px #00ffff, 0 0 20px #0000ff; }
  100% { background-position: 0% 50%; box-shadow: 0 0 10px #ff0000, 0 0 20px #ff8000; }
}
@keyframes random-glow {
  0% { border-color: #ff00ff; box-shadow: 0 0 20px #ff00ff; }
  20% { border-color: #00ffff; box-shadow: 0 0 20px #00ffff; }
  40% { border-color: #ffff00; box-shadow: 0 0 20px #ffff00; }
  60% { border-color: #00ff00; box-shadow: 0 0 20px #00ff00; }
  80% { border-color: #ff0000; box-shadow: 0 0 20px #ff0000; }
  100% { border-color: #ff00ff; box-shadow: 0 0 20px #ff00ff; }
}
@keyframes theme-colors {
  0%, 100% {
    border-color: var(--neon-primary);
    box-shadow:
      0 0 10px var(--neon-primary),
      0 0 20px var(--neon-primary),
      inset 0 0 10px rgba(255, 215, 0, 0.3);
  }
  33% {
    border-color: var(--neon-secondary);
    box-shadow:
      0 0 10px var(--neon-secondary),
      0 0 20px var(--neon-secondary),
      inset 0 0 10px rgba(139, 0, 0, 0.3);
  }
  66% {
    border-color: var(--neon-accent);
    box-shadow:
      0 0 10px var(--neon-accent),
      0 0 20px var(--neon-accent),
      inset 0 0 10px rgba(0, 255, 255, 0.3);
  }
}
@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),
      0 0 10px var(--neon-primary),
      0 0 15px var(--neon-primary);
    color: #ffffff;
  }
  50% {
    text-shadow:
      0 0 5px var(--neon-accent),
      0 0 10px var(--neon-accent),
      0 0 15px var(--neon-accent);
    color: #ffffff;
  }
  100% {
    text-shadow:
      0 0 5px var(--neon-secondary),
      0 0 10px var(--neon-secondary),
      0 0 15px var(--neon-secondary);
    color: #ffffff;
  }
}

/* General Body Styles for Content Area Protection */
body {
  margin: 0;
  padding-top: var(--header-height);
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: #1a1a2e;
  color: #e0e0e0;
  line-height: 1.6;
}

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

.header-top {
  background: linear-gradient(135deg, var(--dark-bg-1), var(--dark-bg-2));
  border-bottom: 2px solid;
  animation: theme-colors 4s ease-in-out infinite; /* Dynamic border color */
  padding: 15px 0;
}

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

.hamburger-menu {
  display: none;
}

.logo {
  font-family: 'Orbitron', sans-serif;
  font-size: 2.2em;
  font-weight: bold;
  color: #fff;
  text-decoration: none;
  text-transform: uppercase;
  padding: 5px 0;
  position: relative;
  display: block;
}

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

.mobile-nav-buttons {
  display: none;
}

.main-nav {
  background: linear-gradient(135deg, var(--dark-bg-2), var(--dark-bg-3));
  border-top: 2px solid transparent;
  border-bottom: 2px solid transparent;
  animation: alternate-colors 4s ease-in-out infinite; /* Different dynamic border color */
  padding: 10px 0;
  display: flex;
  flex-direction: row;
  position: static;
  width: 100%;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0 20px;
  flex-wrap: wrap; /* Allow nav links to wrap if screen is too narrow on desktop */
}

.nav-link {
  color: #c0c0c0;
  text-decoration: none;
  padding: 10px 15px;
  font-size: 1.1em;
  transition: color 0.3s ease, text-shadow 0.3s ease;
  white-space: nowrap; /* Prevent menu items from breaking words */
}

.nav-link:hover {
  color: #fff;
  text-shadow: 0 0 5px var(--neon-primary), 0 0 10px var(--neon-primary);
}

/* Buttons */
.btn {
  position: relative;
  padding: 12px 25px;
  color: #ffffff;
  text-decoration: none;
  border-radius: 5px;
  font-weight: bold;
  letter-spacing: 0.5px;
  overflow: hidden;
  background: transparent;
  border: 2px solid transparent;
  transition: all 0.3s ease;
  cursor: pointer;
}

.btn.theme-flow {
  animation: theme-colors 4s ease-in-out infinite, pulse-glow 2s ease-in-out infinite alternate;
}

.btn:hover {
  animation-duration: 2s;
  transform: translateY(-2px);
  box-shadow:
    0 0 15px var(--neon-primary),
    0 0 30px var(--neon-primary),
    0 0 45px var(--neon-primary);
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 998;
}

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

/* Footer Styles */
.site-footer {
  background: #111;
  color: #ccc;
  padding: 40px 20px 20px;
  font-size: 0.9em;
}

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

.footer-col {
  padding: 10px 0;
}

.footer-logo {
  font-size: 1.8em;
  font-weight: bold;
  color: var(--neon-primary);
  text-decoration: none;
  margin-bottom: 15px;
  display: block;
  text-transform: uppercase;
}

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

.footer-col h4 {
  color: #fff;
  font-size: 1.2em;
  margin-bottom: 20px;
  position: relative;
}

.footer-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-nav li {
  margin-bottom: 10px;
}

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

.footer-nav a:hover {
  color: var(--neon-primary);
}

.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;
}

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

.copyright {
  text-align: center;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid #333;
  color: #888;
}

.footer-legal-nav {
  margin-top: 10px;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 5px 15px;
}

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

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

.footer-legal-nav .separator {
  color: #555;
}

/* Responsive Styles (Mobile First Override) */
@media (max-width: 768px) {
  .site-header {
    flex-direction: column;
  }

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

  .hamburger-menu {
    display: block;
    cursor: pointer;
    padding: 10px;
    position: relative;
    z-index: 1001;
    background: transparent;
    border: none;
    color: var(--neon-primary);
    font-size: 1.8em;
    animation: theme-colors 4s ease-in-out infinite, neon-flicker 2s infinite alternate;
    box-shadow:
      0 0 5px currentColor,
      0 0 10px currentColor;
  }

  .hamburger-menu.active {
    animation-duration: 2s;
  }

  .logo {
    flex: 1;
    text-align: center;
    padding: 10px 0;
    font-size: 1.8em;
  }

  .desktop-nav-buttons {
    display: none;
  }

  .mobile-nav-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 10px 15px;
    background: linear-gradient(135deg, var(--dark-bg-1), var(--dark-bg-2));
    border-top: 1px solid;
    animation: theme-colors 4s ease-in-out infinite;
    box-shadow:
      0 0 5px currentColor,
      0 0 10px currentColor;
  }

  .main-nav {
    display: none;
    flex-direction: column;
    position: fixed;
    top: 0; /* Will be adjusted by JS */
    left: 0;
    width: 80%;
    max-width: 300px;
    height: 100vh;
    background: linear-gradient(180deg, var(--dark-bg-3), var(--dark-bg-1));
    transform: translateX(-100%);
    transition: transform 0.3s ease-out;
    padding-top: 20px; /* Initial padding, JS will adjust for header height */
    box-shadow: 5px 0 15px rgba(0, 0, 0, 0.5);
    z-index: 999;
    border-right: 2px solid;
    animation: theme-colors 4s ease-in-out infinite;
  }

  .main-nav.active {
    display: flex;
    transform: translateX(0);
  }

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

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

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

  .game-providers-section,
  .social-media-section {
    padding: 15px 0;
  }

  .payment-icons,
  .game-providers-icons,
  .social-media-icons {
    justify-content: center;
  }

  .footer-legal-nav {
    flex-direction: column;
    gap: 5px;
  }
  .footer-legal-nav .separator {
    display: none;
  }
}