:root {
  --header-offset: 120px;
}
@media (max-width: 768px) {
  :root {
    --header-offset: 200px;
  }
}

/* Base styles */
body {
  margin: 0;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: #fff; /* Default text color for dark backgrounds */
  background-color: #000;
  padding-top: var(--header-offset); /* Ensure content is not hidden by fixed header */
  overflow-x: hidden;
}

/* Header styles */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
  min-height: 60px;
  display: flex;
  flex-direction: column; /* Default for desktop, allowing mobile to override */
}

.header-top {
  background-color: #111111; /* Very dark grey for top bar */
  padding: 15px 0;
}

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

.logo {
  font-size: 28px;
  font-weight: bold;
  color: #FFD700; /* Gold text for logo */
  text-decoration: none;
  white-space: nowrap;
}

.desktop-nav-buttons {
  display: flex;
  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;
  border: none;
  text-align: center;
  line-height: 1;
}

.btn-register, .btn-login {
  background-color: #FFD700; /* Gold background */
  color: #1A202C; /* Dark blue text */
}

.btn-register:hover, .btn-login:hover {
  background-color: #e0b800; /* Slightly darker gold on hover */
}

.main-nav {
  background-color: #1A202C; /* Primary dark blue for main nav */
  padding: 10px 0;
  flex-grow: 1;
  display: flex; /* Desktop default: visible */
}

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

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

.nav-link:hover {
  background-color: rgba(255, 215, 0, 0.1); /* Subtle gold highlight */
  color: #fff;
}

/* Mobile specific elements (hidden by default on desktop) */
.mobile-hamburger,
.mobile-buttons,
.mobile-menu-overlay {
  display: none;
}

/* Footer styles */
.site-footer {
  background-color: #1A202C; /* Primary dark blue for footer */
  color: #fff;
  padding: 40px 0 20px;
  font-size: 14px;
}

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

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

.footer-col h3 {
  color: #FFD700; /* Gold for footer headings */
  margin-top: 0;
  font-size: 18px;
  margin-bottom: 15px;
}

.footer-col p {
  color: #ccc;
  line-height: 1.8;
}

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

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

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

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

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

/* Mobile styles */
@media (max-width: 768px) {
  /* Mobile overflow protection */
  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }
  body {
    overflow-x: hidden;
  }

  .site-header {
    flex-direction: column;
  }

  .header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    position: relative; /* For absolute logo positioning */
  }

  .header-container {
    width: 100%;
    max-width: none;
    padding: 0;
    justify-content: space-between;
  }

  .logo {
    display: flex;
    justify-content: center;
    align-items: center;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: auto;
    max-width: calc(100% - 100px); /* Leave space for hamburger */
    font-size: 24px;
  }

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

  .mobile-hamburger {
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 25px;
    cursor: pointer;
    z-index: 1001; /* Above logo and mobile buttons */
    position: relative;
  }

  .mobile-hamburger span {
    display: block;
    height: 3px;
    width: 100%;
    background-color: #FFD700;
    border-radius: 3px;
    transition: all 0.3s ease-in-out;
  }

  .mobile-hamburger.active span:nth-child(1) {
    transform: translateY(11px) rotate(45deg);
  }

  .mobile-hamburger.active span:nth-child(2) {
    opacity: 0;
  }

  .mobile-hamburger.active span:nth-child(3) {
    transform: translateY(-11px) rotate(-45deg);
  }

  .main-nav {
    display: none; /* Hidden by default */
    position: fixed;
    top: var(--header-offset);
    left: 0;
    width: 80%;
    max-width: 300px;
    height: calc(100vh - var(--header-offset));
    background-color: #1A202C; /* Same as desktop main nav */
    flex-direction: column;
    padding: 20px 0;
    transform: translateX(-100%); /* Slide out of view */
    transition: transform 0.3s ease-in-out;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.5);
    overflow-y: auto;
    z-index: 999; /* Below hamburger, above overlay */
  }

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

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

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

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

  .mobile-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    background-color: #111111; /* Same as header-top */
    padding: 10px 15px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
    z-index: 998; /* Below main nav, above content */
  }

  .mobile-buttons .btn {
    flex: 1;
    max-width: 150px;
    font-size: 14px;
    padding: 10px 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: 990;
    transition: opacity 0.3s ease-in-out;
    opacity: 0;
  }

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

  .site-footer .footer-container {
    flex-direction: column;
    gap: 20px;
    padding: 0 15px;
  }

  .footer-col {
    min-width: unset;
    width: 100%;
  }

  .footer-bottom .footer-container {
    padding: 0 15px;
  }

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