/* ===== AegisPDF 官网全局样式 ===== */

/* --- 基础变量 --- */
:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #dbeafe;
    --accent: #0ea5e9;
    --dark: #0f172a;
    --gray-900: #1e293b;
    --gray-700: #334155;
    --gray-500: #64748b;
    --gray-300: #cbd5e1;
    --gray-100: #f1f5f9;
    --white: #ffffff;
    --gradient: linear-gradient(135deg, #2563eb 0%, #0ea5e9 100%);
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
    --shadow-md: 0 4px 16px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 40px rgba(0,0,0,0.12);
    --radius: 12px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    color: var(--gray-900);
    line-height: 1.6;
    background: var(--white);
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

/* --- 导航栏 --- */
.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 1000;
    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--gray-100);
    transition: box-shadow 0.3s;
}
.navbar.scrolled { box-shadow: var(--shadow-sm); }
.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 20px;
    font-weight: 700;
    color: var(--primary);
}
.nav-logo svg { width: 32px; height: 32px; }
.nav-links { display: flex; gap: 32px; align-items: center; }
.nav-links a {
    font-size: 15px;
    font-weight: 500;
    color: var(--gray-700);
    transition: color 0.2s;
    position: relative;
}
.nav-links a:hover, .nav-links a.active { color: var(--primary); }
.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -4px; left: 0; right: 0;
    height: 2px;
    background: var(--primary);
    border-radius: 1px;
}
.nav-cta {
    background: var(--gradient) !important;
    color: var(--white) !important;
    padding: 8px 20px !important;
    border-radius: 8px;
    font-weight: 600 !important;
    transition: opacity 0.2s !important;
}
.nav-cta:hover { opacity: 0.9; }

/* 移动端菜单按钮 */
.nav-toggle { display: none; background: none; border: none; cursor: pointer; }
.nav-toggle span {
    display: block; width: 24px; height: 2px;
    background: var(--gray-700); margin: 5px 0;
    transition: 0.3s;
}

/* --- 通用区块 --- */
.section {
    padding: 100px 24px;
    max-width: 1200px;
    margin: 0 auto;
}
.section-tag {
    display: inline-block;
    background: var(--primary-light);
    color: var(--primary);
    padding: 4px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 12px;
}
.section-title {
    font-size: 40px;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 16px;
    color: var(--dark);
}
.section-desc {
    font-size: 18px;
    color: var(--gray-500);
    max-width: 640px;
    line-height: 1.7;
}
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}
.btn-primary {
    background: var(--gradient);
    color: var(--white);
    box-shadow: 0 4px 16px rgba(37,99,235,0.3);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 6px 24px rgba(37,99,235,0.4); }
.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}
.btn-outline:hover { background: var(--primary-light); }

/* --- Hero 区块 --- */
.hero {
    padding-top: 140px;
    padding-bottom: 80px;
    text-align: center;
    background: linear-gradient(180deg, var(--primary-light) 0%, var(--white) 100%);
}
.hero-inner { max-width: 800px; margin: 0 auto; padding: 0 24px; }
.hero-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: var(--white); border: 1px solid var(--gray-300);
    padding: 6px 16px; border-radius: 20px;
    font-size: 14px; color: var(--gray-700);
    margin-bottom: 24px;
    box-shadow: var(--shadow-sm);
}
.hero-badge span { color: var(--primary); font-weight: 600; }
.hero h1 {
    font-size: 52px;
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 20px;
    color: var(--dark);
}
.hero h1 .highlight {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero p {
    font-size: 20px;
    color: var(--gray-500);
    margin-bottom: 36px;
    line-height: 1.7;
}
.hero-buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.hero-visual {
    margin-top: 60px;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
}
.hero-visual img { width: 100%; }

/* --- 特性卡片 --- */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 48px;
}
.feature-card {
    background: var(--white);
    border: 1px solid var(--gray-100);
    border-radius: var(--radius);
    padding: 32px;
    transition: all 0.3s;
}
.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-light);
}
.feature-icon {
    width: 52px; height: 52px;
    background: var(--primary-light);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 20px;
    font-size: 24px;
}
.feature-card h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--dark);
}
.feature-card p {
    font-size: 15px;
    color: var(--gray-500);
    line-height: 1.6;
}

/* --- 产品特性（左右布局） --- */
.product-feature {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
    margin-bottom: 80px;
}
.product-feature.reverse { direction: rtl; }
.product-feature.reverse > * { direction: ltr; }
.product-feature-text h3 {
    font-size: 28px; font-weight: 700;
    margin-bottom: 16px; color: var(--dark);
}
.product-feature-text p {
    font-size: 16px; color: var(--gray-500); line-height: 1.7;
    margin-bottom: 20px;
}
.product-feature-img {
    background: var(--gray-100);
    border-radius: var(--radius);
    overflow: hidden;
    aspect-ratio: 4/3;
    display: flex; align-items: center; justify-content: center;
}
.feature-list { display: flex; flex-direction: column; gap: 12px; }
.feature-list li {
    display: flex; align-items: flex-start; gap: 10px;
    font-size: 15px; color: var(--gray-700);
}
.feature-list li::before {
    content: '✓';
    color: var(--primary);
    font-weight: 700;
    flex-shrink: 0;
}

/* --- 关于我们 --- */
.about-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 32px;
    margin-top: 48px;
}
.stat-card {
    text-align: center;
    padding: 32px 16px;
    background: var(--gray-100);
    border-radius: var(--radius);
}
.stat-card .stat-number {
    font-size: 36px; font-weight: 800;
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.stat-card .stat-label {
    font-size: 14px; color: var(--gray-500); margin-top: 4px;
}
.timeline { margin-top: 48px; position: relative; padding-left: 32px; }
.timeline::before {
    content: '';
    position: absolute;
    left: 8px; top: 0; bottom: 0;
    width: 2px;
    background: var(--gray-300);
}
.timeline-item {
    position: relative;
    margin-bottom: 32px;
    padding: 24px;
    background: var(--white);
    border: 1px solid var(--gray-100);
    border-radius: var(--radius);
}
.timeline-item::before {
    content: '';
    position: absolute;
    left: -28px; top: 28px;
    width: 12px; height: 12px;
    background: var(--primary);
    border-radius: 50%;
    border: 3px solid var(--primary-light);
}
.timeline-item h4 { font-size: 16px; font-weight: 700; color: var(--dark); }
.timeline-item .year {
    font-size: 13px; color: var(--primary); font-weight: 600; margin-bottom: 6px;
}
.timeline-item p { font-size: 14px; color: var(--gray-500); line-height: 1.6; }

/* --- 下载页 --- */
.download-hero {
    text-align: center;
    padding-top: 140px;
    padding-bottom: 40px;
    background: linear-gradient(180deg, var(--primary-light) 0%, var(--white) 100%);
}
.download-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 32px;
    margin-top: 48px;
}
.download-card {
    background: var(--white);
    border: 1px solid var(--gray-100);
    border-radius: var(--radius);
    padding: 40px 32px;
    text-align: center;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}
.download-card.featured {
    border-color: var(--primary);
    box-shadow: 0 4px 24px rgba(37,99,235,0.12);
}
.download-card.featured::before {
    content: attr(data-featured-text);
    position: absolute;
    top: 16px; right: -30px;
    background: var(--gradient);
    color: var(--white);
    padding: 4px 40px;
    font-size: 12px;
    font-weight: 600;
    transform: rotate(45deg);
}
.download-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.download-card .os-icon { font-size: 48px; margin-bottom: 16px; }
.download-card h3 { font-size: 22px; font-weight: 700; margin-bottom: 8px; }
.download-card .version { font-size: 14px; color: var(--gray-500); margin-bottom: 24px; }
.download-card .btn { width: 100%; justify-content: center; margin-bottom: 12px; }
.download-card .sys-req {
    font-size: 13px; color: var(--gray-500); margin-top: 16px;
    text-align: left; padding-top: 16px;
    border-top: 1px solid var(--gray-100);
}
.download-card .sys-req li { padding: 4px 0; }
.download-card .sys-req li::before { content: '• '; color: var(--gray-300); }

/* --- FAQ --- */
.faq-list { margin-top: 48px; max-width: 800px; }
.faq-item {
    border: 1px solid var(--gray-100);
    border-radius: var(--radius);
    margin-bottom: 12px;
    overflow: hidden;
}
.faq-question {
    padding: 20px 24px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--white);
    transition: background 0.2s;
}
.faq-question:hover { background: var(--gray-100); }
.faq-question .arrow { transition: transform 0.3s; font-size: 12px; color: var(--gray-500); }
.faq-item.open .faq-question .arrow { transform: rotate(180deg); }
.faq-answer {
    max-height: 0; overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    padding: 0 24px;
}
.faq-item.open .faq-answer {
    max-height: 300px;
    padding: 0 24px 20px;
}
.faq-answer p { font-size: 15px; color: var(--gray-500); line-height: 1.7; }

/* --- 页脚 --- */
.footer {
    background: var(--dark);
    color: var(--gray-300);
    padding: 60px 24px 30px;
    margin-top: 80px;
}
.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 48px;
}
.footer-brand h3 {
    font-size: 20px; font-weight: 700; color: var(--white); margin-bottom: 12px;
}
.footer-brand p { font-size: 14px; line-height: 1.7; }
.footer-col h4 {
    font-size: 14px; font-weight: 600; color: var(--white);
    text-transform: uppercase; letter-spacing: 1px;
    margin-bottom: 16px;
}
.footer-col a {
    display: block; font-size: 14px; color: var(--gray-300);
    padding: 4px 0; transition: color 0.2s;
}
.footer-col a:hover { color: var(--white); }
.footer-bottom {
    max-width: 1200px;
    margin: 40px auto 0;
    padding-top: 24px;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
    font-size: 13px;
}

/* --- 响应式 --- */
@media (max-width: 768px) {
    .nav-links { display: none; }
    .nav-toggle { display: block; }
    .nav-links.open {
        display: flex; flex-direction: column;
        position: absolute; top: 64px; left: 0; right: 0;
        background: var(--white);
        padding: 24px;
        border-bottom: 1px solid var(--gray-100);
        box-shadow: var(--shadow-md);
    }
    .hero h1 { font-size: 32px; }
    .hero p { font-size: 17px; }
    .section-title { font-size: 28px; }
    .product-feature { grid-template-columns: 1fr; gap: 32px; }
    .product-feature.reverse { direction: ltr; }
    .about-stats { grid-template-columns: repeat(2, 1fr); }
    .footer-inner { grid-template-columns: 1fr 1fr; }
    .download-cards { grid-template-columns: 1fr; }
}
