:root {
  --primary-color: #0A2E36;
  --secondary-color: #FFD700;
  --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) */
  }
}

/* Base styles */
body {
  margin: 0;
  font-family: Arial, sans-serif;
  color: #333;
  line-height: 1.6;
  padding-top: var(--header-offset); /* Apply header offset to body */
}

body.no-scroll {
  overflow: hidden;
}

/* Header styles */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  background-color: #fff; /* Neutral background for the entire fixed header */
}

.header-top {
  background-color: var(--primary-color); /* Dark primary color for top bar */
  padding: 15px 0; /* Vertical padding for header-top */
  min-height: 30px; /* Ensure minimum height */
  display: flex;
  align-items: center;
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%; /* Ensure container fills width on desktop */
  padding: 0 20px; /* Horizontal padding for container */
}

.logo {
  font-size: 24px;
  font-weight: bold;
  color: var(--secondary-color); /* Gold color for logo */
  text-decoration: none;
  text-transform: uppercase;
  display: block; /* Ensure logo is visible */
}

.desktop-nav-buttons {
  display: flex; /* Visible on desktop */
  gap: 10px;
}

.btn {
  display: inline-block;
  padding: 8px 15px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s ease, color 0.3s ease;
  white-space: nowrap;
  border: none; /* Remove default button border */
  line-height: 1;
  height: 30px; /* Fixed height for buttons */
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-login {
  background-color: #e0a800; /* Slightly darker gold for login */
  color: var(--primary-color); /* Dark text for contrast */
}

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

.btn-register {
  background-color: var(--secondary-color); /* Gold for register */
  color: var(--primary-color); /* Dark text for contrast */
}

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

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

.hamburger-menu .bar {
  display: block;
  width: 25px;
  height: 3px;
  background-color: var(--secondary-color); /* Gold bars */
  margin: 5px auto;
  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);
}

/* Main Navigation */
.main-nav {
  background-color: var(--secondary-color); /* Gold for main nav */
  width: 100%;
  display: flex; /* Visible on desktop */
  justify-content: center;
  padding: 15px 0; /* Vertical padding for main-nav */
  min-height: 20px; /* Ensure minimum height for nav links */
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  width: 100%; /* Ensure container fills width on desktop */
  padding: 0 20px; /* Horizontal padding for container */
  gap: 25px; /* Spacing between nav links */
}

.nav-link {
  color: var(--primary-color); /* Dark text for nav links */
  text-decoration: none;
  font-weight: bold;
  padding: 5px 0;
  transition: color 0.3s ease;
  white-space: nowrap;
}

.nav-link:hover {
  color: #000; /* Darker hover effect */
}

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

.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;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-menu-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* Footer styles */
.site-footer {
  background-color: var(--primary-color); /* Dark primary color for footer */
  color: #fff; /* White text for footer */
  padding: 40px 20px;
  font-size: 14px;
  text-align: center;
}

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

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

.footer-col.footer-info {
  flex-basis: 100%; /* Take full width on small screens initially */
  text-align: center;
}

.footer-logo {
  font-size: 20px;
  font-weight: bold;
  color: var(--secondary-color); /* Gold for footer logo */
  text-decoration: none;
  text-transform: uppercase;
  margin-bottom: 15px;
  display: inline-block;
}

.footer-col h3 {
  color: var(--secondary-color); /* Gold for footer headings */
  font-size: 16px;
  margin-bottom: 15px;
  text-transform: uppercase;
}

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

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

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

.footer-col ul li a:hover {
  color: var(--secondary-color); /* Gold hover for footer links */
}

/* Mobile styles */
@media (max-width: 768px) {
  /* Mobile Content Overflow */
  .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 mobile layout */
  .site-header {
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2); /* Ensure shadow is visible on mobile */
  }

  .header-top {
    padding: 15px 0; /* Consistent vertical padding */
  }

  .header-container {
    padding: 0 15px; /* Smaller horizontal padding */
    width: 100%; /* Occupy full width */
    max-width: none; /* No max-width on mobile */
    justify-content: space-between; /* Hamburger left, logo center, space right */
  }

  .hamburger-menu {
    display: block; /* Show hamburger on mobile */
    order: 1; /* Place it first */
    color: var(--secondary-color);
  }

  .logo {
    order: 2; /* Place logo second */
    flex: 1 !important; /* Force flex item to take available space */
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    font-size: 20px; /* Smaller font size for mobile logo */
  }

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

  .main-nav {
    display: none; /* Hide main nav by default on mobile */
    flex-direction: column;
    position: fixed;
    top: var(--header-offset); /* Start below the fixed header + buttons */
    left: 0;
    width: 80%; /* Sidebar width */
    height: calc(100% - var(--header-offset)); /* Fill remaining height */
    background-color: var(--primary-color); /* Dark background for mobile menu */
    transform: translateX(-100%); /* Start off-screen */
    transition: transform 0.3s ease;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.3);
    overflow-y: auto; /* Enable scrolling for long menus */
    z-index: 1000;
    padding: 0; /* Remove default padding */
  }

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

  .nav-container {
    flex-direction: column;
    padding: 20px 15px; /* Adjust padding for vertical menu */
    width: 100%; /* Occupy full width */
    max-width: none; /* No max-width on mobile */
    align-items: flex-start; /* Align links to the left */
    gap: 15px; /* Spacing between vertical nav links */
  }

  .nav-link {
    width: 100%; /* Full width for clickable area */
    padding: 10px 0;
    color: #fff; /* White text for mobile menu links */
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

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

  .mobile-nav-buttons {
    display: flex; /* Show mobile buttons below header-top */
    background-color: var(--primary-color); /* Consistent background */
    padding: 15px 15px; /* Padding for button area */
    justify-content: center;
    gap: 10px;
    width: 100%;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); /* Subtle shadow for separation */
    min-height: 30px; /* Ensure minimum height */
  }

  .mobile-nav-buttons .btn {
    flex: 1; /* Distribute space evenly */
    text-align: center;
  }

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

  /* Footer mobile layout */
  .footer-container {
    flex-direction: column;
    gap: 20px;
  }

  .footer-col {
    text-align: center;
    min-width: unset; /* Remove min-width for mobile */
  }
}
/* 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;
  }
}
