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

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

html {
  scroll-behavior: smooth;
}

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

a {
  text-decoration: none;
  color: inherit;
}

.site-header {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  background-color: transparent; /* Handled by child sections */
}

.header-top {
  background-color: #000000; /* Primary color */
  padding: 15px 0;
}

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

.logo {
  font-size: 24px;
  font-weight: bold;
  color: #FFFFFF;
  text-transform: uppercase;
  padding-right: 20px; /* Space between logo and buttons/menu if needed */
}

.desktop-nav-buttons {
  display: flex;
  gap: 12px;
}

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

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

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

.btn-register {
  background-color: #FFFFFF; /* Register color */
  color: #000000;
}

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

.main-nav {
  background-color: #333333; /* Contrasting dark color */
  padding: 10px 0;
}

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

.nav-link {
  color: #FFFFFF;
  font-size: 16px;
  padding: 5px 0;
  transition: color 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #FCBC45;
}

/* Mobile specific header parts - initially hidden on desktop */
.mobile-header-bar,
.mobile-nav-buttons,
.hamburger-menu,
.mobile-menu-overlay {
  display: none;
}

/* Footer */
.site-footer {
  background-color: #000000; /* Primary color */
  color: #FFFFFF;
  padding: 40px 0;
  font-size: 14px;
  border-top: 1px solid #333333;
}

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

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

.footer-col:last-child {
  margin-right: 0;
}

.footer-logo {
  font-size: 20px;
  font-weight: bold;
  color: #FFFFFF;
  text-transform: uppercase;
  margin-bottom: 15px;
  display: block;
}

.footer-col h3 {
  font-size: 18px;
  margin-bottom: 20px;
  color: #FCBC45; /* Accent color for titles */
}

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

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

.footer-nav a {
  color: #FFFFFF;
  transition: color 0.3s ease;
}

.footer-nav a:hover {
  color: #FCBC45;
}

.copyright {
  margin-top: 20px;
  font-size: 12px;
  color: #cccccc;
}

/* Mobile responsive styles */
@media (max-width: 768px) {
  .header-top,
  .main-nav {
    display: none; /* Hide desktop header elements */
  }

  .mobile-header-bar {
    display: block;
    background-color: #000000; /* Primary color */
    padding: 15px 0;
  }

  .mobile-header-bar .header-container {
    width: 100%;
    max-width: none;
    padding: 0 15px;
    justify-content: space-between; /* Hamburger left, Logo center */
  }

  .mobile-header-bar .logo {
    flex: 1;
    text-align: center;
    padding: 0;
  }

  .hamburger-menu {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001; /* Above logo for clickability */
  }

  .hamburger-menu .bar {
    width: 100%;
    height: 3px;
    background-color: #FFFFFF;
    transition: all 0.3s ease;
  }

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

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

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

  .mobile-nav-buttons {
    display: block;
    background-color: #1a1a1a; /* Slightly lighter dark for distinction */
    padding: 10px 0;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  }

  .mobile-nav-buttons .header-container {
    width: 100%;
    max-width: none;
    padding: 0 15px;
    display: flex;
    justify-content: center;
    gap: 12px;
  }

  .main-nav {
    display: none; /* Hidden by default */
    flex-direction: column;
    position: fixed;
    top: var(--header-offset); /* Start below the fixed header */
    left: 0;
    width: 80%;
    height: calc(100% - var(--header-offset));
    background-color: #222222; /* Menu background */
    transform: translateX(-100%); /* Slide out of view */
    transition: transform 0.3s ease;
    overflow-y: auto;
    z-index: 999; /* Below hamburger menu */
    padding-top: 20px;
  }

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

  .main-nav .nav-container {
    flex-direction: column;
    align-items: flex-start;
    padding: 0 20px;
    width: 100%;
    max-width: none;
  }

  .main-nav .nav-link {
    width: 100%;
    padding: 15px 0;
    border-bottom: 1px solid #444444;
    font-size: 18px;
  }

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

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

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

  body.no-scroll {
    overflow: hidden;
  }

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

  .footer-col {
    text-align: center;
    min-width: unset;
    width: 100%;
    margin-bottom: 25px;
  }

  .footer-col h3 {
    margin-top: 0;
  }

  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }
  body {
    overflow-x: 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;
  }
}
