/* ========== 全局 ========== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg: #ffffff;
    --bg-dark: #0a0a0f;
    --text: #1a1a1a;
    --text-secondary: #666;
    --text-light: #eaeaea;
    --text-light-secondary: #999;
    --accent: #4f6ef7;
    --accent-hover: #3b5ae0;
    --border: #e5e5e5;
    --border-dark: rgba(255, 255, 255, 0.1);
    --radius: 12px;
    --max-width: 1200px;
    --nav-height: 72px;
}

html { scroll-behavior: smooth; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        "PingFang SC", "Microsoft YaHei", sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }

/* ========== 导航栏 ========== */
.navbar {
    position: fixed;
    top: 0; left: 0;
    width: 100%;
    height: var(--nav-height);
    z-index: 1000;
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 var(--border);
}

.navbar.on-dark.scrolled {
    background: rgba(10, 10, 15, 0.85);
    box-shadow: 0 1px 0 var(--border-dark);
}

.nav-container {
    max-width: var(--max-width);
    height: 100%;
    margin: 0 auto;
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1rem;
}

.logo-icon {
    width: 34px;
    height: 34px;
    border-radius: 9px;
    object-fit: contain;
    display: block;
    flex-shrink: 0;
}

.logo-text { color: var(--text); }
.navbar.on-dark .logo-text { color: var(--text-light); }

.nav-links {
    display: flex;
    align-items: center;
    gap: 36px;
}

.nav-links a {
    font-size: 0.9rem;
    color: var(--text-secondary);
    transition: color 0.2s ease;
}

.nav-links a:hover { color: var(--text); }

.navbar.on-dark .nav-links a { color: var(--text-light-secondary); }
.navbar.on-dark .nav-links a:hover { color: var(--text-light); }

.nav-download {
    padding: 8px 20px;
    background: var(--accent);
    color: #fff !important;
    border-radius: 8px;
    font-weight: 600;
    transition: background 0.2s ease, transform 0.2s ease;
}

.nav-download:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.menu-toggle span {
    display: block;
    width: 22px; height: 2px;
    background: var(--text);
    transition: 0.3s ease;
}

.navbar.on-dark .menu-toggle span { background: var(--text-light); }

/* ========== Hero ========== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 32px;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 60% 50% at 50% 0%, rgba(79, 110, 247, 0.12), transparent),
        radial-gradient(ellipse 40% 40% at 80% 60%, rgba(79, 110, 247, 0.06), transparent);
    pointer-events: none;
}

.hero-content {
    position: relative;
    max-width: var(--max-width);
    width: 100%;
    margin: 0 auto;
    padding-top: var(--nav-height);
}

.hero-tag {
    font-size: 0.8rem;
    letter-spacing: 4px;
    color: var(--accent);
    font-weight: 600;
    margin-bottom: 24px;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s ease forwards;
    animation-delay: 0.2s;
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 900;
    line-height: 1.15;
    letter-spacing: -1px;
    margin-bottom: 28px;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s ease forwards;
    animation-delay: 0.4s;
}

.gradient-text {
    background: linear-gradient(135deg, var(--accent), #7c5cfc, #4f6ef7);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-desc {
    max-width: 560px;
    font-size: 1.05rem;
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 40px;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s ease forwards;
    animation-delay: 0.6s;
}

.hero-actions {
    display: flex;
    gap: 16px;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s ease forwards;
    animation-delay: 0.8s;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 32px;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    transition: all 0.25s ease;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(79, 110, 247, 0.3);
}

.btn-large {
    padding: 18px 44px;
    font-size: 1.05rem;
}

.hero-scroll {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    font-size: 0.7rem;
    letter-spacing: 3px;
    color: var(--text-secondary);
    opacity: 0;
    animation: fadeUp 0.8s ease forwards;
    animation-delay: 1.2s;
}

.scroll-line {
    width: 1px; height: 40px;
    background: linear-gradient(to bottom, var(--border), transparent);
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

@keyframes fadeUp {
    to { opacity: 1; transform: translateY(0); }
}

/* ========== Section ========== */
.section { padding: 120px 32px; background: var(--bg); }
.section-dark { background: var(--bg-dark); color: var(--text-light); }

.section-container {
    max-width: var(--max-width);
    margin: 0 auto;
}

.section-head {
    display: flex;
    align-items: baseline;
    gap: 20px;
    margin-bottom: 64px;
}

.section-num {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--accent);
    letter-spacing: 2px;
}

.section-title {
    font-size: clamp(1.8rem, 3vw, 2.5rem);
    font-weight: 800;
    letter-spacing: -0.5px;
}

/* ========== 关于 ========== */
.about-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 80px;
    align-items: start;
}

.about-text p {
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.9;
    margin-bottom: 20px;
}

.about-text .lead {
    font-size: 1.25rem;
    color: var(--text);
    font-weight: 600;
    line-height: 1.7;
    margin-bottom: 28px;
}

.about-stats {
    display: flex;
    flex-direction: column;
    gap: 32px;
    padding-top: 8px;
}

.stat-item {
    border-left: 2px solid var(--accent);
    padding-left: 20px;
}

.stat-num {
    display: block;
    font-size: 2.5rem;
    font-weight: 900;
    color: var(--text);
    letter-spacing: -1px;
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* ========== 产品 ========== */
.products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 40px;
}

.product-card {
    padding: 40px 32px;
    border-radius: var(--radius);
    border: 1px solid var(--border-dark);
    background: rgba(255, 255, 255, 0.02);
    transition: transform 0.3s ease, border-color 0.3s ease, background 0.3s ease;
}

.product-card:hover {
    transform: translateY(-6px);
    border-color: rgba(79, 110, 247, 0.5);
    background: rgba(79, 110, 247, 0.05);
}

.product-icon {
    font-size: 1.6rem;
    color: var(--accent);
    margin-bottom: 20px;
}

.product-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-light);
}

.product-card p {
    font-size: 0.9rem;
    color: var(--text-light-secondary);
    line-height: 1.8;
}

.products-note {
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-light-secondary);
    letter-spacing: 1px;
}

/* ========== 技术 ========== */
.craft-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

.craft-item {
    padding-top: 24px;
    border-top: 2px solid var(--accent);
}

.craft-item h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 16px;
}

.craft-item p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.9;
}

/* ========== 下载 ========== */
.download-container { text-align: center; }

.download-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 900;
    line-height: 1.2;
    letter-spacing: -1px;
    margin-bottom: 24px;
}

.download-desc {
    font-size: 1.05rem;
    color: var(--text-light-secondary);
    margin-bottom: 40px;
}

/* ========== 页脚 ========== */
.footer {
    background: var(--bg-dark);
    border-top: 1px solid var(--border-dark);
    padding: 32px;
}

.footer-container {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.footer-left {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    color: var(--text-light);
    font-weight: 600;
}

.footer-right {
    font-size: 0.8rem;
    color: var(--text-light-secondary);
}

/* ========== 滚动动画 ========== */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ========== 响应式 ========== */
@media (max-width: 900px) {
    .products-grid { grid-template-columns: repeat(2, 1fr); }
    .craft-grid { grid-template-columns: 1fr; gap: 32px; }
    .about-grid { grid-template-columns: 1fr; gap: 48px; }
}

@media (max-width: 640px) {
    .nav-container { padding: 0 20px; }
    .section { padding: 80px 20px; }
    .hero { padding: 0 20px; }
    .hero-actions { flex-direction: column; }
    .btn { width: 100%; }

    .nav-links {
        position: fixed;
        top: var(--nav-height);
        left: 0;
        width: 100%;
        flex-direction: column;
        gap: 0;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        padding: 20px;
        border-bottom: 1px solid var(--border);
        transform: translateY(-120%);
        transition: transform 0.3s ease;
    }

    .nav-links.open { transform: translateY(0); }

    .nav-links a {
        padding: 14px 0;
        width: 100%;
        border-bottom: 1px solid var(--border);
    }

    .nav-download {
        text-align: center;
        margin-top: 12px;
        border-bottom: none !important;
    }

    .menu-toggle { display: flex; }
    .products-grid { grid-template-columns: 1fr; }

    .footer-container { flex-direction: column; gap: 16px; text-align: center; }
}