/* Base Styles */
:root {
    --primary-color: #11A84E;
    --secondary-color: #22C768;
    --button-gradient: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
    --card-bg: #11271B;
    --background-color: #08160F;
    --text-main: #F2FFF6;
    --text-secondary: #A7D9B8;
    --border-color: #2E7A4E;
    --glow-color: #57E38D;
    --gold-color: #F2C14E;
    --divider-color: #1E3A2A;
    --deep-green: #0A4B2C;
    --header-offset: 122px; /* Desktop: 68px (header-top) + 52px (main-nav) + 2px buffer */
}

body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding-top: var(--header-offset);
    background-color: var(--background-color);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden; /* Prevent horizontal scroll for desktop */
}

a {
    text-decoration: none;
    color: var(--text-main);
}

a:hover {
    color: var(--secondary-color);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: bold;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    color: var(--text-main);
    background: var(--button-gradient);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.btn:hover {
    opacity: 0.9;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3), 0 0 15px var(--glow-color);
}

/* Header Styles */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    box-sizing: border-box;
}

.header-top {
    background-color: var(--deep-green); /* Distinct from main-nav */
    min-height: 68px;
    height: 68px;
    display: flex;
    align-items: center;
    overflow: hidden;
    width: 100%;
    box-sizing: border-box;
}

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

.logo {
    font-size: 28px;
    font-weight: bold;
    color: var(--gold-color);
    text-transform: uppercase;
    display: block; /* Ensure it's not inline-flex if using img inside */
}

.logo img {
    display: block;
    max-height: 60px;
    height: auto;
    width: auto;
    max-width: 280px;
    object-fit: contain;
}

.hamburger-menu {
    display: none; /* Hidden on desktop */
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 24px;
    position: relative;
    z-index: 1002;
}

.hamburger-menu .bar {
    display: block;
    width: 100%;
    height: 3px;
    background-color: var(--text-main);
    margin: 5px 0;
    transition: all 0.3s ease;
    border-radius: 2px;
}

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

.mobile-nav-buttons {
    box-sizing: border-box;
    display: none; /* Hidden on desktop, shown on mobile */
    min-height: 48px; /* Placeholder for mobile */
}

.main-nav {
    background-color: var(--card-bg); /* Distinct from header-top */
    min-height: 52px;
    height: 52px;
    display: flex; /* Displayed on desktop */
    align-items: center;
    overflow: hidden;
    width: 100%;
    box-sizing: border-box;
}

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

.nav-link {
    padding: 10px 15px;
    font-size: 15px;
    font-weight: bold;
    color: var(--text-main);
    transition: color 0.3s ease;
    white-space: nowrap;
}

.nav-link:hover {
    color: var(--secondary-color);
}

/* Overlay for mobile menu */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 999;
    display: none;
    transition: opacity 0.3s ease;
    opacity: 0;
}

.overlay.active {
    display: block;
    opacity: 1;
}

/* Footer Styles */
.site-footer {
    background-color: var(--card-bg);
    padding: 40px 20px 20px;
    color: var(--text-secondary);
    border-top: 1px solid var(--divider-color);
    box-sizing: border-box;
}

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

.footer-col {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.footer-logo {
    font-size: 24px;
    font-weight: bold;
    color: var(--gold-color);
    text-transform: uppercase;
}

.footer-description {
    font-size: 14px;
    color: var(--text-secondary);
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.footer-heading {
    font-size: 18px;
    color: var(--text-main);
    margin: 0 0 10px;
}

.footer-nav {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer-nav a {
    font-size: 14px;
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

.footer-nav a:hover {
    color: var(--secondary-color);
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
    font-size: 13px;
    color: var(--text-secondary);
    border-top: 1px solid var(--divider-color);
    padding-top: 20px;
}

.footer-slot-anchor-inner {
    /* These are placeholders for injected content */
    min-height: 1px; /* Ensure they take up some space */
}

/* Responsive Styles */
@media (max-width: 768px) {
    :root {
        --header-offset: 110px; /* Mobile: 60px (header-top) + 48px (mobile-nav-buttons) + 2px buffer */
    }

    body {
        padding-top: var(--header-offset);
        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 {
        min-height: 60px !important;
        height: 60px !important;
    }

    .header-container {
        padding: 0 15px;
        max-width: none; /* Ensure it takes full width */
        position: relative; /* For logo centering */
    }

    .hamburger-menu {
        display: block;
        order: -1; /* Place it at the beginning */
        margin-right: auto;
    }

    .hamburger-menu.active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .hamburger-menu.active .bar:nth-child(2) { opacity: 0; }
    .hamburger-menu.active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

    .logo {
        flex: 1 !important;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        margin: 0; /* Reset margin */
        position: absolute; /* Absolute positioning for centering */
        left: 50%;
        transform: translateX(-50%);
        max-width: calc(100% - 100px); /* Leave space for hamburger and potential right items */
    }

    .logo img {
        max-height: 56px !important; /* Adjusted for mobile header height */
    }

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

    .mobile-nav-buttons {
        display: flex !important;
        min-height: 48px;
        align-items: center;
        justify-content: center;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        padding: 0 15px;
        overflow: hidden;
        gap: 10px;
        flex-wrap: nowrap;
        background-color: var(--card-bg); /* Same as main-nav background */
        border-bottom: 1px solid var(--divider-color);
    }

    .mobile-nav-buttons .btn {
        flex: 1;
        min-width: 0;
        max-width: calc(50% - 5px); /* 50% minus half of the gap */
        box-sizing: border-box;
        padding: 8px 12px;
        font-size: 13px;
        white-space: normal;
        word-wrap: break-word;
        overflow-wrap: break-word;
        text-align: center;
    }

    .main-nav {
        display: none; /* Hidden by default on mobile */
        position: fixed;
        top: 0;
        left: 0;
        width: 80%;
        max-width: 300px; /* Limit sidebar width */
        height: 100vh; /* Full viewport height */
        background-color: var(--deep-green); /* Use a consistent color */
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-start;
        padding-top: 60px; /* Space for fixed header content */
        transform: translateX(-100%); /* Off-screen by default */
        transition: transform 0.3s ease;
        z-index: 1001;
        box-shadow: 2px 0 10px rgba(0, 0, 0, 0.3);
    }

    .main-nav.active {
        display: flex; /* Must set display to show */
        transform: translateX(0); /* Slide into view */
    }

    .nav-container {
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-start;
        padding: 20px 15px;
        height: auto; /* Allow content to dictate height */
        max-width: none; /* Ensure it takes full width */
    }

    .nav-link {
        width: 100%;
        padding: 12px 0;
        border-bottom: 1px solid var(--divider-color);
        font-size: 16px;
    }

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

    .site-footer {
        padding: 30px 15px 15px;
    }

    .footer-top-grid {
        grid-template-columns: 1fr;
        gap: 30px;
        margin-bottom: 20px;
    }

    .footer-bottom {
        padding-top: 15px;
    }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@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;
  }
}
/* 内容保护（系统追加，请勿删除） */
body {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}
input, textarea, select, [contenteditable="true"] {
  -webkit-user-select: text;
  -moz-user-select: text;
  user-select: text;
}
