:root {
  --primary-color: #FFD700;
  --secondary-color: #8B0000;
  --dark-background-1: #0a0a0a;
  --dark-background-2: #1a1a2e;
  --dark-background-3: #16213e;
  --text-color: #ffffff;
  --neon-primary: var(--primary-color);
  --neon-secondary: var(--secondary-color);
  --neon-accent: #00ffff; /* A vibrant accent for dynamic effects */
  --marquee-height-desktop: 45px;
  --header-top-height-desktop: 60px;
  --main-nav-height-desktop: 50px;
  --header-offset: calc(var(--marquee-height-desktop) + var(--header-top-height-desktop) + var(--main-nav-height-desktop)); /* 桌面端：45 + 60 + 50 = 155px */
}

@media (max-width: 768px) {
  :root {
    --marquee-height-mobile: 30px;
    --header-top-height-mobile: 50px;
    --mobile-nav-buttons-height: 40px;
    --header-offset: calc(var(--marquee-height-mobile) + var(--header-top-height-mobile) + var(--mobile-nav-buttons-height)); /* 移动端：30 + 50 + 40 = 120px */
  }
}

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

.footer-container, .header-container, .nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

a {
  text-decoration: none;
  color: var(--text-color);
}

/* Animations for dynamic neon colors */
@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 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 neon-pulse {
  from { transform: scale(1); opacity: 0.8; }
  to { transform: scale(1.05); opacity: 1; }
}

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

/* Marquee Section Styles */
.marquee-section {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: linear-gradient(135deg, var(--dark-background-1), var(--dark-background-2), var(--dark-background-3));
  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, 215, 0, 0.1);
  z-index: 1001;
  height: var(--marquee-height-desktop);
  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: 0 20px;
}

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

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

@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 content doesn't abruptly end */
}

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

.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.02);
  color: #ffffff;
}

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

/* Header Section Styles */
.site-header {
  position: fixed;
  top: var(--marquee-height-desktop);
  left: 0;
  width: 100%;
  z-index: 1000;
  background: linear-gradient(135deg, var(--dark-background-1), var(--dark-background-2), var(--dark-background-3));
}

.header-top {
  width: 100%;
  background: linear-gradient(135deg, var(--dark-background-1), var(--dark-background-2));
  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 15px rgba(255, 215, 0, 0.1);
  min-height: var(--header-top-height-desktop);
  display: flex;
  align-items: center;
}

.header-top .header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 0 20px;
}

.logo {
  font-size: 28px;
  font-weight: bold;
  color: var(--text-color); /* LOGO uses regular color */
  text-decoration: none;
  display: block;
  padding: 10px 0;
  flex-shrink: 0;
}

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

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

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

.btn {
  position: relative;
  background: linear-gradient(135deg, var(--neon-primary), var(--neon-secondary));
  padding: 12px 25px;
  color: var(--text-color);
  text-decoration: none;
  border-radius: 5px;
  border: 2px solid;
  animation: theme-colors 4s ease-in-out infinite;
  text-shadow:
    0 0 5px #ffffff,
    0 0 10px var(--neon-primary);
  transition: all 0.3s ease;
  font-weight: bold;
  font-size: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

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

/* Main Navigation */
.main-nav {
  width: 100%;
  background: linear-gradient(135deg, var(--dark-background-2), var(--dark-background-3));
  border-top: 2px solid;
  border-bottom: 2px solid;
  animation: rainbow-border 3s linear infinite; /* Different neon effect */
  box-shadow:
    0 0 8px var(--neon-secondary),
    0 0 15px var(--neon-secondary),
    inset 0 0 10px rgba(139, 0, 0, 0.1);
  min-height: var(--main-nav-height-desktop);
  display: flex; /* Desktop default: flex */
  align-items: center;
  flex-direction: row; /* Desktop default: row */
  position: static; /* Desktop default: static */
}

.main-nav .nav-container {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  width: 100%;
  padding: 10px 20px;
}

.nav-link {
  color: var(--text-color);
  font-weight: 600;
  font-size: 17px;
  padding: 8px 0;
  position: relative;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

.nav-link::after {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  width: 0;
  height: 2px;
  background-color: var(--neon-primary);
  box-shadow: 0 0 8px var(--neon-primary), 0 0 15px var(--neon-primary);
  transition: width 0.3s ease;
}

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

.nav-link:hover::after {
  width: 100%;
}

/* Hamburger Menu */
.hamburger-menu {
  display: none; /* Hidden on desktop */
  flex-direction: column;
  justify-content: space-around;
  width: 30px;
  height: 25px;
  cursor: pointer;
  padding: 5px;
  position: relative;
  z-index: 1002; /* Above mobile menu overlay */
}

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

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

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

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

.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.visible {
  display: block;
  opacity: 1;
}

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

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

.footer-top .footer-container {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-col {
  flex: 1 1 22%; /* Approx 4 columns */
  min-width: 180px;
}

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

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

.site-footer h4 {
  color: var(--primary-color);
  font-size: 18px;
  margin-bottom: 15px;
  text-transform: uppercase;
}

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

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

.site-footer ul li a {
  color: #cccccc;
  transition: color 0.3s ease;
}

.site-footer ul li 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(80%) brightness(120%); /* Subtle effect for footer icons */
  transition: filter 0.3s ease;
}

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

.game-providers-section, .social-media-section {
  margin-bottom: 30px;
}

.footer-bottom {
  padding-top: 20px;
  text-align: center;
  color: #888888;
}

/* Responsive Styles */
@media (max-width: 768px) {
  .marquee-section {
    height: var(--marquee-height-mobile);
  }
  .marquee-container {
    gap: 10px;
    padding: 0 10px;
  }
  .marquee-icon {
    width: 20px;
    height: 20px;
  }
  .marquee-icon-emoji {
    font-size: 16px;
  }
  .marquee-text {
    font-size: 13px;
    line-height: 1.3;
  }
  .marquee-separator {
    font-size: 13px;
    margin: 0 8px;
  }
  .marquee-content {
    gap: 15px;
    animation-duration: 20s; /* Faster scroll on mobile */
  }

  .site-header {
    top: var(--marquee-height-mobile);
    min-height: var(--header-top-height-mobile);
  }

  .header-top {
    min-height: var(--header-top-height-mobile);
    padding: 0 15px;
  }

  .header-top .header-container {
    padding: 0;
    justify-content: flex-start;
    gap: 15px;
  }

  .hamburger-menu {
    display: flex;
    order: 0; /* Leftmost */
  }

  .logo {
    flex: 1 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    font-size: 24px;
    padding: 8px 0;
  }
  .logo img {
    max-height: 35px;
  }

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

  .mobile-nav-buttons {
    display: flex !important; /* Show mobile buttons */
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 8px 15px;
    gap: 10px;
    justify-content: center;
    flex-wrap: nowrap; /* Ensure buttons stay in one line */
    background: linear-gradient(135deg, var(--dark-background-1), var(--dark-background-2));
    border-bottom: 2px solid;
    animation: theme-colors 4s ease-in-out infinite;
    box-shadow:
      0 0 8px var(--neon-primary),
      0 0 15px var(--neon-primary),
      inset 0 0 10px rgba(255, 215, 0, 0.1);
    z-index: 999;
  }

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

  .main-nav {
    display: none; /* Hidden by default on mobile */
    flex-direction: column; /* Vertical menu */
    position: fixed;
    top: var(--header-offset); /* Start below fixed header and mobile buttons */
    left: 0;
    width: 80%;
    max-width: 300px;
    height: calc(100% - var(--header-offset));
    overflow-y: auto;
    transform: translateX(-100%); /* Off-screen by default */
    transition: transform 0.3s ease;
    z-index: 1000; /* Above overlay */
    border-right: 2px solid;
    animation: rainbow-border 3s linear infinite;
    box-shadow:
      0 0 8px var(--neon-secondary),
      0 0 15px var(--neon-secondary),
      inset 0 0 10px rgba(139, 0, 0, 0.1);
  }

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

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

  .nav-link {
    width: 100%;
    padding: 10px 0;
    font-size: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }
  .nav-link::after {
    display: none; /* Hide underline effect on mobile */
  }
  .nav-link:hover::after {
    width: 0;
  }

  .footer-top .footer-container {
    flex-direction: column;
    gap: 30px;
  }

  .footer-col {
    flex: 1 1 100%;
    min-width: unset;
  }

  .footer-container {
    padding: 0 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;
  }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@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;
  }
}
