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

html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background: #f4f7fc;
    color: #1a1a2e;
    line-height: 1.6;
    transition: background 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
}

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

a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

ul {
    list-style: none;
}

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

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

/* ===== 辅助 ===== */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

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

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

/* ===== 按钮 ===== */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 30px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
    line-height: 1.4;
}

.btn-primary {
    background: linear-gradient(135deg, #f5c842, #f0a500);
    color: #1a1a2e;
    box-shadow: 0 4px 15px rgba(245, 200, 66, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(245, 200, 66, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-outline {
    background: transparent;
    border: 2px solid #f5c842;
    color: #f5c842;
}

.btn-outline:hover {
    background: #f5c842;
    color: #1a1a2e;
}

/* ===== 章节 ===== */
.section {
    padding: 80px 0;
}

.section-title {
    font-size: 2.2rem;
    text-align: center;
    margin-bottom: 15px;
    font-weight: 700;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: #f5c842;
    margin: 15px auto 0;
    border-radius: 2px;
}

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

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

/* ===== 卡片 ===== */
.card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

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

body.dark .card {
    background: rgba(30, 30, 50, 0.7);
    border-color: rgba(255, 255, 255, 0.05);
}

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

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

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

/* ===== 头部导航 ===== */
header[role="banner"] {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    transition: background 0.3s ease;
}

body.dark header[role="banner"] {
    background: rgba(15, 15, 26, 0.85);
    border-bottom-color: rgba(255, 255, 255, 0.06);
}

header[role="banner"] .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
}

header[role="banner"] .logo-link {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 800;
    color: #1a1a2e;
}

body.dark header[role="banner"] .logo-link {
    color: #e0e0e0;
}

header[role="banner"] nav[role="navigation"] {
    display: flex;
    align-items: center;
    gap: 24px;
}

header[role="banner"] nav[role="navigation"] ul {
    display: flex;
    gap: 20px;
    font-weight: 500;
}

header[role="banner"] nav[role="navigation"] ul li a {
    padding: 6px 0;
    position: relative;
    transition: color 0.2s ease;
}

header[role="banner"] nav[role="navigation"] ul li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: #f5c842;
    transition: width 0.3s ease;
}

header[role="banner"] nav[role="navigation"] ul li a:hover::after,
header[role="banner"] nav[role="navigation"] ul li a:focus::after {
    width: 100%;
}

header[role="banner"] nav[role="navigation"] ul li a[href="#hero"] {
    color: #f5c842;
}

/* 头部按钮 */
header[role="banner"] .nav-btn {
    background: none;
    border: none;
    font-size: 1.4rem;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 8px;
    transition: background 0.2s ease;
    line-height: 1;
}

header[role="banner"] .nav-btn:hover {
    background: rgba(0, 0, 0, 0.05);
}

body.dark header[role="banner"] .nav-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* 搜索栏 */
#searchBar {
    display: none;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

body.dark #searchBar {
    background: rgba(15, 15, 26, 0.9);
}

#searchBar .container {
    display: flex;
    gap: 10px;
}

#searchBar input[type="search"] {
    flex: 1;
    padding: 12px 18px;
    border: 2px solid #ddd;
    border-radius: 30px;
    font-size: 1rem;
    outline: none;
    background: #fff;
    transition: border-color 0.3s ease;
}

body.dark #searchBar input[type="search"] {
    background: #1a1a2e;
    border-color: #333;
    color: #e0e0e0;
}

#searchBar input[type="search"]:focus {
    border-color: #f5c842;
}

#searchBar button {
    padding: 12px 24px;
    background: #f5c842;
    border: none;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    color: #1a1a2e;
    transition: background 0.3s ease;
}

#searchBar button:hover {
    background: #f0a500;
}

/* 移动菜单 */
#mobileMenu {
    display: none;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 20px;
    border-top: 1px solid #eee;
}

body.dark #mobileMenu {
    background: rgba(15, 15, 26, 0.95);
    border-top-color: #222;
}

#mobileMenu ul {
    display: flex;
    flex-direction: column;
    gap: 16px;
    font-size: 1.1rem;
    font-weight: 500;
}

#mobileMenu ul li a {
    display: block;
    padding: 8px 0;
}

/* ===== Hero Banner ===== */
#hero {
    position: relative;
    overflow: hidden;
    padding: 120px 0 100px;
    background: linear-gradient(135deg, #0f0f2e 0%, #1a1a4e 40%, #2a2a6e 100%);
    color: #fff;
}

#hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 20% 50%, rgba(245, 200, 66, 0.15), transparent 60%);
    pointer-events: none;
}

#hero .container {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 40px;
}

#hero .hero-text {
    flex: 1;
    min-width: 280px;
}

#hero h1 {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
}

#hero h1 span {
    color: #f5c842;
}

#hero p {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.8);
    max-width: 600px;
    margin-bottom: 30px;
}

#hero .hero-buttons {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

#hero .hero-visual {
    flex: 1;
    min-width: 280px;
    text-align: center;
}

#hero .hero-visual svg {
    max-width: 100%;
    height: auto;
}

#hero .hero-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 80px;
    background: linear-gradient(to top, #f4f7fc, transparent);
}

body.dark #hero .hero-wave {
    background: linear-gradient(to top, #0f0f1a, transparent);
}

/* ===== 面包屑 ===== */
.breadcrumb {
    background: #fff;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

body.dark .breadcrumb {
    background: #0f0f1a;
    border-bottom-color: #222;
}

.breadcrumb ol {
    display: flex;
    gap: 8px;
    font-size: 0.9rem;
    color: #666;
}

body.dark .breadcrumb ol {
    color: #aaa;
}

.breadcrumb ol li a {
    color: #f5c842;
}

/* ===== 关于 ===== */
#about {
    background: #fff;
}

body.dark #about {
    background: #0f0f1a;
}

#about .stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    margin-top: 40px;
}

#about .stats-grid .card {
    text-align: center;
}

#about .stats-grid .card strong {
    font-size: 2rem;
    color: #f5c842;
}

/* ===== 产品 ===== */
#products {
    background: #f4f7fc;
}

body.dark #products {
    background: #0a0a14;
}

#products .card svg {
    margin: 0 auto 15px;
}

/* ===== 优势 ===== */
#advantages {
    background: #fff;
}

body.dark #advantages {
    background: #0f0f1a;
}

/* ===== 服务 ===== */
#services {
    background: #f4f7fc;
}

body.dark #services {
    background: #0a0a14;
}

/* ===== 解决方案 ===== */
#solutions {
    background: #fff;
}

body.dark #solutions {
    background: #0f0f1a;
}

/* ===== 场景 ===== */
#scenarios {
    background: #f4f7fc;
}

body.dark #scenarios {
    background: #0a0a14;
}

/* ===== 数据 ===== */
#stats {
    background: linear-gradient(135deg, #1a1a2e, #2a2a5e);
    color: #fff;
}

#stats .section-title {
    color: #fff;
}

#stats .section-subtitle {
    color: rgba(255, 255, 255, 0.7);
}

#stats .stats-display {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 30px;
    text-align: center;
}

#stats .stats-display .stat-item .counter {
    font-size: 3rem;
    font-weight: 800;
    color: #f5c842;
}

#stats .stats-display .stat-item .suffix {
    font-size: 1.5rem;
    color: #f5c842;
}

#stats .stats-display .stat-item p {
    margin-top: 8px;
}

/* ===== 案例 ===== */
#cases {
    background: #fff;
}

body.dark #cases {
    background: #0f0f1a;
}

/* ===== 客户 ===== */
#clients {
    background: #f4f7fc;
}

body.dark #clients {
    background: #0a0a14;
}

#clients .client-logos {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 40px;
    align-items: center;
    padding: 20px 0;
}

#clients .client-logos svg {
    width: 100px;
    height: 40px;
}

/* ===== 评价 ===== */
#testimonials {
    background: #fff;
}

body.dark #testimonials {
    background: #0f0f1a;
}

/* ===== 新闻 ===== */
#news {
    background: #f4f7fc;
}

body.dark #news {
    background: #0a0a14;
}

#news article time {
    font-size: 0.9rem;
    color: #999;
}

/* ===== 文章 ===== */
#articles {
    background: #fff;
}

body.dark #articles {
    background: #0f0f1a;
}

/* ===== 推荐 ===== */
#recommend {
    background: #f4f7fc;
}

body.dark #recommend {
    background: #0a0a14;
}

/* ===== FAQ ===== */
#faq {
    background: #fff;
}

body.dark #faq {
    background: #0f0f1a;
}

#faq .container {
    max-width: 800px;
}

.faq-item {
    border-bottom: 1px solid #eee;
    padding: 15px 0;
}

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

.faq-question {
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    color: inherit;
    transition: color 0.2s ease;
}

.faq-question:hover {
    color: #f5c842;
}

.faq-question span {
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.faq-answer {
    display: none;
    padding: 10px 0;
    color: #666;
}

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

/* ===== HowTo ===== */
#howto {
    background: #f4f7fc;
}

body.dark #howto {
    background: #0a0a14;
}

#howto .container {
    max-width: 800px;
}

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

#howto .steps .card .step-number {
    font-size: 2rem;
    color: #f5c842;
    font-weight: 800;
}

/* ===== 联系 ===== */
#contact {
    background: #fff;
}

body.dark #contact {
    background: #0f0f1a;
}

#contact .grid-2 {
    max-width: 900px;
    margin: 0 auto;
}

/* ===== 网站地图 ===== */
#sitemap {
    background: #f4f7fc;
}

body.dark #sitemap {
    background: #0a0a14;
}

#sitemap .sitemap-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
}

#sitemap .sitemap-grid h4 {
    color: #f5c842;
    margin-bottom: 10px;
}

#sitemap .sitemap-grid ul li {
    margin-bottom: 6px;
}

#sitemap .sitemap-grid ul li a {
    transition: color 0.2s ease;
}

#sitemap .sitemap-grid ul li a:hover {
    color: #f5c842;
}

/* ===== 友情链接 ===== */
#friends {
    background: #fff;
    padding: 40px 0;
}

body.dark #friends {
    background: #0f0f1a;
}

#friends h3 {
    text-align: center;
    margin-bottom: 20px;
    color: #f5c842;
}

#friends .friend-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    font-size: 0.9rem;
}

#friends .friend-links a {
    transition: color 0.2s ease;
}

#friends .friend-links a:hover {
    color: #f5c842;
}

/* ===== 页脚 ===== */
footer[role="contentinfo"] {
    background: #1a1a2e;
    color: rgba(255, 255, 255, 0.7);
    padding: 40px 0 20px;
}

footer[role="contentinfo"] .footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

footer[role="contentinfo"] .footer-grid h4 {
    color: #f5c842;
    margin-bottom: 15px;
}

footer[role="contentinfo"] .footer-grid ul li {
    margin-bottom: 8px;
}

footer[role="contentinfo"] .footer-grid ul li a {
    transition: color 0.2s ease;
}

footer[role="contentinfo"] .footer-grid ul li a:hover {
    color: #f5c842;
}

footer[role="contentinfo"] .footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
}

/* ===== 返回顶部 ===== */
#backToTop {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #f5c842;
    color: #1a1a2e;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(245, 200, 66, 0.4);
    display: none;
    z-index: 999;
    transition: all 0.3s ease;
    line-height: 50px;
    text-align: center;
}

#backToTop:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(245, 200, 66, 0.5);
}

#backToTop:active {
    transform: translateY(0);
}

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

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

/* ===== 暗色模式调整 ===== */
body.dark .btn-primary {
    color: #1a1a2e;
}

body.dark .btn-outline {
    color: #f5c842;
    border-color: #f5c842;
}

body.dark .btn-outline:hover {
    background: #f5c842;
    color: #1a1a2e;
}

/* ===== 响应式 ===== */
@media (max-width: 992px) {
    .section {
        padding: 60px 0;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    #hero h1 {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    .section {
        padding: 50px 0;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .section-subtitle {
        font-size: 1rem;
        margin-bottom: 35px;
    }
    
    .grid-2, .grid-3, .grid-4 {
        gap: 20px;
    }
    
    .card {
        padding: 20px;
    }
    
    /* 头部 */
    header[role="banner"] .container {
        padding: 10px 15px;
    }
    
    header[role="banner"] .logo-link {
        font-size: 1.2rem;
    }
    
    header[role="banner"] .logo-link svg {
        width: 28px;
        height: 28px;
    }
    
    header[role="banner"] nav[role="navigation"] ul {
        display: none;
    }
    
    #menuToggle {
        display: block !important;
    }
    
    /* Hero */
    #hero {
        padding: 80px 0 60px;
    }
    
    #hero h1 {
        font-size: 2rem;
    }
    
    #hero p {
        font-size: 1rem;
    }
    
    #hero .hero-text, #hero .hero-visual {
        min-width: 100%;
    }
    
    /* FAQ */
    .faq-question {
        font-size: 1rem;
    }
    
    /* 页脚 */
    footer[role="contentinfo"] .footer-bottom {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    /* 返回顶部 */
    #backToTop {
        width: 44px;
        height: 44px;
        font-size: 1.2rem;
        line-height: 44px;
        bottom: 20px;
        right: 20px;
    }
}

@media (max-width: 480px) {
    .section {
        padding: 40px 0;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .section-title::after {
        width: 40px;
    }
    
    .container {
        padding: 0 12px;
    }
    
    #hero {
        padding: 60px 0 40px;
    }
    
    #hero h1 {
        font-size: 1.6rem;
    }
    
    #hero p {
        font-size: 0.95rem;
    }
    
    .btn {
        padding: 10px 22px;
        font-size: 0.95rem;
    }
    
    #searchBar input[type="search"] {
        padding: 10px 14px;
        font-size: 0.9rem;
    }
    
    #searchBar button {
        padding: 10px 18px;
        font-size: 0.9rem;
    }
    
    #stats .stats-display .stat-item .counter {
        font-size: 2.2rem;
    }
    
    #stats .stats-display .stat-item .suffix {
        font-size: 1.2rem;
    }
    
    footer[role="contentinfo"] {
        padding: 30px 0 15px;
    }
}

/* ===== 打印样式 ===== */
@media print {
    header[role="banner"],
    #backToTop,
    #searchBar,
    #mobileMenu,
    .breadcrumb {
        display: none !important;
    }
    
    body {
        background: #fff !important;
        color: #000 !important;
    }
    
    .card {
        background: #fff !important;
        box-shadow: none !important;
        border: 1px solid #ddd !important;
    }
    
    .section {
        padding: 20px 0 !important;
        page-break-inside: avoid;
    }
}