/* =====================================================================
   Bedrijfsbeheer | stylesheet
   Geen inline stijlen (strikte CSP): alles via klassen in dit bestand.
   ===================================================================== */

:root {
  --bg: #f1f5f9;
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --border: #e2e8f0;
  --border-strong: #cbd5e1;
  --text: #0f172a;
  --text-2: #475569;
  --text-3: #556275; /* minstens 4,5:1 op --bg, ook leesbaar in de zon */
  --primary: #1d4ed8;
  --primary-hover: #1e40af;
  --primary-soft: #dbeafe;
  --success: #15803d;
  --success-soft: #dcfce7;
  --warning: #b45309;
  --warning-soft: #fef3c7;
  --danger: #b91c1c;
  --danger-soft: #fee2e2;
  --info: #0369a1;
  --info-soft: #e0f2fe;
  --sidebar: #0f172a;
  --sidebar-2: #1e293b;
  --sidebar-text: #cbd5e1;
  --sidebar-active: #ffffff;
  --accent: #f59e0b;
  --radius: 10px;
  --radius-sm: 6px;
  --shadow: 0 1px 2px rgba(15, 23, 42, .06), 0 1px 3px rgba(15, 23, 42, .08);
  --shadow-lg: 0 10px 30px rgba(15, 23, 42, .15);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --sidebar-width: 252px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
}
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0 0 .5rem; line-height: 1.25; color: var(--text); }
h1 { font-size: 1.5rem; font-weight: 700; }
h2 { font-size: 1.15rem; font-weight: 650; }
h3 { font-size: 1rem; font-weight: 650; }
p { margin: 0 0 .75rem; }
img { max-width: 100%; height: auto; }
hr { border: 0; border-top: 1px solid var(--border); margin: 1rem 0; }
code, .mono { font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace; font-size: .9em; }

.icon { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; vertical-align: -3px; }
.icon-lg { width: 24px; height: 24px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- app-layout ---------- */
.app { display: flex; min-height: 100vh; }
.sidebar {
  width: var(--sidebar-width);
  background: var(--sidebar);
  color: var(--sidebar-text);
  display: flex;
  flex-direction: column;
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 40;
  overflow-y: auto;
}
.sidebar-brand { display: flex; align-items: center; gap: .65rem; padding: 1.1rem 1.25rem; color: #fff; font-weight: 700; font-size: 1.05rem; border-bottom: 1px solid var(--sidebar-2); }
.sidebar-brand:hover { text-decoration: none; }
.brand-mark { width: 32px; height: 32px; border-radius: 8px; background: var(--accent); color: var(--sidebar); display: grid; place-items: center; font-weight: 800; }
.nav { padding: .75rem .6rem 1rem; flex: 1; }
.nav-section { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: #94a3b8; padding: 1rem .75rem .35rem; }
.nav a { display: flex; align-items: center; gap: .7rem; padding: .55rem .75rem; border-radius: var(--radius-sm); color: var(--sidebar-text); font-weight: 500; }
.nav a:hover { background: var(--sidebar-2); color: #fff; text-decoration: none; }
.nav a.active { background: var(--primary); color: var(--sidebar-active); }
.sidebar-footer { padding: .9rem 1.25rem; border-top: 1px solid var(--sidebar-2); font-size: .8rem; color: #94a3b8; }

.main { flex: 1; min-width: 0; margin-left: var(--sidebar-width); display: flex; flex-direction: column; }
.topbar {
  height: 60px; background: var(--surface); border-bottom: 1px solid var(--border);
  display: flex; align-items: center; gap: .75rem; padding: 0 1.5rem; position: sticky; top: 0; z-index: 30;
}
.topbar-spacer { flex: 1; }
.topbar .nav-toggle { display: none; }
.topbar-link { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 50%; color: var(--text-2); }
.topbar-link:hover { background: var(--surface-2); text-decoration: none; }
.count-dot { position: absolute; top: 3px; right: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--danger); color: #fff; font-size: .7rem; font-weight: 700; display: grid; place-items: center; }
.content { padding: 1.5rem; max-width: 1400px; width: 100%; }

.sidebar-backdrop { display: none; }

/* gebruikersmenu met <details> (werkt zonder JavaScript) */
.menu { position: relative; }
.menu > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: .5rem; padding: .25rem .4rem; border-radius: 999px; }
.menu > summary::-webkit-details-marker { display: none; }
.menu > summary:hover { background: var(--surface-2); }
.menu-panel { position: absolute; right: 0; top: calc(100% + 6px); min-width: 230px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: .4rem; z-index: 50; }
.menu-panel a, .menu-panel button { display: flex; width: 100%; align-items: center; gap: .6rem; padding: .55rem .7rem; border: 0; background: none; color: var(--text); font: inherit; text-align: left; border-radius: var(--radius-sm); cursor: pointer; }
.menu-panel a:hover, .menu-panel button:hover { background: var(--surface-2); text-decoration: none; }
.menu-head { padding: .5rem .7rem .6rem; border-bottom: 1px solid var(--border); margin-bottom: .3rem; }
.menu-head strong { display: block; }

.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--primary-soft); color: var(--primary); display: inline-grid; place-items: center; font-weight: 700; font-size: .85rem; overflow: hidden; flex: none; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar-lg { width: 88px; height: 88px; font-size: 1.6rem; }
.avatar-sm { width: 28px; height: 28px; font-size: .7rem; }

/* ---------- pagina ---------- */
.page-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.page-header h1 { margin: 0; }
.page-header .subtitle { color: var(--text-3); margin: .2rem 0 0; }
.page-actions { display: flex; gap: .5rem; flex-wrap: wrap; }
.breadcrumbs { font-size: .85rem; color: var(--text-3); margin-bottom: .35rem; }
.breadcrumbs a { color: var(--text-3); }

/* ---------- kaarten ---------- */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 1.25rem; }
.card-header { display: flex; align-items: center; justify-content: space-between; gap: .75rem; flex-wrap: wrap; padding: .9rem 1.2rem; border-bottom: 1px solid var(--border); }
.card-header h2, .card-header h3 { margin: 0; }
.card-body { padding: 1.2rem; }
.card-body.flush { padding: 0; }
.card-footer { padding: .8rem 1.2rem; border-top: 1px solid var(--border); background: var(--surface-2); border-radius: 0 0 var(--radius) var(--radius); }

.grid { display: grid; gap: 1.25rem; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-sidebar { grid-template-columns: minmax(0, 1fr) 340px; }
.grid > .card { margin-bottom: 0; }

.stat { padding: 1.1rem 1.2rem; }
.stat-label { color: var(--text-3); font-size: .85rem; }
.stat-value { font-size: 1.8rem; font-weight: 700; line-height: 1.2; }
.stat-link { font-size: .85rem; }

/* ---------- knoppen ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
  padding: .55rem 1rem; border-radius: var(--radius-sm); border: 1px solid transparent;
  font: inherit; font-weight: 600; font-size: .9rem; line-height: 1.2; cursor: pointer; text-decoration: none; white-space: nowrap;
  background: var(--surface); color: var(--text); border-color: var(--border-strong);
}
.btn:hover { text-decoration: none; background: var(--surface-2); }
.btn:focus-visible, a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
.btn-primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); }
.btn-danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn-danger:hover { background: #991b1b; }
.btn-ghost { background: transparent; border-color: transparent; color: var(--text-2); }
.btn-ghost:hover { background: var(--surface-2); }
.btn-link { background: none; border: 0; padding: 0; color: var(--primary); font-weight: 500; cursor: pointer; font: inherit; }
.btn-link:hover { text-decoration: underline; }
.btn-link.danger { color: var(--danger); }
.btn-sm { padding: .35rem .65rem; font-size: .82rem; }
.btn-block { width: 100%; }
.inline-form { display: inline; margin: 0; }

/* ---------- formulieren ---------- */
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem 1.25rem; }
.form-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.span-2 { grid-column: span 2; }
.span-all { grid-column: 1 / -1; }
.field { display: flex; flex-direction: column; gap: .3rem; min-width: 0; }
.field > label, .label { font-weight: 600; font-size: .87rem; color: var(--text-2); }
.field .required::after { content: " *"; color: var(--danger); }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=number], input[type=tel],
input[type=search], input[type=datetime-local], input[type=time], input[type=file], select, textarea {
  width: 100%; padding: .55rem .7rem; border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  background: #fff; color: var(--text); font: inherit; font-size: .95rem; min-height: 40px;
}
input[type=file] { padding: .4rem; }
textarea { min-height: 90px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--primary); outline: none; box-shadow: 0 0 0 3px rgba(29, 78, 216, .15); }
.is-invalid { border-color: var(--danger) !important; }
.field-error { color: var(--danger); font-size: .82rem; }
.help { color: var(--text-3); font-size: .82rem; }
.checkbox { display: flex; align-items: center; gap: .55rem; font-weight: 500; color: var(--text); cursor: pointer; }
.checkbox input { width: 18px; height: 18px; accent-color: var(--primary); }
.checkbox-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: .5rem 1rem; }
.form-actions { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: 1.25rem; }
fieldset { border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem 1.1rem 1.1rem; margin: 0 0 1.25rem; }
legend { font-weight: 650; padding: 0 .4rem; }

.filters { display: flex; gap: .6rem; flex-wrap: wrap; align-items: flex-end; }
.filters .field { min-width: 160px; flex: 1 1 160px; }
.filters .field.grow { flex: 2 1 240px; }

/* ---------- tabellen ---------- */
.table-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th, .table td { padding: .7rem 1rem; text-align: left; border-bottom: 1px solid var(--border); vertical-align: middle; }
.table th { font-size: .76rem; text-transform: uppercase; letter-spacing: .04em; color: var(--text-3); background: var(--surface-2); font-weight: 650; white-space: nowrap; }
.table tbody tr:hover { background: #f8fafc; }
.table tbody tr:last-child td { border-bottom: 0; }
.table td.num, .table th.num { text-align: right; white-space: nowrap; }
.table td.actions { text-align: right; white-space: nowrap; }
.table .row-link { cursor: pointer; }
.table-compact th, .table-compact td { padding: .45rem .75rem; }
.cell-person { display: flex; align-items: center; gap: .65rem; }
.cell-person small { display: block; color: var(--text-3); }

/* ---------- badges en meldingen ---------- */
.badge { display: inline-flex; align-items: center; gap: .3rem; padding: .15rem .55rem; border-radius: 999px; font-size: .76rem; font-weight: 650; background: var(--surface-2); color: var(--text-2); border: 1px solid var(--border); white-space: nowrap; }
.badge-success { background: var(--success-soft); color: var(--success); border-color: transparent; }
.badge-warning { background: var(--warning-soft); color: var(--warning); border-color: transparent; }
.badge-danger { background: var(--danger-soft); color: var(--danger); border-color: transparent; }
.badge-info { background: var(--info-soft); color: var(--info); border-color: transparent; }
.badge-primary { background: var(--primary-soft); color: var(--primary); border-color: transparent; }
.badge-muted { background: #f1f5f9; color: var(--text-3); border-color: transparent; }
.badge-sub { font-weight: 500; }
.badge-sub::before { content: "\00b7"; margin: 0 .3rem 0 .05rem; }
.expiry-legend { display: flex; flex-wrap: wrap; gap: .3rem .9rem; align-items: center; font-size: .8rem; color: var(--text-3); padding: .6rem 1rem; }
.expiry-legend .badge { font-size: .72rem; }

.alert { display: flex; gap: .7rem; align-items: flex-start; padding: .85rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; border: 1px solid transparent; }
.alert-success { background: var(--success-soft); color: #14532d; border-color: #bbf7d0; }
.alert-error { background: var(--danger-soft); color: #7f1d1d; border-color: #fecaca; }
.alert-warning { background: var(--warning-soft); color: #78350f; border-color: #fde68a; }
.alert-info { background: var(--info-soft); color: #0c4a6e; border-color: #bae6fd; }
.alert .alert-body { flex: 1; }
.alert-close { background: none; border: 0; color: inherit; cursor: pointer; opacity: .7; padding: 0; font-size: 1.1rem; line-height: 1; }

/* ---------- tabs ---------- */
.tabs { display: flex; gap: .25rem; border-bottom: 1px solid var(--border); margin-bottom: 1.25rem; overflow-x: auto; overflow-y: hidden; scrollbar-width: thin; }
.tabs a { padding: .65rem .95rem; color: var(--text-2); font-weight: 600; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs a:hover { color: var(--text); text-decoration: none; }
.tabs a.active { color: var(--primary); border-bottom-color: var(--primary); }
.tabs-select { display: none; }

/* ---------- details ---------- */
.dl { display: grid; grid-template-columns: minmax(140px, 38%) 1fr; gap: .55rem 1rem; margin: 0; }
.dl dt { color: var(--text-3); font-size: .88rem; }
.dl dd { margin: 0; font-weight: 500; word-break: break-word; }
.profile-head { display: flex; gap: 1.1rem; align-items: center; flex-wrap: wrap; }
.profile-head h1 { margin: 0; }
.meta { display: flex; gap: .45rem; flex-wrap: wrap; align-items: center; margin-top: .35rem; color: var(--text-3); }

.empty { text-align: center; color: var(--text-3); padding: 2rem 1rem; }
.empty .icon { width: 36px; height: 36px; margin-bottom: .5rem; stroke-width: 1.5; }

.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { position: relative; padding: 0 0 1rem 1.4rem; border-left: 2px solid var(--border); margin-left: .4rem; }
.timeline li::before { content: ""; position: absolute; left: -7px; top: .3rem; width: 12px; height: 12px; border-radius: 50%; background: var(--surface); border: 2px solid var(--primary); }
.timeline li:last-child { border-left-color: transparent; }
.timeline .when { font-size: .8rem; color: var(--text-3); }

.change-list { margin: .35rem 0 0; padding: 0; list-style: none; font-size: .85rem; }
.change-list li { padding: .1rem 0; }
.change-list del { color: var(--danger); text-decoration: line-through; }
.change-list ins { color: var(--success); text-decoration: none; }

.pagination { display: flex; gap: .3rem; justify-content: center; flex-wrap: wrap; padding: 1rem; }
.pagination a, .pagination span { min-width: 36px; padding: .4rem .65rem; border-radius: var(--radius-sm); border: 1px solid var(--border); text-align: center; color: var(--text-2); background: var(--surface); }
.pagination .current { background: var(--primary); border-color: var(--primary); color: #fff; }
.pagination a:hover { text-decoration: none; background: var(--surface-2); }

.codes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .5rem; padding: 1rem; background: var(--surface-2); border: 1px dashed var(--border-strong); border-radius: var(--radius); font-family: ui-monospace, Consolas, monospace; font-size: 1.05rem; text-align: center; }
.qr-box { display: flex; gap: 1.25rem; align-items: center; flex-wrap: wrap; }
.qr-box img { width: 200px; height: 200px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: .5rem; }
.secret { font-family: ui-monospace, Consolas, monospace; letter-spacing: .08em; word-break: break-all; background: var(--surface-2); padding: .4rem .6rem; border-radius: var(--radius-sm); }

.list-plain { list-style: none; margin: 0; padding: 0; }
.list-plain li { padding: .55rem 0; border-bottom: 1px solid var(--border); }
.list-plain li:last-child { border-bottom: 0; }
.notification.unread { background: #f8fbff; }
.notification.unread strong::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--primary); margin-right: .45rem; vertical-align: 1px; }

.matrix th.rot { text-align: center; }
.matrix td.center { text-align: center; }
.matrix tr.module td { background: var(--surface-2); font-weight: 650; font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; color: var(--text-3); }

/* ---------- hulpklassen ---------- */
.muted { color: var(--text-3); }
.small { font-size: .85rem; }
.nowrap { white-space: nowrap; }
.text-right { text-align: right; }
.text-danger { color: var(--danger); }
.text-success { color: var(--success); }
.flex { display: flex; align-items: center; gap: .5rem; }
.flex-wrap { flex-wrap: wrap; }
.between { justify-content: space-between; }
.stack > * + * { margin-top: .75rem; }
.mt-0 { margin-top: 0; } .mt-1 { margin-top: .5rem; } .mt-2 { margin-top: 1rem; } .mt-3 { margin-top: 1.5rem; }
.mb-0 { margin-bottom: 0; } .mb-1 { margin-bottom: .5rem; } .mb-2 { margin-bottom: 1rem; }
.w-100 { width: 100%; }

/* ---------- aanmelden ---------- */
.auth { min-height: 100vh; display: grid; place-items: center; padding: 1.5rem 1rem; background: linear-gradient(160deg, #0f172a 0%, #1e3a8a 100%); }
.auth-card { width: 100%; max-width: 420px; background: var(--surface); border-radius: 14px; box-shadow: var(--shadow-lg); padding: 2rem; }
.auth-card.wide { max-width: 640px; }
.auth-brand { display: flex; align-items: center; gap: .65rem; font-weight: 700; font-size: 1.1rem; margin-bottom: 1.5rem; }
.auth-card h1 { font-size: 1.35rem; }
.auth-card .form-actions { margin-top: 1rem; }
.auth-footer { margin-top: 1.25rem; font-size: .88rem; text-align: center; }
/* pincode (1.34.0): groot en gespreid, makkelijk te tikken */
#f_pincode, #f_pin, #f_pin_confirm { font-size: 1.6rem; letter-spacing: .45em; text-align: center; font-variant-numeric: tabular-nums; }
.check-list { list-style: none; padding: 0; margin: 0 0 1rem; }
.check-list li { display: flex; gap: .5rem; align-items: center; padding: .3rem 0; }
.check-ok { color: var(--success); }
.check-bad { color: var(--danger); }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-sidebar { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 900px) {
  .sidebar { transform: translateX(-100%); transition: transform .2s ease; }
  .nav-open .sidebar { transform: none; box-shadow: var(--shadow-lg); }
  .nav-open .sidebar-backdrop { display: block; position: fixed; inset: 0; background: rgba(15, 23, 42, .45); z-index: 35; }
  .main { margin-left: 0; }
  .topbar { padding: 0 1rem; }
  .topbar .nav-toggle { display: inline-flex; }
  .content { padding: 1rem; }
  .grid-2, .grid-3 { grid-template-columns: minmax(0, 1fr); }
  .form-grid, .form-grid-3 { grid-template-columns: minmax(0, 1fr); }
  .span-2 { grid-column: auto; }
  .hide-mobile { display: none !important; }
}
@media (max-width: 560px) {
  body { font-size: 15px; }
  h1 { font-size: 1.3rem; }
  .grid-4 { grid-template-columns: minmax(0, 1fr); }
  .card-body { padding: 1rem; }
  .card-header { padding: .8rem 1rem; }
  .table th, .table td { padding: .6rem .7rem; }
  .dl { grid-template-columns: minmax(0, 1fr); gap: .1rem; }
  .dl dd { margin-bottom: .55rem; }
  .page-actions { width: 100%; }
  .page-actions .btn { flex: 1; }
  .auth-card { padding: 1.4rem; }
  .codes { grid-template-columns: 1fr; }
  .topbar .user-name { display: none; }
  .badge { font-size: .85rem; }
  /* tabellen als kaartjes: elke rij onder elkaar, met de kolomtitel als label (data-label, zie app.js) */
  .table-stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
  .table-stack, .table-stack tbody, .table-stack tr, .table-stack td { display: block; width: 100%; }
  .table-stack tr { padding: .55rem 1rem; border-bottom: 1px solid var(--border); }
  .table-stack td, .table-stack td.num { border: 0; padding: .2rem 0; min-width: 0 !important; width: auto !important; text-align: left; white-space: normal; }
  .table-stack td[data-label]::before { content: attr(data-label); display: block; font-size: .72rem; font-weight: 600; color: var(--text-3); text-transform: uppercase; letter-spacing: .04em; }
  .table-stack td.actions { padding-top: .4rem; }
  .table-stack td:empty { display: none; }
  /* veel tabbladen: een keuzelijst in plaats van een balk waarvan je maar 2 of 3 tabbladen ziet */
  .tabs-select { display: block; width: 100%; margin-bottom: 1rem; font-weight: 600; }
  .tabs-select + .tabs { display: none; }
}

/* aanraakscherm (gsm, tablet): aanraakvlakken van minstens 44 px, ook met werkhandschoenen; op pc verandert er niets */
@media (pointer: coarse) {
  .btn, .pagination a, .pagination span, .tabs a, .menu-panel a, .menu-panel button { min-height: 44px; }
  .btn-sm { padding: .5rem .8rem; }
  .tabs a { display: inline-flex; align-items: center; }
  .alert-close { min-width: 44px; min-height: 44px; margin: -.7rem -.6rem -.7rem 0; }
  .checkbox { min-height: 44px; }
  .checkbox input { width: 24px; height: 24px; flex: none; }
  .list-plain li { padding: .2rem 0; }
  .list-plain a { display: inline-block; padding: .65rem 0; }
  .stat-link { display: inline-flex; align-items: center; min-height: 44px; }
  .btn-link { display: inline-flex; align-items: center; min-height: 44px; }
  .table .btn-link.danger { padding: 0 .6rem; margin-left: .25rem; border: 1px solid currentColor; border-radius: var(--radius-sm); }
}

/* aanmeldfiche: enkel bij het afdrukken, en dan enkel de fiche */
.print-sheet { display: none; }
@media print {
  body.print-sheet-only * { visibility: hidden; }
  body.print-sheet-only .print-sheet, body.print-sheet-only .print-sheet * { visibility: visible; }
  body.print-sheet-only .print-sheet { display: block; position: absolute; left: 0; top: 0; width: 100%; padding: 1cm; color: #000; font-size: 12pt; }
  .print-sheet h1 { font-size: 20pt; margin: 0 0 .4cm; }
  .print-sheet-grid { display: flex; gap: .8cm; align-items: center; margin: .5cm 0; }
  .print-sheet ol { padding-left: 1.2em; }
  .print-sheet li { margin-bottom: .2cm; }
}
@media print {
  .sidebar, .topbar, .page-actions, .filters, .form-actions, .no-print { display: none !important; }
  .main { margin: 0; }
  body { background: #fff; }
  .card { box-shadow: none; border: 0; }
}

/* ---------- hulpklassen (keuzelijsten, formulieren) ---------- */
.skip-link { position: absolute; left: .75rem; top: -3rem; z-index: 100; padding: .6rem 1rem; background: var(--primary); color: #fff; border-radius: var(--radius-sm); font-weight: 600; }
.skip-link:focus { top: .75rem; }
.error-links { margin: .35rem 0 0; padding-left: 1.2rem; }
.rights-overview { font-size: .9rem; }
.field.is-hidden { display: none; }
/* aanwezigheid: bolletje rechtsonder op een avatar */
.presence-wrap { position: relative; display: inline-flex; flex: none; border-radius: 50%; }
/* het rondje zelf in de kleur van de status, met een ring (ook zichtbaar rond een foto) */
.presence-is-online .avatar { background: #15803d; color: #fff; box-shadow: 0 0 0 2px #15803d; }
.presence-is-busy .avatar { background: #facc15; color: #422006; box-shadow: 0 0 0 2px #eab308; }
.presence-is-absent .avatar { background: #dc2626; color: #fff; box-shadow: 0 0 0 2px #dc2626; }
.presence-is-offline .avatar { background: #e5e7eb; color: #4b5563; box-shadow: 0 0 0 2px #9ca3af; }
/* klein bolletje in het menu (Zet op bezet / Weer beschikbaar) */
.presence { display: inline-block; width: 11px; height: 11px; border-radius: 50%; background: #9ca3af; }
.presence-online { background: #15803d; }
.presence-busy { background: #facc15; box-shadow: inset 0 0 0 1px #ca8a04; }
.presence-absent { background: #dc2626; }
.presence-offline { background: #9ca3af; }
/* tekst met regeleinden (meldingen) */
.pre-line { white-space: pre-line; }
/* werffoto */
.checkin-list { list-style: none; margin: 0; padding: .4rem 1.25rem .9rem; display: grid; gap: .6rem; }
.checkin-list li { display: flex; gap: .75rem; align-items: center; }
.checkin-list img { width: 72px; height: 72px; object-fit: cover; border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--bg); display: block; }
.checkin-list-inline { padding: 0; }
.checkin-list-inline img { width: 56px; height: 56px; }
.checkin-preview { display: block; max-width: 100%; max-height: 320px; margin-top: .5rem; border-radius: var(--radius-sm); border: 1px solid var(--border); }
.checkin-geo { color: var(--text-2, #475569); }
.camera { position: relative; background: #000; border-radius: var(--radius-sm); overflow: hidden; margin: .25rem 0 .5rem; }
.camera video, .camera img { display: block; width: 100%; max-height: 60vh; object-fit: contain; background: #000; }
.camera-actions { display: flex; gap: .5rem; flex-wrap: wrap; }
.camera-actions .btn-primary { flex: 1 1 12rem; justify-content: center; padding-top: .8rem; padding-bottom: .8rem; font-size: 1.05rem; }
.camera-status { margin: .4rem 0; color: var(--text-2, #475569); }
/* support: tickets naar WNM-Host */
.nav-count { margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--danger); color: #fff; font-size: .72rem; font-weight: 700; display: inline-grid; place-items: center; }
.nav-count[hidden] { display: none; }
.topbar .nav-toggle { position: relative; }
.topbar .nav-toggle .nav-count { position: absolute; top: -4px; right: -6px; margin: 0; }
.support-list { list-style: none; margin: 0; padding: 0; }
.support-item a { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .2rem .75rem; padding: .85rem 1.25rem; border-top: 1px solid var(--border); color: var(--text); text-decoration: none; }
.support-item:first-child a { border-top: 0; }
.support-item a:hover { background: var(--bg); }
.support-item .badge { grid-row: 1 / span 2; grid-column: 2; align-self: center; }
.support-subject { min-width: 0; overflow-wrap: anywhere; }
.support-item.is-unread .support-subject strong { color: var(--primary); }
.support-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--danger); margin-right: .4rem; vertical-align: 1px; }
.support-thread { display: flex; flex-direction: column; gap: .7rem; padding: 1rem 1.25rem; max-height: 60vh; overflow-y: auto; }
.support-msg { max-width: 85%; padding: .6rem .8rem; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface); overflow-wrap: anywhere; }
.support-msg-head { margin-bottom: .2rem; }
.support-msg-me { align-self: flex-end; background: var(--primary-soft); border-color: #bfdbfe; }
.support-msg-support { align-self: flex-start; background: var(--success-soft); border-color: #bbf7d0; }
.support-msg-admin { align-self: flex-start; background: #f3e8ff; border-color: #e9d5ff; }
.support-msg-other { align-self: flex-start; }
.support-reply { border-top: 1px solid var(--border); }
@media (max-width: 560px) { .support-msg { max-width: 100%; } .support-thread { padding: .75rem; } }
/* aanwezigheid op de werf */
.attend { margin-top: .6rem; padding-top: .6rem; border-top: 1px dashed var(--border); }
.attend-status { display: flex; gap: .4rem; flex-wrap: wrap; align-items: center; margin-bottom: .4rem; }
.attend-button { width: 100%; justify-content: center; padding-top: .75rem; padding-bottom: .75rem; font-size: 1rem; }
.btn-danger-soft { background: var(--danger-soft); border-color: #fecaca; color: var(--danger); }
.attend-dialog { width: min(560px, calc(100% - 24px)); max-height: calc(100vh - 24px); padding: 0 1rem 1rem; border: 0; border-radius: var(--radius); box-shadow: var(--shadow-lg); background: var(--surface); color: var(--text); overflow-y: auto; }
.attend-dialog::backdrop { background: rgba(15, 23, 42, .6); }
.attend-dialog-head { display: flex; justify-content: space-between; align-items: center; gap: .5rem; padding: .8rem 0 .4rem; }
.attend-dialog-head h2 { margin: 0; font-size: 1.1rem; }
.attend-day { margin: 1.5rem 0 .6rem; font-size: 1.15rem; }
.attend-cell { display: flex; gap: .5rem; align-items: center; }
.attend-thumb img { width: 52px; height: 52px; object-fit: cover; border-radius: var(--radius-sm); border: 1px solid var(--border); display: block; }
.attend-problem { background: #fff7f7; }
.attend-fix[open] summary { margin-bottom: .4rem; }
.attend-fix-form { display: flex; gap: .4rem; flex-wrap: wrap; align-items: flex-end; }
.attend-fix-form label { display: flex; flex-direction: column; font-size: .8rem; gap: .15rem; }
.attend-fix-form input { width: auto; min-width: 0; padding: .3rem .4rem; font-size: .9rem; }
.attend-fix-form .grow input { min-width: 12rem; }
/* veiligheid: LMRA vóór de LOGIN-foto en toolboxmeetings (1.18.0) */
.lmra-questions { list-style: none; margin: .4rem 0; padding: 0; display: grid; gap: .5rem; }
.lmra-question { margin: 0; padding: .6rem .7rem; border: 1px solid var(--border); border-radius: var(--radius-sm); }
.lmra-question legend { padding: 0; font-weight: 600; font-size: .95rem; float: left; width: 100%; margin-bottom: .45rem; }
.lmra-question.is-yes { border-color: #bbf7d0; background: var(--success-soft); }
.lmra-question.is-no { border-color: #fecaca; background: var(--danger-soft); }
.lmra-choices { clear: both; display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; }
.lmra-choice { display: flex; align-items: center; justify-content: center; gap: .4rem; min-height: 2.75rem; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); font-weight: 600; cursor: pointer; }
.lmra-choice input { width: 1.15rem; height: 1.15rem; margin: 0; }
.lmra-yes:has(input:checked) { border-color: var(--success); color: var(--success); }
.lmra-no:has(input:checked) { border-color: var(--danger); color: var(--danger); }
.camera-status.lmra-warn { font-size: .95rem; font-weight: 700; color: var(--danger); }
.lmra-problem { margin-top: .6rem; padding: .7rem; border-radius: var(--radius-sm); background: var(--warning-soft); color: var(--text); }
.lmra-answer { display: flex; gap: .5rem; align-items: flex-start; padding: .45rem 0; border-top: 1px solid var(--border); }
.lmra-answer:first-child { border-top: 0; }
.lmra-photo img { max-width: 100%; max-height: 420px; border-radius: var(--radius-sm); border: 1px solid var(--border); display: block; }
.toolbox-people { list-style: none; margin: 0; padding: 0; }
.toolbox-people li { display: flex; gap: .75rem; justify-content: space-between; align-items: center; padding: .6rem 1.25rem; border-top: 1px solid var(--border); flex-wrap: wrap; }
.toolbox-people li:first-child { border-top: 0; }
.toolbox-sign img { max-height: 46px; max-width: 160px; display: block; background: #fff; border-radius: var(--radius-sm); }
.toolbox-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: .35rem .9rem; max-height: 380px; overflow-y: auto; padding: .2rem; }
.toolbox-pick label { display: flex; gap: .5rem; align-items: flex-start; font-weight: 400; }
.toolbox-pick small { display: block; color: var(--text-3); }
.toolbox-text { white-space: pre-line; }
/* magazijn: aanvragen van materiaal */
.request-list { list-style: none; margin: 0; padding: 0; }
.request-item { padding: .9rem 1.25rem; border-top: 1px solid var(--border); }
.request-head { display: flex; gap: .75rem; justify-content: space-between; align-items: flex-start; }
.request-actions { display: flex; gap: .5rem; flex-wrap: wrap; align-items: flex-start; margin-top: .6rem; }
.request-form { display: flex; gap: .4rem; flex-wrap: wrap; align-items: center; margin: 0; }
.request-form select, .request-form input { width: auto; min-width: 0; padding: .3rem .5rem; font-size: .9rem; }
.request-form input[name="quantity"] { width: 6rem; }
.request-form input[name="reason"] { min-width: 14rem; }
.request-reject[open] > summary { margin-bottom: .4rem; }
/* dossier: Maak account (rol, taal en knop op één rij) */
.account-quick { display: flex; gap: .4rem; flex-wrap: wrap; align-items: center; }
.account-quick select { width: auto; min-width: 0; padding: .3rem .5rem; font-size: .9rem; }
/* wijzigingen die de gebruiker moet bevestigen, bovenaan elke pagina */
.confirm-bar { margin: 1rem 1.5rem 0; padding: .9rem 1rem; border: 1px solid #fcd34d; border-left: 4px solid var(--accent); border-radius: var(--radius); background: var(--warning-soft); color: var(--text); }
.confirm-bar-head { display: flex; gap: .65rem; align-items: flex-start; margin-bottom: .6rem; }
.confirm-bar-icon { display: inline-flex; color: var(--warning); margin-top: .1rem; }
.confirm-list { list-style: none; margin: 0 0 .4rem; padding: 0; display: grid; gap: .5rem; }
.confirm-list li { display: flex; gap: .75rem; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; padding: .6rem .75rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); }
.confirm-text { flex: 1 1 240px; min-width: 0; }
.confirm-actions { display: flex; gap: .4rem; flex-wrap: wrap; }
.confirm-actions .inline-form { margin: 0; }
@media (max-width: 700px) { .confirm-bar { margin: .75rem .75rem 0; } }
/* wat is er nieuw: venster na een update */
.news-dialog { width: min(640px, calc(100% - 32px)); max-height: calc(100vh - 48px); padding: 0; border: 0; border-radius: var(--radius); box-shadow: var(--shadow-lg); background: var(--surface); color: var(--text); }
.news-dialog::backdrop { background: rgba(15, 23, 42, .55); }
.news-dialog form { display: flex; flex-direction: column; max-height: calc(100vh - 48px); }
.news-dialog-head { display: flex; gap: .75rem; align-items: flex-start; padding: 1.1rem 1.25rem .6rem; border-bottom: 1px solid var(--border); }
.news-dialog-head h2 { margin: 0 0 .15rem; font-size: 1.2rem; }
.news-dialog-head p { margin: 0; }
.news-dialog-icon { display: inline-flex; align-items: center; justify-content: center; width: 2.2rem; height: 2.2rem; flex: none; border-radius: 50%; background: var(--primary-soft); color: var(--primary); }
.news-dialog-body { overflow-y: auto; padding: .4rem 1.25rem .8rem; }
.news-item h3 { margin: .8rem 0 .3rem; font-size: 1rem; }
.news-points { margin: 0; padding-left: 1.15rem; }
.news-points li { margin: .25rem 0; line-height: 1.45; }
.news-dialog-foot { display: flex; justify-content: flex-end; padding: .8rem 1.25rem; border-top: 1px solid var(--border); }
.news-card .card-header h2 { margin: 0; }
.tabs-inline { display: flex; gap: .4rem; flex-wrap: wrap; }
.tabs-inline a { padding: .35rem .75rem; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text); text-decoration: none; font-size: .9rem; }
.tabs-inline a.active { background: var(--primary-soft); border-color: var(--primary); color: var(--primary); font-weight: 600; }
.presence-inline { position: static; display: inline-block; vertical-align: middle; border: 0; margin: 0 .35rem 0 .15rem; }
.password-wrap { position: relative; display: block; }
.password-wrap input { width: 100%; padding-right: 2.75rem; }
.password-wrap input::-ms-reveal, .password-wrap input::-ms-clear { display: none; }
.password-toggle { position: absolute; top: 50%; right: .3rem; transform: translateY(-50%); display: inline-flex; align-items: center; justify-content: center; width: 2.1rem; height: 2.1rem; padding: 0; border: 0; border-radius: var(--radius-sm); background: transparent; color: var(--text-2); cursor: pointer; }
.password-toggle:hover { color: var(--text); background: var(--surface-2); }
.password-toggle:focus-visible { outline: 2px solid var(--primary); outline-offset: 1px; }
.password-toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.qr-link { word-break: break-all; }
.module-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: .6rem 1.25rem; }
.module-choice { display: flex; gap: .6rem; align-items: flex-start; padding: .65rem .75rem; border: 1px solid var(--border); border-radius: var(--radius-sm); cursor: pointer; }
.module-choice input { margin-top: .2rem; width: 18px; height: 18px; flex: none; accent-color: var(--primary); }
.module-choice > span { display: flex; flex-direction: column; gap: .15rem; }
.module-choice:has(input:not(:checked)) { background: var(--surface-2); }
.module-choice:has(input:not(:checked)) strong { color: var(--text-3); }
.center-actions { justify-content: center; }
.input-date-sm { width: auto; padding: .3rem .45rem; font-size: .82rem; }
.dashboard-info { margin-top: 1rem; }
.dashboard-info > summary { cursor: pointer; padding: .75rem 0; font-weight: 600; color: var(--text-2); }
.todo-card h3 { margin: .75rem 0 .25rem; font-size: 1rem; }
.tip { display: inline-block; position: relative; vertical-align: middle; font-weight: normal; text-transform: none; letter-spacing: 0; }
.tip > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; width: 1.15rem; height: 1.15rem; border-radius: 999px;
  border: 1px solid var(--border-strong); color: var(--text-3); font-size: .72rem; font-weight: 700; line-height: 1; }
.tip > summary::-webkit-details-marker { display: none; }
.tip[open] > summary { background: var(--primary); border-color: var(--primary); color: #fff; }
.tip-body { position: absolute; z-index: 30; top: calc(100% + .35rem); right: -.5rem; width: min(280px, 80vw); padding: .7rem .8rem; background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: var(--shadow-lg); color: var(--text); font-size: .85rem; text-align: left; white-space: normal; }
@media (pointer: coarse) { .tip > summary { width: 1.9rem; height: 1.9rem; font-size: .85rem; } }
.sort-link { color: inherit; display: inline-flex; align-items: center; gap: .25rem; white-space: nowrap; }
.sort-link:hover { text-decoration: none; color: var(--primary); }
.sort-arrow { font-size: .7em; color: var(--text-3); }
.sort-link.active .sort-arrow { color: var(--primary); }
.record-history > summary { cursor: pointer; list-style: none; }
.record-history > summary::-webkit-details-marker { display: none; }
.record-history > summary h2::after { content: " \25B8"; color: var(--text-3); }
.record-history[open] > summary h2::after { content: " \25BE"; }
.session-bar { position: fixed; left: 50%; bottom: 1rem; transform: translateX(-50%); z-index: 90; display: flex; flex-wrap: wrap; align-items: center; gap: .75rem;
  width: min(640px, calc(100% - 2rem)); padding: .85rem 1rem; background: var(--sidebar); color: #fff; border-radius: var(--radius); box-shadow: var(--shadow-lg); font-size: .92rem; }
.session-bar span { flex: 1 1 260px; }
.list-summary { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .6rem; padding: .7rem 1.25rem; border-top: 1px solid var(--border); font-size: .9rem; }
.list-export { margin-left: auto; font-size: .85rem; display: inline-flex; align-items: center; gap: .35rem; }
.chip { display: inline-flex; align-items: center; gap: .35rem; padding: .15rem .3rem .15rem .65rem; border-radius: 999px; background: var(--primary-soft); color: var(--primary); font-size: .82rem; font-weight: 600; }
.chip a { display: inline-flex; align-items: center; justify-content: center; width: 1.4rem; height: 1.4rem; border-radius: 999px; color: inherit; text-decoration: none; font-size: 1rem; line-height: 1; }
.chip a:hover { background: rgba(29, 78, 216, .15); }
@media (pointer: coarse) { .chip a { width: 2.2rem; height: 2.2rem; } }
.error-links a { color: inherit; text-decoration: underline; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.center { text-align: center; }
.table th.center, .table td.center { text-align: center; }
.input-narrow { width: 6rem; }
.table tr.table-group td { background: var(--surface-2); font-size: .85rem; color: var(--text-2); }
.radio-cell { display: inline-flex; padding: .35rem; cursor: pointer; }
.radio-cell input { width: 18px; height: 18px; accent-color: var(--primary); cursor: pointer; }

/* het hidden-attribuut wint altijd van display: grid/flex */
[hidden] { display: none !important; }

/* pakketvergelijking (Instellingen > Licentie) */
.packages-table th.is-current, .packages-table td.is-current { background: var(--primary-soft); }
.packages-table th { vertical-align: top; }
.update-progress { width: 100%; display: grid; grid-template-columns: 1fr auto; gap: .25rem .75rem; align-items: center; }
.update-progress progress { width: 100%; height: 14px; accent-color: var(--primary); }
.update-progress .update-percent { font-weight: 700; min-width: 3.5em; text-align: right; }
.update-progress [data-update-step] { grid-column: 1 / -1; color: var(--text-2); }
.update-progress.is-done progress { accent-color: var(--success); }
.update-progress.is-failed [data-update-step] { color: var(--danger); }

/* Handleiding en voorbeeldgegevens */
.help-toc { display: flex; flex-wrap: wrap; gap: .4rem; }
.help-section { scroll-margin-top: 1rem; }
.help-section h2 .icon { vertical-align: -.15em; }
.help-steps { margin: 0 0 1rem; padding-left: 1.3rem; }
.help-steps li { margin-bottom: .6rem; }
.help-steps li strong { display: block; }
.help-steps li span { color: var(--text-2); }
.help-actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1rem; }

/* Zoekbalk bovenaan en zoekresultaten */
.topbar-search { position: relative; flex: 0 1 380px; min-width: 0; }
.topbar-search .icon { position: absolute; left: .7rem; top: 50%; transform: translateY(-50%); color: var(--text-3); pointer-events: none; }
.topbar-search input[type=search] { width: 100%; padding-left: 2.2rem; background: var(--surface-2); }
.topbar-search input[type=search]:focus { background: var(--surface); }
.search-page-form { display: flex; gap: .5rem; }
.search-page-form input[type=search] { flex: 1; min-width: 0; }
.search-list { list-style: none; margin: 0; padding: 0 1.25rem; }
.search-list li { display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding: .6rem 0; border-bottom: 1px solid var(--border); }
.search-list li:last-child { border-bottom: 0; }
.search-list a { display: flex; flex-direction: column; min-width: 0; }
.search-list a:hover { text-decoration: none; }
.search-list a:hover strong { text-decoration: underline; }
@media (max-width: 600px) {
  .topbar-search { flex: 1 1 auto; }
  .topbar-search input[type=search]::placeholder { color: transparent; }
}

/* Bekijken als */
.view-as-bar { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; padding: .6rem 1.5rem; background: var(--warning-soft, #fef3c7); color: #78350f; border-bottom: 1px solid #fde68a; font-size: .9rem; }
.view-as-bar > span { flex: 1; min-width: 200px; }
.view-as-bar .inline-form { margin: 0; }

/* Startgids op het dashboard */
.startgids-progress { width: 100%; height: 10px; accent-color: var(--success); margin-bottom: .75rem; }
.startgids-steps { list-style: none; margin: 0; padding: 0; }
.startgids-steps li { display: flex; align-items: center; gap: .75rem; padding: .6rem 0; border-bottom: 1px solid var(--border); }
.startgids-steps li:last-child { border-bottom: 0; }
.startgids-steps li > div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.startgids-steps li.is-done strong { color: var(--text-3); text-decoration: line-through; font-weight: 500; }
.startgids-mark { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--border-strong); display: grid; place-items: center; }
.startgids-steps li.is-done .startgids-mark { background: var(--success); border-color: var(--success); color: #fff; }
.startgids-mark .icon { width: 14px; height: 14px; }

/* Documenten maken en ondertekenen */
.doc-template-pick, .doc-action-buttons { display: flex; flex-wrap: wrap; gap: .5rem; }
.doc-actions h2 { margin-bottom: .75rem; }
.doc-action-buttons { margin-bottom: .75rem; }
.doc-template-list li { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; padding: .55rem 1.25rem; }
.doc-template-list li a { flex: 1; min-width: 160px; }
.doc-placeholders dt { margin-top: .4rem; }
.doc-preview { font-size: 1rem; line-height: 1.6; max-width: 70ch; }
.doc-preview ul { margin: 0 0 1rem 1.25rem; }
.signature-pad { position: relative; border: 2px dashed var(--border-strong); border-radius: var(--radius); background: #fff; }
.signature-pad.is-invalid { border-color: var(--danger); }
.signature-pad canvas { display: block; width: 100%; height: auto; aspect-ratio: 3 / 1; touch-action: none; cursor: crosshair; }
.signature-hint { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); color: var(--text-3); pointer-events: none; text-align: center; }
.doc-pending li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; }

/* Taalkeuze op de aanmeldpagina */
.auth-languages { display: flex; flex-wrap: wrap; justify-content: center; gap: .35rem .9rem; margin-top: 1.25rem; padding-top: .9rem; border-top: 1px solid var(--border); font-size: .85rem; }
.auth-languages a { color: var(--text-3); }
.auth-languages a.active { color: var(--text); font-weight: 600; }
.sign-languages { display: flex; flex-wrap: wrap; align-items: baseline; gap: .35rem .9rem; margin: 0 0 .75rem; font-size: .85rem; }
.sign-languages a { color: var(--text-3); }
.sign-languages a.active { color: var(--text); font-weight: 600; }

/* rechten kiezen voor één rol */
.role-rights { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 1rem; }
.role-rights-group { margin: 0; }
.role-rights-group legend { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem; font-weight: 600; }
.role-rights-group .checkbox { display: flex; align-items: flex-start; gap: .5rem; margin: .35rem 0; }
.role-rights-group .checkbox input { margin-top: .2rem; flex: none; }


/* dashboard: gegevenscontrole */
.datacheck-row { display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding: .55rem 1rem; border-top: 1px solid var(--border); }

/* ---------- Ik ben ziek (dashboard) ---------- */
.sick-card .card-body { display: flex; flex-direction: column; gap: .75rem; }
.sick-button { display: flex; align-items: center; gap: 1rem; width: 100%; padding: 1.1rem 1.25rem; border: 0; border-radius: var(--radius); background: var(--danger); color: #fff; text-align: left; font: inherit; cursor: pointer; box-shadow: 0 6px 16px rgba(185, 28, 28, .25); }
.sick-button:hover { background: #991b1b; }
.sick-button:focus-visible { outline: 3px solid #fca5a5; outline-offset: 3px; }
.sick-button strong { display: block; font-size: 1.35rem; line-height: 1.2; }
.sick-button small { display: block; margin-top: .2rem; font-size: .88rem; opacity: .92; }
.sick-icon { flex: none; width: 2.2rem; height: 2.2rem; }
.sick-more { margin: 0; }
/* werkongeval melden (1.22.0): onder Ik ben ziek, oranje */
.accident-button { background: #c2410c; box-shadow: 0 6px 16px rgba(194, 65, 12, .25); text-decoration: none; }
.accident-button:hover { background: #9a3412; color: #fff; }
.accident-button:focus-visible { outline-color: #fdba74; }
.acc-bar { display: flex; align-items: center; gap: .6rem; }
.acc-bar progress { width: 9rem; height: .7rem; accent-color: var(--danger); }
.sick-status { margin: 0; padding: .75rem 1rem; border-radius: var(--radius-sm); background: var(--success-soft); color: var(--success); }
.sick-status strong { color: var(--text); }
.sick-attest { display: flex; flex-direction: column; gap: .5rem; padding: .85rem 1rem; border: 1px solid #fcd34d; border-left: 4px solid var(--warning); border-radius: var(--radius-sm); background: #fffbeb; }
.sick-attest.is-late { border-color: #fca5a5; border-left-color: var(--danger); background: #fef2f2; }
.sick-attest > div { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem .6rem; }
.sick-upload { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.sick-upload input[type="file"] { flex: 1 1 14rem; min-width: 0; }

/* ---------- avatars (Wie is wie, Berichten): vaste kleur per persoon ---------- */
.who-avatar { flex: none; width: 2.1rem; height: 2.1rem; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: .76rem; font-weight: 700; letter-spacing: .02em; }
.who-avatar-lg { width: 2.6rem; height: 2.6rem; font-size: .9rem; }
.who-avatar.is-me { background: var(--primary); color: #fff; }
.who-c0 { background: #dbeafe; color: #1e40af; }
.who-c1 { background: #dcfce7; color: #166534; }
.who-c2 { background: #fef3c7; color: #92400e; }
.who-c3 { background: #fce7f3; color: #9d174d; }
.who-c4 { background: #ede9fe; color: #5b21b6; }
.who-c5 { background: #cffafe; color: #155e75; }
.who-c6 { background: #ffedd5; color: #9a3412; }
.who-c7 { background: #e2e8f0; color: #334155; }

/* menubalk onderaan op de gsm (1.25.0): Start, Planning, Uren, Verlof en het menu */
.bottom-nav { display: none; }
@media (max-width: 900px) {
  .bottom-nav { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 32; background: var(--surface); border-top: 1px solid var(--border);
    padding: .2rem .25rem calc(.2rem + env(safe-area-inset-bottom)); box-shadow: 0 -4px 14px rgba(15, 23, 42, .06); }
  .bottom-nav a, .bottom-nav button { position: relative; flex: 1 1 0; min-width: 0; min-height: 54px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .15rem;
    padding: .3rem .15rem; border: 0; background: none; color: var(--text-2); font: inherit; font-size: .72rem; line-height: 1.1; text-decoration: none; cursor: pointer; border-radius: var(--radius-sm); }
  .bottom-nav .icon { width: 1.4rem; height: 1.4rem; }
  .bottom-nav span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .bottom-nav .active { color: var(--primary); font-weight: 600; }
  .bottom-nav .active::before { content: ''; position: absolute; top: 0; left: 25%; right: 25%; height: 3px; border-radius: 0 0 3px 3px; background: var(--primary); }
  .bottom-nav .nav-count { position: absolute; top: .15rem; left: calc(50% + .45rem); }
  .has-bottom-nav .content { padding-bottom: calc(5.5rem + env(safe-area-inset-bottom)); }
}
@media print { .bottom-nav { display: none !important; } }

/* Ik ben ziek en Werkongeval naast elkaar (1.25.0) */
.sick-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; }
.sick-actions > :only-child { grid-column: 1 / -1; }
.sick-actions form { display: flex; }
.sick-actions .sick-button { height: 100%; }
@media (max-width: 700px) {
  .sick-actions .sick-button { flex-direction: column; align-items: flex-start; gap: .4rem; padding: .85rem .9rem; }
  .sick-actions .sick-button strong { font-size: 1.1rem; }
  .sick-actions .sick-button small { display: none; }
  .sick-actions .sick-icon { width: 1.6rem; height: 1.6rem; }
}

/* Op te volgen (1.25.0) */
.followup-list { display: grid; gap: .6rem; }
.followup-item { display: flex; align-items: center; gap: 1rem; padding: .9rem 1.1rem; margin: 0; color: inherit; text-decoration: none; }
.followup-item:hover { border-color: var(--primary); }
.followup-item.is-waiting { border-left: 4px solid var(--danger); }
.followup-icon { flex: none; display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 50%; background: var(--primary-soft); color: var(--primary); }
.followup-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .15rem; }
.followup-count { flex: none; display: flex; align-items: center; gap: .6rem; }
@media (max-width: 560px) { .followup-item { flex-wrap: wrap; } .followup-count { width: 100%; justify-content: space-between; } }

/* Opnieuw bevestigen (1.26.0) */
.card-narrow { max-width: 32rem; }
