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

body {
  margin: 0;
  font-family: Arial, sans-serif;
  color: #333;
  line-height: 1.6;
  overflow-x: hidden;
}

.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: transparent; /* Handled by header-top and main-nav */
}

.header-top {
  background-color: #000080; /* Dark Blue */
  padding: 15px 0;
  position: relative;
  z-index: 1001;
}

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

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

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

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

.btn-register {
  background-color: #FFD700; /* Gold */
  color: #000080; /* Dark Blue */
}

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

.btn-login {
  background-color: #000080; /* Dark Blue */
  color: #FFD700; /* Gold */
  border: 1px solid #FFD700;
}

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

.btn-download {
  background-color: #FFD700; /* Gold */
  color: #000080; /* Dark Blue */
}

.btn-download:hover {
  background-color: #e6c200;
}

.main-nav {
  background-color: #222222; /* Dark Grey, distinct from Dark Blue */
  padding: 10px 0;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  position: static;
  width: 100%;
  z-index: 1000;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  padding: 0 20px;
}

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

.nav-link:hover,
.nav-link.active {
  color: #ffffff;
  background-color: #000080; /* Dark Blue */
  border-radius: 3px;
}

.hamburger-menu {
  display: none;
  width: 30px;
  height: 20px;
  position: relative;
  cursor: pointer;
  z-index: 1002;
  order: -1;
}

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

.hamburger-menu span:nth-child(1) {
  top: 0;
}

.hamburger-menu span:nth-child(2) {
  top: 8.5px;
}

.hamburger-menu span:nth-child(3) {
  top: 17px;
}

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

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

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

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

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

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

.site-footer {
  background-color: #000080; /* Dark Blue */
  color: #ffffff;
  padding: 40px 0;
  font-size: 14px;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  padding: 0 30px;
}

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

.footer-section h3 {
  color: #FFD700; /* Gold */
  font-size: 18px;
  margin-bottom: 20px;
}

.footer-section p {
  margin-bottom: 10px;
}

.footer-section p a {
  color: #FFD700; /* Gold */
  text-decoration: none;
}

.footer-section p a:hover {
  text-decoration: underline;
}

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

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

.footer-nav a {
  color: #ffffff;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-nav a:hover {
  color: #FFD700; /* Gold */
}

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

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

  .site-header {
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  }

  .header-top {
    padding: 10px 15px;
  }

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

  .logo {
    flex: 1 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    font-size: 24px;
  }

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

  .hamburger-menu {
    display: block;
    margin-right: auto; /* Push logo to center */
    padding: 5px;
  }

  .mobile-nav-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 10px 15px;
    background-color: #000080; /* Dark Blue */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    z-index: 1000;
  }

  .mobile-nav-buttons .btn {
    flex: 1;
    text-align: center;
    padding: 8px 10px;
    font-size: 14px;
  }

  .main-nav {
    display: none;
    position: fixed;
    top: var(--header-offset); /* Adjusted for mobile header height */
    left: 0;
    width: 80%;
    max-width: 300px;
    height: calc(100% - var(--header-offset));
    background-color: #000066; /* Slightly darker blue for mobile menu */
    flex-direction: column;
    padding: 20px 0;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.3);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    z-index: 1000;
    overflow-y: auto;
  }

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

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

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

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

  .footer-container {
    grid-template-columns: 1fr;
    padding: 0 20px;
  }

  .footer-section {
    text-align: center;
  }

  .footer-section h3 {
    margin-top: 30px;
  }

  .footer-nav {
    padding: 0;
  }

  .footer-nav li {
    display: inline-block;
    margin: 0 10px 10px 0;
  }

  .footer-nav li:last-child {
    margin-right: 0;
  }
}

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