:root {
  /* BRAND - Van groen/beige naar de zwart/wit look van vandooremolen.com */
  --brand-accent: #000000;
  --brand-accent-hover: #333333;
  --brand-black: #000000;
  --brand-white: #ffffff;

  /* BACKGROUNDS */
  --brand-bg: #f9f9f9;
  --brand-surface: #ffffff;
  --brand-surface-subtle: #f7f7f7;
  --brand-surface-muted: #eeeeee;

  /* TEXT */
  --brand-text: #1a1a1a;
  --brand-text-secondary: #555555;
  --brand-text-muted: #888888;
  --brand-text-faint: #aaaaaa;
  --brand-text-ghost: #c9c3b8;
  --brand-text-inverse: #ffffff;

  /* BORDERS */
  --brand-border: #e5e5e5;
  --brand-border-light: #f0f0f0;
  --brand-border-faint: #f5f5f5;

  /* TYPOGRAPHY - Weg met Georgia, welkom Inter */
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;
  --font-heading: 'Inter', system-ui, sans-serif;
  --font-mono: 'Courier New', Courier, monospace;

  /* RADIUS - Strakkere, rechtere hoeken */
  --radius-sm: 0px;
  --radius-md: 2px;
  --radius-lg: 4px;
  --radius-xl: 6px;
  --radius-pill: 999px;

  /* SHADOWS - Minimalistischer */
  --shadow-card: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-toast: 0 4px 12px rgba(0,0,0,0.1);
  --shadow-modal: 0 12px 32px rgba(0,0,0,0.15);

  /* LAYOUT */
  --app-max-width: 1000px;
  --app-padding-x: 24px;
  
  /* Behoud je legacy aliases voor App.jsx */
  --pri-black: var(--brand-accent);
  --pri-white: var(--brand-white);
  --pri-bg: var(--brand-bg);
  --pri-bg-card: var(--brand-surface);
  --pri-bg-subtle: var(--brand-surface-subtle);
  --pri-text-primary: var(--brand-text);
  --pri-text-secondary: var(--brand-text-secondary);
  --pri-border: var(--brand-border);
  --pri-font: var(--font-body);
}

/* ─── RESET ─────────────────────────────────────────────────────────────────── */

*,*::before,*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-body);
  font-size: var(--text-md);
  font-weight: var(--weight-regular);
  line-height: var(--leading-relaxed);
  letter-spacing: var(--tracking-base);
  color: var(--brand-text);
  background: var(--brand-bg);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

input, select, textarea, button { font: inherit; }

button {
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

input:focus,
select:focus,
textarea:focus { outline: none; }

::selection { background: rgba(31,58,50,0.12); }

/* ─── SCROLLBAR ──────────────────────────────────────────────────────────────── */

::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--brand-border); border-radius: 3px; }

/* ─── MOBILE ─────────────────────────────────────────────────────────────────── */

body { overflow-x: hidden; }

@supports (-webkit-touch-callout: none) {
  .app-shell { min-height: -webkit-fill-available; }
}

@media (max-width: 768px) {
  input[type="text"],
  input[type="email"],
  input[type="password"],
  input[type="number"],
  input[type="date"],
  input[type="tel"],
  select,
  textarea {
    font-size: 16px !important;
  }
}

/* ─── SPINNER ────────────────────────────────────────────────────────────────── */

@keyframes pri-spin { to { transform: rotate(360deg); } }

.pri-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid var(--brand-border);
  border-top-color: var(--brand-accent);
  border-radius: 50%;
  animation: pri-spin 0.55s linear infinite;
  display: inline-block;
  flex-shrink: 0;
}

.pri-spinner-sm {
  width: 13px;
  height: 13px;
  border-width: 1.5px;
}

/* ─── TOAST & MODAL ANIMATIONS ───────────────────────────────────────────────── */

@keyframes pri-toast-in {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes pri-fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes pri-slide-up {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

.pri-toast  { animation: pri-toast-in 0.18s ease; }
.pri-overlay { animation: pri-fade-in 0.2s ease; }
.pri-modal   { animation: pri-slide-up 0.22s ease; }

/* ─── APP SHELL ──────────────────────────────────────────────────────────────── */

.app-shell {
  max-width: var(--app-max-width);
  margin: 0 auto;
  padding: var(--app-padding-top) var(--app-padding-x) var(--app-padding-bottom);
}

/* ─── TYPOGRAPHY HELPERS ─────────────────────────────────────────────────────── */

.label-text {
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--brand-text-muted);
}

.section-label {
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--brand-text-faint);
  margin: 28px 0 10px;
}

/* ─── CARDS ──────────────────────────────────────────────────────────────────── */

.card {
  background: var(--brand-surface);
  border: 1px solid var(--brand-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  padding: 32px; /* Iets meer ademruimte zoals op je site */
  margin-bottom: 20px;
}

/* ─── BUTTONS ────────────────────────────────────────────────────────────────── */

.button,
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px; /* Grotere, luxere knoppen */
  border-radius: var(--radius-sm);
  border: 1px solid var(--brand-black);
  background-color: var(--brand-black);
  color: var(--brand-white);
  font-size: 13px;
  font-weight: 500;
  text-transform: uppercase; /* Matcht met je website menu/buttons */
  letter-spacing: 0.12em;
  cursor: pointer;
  transition: all 0.2s ease;
}

.button:hover, .btn:hover {
  background-color: transparent;
  color: var(--brand-black);
}

/* ─── METRICS ────────────────────────────────────────────────────────────────── */

.metric-card {
  background: var(--brand-surface-subtle);
  border: 1px solid var(--brand-border-light);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
}

.metric-label {
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--brand-text-muted);
  margin-bottom: 10px;
}

.metric-value {
  font-size: var(--text-4xl);
  font-weight: var(--weight-bold);
  line-height: 1;
  letter-spacing: var(--tracking-tight);
}

.metric-sub {
  font-size: var(--text-sm);
  color: var(--brand-text-faint);
  margin-top: 8px;
}

/* ─── TABS ───────────────────────────────────────────────────────────────────── */

.tabs {
  display: flex;
  gap: 2px;
  border-bottom: 1px solid var(--brand-border-light);
  margin-bottom: 32px;
}

.tab {
  padding: 11px 16px;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--brand-text-muted);
  font-size: 13px;
  font-weight: var(--weight-medium);
  cursor: pointer;
  margin-bottom: -1px;
  letter-spacing: 0;
  text-transform: none;
}

.tab-active {
  color: var(--brand-text);
  font-weight: var(--weight-semibold);
  border-bottom-color: var(--brand-accent);
}

/* ─── PILLS / BADGES ─────────────────────────────────────────────────────────── */

.pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: var(--radius-pill);
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  line-height: 1;
  border: 1px solid transparent;
}

.pill-success { background: var(--color-success-bg); color: var(--color-success); border-color: var(--color-success-border); }
.pill-warning { background: var(--color-warning-bg); color: var(--color-warning); border-color: var(--color-warning-border); }
.pill-danger  { background: var(--color-danger-bg);  color: var(--color-danger);  border-color: var(--color-danger-border);  }
.pill-info    { background: var(--color-info-bg);    color: var(--color-info);    border-color: var(--color-info-border);    }

/* ─── TOPBAR ─────────────────────────────────────────────────────────────────── */

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.topbar-meta {
  border-left: 1px solid var(--brand-border);
  padding-left: 16px;
}

.topbar-kicker {
  font-size: var(--text-xs);
  font-weight: var(--weight-bold);
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--brand-text-faint);
}

.topbar-name {
  font-size: 13px;
  color: var(--brand-text-muted);
  margin-top: 3px;
}

/* ─── FOOTER ─────────────────────────────────────────────────────────────────── */

.app-footer {
  margin-top: 56px;
  padding-top: 20px;
  border-top: 1px solid var(--brand-border-faint);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.app-footer-text {
  font-size: var(--text-sm);
  color: var(--brand-text-faint);
}

.app-footer-version {
  font-size: var(--text-xs);
  color: var(--brand-text-faint);
  font-family: var(--font-mono);
}

/* ─── DIVIDER ────────────────────────────────────────────────────────────────── */

.divider {
  border: none;
  border-top: 1px solid var(--brand-border-light);
  margin: 22px 0;
}

/* ─── SLOT ROW ───────────────────────────────────────────────────────────────── */

@media (max-width: 600px) {
  .pri-slot-row {
    grid-template-columns: 40px 1fr !important;
  }
  .pri-slot-cats {
    grid-column: 1 / -1;
    margin-left: 46px;
  }
  .pri-profile-grid,
  .pri-beheer-grid {
    grid-template-columns: 1fr !important;
  }
  .topbar {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ─── UTILITY ────────────────────────────────────────────────────────────────── */

.pri-truncate { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pri-sr-only  { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
