:root {
  --header-offset: 110px; /* Desktop: header-top (60px) + main-nav (50px) */
}

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

body {
  margin: 0;
  font-family: Arial, sans-serif;
  color: #333;
  line-height: 1.6;
  background-color: #FFFFFF; /* Global background color */
  padding-top: var(--header-offset); /* Ensure content is not hidden by fixed header */
  overflow-x: hidden; /* Prevent horizontal scroll on body */
}

body.no-scroll {
  overflow: hidden;
}

.site-header {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  background-color: #000000; /* Default header background for desktop */
}

.header-top {
  background-color: #000000; /* Header top background - Primary color */
  min-height: 60px; /* Ensure sufficient height */
  display: flex;
  align-items: center;
  padding: 0 20px; /* Padding for desktop header-top */
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 20px; /* Padding inside container for logo and buttons */
}

.logo {
  color: #FFFFFF; /* Logo text color - Secondary color */
  text-decoration: none;
  font-size: 24px;
  font-weight: bold;
  padding: 10px 0; /* Vertical padding for logo */
  display: block; /* Ensure logo is block-level for padding */
}

.desktop-nav-buttons {
  display: flex;
  gap: 12px; /* Spacing between desktop buttons */
}

.btn {
  padding: 10px 20px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  text-align: center;
  white-space: nowrap;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  display: inline-block; /* Ensure buttons behave like blocks for padding */
}

.btn-login {
  background-color: #FCBC45; /* Login button color */
  color: #000000; /* Login button text color */
}

.btn-login:hover {
  background-color: #e0a53d;
}

.btn-register {
  background-color: #FFFFFF; /* Register button color */
  color: #000000; /* Register button text color */
  border: 1px solid #FCBC45; /* Border for register button */
}

.btn-register:hover {
  background-color: #f0f0f0;
  border-color: #e0a53d;
}

.main-nav {
  background-color: #FFFFFF; /* Main nav background - Secondary color */
  min-height: 50px; /* Ensure sufficient height */
  display: flex; /* Desktop: visible by default */
  align-items: center;
  padding: 0 20px; /* Padding for desktop main-nav */
}

.main-nav .nav-container {
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  justify-content: center; /* Center menu items horizontally */
  align-items: center;
  gap: 25px; /* Spacing between nav links */
  padding: 10px 20px; /* Padding inside container for nav links */
}

.nav-link {
  color: #000000; /* Nav link color - Primary color */
  text-decoration: none;
  font-weight: bold;
  padding: 5px 0;
  white-space: nowrap;
  transition: color 0.3s ease;
}

.nav-link:hover {
  color: #FCBC45; /* Hover color for nav links */
}

.hamburger-menu {
  display: none; /* Hidden on desktop */
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  z-index: 1001; /* Above mobile menu overlay */
}

.hamburger-menu .bar {
  display: block;
  width: 25px;
  height: 3px;
  background-color: #FFFFFF; /* Hamburger bar color */
  margin: 5px auto;
  transition: all 0.3s ease;
}

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

.mobile-menu-overlay {
  display: none; /* Hidden on desktop */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 999; /* Below hamburger menu, above main content */
}

.site-footer {
  background-color: #000000; /* Footer background - Primary color */
  color: #FFFFFF; /* Footer text color - Secondary color */
  padding: 40px 20px 20px;
  font-size: 14px;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 20px;
}

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

.footer-col h3 {
  color: #FCBC45; /* Footer heading color */
  font-size: 16px;
  margin-bottom: 15px;
}

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

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

.footer-nav a {
  color: #FFFFFF; /* Footer link color - Secondary color */
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-nav a:hover {
  color: #FCBC45; /* Footer link hover color */
}

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

.footer-bottom p {
  margin: 0;
  color: #CCCCCC; /* Lighter color for copyright text */
}

/* 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-top {
    justify-content: space-between; /* Space out hamburger, logo, and empty space */
    padding: 0 15px; /* Smaller padding for mobile */
  }

  .header-container {
    width: 100%;
    max-width: none; /* Crucial: Mobile container takes full width */
    padding: 0; /* No internal padding, header-top handles it */
    position: relative; /* For absolute positioning of logo if needed */
  }

  .hamburger-menu {
    display: block; /* Show hamburger on mobile */
    order: 0; /* Position hamburger first */
    padding: 10px 0; /* Adjust padding */
  }

  .logo {
    flex: 1 !important; /* Allow logo to take available space */
    display: flex !important; /* Use flex for centering */
    justify-content: center !important; /* Center logo */
    align-items: center !important;
    padding: 10px 0; /* Adjust vertical padding */
    order: 1; /* Position logo after hamburger */
    text-align: center; /* For text logo */
  }

  /* For image logo (if applicable, not used here but kept for compliance) */
  .logo img {
    display: block !important;
    max-width: 100%;
    height: auto;
    max-height: 40px;
  }
  
  .desktop-nav-buttons {
    display: none; /* Hide desktop buttons on mobile */
  }

  .mobile-nav-buttons {
    display: flex; /* Show mobile buttons */
    justify-content: center;
    align-items: center;
    gap: 10px;
    background-color: #000000; /* Same as header-top for consistency */
    padding: 10px 15px; /* Padding for mobile buttons area */
    min-height: 60px; /* Ensure sufficient height */
  }

  .main-nav {
    display: none; /* Hidden by default on mobile */
    flex-direction: column;
    position: fixed;
    top: var(--header-offset); /* Start below the fixed header + mobile buttons */
    left: 0;
    width: 250px;
    height: calc(100% - var(--header-offset)); /* Take remaining height */
    background-color: #FFFFFF; /* Menu background */
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.2);
    transform: translateX(-100%); /* Slide out to the left */
    transition: transform 0.3s ease;
    overflow-y: auto; /* Enable scrolling for long menus */
    z-index: 1000; /* Below overlay, above content */
  }

  .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; /* Align menu items to the left */
    padding: 20px 15px; /* Adjust padding for mobile menu */
    gap: 15px; /* Spacing between mobile nav links */
    max-width: none; /* Crucial: Mobile nav container takes full width */
  }

  .nav-link {
    width: 100%;
    padding: 10px 0;
    border-bottom: 1px solid #eee; /* Separator for mobile links */
  }

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

  .mobile-menu-overlay.active {
    display: block; /* Show overlay when active */
  }

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

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

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

  .footer-container {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .footer-col {
    min-width: unset;
    width: 100%;
  }
}
/* 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;
  }
}
