:root {
  --primary-color: #FFD700;
  --secondary-color: #8B0000;
  --text-color: #ffffff;
  --bg-dark: #0a0a0a;
  --bg-darker: #1a1a2e;
  --bg-darkest: #16213e;
  --neon-primary: var(--primary-color, #ff00ff);
  --neon-secondary: var(--secondary-color, #00ffff);
  --neon-accent: #ffff00;
  --header-offset: 160px; /* Desktop: Marquee 45px + Header Top 70px + Main Nav 45px */
}

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

/* General Neon Animations */
@keyframes theme-colors {
  0%, 100% {
    border-color: var(--neon-primary);
    box-shadow: 0 0 10px var(--neon-primary), 0 0 20px var(--neon-primary);
  }
  33% {
    border-color: var(--neon-secondary);
    box-shadow: 0 0 10px var(--neon-secondary), 0 0 20px var(--neon-secondary);
  }
  66% {
    border-color: var(--neon-accent);
    box-shadow: 0 0 10px var(--neon-accent), 0 0 20px var(--neon-accent);
  }
}

@keyframes alternate-glow {
  0%, 100% {
    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);
  }
}

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

/* Marquee Section */
.marquee-section {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: linear-gradient(135deg, var(--bg-dark), var(--bg-darker), var(--bg-darkest));
  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(255, 255, 0, 0.1);
  z-index: 1001;
  padding: 10px 0;
  height: 45px;
  box-sizing: border-box;
}

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

.marquee-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  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;
  padding-right: 30px; /* Ensure space before content repeats */
}

.marquee-text {
  font-size: 16px;
  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.05);
  color: var(--text-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%);
  }
}

/* Site Header */
.site-header {
  position: fixed;
  top: 45px; /* Adjusted to be below marquee */
  left: 0;
  width: 100%;
  z-index: 1000;
  background: linear-gradient(135deg, var(--bg-dark), var(--bg-darker), var(--bg-darkest));
}

.header-top {
  padding: 15px 0;
  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(255, 215, 0, 0.1);
  height: 70px;
  box-sizing: border-box;
  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;
}

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

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

.hamburger-menu {
  display: none; /* Hidden on desktop */
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  position: relative;
  z-index: 1002;
  animation: theme-colors 4s ease-in-out infinite;
  border-radius: 3px;
}

.hamburger-icon {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--neon-primary);
  position: relative;
  transition: background-color 0.3s ease;
  box-shadow: 0 0 5px var(--neon-primary), 0 0 10px var(--neon-primary);
}

.hamburger-icon::before, .hamburger-icon::after {
  content: '';
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--neon-primary);
  position: absolute;
  transition: transform 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 {
  top: 8px;
}

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

.hamburger-menu.active .hamburger-icon::before {
  transform: translateY(8px) 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 {
  transform: translateY(-8px) rotate(-45deg);
  background-color: var(--neon-secondary);
  box-shadow: 0 0 5px var(--neon-secondary), 0 0 10px var(--neon-secondary);
}

.desktop-nav-buttons {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

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

.btn {
  position: relative;
  padding: 12px 25px;
  color: var(--text-color);
  text-decoration: none;
  border-radius: 5px;
  border: 2px solid;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  animation: theme-colors 4s ease-in-out infinite;
  text-shadow: 0 0 5px var(--text-color), 0 0 10px var(--neon-primary);
  background: linear-gradient(135deg, var(--neon-primary), var(--neon-secondary));
  box-sizing: border-box;
}

.btn:hover {
  animation-duration: 2s; /* Faster animation on hover */
  transform: translateY(-2px);
  text-shadow: 0 0 8px var(--text-color), 0 0 15px var(--neon-primary), 0 0 25px var(--neon-primary);
}

.main-nav {
  background: linear-gradient(135deg, var(--bg-darker), var(--bg-darkest), #0f3460);
  border-top: 2px solid;
  border-bottom: 2px solid;
  animation: alternate-glow 4s ease-in-out infinite;
  box-shadow: 0 0 10px var(--neon-secondary), 0 0 20px var(--neon-secondary), inset 0 0 10px rgba(0, 255, 255, 0.1);
  width: 100%;
  display: flex;
  align-items: center;
  height: 45px;
  box-sizing: border-box;
}

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

.nav-link {
  color: var(--text-color);
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  padding: 10px 15px;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

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

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

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

/* Footer */
.site-footer {
  background-color: var(--bg-dark);
  color: rgba(255, 255, 255, 0.8);
  padding: 40px 0 20px;
  font-size: 14px;
  line-height: 1.6;
}

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

.footer-col h4 {
  color: var(--primary-color);
  font-size: 18px;
  margin-bottom: 15px;
  font-weight: 600;
}

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

.footer-description {
  word-wrap: break-word;
  overflow-wrap: break-word;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.7);
}

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

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

.footer-nav-links a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.3s ease;
}

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

.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(0.8);
  transition: filter 0.3s ease;
}

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

.game-providers-section, .social-media-section {
  max-width: 1200px;
  margin: 20px auto 30px;
  padding: 0 20px;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 20px;
  text-align: center;
  max-width: 1200px;
  margin: 0 auto;
  padding-left: 20px;
  padding-right: 20px;
}

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

/* Mobile Responsive */
@media (max-width: 768px) {
  .marquee-section {
    padding: 0;
    height: 30px;
  }
  .marquee-container {
    padding: 0 10px;
    gap: 10px;
  }
  .marquee-icon {
    width: 20px;
    height: 20px;
  }
  .marquee-icon-emoji {
    font-size: 18px;
  }
  .marquee-text {
    font-size: 13px;
    line-height: 1.2;
  }
  .marquee-separator {
    font-size: 13px;
    margin: 0 8px;
  }
  .marquee-content {
    gap: 20px;
    animation-duration: 25s;
  }

  .site-header {
    top: 30px; /* Below mobile marquee */
  }
  .header-top {
    padding: 10px 0;
    height: 50px;
  }
  .header-container {
    padding: 0 15px;
    justify-content: space-between;
    position: relative;
  }

  .hamburger-menu {
    display: block;
    order: 0; /* Left side */
    margin-right: auto;
  }
  .logo {
    order: 1;
    flex: 1 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    font-size: 24px;
    padding-right: 0;
    max-width: calc(100% - 100px); /* Adjust for hamburger */
  }
  .logo img {
    max-height: 30px;
  }
  .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(--bg-dark), var(--bg-darker));
    border-bottom: 2px solid;
    animation: theme-colors 4s ease-in-out infinite;
    box-shadow: 0 0 8px var(--neon-primary), inset 0 0 5px rgba(255, 215, 0, 0.1);
    height: 55px;
    box-sizing: border-box;
    flex-wrap: nowrap; /* Prevent wrapping */
  }
  .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;
    overflow-wrap: break-word;
    text-align: center;
  }

  .main-nav {
    display: none; /* Hidden by default, shown with JS */
    flex-direction: column;
    position: fixed;
    top: var(--header-offset); /* Below fixed header elements */
    left: 0;
    width: 100%;
    height: calc(100% - var(--header-offset));
    background: linear-gradient(135deg, var(--bg-darkest), var(--bg-darker), var(--bg-dark));
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    padding: 20px 0;
    box-shadow: 0 0 15px var(--neon-secondary), 0 0 30px var(--neon-secondary), inset 0 0 15px rgba(0, 255, 255, 0.1);
    z-index: 1000;
    overflow-y: auto;
    justify-content: flex-start;
    align-items: flex-start;
    border: none;
  }
  .main-nav.active {
    display: flex; /* Must set display for it to be visible */
    transform: translateX(0);
  }
  .nav-container {
    flex-direction: column;
    align-items: flex-start;
    padding: 0 15px;
    width: 100%;
    max-width: none;
  }
  .nav-link {
    width: 100%;
    padding: 12px 15px;
    font-size: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }
  .nav-link:last-child {
    border-bottom: none;
  }

  .footer-top-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .footer-col {
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }
  .footer-col:last-child {
    border-bottom: none;
  }
  .game-providers-section, .social-media-section {
    padding: 0 15px;
  }
  .footer-bottom {
    padding-left: 15px;
    padding-right: 15px;
  }
  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }
  body {
    overflow-x: hidden;
  }
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background-color: #121212;
  color: var(--text-color);
  padding-top: var(--header-offset);
}

body.no-scroll {
  overflow: 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;
  }
}
