/* Copied from the website design hand-off (HP-202). The only change: the two theme
   selectors, so every page follows the visitor's light or dark setting
   (.rl-light became :root, .rl-dark became a prefers-color-scheme: dark block).

   RoutineLab design tokens: the one source every board in this canvas reads.
   Colours are the app's asset catalog (Assets.xcassets/Colors), by theme.
   A screen's root takes .rl-light or .rl-dark; a sheet adds only variables of
   its own (a keyboard, a chart), never a new value for one of these. */

:root {
  --font: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', system-ui, 'Helvetica Neue', sans-serif;
  --font-num: ui-rounded, 'SF Pro Rounded', -apple-system, system-ui, sans-serif;
  --font-note: ui-serif, 'New York', Georgia, serif;

  /* the canvas around the phones, not part of the app */
  --board: #E3E5EA;
  --board-text: #0B0B0C;
  --board-num: #1F4BE0;
  --board-tag: #5C5D61;
  --board-frame: 0 0 0 1px rgba(0,0,0,.08), 0 24px 48px rgba(0,0,0,.12);
}

:root {
  color-scheme: light dark;

  /* surfaces */
  --bg: #F4F5F7;          /* background: every screen */
  --card: #ECEDF0;        /* card: a dashboard row */
  --el: #FFFFFF;          /* elevated: a content card */
  --el2: #F7F8FA;         /* elevatedSecondary: a tile set into a card */
  --sheetbg: #FFFFFF;     /* sheet: a sheet's ground */
  --shc: #F4F5F7;         /* sheetCard: a choice set into a sheet */
  --back: #A4A5A9;        /* the page dimmed behind a sheet, flattened */
  --scrim: rgba(11,11,12,.32);

  /* text */
  --t1: #0B0B0C;          /* primary */
  --t2: #5F5F61;          /* secondary, the quietest text a user reads */
  --t3: #A9AAAC;          /* tertiary: chevrons, rings, placeholders, never read text */
  --div: #E4E5E7;

  /* accent */
  --acc: #2B5CFF;
  --acct: #1F4BE0;        /* accent text on --accm */
  --accm: #EAF0FF;
  --accs: rgba(43,92,255,.22);
  --onacc: #FFFFFF;

  /* on a habit's full colour: white in light, near black in dark */
  --onhabit: #FFFFFF;

  /* states */
  --danger: #D92D20;
  --dangerm: rgba(217,45,32,.10);
  --ok: #2D7A4F;
  --warn: #B8762A;
  --warm: #D4581C;        /* a streak's flame */
  --arch: #C8C8C8;        /* a day after the archive day */
  --next: #A9AAAC;        /* a day to come: an empty ring */

  /* controls */
  --ghost: rgba(11,11,12,.06);
  --ghostb: rgba(11,11,12,.08);
  --seg: rgba(11,11,12,.16);
  --lens: #FFFFFF;
  --lensh: 0 1px 4px rgba(0,0,0,.14), 0 0 0 .5px rgba(0,0,0,.04);
  --raised: #FFFFFF;
  --raisedb: rgba(11,11,12,0);
  --orbit: rgba(11,11,12,.14);

  /* elevation */
  --shadow: 0 2px 8px rgba(0,0,0,.06);
  --pop: 0 12px 32px rgba(0,0,0,.18), 0 0 0 1px rgba(0,0,0,.05);
  --sheetsh: 0 -10px 34px rgba(0,0,0,.16), 0 0 0 1px rgba(0,0,0,.05);
  --ctashadow: inset 0 1px 0 rgba(255,255,255,.35), 0 8px 20px rgba(43,92,255,.28);

  /* glass, drawn where iOS draws Liquid Glass */
  --glass: rgba(255,255,255,.62);
  --glassfx: blur(24px) saturate(1.8);
  --gshadow: inset 0 1px 0 rgba(255,255,255,.95), inset 0 0 0 .5px rgba(255,255,255,.6), 0 0 0 .5px rgba(0,0,0,.06), 0 8px 24px rgba(0,0,0,.10);
  --glasslens: rgba(255,255,255,.94);
}

@media (prefers-color-scheme: dark) {
:root {
  --bg: #0A0B0D;
  --card: #0F1114;
  --el: #15171B;
  --el2: #1C1E23;
  --sheetbg: #1C1E23;
  --shc: #26282E;
  --back: #000000;
  --scrim: rgba(0,0,0,.55);

  --t1: #FCFCFC;
  --t2: #ADADAD;
  --t3: #8C8C8C;
  --div: #2B2C2C;

  --acc: #5B84FF;
  --acct: #9DB5FF;
  --accm: rgba(91,132,255,.16);
  --accs: rgba(91,132,255,.30);
  --onacc: #0A0B0D;

  --onhabit: #0A0B0D;

  --danger: #FF6B5E;
  --dangerm: rgba(255,107,94,.14);
  --ok: #4FAE7C;
  --warn: #D99A54;
  --warm: #FF9A5C;
  --arch: #3A3A3A;
  --next: #8C8C8C;

  --ghost: rgba(255,255,255,.08);
  --ghostb: rgba(255,255,255,.12);
  --seg: rgba(255,255,255,.22);
  --lens: #464951;
  --lensh: 0 1px 4px rgba(0,0,0,.4);
  --raised: rgba(255,255,255,.08);
  --raisedb: rgba(255,255,255,.12);
  --orbit: rgba(255,255,255,.16);

  --shadow: inset 0 0 0 1px rgba(255,255,255,.06);
  --pop: 0 12px 32px rgba(0,0,0,.6), inset 0 0 0 1px rgba(255,255,255,.14);
  --sheetsh: 0 -10px 34px rgba(0,0,0,.6), 0 0 0 1px rgba(255,255,255,.14);
  --ctashadow: inset 0 1px 0 rgba(255,255,255,.3), 0 10px 28px rgba(91,132,255,.4);

  --glass: rgba(44,46,52,.55);
  --glassfx: blur(24px) saturate(1.6);
  --gshadow: inset 0 1px 0 rgba(255,255,255,.18), inset 0 0 0 .5px rgba(255,255,255,.10), 0 8px 24px rgba(0,0,0,.45);
  --glasslens: rgba(255,255,255,.15);
}
}
