:root {
  --header-offset: 120px; /* Desktop: Header + button area total height */
}
@media (max-width: 768px) {
  :root {
    --header-offset: 200px; /* Mobile: Marquee/Header/button area total height */
  }
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  color: #f0f0f0;
  background-color: #121212;
}

/* Shared Container Styles */
.header-container,
.nav-container,
.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding-left: 20px;
  padding-right: 20px;
  display: flex;
  align-items: center;
}

/* Site Header - Fixed Navigation */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

/* Header Top Section */
.header-top {
  background-color: #0A1931; /* Primary Dark Blue */
  padding: 15px 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header-top .header-container {
  justify-content: space-between;
}

.logo {
  font-size: 28px;
  font-weight: bold;
  color: #E0B400; /* Secondary Gold */
  text-decoration: none;
  padding: 5px 0;
  display: block; /* Ensure it's not hidden */
}

/* Desktop Navigation Buttons */
.desktop-nav-buttons {
  display: flex;
  gap: 12px;
}

.btn {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease, transform 0.3s ease;
  white-space: nowrap;
  cursor: pointer;
}

.btn-register {
  background-color: #E0B400; /* Secondary Gold */
  color: #0A1931;
  border: none;
}

.btn-register:hover {
  background-color: #ffd700;
  transform: translateY(-2px);
}

.btn-login {
  background-color: #0A1931;
  color: #E0B400;
  border: 2px solid #E0B400;
}

.btn-login:hover {
  background-color: #E0B400;
  color: #0A1931;
  transform: translateY(-2px);
}

/* Main Navigation (Desktop) */
.main-nav {
  background-color: #1E3A5F; /* Slightly lighter dark blue for contrast */
  padding: 10px 0;
  display: flex; /* Desktop default: flex */
  flex-direction: row; /* Desktop default: row */
  position: static; /* Desktop default: static */
}

.main-nav .nav-container {
  justify-content: center;
  gap: 25px;
}

.nav-link {
  color: #f0f0f0;
  text-decoration: none;
  font-weight: bold;
  padding: 8px 15px;
  transition: color 0.3s ease, background-color 0.3s ease, transform 0.3s ease;
  border-radius: 4px;
  white-space: nowrap;
}

.nav-link:hover,
.nav-link.active {
  color: #E0B400;
  background-color: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
}

/* Hamburger Menu (Hidden on Desktop) */
.hamburger-menu {
  display: none; /* Hidden on desktop */
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  position: relative;
  z-index: 1001;
}

.hamburger-menu span {
  display: block;
  width: 25px;
  height: 3px;
  background-color: #E0B400;
  margin: 5px 0;
  transition: all 0.3s ease;
}

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

/* Mobile Menu Overlay (Hidden on Desktop) */
.mobile-menu-overlay {
  display: none; /* Hidden on desktop */
}

/* Site Footer */
.site-footer {
  background-color: #0A1931; /* Primary Dark Blue */
  color: #f0f0f0;
  padding: 40px 0 20px;
  font-size: 14px;
}

.site-footer .footer-container {
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 30px;
}

.footer-col {
  flex: 1;
  min-width: 200px;
  margin-bottom: 20px;
}

.footer-logo {
  font-size: 24px;
  font-weight: bold;
  color: #E0B400;
  text-decoration: none;
  margin-bottom: 15px;
  display: block;
}

.site-footer h3 {
  color: #E0B400;
  font-size: 18px;
  margin-bottom: 15px;
}

.site-footer p {
  line-height: 1.6;
  margin: 0;
}

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

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

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

.site-footer ul li a:hover {
  color: #E0B400;
}

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

/* Mobile Styles */
@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;
  }

  .header-container,
  .nav-container,
  .footer-container {
    padding-left: 15px;
    padding-right: 15px;
    max-width: none; /* Mobile: Occupy full width */
    width: 100%;
  }

  /* Header Top Mobile Layout */
  .header-top .header-container {
    justify-content: space-between;
  }

  .logo {
    flex: 1 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    padding: 0; /* Reset padding for centering */
  }
  .logo img {
    display: block !important;
    max-width: 100%;
    height: auto;
    max-height: 40px;
  }

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

  .hamburger-menu {
    display: block; /* Show hamburger on mobile */
    order: -1; /* Move to the left */
    margin-right: auto; /* Push logo to center */
  }

  .hamburger-menu.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }
  .hamburger-menu.active span:nth-child(2) {
    opacity: 0;
  }
  .hamburger-menu.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }

  /* Mobile Navigation Buttons - Always visible below header-top */
  .mobile-nav-buttons {
    display: flex; /* Show on mobile */
    justify-content: center;
    gap: 10px;
    padding: 10px 15px;
    background-color: #122540; /* Slightly different dark blue */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
    z-index: 990; /* Below main nav, above content */
  }
  .mobile-nav-buttons .btn {
    flex: 1;
    text-align: center;
    padding: 8px 15px;
    font-size: 14px;
  }

  /* Main Navigation Mobile */
  .main-nav {
    display: none; /* Hidden by default on mobile */
    flex-direction: column; /* Vertical layout */
    position: fixed; /* Fixed position for slide-out */
    top: 0;
    left: 0;
    width: 80%; /* Adjust width as needed */
    height: 100vh;
    background-color: #0A1931;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.5);
    transform: translateX(-100%); /* Slide out to the left */
    transition: transform 0.3s ease;
    overflow-y: auto;
    z-index: 1000; /* Ensure it's above other content */
  }

  .main-nav.active {
    display: flex !important; /* Must be flex to override display: none */
    transform: translateX(0); /* Slide in */
  }

  .main-nav .nav-container {
    flex-direction: column;
    align-items: flex-start;
    padding-top: 80px; /* Space for fixed header content */
    gap: 10px;
  }

  .main-nav .nav-link {
    width: 100%;
    padding: 12px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0;
  }
  .main-nav .nav-link:last-child {
    border-bottom: none;
  }

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

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

  /* Footer Mobile Layout */
  .site-footer .footer-container {
    flex-direction: column;
    text-align: center;
  }

  .footer-col {
    min-width: unset;
    width: 100%;
    margin-bottom: 30px;
  }

  .site-footer ul {
    margin-top: 10px;
  }
  .site-footer ul li {
    margin-bottom: 8px;
  }
  .site-footer ul li a {
    display: block;
    padding: 5px 0;
  }
}

/* Prevent body scroll when menu is open */
body.no-scroll {
  overflow: hidden;
}

/* Payment Methods 图标容器样式 */
.payment-icons {
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  align-items: flex-start;
  gap: 5px;
}

.payment-icons img,
.payment-icon {
  max-height: 50px;
  height: auto;
  width: auto;
  display: block;
}

/* Game Providers 图标容器样式 */
.game-providers-icons {
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  align-items: flex-start;
  gap: 8px;
  width: 100%;
}

.game-providers-icons img,
.game-provider-icon {
  max-height: 50px;
  height: auto;
  width: auto;
  display: block;
}

/* Social Media 图标容器样式 */
.social-media-icons {
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  align-items: flex-start;
  gap: 8px;
  width: 100%;
}

.social-media-icons img,
.social-media-icon {
  max-height: 50px;
  height: auto;
  width: auto;
  display: block;
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@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;
  }
}
