/* General Reset & Body */
body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  line-height: 1.6;
  color: #333;
  background-color: #FFFFFF;
}
a {
  text-decoration: none;
  color: inherit;
}
ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

/* Header Offset */
:root {
  --header-offset: 100px; /* Desktop: header-top (~60px) + main-nav (~40px) */
}
@media (max-width: 768px) {
  :root {
    --header-offset: 100px; /* Mobile: header-top (~50px) + mobile-nav-buttons (~50px) */
  }
}

/* Site Header (Fixed, Suspended) */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: #00502a; /* Darker green for header-top */
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  min-height: var(--header-offset);
}

/* Header Top Area */
.header-top {
  width: 100%;
  background-color: #00502a; /* Darker green */
  padding: 15px 0; /* Desktop padding */
}
.header-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 20px; /* Desktop container padding */
}

/* Logo */
.logo {
  font-size: 28px;
  font-weight: bold;
  color: #FFFFFF;
  text-transform: uppercase;
  display: block;
  line-height: 30px;
}

/* Desktop Navigation Buttons */
.desktop-nav-buttons {
  display: flex;
  gap: 10px;
}
.btn {
  padding: 10px 18px;
  border-radius: 5px;
  font-weight: bold;
  text-transform: uppercase;
  transition: background-color 0.3s ease, color 0.3s ease;
  text-decoration: none; /* Remove underline for buttons */
  white-space: nowrap; /* Prevent wrapping on desktop */
  box-sizing: border-box;
}
.btn-register, .btn-login {
  background-color: #C30808; /* Red */
  color: #FFFFFF; /* White for contrast, overriding #FFFF00 */
}
.btn-register:hover, .btn-login:hover {
  background-color: #e00b0b; /* Slightly darker red on hover */
}

/* Main Navigation Area */
.main-nav {
  width: 100%;
  background-color: #017439; /* Primary green */
  padding: 10px 0; /* Desktop padding */
  display: flex; /* Desktop default display */
}
.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: row; /* Desktop horizontal */
  justify-content: center; /* Center nav items */
  align-items: center;
  padding: 0 20px; /* Desktop container padding */
}
.nav-link {
  color: #FFFFFF;
  padding: 8px 15px;
  font-size: 16px;
  font-weight: bold;
  transition: background-color 0.3s ease;
  white-space: nowrap;
}
.nav-link:hover {
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

/* Hamburger Menu (Mobile) */
.hamburger-menu {
  display: none; /* Hidden on desktop */
  flex-direction: column;
  justify-content: space-around;
  width: 30px;
  height: 25px;
  cursor: pointer;
  z-index: 1001;
  padding: 5px;
}
.hamburger-menu span {
  display: block;
  width: 100%;
  height: 3px;
  background-color: #FFFFFF;
  border-radius: 3px;
  transition: all 0.3s ease;
}
.hamburger-menu.active span:nth-child(1) {
  transform: translateY(11px) rotate(45deg);
}
.hamburger-menu.active span:nth-child(2) {
  opacity: 0;
}
.hamburger-menu.active span:nth-child(3) {
  transform: translateY(-11px) rotate(-45deg);
}

/* Mobile Navigation Buttons (hidden on desktop) */
.mobile-nav-buttons {
  display: none; /* Hidden on desktop */
  width: 100%;
  background-color: #00502a; /* Same as header-top */
  padding: 10px 15px; /* Mobile padding */
  box-sizing: border-box;
  overflow: hidden; /* Prevent overflow */
}

/* Mobile Menu Overlay */
.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.5);
  z-index: 999;
  cursor: pointer;
}
.mobile-menu-overlay.active {
  display: block;
}

/* Footer */
.site-footer {
  background-color: #00331a; /* Very dark green */
  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;
  gap: 30px;
}
.footer-col {
  flex: 1;
  min-width: 250px;
  margin-bottom: 20px;
}
.footer-col h3 {
  color: #FFFFFF;
  font-size: 18px;
  margin-bottom: 15px;
}
.footer-logo {
  font-size: 24px;
  font-weight: bold;
  color: #FFFFFF;
  text-transform: uppercase;
  display: block;
  margin-bottom: 15px;
}
.footer-about p {
  color: #ccc;
  line-height: 1.8;
}
.footer-nav ul li, .footer-legal ul li {
  margin-bottom: 8px;
}
.footer-nav ul li a, .footer-legal ul li a {
  color: #ccc;
  transition: color 0.3s ease;
}
.footer-nav ul li a:hover, .footer-legal ul li a:hover {
  color: #FFFFFF;
}
.footer-bottom {
  text-align: center;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.footer-bottom p {
  color: #ccc;
  margin: 0;
}

/* Responsive Styles (Mobile) */
@media (max-width: 768px) {
  /* Header adjustments */
  .site-header {
    min-height: auto;
  }
  .header-top {
    padding: 10px 0;
  }
  .header-container {
    padding: 0 15px;
    justify-content: space-between;
    position: relative;
    min-height: 50px;
  }
  .hamburger-menu {
    display: flex;
  }
  .logo {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 24px;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    max-width: calc(100% - 100px); /* Leave space for hamburger/potential right element */
  }
  .desktop-nav-buttons {
    display: none;
  }

  /* Mobile Navigation Buttons */
  .mobile-nav-buttons {
    display: flex !important;
    gap: 10px;
    flex-wrap: nowrap;
    justify-content: center;
  }
  .mobile-nav-buttons .btn {
    flex: 1;
    min-width: 0;
    max-width: calc(50% - 5px); /* Max width for two buttons with gap */
    padding: 8px 12px; /* Smaller padding */
    font-size: 13px; /* Smaller font size */
    white-space: normal; /* Allow text wrap */
    word-wrap: break-word;
    overflow-wrap: break-word;
  }

  /* Main Navigation (Mobile) */
  .main-nav {
    display: none; /* Hidden by default on mobile */
    position: fixed;
    top: var(--header-offset); /* Start below fixed header content */
    left: 0;
    width: 280px; /* Width of the mobile menu */
    height: calc(100% - var(--header-offset)); /* Full height below header */
    background-color: #017439; /* Primary green */
    flex-direction: column;
    padding: 20px 0;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.3);
    transform: translateX(-100%); /* Off-screen by default */
    transition: transform 0.3s ease;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  .main-nav.active {
    display: flex; /* Show when active */
    transform: translateX(0); /* Slide in */
  }
  .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.1);
    font-size: 15px;
    text-align: left;
  }
  .nav-link:last-child {
    border-bottom: none;
  }

  /* Footer adjustments */
  .footer-container {
    flex-direction: column;
    gap: 20px;
    padding: 0 15px;
  }
  .footer-col {
    min-width: unset;
    width: 100%;
  }

  /* Mobile content overflow prevention */
  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }
  body {
    overflow-x: hidden;
  }
  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;
  }
}
