/* ===== 全局重置与基础 ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f8f9fa;
    color: #333;
    line-height: 1.8;
    overflow-x: hidden;
    transition: background 0.3s, color 0.3s;
}

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

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

img, svg {
    max-width: 100%;
    display: block;
}

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

.gradient-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.glass {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 16px;
}

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

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

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

.btn {
    display: inline-block;
    padding: 12px 32px;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
}

.btn-primary:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.4);
}

.section {
    padding: 80px 0;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 16px;
    text-align: center;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 48px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.dark-mode .section-subtitle {
    color: #aaa;
}

/* ===== 网格系统 ===== */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 32px;
}

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

.grid-4 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
}

/* ===== 工具类 ===== */
.text-center {
    text-align: center;
}

.mt-16 { margin-top: 16px; }
.mt-32 { margin-top: 32px; }
.mb-16 { margin-bottom: 16px; }
.mb-32 { margin-bottom: 32px; }

.hidden {
    display: none;
}

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

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

.scroll-animate {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

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

.stat-animate .stat-number {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.stat-animate.visible .stat-number {
    opacity: 1;
    transform: translateY(0);
}

/* ===== 头部导航 ===== */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 16px 0;
    transition: background 0.3s ease;
}

header.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

.dark-mode header.scrolled {
    background: rgba(15, 15, 26, 0.95);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    gap: 24px;
    align-items: center;
}

.nav-links a {
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: #667eea;
}

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

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 5px;
}

.hamburger span {
    width: 28px;
    height: 3px;
    background: #333;
    border-radius: 2px;
    transition: all 0.3s;
}

.dark-mode .hamburger span {
    background: #e0e0e0;
}

/* ===== 面包屑 ===== */
.breadcrumb {
    padding: 16px 0;
    font-size: 0.9rem;
    color: #999;
    max-width: 1200px;
    margin: 0 auto;
    padding-left: 20px;
}

.breadcrumb a {
    color: #667eea;
}

.breadcrumb span {
    margin: 0 8px;
}

.dark-mode .breadcrumb {
    color: #aaa;
}

.dark-mode .breadcrumb a {
    color: #a78bfa;
}

/* ===== Hero 区域 ===== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #0f0c29 0%, #302b63 50%, #24243e 100%);
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.15) 0%, transparent 70%);
    animation: heroGlow 8s ease-in-out infinite alternate;
}

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

@keyframes heroGlow {
    0% { transform: translate(0, 0); }
    100% { transform: translate(10%, 10%); }
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    padding: 0 20px;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    color: #fff;
    margin-bottom: 24px;
    line-height: 1.2;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.hero-title span {
    background: linear-gradient(135deg, #667eea, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.3rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-buttons .btn {
    font-size: 1.1rem;
    padding: 16px 40px;
}

.hero-buttons .btn-outline {
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.5);
    color: #fff;
}

.hero-buttons .btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #fff;
}

/* ===== Banner 轮播 ===== */
.banner-slider {
    position: relative;
    width: 100%;
    overflow: hidden;
    margin-top: 48px;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.banner-slide {
    display: none;
    width: 100%;
    transition: opacity 0.5s ease;
}

.banner-slide.active {
    display: block;
}

.banner-slide svg {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 16px;
}

.banner-dots {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 16px;
}

.banner-dots span {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: all 0.3s;
}

.banner-dots span.active {
    background: #667eea;
    transform: scale(1.3);
}

/* ===== 关于区域 ===== */
#about .card {
    padding: 40px;
}

#about .card p {
    font-size: 1.05rem;
    line-height: 1.9;
    color: #555;
}

.dark-mode #about .card p {
    color: #ccc;
}

/* ===== 统计区域 ===== */
.stat-item {
    text-align: center;
    padding: 32px 16px;
}

.stat-number {
    font-size: 3rem;
    font-weight: 800;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: block;
}

.stat-label {
    font-size: 1.1rem;
    color: #666;
    margin-top: 8px;
}

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

/* ===== 产品卡片 ===== */
.product-card {
    padding: 24px;
    text-align: center;
}

.product-card svg {
    width: 80px;
    height: 80px;
    margin-bottom: 16px;
}

.product-card h3 {
    font-size: 1.4rem;
    margin-bottom: 12px;
}

.product-card p {
    color: #666;
    font-size: 0.95rem;
}

.dark-mode .product-card p {
    color: #aaa;
}

/* ===== 优势卡片 ===== */
.advantage-card {
    padding: 32px;
    text-align: center;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05), rgba(118, 75, 162, 0.05));
    border-radius: 16px;
    transition: all 0.3s;
}

.advantage-card:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
}

.advantage-card svg {
    width: 60px;
    height: 60px;
    margin-bottom: 16px;
}

.advantage-card h3 {
    font-size: 1.3rem;
    margin-bottom: 12px;
}

.advantage-card p {
    color: #666;
    font-size: 0.95rem;
}

.dark-mode .advantage-card p {
    color: #aaa;
}

/* ===== 案例卡片 ===== */
.case-card {
    padding: 0;
    border-radius: 16px;
    overflow: hidden;
}

.case-card svg {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.case-card .case-body {
    padding: 24px;
}

.case-card .case-body h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.case-card .case-body p {
    color: #666;
    font-size: 0.95rem;
}

.dark-mode .case-card .case-body p {
    color: #aaa;
}

/* ===== 评价卡片 ===== */
.testimonial-card {
    padding: 32px;
    text-align: center;
    position: relative;
}

.testimonial-card::before {
    content: '"';
    font-size: 4rem;
    position: absolute;
    top: 8px;
    left: 24px;
    color: rgba(102, 126, 234, 0.2);
    font-family: Georgia, serif;
}

.testimonial-card p {
    font-style: italic;
    font-size: 1.05rem;
    color: #555;
    margin-bottom: 16px;
}

.dark-mode .testimonial-card p {
    color: #ccc;
}

.testimonial-card .author {
    font-weight: 600;
    color: #333;
}

.dark-mode .testimonial-card .author {
    color: #e0e0e0;
}

/* ===== 新闻卡片 ===== */
.news-card {
    padding: 24px;
}

.news-card .date {
    font-size: 0.85rem;
    color: #999;
    margin-bottom: 8px;
}

.news-card h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
    line-height: 1.5;
}

.news-card p {
    color: #666;
    font-size: 0.95rem;
}

.dark-mode .news-card p {
    color: #aaa;
}

/* ===== FAQ ===== */
.faq-item {
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    padding: 16px 0;
    cursor: pointer;
}

.dark-mode .faq-item {
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    font-size: 1.05rem;
    padding: 8px 0;
}

.faq-question span {
    transition: transform 0.3s;
}

.faq-item.active .faq-question span {
    transform: rotate(45deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s;
    padding: 0 16px;
    color: #666;
    font-size: 0.95rem;
}

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

.faq-item.active .faq-answer {
    max-height: 300px;
    padding: 16px 16px 8px;
}

/* ===== 使用步骤 ===== */
.howto-step {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    padding: 16px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.dark-mode .howto-step {
    border-bottom-color: rgba(255, 255, 255, 0.05);
}

.howto-step .step-num {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
}

.howto-step .step-text {
    flex: 1;
}

.howto-step .step-text h4 {
    font-size: 1.1rem;
    margin-bottom: 4px;
}

.howto-step .step-text p {
    color: #666;
    font-size: 0.95rem;
}

.dark-mode .howto-step .step-text p {
    color: #aaa;
}

/* ===== 联系信息 ===== */
.contact-info {
    padding: 32px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05), rgba(118, 75, 162, 0.05));
    border-radius: 16px;
}

.contact-info p {
    margin-bottom: 12px;
    font-size: 1rem;
}

.contact-info strong {
    color: #667eea;
}

.dark-mode .contact-info strong {
    color: #a78bfa;
}

/* ===== 搜索模拟 ===== */
.search-sim {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
    border-radius: 50px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

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

.dark-mode .search-sim input {
    background: #1e1e32;
    color: #e0e0e0;
}

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

.search-sim button {
    padding: 14px 28px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s;
}

.search-sim button:hover {
    background: linear-gradient(135deg, #764ba2, #667eea);
}

/* ===== 最新更新与相关文章 ===== */
.latest-updates,
.related-articles {
    padding: 16px 0;
}

.latest-updates h3,
.related-articles h3 {
    font-size: 1.2rem;
    margin-bottom: 16px;
    color: #333;
}

.dark-mode .latest-updates h3,
.dark-mode .related-articles h3 {
    color: #e0e0e0;
}

.latest-updates ul li,
.related-articles ul li {
    margin-bottom: 8px;
}

.latest-updates ul li a,
.related-articles ul li a {
    color: #667eea;
    transition: color 0.3s;
}

.latest-updates ul li a:hover,
.related-articles ul li a:hover {
    color: #764ba2;
}

.dark-mode .latest-updates ul li a,
.dark-mode .related-articles ul li a {
    color: #a78bfa;
}

/* ===== 上下篇导航 ===== */
.prev-next {
    display: flex;
    justify-content: space-between;
    padding: 16px 0;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    margin-top: 32px;
}

.dark-mode .prev-next {
    border-top-color: rgba(255, 255, 255, 0.1);
}

.prev-next a {
    color: #667eea;
    font-weight: 500;
    transition: color 0.3s;
}

.prev-next a:hover {
    color: #764ba2;
}

.dark-mode .prev-next a {
    color: #a78bfa;
}

/* ===== 页脚 ===== */
footer {
    background: #1a1a2e;
    color: rgba(255, 255, 255, 0.8);
    padding: 60px 0 20px;
}

.dark-mode footer {
    background: #0a0a1a;
}

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

.footer-grid h4 {
    color: #fff;
    margin-bottom: 16px;
    font-size: 1.1rem;
}

.footer-grid a {
    display: block;
    margin-bottom: 8px;
    transition: color 0.3s;
    font-size: 0.95rem;
}

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

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    text-align: center;
    font-size: 0.9rem;
}

.footer-bottom p {
    margin-bottom: 8px;
}

/* ===== 回到顶部 ===== */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 999;
    border: none;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.4);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-3px);
}

/* ===== 暗色模式切换 ===== */
.dark-mode-toggle {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #fff;
    color: #333;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 999;
    border: none;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    transition: all 0.3s;
}

.dark-mode .dark-mode-toggle {
    background: #1e1e32;
    color: #e0e0e0;
}

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

/* ===== 响应式设计 ===== */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.2rem;
    }

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

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

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(10px);
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    }

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

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

    .hamburger {
        display: flex;
    }

    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }

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

    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }

    .dark-mode-toggle {
        bottom: 20px;
        left: 20px;
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
}

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

    .hero-buttons .btn {
        padding: 12px 24px;
        font-size: 0.95rem;
    }

    .section {
        padding: 48px 0;
    }

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