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

body {
    font-family: 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background: #f4f7fc;
    color: #1a1a2e;
    line-height: 1.6;
    transition: background 0.3s, color 0.3s;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

ul, ol {
    list-style: none;
}

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

/* 暗色模式 */
body.dark-mode {
    background: #0d0d1a;
    color: #e0e0e0;
}

body.dark-mode .nav-container,
body.dark-mode .hero-banner,
body.dark-mode .brand-intro,
body.dark-mode .about,
body.dark-mode .products,
body.dark-mode .advantages,
body.dark-mode .service,
body.dark-mode .solutions,
body.dark-mode .cases,
body.dark-mode .testimonials,
body.dark-mode .news,
body.dark-mode .faq,
body.dark-mode .howto,
body.dark-mode .contact,
body.dark-mode .sidebar,
body.dark-mode footer {
    background: #12122a;
    color: #e0e0e0;
}

body.dark-mode .product-card,
body.dark-mode .case-item,
body.dark-mode .testimonial-list blockquote,
body.dark-mode .faq-item,
body.dark-mode .sidebar .search-box,
body.dark-mode .sidebar .related-posts,
body.dark-mode .sidebar .latest-updates {
    background: #1c1c3a;
    color: #e0e0e0;
}

body.dark-mode .nav-menu a {
    color: #e0e0e0;
}

body.dark-mode .nav-menu a:hover {
    color: #f0c040;
}

body.dark-mode .breadcrumb a {
    color: #f0c040;
}

body.dark-mode .footer-content {
    background: #0d0d1a;
}

body.dark-mode .back-to-top {
    background: #f0c040;
    color: #1a1a2e;
}

/* === 导航栏 === */
header {
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(12px);
    background: rgba(255, 255, 255, 0.7);
    box-shadow: 0 2px 20px rgba(0,0,0,0.08);
    transition: background 0.3s;
}

body.dark-mode header {
    background: rgba(18, 18, 42, 0.8);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 12px 24px;
}

.logo a img {
    height: 40px;
    transition: transform 0.3s;
}

.logo a:hover img {
    transform: scale(1.05);
}

.nav-menu {
    display: flex;
    gap: 24px;
    transition: max-height 0.4s ease;
}

.nav-menu a {
    font-weight: 500;
    padding: 6px 0;
    position: relative;
    transition: color 0.3s;
}

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

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

.nav-menu a:hover {
    color: #f0c040;
}

.nav-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.nav-actions button {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    padding: 6px;
    border-radius: 50%;
    transition: background 0.3s, transform 0.2s;
}

.nav-actions button:hover {
    background: rgba(240, 192, 64, 0.2);
    transform: scale(1.1);
}

.mobile-menu-toggle {
    display: none;
    font-size: 28px;
}

/* 面包屑 */
.breadcrumb {
    max-width: 1200px;
    margin: 0 auto;
    padding: 10px 24px;
    font-size: 14px;
    color: #666;
}

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

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

body.dark-mode .breadcrumb {
    color: #aaa;
}

/* === 英雄横幅 === */
.hero-banner {
    position: relative;
    max-width: 1200px;
    margin: 20px auto;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0,0,0,0.15);
    background: #fff;
}

.banner-slider {
    position: relative;
    width: 100%;
    height: 400px;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.8s ease;
}

.slide.active {
    opacity: 1;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.banner-controls {
    position: absolute;
    top: 50%;
    width: 100%;
    display: flex;
    justify-content: space-between;
    transform: translateY(-50%);
    padding: 0 16px;
    pointer-events: none;
}

.banner-controls button {
    pointer-events: auto;
    background: rgba(255,255,255,0.5);
    border: none;
    font-size: 28px;
    padding: 12px 18px;
    border-radius: 50%;
    cursor: pointer;
    backdrop-filter: blur(4px);
    transition: background 0.3s, transform 0.2s;
}

.banner-controls button:hover {
    background: rgba(240, 192, 64, 0.8);
    transform: scale(1.1);
}

.banner-dots {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255,255,255,0.5);
    border: none;
    cursor: pointer;
    transition: background 0.3s, transform 0.2s;
}

.dot.active {
    background: #f0c040;
    transform: scale(1.2);
}

/* === 通用区域 === */
section {
    max-width: 1200px;
    margin: 40px auto;
    padding: 40px 24px;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    transition: background 0.3s, box-shadow 0.3s;
}

h1, h2, h3 {
    margin-bottom: 16px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

h1 {
    font-size: 2rem;
    color: #1a1a2e;
}

h2 {
    font-size: 1.6rem;
    color: #f0c040;
    position: relative;
    display: inline-block;
}

h2::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #f0c040, #e68a00);
    margin-top: 8px;
    border-radius: 2px;
}

p {
    margin-bottom: 12px;
    line-height: 1.8;
}

/* 品牌介绍 */
.brand-intro {
    background: linear-gradient(135deg, #fff 0%, #fef9e7 100%);
    border: 1px solid rgba(240, 192, 64, 0.2);
}

body.dark-mode .brand-intro {
    background: linear-gradient(135deg, #12122a, #1a1a3e);
}

/* 产品卡片 */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    margin-top: 20px;
}

.product-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
    transition: transform 0.4s, box-shadow 0.4s, background 0.3s;
    backdrop-filter: blur(4px);
    background: rgba(255,255,255,0.7);
    border: 1px solid rgba(255,255,255,0.3);
}

.product-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 12px 40px rgba(0,0,0,0.15);
}

.product-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    transition: transform 0.5s;
}

.product-card:hover img {
    transform: scale(1.05);
}

.product-card h3 {
    padding: 12px 16px 0;
    font-size: 1.2rem;
}

.product-card p {
    padding: 8px 16px 16px;
    font-size: 0.95rem;
    color: #555;
}

body.dark-mode .product-card {
    background: rgba(28, 28, 58, 0.8);
    border-color: rgba(255,255,255,0.1);
}

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

/* 优势列表 */
.advantages ul {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.advantages li {
    background: rgba(240, 192, 64, 0.1);
    padding: 16px 20px;
    border-radius: 12px;
    border-left: 4px solid #f0c040;
    transition: transform 0.3s, background 0.3s;
}

.advantages li:hover {
    transform: translateX(6px);
    background: rgba(240, 192, 64, 0.2);
}

/* 案例 */
.case-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    margin-top: 20px;
}

.case-item {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    transition: transform 0.4s, box-shadow 0.4s;
}

.case-item:hover {
    transform: scale(1.03);
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
}

.case-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.case-item p {
    padding: 16px;
}

/* 客户评价 */
.testimonial-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 16px;
}

.testimonial-list blockquote {
    background: rgba(255,255,255,0.6);
    backdrop-filter: blur(8px);
    padding: 24px;
    border-radius: 16px;
    border: 1px solid rgba(255,255,255,0.3);
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
}

.testimonial-list blockquote::before {
    content: '"';
    font-size: 48px;
    color: #f0c040;
    position: absolute;
    top: -10px;
    left: 16px;
    opacity: 0.3;
}

.testimonial-list blockquote:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}

.testimonial-list cite {
    display: block;
    margin-top: 12px;
    font-style: normal;
    color: #f0c040;
    font-weight: 500;
}

/* 新闻 */
.article-list {
    display: grid;
    gap: 20px;
    margin-top: 16px;
}

.article-list article {
    padding: 20px;
    background: rgba(255,255,255,0.5);
    backdrop-filter: blur(4px);
    border-radius: 12px;
    border: 1px solid rgba(240, 192, 64, 0.2);
    transition: transform 0.3s, background 0.3s;
}

.article-list article:hover {
    transform: translateX(6px);
    background: rgba(240, 192, 64, 0.08);
}

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

.read-more {
    color: #f0c040;
    font-weight: 500;
    transition: color 0.3s;
}

.read-more:hover {
    color: #d4a017;
}

/* FAQ */
.faq-list {
    display: grid;
    gap: 12px;
    margin-top: 16px;
}

.faq-item {
    background: rgba(255,255,255,0.5);
    backdrop-filter: blur(4px);
    border-radius: 12px;
    border: 1px solid rgba(240, 192, 64, 0.2);
    overflow: hidden;
    transition: background 0.3s;
}

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

.faq-question::after {
    content: '+';
    font-size: 1.4rem;
    transition: transform 0.3s;
}

.faq-item.active .faq-question::after {
    transform: rotate(45deg);
}

.faq-question:hover {
    background: rgba(240, 192, 64, 0.1);
}

.faq-answer {
    padding: 0 20px 16px;
    display: none;
    line-height: 1.7;
    color: #555;
}

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

/* 操作指南 */
.howto ol {
    padding-left: 24px;
    margin: 12px 0;
    list-style: decimal;
}

.howto ol li {
    margin-bottom: 8px;
    line-height: 1.7;
}

/* 联系我们 */
.contact address {
    font-style: normal;
    margin: 16px 0;
    line-height: 2;
}

.qr-codes {
    display: flex;
    gap: 24px;
    margin-top: 16px;
    flex-wrap: wrap;
}

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

.qr-item img {
    width: 120px;
    height: 120px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

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

.qr-item p {
    margin-top: 8px;
    font-size: 0.9rem;
}

/* 侧边栏 */
.sidebar {
    max-width: 1200px;
    margin: 0 auto 40px;
    padding: 24px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 16px rgba(0,0,0,0.06);
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 24px;
    transition: background 0.3s;
}

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

.search-box input {
    flex: 1;
    padding: 10px 16px;
    border: 2px solid #eee;
    border-radius: 30px;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.3s;
}

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

.search-box button {
    padding: 10px 20px;
    background: linear-gradient(135deg, #f0c040, #e68a00);
    border: none;
    border-radius: 30px;
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.search-box button:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(240, 192, 64, 0.4);
}

.related-posts ul {
    margin-top: 8px;
}

.related-posts li {
    margin-bottom: 8px;
}

.related-posts a {
    color: #f0c040;
    transition: color 0.3s;
}

.related-posts a:hover {
    color: #d4a017;
}

.latest-updates p {
    margin-top: 8px;
    font-size: 0.95rem;
}

/* 页脚 */
footer {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px 24px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 32px;
    padding: 32px;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.06);
    transition: background 0.3s;
}

.footer-links ul,
.footer-sitemap ul {
    margin-top: 8px;
}

.footer-links li,
.footer-sitemap li {
    margin-bottom: 6px;
}

.footer-links a,
.footer-sitemap a {
    color: #f0c040;
    transition: color 0.3s;
}

.footer-links a:hover,
.footer-sitemap a:hover {
    color: #d4a017;
}

.footer-info p {
    font-size: 0.9rem;
    color: #777;
    margin-bottom: 6px;
}

body.dark-mode .footer-info p {
    color: #aaa;
}

.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f0c040, #e68a00);
    color: #fff;
    border: none;
    font-size: 24px;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(0,0,0,0.2);
    transition: transform 0.3s, box-shadow 0.3s;
    z-index: 999;
}

.back-to-top:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

/* === 滚动动画 === */
.animated {
    animation: fadeInUp 0.6s ease forwards;
}

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

.product-card,
.case-item,
.testimonial-list blockquote {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.product-card.animated,
.case-item.animated,
.testimonial-list blockquote.animated {
    opacity: 1;
    transform: translateY(0);
}

/* === 响应式 === */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(255,255,255,0.95);
        backdrop-filter: blur(12px);
        padding: 20px;
        box-shadow: 0 8px 24px rgba(0,0,0,0.1);
        border-radius: 0 0 16px 16px;
        max-height: 0;
        overflow: hidden;
    }

    .nav-menu.active {
        display: flex;
        max-height: 500px;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .banner-slider {
        height: 250px;
    }

    .banner-controls button {
        font-size: 20px;
        padding: 8px 12px;
    }

    h1 {
        font-size: 1.5rem;
    }

    h2 {
        font-size: 1.3rem;
    }

    section {
        padding: 24px 16px;
        margin: 20px 12px;
    }

    .sidebar {
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 16px;
        margin: 0 12px 20px;
    }

    .footer-content {
        grid-template-columns: 1fr;
        padding: 24px;
    }

    .back-to-top {
        width: 44px;
        height: 44px;
        font-size: 20px;
        bottom: 20px;
        right: 20px;
    }
}

@media (max-width: 480px) {
    .nav-container {
        padding: 10px 16px;
    }

    .logo a img {
        height: 32px;
    }

    .banner-slider {
        height: 200px;
    }

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

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

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

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

    .qr-codes {
        justify-content: center;
    }
}