:root {
  --header-offset: 120px; /* Desktop: Header + button area total height */
}
@media (max-width: 768px) {
  :root {
    --header-offset: 200px; /* Mobile: Header + button area total height */
  }
}

/* Base Styles */
body {
  margin: 0;
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #333333; /* Dark grey for better contrast */
}

/* Site Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  background-color: #ffffff;
}

.header-top {
  background-color: #003366; /* Primary color */
  padding: 10px 0;
  color: #ffffff;
}

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

.logo {
  font-size: 28px;
  font-weight: bold;
  color: #FFD700; /* Secondary color for logo text */
  text-decoration: none;
  text-transform: uppercase;
  display: block;
}

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

.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;
  border: none;
  cursor: pointer;
}

.btn-login {
  background-color: #003366; /* Primary color */
  color: #ffffff;
  border: 1px solid #FFD700; /* Secondary color border */
}

.btn-login:hover {
  background-color: #002244; /* Darker primary */
  color: #FFD700;
}

.btn-register {
  background-color: #FFD700; /* Secondary color */
  color: #003366; /* Primary color for text */
  border: 1px solid #003366;
}

.btn-register:hover {
  background-color: #e6c200; /* Darker secondary */
  color: #002244;
}

.main-nav {
  background-color: #FFD700; /* Secondary color for nav bar */
  padding: 10px 0;
  width: 100%;
  display: flex;
  flex-direction: row; /* Desktop default */
}

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

.nav-link {
  color: #003366; /* Primary color for nav links */
  text-decoration: none;
  padding: 8px 15px;
  font-weight: bold;
  transition: color 0.3s ease, background-color 0.3s ease;
  white-space: nowrap;
}

.nav-link:hover,
.nav-link.active {
  color: #ffffff;
  background-color: #003366;
  border-radius: 5px;
}

.hamburger-menu {
  display: none; /* Hidden on desktop */
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  width: 30px;
  height: 24px;
  position: relative;
  z-index: 1001;
}

.hamburger-menu span {
  display: block;
  width: 100%;
  height: 3px;
  background-color: #FFD700; /* Secondary color for hamburger lines */
  border-radius: 2px;
  position: absolute;
  left: 0;
  transition: all 0.3s ease;
}

.hamburger-menu span:nth-child(1) { top: 0; }
.hamburger-menu span:nth-child(2) { top: 50%; transform: translateY(-50%); }
.hamburger-menu span:nth-child(3) { bottom: 0; }

.hamburger-menu.active span:nth-child(1) {
  transform: translateY(10.5px) rotate(45deg);
}
.hamburger-menu.active span:nth-child(2) {
  opacity: 0;
}
.hamburger-menu.active span:nth-child(3) {
  transform: translateY(-10.5px) rotate(-45deg);
}

.mobile-buttons-area {
  display: none; /* Hidden on desktop */
  background-color: #003366; /* Primary color */
  padding: 10px 0;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.mobile-buttons-container {
  display: flex;
  justify-content: center;
  gap: 12px;
  padding: 0 15px;
}

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

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

/* Footer Styles */
.site-footer {
  background-color: #003366; /* Primary color */
  color: #ffffff;
  padding: 40px 20px 20px;
  text-align: center;
}

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

.footer-column {
  flex: 1;
  min-width: 180px;
  max-width: 250px;
}

.footer-column h3 {
  font-size: 18px;
  margin-bottom: 15px;
  color: #FFD700; /* Secondary color for footer headings */
}

.footer-column p {
  font-size: 14px;
  color: #cccccc;
}

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

.footer-nav li a {
  color: #ffffff;
  text-decoration: none;
  font-size: 14px;
  display: block;
  padding: 5px 0;
  transition: color 0.3s ease;
}

.footer-nav li a:hover {
  color: #FFD700; /* Secondary color on hover */
}

.footer-bottom {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid #004488; /* Darker primary for separator */
  font-size: 13px;
  color: #cccccc;
}

/* Mobile Styles */
@media (max-width: 768px) {
  .header-container {
    width: 100%;
    max-width: none;
    padding: 0 15px;
  }

  .desktop-nav-buttons {
    display: none;
  }

  .hamburger-menu {
    display: block;
    order: -1; /* Place hamburger menu on the left */
  }

  .logo {
    flex: 1 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    font-size: 24px;
    padding-left: 20px; /* Adjust for hamburger */
  }

  .main-nav {
    display: none; /* Hidden by default */
    flex-direction: column; /* Vertical layout */
    position: fixed;
    top: 0;
    left: 0;
    width: 250px;
    height: 100%;
    background-color: #003366; /* Primary color for mobile menu */
    padding-top: var(--header-offset); /* Push menu content below header */
    transform: translateX(-100%); /* Off-screen by default */
    transition: transform 0.3s ease;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.2);
    z-index: 1000;
  }

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

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

  .nav-link {
    width: 100%;
    padding: 12px 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: #ffffff; /* White for mobile nav links */
  }

  .nav-link:hover, .nav-link.active {
    background-color: #002244; /* Darker primary on hover/active */
    color: #FFD700;
    border-radius: 0;
  }

  .mobile-buttons-area {
    display: block;
    position: sticky; /* Make it sticky below the header */
    top: 70px; /* Adjust based on header-top height */
    z-index: 990; /* Below fixed header, above content */
  }
  .site-header {
    display: block;
    height: auto; /* Allow header to adjust height */
  }

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

  .footer-column {
    max-width: 100%;
    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;
  }
}
