/* 全局移动端修复 */
* {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%; /* 防止iOS字体缩放 */
}

body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

/* 备案号样式 */
.icp-beian {
    display: inline;
}

.icp-beian a {
    color: var(--light-gray);
    text-decoration: none;
    transition: color 0.3s ease;
}

.icp-beian a:hover {
    color: var(--pure-white);
    text-decoration: underline;
}


/* 移动端触摸优化 */
@media (max-width: 768px) {
    /* 改善触摸目标 */
    button, 
    .btn, 
    .section-nav-link, 
    .nav-list a,
    .dropdown-menu a {
        min-height: 44px;
        min-width: 44px;
    }
    
    /* 防止iOS点击高亮 */
    a, button {
        -webkit-tap-highlight-color: transparent;
    }
    
    /* 改善滚动体验 */
    .nav {
        -webkit-overflow-scrolling: touch;
    }
}

/* 基础样式重置和变量定义 - 经典蓝白配色方案 */
:root {
    /* 主色调 - 深蓝色系 */
    --primary-blue: #1e3c72;  /* 藏青色 */
    --dark-blue: #0d2b5c;     /* 更深的蓝色 */
    --medium-blue: #2c5282;   /* 中等蓝色 */
    --light-blue: #e6f2ff;    /* 浅蓝色 */
    
    /* 辅助色 - 白色系 */
    --pure-white: #ffffff;
    --light-gray: #f8f9fa;
    --medium-gray: #e9ecef;
    --dark-gray: #6c757d;
    --text-dark: #212529;
    
    /* 点缀色 - 绿色系 */
    --accent-green: #28a745;  /* 成功绿 */
    --light-green: #d4edda;   /* 浅绿色 */
    --dark-green: #011f08;   /* 深绿色 */
    
    /* 字体 */
    --font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    
    /* 间距 */
    --spacing-xs: 8px;
    --spacing-sm: 16px;
    --spacing-md: 24px;
    --spacing-lg: 32px;
    --spacing-xl: 48px;
    --spacing-xxl: 64px;
    
    /* 阴影 */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.15);
    
    /* 圆角 */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
}

/* 更新白色变量引用 */
:root {
    --white: var(--pure-white);
}

/* 更新头部导航样式 - 深蓝色背景 */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--primary-blue);
    z-index: 1000;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-md);
    height: 70px;
}

.header.scrolled {
    background-color: var(--primary-blue);
    box-shadow: var(--shadow-lg);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%; /* 继承.header的高度 */
    padding: 0 var(--spacing-md); /* 只设置左右内边距 */
}


/* Logo样式 */
.logo {
    display: flex;
    align-items: center;
}

.logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo-img {
    width: 225px; /* 根据实际logo尺寸调整 */
    height: 45px; /* 根据实际logo尺寸调整 */
    background: transparent; /* 移除背景色 */
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* 如果使用img标签，添加图片样式 */
.logo-img img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* 保持图片比例 */
    display: block;
}

/* 导航链接样式 - 白色文字 */
.nav-list {
    display: flex;
    gap: var(--spacing-md);
    align-items: center;
    height: 100%;
}

.nav-list a {
    font-weight: 500;
    transition: all 0.3s ease;
    color: var(--pure-white);
    padding: 12px 16px; /* 增加上下内边距以适应70px高度 */
    border-radius: var(--radius-sm);
    font-size: 1rem;
    white-space: nowrap;
    line-height: 1.2;
    display: flex;
    align-items: center;
}

.nav-list a:hover,
.nav-list a.active {
    background-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

/* 下拉菜单样式 */
.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--pure-white);
    box-shadow: var(--shadow-lg);
    border-radius: var(--radius-md);
    padding: var(--spacing-sm);
    min-width: 220px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    border: 1px solid var(--medium-gray);
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    margin-bottom: var(--spacing-xs);
}

.dropdown-menu a {
    display: block;
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--radius-sm);
    color: var(--text-dark);
    background: transparent;
    font-size: 0.95rem;
    line-height: normal !important;  /* 重置行高 */
    height: auto !important;         /* 重置高度 */
    white-space: nowrap;             /* 防止文字换行 */
    transition: all 0.3s ease;
}

.dropdown-menu a:hover {
    background-color: var(--light-blue);
    color: var(--primary-blue);
    transform: none;
}

/* 按钮样式更新 */
.btn {
    display: inline-block;
    padding: var(--spacing-sm) var(--spacing-lg);
    border-radius: var(--radius-sm);
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--primary-blue);
    color: var(--pure-white);
}

.btn-primary:hover {
    background-color: var(--dark-blue);
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: transparent;
    color: var(--primary-blue);
    border: 2px solid var(--primary-blue);
}

.btn-secondary:hover {
    background-color: var(--primary-blue);
    color: var(--pure-white);
    transform: translateY(-2px);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary-blue);
    border: 2px solid var(--primary-blue);
}

.btn-outline:hover {
    background-color: var(--primary-blue);
    color: var(--pure-white);
    transform: translateY(-2px);
}

/* 绿色点缀按钮 */
.btn-accent {
    background-color: var(--accent-green);
    color: var(--pure-white);
}

.btn-accent:hover {
    background-color: #218838;
    transform: translateY(-2px);
}

/* 其余基础样式保持不变 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--pure-white);
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.section {
    padding: var(--spacing-xxl) 0;
}

.page-header h1 {
    font-size: 2.5rem;
    color: var(--primary-blue);
    margin-bottom: var(--spacing-sm);
    text-align: center;
}

.section-title {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: var(--spacing-md);
    text-align: center;
    color: var(--primary-blue);
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 120px;
    height: 3px;
    background-color: var(--primary-blue);
    margin: var(--spacing-sm) auto;
}

.section-subtitle {
    text-align: center;
    color: var(--dark-gray);
    margin-bottom: var(--spacing-lg);
    font-size: 1.1rem;
}

.bg-light {
    background-color: var(--light-gray);
}

.text-center {
    text-align: center;
}

/* 移动端导航优化 - 修复标签重合问题 */
@media (max-width: 768px) {
    .header {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        background-color: var(--dark-blue);
        z-index: 1000;
        height: 60px;
        min-height: 60px;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    }
    
    .header-inner {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding: 0 15px;
        height: 60px;
    }
    
    .logo {
        width: auto;
        margin-bottom: 0;
        flex-shrink: 0;
    }
    
    .logo-img {
        width: 160px;
        height: 32px;
        filter: brightness(0) invert(1); /* 将logo变为白色 */
    }
    
    .nav {
        position: fixed;
        top: 60px;
        left: 0;
        width: 100%;
        height: calc(100vh - 60px);
        background: var(--dark-green);
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        overflow-y: auto;
        z-index: 1000;
        padding: 0;
        display: block;
    }
    
    .nav.active {
        transform: translateX(0);
    }
    
    .nav-list {
        display: flex;
        gap: var(--spacing-md);
        align-items: center;
        height: 100%;
        margin: 0;
        padding: 0;
    }

    .nav-list a {
        font-weight: 500;
        color: var(--pure-white);
        padding: 12px 16px;
        border-radius: var(--radius-sm);
        font-size: 1rem;
        white-space: nowrap;
        line-height: 1.2;
        display: flex;
        align-items: center;
        justify-content: center;
        /* 移除过渡效果 */
    }

    .nav-list a:hover,
    .nav-list a.active {
        background-color: rgba(255, 255, 255, 0.15);
        /* 移除transform效果 */
    }

    /* 下拉菜单样式 */
    .dropdown {
        position: relative;
    }

    .dropdown-menu {
        display: none !important;
        position: static !important;
        box-shadow: none !important;
        background: rgba(255, 255, 255, 0.1) !important;
        border: none !important;
        padding: 0 !important;
        margin: 0 !important;
        opacity: 1 !important;
        visibility: visible !important;
        transform: none !important;
        transition: none !important;
    }
    
    .dropdown.active .dropdown-menu {
        display: block !important;
    }
    
    .dropdown-menu a {
        color: var(--pure-white) !important;
        padding: 12px 20px !important;
        border-left: 3px solid transparent;
        font-size: 14px !important;
        line-height: normal !important;
        height: auto !important;
        display: block !important;
    }
    
    .dropdown-menu a:hover {
        background: rgba(255, 255, 255, 0.1) !important;
        border-left-color: var(--pure-white);
    }

    .dropdown:hover .dropdown-menu {
        opacity: 1;
        visibility: visible;
        /* 移除transform效果 */
    }

    .dropdown-menu li {
        margin-bottom: var(--spacing-xs);
    }
    
    /* 导航切换按钮优化 - 三条横线 */
    .nav-toggle {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        width: 30px;
        height: 30px;
        cursor: pointer;
        position: relative;
        z-index: 1001;
    }
    
    .nav-toggle span {
        display: block;
        width: 25px;
        height: 3px;
        background: var(--pure-white);
        margin: 3px 0;
        transition: all 0.3s ease;
        border-radius: 2px;
    }
    
    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(6px, 6px);
    }
    
    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(6px, -6px);
    }
    
    /* 防止页面滚动当导航打开时 */
    body.nav-open {
        overflow: hidden;
    }

    body {
        padding-top: 60px;
    }

    .footer-bottom p {
        display: flex;
        flex-direction: column;
        gap: var(--spacing-xs);
    }
    
    .icp-beian {
        font-size: 0.9rem;
    }
}

/* 桌面端保持原有固定导航栏 */
@media (min-width: 769px) {
    .header {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        background-color: var(--primary-blue);
        z-index: 1000;
        transition: all 0.3s ease;
        box-shadow: var(--shadow-md);
        height: 70px;
    }
    
    .header.scrolled {
        background-color: var(--primary-blue);
        box-shadow: var(--shadow-lg);
    }
    
    .page-header,
    .hero {
        margin-top: 70px;
    }
    
    .nav-toggle {
        display: none;
    }

    .footer-bottom p {
        font-size: 0.85rem;
        line-height: 1.4;
    }
    
    .icp-beian {
        font-size: 0.85rem;
    }
}