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

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

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

a {
    color: #d32f2f;
    text-decoration: none;
}

a:hover {
    color: #b71c1c;
}

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

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 12px 28px;
    background: linear-gradient(135deg, #d32f2f, #b71c1c);
    color: #fff;
    border-radius: 30px;
    border: none;
    cursor: pointer;
    font-size: 16px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(211, 47, 47, 0.4);
}

/* 头部导航 */
header {
    background: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(10px);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

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

.logo {
    font-size: 24px;
    font-weight: 700;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 10px;
}

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

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

nav a {
    color: #fff;
    font-size: 15px;
    transition: color 0.3s;
}

nav a:hover {
    color: #d32f2f;
}

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

.menu-toggle span {
    width: 28px;
    height: 3px;
    background: #fff;
    border-radius: 3px;
    transition: 0.3s;
}

/* 英雄区渐变Banner */
.hero {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    padding: 120px 0 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero h1 {
    font-size: 48px;
    color: #fff;
    margin-bottom: 20px;
    font-weight: 800;
    background: linear-gradient(135deg, #fff, #d32f2f);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    font-size: 20px;
    color: #ccc;
    max-width: 700px;
    margin: 0 auto 30px;
}

.hero .btn {
    font-size: 18px;
    padding: 15px 40px;
}

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

.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.section-title h2 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 15px;
}

.section-title p {
    font-size: 18px;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

/* 圆角卡片 */
.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.card {
    background: #fff;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s, box-shadow 0.3s;
    backdrop-filter: blur(5px);
}

body.dark .card {
    background: #1a1a2e;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

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

.card h3 {
    font-size: 22px;
    margin-bottom: 15px;
}

.card p {
    color: #555;
    margin-bottom: 20px;
}

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

.card svg {
    width: 60px;
    height: 60px;
    margin-bottom: 20px;
    border-radius: 12px;
}

/* 轮播Banner */
.banner-carousel {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
    margin: 40px 0;
}

.banner-slide {
    display: none;
    padding: 60px;
    background: linear-gradient(135deg, #1a1a2e, #0f3460);
    color: #fff;
    text-align: center;
    min-height: 300px;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

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

.banner-slide h3 {
    font-size: 32px;
    margin-bottom: 15px;
}

.banner-slide p {
    font-size: 18px;
    max-width: 600px;
}

.carousel-controls {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
}

.carousel-controls button {
    background: #d32f2f;
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 30px;
    cursor: pointer;
    transition: background 0.3s;
}

.carousel-controls button:hover {
    background: #b71c1c;
}

/* FAQ手风琴 */
.faq-item {
    border-bottom: 1px solid #ddd;
    padding: 20px 0;
    cursor: pointer;
}

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

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

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
    padding-top: 10px;
    color: #555;
}

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

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

/* 操作指南步骤 */
.howto-steps {
    list-style: none;
    counter-reset: step;
}

.howto-steps li {
    counter-increment: step;
    padding: 20px 0 20px 60px;
    position: relative;
    border-left: 3px solid #d32f2f;
    margin-left: 20px;
}

.howto-steps li::before {
    content: counter(step);
    position: absolute;
    left: -18px;
    top: 20px;
    width: 36px;
    height: 36px;
    background: #d32f2f;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

/* 页脚 */
.footer {
    background: #1a1a2e;
    color: #ccc;
    padding: 60px 0 30px;
}

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

.footer h4 {
    color: #fff;
    margin-bottom: 20px;
    font-size: 18px;
}

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

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

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid #333;
    margin-top: 40px;
    font-size: 14px;
}

/* 回到顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: #d32f2f;
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 24px;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 20px rgba(211, 47, 47, 0.4);
    z-index: 999;
    transition: transform 0.3s;
}

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

/* 暗色模式切换按钮 */
.dark-toggle {
    background: transparent;
    border: 2px solid #fff;
    color: #fff;
    padding: 8px 16px;
    border-radius: 30px;
    cursor: pointer;
    font-size: 14px;
    transition: 0.3s;
}

.dark-toggle:hover {
    background: #fff;
    color: #1a1a2e;
}

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

.search-box input {
    flex: 1;
    padding: 12px 20px;
    border: 2px solid #ddd;
    border-radius: 30px;
    font-size: 16px;
    outline: none;
    transition: border 0.3s;
}

body.dark .search-box input {
    background: #1a1a2e;
    border-color: #333;
    color: #fff;
}

.search-box input:focus {
    border-color: #d32f2f;
}

.search-box button {
    padding: 12px 24px;
    background: #d32f2f;
    color: #fff;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    transition: background 0.3s;
}

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

/* 面包屑导航 */
.breadcrumb {
    padding: 20px 0;
    font-size: 14px;
    color: #888;
}

.breadcrumb a {
    color: #d32f2f;
    margin: 0 5px;
}

.breadcrumb span {
    margin: 0 5px;
}

/* 新闻网格 */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.news-card {
    background: #fff;
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s;
}

body.dark .news-card {
    background: #1a1a2e;
}

.news-card:hover {
    transform: translateY(-5px);
}

.news-card h4 {
    font-size: 20px;
    margin-bottom: 10px;
}

.news-card .date {
    color: #999;
    font-size: 14px;
    margin-bottom: 10px;
}

.news-card p {
    color: #555;
    margin-bottom: 15px;
}

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

.news-card .btn {
    padding: 8px 20px;
    font-size: 14px;
}

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

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

/* 数字动画 */
.number-animate {
    font-size: 48px;
    font-weight: 800;
    color: #d32f2f;
    display: inline-block;
}

/* 合作伙伴链接 */
.partner-links {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    margin-top: 20px;
}

.partner-links a {
    background: rgba(211, 47, 47, 0.1);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    transition: background 0.3s;
}

.partner-links a:hover {
    background: rgba(211, 47, 47, 0.2);
}

/* 响应式布局 */
@media (max-width: 768px) {
    header .container {
        flex-wrap: wrap;
    }

    .menu-toggle {
        display: flex;
    }

    nav ul {
        display: none;
        flex-direction: column;
        width: 100%;
        padding: 20px 0;
        gap: 15px;
    }

    nav ul.open {
        display: flex;
    }

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

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

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

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

    .banner-slide {
        padding: 30px 20px;
    }

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

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

@media (max-width: 480px) {
    .hero {
        padding: 80px 0 60px;
    }

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

    .btn {
        padding: 10px 20px;
        font-size: 14px;
    }
}