:root {
  --header-offset: 110px; /* Desktop: header-top (60px) + main-nav (50px) */
}
@media (max-width: 768px) {
  :root {
    --header-offset: 100px; /* Mobile: header-top (55px) + mobile-nav-buttons-wrapper (45px) */
  }
}

body {
  padding-top: var(--header-offset);
  overflow-x: hidden;
  font-family: Arial, sans-serif;
  margin: 0;
  background-color: #FFFFFF;
  color: #333333;
}

/* Header Styles */
.site-header {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
}

.header-top {
  background-color: #000000; /* Primary dark */
  color: #FFFFFF;
  padding: 10px 0;
  min-height: 60px; /* Ensure minimum height for desktop */
  display: flex;
  align-items: center;
}

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

.logo {
  font-size: 28px;
  font-weight: bold;
  color: #FFFFFF;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
}

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

.btn {
  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;
  cursor: pointer;
}

.btn.login-btn {
  background-color: #FCBC45; /* Login color */
  color: #000000;
  border: 1px solid #FCBC45;
}
.btn.login-btn:hover {
  background-color: #e0a73b;
  border-color: #e0a73b;
}

.btn.register-btn {
  background-color: #FFFFFF; /* Register color */
  color: #000000;
  border: 1px solid #FFFFFF;
}
.btn.register-btn:hover {
  background-color: #f0f0f0;
  border-color: #f0f0f0;
}

.main-nav {
  background-color: #333333; /* Darker grey, contrasts with header-top */
  color: #FFFFFF;
  padding: 10px 0;
  display: flex;
  flex-direction: row;
  justify-content: center;
  min-height: 50px; /* Ensure minimum height for desktop */
  align-items: center;
}

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

.nav-link {
  color: #FFFFFF;
  text-decoration: none;
  padding: 8px 15px;
  transition: color 0.3s ease, background-color 0.3s ease;
  white-space: nowrap;
  font-size: 15px;
}
.nav-link:hover {
  background-color: #555555;
  border-radius: 3px;
}

.hamburger-menu {
  display: none; /* Hidden on desktop */
  cursor: pointer;
  width: 30px;
  height: 24px;
  position: relative;
  z-index: 1001;
}
.hamburger-menu span {
  display: block;
  height: 3px;
  width: 100%;
  background: #FFFFFF;
  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) { top: 50%; transform: translateY(-50%) rotate(45deg); }
.hamburger-menu.active span:nth-child(2) { opacity: 0; }
.hamburger-menu.active span:nth-child(3) { bottom: 50%; transform: translateY(50%) rotate(-45deg); }

.mobile-nav-buttons-wrapper {
  display: none; /* Hidden on desktop */
  background-color: #1a1a1a; /* Darker grey for mobile buttons */
  padding: 8px 0;
  width: 100%;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  z-index: 999; /* Below main-nav when open, but above content */
  min-height: 45px; /* Ensure minimum height for mobile buttons */
  display: flex;
  align-items: center;
}

.mobile-nav-buttons-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
  gap: 12px;
  padding: 0 15px;
  width: 100%;
}

.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: 998;
  transition: opacity 0.3s ease;
  opacity: 0;
}
.mobile-menu-overlay.active {
  display: block;
  opacity: 1;
}

/* Footer Styles */
.site-footer {
  background-color: #000000; /* Primary dark */
  color: #FFFFFF;
  padding: 40px 0 20px;
  font-size: 14px;
}

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

.footer-section {
  flex: 1;
  min-width: 180px;
  margin-bottom: 20px;
  padding: 0 10px;
}

.footer-section h3 {
  font-size: 16px;
  margin-bottom: 15px;
  color: #FCBC45; /* Highlight footer titles */
}

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

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

.footer-section ul li a {
  color: #FFFFFF;
  text-decoration: none;
  transition: color 0.3s ease;
}
.footer-section ul li a:hover {
  color: #FCBC45;
}

.footer-section.copyright {
  flex-basis: 100%;
  text-align: center;
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

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

  .header-top {
    padding: 8px 0;
    min-height: 55px; /* Adjust height for mobile */
  }

  .header-container {
    padding: 0 15px;
    position: relative;
  }

  .hamburger-menu {
    display: block;
    order: 1;
  }

  .logo {
    order: 2;
    flex: 1;
    text-align: center;
    font-size: 24px;
  }

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

  .mobile-nav-buttons-wrapper {
    display: flex; /* Show on mobile */
    order: 3;
    min-height: 45px; /* Adjust height for mobile */
  }

  .main-nav {
    display: none;
    position: fixed;
    top: var(--header-offset); /* Position below fixed header parts */
    left: 0;
    width: 280px;
    height: calc(100% - var(--header-offset));
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    padding: 20px 0;
    background-color: #222222;
    transform: translateX(-100%);
    transition: transform 0.3s ease-out;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.3);
    z-index: 999;
    overflow-y: auto;
  }

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

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

  .nav-link {
    width: 100%;
    padding: 12px 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }
  .nav-link:last-child {
    border-bottom: none;
  }

  .footer-container {
    flex-direction: column;
    align-items: center;
    padding: 0 15px;
  }

  .footer-section {
    flex-basis: 100%;
    min-width: unset;
    text-align: center;
    padding: 0;
  }

  .footer-section h3 {
    margin-top: 20px;
  }
}
/* 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;
  }
}
