/* huisstijl.css: de stijl van itaanspreekpunt.nl voor de webonderdelen van het platform.
   Kleuren en maten komen van de website (tokens met dezelfde namen). Klassen beginnen met
   "hs-", zodat een app er eigen CSS naast kan zetten zonder botsingen.
   Contrast (WCAG AA) is nagemeten; zie app/README.md, sectie Huisstijl. */

:root {
  /* Kleuren van de website */
  --ink: #191a58;          /* navy: tekst, kop */
  --ink-diep: #0e0f48;     /* footer, codeblok */
  --ink-zacht: #43476a;    /* rustige tekst */
  --ink-dof: #5d6279;      /* hulptekst */
  --accent: #545cf9;       /* knoppen (wit erop 4,9:1); te overschrijven met HUISSTIJL["PRIMAIR"] */
  --link: #4148e6;         /* tekstlinks: iets donkerder dan accent, ook AA op de lichte vlakken */
  --creme: #f7fcd3;
  --papier: #fff;
  --lijn: #dfe6ef;
  --lijn-veld: #7c80b0;    /* rand van invoervelden, 3,8:1 op wit (WCAG 1.4.11) */
  --vlak-kaart: #eef2f8;
  --sectie-licht: #e9f2f8;
  --sectie-blauw: #dae9f3; /* paginaachtergrond */
  --op-navy: #c7ccf2;
  --op-navy-sterk: #e4e7ff;
  --fout: #b42318;
  --fout-vlak: #fdecea;
  --ok: #1d6b34;
  --ok-vlak: #e6f4ea;

  --font-kop: "Space Grotesk", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-tekst: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-code: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;

  --rond-groot: 30px;
  --rond-kaart: 20px;
  --rond-veld: 12px;
  --rond-pil: 999px;
  --schaduw-rust: 0 18px 50px rgba(25, 26, 88, .12);
  --breedte: 960px;
  --rand: 16px;              /* buitenmarge rond het paneel, zoals de site */
  --binnen: clamp(20px, 5vw, 56px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font: 500 1rem/1.7 var(--font-tekst);
  color: var(--ink);
  background: var(--sectie-blauw);
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}
img, svg { max-width: 100%; }

h1, h2, h3, h4 { font-family: var(--font-kop); font-weight: 500; line-height: 1.15; margin: 0 0 .6em; text-wrap: balance; }
h2 { font-size: 1.6rem; margin-top: 1.6em; }
h3 { font-size: 1.25rem; margin-top: 1.4em; }
p { margin: 0 0 1em; }
strong { font-weight: 700; }
a { color: var(--link); text-underline-offset: .18em; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
ul, ol { padding-left: 1.4rem; margin: 0 0 1.2em; }
li { margin-bottom: .4em; }
li::marker { color: var(--accent); }
code, pre { font-family: var(--font-code); font-size: .92em; }
:not(pre) > code { background: var(--vlak-kaart); border-radius: 6px; padding: .1em .35em; }
pre {
  background: var(--ink-diep); color: var(--creme);
  padding: 12px 16px; border-radius: var(--rond-veld);
  overflow-x: auto; white-space: pre;
}

.hs-sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.hs-overslaan {
  position: absolute; left: 16px; top: -60px; z-index: 10;
  padding: 10px 18px; border-radius: var(--rond-pil);
  background: var(--creme); color: var(--ink); font-weight: 700;
}
.hs-overslaan:focus { top: 16px; }

/* ---- Kop: navy paneel met gloed, logo en paginatitel ------------------- */
.hs-paneel {
  position: relative; overflow: hidden;
  width: calc(100% - 2 * var(--rand));
  max-width: calc(var(--breedte) + 2 * var(--binnen));
  margin: var(--rand) auto 0;
  border-radius: var(--rond-groot);
  background: var(--ink);
  color: var(--papier);
}
.hs-paneel::before {
  content: ""; position: absolute; top: -45%; left: -15%;
  width: 70%; aspect-ratio: 1; pointer-events: none;
  background: radial-gradient(circle, rgba(84, 92, 249, .55), rgba(84, 92, 249, 0) 70%);
}
.hs-paneel > * { position: relative; }
.hs-paneel :focus-visible { outline-color: var(--creme); }
.hs-balk {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding: 22px var(--binnen) 0;
}
.hs-logo { display: inline-flex; align-items: center; }
.hs-logo img { display: block; height: 52px; width: auto; }
.hs-balk__rechts { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.hs-balk__rechts a { color: var(--papier); font-weight: 600; text-decoration: none; }
.hs-balk__rechts a:hover { color: var(--creme); text-decoration: underline; }

.hs-hero { padding: 36px var(--binnen) 44px; }
.hs-pil {
  display: inline-block; margin: 0 0 18px;
  padding: 7px 16px; border-radius: var(--rond-pil);
  background: var(--creme); color: var(--ink);
  font: 700 .8rem/1.2 var(--font-tekst); letter-spacing: .12em; text-transform: uppercase;
}
.hs-hero h1 {
  margin: 0; max-width: 22ch;
  font: 700 clamp(2rem, 6.4vw, 3.2rem)/1.15 var(--font-kop);
  letter-spacing: -.01em; color: var(--papier);
}
.hs-hero h1 em { font-style: normal; color: var(--creme); }
.hs-intro { margin: 18px 0 0; max-width: 60ch; color: var(--op-navy-sterk); font-size: 1.1rem; line-height: 1.75; }
.hs-intro strong { color: var(--creme); }
.hs-intro a { color: var(--creme); }

/* ---- Inhoud: witte kaart op de blauwe achtergrond ---------------------- */
.hs-hoofd { flex: 1 0 auto; width: 100%; padding: 28px var(--rand) 64px; }
.hs-kaart {
  max-width: calc(var(--breedte) + 2 * var(--binnen));
  margin: 0 auto;
  padding: clamp(22px, 5vw, 48px) var(--binnen);
  border-radius: var(--rond-groot);
  background: var(--papier);
  box-shadow: var(--schaduw-rust);
}
.hs-kaart > :first-child { margin-top: 0; }
.hs-kaart > :last-child { margin-bottom: 0; }
.hs-kaart p, .hs-kaart ul, .hs-kaart ol:not(.hs-stappen) { max-width: 68ch; }

/* ---- Knoppen: pil, accent, hover naar navy (zoals de site) -------------- */
.hs-knop {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 12px 26px;
  border: 1px solid var(--accent); border-radius: var(--rond-pil);
  background: var(--accent); color: var(--papier);
  font: 700 1rem/1.2 var(--font-tekst); text-decoration: none; cursor: pointer;
}
.hs-knop:hover { background: var(--ink); border-color: var(--ink); color: var(--papier); }
.hs-knop svg { flex: none; }
.hs-knop--licht { background: var(--creme); border-color: var(--creme); color: var(--ink); }
.hs-knop--omlijnd { background: transparent; border-color: var(--ink); color: var(--ink); }
.hs-knop--omlijnd:hover { background: var(--ink); color: var(--papier); }
.hs-paneel .hs-knop--omlijnd { border-color: var(--papier); color: var(--papier); }
.hs-paneel .hs-knop--omlijnd:hover { background: var(--papier); color: var(--ink); }
.hs-knoppen { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }
@media (prefers-reduced-motion: no-preference) {
  .hs-knop { transition: background-color .2s, border-color .2s, color .2s, transform .2s; }
  .hs-knop:hover { transform: translateY(-2px); }
}

/* ---- Meldingen ---------------------------------------------------------- */
.hs-melding {
  margin: 0 0 20px; padding: 14px 18px;
  border-radius: var(--rond-veld); border-left: 5px solid var(--accent);
  background: var(--vlak-kaart); color: var(--ink);
}
.hs-melding p { margin: 0; }
.hs-melding p + p { margin-top: 6px; }
.hs-melding--fout, .hs-melding--error { border-left-color: var(--fout); background: var(--fout-vlak); color: var(--fout); }
.hs-melding--ok, .hs-melding--success { border-left-color: var(--ok); background: var(--ok-vlak); color: var(--ok); }
.hs-melding--let-op, .hs-melding--warning { border-left-color: var(--ink); background: var(--creme); }

.hs-foutsamenvatting {
  margin: 0 0 24px; padding: 16px 20px;
  border: 2px solid var(--fout); border-radius: var(--rond-veld);
  background: var(--fout-vlak); color: var(--fout);
}
.hs-foutsamenvatting:focus { outline: 3px solid var(--accent); outline-offset: 3px; }
.hs-foutsamenvatting h2 { margin: 0 0 8px; font-size: 1.1rem; color: var(--fout); }
.hs-foutsamenvatting ul { margin: 0; padding-left: 20px; }
.hs-foutsamenvatting li + li { margin-top: 4px; }
.hs-foutsamenvatting a { color: var(--fout); font-weight: 600; text-decoration: underline; }

/* ---- Formulieren -------------------------------------------------------- */
.hs-formulier { margin: 28px 0 0; }
.hs-veld { margin-bottom: 22px; }
.hs-veld > label, .hs-label { display: block; margin-bottom: 6px; font-weight: 600; font-size: .98rem; }
.hs-optioneel { font-weight: 400; color: var(--ink-dof); }
input[type=text], input[type=email], input[type=url], input[type=password], input[type=number],
input[type=search], input[type=tel], input[type=date], select, textarea {
  width: 100%; min-height: 48px;
  padding: 11px 14px;
  border: 1px solid var(--lijn-veld); border-radius: var(--rond-veld);
  background: var(--papier); color: var(--ink);
  font: 400 1rem/1.45 var(--font-tekst);
}
textarea { font-family: var(--font-code); font-size: .92rem; resize: vertical; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
input[type=checkbox], input[type=radio] { width: 20px; height: 20px; margin: 3px 0 0; flex: none; accent-color: var(--accent); }
.hs-hulp { margin: 6px 0 0; font-size: .9rem; line-height: 1.5; color: var(--ink-dof); }
.hs-foutmelding { margin: 6px 0 0; font-size: .92rem; font-weight: 600; line-height: 1.45; color: var(--fout); }
.hs-veld--fout input, .hs-veld--fout textarea, .hs-veld--fout select { border-color: var(--fout); border-width: 2px; }
.hs-veld > label.hs-keuze, .hs-keuze { display: flex; gap: 10px; align-items: flex-start; font-weight: 500; }
.hs-invoer-affix { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-family: var(--font-code); font-size: .95rem; }
.hs-invoer-affix input { flex: 1 1 160px; width: auto; min-width: 0; }

/* ---- Bouwstenen --------------------------------------------------------- */
.hs-stappen {
  counter-reset: stap; list-style: none;
  margin: 0 0 8px; padding: 20px 24px; max-width: none;
  border-radius: var(--rond-kaart); background: var(--sectie-licht);
}
.hs-stappen li { counter-increment: stap; position: relative; padding: 4px 0 4px 44px; margin: 0; }
.hs-stappen li + li { margin-top: 8px; }
.hs-stappen li::before {
  content: counter(stap); position: absolute; left: 0; top: 2px;
  display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%;
  background: var(--accent); color: var(--papier); font: 700 .9rem/1 var(--font-kop);
}
.hs-uitleg { margin: 6px 0 24px; padding: 14px 20px; border-radius: var(--rond-kaart); background: var(--vlak-kaart); }
.hs-uitleg summary { cursor: pointer; font-weight: 700; }
.hs-uitleg[open] summary { margin-bottom: 10px; }
.hs-uitleg > :last-child { margin-bottom: 0; }

/* ---- Voet ---------------------------------------------------------------- */
.hs-voet {
  flex-shrink: 0;
  padding: 48px var(--rand) 40px;
  border-radius: 40px 40px 0 0;
  background: var(--ink-diep); color: var(--papier);
  font-size: .95rem;
}
.hs-voet__in {
  max-width: calc(var(--breedte) + 2 * var(--binnen)); margin: 0 auto; padding: 0 var(--binnen);
  display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 28px 48px;
}
.hs-voet__logo img { display: block; height: 36px; width: auto; }
.hs-voet p { margin: 12px 0 0; color: var(--op-navy-sterk); }
.hs-voet__tagline { font: 700 1.1rem/1.3 var(--font-kop); color: var(--creme) !important; }
.hs-voet a { color: var(--papier); font-weight: 700; }
.hs-voet a:hover { color: var(--creme); }
.hs-voet :focus-visible { outline-color: var(--creme); }
.hs-voet__links { list-style: none; margin: 0; padding: 0; }
.hs-voet__links li { margin: 0 0 10px; color: var(--op-navy-sterk); }
.hs-voet__links li::marker { content: none; }

@media (max-width: 640px) {
  :root { --rand: 10px; --rond-groot: 22px; }
  .hs-logo img { height: 36px; }
  .hs-hero { padding-top: 28px; padding-bottom: 32px; }
  .hs-intro { font-size: 1rem; }
  .hs-voet { border-radius: 26px 26px 0 0; }
  .hs-voet__in { grid-template-columns: minmax(0, 1fr); }
  .hs-knop { width: 100%; }
  .hs-stappen { padding: 16px 16px; }
}

@media print {
  body { background: #fff; }
  .hs-paneel { background: #fff; color: var(--ink); }
  .hs-paneel::before, .hs-voet, .hs-overslaan { display: none; }
  .hs-hero h1, .hs-intro { color: var(--ink); }
  .hs-kaart { box-shadow: none; padding: 0; }
}
