:root {
  --primary-color: #8B0000; /* Burgundy Red */
  --secondary-color: #FFD700; /* Gold */
  --dark-bg-1: #0a0a0a;
  --dark-bg-2: #1a1a2e;
  --dark-bg-3: #16213e;
  --text-color: #ffffff;
  --link-color: #ffffff;
  --neon-primary: var(--primary-color); /* Initial neon primary from site primary */
  --neon-secondary: var(--secondary-color); /* Initial neon secondary from site secondary */
  --neon-accent: #00ffff; /* A vibrant accent for dynamic effects */

  --marquee-height-desktop: 45px; /* Estimated marquee height */
  --header-top-height-desktop: 60px; /* Estimated header-top height */
  --main-nav-height-desktop: 50px; /* Estimated main-nav height */
  --header-offset: calc(var(--marquee-height-desktop) + var(--header-top-height-desktop) + var(--main-nav-height-desktop));
}

@media (max-width: 768px) {
  :root {
    --marquee-height-mobile: 30px; /* Estimated marquee height mobile */
    --header-top-height-mobile: 50px; /* Estimated header-top height mobile (hamburger + logo) */
    --mobile-nav-buttons-height-mobile: 50px; /* Estimated mobile buttons height */
    --header-offset: calc(var(--marquee-height-mobile) + var(--header-top-height-mobile) + var(--mobile-nav-buttons-height-mobile));
  }
}

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

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

a:hover {
  text-decoration: underline;
}

/* Neon Glow Animations */
@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 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 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;
  }
}

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

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

/* 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(--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, 0, 255, 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: 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));
}

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

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

/* Site Header */
.site-header {
  position: fixed;
  top: var(--marquee-height-desktop); /* Position below marquee */
  left: 0;
  width: 100%;
  z-index: 1000;
  min-height: var(--header-top-height-desktop);
  background: linear-gradient(135deg, var(--dark-bg-1), 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),
    0 0 30px var(--neon-primary),
    inset 0 0 20px rgba(255, 0, 255, 0.1);
}

.site-header .header-top {
  display: flex;
  align-items: center;
  min-height: var(--header-top-height-desktop);
}

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

/* Logo */
.logo {
  font-size: 28px;
  font-weight: bold;
  color: var(--text-color);
  text-decoration: none;
  display: block;
  text-shadow: none;
  box-shadow: none;
  filter: none;
  animation: none;
}
.logo img {
  display: block;
  max-width: 100%;
  height: auto;
  max-height: 50px;
}

/* Hamburger Menu (Hidden on Desktop) */
.hamburger-menu {
  display: none;
  flex-direction: column;
  justify-content: space-around;
  width: 30px;
  height: 25px;
  cursor: pointer;
  z-index: 1002;
  position: relative;
  animation: theme-colors 4s ease-in-out infinite;
  box-shadow:
    0 0 5px var(--neon-primary),
    0 0 10px var(--neon-primary);
  border-radius: 3px;
  padding: 5px;
}

.hamburger-menu span {
  display: block;
  height: 3px;
  width: 100%;
  background: var(--text-color);
  border-radius: 3px;
  transition: all 0.3s ease;
  text-shadow:
    0 0 3px var(--neon-primary),
    0 0 6px var(--neon-primary);
}

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

/* Mobile Buttons (Hidden on Desktop) */
.mobile-nav-buttons {
  display: none;
}

/* Main Navigation (Desktop) */
.main-nav {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  min-height: var(--main-nav-height-desktop);
  background: linear-gradient(135deg, var(--dark-bg-2), var(--dark-bg-3), #0f3460);
  border-top: 2px solid;
  border-bottom: 2px solid;
  animation: theme-colors 4s ease-in-out infinite;
  box-shadow:
    0 0 10px var(--neon-secondary),
    0 0 20px var(--neon-secondary),
    0 0 30px var(--neon-secondary),
    inset 0 0 20px rgba(0, 255, 255, 0.1);
  padding: 0 20px;
}

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

.nav-link {
  font-size: 16px;
  font-weight: 500;
  color: var(--text-color);
  padding: 8px 15px;
  border-radius: 5px;
  transition: all 0.3s ease;
  text-shadow: none;
  box-shadow: none;
  filter: none;
  animation: none;
}

.nav-link:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: var(--secondary-color);
  text-decoration: none;
}

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

.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),
    inset 0 0 15px rgba(255, 255, 255, 0.4);
}

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

/* Hamburger Menu Active State */
.hamburger-menu.active span:nth-child(1) {
  transform: translateY(11px) rotate(45deg);
}
.hamburger-menu.active span:nth-child(2) {
  opacity: 0;
}
.hamburger-menu.active span:nth-child(3) {
  transform: translateY(-11px) rotate(-45deg);
}

/* Mobile Nav Active State (Desktop hidden) */
.main-nav.active {
  transform: translateX(0);
  display: flex;
}

/* Body no-scroll */
body.no-scroll {
  overflow: hidden;
}

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

.site-footer a {
  color: #cccccc;
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--secondary-color);
  text-decoration: underline;
}

.site-footer h4 {
  color: var(--text-color);
  font-size: 16px;
  margin-bottom: 15px;
  font-weight: bold;
}

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

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

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

.site-footer .footer-description {
  line-height: 1.6;
  word-wrap: break-word;
  overflow-wrap: break-word;
  text-align: justify;
}

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

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

.site-footer .footer-nav li a {
  display: inline-block;
}

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

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

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

.site-footer .footer-section {
  margin-bottom: 20px;
}
.site-footer .footer-section:last-child {
  margin-bottom: 0;
}

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

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

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

.site-footer .footer-legal-nav li a {
  color: #999999;
}

.site-footer .footer-legal-nav li a:hover {
  color: var(--secondary-color);
}

/* Responsive Styles */
@media (max-width: 768px) {
  /* Marquee Mobile */
  .marquee-section {
    height: var(--marquee-height-mobile);
    padding: 0;
  }
  .marquee-container {
    gap: 10px;
    padding: 0 5px;
  }
  .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: 20s;
  }

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

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

  .site-header .header-container {
    padding: 0;
    justify-content: flex-start;
  }

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

  .logo {
    flex: 1 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    order: 2;
    font-size: 22px;
  }
  .logo img {
    max-height: 40px;
  }

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

  .mobile-nav-buttons {
    display: flex !important;
    position: fixed;
    top: calc(var(--marquee-height-mobile) + var(--header-top-height-mobile)); /* Position below header-top */
    left: 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 8px 15px;
    gap: 10px;
    justify-content: center;
    flex-wrap: nowrap;
    background: linear-gradient(135deg, var(--dark-bg-1), var(--dark-bg-2));
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 1001;
  }

  .mobile-nav-buttons .btn {
    flex: 1;
    min-width: 0;
    max-width: calc(50% - 5px);
    padding: 8px 12px;
    font-size: 13px;
    white-space: normal;
    word-wrap: break-word;
    overflow-wrap: break-word;
    text-align: center;
  }
  
  .main-nav {
    display: none;
    flex-direction: column;
    position: fixed;
    top: calc(var(--marquee-height-mobile) + var(--header-top-height-mobile) + var(--mobile-nav-buttons-height-mobile));
    left: 0;
    width: 80%;
    max-width: 300px;
    height: calc(100% - var(--marquee-height-mobile) - var(--header-top-height-mobile) - var(--mobile-nav-buttons-height-mobile));
    background: linear-gradient(135deg, var(--dark-bg-1), var(--dark-bg-2), var(--dark-bg-3));
    transform: translateX(-100%);
    transition: transform 0.3s ease-out;
    z-index: 1000;
    padding: 20px 0;
    overflow-y: auto;
    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);
  }

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

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

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

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

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

  .site-footer .footer-about {
    text-align: center;
  }

  .site-footer .footer-logo {
    margin-bottom: 10px;
  }

  .site-footer .footer-description {
    font-size: 13px;
    text-align: center;
  }

  .site-footer .footer-col h4 {
    text-align: center;
    margin-top: 20px;
  }

  .site-footer .footer-nav,
  .site-footer .footer-legal-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
  }
  .site-footer .footer-legal-nav {
    gap: 10px;
    flex-direction: row;
    justify-content: center;
  }

  .site-footer .footer-middle {
    padding: 15px;
  }
  .site-footer .footer-section h4 {
    text-align: center;
  }

  .site-footer .game-providers-icons,
  .site-footer .social-media-icons {
    justify-content: center;
    gap: 5px;
  }

  .site-footer .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 15px;
    padding: 0 15px;
  }

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