/* ===== 全局变量 ===== */
:root {
    --primary-color: #006666;
    --primary-dark: #004d4d;
    --primary-light: #008080;
    --secondary-bg: #f0f7f7;
    --neutral-gray-light: #f5f7fa;
    --neutral-gray: #e5e6eb;
    --text-dark: #1a1a1a;
    --text-light: #555555;
    --shadow: rgba(0, 0, 0, 0.06);
    --shadow-hover: rgba(0, 0, 0, 0.10);
    --border-radius: 8px;
    --border-radius-large: 12px;
    --transition: all 0.25s ease;
    --navbar-height: 80px;
}

* { margin:0; padding:0; box-sizing:border-box; }

body {
    font-family: 'Segoe UI', 'PingFang SC', system-ui, -apple-system, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background: var(--secondary-bg);
    min-height: 100vh;
}

/* ===== 导航栏 ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255,255,255,0.96);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--neutral-gray);
    z-index: 1000;
    padding: 1rem 0;
    transition: var(--transition);
}
.navbar.scrolled { box-shadow: 0 2px 10px var(--shadow); padding: 0.5rem 0; }

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

.logo { height: 50px; width: auto; }
.nav-brand { font-weight: 700; font-size: 1.1rem; margin-left: 0.5rem; display: none; }

.nav-search { flex: 1; max-width: 400px; margin: 0 2rem; }
.search-box { position: relative; width: 100%; }
.search-input {
    width: 100%;
    padding: 0.75rem 3rem 0.75rem 1rem;
    border: 2px solid var(--neutral-gray);
    border-radius: 25px;
    font-size: 1rem;
    transition: var(--transition);
    background: white;
}
.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0,102,102,0.15);
}
.search-btn {
    position: absolute;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    background: var(--primary-color);
    color: white;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}
.search-btn:hover { background: var(--primary-dark); }

.nav-links { display: flex; gap: 2rem; align-items: center; }
.nav-link {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 500;
    transition: var(--transition);
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
}
.nav-link:hover { color: var(--primary-color); background: var(--neutral-gray-light); }
.nav-link.active { color: var(--primary-color); position: relative; }
.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
}

.download-dropdown { position: relative; display: inline-block; }
.download-btn {
    background: var(--primary-color);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 12px rgba(0,102,102,0.3);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: inherit;
    font-size: inherit;
}
.download-btn::after { content: '▼'; font-size: 0.7rem; margin-left: 0.25rem; transition: transform 0.3s; }
.download-dropdown.active .download-btn::after { transform: rotate(180deg); }
.download-btn:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,102,102,0.4); }

.download-menu {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    background: white;
    border-radius: var(--border-radius);
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1001;
    border: 1px solid var(--neutral-gray);
    pointer-events: none;
}
.download-dropdown.active .download-menu { opacity: 1; visibility: visible; transform: translateY(0); pointer-events: auto; }
.download-menu-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1.25rem;
    color: var(--text-dark);
    text-decoration: none;
    transition: var(--transition);
    border-bottom: 1px solid var(--neutral-gray-light);
}
.download-menu-item:last-child { border-bottom: none; }
.download-menu-item:hover { background: var(--neutral-gray-light); color: var(--primary-color); }

.mobile-download-dropdown { display: none !important; }
.mobile-download { display: none !important; }

/* ===== 容器 ===== */
.container { max-width: 1200px; margin: 0 auto; padding: 0 2rem; }

/* ===== 标题通用 ===== */
.section-title { font-size: 2.2rem; text-align: center; margin-bottom: 0.5rem; }
.section-subtitle { text-align: center; color: var(--text-light); margin-bottom: 3rem; font-size: 1.1rem; }

/* ===== 英雄区 ===== */
.hero {
    min-height: 50vh;
    max-height: 720px;
    display: flex;
    align-items: center;
    padding: calc(40px + var(--navbar-height)) 0 40px;
    position: relative;
    overflow: hidden;
}
.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}
.hero-left { text-align: left; }
.hero-right { text-align: center; }

.hero-cta {
    background: white;
    padding: 3rem;
    border-radius: var(--border-radius-large);
    box-shadow: 0 10px 40px var(--shadow);
    border: 1px solid var(--neutral-gray);
}
.cta-title { font-size: 1.8rem; font-weight: 700; margin-bottom: 0.5rem; }
.cta-desc { color: var(--text-light); margin-bottom: 2rem; font-size: 1.1rem; }

.download-buttons { display: flex; flex-direction: column; gap: 1rem; margin-bottom: 2rem; }
.btn-large { padding: 1.2rem 2.5rem; font-size: 1.2rem; font-weight: 700; }

.download-features {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
}
.download-feature {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--text-light);
    font-size: 0.9rem;
}

.hero-bg {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="%23e5e6eb" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.12;
    z-index: -1;
}

.hero-title { font-size: 3.5rem; font-weight: 700; margin-bottom: 1.5rem; color: var(--text-dark); }
.hero-subtitle { font-size: 1.25rem; color: var(--text-dark); margin-bottom: 3rem; max-width: 600px; }

.hero-stats { display: flex; gap: 3rem; margin-bottom: 3rem; flex-wrap: wrap; }
.hero-left .hero-stats { justify-content: flex-start; }
.stat-item { text-align: center; }
.stat-number { font-size: 2.5rem; font-weight: 700; display: block; color: var(--primary-color); }
.stat-label { font-size: 0.9rem; color: var(--text-light); margin-top: 0.5rem; }

/* ===== 按钮 ===== */
.btn-primary {
    background: var(--primary-color);
    color: white;
    padding: 1rem 2rem;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: var(--transition);
    box-shadow: 0 4px 12px rgba(0,102,102,0.3);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border: none;
    cursor: pointer;
}
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,102,102,0.4); }

.btn-secondary {
    background: white;
    color: var(--text-dark);
    padding: 1rem 2rem;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    border: 2px solid var(--neutral-gray);
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}
.btn-secondary:hover { border-color: var(--primary-color); color: var(--primary-color); transform: translateY(-2px); }

/* ===== 功能特色 ===== */
.features { padding: 80px 0; background: white; }
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}
.feature-card {
    background: var(--secondary-bg);
    padding: 2rem;
    border-radius: var(--border-radius-large);
    text-align: center;
    transition: var(--transition);
    border: 1px solid transparent;
}
.feature-card:hover { transform: translateY(-5px); border-color: var(--primary-color); box-shadow: 0 8px 30px var(--shadow-hover); }
.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2.2rem;
}
.feature-title { font-size: 1.25rem; font-weight: 600; margin-bottom: 1rem; }
.feature-desc { color: var(--text-light); line-height: 1.6; }

/* ===== 教程区域 ===== */
.tutorials { padding: 80px 0; background: var(--secondary-bg); }
.tutorials-container { display: grid; grid-template-columns: 2fr 1fr; gap: 3rem; }
.tutorials-main {
    background: white;
    border-radius: var(--border-radius-large);
    overflow: hidden;
    box-shadow: 0 4px 20px var(--shadow);
}
.tutorials-header {
    background: var(--primary-color);
    color: white;
    padding: 1.5rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.tutorials-title { font-size: 1.25rem; font-weight: 600; }
.tutorials-more { color: white; text-decoration: none; font-size: 0.9rem; opacity: 0.85; transition: var(--transition); }
.tutorials-more:hover { opacity: 1; }

.tutorials-list { list-style: none; padding: 0; margin: 0; }
.tutorial-item {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--neutral-gray);
    display: flex;
    align-items: center;
    gap: 1.5rem;
    transition: var(--transition);
    cursor: pointer;
}
.tutorial-item:hover { background: var(--neutral-gray-light); }
.tutorial-item:last-child { border-bottom: none; }

.tutorial-cover {
    width: 140px;
    height: 100px;
    background: var(--neutral-gray-light);
    border-radius: var(--border-radius);
    flex-shrink: 0;
    overflow: hidden;
}
.tutorial-cover img { width: 100%; height: 100%; object-fit: cover; }

.tutorial-info h4 { font-size: 1rem; font-weight: 600; margin-bottom: 0.5rem; }
.tutorial-meta { font-size: 0.85rem; color: var(--text-light); display: flex; gap: 1rem; align-items: center; }
.tutorial-desc { font-size: 0.85rem; color: var(--text-light); margin-top: 0.25rem; }
.tutorial-badge {
    background: var(--primary-color);
    color: white;
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 600;
}

.tutorials-sidebar { display: flex; flex-direction: column; gap: 2rem; }
.sidebar-card {
    background: white;
    border-radius: var(--border-radius-large);
    padding: 2rem;
    box-shadow: 0 4px 20px var(--shadow);
}
.sidebar-title { font-size: 1.1rem; font-weight: 600; margin-bottom: 1.5rem; }

.faq-item {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--neutral-gray-light);
}
.faq-item:last-child { border-bottom: none; }
.faq-item h4 { font-size: 0.95rem; font-weight: 600; color: var(--text-dark); }
.faq-item p { font-size: 0.85rem; color: var(--text-light); margin-top: 0.2rem; }

.popular-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.tag {
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    background: var(--secondary-bg);
    color: var(--text-dark);
    border: 1px solid var(--neutral-gray);
    cursor: pointer;
    transition: var(--transition);
}
.tag:hover { background: var(--primary-color); color: white; border-color: var(--primary-color); }

/* ===== 评价 ===== */
.reviews { padding: 80px 0; background: white; }
.reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}
.review-card {
    background: white;
    border-radius: var(--border-radius-large);
    padding: 2rem;
    box-shadow: 0 4px 20px var(--shadow);
    border: 1px solid var(--neutral-gray);
}
.top-review {
    background: white;
    border-radius: var(--border-radius-large);
    padding: 1.5rem;
    box-shadow: 0 14px 40px rgba(0,0,0,0.06);
    border: 1px solid var(--neutral-gray);
    margin-bottom: 2rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    position: relative;
    border-left: 6px solid var(--primary-color);
}
.top-review .top-badge {
    position: absolute;
    right: 12px;
    top: -10px;
    background: var(--primary-color);
    color: white;
    font-size: 0.75rem;
    padding: 0.25rem 0.6rem;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
.review-avatar {
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    flex-shrink: 0;
}
.review-rating { color: #f5a623; }
.review-content { color: var(--text-light); line-height: 1.6; margin-bottom: 1rem; }
.review-footer { display: flex; justify-content: space-between; font-size: 0.85rem; color: var(--text-light); }

/* ===== 下载底部 ===== */
.download-section {
    padding: 80px 0;
    background: var(--primary-color);
    color: white;
    text-align: center;
}
.download-section h2 { font-size: 2.5rem; margin-bottom: 1rem; }
.download-section p { font-size: 1.2rem; margin-bottom: 2rem; opacity: 0.9; }
.download-section .btn-primary {
    background: white;
    color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(255,255,255,0.3);
}
.download-section .btn-primary:hover { background: var(--neutral-gray-light); }
.download-section .btn-secondary {
    background: transparent;
    color: white;
    border-color: rgba(255,255,255,0.5);
}
.download-section .btn-secondary:hover { background: rgba(255,255,255,0.1); border-color: white; }

/* ===== 页脚 ===== */
.footer {
    background: #1a1a1a;
    color: white;
    padding: 3rem 0 1rem;
}
.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}
.footer-section h3 { color: var(--primary-color); margin-bottom: 1rem; font-size: 1.1rem; }
.footer-section p, .footer-section a { color: rgba(255,255,255,0.8); text-decoration: none; line-height: 2; }
.footer-section a:hover { color: var(--primary-color); }
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.08);
    padding-top: 1.5rem;
    text-align: center;
    color: rgba(255,255,255,0.6);
}
.footer-disclaimer { color: rgba(255,255,255,0.4); font-size: 0.85rem; margin-top: 0.5rem; }
.download-count { font-size: 1rem; margin-top: 0.5rem; color: var(--primary-color); }
.download-count span { font-weight: 700; }

/* ===== 悬浮下载 ===== */
.floating-download {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 1000;
}
.scroll-to-top {
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: 0 4px 12px rgba(0,102,102,0.3);
}
.scroll-to-top.visible { opacity: 1; visibility: visible; }
.scroll-to-top:hover { background: var(--primary-dark); transform: scale(1.1); }
.floating-download-menu {
    position: absolute;
    bottom: calc(100% + 0.5rem);
    right: 0;
    top: auto !important;
    transform: translateY(10px);
}
.floating-download.active .floating-download-menu { opacity: 1; visibility: visible; transform: translateY(0); pointer-events: auto; }

/* ===== 响应式 ===== */
@media (max-width: 1024px) {
    .hero-content { grid-template-columns: 1fr; gap: 2rem; }
    .hero-left, .hero-right { text-align: center; }
    .hero-stats { justify-content: center !important; }
    .tutorials-container { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
    .nav-links { display: none; }
    .nav-brand { display: inline-block; }
    .mobile-download-dropdown { display: inline-block !important; margin-left: auto; }
    .mobile-download { display: inline-block !important; }
    .nav-search { display: none; }
    .hero-title { font-size: 2.2rem; }
    .hero { padding: calc(var(--navbar-height) + 10px) 0 20px; min-height: 40vh; max-height: none; }
    .hero-cta { padding: 1.5rem; }
    .stat-number { font-size: 2rem; }
    .features-grid { display: flex; gap: 1rem; overflow-x: auto; -webkit-overflow-scrolling: touch; scroll-snap-type: x mandatory; }
    .features-grid .feature-card { min-width: 80%; flex: 0 0 80%; scroll-snap-align: center; }
    .tutorials-sidebar { order: 2; margin-top: 1.5rem; }
    .tutorials-main { order: 1; }
    .reviews-grid { grid-template-columns: 1fr; }
    .tutorial-cover { width: 100px; height: 75px; }
}
@media (max-width: 480px) {
    .hero-title { font-size: 1.8rem; }
    .hero-stats { flex-direction: row; gap: 1rem; justify-content: space-between; }
    .btn-large { padding: 0.8rem 1.2rem; font-size: 1rem; }
    .container { padding: 0 1rem; }
    .tutorial-cover { width: 80px; height: 60px; }
    .tutorial-item { padding: 1rem; gap: 1rem; }
}