/*
 * One — design system.
 * Brand: ink + One Blue with a cyan gradient accent; circle/ring motif ("één").
 * Modern CSS: custom properties, nesting, clamp() fluid type. No framework.
 */

/* ---------- Tokens ---------- */

:root {
    --ink: #0a0e1a;
    --ink-2: #10172e;
    --ink-3: #1a2342;
    --paper: #ffffff;
    --paper-2: #f5f7fb;
    --line: #e4e9f3;
    --line-dark: #26304f;

    --blue: #2e5cff;
    --blue-strong: #1d47e6;
    --blue-soft: #eaefff;
    --cyan: #22d3ee;

    --text: #253048;
    --muted: #5b6579;
    --text-inverse: #eef1f9;
    --muted-inverse: #9aa5c1;

    --gradient: linear-gradient(120deg, var(--blue) 0%, #2f7cf6 55%, var(--cyan) 100%);

    --font-display: 'Space Grotesk Variable', 'Space Grotesk', 'Inter Variable', system-ui, sans-serif;
    --font-body: 'Inter Variable', 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;

    --radius-s: 10px;
    --radius: 16px;
    --radius-l: 24px;

    --shadow-s: 0 1px 2px rgb(10 14 26 / 0.06), 0 2px 8px rgb(10 14 26 / 0.05);
    --shadow-m: 0 2px 6px rgb(10 14 26 / 0.06), 0 12px 32px rgb(10 14 26 / 0.10);
    --shadow-l: 0 8px 24px rgb(10 14 26 / 0.10), 0 24px 64px rgb(10 14 26 / 0.16);

    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 1rem;
    --space-4: 1.5rem;
    --space-5: 2.5rem;
    --space-6: 4rem;
    --space-7: 6rem;

    --nav-height: 4.5rem;
}

/* ---------- Base ---------- */

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

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

body {
    margin: 0;
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.65;
    color: var(--text);
    background: var(--paper);
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

img,
svg {
    max-width: 100%;
    height: auto;
    vertical-align: middle;
}

h1,
h2,
h3,
h4 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.12;
    letter-spacing: -0.02em;
    color: var(--ink);
    margin: 0 0 var(--space-3);
    text-wrap: balance;
}

h1 {
    font-size: clamp(2.4rem, 5.5vw, 3.9rem);
}

h2 {
    font-size: clamp(1.7rem, 3.4vw, 2.5rem);
}

h3 {
    font-size: clamp(1.2rem, 2vw, 1.45rem);
    line-height: 1.3;
}

p {
    margin: 0 0 var(--space-3);
}

a {
    color: var(--blue);
    text-decoration: none;
    text-underline-offset: 3px;

    &:hover {
        text-decoration: underline;
    }
}

ul,
ol {
    margin: 0 0 var(--space-3);
    padding-left: 1.4rem;
}

li {
    margin-bottom: var(--space-2);
}

strong {
    color: var(--ink);
}

:focus-visible {
    outline: 3px solid var(--cyan);
    outline-offset: 2px;
    border-radius: 4px;
}

::selection {
    background: var(--blue);
    color: #fff;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    top: -100px;
    left: var(--space-3);
    z-index: 200;
    padding: 0.6rem 1rem;
    background: var(--ink);
    color: #fff;
    border-radius: var(--radius-s);

    &:focus {
        top: var(--space-3);
    }
}

/* ---------- Layout ---------- */

.container {
    width: min(100% - 2.5rem, 72.5rem);
    margin-inline: auto;
}

.container--narrow {
    width: min(100% - 2.5rem, 50rem);
}

.section {
    padding-block: clamp(3.5rem, 8vw, 6.5rem);

    &.section--soft {
        background: var(--paper-2);
    }

    &.section--dark {
        background:
            radial-gradient(60rem 30rem at 85% -10%, rgb(46 92 255 / 0.22), transparent 60%),
            radial-gradient(40rem 24rem at -10% 110%, rgb(34 211 238 / 0.12), transparent 60%),
            var(--ink);
        color: var(--text-inverse);

        h1,
        h2,
        h3,
        h4,
        strong {
            color: #fff;
        }

        a:not(.btn) {
            color: var(--cyan);
        }
    }

    &.section--flush-top {
        padding-top: 0;
    }
}

.section-head {
    max-width: 46rem;
    margin-bottom: clamp(2rem, 5vw, 3.5rem);

    &.section-head--center {
        margin-inline: auto;
        text-align: center;
    }

    p {
        font-size: 1.15rem;
        color: var(--muted);
    }

    .section--dark & p {
        color: var(--muted-inverse);
    }
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: var(--space-3);
    font-family: var(--font-display);
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--blue);

    &::before {
        content: '';
        width: 0.55rem;
        height: 0.55rem;
        border-radius: 50%;
        background: var(--gradient);
        flex-shrink: 0;
    }

    .section--dark & {
        color: var(--cyan);
    }
}

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

.btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    padding: 0.85rem 1.6rem;
    border: 2px solid transparent;
    border-radius: 999px;
    font-family: var(--font-display);
    font-size: 1rem !important;
    font-weight: 600;
    letter-spacing: 0.01em;
    line-height: 1.2;
    cursor: pointer;
    text-decoration: none;
    transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;

    &:hover {
        text-decoration: none;
        transform: translateY(-1px);
    }

    &:active {
        transform: translateY(0);
    }

    &:disabled {
        opacity: 0.55;
        cursor: not-allowed;
        transform: none;
    }
}

.btn--primary {
    background: var(--blue);
    color: #fff !important;
    box-shadow: 0 8px 20px rgb(46 92 255 / 0.32);

    &:hover {
        background: var(--blue-strong);
        color: #fff;
        box-shadow: 0 10px 26px rgb(46 92 255 / 0.4);
    }
}

.btn--ghost {
    border-color: var(--line);
    color: var(--ink);
    background: transparent;

    &:hover {
        border-color: var(--blue);
        color: var(--blue);
    }

    :is(.section--dark, .hero) & {
        border-color: rgb(255 255 255 / 0.35);
        color: #fff;

        &:hover {
            border-color: var(--cyan);
            color: var(--cyan);
        }
    }
}

.btn--light {
    background: #fff;
    color: var(--ink);

    &:hover {
        color: var(--blue-strong);
        box-shadow: var(--shadow-m);
    }
}

.btn--small {
    padding: 0.55rem 1.1rem !important;
    font-size: 0.92rem !important;
}

.btn-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-3);
}

.btn-note {
    font-size: 0.9rem;
    color: var(--muted);
}

/* ---------- Navigation ---------- */

.nav {
    position: sticky;
    top: 0;
    z-index: 100;
    height: var(--nav-height);
    display: flex;
    align-items: center;
    background: rgb(255 255 255 / 0.86);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;

    &.nav--scrolled {
        border-bottom-color: var(--line);
        box-shadow: 0 4px 24px rgb(10 14 26 / 0.06);
    }
}

.nav-inner {
    display: flex;
    align-items: center;
    gap: var(--space-4);
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-family: var(--font-display);
    font-size: 1.45rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--ink);

    &:hover {
        text-decoration: none;
    }

    svg {
        width: 2rem;
        height: 2rem;
        flex-shrink: 0;
    }
}

.nav-links {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    margin-left: auto;
    margin-bottom: 0;
    list-style: none;
    padding: 0;

    li {
        margin: 0;
    }

    a {
        font-size: 0.98rem;
        font-weight: 500;
        color: var(--text);

        &:hover {
            color: var(--blue);
            text-decoration: none;
        }

        &[aria-current='page'] {
            color: var(--blue);
            font-weight: 600;
        }
    }
}

.nav-toggle {
    display: none;
    margin-left: auto;
    padding: 0.5rem;
    border: 0;
    background: none;
    cursor: pointer;
    color: var(--ink);
}

@media (max-width: 980px) {
    .nav-links {
        position: fixed;
        inset: var(--nav-height) 0 auto 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        margin: 0;
        padding: var(--space-3) var(--space-4) var(--space-5);
        background: #fff;
        border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow-l);
        display: none;

        a {
            display: block;
            padding: 0.8rem 0;
            font-size: 1.1rem;
        }

        .nav--open & {
            display: flex;
        }
    }

    .nav-toggle {
        display: inline-flex;
    }

    .nav-cta {
        margin-top: var(--space-3);
    }
}

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

.hero {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(70rem 36rem at 80% -20%, rgb(46 92 255 / 0.28), transparent 62%),
        radial-gradient(50rem 30rem at -15% 115%, rgb(34 211 238 / 0.16), transparent 60%),
        var(--ink);
    color: var(--text-inverse);
    padding-block: clamp(4.5rem, 11vw, 8.5rem);

    h1 {
        color: #fff;
        margin-bottom: var(--space-4);

        .accent {
            background: var(--gradient);
            -webkit-background-clip: text;
            background-clip: text;
            color: transparent;
        }
    }

    .lead {
        font-size: clamp(1.1rem, 2vw, 1.3rem);
        color: var(--muted-inverse);
        max-width: 38rem;
        margin-bottom: var(--space-5);
    }
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
    gap: clamp(2rem, 6vw, 5rem);
    align-items: center;
}

.hero--page {
    padding-block: clamp(3.5rem, 8vw, 5.5rem);

    .lead {
        margin-bottom: 0;
    }
}

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

    &::before,
    &::after {
        content: '';
        position: absolute;
        border: 1px solid rgb(255 255 255 / 0.07);
        border-radius: 50%;
    }

    &::before {
        width: 44rem;
        height: 44rem;
        right: -14rem;
        top: -18rem;
    }

    &::after {
        width: 28rem;
        height: 28rem;
        right: -4rem;
        top: -8rem;
        border-color: rgb(255 255 255 / 0.1);
    }
}

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

/* ---------- Mock UI (hero visual) ---------- */

.mock {
    background: rgb(255 255 255 / 0.045);
    border: 1px solid rgb(255 255 255 / 0.12);
    border-radius: var(--radius-l);
    padding: var(--space-3);
    backdrop-filter: blur(6px);
    box-shadow: var(--shadow-l);
}

.mock-bar {
    display: flex;
    gap: 0.4rem;
    margin-bottom: var(--space-3);

    span {
        width: 0.6rem;
        height: 0.6rem;
        border-radius: 50%;
        background: rgb(255 255 255 / 0.18);

        &:first-child {
            background: var(--cyan);
        }
    }
}

.mock-rows {
    display: grid;
    gap: 0.7rem;
}

.mock-row {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    background: rgb(255 255 255 / 0.05);
    border: 1px solid rgb(255 255 255 / 0.08);
    border-radius: var(--radius-s);
    padding: 0.7rem 0.9rem;
    font-size: 0.85rem;
    color: var(--muted-inverse);

    .dot {
        width: 0.55rem;
        height: 0.55rem;
        border-radius: 50%;
        background: var(--cyan);
        flex-shrink: 0;
    }

    .dot--blue {
        background: var(--blue);
    }

    .dot--warn {
        background: #fbbf24;
    }

    strong {
        color: #fff;
        font-weight: 600;
    }

    .tag {
        margin-left: auto;
        font-size: 0.72rem;
        padding: 0.15rem 0.55rem;
        border-radius: 999px;
        background: rgb(34 211 238 / 0.14);
        color: var(--cyan);
        white-space: nowrap;
    }
}

/* ---------- Cards ---------- */

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr));
    gap: var(--space-4);
}

.card-grid--dense {
    grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
}

.card {
    position: relative;
    display: flex;
    flex-direction: column;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: var(--space-4);
    box-shadow: var(--shadow-s);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;

    h3 {
        margin-bottom: var(--space-2);
    }

    p {
        color: var(--muted);
        margin-bottom: 0;
        font-size: 0.98rem;
    }
}

a.card:hover,
.card--link:hover {
    text-decoration: none;
    transform: translateY(-3px);
    border-color: rgb(46 92 255 / 0.4);
    box-shadow: var(--shadow-m);
}

a.card {
    color: inherit;
}

.card-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    margin-bottom: var(--space-3);
    border-radius: 12px;
    background: var(--blue-soft);
    color: var(--blue);

    svg {
        width: 1.4rem;
        height: 1.4rem;
    }
}

.card-more {
    margin-top: auto;
    padding-top: var(--space-3);
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--blue);
}

.section--dark .card {
    background: rgb(255 255 255 / 0.04);
    border-color: var(--line-dark);

    h3 {
        color: #fff;
    }

    p {
        color: var(--muted-inverse);
    }
}

/* ---------- Chain (numbered process) ---------- */

.chain {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: var(--space-3);
    counter-reset: chain;
}

.chain li {
    position: relative;
    display: grid;
    grid-template-columns: 2.6rem 1fr;
    gap: var(--space-3);
    align-items: start;
    counter-increment: chain;
    margin: 0;

    &::before {
        content: counter(chain);
        display: flex;
        align-items: center;
        justify-content: center;
        width: 2.6rem;
        height: 2.6rem;
        border-radius: 50%;
        background: var(--blue-soft);
        color: var(--blue);
        font-family: var(--font-display);
        font-weight: 700;
    }

    strong {
        display: block;
    }

    .pain {
        color: var(--muted);
        font-size: 0.95rem;
    }
}

.section--dark .chain li {
    &::before {
        background: rgb(46 92 255 / 0.22);
        color: var(--cyan);
    }

    .pain {
        color: var(--muted-inverse);
    }
}

/* ---------- Steps (how it works) ---------- */

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
    gap: var(--space-4);
    counter-reset: steps;
}

.step {
    counter-increment: steps;
    padding: var(--space-4);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--paper);

    &::before {
        content: '0' counter(steps);
        display: block;
        font-family: var(--font-display);
        font-size: 2rem;
        font-weight: 700;
        background: var(--gradient);
        -webkit-background-clip: text;
        background-clip: text;
        color: transparent;
        margin-bottom: var(--space-2);
    }

    p {
        color: var(--muted);
        margin: 0;
        font-size: 0.98rem;
    }
}

/* ---------- FAQ ---------- */

.faq {
    display: grid;
    gap: var(--space-2);
}

.faq details {
    border: 1px solid var(--line);
    border-radius: var(--radius-s);
    background: var(--paper);

    &[open] {
        border-color: rgb(46 92 255 / 0.4);
        box-shadow: var(--shadow-s);

        summary::after {
            transform: rotate(45deg);
        }
    }
}

.faq summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-3);
    padding: 1rem 1.2rem;
    cursor: pointer;
    font-weight: 600;
    color: var(--ink);
    list-style: none;

    &::-webkit-details-marker {
        display: none;
    }

    &::after {
        content: '+';
        font-family: var(--font-display);
        font-size: 1.4rem;
        line-height: 1;
        color: var(--blue);
        transition: transform 0.2s ease;
        flex-shrink: 0;
    }
}

.faq .faq-answer {
    padding: 0 1.2rem 1.1rem;
    color: var(--muted);
}

/* ---------- Prose (blog & legal) ---------- */

.prose {
    font-size: 1.08rem;

    h2 {
        margin-top: var(--space-5);
        font-size: 1.65rem;
    }

    h3 {
        margin-top: var(--space-4);
    }

    ul li,
    ol li {
        margin-bottom: 0.4rem;
    }

    blockquote {
        margin: var(--space-4) 0;
        padding: var(--space-3) var(--space-4);
        border-left: 4px solid var(--blue);
        background: var(--paper-2);
        border-radius: 0 var(--radius-s) var(--radius-s) 0;
        color: var(--ink);
        font-family: var(--font-display);
        font-size: 1.15rem;
    }
}

/* ---------- Meta rows, badges ---------- */

.meta-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 1rem;
    font-size: 0.92rem;
    color: var(--muted);
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 600;
    background: var(--blue-soft);
    color: var(--blue-strong);
}

.badge--outline {
    background: transparent;
    border: 1px solid var(--line);
    color: var(--muted);
}

.badge--dark {
    background: rgb(255 255 255 / 0.1);
    color: #fff;
}

/* ---------- Breadcrumbs ---------- */

.breadcrumbs {
    margin-bottom: var(--space-4);
    font-size: 0.9rem;

    ol {
        display: flex;
        flex-wrap: wrap;
        gap: 0.35rem;
        list-style: none;
        margin: 0;
        padding: 0;
    }

    li {
        margin: 0;
        display: flex;
        align-items: center;
        gap: 0.35rem;
        color: var(--muted-inverse);

        &:not(:first-child)::before {
            content: '/';
            opacity: 0.5;
        }
    }

    a {
        color: inherit;

        &:hover {
            color: var(--cyan);
        }
    }
}

/* ---------- CTA block ---------- */

.cta-block {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-l);
    padding: clamp(2rem, 5vw, 3.5rem);
    background:
        radial-gradient(40rem 20rem at 90% -30%, rgb(34 211 238 / 0.35), transparent 60%),
        linear-gradient(120deg, var(--blue-strong), var(--blue));
    color: #fff;
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) auto;
    gap: var(--space-4);
    align-items: center;

    h2,
    h3 {
        color: #fff;
        margin-bottom: var(--space-2);
    }

    p {
        color: rgb(255 255 255 / 0.85);
        margin: 0;
    }

    &::after {
        content: '';
        position: absolute;
        width: 18rem;
        height: 18rem;
        border: 1px solid rgb(255 255 255 / 0.18);
        border-radius: 50%;
        right: -6rem;
        bottom: -9rem;
        pointer-events: none;
    }
}

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

/* ---------- Calculator ---------- */

.calc {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius-l);
    box-shadow: var(--shadow-m);
    padding: clamp(1.5rem, 4vw, 2.5rem);
    color: var(--text);
}

.calc-fields {
    display: grid;
    gap: var(--space-4);
}

.calc-field {
    label {
        display: flex;
        justify-content: space-between;
        align-items: baseline;
        gap: var(--space-3);
        font-weight: 600;
        color: var(--ink);
        margin-bottom: 0.6rem;

        output {
            font-family: var(--font-display);
            color: var(--blue);
            font-size: 1.15rem;
            white-space: nowrap;
        }
    }
}

input[type='range'] {
    width: 100%;
    height: 0.5rem;
    appearance: none;
    -webkit-appearance: none;
    background: linear-gradient(to right, var(--blue) var(--fill, 50%), var(--line) var(--fill, 50%));
    border-radius: 999px;
    cursor: pointer;

    &::-webkit-slider-thumb {
        appearance: none;
        -webkit-appearance: none;
        width: 1.5rem;
        height: 1.5rem;
        border-radius: 50%;
        background: #fff;
        border: 3px solid var(--blue);
        box-shadow: var(--shadow-s);
    }

    &::-moz-range-thumb {
        width: 1.2rem;
        height: 1.2rem;
        border-radius: 50%;
        background: #fff;
        border: 3px solid var(--blue);
        box-shadow: var(--shadow-s);
    }
}

.calc-result {
    margin-top: var(--space-4);
    padding: var(--space-4);
    border-radius: var(--radius);
    background: var(--ink);
    color: var(--text-inverse);
    text-align: center;

    .calc-amount {
        display: block;
        font-family: var(--font-display);
        font-size: clamp(2.2rem, 5vw, 3.2rem);
        font-weight: 700;
        background: var(--gradient);
        -webkit-background-clip: text;
        background-clip: text;
        color: transparent;
        line-height: 1.1;
    }

    .calc-sub {
        color: var(--muted-inverse);
        font-size: 0.95rem;
        margin: 0.4rem 0 0;
    }
}

.calc-note {
    margin-top: var(--space-3);
    font-size: 0.88rem;
    color: var(--muted);
    text-align: center;
}

/* ---------- Forms ---------- */

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-3);
}

.form-field {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;

    &.form-field--full {
        grid-column: 1 / -1;
    }

    label {
        font-weight: 600;
        font-size: 0.95rem;
        color: var(--ink);

        .optional {
            font-weight: 400;
            color: var(--muted);
        }
    }
}

.form-input {
    width: 100%;
    padding: 0.8rem 1rem;
    font: inherit;
    color: var(--ink);
    background: var(--paper);
    border: 1.5px solid var(--line);
    border-radius: var(--radius-s);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;

    &:focus {
        outline: none;
        border-color: var(--blue);
        box-shadow: 0 0 0 4px rgb(46 92 255 / 0.14);
    }

    &.form-input--error {
        border-color: #dc2626;
    }
}

textarea.form-input {
    resize: vertical;
    min-height: 7rem;
}

.form-error {
    font-size: 0.88rem;
    color: #dc2626;
}

.form-check {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    font-size: 0.92rem;
    color: var(--muted);

    input {
        margin-top: 0.3rem;
        width: 1.05rem;
        height: 1.05rem;
        accent-color: var(--blue);
        flex-shrink: 0;
    }
}

.form-success {
    padding: var(--space-4);
    border-radius: var(--radius);
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #065f46;

    h3 {
        color: #065f46;
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }

    p:last-child {
        margin-bottom: 0;
    }
}

/* Honeypot field: visually gone, still in the DOM for bots. */
.hp-field {
    position: absolute !important;
    left: -9999px !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

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

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

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
    gap: var(--space-4);
}

.stat {
    text-align: center;

    .stat-number {
        display: block;
        font-family: var(--font-display);
        font-size: clamp(2rem, 4.5vw, 3rem);
        font-weight: 700;
        color: var(--ink);

        .section--dark & {
            background: var(--gradient);
            -webkit-background-clip: text;
            background-clip: text;
            color: transparent;
        }
    }

    .stat-label {
        font-size: 0.92rem;
        color: var(--muted);

        .section--dark & {
            color: var(--muted-inverse);
        }
    }
}

/* ---------- Blog ---------- */

.post-card {
    display: flex;
    flex-direction: column;
    height: 100%;

    .post-cover {
        border-radius: var(--radius-s);
        margin-bottom: var(--space-3);
        aspect-ratio: 16 / 8.5;
        background:
            radial-gradient(14rem 8rem at 80% 0%, rgb(34 211 238 / 0.35), transparent 65%),
            var(--ink);
        display: flex;
        align-items: flex-end;
        padding: var(--space-3);

        .badge {
            background: rgb(255 255 255 / 0.12);
            color: #fff;
        }
    }

    h3 a {
        color: var(--ink);

        &:hover {
            color: var(--blue);
            text-decoration: none;
        }
    }

    .post-excerpt {
        color: var(--muted);
        font-size: 0.98rem;
        margin-bottom: var(--space-3);
    }

    .meta-row {
        margin-top: auto;
    }
}

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: var(--space-5);

    a {
        padding: 0.45rem 1rem;
        border-radius: 999px;
        border: 1.5px solid var(--line);
        font-size: 0.92rem;
        font-weight: 600;
        color: var(--text);

        &:hover {
            border-color: var(--blue);
            color: var(--blue);
            text-decoration: none;
        }

        &.active {
            background: var(--ink);
            border-color: var(--ink);
            color: #fff;
        }
    }
}

.search-box {
    position: relative;
    margin-bottom: var(--space-4);

    .search-results {
        position: absolute;
        top: calc(100% + 0.5rem);
        left: 0;
        right: 0;
        z-index: 50;
        background: var(--paper);
        border: 1px solid var(--line);
        border-radius: var(--radius-s);
        box-shadow: var(--shadow-l);
        max-height: 22rem;
        overflow: auto;

        a {
            display: block;
            padding: 0.8rem 1rem;
            color: var(--ink);
            border-bottom: 1px solid var(--line);

            &:last-child {
                border-bottom: 0;
            }

            &:hover {
                background: var(--paper-2);
                text-decoration: none;
            }

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

        .search-empty {
            display: block;
            padding: 0.8rem 1rem;
            color: var(--muted);
        }
    }
}

/* ---------- Pricing ---------- */

.price-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
    gap: var(--space-4);
    align-items: stretch;
}

.price-card {
    display: flex;
    flex-direction: column;
    border: 1.5px solid var(--line);
    border-radius: var(--radius);
    padding: var(--space-4);
    background: var(--paper);

    &.price-card--featured {
        border-color: var(--blue);
        box-shadow: var(--shadow-m);
    }

    .price {
        font-family: var(--font-display);
        font-size: 1.9rem;
        font-weight: 700;
        color: var(--ink);
        margin-bottom: 0.2rem;

        small {
            font-size: 1rem;
            font-weight: 500;
            color: var(--muted);
        }
    }

    ul {
        list-style: none;
        padding: 0;
        margin: var(--space-3) 0 var(--space-4);

        li {
            padding-left: 1.6rem;
            position: relative;
            font-size: 0.96rem;
            color: var(--muted);

            &::before {
                content: '';
                position: absolute;
                left: 0;
                top: 0.5rem;
                width: 0.9rem;
                height: 0.5rem;
                border-left: 2.5px solid var(--blue);
                border-bottom: 2.5px solid var(--blue);
                transform: rotate(-45deg);
            }
        }
    }

    .btn {
        margin-top: auto;
    }
}

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

.footer {
    background: var(--ink);
    color: var(--muted-inverse);
    padding: var(--space-6) 0 var(--space-4);
    font-size: 0.95rem;

    h4 {
        color: #fff;
        font-size: 1rem;
        margin-bottom: var(--space-3);
    }

    a {
        color: var(--muted-inverse);

        &:hover {
            color: #fff;
        }
    }

    ul {
        list-style: none;
        margin: 0;
        padding: 0;
    }

    li {
        margin-bottom: 0.55rem;
    }
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
    gap: var(--space-5);
    padding-bottom: var(--space-5);
    border-bottom: 1px solid var(--line-dark);

    .logo {
        color: #fff;
        margin-bottom: var(--space-3);
    }
}

.footer-bottom {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: var(--space-3);
    padding-top: var(--space-4);
    font-size: 0.88rem;
}

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

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

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

/* Only hide reveal targets when JS actually runs (progressive enhancement). */
.js .reveal {
    opacity: 0;
    transform: translateY(1.25rem);
    transition: opacity 0.6s ease, transform 0.6s ease;

    &.reveal--visible {
        opacity: 1;
        transform: none;
    }
}

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

    .js .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .btn,
    .card {
        transition: none;
    }
}

/* ---------- Helpers ---------- */

.text-center {
    text-align: center;
}

.mt-0 {
    margin-top: 0;
}

.mb-0 {
    margin-bottom: 0;
}

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-5);
    align-items: start;
}

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

.divider {
    border: 0;
    border-top: 1px solid var(--line);
    margin: var(--space-5) 0;
}

/* ---------------------------------------------------------------------------
   Cookie consent banner
   Bottom-left card, out of the way of the content and of the mobile nav.
   --------------------------------------------------------------------------- */

.cookie-banner {
    position: fixed;
    z-index: 60;
    inset-block-end: var(--space-3);
    inset-inline-start: var(--space-3);
    inline-size: min(26rem, calc(100vw - var(--space-3) * 2));

    &[hidden] {
        display: none;
    }

    .cookie-banner__box {
        position: relative;
        padding: var(--space-4);
        background: var(--paper);
        border: 1px solid var(--line);
        border-radius: var(--radius);
        box-shadow: var(--shadow-l);
    }

    .cookie-banner__close {
        position: absolute;
        inset-block-start: var(--space-2);
        inset-inline-end: var(--space-2);
        display: grid;
        place-items: center;
        inline-size: 2rem;
        block-size: 2rem;
        padding: 0;
        color: var(--muted);
        background: none;
        border: 0;
        border-radius: var(--radius-s);
        cursor: pointer;

        &:hover {
            color: var(--text);
            background: var(--paper-2);
        }
    }

    .cookie-banner__eyebrow {
        margin: 0 0 var(--space-1);
        font-size: 0.75rem;
        font-weight: 600;
        letter-spacing: 0.08em;
        text-transform: uppercase;
        color: var(--blue);
    }

    .cookie-banner__title {
        margin: 0 0 var(--space-2);
        font-family: var(--font-display);
        font-size: 1.0625rem;
        line-height: 1.35;
    }

    .cookie-banner__text {
        margin: 0 0 var(--space-2);
        font-size: 0.875rem;
        color: var(--muted);
    }

    .cookie-banner__fineprint {
        margin: 0 0 var(--space-4);
        font-size: 0.8125rem;
        color: var(--muted);
    }

    .cookie-banner__actions {
        display: flex;
        gap: var(--space-2);

        .btn {
            flex: 1;
        }
    }
}

@media (max-width: 560px) {
    .cookie-banner {
        inset-inline: var(--space-3);
        inline-size: auto;
    }
}

.footer-link-button {
    padding: 0;
    font: inherit;
    color: inherit;
    background: none;
    border: 0;
    cursor: pointer;

    &:hover {
        text-decoration: underline;
    }
}
