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

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

/* Global styles for site-header */
.site-header {
  position: fixed;
  top: 0;
  width: 100%;
  background-color: #000000; /* Primary background for the entire header */
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  z-index: 1000;
  display: flex;
  flex-direction: column; /* Stacks header-top and main-nav vertically on desktop */
}

.header-top {
  background-color: #000000; /* Black for top bar */
  width: 100%;
  min-height: 80px; /* Base height for desktop header-top */
  display: flex;
  align-items: center;
}

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

.logo {
  color: #FCBC45; /* Login button color for logo text */
  font-size: 28px;
  font-weight: bold;
  text-decoration: none;
  text-transform: uppercase;
  display: block; /* Ensure logo is always visible */
  padding: 0; /* Remove default padding */
}

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

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

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

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

.btn-register {
  background-color: #FFFFFF;
  color: #000000;
  border: 1px solid #FCBC45;
}

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

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

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

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

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

.main-nav {
  background-color: #333333; /* Dark gray for navigation bar, contrasts with black header-top */
  width: 100%;
  min-height: 60px; /* Base height for desktop main-nav */
  display: flex; /* Always flex on desktop */
  align-items: center;
  justify-content: center; /* Center nav links on desktop */
  transition: transform 0.3s ease; /* For mobile menu animation */
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-direction: row; /* Horizontal on desktop */
  justify-content: center; /* Center nav links */
  align-items: center;
  padding: 10px 20px;
}

.nav-link {
  color: #FFFFFF;
  text-decoration: none;
  padding: 10px 15px;
  white-space: nowrap;
  transition: color 0.3s ease, background-color 0.3s ease;
}

.nav-link:hover {
  color: #FCBC45;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 3px;
}

.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.5);
  z-index: 998;
}

/* Footer styles */
.site-footer {
  background-color: #000000;
  color: #FFFFFF;
  padding: 40px 20px;
  text-align: center;
}

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

.footer-column {
  flex: 1;
  min-width: 200px;
  text-align: left;
}

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

.site-footer p {
  font-size: 14px;
  line-height: 1.5;
  margin: 0;
}

.site-footer h3 {
  color: #FCBC45;
  font-size: 18px;
  margin-bottom: 15px;
  text-transform: uppercase;
}

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

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

.footer-nav a {
  color: #FFFFFF;
  text-decoration: none;
  font-size: 14px;
  transition: color 0.3s ease;
}

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

/* 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 {
    min-height: 70px; /* Base height for mobile header-top */
  }

  .header-container {
    padding: 15px 15px;
    justify-content: space-between;
  }

  .hamburger-menu {
    display: block;
    order: 1;
  }

  .logo {
    order: 2;
    flex: 1;
    text-align: center;
    font-size: 24px;
  }

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

  .mobile-nav-buttons {
    display: flex; /* Show mobile buttons */
    justify-content: center;
    gap: 10px;
    padding: 15px 15px;
    background-color: #000000; /* Same as header-top */
    min-height: 70px; /* Base height for mobile button area */
  }

  .main-nav {
    display: none; /* Hidden by default on mobile */
    position: fixed;
    top: var(--header-offset); /* Position below the main header and mobile buttons */
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-offset)); /* Take remaining viewport height */
    flex-direction: column; /* Vertical on mobile */
    transform: translateX(-100%); /* Slide out to the left */
    background-color: #000000; /* Dark background for mobile menu */
    z-index: 999; /* Below overlay, above content */
    overflow-y: auto; /* Enable scrolling for long menus */
    padding: 20px 0;
  }

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

  .nav-container {
    flex-direction: column;
    padding: 0 15px;
  }

  .nav-link {
    width: 100%;
    text-align: center;
    padding: 15px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

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

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

  .site-footer {
    padding: 30px 15px;
  }

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

  .footer-column {
    min-width: unset;
    text-align: center;
  }

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

  .site-footer h3 {
    margin-top: 20px;
    margin-bottom: 10px;
  }
}

/* Utility class for no-scroll on body */
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;
  }
}
