:root {
    --scalar-font: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --scalar-font-code: ui-monospace, SFMono-Regular, Consolas, monospace;
    --scalar-color-accent: #176354;
    /* The topbar scrolls with the page, so sticky navigation needs no fixed offset. */
    --scalar-custom-header-height: 0px;
    color-scheme: light;
    background: var(--docs-background, #fff);
    color: var(--docs-text, #192f2a);
    font-family: var(--scalar-font)
}

* {
    box-sizing: border-box
}

body {
    margin: 0
}

.topbar {
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 28px;
    border-bottom: 1px solid var(--docs-border, #e4e9e6);
    gap: 24px;
    background: var(--docs-background, #fff);
    position: relative;
    z-index: 10
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: inherit;
    font-size: 15px;
    white-space: nowrap
}

.brand strong {
    font-size: 19px;
    letter-spacing: -.7px
}

.brand-mark {
    background: #175b4c;
    color: white;
    display: grid;
    place-items: center;
    border-radius: 8px;
    width: 32px;
    height: 32px;
    font-size: 24px;
    font-weight: 800
}

.divider {
    height: 20px;
    width: 1px;
    background: var(--docs-border, #dce4df);
    margin: 0 4px
}

nav {
    display: flex;
    align-items: center;
    gap: 24px;
    font-size: 12px;
    font-weight: 550
}

nav a {
    color: var(--docs-link, #476159);
    text-decoration: none
}

nav a:hover {
    text-decoration: underline
}

.environment {
    display: flex;
    align-items: center;
    gap: 7px
}

.environment > span {
    height: 7px;
    width: 7px;
    border-radius: 50%;
    background: #339c73
}

.mode-note {
    min-height: 40px;
    padding: 8px 28px;
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--docs-surface, #f3f7f4);
    border-bottom: 1px solid var(--docs-border, #e4e9e6);
    font-size: 12px;
    color: var(--docs-muted, #496057)
}

.mode-pill {
    font-size: 9px;
    letter-spacing: .8px;
    font-weight: 700;
    white-space: nowrap;
    color: var(--docs-accent, #236752)
}

.loading {
    padding: 48px
}

.guide {
    max-width: 940px;
    margin: 64px auto;
    padding: 0 28px 80px;
    line-height: 1.75
}

.guide h1 {
    font-size: 40px;
    letter-spacing: -1.5px;
    line-height: 1.15;
    margin: 12px 0 24px
}

.guide h2 {
    font-size: 22px;
    margin-top: 40px
}

.guide p, .guide li {
    color: var(--docs-muted, #496057)
}

.guide a {
    color: var(--docs-accent, #176354)
}

.eyebrow {
    letter-spacing: 1.5px;
    font-size: 11px;
    font-weight: 700
}

.guide code {
    background: var(--docs-code, #f0f4f1);
    padding: 2px 5px;
    border-radius: 4px
}

.guide table {
    border-collapse: collapse;
    width: 100%;
    font-size: 14px
}

.guide td, .guide th {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--docs-border, #e4e9e6)
}

.guide pre {
    overflow: auto;
    background: var(--docs-surface, #f3f7f4);
    padding: 20px;
    border-radius: 8px
}

@media (max-width: 700px) {
    .topbar {
        padding: 0 16px;
        gap: 10px
    }

    nav {
        gap: 12px
    }

    .environment {
        display: none
    }

    .brand {
        gap: 8px;
        font-size: 12px
    }

    .mode-note {
        padding: 9px 16px;
        align-items: flex-start;
        font-size: 11px
    }

    .guide {
        margin-top: 36px
    }

    .guide h1 {
        font-size: 32px
    }
}

/* Scalar applies light-mode/dark-mode to body when its toggle changes. */
@media (prefers-color-scheme: dark) {
    :root:not(:has(body.light-mode)) {
        --docs-background: #111714;
        --docs-text: #e5ede8;
        --docs-border: #2c3931;
        --docs-surface: #18231c;
        --docs-muted: #a6bdae;
        --docs-link: #b1c7ba;
        --docs-accent: #87c8aa;
        --docs-code: #25352b;
        color-scheme: dark;
    }
}

:root:has(body.dark-mode) {
    --docs-background: #111714;
    --docs-text: #e5ede8;
    --docs-border: #2c3931;
    --docs-surface: #18231c;
    --docs-muted: #a6bdae;
    --docs-link: #b1c7ba;
    --docs-accent: #87c8aa;
    --docs-code: #25352b;
    color-scheme: dark;
}

/* Original EYCA artwork from https://eyca.org; keep its colours and proportions. */
.eyca-brand {
    display: flex;
    align-items: center;
    border-radius: 4px;
    padding: 2px 4px
}

.eyca-brand img {
    display: block;
    width: 150px;
    height: 40px;
    object-fit: contain
}

@media (max-width: 700px) {
    .eyca-brand {
        padding: 0
    }

    .eyca-brand img {
        width: 34px;
        height: 34px
    }
}
