/* Quotecycle design tokens v1.0 (S04, 25 Nov 2026)
   ONE file. Every colour, size, space, radius and shadow in the app comes from here.
   Company brand (logo, primary colour) is a separate layer: --brand-* below,
   later read from companies.brand (contract 01). Nothing else may hard-code a value. */

@font-face { font-family: "Plex"; font-weight: 400; font-display: swap; src: url("../fonts/ibm-plex-sans-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Plex"; font-weight: 500; font-display: swap; src: url("../fonts/ibm-plex-sans-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Plex"; font-weight: 600; font-display: swap; src: url("../fonts/ibm-plex-sans-latin-600-normal.woff2") format("woff2"); }

:root {
  /* ---- Slate neutrals ---- */
  --slate-25:  #FBFCFD;
  --slate-50:  #F6F8FA;   /* page */
  --slate-100: #EDF0F4;   /* quiet fills, table header */
  --slate-200: #E0E5EB;   /* thin borders */
  --slate-300: #C9D1DA;   /* input borders */
  --slate-400: #8D99A8;   /* decorative only, never text */
  --slate-500: #657181;   /* secondary text (5.0:1 on white) */
  --slate-600: #4A5565;   /* body secondary */
  --slate-700: #354050;
  --slate-800: #222B38;
  --slate-900: #141A23;   /* primary text */
  --white: #FFFFFF;

  /* ---- Accent: the APP accent (Aurora blue is the first company's brand colour too) ---- */
  --accent:        #135FAC;   /* 6.4:1 on white */
  --accent-strong: #0E4B8A;   /* hover, pressed */
  --accent-tint:   #E7F0F9;   /* selected rows, soft fills */
  --accent-edge:   #B7D0EA;   /* tint borders */
  --on-accent:     #FFFFFF;

  /* ---- Company brand layer (recipient page, PDF, email). Set per company. ---- */
  --brand-primary: #135FAC;
  --brand-tint:    #E7F0F9;

  /* ---- Status (quiet tints; text colours all pass AA on their tint) ---- */
  --st-draft-bg:    #EDF0F4; --st-draft-fg:    #4A5565;
  --st-sent-bg:     #E7F0F9; --st-sent-fg:     #0E4B8A;
  --st-accepted-bg: #E3F3EA; --st-accepted-fg: #17673A;
  --st-complete-bg: #DDE8E4; --st-complete-fg: #2B5A4C;
  --st-warn-bg:     #FBF0D9; --st-warn-fg:     #7A4E06;
  --st-bad-bg:      #FAE6E4; --st-bad-fg:      #9A2A20;
  --live: #1E8E4E;          /* the small "Live now" dot */

  /* ---- Staff-only band (what a recipient never sees) ---- */
  --staff-bg:   #F5F2EC;
  --staff-edge: #E3DDD0;
  --staff-fg:   #5A5142;    /* 6.9:1 on staff-bg */

  /* ---- Feedback ---- */
  --focus: #135FAC;         /* focus ring colour */
  --danger: #B3261E;

  /* ---- Type ---- */
  --font: "Plex", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --text-xs: 0.75rem;     /* 12  small print, chips */
  --text-sm: 0.8125rem;   /* 13  labels, table */
  --text-md: 0.9375rem;   /* 15  body */
  --text-lg: 1.0625rem;   /* 17  section titles */
  --text-xl: 1.375rem;    /* 22  page title */
  --text-2xl: 1.875rem;   /* 30  big figures */
  --lh-tight: 1.25; --lh-body: 1.5;
  --weight-regular: 400; --weight-medium: 500; --weight-strong: 600;
  --ui-scale: 1;           /* user can nudge text size on the component page */

  /* ---- Space (4px base) ---- */
  --s-1: 4px;  --s-2: 8px;  --s-3: 12px; --s-4: 16px; --s-5: 24px;
  --s-6: 32px; --s-7: 48px; --s-8: 64px;

  /* ---- Radius ---- */
  --r-sm: 3px; --r-md: 5px; --r-lg: 8px; --r-pill: 999px;

  /* ---- Shadows (barely visible) ---- */
  --shadow-1: 0 1px 2px rgba(20, 26, 35, 0.05);
  --shadow-2: 0 2px 8px rgba(20, 26, 35, 0.07);
  --shadow-3: 0 12px 32px rgba(20, 26, 35, 0.14);   /* dialogs only */

  /* ---- Layout ---- */
  --rail-w: 220px;
  --topbar-h: 56px;
  --content-w: 900px;
  --control-h: 36px;      /* default control height */
  --control-h-lg: 44px;   /* recipient page and touch */

  /* ---- Motion ---- */
  --ease: cubic-bezier(0.2, 0, 0, 1);
  --dur: 140ms;
}

@media (prefers-reduced-motion: reduce) { :root { --dur: 0ms; } }
