/* ===== 全局基础样式 ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: #f8f9fa;
    color: #222;
    line-height: 1.7;
    transition: background 0.3s, color 0.3s;
}

body.dark {
    background: #0f0f1a;
    color: #e0e0e0;
}

a {
    color: #0056b3;
    text-decoration: none;
    transition: color 0.3s;
}

a:hover {
    text-decoration: underline;
}

/* ===== 容器与布局 ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.glass {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.dark .glass {
    background: rgba(20, 20, 40, 0.85);
    border-color: rgba(255, 255, 255, 0.08);
}

.card {
    border-radius: 24px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background: #fff;
}

.dark .card {
    background: #1a1a30;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.1);
}

.dark .card:hover {
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.6);
}

.grid {
    display: grid;
    gap: 24px;
}

.flex {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

.text-center {
    text-align: center;
}

.mb-2 {
    margin-bottom: 16px;
}

.mb-4 {
    margin-bottom: 32px;
}

.mt-4 {
    margin-top: 32px;
}

.py-4 {
    padding-top: 32px;
    padding-bottom: 32px;
}

.py-6 {
    padding-top: 48px;
    padding-bottom: 48px;
}

/* ===== 标题与副标题 ===== */
.section-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 12px;
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.dark .section-title {
    background: linear-gradient(135deg, #e0e0ff, #a0a0ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.section-sub {
    color: #555;
    max-width: 640px;
    margin: 0 auto 32px;
}

.dark .section-sub {
    color: #aaa;
}

/* ===== 按钮 ===== */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 40px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    color: #fff;
}

.btn:hover {
    transform: scale(1.03);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.dark .btn {
    background: linear-gradient(135deg, #3a3a6e, #2a2a5e);
}

.dark .btn:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

/* ===== 头部导航 ===== */
header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.dark header {
    background: rgba(15, 15, 30, 0.92);
    border-bottom-color: rgba(255, 255, 255, 0.05);
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
}

.nav-logo {
    font-size: 1.6rem;
    font-weight: 800;
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.dark .nav-logo {
    background: linear-gradient(135deg, #e0e0ff, #a0a0ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-links {
    display: flex;
    gap: 24px;
    list-style: none;
}

.nav-links a {
    font-weight: 500;
    color: #333;
    padding: 6px 0;
    border-bottom: 2px solid transparent;
    transition: border-color 0.3s, color 0.3s;
}

.dark .nav-links a {
    color: #ccc;
}

.nav-links a:hover {
    border-bottom-color: #1a1a2e;
}

.dark .nav-links a:hover {
    border-bottom-color: #a0a0ff;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    background: none;
    border: none;
    padding: 8px;
}

.nav-toggle span {
    width: 26px;
    height: 3px;
    background: #333;
    border-radius: 4px;
    transition: all 0.3s;
}

.dark .nav-toggle span {
    background: #ccc;
}

/* ===== Hero 区域 ===== */
.hero {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 80px 20px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #f0f2ff, #e8ecff);
}

.dark .hero {
    background: linear-gradient(135deg, #0f0f2a, #1a1a3e);
}

.hero h1 {
    font-size: 3.2rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.dark .hero h1 {
    background: linear-gradient(135deg, #e0e0ff, #a0a0ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    font-size: 1.2rem;
    color: #444;
    max-width: 600px;
    margin: 0 auto 32px;
}

.dark .hero p {
    color: #bbb;
}

/* ===== Banner 轮播 ===== */
.banner-slider {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 24px;
    margin: 40px auto;
    max-width: 900px;
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(8px);
    padding: 20px;
}

.dark .banner-slider {
    background: rgba(20, 20, 40, 0.5);
}

.banner-slide {
    display: none;
    padding: 40px;
    text-align: center;
}

.banner-slide.active {
    display: block;
    animation: fadeIn 0.6s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== 统计网格 ===== */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 24px;
    margin: 40px 0;
}

.stat-item {
    text-align: center;
    padding: 24px 12px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: transform 0.3s, box-shadow 0.3s;
}

.stat-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}

.dark .stat-item {
    background: rgba(30, 30, 60, 0.7);
    border-color: rgba(255, 255, 255, 0.05);
}

.stat-number {
    font-size: 2.8rem;
    font-weight: 800;
    color: #1a1a2e;
}

.dark .stat-number {
    color: #e0e0ff;
}

.stat-label {
    color: #555;
    margin-top: 8px;
}

.dark .stat-label {
    color: #aaa;
}

/* ===== FAQ 折叠 ===== */
.faq-item {
    border-bottom: 1px solid #e0e0e0;
    padding: 16px 0;
    cursor: pointer;
    transition: background 0.3s;
}

.faq-item:hover {
    background: rgba(0, 0, 0, 0.02);
}

.dark .faq-item {
    border-color: #2a2a4a;
}

.dark .faq-item:hover {
    background: rgba(255, 255, 255, 0.02);
}

.faq-question {
    font-weight: 600;
    font-size: 1.1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
    color: #444;
}

.dark .faq-answer {
    color: #aaa;
}

.faq-item.open .faq-answer {
    max-height: 300px;
    padding-top: 12px;
}

.faq-item .icon {
    transition: transform 0.3s;
}

.faq-item.open .icon {
    transform: rotate(45deg);
}

/* ===== 页脚 ===== */
footer {
    background: #1a1a2e;
    color: #ccc;
    padding: 48px 20px 24px;
    margin-top: 48px;
}

.dark footer {
    background: #0a0a18;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 32px;
}

.footer-grid h4 {
    color: #fff;
    margin-bottom: 12px;
}

.footer-grid a {
    color: #aaa;
    display: block;
    margin-bottom: 6px;
    transition: color 0.3s;
}

.footer-grid a:hover {
    color: #fff;
}

.footer-bottom {
    border-top: 1px solid #2a2a4a;
    margin-top: 32px;
    padding-top: 20px;
    text-align: center;
    font-size: 0.9rem;
}

/* ===== 返回顶部 ===== */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #1a1a2e;
    color: #fff;
    border: none;
    font-size: 1.4rem;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    transition: all 0.3s;
    z-index: 99;
}

.dark .back-to-top {
    background: #3a3a6e;
}

.back-to-top.show {
    display: flex;
}

.back-to-top:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* ===== 暗色模式切换 ===== */
.dark-mode-toggle {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #1a1a2e;
    color: #fff;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    z-index: 99;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    transition: all 0.3s;
}

.dark .dark-mode-toggle {
    background: #3a3a6e;
}

.dark-mode-toggle:hover {
    transform: scale(1.1);
}

/* ===== 搜索模拟 ===== */
.search-sim {
    display: flex;
    max-width: 500px;
    margin: 20px auto;
    background: #fff;
    border-radius: 40px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.3s;
}

.search-sim:focus-within {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.dark .search-sim {
    background: #1a1a30;
}

.search-sim input {
    flex: 1;
    padding: 14px 20px;
    border: none;
    outline: none;
    font-size: 1rem;
    background: transparent;
    color: #222;
}

.dark .search-sim input {
    color: #e0e0e0;
}

.search-sim button {
    padding: 14px 24px;
    background: #1a1a2e;
    color: #fff;
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s;
}

.search-sim button:hover {
    background: #16213e;
}

.dark .search-sim button {
    background: #3a3a6e;
}

.dark .search-sim button:hover {
    background: #2a2a5e;
}

/* ===== 滚动动画 ===== */
.scroll-fade {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.scroll-fade.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===== SVG 图片 ===== */
svg {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
    border-radius: 16px;
}

/* ===== 响应式设计 ===== */
@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(255, 255, 255, 0.98);
        flex-direction: column;
        padding: 20px;
        gap: 12px;
        backdrop-filter: blur(20px);
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    }

    .dark .nav-links {
        background: rgba(15, 15, 30, 0.98);
    }

    .nav-links.open {
        display: flex;
    }

    .nav-toggle {
        display: flex;
    }

    .hero h1 {
        font-size: 2.2rem;
    }

    .section-title {
        font-size: 1.6rem;
    }

    .stat-number {
        font-size: 2rem;
    }

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

    .hero {
        min-height: 60vh;
        padding: 60px 20px;
    }

    .banner-slide {
        padding: 20px;
    }

    .banner-slider {
        margin: 20px auto;
    }

    .stat-grid {
        gap: 16px;
    }

    .back-to-top,
    .dark-mode-toggle {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
    }

    .dark-mode-toggle {
        bottom: 20px;
        left: 20px;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.8rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .section-title {
        font-size: 1.4rem;
    }

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

    .grid {
        gap: 16px;
    }

    .card {
        border-radius: 16px;
    }
}

/* ===== 暗色模式额外微调 ===== */
.dark .banner-slide h3 {
    background: linear-gradient(135deg, #e0e0ff, #a0a0ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.dark .banner-slide p {
    color: #bbb;
}

.dark .faq-question {
    color: #e0e0e0;
}

.dark .nav-links a:hover {
    color: #a0a0ff;
}

.dark .search-sim input::placeholder {
    color: #888;
}

.dark .stat-item:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}