:root {
  --bg: #f1efea;
  --panel: #ffffff;
  --ink: #1a1a1e;
  --ink-2: #5b5b64;
  --line: #dedbd3;
  --grey: #b9bcc2;
  --dark-grey: #33353a;
  --red: #da140f;
  --red-dark: #b0100c;
  --red-tint: #fbe3e2;
  --font: "Instrument Sans", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --wrap: 1120px;
  --r: 18px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; font-family: var(--font); color: var(--ink); background: var(--bg);
  font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 3px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 28px; }

/* Header */
header { position: sticky; top: 0; z-index: 10; background: rgba(230,227,219,.9); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; font-weight: 500; letter-spacing: -.01em; }
.brand img { height: 38px; width: 38px; display: block; border-radius: 9px; transition: transform .3s cubic-bezier(.2,.7,.2,1); }
.brand:hover img { transform: rotate(-8deg); }
.brand b { font-weight: 700; }
.brand small { font-size: 1em; color: #6b6b72; font-weight: 500; }
nav ul { list-style: none; display: flex; gap: 6px; margin: 0; padding: 0; }
nav a { text-decoration: none; color: var(--ink-2); font-weight: 500; font-size: 15px; padding: 8px 14px; border-radius: 999px; transition: background .15s, color .15s; }
nav a:hover { color: var(--ink); background: rgba(255,255,255,.7); }
nav a.cta { background: var(--ink); color: #fff; }
nav a.cta:hover { background: var(--red); color: #fff; }
@media (max-width: 640px) { nav a:not(.cta) { display: none; } }

/* Hero */
.hero { padding: 88px 0 80px; position: relative; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(var(--line) 1.2px, transparent 1.2px);
  background-size: 26px 26px;
  -webkit-mask-image: radial-gradient(ellipse 70% 80% at 65% 40%, #000 20%, transparent 70%);
  mask-image: radial-gradient(ellipse 70% 80% at 65% 40%, #000 20%, transparent 70%);
}
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 56px; align-items: center; position: relative; }
@media (max-width: 860px) { .hero-grid { grid-template-columns: 1fr; gap: 44px; } .hero { padding: 56px 0 56px; } }

.pill {
  display: inline-flex; align-items: center; gap: 9px; font-size: 14px; font-weight: 500;
  background: var(--panel); border: 1px solid var(--line); padding: 7px 14px 7px 10px; border-radius: 999px; margin-bottom: 22px;
  opacity: 0; animation: fade .6s ease .1s forwards;
}
.pill i { width: 9px; height: 9px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 0 rgba(218,20,15,.4); animation: pulse 2.2s ease-out infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 9px rgba(218,20,15,0); } 100% { box-shadow: 0 0 0 0 rgba(218,20,15,0); } }

h1 { font-size: clamp(42px, 6.2vw, 78px); line-height: 1.04; letter-spacing: -.035em; font-weight: 700; margin: 0 0 26px; }
h1 .line { display: block; overflow: hidden; padding-bottom: .06em; margin-bottom: -.06em; }
h1 .line > span { display: block; transform: translateY(110%); animation: rise .9s cubic-bezier(.2,.7,.2,1) forwards; }
h1 .line:nth-child(2) > span { animation-delay: .12s; }
h1 .line:nth-child(3) > span { animation-delay: .24s; }
@keyframes rise { to { transform: translateY(0); } }

/* Onderstreping als "marker": een achtergrond die van 0 naar 100% breedte groeit. Geen positionering, dus loopt altijd netjes mee met de tekst. */
.mark-under {
  background-image: linear-gradient(var(--red), var(--red));
  background-repeat: no-repeat;
  background-position: 0 92%;
  background-size: 0% .07em;
  animation: draw .75s cubic-bezier(.2,.7,.2,1) .85s forwards;
}
@keyframes draw { to { background-size: 100% .07em; } }

.lead { font-size: 20px; color: var(--ink-2); max-width: 32em; margin: 0 0 34px; opacity: 0; animation: fade .8s ease .6s forwards; }
@keyframes fade { to { opacity: 1; } }
.actions { display: flex; gap: 14px; flex-wrap: wrap; opacity: 0; animation: fade .8s ease .8s forwards; }
.btn { display: inline-flex; align-items: center; gap: 10px; padding: 15px 24px; border-radius: 999px; text-decoration: none; font-weight: 600; font-size: 16px; line-height: 1; border: 0; cursor: pointer; font-family: inherit; transition: transform .15s ease, background .15s ease, box-shadow .15s ease; }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: scale(.98); }
.btn-red { background: var(--red); color: #fff; box-shadow: 0 10px 24px -12px rgba(218,20,15,.7); }
.btn-red:hover { background: var(--red-dark); }
.btn .spin { display: none; width: 16px; height: 16px; border: 2.5px solid rgba(255,255,255,.35); border-top-color: #fff; border-radius: 50%; animation: turn .7s linear infinite; }
.btn.busy .spin { display: block; }
.btn.busy { pointer-events: none; opacity: .85; }
@keyframes turn { to { transform: rotate(360deg); } }
.btn-ghost { background: var(--panel); border: 1.5px solid var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); }

/* Code window, licht scheef als een sticker */
.code-wrap { position: relative; opacity: 0; animation: fade .8s ease .9s forwards; }
.code {
  background: var(--ink); color: #e8e8ec; border-radius: 16px; font-family: var(--mono); font-size: 13.5px; line-height: 1.7;
  box-shadow: 0 40px 70px -30px rgba(26,26,30,.55);
  transform: rotate(-1.5deg); transition: transform .4s cubic-bezier(.2,.7,.2,1);
}
.code-wrap:hover .code { transform: rotate(0deg); }
.code-bar { display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-bottom: 1px solid rgba(255,255,255,.08); }
.code-bar i { width: 10px; height: 10px; border-radius: 50%; background: rgba(255,255,255,.18); display: block; }
.code-bar i:first-child { background: var(--red); }
.code-bar em { font-style: normal; margin-left: auto; color: var(--grey); font-size: 12px; }
.code pre { margin: 0; padding: 18px 20px 22px; white-space: pre; overflow-x: auto; min-height: 236px; }
.k { color: #ff8a80; } .s { color: #b6e3a8; } .c { color: rgba(255,255,255,.4); } .v { color: #9ecbff; }
.caret { display: inline-block; width: 7px; height: 1.1em; background: var(--red); vertical-align: -.2em; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.sticker {
  position: absolute; right: -10px; top: -18px; z-index: 2; background: var(--red); color: #fff; font-weight: 700; font-size: 13px;
  padding: 8px 14px; border-radius: 999px; transform: rotate(6deg); box-shadow: 0 8px 20px -8px rgba(218,20,15,.8);
}

/* Secties */
section { padding: 88px 0; scroll-margin-top: 24px; }
#werkwijze { scroll-margin-top: 100px; }
h2 { font-size: clamp(28px, 3.6vw, 40px); letter-spacing: -.025em; line-height: 1.1; margin: 0 0 14px; font-weight: 700; }
.soft { color: #8e8e95; }
.card.red .soft { color: var(--grey); }
.intro { color: var(--ink-2); font-size: 18px; max-width: 36em; margin: 0 0 40px; }

.services { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; counter-reset: s; }
.services li {
  background: var(--panel); border-radius: var(--r); padding: 28px 30px;
  display: grid; grid-template-columns: 64px 300px 1fr; gap: 24px; align-items: start;
  border: 1px solid transparent; transition: transform .25s cubic-bezier(.2,.7,.2,1), border-color .25s, box-shadow .25s;
}
/* Startstand: alle kaarten liggen als een stapel op de plek van de eerste en waaieren naar beneden uit. */
.services.stack li { transition: transform .9s cubic-bezier(.2,.75,.2,1), opacity .4s ease, box-shadow .9s ease; box-shadow: 0 20px 40px -30px rgba(26,26,30,.45); }
.services.stack:not(.in) li { transform: translateY(var(--dy)) scale(calc(1 - var(--n) * .03)) rotate(calc(var(--n) * -1.2deg)); z-index: calc(10 - var(--n)); }
.services.stack:not(.in) li:not(:first-child) { opacity: .9; }
.services li:hover { transform: translateX(6px); border-color: var(--red-tint); box-shadow: 0 20px 40px -30px rgba(26,26,30,.35); }
.services li::before {
  counter-increment: s; content: counter(s, decimal-leading-zero);
  font-family: var(--mono); font-size: 14px; font-weight: 500; color: var(--red);
  background: var(--red-tint); width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center;
}
.services h3 { margin: 0; font-size: 20px; font-weight: 600; letter-spacing: -.01em; }
.services p { margin: 0; color: var(--ink-2); max-width: 40em; }
.services .tech { display: block; margin-top: 6px; font-family: var(--mono); font-size: 12.5px; color: #8e8e95; }
@media (max-width: 860px) { .services li { grid-template-columns: 44px 1fr; } .services p { grid-column: 2; } }

/* Werkwijze + over */
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
@media (max-width: 860px) { .two { grid-template-columns: 1fr; } }
.card { background: var(--panel); border-radius: var(--r); padding: 40px; position: relative;
  transition: transform .85s cubic-bezier(.2,.75,.2,1), opacity .5s ease; }
/* Startstand: de blokken staan op elkaars plek en schuiven bij binnenkomst langs elkaar naar hun eigen plek. */
.two:not(.in) .card:first-child { transform: translateX(calc(100% + 24px)); opacity: 0; }
.two:not(.in) .card:last-child  { transform: translateX(calc(-100% - 24px)) rotate(-2deg); opacity: 0; }
.card.red { z-index: 1; }
@media (max-width: 860px) {
  .two:not(.in) .card:first-child { transform: translateX(-40px); }
  .two:not(.in) .card:last-child  { transform: translateX(40px); }
}
.card.red { background: var(--dark-grey); color: #fff; }
.card.red h2 { color: #fff; }
.card.red p { color: var(--grey); }
.card.red strong { color: #fff; }
.card p { color: var(--ink-2); margin: 0 0 16px; max-width: 34em; }
.card p strong { color: var(--ink); font-weight: 600; }
.facts { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 10px; }
.facts li { display: flex; gap: 12px; align-items: baseline; }
.facts li::before { content: ""; width: 10px; height: 10px; flex: none; background: var(--red); border-radius: 3px; transform: translateY(-1px) rotate(45deg); }

.socials { display: flex; gap: 18px; margin: 24px 0 0; padding: 0; }
.socials a { color: #fff; font-weight: 600; font-size: 14.5px; text-decoration: none; border-bottom: 1.5px solid var(--grey); padding-bottom: 2px; transition: border-color .15s, color .15s; }
.socials a:hover { color: var(--red-tint); border-color: var(--red-tint); }

/* Slogan die zichzelf schrijft */
.slogan-band { padding: 40px 0 96px; text-align: center; }
.slogan-band p { margin: 0; font-size: clamp(30px, 5vw, 60px); font-weight: 700; letter-spacing: -.03em; line-height: 1.1; min-height: 1.1em; }
.slogan-band .soft { color: #8e8e95; }
.slogan-band .caret2 { display: inline-block; width: .08em; height: .95em; background: var(--red); vertical-align: -.1em; margin-left: .06em; border-radius: 2px; animation: blink 1s steps(1) infinite; }
.slogan-band .caret2.off { transition: opacity .6s ease; opacity: 0; }

/* Contact */
.contact { padding-top: 0; }
.contact .wrap { display: grid; grid-template-columns: .9fr 1.1fr; gap: 48px; align-items: start; }
@media (max-width: 860px) { .contact { padding-top: 0; }
.contact .wrap { grid-template-columns: 1fr; } }
.contact p { color: var(--ink-2); max-width: 30em; margin: 0 0 18px; }
.contact .note { font-size: 14px; color: #8e8e95; margin-top: 28px; }
.contact .note a { color: inherit; text-decoration: underline; }
form { background: var(--panel); border-radius: var(--r); padding: 32px; display: grid; gap: 16px; position: relative; overflow: hidden;
  opacity: 0; transform: translateY(28px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1); }
form.in { opacity: 1; transform: none; }
form > *:not(.done) { transition: opacity .35s ease, transform .35s ease; }
form.sent > *:not(.done) { opacity: 0; transform: scale(.97); pointer-events: none; }
.done { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; gap: 10px; padding: 32px;
  opacity: 0; pointer-events: none; transition: opacity .4s ease .25s; }
form.sent .done { opacity: 1; pointer-events: auto; }
.done svg { width: 72px; height: 72px; margin: 0 auto 6px; }
.done circle { fill: var(--red-tint); stroke: var(--red); stroke-width: 2.5; stroke-dasharray: 220; stroke-dashoffset: 220; }
.done path { fill: none; stroke: var(--red); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 60; stroke-dashoffset: 60; }
form.sent .done circle { animation: dash .6s ease .3s forwards; }
form.sent .done path { animation: dash .45s ease .75s forwards; }
@keyframes dash { to { stroke-dashoffset: 0; } }
.done strong { font-size: 20px; letter-spacing: -.01em; }
.done p { margin: 0; }
.done button { background: none; border: 0; color: var(--red); font: inherit; font-weight: 600; cursor: pointer; padding: 6px; }
.done button:hover { text-decoration: underline; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) { .row { grid-template-columns: 1fr; } }
label { display: grid; gap: 6px; font-size: 14px; font-weight: 500; transition: color .15s; }
label:focus-within { color: var(--red); }
input, textarea {
  font: inherit; font-size: 16px; padding: 13px 15px; border: 1.5px solid transparent; border-radius: 12px; background: #e6e3db; color: var(--ink); width: 100%;
  transition: border-color .15s, background .15s, box-shadow .2s;
}
input:focus, textarea:focus { outline: none; border-color: var(--red); background: #fff; box-shadow: 0 0 0 4px var(--red-tint); }
textarea { min-height: 130px; resize: vertical; }
.hp { position: absolute; left: -9999px; }
.form-foot { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.msg { font-size: 15px; color: #8e8e95; }
.msg.ok { color: #1c7a3a; font-weight: 500; }
.msg.err { color: var(--red); font-weight: 500; }

footer { padding: 36px 0; font-size: 14px; color: #7d7d84; background: #e6e3db; border-top: 1px solid var(--line); }
footer .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

@media (prefers-reduced-motion: reduce) {
  h1 .line > span, .mark-under, .lead, .actions, .code-wrap, .pill { animation: none; opacity: 1; transform: none; background-size: 100% .07em; }
  .caret, .pill i { animation: none; }
  .code { transform: none; }
  form { opacity: 1; transform: none; transition: none; }
  .two:not(.in) .card { transform: none; opacity: 1; }
  .services.stack:not(.in) li { transform: none; opacity: 1; }
  .done circle, .done path { stroke-dashoffset: 0; animation: none; }
  html { scroll-behavior: auto; }
}
