/* ============================================================
   Ziezodan intake: één stijl, twee modi
   [data-mode="filled"]  gekleurde achtergrond, inhoud op een witte sheet
   [data-mode="light"]   witte achtergrond + accentkleuren (klantlabel)
   Kleuren per klant komen uit themes.js.
   ============================================================ */

:root {
  --accent: #f7941d;
  --accent-hover: #e5820a;
  --accent-text: #fff;
  --brand: #046d4a;
  --brand-tint: #e7f5ee;
  --bg-from: #0b7550;
  --bg-to: #005a3c;
  --footer: #1d2433;

  --sheet: #fff;
  --ink: #12241d;
  --ink-2: #5a6a63;
  --ink-3: #97a39e;
  --line: #e6ebe8;
  --soft: #f3f6f4;
  --accent-tint: color-mix(in srgb, var(--accent) 12%, #fff);
  --ring: color-mix(in srgb, var(--accent) 30%, transparent);

  --r-sm: 12px;
  --r: 16px;
  --r-lg: 24px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --spring: cubic-bezier(.3, 1.5, .5, 1);
  --font: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}

[data-mode="filled"] {
  --page: var(--bg-to);
  --hero-text: #fff;
  --hero-muted: rgba(255, 255, 255, .72);
  --dot-todo-bg: rgba(255, 255, 255, .14);
  --dot-todo-fg: rgba(255, 255, 255, .8);
  --dot-done-bg: #fff;
  --dot-done-fg: var(--brand);
  --bar-track: rgba(255, 255, 255, .2);
  --bar-fill: #fff;
  --wies-from: #8ec3e6;
  --wies-to: #0a6a46;
  --panel-bg: rgba(255, 255, 255, .1);
  --panel-line: rgba(255, 255, 255, .16);
  --panel-text: #fff;
  --panel-muted: rgba(255, 255, 255, .62);
  --logo: #fff;
  --logo-o: #fff;
}

[data-mode="light"] {
  --page: #fff;
  --ink: #1d2433;
  --ink-2: #5f6675;
  --ink-3: #9aa0ab;
  --line: #eaecf0;
  --soft: #f5f6f8;
  --hero-text: var(--ink);
  --hero-muted: var(--ink-3);
  --dot-todo-bg: #f1f2f5;
  --dot-todo-fg: #9aa0ab;
  --dot-done-bg: var(--accent);
  --dot-done-fg: #fff;
  --bar-track: #eceef2;
  --bar-fill: var(--accent);
  --wies-from: #8ec3e6;
  --wies-to: color-mix(in srgb, var(--accent) 70%, #000);
  --panel-bg: #fff;
  --panel-line: #eaecf0;
  --panel-text: var(--ink);
  --panel-muted: #8a909c;
  --logo: #1b2a4a;
  --logo-o: #3cb07e;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  font-family: var(--font);
  font-size: 16px;
  color: var(--ink);
  background: var(--page);
  -webkit-font-smoothing: antialiased;
}
/* vaste achtergrond via pseudo-element: werkt ook op iOS */
[data-mode="filled"] body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(60% 40% at 10% 0%, rgba(255, 255, 255, .07), transparent 70%),
    radial-gradient(50% 50% at 100% 30%, rgba(60, 176, 126, .18), transparent 70%),
    linear-gradient(170deg, var(--bg-from), var(--bg-to) 70%);
}
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--ring); outline-offset: 2px; }

/* ---------- Logo's ---------- */
.zz-logo { display: inline-flex; align-items: center; font-family: "Nunito", sans-serif; font-weight: 800; font-size: 25px; letter-spacing: -.6px; line-height: 1; color: var(--logo); }
.zz-o { display: inline-block; width: 16px; height: 16px; margin: 3px .5px 0; border: 3px solid var(--logo-o); border-radius: 50%; position: relative; }
.zz-o::after { content: ""; position: absolute; left: 3.2px; top: 1.4px; width: 3.4px; height: 6.2px; border: solid var(--logo-o); border-width: 0 2.4px 2.4px 0; transform: rotate(40deg); }
.wordmark { display: flex; flex-direction: column; align-items: center; color: var(--ink); line-height: 1; }
.wordmark b { font-weight: 500; letter-spacing: 5px; font-size: 15px; }
.wordmark small { font-size: 6.5px; letter-spacing: 3.6px; margin-top: 3px; color: var(--ink-2); }

/* ---------- Kop + stappen (de enige tijdlijn) ---------- */
.hero { width: 100%; max-width: 1080px; margin: 0 auto; padding: env(safe-area-inset-top) 16px 0; color: var(--hero-text); }
.hero-row { display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; height: 60px; }
.brand { display: flex; justify-content: center; }
.icon-btn { width: 40px; height: 40px; border: 0; background: none; border-radius: 50%; display: grid; place-items: center; color: var(--hero-text); transition: background .15s, opacity .2s; }
.icon-btn:hover { background: var(--dot-todo-bg); }
.icon-btn svg { width: 22px; height: 22px; }
.icon-btn.invisible { opacity: 0; pointer-events: none; }
.lang { justify-self: end; width: 30px; height: 22px; border-radius: 6px; overflow: hidden; display: grid; place-items: center; background: #fff; box-shadow: 0 0 0 1px rgba(0, 0, 0, .06); }
.flag { width: 22px; height: 14px; border-radius: 2px; background: linear-gradient(#ae1c28 0 33.3%, #fff 33.3% 66.6%, #21468b 66.6%); }

.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; padding: 6px 4px 22px; max-width: 560px; margin: 0 auto; }
.step { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 500; color: var(--hero-muted); }
.dot {
  width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center;
  background: var(--dot-todo-bg); color: var(--dot-todo-fg);
  transition: background .3s, color .3s, transform .4s var(--spring), box-shadow .3s;
}
.dot svg { width: 17px; height: 17px; }
.step.done .dot { background: var(--dot-done-bg); color: var(--dot-done-fg); }
.step.active { color: var(--hero-text); font-weight: 700; }
.step.active .dot { background: var(--accent); color: #fff; transform: scale(1.08); box-shadow: 0 0 0 5px color-mix(in srgb, var(--accent) 28%, transparent); }
.bar { width: 100%; height: 3px; border-radius: 3px; background: var(--bar-track); overflow: hidden; }
.bar i { display: block; height: 100%; width: 0; background: var(--bar-fill); border-radius: 3px; transition: width .7s var(--ease); }

/* ---------- Sheet + layout ---------- */
.stage { flex: 1; width: 100%; max-width: 720px; margin: 0 auto; display: grid; grid-template-columns: minmax(0, 1fr); }
.sheet {
  background: var(--sheet); color: var(--ink);
  border-radius: 28px 28px 0 0;
  padding: 28px 20px 32px; /* altijd ruimte onderin het witte vlak */
  min-height: calc(100dvh - 160px);
  display: flex; flex-direction: column;
  box-shadow: 0 -10px 30px rgba(0, 30, 15, .14);
}
[data-mode="light"] .sheet { border-radius: 0; box-shadow: none; border-top: 1px solid var(--line); }
@media (min-width: 1000px) {
  .stage { padding: 0 24px 40px; }
  .sheet { border-radius: var(--r-lg); padding: 40px 44px 44px; min-height: 600px; box-shadow: 0 30px 60px rgba(0, 30, 15, .22); }
  [data-mode="light"] body { background: #f5f6f8; }
  [data-mode="light"] .hero { background: transparent; }
  [data-mode="light"] .sheet { border-radius: var(--r-lg); border: 1px solid var(--line); box-shadow: 0 20px 50px rgba(16, 24, 40, .06); }
  .steps { max-width: 600px; }
}

/* ---------- Typografie ---------- */
.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 8px; }
h1, h2 { font-weight: 700; letter-spacing: -.025em; margin: 0 0 10px; }
h1 { font-size: 30px; line-height: 1.12; }
h2 { font-size: 26px; line-height: 1.18; }
.lead { color: var(--ink-2); line-height: 1.55; margin: 0 0 24px; font-size: 16.5px; }
.enter { animation: enter .5s var(--ease) both; }
@keyframes enter { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.reveal > span { display: inline-block; animation: word .5s var(--ease) both; animation-delay: calc(var(--i) * 32ms + 120ms); }
@keyframes word { from { opacity: 0; transform: translateY(8px); filter: blur(4px); } to { opacity: 1; transform: none; filter: none; } }
.stagger > * { animation: enter .45s var(--ease) both; animation-delay: calc(var(--d, 0ms) + var(--j) * 60ms); }

/* ---------- Wies ---------- */
.wies { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.wies-avatar { position: relative; width: 48px; height: 48px; border-radius: 50%; flex: none; box-shadow: 0 6px 16px rgba(60, 110, 160, .25); }
.wies-avatar img { display: block; width: 100%; height: 100%; border-radius: 50%; }
.wies:not(.thinking) .wies-avatar img { animation: wave .9s var(--spring) both; }
@keyframes wave { 0% { transform: scale(.6) rotate(-12deg); opacity: 0; } 60% { transform: scale(1.05) rotate(4deg); opacity: 1; } 100% { transform: none; } }
.wies-name { font-weight: 700; line-height: 1.2; }
.wies-name small { display: block; color: var(--ink-3); font-weight: 500; font-size: 13px; }
.wies.thinking .wies-avatar::before { content: ""; position: absolute; inset: -6px; border-radius: 50%; border: 2px solid var(--wies-from); animation: ping 1.4s var(--ease) infinite; }
@keyframes ping { from { transform: scale(.85); opacity: .9; } to { transform: scale(1.35); opacity: 0; } }
.shimmer {
  background: linear-gradient(90deg, var(--ink-3) 0%, var(--ink) 50%, var(--ink-3) 100%) 0 0 / 200% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent; animation: shimmer 1.6s linear infinite; font-weight: 600;
}
@keyframes shimmer { to { background-position: -200% 0; } }
.skeleton { display: grid; gap: 12px; margin-top: 6px; }
.skeleton i { display: block; height: 26px; border-radius: 10px; background: linear-gradient(90deg, var(--soft) 0%, var(--line) 50%, var(--soft) 100%) 0 0 / 200% 100%; animation: shimmer 1.4s linear infinite; }
.skeleton div { display: flex; gap: 10px; margin-top: 10px; }
.skeleton div i { width: 88px; height: 46px; border-radius: 999px; }
.intro { color: var(--ink-2); line-height: 1.55; margin: 0 0 10px; }
.photo-insight { display: flex; gap: 12px; align-items: center; background: var(--soft); border-radius: var(--r); padding: 10px 14px 10px 10px; margin-bottom: 18px; font-size: 14.5px; line-height: 1.45; color: var(--ink-2); }
.photo-insight img { width: 44px; height: 44px; border-radius: 10px; object-fit: cover; flex: none; }

/* ---------- Keuzes ---------- */
.choices { display: grid; gap: 10px; }
.choice {
  display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px; text-align: left;
  background: #fff; color: var(--ink); border: 1.5px solid var(--line); border-radius: var(--r);
  transition: border-color .2s, background .2s, transform .2s var(--ease), box-shadow .2s;
}
.choice:hover { border-color: var(--accent); background: var(--accent-tint); transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0, 0, 0, .06); }
.choice .tile { width: 52px; height: 52px; border-radius: 14px; background: var(--brand-tint); color: var(--brand); display: grid; place-items: center; flex: none; transition: background .2s, color .2s; }
.choice:hover .tile { background: var(--accent); color: #fff; }
.choice .tile svg { width: 26px; height: 26px; }
.choice .txt { flex: 1; min-width: 0; }
.choice b { display: block; font-size: 17px; font-weight: 700; }
.choice small { display: block; color: var(--ink-2); font-size: 14px; margin-top: 2px; line-height: 1.4; }
.choice .chev { width: 20px; height: 20px; color: var(--ink-3); flex: none; transition: transform .2s var(--ease); }
.choice:hover .chev { transform: translateX(3px); color: var(--accent); }
@media (min-width: 1000px) {
  .choices.tiles { grid-template-columns: repeat(3, 1fr); gap: 14px; }
  .choices.tiles .choice { flex-direction: column; align-items: flex-start; padding: 22px 20px; min-height: 190px; }
  .choices.tiles .chev { display: none; }
  .choices.tiles .tile { margin-bottom: 18px; }
}

/* AI-antwoorden */
.options { display: flex; flex-wrap: wrap; gap: 10px; margin: 20px 0 0; }
.options.list { display: grid; }
.option {
  display: inline-flex; align-items: center; gap: 10px; justify-content: space-between;
  background: #fff; color: var(--ink); border: 1.5px solid var(--line); border-radius: 999px;
  padding: 13px 20px; font-weight: 600; font-size: 16px; text-align: left;
  transition: border-color .2s, background .2s, transform .2s var(--ease), color .2s;
}
.options.list .option { border-radius: var(--r); padding: 16px 18px; width: 100%; }
.option:hover { border-color: var(--accent); background: var(--accent-tint); transform: translateY(-1px); }
.option:active { transform: scale(.98); }
.option .arr { width: 18px; height: 18px; color: var(--ink-3); flex: none; transition: transform .2s var(--ease), color .2s; }
.option:hover .arr { color: var(--accent); transform: translateX(3px); }
.options:not(.list) .arr { display: none; }
.option.picked { background: var(--accent); border-color: var(--accent); color: #fff; }

/* Composer (zoals een chat-app) */
.composer {
  border: 1.5px solid var(--line); border-radius: 22px; background: #fff;
  transition: border-color .2s, box-shadow .2s;
}
.composer:focus-within { border-color: var(--accent); box-shadow: 0 0 0 4px var(--ring); }
.composer textarea, .composer input {
  display: block; width: 100%; border: 0; outline: none; background: transparent; resize: none;
  padding: 18px 18px 6px; font-size: 17px; line-height: 1.5; color: var(--ink);
}
.composer textarea { min-height: 120px; }
.composer ::placeholder { color: var(--ink-3); }
.composer .attachments { display: flex; flex-wrap: wrap; gap: 8px; padding: 6px 14px 4px; }
.composer .attachments:empty { display: none; }
.toolbar { display: flex; align-items: center; gap: 8px; padding: 8px 8px 8px 10px; }
.toolbar .count { margin-left: auto; font-size: 12.5px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.tool { display: inline-flex; align-items: center; gap: 7px; border: 0; background: var(--soft); color: var(--ink); padding: 9px 14px; border-radius: 999px; font-weight: 600; font-size: 14px; transition: background .2s; }
.tool:hover { background: var(--line); }
.tool svg { width: 18px; height: 18px; }
.go {
  width: 46px; height: 46px; border-radius: 50%; border: 0; flex: none;
  background: var(--accent); color: var(--accent-text); display: grid; place-items: center;
  transition: transform .2s var(--spring), opacity .2s, background .2s;
}
.go:hover:not(:disabled) { transform: scale(1.06); background: var(--accent-hover); }
.go:disabled { opacity: .3; cursor: default; }
.go svg { width: 21px; height: 21px; }
.composer.mini { display: flex; align-items: center; margin-top: 14px; border-radius: 999px; padding: 4px; }
.composer.mini input { padding: 10px 14px; font-size: 15.5px; }
.composer.mini .go { width: 40px; height: 40px; }
.thumb { position: relative; width: 64px; height: 64px; border-radius: 12px; overflow: hidden; animation: enter .3s var(--ease) both; }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb button { position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; border-radius: 50%; border: 0; padding: 0; background: rgba(15, 15, 15, .6); color: #fff; display: grid; place-items: center; backdrop-filter: blur(4px); }
.thumb button svg { width: 12px; height: 12px; }
/* Fotoblok: prominent onder de omschrijving */
.photo-zone {
  position: relative; margin-top: 16px; padding: 26px 20px 22px; text-align: center;
  border: 2px dashed color-mix(in srgb, var(--accent) 55%, transparent); border-radius: var(--r-lg);
  background: linear-gradient(160deg, var(--accent-tint), #fff 70%);
  transition: border-color .2s, background .2s, transform .2s var(--ease);
}
.photo-zone.drag { border-color: var(--accent); background: var(--accent-tint); transform: scale(1.01); }
.pz-badge { position: absolute; top: 12px; right: 12px; display: inline-flex; align-items: center; gap: 5px; background: var(--accent); color: var(--accent-text); font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; }
.pz-badge svg { width: 13px; height: 13px; }
.pz-icon {
  width: 68px; height: 68px; margin: 4px auto 14px; border-radius: 22px; display: grid; place-items: center;
  background: var(--accent); color: var(--accent-text); box-shadow: 0 12px 26px color-mix(in srgb, var(--accent) 35%, transparent);
  animation: bob 3s ease-in-out infinite;
}
.pz-icon svg { width: 32px; height: 32px; }
@keyframes bob { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-4px) rotate(-3deg); } }
.photo-zone > b { display: block; font-size: 19px; letter-spacing: -.01em; }
.photo-zone > p { margin: 6px auto 18px; max-width: 380px; color: var(--ink-2); line-height: 1.5; font-size: 15px; }
.pz-btns { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; align-items: center; }
.pz-btns .btn { min-height: 50px; padding: 0 22px; font-size: 15.5px; }
.pz-btns .btn.secondary { background: #fff; border: 1.5px solid var(--line); }
.pz-drop { color: var(--ink-3); font-size: 14px; }
.photo-zone.filled { padding: 16px; text-align: left; border-style: solid; border-color: var(--line); background: #fff; }
.pz-head { display: flex; gap: 10px; align-items: center; margin-bottom: 12px; font-size: 14px; color: var(--ink-2); }
.pz-head > svg { width: 22px; height: 22px; color: #2e9e6b; flex: none; }
.pz-head b { display: block; color: var(--ink); font-size: 15px; }
.pz-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
@media (min-width: 560px) { .pz-grid { grid-template-columns: repeat(4, 1fr); } }
.pz-thumb { position: relative; aspect-ratio: 1; border-radius: 14px; overflow: hidden; animation: enter .35s var(--ease) both; }
.pz-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pz-thumb button { position: absolute; top: 6px; right: 6px; width: 28px; height: 28px; border-radius: 50%; border: 0; padding: 0; background: rgba(15, 15, 15, .6); color: #fff; display: grid; place-items: center; backdrop-filter: blur(4px); }
.pz-thumb button svg { width: 14px; height: 14px; }
.pz-more {
  aspect-ratio: 1; border-radius: 14px; border: 2px dashed color-mix(in srgb, var(--accent) 55%, transparent); background: var(--accent-tint);
  color: var(--ink); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; font-weight: 600; font-size: 13.5px;
  transition: border-color .2s, transform .2s var(--ease);
}
.pz-more:hover { border-color: var(--accent); transform: translateY(-1px); }
.pz-more svg { width: 24px; height: 24px; color: var(--accent); }
.hint { font-size: 13.5px; color: var(--ink-3); margin: 12px 4px 0; display: flex; gap: 6px; align-items: center; }
.hint svg { width: 15px; height: 15px; }

/* Adres zoeken */
.search { position: relative; }
.search > svg { position: absolute; left: 18px; top: 50%; transform: translateY(-50%); width: 21px; height: 21px; color: var(--ink-3); pointer-events: none; }
.search input {
  width: 100%; min-height: 60px; padding: 0 18px 0 50px; border-radius: 999px;
  background: var(--soft); border: 1.5px solid transparent; outline: none; font-size: 17px; color: var(--ink);
  transition: background .2s, border-color .2s, box-shadow .2s;
}
.search input:focus { background: #fff; border-color: var(--accent); box-shadow: 0 0 0 4px var(--ring); }
.search input::placeholder { color: var(--ink-3); }
.suggest { list-style: none; margin: 10px 0 0; padding: 6px; border: 1px solid var(--line); border-radius: var(--r); background: #fff; box-shadow: 0 16px 40px rgba(0, 0, 0, .08); animation: enter .25s var(--ease) both; }
.suggest button { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 12px; border: 0; border-radius: 10px; background: none; color: var(--ink); font-size: 15.5px; line-height: 1.35; }
.suggest button svg { width: 18px; height: 18px; flex: none; color: var(--ink-3); }
.suggest button b { font-weight: 700; }
.suggest button:hover, .suggest button.active { background: var(--soft); }
.note { margin: 12px 4px 0; font-size: 14px; color: var(--ink-2); display: flex; gap: 8px; align-items: center; }
.note > svg { width: 16px; height: 16px; flex: none; }
.found { display: flex; gap: 14px; align-items: center; padding: 16px; border-radius: var(--r); background: var(--soft); animation: enter .4s var(--ease) both; }
.found .tile { width: 46px; height: 46px; border-radius: 12px; background: var(--brand); color: #fff; display: grid; place-items: center; flex: none; }
.found .tile svg { width: 22px; height: 22px; }
.found b { display: block; font-size: 17px; }
.found small { color: var(--ink-2); font-size: 14px; }
.found .change { margin-left: auto; }

.field { margin-bottom: 16px; }
.field label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 7px; }
.field label span { color: var(--ink-3); font-weight: 500; }
.input {
  width: 100%; min-height: 54px; padding: 14px 16px; border-radius: var(--r-sm);
  background: var(--soft); border: 1.5px solid transparent; outline: none; font-size: 16.5px; color: var(--ink);
  transition: background .2s, border-color .2s, box-shadow .2s;
}
.input:focus { background: #fff; border-color: var(--accent); box-shadow: 0 0 0 4px var(--ring); }
.input::placeholder { color: var(--ink-3); }
textarea.input { min-height: 96px; resize: vertical; line-height: 1.5; }

/* ---------- Acties ---------- */
.spacer { flex: 1; min-height: 24px; }
.actions {
  position: sticky; bottom: 0; z-index: 5;
  margin: 0 -20px -32px; padding: 16px 20px calc(16px + env(safe-area-inset-bottom)); /* vaste balk blijft tegen de onderrand */
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0), var(--sheet) 20px);
  display: grid; gap: 8px;
}
@media (min-width: 1000px) { .actions { position: static; margin: 0; padding: 24px 0 0; background: none; grid-template-columns: auto auto; justify-content: start; } }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 56px; padding: 0 28px;
  border: 0; border-radius: 999px; background: var(--accent); color: var(--accent-text); font-weight: 700; font-size: 16.5px;
  box-shadow: 0 10px 24px color-mix(in srgb, var(--accent) 32%, transparent);
  transition: background .2s, transform .2s var(--ease), opacity .2s, box-shadow .2s;
}
.btn:hover:not(:disabled) { background: var(--accent-hover); transform: translateY(-1px); }
.btn:active { transform: scale(.98); }
.btn svg { width: 19px; height: 19px; transition: transform .2s var(--ease); }
.btn:hover:not(:disabled) svg { transform: translateX(3px); }
.btn:disabled { opacity: .35; box-shadow: none; cursor: default; }
.btn.secondary { background: var(--soft); color: var(--ink); box-shadow: none; }
.btn.secondary:hover { background: var(--line); }
.text-btn { background: none; border: 0; padding: 10px 2px; font-weight: 700; font-size: 15px; color: var(--ink); text-decoration: underline; text-underline-offset: 4px; text-decoration-color: var(--ink-3); }
.text-btn:hover { text-decoration-color: var(--accent); }

/* ---------- Zelfhulpvideo ---------- */
.video-card { display: block; width: 100%; padding: 0; overflow: hidden; text-align: left; margin: 18px 0 6px; border: 1.5px solid var(--line); border-radius: var(--r-lg); background: #fff; transition: transform .25s var(--ease), box-shadow .25s; }
.video-card:hover { transform: translateY(-3px); box-shadow: 0 18px 40px rgba(0, 0, 0, .1); }
.poster { position: relative; aspect-ratio: 16 / 8.5; background: #bfe3f2; overflow: hidden; }
.poster svg.scene { position: absolute; inset: 0; width: 100%; height: 100%; }
.play { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 64px; height: 64px; border-radius: 50%; background: rgba(255, 255, 255, .85); backdrop-filter: blur(8px); color: var(--ink); display: grid; place-items: center; box-shadow: 0 10px 30px rgba(0, 0, 0, .18); transition: transform .3s var(--spring); }
.video-card:hover .play { transform: translate(-50%, -50%) scale(1.1); }
.play svg { width: 24px; height: 24px; margin-left: 3px; }
.dur { position: absolute; right: 12px; bottom: 12px; background: rgba(0, 0, 0, .6); backdrop-filter: blur(6px); color: #fff; font-size: 12px; font-weight: 700; padding: 4px 8px; border-radius: 8px; }
.video-meta { padding: 14px 18px 16px; display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.video-meta b { display: block; font-size: 16.5px; }
.video-meta span { font-size: 13.5px; color: var(--ink-2); }
.video-meta .badge { font-size: 12.5px; font-weight: 700; color: var(--brand); background: var(--brand-tint); padding: 5px 10px; border-radius: 999px; white-space: nowrap; }

.video-modal { position: fixed; inset: 0; background: #0b0f0d; z-index: 50; display: flex; flex-direction: column; justify-content: center; animation: fade .25s; }
@keyframes fade { from { opacity: 0; } }
.video-modal .close { position: absolute; top: calc(14px + env(safe-area-inset-top)); right: 14px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .14); color: #fff; display: grid; place-items: center; z-index: 2; backdrop-filter: blur(8px); }
.video-modal .close svg { width: 20px; height: 20px; }
.video-stage { position: relative; width: 100%; max-width: 960px; margin: 0 auto; aspect-ratio: 16 / 9; background: #bfe3f2; overflow: hidden; }
@media (min-width: 1000px) { .video-stage { border-radius: 20px; } }
.video-stage svg.scene { position: absolute; inset: 0; width: 100%; height: 100%; }
.caption { position: absolute; left: 50%; bottom: 7%; transform: translateX(-50%); background: rgba(15, 15, 15, .75); backdrop-filter: blur(6px); color: #fff; padding: 6px 14px; border-radius: 8px; font-size: clamp(13px, 2.4vw, 20px); white-space: nowrap; max-width: 92%; overflow: hidden; text-overflow: ellipsis; }
.video-bottom { width: 100%; max-width: 960px; margin: 18px auto 0; padding: 0 20px; color: #fff; }
.video-progress { height: 4px; background: rgba(255, 255, 255, .2); border-radius: 4px; overflow: hidden; margin-bottom: 14px; }
.video-progress i { display: block; height: 100%; width: 0; background: var(--accent); }
.video-bottom span { display: block; color: rgba(255, 255, 255, .6); font-size: 14px; margin-top: 2px; }

.anim-lift { animation: lift 4s ease-in-out infinite; }
@keyframes lift { 0%, 25% { transform: translateY(0); } 55%, 80% { transform: translateY(-46px); } 100% { transform: translateY(0); } }
.anim-drop { animation: drop 1.4s ease-in infinite; }
@keyframes drop { 0% { transform: translateY(0); opacity: 1; } 100% { transform: translateY(60px); opacity: 0; } }
.anim-needle { transform-origin: 320px 190px; animation: needle 5s ease-in-out infinite; }
@keyframes needle { 0%, 15% { transform: rotate(-70deg); } 60%, 85% { transform: rotate(10deg); } 100% { transform: rotate(-70deg); } }
.anim-turn { transform-box: fill-box; transform-origin: center; animation: turn 3s ease-in-out infinite; }
@keyframes turn { 0%, 20% { transform: rotate(0); } 60%, 85% { transform: rotate(-90deg); } 100% { transform: rotate(0); } }

/* ---------- Samenvatting ---------- */
.summary { border: 1.5px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: #fff; }
.sum-head { display: flex; gap: 14px; align-items: center; padding: 18px 20px; background: linear-gradient(135deg, var(--brand-tint), #fff); }
.sum-head .tile { width: 50px; height: 50px; border-radius: 14px; background: var(--brand); color: #fff; display: grid; place-items: center; flex: none; }
.sum-head .tile svg { width: 24px; height: 24px; }
.sum-head small { color: var(--ink-2); font-weight: 600; font-size: 13px; }
.sum-title { font-size: 21px; font-weight: 700; letter-spacing: -.02em; line-height: 1.2; }
.badge-urgent { display: inline-flex; align-items: center; gap: 5px; background: #fff1e2; color: #a14f00; font-size: 12px; font-weight: 700; padding: 4px 9px; border-radius: 999px; margin-left: 6px; vertical-align: 3px; }
.badge-urgent svg { width: 13px; height: 13px; }
.sum-body { padding: 4px 20px 8px; }
.sum-sec { padding: 14px 0; border-top: 1px solid var(--line); }
.sum-sec:first-child { border-top: 0; }
.sum-desc { display: flex; gap: 12px; }
.sum-desc img { width: 62px; height: 62px; border-radius: 12px; object-fit: cover; flex: none; }
.sum-desc q { display: block; line-height: 1.5; color: var(--ink); quotes: "“" "”"; }
.sum-notes { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 6px; }
.sum-notes li { display: flex; gap: 8px; font-size: 14px; color: var(--ink-2); line-height: 1.4; }
.sum-notes svg { width: 16px; height: 16px; flex: none; margin-top: 2px; color: var(--brand); }
.k { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 8px; }
.path { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 4px; font-size: 14px; font-weight: 600; }
.path span { background: var(--soft); padding: 4px 10px; border-radius: 999px; white-space: nowrap; }
.path span:last-child { background: var(--brand-tint); color: var(--brand); }
.path svg { width: 13px; height: 13px; color: var(--ink-3); }
.facts { display: grid; gap: 12px; }
.fact { display: flex; gap: 12px; align-items: center; font-size: 15px; }
.fact .ic { width: 34px; height: 34px; border-radius: 10px; background: var(--soft); display: grid; place-items: center; flex: none; color: var(--ink-2); }
.fact .ic svg { width: 17px; height: 17px; }
.fact b { display: block; font-size: 12.5px; color: var(--ink-3); font-weight: 600; }

/* ---------- Afspraak ---------- */
/* Tijdsloten onder elkaar, zoals in de huidige intake */
.slots { display: grid; gap: 10px; }
.slot-card {
  display: flex; align-items: stretch; width: 100%; min-height: 76px; padding: 0; overflow: hidden; text-align: left;
  border: 1.5px solid var(--line); border-radius: var(--r); background: #fff; color: var(--ink);
  transition: border-color .2s, background .2s, transform .2s var(--ease), box-shadow .2s;
}
.slot-card:hover { border-color: var(--accent); transform: translateY(-1px); box-shadow: 0 8px 20px rgba(0, 0, 0, .06); }
.slot-card .cal { position: relative; width: 68px; flex: none; display: grid; place-items: center; color: var(--ink); }
.slot-card .cal svg { width: 36px; height: 36px; stroke-width: 1.6; }
.slot-card .cal span { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -12%); font-weight: 700; font-size: 13px; }
.slot-card .when { flex: 1; padding: 14px 8px 14px 0; display: flex; flex-direction: column; justify-content: center; }
.slot-card .when b { font-size: 17px; font-weight: 700; letter-spacing: -.01em; }
.slot-card .when span { color: var(--ink-2); font-size: 15px; margin-top: 1px; }
.slot-card .radio { align-self: center; width: 22px; height: 22px; margin-right: 18px; border-radius: 50%; border: 2px solid var(--line); flex: none; transition: border-color .2s, box-shadow .2s; }
.slot-card .eco { width: 76px; flex: none; background: #8cc63f; color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: 17px; font-weight: 600; letter-spacing: .02em; }
.slot-card .eco svg { width: 22px; height: 22px; }
.slot-card.sel { border-color: var(--accent); background: var(--accent-tint); box-shadow: 0 0 0 3px var(--ring); }
.slot-card.sel .radio { border-color: var(--accent); box-shadow: inset 0 0 0 5px #fff, inset 0 0 0 12px var(--accent); }
.text-btn.more { display: block; margin: 12px auto 0; text-decoration: none; font-size: 14px; letter-spacing: .02em; text-transform: uppercase; }
.text-btn.more:hover { color: var(--accent); }
.urgent-card { display: flex; gap: 14px; padding: 20px; border-radius: var(--r-lg); background: #fff6ec; }
.urgent-card .tile { width: 48px; height: 48px; border-radius: 14px; background: #ffe2c2; color: #c45f00; display: grid; place-items: center; flex: none; }
.urgent-card .tile svg { width: 22px; height: 22px; }
.urgent-card p { margin: 4px 0 0; color: var(--ink-2); line-height: 1.5; font-size: 15px; }

/* ---------- Bevestiging ---------- */
.success { text-align: center; padding: 12px 0 4px; }
.check-anim { width: 88px; height: 88px; margin: 0 auto 20px; display: block; }
.check-anim circle { fill: var(--accent); transform-origin: center; animation: pop .55s var(--spring) both; }
.check-anim path { fill: none; stroke: #fff; stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 60; stroke-dashoffset: 60; animation: draw .45s .35s var(--ease) forwards; }
@keyframes pop { from { transform: scale(.3); opacity: 0; } }
@keyframes draw { to { stroke-dashoffset: 0; } }
.ticket { display: inline-flex; gap: 6px; align-items: center; margin-top: 6px; padding: 7px 14px; border-radius: 999px; background: var(--soft); font-weight: 700; font-size: 14px; font-variant-numeric: tabular-nums; }
.appt { display: flex; gap: 14px; align-items: center; padding: 16px; margin: 24px 0 14px; text-align: left; border-radius: var(--r-lg); background: var(--accent-tint); }
.appt .tile { width: 50px; height: 50px; border-radius: 14px; background: var(--accent); color: #fff; display: grid; place-items: center; flex: none; }
.appt .tile svg { width: 24px; height: 24px; }
.appt b { display: block; font-size: 16.5px; }
.appt span { color: var(--ink-2); font-size: 14px; }
.feedback { display: flex; gap: 10px; justify-content: center; margin-top: 14px; }


/* ---------- Voet ---------- */
.foot { width: 100%; }
.partner { text-align: center; padding: 26px 20px 22px; color: var(--ink-2); font-size: 14px; background: var(--sheet); }
.partner .zz-logo { margin-top: 8px; font-size: 22px; }
.theme-switch { display: flex; justify-content: center; align-items: center; gap: 8px; padding: 12px 20px calc(18px + env(safe-area-inset-bottom)); font-size: 12.5px; color: rgba(255, 255, 255, .6); }
[data-mode="filled"] .foot { background: var(--sheet); }
[data-mode="filled"] .theme-switch { color: var(--ink-3); }
.seg-ctl { display: inline-flex; background: rgba(127, 127, 127, .14); border-radius: 999px; padding: 3px; }
.seg-ctl button { border: 0; background: none; padding: 6px 12px; border-radius: 999px; font-weight: 600; font-size: 12.5px; color: inherit; }
.seg-ctl button.on { background: #fff; color: var(--ink); box-shadow: 0 1px 3px rgba(0, 0, 0, .12); }
[data-mode="light"] .foot { background: var(--footer); }
@media (min-width: 1000px) {
  [data-mode="filled"] .foot { background: none; }
  [data-mode="filled"] .theme-switch { color: rgba(255, 255, 255, .7); }
  [data-mode="light"] .partner { background: #f5f6f8; }
}

@media (max-width: 380px) {
  h1 { font-size: 26px; }
  h2 { font-size: 23px; }
  .sheet { padding-left: 16px; padding-right: 16px; }
  .actions { margin: 0 -16px -32px; padding-left: 16px; padding-right: 16px; }
  .step { font-size: 11.5px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0ms !important; transition-duration: .01ms !important; }
}

/* Fotoblok compact op mobiel: icoon naast de tekst, knoppen eronder */
@media (max-width: 999px) {
  .composer textarea { min-height: 96px; }
  .photo-zone:not(.filled) {
    display: grid; grid-template-columns: 56px 1fr; column-gap: 14px; align-items: center;
    text-align: left; padding: 18px 16px 16px;
  }
  .photo-zone:not(.filled) .pz-icon { width: 56px; height: 56px; border-radius: 18px; margin: 0; grid-row: span 2; }
  .photo-zone:not(.filled) .pz-icon svg { width: 26px; height: 26px; }
  .photo-zone:not(.filled) > b { font-size: 17px; padding-right: 96px; }
  .photo-zone:not(.filled) > p { margin: 2px 0 0; font-size: 14px; }
  .photo-zone:not(.filled) .pz-btns { grid-column: 1 / -1; margin-top: 14px; display: grid; grid-template-columns: 1fr 1fr; }
  .photo-zone:not(.filled) .pz-btns .btn { padding: 0 12px; }
}

/* ---------- Eigen verantwoordelijkheid ---------- */
.resp-card { margin: 6px 0 22px; padding: 18px 18px 16px; border-radius: var(--r-lg); background: var(--soft); border: 1px solid var(--line); }
.resp-card p { margin: 10px 0 0; line-height: 1.55; color: var(--ink); }
.resp-badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; color: var(--ink-2); background: #fff; border: 1px solid var(--line); padding: 5px 10px; border-radius: 999px; }
.resp-badge svg { width: 14px; height: 14px; }
.ask-label { font-weight: 700; margin: 0 0 12px; }
.choice.primary { border-color: var(--accent); background: var(--accent-tint); }
.choice.primary .tile { background: var(--accent); color: #fff; }
.resp-good { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; margin-bottom: 18px; border-radius: var(--r); background: #e9f7ef; color: #1d5b3c; font-size: 14.5px; line-height: 1.5; }
.resp-good svg { width: 20px; height: 20px; flex: none; color: #2e9e6b; margin-top: 1px; }
.fact .src { display: block; font-size: 12.5px; color: var(--ink-3); margin-top: 1px; }
.anim-plunge { animation: plunge 1.1s ease-in-out infinite; }
@keyframes plunge { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(22px); } }

/* ---------- Verfijning: extra onderdelen uit het API-bericht ---------- */
.video-card .badge { display: inline-flex; gap: 4px; align-items: center; }
.video-card .badge svg { width: 13px; height: 13px; }
.q-image { display: block; width: 100%; border-radius: var(--r-lg); margin: 16px 0 4px; }
.photo-ask { margin: 18px 0 4px; padding: 16px; border-radius: var(--r-lg); border: 2px dashed color-mix(in srgb, var(--accent) 55%, transparent); background: linear-gradient(160deg, var(--accent-tint), #fff 70%); transition: border-color .2s, background .2s; }
.photo-ask.drag { border-color: var(--accent); background: var(--accent-tint); }
.pa-head { display: flex; gap: 12px; align-items: center; margin-bottom: 14px; }
.pa-head b { display: block; font-size: 15.5px; line-height: 1.35; }
.pa-head small { color: var(--ink-2); font-size: 13.5px; }
.pa-icon { width: 44px; height: 44px; border-radius: 14px; background: var(--accent); color: var(--accent-text); display: grid; place-items: center; flex: none; }
.pa-icon svg { width: 22px; height: 22px; }
.photo-ask .pz-btns { justify-content: flex-start; }
.photo-ask .pz-btns .btn { min-height: 46px; padding: 0 18px; font-size: 15px; }
.photo-ask .pz-btns .btn.secondary { background: #fff; border: 1.5px solid var(--line); }
@media (max-width: 999px) { .photo-ask .pz-btns { display: grid; grid-template-columns: 1fr 1fr; } }
.photo-ask + .choices, .photo-ask + .options { margin-top: 18px; }

/* ---------- Beslisboom (backup-flow en aanpassen) ---------- */
.crumbs-inline { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; margin: -2px 0 18px; }
.crumbs-inline button { display: inline-flex; align-items: center; gap: 6px; border: 0; background: var(--soft); color: var(--ink); padding: 6px 10px; border-radius: 999px; font-size: 13.5px; font-weight: 600; }
.crumbs-inline button:hover { background: var(--accent-tint); }
.crumbs-inline button svg { width: 13px; height: 13px; color: var(--ink-3); }
.crumbs-inline .sep { width: 14px; height: 14px; color: var(--ink-3); }
.crumb-list { display: grid; gap: 8px; }
.crumb-row { display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px 16px; text-align: left; border: 1.5px solid var(--line); border-radius: var(--r); background: #fff; color: var(--ink); transition: border-color .2s, background .2s; }
.crumb-row:hover { border-color: var(--accent); background: var(--accent-tint); }
.crumb-row .lvl { width: 28px; height: 28px; border-radius: 50%; background: var(--soft); color: var(--ink-2); display: grid; place-items: center; font-size: 13px; font-weight: 700; flex: none; }
.crumb-row .txt { flex: 1; font-weight: 600; }
.crumb-row .pen { width: 18px; height: 18px; color: var(--accent); }
.k-row { display: flex; justify-content: space-between; align-items: center; }
.edit-btn { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; color: var(--ink); font-weight: 700; font-size: 13.5px; padding: 4px 0; margin-bottom: 8px; }
.edit-btn svg { width: 15px; height: 15px; color: var(--accent); }
.edit-btn:hover { color: var(--accent); }

/* ---------- Controle en vervolg ---------- */
.resp-warn { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; margin-bottom: 16px; border-radius: var(--r); background: #fff6ec; color: #7a4300; font-size: 14.5px; line-height: 1.5; }
.resp-warn svg { width: 20px; height: 20px; flex: none; color: #d26a00; margin-top: 1px; }
.specialist-card { display: flex; gap: 14px; padding: 20px; border-radius: var(--r-lg); background: var(--brand-tint); }
.specialist-card .tile { width: 48px; height: 48px; border-radius: 14px; background: var(--brand); color: #fff; display: grid; place-items: center; flex: none; }
.specialist-card .tile svg { width: 22px; height: 22px; }
.specialist-card p { margin: 4px 0 0; color: var(--ink-2); line-height: 1.5; font-size: 15px; }
.end-icon { width: 72px; height: 72px; margin: 0 auto 18px; border-radius: 50%; background: var(--brand-tint); color: var(--brand); display: grid; place-items: center; }
.end-icon svg { width: 34px; height: 34px; }
a.btn { text-decoration: none; }

/* ---------- Demo-voet: API-berichten en rapportage ---------- */
.theme-switch { flex-wrap: wrap; row-gap: 10px; }
.api-btn { display: inline-flex; align-items: center; gap: 6px; border: 0; background: rgba(127, 127, 127, .14); color: inherit; padding: 7px 12px; border-radius: 999px; font-weight: 600; font-size: 12.5px; }
.api-btn:hover { background: rgba(127, 127, 127, .24); }
.api-btn svg, .prevented svg { width: 14px; height: 14px; }
.prevented { display: inline-flex; align-items: center; gap: 6px; }

/* ---------- API-berichten (inspector) ---------- */
.drawer {
  position: fixed; z-index: 40; right: 0; top: 0; bottom: 0; width: min(480px, 100%);
  background: #0f1714; color: #dfe9e4; display: flex; flex-direction: column;
  box-shadow: -20px 0 50px rgba(0, 0, 0, .3); animation: slideIn .3s var(--ease);
}
@keyframes slideIn { from { transform: translateX(100%); } }
.drawer-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: calc(16px + env(safe-area-inset-top)) 16px 14px 20px; border-bottom: 1px solid rgba(255, 255, 255, .08); }
.drawer-head b { display: block; font-size: 16px; color: #fff; }
.drawer-head small { color: rgba(255, 255, 255, .55); font-size: 12.5px; }
.drawer-head .icon-btn { color: #fff; }
.drawer-body { flex: 1; overflow: auto; padding: 12px 12px calc(20px + env(safe-area-inset-bottom)); display: grid; gap: 10px; align-content: start; }
.drawer .empty { color: rgba(255, 255, 255, .55); padding: 12px; }
.api-entry { background: rgba(255, 255, 255, .04); border: 1px solid rgba(255, 255, 255, .08); border-radius: 12px; }
.api-entry summary { list-style: none; cursor: pointer; display: flex; gap: 10px; align-items: center; padding: 12px 14px; font-size: 13px; }
.api-entry summary::-webkit-details-marker { display: none; }
.api-entry .ep { font-family: ui-monospace, "Cascadia Code", Consolas, monospace; color: #fff; font-weight: 600; }
.api-entry .nx { color: #f7b464; font-weight: 700; }
.api-entry .tm { margin-left: auto; color: rgba(255, 255, 255, .45); }
.api-entry .lbl { padding: 2px 14px 6px; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: rgba(255, 255, 255, .45); font-weight: 700; }
.api-entry pre { margin: 0 10px 12px; padding: 12px; border-radius: 8px; background: rgba(0, 0, 0, .35); font: 12px/1.55 ui-monospace, "Cascadia Code", Consolas, monospace; white-space: pre-wrap; word-break: break-word; color: #c9d6d0; }
.j-key { color: #8fd3b0; }
.j-str { color: #f2c99a; }
.j-lit { color: #9cc3ff; }

/* Logo als afbeelding in de kop */
.brand-logo { display: block; height: 30px; width: auto; }
@media (max-width: 380px) { .brand-logo { height: 26px; } }
