:root {
  --primary-color: #0A192F;
  --accent-color: #FFD700;
  --text-light: #F0F0F0;
  --text-dark: #0A192F;
  --header-offset: 90px; /* Desktop: header-top (50px) + main-nav (40px) */
}

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

body {
  font-family: 'Arial', sans-serif;
  margin: 0;
  padding-top: var(--header-offset); /* Apply header offset to body */
  background-color: #F8F8F8;
  color: var(--text-dark);
  overflow-x: hidden; /* Prevent horizontal scroll on desktop */
}

.site-header {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  background-color: var(--primary-color); /* Default background for entire header */
}

.header-top {
  background-color: var(--primary-color); /* Deep blue */
  width: 100%;
  min-height: 50px; /* Base height for 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: 0 20px; /* Left/right padding for desktop */
}

.logo {
  font-size: 24px;
  font-weight: bold;
  color: var(--accent-color); /* Gold color for logo */
  text-decoration: none;
  padding: 15px 0; /* Vertical padding to define height */
  display: block; /* Ensure it's a block element */
  white-space: nowrap; /* Prevent logo text from wrapping */
}

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

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

.btn-login {
  background-color: var(--accent-color); /* Gold for login */
  color: var(--primary-color); /* Deep blue text */
  border: 2px solid var(--accent-color);
}

.btn-login:hover {
  background-color: #e6c200; /* Darker gold on hover */
}

.btn-register {
  background-color: var(--primary-color); /* Deep blue for register */
  color: var(--accent-color); /* Gold text */
  border: 2px solid var(--accent-color);
}

.btn-register:hover {
  background-color: #1A304D; /* Darker blue on hover */
}

.main-nav {
  background-color: #1A304D; /* Darker blue, distinct from header-top */
  width: 100%;
  min-height: 40px; /* Base height for main-nav */
  display: flex; /* Show on desktop */
  justify-content: center;
  align-items: center;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-wrap: wrap; /* Allow wrapping on smaller screens */
  justify-content: center;
  align-items: center;
  padding: 0 20px; /* Left/right padding for desktop */
}

.nav-link {
  color: var(--text-light); /* Light text for navigation links */
  text-decoration: none;
  padding: 10px 15px;
  font-weight: 600;
  transition: color 0.3s ease, background-color 0.3s ease;
  white-space: nowrap;
}

.nav-link:hover {
  color: var(--accent-color); /* Gold on hover */
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
}

/* Hamburger menu (hidden on desktop) */
.hamburger-menu {
  display: none; /* Hidden on desktop */
  cursor: pointer;
  padding: 15px;
  z-index: 1001; /* Above other elements */
}

.hamburger-menu .bar {
  width: 25px;
  height: 3px;
  background-color: var(--accent-color); /* Gold bars */
  margin: 5px 0;
  transition: 0.4s;
}

.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: 998; /* Below menu, above content */
  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); /* Deep blue for footer */
  color: var(--text-light); /* Light text for footer */
  padding: 40px 0 20px;
  font-size: 14px;
}

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

.footer-col {
  flex: 1;
  min-width: 250px;
}

.footer-col h3 {
  color: var(--accent-color); /* Gold for footer headings */
  font-size: 18px;
  margin-bottom: 15px;
}

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

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

.footer-col ul li a {
  color: var(--text-light);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-col ul li a:hover {
  color: var(--accent-color);
}

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

.footer-bottom p {
  margin: 0;
  color: #B0B0B0; /* Slightly lighter grey for copyright */
}

/* --- 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 {
    padding: 0 15px; /* Smaller padding on mobile */
    justify-content: space-between; /* Hamburger left, Logo center */
  }

  .hamburger-menu {
    display: block; /* Show hamburger on mobile */
    order: 0; /* Position to the left */
    flex-shrink: 0; /* Don't shrink */
  }

  .logo {
    flex: 1 !important; /* Take remaining space */
    display: flex !important;
    justify-content: center !important; /* Center logo */
    align-items: center !important;
    font-size: 20px; /* Adjust logo size for mobile */
    padding: 10px 0; /* Adjust padding for mobile */
  }

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

  .main-nav {
    display: none; /* Hidden by default on mobile */
    position: fixed;
    top: var(--header-offset); /* Position below fixed header */
    left: 0;
    width: 80%; /* Menu width */
    height: calc(100% - var(--header-offset)); /* Full height below header */
    background-color: var(--primary-color); /* Menu background */
    flex-direction: column;
    align-items: flex-start;
    transform: translateX(-100%); /* Slide out from left */
    transition: transform 0.3s ease-in-out;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.2);
    overflow-y: auto; /* Allow scrolling if menu is long */
  }

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

  .nav-container {
    flex-direction: column;
    align-items: flex-start;
    padding: 20px 15px; /* Padding for mobile menu items */
    width: 100%;
    max-width: none; /* No max-width on mobile */
  }

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

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

  .mobile-nav-buttons {
    display: flex; /* Show mobile buttons */
    width: 100%;
    background-color: #1A304D; /* Background for mobile buttons area, different from header-top */
    justify-content: center;
    gap: 10px;
    padding: 10px 15px; /* Padding for mobile buttons area */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05); /* Subtle shadow */
    min-height: 40px; /* Base height for mobile buttons */
  }

  .site-header {
    flex-direction: column; /* Stack header-top and mobile-nav-buttons */
  }

  .header-top {
    width: 100%;
  }
  
  /* Hamburger menu active state */
  .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-col {
    min-width: 100%; /* Stack columns on mobile */
    text-align: center;
  }

  .footer-col ul {
    text-align: center;
  }
}
/* 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;
  }
}
