/* =====================================================================
   What the Phage v2.0 — landing page design system
   Accent: #ff1d6c (pink)  ·  Text light: #1e293b  ·  Text dark: #f8fafc
   ===================================================================== */

:root {
    --accent: #ff1d6c;
    --accent-hover: #d9005c;
    --accent-dim: #ff8fb5;
    --accent-soft: #fff0f5;

    --text: #1e293b;
    --text-soft: #475569;
    --text-muted: #64748b;
    --text-dark: #f8fafc;
    --text-dark-soft: #cbd5e1;

    --surface: #ffffff;
    --surface-alt: #f8fafc;
    --surface-muted: #f1f5f9;

    --border: #e2e8f0;
    --border-dark: #24304a;

    --dark: #0b1220;
    --dark-2: #101b30;
    --dark-3: #16233c;

    --radius: 18px;
    --radius-sm: 12px;
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 12px 34px -14px rgba(15, 23, 42, 0.18);
    --shadow-lg: 0 30px 60px -22px rgba(15, 23, 42, 0.28);

    --font-sans: "Plus Jakarta Sans", ui-sans-serif, system-ui, sans-serif;
    --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", monospace;

    --container: 1160px;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 84px;
    overflow-x: hidden;
    overflow-x: clip;
}

body {
    font-family: var(--font-sans);
    color: var(--text);
    background: var(--surface);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

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

a {
    color: inherit;
    text-decoration: none;
}

code,
pre,
.mono {
    font-family: var(--font-mono);
}

.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}

.section {
    padding: 96px 0;
}

.section-alt {
    background: var(--surface-alt);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 16px;
}

.eyebrow::before {
    content: "";
    width: 24px;
    height: 2px;
    border-radius: 2px;
    background: var(--accent);
}

.section-head {
    max-width: 720px;
    margin-bottom: 56px;
}

.section-head.center {
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

.section-head.center .eyebrow::before {
    display: none;
}

.section-head h2 {
    font-size: clamp(1.9rem, 3.4vw, 2.7rem);
    line-height: 1.15;
    letter-spacing: -0.02em;
    color: var(--text);
    margin-bottom: 16px;
}

.section-head p {
    color: var(--text-soft);
    font-size: 1.075rem;
}

/* ---------- Buttons ---------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-weight: 700;
    font-size: 0.95rem;
    padding: 14px 26px;
    border-radius: 999px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 10px 26px -10px rgba(255, 29, 108, 0.55);
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
}

.btn-ghost {
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-dark);
    border-color: rgba(255, 255, 255, 0.16);
}

.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.28);
}

.btn-outline {
    background: var(--surface);
    color: var(--text);
    border-color: var(--border);
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.btn-sm {
    padding: 10px 18px;
    font-size: 0.85rem;
}

/* ---------- Navbar ---------- */

.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(11, 18, 32, 0.82);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    transition: background 0.3s ease;
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: clamp(16px, 2.5vw, 36px);
    height: 72px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-dark);
    font-weight: 700;
    font-size: 1.05rem;
    letter-spacing: -0.01em;
    white-space: nowrap;
    flex-shrink: 0;
}

.nav-logo img {
    height: 34px;
    width: auto;
    border-radius: 8px;
}

.nav-logo .ver {
    font-size: 11px;
    font-weight: 800;
    color: var(--accent);
    background: rgba(255, 29, 108, 0.14);
    padding: 3px 8px;
    border-radius: 999px;
    margin-left: 2px;
    letter-spacing: 0.03em;
}

.nav-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(14px, 1.8vw, 26px);
    min-width: 0;
}

.nav-links a {
    color: var(--text-dark-soft);
    font-size: 0.85rem;
    font-weight: 600;
    white-space: nowrap;
    transition: color 0.2s ease;
}

.nav-links a:hover {
    color: #fff;
}

.nav-links .nav-github {
    display: none;
}

.nav-cta {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-shrink: 0;
}

.nav-burger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-dark);
    padding: 8px;
}

.nav-burger svg {
    width: 26px;
    height: 26px;
}

@media (max-width: 1080px) {
    .nav-links {
        position: fixed;
        inset: 72px 0 auto 0;
        flex-direction: column;
        align-items: stretch;
        gap: 2px;
        background: var(--dark);
        border-bottom: 1px solid var(--border-dark);
        padding: 16px 24px 24px;
        max-height: calc(100vh - 72px);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        transform: translateY(-8px);
        opacity: 0;
        pointer-events: none;
        transition: all 0.25s ease;
    }

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

    .nav-links a {
        padding: 12px 0;
        font-size: 1.05rem;
        width: 100%;
        white-space: normal;
    }

    .nav-links .nav-github {
        display: flex;
        align-items: center;
        justify-content: center;
        margin-top: 14px;
        padding: 12px 16px;
        border: 1px solid rgba(255, 255, 255, 0.16);
        border-radius: 999px;
        background: rgba(255, 255, 255, 0.06);
        color: var(--text-dark);
        font-weight: 700;
        font-size: 0.95rem;
    }

    .nav-cta .btn {
        display: none;
    }

    .nav-burger {
        display: block;
    }
}

@media (max-width: 480px) {
    .nav-logo {
        font-size: 0.95rem;
        gap: 10px;
    }

    .nav-logo img {
        height: 30px;
    }

    .nav-logo .ver {
        display: none;
    }
}

/* ---------- Hero ---------- */

.hero {
    position: relative;
    background: var(--dark);
    color: var(--text-dark);
    padding: 168px 0 120px;
    overflow: hidden;
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(700px 380px at 82% -10%, rgba(255, 29, 108, 0.28), transparent 60%),
        radial-gradient(600px 420px at -5% 15%, rgba(59, 130, 246, 0.16), transparent 55%);
    pointer-events: none;
}

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(148, 163, 184, 0.16) 1px, transparent 1px);
    background-size: 30px 30px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.7), transparent 70%);
    pointer-events: none;
}

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

.hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 26px;
}

.hero-badges span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 12.5px;
    font-weight: 700;
    color: var(--text-dark);
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.12);
    padding: 7px 14px;
    border-radius: 999px;
}

.hero-badges span::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 10px var(--accent);
}

.hero h1 {
    font-size: clamp(2.5rem, 5vw, 3.9rem);
    line-height: 1.05;
    letter-spacing: -0.03em;
    font-weight: 800;
    margin-bottom: 22px;
}

.hero h1 .grad {
    background: linear-gradient(92deg, #ff1d6c, #ff8fb5 60%, #c4b5fd);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero p.lead {
    font-size: 1.16rem;
    color: var(--text-dark-soft);
    max-width: 540px;
    margin-bottom: 34px;
}

.hero-cta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 40px;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 26px;
    color: var(--text-dark-soft);
    font-size: 0.9rem;
}

.hero-meta strong {
    color: #fff;
    font-weight: 700;
}

/* Terminal card */
.terminal {
    position: relative;
    background: rgba(15, 23, 42, 0.92);
    border: 1px solid var(--border-dark);
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.terminal-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.04);
    border-bottom: 1px solid var(--border-dark);
}

.terminal-bar .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.terminal-bar .dot:nth-child(1) { background: #ff5f57; }
.terminal-bar .dot:nth-child(2) { background: #febc2e; }
.terminal-bar .dot:nth-child(3) { background: #28c840; }

.terminal-bar .title {
    margin-left: 10px;
    font-size: 12px;
    color: var(--text-dark-soft);
    font-weight: 600;
}

.terminal-body {
    padding: 22px;
    font-family: var(--font-mono);
    font-size: 13px;
    line-height: 1.9;
    color: #e2e8f0;
    overflow-x: auto;
}

.terminal-body .cmt { color: #7d8aa5; }
.terminal-body .cmd { color: #f8fafc; }
.terminal-body .flag { color: var(--accent-dim); }
.terminal-body .ok { color: #4ade80; }
.terminal-body .prompt { color: var(--accent); }

.terminal-glow {
    position: absolute;
    width: 340px;
    height: 340px;
    background: radial-gradient(circle, rgba(255, 29, 108, 0.35), transparent 65%);
    filter: blur(20px);
    top: -60px;
    right: -60px;
    z-index: -1;
}

@media (max-width: 920px) {
    .hero {
        padding: 130px 0 80px;
    }

    .hero-grid {
        grid-template-columns: 1fr;
        gap: 44px;
    }
}

/* ---------- Stats ---------- */

.stats {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    padding: 52px 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.stat {
    text-align: center;
}

.stat .num {
    font-size: 2.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--accent);
    line-height: 1;
}

.stat .label {
    margin-top: 10px;
    font-size: 0.9rem;
    color: var(--text-soft);
    font-weight: 600;
}

@media (max-width: 720px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 32px 16px;
    }
}

/* ---------- Pipeline ---------- */

.pipeline-flow {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
    margin-bottom: 20px;
}

.pipe-card {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px 20px;
    transition: all 0.25s ease;
    box-shadow: var(--shadow-sm);
}

.pipe-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    border-color: rgba(255, 29, 108, 0.4);
}

.pipe-card .step {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 9px;
    background: var(--accent-soft);
    color: var(--accent);
    font-weight: 800;
    font-size: 0.85rem;
    margin-bottom: 14px;
}

.pipe-card h3 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 6px;
    letter-spacing: -0.01em;
}

.pipe-card p {
    font-size: 0.83rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.pipe-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    margin: 2px 0 14px;
}

.pipe-arrow svg {
    width: 22px;
    height: 22px;
}

.pipe-arrow.down { display: none; }

.pipe-note {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 14px;
    background: var(--dark);
    color: var(--text-dark-soft);
    border-radius: var(--radius);
    padding: 20px 24px;
    margin-top: 26px;
    font-size: 0.95rem;
}

.pipe-note code {
    color: var(--accent-dim);
    font-size: 0.9rem;
    background: rgba(255, 255, 255, 0.08);
    padding: 4px 8px;
    border-radius: 7px;
    white-space: nowrap;
}

.pipe-note + .code-block {
    margin-top: 26px;
}

@media (max-width: 1000px) {
    .pipeline-flow {
        grid-template-columns: repeat(2, 1fr);
    }

    .pipe-arrow {
        transform: rotate(90deg);
        margin: 4px auto;
        width: 22px;
    }
}

@media (max-width: 560px) {
    .pipeline-flow {
        grid-template-columns: 1fr;
    }
}

/* ---------- Flow chart ---------- */

.flow {
    margin-bottom: 8px;
}

.flow-row {
    display: flex;
    align-items: stretch;
    gap: 12px;
}

.flow-row .flow-node {
    flex: 1;
    min-width: 0;
}

.flow-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    flex-shrink: 0;
}

.flow-arrow svg {
    width: 20px;
    height: 20px;
}

.flow-drop {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 46px;
    position: relative;
}

.flow-drop::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    width: 2px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(to bottom, var(--accent-dim), var(--accent));
    border-radius: 2px;
}

.flow-drop::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 4px;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--accent);
}

.flow-report {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    background: linear-gradient(120deg, var(--dark-3), var(--dark));
    border: 1px solid var(--border-dark);
    color: var(--text-dark);
    border-radius: var(--radius);
    padding: 26px 30px;
    text-align: center;
    box-shadow: var(--shadow-md);
    position: relative;
    overflow: hidden;
}

.flow-report::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(420px 180px at 50% -30%, rgba(255, 29, 108, 0.25), transparent 60%);
    pointer-events: none;
}

.flow-report svg {
    width: 28px;
    height: 28px;
    color: var(--accent-dim);
    position: relative;
}

.flow-report h3 {
    font-size: 1.15rem;
    font-weight: 800;
    position: relative;
}

.flow-report p {
    color: var(--text-dark-soft);
    font-size: 0.88rem;
    position: relative;
    width: 100%;
}

@media (max-width: 900px) {
    .flow-row {
        flex-direction: column;
    }

    .flow-arrow {
        transform: rotate(90deg);
        align-self: center;
        margin: 4px 0;
        width: 22px;
    }

    .flow-drop {
        height: 34px;
    }
}

/* ---------- Vertical flow (v2) ---------- */

.vflow {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.vflow-node {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px 30px;
    box-shadow: var(--shadow-sm);
    text-align: center;
    width: 100%;
    max-width: 520px;
}

.vflow-node h3 {
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.vflow-node p {
    font-size: 0.86rem;
    color: var(--text-muted);
    margin-top: 4px;
}

.vflow-node.primary {
    border-color: var(--accent);
    background: var(--accent-soft);
}

.vflow-node.primary h3 {
    color: var(--accent);
}

.vflow-node.primary p {
    color: var(--accent-hover);
}

.vflow-arrow {
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--accent);
    padding: 8px 0;
}

.vflow-arrow svg {
    width: 26px;
    height: 26px;
}

.vflow-bus {
    position: relative;
    width: 100%;
    height: 34px;
    margin: 2px 0 10px;
}

.vflow-bus::before {
    content: "";
    position: absolute;
    left: 4%;
    right: 4%;
    top: 50%;
    height: 2px;
    transform: translateY(-50%);
    background: linear-gradient(to right, transparent, var(--accent-dim) 10%, var(--accent-dim) 90%, transparent);
    border-radius: 2px;
}

.vflow-bus::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 2px;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--accent);
}

.vflow-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    width: 100%;
}

.vflow-mod {
    flex: 0 1 146px;
    min-width: 0;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 18px 14px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: all 0.25s ease;
}

.vflow-mod:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: rgba(255, 29, 108, 0.4);
}

.vflow-mod .idx {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 8px;
    background: var(--accent-soft);
    color: var(--accent);
    font-weight: 800;
    font-size: 0.75rem;
    margin-bottom: 10px;
}

.vflow-mod h3 {
    font-size: 0.92rem;
    font-weight: 700;
    margin-bottom: 5px;
    letter-spacing: -0.01em;
}

.vflow-mod p {
    font-size: 0.74rem;
    color: var(--text-muted);
    line-height: 1.45;
}

.vflow-mod .new-tag {
    display: block;
    font-size: 0.58rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #fff;
    background: var(--accent);
    padding: 2px 8px;
    border-radius: 999px;
    width: fit-content;
    margin: 0 auto 8px;
}

.vflow-note {
    margin-top: 22px;
    font-size: 0.88rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 10px;
}

.vflow-note svg {
    width: 20px;
    height: 20px;
    color: var(--accent);
    flex-shrink: 0;
}

/* ---------- Tools ---------- */

.tool-group {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 26px;
    margin-bottom: 22px;
    box-shadow: var(--shadow-sm);
}

.tool-group-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
}

.tool-group-head .icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent-soft);
    color: var(--accent);
    flex-shrink: 0;
}

.tool-group-head .icon svg { width: 22px; height: 22px; }

.tool-group-head h3 {
    font-size: 1.12rem;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.tool-group-head .tagline {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.tool-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tool-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 16px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--surface-muted);
    font-size: 0.86rem;
    font-weight: 700;
    color: var(--text);
    cursor: pointer;
    transition: all 0.2s ease;
}

.tool-chip:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-soft);
    transform: translateY(-2px);
}

.tool-chip .tip {
    font-weight: 500;
    color: var(--text-muted);
    font-size: 0.8rem;
}

.tool-chip:hover .tip { color: var(--accent); }

.tool-chip::after {
    content: "↗";
    font-size: 0.72em;
    color: var(--text-muted);
    opacity: 0;
    transform: translate(-3px, 3px);
    transition: all 0.2s ease;
}

.tool-chip:hover::after {
    color: var(--accent);
    opacity: 1;
    transform: translate(0, 0);
}

.badge-new {
    display: inline-block;
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #fff;
    background: var(--accent);
    padding: 3px 9px;
    border-radius: 999px;
    vertical-align: middle;
    margin-left: 8px;
    box-shadow: 0 4px 12px -4px rgba(255, 29, 108, 0.55);
}

.badge-dev {
    display: inline-block;
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #b45309;
    background: #fffbeb;
    border: 1px solid #fcd34d;
    padding: 2px 9px;
    border-radius: 999px;
    vertical-align: middle;
    margin-left: 8px;
}

.tools-note {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 22px;
    margin-top: 26px;
    font-size: 0.86rem;
    color: var(--text-muted);
}

.tools-note .pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

/* ---------- Features ---------- */

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.feature {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 30px 26px;
    transition: all 0.25s ease;
}

.feature:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: rgba(255, 29, 108, 0.35);
}

.feature .icon {
    width: 46px;
    height: 46px;
    border-radius: 13px;
    background: var(--dark);
    color: var(--accent-dim);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.feature .icon svg { width: 23px; height: 23px; }

.feature h3 {
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: -0.01em;
}

.feature p {
    font-size: 0.9rem;
    color: var(--text-soft);
    line-height: 1.6;
}

.feature ul {
    list-style: none;
    margin-top: 12px;
}

.feature ul li {
    font-size: 0.85rem;
    color: var(--text-muted);
    padding: 4px 0;
    display: flex;
    gap: 8px;
}

.feature ul li::before {
    content: "→";
    color: var(--accent);
    font-weight: 700;
}

@media (max-width: 920px) {
    .features-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 620px) {
    .features-grid { grid-template-columns: 1fr; }
}

/* ---------- Code / How to run ---------- */

.code-block {
    background: var(--dark);
    border: 1px solid var(--border-dark);
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 22px;
    box-shadow: var(--shadow-md);
}

.code-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 13px 20px;
    border-bottom: 1px solid var(--border-dark);
    background: rgba(255, 255, 255, 0.03);
}

.code-head .name {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-dark-soft);
    display: flex;
    align-items: center;
    gap: 10px;
}

.code-head .name svg { width: 16px; height: 16px; color: var(--accent); }

.copy-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-family: var(--font-sans);
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text-dark-soft);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    padding: 6px 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.copy-btn:hover { color: #fff; background: rgba(255, 255, 255, 0.14); }
.copy-btn.copied { color: #4ade80; border-color: rgba(74, 222, 128, 0.4); }

.code-block pre {
    padding: 22px 24px;
    overflow-x: auto;
    font-size: 0.86rem;
    line-height: 1.75;
    color: #e2e8f0;
}

.code-block .cmt { color: #7d8aa5; }
.code-block .flag { color: var(--accent-dim); }

.run-notes {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
    margin-top: 36px;
}

.run-note {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 20px;
}

.run-note h4 {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.run-note p {
    font-size: 0.86rem;
    color: var(--text-soft);
}

@media (max-width: 900px) {
    .run-notes { grid-template-columns: 1fr; }
}

/* ---------- Storage & runtime requirements ---------- */

.req-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
    margin-bottom: 28px;
}

.req-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 22px;
    box-shadow: var(--shadow-sm);
}

.req-card h4 {
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 10px;
}

.req-card .req-big {
    font-size: 1.55rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text);
    line-height: 1.35;
}

.req-card .req-opt {
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--accent-hover);
    background: var(--accent-soft);
    padding: 2px 8px;
    border-radius: 999px;
    vertical-align: middle;
    margin-left: 6px;
    letter-spacing: 0.02em;
}

.req-card .req-sub {
    margin-top: 6px;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.req-grid {
    display: grid;
    grid-template-columns: 1.35fr 1fr;
    gap: 22px;
    margin-bottom: 44px;
}

.req-panel {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 24px;
    box-shadow: var(--shadow-sm);
}

.req-panel h4 {
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 12px;
}

.req-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}

.req-table th {
    text-align: left;
    font-size: 0.7rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--text-muted);
    padding: 7px 6px;
    border-bottom: 2px solid var(--border);
}

.req-table th:last-child {
    text-align: right;
}

.req-table td {
    padding: 8px 6px;
    border-bottom: 1px solid var(--surface-muted);
    color: var(--text-soft);
}

.req-table td:last-child {
    text-align: right;
    font-family: var(--font-mono);
    font-size: 0.78rem;
    color: var(--text);
    white-space: nowrap;
}

.req-table .req-total td {
    font-weight: 800;
    color: var(--accent-hover);
    border-bottom: 2px solid var(--border);
}

.req-note {
    margin-top: 12px;
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.5;
}

@media (max-width: 900px) {
    .req-cards { grid-template-columns: 1fr; }
    .req-grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
    .req-table { font-size: 0.78rem; }
    .req-table td { padding: 7px 4px; }
    .req-card .req-big { font-size: 1.3rem; }
}

/* ---------- Options reference ---------- */

.opts {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px;
    margin-top: 34px;
}

.opt-group {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 26px 26px 18px;
    box-shadow: var(--shadow-sm);
}

.opt-group h4 {
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 14px;
}

.opt-row {
    display: flex;
    gap: 16px;
    align-items: baseline;
    padding: 11px 0;
    border-bottom: 1px solid var(--surface-muted);
}

.opt-row:last-child {
    border-bottom: 0;
    padding-bottom: 4px;
}

.opt-row code {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    color: var(--accent-hover);
    background: var(--accent-soft);
    padding: 3px 10px;
    border-radius: 7px;
    white-space: nowrap;
    flex-shrink: 0;
    min-width: 150px;
    text-align: center;
}

.opt-row .desc {
    color: var(--text-soft);
    font-size: 0.88rem;
    line-height: 1.5;
}

.opt-row .desc .def {
    color: var(--text-muted);
    font-size: 0.8rem;
}

@media (max-width: 900px) {
    .opts { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
    .opt-row { flex-direction: column; gap: 6px; }
    .opt-row code { min-width: 0; width: fit-content; }
}

/* ---------- Live demo ---------- */

.demo-frame {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    background: var(--surface);
}

.demo-frame iframe {
    width: 100%;
    height: 680px;
    border: 0;
    display: block;
    background: #f8fafc;
}

.demo-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding: 16px 22px;
    background: var(--dark);
    color: var(--text-dark-soft);
}

.demo-bar .info {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.9rem;
}

.demo-bar .pulse {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #4ade80;
    box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.6);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.55); }
    70% { box-shadow: 0 0 0 10px rgba(74, 222, 128, 0); }
    100% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0); }
}

.demo-cta {
    display: flex;
    gap: 12px;
}

@media (max-width: 720px) {
    .demo-frame iframe { height: 560px; }
}

/* ---------- Publication ---------- */

.pub-card {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 26px;
    align-items: center;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 34px;
    box-shadow: var(--shadow-sm);
}

.pub-card .journal {
    width: 88px;
    height: 88px;
    border-radius: 20px;
    background: var(--dark);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-dim);
    font-weight: 800;
    font-size: 0.78rem;
    text-align: center;
    letter-spacing: 0.02em;
    line-height: 1.3;
    flex-shrink: 0;
}

.pub-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    margin-bottom: 8px;
}

.pub-card p {
    color: var(--text-soft);
    font-size: 0.95rem;
}

.pub-card .authors {
    font-size: 0.86rem;
    color: var(--text-muted);
    margin-top: 6px;
}

.pub-card .doi {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    background: var(--accent-soft);
    color: var(--accent-hover);
    border-radius: 999px;
    padding: 8px 16px;
    font-weight: 700;
}

@media (max-width: 760px) {
    .pub-card { grid-template-columns: 1fr; text-align: left; }
}

/* ---------- CTA band ---------- */

.cta-band {
    background: var(--dark);
    position: relative;
    overflow: hidden;
    border-radius: var(--radius);
    padding: 72px 48px;
    text-align: center;
    color: var(--text-dark);
}

.cta-band::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(560px 260px at 50% -20%, rgba(255, 29, 108, 0.3), transparent 60%);
    pointer-events: none;
}

.cta-band h2 {
    position: relative;
    font-size: clamp(1.8rem, 3.4vw, 2.5rem);
    letter-spacing: -0.02em;
    margin-bottom: 14px;
}

.cta-band p {
    position: relative;
    color: var(--text-dark-soft);
    max-width: 560px;
    margin: 0 auto 30px;
}

.cta-band .hero-cta { justify-content: center; }

/* ---------- Footer ---------- */

.footer {
    background: var(--dark);
    color: var(--text-dark-soft);
    padding: 56px 0 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid var(--border-dark);
    margin-bottom: 30px;
}

.footer-brand p {
    font-size: 0.9rem;
    margin-top: 16px;
    max-width: 340px;
}

.footer h4 {
    color: #fff;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 16px;
}

.footer ul { list-style: none; }

.footer ul li { margin-bottom: 10px; }

.footer ul a {
    font-size: 0.9rem;
    color: var(--text-dark-soft);
    transition: color 0.2s ease;
}

.footer ul a:hover { color: var(--accent-dim); }

.footer-bottom {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 0.83rem;
    color: #7d8aa5;
}

.footer-bottom a { color: var(--text-dark-soft); }

.footer-bottom a:hover { color: var(--accent-dim); }

@media (max-width: 760px) {
    .footer-grid { grid-template-columns: 1fr; }
}

/* ---------- Reveal animations ---------- */

.reveal {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; }
    html { scroll-behavior: auto; }
}