:root {
    color-scheme: light;
    --bg: #ffffff;
    --soft: #fafafb;
    --ink: #18181b;
    --ink-2: #3f3f46;
    --muted: #71717a;
    --line: #ececf0;
    --line-2: #e4e4ea;
    --accent: #6366f1;
    --accent-dark: #4f46e5;
    --accent-50: #eef0ff;
    --accent-100: #e0e3ff;
    --code: #f6f7f9;
    --code-fg: #2b2b31;
    --code-muted: #9a9aa3;
    --code-key: #4f46e5;
    --code-tag: #4f46e5;
    --code-border: #e8e8ef;
    --sh-card: 0 1px 2px rgba(24, 24, 27, .04), 0 10px 28px rgba(24, 24, 27, .05);
    --sh-btn: 0 1px 2px rgba(79, 70, 229, .18), 0 8px 22px rgba(79, 70, 229, .16);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 84px;
}

body {
    margin: 0;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--ink);
    background: var(--bg);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}

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

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

h1, h2, h3 {
    letter-spacing: -0.02em;
}

code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

p code {
    font-size: 0.9em;
    color: var(--accent-dark);
    background: var(--accent-50);
    padding: 1px 6px;
    border-radius: 6px;
    overflow-wrap: anywhere;
}

a:focus-visible,
button:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
    border-radius: 8px;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

.wrap {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 32px;
}

.eyebrow {
    display: inline-block;
    margin: 0 0 18px;
    color: var(--accent-dark);
    background: var(--accent-50);
    padding: 6px 13px;
    border-radius: 999px;
    font-size: 12.5px;
    font-weight: 500;
}

/* Header */
.nav {
    position: sticky;
    top: 0;
    z-index: 5;
    background: rgba(255, 255, 255, .85);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(8px);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 66px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 15px;
}

.brand .mk {
    display: grid;
    place-items: center;
    width: 27px;
    height: 27px;
    color: #fff;
    background: var(--accent);
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
}

.nav-links {
    display: flex;
    gap: 28px;
    font-size: 14px;
    color: var(--muted);
}

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 46px;
    padding: 0 22px;
    border: 1px solid transparent;
    border-radius: 10px;
    font-size: 14.5px;
    font-weight: 500;
    transition: transform .15s ease, background .15s ease;
}

.btn.primary {
    color: #fff;
    background: var(--accent);
    box-shadow: var(--sh-btn);
}

.btn.secondary {
    color: var(--ink);
    background: #fff;
    border-color: var(--line-2);
}

.btn.secondary:hover {
    background: var(--soft);
}

.btn.text {
    color: var(--accent-dark);
    padding: 0 8px;
}

.btn.primary:hover,
.btn.secondary:hover {
    transform: translateY(-1px);
}

/* Hero */
.hero {
    padding: 92px 0 72px;
    text-align: center;
}

.hero h1 {
    margin: 0 auto;
    max-width: 16ch;
    font-size: clamp(2.5rem, 5.2vw, 3.65rem);
    line-height: 1.06;
    font-weight: 600;
}

.lede {
    margin: 24px auto 0;
    max-width: 62ch;
    color: var(--muted);
    font-size: 1.18rem;
}

.actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    margin-top: 32px;
}

/* Code blocks */
.install,
.codepanel {
    overflow: hidden;
    background: var(--code);
    border: 1px solid var(--code-border);
    border-radius: 12px;
    box-shadow: var(--sh-card);
    text-align: left;
}

.install {
    width: min(720px, 100%);
    margin: 36px auto 0;
}

.install .co,
.codepanel .co {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 14px;
    border-bottom: 1px solid var(--code-border);
    color: var(--code-muted);
    font-size: 12px;
}

.install pre,
.codepanel pre,
.codewrap pre {
    margin: 0;
    padding: 16px 18px;
    overflow-x: auto;
    color: var(--code-fg);
    font-size: 13px;
    line-height: 1.7;
}

.install pre code,
.codepanel pre code {
    white-space: pre;
}

.k {
    color: var(--code-key);
}

.t {
    color: var(--code-tag);
}

/* Copy button */
.copy {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    color: var(--code-muted);
    background: transparent;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    transition: color .15s ease, background .15s ease;
}

.copy:hover {
    color: var(--ink);
    background: var(--line);
}

.copy .ct {
    display: none;
}

.copy .ic {
    width: 15px;
    height: 15px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.copy .ic-ok {
    display: none;
}

.copy.ok {
    color: #2f9e44;
}

.copy.ok .ic-copy {
    display: none;
}

.copy.ok .ic-ok {
    display: inline-block;
}

.codewrap {
    margin-top: 24px;
}

/* Code blocks: one consistent focus ring on the outer panel (the inner
   scrollable <pre> outline would otherwise be clipped by border-radius). */
.install pre:focus,
.codepanel pre:focus {
    outline: none;
}

.install:has(pre:focus),
.codepanel:has(pre:focus) {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* Tags */
.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    justify-content: center;
    margin-top: 24px;
}

.tags span {
    padding: 6px 14px;
    color: var(--muted);
    background: var(--soft);
    border: 1px solid var(--line);
    border-radius: 999px;
    font-size: 13px;
}

/* Sections */
.section {
    padding: 90px 0;
}

.section.soft {
    background: var(--soft);
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.sec-head {
    max-width: 680px;
    margin: 0 auto 46px;
    text-align: center;
}

.sec-head .eyebrow {
    margin-bottom: 14px;
}

.sec-head h2 {
    margin: 0;
    font-size: 2.05rem;
    font-weight: 600;
    line-height: 1.16;
}

/* Proof strip */
.proof-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
}

.proof-grid > div {
    padding: 22px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
}

.proof-grid strong {
    display: block;
    font-size: 14px;
    font-weight: 600;
}

.proof-grid span {
    display: block;
    margin-top: 7px;
    color: var(--muted);
    font-size: 13.5px;
}

/* Cards */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.card,
.vcard {
    padding: 28px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--sh-card);
}

.chip {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    color: var(--accent-dark);
    background: var(--accent-50);
    border-radius: 11px;
    font-size: 15px;
    font-weight: 600;
}

.card h3 {
    margin: 18px 0 9px;
    font-size: 1.12rem;
    font-weight: 600;
}

.vcard h3 {
    margin: 0 0 10px;
    font-size: 1.1rem;
    font-weight: 600;
}

.card p,
.vcard p {
    margin: 0;
    color: var(--muted);
    font-size: 14.5px;
}

/* Install layout */
.install-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(280px, .7fr);
    gap: 20px;
    align-items: start;
}

.compat {
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
}

.crow {
    display: grid;
    grid-template-columns: .9fr .9fr 1fr;
    gap: 12px;
    padding: 14px 18px;
    border-bottom: 1px solid var(--line);
    color: var(--ink-2);
    font-size: 14px;
}

.crow:last-child {
    border-bottom: 0;
}

.crow.head {
    color: var(--accent-dark);
    background: var(--accent-50);
    font-size: 12.5px;
    font-weight: 600;
}

/* Showcase */
.showcase {
    display: grid;
    grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr);
    gap: 44px;
    align-items: center;
}

.showcase-copy h2 {
    margin: 0;
    font-size: 2.05rem;
    font-weight: 600;
    line-height: 1.16;
}

.showcase-copy > p {
    margin: 18px 0 0;
    color: var(--muted);
}

.showcase-media {
    margin: 0;
}

.showcase-media img {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: var(--sh-card);
}

/* Screens */
.screens {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.screens figure {
    overflow: hidden;
    margin: 0;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: var(--sh-card);
}

.screens img {
    width: 100%;
    aspect-ratio: 1.5;
    object-fit: cover;
    object-position: top left;
    background: var(--soft);
    border-bottom: 1px solid var(--line);
}

.screens figcaption {
    padding: 13px 16px;
    color: var(--muted);
    font-size: 13.5px;
}

/* Notes */
.notes {
    display: grid;
    grid-template-columns: .78fr 1.22fr;
    gap: 32px;
    padding: 36px;
    background: var(--accent-50);
    border: 1px solid var(--accent-100);
    border-radius: 18px;
}

.notes h2 {
    margin: 0;
    font-size: 1.65rem;
    font-weight: 600;
}

.notes p {
    margin: 0;
    color: var(--ink-2);
}

.notes p code {
    background: #fff;
}

/* Footer */
.site-footer {
    background: var(--soft);
    border-top: 1px solid var(--line);
}

.foot-inner {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    justify-content: center;
    padding: 36px 0;
    color: var(--muted);
    font-size: 14px;
}

.site-footer a {
    color: var(--accent-dark);
    font-weight: 500;
}

/* Responsive */
@media (max-width: 980px) {
    .section {
        padding: 68px 0;
    }

    .proof-grid,
    .grid-3,
    .screens {
        grid-template-columns: repeat(2, 1fr);
    }

    .install-layout,
    .showcase,
    .notes {
        /* minmax(0, 1fr) lets the column shrink below its content's min width so
           non-wrapping code blocks scroll inside their own panel instead of
           widening the page (mirrors the desktop track definitions). */
        grid-template-columns: minmax(0, 1fr);
        gap: 24px;
    }

    .sec-head h2,
    .showcase-copy h2 {
        font-size: 1.8rem;
    }
}

@media (max-width: 620px) {
    .wrap {
        padding: 0 20px;
    }

    .nav-links {
        display: none;
    }

    .hero {
        padding: 64px 0 56px;
    }

    .lede {
        font-size: 1.06rem;
    }

    .actions {
        flex-direction: column;
        align-items: stretch;
    }

    .btn {
        justify-content: center;
    }

    .proof-grid,
    .grid-3,
    .screens {
        grid-template-columns: 1fr;
    }

    .notes {
        padding: 26px;
    }
}
