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

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

body.dark {
    background: #1a1a2e;
    color: #e0e0e0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== 头部 Header ===== */
header {
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    color: white;
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

body.dark header {
    background: linear-gradient(135deg, #0f0f1a, #1a1a2e);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: bold;
}

.logo svg {
    width: 40px;
    height: 40px;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

nav a {
    color: white;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 20px;
    transition: background 0.3s;
}

nav a:hover {
    background: rgba(255, 255, 255, 0.2);
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 28px;
    cursor: pointer;
}

.search-box {
    display: flex;
    align-items: center;
    gap: 5px;
}

.search-box input {
    padding: 8px 12px;
    border: none;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.search-box input::placeholder {
    color: #ccc;
}

.search-box button {
    background: #ff6b35;
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    transition: background 0.3s;
}

.search-box button:hover {
    background: #e55a2b;
}

.dark-toggle {
    background: none;
    border: 2px solid white;
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    transition: background 0.3s, color 0.3s;
}

.dark-toggle:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* ===== Hero 区域 ===== */
.hero {
    background: linear-gradient(135deg, #1a1a2e, #16213e, #0f3460);
    padding: 100px 0;
    text-align: center;
    color: white;
}

.hero h1 {
    font-size: 48px;
    margin-bottom: 20px;
}

.hero p {
    font-size: 20px;
    max-width: 800px;
    margin: 0 auto;
}

.hero .btn {
    display: inline-block;
    margin-top: 30px;
    padding: 14px 40px;
    background: #ff6b35;
    color: white;
    border-radius: 30px;
    text-decoration: none;
    font-size: 18px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.hero .btn:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 20px rgba(255, 107, 53, 0.4);
}

/* ===== 通用 Section ===== */
.section {
    padding: 60px 0;
}

.section h2 {
    font-size: 36px;
    margin-bottom: 30px;
    text-align: center;
}

.section h3 {
    font-size: 24px;
    margin-bottom: 20px;
}

/* ===== 卡片 Card ===== */
.card {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
    transition: transform 0.3s, box-shadow 0.3s;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

body.dark .card {
    background: #2a2a4a;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

/* ===== 网格与弹性布局 ===== */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

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

/* ===== Banner 轮播 ===== */
.banner-slider {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
}

.banner-slide {
    display: none;
    padding: 60px;
    background: linear-gradient(135deg, #ff6b35, #ffa500);
    color: white;
    text-align: center;
    min-height: 300px;
}

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

.banner-slide h2 {
    font-size: 36px;
}

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

.banner-dots span {
    width: 12px;
    height: 12px;
    background: #ccc;
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.3s;
}

.banner-dots span.active {
    background: #ff6b35;
}

/* ===== FAQ ===== */
.faq-item {
    border-bottom: 1px solid #ddd;
    padding: 15px 0;
    cursor: pointer;
}

body.dark .faq-item {
    border-color: #444;
}

.faq-question {
    font-weight: bold;
    display: flex;
    justify-content: space-between;
}

.faq-answer {
    display: none;
    padding-top: 10px;
}

.faq-item.open .faq-answer {
    display: block;
}

/* ===== HowTo 步骤 ===== */
.howto-step {
    padding: 20px;
    background: #f1f3f5;
    border-radius: 15px;
    margin-bottom: 20px;
}

body.dark .howto-step {
    background: #2a2a4a;
}

/* ===== 客户评价 ===== */
.testimonial {
    background: #f8f9fa;
    padding: 30px;
    border-radius: 20px;
}

body.dark .testimonial {
    background: #2a2a4a;
}

/* ===== 页脚 Footer ===== */
.footer {
    background: #1a1a2e;
    color: white;
    padding: 40px 0;
    margin-top: 60px;
}

.footer a {
    color: #ff6b35;
    text-decoration: none;
    transition: color 0.3s;
}

.footer a:hover {
    color: #ffa500;
}

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

/* ===== 返回顶部 ===== */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: #ff6b35;
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 24px;
    cursor: pointer;
    display: none;
    z-index: 999;
    transition: background 0.3s, transform 0.3s;
}

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

.back-to-top:hover {
    background: #e55a2b;
    transform: scale(1.1);
}

/* ===== 面包屑 ===== */
.breadcrumb {
    padding: 20px 0;
    font-size: 14px;
}

.breadcrumb a {
    color: #ff6b35;
    text-decoration: none;
}

.breadcrumb span {
    color: #666;
}

/* ===== 数字动画 ===== */
.animated-number {
    font-size: 48px;
    font-weight: bold;
    color: #ff6b35;
}

/* ===== 文章卡片 ===== */
.article-card {
    padding: 20px;
    background: #fff;
    border-radius: 15px;
}

body.dark .article-card {
    background: #2a2a4a;
}

.article-card h3 {
    font-size: 20px;
}

.article-card .read-more {
    color: #ff6b35;
    text-decoration: none;
    display: inline-block;
    margin-top: 10px;
    transition: color 0.3s;
}

.article-card .read-more:hover {
    color: #e55a2b;
}

/* ===== Newsletter ===== */
.newsletter {
    background: linear-gradient(135deg, #ff6b35, #ffa500);
    padding: 40px;
    border-radius: 20px;
    text-align: center;
    color: white;
}

.newsletter input {
    padding: 12px 20px;
    border: none;
    border-radius: 30px;
    width: 300px;
    max-width: 100%;
}

.newsletter button {
    padding: 12px 30px;
    border: none;
    background: #1a1a2e;
    color: white;
    border-radius: 30px;
    cursor: pointer;
    transition: background 0.3s;
}

.newsletter button:hover {
    background: #2a2a4a;
}

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

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

/* ===== 图片通用 ===== */
.card img,
.article-card img,
.banner-slide img {
    width: 100%;
    height: auto;
    border-radius: 10px;
}

/* ===== QR Code ===== */
.qr-code {
    width: 120px;
    height: 120px;
    background: #f0f0f0;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 10px 0;
}

body.dark .qr-code {
    background: #2a2a4a;
}

/* ===== 响应式设计 ===== */
@media (max-width: 768px) {
    nav ul {
        display: none;
        flex-direction: column;
        width: 100%;
    }

    nav ul.show {
        display: flex;
    }

    .nav-toggle {
        display: block;
    }

    .hero h1 {
        font-size: 32px;
    }

    .hero p {
        font-size: 16px;
    }

    .header-inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .search-box {
        margin-top: 10px;
        width: 100%;
    }

    .search-box input {
        flex: 1;
    }

    .section h2 {
        font-size: 28px;
    }

    .banner-slide h2 {
        font-size: 24px;
    }

    .banner-slide {
        padding: 30px;
    }

    .newsletter input {
        width: 100%;
        margin-bottom: 10px;
    }

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

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

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

    .hero p {
        font-size: 14px;
    }

    .hero .btn {
        padding: 10px 30px;
        font-size: 16px;
    }

    .card {
        padding: 20px;
    }

    .section {
        padding: 40px 0;
    }
}