/* ============================================================
   OptimAI Dashboard — design tokens uit pitchdeck
   Cream #F4F1E8 · Ink #0B0B0C · Lime #C3F380 · Groen #125603
   Geel #FAE170/#906713 · Rood #D13F13 · Paars #7523B4
   Blauw #0D5072 · Cyaan #7FEEFF · Roze #F058AB/#FF97D0
   ============================================================ */

:root {
  --cream: #F4F1E8;
  --cream-2: #EDE9DC;
  --paper: #FBF9F2;
  --ink: #0B0B0C;
  --muted: #6B6960;
  --line: rgba(11, 11, 12, 0.14);

  --lime: #C3F380;
  --green: #125603;
  --yellow: #FAE170;
  --yellow-d: #6B4C0B;
  --red: #D13F13;
  --red-d: #630700;
  --purple: #7523B4;
  --blue: #0D5072;
  --cyan: #7FEEFF;
  --pink: #F058AB;
  --pink-l: #FF97D0;

  --accent: var(--lime);
  --accent-d: var(--green);

  --radius: 14px;
  --radius-s: 9px;
  --pad: 22px;
  --gap: 14px;

  --font: "Helvetica Neue", Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font);
  font-size: 14.5px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--accent); color: var(--ink); }

button { font-family: var(--font); cursor: pointer; }
textarea, input { font-family: var(--font); }

/* ---------- typografische bouwstenen ---------- */
.kicker {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.kicker b { color: var(--ink); font-weight: 700; }

.h-display {
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.04;
  margin: 0;
}

.num-label {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.08em;
}

/* ---------- layout shell ---------- */
.shell {
  display: grid;
  grid-template-columns: 248px 1fr;
  min-height: 100vh;
}

/* ---------- sidebar ---------- */
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  border-right: 1.5px solid var(--ink);
  background: var(--cream);
  padding: 26px 18px 18px;
  overflow-y: auto;
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 0 8px 22px;
}
.brand .mark {
  font-size: 19px;
  color: var(--accent-d);
  line-height: 1;
  transform: translateY(1px);
}
.brand .name {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.045em;
}
.brand .name span { color: var(--accent-d); }

.nav { display: flex; flex-direction: column; gap: 3px; }

.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  border: 1.5px solid transparent;
  background: transparent;
  border-radius: var(--radius-s);
  padding: 9px 10px;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--ink);
  text-align: left;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.nav-item:hover { background: var(--cream-2); }
.nav-item.active {
  background: var(--ink);
  color: var(--cream);
  border-color: var(--ink);
}
.nav-item .nn {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--muted);
  width: 18px;
  font-variant-numeric: tabular-nums;
}
.nav-item.active .nn { color: var(--accent); }
.nav-item .badge {
  margin-left: auto;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
  background: var(--accent);
  color: var(--accent-d);
}
.nav-item.active .badge { background: var(--accent); color: var(--accent-d); }

.nav-sep {
  margin: 16px 8px 8px;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.sidebar-foot {
  margin-top: auto;
  padding: 14px 8px 0;
  border-top: 1.5px solid var(--line);
}
.company-chip {
  display: flex;
  align-items: center;
  gap: 10px;
}
.company-chip .avatar {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-s);
  background: var(--ink);
  color: var(--lime);
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.company-chip .cname { font-size: 13px; font-weight: 700; line-height: 1.2; }
.company-chip .csub { font-size: 10.5px; color: var(--muted); letter-spacing: 0.06em; text-transform: uppercase; }

/* ---------- main ---------- */
.main { padding: 0 34px 60px; min-width: 0; }

.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  padding: 30px 0 20px;
  border-bottom: 1.5px solid var(--ink);
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.page-head h1 { font-size: 32px; }
.page-head .sub { color: var(--muted); margin-top: 7px; max-width: 560px; font-size: 14px; }

/* ---------- cards ---------- */
.card {
  background: var(--paper);
  border: 1.5px solid var(--ink);
  border-radius: var(--radius);
  overflow: hidden;
}
.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px var(--pad) 12px;
  border-bottom: 1.5px solid var(--line);
}
.card-head .kicker { color: var(--ink); }
.card-body { padding: var(--pad); }

/* ---------- chips / pills ---------- */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 22px;
  padding: 0 9px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}
.pill .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

.pill.lime   { background: var(--lime);   color: var(--green); }
.pill.yellow { background: var(--yellow); color: var(--yellow-d); }
.pill.pink   { background: var(--pink-l); color: #8a1356; }
.pill.cyan   { background: var(--cyan);   color: var(--blue); }
.pill.red    { background: #F8CDBF;       color: #A12F0C; }
.pill.purple { background: #E4CCF8;       color: var(--purple); }
.pill.ink    { background: var(--ink);    color: var(--cream); }
.pill.ghost  { background: transparent;   color: var(--muted); border: 1.5px solid var(--line); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 36px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1.5px solid var(--ink);
  background: transparent;
  color: var(--ink);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: transform 0.08s ease, background 0.12s ease, box-shadow 0.12s ease;
  white-space: nowrap;
}
.btn:hover { background: var(--cream-2); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--ink); color: var(--cream); }
.btn.primary:hover { background: #232325; }
.btn.accent { background: var(--accent); color: var(--ink); border-color: var(--ink); }
.btn.accent:hover { filter: brightness(0.97); }
.btn.sm { height: 29px; padding: 0 12px; font-size: 11.5px; }
.btn:disabled { opacity: 0.45; cursor: default; }
.btn .arrow { font-size: 14px; line-height: 1; }

/* ---------- lijstrijen ---------- */
.row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px var(--pad);
  border-bottom: 1.5px solid var(--line);
}
.row:last-child { border-bottom: none; }
.row.clickable { cursor: pointer; transition: background 0.1s ease; }
.row.clickable:hover { background: rgba(11,11,12,0.025); }

.row .grow { flex: 1; min-width: 0; }
.row .title { font-weight: 600; font-size: 14px; }
.row .meta { font-size: 12px; color: var(--muted); margin-top: 2px; }

/* checkbox in deck-stijl */
.check {
  width: 22px;
  height: 22px;
  flex: none;
  border: 1.5px solid var(--ink);
  border-radius: 7px;
  background: var(--paper);
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 700;
  color: transparent;
  transition: background 0.12s ease, color 0.12s ease;
  padding: 0;
}
.check.done { background: var(--accent); color: var(--ink); }
.row.task-done .title { text-decoration: line-through; color: var(--muted); }
.row.task-done .meta { text-decoration: line-through; }

/* ---------- stat tegels ---------- */
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap); }
.stat {
  border: 1.5px solid var(--ink);
  border-radius: var(--radius);
  padding: 18px 20px 16px;
  background: var(--paper);
}
.stat .v { font-size: 36px; font-weight: 700; letter-spacing: -0.03em; line-height: 1; }
.stat .v small { font-size: 16px; font-weight: 700; letter-spacing: 0; }
.stat .l { margin-top: 9px; font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.stat .d { margin-top: 4px; font-size: 12px; color: var(--muted); }
.stat.fill-lime   { background: var(--lime); }
.stat.fill-yellow { background: var(--yellow); }
.stat.fill-pink   { background: var(--pink-l); }
.stat.fill-cyan   { background: var(--cyan); }
.stat.fill-lime .l, .stat.fill-yellow .l, .stat.fill-pink .l, .stat.fill-cyan .l { color: rgba(11,11,12,0.62); }
.stat.fill-lime .d, .stat.fill-yellow .d, .stat.fill-pink .d, .stat.fill-cyan .d { color: rgba(11,11,12,0.62); }

/* ---------- module grid layouts ---------- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); align-items: start; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); align-items: start; }
.grid-main-side { display: grid; grid-template-columns: 1fr 360px; gap: var(--gap); align-items: start; }
.stack { display: flex; flex-direction: column; gap: var(--gap); }

/* ---------- agent kaarten ---------- */
.agent-card {
  border: 1.5px solid var(--ink);
  border-radius: var(--radius);
  background: var(--paper);
  padding: 18px 18px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: transform 0.1s ease, box-shadow 0.1s ease;
}
.agent-card:hover { transform: translateY(-2px); box-shadow: 4px 4px 0 var(--ink); }
.agent-glyph {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 17px;
  font-weight: 700;
  border: 1.5px solid var(--ink);
}
.agent-card h3 { margin: 0; font-size: 15.5px; font-weight: 700; letter-spacing: -0.01em; }
.agent-card p { margin: 0; font-size: 12.5px; color: var(--muted); line-height: 1.45; flex: 1; }
.agent-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.agent-foot .uses { font-size: 11px; color: var(--muted); font-weight: 600; letter-spacing: 0.04em; }

/* ---------- generator / werkblad ---------- */
.output-box {
  border: 1.5px solid var(--ink);
  border-radius: var(--radius-s);
  background: #FFFFFF;
  padding: 16px 18px;
  font-size: 13.5px;
  line-height: 1.6;
  white-space: pre-wrap;
  min-height: 90px;
}
.output-box.empty {
  color: var(--muted);
  display: grid;
  place-items: center;
  text-align: center;
  font-size: 12.5px;
  background: repeating-linear-gradient(-45deg, #fff, #fff 10px, #faf8f1 10px, #faf8f1 20px);
}
.caret { display: inline-block; width: 8px; height: 15px; background: var(--ink); vertical-align: -2px; animation: blink 0.8s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* ---------- progress / meter ---------- */
.meter { height: 9px; border-radius: 999px; background: var(--cream-2); border: 1.5px solid var(--ink); overflow: hidden; }
.meter > div { height: 100%; background: var(--accent); border-radius: 999px; transition: width 0.5s ease; }

/* ---------- staafgrafiek ---------- */
.bars { display: flex; align-items: flex-end; gap: 10px; height: 150px; padding-top: 8px; }
.bars .bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 7px; height: 100%; justify-content: flex-end; }
.bars .bar {
  width: 100%;
  max-width: 46px;
  border: 1.5px solid var(--ink);
  border-radius: 7px 7px 0 0;
  background: var(--accent);
  transition: height 0.5s ease;
}
.bars .bar-lab { font-size: 10px; font-weight: 700; letter-spacing: 0.08em; color: var(--muted); text-transform: uppercase; }

/* ---------- modal ---------- */
.modal-veil {
  position: fixed;
  inset: 0;
  background: rgba(11,11,12,0.42);
  display: grid;
  place-items: center;
  padding: 30px;
  z-index: 80;
  animation: veilIn 0.15s ease;
}
@keyframes veilIn { from { opacity: 0; } }
.modal {
  width: min(680px, 100%);
  max-height: min(82vh, 760px);
  overflow-y: auto;
  background: var(--cream);
  border: 2px solid var(--ink);
  border-radius: 18px;
  box-shadow: 8px 8px 0 rgba(11,11,12,0.85);
  animation: modalIn 0.18s cubic-bezier(0.2, 0.9, 0.3, 1.2);
}
@keyframes modalIn { from { opacity: 0; transform: translateY(12px) scale(0.985); } }
.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 24px 14px;
  border-bottom: 1.5px solid var(--ink);
  position: sticky;
  top: 0;
  background: var(--cream);
  z-index: 2;
}
.modal-body { padding: 22px 24px 26px; }
.x-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1.5px solid var(--ink);
  background: var(--paper);
  font-size: 14px;
  font-weight: 700;
  display: grid;
  place-items: center;
  line-height: 1;
}
.x-btn:hover { background: var(--ink); color: var(--cream); }

/* ---------- toast ---------- */
.toast {
  position: fixed;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--ink);
  color: var(--cream);
  border-radius: 999px;
  border: 1.5px solid var(--ink);
  padding: 10px 20px;
  font-size: 13px;
  font-weight: 600;
  z-index: 120;
  display: flex;
  align-items: center;
  gap: 9px;
  animation: toastIn 0.22s cubic-bezier(0.2, 0.9, 0.3, 1.25);
  box-shadow: 0 6px 24px rgba(11,11,12,0.3);
}
.toast .tdot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
@keyframes toastIn { from { opacity: 0; transform: translate(-50%, 10px); } }

/* ---------- tabs (binnen module) ---------- */
.seg {
  display: inline-flex;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: var(--paper);
  padding: 3px;
  gap: 2px;
}
.seg button {
  border: none;
  background: transparent;
  border-radius: 999px;
  height: 28px;
  padding: 0 14px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--muted);
}
.seg button.on { background: var(--ink); color: var(--cream); }

/* ---------- activity feed ---------- */
.feed-item { display: flex; gap: 12px; padding: 11px var(--pad); border-bottom: 1.5px solid var(--line); }
.feed-item:last-child { border-bottom: none; }
.feed-glyph {
  width: 28px; height: 28px; flex: none;
  border-radius: 9px; border: 1.5px solid var(--ink);
  display: grid; place-items: center; font-size: 12px; font-weight: 700;
}
.feed-item .ft { font-size: 13px; line-height: 1.4; }
.feed-item .ft b { font-weight: 700; }
.feed-item .fm { font-size: 11px; color: var(--muted); margin-top: 2px; letter-spacing: 0.03em; }

/* ---------- compact density ---------- */
.density-compact { --pad: 16px; --gap: 10px; font-size: 13.5px; }
.density-compact .row { padding-top: 9px; padding-bottom: 9px; }
.density-compact .page-head { padding-top: 22px; padding-bottom: 14px; }
.density-compact .page-head h1 { font-size: 27px; }
.density-compact .stat .v { font-size: 30px; }

/* ---------- responsive ---------- */
@media (max-width: 1180px) {
  .grid-main-side { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
  .shell { grid-template-columns: 76px 1fr; }
  .sidebar { padding: 20px 10px 14px; }
  .brand .name, .nav-item span.lab, .nav-item .badge, .nav-sep, .company-chip .ctxt { display: none; }
  .nav-item { justify-content: center; }
  .nav-item .nn { width: auto; }
  .main { padding: 0 18px 40px; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

/* scrollbars */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(11,11,12,0.22); border-radius: 999px; border: 2px solid var(--cream); }
::-webkit-scrollbar-track { background: transparent; }

/* =====================================================================
   OptimAI live — toevoegingen (login, banners, formulieren, lege staten)
   ===================================================================== */
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap); }
@media (max-width: 1180px) { .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) {
  .grid-4 { grid-template-columns: 1fr; }
  .main { padding: 0 12px 40px; }
  .page-head { flex-direction: column; align-items: flex-start !important; gap: 12px; }
  .page-head h1 { font-size: 26px; }
  .stat .v { font-size: 28px; }
}

.banner {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  margin: 18px 0 0; padding: 11px 16px;
  border: 1.5px solid var(--ink); border-radius: var(--radius-s);
  background: var(--yellow); font-size: 13px; font-weight: 600;
}
.banner.ink { background: var(--ink); color: var(--cream); }
.banner.ink .btn { background: var(--lime); border-color: var(--lime); color: var(--ink); }
.banner a { color: inherit; }

.leeg {
  padding: 22px var(--pad); color: var(--muted); font-size: 13px; line-height: 1.55;
}
.leeg b { color: var(--ink); display: block; margin-bottom: 3px; font-size: 13.5px; }

/* formulieren */
.veld { display: flex; flex-direction: column; gap: 5px; margin-bottom: 12px; }
.veld label { font-size: 10.5px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.veld input, .veld select, .veld textarea {
  width: 100%; height: 40px; padding: 0 12px;
  border: 1.5px solid var(--ink); border-radius: var(--radius-s);
  background: #fff; font-size: 14px; color: var(--ink);
}
.veld textarea { height: auto; min-height: 90px; padding: 10px 12px; line-height: 1.5; resize: vertical; }
.veld textarea.code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 12px; min-height: 280px; }
.veld input:focus, .veld select:focus, .veld textarea:focus { outline: 3px solid var(--accent); outline-offset: 1px; }
.veld-rij { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
@media (max-width: 560px) { .veld-rij { grid-template-columns: 1fr; } }
.hint { font-size: 12px; color: var(--muted); line-height: 1.5; }
.fout { color: var(--red); font-size: 12.5px; font-weight: 600; min-height: 1em; }
.ok-msg { color: var(--green); font-size: 12.5px; font-weight: 600; }

/* auth-pagina's (login, wachtwoord) */
.auth-wrap { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; }
.auth-card {
  width: 100%; max-width: 410px; background: var(--paper);
  border: 2px solid var(--ink); border-radius: 18px; padding: 28px 26px;
  box-shadow: 8px 8px 0 rgba(11, 11, 12, 0.85);
}
.auth-card h1 { margin: 6px 0 4px; font-size: 26px; letter-spacing: -0.02em; }
.auth-card .sub { margin: 0 0 20px; color: var(--muted); font-size: 13.5px; }
.auth-card .btn { width: 100%; height: 44px; justify-content: center; font-size: 13.5px; }
.auth-links { display: flex; justify-content: space-between; margin-top: 16px; font-size: 12.5px; }
.auth-links a, .auth-links button { color: var(--ink); background: none; border: 0; padding: 0; text-decoration: underline; font-size: 12.5px; }
.auth-logo { display: inline-flex; gap: 6px; font-weight: 700; letter-spacing: 0.045em; text-decoration: none; color: var(--ink); font-size: 17px; margin-bottom: 18px; }
.auth-logo .s { color: var(--green); }

/* laadscherm */
.laden { min-height: 100vh; display: grid; place-items: center; color: var(--muted); font-size: 13px; }
.laden .spin { width: 26px; height: 26px; border: 3px solid var(--line); border-top-color: var(--ink); border-radius: 50%; animation: draai 0.8s linear infinite; margin: 0 auto 12px; }
@keyframes draai { to { transform: rotate(360deg); } }
@media (max-width: 900px) { .sidebar .ctxt { display: none !important; } }
.admin-tabel { width: 100%; border-collapse: collapse; font-size: 13px; }
.admin-tabel th { text-align: left; font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); padding: 10px var(--pad); border-bottom: 1.5px solid var(--line); }
.admin-tabel td { padding: 10px var(--pad); border-bottom: 1.5px solid var(--line); vertical-align: top; }
.admin-tabel tr:last-child td { border-bottom: 0; }
.tabel-scroll { overflow-x: auto; }
.tabs-mini { display: flex; gap: 6px; margin-bottom: 14px; flex-wrap: wrap; }
.doel-meter { height: 14px; border: 1.5px solid var(--ink); border-radius: 999px; background: var(--paper); overflow: hidden; }
.doel-meter > div { height: 100%; background: var(--accent); border-right: 1.5px solid var(--ink); }
.alleen-mobiel { display: none !important; }
@media (max-width: 900px) {
  .alleen-mobiel { display: inline-flex !important; width: 100%; margin-top: 10px; padding: 0; justify-content: center; font-size: 10.5px; text-decoration: none; }
}

/* ===== v2: WhatsApp-knop, fototip, topbalk + onderbalk op gsm ===== */
.btn.wa { background: #25D366; border-color: #0B0B0C; color: #0B0B0C; text-decoration: none; }
.btn.wa:hover { background: #1fbe5b; }
.tip-balk { display: flex; gap: 10px; align-items: flex-start; font-size: 12.5px; line-height: 1.5; background: var(--yellow); border: 1.5px solid var(--ink); border-radius: var(--radius-s); padding: 10px 13px; margin-bottom: 14px; }

.topbalk, .onderbalk, .meer-veil { display: none; }
@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr !important; }
  .sidebar { display: none !important; }
  .topbalk {
    display: flex; justify-content: space-between; align-items: center; position: sticky; top: 0; z-index: 40;
    background: rgba(244, 241, 232, 0.95); backdrop-filter: blur(6px); border-bottom: 1.5px solid var(--ink); padding: 10px 14px;
  }
  .brand-klein { font-weight: 700; letter-spacing: 0.05em; font-size: 14px; }
  .brand-klein b { color: var(--green); }
  .topbalk-bedrijf { display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 700; }
  .avatar-klein { width: 26px; height: 26px; border-radius: 8px; background: var(--ink); color: var(--lime); display: grid; place-items: center; font-size: 10px; }
  .main { padding-bottom: 96px !important; }
  .onderbalk {
    display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
    background: var(--paper); border-top: 1.5px solid var(--ink); padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  }
  .onderbalk button { position: relative; background: none; border: 0; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px; color: var(--muted); font-size: 10.5px; font-weight: 700; border-radius: 12px; }
  .onderbalk button.actief { color: var(--ink); background: var(--accent); }
  .onderbalk .bol { position: absolute; top: 2px; right: 18%; min-width: 17px; height: 17px; border-radius: 999px; background: var(--ink); color: var(--lime); font-size: 9.5px; font-style: normal; display: grid; place-items: center; padding: 0 4px; }
  .meer-veil { display: block; position: fixed; inset: 0; z-index: 55; background: rgba(11, 11, 12, 0.35); }
  .meer-blad { position: absolute; left: 10px; right: 10px; bottom: 78px; background: var(--paper); border: 2px solid var(--ink); border-radius: 16px; padding: 8px; display: flex; flex-direction: column; box-shadow: 6px 6px 0 rgba(11,11,12,0.85); }
  .meer-item { text-align: left; background: none; border: 0; padding: 13px 14px; font-size: 15px; font-weight: 600; color: var(--ink); text-decoration: none; border-radius: 10px; }
  .meer-item.actief { background: var(--accent); }
  .banner { margin-top: 12px; }
}

/* lange onderwerpen mogen de kolom niet breder maken dan het scherm */
.grid-main-side > *, .grid-2 > *, .grid-3 > *, .stack > * { min-width: 0; }

/* ---------- klantfiche (eigenaar) ---------- */
.link-knop { background: none; border: 0; padding: 0; font: inherit; color: inherit; cursor: pointer; text-align: left; text-decoration: underline; text-decoration-color: rgba(11,11,12,0.25); text-underline-offset: 3px; }
.link-knop:hover { text-decoration-color: var(--ink); }
.opstart-mini { margin: 12px 0 2px; }
.opstart-mini .kicker { margin-bottom: 5px; }
.fiche-terug { margin-bottom: 14px; }
.fiche-kop { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; padding-bottom: 22px; margin-bottom: var(--gap); border-bottom: 1.5px solid var(--ink); }
.fiche-logo { width: 72px; height: 72px; border-radius: 20px; border: 1.5px solid var(--ink); display: grid; place-items: center; font-size: 24px; font-weight: 700; letter-spacing: -0.02em; flex: none; }
.fiche-titel { flex: 1; min-width: 220px; }
.fiche-titel h1 { margin: 6px 0 4px; font-size: clamp(30px, 4vw, 44px); line-height: 1.02; }
.fiche-titel p { margin: 0; color: var(--muted); font-size: 14px; }
.fiche-acties { display: flex; gap: 8px; flex-wrap: wrap; }
.fiche-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: var(--gap); align-items: start; }
.fiche-grid > * { min-width: 0; }
.fiche-snel { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.fiche-snel .btn { text-decoration: none; }
.fiche-print-contact { display: none; }
.row.task-done-zacht .title { color: var(--muted); }
.check:disabled { cursor: default; }
.fiche-link { display: flex; gap: 8px; margin-bottom: 10px; }
.fiche-link input { flex: 1; min-width: 0; font: inherit; font-size: 12.5px; padding: 8px 12px; border: 1.5px solid var(--line); border-radius: 10px; background: var(--cream); color: var(--muted); }
.fiche-antwoorden { margin-top: 16px; display: grid; gap: 14px; }
.fa-sectie h4 { margin: 0 0 6px; font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; }
.fa-sectie dl { margin: 0; display: grid; grid-template-columns: minmax(140px, 38%) 1fr; gap: 6px 14px; font-size: 13.5px; border-top: 1px solid var(--line); padding-top: 8px; }
.fa-sectie dt { color: var(--muted); }
.fa-sectie dd { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.fiche-pakketten { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.fiche-pakket { font: inherit; font-size: 12.5px; font-weight: 700; padding: 9px 6px; border: 1.5px solid var(--ink); border-radius: 12px; background: var(--paper); cursor: pointer; }
.fiche-pakket.actief { background: var(--accent); box-shadow: 2px 2px 0 var(--ink); }
.fiche-plan { margin-top: 12px; font-size: 15px; font-weight: 700; }
.fiche-feiten { display: grid; gap: 10px; font-size: 13.5px; }
.fiche-feiten div { display: grid; grid-template-columns: 110px 1fr; gap: 10px; }
.fiche-feiten span { color: var(--muted); }
.fiche-feiten b { overflow-wrap: anywhere; font-weight: 600; }
.fiche-voet { display: none; }
.fiche-print-notities { display: none; }
@media (max-width: 900px) {
  .fiche-grid { grid-template-columns: 1fr; }
  .fiche-pakketten { grid-template-columns: repeat(2, 1fr); }
  .fa-sectie dl { grid-template-columns: 1fr; gap: 2px; }
  .fa-sectie dd { margin-bottom: 8px; }
}

/* afdrukken / bewaren als PDF: enkel de fiche, netjes op A4 */
@media print {
  @page { size: A4; margin: 14mm; }
  body { background: #fff !important; }
  .sidebar, .topbalk, .onderbalk, .meer-veil, .meer-blad, .toast, .geen-print, .banner { display: none !important; }
  .shell { display: block !important; }
  .main { padding: 0 !important; margin: 0 !important; max-width: none !important; }
  .fiche-grid { grid-template-columns: 1.35fr 1fr; }
  .card { break-inside: avoid; box-shadow: none !important; }
  .fiche-print-contact { display: block; font-size: 13px; margin-top: 6px; }
  .fiche-voet { display: block; margin-top: 18px; font-size: 10px; color: var(--muted); text-align: center; }
  .fiche input, .fiche textarea { border: 0 !important; background: none !important; padding: 0 !important; resize: none; }
  .fiche .veld-rij, .fiche textarea { display: none !important; }
  .fiche-print-notities { display: block; white-space: pre-wrap; font-size: 13px; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
