:root {
  --primary-color: #017439;
  --secondary-color: #FFFFFF;
  --text-color: #e0e0e0;
  --dark-bg-1: #0a0a0a;
  --dark-bg-2: #1a1a2e;
  --dark-bg-3: #16213e;
  --dark-bg-4: #0f3460;

  /* Neon Colors - adapted for green scheme */
  --neon-primary: #39FF14; /* Electric Green */
  --neon-secondary: #00FFFF; /* Cyan */
  --neon-accent: #FF00FF; /* Magenta */
  --neon-red: #FF0000; /* Red for emphasis */
  --neon-yellow: #FFFF00; /* Yellow for emphasis */

  --header-offset: 155px; /* Desktop: Marquee ~45px + Header Top ~60px + Main Nav ~50px */
}

@media (max-width: 768px) {
  :root {
    --header-offset: 135px; /* Mobile: Marquee ~30px + Header Top ~50px + Mobile Nav Buttons ~55px */
  }
}

/* General Body Styles */
body {
  font-family: 'Arial', sans-serif;
  margin: 0;
  padding-top: var(--header-offset);
  background-color: var(--dark-bg-1);
  color: var(--text-color);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Shared Animations for Neon Effects */
@keyframes rainbow-border {
  0% { border-color: var(--neon-red); box-shadow: 0 0 10px var(--neon-red), 0 0 20px var(--neon-red); }
  16.6% { border-color: var(--neon-accent); box-shadow: 0 0 10px var(--neon-accent), 0 0 20px var(--neon-accent); }
  33.3% { border-color: var(--neon-primary); box-shadow: 0 0 10px var(--neon-primary), 0 0 20px var(--neon-primary); }
  50% { border-color: var(--neon-secondary); box-shadow: 0 0 10px var(--neon-secondary), 0 0 20px var(--neon-secondary); }
  66.6% { border-color: var(--neon-yellow); box-shadow: 0 0 10px var(--neon-yellow), 0 0 20px var(--neon-yellow); }
  83.3% { border-color: var(--neon-red); box-shadow: 0 0 10px var(--neon-red), 0 0 20px var(--neon-red); }
  100% { border-color: var(--neon-red); box-shadow: 0 0 10px var(--neon-red), 0 0 20px var(--neon-red); }
}

@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(57, 255, 20, 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(0, 255, 255, 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(255, 0, 255, 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: var(--secondary-color); }
  50% { text-shadow: 0 0 5px var(--neon-secondary), 0 0 10px var(--neon-secondary), 0 0 15px var(--neon-secondary); color: var(--secondary-color); }
  100% { text-shadow: 0 0 5px var(--neon-accent), 0 0 10px var(--neon-accent), 0 0 15px var(--neon-accent); color: var(--secondary-color); }
}

@keyframes alternate-colors {
  0% { border-color: var(--neon-red); box-shadow: 0 0 10px var(--neon-red), 0 0 20px var(--neon-red); }
  100% { border-color: var(--neon-yellow); box-shadow: 0 0 10px var(--neon-yellow), 0 0 20px var(--neon-yellow); }
}

@keyframes neon-pulse {
  0% { transform: scale(1); opacity: 1; text-shadow: 0 0 5px currentColor, 0 0 10px currentColor; }
  50% { transform: scale(1.05); opacity: 0.9; text-shadow: 0 0 15px currentColor, 0 0 30px currentColor; }
  100% { transform: scale(1); opacity: 1; text-shadow: 0 0 5px currentColor, 0 0 10px currentColor; }
}

/* Marquee Section */
.marquee-section {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: linear-gradient(135deg, var(--dark-bg-1), var(--dark-bg-2), var(--dark-bg-3));
  color: var(--secondary-color);
  overflow: hidden;
  border-bottom: 2px solid;
  animation: theme-colors 4s ease-in-out infinite;
  box-shadow:
    0 0 10px var(--neon-primary),
    0 0 20px var(--neon-primary),
    0 0 30px var(--neon-primary),
    inset 0 0 20px rgba(57, 255, 20, 0.1);
  z-index: 1001;
  min-height: 45px;
  display: flex;
  align-items: center;
}

.marquee-container {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 10px 20px;
}

.marquee-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  z-index: 2;
  position: relative;
}

.marquee-icon-emoji {
  font-size: 24px;
  display: inline-block;
  animation: marquee-pulse 2s ease-in-out infinite, text-glow-flow 3s ease-in-out infinite alternate;
  text-shadow:
    0 0 5px var(--neon-primary),
    0 0 10px var(--neon-primary),
    0 0 15px var(--neon-primary);
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

@keyframes marquee-pulse {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.15);
    opacity: 0.9;
  }
}

.marquee-wrapper {
  flex: 1;
  overflow: hidden;
  position: relative;
}

.marquee-content {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  animation: marquee-scroll 30s linear infinite;
  gap: 30px;
}

.marquee-text {
  font-size: 16px;
  font-weight: 600;
  color: var(--secondary-color);
  text-decoration: none;
  text-shadow:
    0 0 5px var(--neon-primary),
    0 0 10px var(--neon-primary),
    0 0 15px var(--neon-primary);
  line-height: 1.5;
  display: inline-block;
  vertical-align: middle;
  animation: text-glow-flow 3s ease-in-out infinite alternate;
  cursor: pointer;
  transition: all 0.3s ease;
}

.marquee-text:hover {
  text-shadow:
    0 0 10px var(--neon-primary),
    0 0 20px var(--neon-primary),
    0 0 30px var(--neon-primary),
    0 0 40px var(--neon-primary);
  transform: scale(1.05);
  color: var(--secondary-color);
}

.marquee-separator {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.6);
  margin: 0 15px;
  text-shadow:
    0 0 3px var(--neon-primary),
    0 0 6px var(--neon-primary);
}

@keyframes marquee-scroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* Header Section */
.site-header {
  position: fixed;
  top: var(--marquee-offset);
  left: 0;
  width: 100%;
  z-index: 1000;
  font-family: 'Arial', sans-serif; /* Fallback for cyberpunk font */
}

.header-top {
  background: linear-gradient(135deg, var(--dark-bg-2), var(--dark-bg-3));
  border-bottom: 2px solid;
  animation: theme-colors 4s ease-in-out infinite;
  box-shadow:
    0 0 10px var(--neon-primary),
    0 0 20px var(--neon-primary),
    inset 0 0 20px rgba(57, 255, 20, 0.1);
  padding: 15px 0;
  min-height: 60px;
  display: flex;
  align-items: center;
}

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

.logo {
  font-size: 28px;
  font-weight: bold;
  color: var(--secondary-color); /* Regular color, no neon */
  text-decoration: none;
  flex-shrink: 0;
  padding-right: 20px;
}

.logo img {
  display: block;
  max-width: 100%;
  height: auto;
  max-height: 50px;
}

.desktop-nav-buttons {
  display: flex;
  gap: 10px;
  align-items: center;
}

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

.main-nav {
  background: linear-gradient(135deg, var(--dark-bg-3), var(--dark-bg-4));
  border-top: 2px solid;
  border-bottom: 2px solid;
  animation: rainbow-border 6s linear infinite; /* Different animation for contrast */
  box-shadow:
    0 0 10px var(--neon-red),
    0 0 20px var(--neon-red),
    inset 0 0 20px rgba(255, 0, 0, 0.1);
  width: 100%;
  display: flex;
  min-height: 50px;
  align-items: center;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  padding: 10px 20px;
  box-sizing: border-box;
}

.nav-link {
  color: var(--secondary-color);
  text-decoration: none;
  padding: 8px 15px;
  font-size: 16px;
  font-weight: 500;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  display: block;
}

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

/* Hamburger Menu */
.hamburger-menu {
  display: none; /* Hidden on desktop */
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 10px;
  position: relative;
  z-index: 1002; /* Above logo */
  margin-right: 15px;
}

.hamburger-icon {
  display: block;
  width: 30px;
  height: 3px;
  background-color: var(--neon-secondary);
  position: relative;
  transition: all 0.3s ease-in-out;
  box-shadow: 0 0 5px var(--neon-secondary), 0 0 10px var(--neon-secondary);
}

.hamburger-icon::before, .hamburger-icon::after {
  content: '';
  display: block;
  width: 30px;
  height: 3px;
  background-color: var(--neon-secondary);
  position: absolute;
  transition: all 0.3s ease-in-out;
  box-shadow: 0 0 5px var(--neon-secondary), 0 0 10px var(--neon-secondary);
}

.hamburger-icon::before {
  top: -10px;
}

.hamburger-icon::after {
  top: 10px;
}

.hamburger-menu.active .hamburger-icon {
  background-color: transparent;
  box-shadow: none;
}

.hamburger-menu.active .hamburger-icon::before {
  top: 0;
  transform: rotate(45deg);
  background-color: var(--neon-red);
  box-shadow: 0 0 5px var(--neon-red), 0 0 10px var(--neon-red);
}

.hamburger-menu.active .hamburger-icon::after {
  top: 0;
  transform: rotate(-45deg);
  background-color: var(--neon-red);
  box-shadow: 0 0 5px var(--neon-red), 0 0 10px var(--neon-red);
}

/* Buttons */
.btn {
  position: relative;
  padding: 12px 30px;
  color: var(--secondary-color);
  text-decoration: none;
  border-radius: 5px;
  border: 2px solid;
  font-weight: bold;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-block;
  text-align: center;
}

.btn.register-btn {
  background: linear-gradient(135deg, #C30808, #FF6600);
  color: #FFFF00; /* Custom font color for register/login */
  animation: theme-colors 4s ease-in-out infinite;
  text-shadow: 0 0 5px #FFFF00, 0 0 10px #C30808;
}

.btn.login-btn {
  background: linear-gradient(135deg, #C30808, #FF3366);
  color: #FFFF00; /* Custom font color for register/login */
  animation: alternate-colors 3s ease-in-out infinite;
  text-shadow: 0 0 5px #FFFF00, 0 0 10px #C30808;
}

.btn:hover {
  animation-duration: 2s; /* Faster animation on hover */
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 0 15px currentColor, 0 0 30px currentColor, 0 0 45px currentColor;
}

/* 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: 999;
  transition: opacity 0.3s ease;
  opacity: 0;
}

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

/* Footer Section */
.site-footer {
  background-color: var(--dark-bg-2);
  color: var(--text-color);
  padding: 40px 0 20px;
  font-size: 14px;
}

.site-footer h4 {
  color: var(--secondary-color);
  font-size: 18px;
  margin-bottom: 20px;
  font-weight: bold;
}

.footer-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.footer-grid-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 30px;
  margin-bottom: 40px;
}

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

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

.footer-col ul li a, .footer-legal-nav li a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-col ul li a:hover, .footer-legal-nav li a:hover {
  color: var(--primary-color);
}

.footer-logo {
  font-size: 24px;
  font-weight: bold;
  color: var(--secondary-color);
  text-decoration: none;
  margin-bottom: 15px;
  display: block;
}

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

.payment-methods, .game-providers-section, .social-media-section {
  margin-top: 30px;
}

.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;
  filter: grayscale(100%) brightness(150%); /* Make icons fit dark theme, optional */
  opacity: 0.8;
  transition: opacity 0.3s ease;
}

.payment-icons img:hover, .game-providers-icons img:hover, .social-media-icons img:hover {
  opacity: 1;
  filter: grayscale(0%) brightness(100%);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 40px;
  padding-top: 20px;
}

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

.copyright {
  margin: 0;
  color: rgba(255, 255, 255, 0.6);
}

.footer-legal-nav {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .marquee-section {
    min-height: 30px;
    padding: 0;
  }
  .marquee-container {
    gap: 10px;
    padding: 0 5px;
  }
  .marquee-icon {
    width: 25px;
    height: 25px;
  }
  .marquee-icon-emoji {
    font-size: 16px;
  }
  .marquee-text, .marquee-separator {
    font-size: 13px;
    margin: 0 8px;
  }
  .marquee-content {
    gap: 15px;
    animation: marquee-scroll 20s linear infinite;
  }

  .site-header {
    top: var(--marquee-offset);
  }

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

  .header-container {
    padding: 0 15px;
    justify-content: space-between;
    flex-wrap: nowrap;
    max-width: none; /* Important for mobile */
  }

  .hamburger-menu {
    display: block;
    order: 0;
    margin-right: 0;
  }

  .logo {
    flex: 1 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    font-size: 22px;
    padding-right: 0;
  }

  .logo img {
    max-height: 40px;
  }

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

  .mobile-nav-buttons {
    display: flex !important;
    justify-content: center;
    gap: 10px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 10px 15px;
    background: linear-gradient(135deg, var(--dark-bg-1), var(--dark-bg-2));
    border-bottom: 2px solid;
    animation: theme-colors 4s ease-in-out infinite;
    box-shadow:
      0 0 5px var(--neon-primary),
      0 0 10px var(--neon-primary),
      inset 0 0 10px rgba(57, 255, 20, 0.1);
    flex-wrap: nowrap;
    min-height: 55px;
    align-items: center;
  }

  .mobile-nav-buttons .btn {
    flex: 1;
    min-width: 0;
    max-width: calc(50% - 5px);
    box-sizing: border-box;
    white-space: normal;
    word-wrap: break-word;
    overflow-wrap: break-word;
    padding: 8px 12px;
    font-size: 13px;
  }

  .main-nav {
    display: none; /* Hidden by default on mobile */
    flex-direction: column;
    position: fixed;
    top: calc(var(--marquee-offset) + 55px); /* Below marquee and mobile buttons */
    left: 0;
    width: 70%;
    max-width: 300px;
    height: calc(100% - var(--marquee-offset) - 55px);
    background: var(--dark-bg-3);
    padding: 20px 0;
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out;
    z-index: 1000;
    border-right: 2px solid var(--neon-secondary);
    box-shadow: 5px 0 20px rgba(0, 255, 255, 0.3);
    overflow-y: auto;
  }

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

  .nav-container {
    flex-direction: column;
    align-items: flex-start;
    padding: 0 15px;
    max-width: none; /* Important for mobile */
  }

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

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

  body.no-scroll {
    overflow: hidden;
  }

  .footer-grid-container {
    grid-template-columns: 1fr;
  }

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

  .footer-legal-nav {
    justify-content: center;
  }

  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }
  body {
    overflow-x: hidden;
  }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@media (max-width: 768px) {
  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }
  body {
    overflow-x: hidden;
  }
}
