:root {
    --primary-color: #2F6BFF;
    --secondary-color: #6FA3FF;
    --button-gradient: linear-gradient(180deg, #4A8BFF 0%, #2F6BFF 100%);
    --card-bg: #FFFFFF;
    --background-color: #F4F7FB;
    --text-main: #1F2D3D;
    --text-black: #000000;
    --border-color: #D6E2FF;
    --glow-color: #A5C4FF;
    --header-offset: 122px; /* 68px (header-top) + 52px (main-nav) + 2px buffer */
}

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

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    background-color: var(--card-bg); /* Use card-bg for header background */
}

.header-top {
    box-sizing: border-box;
    min-height: 68px;
    height: 68px;
    display: flex;
    align-items: center;
    overflow: hidden;
    background-color: var(--primary-color); /* Distinct background for header-top */
    width: 100%;
    padding: 0 20px;
}

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

.logo {
    font-size: 28px;
    font-weight: bold;
    color: var(--card-bg);
    text-decoration: none;
    display: flex;
    align-items: center;
    height: 100%;
}

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

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

.mobile-nav-buttons {
    box-sizing: border-box;
    display: none; /* Hidden by default on desktop */
    min-height: 48px;
    background-color: var(--background-color); /* Different background for mobile buttons */
    padding: 0 15px;
}

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

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

.nav-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 25px;
}

.nav-menu li a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 500;
    padding: 10px 0;
    display: block;
    white-space: nowrap;
    transition: color 0.3s ease;
}

.nav-menu li a:hover,
.nav-menu li a.active {
    color: var(--primary-color);
}

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

.hamburger-menu .bar {
    display: block;
    width: 100%;
    height: 3px;
    background-color: var(--card-bg);
    margin-bottom: 5px;
    transition: all 0.3s ease;
}

.hamburger-menu .bar:last-child {
    margin-bottom: 0;
}

.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);
}

.overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: bold;
    text-align: center;
    transition: all 0.3s ease;
    white-space: nowrap;
    cursor: pointer;
    border: none;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.btn-primary {
    background: var(--button-gradient);
    color: var(--card-bg);
}

.btn-primary:hover {
    opacity: 0.9;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--card-bg);
}

.btn-secondary:hover {
    opacity: 0.9;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
}

/* Footer Styles */
.site-footer {
    background-color: var(--text-main);
    color: var(--card-bg);
    padding: 40px 20px 20px;
    font-size: 14px;
    line-height: 1.6;
}

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

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

.footer-logo {
    font-size: 24px;
    font-weight: bold;
    color: var(--card-bg);
    text-decoration: none;
    margin-bottom: 15px;
}

.footer-description {
    margin-top: 0;
    margin-bottom: 15px;
    color: rgba(255, 255, 255, 0.7);
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.footer-heading {
    font-size: 18px;
    color: var(--card-bg);
    margin-top: 0;
    margin-bottom: 15px;
}

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

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

.footer-nav li a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.3s ease;
}

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

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    max-width: 1200px;
    margin: 0 auto;
    color: rgba(255, 255, 255, 0.6);
}

.footer-bottom p {
    margin: 0;
}

.footer-slot-anchor-inner {
    /* This is an empty container for dynamic content injection */
    margin-top: 10px; /* Provide some spacing if content is injected */
}

/* Mobile Styles */
@media (max-width: 768px) {
    :root {
        --header-offset: 110px; /* 60px (header-top) + 48px (main-nav) + 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%;
    }
    body {
        overflow-x: hidden;
    }

    .header-top {
        min-height: 60px !important;
        height: 60px !important;
        padding: 0 15px;
        justify-content: space-between;
    }

    .header-container {
        width: 100%;
        max-width: none;
        padding: 0;
        position: relative;
    }

    .logo {
        flex: 1 !important;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        height: 100%;
        max-width: calc(100% - 100px); /* Adjust based on hamburger size */
    }

    .logo img {
        max-height: 56px !important;
    }

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

    .mobile-nav-buttons {
        display: flex !important;
        min-height: 48px;
        height: auto;
        align-items: center;
        justify-content: center;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        padding: 10px 15px;
        overflow: hidden;
        gap: 10px;
        flex-wrap: nowrap;
        background-color: var(--primary-color);
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    }

    .mobile-nav-buttons .btn {
        flex: 1;
        min-width: 0;
        max-width: calc(50% - 5px);
        box-sizing: border-box;
        padding: 8px 12px;
        font-size: 13px;
        white-space: normal;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }

    .main-nav {
        min-height: 48px !important;
        height: 100vh; /* Full viewport height for mobile menu */
        width: 250px; /* Fixed width for slide-in menu */
        position: fixed; /* Fixed position for mobile menu */
        top: calc(var(--header-offset) - 2px); /* Position below header */
        left: 0;
        transform: translateX(-100%); /* Hidden by default */
        transition: transform 0.3s ease-in-out;
        background-color: var(--card-bg);
        box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
        display: none; /* Crucial for hiding by default */
        padding-top: 20px;
        overflow-y: auto;
    }

    .main-nav.active {
        transform: translateX(0); /* Slide in */
        display: flex; /* Crucial for showing when active */
        flex-direction: column;
    }

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

    .nav-menu {
        flex-direction: column;
        width: 100%;
        gap: 0;
    }

    .nav-menu li {
        width: 100%;
        border-bottom: 1px solid var(--border-color);
    }

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

    .nav-menu li a {
        padding: 15px 10px;
        color: var(--text-main);
        white-space: normal;
    }

    .hamburger-menu {
        display: block;
        position: relative;
        left: 0;
        height: 100%;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        z-index: 1001;
    }

    .hamburger-menu .bar {
        background-color: var(--card-bg);
    }

    .overlay.active {
        display: block;
    }

    .site-header .header-container {
        justify-content: flex-start; /* Adjust for hamburger menu */
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .footer-col {
        align-items: flex-start;
    }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@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;
}
