:root {
    --primary: #0066ff;
    --primary-dark: #0052cc;
    --primary-light: #e8f1ff;
    --accent: #7c3aed;
    --text: #0f172a;
    --text-muted: #64748b;
    --text-soft: #475569;
    --bg: #ffffff;
    --bg-muted: #f8fafc;
    --bg-elevated: #ffffff;
    --border: #e2e8f0;
    --border-soft: rgba(226, 232, 240, 0.8);
    --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 8px 30px rgba(15, 23, 42, 0.08);
    --shadow-lg: 0 24px 64px rgba(15, 23, 42, 0.12);
    --radius: 16px;
    --radius-lg: 24px;
    --radius-full: 9999px;
    --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Noto Sans SC", sans-serif;
    --font-display: var(--font);
    --nav-height: 72px;
    --container: 1200px;
    --transition: 0.2s ease;
}

@media (prefers-color-scheme: dark) {
    :root.auto-theme {
        --text: #f1f5f9;
        --text-muted: #94a3b8;
        --text-soft: #cbd5e1;
        --bg: #0b1120;
        --bg-muted: #111827;
        --bg-elevated: #1e293b;
        --border: #334155;
        --border-soft: rgba(51, 65, 85, 0.8);
        --primary-light: rgba(0, 102, 255, 0.15);
    }
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: var(--font);
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}

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

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ── Navbar v2 ── */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--nav-height);
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-soft);
    z-index: 1000;
    transition: box-shadow var(--transition);
}

.navbar.scrolled {
    box-shadow: var(--shadow-sm);
}

.navbar__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--nav-height);
    gap: 1rem;
}

.logo img {
    height: 36px;
    width: auto;
    display: block;
}

.logo a {
    display: inline-flex;
    align-items: center;
}

.nav-panel {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 1.75rem;
    margin: 0;
    padding: 0;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-soft);
    font-weight: 500;
    font-size: 0.9375rem;
    transition: color var(--transition);
}

.nav-links a:hover { color: var(--primary); }

.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.lang-switcher {
    display: flex;
    background: var(--bg-muted);
    border-radius: var(--radius-full);
    padding: 3px;
    border: 1px solid var(--border);
}

.lang-switcher__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 28px;
    padding: 0 8px;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 600;
    text-decoration: none;
    color: var(--text-muted);
    transition: all var(--transition);
}

.lang-switcher__btn.is-active,
.lang-switcher__btn:hover {
    background: var(--bg);
    color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: transform var(--transition);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.9375rem;
    text-decoration: none;
    transition: all 0.25s ease;
    border: 2px solid transparent;
    cursor: pointer;
}

.btn--sm { padding: 0.5rem 1rem; font-size: 0.8125rem; border-radius: 10px; }

.btn.primary, .btn--primary {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.btn.primary:hover, .btn--primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 8px 24px rgba(0, 102, 255, 0.25);
}

.btn.secondary, .btn--secondary {
    background: transparent;
    color: var(--primary);
    border-color: var(--primary);
}

.btn.secondary:hover, .btn--secondary:hover {
    background: var(--primary-light);
}

.btn--nav-cta {
    background: var(--text);
    color: #fff;
    border-color: var(--text);
    white-space: nowrap;
}

.btn--nav-cta:hover {
    background: #1e293b;
    transform: translateY(-1px);
}

.btn--ghost {
    background: rgba(255,255,255,0.12);
    color: #fff;
    border-color: rgba(255,255,255,0.3);
}

.btn--ghost:hover {
    background: rgba(255,255,255,0.2);
}

/* ── Hero v2 ── */
.hero-v2 {
    position: relative;
    min-height: 100vh;
    padding: calc(var(--nav-height) + 4rem) 0 5rem;
    overflow: hidden;
    background: var(--bg);
}

.hero-v2--slim {
    min-height: auto;
    padding: calc(var(--nav-height) + 5rem) 0 4.5rem;
    display: flex;
    align-items: center;
}

.hero-v2__slim {
    position: relative;
    max-width: 760px;
    margin: 0 auto;
    text-align: center;
}

.hero-v2__brand {
    font-size: clamp(2.75rem, 6vw, 4.25rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    line-height: 1;
    color: var(--text);
    margin-bottom: 1rem;
}

.hero-v2__slim .hero-v2__eyebrow {
    margin-bottom: 1rem;
}

.hero-v2__slim h1 {
    font-size: clamp(1.5rem, 3.2vw, 2.125rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.3;
    margin-bottom: 0.875rem;
    color: var(--text-soft);
}

.hero-v2__slim .hero-v2__subtitle {
    font-size: 1.125rem;
    margin-bottom: 1.75rem;
    max-width: 540px;
    margin-left: auto;
    margin-right: auto;
}

.hero-v2__split {
    justify-content: center;
    margin-bottom: 2rem;
}

.hero-v2__stats--compact {
    justify-content: center;
    gap: 2rem;
    padding-top: 0.5rem;
    border-top: 1px solid var(--border);
}

.tech-card__icon--ai,
.tech-card__icon--privacy,
.tech-card__icon--speed,
.tech-card__icon--scale {
    position: relative;
}

.tech-card__icon--ai::before { content: ""; width: 18px; height: 18px; border: 2px solid var(--primary); border-radius: 4px; transform: rotate(45deg); }
.tech-card__icon--privacy::before { content: ""; width: 14px; height: 16px; border: 2px solid var(--primary); border-radius: 4px 4px 6px 6px; }
.tech-card__icon--speed::before { content: ""; width: 0; height: 0; border-left: 10px solid transparent; border-right: 10px solid transparent; border-bottom: 16px solid var(--primary); }
.tech-card__icon--scale::before { content: ""; width: 18px; height: 12px; border-bottom: 2px solid var(--primary); border-left: 2px solid var(--primary); box-shadow: inset 4px 0 0 var(--primary), inset 10px 0 0 var(--primary); }

/* keep old layout helpers for product pages that still load style.css */
.hero-v2__grid { /* legacy */ }

@media (max-width: 768px) {
    .hero-v2--slim { padding: calc(var(--nav-height) + 3.5rem) 0 3rem; }
    .hero-v2__stats--compact { gap: 1.25rem; }
}

.hero-v2__bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.hero-v2__bg::before {
    content: "";
    position: absolute;
    top: -20%;
    right: -10%;
    width: 60%;
    height: 70%;
    background: radial-gradient(circle, rgba(0, 102, 255, 0.12) 0%, transparent 65%);
}

.hero-v2__bg::after {
    content: "";
    position: absolute;
    bottom: -10%;
    left: -5%;
    width: 40%;
    height: 50%;
    background: radial-gradient(circle, rgba(124, 58, 237, 0.08) 0%, transparent 70%);
}

.hero-v2__grid {
    position: relative;
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 3rem;
    align-items: center;
}

.hero-v2__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--primary);
    background: var(--primary-light);
    border: 1px solid rgba(0, 102, 255, 0.15);
    padding: 6px 14px;
    border-radius: var(--radius-full);
    margin-bottom: 1.25rem;
}

.hero-v2 h1 {
    font-size: clamp(2.25rem, 5vw, 3.5rem);
    line-height: 1.12;
    letter-spacing: -0.03em;
    font-weight: 800;
    color: var(--text);
    margin-bottom: 1rem;
}

.hero-v2__subtitle {
    font-size: clamp(1.125rem, 2vw, 1.375rem);
    color: var(--text-soft);
    margin-bottom: 1.25rem;
    font-weight: 500;
}

.hero-v2__intro {
    font-size: 1.0625rem;
    line-height: 1.8;
    color: var(--text-muted);
    margin-bottom: 2rem;
    max-width: 540px;
}

.hero-v2__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.875rem;
    margin-bottom: 2.5rem;
}

.hero-v2__stats {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem 2.5rem;
}

.hero-stat__val {
    display: block;
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text);
}

.hero-stat__label {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.hero-v2__visual {
    position: relative;
}

.hero-bento {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.hero-bento__main {
    grid-column: 1 / -1;
    background: linear-gradient(145deg, #f0f6ff, #e8f1ff);
    border-radius: var(--radius-lg);
    padding: 2rem;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
}

.hero-bento__main img {
    max-width: 280px;
    border-radius: 32px;
    box-shadow: var(--shadow-lg);
}

.hero-bento__item {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: inherit;
    transition: transform var(--transition), box-shadow var(--transition);
}

.hero-bento__item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.hero-bento__item img {
    width: 48px;
    height: 48px;
    border-radius: 12px;
}

.hero-bento__item span {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
}

/* ── Sections ── */
.section {
    padding: 5rem 0;
}

.section--muted { background: var(--bg-muted); }

.section__kicker {
    display: block;
    font-size: 0.8125rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.section__title {
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    text-align: center;
    margin-bottom: 0.75rem;
}

.section__desc {
    text-align: center;
    color: var(--text-muted);
    max-width: 640px;
    margin: 0 auto 3rem;
    font-size: 1.0625rem;
    line-height: 1.7;
}

/* ── How we work ── */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.step-card {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    position: relative;
    transition: transform var(--transition), box-shadow var(--transition);
}

.step-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.step-card__num {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: var(--primary-light);
    color: var(--primary);
    font-weight: 800;
    font-size: 1rem;
    margin-bottom: 1.25rem;
}

.step-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.step-card p {
    color: var(--text-muted);
    font-size: 0.9375rem;
    line-height: 1.7;
}

/* ── Products ── */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem;
}

.product-card {
    display: block;
    text-decoration: none;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    transition: all 0.25s ease;
    color: inherit;
}

.product-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-md);
    border-color: rgba(0, 102, 255, 0.2);
}

.product-card img {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    margin-bottom: 1rem;
}

.product-card h3 {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text);
}

.product-card p {
    font-size: 0.875rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.badge {
    display: inline-block;
    font-size: 0.6875rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 6px;
    margin-left: 6px;
    vertical-align: middle;
}

.badge--new { background: #fff7ed; color: #ea580c; }
.badge--web { background: #ecfdf5; color: #059669; }

/* ── Tech grid ── */
.tech-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
}

.tech-card {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.75rem;
    text-align: center;
}

.tech-card__icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 1rem;
    border-radius: 16px;
    background: var(--primary-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.tech-card h3 {
    font-size: 1.0625rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.tech-card p {
    font-size: 0.875rem;
    color: var(--text-muted);
    line-height: 1.6;
}

/* ── Creator CTA banner ── */
.creator-cta {
    padding: 5rem 0;
    background: linear-gradient(135deg, #0f172a 0%, #1e3a5f 50%, #0066ff 100%);
    color: #fff;
    text-align: center;
}

.creator-cta h2 {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 0.75rem;
}

.creator-cta p {
    font-size: 1.0625rem;
    opacity: 0.85;
    margin-bottom: 2rem;
    max-width: 560px;
    margin-left: auto;
    margin-right: auto;
}

.creator-cta__actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ── About snippet ── */
.about-snippet {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}

.about-snippet__text h2 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 1rem;
}

.about-snippet__text p {
    color: var(--text-muted);
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.about-snippet__text a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
}

.about-snippet__image img {
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.stat-box {
    text-align: center;
    padding: 1.25rem;
    background: var(--bg-muted);
    border-radius: var(--radius);
    border: 1px solid var(--border);
}

.stat-box__num {
    display: block;
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--text);
}

.stat-box__label {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

/* ── Footer v2 ── */
.site-footer {
    background: var(--bg-muted);
    border-top: 1px solid var(--border);
    padding: 3.5rem 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr repeat(4, 1fr);
    gap: 2rem;
    margin-bottom: 2.5rem;
}

.footer-logo { height: 32px; margin-bottom: 0.75rem; }

.footer-tagline {
    font-size: 0.875rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.footer-col h4 {
    font-size: 0.8125rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text);
    margin-bottom: 1rem;
}

.footer-col a,
.footer-col span {
    display: block;
    font-size: 0.875rem;
    color: var(--text-muted);
    text-decoration: none;
    margin-bottom: 0.5rem;
    transition: color var(--transition);
}

.footer-col a:hover { color: var(--primary); }

.footer-wechat-note {
    display: block;
    font-size: 0.75rem !important;
    line-height: 1.45;
    opacity: 0.85;
    margin-top: -0.15rem;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.footer-beian { margin-top: 0.5rem; }

.beian-link {
    color: var(--text-muted);
    text-decoration: none;
    margin: 0 0.5rem;
}

.beian-link:hover { color: var(--primary); }

/* ── Product creator banner ── */
.creator-banner-wrap {
    padding: 1.5rem 0;
    background: var(--primary-light);
    border-top: 1px solid rgba(0, 102, 255, 0.1);
}

.creator-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.creator-banner__text {
    font-weight: 600;
    color: var(--text);
}

.creator-banner__link {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
}

.creator-banner__link:hover { text-decoration: underline; }

/* ── Responsive ── */
@media (max-width: 1024px) {
    .hero-v2__grid { grid-template-columns: 1fr; }
    .hero-v2__visual { order: -1; max-width: 480px; margin: 0 auto; }
    .steps-grid { grid-template-columns: 1fr; }
    .tech-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: repeat(2, 1fr); }
    .about-snippet { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .nav-toggle { display: flex; }

    .nav-panel {
        position: fixed;
        top: var(--nav-height);
        left: 0;
        right: 0;
        background: var(--bg);
        border-bottom: 1px solid var(--border);
        flex-direction: column;
        padding: 1.5rem;
        gap: 1.5rem;
        transform: translateY(-120%);
        opacity: 0;
        pointer-events: none;
        transition: all 0.3s ease;
        box-shadow: var(--shadow-md);
    }

    .navbar.is-open .nav-panel {
        transform: translateY(0);
        opacity: 1;
        pointer-events: auto;
    }

    .nav-links {
        flex-direction: column;
        gap: 0.75rem;
        width: 100%;
    }

    .nav-actions {
        flex-direction: column;
        width: 100%;
    }

    .btn--nav-cta { width: 100%; }

    .tech-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .stats-row { grid-template-columns: 1fr; }
}
