/*
 * Opmaak: de kleuren van de app (donker menu, blauw accent) met de vorm van het
 * ontwerpsysteem van Tip Top Ops, Richting D: zakelijk en typografisch. De inhoud
 * staat direct naast het menu op wit; secties hebben een kop met een dunne lijn.
 * Een kader krijgt alleen wat echt een los blok is (kengetallen, "Vandaag op pad",
 * "Vraagt om actie"). Geen zwevende schaduwen, kleine radius, rustige tabelkoppen
 * (geen kapitalen) en getallen rechts in cijfers van gelijke breedte.
 *
 * Stijlgids voor nieuwe schermen: docs/stijlgids.md.
 *
 * Alle waarden staan hier als variabelen (tokens); componenten gebruiken alleen die.
 */

/* Inter Variable (alle gewichten 100–900 in één bestand); de losse TTF's blijven voor de PDF's. */
@font-face { font-family: 'Inter Variable'; src: url('fonts/inter/variable.woff2') format('woff2'); font-weight: 100 900; font-style: normal; font-display: swap; }

:root {
  /* kleur: ongewijzigd ten opzichte van de vorige opmaak */
  --frame: #141d29;
  --sidebar: #16212f;
  --sidebar-2: #1b2a3c;
  --sidebar-text: #c3ccd8;
  --sidebar-hover: rgba(255, 255, 255, 0.05);
  --sidebar-active: rgba(255, 255, 255, 0.1);
  --sidebar-line: rgba(255, 255, 255, 0.08);
  --bg: #f0f2f5;
  --surface: #ffffff;
  --surface-2: #f7f8fa;
  --surface-3: #eef1f4;
  --text: #1c2430;
  --muted: #6b7684;
  --border: #e1e5ea;
  --border-strong: #c9d0d8;
  --hair: #edf0f3;
  --accent: #2a83d6;
  --accent-hover: #1f6fbd;
  --accent-soft: #e8f2fc;
  --accent-ring: rgba(42, 131, 214, 0.25);
  --success: #2e8b3e;
  --success-soft: #e6f4e8;
  --danger: #c0312b;
  --danger-soft: #fdeceb;
  --warning: #b86200;
  --warning-soft: #fff3e0;
  --info: #2a83d6;
  --info-soft: #e8f2fc;

  /* vorm (Richting D) */
  --radius: 6px;
  --radius-sm: 5px;
  --radius-xs: 4px;
  --radius-lg: 6px;
  /* Geen zwevende schaduwen: een 1 px rand. Alleen wat over de inhoud heen ligt
     (keuzelijst, dialoog) krijgt een schaduw. */
  --shadow: none;
  --shadow-lg: 0 8px 24px rgba(16, 24, 40, 0.18);
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --font: 'Inter Variable', Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  /* VIS-14 / punt 6: één hoogte voor invoervelden, keuzelijsten en knoppen */
  --control-h: 32px;
  --chevron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b7684' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7 10l5 5 5-5'/%3E%3C/svg%3E");
  --mono: ui-monospace, 'SF Mono', 'Cascadia Mono', Menlo, Consolas, monospace;

  font-family: var(--font);
  font-size: 14px;
  line-height: 20px;
  color: var(--text);
}

* { box-sizing: border-box; }
html, body, #root { height: 100%; margin: 0; }
body { background: var(--surface); -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.icon { width: 17px; height: 17px; flex: none; }
.mono { font-family: var(--mono); font-size: 13px; }

/* ---------- opbouw: menu, balk en inhoud ---------- */

.app { display: grid; grid-template-columns: 228px 1fr; height: 100%; background: var(--surface); }

.sidebar {
  background: var(--sidebar); color: var(--sidebar-text); display: flex; flex-direction: column; overflow-y: auto; padding: 10px 10px 12px;
  scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, 0.15) transparent;
}
.brand { display: flex; align-items: center; gap: 10px; padding: 6px 8px 12px; }
.brand-mark {
  width: 26px; height: 26px; border-radius: 5px; background: var(--accent); color: #fff; flex: none;
  display: grid; place-items: center; font-weight: 700; font-size: 11.5px; letter-spacing: 0.02em;
}
.brand-text { min-width: 0; }
.brand-text b { display: block; color: #fff; font-weight: 600; font-size: 13.5px; line-height: 17px; letter-spacing: -0.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-text small { display: block; font-size: 11px; line-height: 14px; opacity: 0.7; }
.nav { display: flex; flex-direction: column; gap: 1px; }
.nav-group { padding: 14px 10px 4px; font-size: 12px; line-height: 16px; font-weight: 600; text-transform: none; letter-spacing: 0; color: var(--sidebar-text); opacity: 0.55; }
.nav a {
  display: flex; align-items: center; gap: 9px; padding: 5px 10px; border-radius: var(--radius-sm);
  color: var(--sidebar-text); text-decoration: none; font-weight: 500; font-size: 13.5px; line-height: 20px;
}
.nav a .icon { width: 16px; height: 16px; opacity: 0.55; }
.nav a .label { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav a:hover { background: var(--sidebar-hover); color: #fff; text-decoration: none; }
.nav a.active { background: var(--sidebar-active); color: #fff; font-weight: 600; }
.nav a.active .icon { opacity: 0.95; }
.nav .count { font-family: var(--font); font-size: 12px; line-height: 20px; align-self: center; color: var(--sidebar-text); opacity: 0.7; padding: 0 2px; }
.nav .count.late { color: #ff8f5a; opacity: 1; font-weight: 700; }
.nav .count.expired { color: #f5a524; opacity: 1; font-weight: 700; }

.subnav { position: relative; margin: 1px 0 6px 18px; padding-left: 9px; border-left: 1px solid var(--sidebar-line); display: flex; flex-direction: column; gap: 1px; }
.subnav a { padding: 4px 10px; font-size: 13px; font-weight: 500; }
.subnav a.active { background: none; color: #fff; font-weight: 600; }

.nav-bottom { margin-top: auto; padding-top: 8px; border-top: 1px solid var(--sidebar-line); }
.user-menu { position: relative; margin-top: 6px; }
.user {
  display: flex; align-items: center; gap: 9px; width: 100%; padding: 7px 8px; border: 0; border-radius: var(--radius-sm);
  background: none; color: var(--sidebar-text); cursor: pointer; text-align: left;
}
.user:hover { background: var(--sidebar-hover); }
.user .avatar { width: 26px; height: 26px; font-size: 10.5px; background: rgba(255, 255, 255, 0.12); color: #fff; }
.user-text { flex: 1; min-width: 0; }
.user-text b { display: block; color: #fff; font-size: 12.5px; font-weight: 600; line-height: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-text small { display: block; font-size: 11px; line-height: 14px; opacity: 0.7; }
.user .icon { width: 15px; height: 15px; opacity: 0.55; transform: rotate(180deg); }

.main { display: flex; flex-direction: column; min-width: 0; overflow: hidden; background: var(--surface); }
.appbar {
  display: flex; align-items: center; gap: 12px; padding: 0 28px; height: 52px; flex: none;
  background: var(--surface); border-bottom: 1px solid var(--border);
}
.appbar-title { margin: 0; font-size: 14px; line-height: 22px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.appbar-date { font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.appbar-search {
  margin-left: auto; display: flex; align-items: center; gap: 8px; width: 17rem; max-width: 40%;
  background: var(--surface-3); border: 1px solid transparent; border-radius: var(--radius-sm); padding: 0 10px; color: var(--muted);
}
.appbar-search input { flex: 1; min-width: 0; border: 0; background: none; padding: 6px 0; font-size: 13px; outline: none; color: var(--text); }
.appbar-search:focus-within { border-color: var(--accent); background: var(--surface); }
.appbar-search .icon { width: 15px; height: 15px; }
.menu-toggle, .appbar-search-button { display: none; }
.avatar {
  width: 34px; height: 34px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); flex: none;
  display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px;
}
.scroll { flex: 1; overflow-y: auto; }

.page { padding: 20px 28px 48px; max-width: 1360px; }
.page-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px 16px; margin-bottom: 18px; flex-wrap: wrap; }
.page-title { min-width: 0; }
.page-header h1 { font-size: 20px; line-height: 26px; font-weight: 600; margin: 0; display: flex; align-items: center; flex-wrap: wrap; gap: 6px 10px; letter-spacing: -0.012em; }
.title-chips { display: inline-flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 14px; letter-spacing: 0; }
.page-header .sub { color: var(--muted); margin-top: 2px; font-size: 13px; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* ---------- secties en kaarten ---------- */

/*
 * .card is een sectie: een kop met een dunne lijn eronder en dan de inhoud, zonder
 * kader. Alleen wat echt een los blok is krijgt een kader: .card.box en .kpi.
 */
.card { margin-bottom: 28px; min-width: 0; }
.card h2 { font-size: 15px; line-height: 22px; font-weight: 600; margin: 0 0 10px; }
.card > h2:first-child { padding-bottom: 8px; border-bottom: 1px solid var(--border); margin-bottom: 12px; }
.card-head { display: flex; align-items: center; gap: 8px; padding: 0 0 8px; min-height: 30px; border-bottom: 1px solid var(--border); margin-bottom: 12px; }
.card-head > .icon { color: var(--muted); width: 16px; height: 16px; }
.card-head h2 { margin: 0; flex: 0 1 auto; min-width: 0; }
.card-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: flex-end; font-size: 13px; }
.card-actions .more { font-size: 13px; font-weight: 600; }
.card-body { min-width: 0; }
.card.flush > .card-head { margin-bottom: 0; }
.card .pad { padding: 10px 0; margin: 0; }

.card.box { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 14px; }
.card.box > .card-head { padding: 8px 14px; margin-bottom: 0; border-bottom-color: var(--hair); }
.card.box > .card-body { padding: 12px 14px; }
.card.box.flush > .card-body { padding: 0; }
.card.box .pad { padding: 10px 14px; }

.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 36px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 28px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.grid-4 > .card { margin-bottom: 0; }
/* Twee kolommen zoals "Vandaag": links de lijst, rechts wat om actie vraagt. */
.duo { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 14px; align-items: start; margin-bottom: 28px; }
.duo > .card { margin-bottom: 0; }

/* kengetallen */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.kpis.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.kpi, .stat {
  display: block; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 10px 14px;
  color: inherit; text-decoration: none; min-width: 0;
}
a.kpi:hover, a.stat:hover { text-decoration: none; border-color: var(--border-strong); }
.kpi-label, .stat .label { margin: 0; font-size: 12px; line-height: 16px; color: var(--muted); font-weight: 600; display: flex; align-items: center; gap: 6px; }
.kpi-label .icon { width: 15px; height: 15px; }
.kpi-value, .stat .value { display: block; font-size: 22px; line-height: 28px; font-weight: 700; letter-spacing: -0.02em; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kpi-sub, .stat .hint { display: block; font-size: 12px; line-height: 16px; color: var(--muted); }
.kpi-sub.danger { color: var(--danger); font-weight: 600; }
.kpi-sub.warning { color: var(--warning); font-weight: 600; }
.kpi-sub.success { color: var(--success); font-weight: 600; }
.stat.warn .value { color: var(--warning); }

/* lijstregels in een kaart: tijd, gekleurde streep, titel, status rechts */
.list-row { display: flex; align-items: center; gap: 10px; padding: 8px 14px; border-bottom: 1px solid var(--hair); color: inherit; text-decoration: none; min-width: 0; }
.list-row:last-child { border-bottom: 0; }
a.list-row:hover { background: var(--surface-2); text-decoration: none; }
.list-row .bar { width: 3px; align-self: stretch; border-radius: 2px; background: var(--accent); flex: none; }
.list-row .time { font-size: 12px; color: var(--muted); width: 6.6rem; flex: none; font-variant-numeric: tabular-nums; }
.list-row .what { min-width: 0; flex: 1; }
.list-row .what b { display: block; font-weight: 600; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list-row .what .sub { display: block; font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list-row .right { margin-left: auto; flex: none; }

/* "Vraagt om actie": één lijst, op urgentie */
.action-row { display: flex; gap: 10px; align-items: flex-start; padding: 8px 14px; border-bottom: 1px solid var(--hair); color: inherit; text-decoration: none; font-size: 13px; }
.action-row:last-child { border-bottom: 0; }
a.action-row:hover { background: var(--surface-2); text-decoration: none; }
.action-row > .icon { color: var(--muted); margin-top: 1px; width: 16px; height: 16px; }
.action-row .what { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.action-row .sub { font-size: 12px; color: var(--muted); }
.action-row .act { margin-left: auto; font-size: 12px; color: var(--accent); font-weight: 600; white-space: nowrap; }

/* chips naast een titel: rustig, met een dunne rand */
.chip {
  display: inline-flex; align-items: center; gap: 5px; font-size: 12px; line-height: 18px; font-weight: 600; padding: 1px 7px;
  border: 1px solid var(--border); border-radius: var(--radius-xs); color: var(--muted); white-space: nowrap; letter-spacing: 0; background: var(--surface);
}
.chip .icon { width: 13px; height: 13px; }
.chip.accent { color: var(--accent); border-color: #cfe2f5; }
.chip.success { color: var(--success); }
.chip.warning { color: var(--warning); }
.chip.danger { color: var(--danger); }

/*
 * Statuschip (VIS-06, stijlgids punt 2): stip + woord, dunne rand in de statuskleur.
 * Tussenstatus = alleen omlijnd; eindstatus (.final) = licht gevuld. De toon komt uit
 * renderer/status.ts. .badge (oude losse chips) heeft dezelfde vorm.
 */
.status-chip, .badge {
  display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border: 1px solid currentColor; border-radius: 3px;
  background: transparent; font-size: 12px; line-height: 20px; font-weight: 600; white-space: nowrap; letter-spacing: 0; vertical-align: middle;
  color: var(--muted);
}
.status-chip::before, .badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex: none; }
.status-chip.final, .badge.final { background: color-mix(in srgb, currentColor 10%, var(--surface)); }
.status-chip.neutral { color: var(--muted); }
.status-chip.info, .badge.blue { color: #44505e; }
.status-chip.accent { color: var(--accent); }
.status-chip.warning, .badge.orange { color: var(--warning); }
.status-chip.danger, .badge.red { color: var(--danger); }
.status-chip.success, .badge.green { color: var(--success); }
.badge .icon { display: none; }

/* ---------- knoppen ---------- */

/*
 * Secundair: rustig grijs vlak met een dunne rand (MOB-14: ook buiten in de zon herkenbaar als knop);
 * primair: het accent, één per scherm; ghost: zonder vlak, voor rijacties; danger alleen in menu's en bevestigingen.
 */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid var(--border-strong); background: var(--surface-3);
  min-height: var(--control-h); padding: 0 12px; border-radius: var(--radius-sm); cursor: pointer; white-space: nowrap; text-decoration: none;
  color: #2c3744; font-weight: 600; font-size: 13px; line-height: 18px; transition: background 0.12s, border-color 0.12s;
}
.btn:hover { background: #e3e7ec; text-decoration: none; }
.btn.ghost { background: none; border-color: transparent; color: var(--text); }
.btn.ghost:hover { background: var(--surface-3); }
.btn.icon-only { padding: 0; width: var(--control-h); }
.btn.icon-only .icon { width: 17px; height: 17px; }
.btn:disabled { opacity: 0.5; cursor: default; }
.btn .icon { width: 15px; height: 15px; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn.danger { color: var(--danger); background: var(--surface); border-color: #efc2bf; }
.btn.danger:hover { background: var(--danger-soft); border-color: var(--danger); }
.btn.small { min-height: 26px; padding: 0 8px; font-size: 12.5px; }
.btn.link { border: none; background: none; padding: 0; min-height: 0; color: var(--accent); font-weight: 600; }
.btn.link:hover { text-decoration: underline; background: none; }

/* "Nieuw ▾": secundaire handelingen in één menu in plaats van een rij knoppen */
.menu-button { position: relative; display: inline-block; }
.menu-button .icon.caret { width: 14px; height: 14px; margin-right: -3px; }
.menu-button .dropdown a, .user-menu .dropdown a { display: flex; align-items: center; gap: 8px; }
.menu-button .dropdown .icon { width: 15px; height: 15px; color: var(--muted); }
.dropdown.up { top: auto; bottom: calc(100% + 6px); left: 0; right: 0; min-width: 0; color: var(--text); }

/* ---------- lijsten ---------- */

.toolbar { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; flex-wrap: wrap; }
.tabs { display: flex; gap: 2px; flex-wrap: wrap; border-bottom: 1px solid var(--border); }
.tabs button {
  border: none; background: none; padding: 8px 12px 7px; cursor: pointer; color: var(--muted); font-weight: 600; font-size: 13.5px;
  border-bottom: 2px solid transparent; margin-bottom: -1px;
}
.tabs button:hover { color: var(--text); }
.tabs button.active { color: var(--accent); border-bottom-color: var(--accent); }
.toolbar .tabs { flex: 1; }
/* Filters naast elkaar in een werkbalk, het zoekveld neemt de rest. */
.toolbar > .input, .toolbar > select { width: auto; max-width: 100%; }
.toolbar > .input.search, .toolbar > input.search { flex: 1 1 260px; }
.search { min-width: 260px; }

table.data { width: 100%; border-collapse: separate; border-spacing: 0; background: var(--surface); }
table.data th {
  text-align: left; font-size: 12px; line-height: 16px; font-weight: 600; letter-spacing: 0; text-transform: none; color: var(--muted);
  padding: 8px 12px 7px; border-bottom: 1px solid var(--border); background: var(--surface); white-space: nowrap;
}
table.data td { padding: 8px 12px; border-bottom: 1px solid var(--hair); vertical-align: middle; }
table.data th:first-child, table.data td:first-child { padding-left: 4px; }
table.data th:last-child, table.data td:last-child { padding-right: 4px; }
.card.box table.data th:first-child, .card.box table.data td:first-child { padding-left: 14px; }
.card.box table.data th:last-child, .card.box table.data td:last-child { padding-right: 14px; }
table.data tbody tr:last-child td { border-bottom: none; }
table.data tr.clickable { cursor: pointer; }
table.data tr.clickable:hover td { background: var(--surface-2); }
table.data tfoot td { font-weight: 700; border-top: 1px solid var(--border); border-bottom: none; }
/* Regels op een document: dezelfde rustige kop als elke tabel (VIS-09). */
table.data.doc th:first-child, table.data.doc td:first-child { padding-left: 10px; }
.num { text-align: right !important; font-variant-numeric: tabular-nums; font-feature-settings: 'tnum', 'zero'; white-space: nowrap; }
.nowrap { white-space: nowrap; }
.muted { color: var(--muted); }
.loading { padding: 8px 0; }

/* lege toestand (§6.7): wat het scherm doet en de eerste handeling, geen illustratie */
.empty {
  display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 28px 20px; text-align: center; color: var(--muted);
  background: var(--surface-2); border-radius: var(--radius); margin-bottom: 14px;
}
.card .empty { padding: 20px 12px; margin-bottom: 0; }
.empty-icon { width: 22px; height: 22px; color: var(--muted); margin-bottom: 2px; }
.empty-title { color: var(--text); font-size: 14px; font-weight: 600; }
.empty-text { max-width: 46ch; }
.empty-action { margin-top: 8px; display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }

/* ---------- formulieren ---------- */

.form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 20px; }
.form .full { grid-column: 1 / -1; }
.field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.field > span { font-size: 12px; line-height: 16px; color: var(--text); font-weight: 600; }
.field input, .field select, .field textarea, .input {
  border: 1px solid var(--border-strong); border-radius: var(--radius-sm); padding: 5px 10px; background: var(--surface); width: 100%;
  min-height: var(--control-h); font-size: 14px; line-height: 20px; transition: border-color 0.12s, box-shadow 0.12s;
}
/* Eigen pijltje in keuzelijsten, overal dezelfde hoogte (VIS-14). */
select, select.input, .field select {
  appearance: none; -webkit-appearance: none; background-image: var(--chevron); background-repeat: no-repeat; background-position: right 9px center;
  padding-right: 28px !important;
}
select:not(.status-select):not([multiple]) { min-height: var(--control-h); }
select[multiple] { background-image: none; padding-right: 10px !important; }
input[type='checkbox'], input[type='radio'] { width: 16px; height: 16px; min-height: 0; padding: 0; accent-color: var(--accent); margin: 0; flex: none; }
.field textarea { min-height: 76px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus, .input:focus,
table.lines input:focus, table.lines select:focus, .setting-control input:focus, .setting-control select:focus, .setting-control textarea:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent-ring);
}

table.lines { width: 100%; border-collapse: collapse; }
table.lines th { text-align: left; font-size: 12px; line-height: 16px; letter-spacing: 0; text-transform: none; color: var(--muted); font-weight: 600; padding: 4px 4px 8px; }
table.lines td { padding: 3px 4px; vertical-align: top; }
table.lines input, table.lines select { border: 1px solid var(--border-strong); border-radius: var(--radius-xs); padding: 5px 8px; min-height: var(--control-h); font-size: 14px; width: 100%; background-color: var(--surface); }
table.lines .total { padding-top: 10px; }

.totals { margin-left: auto; width: 360px; margin-top: 14px; }
.totals div { display: flex; justify-content: space-between; padding: 3px 0; font-variant-numeric: tabular-nums; color: var(--muted); font-size: 13px; }
.totals div > :last-child { color: var(--text); }
.totals .grand { border-top: 1px solid var(--border); margin-top: 6px; padding-top: 8px; font-weight: 700; font-size: 17px; color: var(--text); }

dl.props { display: grid; grid-template-columns: max-content 1fr; gap: 6px 24px; margin: 0; font-size: 13.5px; }
dl.props dt { color: var(--muted); }
dl.props dd { margin: 0; }

/* ---------- dialogen en meldingen ---------- */

.modal-backdrop { position: fixed; inset: 0; background: rgba(15, 22, 32, 0.45); display: flex; align-items: flex-start; justify-content: center; padding-top: 9vh; z-index: 40; }
.modal { background: var(--surface); border-radius: var(--radius); width: min(640px, 92vw); max-height: 82vh; overflow-y: auto; box-shadow: var(--shadow-lg); }
.modal header { display: flex; align-items: center; gap: 8px; padding: 6px 6px 6px 20px; min-height: 50px; border-bottom: 1px solid var(--border); font-weight: 600; font-size: 15px; line-height: 22px; }
.modal-title { flex: 1; min-width: 0; }
.modal-close { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; margin-left: auto; border: 0; border-radius: var(--radius-sm); background: none; color: var(--muted); cursor: pointer; }
.modal-close:hover { background: var(--surface-3); color: var(--text); }
.modal-close .icon { width: 18px; height: 18px; }
.modal .body { padding: 18px 20px; }
.modal footer { padding: 12px 20px; border-top: 1px solid var(--border); display: flex; justify-content: flex-end; gap: 8px; background: var(--surface-2); border-radius: 0 0 var(--radius) var(--radius); }

.toasts { position: fixed; bottom: 20px; right: 20px; display: flex; flex-direction: column; gap: 8px; z-index: 50; }
.toast { background: #1c2430; color: #fff; padding: 10px 14px; border-radius: var(--radius); width: 320px; max-width: calc(100vw - 24px); box-shadow: var(--shadow-lg); font-weight: 500; }
.toast.error { background: var(--danger); }

/* Info neutraal grijs met een lijnicoon (VIS-27); accent alleen voor wat klikbaar is. */
.alert { position: relative; padding: 9px 14px 9px 38px; border-radius: var(--radius); margin-bottom: 14px; background: var(--surface-2); color: var(--text); border: 1px solid var(--border); }
.alert::before {
  content: ''; position: absolute; left: 13px; top: 11px; width: 16px; height: 16px; background: var(--muted);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 11v5M12 8v.01'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 11v5M12 8v.01'/%3E%3C/svg%3E") center / contain no-repeat;
}
.alert.warn::before, .alert.error::before { background: currentColor; }
.alert.warn { background: var(--warning-soft); color: #8a4a00; border-color: #f6dcb4; }
/* Een blokkade (fout) heeft een eigen vorm: een 3 px streep links, zodat kleur niet de enige drager is. */
.alert.error { background: var(--danger-soft); color: var(--danger); border-color: #f5c9c6; border-left: 3px solid var(--danger); }

.bars { display: flex; align-items: flex-end; gap: 8px; height: 160px; padding-top: 10px; }
.bars .bar { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 5px; height: 100%; justify-content: flex-end; }
.bars .bar div { width: 100%; max-width: 42px; background: var(--accent); border-radius: 3px 3px 0 0; min-height: 2px; }
.bars .bar span { font-size: 11px; color: var(--muted); }

/* ---------- hulpklassen ---------- */

.stack { display: flex; flex-direction: column; gap: 12px; }
.check { display: flex; gap: 8px; align-items: center; }
.btn.block { width: 100%; justify-content: center; }
.small { font-size: 12px; }
.center { text-align: center !important; }
.stats { margin-bottom: 14px; }
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.table-wrap > table.data { min-width: 100%; }
table.rights td, table.rights th { padding: 7px 12px; }
fieldset.plain { border: 0; padding: 0; margin: 0; min-width: 0; }
code { font-family: var(--mono); font-size: 12px; background: var(--surface-3); padding: 1px 5px; border-radius: 3px; }
.dashboard-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.search-page-form { display: flex; gap: 8px; margin-bottom: 18px; max-width: 640px; }
.search-results { align-items: start; }

/* ---------- inloggen ---------- */

.login { min-height: 100%; display: flex; align-items: center; justify-content: center; padding: 16px; background: var(--frame); }
.login > .card { width: min(420px, 100%); padding: 28px 28px 24px; background: var(--surface); border-radius: var(--radius); margin: 0; }
.login h1 { font-size: 20px; margin: 0 0 6px; }

.topbar, .backdrop { display: none; }

/* ---------- mobiel en tablet ---------- */

@media (max-width: 1100px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .duo { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 900px) {
  .app { display: block; height: auto; min-height: 100%; }
  .sidebar {
    position: fixed; top: 0; bottom: 0; left: 0; width: min(280px, 84vw); z-index: 25;
    transform: translateX(-100%); transition: transform 0.2s ease;
  }
  .menu-open .sidebar { transform: none; box-shadow: 0 0 40px rgba(0, 0, 0, 0.3); }
  .menu-open .backdrop { display: block; position: fixed; inset: 0; z-index: 20; background: rgba(0, 0, 0, 0.35); }
  .nav a { padding: 9px 10px; }
  .main { overflow: visible; }
  .appbar { position: sticky; top: 0; z-index: 15; padding: 0 6px 0 2px; height: 50px; gap: 4px; }
  .menu-toggle, .appbar-search-button {
    display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; flex: none;
    background: none; border: 0; color: var(--text); cursor: pointer; border-radius: var(--radius-sm);
  }
  .menu-toggle .icon, .appbar-search-button .icon { width: 21px; height: 21px; }
  .appbar-search-button { margin-left: auto; color: var(--muted); }
  .appbar-date, .appbar-search { display: none; }
  .scroll { overflow: visible; }
  .page { padding: 14px 16px 40px; }
  .page-header h1 { font-size: 19px; line-height: 25px; }
  .page-header .actions { width: 100%; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .kpis, .kpis.three { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .kpi-value, .stat .value { font-size: 18px; line-height: 24px; }
  .form { grid-template-columns: 1fr; }
  .form .full { grid-column: auto; }
  .card { margin-bottom: 22px; }
  .list-row, .action-row { padding: 9px 12px; }
  .list-row { flex-wrap: wrap; row-gap: 2px; }
  .list-row .time { width: auto; }
  .list-row .what { flex-basis: calc(100% - 20px); order: 3; padding-left: 13px; }
  .list-row .right { order: 2; }
  .toolbar .search { min-width: 0; flex: 1 1 100%; }
  .tabs { overflow-x: auto; flex-wrap: nowrap; max-width: 100%; }
  .tabs button { white-space: nowrap; }
  /* Tabellen schuiven zijwaarts in plaats van de pagina breder te maken. */
  .page > table.data, .card > table.data, .card-body > table.data { display: block; overflow-x: auto; }
  table.data td, table.data th { padding: 9px 10px; }
  .hide-mobile { display: none; }
  table.lines { min-width: 860px; }
  .card:has(table.lines) { overflow-x: auto; }
  .totals { width: 100%; }
  .modal-backdrop { padding-top: 0; align-items: stretch; }
  .modal { width: 100%; max-height: 100%; border-radius: 0; }
  .modal footer { border-radius: 0; }
  .toasts { left: 12px; right: 12px; bottom: 12px; }
  .toast { width: auto; max-width: none; }
  /* Grotere aanraakdoelen. */
  .btn { padding: 9px 14px; }
  .btn.small { padding: 6px 10px; }
  .field input:not([type='checkbox']):not([type='radio']), .field select, .field textarea, .input { padding: 9px 10px; font-size: 16px; }
}

/* ---------- instellingen (indeling zoals WeFact) ---------- */

.settings-layout { display: grid; grid-template-columns: 230px 1fr; gap: 18px; align-items: start; }
.white-menu { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 6px 0; position: sticky; top: 12px; }
.white-menu a { display: block; padding: 8px 14px; color: var(--text); text-decoration: none; border-left: 3px solid transparent; }
.white-menu a:hover { background: #f6f8f7; }
.white-menu a.active { color: var(--accent); border-left-color: var(--accent); background: var(--accent-soft); font-weight: 600; }
.white-menu a.danger.active { color: var(--danger); border-left-color: var(--danger); background: var(--danger-soft); }
.settings-card h2 { display: flex; align-items: center; gap: 8px; }
.card-intro { color: var(--muted); margin: -4px 0 14px; }
.settings-fields { display: flex; flex-wrap: wrap; gap: 12px 16px; }
.setting-row { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 6px 16px; align-items: start; width: 100%; }
.setting-row.half { width: calc(50% - 8px); grid-template-columns: 1fr; }
.setting-label { font-weight: 600; font-size: 13px; padding-top: 7px; }
.setting-row.half .setting-label { padding-top: 0; }
.setting-control input:not([type='checkbox']):not([type='radio']), .setting-control select, .setting-control textarea {
  border: 1px solid var(--border-strong); border-radius: var(--radius-sm); padding: 5px 10px; background-color: #fff; width: 100%; max-width: 460px; min-height: var(--control-h); font-size: 14px;
}
.setting-control textarea { min-height: 80px; max-width: none; }
.setting-control .check { padding-top: 7px; }
.radios { display: flex; flex-direction: column; gap: 6px; padding-top: 7px; }
.radios .check { padding-top: 0; }
.with-suffix { display: inline-flex; align-items: center; gap: 8px; }
.with-suffix input { width: 110px !important; }
.time { display: inline-flex; align-items: center; gap: 6px; }
.time select { width: auto !important; }
.save-bar { display: flex; justify-content: flex-end; margin-top: 4px; }
.badge.plus { display: none; }
.subhead { font-size: 13px; margin: 14px 0 8px; }

@media (max-width: 900px) {
  .settings-layout { grid-template-columns: 1fr; }
  .white-menu { position: static; display: flex; overflow-x: auto; padding: 0; }
  .white-menu a { white-space: nowrap; border-left: 0; border-bottom: 3px solid transparent; }
  .white-menu a.active { border-bottom-color: var(--accent); }
  .setting-row { grid-template-columns: 1fr; }
  .setting-row.half { width: 100%; }
  .setting-label { padding-top: 0; }
  .save-bar .btn { width: 100%; justify-content: center; }
}

/* ---------- offertes ---------- */
.quote-status { font-size: 14px; font-weight: 500; margin-left: 4px; }
.quote-group { margin-bottom: 22px; }
.quote-group-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.quote-bulk { padding: 10px 12px; border-top: 1px solid var(--border); }
.quote-bulk select { border: 1px solid var(--border); border-radius: 6px; padding: 6px 8px; background-color: #fff; }
.quote-props { display: grid; grid-template-columns: 150px 1fr; gap: 8px 12px; margin: 0; }
.quote-props dt { color: var(--muted); }
.quote-props dd { margin: 0; }
.quote-buildup-card { background: #f6f8f9; border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; margin-top: 20px; }
.quote-parts { display: flex; gap: 12px; flex-wrap: wrap; }
.quote-part { width: 120px; min-height: 150px; border-radius: 6px; padding: 10px; display: flex; flex-direction: column; gap: 6px; font-size: 12px; word-break: break-word; }
.quote-part.pdf, .quote-part.lines { background: #fff; border: 1px solid var(--border); }
.quote-part.pending { opacity: 0.7; }
.quote-part.add { border: 1px dashed #b9c2c9; background: none; color: var(--muted); align-items: center; justify-content: center; cursor: pointer; }
.quote-part.add span { font-size: 20px; }
.quote-part.hidden-lines { opacity: 0.5; }
.quote-part-lines { flex: 1; background: repeating-linear-gradient(#fff 0 6px, #dfe4e8 6px 8px); }
.quote-part-actions { display: flex; gap: 4px; margin-top: auto; }
.quote-dropzone { border: 2px dashed #b9c2c9; border-radius: var(--radius); padding: 36px 16px; text-align: center; color: var(--muted); cursor: pointer; }
.quote-dropzone.over { border-color: var(--accent); background: var(--accent-soft); }
.quote-vat-mode { border: none; background: none; color: var(--muted); cursor: pointer; }
.quote-layout { display: grid; grid-template-columns: minmax(0, 1fr) 240px; gap: 20px; align-items: start; }
.quote-side-block { margin-bottom: 18px; }
.quote-side-block h3 { font-size: 14px; margin: 0 0 4px; }
.quote-links { margin: 0; padding-left: 16px; }
.quote-mode { display: flex; width: fit-content; margin: 20px auto 12px; }
.quote-preview { width: 100%; height: 70vh; border: 1px solid var(--border); border-radius: 6px; background: #fff; }
.quote-timeline { margin-top: 14px; }
.quote-timeline-bar { position: relative; height: 4px; background: var(--border); margin: 12px 8px 14px; border-radius: 2px; }
.quote-timeline-dot { position: absolute; top: -5px; width: 14px; height: 14px; margin-left: -7px; border-radius: 50%; background: var(--info); }
.quote-timeline-dot.verzonden { background: var(--accent); }
.quote-timeline-dot.verlopen { background: #f08c00; }
.quote-timeline-dot.skipped { background: #b9c2c9; }
.quote-timeline-list { margin: 0; padding-left: 18px; }
@media (max-width: 900px) {
  .quote-layout { grid-template-columns: 1fr; }
  .quote-props { grid-template-columns: 120px 1fr; }
}

/* ---------- facturen ---------- */
.invoice-layout { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 18px; align-items: start; }
.invoice-aside section { margin-bottom: 18px; }
.invoice-aside h3 { font-size: 14px; margin: 0 0 6px; display: flex; justify-content: space-between; }
.invoice-aside ul { margin: 0; padding-left: 16px; }
.invoice-aside .history-entry { margin-bottom: 8px; }
.invoice-filters .spacer, .invoice-bulk .spacer { flex: 1; }
.invoice-filters .btn.link.active { font-weight: 700; text-decoration: underline; }
.invoice-lines textarea { width: 100%; min-height: 34px; resize: vertical; border: 1px solid var(--border); border-radius: 5px; padding: 6px 7px; font: inherit; }
.invoice-lines .note-line td { background: #fafbfc; }
.line-links { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 2px; }
.line-discount { display: inline-flex; align-items: center; gap: 4px; }
.line-discount input { width: 64px !important; }
.lines-actions { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; }
.kenmerken dd .input { max-width: 280px; }
.input.compact { width: auto; padding: 4px 8px; }
.invoice-preview { width: 100%; height: 900px; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; }
.dropzone { min-height: 60px; }
@media (max-width: 1000px) { .invoice-layout { grid-template-columns: 1fr; } }
.modal table.data input:not([type="checkbox"]) { width: 100px; }

/* ---------- inkoop ---------- */
.purchase-submit { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; padding: 0; border: 1px dashed var(--border-strong); border-radius: var(--radius); text-align: center; }
.purchase-submit > div { padding: 18px 12px; }
.purchase-submit > div + div { border-left: 1px solid var(--border); }
.purchase-submit.dragging { border-color: var(--accent); background: var(--accent-soft); }
.purchase-layout { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 16px; align-items: start; }
.purchase-document { min-height: 420px; position: sticky; top: 12px; }
.match-row { display: grid; grid-template-columns: auto 1fr auto 1fr; gap: 16px; align-items: center; margin-bottom: 0; }
.text-danger { color: var(--danger); }
@media (max-width: 900px) { .purchase-layout, .purchase-submit, .match-row { grid-template-columns: 1fr; } .purchase-submit > div + div { border-left: 0; border-top: 1px solid var(--border); } .purchase-document { position: static; } }
@media print { .no-print, .sidebar, .topbar { display: none !important; } .app { display: block; } }

/* ---------- huisstijl ---------- */
.hst-editor { display: grid; grid-template-columns: 290px minmax(0, 1fr); gap: 18px; align-items: start; }
.hst-editor .card h3 { margin: 0 0 8px; font-size: 14px; }
.hst-preview iframe { width: 100%; height: 78vh; border: 1px solid var(--border); border-radius: 8px; background: #e9edf1; }
.hst-row { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; padding: 4px 0; }
.hst-row > span:first-child { font-weight: 600; min-width: 80px; }
.hst-blocks { list-style: none; margin: 0 0 8px; padding: 0; }
.hst-blocks li { display: flex; justify-content: space-between; gap: 8px; padding: 3px 0; }
.hst-blocks li.active { font-weight: 700; }
.hst-block-edit { margin-top: 14px; }
.hst-block-edit.with-vars { display: grid; grid-template-columns: minmax(0, 1fr) 230px; gap: 16px; }
.hst-vars { border-left: 1px solid var(--border); padding-left: 12px; max-height: 60vh; overflow-y: auto; }
.hst-vars h3 { margin: 0 0 8px; font-size: 14px; }
.hst-vars-head { display: flex; justify-content: space-between; width: 100%; background: none; border: 0; border-bottom: 1px solid var(--border); padding: 8px 0; font-weight: 700; cursor: pointer; }
.hst-vars ul { list-style: none; margin: 4px 0; padding: 0; }
.hst-vars li { display: flex; flex-direction: column; padding: 3px 0; }
.hst-vars code { font-size: 11px; color: var(--muted); }
.hst-grid { border-collapse: collapse; }
.hst-grid td, .hst-grid th { padding: 3px; text-align: left; font-size: 12.5px; }
.hst-grid input, .hst-grid select, .hst-grid textarea { width: 100%; min-width: 60px; }
textarea.send-message { min-height: 220px; font-family: inherit; }
.send-attachments { margin: 4px 0; padding-left: 18px; }
.hst-save { align-items: center; gap: 12px; }
@media (max-width: 900px) {
  .hst-editor, .hst-block-edit.with-vars { grid-template-columns: 1fr; }
  .hst-vars { border-left: 0; padding-left: 0; }
}
/* ---------- breedte: zijkolom op detailpagina's ---------- */
/* Met het menu erbij is de inhoud ±250px smaller dan het venster; onder 1280px valt de zijkolom eronder. */
@media (max-width: 1280px) {
  .invoice-layout, .quote-layout { grid-template-columns: 1fr; }
}
dl.props dd { min-width: 0; overflow-wrap: anywhere; }
/* ---------- resend ---------- */
.send-from { padding: 8px 12px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px; }
.domain-icon { margin-left: 6px; cursor: help; }
.address-input { display: inline-flex; align-items: center; gap: 4px; }
.address-input .input.local { width: 120px; }
.senders-matrix td { vertical-align: top; }
.senders-matrix .input { min-width: 150px; }
.dns-records code, .webhook-url { word-break: break-all; font-size: 12px; }
.dns-value { max-width: 420px; }
.senders-matrix td:first-child { min-width: 130px; }
.settings-layout > .settings-content { min-width: 0; } /* brede tabellen scrollen binnen hun kaart */

/* ---------- instellingen: huisstijl-editor ---------- */
.hst-title { margin: 0; font-size: 20px; line-height: 26px; font-weight: 600; }
.hst-bar { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 16px; }
.hst-bar .segmented { justify-self: center; }
.segmented { display: inline-flex; background: #e6e9ee; border-radius: 8px; padding: 3px; }
.segmented button { border: 0; background: none; padding: 6px 48px; border-radius: 6px; font: inherit; color: var(--muted); cursor: pointer; }
.segmented button.active { background: var(--surface); color: var(--text); font-weight: 600; box-shadow: var(--shadow); }
.hst-side h3 { color: var(--muted); font-weight: 600; }
.hst-acc { border-bottom: 1px solid var(--border); }
.hst-acc-head { display: flex; justify-content: space-between; width: 100%; background: none; border: 0; padding: 10px 0; font: inherit; font-weight: 700; cursor: pointer; color: var(--text); }
.hst-acc-body { padding: 0 0 12px; }
.hst-drop, .hst-upload { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; width: 100%; min-height: 84px; padding: 12px; border: 1px dashed var(--border-strong); border-radius: 8px; background: var(--surface-2); color: var(--muted); font: inherit; font-size: 13px; cursor: pointer; }
.hst-drop.big { min-height: 190px; font-size: 15px; color: var(--text); }
.hst-drop.over, .hst-drop:hover, .hst-upload:hover { border-color: var(--accent); background: var(--accent-soft); }
.hst-drop .link { color: var(--accent); }
.hst-pdf-icon { display: inline-block; padding: 10px 8px; background: #e53935; color: #fff; font-weight: 700; font-size: 12px; border-radius: 3px; transform: rotate(-8deg); }
.plus { display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; border-radius: 4px; background: var(--success); color: #fff; font-weight: 700; font-size: 13px; line-height: 1; }
.hst-upload .plus, .hst-drop .plus { background: var(--text); }
.hst-add { display: inline-flex; align-items: center; gap: 6px; padding: 4px 0; }
.hst-file { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; word-break: break-all; }
.hst-canvas iframe { display: block; width: 100%; min-height: 1150px; border: 0; border-radius: 8px; background: #e9edf1; }
.modal:has(.hst-dialog) { width: min(1120px, 96vw); max-height: 92vh; }
.hst-dialog-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.hst-dialog-head .btn.link { font-weight: 400; font-size: 14px; }
.hst-position { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 32px; }
.hst-position h3 { margin: 0 0 10px; font-size: 15px; }
.hst-position .full { grid-column: 1 / -1; }
.hst-mm { display: grid; grid-template-columns: 110px 1fr; align-items: center; gap: 8px; margin-bottom: 8px; }
.hst-qr-choice { display: flex; flex-direction: column; gap: 8px; }
.hst-qr-option { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px; cursor: pointer; }
.hst-qr-option.active { border-color: var(--accent); background: var(--accent-soft); }
.hst-qr-option.disabled { opacity: .6; cursor: not-allowed; }
.hst-qr-option small { display: block; color: var(--muted); margin-top: 4px; line-height: 1.5; }
.hst-lines tr.dragging { opacity: .5; }
.hst-handle { cursor: grab; color: var(--muted); padding: 0 6px; user-select: none; font-size: 15px; }
.hst-fonts td { vertical-align: top; }
.font-sample { font-size: 18px; }
@media (max-width: 900px) {
  .hst-bar { grid-template-columns: 1fr; }
  .segmented button { padding: 6px 18px; }
  .hst-position { grid-template-columns: 1fr; }
}
.hst-mail-preview { width: 100%; min-height: 220px; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.hst-mailfont { align-items: center; gap: 12px; margin: 0; }

/* ---------- instellingen ---------- */
.settings-card-title { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.settings-status { font-size: 13px; font-weight: 400; color: var(--muted); }
.settings-sub { margin-top: 22px; }
.settings-sub > h3 { font-size: 15px; line-height: 22px; font-weight: 600; margin: 0 0 8px; }
.plus-card { border-color: #f0d9a8; }
.card-bullets { margin: -6px 0 14px; padding-left: 20px; }
.card-note { color: var(--text); margin: 12px 0 0; }
.help-dot { display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; margin-left: 6px; border-radius: 50%; border: 1.5px solid var(--muted); background: none; color: var(--muted); font-size: 10px; font-weight: 700; cursor: help; vertical-align: 1px; }
.setting-before { margin: 18px 0 10px; }
.setting-control select.narrow { width: 80px; }
.pair { display: flex; gap: 6px; }
.pair .zip, .setting-control .pair .zip { width: 110px !important; flex: none; }
table.numbering { border-collapse: separate; border-spacing: 8px 6px; margin-left: -8px; }
table.numbering th { text-align: left; font-weight: 700; padding-right: 12px; }
table.numbering input { width: 180px; }
table.numbering input.prefix { width: 90px; }
.reminder-timeline { background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 20px; margin-top: 18px; }
.reminder-timeline h4 { margin: 0 0 10px; }
.reminder-timeline ol { list-style: none; margin: 0 0 12px; padding: 0 0 0 14px; border-left: 2px dotted var(--border-strong); }
.reminder-timeline li { position: relative; padding: 4px 0 12px 8px; }
.reminder-timeline li::before { content: ''; position: absolute; left: -20px; top: 10px; width: 10px; height: 10px; border-radius: 50%; background: var(--success); }
.reminder-timeline li.rt-reminder::before { background: #f39c12; }
.reminder-timeline li.rt-summation::before { background: var(--danger); }
.rt-row { display: grid; grid-template-columns: 22px 64px 1fr; align-items: baseline; padding: 2px 0; }
.rt-reminder .rt-icon { color: #f39c12; }
.rt-summation .rt-icon { color: var(--danger); }
.cloud-choice { display: flex; flex-direction: column; align-items: center; gap: 12px; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; margin-top: 8px; }
.cloud-options { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; width: 100%; }
.cloud-option { display: flex; align-items: center; gap: 10px; padding: 18px 14px; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; cursor: pointer; }
.cloud-option.active { border-color: var(--accent); }
.company-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 26px 48px; }
/* HER-V-02: two columns only when there is room; there the label sits above the field so IBAN/BIC keep a usable width. */
.company-grid .setting-row { grid-template-columns: minmax(0, 1fr); }
.company-grid .setting-row .setting-label { padding-top: 0; }
.company-grid .logo-drop { max-width: 460px; }
@media (max-width: 1499px) { .company-grid { grid-template-columns: minmax(0, 1fr); } }
@media (min-width: 901px) and (max-width: 1499px) {
  .company-grid .setting-row { grid-template-columns: 260px minmax(0, 1fr); }
  .company-grid .setting-row .setting-label { padding-top: 7px; }
}
.company-card .settings-card-title { margin-top: 0; }
.logo-drop { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 200px; padding: 16px; border: 2px dashed var(--border-strong); border-radius: 10px; color: var(--muted); text-align: center; }
.logo-drop.over { border-color: var(--accent); background: var(--accent-soft); }
.logo-drop img { max-width: 100%; max-height: 140px; object-fit: contain; }
.logo-placeholder { font-size: 54px; line-height: 1; opacity: .5; }
.warn-dot { display: inline-flex; align-items: center; justify-content: center; width: 18px; height: 16px; margin-left: 8px; background: #f39c12; color: #fff; font-size: 11px; font-weight: 800; clip-path: polygon(50% 0, 100% 100%, 0 100%); padding-top: 3px; }
.appbar-menu { position: relative; }
.appbar-menu .who { background: none; border: 0; font: inherit; cursor: pointer; padding: 4px 6px; }
.admin-switch .caret { color: var(--muted); font-size: 11px; }
.dropdown { position: absolute; top: calc(100% + 6px); left: 0; min-width: 230px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: 6px 0; z-index: 60; }
.dropdown.right { left: auto; right: 0; }
.dropdown a { display: block; padding: 8px 14px; color: var(--text); text-decoration: none; }
.dropdown a:hover { background: var(--surface-2); }
.dropdown a.current { font-weight: 600; }
.dropdown-head { display: flex; flex-direction: column; padding: 8px 14px 10px; border-bottom: 1px solid var(--border); margin-bottom: 4px; }
.admin-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.admin-tile { display: flex; flex-direction: column; gap: 4px; text-decoration: none; color: var(--text); }
.cleanup-tree { list-style: none; padding: 0; margin: 6px 0 14px; }
.cleanup-tree li.top { margin-top: 8px; }
.cleanup-tree li.child { padding-left: 22px; }
.api-key { display: block; margin: 6px 0; font-size: 14px; word-break: break-all; }
.api-docs { margin-top: 18px; }
.api-docs summary { cursor: pointer; color: var(--accent); }
.api-example { background: var(--surface-2); padding: 10px; border-radius: 6px; overflow-x: auto; font-size: 12px; }
.api-log-filters .input { min-width: 260px; }
.profile-page { max-width: 720px; margin: 0 auto; }
.profile-photo { display: flex; align-items: center; gap: 18px; }
.avatar.big { width: 58px; height: 58px; font-size: 20px; }
@media (max-width: 900px) {
  .company-grid, .cloud-options { grid-template-columns: 1fr; }
  table.numbering input { width: 110px; }
}
.numbering-wrap { overflow-x: auto; }
.pair input { min-width: 0; } .pair input:not(.zip) { flex: 1; width: auto !important; }
/* ---------- editor (klant kiezen, Klant aanmaken, korting, offerte opbouw) ---------- */
.hrow { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 4px 14px; align-items: start; margin-bottom: 9px; }
.hlabel { padding-top: 7px; color: var(--text); display: inline-flex; align-items: center; gap: 6px; }
.hcontrol { min-width: 0; }
.hcontrol > input, .hcontrol > select, .hsplit input, .hsplit select, .suggest input { border: 1px solid var(--border-strong); border-radius: 6px; padding: 7px 10px; background-color: #fff; min-height: var(--control-h); width: 100%; }
.hcontrol:not(:has(input, select, button)) { padding-top: 7px; }
.hsplit { display: flex; gap: 6px; }
.hcontrol.check { display: flex; align-items: flex-start; gap: 8px; padding-top: 7px; }
.hcontrol.check input { flex: none; margin-top: 3px; }
.hgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 34px; }
.hgrid h3 { margin: 0 0 8px; font-size: 15px; line-height: 22px; font-weight: 600; }
.info-dot { display: inline-grid; place-items: center; width: 15px; height: 15px; border-radius: 50%; border: 1.5px solid var(--muted); background: none; color: var(--muted); font-size: 9.5px; font-weight: 700; cursor: help; }
.modal:has(.debtor-dialog) { width: min(1100px, 95vw); }
.debtor-dialog-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.debtor-dialog-head .btn.link { font-weight: 600; text-decoration: none; }
.suggest { position: relative; }
.suggest .suggest-search { padding-right: 30px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%236b7684' stroke-width='2.2'%3E%3Ccircle cx='10' cy='10' r='6'/%3E%3Cpath d='M15 15l6 6'/%3E%3C/svg%3E") no-repeat right 10px center; }
.customer-picker input { padding-right: 28px; }
.suggest-caret { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 12px; cursor: pointer; }
.suggest-list { position: absolute; left: 0; right: 0; top: calc(100% + 2px); z-index: 50; margin: 0; padding: 4px 0; list-style: none; background: #fff; border: 1px solid var(--border-strong); border-radius: 6px; box-shadow: var(--shadow-lg); max-height: 300px; overflow-y: auto; }
.suggest-list li { padding: 7px 12px; cursor: pointer; display: flex; flex-direction: column; gap: 1px; }
.suggest-list li strong { font-weight: 600; }
.suggest-list li span { color: var(--muted); font-size: 12.5px; }
.suggest-list li.active { background: var(--accent-soft); }
.suggest-list li.suggest-footer { cursor: default; }
.doc-customer-head { display: flex; justify-content: space-between; align-items: baseline; }
.doc-customer-head h2 { margin: 0 0 12px; }
.doc-customer-data { margin-top: 18px; }
.drop-menu { position: relative; display: inline-block; }
.drop-menu-items { position: absolute; left: -12px; top: calc(100% + 4px); z-index: 30; background: #fff; border-radius: 8px; box-shadow: var(--shadow-lg); padding: 6px 0; min-width: 300px; }
.drop-menu-items button { display: flex; align-items: center; gap: 10px; width: 100%; border: 0; background: none; padding: 9px 16px; text-align: left; font: inherit; cursor: pointer; color: var(--text); }
.drop-menu-items button:hover { background: var(--surface-2); }
.drop-menu-items .icon { width: 16px; height: 16px; }
.discount-box { margin: 14px 0 0 auto; width: 400px; max-width: 100%; background: var(--surface-2); border: 1px solid var(--border); border-radius: 6px; padding: 12px; display: grid; gap: 10px; }
.discount-box-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.discount-box input { width: 80px; text-align: right; }
.status-select { border: 0; background-color: transparent; color: var(--muted); font-size: 14px; cursor: pointer; }
.quote-buildup-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.quote-buildup-head h2 { margin-top: 0; }
.quote-buildup-body { display: flex; gap: 20px; justify-content: space-between; flex-wrap: wrap; align-items: flex-start; }
.quote-tip { background: var(--accent-soft); border: 1px solid #cfe2f6; border-radius: 10px; padding: 14px 16px; max-width: 520px; }
.quote-tip ul { margin: 6px 0 8px; padding-left: 18px; }
.quote-dropzone-title { display: block; color: var(--text); font-size: 16px; margin-bottom: 2px; }
.link-text { color: var(--accent); }
@media (max-width: 760px) {
  .hrow { grid-template-columns: 1fr; }
  .hlabel { padding-top: 0; font-weight: 600; }
  .hgrid { grid-template-columns: 1fr; }
}
.quick-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: -6px 0 18px; }
.quick-actions .btn { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; }
.quick-actions .icon { width: 16px; height: 16px; }
.company-stats-head { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid var(--border); padding-bottom: 12px; margin-bottom: 16px; }
.company-stats-head h2 { margin: 0; }
.company-stats-head .btn.link { font-size: 18px; text-decoration: none; }
.company-stats-body { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 24px; }
.results-chart { margin: 0; }
.results-chart figcaption { text-align: center; margin-bottom: 4px; }
.results-chart figcaption .info-dot { margin-left: 6px; vertical-align: 1px; }
.results-chart svg { width: 100%; height: auto; display: block; }
.results-chart text { font-size: 12px; fill: var(--muted); }
.results-chart .grid { stroke: var(--border); }
.results-chart .zero { stroke: var(--border-strong); }
.results-chart .area { fill: rgba(46, 139, 62, 0.16); }
.results-chart .current { fill: none; stroke: var(--success); stroke-width: 2.5; }
.results-chart .previous { fill: none; stroke: #9aa5b1; stroke-width: 1.5; stroke-dasharray: 5 4; }
.results-chart .hit { fill: transparent; }
.chart-legend { display: flex; justify-content: center; gap: 18px; font-size: 12px; color: var(--muted); }
.chart-legend span::before { content: ''; display: inline-block; width: 16px; height: 0; border-top: 2.5px solid var(--success); margin-right: 6px; vertical-align: middle; }
.chart-legend .previous::before { border-top: 1.5px dashed #9aa5b1; }
.action-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 14px; }
.action-tile { border: 1px solid var(--border); border-radius: 6px; padding: 12px 14px; display: flex; flex-direction: column; gap: 3px; color: var(--muted); text-decoration: none; }
.action-tile strong { color: var(--text); font-weight: 600; }
a.action-tile.active { border-color: var(--border-strong); }
a.action-tile.active span { color: var(--accent); }
a.action-tile:hover { border-color: var(--accent); text-decoration: none; }
.company-figures hr { border: 0; border-top: 1px solid var(--border); margin: 14px 0; }
.figures { margin-bottom: 18px; }
.figures h3 { display: flex; justify-content: space-between; align-items: baseline; font-size: 14px; margin: 0 0 6px; }
.figure-row { display: grid; grid-template-columns: 1fr auto 100px; gap: 8px; padding: 3px 0; font-variant-numeric: tabular-nums; }
.change { font-size: 11px; padding: 1px 6px; border-radius: 4px; background: var(--surface-2); color: var(--muted); align-self: center; }
.change.up { color: var(--success); background: var(--success-soft); }
.change.down { color: var(--danger); background: var(--danger-soft); }
.line-tabs { display: flex; gap: 24px; border-bottom: 1px solid var(--border); }
.line-tabs button { border: 0; background: none; padding: 4px 0 10px; font: inherit; font-weight: 600; color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.line-tabs button.active { color: var(--text); border-bottom-color: var(--accent); }
.bulk-row { display: flex; align-items: center; gap: 10px; padding: 12px 0 2px 8px; }
.bulk-corner { width: 14px; height: 14px; border-left: 1px solid var(--border-strong); border-bottom: 1px solid var(--border-strong); margin-top: -10px; }
@media (max-width: 1000px) {
  .company-stats-body { grid-template-columns: 1fr; }
  .action-tiles { grid-template-columns: 1fr; }
}
/* ---------- overig (taken, producten, voorraad, statistieken) ---------- */
.task-assignee { display: inline-flex; align-items: center; gap: 10px; }
.task-avatar { width: 30px; height: 30px; flex: none; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; }
.task-avatar.none { background: #f3f4f6; border: 1px dashed var(--border-strong); }
.task-status { width: auto; border-radius: 999px; padding: 5px 10px; font-size: 13px; }
.task-view-title { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.task-view-title .btn.link { font-size: 14px; }
.task-view-card { border: 1px solid var(--border); border-radius: 12px; }
.task-view-head { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-bottom: 1px solid var(--border); font-size: 16px; }
.task-view-row { display: flex; align-items: center; gap: 10px; padding: 12px 16px 0; }
.task-view-body { padding: 16px; white-space: pre-wrap; }
.task-view-comments { margin: 20px -22px -20px; padding: 18px 22px; background: var(--surface-2); border-top: 1px solid var(--border); display: flex; flex-direction: column; gap: 12px; }
.task-comment { display: flex; gap: 10px; align-items: flex-start; }
.task-comment textarea { flex: 1; min-height: 36px; resize: vertical; }
.task-created { text-align: center; border-top: 1px solid var(--border); padding-top: 10px; }
.btn.link.product-code { color: var(--muted); font-size: 16px; }
.affix { display: inline-flex; align-items: stretch; border: 1px solid var(--border); border-radius: 6px; overflow: hidden; background: #fff; width: max-content; }
.affix > span { padding: 7px 9px; color: var(--muted); background: var(--surface-2); }
.affix input, .field .affix input { border: none; border-radius: 0; width: 110px; box-shadow: none; }
.stock-warning { font-size: 12.5px; font-weight: 600; }
.stock-warning.low { color: var(--warning); }
.stock-warning.none { color: var(--danger); }
.stock-saved { color: #2e7d32; font-size: 12.5px; font-weight: 600; }
.feature-hero { background: var(--accent-soft); border-color: #cfe3f7; padding: 30px 34px; }
.feature-hero h1 { margin: 0 0 12px; font-size: 20px; line-height: 26px; font-weight: 600; }
.feature-lead { font-size: 16px; color: var(--muted); max-width: 720px; }
.feature-checks { list-style: none; padding: 0; margin: 0 0 20px; display: flex; flex-direction: column; gap: 6px; }
.feature-checks li::before { content: '✓'; color: #2e7d32; font-weight: 700; margin-right: 8px; }
.feature-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 40px; margin-top: 10px; }
.feature { text-align: center; padding: 18px 10px; }
.feature h2 { font-size: 15px; line-height: 22px; margin: 0 0 8px; }
.feature p { margin: 0; color: var(--muted); }
.stats-table { width: 100%; border-collapse: collapse; }
.stats-table th, .stats-table td { padding: 9px 4px; border-bottom: 1px solid #eef0f3; text-align: left; }
.stats-table thead th { font-weight: 700; }
.stats-table tbody th { font-weight: 600; }
.stats-table .num { text-align: right; white-space: nowrap; }
.stats-table tfoot th, .stats-table tfoot td { border-top: 1px solid var(--text); font-weight: 700; border-bottom: none; }
.line-chart svg { width: 100%; height: auto; display: block; }
.line-chart .legend { display: flex; justify-content: center; gap: 16px; flex-wrap: wrap; margin-bottom: 6px; font-size: 13px; }
.line-chart .legend i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 4px; }
@media (max-width: 900px) { .feature-grid { grid-template-columns: 1fr; } }
.field .check input[type='checkbox'], .field .check input[type='radio'] { width: auto; flex: none; }

/* ---------- handtekening ---------- */
.sig-progress-head { display: flex; align-items: center; gap: 14px; margin-bottom: 10px; }
.sig-progress-head h2 { margin: 0; }
.sig-bar { flex: 1; max-width: 220px; height: 6px; border-radius: 3px; background: var(--border); overflow: hidden; margin-left: auto; }
.sig-bar i { display: block; height: 100%; background: var(--success); }
.sig-steps, .sig-users { list-style: none; margin: 0; padding: 0; }
.sig-steps li { display: flex; align-items: center; gap: 12px; padding: 8px 0; border-top: 1px solid #eef0f3; }
.sig-step-text { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.sig-dot { width: 24px; height: 24px; flex: none; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; background: var(--warning-soft); color: var(--warning); }
.done > .sig-dot { background: var(--success-soft); color: var(--success); }
.sig-logo-row, .sig-color-row, .sig-photo-row { display: flex; align-items: center; gap: 10px; }
.sig-logo { max-width: 120px; max-height: 48px; }
.sig-color-row input[type='color'] { width: 42px; height: 34px; padding: 2px; border: 1px solid var(--border-strong); border-radius: 6px; background: #fff; }
.sig-network { display: inline-flex; align-items: center; gap: 6px; }
.sig-editor { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 18px; align-items: start; }
.sig-editor > .card { margin-bottom: 0; }
.sig-toolbar, .sig-format { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 10px; }
.sig-toolbar-label { font-size: 12px; font-weight: 600; letter-spacing: 0; text-transform: none; color: var(--muted); margin-right: 4px; }
.sig-field-btn { border: 1px solid var(--border-strong); background: var(--surface-2); border-radius: 999px; padding: 2px 10px; font: 12px ui-monospace, Consolas, monospace; cursor: pointer; }
.sig-field-btn:hover { border-color: var(--accent); color: var(--accent); }
.sig-color-pick { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 28px; border: 1px solid var(--border-strong); border-radius: 6px; font-weight: 700; cursor: pointer; }
.sig-color-pick input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.sig-edit { min-height: 150px; padding: 16px 18px; border: 1px solid var(--border-strong); border-radius: 8px; background: #fff; font: 13px/1.45 Arial, Helvetica, sans-serif; color: #1d2530; overflow-x: auto; }
.sig-edit:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-ring); }
.sig-chip { display: inline-block; padding: 0 5px; border-radius: 4px; background: var(--accent-soft); color: var(--accent); font: 12px ui-monospace, Consolas, monospace; white-space: nowrap; user-select: all; }
.sig-chip.media { width: 58px; height: 58px; line-height: 58px; text-align: center; overflow: hidden; font-size: 9px; border: 1px dashed var(--accent); }
.sig-raw { width: 100%; min-height: 220px; font: 12px ui-monospace, Consolas, monospace; border: 1px solid var(--border-strong); border-radius: 8px; padding: 10px; }
.sig-side-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.sig-side-head select { flex: 1; min-width: 0; }
.sig-preview-box { padding: 14px 16px; border: 1px solid var(--border); border-radius: 8px; background: #fff; overflow-x: auto; }
.sig-side h4 { margin: 16px 0 6px; font-size: 13px; }
.sig-users li { display: flex; justify-content: space-between; gap: 10px; padding: 5px 0; border-top: 1px solid #eef0f3; }
.sig-missing { color: var(--warning); font-size: 12.5px; font-weight: 600; }
.sig-required { color: var(--danger); }
.sig-photo, .sig-avatar { width: 58px; height: 58px; border-radius: 50%; object-fit: cover; }
.sig-locked { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid var(--border); border-radius: 6px; background: var(--surface-2); color: var(--muted); }
.sig-stepper { display: flex; gap: 8px; list-style: none; margin: 0 0 18px; padding: 0; }
.sig-stepper li { flex: 1; display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.sig-stepper li:not(:last-child)::after { content: ''; flex: 1; height: 2px; background: var(--border); }
.sig-stepper li.done::after { background: var(--success); }
.sig-stepper li.current { color: var(--text); }
.sig-stepper li.current .sig-dot { background: var(--accent); color: #fff; }
.sig-stepper li:not(.done):not(.current) .sig-dot { background: #eef0f3; color: var(--muted); }
.crop { display: flex; gap: 20px; align-items: flex-start; flex-wrap: wrap; }
.crop-view { position: relative; overflow: hidden; border-radius: 8px; background: #20262e; cursor: grab; touch-action: none; flex: none; }
.crop-view img { position: absolute; left: 50%; top: 50%; transform-origin: center; user-select: none; pointer-events: none; }
.crop-ring { position: absolute; inset: 0; border-radius: 50%; box-shadow: 0 0 0 999px rgba(15, 22, 32, 0.45); pointer-events: none; }
.crop-controls { flex: 1; min-width: 180px; display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.send-signature summary { cursor: pointer; margin-bottom: 8px; }
.sig-preview { max-width: 100%; overflow-x: auto; }
@media (max-width: 1000px) { .sig-editor { grid-template-columns: minmax(0, 1fr); } .sig-stepper b { display: none; } }

.identity-select { display: inline-flex; align-items: center; gap: 10px; width: 100%; }
.identity-select .input { flex: 1; min-width: 0; }

/* ---------- varianten ---------- */
.variants-layout { display: grid; grid-template-columns: 290px minmax(0, 1fr); gap: 16px; align-items: start; }
.variants-list { position: sticky; top: 12px; max-height: calc(100vh - 120px); overflow-y: auto; }
.variants-list-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.variants-list-head h2 { margin: 0 0 4px; font-size: 16px; }
.variant-items { list-style: none; margin: 0; padding: 0; }
.variant-row { display: flex; align-items: center; gap: 6px; padding: 5px 6px; border-radius: 6px; border: 1px solid transparent; }
.variant-row + .variant-row { margin-top: 2px; }
.variant-row:hover { background: var(--surface-2); }
.variant-row.selected { background: var(--accent-soft); border-color: var(--accent-ring); }
.variant-row.over { border-top: 2px solid var(--accent); }
.variant-row.dragging { opacity: 0.45; }
.variant-grip { cursor: grab; color: var(--muted); font-size: 12px; letter-spacing: -2px; user-select: none; }
.variant-name { flex: 1; min-width: 0; display: flex; align-items: center; gap: 6px; color: inherit; text-decoration: none; overflow-wrap: anywhere; }
.variant-row.selected .variant-name { font-weight: 600; }
.variant-move { display: flex; gap: 2px; }
.variant-move .btn { padding: 0 6px; min-height: 0; line-height: 1.6; }
.variant-archive { margin-top: 10px; }
.variant-archive summary { cursor: pointer; padding: 4px 0; }
.variant-actions { flex-wrap: wrap; gap: 6px; }
.variant-title { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; }
.variant-preview-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.variant-preview-head select { font-weight: 400; max-width: 100%; }
.variant-preview-subject { padding: 6px 0; overflow-wrap: anywhere; }
.variant-preview mark, .variant-preview-subject mark { background: #ffe08a; color: var(--text); padding: 0 2px; }
.variant-select input[type='search'] { margin-bottom: 4px; }
@media (max-width: 900px) {
  .variants-layout { grid-template-columns: minmax(0, 1fr); }
  .variants-list { position: static; max-height: 55vh; }
}

/* ---------- aanvragen ---------- */
.brand-buttons { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.brand-button { --brand: var(--accent); display: inline-flex; align-items: center; gap: 10px; min-width: 150px; padding: 12px 18px; border: 2px solid var(--border); border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow); font-size: 15px; font-weight: 600; cursor: pointer; }
.brand-button:hover { border-color: var(--brand); }
.brand-button.active { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 10%, var(--surface)); }
.brand-button .swatch { width: 14px; height: 14px; border-radius: 50%; background: var(--brand); flex: none; }
.brand-button .swatch.all { background: conic-gradient(#2e7d32, #2a83d6, #b86200, #2e7d32); }
.brand-button .count { margin-left: auto; padding-left: 8px; color: var(--muted); font-variant-numeric: tabular-nums; }
/* Merk: een staafje in de merkkleur + de naam als gewone tekst (VIS-10), geen gekleurd vlak. */
.brand-tag { display: inline-block; padding: 0 0 0 8px; border-left: 4px solid var(--brand); border-radius: 0; background: none; color: var(--text); font-size: 12.5px; line-height: 16px; font-weight: 500; white-space: nowrap; }
table.data tr.request-new td { font-weight: 600; }
.kv { display: grid; grid-template-columns: 130px minmax(0, 1fr); gap: 6px 14px; align-items: baseline; }
.kv > span:nth-child(odd) { color: var(--muted); }
.request-text { white-space: pre-wrap; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius); padding: 10px 12px; margin-top: 12px; }
.plain-list, .event-list { list-style: none; margin: 0; padding: 0; }
.plain-list li { padding: 3px 0; }
.event-list li { padding: 7px 0; border-bottom: 1px solid #eef0f3; }
.event-list li:last-child { border-bottom: none; }
.photo-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.photo-grid button { width: 120px; height: 90px; padding: 0; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--surface-2); cursor: zoom-in; }
.photo-grid img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lightbox { position: fixed; inset: 0; z-index: 1000; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; background: rgba(10, 15, 25, 0.88); }
.lightbox img { max-width: 92vw; max-height: 80vh; border-radius: 6px; box-shadow: var(--shadow-lg); }
.lightbox-bar { display: flex; align-items: center; gap: 10px; color: #fff; }
.secret-box { padding: 12px; border-radius: var(--radius); background: var(--surface-2); border: 1px solid var(--border); white-space: pre-wrap; word-break: break-all; font-size: 13px; user-select: all; }
.source-product { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.source-product select { flex: 1 1 260px; }
.kanban { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(220px, 1fr); gap: 12px; overflow-x: auto; padding-bottom: 8px; }
.kanban-col { display: flex; flex-direction: column; min-height: 240px; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius); }
.kanban-col header { display: flex; justify-content: space-between; gap: 6px; padding: 10px 12px; border-bottom: 1px solid var(--border); font-weight: 700; }
.kanban-col header small { font-weight: 400; color: var(--muted); }
.kanban-cards { display: flex; flex-direction: column; gap: 8px; padding: 8px; }
.kanban-empty { padding: 8px 4px; }
.job-card { --brand: var(--accent); display: block; width: 100%; padding: 9px 10px; text-align: left; font: inherit; color: inherit; background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--brand); border-radius: var(--radius); box-shadow: var(--shadow); cursor: pointer; }
.job-card:hover { border-color: var(--accent); border-left-color: var(--brand); }
.job-card.closed { opacity: 0.6; }
/* HER-V-04: the amount never overlaps the name; when the longest word and the amount do not fit together, the amount moves to its own line. */
.job-card-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; column-gap: 8px; }
.job-card-head .title { flex: 1 1 0; font-weight: 600; }
.job-card-head .amount { flex: none; margin-left: auto; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.job-card-meta { display: flex; justify-content: space-between; align-items: center; gap: 6px; margin-top: 6px; color: var(--muted); font-size: 12px; }
.job-card .next { margin-top: 6px; color: var(--accent); font-size: 12.5px; }
.funnel-row { display: grid; grid-template-columns: 150px minmax(80px, 1fr) 70px 90px 110px 80px; gap: 10px; align-items: center; padding: 5px 0; }
.funnel-row .num, .funnel-row.head .num { text-align: right; font-variant-numeric: tabular-nums; }
.funnel-bar { position: relative; height: 22px; border-radius: 6px; background: var(--accent-soft); overflow: hidden; }
.funnel-bar span { position: absolute; inset: 0 auto 0 0; border-radius: 6px; background: var(--accent); }
.phase-steps { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 6px; margin: 0 0 18px; padding: 0; list-style: none; }
.phase-steps li { --brand: var(--accent); display: flex; flex-direction: column; gap: 2px; padding: 8px 10px; border-top: 4px solid var(--border); background: var(--surface); border-radius: 0 0 var(--radius) var(--radius); box-shadow: var(--shadow); }
.phase-steps li.reached { border-top-color: var(--brand); }
.phase-steps li.current { outline: 2px solid var(--brand); }
.phase-steps .phase-name { font-weight: 600; font-size: 13px; }
@media (max-width: 900px) {
  .phase-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .funnel-row { grid-template-columns: 110px minmax(40px, 1fr) 50px 60px; }
  .funnel-row > :nth-child(5), .funnel-row > :nth-child(6) { display: none; }
  .brand-button { min-width: 0; flex: 1 1 140px; }
}
/* ---------- rollen (kunstgrasvoorraad) ---------- */
.roll-scan { max-width: 620px; margin: 0 auto; }
.roll-scan h1 { margin-top: 0; }
.roll-big { min-height: 52px; font-size: 17px; justify-content: center; }
.roll-type { margin-top: 16px; display: grid; gap: 10px; }
.roll-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.roll-code { font-size: 30px; font-weight: 800; letter-spacing: 0.5px; line-height: 1.1; }
.roll-choices { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.roll-choice { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 2px; min-height: 52px; padding: 8px 12px; border: 2px solid var(--border); border-radius: var(--radius); background: var(--surface); font: inherit; font-weight: 600; text-align: left; cursor: pointer; color: var(--text); }
.roll-choice small { font-weight: 400; color: var(--muted); font-size: 12px; }
.roll-choice.active { border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 2px var(--accent-ring); }
.roll-choice.roll-color { flex-direction: row; align-items: center; gap: 10px; }
.roll-swatch { display: inline-block; width: 22px; height: 22px; border-radius: 50%; border: 1px solid rgba(0, 0, 0, 0.2); flex: none; vertical-align: middle; }
.roll-batch { display: inline-flex; align-items: center; gap: 6px; }
.roll-batch .roll-swatch { width: 14px; height: 14px; }
.roll-number { font-size: 22px !important; font-weight: 700; max-width: 180px; }
.roll-length { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
.roll-length-value { font-size: 28px; font-weight: 800; line-height: 1.1; }
.roll-length-value.small-value { font-size: 20px; }
.roll-length-value.reserved, .roll-reserved-text { color: var(--warning); }
.roll-reserved strong { display: block; }
.roll-actions { display: grid; gap: 10px; margin-bottom: 18px; }
.roll-actions .card { margin-bottom: 0; }
.roll-action-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.roll-manage { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.roll-piece { display: flex; gap: 8px; margin-bottom: 6px; }
.roll-after { padding: 12px 14px; border-radius: var(--radius); background: var(--success-soft); color: var(--success); font-weight: 700; font-size: 17px; }
.roll-after.archive { background: var(--warning-soft); color: var(--warning); }
.roll-after.error { background: var(--danger-soft); color: var(--danger); }
.roll-log { list-style: none; margin: 0; padding: 0; }
.roll-log li { padding: 8px 0; border-bottom: 1px solid var(--border); }
.roll-log li:last-child { border-bottom: 0; }
.roll-camera { display: grid; gap: 10px; }
.roll-camera-view { position: relative; border-radius: var(--radius-lg); overflow: hidden; background: #000; aspect-ratio: 3 / 4; max-height: 60vh; }
.roll-camera-view video { width: 100%; height: 100%; object-fit: cover; display: block; }
.roll-camera-frame { position: absolute; inset: 18%; border: 3px solid rgba(255, 255, 255, 0.85); border-radius: 12px; box-shadow: 0 0 0 999px rgba(0, 0, 0, 0.3); }
.roll-preview { width: 100%; height: 680px; border: 1px solid var(--border); border-radius: var(--radius); background: #e9ecef; }
table.data tr.roll-group td { background: var(--surface-2, #f6f7f9); }
.roll-import-tabs { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; margin-bottom: 8px; }
.roll-import-tabs .roll-choice { flex-direction: row; align-items: center; justify-content: flex-start; gap: 8px; }
@media (max-width: 900px) {
  .roll-choices { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .roll-length-value { font-size: 24px; }
  .roll-code { font-size: 26px; }
}

/* ---------- smalle schermen: niets breder dan het scherm ---------- */
.page select, .page input, .page textarea { max-width: 100%; }
.btn.link { white-space: normal; text-align: left; }
.page a { overflow-wrap: anywhere; }

/* ---------- planning ---------- */
.plan-toolbar { align-items: center; }
.plan-nav { display: inline-flex; flex-wrap: wrap; gap: 6px; align-items: center; max-width: 100%; }
.plan-nav .input { width: auto; min-width: 0; max-width: 100%; }
.plan-title { font-size: 16px; }
.plan-scroll { overflow-x: auto; max-width: 100%; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.plan-grid { display: grid; min-width: max-content; user-select: none; }
.plan-corner, .plan-colhead { position: sticky; top: 0; z-index: 3; background: var(--surface-2); border-bottom: 1px solid var(--border); }
.plan-colhead { --team: var(--accent); padding: 8px; font-weight: 700; border-left: 1px solid var(--border); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plan-colhead.today { color: var(--accent); background: var(--accent-soft); }
.plan-dot, .plan-swatch { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--team); margin-right: 6px; }
.plan-gutter { position: relative; font-size: 11px; color: var(--muted); }
.plan-gutter span { position: absolute; right: 6px; transform: translateY(-50%); }
.plan-allday-label { display: flex; align-items: center; justify-content: flex-end; padding-right: 6px; border-bottom: 1px solid var(--border-strong); }
.plan-allday { display: flex; flex-direction: column; gap: 3px; padding: 4px; min-height: 34px; border-left: 1px solid var(--border); border-bottom: 1px solid var(--border-strong); }
.plan-col { position: relative; border-left: 1px solid var(--border); background: repeating-linear-gradient(135deg, var(--surface-2) 0 6px, var(--surface) 6px 12px); cursor: copy; }
.plan-col.closed { background: repeating-linear-gradient(135deg, #eceff3 0 6px, var(--surface-2) 6px 12px); }
.plan-workhours { position: absolute; left: 0; right: 0; background: var(--surface); pointer-events: none; }
.plan-hourline { position: absolute; left: 0; right: 0; border-top: 1px solid var(--border); pointer-events: none; }
.plan-item, .plan-chip { --brand: var(--accent); --team: var(--accent); border-left: 4px solid var(--brand); background: color-mix(in srgb, var(--team) 16%, var(--surface)); border-radius: 6px; font-size: 12px; line-height: 1.3; cursor: grab; touch-action: none; }
.plan-item { position: absolute; display: flex; flex-direction: column; gap: 1px; padding: 3px 6px 8px; overflow: hidden; box-shadow: 0 1px 2px rgba(16, 24, 40, 0.12); }
.plan-item.conflict, .plan-chip.conflict { outline: 2px solid var(--danger); outline-offset: -2px; }
.plan-item.uitgevoerd, .plan-chip.uitgevoerd { opacity: 0.6; }
.plan-item.geannuleerd, .plan-chip.geannuleerd, .plan-row.geannuleerd { opacity: 0.5; text-decoration: line-through; }
.plan-item.dragging, .plan-chip.dragging { opacity: 0.85; box-shadow: var(--shadow-lg); z-index: 5; cursor: grabbing; }
.plan-item-time { font-weight: 700; font-variant-numeric: tabular-nums; }
.plan-item-title { font-weight: 600; overflow-wrap: normal; word-break: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.plan-item-sub { color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plan-resize { position: absolute; left: 0; right: 0; bottom: 0; height: 7px; cursor: ns-resize; }
.plan-resize:hover, .plan-resize-x:hover { background: color-mix(in srgb, var(--team) 45%, transparent); }
.plan-chip { position: relative; padding: 2px 10px 2px 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plan-resize-x { position: absolute; top: 0; right: 0; bottom: 0; width: 7px; cursor: ew-resize; }
.plan-absence { padding: 1px 6px; border-radius: 4px; font-size: 11px; color: var(--muted); background: repeating-linear-gradient(135deg, #eceff3 0 4px, #f7f8fa 4px 8px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plan-month { display: grid; grid-template-columns: repeat(7, minmax(110px, 1fr)); min-width: 770px; user-select: none; }
.plan-day { display: flex; flex-direction: column; gap: 3px; min-height: 104px; padding: 4px; border-left: 1px solid var(--border); border-top: 1px solid var(--border); cursor: copy; min-width: 0; }
.plan-day.other { background: var(--surface-2); }
.plan-day.weekend { background: #f3f5f7; }
.plan-day.today .plan-daynum { background: var(--accent); color: #fff; border-radius: 10px; }
.plan-day .plan-daynum { color: var(--text); }
.plan-daynum { align-self: flex-start; padding: 0 6px; font-weight: 700; }
.plan-row { --brand: var(--accent); display: flex; gap: 14px; align-items: flex-start; width: 100%; padding: 10px 12px; text-align: left; background: var(--surface); border: 1px solid var(--border); border-left: 5px solid var(--brand); border-radius: var(--radius); cursor: pointer; }
.plan-row:hover { border-color: var(--brand); }
.plan-row-when { display: flex; flex-direction: column; min-width: 140px; }
.plan-row-main { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.plan-conflict-text { color: var(--danger); font-size: 12px; }
.plan-checklist { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.plan-fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.plan-mail-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border); }
.plan-suggestions { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; }
.plan-suggestion { --team: var(--accent); display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; text-align: left; background: var(--surface); border: 2px solid var(--border); border-left: 6px solid var(--team); border-radius: var(--radius); cursor: pointer; }
.plan-suggestion.active { border-color: var(--team); background: color-mix(in srgb, var(--team) 10%, var(--surface)); }
.plan-dates { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.plan-date { display: inline-flex; align-items: center; gap: 2px; }
.plan-colors { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.plan-color { width: 24px; height: 24px; border-radius: 50%; border: 2px solid transparent; cursor: pointer; }
.plan-color.active { border-color: var(--text); box-shadow: 0 0 0 2px var(--surface) inset; }
.my-planning { max-width: 720px; }
.my-day h2 { font-size: 15px; margin: 18px 0 8px; }
.my-card { --brand: var(--accent); display: flex; flex-direction: column; gap: 3px; width: 100%; margin-bottom: 8px; padding: 12px 14px; text-align: left; background: var(--surface); border: 1px solid var(--border); border-left: 6px solid var(--brand); border-radius: var(--radius); box-shadow: var(--shadow); cursor: pointer; font-size: 15px; }
.my-card.uitgevoerd { opacity: 0.65; }
.my-card-time { font-weight: 700; font-variant-numeric: tabular-nums; }
.my-card-title { font-weight: 600; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.my-when { display: flex; flex-direction: column; gap: 2px; font-size: 16px; }
.my-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.my-list { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; }
.my-photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.my-photo { padding: 0; border: 1px solid var(--border); border-radius: 6px; overflow: hidden; background: none; cursor: zoom-in; aspect-ratio: 1; }
.my-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.my-done { position: sticky; bottom: 0; padding: 12px 0; background: linear-gradient(transparent, var(--bg) 30%); }
.my-done-button { width: 100%; padding: 14px; font-size: 17px; }
@media (max-width: 900px) {
  .plan-title { flex: 1 1 100%; }
  .plan-toolbar .tabs { flex: 1 1 100%; }
  .plan-row { flex-direction: column; gap: 4px; }
  .my-buttons .btn { flex: 1 1 auto; text-align: center; }
}

/* ---------- meten (inmeten, legplan) ---------- */
.meten-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 16px; align-items: start; }
.meten-main, .meten-side { min-width: 0; }
.meten-map { height: calc(100vh - 290px); min-height: 360px; border-radius: var(--radius); border: 1px solid var(--border); background: #dfe3e8; }
.meten-mapwrap { position: relative; display: flex; flex-direction: column; gap: 8px; }
.meten-search { position: relative; display: flex; gap: 8px; }
.meten-search input { flex: 1; min-width: 0; }
.meten-places { position: absolute; z-index: 1000; top: 100%; left: 0; right: 0; margin: 2px 0 0; padding: 4px; list-style: none; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.meten-tools { flex-wrap: wrap; gap: 6px; align-items: center; }
.meten-label { pointer-events: none; }
.meten-label span { display: inline-block; transform: translate(-50%, -50%); white-space: nowrap; padding: 1px 5px; border-radius: 4px; background: rgba(0, 0, 0, 0.62); color: #fff; font: 600 12px/1.3 system-ui, sans-serif; }
.meten-label.meten-area span { font-size: 14px; background: rgba(27, 94, 32, 0.85); }
.meten-label.meten-side span { transform: translate(-50%, -150%); }
.meten-handle { width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 3px solid var(--accent); box-sizing: border-box; }
.meten-handle.active { background: var(--accent); }
.meten-handle.first { background: #ffeb3b; border-color: #1b5e20; }
.meten-plus { width: 18px; height: 18px; border-radius: 50%; background: rgba(255, 255, 255, 0.85); color: #1b5e20; font: 700 14px/18px system-ui, sans-serif; text-align: center; }
.meten-drawing { padding: 8px; overflow: hidden; }
.meten-svg { display: block; width: 100%; height: auto; max-height: 70vh; }
.meten-snapshot { display: block; width: 100%; border-radius: var(--radius); }
.meten-swatch { display: inline-block; width: 12px; height: 12px; border-radius: 3px; }
.meten-features tr { cursor: pointer; }
.meten-features tr.selected td, .meten-page tr.selected td { background: var(--accent-soft); }
.meten-features select, .meten-features input { width: 100%; margin-bottom: 4px; }
.meten-shape { border: 1px solid var(--border); border-radius: var(--radius); padding: 10px 12px; background: var(--surface); }
.meten-shape legend { font-weight: 600; padding: 0 4px; }
.meten-dims { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; margin: 8px 0; }
.meten-sides input, .meten-sides select { width: 100%; }
.meten-angle, .meten-angle-row { display: inline-flex; gap: 6px; align-items: center; }
.meten-angle input { width: 70px; }
.meten-angle-row { flex-wrap: wrap; }
.meten-rules input, .meten-rules select { width: 100%; min-width: 70px; }
.meten-rules td.narrow { width: 80px; }
@media (max-width: 1000px) {
  .meten-layout { grid-template-columns: 1fr; }
  .meten-map { height: 62vh; min-height: 300px; }
}
.my-legplan svg, .my-snapshot { width: 100%; height: auto; display: block; }
.my-snapshot { margin-top: 10px; border-radius: 6px; }

/* ---------- google (agenda zoals Google Agenda) ---------- */
.gcal-layout { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 14px; align-items: start; }
.gcal-main { min-width: 0; }
.gcal-side { display: flex; flex-direction: column; gap: 4px; position: sticky; top: 8px; font-size: 13px; }
.gcal-status { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 10px; margin-bottom: 6px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.gcal-head { margin: 10px 0 2px; font-size: 12px; font-weight: 600; text-transform: none; letter-spacing: 0; color: var(--muted); }
.gcal-cal { display: grid; grid-template-columns: 18px 1fr; column-gap: 8px; align-items: center; padding: 3px 4px; border-radius: 6px; cursor: pointer; }
.gcal-cal:hover { background: var(--surface-2); }
.gcal-cal input { appearance: none; width: 16px; height: 16px; margin: 0; border: 2px solid var(--cal); border-radius: 3px; cursor: pointer; }
.gcal-cal input:checked { background: var(--cal); box-shadow: inset 0 0 0 2px var(--surface); }
.gcal-cal input.striped:checked { background: repeating-linear-gradient(135deg, var(--cal) 0 3px, var(--surface) 3px 6px); }
.gcal-cal-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gcal-cal-sub { grid-column: 2; color: var(--muted); font-size: 11.5px; }
.gcal-note { margin-top: 10px; }
.gcal-swatch { display: inline-block; width: 11px; height: 11px; border-radius: 3px; background: var(--cal); vertical-align: -1px; }
.gcal-notices ul { margin: 6px 0 0; display: flex; flex-direction: column; gap: 6px; }
.gcal-notices li { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; justify-content: space-between; }
.gcal-notice-actions { display: inline-flex; gap: 6px; flex-wrap: wrap; }
.gcal-iteminfo { margin: 0 0 10px; }
.gcal-connect { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 10px; }
.gcal-help ol { padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }
.gcal-help summary { cursor: pointer; font-weight: 600; }
.gcal-now { position: absolute; left: 0; right: 0; height: 2px; background: #ea4335; z-index: 4; pointer-events: none; }
.gcal-now::before { content: ''; position: absolute; left: -5px; top: -4px; width: 10px; height: 10px; border-radius: 50%; background: #ea4335; }
/* Events als blokjes in de agendakleur, zoals in Google; het merk als label. */
.plan-item.gc, .plan-chip.gc { background: var(--team); color: var(--on-team, #fff); border-left: 4px solid color-mix(in srgb, var(--team) 70%, #000); }
.plan-item.gc .plan-item-sub, .plan-chip.gc .gc-chip-sub { color: inherit; opacity: 0.85; }
.plan-item.gc.uitgevoerd, .plan-chip.gc.uitgevoerd { opacity: 0.55; }
.plan-item.gc-gone, .plan-chip.gc-gone, .plan-row.gc-gone { outline: 2px dashed var(--danger); outline-offset: -2px; opacity: 0.7; }
.gc-tags { display: flex; flex-wrap: wrap; gap: 3px; }
.gc-tag { padding: 0 5px; border-radius: 3px; font-size: 11px; font-weight: 600; background: color-mix(in srgb, currentColor 16%, transparent); color: inherit; white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.plan-item.gc-ext, .plan-chip.gc-ext { --cal: #888; cursor: pointer; touch-action: auto; }
.gc-google { background: color-mix(in srgb, var(--cal) 82%, #fff); color: var(--on-cal, #fff); border-left: 4px solid var(--cal); }
.gc-google .plan-item-sub { color: inherit; opacity: 0.85; }
.gc-bezet { background: repeating-linear-gradient(135deg, #e3e6ea 0 6px, #f4f5f7 6px 12px); color: #3c4043; border-left: 4px solid var(--cal); }
.gc-bezet .plan-item-sub { color: var(--muted); }
.gc-free { opacity: 0.6; }
.plan-row.gc-row { border-left-color: var(--cal); }
.plan-row.gc-bezet { background: repeating-linear-gradient(135deg, #f1f2f4 0 6px, var(--surface) 6px 12px); }
@media (max-width: 900px) {
  .gcal-layout { grid-template-columns: 1fr; }
  .gcal-side { position: static; flex-direction: row; flex-wrap: wrap; gap: 4px 10px; }
  .gcal-status { flex-direction: row; flex-wrap: wrap; align-items: center; width: 100%; }
  .gcal-head, .gcal-note { display: none; }
  .gcal-cal-sub { display: none; }
}

/* ---------- stijl (Richting D): blokken van andere onderdelen in de nieuwe vorm ---------- */
/* Dashboard: grafiek niet hoger dan nodig, actietegels als rustige regels. */
.company-stats-head { padding-bottom: 8px; margin-bottom: 14px; }
.company-stats-head h2 { margin: 0; }
.results-chart svg { max-height: 300px; }
.results-chart .area { fill: rgba(46, 139, 62, 0.1); }
.action-tile { border-radius: var(--radius); padding: 10px 12px; }
.dashboard-tabs .bulk-row { padding-left: 4px; }
/* Merkknoppen (pijplijn, agenda, aanvragen): een rustige segmentkeuze in plaats van grote tegels. */
.brand-buttons { gap: 6px; margin-bottom: 14px; }
.brand-button { min-width: 0; padding: 5px 12px; gap: 8px; border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 13px; }
.brand-button.active { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 8%, var(--surface)); }
.brand-button .swatch { width: 10px; height: 10px; }
.brand-button .count { font-size: 12px; font-variant-numeric: tabular-nums; }
.job-card .brand-tag { border-left: 0; padding-left: 0; color: var(--muted); } /* kaart heeft de merkrand al */
/* Pijplijn */
.kanban-col { border-radius: var(--radius); }
.kanban-col header { font-size: 13px; padding: 8px 10px; }
.job-card { border-left-width: 3px; border-radius: var(--radius-sm); }
.phase-steps li { border-radius: 0; }
/* Agenda (Google-weergave): vlakke blokjes, geen arcering buiten de werktijden. */
.plan-scroll { border-radius: var(--radius); }
.plan-col { background: var(--surface-2); }
.plan-col.closed { background: #eceff3; }
.plan-colhead { font-size: 13px; font-weight: 600; }
.plan-item.gc, .plan-chip.gc { border-left: 0; border-radius: 4px; box-shadow: 0 0 0 1px var(--surface); }
.plan-item { box-shadow: 0 0 0 1px var(--surface); }
.plan-absence { background: var(--surface-3); }
.gcal-status { border-radius: var(--radius); }
/* Lijsten en tegels elders */
.roll-choice, .hst-qr-option, .cloud-option { border-radius: var(--radius); }
.my-card, .plan-row { border-radius: var(--radius); }
.quote-tip { border-radius: var(--radius); }
.task-view-card { border-radius: var(--radius); }
.segmented { border-radius: var(--radius); }
.segmented button.active { box-shadow: 0 0 0 1px var(--border); }
/* Werkbon op de telefoon (Richting D, scherm 4): grote raakvlakken, losse vakken op grijs. */
.my-buttons .btn { min-height: 44px; justify-content: center; }
.my-done-button { border-radius: 10px; font-weight: 600; justify-content: center; }
@media (max-width: 900px) {
  .page.my-planning { background: var(--bg); min-height: calc(100vh - 50px); padding: 12px 12px 24px; font-size: 15px; }
  .my-planning .card { background: var(--surface); border-radius: 12px; padding: 12px 14px; margin-bottom: 12px; }
  .my-planning .card > h2:first-child { margin: -12px -14px 10px; padding: 11px 14px 9px; border-bottom: 1px solid var(--hair); font-size: 14px; }
  .my-planning .page-header { margin-bottom: 12px; }
  .my-card { border: 0; border-left: 4px solid var(--brand); border-radius: 12px; }
  .my-done { padding: 12px 0 4px; }
}
/* Detailpagina's in één kolom: de kolom mag nooit breder worden dan het scherm. */
@media (max-width: 1280px) { .invoice-layout, .quote-layout { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 900px) {
  table.data.doc { display: block; overflow-x: auto; }
  .page-header .actions > .btn, .page > .toolbar > .btn { flex: 0 1 auto; }
  .dashboard-tabs .table-wrap { margin: 0 -16px; padding: 0 16px; }
  .results-chart svg { max-height: 200px; }
}
.meten-search input { border: 1px solid var(--border-strong); border-radius: var(--radius-sm); padding: 6px 10px; background: var(--surface); }

/* ---------- basis (stijlgids-correctielijst, docs/stijlgids.md) ---------- */

/* Kruimelpad in de balk bovenaan (VIS-11): onderdeel › subonderdeel › echte naam. */
.breadcrumb { display: flex; align-items: center; min-width: 0; overflow: hidden; white-space: nowrap; }
.breadcrumb .crumb { display: inline-flex; align-items: center; min-width: 0; }
.breadcrumb .crumb:last-child { overflow: hidden; }
.breadcrumb .crumb:last-child > span:last-child { overflow: hidden; text-overflow: ellipsis; }
.breadcrumb a { color: var(--muted); font-weight: 500; }
.breadcrumb a:hover { color: var(--text); text-decoration: none; }
.crumb-sep { color: var(--border-strong); margin: 0 7px; font-weight: 400; }

/* Uitklapmenu (Meer ▾ en ⋮): ligt vast in beeld, wordt niet afgeknipt door een scrollende tabel. */
.menu-wrap { position: relative; display: inline-flex; }
.menu-wrap .icon.caret { width: 14px; height: 14px; margin-right: -3px; }
.menu-pop {
  position: fixed; z-index: 70; min-width: 210px; max-width: min(320px, calc(100vw - 16px)); padding: 4px 0; background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg);
}
.menu-item {
  display: flex; align-items: center; gap: 9px; width: 100%; padding: 7px 14px; border: 0; background: none; font: inherit; font-size: 13.5px;
  color: var(--text); text-align: left; cursor: pointer; text-decoration: none; white-space: nowrap;
}
.menu-item:hover { background: var(--surface-2); text-decoration: none; }
.menu-item:disabled { opacity: 0.45; cursor: default; background: none; }
.menu-item .icon { width: 16px; height: 16px; color: var(--muted); }
.menu-icon-space { width: 16px; flex: none; }
.menu-item.danger, .menu-item.danger .icon { color: var(--danger); }
.menu-item.danger:hover { background: var(--danger-soft); }
.menu-sep { height: 1px; margin: 4px 0; background: var(--border); }

/* Documentkop: [hoofdknop][tweede][Meer ▾] (VIS-01) */
.action-bar { display: flex; align-items: center; gap: 8px; flex-wrap: nowrap; }
/* Rijacties: één ghost-knop + ⋮ (VIS-16) */
.row-actions { display: inline-flex; align-items: center; justify-content: flex-end; gap: 2px; }
.row-actions .btn.ghost { min-height: 28px; padding: 0 8px; font-weight: 600; color: var(--accent); }
.row-actions .btn.icon-only { width: 28px; min-height: 28px; color: var(--muted); }
td.row-actions-cell { width: 1%; white-space: nowrap; text-align: right; }

/* Filters: op een breed scherm gewoon naast elkaar in de werkbalk. */
.filters { display: contents; }
.filters-toggle { display: none; }
.filters-body { display: contents; }

/* Kleine hulpmiddelen */
.dt-icon { width: 14px; height: 14px; color: var(--muted); vertical-align: -2px; margin-right: 2px; }
.inline-icon .icon { width: 15px; height: 15px; vertical-align: -3px; }
.icon.caret-left { transform: rotate(90deg); width: 14px; height: 14px; }

/* Agenda: inklapbare legenda (VIS-02) */
.gcal-side-close { align-self: flex-start; color: var(--muted); padding: 0 6px 0 2px; margin-bottom: 2px; }
.gcal-layout.side-closed { grid-template-columns: 36px minmax(0, 1fr); gap: 8px; }
.gcal-side-open { width: 36px; min-height: 36px; padding: 0; position: sticky; top: 8px; color: var(--muted); border: 1px solid var(--border); }
.plan-chip { line-height: 18px; }

/*
 * Telefoon (<700px): tabellen met class "cards" worden kaartregels (VIS-05, stijlgids punt 15).
 * Regel 1: nummer (vet) + bedrag rechts; regel 2: klant + statuschip rechts; regel 3: meta.
 * Cellen zonder data-card verdwijnen. Vinkje links, rijacties rechtsboven.
 */
@media (max-width: 699px) {
  table.data.cards, table.data.cards tbody, table.data.cards tfoot { display: block; width: 100%; }
  .page > table.data.cards, .card > table.data.cards, .card-body > table.data.cards { overflow: visible; }
  table.data.cards thead { display: none; }
  table.data.cards tr {
    display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto;
    grid-template-areas: 'select title amount actions' 'select sub status actions' 'select meta meta actions';
    column-gap: 10px; row-gap: 2px; align-items: center; padding: 10px 2px; border-bottom: 1px solid var(--hair);
  }
  table.data.cards tbody tr:last-child { border-bottom: 0; }
  table.data.cards td { display: none; padding: 0 !important; border: 0; min-width: 0; }
  table.data.cards tr.clickable:hover td { background: none; }
  table.data.cards tr.clickable:active { background: var(--surface-2); }
  table.data.cards td[data-card] { display: block; }
  table.data.cards td[data-card='select'] { grid-area: select; align-self: start; padding-top: 2px !important; }
  table.data.cards td[data-card='title'] { grid-area: title; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  table.data.cards td[data-card='amount'] { grid-area: amount; text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
  table.data.cards td[data-card='sub'] { grid-area: sub; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  table.data.cards td[data-card='status'] { grid-area: status; justify-self: end; text-align: right; white-space: nowrap; }
  table.data.cards td[data-card='meta'] { grid-area: meta; color: var(--muted); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  table.data.cards td[data-card='actions'] { grid-area: actions; align-self: start; }
  /* Groepsregel ("Concept (3)") over de hele breedte */
  table.data.cards tr.group-row { display: block; padding: 12px 2px 6px; border-bottom: 1px solid var(--border); }
  table.data.cards tr.group-row td { display: block; background: none !important; font-weight: 600; }
  /* Filters achter één knop */
  .filters { display: block; width: 100%; }
  .filters-toggle { display: inline-flex; }
  .filters-body { display: none; }
  .filters.open .filters-body { display: flex; flex-direction: column; align-items: stretch; gap: 10px; margin-top: 10px; }
  .filters.open .filters-body > *, .filters.open .filters-body select, .filters.open .filters-body .input { width: 100%; }
  .filters-body .check { justify-content: space-between; }
}

/* Aanraakdoelen ≥ 44px onder 900px (MOB-13); invoer 16px tegen inzoomen. */
@media (max-width: 900px) {
  :root { --control-h: 44px; }
  .btn { padding: 0 14px; }
  .btn.small { min-height: 36px; padding: 0 10px; }
  .btn.link { min-height: 0; padding: 4px 0; }
  .row-actions .btn.ghost, .row-actions .btn.icon-only { min-height: 40px; }
  .row-actions .btn.icon-only { width: 40px; }
  .tabs button { min-height: 44px; }
  .nav a { min-height: 44px; }
  .field input:not([type='checkbox']):not([type='radio']), .field select, .field textarea, .input, table.lines input:not([type='checkbox']), table.lines select, .setting-control input:not([type='checkbox']):not([type='radio']), .setting-control select { min-height: 44px; font-size: 16px; padding-top: 9px; padding-bottom: 9px; }
  .menu-item { min-height: 44px; font-size: 15px; }
  .white-menu a { min-height: 44px; display: flex; align-items: center; }
  .action-bar { width: 100%; }
  .action-bar > .btn.primary { flex: 1 1 auto; }
  input[type='checkbox'], input[type='radio'] { width: 20px; height: 20px; }
  label.check { min-height: 44px; }
  .crumb:not(:last-child), .crumb .crumb-sep { display: none; }
}
.show-mobile { display: none; }
@media (max-width: 699px) { .show-mobile { display: inline; } .hide-phone { display: none !important; } }
.invoice-bulk label.check { white-space: nowrap; }

/* ---------- fix-documenten ---------- */

/* ActionBar op de telefoon: één hoofdknop, de tweede knop bovenaan in Meer (MOB-12). */
.phone-only { display: none !important; }
@media (max-width: 699px) {
  .menu-item.phone-only { display: flex !important; }
  .menu-wrap.phone-only { display: inline-flex !important; }
  .menu-sep.phone-only { display: block !important; }
}
/* Eén raster voor kenmerken (VIS-26): labelkolom 140px, waarde ernaast. */
dl.props, .quote-props { grid-template-columns: 140px minmax(0, 1fr); gap: 6px 16px; align-items: baseline; }
@media (max-width: 699px) { dl.props, .quote-props { grid-template-columns: 112px minmax(0, 1fr); } }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
/* Snelfilters boven het factuuroverzicht (UX-08) */
.quick-filters { flex-wrap: nowrap; overflow-x: auto; margin: 0 0 12px; }
.quick-filters button { white-space: nowrap; }
.quick-filters .count { margin-left: 6px; color: var(--muted); font-weight: 500; font-variant-numeric: tabular-nums; }
.quick-filters button.late .count { color: var(--danger); }
.late-text { color: var(--danger); }
/* Offerte- en factuurregels op de telefoon als lijst: omschrijving, aantal × prijs, bedrag (MOB-12). */
@media (max-width: 699px) {
  table.data.doc-lines td[data-card='title'] { white-space: pre-wrap; overflow: visible; font-weight: 500; }
  table.data.doc-lines td[data-card='sub'] { color: var(--muted); font-size: 13px; }
}
/* Offertelijst en inkoop: één tabel met groepsregels (VIS-13) en één bulkbalk erboven. */
table.data.quote-table { table-layout: fixed; }
table.data.quote-table td.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
table.data tr.quote-group-row td { background: var(--surface-2); padding-top: 9px; padding-bottom: 9px; }
tr.quote-group-row .group-title { font-size: 13px; font-weight: 600; }
tr.quote-group-row .group-total { float: right; font-size: 12.5px; font-weight: 400; font-variant-numeric: tabular-nums; }
.bulk-bar { display: flex; align-items: center; gap: 12px; margin: 0 0 8px; }
@media (max-width: 699px) {
  table.data.quote-table { table-layout: auto; }
  tr.quote-group-row .group-total { float: none; display: block; margin-top: 2px; }
}
/* Regeleditor (VIS-15): 40px per regel, sleepgreep, ⋯ en × zonder rand. */
.invoice-lines td { padding: 4px; vertical-align: top; }
.invoice-lines textarea { display: block; height: var(--control-h); min-height: var(--control-h); padding: 6px 8px; line-height: 18px; resize: vertical; border-color: var(--border-strong); border-radius: var(--radius-xs); }
.invoice-lines th.line-grip-col, .invoice-lines td.line-grip { width: 22px; padding-left: 0; padding-right: 0; }
.invoice-lines .grip { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: var(--control-h); border: 0; background: none; padding: 0; color: var(--muted); cursor: grab; opacity: 0.45; }
.invoice-lines tr:hover .grip, .invoice-lines .grip:focus-visible { opacity: 1; }
.invoice-lines .grip .icon { width: 16px; height: 16px; }
.invoice-lines tr.dragging td { opacity: 0.5; }
.invoice-lines td.total { padding-top: 10px; white-space: nowrap; }
.invoice-lines td.line-tools { white-space: nowrap; text-align: right; }
.invoice-lines .line-tools .btn.icon-only { width: 28px; min-height: var(--control-h); padding: 0; }
.line-remove { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: var(--control-h); border: 0; border-radius: var(--radius-xs); background: none; color: var(--muted); cursor: pointer; vertical-align: top; }
.line-remove:hover { color: var(--danger); background: var(--danger-soft); }
.line-remove .icon { width: 14px; height: 14px; }
.line-extras { margin-top: 3px; display: flex; flex-wrap: wrap; align-items: center; gap: 0 4px; }
.line-extras .line-discount input { width: 56px !important; min-height: 26px !important; padding: 2px 6px !important; }
.product-code { position: relative; }
.product-code .suggest-list { min-width: 280px; right: auto; }
@media (max-width: 699px) { table.data.cards td[data-card='sub'].num, table.data.cards td[data-card='meta'].num { text-align: left; } }
/* Grafieken (VIS-20): geen vlak, reeks 1 accentblauw, reeks 2 grijze stippellijn, assen 11px grijs; negatief rood met echt minteken. */
.negative { color: var(--danger); }
.line-chart .legend { font-size: 12px; color: var(--muted); }
.line-chart .legend i { width: 16px; height: 0; border-radius: 0; border-top: 2px solid; vertical-align: middle; background: none !important; }
.line-chart .legend i.dashed { border-top-style: dashed; }
.results-chart text { font-size: 16px; }
.results-chart .area, .results-chart .area { fill: none; }
.results-chart .current { stroke: var(--accent); stroke-width: 2.5; }
.results-chart .previous { stroke: var(--muted); }
.chart-legend span::before { border-top-color: var(--accent); }
.chart-legend .previous::before { border-top-color: var(--muted); }
.results-chart figcaption .info-dot { border-width: 1.2px; font-weight: 600; background: none; }
/* E-mailbericht zonder HTML typen (VIS-23): opmaakbalk boven een bewerkbaar vlak. */
.rich-message { border: 1px solid var(--border-strong); border-radius: var(--radius-sm); background: var(--surface); }
.rich-message:focus-within { border-color: var(--accent); }
.rich-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; padding: 4px 6px; border-bottom: 1px solid var(--border); background: var(--surface-2); border-radius: var(--radius-sm) var(--radius-sm) 0 0; }
.rich-toolbar .btn.ghost { min-height: 28px; padding: 0 8px; font-weight: 500; color: var(--text); }
.rich-toolbar .btn.icon-only { width: 28px; padding: 0; justify-content: center; }
.rich-toolbar .btn .icon { width: 14px; height: 14px; }
.rich-toolbar select.input.compact { min-height: 28px; max-width: 200px; }
.rich-box { min-height: 220px; max-height: 480px; overflow-y: auto; padding: 10px 12px; line-height: 1.55; outline: none; white-space: pre-wrap; overflow-wrap: anywhere; }
.rich-message.disabled .rich-toolbar { display: none; }
.msg-chip { display: inline-block; padding: 0 6px; margin: 0 1px; border-radius: 3px; background: var(--accent-soft); color: var(--accent); font-size: 12.5px; line-height: 20px; white-space: nowrap; user-select: all; }
/* ---------- fix-indeling ---------- */
/* Veldfouten bij het veld (UX-22). */
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: var(--danger); box-shadow: 0 0 0 1px var(--danger); }
.field-error { color: var(--danger); font-size: 12px; line-height: 16px; font-weight: 500; }
.field-required { color: var(--danger); font-weight: 600; }

/* ---------- fix-indeling: inlogscherm (VIS-22) ---------- */
/* Geen los wit kaartje meer: links een merkvlak in de zijbalkkleur, rechts het formulier op de gewone achtergrond; op de telefoon boven elkaar. */
.login { min-height: 100%; display: grid; grid-template-columns: minmax(240px, 34%) 1fr; padding: 0; align-items: stretch; justify-content: stretch; background: var(--surface); }
.login-brand { background: var(--sidebar); color: var(--sidebar-text); display: flex; align-items: flex-start; gap: 12px; padding: 28px 28px; }
.login-brand .brand-mark { width: 32px; height: 32px; font-size: 14px; }
.login-brand-text b { display: block; color: #fff; font-weight: 600; font-size: 15px; line-height: 20px; }
.login-brand-text small { display: block; font-size: 12px; line-height: 16px; opacity: 0.7; }
.login-main { display: flex; align-items: center; justify-content: center; padding: 32px 16px; }
.login-panel { width: min(380px, 100%); }
.login-form h1 { font-size: 20px; line-height: 26px; margin: 0 0 24px; }
.login-form .login-intro { margin: -16px 0 24px; }
.login-form .login-error { margin: 16px 0 0; }
.login-form .login-submit { margin-top: 20px; }
.login-remember { min-height: 32px; cursor: pointer; }
@media (max-width: 899px) {
  .login { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
  .login-brand { padding: 16px; align-items: center; }
  .login-main { align-items: flex-start; padding: 24px 16px; }
  .login-remember { min-height: 44px; }
}

/* ---------- fix-indeling: globale zoekfunctie (UX-03) ---------- */
/* Eén rustige lijst onder het zoekveld in de kopbalk, zoals de bestaande uitklapmenu's. */
.global-search { position: relative; }
.global-search-list {
  position: absolute; top: calc(100% + 6px); right: 0; z-index: 60; width: 26rem; max-width: calc(100vw - 32px); max-height: min(70vh, 560px); overflow-y: auto;
  padding: 4px 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg); color: var(--text);
}
.global-search-head { padding: 8px 14px 3px; font-size: 12px; line-height: 16px; font-weight: 600; color: var(--muted); }
.global-search-head span { font-weight: 400; text-transform: none; }
.global-search-item, .global-search-all { display: block; padding: 6px 14px; color: var(--text); text-decoration: none; }
.global-search-item:hover, .global-search-all:hover { text-decoration: none; }
.global-search-item.active, .global-search-all.active { background: var(--surface-2); }
.global-search-title { display: block; font-size: 13.5px; line-height: 18px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.global-search-sub { display: block; font-size: 12px; line-height: 16px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.global-search-note { padding: 8px 14px; font-size: 13px; color: var(--muted); }
.global-search-all { margin-top: 4px; border-top: 1px solid var(--border); padding-top: 8px; font-size: 13px; color: var(--accent); }
/* Resultatenpagina: per onderdeel een kop met aantal en compacte regels. */
.search-groups { display: grid; gap: 20px; max-width: 960px; }
.search-group-head { margin: 0 0 6px; font-size: 13px; font-weight: 600; }
.search-list { list-style: none; margin: 0; padding: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.search-list li + li { border-top: 1px solid var(--hair); }
.search-list a { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 2fr) minmax(0, 1.4fr); gap: 12px; align-items: baseline; padding: 8px 14px; color: var(--text); text-decoration: none; }
.search-list a:hover { background: var(--surface-2); text-decoration: none; }
.search-list-title { font-weight: 500; color: var(--accent); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-list-sub, .search-list-meta { font-size: 12.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-list-meta { text-align: right; }
.search-group-more { margin: 6px 0 0; font-size: 12.5px; }
@media (max-width: 699px) {
  .search-page-form .input { min-width: 0; flex: 1; }
  .search-list a { grid-template-columns: 1fr; gap: 1px; padding: 10px 14px; min-height: 44px; }
  .search-list-meta { text-align: left; }
}

/* Instellingen in één laag (UX-11, VIS-24): vaste linkerkolom zonder kader, met kopjes. */
.settings-page > .settings-shell { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 24px; align-items: start; }
.settings-nav { position: sticky; top: 0; max-height: calc(100vh - 90px); overflow-y: auto; display: flex; flex-direction: column; gap: 14px; padding-top: 2px; }
.settings-nav-head { font-size: 12px; line-height: 16px; font-weight: 600; color: var(--muted); padding: 0 10px 4px; }
.settings-nav a { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 5px 10px; border-radius: var(--radius-sm); color: var(--text); text-decoration: none; font-size: 13.5px; line-height: 20px; }
.settings-nav a:hover { background: var(--surface-2); text-decoration: none; }
.settings-nav a.active { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.settings-main { min-width: 0; }
.settings-main > .page, .settings-main .page { padding: 0; max-width: none; }
.settings-back { display: none; }
@media (max-width: 900px) {
  .settings-page > .settings-shell { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .settings-shell:not(.is-index) > .settings-nav { display: none; }
  .settings-shell.is-index > .settings-main { display: none; }
  .settings-nav { position: static; gap: 18px; }
  .settings-nav a { min-height: 44px; font-size: 15px; border-bottom: 1px solid var(--border); border-radius: 0; }
  .settings-back { display: inline-flex; align-items: center; gap: 4px; min-height: 40px; margin: -6px 0 6px; color: var(--muted); font-size: 14px; }
  .settings-back .icon { width: 16px; height: 16px; }
}

/* "+ Nieuw" in de kopbalk (UX-20). */
.appbar-new { flex: none; }
.appbar-new .btn .icon { width: 15px; height: 15px; }
@media (max-width: 900px) {
  .appbar-new .btn { font-size: 0; gap: 0; width: 44px; padding: 0; justify-content: center; border: 0; background: none; }
  .appbar-new .btn .icon { width: 21px; height: 21px; }
  .appbar-new .btn .caret { display: none; }
}

/* Sneltoetsen-overzicht (UX-25). */
.shortcut-table { border-collapse: collapse; width: 100%; }
.shortcut-table td { padding: 6px 8px 6px 0; vertical-align: middle; }
.shortcut-table td:first-child { width: 90px; white-space: nowrap; }
kbd { display: inline-block; min-width: 22px; padding: 1px 6px; margin-right: 4px; border: 1px solid var(--border); border-bottom-width: 2px; border-radius: 4px; background: var(--surface-2); font: 600 12px/18px var(--font); text-align: center; color: var(--text); }

/* Onderbalk voor de buitendienst op de telefoon (MOB-06). */
.tabbar { display: none; }
@media (max-width: 900px) {
  .has-tabbar .tabbar {
    display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 18;
    background: var(--surface); border-top: 1px solid var(--border); padding-bottom: env(safe-area-inset-bottom);
  }
  .tabbar a, .tabbar button {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 56px;
    background: none; border: 0; color: var(--muted); font: 500 12px/16px var(--font); text-decoration: none; cursor: pointer;
  }
  .tabbar .icon { width: 22px; height: 22px; }
  .tabbar a.active { color: var(--accent); }
  .has-tabbar .scroll { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
  .has-tabbar .toasts { bottom: 72px; }
}

/* ---------- fix-indeling: afzenders per merk (UX-12) ---------- */
.brand-senders fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.sent-as { margin-top: 4px; font-weight: 400; }
.brand-senders-kinds { margin-top: 12px; }
.brand-senders-kinds summary { cursor: pointer; font-weight: 600; padding: 4px 0; }
.brand-senders-table td { vertical-align: top; }
.brand-senders-table .input { min-width: 150px; }
.brand-senders-list { margin: 4px 0 0; padding-left: 18px; }
.brand-senders-list .btn.link { margin-left: 8px; }
.mail-senders-moved { margin: 0 0 8px; }

/* ---------- fix-indeling: medewerkers en rollen (UX-13/14) ---------- */
.role-list { display: grid; gap: 2px; }
.role-option { align-items: flex-start; padding: 4px 0; }
.role-option input { margin-top: 3px; }
.role-rights details { margin-top: 8px; }
.role-rights summary { cursor: pointer; color: var(--accent); padding: 4px 0; }

/* ---------- fix-pwa: offline-balk, nieuwe versie, onthoud mij, meldingen op mobiel (MOB-03/04/07) ---------- */
.netbar { flex: none; display: flex; align-items: center; gap: 10px; min-height: 36px; padding: 6px 28px; font-size: 13px; font-weight: 600; color: #fff; background: var(--frame); }
.netbar.offline { background: var(--warning); }
.netbar.update { background: var(--accent); }
.netbar-dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; opacity: 0.85; flex: none; }
.netbar.sending .netbar-dot { animation: netbar-pulse 1.2s ease-in-out infinite; }
.netbar-text { min-width: 0; flex: 1; }
.netbar-action { flex: none; min-height: 32px; padding: 0 12px; border: 1px solid rgba(255, 255, 255, 0.6); border-radius: var(--radius-sm); background: transparent; color: inherit; font: inherit; cursor: pointer; }
.netbar-action:hover { background: rgba(255, 255, 255, 0.12); }
@keyframes netbar-pulse { 50% { opacity: 0.3; } }
.check.remember { gap: 12px; min-height: 48px; padding: 6px 10px; margin: 0 -10px; border-radius: var(--radius-sm); cursor: pointer; }
.check.remember:hover { background: var(--surface-2); }
.check.remember input { width: 22px; height: 22px; flex: none; margin: 0; accent-color: var(--accent); }
.check.remember span { display: flex; flex-direction: column; line-height: 1.3; }
.check.remember small { font-size: 12px; }
@media (max-width: 900px) {
  .netbar { padding: 6px 16px; }
  /* Meldingen bovenaan, onder de kopbalk: niet over de vaste knoppen onderin (Klaar, Opslaan). */
  .toasts { top: 60px; bottom: auto; }
}
/* Veldfouten in de kenmerkenlijst en klantkeuze van offerte/factuur (UX-22). */
dd.invalid input, dd.invalid select, .hrow[data-field] .hcontrol:has(.field-error) input { border-color: var(--danger); box-shadow: 0 0 0 1px var(--danger); }
dd .field-error, .hcontrol .field-error, .discount-box .field-error { display: block; margin-top: 3px; }


/* ---------- fix-keten ---------- */
/* "Vraagt om actie": een klaargezet bericht opent een dialoog (knop met de vorm van een actieregel). */
.action-button { display: block; width: 100%; padding: 0; border: 0; background: none; text-align: left; font: inherit; color: inherit; cursor: pointer; }
.action-button:hover .action-row { background: var(--hover, rgba(0, 0, 0, 0.03)); }
/* Afronden/reserveringen: per regel wat er gebeurt. */
.choice-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 6px 0; border-bottom: 1px solid var(--border); }
.choice-row select { width: auto; max-width: 60%; }
.group-title { font-size: 13px; font-weight: 600; color: var(--muted); margin: 0 0 4px; }
/* ---------- fix-buitendienst (MOB-01/05/08/09/10/11/14/16/18, KET-07/08) ---------- */
/* Buitendienst: leesbaar buiten, minstens 15px tekst en 13px voor de grijze regels. */
.my-planning { font-size: 15px; }
.my-meta { color: var(--muted); font-size: 13px; }
.my-card > .my-meta, .my-when > .my-meta, .my-today-items .my-meta + .my-meta { display: block; }
.my-day.today h2 { color: var(--text); }
.my-empty { cursor: default; color: var(--muted); border-left-color: var(--border-strong); }
.my-count { float: right; font-weight: 500; font-size: 13px; color: var(--muted); }
.my-days { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.my-daypill { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border: 1px solid var(--border-strong); border-radius: 3px; font-size: 13px; }
.my-daypill .icon { width: 14px; height: 14px; }
.my-daypill.done { color: var(--success); border-color: currentColor; }
.my-daypill.now { font-weight: 600; }
.my-list.plain { list-style: none; padding: 0; margin-top: 10px; }
.my-m2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: 8px; margin-bottom: 10px; padding: 8px 0; border-bottom: 1px solid var(--hair); }
.my-m2 > div { display: flex; flex-direction: column; }
.my-m2 b { font-size: 18px; font-variant-numeric: tabular-nums; }
.my-pack { list-style: none; margin: 0; padding: 0; }
.my-pack > li { border-bottom: 1px solid var(--hair); padding: 2px 0; }
.my-pack > li:last-child { border-bottom: 0; }
.my-pack > li.checked .my-check > span { color: var(--muted); text-decoration: line-through; }
.my-check { display: flex; gap: 12px; align-items: flex-start; min-height: 44px; padding: 10px 0; cursor: pointer; }
.my-check input { width: 22px; height: 22px; flex: none; margin: 1px 0 0; }
.my-pieces { list-style: none; margin: -4px 0 8px 34px; padding: 0; font-size: 14px; }
.my-pieces li::before { content: '– '; color: var(--muted); }
.my-legplan { display: block; width: 100%; padding: 0; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); cursor: zoom-in; margin-bottom: 8px; }
.my-legplan svg { display: block; width: 100%; height: auto; }
.my-preview { max-width: 100%; max-height: 50vh; display: block; margin: 0 auto; border-radius: var(--radius); }
.my-done-note { padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--muted); font-size: 14px; text-align: center; }
.btn.block { width: 100%; justify-content: center; }
/* Uren */
.my-clock .my-buttons { margin-top: 8px; }
.my-running { margin: 0; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.my-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--success); }
.my-who { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 10px; }
.my-whochip { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 10px; border: 1px solid var(--border-strong); border-radius: var(--radius); cursor: pointer; font-size: 14px; }
.my-whochip.on { border-color: var(--accent); color: var(--accent); }
.my-whochip input { width: 18px; height: 18px; margin: 0; }
.my-today-items { list-style: none; margin: 12px 0 0; padding: 0; }
.my-today-items li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--hair); }
.my-travel { display: flex; gap: 8px; align-items: flex-end; margin-top: 12px; }
.my-travel .field { flex: 1; margin: 0; }
.my-weeknav { flex-wrap: wrap; gap: 8px; }
.my-hours-day h3 { display: flex; justify-content: space-between; font-size: 14px; margin: 14px 0 6px; }
.my-hours-day h3 > span:first-child::first-letter { text-transform: uppercase; }
.my-entry { display: grid; grid-template-columns: 96px 1fr auto; gap: 10px; align-items: baseline; width: 100%; min-height: 44px; padding: 8px 12px; margin-bottom: 4px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); text-align: left; font: inherit; color: var(--text); cursor: pointer; }
.my-entry:disabled { cursor: default; }
.my-entry-time, .my-entry-sum { font-variant-numeric: tabular-nums; }
.my-entry-sum { font-weight: 600; }
.my-tag { margin-left: 6px; padding: 0 6px; border: 1px solid var(--warning); border-radius: 3px; color: var(--warning); font-size: 12px; }
.hours-table td.num { white-space: nowrap; }
.hours-detail td { background: var(--surface-2); }
.hours-entries { list-style: none; margin: 0; padding: 0; }
.hours-entries li { display: grid; grid-template-columns: 100px 170px 1fr 60px; gap: 10px; padding: 4px 0; }
.hours-bottom { margin-top: 16px; align-items: start; }
/* Schermvullend bekijken (foto's, legplan) */
.lightbox { position: fixed; inset: 0; z-index: 2000; background: #0d1117; color: #fff; display: flex; flex-direction: column; }
.lightbox-bar { display: flex; align-items: center; gap: 4px; padding: 4px 4px 4px 14px; padding-top: max(4px, env(safe-area-inset-top)); }
.lightbox-title { flex: 1; font-weight: 600; font-size: 15px; }
.lightbox-btn { width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center; background: none; border: 0; color: #fff; cursor: pointer; }
.lightbox-btn .icon { width: 22px; height: 22px; }
.lightbox-stage { flex: 1; overflow: hidden; touch-action: none; display: flex; align-items: center; justify-content: center; }
.lightbox-content { transform-origin: center; max-width: 100%; max-height: 100%; display: flex; }
.lightbox-content img { max-width: 100vw; max-height: calc(100vh - 100px); object-fit: contain; user-select: none; -webkit-user-drag: none; }
.lightbox-html { background: #fff; width: min(100vw, 1100px); }
.lightbox-html svg { display: block; width: 100%; height: auto; max-height: calc(100vh - 100px); }
.lightbox-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 64px; background: rgba(0, 0, 0, 0.35); color: #fff; border: 0; font-size: 32px; cursor: pointer; }
.lightbox-nav.prev { left: 0; }
.lightbox-nav.next { right: 0; }
.lightbox-caption { padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); font-size: 14px; color: #d0d7de; }
/* Scannen en afsnijden */
.roll-scan .roll-type input.roll-id { min-height: 52px; font-size: 20px; font-weight: 600; letter-spacing: 0.5px; }
.roll-torch { position: absolute; right: 10px; bottom: 10px; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px; border: 0; border-radius: var(--radius); background: rgba(0, 0, 0, 0.55); color: #fff; font: 600 14px/1 var(--font); cursor: pointer; }
.roll-torch.on { background: #fff; color: #000; }
.undo-bar { position: fixed; left: 12px; right: 12px; bottom: 16px; z-index: 30; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; max-width: 620px; margin: 0 auto; padding: 10px 12px; background: var(--frame); color: #fff; border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.undo-text { flex: 1 1 100%; font-weight: 600; }
.undo-bar .btn { background: transparent; color: #fff; border-color: rgba(255, 255, 255, 0.4); }
.pick-job { margin-bottom: 18px; }
.pick-job h2 { font-size: 15px; margin: 0 0 6px; }
.pick-time { margin-right: 8px; font-variant-numeric: tabular-nums; }
.pick-done { display: flex; align-items: center; gap: 6px; }
.pick-done .icon { width: 14px; height: 14px; color: var(--success); }
@media print {
  .pick-list .page-header .actions, .undo-bar, .tabbar { display: none !important; }
  .pick-table th, .pick-table td { font-size: 12px; padding: 4px 6px; }
}
/* Meten op de telefoon: grote aanraakvlakken, vergrootglas, vaste onderbalk */
.meten-mapbox { position: relative; isolation: isolate; }
.meten-handle, .meten-plus { background: transparent; border: 0; }
.meten-handle::after { content: ''; position: absolute; left: 13px; top: 13px; width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 3px solid var(--accent); box-sizing: border-box; }
.meten-handle.active::after { background: var(--accent); }
.meten-handle.first::after { background: #ffeb3b; border-color: #1b5e20; }
.meten-plus span { position: absolute; left: 11px; top: 11px; width: 22px; height: 22px; border-radius: 50%; background: rgba(255, 255, 255, 0.9); color: #1b5e20; font: 700 16px/22px system-ui, sans-serif; text-align: center; }
.meten-loupe { position: absolute; top: 10px; left: 10px; z-index: 1000; width: 130px; height: 130px; border-radius: 50%; overflow: hidden; border: 3px solid #fff; box-shadow: var(--shadow-lg); opacity: 0; pointer-events: none; transition: opacity 0.1s; }
.meten-loupe.on { opacity: 1; }
.meten-loupe-map { width: 100%; height: 100%; }
.meten-loupe-cross { position: absolute; left: 50%; top: 50%; z-index: 500; width: 18px; height: 18px; margin: -9px 0 0 -9px; border: 2px solid #ffeb3b; border-radius: 50%; }
.meten-mapbox.locked .meten-map { outline: 2px solid var(--accent-ring); }
.meten-map, .meten-loupe-map { overflow: hidden; contain: paint; }
.meten-bottombar { display: none; }
@media (max-width: 900px) {
  .my-planning .page-header h1 { display: none; }
  .has-tabbar .my-done { bottom: calc(56px + env(safe-area-inset-bottom)); }
  .has-tabbar .undo-bar { bottom: calc(68px + env(safe-area-inset-bottom)); }
  .my-entry { grid-template-columns: 84px 1fr auto; }
  .hours-entries li { grid-template-columns: 1fr auto; }
  .meten-page .page-header .actions .btn.primary { display: none; }
  .meten-bottombar { display: flex; position: sticky; bottom: 0; z-index: 15; align-items: center; justify-content: space-between; gap: 12px; margin: 8px -12px 0; padding: 10px 12px calc(10px + env(safe-area-inset-bottom)); background: var(--surface); border-top: 1px solid var(--border); }
  .has-tabbar .meten-bottombar { bottom: calc(56px + env(safe-area-inset-bottom)); }
  .meten-bottombar b { font-size: 20px; font-variant-numeric: tabular-nums; }
  .meten-bottombar .btn { min-width: 120px; }
  .meten-map { height: 55vh; }
}
.pick-list .page-header .actions { flex-wrap: wrap; align-items: center; justify-content: flex-end; }
.pick-list .page-header .actions .input { width: 170px; }

/* ---------- HER-V: second layout/visual audit ---------- */
details.fold > summary { cursor: pointer; color: var(--accent); white-space: nowrap; list-style-position: inside; }
details.fold[open] > summary { margin-bottom: 4px; }
/* HER-V-03: secondary columns give way inside the settings shell on a laptop screen. */
@media (max-width: 1499px) { .hide-narrow { display: none; } }
table.meten-rules { table-layout: fixed; min-width: 860px; }
table.meten-rules input, table.meten-rules select { min-width: 0; }
table.meten-rules td > select + input { margin-top: 4px; }
.action-group { background: var(--surface-2); border-bottom: 1px solid var(--hair); }
.action-group .action-row { padding-left: 40px; }
.neg { color: var(--danger); }
.duo > .stack > .card { margin-bottom: 0; }
/* VIS-12: section headings never larger than the page title (h1 20/26): h2 15/22, h3 13/18. */
.page h2 { font-size: 15px; line-height: 22px; font-weight: 600; }
.page h3 { font-size: 13px; line-height: 18px; font-weight: 600; }
/* HER-V-06: "Meer" status tab of the invoice list; its menu items keep the menu look inside the tab bar. */
.tabs button.tab-more { display: inline-flex; align-items: center; gap: 4px; }
.tabs .menu-pop .menu-item { padding: 7px 14px; margin: 0; border: 0; font-weight: 400; color: var(--text); }
/* VIS-22: the company logo from the standard house style on the login panel, on a light plate so its own colours stay true. */
.login-brand { flex-direction: column; }
.login-logo { display: inline-flex; align-items: center; padding: 10px 14px; background: #fff; border-radius: var(--radius); }
.login-logo img { display: block; max-width: 200px; max-height: 64px; object-fit: contain; }
@media (max-width: 699px) { .login-brand { flex-direction: row; } .login-logo img { max-width: 120px; max-height: 36px; } }
/* HER-V-08: tabular figures only where numbers line up (.num amount columns, key figures), not on all text: hyphens in dates and numbers stay narrow. */
.kpi-value { font-variant-numeric: tabular-nums; }
/* UX-11: only the menu scrolls; the user menu at the bottom always stays in view, also with a submenu open. */
.sidebar { overflow: hidden; }
.sidebar > .nav:not(.nav-bottom) { flex: 1 1 auto; min-height: 0; overflow-y: auto; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, 0.15) transparent; }
.sidebar > .nav-bottom { flex: none; }
