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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #f9fafb;
    transition: background 0.3s, color 0.3s;
    scroll-behavior: smooth;
}

body.dark {
    background: #1a1a2e;
    color: #e0e0e0;
}

a {
    color: #1a73e8;
    text-decoration: none;
    transition: color 0.2s;
}

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

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

/* === 头部导航 === */
header {
    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.08);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: background 0.3s, box-shadow 0.3s;
}

body.dark header {
    background: rgba(22, 33, 62, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

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

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: #1a73e8;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: transform 0.3s;
}

.logo:hover {
    transform: scale(1.02);
}

.logo svg {
    width: 40px;
    height: 40px;
    filter: drop-shadow(0 2px 4px rgba(26, 115, 232, 0.3));
}

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

nav ul li a {
    font-size: 1rem;
    color: #333;
    padding: 6px 0;
    border-bottom: 2px solid transparent;
    transition: border-color 0.2s, color 0.2s, transform 0.2s;
    position: relative;
}

body.dark nav ul li a {
    color: #e0e0e0;
}

nav ul li a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: #1a73e8;
    transition: width 0.3s;
}

nav ul li a:hover::after {
    width: 100%;
}

nav ul li a:hover {
    border-bottom-color: transparent;
    text-decoration: none;
    transform: translateY(-1px);
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.8rem;
    cursor: pointer;
    color: #333;
    transition: color 0.3s;
}

body.dark .menu-toggle {
    color: #e0e0e0;
}

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

.search-bar input {
    padding: 8px 16px;
    border: 1px solid #ccc;
    border-radius: 24px;
    font-size: 0.9rem;
    outline: none;
    width: 200px;
    transition: border-color 0.3s, box-shadow 0.3s, background 0.3s, color 0.3s;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(4px);
}

body.dark .search-bar input {
    background: rgba(42, 42, 74, 0.7);
    border-color: #555;
    color: #e0e0e0;
}

.search-bar input:focus {
    border-color: #1a73e8;
    box-shadow: 0 0 0 3px rgba(26, 115, 232, 0.15);
}

.search-bar button {
    background: #1a73e8;
    color: #fff;
    border: none;
    padding: 8px 20px;
    border-radius: 24px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background 0.3s, transform 0.2s, box-shadow 0.3s;
}

.search-bar button:hover {
    background: #1557b0;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(26, 115, 232, 0.3);
}

/* === 渐变Banner Hero === */
.hero {
    background: linear-gradient(135deg, #1a73e8, #0d47a1, #1a73e8);
    background-size: 200% 200%;
    animation: gradientShift 8s ease infinite;
    color: #fff;
    padding: 100px 0 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.05) 0%, transparent 70%);
    animation: heroGlow 10s ease-in-out infinite;
}

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

.hero h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    font-weight: 700;
    text-shadow: 0 2px 10px rgba(0,0,0,0.2);
    animation: fadeInUp 0.8s ease;
}

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

.hero .cta {
    display: inline-block;
    background: #fff;
    color: #1a73e8;
    padding: 14px 44px;
    border-radius: 30px;
    font-size: 1.1rem;
    font-weight: 600;
    transition: transform 0.3s, box-shadow 0.3s, background 0.3s, color 0.3s;
    animation: fadeInUp 0.8s ease 0.4s both;
    position: relative;
    overflow: hidden;
}

.hero .cta::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;
}

.hero .cta:hover::before {
    left: 100%;
}

.hero .cta:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    background: #f0f4ff;
    text-decoration: none;
}

.hero .carousel-dots {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
}

.hero .carousel-dots span {
    width: 12px;
    height: 12px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.3s, transform 0.3s;
}

.hero .carousel-dots span.active {
    background: #fff;
    transform: scale(1.4);
    box-shadow: 0 0 10px rgba(255,255,255,0.5);
}

/* === 通用章节 === */
section {
    padding: 70px 0;
}

section h2 {
    font-size: 2.2rem;
    text-align: center;
    margin-bottom: 40px;
    color: #1a73e8;
    position: relative;
    animation: fadeInUp 0.6s ease;
}

section h2:after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, #1a73e8, #0d47a1);
    margin: 14px auto 0;
    border-radius: 2px;
}

body.dark section h2 {
    color: #4dabf7;
}

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

.card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 16px;
    padding: 28px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s, box-shadow 0.3s, background 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

body.dark .card {
    background: rgba(22, 33, 62, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
    background: rgba(255, 255, 255, 0.9);
}

body.dark .card:hover {
    background: rgba(30, 42, 74, 0.9);
}

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

.card:hover h3 {
    color: #0d47a1;
}

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

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

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

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

/* === 关于区域 === */
.about-content {
    display: flex;
    flex-wrap: wrap;
    gap: 40px;
    align-items: center;
}

.about-text {
    flex: 1;
    min-width: 280px;
}

.about-text p {
    margin-bottom: 16px;
    font-size: 1.05rem;
    line-height: 1.8;
}

.about-text ul {
    list-style: none;
    padding: 0;
}

.about-text ul li {
    padding: 8px 0;
    padding-left: 28px;
    position: relative;
    transition: transform 0.2s;
}

.about-text ul li:hover {
    transform: translateX(4px);
}

.about-text ul li:before {
    content: "✓";
    color: #1a73e8;
    position: absolute;
    left: 0;
    font-weight: 700;
    font-size: 1.1rem;
}

.about-image {
    flex: 1;
    min-width: 280px;
    text-align: center;
}

.about-image svg {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    transition: transform 0.3s;
}

.about-image svg:hover {
    transform: scale(1.02);
}

/* === FAQ === */
.faq-item {
    border-bottom: 1px solid #e0e0e0;
    padding: 18px 0;
    transition: border-color 0.3s;
}

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

.faq-question {
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    transition: color 0.3s;
    user-select: none;
}

.faq-question:hover {
    color: #1a73e8;
}

.faq-question .arrow {
    transition: transform 0.3s;
    font-size: 1.2rem;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease, padding 0.3s ease;
    padding-left: 8px;
    color: #555;
    line-height: 1.7;
}

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

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

.faq-question.open .arrow {
    transform: rotate(180deg);
}

/* === 步骤指南 === */
.howto-steps ol {
    counter-reset: step;
    list-style: none;
    padding: 0;
}

.howto-steps ol li {
    counter-increment: step;
    padding: 18px 0 18px 50px;
    position: relative;
    font-size: 1.05rem;
    border-left: 3px solid #1a73e8;
    margin-left: 20px;
    padding-left: 40px;
    transition: border-color 0.3s, background 0.3s;
}

.howto-steps ol li:hover {
    border-left-color: #0d47a1;
    background: rgba(26, 115, 232, 0.03);
}

.howto-steps ol li:before {
    content: counter(step);
    position: absolute;
    left: -18px;
    top: 14px;
    background: linear-gradient(135deg, #1a73e8, #0d47a1);
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    box-shadow: 0 2px 8px rgba(26, 115, 232, 0.3);
    transition: transform 0.3s;
}

.howto-steps ol li:hover:before {
    transform: scale(1.1);
}

.howto-steps .note {
    background: rgba(232, 240, 254, 0.7);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    padding: 20px;
    border-radius: 12px;
    margin-top: 24px;
    border: 1px solid rgba(26, 115, 232, 0.1);
}

body.dark .howto-steps .note {
    background: rgba(30, 42, 74, 0.7);
}

/* === 文章列表 === */
.articles .article-item {
    display: flex;
    gap: 24px;
    padding: 24px 0;
    border-bottom: 1px solid #e0e0e0;
    transition: background 0.3s, padding 0.3s;
}

body.dark .articles .article-item {
    border-color: #444;
}

.articles .article-item:last-child {
    border: none;
}

.articles .article-item:hover {
    padding-left: 12px;
    background: rgba(26, 115, 232, 0.02);
}

.articles .article-item .thumb {
    flex-shrink: 0;
    width: 120px;
    height: 80px;
    background: linear-gradient(135deg, #e8f0fe, #d0e0ff);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s, box-shadow 0.3s;
}

body.dark .articles .article-item .thumb {
    background: linear-gradient(135deg, #2a2a4a, #1e2a4a);
}

.articles .article-item:hover .thumb {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(26, 115, 232, 0.15);
}

.articles .article-item .info h4 {
    font-size: 1.1rem;
    margin-bottom: 6px;
    color: #1a73e8;
    transition: color 0.3s;
}

.articles .article-item:hover .info h4 {
    color: #0d47a1;
}

.articles .article-item .info .meta {
    font-size: 0.85rem;
    color: #888;
    margin-bottom: 8px;
}

body.dark .articles .article-item .info .meta {
    color: #aaa;
}

.articles .article-item .info p {
    font-size: 0.95rem;
    color: #555;
    line-height: 1.6;
}

body.dark .articles .article-item .info p {
    color: #b0b0b0;
}

.articles .article-item .info .read-more {
    color: #1a73e8;
    font-weight: 600;
    font-size: 0.9rem;
    transition: color 0.3s, gap 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.articles .article-item .info .read-more:hover {
    color: #0d47a1;
    gap: 8px;
    text-decoration: none;
}

/* === 客户评价 === */
.testimonials .testimonial {
    background: rgba(255, 255, 255, 0.7);
    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.06);
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

body.dark .testimonials .testimonial {
    background: rgba(22, 33, 62, 0.7);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

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

.testimonials .testimonial p {
    font-style: italic;
    margin-bottom: 12px;
    font-size: 1.05rem;
    position: relative;
}

.testimonials .testimonial p::before {
    content: '"';
    font-size: 2rem;
    color: #1a73e8;
    opacity: 0.3;
    position: absolute;
    left: -16px;
    top: -8px;
}

.testimonials .testimonial .author {
    font-weight: 600;
    color: #1a73e8;
}

/* === 联系信息 === */
.contact-info {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: center;
}

.contact-info .item {
    text-align: center;
    padding: 24px 20px;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 16px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    flex: 1;
    min-width: 200px;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

body.dark .contact-info .item {
    background: rgba(22, 33, 62, 0.7);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.contact-info .item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.contact-info .item svg {
    width: 40px;
    height: 40px;
    margin-bottom: 12px;
    fill: #1a73e8;
    transition: transform 0.3s;
}

.contact-info .item:hover svg {
    transform: scale(1.1);
}

.contact-info .item h4 {
    font-size: 1.1rem;
    margin-bottom: 6px;
}

.contact-info .item p {
    color: #555;
    font-size: 0.95rem;
}

body.dark .contact-info .item p {
    color: #b0b0b0;
}

/* === 订阅区域 === */
.newsletter {
    background: linear-gradient(135deg, #1a73e8, #0d47a1);
    color: #fff;
    padding: 50px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.newsletter::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 80%, rgba(255,255,255,0.05) 0%, transparent 60%);
}

.newsletter h2 {
    color: #fff;
    margin-bottom: 20px;
}

.newsletter h2:after {
    background: #fff;
}

.newsletter p {
    position: relative;
    z-index: 1;
}

.newsletter form {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    max-width: 500px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.newsletter input[type="email"] {
    padding: 14px 24px;
    border: none;
    border-radius: 30px;
    font-size: 1rem;
    flex: 1;
    min-width: 200px;
    outline: none;
    transition: box-shadow 0.3s;
}

.newsletter input[type="email"]:focus {
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3);
}

.newsletter button {
    background: #0d47a1;
    color: #fff;
    border: none;
    padding: 14px 34px;
    border-radius: 30px;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.3s, transform 0.2s, box-shadow 0.3s;
}

.newsletter button:hover {
    background: #0a3a7a;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* === 页脚 === */
.footer {
    background: #1a1a2e;
    color: #ccc;
    padding: 50px 0 20px;
}

.footer .container {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: space-between;
}

.footer .col {
    flex: 1;
    min-width: 180px;
}

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

.footer .col h4::after {
    content: '';
    display: block;
    width: 30px;
    height: 2px;
    background: #1a73e8;
    margin-top: 6px;
}

.footer .col ul {
    list-style: none;
    padding: 0;
}

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

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

.footer .col ul li a {
    color: #aaa;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.footer .col ul li a:hover {
    color: #1a73e8;
    text-decoration: none;
}

.footer .copyright {
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid #333;
    margin-top: 24px;
    font-size: 0.85rem;
    line-height: 1.8;
}

.footer .copyright p {
    margin-bottom: 4px;
}

/* === 返回顶部 === */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: linear-gradient(135deg, #1a73e8, #0d47a1);
    color: #fff;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s, transform 0.3s, box-shadow 0.3s;
    z-index: 999;
    box-shadow: 0 4px 12px rgba(26, 115, 232, 0.3);
}

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

.back-to-top:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(26, 115, 232, 0.4);
}

/* === 面包屑 === */
.breadcrumb {
    background: rgba(240, 244, 248, 0.7);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    padding: 14px 0;
    font-size: 0.9rem;
}

body.dark .breadcrumb {
    background: rgba(30, 42, 74, 0.7);
}

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

.breadcrumb a:hover {
    color: #0d47a1;
}

.breadcrumb span {
    color: #888;
}

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

/* === 暗黑模式切换 === */
.dark-mode-toggle {
    background: none;
    border: 2px solid #1a73e8;
    color: #1a73e8;
    padding: 6px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: background 0.3s, color 0.3s, transform 0.2s;
    margin-left: 12px;
}

.dark-mode-toggle:hover {
    background: #1a73e8;
    color: #fff;
    transform: scale(1.05);
}

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

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

/* === 通用动画 === */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* === 响应式设计 === */
@media (max-width: 768px) {
    nav ul {
        display: none;
        flex-direction: column;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        position: absolute;
        top: 60px;
        left: 0;
        width: 100%;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
        padding: 20px;
        gap: 12px;
    }

    body.dark nav ul {
        background: rgba(22, 33, 62, 0.95);
        backdrop-filter: blur(12px);
    }

    nav ul.open {
        display: flex;
    }

    .menu-toggle {
        display: block;
    }

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

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

    .hero {
        padding: 70px 0 60px;
    }

    .search-bar input {
        width: 140px;
    }

    .about-content {
        flex-direction: column;
    }

    .articles .article-item {
        flex-direction: column;
    }

    .articles .article-item .thumb {
        width: 100%;
        height: 120px;
    }

    .footer .container {
        flex-direction: column;
        gap: 20px;
    }

    section {
        padding: 50px 0;
    }

    section h2 {
        font-size: 1.8rem;
    }

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

    .contact-info .item {
        min-width: 150px;
    }

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

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.6rem;
    }

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

    .hero .cta {
        padding: 12px 32px;
        font-size: 1rem;
    }

    .search-bar input {
        width: 100px;
    }

    .logo {
        font-size: 1.4rem;
    }

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

    .card {
        padding: 20px;
    }

    .newsletter input[type="email"] {
        min-width: 160px;
    }
}