:root {
  --primary-color: #26A9E0;
  --secondary-color: #FFFFFF;
  --text-color: #FFFFFF;
  --dark-bg: #0a0a0a;
  --dark-bg-light: #1a1a2e;
  --dark-bg-lighter: #16213e;
  --neon-primary: #00FFFF; /* Bright Cyan */
  --neon-secondary: #FF00FF; /* Magenta */
  --neon-accent: #FFFF00; /* Yellow */
  --neon-alt-1: #FF0000; /* Red */
  --neon-alt-2: #00FF00; /* Green */

  --header-offset: 155px; /* Desktop: marquee(45px) + header-top(60px) + main-nav(50px) */
}

@media (max-width: 768px) {
  :root {
    --header-offset: 140px; /* Mobile: marquee(40px) + header-top(50px) + mobile-nav-buttons(50px) */
  }
}

/* Universal Box-sizing */
*,
*::before,
*::after {
  box-sizing: border-box;
}

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

/* Global container for content width */
.header-container,
.nav-container,
.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding-left: 20px;
  padding-right: 20px;
}

/* Neon Glow Animations */
@keyframes rainbow-border {
  0% { border-color: var(--neon-primary); box-shadow: 0 0 10px var(--neon-primary), 0 0 20px var(--neon-primary); }
  25% { border-color: var(--neon-secondary); box-shadow: 0 0 10px var(--neon-secondary), 0 0 20px var(--neon-secondary); }
  50% { border-color: var(--neon-accent); box-shadow: 0 0 10px var(--neon-accent), 0 0 20px var(--neon-accent); }
  75% { border-color: var(--neon-alt-1); box-shadow: 0 0 10px var(--neon-alt-1), 0 0 20px var(--neon-alt-1); }
  100% { border-color: var(--neon-primary); box-shadow: 0 0 10px var(--neon-primary), 0 0 20px var(--neon-primary); }
}

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

@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(0, 255, 255, 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(255, 0, 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, 255, 0, 0.3);
  }
}

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

/* Marquee Section */
.marquee-section {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 45px; /* Fixed height for marquee */
  background: linear-gradient(135deg, var(--dark-bg), var(--dark-bg-light), var(--dark-bg-lighter));
  color: var(--text-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(0, 255, 255, 0.1);
  z-index: 1001;
}

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

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

.marquee-icon-emoji {
  font-size: 20px;
  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));
}

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

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

.marquee-text {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-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.02);
  color: var(--text-color);
}

.marquee-separator {
  font-size: 15px;
  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: 45px; /* Marquee height */
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: transparent;
}

.site-header .header-top {
  background: linear-gradient(135deg, var(--dark-bg), var(--dark-bg-light));
  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 10px rgba(0, 255, 255, 0.1);
  min-height: 60px;
  display: flex;
  align-items: center;
}

.site-header .header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 60px;
  width: 100%; /* Ensure it spans max-width */
}

.site-header .logo {
  font-size: 28px;
  font-weight: bold;
  color: var(--secondary-color); /* LOGO NO NEON EFFECT */
  text-decoration: none;
  padding: 5px 0;
  display: block;
  flex-shrink: 0;
  margin-right: auto; /* Push buttons to right */
}

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

.site-header .desktop-nav-buttons {
  display: flex;
  gap: 12px;
  flex-shrink: 0;
}

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

.site-header .main-nav {
  background: linear-gradient(135deg, var(--dark-bg-light), var(--dark-bg-lighter));
  border-top: 2px solid;
  border-bottom: 2px solid;
  animation: theme-colors 4s ease-in-out infinite;
  box-shadow:
    0 0 8px var(--neon-secondary),
    0 0 15px var(--neon-secondary),
    inset 0 0 8px rgba(255, 0, 255, 0.1);
  min-height: 50px;
  display: flex;
  align-items: center;
  width: 100%;
}

.site-header .nav-container {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  gap: 25px;
  height: 100%;
}

.site-header .nav-link {
  color: var(--secondary-color);
  text-decoration: none;
  font-weight: 500;
  font-size: 16px;
  padding: 8px 0;
  transition: color 0.3s ease, transform 0.3s ease;
  position: relative;
  text-shadow: none; /* NO NEON FOR NAV LINKS */
}

.site-header .nav-link:hover,
.site-header .nav-link.active {
  color: var(--primary-color);
  transform: translateY(-2px);
}

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

.btn:hover {
  animation-duration: 2s;
  transform: translateY(-2px) scale(1.02);
  box-shadow:
    0 0 15px var(--neon-primary),
    0 0 25px var(--neon-primary),
    0 0 35px var(--neon-primary),
    inset 0 0 15px rgba(0, 255, 255, 0.4);
}

/* Hamburger Menu */
.hamburger-menu {
  display: none; /* Hidden on desktop */
  width: 40px;
  height: 40px;
  background: transparent;
  border: none;
  cursor: pointer;
  position: relative;
  z-index: 1002;
  padding: 0;
  flex-shrink: 0;
  margin-right: 15px;
}

.hamburger-icon {
  display: block;
  width: 28px;
  height: 3px;
  background-color: var(--neon-primary);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  transition: background-color 0.3s ease;
  border-radius: 2px;
  box-shadow:
    0 0 5px var(--neon-primary),
    0 0 10px var(--neon-primary);
}

.hamburger-icon::before,
.hamburger-icon::after {
  content: '';
  width: 100%;
  height: 3px;
  background-color: var(--neon-primary);
  position: absolute;
  left: 0;
  border-radius: 2px;
  transition: transform 0.3s ease, top 0.3s ease, bottom 0.3s ease, background-color 0.3s ease;
  box-shadow:
    0 0 5px var(--neon-primary),
    0 0 10px var(--neon-primary);
}

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

.hamburger-icon::after {
  bottom: -8px;
}

.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-secondary);
  box-shadow:
    0 0 5px var(--neon-secondary),
    0 0 10px var(--neon-secondary);
}

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

/* Mobile Menu Overlay */
.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;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease;
}

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

body.no-scroll {
  overflow: hidden;
}

/* Footer Section */
.site-footer {
  background-color: #1a1a2e; /* Dark background for footer, no neon */
  color: #cccccc;
  padding: 40px 0 20px;
  font-size: 14px;
  line-height: 1.8;
}

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

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

.site-footer h4 {
  color: var(--secondary-color);
  font-size: 16px;
  margin-bottom: 15px;
  font-weight: bold;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 8px;
}

.site-footer .footer-top {
  padding-bottom: 30px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.site-footer .footer-top .footer-container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
}

.site-footer .footer-col .footer-logo {
  font-size: 24px;
  font-weight: bold;
  color: var(--primary-color);
  display: block;
  margin-bottom: 15px;
}

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

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

.site-footer .footer-nav-list li {
  margin-bottom: 8px;
}

.site-footer .footer-middle {
  padding: 30px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.site-footer .footer-middle .footer-container {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  justify-content: space-between;
}

.site-footer .game-providers-section,
.site-footer .social-media-section,
.site-footer .payment-methods {
  flex: 1 1 calc(33% - 20px); /* Distribute space among 3 sections */
  min-width: 250px;
}

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

.site-footer .game-providers-icons img,
.site-footer .social-media-icons img,
.site-footer .payment-icons img {
  max-height: 50px;
  height: auto;
  width: auto;
  object-fit: contain;
}

.site-footer .footer-bottom {
  padding-top: 20px;
  text-align: center;
}

.site-footer .copyright-info {
  color: #888888;
  margin: 0;
}

/* Responsive Design */
@media (max-width: 768px) {
  .header-container,
  .nav-container,
  .footer-container {
    padding-left: 15px;
    padding-right: 15px;
    max-width: none;
    width: 100%;
  }

  /* Marquee Mobile */
  .marquee-section {
    height: 40px;
  }
  .marquee-container {
    padding: 0 10px;
    gap: 10px;
  }
  .marquee-icon {
    width: 25px;
    height: 25px;
  }
  .marquee-icon-emoji {
    font-size: 16px;
  }
  .marquee-text {
    font-size: 13px;
  }
  .marquee-separator {
    font-size: 13px;
    margin: 0 8px;
  }
  .marquee-content {
    gap: 20px;
    animation-duration: 25s;
  }

  /* Header Mobile */
  .site-header {
    top: 40px; /* Marquee height for mobile */
  }

  .site-header .header-top {
    min-height: 50px;
  }

  .site-header .header-container {
    justify-content: flex-start;
    position: relative;
  }

  .site-header .hamburger-menu {
    display: block;
    order: 1;
    margin-left: 0;
  }

  .site-header .logo {
    order: 2;
    flex: 1 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    font-size: 22px;
    padding: 0;
    margin: 0; /* Override desktop margin-right: auto */
  }

  .site-header .logo img {
    max-height: 40px !important;
  }

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

  .site-header .mobile-nav-buttons {
    display: flex !important;
    justify-content: center;
    align-items: center;
    gap: 10px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 10px 15px;
    background: linear-gradient(135deg, #1a1a2e, #0f3460);
    border-bottom: 2px solid;
    animation: theme-colors 4s ease-in-out infinite;
    box-shadow:
      0 0 8px var(--neon-accent),
      0 0 15px var(--neon-accent),
      inset 0 0 8px rgba(255, 255, 0, 0.1);
    flex-wrap: nowrap; /* Ensure buttons stay in one row */
  }

  .site-header .mobile-nav-buttons .btn {
    flex: 1;
    min-width: 0;
    max-width: calc(50% - 5px); /* Account for gap */
    padding: 8px 12px;
    font-size: 13px;
    white-space: normal;
    word-wrap: break-word;
    text-align: center;
  }

  .site-header .main-nav {
    display: none; /* Hidden by default for mobile */
    flex-direction: column;
    position: fixed;
    top: calc(40px + 50px + 50px); /* Marquee + Header Top + Mobile Buttons */
    left: 0;
    width: 280px;
    height: calc(100% - var(--header-offset));
    background: linear-gradient(180deg, var(--dark-bg-light), var(--dark-bg-lighter));
    border-right: 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 10px rgba(0, 255, 255, 0.1);
    transform: translateX(-100%);
    transition: transform 0.3s ease-out;
    z-index: 1000;
    overflow-y: auto;
  }

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

  .site-header .nav-container {
    flex-direction: column;
    align-items: flex-start;
    padding: 20px;
    gap: 15px;
  }

  .site-header .nav-link {
    width: 100%;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .site-header .nav-link:last-child {
    border-bottom: none;
  }

  /* Footer Mobile */
  .site-footer .footer-top .footer-container {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .site-footer .footer-middle .footer-container {
    flex-direction: column;
    gap: 20px;
  }
  
  .site-footer .game-providers-section,
  .site-footer .social-media-section,
  .site-footer .payment-methods {
    flex: 1 1 100%; /* Take full width on mobile */
    min-width: auto;
  }

  /* Mobile content overflow */
  .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;
  }
}
