/*
 * Valinameh tokens for the React package.
 *
 * 1. The real tokens live in handoff/tokens/tokens.css (written by the foundations chapter).
 *    This import pulls them in when the package sits inside handoff/ next to that folder.
 *    If you copy the package somewhere else, copy tokens.css with it or remove this line.
 * 2. The block after it is a fallback layer at zero specificity (:where), so the imported
 *    tokens always win. It keeps Storybook readable when the tokens file is missing.
 *
 * Components read only these custom properties. They never hold a colour of their own.
 */
@import "../../tokens/tokens.css";

:where(:root) {
  --paper: #F6F1E7;
  --paper-2: #EEE6D6;
  --sheet: #FFFDF8;
  --rule: #E3D9C7;
  --ink: #2B2A2E;
  --ink-2: #5F5A55;
  --ink-3: #857E76;
  --accent: #3D63AE;
  --accent-ink: #FFFDF8;
  --red: #B8433A;
  --ok: #5E8B6E;
  --marker: #F5D547;
  --on-marker: #2B2A2E;
  --tape: rgba(232, 222, 198, .86);
  --shade: rgba(84, 62, 40, .16);

  /* notes keep day inks in both themes (paper islands) */
  --note-ok-bg: #DCE8DA;
  --note-ok-ink: #3F6650;
  --note-warn-bg: #F7E7B4;
  --note-warn-ink: #7A5A12;
  --note-error-bg: #F4D6D0;
  --note-error-ink: #8E2F27;
  --note-text: #2B2A2E;

  /* score bands: always paired with a word, never colour alone */
  --band-low: #CAD8EA;
  --band-mid: #F5DF86;
  --band-high: #DCE8DA;

  --f-head: 'Abar', 'Ravi', Tahoma, sans-serif;
  --f-body: 'Ravi', 'Abar', Tahoma, sans-serif;
  --fs-xs: 11px;
  --fs-sm: 13.5px;
  --fs-md: 17px;
  --fs-lg: 21px;
  --fs-xl: 26.5px;
  --fw-regular: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;
  --sp-1: 4px;
  --sp-2: 8px;
  --sp-3: 12px;
  --sp-4: 16px;
  --sp-5: 24px;
  --sp-6: 32px;
  --m-tap: 120ms;
  --m-hover: 180ms;
  --ease-out: cubic-bezier(.2, .7, .2, 1);
  --focus: var(--accent);
  --target-min: 44px;
}

:where([data-theme="dark"]) {
  --paper: #1D2446;
  --paper-2: #232B52;
  --sheet: #29315E;
  --rule: #39436F;
  --ink: #F3EDE2;
  --ink-2: #C9C1B5;
  --ink-3: #9C95AA;
  --accent: #9DB2EE;
  --accent-ink: #1D2446;
  --red: #EE8A7E;
  --ok: #9CC3A8;
  --marker: #E8C93F;
  --on-marker: #1D2446;
  --tape: rgba(240, 230, 205, .24);
  --shade: rgba(0, 0, 16, .42);
  color-scheme: dark;
}
