/* ============================================================
   Wooden Design System — root tokens
   Overgenomen uit .context/design-system/project/colors_and_type.css
   ============================================================ */

:root {
  /* Brand palette */
  --color-gold: #D4AF37;
  --color-brown-strong: #654321;
  --color-brown-muted:  #6C4B2B;
  --color-brown-warm:   #5B3D24;
  --color-brown-dark:   #3D2817;
  --color-brown-deep:   #3B220F;
  --color-parchment:    #f6e7c3;
  --color-parchment-card: #fffdf6;

  /* Semantic feedback */
  --color-success: #4CAF50;
  --color-error:   #F44336;
  --color-alert:   #D9534F;

  /* Purple accent gradients (primary CTA) */
  --gradient-button-primary:  linear-gradient(135deg, #583286 0%, #7a4ba8 100%);
  --gradient-button-hover:    linear-gradient(135deg, #7a4ba8 0%, #9a6bc8 100%);
  --gradient-button-disabled: linear-gradient(135deg, #555 0%, #777 100%);

  /* Dark panel gradients (modal surfaces) */
  --gradient-panel-dark: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);

  /* Translucent surfaces */
  --surface-panel-card:        rgba(255, 253, 246, 0.95);
  --surface-panel-card-bright: rgba(255, 253, 246, 0.98);
  --border-subtle:             1px solid rgba(0, 0, 0, 0.08);

  /* Warm menu-highlight family */
  --menu-selected-bg: rgba(228, 198, 164, 0.7);

  /* Shadows */
  --shadow-card:         0 4px 20px rgba(0, 0, 0, 0.15);
  --shadow-button:       0 2px 8px  rgba(0, 0, 0, 0.30);
  --shadow-button-hover: 0 6px 12px rgba(0, 0, 0, 0.40);
  --shadow-modal:        0 10px 30px rgba(0, 0, 0, 0.80);

  /* Radii */
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 10px;
  --radius-lg: 12px;
  --radius-xl: 15px;
  --radius-round: 50%;

  /* Borders */
  --modal-surface-border: 3px solid var(--color-gold);

  /* Spacing */
  --space-1: 4px; --space-2: 6px; --space-3: 8px; --space-4: 10px;
  --space-5: 12px; --space-6: 16px; --space-7: 20px; --space-8: 24px; --space-9: 30px;

  /* Typography */
  --font-family-ui: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --font-size-xxs: 0.68rem;
  --font-size-xs:  0.75rem;
  --font-size-sm:  0.85rem;
  --font-size-md:  0.9rem;
  --font-size-base:1rem;
  --font-size-lg:  1.1rem;
  --font-size-xl:  1.25rem;

  --font-weight-regular: 400;
  --font-weight-medium:  500;
  --font-weight-semibold:600;
  --font-weight-bold:    700;
  --font-weight-heavy:   800;

  --letter-spacing-caps:    0.05em;
  --letter-spacing-display: 0.02em;

  --line-height-tight: 1.2;
  --line-height-body:  1.45;
  --line-height-loose: 1.5;
}

/* ── Basis ───────────────────────────────────────────────── */
* { box-sizing: border-box; }
html, body { height: 100%; }

body {
  margin: 0;
  font-family: var(--font-family-ui);
  background: radial-gradient(120% 80% at 50% 0%, #fbeecb 0%, var(--color-parchment) 60%);
  color: var(--color-brown-strong);
  display: flex;
  justify-content: center;
  overflow: hidden;
  -webkit-tap-highlight-color: transparent;
}

/* Voorkom iOS-zoom op formulierbesturing (geen invoervelden hier, maar veilig). */
input, textarea, select { font-size: 16px; }

/* ── Loading-overlay (PWA-update) ────────────────────────── */
.loading-overlay {
  position: fixed; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: var(--space-5);
  background: var(--color-parchment);
  color: var(--color-brown-strong);
  z-index: 5000;
}
.loading-overlay--hidden { display: none; }
.loading-spinner {
  width: 38px; height: 38px;
  border: 4px solid rgba(101, 67, 33, 0.2);
  border-top-color: var(--color-brown-strong);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
