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

html {
    scroll-behavior: smooth;
}

body {
    font-family: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: #f0f2f5;
    color: #1a1a2e;
    line-height: 1.6;
    transition: background 0.3s ease, color 0.3s ease;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

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

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

ul, ol {
    list-style: none;
}

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

/* 头部导航 */
header {
    background: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: white;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

body.dark header {
    background: rgba(15, 15, 26, 0.95);
}

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

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, #f7971e, #ffd200);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
    cursor: default;
}

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

nav a {
    padding: 8px 0;
    border-bottom: 2px solid transparent;
    transition: border-color 0.3s ease, color 0.3s ease;
    font-weight: 500;
    position: relative;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(135deg, #f7971e, #ffd200);
    transition: width 0.3s ease;
}

nav a:hover::after,
nav a.active::after {
    width: 100%;
}

nav a:hover,
nav a.active {
    color: #ffd200;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.8rem;
    cursor: pointer;
    padding: 4px;
    transition: transform 0.2s ease;
}

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

/* 英雄区域 */
.hero {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    color: white;
    padding: 80px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
    min-height: 400px;
    display: flex;
    align-items: center;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 50%, rgba(255, 210, 0, 0.1) 0%, transparent 60%);
    animation: heroGlow 8s ease-in-out infinite;
    pointer-events: none;
}

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

.hero .container {
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    font-weight: 800;
    letter-spacing: -0.02em;
    animation: fadeInUp 0.8s ease-out;
}

.hero p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 30px;
    opacity: 0.9;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

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

/* 按钮 */
.btn {
    display: inline-block;
    background: linear-gradient(135deg, #f7971e, #ffd200);
    color: #1a1a2e;
    padding: 14px 40px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
    border: none;
    cursor: pointer;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(255, 210, 0, 0.3);
}

.btn:active {
    transform: translateY(-1px);
}

/* 通用区块 */
.section {
    padding: 60px 0;
}

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

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: linear-gradient(135deg, #f7971e, #ffd200);
    margin: 10px auto;
    border-radius: 2px;
}

/* 网格布局 */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

/* 卡片 */
.card {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

body.dark .card {
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    border-color: rgba(255, 255, 255, 0.05);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
}

body.dark .card:hover {
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.card svg {
    margin-bottom: 20px;
    transition: transform 0.3s ease;
}

.card:hover svg {
    transform: scale(1.05);
}

.card h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.card p {
    color: #555;
    line-height: 1.7;
}

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

/* 面包屑 */
.breadcrumb {
    padding: 15px 0;
    font-size: 0.9rem;
    color: #888;
}

.breadcrumb a {
    color: #f7971e;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: #ffd200;
}

.breadcrumb span {
    margin: 0 5px;
}

/* 统计数字 */
.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    background: linear-gradient(135deg, #f7971e, #ffd200);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

/* FAQ */
.faq-item {
    border-bottom: 1px solid #eee;
    padding: 20px 0;
    cursor: pointer;
    transition: background 0.3s ease;
}

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

.faq-item:hover {
    background: rgba(247, 151, 30, 0.03);
}

body.dark .faq-item:hover {
    background: rgba(255, 210, 0, 0.03);
}

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

.faq-question::after {
    content: '+';
    font-size: 1.5rem;
    transition: transform 0.3s ease, content 0.3s ease;
    flex-shrink: 0;
    color: #f7971e;
}

.faq-item.open .faq-question::after {
    content: '−';
    transform: rotate(180deg);
}

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

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

.faq-item.open .faq-answer {
    max-height: 500px;
    padding-top: 15px;
}

/* 步骤 */
.howto-step {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    align-items: flex-start;
    padding: 20px;
    border-radius: 16px;
    transition: background 0.3s ease, transform 0.3s ease;
}

.howto-step:hover {
    background: rgba(247, 151, 30, 0.05);
    transform: translateX(5px);
}

body.dark .howto-step:hover {
    background: rgba(255, 210, 0, 0.05);
}

.howto-num {
    background: linear-gradient(135deg, #f7971e, #ffd200);
    color: #1a1a2e;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
    font-size: 1.1rem;
}

/* 文章卡片 */
.article-card {
    margin-bottom: 30px;
}

.article-card h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
    transition: color 0.3s ease;
}

.article-card:hover h3 {
    color: #f7971e;
}

.article-card .date {
    font-size: 0.85rem;
    color: #888;
    display: block;
    margin-bottom: 8px;
}

/* 底部 */
.footer {
    background: #1a1a2e;
    color: #ccc;
    padding: 40px 0;
}

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

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

.footer h4 {
    color: white;
    margin-bottom: 15px;
    font-size: 1.1rem;
    font-weight: 600;
}

.footer a {
    display: block;
    margin-bottom: 8px;
    transition: color 0.3s ease, padding-left 0.3s ease;
    color: #aaa;
}

.footer a:hover {
    color: #ffd200;
    padding-left: 5px;
}

.footer-bottom {
    border-top: 1px solid #333;
    padding-top: 20px;
    margin-top: 30px;
    text-align: center;
    font-size: 0.9rem;
    color: #888;
}

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

/* 返回顶部 */
.back-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f7971e, #ffd200);
    color: #1a1a2e;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
    z-index: 999;
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
}

.back-top.show {
    display: flex;
    opacity: 1;
    transform: translateY(0);
}

.back-top:hover {
    transform: scale(1.1) translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 210, 0, 0.4);
}

/* 暗黑模式切换 */
.dark-toggle {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #1a1a2e;
    color: white;
    border: 2px solid #ffd200;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    transition: all 0.3s ease;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

.dark-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(255, 210, 0, 0.3);
}

body.dark .dark-toggle {
    background: #ffd200;
    color: #1a1a2e;
    border-color: #1a1a2e;
}

/* 搜索框 */
.search-box {
    display: flex;
    gap: 10px;
    max-width: 500px;
    margin: 0 auto;
}

.search-box input {
    flex: 1;
    padding: 12px 20px;
    border-radius: 50px;
    border: 2px solid #ddd;
    outline: none;
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    background: white;
}

.search-box input:focus {
    border-color: #f7971e;
    box-shadow: 0 0 0 3px rgba(247, 151, 30, 0.1);
}

body.dark .search-box input {
    background: #222;
    border-color: #444;
    color: white;
}

body.dark .search-box input:focus {
    border-color: #ffd200;
    box-shadow: 0 0 0 3px rgba(255, 210, 0, 0.1);
}

.search-box button {
    padding: 12px 30px;
    border-radius: 50px;
    background: linear-gradient(135deg, #f7971e, #ffd200);
    border: none;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.search-box button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 210, 0, 0.3);
}

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

.banner-slide {
    display: none;
    animation: fadeIn 0.8s ease;
}

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

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

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

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

.banner-dot.active {
    background: #f7971e;
    transform: scale(1.2);
}

.banner-dot:hover {
    background: #ffd200;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .header-inner {
        padding: 10px 0;
    }

    nav ul {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(26, 26, 46, 0.98);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        padding: 20px;
        gap: 15px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
        animation: slideDown 0.3s ease;
    }

    @keyframes slideDown {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    nav ul.open {
        display: flex;
    }

    nav a {
        padding: 10px 0;
        font-size: 1.1rem;
    }

    .menu-toggle {
        display: block;
    }

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

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

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

    .hero {
        padding: 50px 0;
        min-height: 300px;
    }

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

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

    .card {
        padding: 20px;
    }

    .footer-grid {
        gap: 20px;
    }

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

    .back-top {
        right: 15px;
        bottom: 15px;
    }

    .dark-toggle {
        left: 15px;
        bottom: 15px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

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

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

    .btn {
        padding: 12px 30px;
        font-size: 1rem;
    }

    .section {
        padding: 40px 0;
    }

    .section-title {
        font-size: 1.4rem;
        margin-bottom: 30px;
    }

    .howto-step {
        flex-direction: column;
        gap: 10px;
        padding: 15px;
    }

    .howto-num {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }

    .grid-3 {
        gap: 20px;
    }
}

/* 滚动动画支持 */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* 选中样式 */
::selection {
    background: rgba(247, 151, 30, 0.3);
    color: #1a1a2e;
}

body.dark ::selection {
    background: rgba(255, 210, 0, 0.3);
    color: #0f0f1a;
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f0f2f5;
}

body.dark ::-webkit-scrollbar-track {
    background: #0f0f1a;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #f7971e, #ffd200);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #e68a1a, #e6bd00);
}

/* 辅助类 */
.text-center {
    text-align: center;
}

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

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

/* 暗色模式下的特定调整 */
body.dark .section[style*="background: #f8f9fa"] {
    background: #1a1a2e !important;
}

body.dark .section[style*="background: #f8f9fa"] .card {
    background: rgba(255, 255, 255, 0.05);
}

/* 渐变背景区块 */
body.dark .section[style*="background: #1a1a2e"] {
    background: #0a0a14 !important;
}

/* 企业优势区块 */
.section[style*="background: #1a1a2e"] .stat-number {
    font-size: 3rem;
}

.section[style*="background: #1a1a2e"] p {
    color: #ccc;
    margin-top: 5px;
}

/* 导航栏 active 状态增强 */
nav a.active {
    color: #ffd200;
}

/* 卡片内链接样式 */
.card a {
    color: #f7971e;
    font-weight: 600;
    transition: color 0.3s ease;
}

.card a:hover {
    color: #ffd200;
}

/* 产品中心 SVG 图标悬停效果 */
.card svg circle[fill="#f7971e"],
.card svg circle[fill="#ffd200"] {
    transition: opacity 0.3s ease;
}

.card:hover svg circle[fill="#f7971e"] {
    opacity: 0.8;
}

.card:hover svg circle[fill="#ffd200"] {
    opacity: 0.8;
}

/* 页脚链接分隔 */
.footer a:last-child {
    margin-bottom: 0;
}

/* 文章卡片阅读全文链接 */
.article-card a[style*="color:#f7971e"] {
    display: inline-block;
    margin-top: 10px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.article-card a[style*="color:#f7971e"]:hover {
    color: #ffd200 !important;
    transform: translateX(5px);
}

/* 暗色模式下的面包屑 */
body.dark .breadcrumb {
    color: #aaa;
}

body.dark .breadcrumb a {
    color: #ffd200;
}

/* 轮播指示器暗色模式 */
body.dark .banner-dot {
    background: #555;
}

body.dark .banner-dot.active {
    background: #ffd200;
}

/* 步骤数字暗色模式适配 */
body.dark .howto-num {
    color: #1a1a2e;
}

/* 确保所有过渡平滑 */
* {
    transition-property: background-color, border-color, color, fill, stroke, opacity, box-shadow, transform;
    transition-duration: 0.3s;
    transition-timing-function: ease;
}