/* ==========================================================================
   ASK Dashboard – centraal stijlsysteem (november 2026)

   Dit bestand wordt als LAATSTE stylesheet in de <head> geladen.
   1. Tokens: alle kleuren, maten, typografie en schaduwen als CSS-variabelen.
      De andere CSS-bestanden (dashboard.css, planning.css, clients.css, …)
      verwijzen naar deze variabelen in plaats van naar vaste kleuren.
   2. Gedeelde onderdelen: shell (sidebar/topbalk), knoppen, formulieren,
      panelen, tabellen, pills, meldingen, KPI-kaarten.
   Spacing volgt een 8px-grid (4px als halve stap).
   ========================================================================== */

/* ------------------------------------------------------------ 1. Tokens */
:root {
  /* Merk – blauw uit het ASK-logo */
  --accent: #0b50b4;
  --accent-hover: #09439a;
  --accent-subtle: #edf3fc;
  --accent-border: #c9daf5;

  /* Neutralen */
  --bg: #f7f8fa;
  --surface: #ffffff;
  --surface-muted: #f9fafb;
  --surface-hover: #f3f4f6;
  --neutral-subtle: #f1f3f6;
  --border: #e6e8ec;
  --border-soft: #f0f1f4;
  --border-strong: #d5d9e0;
  --text: #111827;
  --text-2: #4b5563;
  --text-3: #6b7280;
  --text-4: #9ca3af;

  /* Betekenis – alleen gebruiken als het iets betekent */
  --danger: #c6312b;
  --danger-text: #b42318;
  --danger-subtle: #fef1f0;
  --danger-border: #f7cdc9;
  --warning: #d97706;
  --warning-text: #92400e;
  --warning-subtle: #fffbeb;
  --warning-border: #fde68a;
  --success: #15803d;
  --success-subtle: #ecfdf3;
  --success-border: #bbf0cf;
  --purple: #6d28d9;
  --purple-subtle: #f5f3ff;

  /* Soorten actie (als klein stipje in een pill) */
  --kind-processing: #0b50b4;
  --kind-completeness: #d97706;
  --kind-documents: #ca8a04;
  --kind-review: #7c3aed;
  --kind-publication: #16a34a;

  /* Sidebar (donker) */
  --sb-bg: #0f1b2d;
  --sb-text: #c7d0dc;
  --sb-icon: #8a99ad;
  --sb-label: #66768c;
  --sb-hover: rgba(255, 255, 255, .06);
  --sb-active-bg: rgba(255, 255, 255, .10);
  --sb-active-text: #ffffff;
  --sb-indicator: #6ea8ff;

  /* Spacing (8px-grid) */
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px;
  --s-5: 24px; --s-6: 32px; --s-7: 40px; --s-8: 48px;

  /* Vorm */
  --radius-sm: 6px;
  --radius: 8px;
  --radius-lg: 12px;
  --shadow-xs: 0 1px 2px rgba(16, 24, 40, .05);
  --shadow-sm: 0 1px 3px rgba(16, 24, 40, .06), 0 1px 2px rgba(16, 24, 40, .04);
  --shadow-pop: 0 12px 32px rgba(16, 24, 40, .12), 0 2px 6px rgba(16, 24, 40, .06);
  --ring: 0 0 0 3px rgba(11, 80, 180, .22);

  /* Typografie */
  --font: "Inter", "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
  --fs-xs: .75rem;     /* 12px */
  --fs-sm: .8125rem;   /* 13px */
  --fs-base: .875rem;  /* 14px */
  --fs-md: .9375rem;   /* 15px */
  --fs-lg: 1.125rem;   /* 18px */
  --fs-xl: 1.5rem;     /* 24px */
  --fs-kpi: 1.75rem;   /* 28px */

  /* Layout */
  --sidebar-w: 240px;
  --topbar-h: 56px;

  /* Oude variabelen uit dashboard.css / ui-2026.css laten meeliften */
  --navy: #0f1b2d;
  --blue: var(--accent);
  --line: var(--border);
  --ink: var(--text);
  --muted: var(--text-3);
  --late: var(--danger-text);
  --late-bg: var(--danger-subtle);
  --today: var(--accent);
  --today-bg: var(--accent-subtle);
  --week: var(--text-2);
  --week-bg: var(--neutral-subtle);
  --ok: var(--success);
  --ok-bg: var(--success-subtle);
  /* planning.css */
  --purple-bg: var(--purple-subtle);
  --purple-ink: var(--purple);
  --green-bg: var(--success-subtle);
  --green-ink: var(--success);
  --red-bg: var(--danger-subtle);
  --red-ink: var(--danger-text);

  font-family: var(--font);
  font-size: 16px;
  color: var(--text);
  background: var(--bg);
}
#capacity-planning {
  --purple-bg: var(--purple-subtle); --purple-ink: var(--purple);
  --green-bg: var(--success-subtle); --green-ink: var(--success);
  --red-bg: var(--danger-subtle); --red-ink: var(--danger-text);
}

/* ------------------------------------------------------------ 2. Basis */
body {
  background: var(--bg);
  color: var(--text);
  font-size: var(--fs-base);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "cv11", "ss01";
}
a { color: var(--accent); }
:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--radius-sm); }
p { line-height: 1.55; }
h1 { font-size: var(--fs-xl); line-height: 1.33; font-weight: 650; letter-spacing: -.02em; margin: 0 0 var(--s-1); color: var(--text); }
h2 { font-size: 1rem; font-weight: 600; letter-spacing: -.01em; color: var(--text); }
h3 { font-size: var(--fs-md); font-weight: 600; color: var(--text); }
small { color: var(--text-3); font-size: var(--fs-xs); }
.muted { color: var(--text-3); font-size: var(--fs-sm); }
.ask-icon { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }

/* ------------------------------------------------------------ 3. Sidebar */
.sidebar {
  width: var(--sidebar-w);
  background: var(--sb-bg);
  color: var(--sb-text);
  padding: var(--s-4) var(--s-3);
  overflow-y: auto;
}
.sidebar .brand {
  display: block; background: #fff; border-radius: var(--radius);
  padding: var(--s-2) var(--s-3); margin: 0 var(--s-1) var(--s-2); line-height: 0;
}
.sidebar .brand-logo { width: 100%; height: auto; }
.sidebar .brand-mark { display: none; }
.navlabel, .navlabel-sub {
  font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  color: var(--sb-label); margin: var(--s-5) var(--s-3) var(--s-1);
}
.sidebar nav { display: flex; flex-direction: column; gap: 2px; flex-wrap: nowrap; }
.sidebar nav a {
  display: flex; align-items: center; gap: var(--s-3);
  height: 36px; padding: 0 var(--s-3); margin: 0;
  border-radius: var(--radius-sm);
  color: var(--sb-text); font-size: var(--fs-base); font-weight: 500;
  position: relative; box-shadow: none;
}
.sidebar nav a .ask-icon { color: var(--sb-icon); }
.sidebar nav a:hover { background: var(--sb-hover); text-decoration: none; color: #fff; }
.sidebar nav a.active { background: var(--sb-active-bg); color: var(--sb-active-text); font-weight: 600; box-shadow: none; }
.sidebar nav a.active .ask-icon { color: var(--sb-active-text); }
.sidebar nav a.active::before {
  content: ""; position: absolute; left: -12px; top: 8px; bottom: 8px; width: 3px;
  border-radius: 0 3px 3px 0; background: var(--sb-indicator);
}
.sidebar nav .nav-text { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nav-badge {
  min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px;
  background: var(--danger); color: #fff; font-size: 11px; font-weight: 600; line-height: 20px;
  display: inline-grid; place-items: center; font-variant-numeric: tabular-nums;
}
.sidebar-bottom {
  margin-top: auto; padding: var(--s-2); gap: var(--s-3);
  border-radius: var(--radius); background: var(--sb-hover); font-size: var(--fs-sm);
}
.sidebar-bottom strong { display: block; color: #fff; font-weight: 600; }
.sidebar-bottom small { display: block; margin: 0; color: var(--sb-icon); }
.sidebar .avatar { width: 32px; height: 32px; background: var(--accent); color: #fff; font-size: var(--fs-sm); font-weight: 600; flex: none; }

/* ------------------------------------------------------------ 4. Hoofdgebied + topbalk */
main { margin-left: var(--sidebar-w); padding: 0 var(--s-6) var(--s-5); max-width: none; }
main > *:not(.topline) { max-width: 1400px; }
.topline {
  position: sticky; top: 0; z-index: 20;
  height: var(--topbar-h); gap: var(--s-3);
  margin: 0 calc(var(--s-6) * -1); padding: 0 var(--s-6);
  background: rgba(247, 248, 250, .88); backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--border);
  color: var(--text-3); font-size: var(--fs-sm);
}
.topline-title { font-weight: 600; color: var(--text); margin-right: auto; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topline-title span { color: var(--text-3); font-weight: 400; }
.topline form { margin: 0; }
.env-pill {
  display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 var(--s-2);
  border-radius: 999px; background: var(--warning-subtle); color: var(--warning-text);
  border: 1px solid var(--warning-border); font-size: var(--fs-xs); font-weight: 500; white-space: nowrap;
}
.env-pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--warning); }
.topline-date { white-space: nowrap; }
.demo { display: none; } /* vervangen door .env-pill in de topbalk */
footer { font-size: var(--fs-xs); color: var(--text-4); padding: var(--s-5) 0 0; }

/* ------------------------------------------------------------ 5. Paginakop */
.pagehead { margin: var(--s-6) 0 var(--s-5); gap: var(--s-4); }
.pagehead h1 { margin-bottom: var(--s-1); }
.eyebrow { font-size: var(--fs-xs); letter-spacing: .06em; font-weight: 600; text-transform: uppercase; color: var(--text-3); margin: 0 0 var(--s-1); }
header p:not(.eyebrow), .panelhead p, .formpanel > p { color: var(--text-3); font-size: var(--fs-base); }
.backlink { font-size: var(--fs-sm); color: var(--text-3); margin-top: var(--s-5); }
.backlink:hover { color: var(--accent); }

/* ------------------------------------------------------------ 6. Knoppen */
button, .button {
  height: auto; min-height: 36px; padding: 0 var(--s-4); gap: var(--s-2);
  background: var(--accent); border: 1px solid var(--accent); color: #fff;
  border-radius: var(--radius); font-size: var(--fs-base); font-weight: 500;
  box-shadow: var(--shadow-xs); transition: background .12s, border-color .12s, color .12s;
}
button:hover, .button:hover { background: var(--accent-hover); border-color: var(--accent-hover); text-decoration: none; }
.secondary, button.secondary, .button.secondary {
  background: var(--surface); color: var(--text); border: 1px solid var(--border-strong);
}
.secondary:hover, button.secondary:hover, .button.secondary:hover { background: var(--surface-hover); color: var(--text); border-color: var(--border-strong); }
.compact, button.compact, .button.compact { min-height: 32px; padding: 0 var(--s-3); font-size: var(--fs-sm); }
button:disabled, .button[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
.topline .secondary { background: transparent; border-color: transparent; box-shadow: none; color: var(--text-2); }
.topline .secondary:hover { background: var(--neutral-subtle); }

/* ------------------------------------------------------------ 7. Formulieren */
label { font-size: var(--fs-sm); font-weight: 500; color: var(--text-2); gap: 6px; }
input, select, textarea {
  border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  background: var(--surface); color: var(--text); font-size: var(--fs-base);
  padding: 7px var(--s-3); min-height: 36px; box-shadow: var(--shadow-xs);
  transition: border-color .12s, box-shadow .12s;
}
textarea { padding: var(--s-2) var(--s-3); }
input[type="checkbox"], input[type="radio"] { min-height: 0; box-shadow: none; accent-color: var(--accent); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: var(--ring); }
input::placeholder, textarea::placeholder { color: var(--text-4); }
.filters { gap: var(--s-3); margin: var(--s-5) 0; }
.check { font-weight: 400; color: var(--text); }
.formpanel { padding: var(--s-5); }
.formgrid { gap: var(--s-4); }
.reset { color: var(--text-3); }

/* ------------------------------------------------------------ 8. Panelen, feiten, kaarten */
.panel, .facts {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-xs);
}
.panel { margin-bottom: var(--s-5); }
/* Kolommen mogen smaller worden dan een brede tabel; de tabel scrolt dan binnen zijn eigen vak */
.detailgrid > *, .crm-grid > * { min-width: 0; }
.panelhead { padding: var(--s-4) var(--s-5); }
.panelhead h2 { font-size: 1rem; }
.facts { padding: var(--s-5); gap: var(--s-6); }
.facts strong { color: var(--text); }
.workcard, .readcheck { padding: var(--s-4) var(--s-5); border-top-color: var(--border); }
.count { background: var(--neutral-subtle); color: var(--text-3); border-radius: 999px; padding: 2px var(--s-2); font-size: var(--fs-xs); font-weight: 500; }
.event { border-bottom-color: var(--border); }
details > summary { color: var(--text); }

/* KPI-kaarten (algemeen) */
.metrics { gap: var(--s-4); margin: var(--s-5) 0; }
.metric {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: var(--s-4) var(--s-5); color: var(--text); box-shadow: var(--shadow-xs);
  transition: border-color .12s, box-shadow .12s;
}
.metric:hover { text-decoration: none; border-color: var(--border-strong); box-shadow: var(--shadow-sm); }
.metric.selected { border-color: var(--accent-border); box-shadow: 0 0 0 1px var(--accent-border); }
.metric-label { font-size: var(--fs-sm); font-weight: 500; color: var(--text-2); }
.metric strong { font-size: var(--fs-kpi); font-weight: 650; letter-spacing: -.02em; margin: var(--s-2) 0; font-variant-numeric: tabular-nums; }
.metric-foot { color: var(--text-3); font-size: var(--fs-xs); }

/* ------------------------------------------------------------ 9. Tabellen */
/* position: relative houdt verborgen schermlezerteksten (sr-only) binnen het scrollvak */
.tablewrap { position: relative; }
table { font-size: var(--fs-base); }
th {
  background: var(--surface-muted); color: var(--text-3);
  font-size: var(--fs-xs); font-weight: 500; letter-spacing: 0;
  padding: var(--s-3) var(--s-4); border-block: 1px solid var(--border);
}
td { padding: var(--s-3) var(--s-4); border-bottom: 1px solid var(--border-soft); }
tbody tr { transition: background .1s; }
tbody tr:hover > td { background: #fafbfc; }
.clientlink { color: var(--text); font-weight: 600; }
.clientlink:hover { color: var(--accent); text-decoration: none; }
.sort-link { color: var(--text-3); }
.sort-link:hover { color: var(--text); text-decoration: none; }
.sort-link.selected { color: var(--text); font-weight: 600; }
.administration-list th[aria-sort=ascending], .administration-list th[aria-sort=descending],
.workspace-list th[aria-sort=ascending], .workspace-list th[aria-sort=descending] { background: var(--neutral-subtle); }
.empty { color: var(--text-3); padding: var(--s-8) var(--s-4); }
.empty strong { color: var(--text); font-size: var(--fs-md); }
.pager { gap: var(--s-4); padding: var(--s-3) var(--s-5); border-top: 1px solid var(--border); font-size: var(--fs-sm); color: var(--text-3); }

/* ------------------------------------------------------------ 10. Pills / badges */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  min-height: 24px; padding: 2px 10px; border-radius: 999px;
  background: var(--neutral-subtle); border: 1px solid #eceef1; color: var(--text-2);
  font-size: var(--fs-sm); font-weight: 500; line-height: 1.3;
}
.badge.processing, .badge.completeness, .badge.documents, .badge.review, .badge.publication { background: var(--neutral-subtle); color: var(--text-2); }
.badge.processing::before, .badge.completeness::before, .badge.documents::before, .badge.review::before, .badge.publication::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%; flex: none; background: var(--text-4);
}
.badge.processing::before { background: var(--kind-processing); }
.badge.completeness::before { background: var(--kind-completeness); }
.badge.documents::before { background: var(--kind-documents); }
.badge.review::before { background: var(--kind-review); }
.badge.publication::before { background: var(--kind-publication); }
.badge.unknown { background: var(--neutral-subtle); color: var(--text-3); }
.workspace-list .badge { font-size: var(--fs-sm); padding: 2px 10px; }
.status-pill { min-height: 24px; align-items: center; padding: 2px 10px; font-size: var(--fs-xs); font-weight: 500; white-space: nowrap; }
.status-unknown { background: var(--neutral-subtle); color: var(--text-3); }
.count-pill { background: var(--neutral-subtle); color: var(--text-2); font-weight: 600; font-size: var(--fs-xs); }
.overdue { color: var(--danger-text); }
.done { color: var(--success); }

/* ------------------------------------------------------------ 11. Meldingen */
.notice, .errors, .task-alert {
  border-radius: var(--radius); padding: var(--s-3) var(--s-4); margin-top: var(--s-4);
  font-size: var(--fs-base); border: 1px solid transparent;
}
.notice { background: var(--success-subtle); border-color: var(--success-border); color: var(--success); }
.errors, .task-alert { background: var(--danger-subtle); border-color: var(--danger-border); color: var(--danger-text); }
.task-alert a { color: var(--danger-text); }
.errors ul { margin: var(--s-2) 0 0; padding-left: var(--s-5); }

/* ------------------------------------------------------------ 12. Segmenten, chips, tabs */
.segmented { background: var(--neutral-subtle); border-radius: var(--radius); padding: 2px; gap: 2px; }
.segmented a {
  min-height: 30px; padding: 0 var(--s-3); border-radius: var(--radius-sm);
  color: var(--text-2); font-size: var(--fs-sm); font-weight: 500; gap: 6px;
}
.segmented a:hover { background: transparent; color: var(--text); }
.segmented a[aria-current] { background: var(--surface); color: var(--text); font-weight: 600; box-shadow: var(--shadow-sm); }
.segmented-small a { min-height: 28px; font-size: var(--fs-sm); }
.segmented .avatar-chip { width: 18px; height: 18px; font-size: 10px; }
.chips { gap: var(--s-1); }
.chips a {
  min-height: 28px; padding: 0 10px; gap: 6px;
  border: 1px solid var(--border); border-radius: 999px; background: var(--surface);
  color: var(--text-2); font-size: var(--fs-sm); font-weight: 500;
}
.chips a:hover { border-color: var(--border-strong); color: var(--text); }
.chips a[aria-current] { background: var(--accent-subtle); border-color: var(--accent-border); color: var(--accent); }
.chip-count { color: var(--text-4); font-weight: 500; }
.chips a[aria-current] .chip-count { color: var(--accent); opacity: .75; }
.chip-dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.chip-dot.processing { background: var(--kind-processing); }
.chip-dot.completeness { background: var(--kind-completeness); }
.chip-dot.documents { background: var(--kind-documents); }
.chip-dot.review { background: var(--kind-review); }
.chip-dot.publication { background: var(--kind-publication); }
.view-tabs { border-bottom-color: var(--border); gap: var(--s-1); }
.view-tabs a { color: var(--text-3); font-size: var(--fs-base); font-weight: 500; min-height: 40px; padding: 0 var(--s-3); }
.view-tabs a:hover { color: var(--text); }
.view-tabs a[aria-current] { color: var(--text); font-weight: 600; box-shadow: inset 0 -2px var(--accent); }

/* ------------------------------------------------------------ 13. Avatars, rijmenu */
.avatar-chip {
  width: 28px; height: 28px; font-size: var(--fs-xs); font-weight: 600;
  background: var(--accent); color: #fff;
}
.avatar-chip[data-p="J"] { background: #0e7490; }
.avatar-chip[data-p="M"] { background: #6d28d9; }
.avatar-review { background: var(--purple-subtle); color: var(--purple); }
.row-menu summary {
  width: 32px; height: 32px; border: 0; border-radius: var(--radius-sm);
  color: var(--text-3); background: transparent; font-weight: 400;
}
.row-menu summary:hover { background: var(--neutral-subtle); color: var(--text); }
.row-menu[open] > summary { background: var(--neutral-subtle); }
.row-menu > div { top: 36px; border-color: var(--border); border-radius: var(--radius); box-shadow: var(--shadow-pop); padding: var(--s-1); }
.row-menu > div a { color: var(--text); font-size: var(--fs-sm); padding: var(--s-2); border-radius: var(--radius-sm); }
.row-menu > div a:hover { background: var(--surface-hover); }

/* ------------------------------------------------------------ 14. Mijn werk */
.ws-head { margin-bottom: var(--s-5); align-items: flex-end; }
.ws-head h1 { margin-bottom: var(--s-1); }
.ws-head p { font-size: var(--fs-md); }
.ws-late-text { color: var(--danger-text); font-weight: 600; }
.ws-summary { gap: var(--s-4); margin: 0 0 var(--s-5); }
.ws-card {
  gap: var(--s-3); padding: var(--s-4) var(--s-5) var(--s-4) var(--s-4);
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  background: var(--surface); box-shadow: var(--shadow-xs); color: var(--text);
  transition: border-color .12s, box-shadow .12s;
}
.ws-card:hover { border-color: var(--border-strong); box-shadow: var(--shadow-sm); }
.ws-card .ws-card-top { display: flex; align-items: center; gap: var(--s-2); font-size: var(--fs-sm); font-weight: 500; color: var(--text-2); }
.ws-card .ws-card-icon { width: 28px; height: 28px; border-radius: var(--radius-sm); display: grid; place-items: center; background: var(--neutral-subtle); color: var(--text-3); }
.ws-card .ws-card-icon .ask-icon { width: 16px; height: 16px; }
.ws-card strong { font-size: var(--fs-kpi); line-height: 1; font-weight: 650; letter-spacing: -.02em; color: var(--text); }
.ws-card small { font-size: var(--fs-xs); color: var(--text-3); margin: 0; }
/* Alleen "Te laat" krijgt kleur, en alleen als er echt iets te laat is */
.ws-card-today span, .ws-card-week span, .ws-card-done span { color: inherit; }
.ws-card-late.has-items { border-color: var(--danger-border); background: linear-gradient(180deg, var(--danger-subtle), var(--surface) 70%); }
.ws-card-late.has-items .ws-card-top, .ws-card-late.has-items strong { color: var(--danger-text); }
.ws-card-late.has-items .ws-card-icon { background: #fde2e0; color: var(--danger); }

.ws-filterbar {
  gap: var(--s-3); padding: var(--s-2); margin-bottom: var(--s-4);
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-xs);
}
.ws-filterbar .ws-sep { width: 1px; align-self: stretch; background: var(--border); margin: var(--s-1) 0; }
.ws-search { position: relative; display: flex; align-items: center; }
.ws-search label { position: relative; display: flex; flex-direction: row; align-items: center; gap: 0; }
.ws-search .ask-icon { position: absolute; left: 10px; width: 16px; height: 16px; color: var(--text-4); pointer-events: none; }
.ws-search input { width: 240px; height: 32px; min-height: 32px; padding: 0 var(--s-3) 0 34px; background: var(--surface-muted); border-color: var(--border); box-shadow: none; font-size: var(--fs-sm); }
.ws-search input:focus { background: var(--surface); }
.ws-reset { font-size: var(--fs-sm); color: var(--text-3); margin-left: auto; }

.workspace-panel { overflow: visible; }
.workspace-list { font-size: var(--fs-base); }
.workspace-list th { padding: var(--s-3) var(--s-4); vertical-align: middle; }
.workspace-list td { padding: var(--s-3) var(--s-4); }
.workspace-list th:first-child, .workspace-list td:first-child { padding-left: var(--s-5); }
.workspace-list tr.ws-group th {
  padding: var(--s-4) var(--s-5) var(--s-2); background: var(--surface);
  font-size: var(--fs-xs); font-weight: 600; letter-spacing: .02em; text-transform: none;
  color: var(--text-2); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
}
.workspace-list tbody tr.ws-group:first-child th { border-top: 0; }
.ws-group-late th { color: var(--danger-text) !important; }
.ws-group-today th, .ws-group-week th, .ws-group-later th, .ws-group-done th { color: var(--text-2) !important; }
.ws-group-count { margin-left: 6px; color: var(--text-4); font-weight: 500; }
.ws-row.is-late td:first-child { box-shadow: inset 3px 0 var(--danger); }
.workspace-client .clientlink { line-height: 1.4; }
.workspace-period { color: var(--text-3); font-size: var(--fs-sm); margin-top: 2px; }
.work-note-alert {
  display: inline-flex !important; align-items: center; gap: 4px; margin-top: 4px;
  background: transparent !important; padding: 0 !important; color: var(--warning-text) !important;
  font-size: var(--fs-xs) !important; font-weight: 500 !important;
}
.work-note-alert::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--warning); }
.workspace-list .note { color: var(--text-3); font-size: var(--fs-sm); margin-top: 4px; }
.due { color: var(--text); font-weight: 500; font-variant-numeric: tabular-nums; }
.due-note { font-size: var(--fs-sm); color: var(--text-3); margin-top: 2px; }
.due-late { color: var(--danger-text) !important; font-weight: 600; }
.due-today { color: var(--accent) !important; font-weight: 600; }
.due-week, .due-later { color: var(--text-3); }
.workspace-date .due.due-late, .workspace-date .due.due-today { color: var(--text) !important; font-weight: 500; }
.workspace-open { text-align: right; white-space: nowrap; }
.workspace-open .button { opacity: 0; background: var(--surface); color: var(--text); border-color: var(--border-strong); transition: opacity .12s; }
.workspace-open .button:hover { background: var(--surface-hover); }
.ws-row:hover .workspace-open .button, .ws-row:focus-within .workspace-open .button { opacity: 1; }
@media (hover: none) { .workspace-open .button { opacity: 1; } }

/* ------------------------------------------------------------ 15. Administraties */
.progress-bar { height: 6px; border-radius: 3px; background: var(--neutral-subtle); }
.progress-bar > span { background: var(--accent); border-radius: 3px; }
.progress-publication > span { background: var(--success); }
.progress-documents > span { background: var(--warning); }
.progress-unknown > span { background: var(--text-4); }
.step { background: var(--neutral-subtle); color: var(--text-3); font-weight: 500; }
.step-done { background: var(--success-subtle); color: var(--success); }
.step-now { background: var(--accent); color: #fff; }
.more-filters summary { color: var(--accent); font-size: var(--fs-sm); font-weight: 500; }

/* ------------------------------------------------------------ 16. Aanmelden */
.login-page { background: var(--bg); }
.login-card { border-radius: var(--radius-lg); border-color: var(--border); box-shadow: var(--shadow-sm); padding: var(--s-7); }
.login-brand { color: var(--text); }
.login-card .demo { display: block; background: var(--accent-subtle); color: var(--text-2); border-radius: var(--radius); }

/* ------------------------------------------------------------ 17. Responsive */
@media (max-width: 1150px) {
  :root { --sidebar-w: 216px; }
  .sidebar { width: var(--sidebar-w); padding: var(--s-4) var(--s-3); }
  main { margin-left: var(--sidebar-w); padding-inline: var(--s-5); }
  .topline { margin-inline: calc(var(--s-5) * -1); padding-inline: var(--s-5); }
  .ws-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  td, th { padding-inline: var(--s-3); }
}
@media (max-width: 1024px) and (min-width: 761px) {
  :root { --sidebar-w: 64px; }
  .sidebar { padding: var(--s-4) var(--s-2); align-items: center; }
  .sidebar .brand { padding: 6px; margin: 0 0 var(--s-2); width: 44px; }
  .sidebar .brand-logo { display: none; }
  .sidebar .brand-mark { display: block; width: 100%; height: auto; }
  .navlabel, .navlabel-sub { visibility: hidden; height: 1px; margin: var(--s-3) 0; overflow: hidden; }
  .sidebar nav a { width: 40px; height: 40px; padding: 0; justify-content: center; }
  .sidebar nav .nav-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .sidebar nav a.active::before { left: -8px; }
  .nav-badge { position: absolute; top: 2px; right: 0; min-width: 16px; height: 16px; line-height: 16px; font-size: 10px; padding: 0 4px; }
  .sidebar-bottom { background: none; padding: 0; }
  .sidebar-bottom > div { display: none; }
  .ws-search input { width: 180px; }
}
@media (max-width: 760px) {
  .sidebar { position: static; width: auto; height: auto; padding: var(--s-3) var(--s-4); display: block; }
  .sidebar .brand { width: 180px; margin: 0 0 var(--s-2); }
  .navlabel, .navlabel-sub, .sidebar-bottom { display: none; }
  .sidebar nav { flex-direction: row; overflow-x: auto; gap: var(--s-1); margin-top: var(--s-2); scrollbar-width: none; }
  .sidebar nav a { flex: none; height: 36px; padding: 0 var(--s-3); font-size: var(--fs-sm); }
  .sidebar nav a.active::before { display: none; }
  main { margin: 0; padding-inline: var(--s-4); }
  .topline { position: static; height: auto; padding: var(--s-3) var(--s-4); margin-inline: calc(var(--s-4) * -1); flex-wrap: wrap; }
  .topline-date { display: none; }
  .ws-filterbar { gap: var(--s-2); }
  .ws-filterbar .ws-sep { display: none; }
  .ws-search, .ws-search input { width: 100%; }
  .ws-summary { gap: var(--s-2); }
  .ws-card { padding: var(--s-3); }
  .workspace-open .button { opacity: 1; }
}
