/* HeartBeat – design tokens (colours, font, sizes).
   Shared by the app (app.css) and the technical admin (admin.css). */

:root {
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  --bg: #f5f5f7;
  --surface: #ffffff;
  --surface-2: #f0f0f3;
  --text: #1d1d1f;
  --text-muted: #5f5f66;      /* 6.1:1 on white */
  --border: rgba(0, 0, 0, 0.08);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06);
  --focus: #0066cc;

  --accent: #d70015;          /* HeartBeat red, 5.6:1 on white */
  --accent-contrast: #ffffff;

  /* Status tones: background tint + strong foreground (both themes AA). */
  --green: #1a7f37;  --green-bg: #e3f4e8;
  --blue: #0058b0;   --blue-bg: #e2eefb;
  --orange: #a44a00; --orange-bg: #fdeedd;
  --red: #c4141f;    --red-bg: #fde6e7;
  --purple: #7a2fb5; --purple-bg: #f1e7fa;
  --gray: #5f5f66;   --gray-bg: #ececef;

  --radius-s: 10px;
  --radius: 16px;
  --radius-l: 22px;
  --space: 16px;
  --tap: 48px;               /* minimum touch target */

  --ease: cubic-bezier(0.25, 0.1, 0.25, 1);
  --fast: 150ms;
}

/* Night (dark): follows the device unless the user chose Dag or Nacht (data-theme on <html>, see My account). */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="licht"]) {
    --bg: #000000;
    --surface: #1c1c1e;
    --surface-2: #2c2c2e;
    --text: #f5f5f7;
    --text-muted: #a1a1a8;
    --border: rgba(255, 255, 255, 0.1);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
    --focus: #4da3ff;

    --accent: #ff4d5a;
    --accent-contrast: #000000;

    --green: #4cd27a;  --green-bg: #12301c;
    --blue: #6cb2ff;   --blue-bg: #0f2740;
    --orange: #ffad5c; --orange-bg: #3a2410;
    --red: #ff6b73;    --red-bg: #3d1517;
    --purple: #c99bff; --purple-bg: #2c1a40;
    --gray: #a1a1a8;   --gray-bg: #2c2c2e;
  }
}

:root[data-theme="donker"] {
  --bg: #000000;
  --surface: #1c1c1e;
  --surface-2: #2c2c2e;
  --text: #f5f5f7;
  --text-muted: #a1a1a8;
  --border: rgba(255, 255, 255, 0.1);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  --focus: #4da3ff;

  --accent: #ff4d5a;
  --accent-contrast: #000000;

  --green: #4cd27a;  --green-bg: #12301c;
  --blue: #6cb2ff;   --blue-bg: #0f2740;
  --orange: #ffad5c; --orange-bg: #3a2410;
  --red: #ff6b73;    --red-bg: #3d1517;
  --purple: #c99bff; --purple-bg: #2c1a40;
  --gray: #a1a1a8;   --gray-bg: #2c2c2e;
}

/* Form controls and scrollbars follow the chosen theme too. */
:root[data-theme="licht"] { color-scheme: light; }
:root[data-theme="donker"] { color-scheme: dark; }
