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

:root {
    color-scheme: light dark;
    --bg: #f7f8f3;
    --surface: #e9eee5;
    --ink: #19251e;
    --muted: #526259;
    --accent: #245d43;
    --on: #fff;
    --line: #cbd5ca;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #111a15;
        --surface: #202f26;
        --ink: #e4eee5;
        --muted: #b6c7ba;
        --accent: #a5d9b5;
        --on: #173a27;
        --line: #405247;
    }
}

html {
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font: 16px/1.65 system-ui, -apple-system, sans-serif;
    overflow-x: clip;
}

header,
main,
footer {
    max-width: 1120px;
    margin: auto;
    padding: 24px clamp(16px, 5vw, 64px);
}

header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px 24px;
    flex-wrap: wrap;
    border-bottom: 1px solid var(--line);
}

.brand {
    display: inline-flex;
    align-items: flex-end;
    font-size: clamp(26px, 4vw, 32px);
    font-weight: 850;
    line-height: 1;
    letter-spacing: -2px;
    text-decoration: none;
    color: var(--ink);
    flex-shrink: 0;
}

.brand svg,
.brand img {
    height: 0.74em;
    width: auto;
    display: block;
    flex-shrink: 0;
    margin-right: 8px;
}

.brand span,
a {
    color: var(--accent);
}

nav {
    display: flex;
    gap: 6px 8px;
    flex-wrap: wrap;
    align-items: center;
}

nav a {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 24px;
    text-decoration: none;
    font-size: 14px;
    white-space: nowrap;
}

nav a[aria-current] {
    background: var(--surface);
    font-weight: 700;
}

main {
    min-height: 70vh;
    padding-block: clamp(32px, 6vw, 56px);
    overflow-wrap: break-word;
}

h1 {
    font-size: clamp(32px, 6.5vw, 76px);
    line-height: 1.08;
    letter-spacing: -0.045em;
    margin: 12px 0 24px;
}

h2 {
    line-height: 1.25;
    letter-spacing: -0.025em;
}

p {
    max-width: 72ch;
}

.eyebrow {
    font-size: 12px;
    letter-spacing: 0.13em;
    font-weight: 750;
    color: var(--accent);
}

.lead {
    font-size: clamp(17px, 2.2vw, 20px);
    color: var(--muted);
}

.button {
    display: inline-block;
    background: var(--accent);
    color: var(--on);
    padding: 14px 24px;
    border-radius: 32px;
    text-decoration: none;
    font-weight: 650;
    text-align: center;
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: clamp(24px, 4vw, 32px);
    align-items: center;
}

.preview,
article:not(.legal) {
    background: var(--surface);
    border-radius: clamp(22px, 3vw, 32px);
    padding: clamp(20px, 3.5vw, 28px);
}

.preview h2 {
    font-size: clamp(34px, 5vw, 48px);
    margin: 0;
}

.preview small {
    display: block;
    color: var(--muted);
}

.bars {
    height: 130px;
    display: flex;
    gap: 12px;
    align-items: end;
}

.bars i {
    flex: 1;
    background: var(--accent);
    border-radius: 14px 14px 4px 4px;
}

.features {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin: clamp(32px, 5vw, 48px) 0;
}

.legal {
    max-width: 760px;
    margin: auto;
}

.legal h1 {
    font-size: clamp(30px, 5.5vw, 60px);
}

.legal h2 {
    margin-top: 36px;
}

details {
    padding: 18px 0;
    border-bottom: 1px solid var(--line);
}

summary {
    cursor: pointer;
    font-weight: 650;
}

footer {
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 14px;
    overflow-wrap: anywhere;
}

a:focus-visible,
summary:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 4px;
}

/* Tablet */
@media (max-width: 960px) {
    .hero {
        grid-template-columns: 1fr;
    }

    .features {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .features article:last-child:nth-child(odd) {
        grid-column: 1 / -1;
    }
}

/* Mobile */
@media (max-width: 640px) {
    header {
        padding-block: 16px;
    }

    nav {
        width: 100%;
        gap: 4px 6px;
    }

    nav a {
        padding: 8px 10px;
        font-size: 13px;
    }

    .features {
        grid-template-columns: 1fr;
    }

    .features article:last-child:nth-child(odd) {
        grid-column: auto;
    }

    .button {
        width: 100%;
    }

    .bars {
        height: 110px;
        gap: 8px;
    }
}
