a {
    text-decoration: none;
}

@media (max-width: 768px) {
    .container {
        padding: 0 20px;
    }
}

.header-container {
    width: 100%;
    /* max-width: 1600px; */
    margin: 0 auto;
    padding: 10px 40px;
}

/* 导航栏 */
header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    transition: 0.3s ease;
    background: transparent;
    border-bottom: 1px solid var(--gray-100);
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 90px;
}

@media (max-width: 768px) {
    .logo img {
        height: 50px !important;
    }

    .nav {
        height: 50px !important;
    }

    .mobile-menu {
        width: 260px;
        padding: 80px 24px;
    }

    .mobile-menu a {
        padding: 12px 0;
        font-size: 0.95rem;
    }
}

/* 修复：移动端Logo自适应 */
.logo img {
    height: 90px;
    width: auto;
    transition: 0.2s;
}

.logo-scrolled {
    display: none;
}

header.scrolled {
    background: rgba(255, 255, 255, 0.96) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

header.scrolled .logo-default {
    display: none;
}

header.scrolled .logo-scrolled {
    display: block;
}

.nav-menu {
    display: flex;
    gap: 40px;
    font-weight: 500;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-menu li {
    list-style: none;
}

.nav-menu a {
    color: #fff;
    position: relative;
    padding: 6px 0;
    text-decoration: none;
    font-size: 1rem;
}

header.scrolled .nav-menu a {
    color: #1e293b;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2.5px;
    background: #fff;
    transition: width 0.25s;
}

header.scrolled .nav-menu a::after {
    background: var(--blue);
}

.nav-menu a:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    z-index: 1002;
    position: relative;
}

.menu-toggle span {
    width: 28px;
    height: 2.5px;
    background: #fff;
    border-radius: 4px;
    transition: 0.2s;
}

/* 关闭按钮 */
.mobile-menu-close {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
    color: #666;
    background: none;
    border: none;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.mobile-menu-close:hover {
    background: #f0f0f0;
}

header.scrolled .menu-toggle span {
    background: var(--blue);
}

@media (max-width: 992px) {
    .nav-menu {
        display: none;
    }

    .menu-toggle {
        display: flex;
    }
}

.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: #fff;
    box-shadow: -8px 0 32px rgba(0, 0, 0, 0.08);
    z-index: 1001;
    transition: 0.3s;
    padding: 100px 32px;
}

.mobile-menu.active {
    right: 0;
}

.mobile-menu ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mobile-menu li {
    list-style: none;
}

.mobile-menu a {
    display: block;
    padding: 14px 0;
    font-weight: 500;
    border-bottom: 1px solid #eef2f6;
    text-decoration: none;
    color: #222;
}

.menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: 0.2s;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ========= 全屏宽下拉菜单 - 紧凑高级版 ========= */
.mega-dropdown {
    position: fixed;
    top: 80px;
    left: 0;
    width: 100%;
    background: #f6f8fc;
    box-shadow: 0 20px 35px -12px rgba(0, 0, 0, 0.08);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    z-index: 999;
    pointer-events: none;
    border-top: 1px solid #eef2f5;
}

.mega-container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 36px 40px;
    display: flex;
    gap: 180px; /* 增加左右间距，图片更远 */
    align-items: stretch;
}

/* 左侧区域 - 白色卡片，内容水平排列 */
.mega-left {
    flex: 1.2;
    background: #ffffff;
    border-radius: 20px;
    padding: 24px 28px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
    border: 1px solid rgba(0, 0, 0, 0.04);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px 24px;
}

.mega-left h4 {
    font-size: 1.2rem;
    font-weight: 600;
    color: #1a2c3e;
    margin: 0;
    letter-spacing: -0.3px;
    white-space: nowrap;
}

.mega-left p {
    font-size: 0.85rem;
    color: #5a6e7c;
    line-height: 1.4;
    margin: 0;
    flex: 1;
    min-width: 200px;
}

.badge-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
}

.badge {
    background: #f0f4fa;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 500;
    color: #0052cc;
    white-space: nowrap;
}

/* 右侧区域 - 链接网格 + 图片 */
.mega-right {
    flex: 2;
    display: flex;
    gap: 160px; /* 链接和图片间距拉大 */
    align-items: flex-start;
}

/* 链接采用一行一个的布局，两列 */
.mega-links {
    flex: 1.5;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 6px 70px;
}

.mega-links a {
    color: #2c3e50 !important;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 450;
    padding: 8px 0;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    border-bottom: 1px solid transparent;
    white-space: nowrap;
}

.mega-links a:hover {
    color: #0052cc !important;
    transform: translateX(4px);
    border-bottom-color: #0052cc;
}

.mega-links a span {
    font-size: 0.9rem;
    margin-right: 8px;
    opacity: 0.6;
}

/* 右侧配图区域 - 宽度固定，距离链接更远 */
.mega-image {
    flex: 0.7;
    min-width: 180px;
    border-radius: 16px;
    overflow: hidden;
    background: #eef2f7;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
}

.mega-image img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.mega-image:hover img {
    transform: scale(1.02);
}

/* 响应式 */
@media (max-width: 1100px) {
    .mega-container {
        flex-direction: column;
        gap: 24px;
    }

    .mega-left {
        flex-direction: column;
        align-items: flex-start;
    }

    .mega-left h4 {
        white-space: normal;
    }

    .mega-right {
        flex-direction: column;
    }

    .mega-links {
        grid-template-columns: 1fr;
    }

    .mega-links a {
        white-space: normal;
    }

    .mega-image {
        min-width: auto;
        max-height: 180px;
    }
}

@media (max-width: 768px) {
    .mega-dropdown {
        display: none !important;
    }
}

/* ========= 下拉菜单结束 ========= */