/* Holdfast Turnover: design tokens (Phase 2, 2026-11-11; reskinned 2026-11-22,
   design batch 0).
   The one place a colour, size, radius, shadow or timing is named. Loaded
   before every other stylesheet. Screens and components use these names and
   never a raw value. Light only, by owner decision.

   The older names in app.css (--line, --line-strong, --r, --r-sm, --shadow)
   still work and mean what they meant; new work uses the names below. */

/* Inter variable, Latin plus Latin-1 (Spanish is covered), SIL OFL 1.1.
   Version, source and hash: public/fonts/README.txt. Weights 400 to 700 in use. */
@font-face{
  font-family:"Inter";
  font-style:normal;
  font-weight:100 900;
  font-display:swap;
  src:url("/fonts/inter-var-latin.woff2") format("woff2");
}

:root{
  color-scheme: light;

  /* Neutral: cool, calm. Color is saved for the few things that matter. */
  --ground:#F6F6F3;            /* the page */
  --surface:#FFFFFF;           /* a card, a bar, a sheet, an input */
  --stub:#F1F1ED;              /* quiet fill: table head, hover row, neutral chip, segmented track */
  --ink:#16181D;               /* titles, strong text. Not the primary button */
  --body:#3A3D45;              /* running text */
  --muted:#646771;             /* secondary text: 5.6:1 on white, 5.2:1 on ground */
  --hair:#E5E5E0;              /* dividers and the edge of a card */
  --border-strong:#8B8E97;     /* the edge of an input: 3.3:1 on white */
  --border-mid:#C9CAD0;        /* the edge of a secondary button or a filter chip */
  --track:#E5E5E0;             /* the empty part of a progress bar */
  --scrim:rgba(16,18,24,.45);  /* behind a sheet or dialog */
  --scrim-strong:rgba(16,18,24,.72); /* a label laid over a photo */
  --on-solid:#FFFFFF;          /* text and icons on a solid fill: brand, ok, late, ink */

  /* Brand: Readymark indigo (owner, 2026-11-22). Hover and edge are derived
     from the palette (hover is the midpoint of indigo and deep indigo). To rebrand,
     change these six values and nothing else: every other brand use
     (primary button, selected, link, focus, toggle on, progress, active tab,
     tip card, Checking chip) reads from them. White on --brand is 6.5:1, brand on the ground 6.0:1. */
  --brand:#3F4CD9;                 /* Readymark indigo */
  --brand-hover:#3541C0;
  --brand-press:#2C37A8;
  --brand-ink:#2C37A8;         /* brand colored text on a wash */
  --brand-wash:#ECEEFD;        /* selected row, tip card, Checking chip */
  --brand-edge:#CDD2F6;        /* its edge, and the focus halo */

  /* The old gold family is retired. These names stay as aliases so older
     rules keep working; remove uses batch by batch. */
  --gold:var(--brand);
  --gold-ink:var(--brand-ink);
  --gold-wash:var(--brand-wash);
  --gold-edge:var(--brand-edge);

  /* Status: ink on its wash, with an edge. Color shows as a chip, a dot or a 4px bar. */
  --ok:#17703F;   --ok-wash:#E7F5EC;   --ok-edge:#BEE3CC;
  --warn:#8A5200; --warn-wash:#FFF4DC; --warn-edge:#F3DBA8;
  --late:#B4231A; --late-wash:#FDECEA; --late-edge:#F4BEB8;
  --info:var(--brand-ink); --info-wash:var(--brand-wash); --info-edge:var(--brand-edge);
  /* Thermostat mode (2026-11-26): Cool is blue, Heat is red. White on --cool is 6.4:1, white on --heat 6.6:1; the ink on a wash is above 5.7:1. */
  --cool:#1B5CB8; --cool-ink:#174A99; --cool-wash:#E8F0FC; --cool-edge:#BCD3F3;
  --heat:#B4231A; --heat-ink:#B4231A; --heat-wash:#FDECEA; --heat-edge:#F4BEB8;
  /* 8px dots and 4px bars only. Never text. */
  --ok-dot:#1F9D57; --warn-dot:#E0900B; --late-dot:#D93A2F;

  /* Type: Inter variable, self-hosted (public/fonts), the system faces as fallback, tabular numerals. Nothing a cleaner reads is under 14px. */
  --font:"Inter",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
  --t-label:12px;              /* 600, uppercase, section labels and table heads */
  --t-chip:13px;               /* 600, all chips */
  --t-meta:14px;               /* 400, secondary lines */
  --t-meta-d:13px;             /* desktop tables only */
  --t-ui:15px;                 /* 500 or 600, nav, desktop buttons, segmented, table cells */
  --t-body:16px;               /* 400, text and inputs */
  --t-list:17px;               /* 600, a card or row title */
  --t-title:20px;              /* 700, a sheet, section or desktop page title */
  --t-screen:26px;             /* 700, a phone screen title, the cleaner greeting */
  --t-num:30px;                /* 700, dashboard numbers and money totals */

  /* Spacing */
  --s1:4px; --s2:8px; --s3:12px; --s4:16px; --s5:24px; --s6:32px; --s7:48px; --s8:64px;
  --gutter:16px;

  /* Radius */
  --r-control:8px;             /* buttons on desktop, inputs, segmented track */
  --r-card:12px;               /* cards, lists, phone buttons, photo tiles */
  --r-sheet:16px;              /* sheets, dialogs, the sign in card */
  --r-full:999px;

  /* Elevation: the border does the work, not the shadow. */
  --shadow-paper:0 1px 2px rgba(16,18,24,.05);                                         /* level 1, resting cards */
  --shadow-raised:0 4px 12px -2px rgba(16,18,24,.10),0 2px 4px -2px rgba(16,18,24,.06); /* level 2, menus, toast */
  --shadow-lift:0 -1px 0 var(--hair),0 -8px 20px -12px rgba(16,18,24,.16);             /* bottom dock and tab bar */
  --shadow-sheet:0 24px 48px -12px rgba(16,18,24,.28);                                 /* level 3, sheet and dialog */

  /* Controls: the smallest thing a thumb is asked to hit. */
  --tap:48px;
  --tap-primary:56px;
  --tap-shutter:76px;
  --ctl:48px;                  /* inputs, buttons, segmented, on phone */
  --ctl-lg:56px;
  --row:56px;

  /* Chrome */
  --appbar-h:56px;
  --tabbar-h:64px;
  --safe-top:env(safe-area-inset-top,0px);
  --safe-bottom:env(safe-area-inset-bottom,0px);
  --safe-left:env(safe-area-inset-left,0px);
  --safe-right:env(safe-area-inset-right,0px);

  /* Motion. Everything is off under reduced motion (ui.css). */
  --ease-out:cubic-bezier(.2,.8,.2,1);   /* things arriving */
  --ease-std:cubic-bezier(.4,0,.2,1);    /* color, background and position changes in place */
  --d-press:100ms;
  --d-hover:120ms;
  --d-screen:180ms;
  --d-toast:200ms;
  --d-sheet:240ms;
  --d-success:320ms;

  /* Older names from app.css. They mean the new tokens. */
  --line:var(--hair);
  --line-strong:var(--border-strong);
  --r:var(--r-card);
  --r-sm:var(--r-control);
  --shadow:var(--shadow-paper);
  --sand:var(--border-strong);   /* idle and empty icons */
  --cream:var(--brand-wash);     /* hover fill and selection */
}

/* Density: a manager at a desk gets tighter controls. The team lead and the
   cleaner never get of-desk, so their targets do not shrink. */
@media (min-width:1100px){
  body.of-desk{ --ctl:36px; --ctl-lg:40px; --row:48px }
}
