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

body {
    font-family: 'Segoe UI', 'PingFang SC', Roboto, 'Helvetica Neue', sans-serif;
    background: linear-gradient(135deg, #f5f9f5 0%, #e8f5e9 100%);
    color: #1a2e1a;
    line-height: 1.7;
    transition: background 0.4s ease, color 0.4s ease;
}

a {
    color: #2e7d32;
    text-decoration: none;
    transition: color 0.3s;
}

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

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

/* 导航吸顶 + 毛玻璃 */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.06);
    padding: 12px 0;
    transition: background 0.4s;
}

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

.logo {
    font-size: 1.6rem;
    font-weight: 700;
    color: #1b5e20;
    letter-spacing: 1px;
}

.logo span {
    color: #4caf50;
}

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

.nav-links a {
    color: #1a2e1a;
    font-weight: 500;
    transition: color 0.3s, transform 0.2s;
    position: relative;
}

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

.nav-links a:hover {
    color: #2e7d32;
    transform: translateY(-1px);
}

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

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.8rem;
    cursor: pointer;
    color: #1b5e20;
    transition: transform 0.2s;
}

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

@media (max-width: 768px) {
    .nav-links {
        display: none;
        flex-direction: column;
        width: 100%;
        margin-top: 12px;
        gap: 12px;
        background: rgba(249, 253, 249, 0.95);
        backdrop-filter: blur(8px);
        padding: 16px;
        border-radius: 12px;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    }

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

    .menu-toggle {
        display: block;
    }
}

/* 返回顶部 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: linear-gradient(135deg, #2e7d32, #4caf50);
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    font-size: 1.5rem;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(46, 125, 50, 0.3);
    z-index: 999;
    transition: transform 0.3s, box-shadow 0.3s;
}

.back-to-top:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 8px 28px rgba(46, 125, 50, 0.4);
    background: linear-gradient(135deg, #1b5e20, #2e7d32);
}

/* Banner 渐变轮播 */
.banner {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 50%, #a5d6a7 100%);
    border-radius: 16px;
    margin: 20px 0;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
}

.banner-slides {
    display: flex;
    transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.banner-slide {
    min-width: 100%;
    padding: 80px 40px;
    text-align: center;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(4px);
}

.banner-slide h2 {
    font-size: 2.2rem;
    color: #1b5e20;
    margin-bottom: 16px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.banner-slide p {
    font-size: 1.15rem;
    color: #2e7d32;
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.8;
}

.banner-controls {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 14px;
}

.banner-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: rgba(165, 214, 167, 0.6);
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.3s;
}

.banner-dot.active {
    background: #2e7d32;
    border-color: #fff;
    transform: scale(1.2);
    box-shadow: 0 0 12px rgba(46, 125, 50, 0.4);
}

.banner-dot:hover {
    background: #4caf50;
    transform: scale(1.1);
}

/* 通用标题 */
.section-title {
    text-align: center;
    margin: 56px 0 32px;
}

.section-title h2 {
    font-size: 2rem;
    color: #1b5e20;
    position: relative;
    display: inline-block;
}

.section-title h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #4caf50, #81c784);
    margin: 12px auto 0;
    border-radius: 2px;
    transition: width 0.4s;
}

.section-title h2:hover::after {
    width: 100px;
}

/* 卡片网格 */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 28px;
    margin: 24px 0;
}

.card {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 16px;
    padding: 28px 24px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
    transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94), box-shadow 0.35s, background 0.4s;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.1);
    background: rgba(255, 255, 255, 0.95);
}

.card h3 {
    color: #1b5e20;
    margin-bottom: 12px;
    font-size: 1.35rem;
    transition: color 0.3s;
}

.card:hover h3 {
    color: #2e7d32;
}

.card p {
    color: #2e3b2e;
}

.card svg {
    display: block;
    margin: 0 auto 16px;
    width: 64px;
    height: 64px;
    transition: transform 0.4s;
}

.card:hover svg {
    transform: scale(1.1) rotate(4deg);
}

/* 文章列表 */
.article-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.article-item {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(6px);
    padding: 20px 28px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
    transition: transform 0.3s, box-shadow 0.3s, background 0.4s;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.article-item:hover {
    transform: translateX(6px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.06);
    background: rgba(255, 255, 255, 0.95);
}

.article-item h3 {
    color: #1b5e20;
    font-size: 1.2rem;
    transition: color 0.3s;
}

.article-item:hover h3 {
    color: #2e7d32;
}

.article-item .meta {
    color: #558b2f;
    font-size: 0.9rem;
    margin: 6px 0;
}

.article-item p {
    color: #2e3b2e;
}

.read-more {
    display: inline-block;
    margin-top: 8px;
    color: #2e7d32;
    font-weight: 500;
    transition: transform 0.3s, color 0.3s;
}

.read-more:hover {
    transform: translateX(4px);
    color: #1b5e20;
}

/* FAQ */
.faq-item {
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(6px);
    border-radius: 12px;
    margin-bottom: 12px;
    padding: 16px 24px;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
    transition: transform 0.3s, box-shadow 0.3s, background 0.4s;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.faq-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.06);
    background: rgba(255, 255, 255, 0.9);
}

.faq-question {
    font-weight: 600;
    color: #1b5e20;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: color 0.3s;
}

.faq-question::after {
    content: '+';
    font-size: 1.6rem;
    color: #4caf50;
    transition: transform 0.4s, color 0.3s;
}

.faq-item.active .faq-question::after {
    content: '−';
    transform: rotate(180deg);
    color: #2e7d32;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94), padding 0.4s;
    padding-top: 0;
    color: #2e3b2e;
}

.faq-item.active .faq-answer {
    max-height: 500px;
    padding-top: 14px;
}

/* HowTo */
.howto {
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
    border-radius: 16px;
    padding: 36px;
    margin: 32px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}

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

.howto ol {
    padding-left: 24px;
    color: #1a2e1a;
}

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

.howto li:hover {
    transform: translateX(4px);
}

/* 联系方式 */
.contact-info {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(8px);
    border-radius: 16px;
    padding: 36px;
    margin: 32px 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: background 0.4s;
}

.contact-info div {
    text-align: center;
    padding: 16px;
    border-radius: 12px;
    transition: background 0.3s, transform 0.3s;
}

.contact-info div:hover {
    background: rgba(76, 175, 80, 0.08);
    transform: translateY(-4px);
}

.contact-info svg {
    width: 40px;
    height: 40px;
    margin-bottom: 8px;
    transition: transform 0.3s;
}

.contact-info div:hover svg {
    transform: scale(1.15);
}

/* 页脚 */
.footer {
    background: linear-gradient(135deg, #1b5e20 0%, #2e7d32 100%);
    color: #e8f5e9;
    padding: 40px 0;
    margin-top: 48px;
}

.footer a {
    color: #a5d6a7;
    transition: color 0.3s, transform 0.2s;
    display: inline-block;
}

.footer a:hover {
    color: #c8e6c9;
    transform: translateX(4px);
}

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

.footer h4 {
    margin-bottom: 12px;
    color: #c8e6c9;
    font-size: 1.1rem;
}

.footer ul {
    list-style: none;
}

.footer ul li {
    margin-bottom: 6px;
}

.copyright {
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid rgba(46, 125, 50, 0.4);
    margin-top: 24px;
    font-size: 0.9rem;
    opacity: 0.9;
}

/* 暗黑模式 */
body.dark-mode {
    background: linear-gradient(135deg, #0d1f0d 0%, #1a2e1a 100%);
    color: #d0e0d0;
}

body.dark-mode .navbar {
    background: rgba(18, 33, 18, 0.85);
    backdrop-filter: blur(12px);
}

body.dark-mode .navbar a {
    color: #c8e6c9;
}

body.dark-mode .card,
body.dark-mode .article-item,
body.dark-mode .faq-item,
body.dark-mode .contact-info {
    background: rgba(26, 46, 26, 0.8);
    backdrop-filter: blur(8px);
    color: #d0e0d0;
    border-color: rgba(76, 175, 80, 0.15);
}

body.dark-mode .card h3,
body.dark-mode .article-item h3,
body.dark-mode .faq-question {
    color: #a5d6a7;
}

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

body.dark-mode .banner {
    background: linear-gradient(135deg, #1b2e1b 0%, #2a3e2a 100%);
}

body.dark-mode .banner-slide h2 {
    color: #c8e6c9;
}

body.dark-mode .banner-slide p {
    color: #a5d6a7;
}

body.dark-mode .howto {
    background: linear-gradient(135deg, #1a2e1a 0%, #2a3e2a 100%);
}

body.dark-mode .footer {
    background: linear-gradient(135deg, #0d1f0d 0%, #1b5e20 100%);
}

body.dark-mode .search-box input {
    background: #1a2e1a;
    color: #d0e0d0;
    border-color: #2e7d32;
}

body.dark-mode .back-to-top {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

/* 滚动动画 */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94), transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

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

/* 搜索 */
.search-box {
    display: flex;
    gap: 8px;
    align-items: center;
}

.search-box input {
    padding: 8px 16px;
    border: 1px solid #c8e6c9;
    border-radius: 24px;
    outline: none;
    background: #f9fdf9;
    color: #1a2e1a;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.search-box input:focus {
    border-color: #4caf50;
    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.15);
}

.search-box button {
    background: linear-gradient(135deg, #2e7d32, #4caf50);
    color: #fff;
    border: none;
    border-radius: 24px;
    padding: 8px 20px;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    font-weight: 500;
}

.search-box button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(46, 125, 50, 0.3);
}

/* 数字动画 */
.stat-number {
    font-size: 2.4rem;
    font-weight: 700;
    color: #2e7d32;
    transition: color 0.4s;
}

body.dark-mode .stat-number {
    color: #a5d6a7;
}

/* 图片懒加载占位 */
.lazy-placeholder {
    background: linear-gradient(135deg, #e0f2e0 0%, #c8e6c9 100%);
    border-radius: 8px;
    min-height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #558b2f;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.7; }
    50% { opacity: 1; }
}

/* 面包屑 */
nav[aria-label="面包屑导航"] {
    margin: 16px 0;
    font-size: 0.9rem;
    color: #558b2f;
}

nav[aria-label="面包屑导航"] a {
    color: #2e7d32;
    transition: color 0.3s;
}

nav[aria-label="面包屑导航"] a:hover {
    color: #1b5e20;
}

/* 响应式增强 */
@media (max-width: 768px) {
    .banner-slide {
        padding: 50px 20px;
    }

    .banner-slide h2 {
        font-size: 1.6rem;
    }

    .banner-slide p {
        font-size: 1rem;
    }

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

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

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

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

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

    .search-box input {
        flex: 1;
    }
}

@media (max-width: 480px) {
    .banner-slide {
        padding: 36px 16px;
    }

    .banner-slide h2 {
        font-size: 1.3rem;
    }

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

    .card {
        padding: 20px;
    }
}

/* 暗黑模式按钮 */
#darkToggle {
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    transition: transform 0.3s;
}

#darkToggle:hover {
    transform: rotate(20deg) scale(1.1);
}

/* 站点地图区域 */
section h4 {
    color: #1b5e20;
    margin-bottom: 12px;
}

section ul {
    list-style: none;
}

section ul li {
    margin-bottom: 6px;
}

section ul li a {
    transition: color 0.3s, padding-left 0.3s;
}

section ul li a:hover {
    padding-left: 4px;
    color: #1b5e20;
}

/* 服务承诺区域 */
#contact + div {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(6px);
    border-radius: 16px;
    padding: 24px;
    margin: 16px 0;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: background 0.4s;
}

body.dark-mode #contact + div {
    background: rgba(26, 46, 26, 0.8);
}