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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background: #f8f9fa;
    color: #222;
    line-height: 1.7;
    transition: background 0.3s, color 0.3s;
}

a {
    color: #0066cc;
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    text-decoration: underline;
    color: #f0c27f;
}

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

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

/* ===== 导航吸顶 ===== */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: linear-gradient(135deg, #1a1a2e 0%, #0f3460 100%);
    color: #fff;
    padding: 12px 0;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

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

.navbar .logo {
    font-size: 1.6rem;
    font-weight: 700;
    color: #f0c27f;
    text-shadow: 0 2px 10px rgba(240, 194, 127, 0.3);
}

.navbar .logo span {
    color: #fff;
}

.nav-links {
    display: flex;
    gap: 20px;
    list-style: none;
}

.nav-links a {
    color: #ddd;
    font-size: 0.95rem;
    transition: color 0.2s, transform 0.2s;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: #f0c27f;
    transition: width 0.3s;
}

.nav-links a:hover {
    color: #f0c27f;
    text-decoration: none;
    transform: translateY(-1px);
}

.nav-links a:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    background: none;
    border: 2px solid #f0c27f;
    color: #f0c27f;
    font-size: 1.5rem;
    padding: 4px 12px;
    cursor: pointer;
    border-radius: 6px;
    transition: background 0.2s, color 0.2s;
}

.menu-toggle:hover {
    background: rgba(240, 194, 127, 0.2);
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
        width: 100%;
        flex-direction: column;
        background: rgba(22, 33, 62, 0.95);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        padding: 20px;
        margin-top: 12px;
        border-radius: 12px;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    }

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

    .menu-toggle {
        display: block;
    }
}

/* ===== 面包屑 ===== */
.breadcrumb {
    background: linear-gradient(135deg, #ffffff, #f8f9fa);
    padding: 12px 0;
    border-bottom: 1px solid #e9ecef;
    font-size: 0.9rem;
}

.breadcrumb a {
    color: #555;
    transition: color 0.2s;
}

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

.breadcrumb span {
    color: #999;
}

/* ===== 轮播 Hero ===== */
.hero {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #0f3460 0%, #1a1a2e 50%, #16213e 100%);
    color: #fff;
    padding: 80px 0;
    min-height: 480px;
}

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

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

.hero-slide {
    display: none;
    animation: fadeIn 0.8s ease;
    position: relative;
    z-index: 1;
}

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

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

.hero-content {
    max-width: 700px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.hero h1 {
    font-size: 2.8rem;
    line-height: 1.2;
    margin-bottom: 20px;
    background: linear-gradient(135deg, #f0c27f, #ffd700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero p {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 30px;
    color: #e0e0e0;
}

.hero .btn {
    display: inline-block;
    background: linear-gradient(135deg, #f0c27f, #e0b06a);
    color: #1a1a2e;
    padding: 14px 36px;
    border-radius: 40px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(240, 194, 127, 0.3);
}

.hero .btn:hover {
    background: linear-gradient(135deg, #e0b06a, #d4a05a);
    transform: translateY(-2px) scale(1.02);
    text-decoration: none;
    box-shadow: 0 6px 25px rgba(240, 194, 127, 0.4);
}

.hero-nav {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 2;
}

.hero-nav button {
    background: rgba(255, 255, 255, 0.3);
    border: none;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s;
}

.hero-nav button.active {
    background: #f0c27f;
    box-shadow: 0 0 10px rgba(240, 194, 127, 0.5);
    transform: scale(1.2);
}

.hero-nav button:hover {
    background: #f0c27f;
    transform: scale(1.3);
}

/* ===== 通用区块 ===== */
.section {
    padding: 60px 0;
    transition: background 0.3s;
}

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

.section-title h2 {
    font-size: 2rem;
    color: #1a1a2e;
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
}

.section-title h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #f0c27f, #ffd700);
    border-radius: 2px;
}

.section-title p {
    color: #666;
    margin-top: 12px;
    font-size: 1rem;
}

.bg-light {
    background: #fff;
}

.bg-alt {
    background: linear-gradient(135deg, #f1f3f5, #e9ecef);
}

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

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

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

@media (max-width: 768px) {
    .grid-3, .grid-4, .grid-2 {
        grid-template-columns: 1fr;
    }
}

/* ===== 卡片 ===== */
.card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
    transition: all 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.1);
    border-color: rgba(240, 194, 127, 0.3);
}

.card h3 {
    font-size: 1.3rem;
    margin-bottom: 12px;
    color: #1a1a2e;
}

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

.card-icon {
    margin-bottom: 16px;
    transition: transform 0.3s;
}

.card:hover .card-icon {
    transform: scale(1.1);
}

/* ===== 文章卡片 ===== */
.article-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
    transition: all 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.article-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.1);
    border-color: rgba(240, 194, 127, 0.3);
}

.article-card .art-body {
    padding: 20px;
}

.article-card .art-body h3 {
    font-size: 1.15rem;
    margin-bottom: 8px;
    color: #1a1a2e;
    transition: color 0.2s;
}

.article-card:hover .art-body h3 {
    color: #f0c27f;
}

.article-card .art-body .meta {
    color: #888;
    font-size: 0.85rem;
    margin-bottom: 10px;
}

.article-card .art-body p {
    color: #555;
    font-size: 0.95rem;
}

.article-card .art-body .read-more {
    color: #0066cc;
    font-weight: 500;
    transition: color 0.2s;
}

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

/* ===== FAQ ===== */
.faq-item {
    border-bottom: 1px solid #e9ecef;
    padding: 18px 0;
    cursor: pointer;
    transition: background 0.2s;
}

.faq-item:hover {
    background: rgba(240, 194, 127, 0.05);
}

.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    font-size: 1.05rem;
    color: #1a1a2e;
}

.faq-question .icon {
    font-size: 1.5rem;
    transition: transform 0.3s;
}

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

.faq-item.open .faq-answer {
    max-height: 600px;
    padding-top: 16px;
}

.faq-item.open .faq-question .icon {
    transform: rotate(45deg);
}

/* ===== HowTo ===== */
.howto-step {
    display: flex;
    gap: 20px;
    margin-bottom: 24px;
    align-items: flex-start;
    padding: 15px;
    border-radius: 12px;
    transition: background 0.3s, transform 0.3s;
}

.howto-step:hover {
    background: rgba(240, 194, 127, 0.08);
    transform: translateX(5px);
}

.howto-step .step-num {
    background: linear-gradient(135deg, #1a1a2e, #0f3460);
    color: #fff;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
    box-shadow: 0 2px 10px rgba(15, 52, 96, 0.3);
}

.howto-step .step-content h4 {
    font-size: 1.1rem;
    margin-bottom: 6px;
    color: #1a1a2e;
}

/* ===== 联系方式 ===== */
.contact-info p {
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.contact-info strong {
    color: #1a1a2e;
}

/* ===== 页脚 ===== */
.footer {
    background: linear-gradient(135deg, #1a1a2e 0%, #0f3460 100%);
    color: #ccc;
    padding: 40px 0 20px;
    font-size: 0.9rem;
}

.footer a {
    color: #aaa;
    transition: color 0.2s;
}

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

.footer .grid-4 {
    gap: 20px;
}

.footer h4 {
    color: #fff;
    margin-bottom: 16px;
    font-size: 1.1rem;
    position: relative;
    display: inline-block;
}

.footer h4::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 30px;
    height: 2px;
    background: #f0c27f;
}

.footer ul {
    list-style: none;
}

.footer ul li {
    margin-bottom: 8px;
    transition: transform 0.2s;
}

.footer ul li:hover {
    transform: translateX(3px);
}

.footer .copyright {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    margin-top: 30px;
    padding-top: 20px;
    text-align: center;
}

/* ===== 返回顶部 ===== */
.back-top {
    position: fixed;
    bottom: 40px;
    right: 30px;
    background: linear-gradient(135deg, #1a1a2e, #0f3460);
    color: #f0c27f;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    border: none;
    z-index: 999;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

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

.back-top:hover {
    background: linear-gradient(135deg, #f0c27f, #e0b06a);
    color: #1a1a2e;
    transform: translateY(-3px);
    box-shadow: 0 6px 25px rgba(240, 194, 127, 0.4);
}

/* ===== 数字动画 ===== */
.stat-item {
    text-align: center;
    padding: 20px;
    transition: transform 0.3s;
}

.stat-item:hover {
    transform: scale(1.05);
}

.stat-number {
    font-size: 2.8rem;
    font-weight: 700;
    color: #1a1a2e;
    background: linear-gradient(135deg, #1a1a2e, #f0c27f);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    color: #666;
    margin-top: 8px;
}

/* ===== 暗黑模式 ===== */
body.dark {
    background: #121212;
    color: #e0e0e0;
}

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

body.dark .card {
    background: rgba(30, 30, 46, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: #ddd;
    border-color: rgba(255, 255, 255, 0.05);
}

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

body.dark .bg-light {
    background: #1a1a2a;
}

body.dark .bg-alt {
    background: linear-gradient(135deg, #16162a, #1a1a2a);
}

body.dark .breadcrumb {
    background: linear-gradient(135deg, #1a1a2a, #16162a);
    border-color: #333;
}

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

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

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

body.dark .section-title h2 {
    color: #f0c27f;
}

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

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

body.dark .faq-question {
    color: #f0c27f;
}

body.dark .stat-number {
    background: linear-gradient(135deg, #f0c27f, #ffd700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

body.dark .article-card {
    background: rgba(30, 30, 46, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-color: rgba(255, 255, 255, 0.05);
}

body.dark .article-card .art-body h3 {
    color: #f0c27f;
}

body.dark .article-card .art-body p {
    color: #bbb;
}

body.dark .article-card .art-body .meta {
    color: #888;
}

body.dark .contact-info strong {
    color: #f0c27f;
}

body.dark .howto-step .step-content h4 {
    color: #f0c27f;
}

body.dark .howto-step:hover {
    background: rgba(240, 194, 127, 0.1);
}

.dark-toggle {
    background: none;
    border: 2px solid #f0c27f;
    color: #f0c27f;
    padding: 6px 14px;
    border-radius: 30px;
    cursor: pointer;
    font-size: 0.9rem;
    margin-left: 12px;
    transition: all 0.3s;
}

.dark-toggle:hover {
    background: rgba(240, 194, 127, 0.2);
    transform: scale(1.05);
}

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

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

/* ===== 搜索 ===== */
.search-box {
    display: flex;
    gap: 8px;
    margin: 20px 0;
}

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

.search-box input:focus {
    border-color: #f0c27f;
    box-shadow: 0 0 0 3px rgba(240, 194, 127, 0.2);
}

.search-box button {
    padding: 12px 24px;
    background: linear-gradient(135deg, #1a1a2e, #0f3460);
    color: #fff;
    border: none;
    border-radius: 40px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s;
}

.search-box button:hover {
    background: linear-gradient(135deg, #f0c27f, #e0b06a);
    color: #1a1a2e;
    transform: translateY(-2px);
}

body.dark .search-box input {
    background: #2a2a3e;
    border-color: #444;
    color: #eee;
}

body.dark .search-box input:focus {
    border-color: #f0c27f;
}

/* ===== 图片懒加载占位 ===== */
.lazy-placeholder {
    background: linear-gradient(135deg, #e9ecef, #dee2e6);
    min-height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    border-radius: 12px;
}

/* ===== 响应式微调 ===== */
@media (max-width: 480px) {
    .hero h1 {
        font-size: 2rem;
    }

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

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

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

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