:root {
    --header-offset: 150px; /* Desktop: header-top (approx 90px) + main-nav (approx 60px) */
}
@media (max-width: 768px) {
    :root {
        --header-offset: 150px; /* Mobile: header-top (approx 90px) + mobile-buttons-area (approx 60px) */
    }
    .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 {
    margin: 0;
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #FFFFFF; /* Default text color for the dark theme */
    background-color: #FFFFFF; /* Page background */
    padding-top: var(--header-offset);
}

/* 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.2);
    background-color: transparent; /* Base for fixed header, sections will have colors */
}

/* Header Top Section (Desktop) */
.header-top {
    background-color: #000000; /* Primary color, dark */
    padding: 15px 0;
    min-height: 60px;
    display: flex;
    align-items: center;
}

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

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

/* Desktop Navigation Buttons */
.desktop-nav-buttons {
    display: flex;
    gap: 12px;
}

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

.btn.login-btn {
    background-color: #FCBC45; /* Login color */
    color: #000000; /* Black text for contrast */
    border: 1px solid #FCBC45;
}

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

.btn.register-btn {
    background-color: #FFFFFF; /* Secondary color */
    color: #000000; /* Black text for contrast */
    border: 1px solid #FFFFFF;
}

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

/* Main Navigation (Desktop) */
.main-nav {
    background-color: #1a1a1a; /* Darker grey, contrasting with black */
    padding: 10px 0;
    min-height: 40px;
    display: flex; /* Desktop default: flex */
    align-items: center;
}

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

.nav-link {
    color: #FFFFFF;
    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,
.nav-link.active {
    color: #FCBC45;
    background-color: rgba(255,255,255,0.05);
    border-radius: 3px;
}

/* Hamburger Menu (Hidden on Desktop) */
.hamburger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 25px;
    cursor: pointer;
    z-index: 1001;
}

.hamburger-menu span {
    display: block;
    width: 100%;
    height: 3px;
    background-color: #FFFFFF;
    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 Specific Styles */
@media (max-width: 768px) {
    .header-container,
    .nav-container,
    .mobile-buttons-container {
        width: 100%;
        max-width: none;
        padding: 0 15px; /* Smaller padding for mobile */
    }

    .header-top {
        justify-content: space-between;
        padding: 15px 0;
    }
    
    .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: flex;
        order: -1; /* Place hamburger on the left */
        margin-right: auto; /* Push logo to center */
    }

    /* Mobile Buttons Area */
    .mobile-buttons-area {
        background-color: #000000; /* Same as header-top */
        padding: 10px 0;
        min-height: 40px;
        display: flex; /* Always visible */
        justify-content: center;
        box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    }

    .mobile-buttons-container {
        display: flex;
        gap: 10px;
        justify-content: center;
        align-items: center;
    }

    /* Main Navigation (Mobile) */
    .main-nav {
        display: none; /* Hidden by default */
        flex-direction: column; /* Vertical layout */
        position: fixed;
        top: var(--header-offset); /* Below header-top and mobile-buttons-area */
        left: 0;
        width: 80%; /* Takes 80% of screen width */
        height: calc(100% - var(--header-offset)); /* Fill remaining height */
        background-color: #1a1a1a; /* Same as desktop nav */
        box-shadow: 2px 0 5px rgba(0,0,0,0.2);
        transform: translateX(-100%); /* Slide out to the left */
        transition: transform 0.3s ease-in-out;
        overflow-y: auto;
    }

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

    .nav-container {
        flex-direction: column;
        align-items: flex-start;
        padding: 20px;
    }

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

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

    /* Mobile Menu Overlay */
    .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;
    }

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

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

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

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

.footer-col:last-child {
    margin-bottom: 0;
}

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

.site-footer h3 {
    color: #FFFFFF;
    font-size: 18px;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.site-footer h3::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 2px;
    background-color: #FCBC45;
}

.site-footer p {
    margin-bottom: 15px;
    color: #CCCCCC;
}

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

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

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

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

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

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