/* Toolbridge, landingspagina.
   Handgeschreven, zonder framework of JavaScript. Huisstijl afgeleid van basiqcompany.nl
   (design-handover/toolbridge): wit als basis, zware koppen, hard contrast, vierkante vormen,
   lijnen in plaats van kaders. Eigen accentkleur: lime in plaats van amber.
   Componenten gebruiken alleen de custom properties hieronder, nooit losse kleurwaarden.

   Contrastregels: tekst op lime is altijd ink, nooit wit. Lime nooit als tekstkleur op wit
   (gebruik .marker). ink-muted alleen op wit, niet op surface-alt of lime. */

/* ───────────── Lettertypes (self-hosted, SIL OFL; zie fonts/LICENSE.txt) ───────────── */
@font-face {
    font-family: "Plus Jakarta Sans";
    src: url("fonts/PlusJakartaSansVariable.woff2") format("woff2");
    font-weight: 200 800;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Inter";
    src: url("fonts/InterVariable.woff2") format("woff2");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

/* ───────────── Tokens ───────────── */
:root {
    color-scheme: light;

    /* Kleur */
    --surface: #ffffff;
    --surface-alt: #f2f5f7;
    --lime: #84cc16;
    --lime-soft: #d9f99d;
    --ink: #1e293b;
    --ink-muted: #67768e;
    --line: #eaeaea;
    --link: var(--ink);
    --ink-hover: color-mix(in srgb, var(--ink) 82%, var(--surface));
    --danger: #b42318;

    /* Typografie */
    --font-display: "Plus Jakarta Sans", ui-sans-serif, system-ui, "Segoe UI", Arial, sans-serif;
    --font-sans: "Inter", ui-sans-serif, system-ui, "Segoe UI", Arial, sans-serif;
    --font-mono: ui-monospace, "Cascadia Code", Consolas, monospace;

    --text-h1: clamp(44px, 6.4vw, 92px);
    --text-h1-hero: clamp(40px, 3.2vw + 24px, 68px); /* h1 deelt de hero met het chatvenster */
    --text-h2: clamp(36px, 4.4vw, 60px);
    --text-h2-closing: clamp(40px, 5.6vw, 80px);
    --text-h3: 24px;
    --text-intro: clamp(19px, 1.2vw + 14px, 21px);
    --text-body: 18px;
    --text-small: 16px;
    --text-overline: 14px;

    /* Ruimte en vorm */
    --container: 1280px;
    --gutter: 32px;
    --gap-buttons: 12px;
    --gap-cards: 24px;
    --gap-steps: 32px;
    --gap-columns: 64px;
    --section-y: 128px;
    --hero-top: 96px;
    --hero-bottom: 112px;
    --band-y: 112px;
    --radius-none: 0;
    --radius-xs: 2px;

    /* Schaduw: uitsluitend onder het chatvenster. */
    --shadow-window: 0 24px 48px -24px color-mix(in srgb, var(--ink) 35%, transparent);

    /* Focusring; vlakken overschrijven de kleur zodat hij zichtbaar blijft. */
    --focus-ring: var(--ink);
}

@media (max-width: 768px) {
    :root {
        --gutter: 20px;
        --gap-columns: 32px;
        --section-y: 64px;
        --hero-top: 48px;
        --hero-bottom: 56px;
        --band-y: 64px;
    }
}

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

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

@media (prefers-reduced-motion: no-preference) {
    html { scroll-behavior: smooth; }
}

body {
    margin: 0;
    background: var(--surface);
    color: var(--ink);
    font-family: var(--font-sans);
    font-size: var(--text-body);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: clip;
}

h1, h2, h3 {
    margin: 0;
    color: inherit;
    font-family: var(--font-display);
    font-weight: 800;
    text-wrap: balance;
}
h1 { font-size: var(--text-h1); line-height: 1.02; letter-spacing: -0.035em; }
h2 { font-size: var(--text-h2); line-height: 1.08; letter-spacing: -0.03em; }
h3 { font-size: var(--text-h3); line-height: 1.3; font-weight: 700; }

p { margin: 0; text-wrap: pretty; }

/* Links: ink-tekst met een lime onderstreping; bij hover wordt de onderstreping ink. */
a {
    color: var(--link);
    text-decoration-line: underline;
    text-decoration-color: var(--lime);
    text-decoration-thickness: 2px;
    text-underline-offset: 0.2em;
    transition: text-decoration-color .15s;
}
a:hover { color: var(--ink); text-decoration-color: currentColor; }

svg { display: block; }
code { font-family: var(--font-mono); font-size: 0.9em; }
::selection { background: var(--lime-soft); color: var(--ink); }

:focus-visible {
    outline: 3px solid var(--focus-ring);
    outline-offset: 3px;
}

.container {
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
    padding-inline: var(--gutter);
}

.muted { color: var(--ink-muted); }

.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0;
}

.skip-link {
    position: absolute; top: 8px; left: 8px; z-index: 100;
    padding: 12px 20px;
    background: var(--ink); color: var(--surface);
    font-weight: 600; text-decoration: none;
    transform: translateY(-200%);
}
.skip-link:focus { transform: none; color: var(--surface); }

.icon { width: 1.25em; height: 1.25em; flex: none; }

/* ───────────── Vlakken ───────────── */
.surface-alt { background: var(--surface-alt); color: var(--ink); }

/* Op lime is alles ink: tekst, onderstreping, streepjes en de focusring. */
.surface-lime {
    --focus-ring: var(--ink);
    background: var(--lime);
    color: var(--ink);
}
.surface-lime a:not(.btn) { color: var(--ink); text-decoration-color: var(--ink); }

/* ───────────── Overline & markering ───────────── */
.overline {
    display: inline-flex; align-items: center; gap: 10px;
    font-family: var(--font-sans);
    font-size: var(--text-overline); font-weight: 600; line-height: 1.4;
    letter-spacing: 0.08em; text-transform: uppercase;
}
.overline::before {
    content: ""; flex: none;
    width: 28px; height: 4px;
    background: var(--lime);
}
.surface-lime .overline::before { background: var(--ink); }

/* Lime markering onder een woord: de enige manier om lime "in" een kop op wit te zetten. */
.marker { box-shadow: inset 0 -0.32em 0 var(--lime); }

/* ───────────── Knoppen ───────────── */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 12px;
    padding: 18px 30px;
    border: 2px solid transparent; border-radius: var(--radius-none);
    font-family: var(--font-sans); font-size: 18px; font-weight: 600; line-height: 1.2;
    text-decoration: none; white-space: nowrap; cursor: pointer;
    transition: background-color .15s, color .15s, border-color .15s;
}

.btn--primary { background: var(--ink); border-color: var(--ink); color: var(--surface); }
.btn--primary:hover { background: var(--ink-hover); border-color: var(--ink-hover); color: var(--surface); }
.btn--primary .btn__arrow { color: var(--lime); }

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

/* Alleen op een ink-vlak. */
.btn--lime { background: var(--lime); border-color: var(--lime); color: var(--ink); }
.btn--lime:hover { background: var(--lime-soft); border-color: var(--lime-soft); color: var(--ink); }

.btn--small { padding: 10px 20px; font-size: 16px; }

.btn__arrow { width: 18px; height: 18px; }

/* ───────────── Velden ───────────── */
.input {
    width: 100%; min-width: 0;
    padding: 16px 18px;
    border: 2px solid var(--ink); border-radius: var(--radius-none);
    background: var(--surface); color: var(--ink);
    font-family: var(--font-sans); font-size: 18px; line-height: 1.2; /* ≥16px: geen auto-zoom op iOS */
}
.input::placeholder { color: var(--ink-muted); opacity: 1; }
.input:focus-visible { outline-offset: 0; }
.input.invalid { border-color: var(--danger); }
.input--small { margin-top: 12px; padding-block: 12px; font-size: 16px; }

/* ───────────── Header ───────────── */
.site-header { background: var(--surface); border-bottom: 1px solid var(--line); }

.site-header__inner {
    display: flex; align-items: center; justify-content: space-between; gap: 24px;
    padding-block: 20px;
}

/* Woordmerk: tekst met een klein lime vierkant ervoor, geen icoon. */
.wordmark {
    display: inline-flex; align-items: center; gap: 10px;
    font-family: var(--font-display); font-size: 26px; font-weight: 700; line-height: 1.2;
    letter-spacing: -0.02em;
    color: var(--ink); text-decoration: none;
}
.wordmark::before {
    content: ""; flex: none;
    width: 14px; height: 14px;
    background: var(--lime);
}
.wordmark:hover { color: var(--ink); }
.wordmark--small { font-size: 22px; }
.wordmark--small::before { width: 12px; height: 12px; }

.site-nav { display: flex; align-items: center; gap: 16px 32px; }
.site-nav__list { display: flex; flex-wrap: wrap; gap: 8px 32px; margin: 0; padding: 0; list-style: none; }
.site-nav__list a {
    color: var(--ink);
    font-size: var(--text-small); font-weight: 500;
    text-decoration: none;
}
.site-nav__list a:hover,
.site-nav__list a[aria-current="page"] {
    text-decoration-line: underline;
    text-decoration-color: var(--lime);
}

@media (max-width: 900px) {
    .site-nav__list { display: none; }
}

/* ───────────── Secties ───────────── */
.section { padding-block: var(--section-y); }

.section-header { margin-bottom: 56px; }
.section-header h2 { max-width: 760px; margin-top: 20px; }
.section-header p:not(.overline) {
    max-width: 620px; margin-top: 20px;
    font-size: var(--text-intro); line-height: 1.6;
    color: var(--ink-muted);
}
/* ink-muted heeft te weinig contrast op het lichtgrijze vlak. */
.surface-alt .section-header p:not(.overline) { color: var(--ink); }

/* Gesplitst: links overline + kop, rechts de intro. */
.section-header--split {
    display: flex; flex-wrap: wrap; align-items: flex-end;
    gap: 24px var(--gap-columns);
    margin-bottom: 64px;
}
.section-header--split > div { flex: 1 1 520px; min-width: 0; }
.section-header--split > p:not(.overline) { flex: 1 1 380px; margin-top: 0; }

/* ───────────── Hero ───────────── */
.hero { padding-block: var(--hero-top) var(--hero-bottom); }

.hero__inner {
    display: flex; flex-wrap: wrap; align-items: center;
    gap: 56px var(--gap-columns);
}
.hero__text { flex: 1 1 520px; min-width: 0; }
.hero__text h1 { margin-top: 28px; font-size: var(--text-h1-hero); }
.hero__intro {
    max-width: 620px; margin-top: 28px;
    font-size: var(--text-intro); line-height: 1.6;
    color: var(--ink-muted);
}
.hero__form { max-width: 600px; margin-top: 40px; }

.fineprint { margin-top: 14px; color: var(--ink-muted); font-size: 14px; }

/* ───────────── Aanmeldformulier ───────────── */
.signup { display: flex; flex-direction: column; }

.signup__row { display: flex; flex-wrap: wrap; gap: var(--gap-buttons); }
.signup__row .input { flex: 1 1 240px; }
.signup__row .btn { flex: 0 0 auto; }

@media (max-width: 520px) {
    .signup__row .btn { flex-basis: 100%; }
}

.consent {
    display: flex; align-items: flex-start; gap: 10px;
    margin-top: 16px;
    color: var(--ink-muted); font-size: 14px; line-height: 1.5;
    cursor: pointer;
}
.consent input {
    flex: none; width: 18px; height: 18px; margin: 1px 0 0;
    accent-color: var(--ink); cursor: pointer;
}

.field-error, .validation-message {
    margin: 8px 0 0;
    color: var(--danger); font-size: 14px; font-weight: 600;
}
.form-error {
    margin-top: 16px; padding: 12px 16px;
    border-left: 4px solid var(--danger);
    background: var(--surface);
    color: var(--danger); font-size: 14px; font-weight: 600;
}

/* Honeypot: buiten beeld voor mensen (niet display:none, sommige bots slaan dat over). */
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.signup-success {
    display: flex; align-items: center; gap: 16px;
    padding: 20px;
    border-top: 4px solid var(--lime);
    background: var(--lime-soft); color: var(--ink);
}
.success-icon {
    display: grid; place-items: center; flex: none;
    width: 40px; height: 40px;
    background: var(--ink); color: var(--lime);
}
.success-icon svg { width: 22px; height: 22px; }
.success-title { font-weight: 700; }
.signup-success p:not(.success-title) { font-size: var(--text-small); }

/* Op het lime vlak: alle tekst ink, meldingen op wit zodat rood leesbaar blijft. */
.surface-lime .consent { color: var(--ink); }
.surface-lime .field-error,
.surface-lime .validation-message { display: inline-block; align-self: flex-start; padding: 2px 8px; background: var(--surface); }
.surface-lime .signup-success { background: var(--surface); border-top-color: var(--ink); }

/* ───────────── Chatvoorbeeld ───────────── */
.chat {
    flex: 1 1 460px; min-width: 0;
    border: 1px solid var(--line);
    border-top: 4px solid var(--lime);
    background: var(--surface);
    box-shadow: var(--shadow-window);
}

.chat__bar {
    display: flex; align-items: center; gap: 6px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--line);
}
.chat__bar > span { width: 9px; height: 9px; background: var(--line); }
.chat__title { margin-inline: auto; padding-right: 39px; color: var(--ink-muted); font-size: 13px; font-weight: 500; }

.chat__body { display: flex; flex-direction: column; gap: 18px; padding: 28px 24px; font-size: 15px; line-height: 1.55; }

.msg-user {
    align-self: flex-end; max-width: 85%;
    padding: 14px 16px;
    background: var(--surface-alt);
}

.msg-ai { display: flex; gap: 12px; align-items: flex-start; }
.ai-avatar { flex: none; width: 24px; height: 24px; margin-top: 1px; background: var(--lime); }

.tool {
    width: min(100%, 440px); margin-left: 36px;
    border: 1px solid var(--line);
    font-size: 13px;
}
.tool__head {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px;
    padding: 10px 14px; border-bottom: 1px solid var(--line);
}
.tool__name {
    padding: 2px 8px;
    background: var(--lime-soft); color: var(--ink);
    font-family: var(--font-mono); font-size: 13px; font-weight: 600;
}
.tool__meta { color: var(--ink-muted); }
.tool__meta code { color: var(--ink); }

.tool__args {
    display: grid; grid-template-columns: max-content 1fr; gap: 6px 20px;
    margin: 0; padding: 14px;
    font-family: var(--font-mono);
}
.tool__args dt { color: var(--ink-muted); }
.tool__args dd { margin: 0; }

.tool__status {
    display: flex; align-items: center; gap: 8px;
    padding: 10px 14px; border-top: 1px solid var(--line);
    font-weight: 600;
}
.status-check {
    display: grid; place-items: center; flex: none;
    width: 18px; height: 18px;
    background: var(--lime); color: var(--ink);
}
.status-check .icon { width: 13px; height: 13px; stroke-width: 3; }

@media (max-width: 560px) {
    .tool { margin-left: 0; }
    .chat__title { padding-right: 0; }
}

/* ───────────── Kenmerkenbalk ───────────── */
.features { border-block: 1px solid var(--line); }
.features__list {
    display: flex; flex-wrap: wrap; gap: 16px 48px;
    margin: 0 auto; padding-block: 28px;
    list-style: none;
    font-size: var(--text-small); font-weight: 600;
}
.features__list li { display: inline-flex; align-items: center; gap: 10px; }

/* Vinkje: klein ink-vierkant met een lime vinkje. */
.check {
    display: grid; place-items: center; flex: none;
    width: 22px; height: 22px;
    background: var(--ink); color: var(--lime);
}
.check .icon { width: 14px; height: 14px; stroke-width: 3; }

/* ───────────── Hoe het werkt: stappen ───────────── */
.steps {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: var(--gap-steps);
    margin: 0; padding: 0; list-style: none;
}
.step { padding-top: 24px; border-top: 4px solid var(--lime); }
.step--final { border-top-color: var(--ink); }
.step__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.step__number {
    font-family: var(--font-display); font-size: 48px; font-weight: 800; line-height: 1;
    letter-spacing: -0.03em;
    font-variant-numeric: tabular-nums;
}
.step__head .icon { width: 28px; height: 28px; color: var(--ink); }
.step h3 { margin: 20px 0 8px; font-size: 22px; }
.step p { font-size: var(--text-small); line-height: 1.6; color: var(--ink-muted); }

/* ───────────── Functies: tegels ───────────── */
.tiles {
    display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--gap-cards);
    margin: 0; padding: 0; list-style: none;
}
.tile {
    display: flex; flex-direction: column; gap: 16px;
    padding: 32px;
    background: var(--surface-alt);
    border-top: 4px solid var(--lime);
}
/* Op het lichtgrijze vlak worden de tegels wit, zodat ze loskomen (net als op basiqcompany.nl). */
.surface-alt .tile { background: var(--surface); }
.tile h3 { margin-top: 8px; line-height: 1.2; }
.tile p { color: var(--ink-muted); font-size: var(--text-small); line-height: 1.6; }

.tile__icon {
    display: grid; place-items: center; flex: none;
    width: 40px; height: 40px;
    background: var(--lime); color: var(--ink);
}
.tile__icon .icon { width: 22px; height: 22px; }

/* De grote tegel beslaat de volle breedte: tekst links, codevoorbeeld rechts. */
.tile--wide {
    grid-column: 1 / -1;
    display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: 16px var(--gap-columns); align-items: center;
}
.tile__text { display: flex; flex-direction: column; gap: 16px; }

.code {
    margin: 0; padding: 24px;
    background: var(--ink); color: var(--surface);
    font-family: var(--font-mono); font-size: 14px; line-height: 1.75;
    overflow-x: auto;
}
.code code { font-size: inherit; }
.code .k { color: var(--lime); font-weight: 600; }
.code .p { color: var(--lime-soft); }

@media (max-width: 900px) {
    .tile--wide { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
    .tiles { grid-template-columns: 1fr; }
    .tile { padding: 28px 24px; }
}

/* ───────────── Integraties ─────────────
   Namen in een rij, gescheiden door 1px-lijnen; geen kaarten. De negatieve marge verbergt de
   linker- en bovenlijn van de eerste kolom/rij onder de overflow, ook als de rij afbreekt. */
.integrations {
    display: grid; grid-template-columns: repeat(6, 1fr);
    margin: 0; padding: 0; list-style: none;
    border-block: 1px solid var(--line);
    overflow: hidden;
}
.integrations li {
    display: flex; flex-direction: column; gap: 4px;
    margin: -1px 0 0 -1px;
    padding: 28px 24px;
    border-top: 1px solid var(--line);
    border-left: 1px solid var(--line);
}
.integrations li:first-child { padding-left: 0; }
.integrations strong { font-family: var(--font-display); font-size: 19px; font-weight: 700; line-height: 1.3; }
.integrations span { color: var(--ink-muted); font-size: 15px; }

@media (max-width: 1100px) {
    .integrations { grid-template-columns: repeat(3, 1fr); }
    .integrations li:first-child { padding-left: 24px; }
}
@media (max-width: 600px) {
    .integrations { grid-template-columns: repeat(2, 1fr); }
    .integrations li { padding: 24px 16px; }
}

/* ───────────── FAQ ───────────── */
.faq-layout {
    display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: 40px var(--gap-columns); align-items: start;
}
.faq-layout .section-header { margin-bottom: 0; }

.faq { border-top: 2px solid var(--ink); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
    display: flex; align-items: center; justify-content: space-between; gap: 24px;
    padding: 24px 0;
    font-family: var(--font-display); font-size: 20px; font-weight: 700; line-height: 1.3;
    list-style: none; cursor: pointer;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { text-decoration: underline 2px var(--lime); text-underline-offset: 0.2em; }
.faq-icon { width: 24px; height: 24px; color: var(--ink); stroke-width: 2.2; }
/* Plus wordt min: de verticale streep verdwijnt als de vraag open staat. */
.faq details[open] .faq-icon .pm-v { display: none; }
.faq details p { padding: 0 48px 26px 0; color: var(--ink-muted); font-size: var(--text-small); line-height: 1.6; }

/* Open/dicht vloeiend animeren waar de browser het kan (Chromium 131+); elders gewoon direct. */
@media (prefers-reduced-motion: no-preference) {
    @supports (interpolate-size: allow-keywords) {
        :root { interpolate-size: allow-keywords; }
        .faq details::details-content {
            height: 0; overflow: clip;
            transition: height .3s ease, content-visibility .3s allow-discrete;
        }
        .faq details[open]::details-content { height: auto; }
    }
}

@media (max-width: 900px) {
    .faq-layout { grid-template-columns: 1fr; }
    .faq details p { padding-right: 0; }
}

/* ───────────── Afsluitende band ───────────── */
.band__inner {
    display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between;
    gap: 40px var(--gap-columns);
    padding-block: var(--band-y);
}
.band__text { flex: 1 1 560px; min-width: 0; }
.band__text h2 {
    margin-top: 24px;
    font-size: var(--text-h2-closing); line-height: 1.02; letter-spacing: -0.035em;
}
.band__text p:not(.overline) { max-width: 620px; margin-top: 24px; font-size: 20px; }
.band__form { flex: 1 1 440px; min-width: 0; max-width: 560px; }

/* ───────────── Footer ───────────── */
.site-footer { border-top: 1px solid var(--line); font-size: var(--text-small); }

.site-footer__top {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
    gap: 20px 40px;
    padding-block: 48px;
}
.site-footer__links { display: flex; flex-wrap: wrap; gap: 8px 24px; }

.site-footer__legal {
    display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px;
    padding-block: 24px 40px;
    border-top: 1px solid var(--line);
    color: var(--ink-muted); font-size: 14px;
}

/* ───────────── Inhoudspagina's (privacy, 404) ───────────── */
.prose { max-width: calc(760px + var(--gutter) * 2); padding-block: var(--hero-top) var(--section-y); }
.prose h1 { margin: 28px 0 20px; font-size: clamp(40px, 5vw, 60px); line-height: 1.05; }
.prose h2 { margin: 48px 0 12px; font-size: var(--text-h3); line-height: 1.3; letter-spacing: -0.01em; }
.prose .intro { font-size: var(--text-intro); line-height: 1.6; color: var(--ink-muted); }
.prose p + p { margin-top: 12px; }
.prose ul { margin: 0; padding-left: 20px; }
.prose li + li { margin-top: 6px; }
.prose li::marker { color: var(--ink); }
.link-arrow { display: inline-block; margin-top: 48px; font-weight: 600; }

.status-page {
    display: flex; flex-direction: column; align-items: flex-start; gap: 24px;
    padding-block: var(--section-y);
}
.status-page h1 { font-size: clamp(40px, 5vw, 68px); }
.status-page p:not(.overline) { font-size: var(--text-intro); color: var(--ink-muted); }
.status-page .btn { margin-top: 8px; }
