/* Boxback-app – kleuren en letters gelijk aan boxback.vercel.app */
:root {
  --ink: #17111a; --ink-2: #231a25;
  --magenta: #e0157a; --magenta-deep: #b50e62; --magenta-soft: #ff7fbd;
  --blush: #fbf1f6; --paper: #fff; --line: #eedbe5;
  --text: #1d161a; --muted: #6c5f67; --on-dark: #f6eef2; --on-dark-muted: #bfaeb8;
  --kraft: #c9a26f; --ok: #1f9d6b; --warn: #b86e00; --err: #c2223b;
  --display: "Montserrat", "Segoe UI", system-ui, sans-serif;
  --body: "Plus Jakarta Sans", "Segoe UI", system-ui, sans-serif;
  --radius: 18px; --max: 560px;
  --safe-top: env(safe-area-inset-top, 0px); --safe-bottom: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--blush); color: var(--text); font: 400 16px/1.5 var(--body); min-height: 100dvh; -webkit-tap-highlight-color: transparent; }
h1, h2, h3 { font-family: var(--display); letter-spacing: -0.02em; line-height: 1.12; margin: 0; }
h1 { font-size: 30px; font-weight: 900; }
h2 { font-size: 20px; font-weight: 800; }
h3 { font-size: 16px; font-weight: 800; }
p { margin: 0; }
a { color: var(--magenta-deep); }
button { font: inherit; color: inherit; }
[hidden] { display: none !important; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.laden { padding: 60px 20px; text-align: center; color: var(--muted); }

/* Kopbalk */
.bar { position: sticky; top: 0; z-index: 20; background: var(--ink); color: var(--on-dark); padding: calc(var(--safe-top) + 12px) 16px 12px; }
.bar-in { max-width: var(--max); margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 36px; }
.brand { display: flex; align-items: center; gap: 9px; text-decoration: none; }
.brand svg { width: 32px; height: 32px; }
.wordmark { font: italic 900 20px/1 var(--display); letter-spacing: -0.02em; color: #fff; }
.wordmark b { color: var(--magenta); font-weight: 900; }
.terug { display: inline-flex; align-items: center; gap: 6px; background: none; border: 0; color: var(--on-dark); font-weight: 600; padding: 8px 4px; cursor: pointer; text-decoration: none; }
.terug svg { width: 20px; height: 20px; }

/* Pagina */
main { max-width: var(--max); margin: 0 auto; padding: 20px 16px calc(110px + var(--safe-bottom)); }
body.uit main { padding-bottom: calc(40px + var(--safe-bottom)); }
.stack { display: grid; gap: 16px; }
.kop { display: grid; gap: 6px; margin-bottom: 4px; }

/* Kaarten */
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; display: grid; gap: 12px; }
.card.dark { background: var(--ink); border-color: var(--ink); color: var(--on-dark); }
.card.dark .muted { color: var(--on-dark-muted); }
.card.accent { background: linear-gradient(135deg, var(--magenta), var(--magenta-deep)); border: 0; color: #fff; }
.label { font: 700 12px/1 var(--body); letter-spacing: .08em; text-transform: uppercase; color: var(--magenta); }
.card.dark .label { color: var(--magenta-soft); }
.rij { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pill { display: inline-flex; align-items: center; gap: 6px; font: 700 12px/1 var(--body); padding: 7px 10px; border-radius: 999px; background: var(--blush); color: var(--magenta-deep); white-space: nowrap; }
.pill.ok { background: #e3f5ed; color: var(--ok); }
.pill.grijs { background: #f0ecef; color: var(--muted); }
.pill.warn { background: #fff1dc; color: var(--warn); }

/* Knoppen */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; font: 700 16px/1 var(--body); padding: 16px 22px; border-radius: 999px; border: 2px solid transparent; text-decoration: none; cursor: pointer; transition: transform .15s, background .15s; min-height: 52px; }
.btn:active { transform: scale(.98); }
.btn:focus-visible, .keuze:focus-within, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 3px solid var(--magenta-soft); outline-offset: 2px; }
.btn.primary { background: var(--magenta); color: #fff; }
.btn.primary:hover { background: var(--magenta-deep); }
.btn.big { width: 100%; font: 900 20px/1 var(--display); letter-spacing: -0.01em; padding: 20px; box-shadow: 0 12px 26px rgba(224,21,122,.3); }
.btn.wit { background: #fff; color: var(--magenta-deep); }
.btn.ghost { background: transparent; border-color: rgba(255,255,255,.3); color: var(--on-dark); }
.btn.outline { background: transparent; border-color: var(--line); color: var(--text); }
.btn.wide { width: 100%; }
.btn.klein { min-height: 40px; padding: 10px 16px; font-size: 14px; }
.btn[disabled] { opacity: .55; cursor: default; transform: none; }
.link { background: none; border: 0; color: var(--magenta-deep); font-weight: 600; padding: 6px 0; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }

/* Formulieren */
form { display: grid; gap: 14px; }
.fld { display: grid; gap: 6px; }
.fld > span { font-weight: 600; font-size: 15px; }
.fld .hint { font-size: 13px; color: var(--muted); font-weight: 400; }
input, textarea, select { width: 100%; font: 500 16px/1.3 var(--body); color: var(--text); background: #fff; border: 1.5px solid var(--line); border-radius: 14px; padding: 14px; min-height: 52px; }
textarea { min-height: 90px; resize: vertical; }
input:focus, textarea:focus { border-color: var(--magenta); outline: none; }
.twee { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.twee.pc { grid-template-columns: 1.2fr .8fr; }
.vink { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; }
.vink input { width: 22px; height: 22px; min-height: 0; flex: 0 0 auto; margin-top: 1px; accent-color: var(--magenta); }
.err { color: var(--err); font-weight: 600; font-size: 15px; background: #fdecef; padding: 12px 14px; border-radius: 12px; }
.info { font-size: 14px; background: var(--blush); border-radius: 12px; padding: 12px 14px; }
.wijkinfo { font-size: 14px; border-radius: 12px; padding: 12px 14px; background: #e3f5ed; color: #11603f; }
.wijkinfo.nee { background: #fff1dc; color: #7a4a00; }
fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 10px; }
legend { font-weight: 700; font-size: 15px; padding: 0; margin-bottom: 10px; }

/* Keuzes (chips en kaartjes) */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.keuze { position: relative; }
.keuze input { position: absolute; opacity: 0; inset: 0; min-height: 0; cursor: pointer; }
.keuze span { display: block; border: 1.5px solid var(--line); background: #fff; border-radius: 14px; padding: 12px 14px; font-weight: 600; cursor: pointer; }
.chips .keuze span { border-radius: 999px; padding: 10px 16px; }
.keuze input:checked + span { border-color: var(--magenta); background: var(--blush); color: var(--magenta-deep); box-shadow: inset 0 0 0 1px var(--magenta); }
.keuze span small { display: block; font-weight: 400; color: var(--muted); font-size: 13px; margin-top: 2px; }
.lijst-keuze { display: grid; gap: 8px; }
.teller { display: flex; align-items: center; gap: 0; border: 1.5px solid var(--line); border-radius: 999px; background: #fff; width: max-content; }
.teller button { width: 52px; height: 52px; border: 0; background: none; font: 800 24px/1 var(--display); color: var(--magenta); cursor: pointer; border-radius: 999px; }
.teller button:disabled { color: var(--line); }
.teller output { min-width: 44px; text-align: center; font: 900 22px/1 var(--display); }
.totaal { display: flex; align-items: baseline; justify-content: space-between; font-weight: 600; }
.totaal strong { font: 900 28px/1 var(--display); }

/* Welkom */
.welkom { margin: -20px -16px 0; background: var(--ink); color: var(--on-dark); padding: 28px 20px 34px; display: grid; gap: 18px; border-radius: 0 0 28px 28px; background-image: radial-gradient(circle at 90% 0%, rgba(224,21,122,.35), transparent 55%); }
.welkom h1 { font-size: 40px; color: #fff; }
.welkom h1 em { font-style: normal; color: var(--magenta); }
.welkom .usp { display: grid; gap: 8px; font-size: 15px; color: var(--on-dark-muted); }
.welkom .usp div { display: flex; gap: 10px; align-items: center; }
.welkom .usp svg { width: 18px; height: 18px; color: var(--magenta); flex: 0 0 auto; }
.stappen { display: grid; gap: 12px; counter-reset: s; }
.stap { display: grid; grid-template-columns: 36px 1fr; gap: 12px; align-items: start; }
.stap b { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--magenta); color: #fff; font: 900 16px/1 var(--display); }

/* Ronde-kaart */
.ronde-dag { font: 900 26px/1.1 var(--display); color: #fff; }
.adres { display: flex; gap: 10px; align-items: flex-start; }
.adres svg { width: 20px; height: 20px; color: var(--magenta-soft); flex: 0 0 auto; margin-top: 2px; }

/* Verzoeken */
.verzoek { display: grid; gap: 8px; }
.verzoek .datum { font: 800 17px/1.2 var(--display); }
.leeg { text-align: center; padding: 26px 18px; color: var(--muted); }
details.geschiedenis summary { cursor: pointer; font-weight: 700; padding: 6px 0; }

/* Bevestiging */
.vinkje { width: 72px; height: 72px; border-radius: 50%; background: var(--ok); display: grid; place-items: center; margin: 8px auto 0; }
.vinkje svg { width: 40px; height: 40px; color: #fff; }
.center { text-align: center; }

/* Installeer-instructie */
.os-tabs { display: grid; grid-template-columns: 1fr 1fr; background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 4px; }
.os-tabs button { border: 0; background: none; padding: 11px; border-radius: 999px; font-weight: 700; cursor: pointer; color: var(--muted); }
.os-tabs button[aria-selected="true"] { background: var(--ink); color: #fff; }
.inst { display: grid; gap: 14px; }
.inst li { display: grid; grid-template-columns: 36px 1fr; gap: 12px; align-items: start; }
.inst ol { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; }
.inst .nr { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--blush); color: var(--magenta-deep); font: 900 16px/1 var(--display); }
.ico { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: #f0ecef; vertical-align: middle; margin: 0 2px; }
.ico svg { width: 18px; height: 18px; color: #0a84ff; }
.ico.and svg { color: var(--text); }
.mock { border-radius: 14px; background: #f6f3f5; padding: 12px; display: flex; align-items: center; gap: 12px; font-weight: 600; font-size: 14px; }
.mock img { width: 44px; height: 44px; border-radius: 11px; }
.installeer-kaart { display: grid; grid-template-columns: 48px 1fr; gap: 14px; align-items: center; }
.installeer-kaart img { width: 48px; height: 48px; border-radius: 12px; }
.sluit { background: none; border: 0; color: var(--muted); cursor: pointer; padding: 4px; font-size: 22px; line-height: 1; }

/* Tabbalk onderin */
.tabs { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; background: rgba(255,255,255,.96); backdrop-filter: blur(10px); border-top: 1px solid var(--line); padding: 6px 8px calc(6px + var(--safe-bottom)); }
.tabs-in { max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); }
.tabs a { display: grid; justify-items: center; gap: 3px; padding: 6px 0; text-decoration: none; color: var(--muted); font-size: 12px; font-weight: 700; }
.tabs a svg { width: 24px; height: 24px; }
.tabs a[aria-current="page"] { color: var(--magenta); }
.tabs a.plus span { display: grid; place-items: center; width: 44px; height: 44px; margin-top: -18px; border-radius: 50%; background: var(--magenta); color: #fff; box-shadow: 0 8px 18px rgba(224,21,122,.35); }

/* Melding */
.toast { position: fixed; left: 50%; bottom: calc(96px + var(--safe-bottom)); transform: translate(-50%, 20px); background: var(--ink); color: #fff; padding: 13px 18px; border-radius: 14px; font-weight: 600; font-size: 15px; opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; max-width: calc(100% - 32px); z-index: 50; }
.toast.zichtbaar { opacity: 1; transform: translate(-50%, 0); }

@media (min-width: 700px) { h1 { font-size: 34px; } .welkom { margin: 0; border-radius: 28px; } }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
