/* Header/Navigation */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: all 0.3s ease;
    padding: 1.5rem 0;
    background: transparent;
}

.site-header.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px) saturate(180%);
    padding: 1rem 0;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
    border-bottom: 1px solid rgba(37, 99, 235, 0.08);
}

.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Logo */
.brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--text-main);
}

.brand-logo {
    width: 44px;
    height: 44px;
    background: var(--primary-gradient);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.3rem;
    box-shadow: 0 4px 16px rgba(37, 99, 235, 0.35);
    transition: all 0.3s ease;
}

.brand:hover .brand-logo {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.brand-text {
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text-main);
}

/* Navigation */
.main-nav {
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-link {
    /* 修复变量名：--text-secondary 改为 --text-light */
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.2s ease;
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-link i {
    font-size: 0.9rem;
    opacity: 0.7;
}

.nav-link:hover {
    /* 修复变量名：--primary-color 改为 --primary */
    color: var(--primary);
}

/* Nav Link Underline Effect */
.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
}

.nav-link:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-main);
    font-size: 1.5rem;
    cursor: pointer;
}

/* Mobile Styles */
@media (max-width: 900px) {
    .menu-toggle {
        display: block;
    }

    .main-nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 320px;
        height: 100vh;
        background: white;
        flex-direction: column;
        padding: 6rem 2rem 2rem;
        box-shadow: -10px 0 30px rgba(0,0,0,0.1);
        transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 999;
        align-items: stretch;
    }

    .main-nav.active {
        right: 0;
    }

    .nav-links {
        flex-direction: column;
        width: 100%;
        align-items: flex-start;
        gap: 1.5rem;
        margin-bottom: 2rem;
    }
    
    .nav-link {
        font-size: 1.1rem;
        display: flex;
        padding: 0.5rem 0;
        width: 100%;
    }

    .nav-actions {
        flex-direction: column;
        width: 100%;
        gap: 1rem;
    }

    .nav-actions .button {
        width: 100%;
    }
}