/* Vedetta's shared foundation: the typeface and the colours, for the app and the website, in light and dark.
   The typeface is Archivo (SIL Open Font License: /site/fonts/OFL.txt), served by Vedetta itself, so opening
   Vedetta contacts no other company. One file carries every weight and width; headings use the wide cut.

   Colour has one rule: the interface itself is black, white and grey. Colour appears only when it means
   something about an agent: blue is working, amber is waiting on you, red is a problem, green is finished. The one exception is the mark,
   whose right half is the same blue. */
@font-face { font-family: 'Archivo'; font-style: normal; font-display: swap; font-weight: 100 900; font-stretch: 62% 125%; src: url(/site/fonts/archivo-ext.woff2) format('woff2'); unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF; }
@font-face { font-family: 'Archivo'; font-style: normal; font-display: swap; font-weight: 100 900; font-stretch: 62% 125%; src: url(/site/fonts/archivo.woff2) format('woff2'); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }

:root {
  color-scheme: light;
  --ground: #F5F5F3;
  --surface: #FFFFFF;
  --sunk: #ECECE9;
  --raised: #FFFFFF;
  --ink: #131517;
  --ink-2: #2B2F33;
  --muted: #5F656B;
  --faint: #8A9096;
  --line: #E1E1DD;
  --line-strong: #C9C9C4;
  --soft: #EDEDEA;
  --on-ink: #FFFFFF;

  --signal: #2647E8;
  --signal-tint: #E8ECFE;
  --attention: #A85A06;
  --attention-tint: #FAEEDB;
  --alert: #C22F1D;
  --alert-tint: #FCE8E4;
  --ok: #1A7A50;
  --ok-tint: #E1F3EA;

  --scrim: rgba(19, 21, 23, .44);
  --shadow-pop: 0 1px 2px rgba(19, 21, 23, .06), 0 16px 40px -12px rgba(19, 21, 23, .22);
  --font: 'Archivo', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 18px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme=light]) {
    color-scheme: dark;
    --ground: #0E0F10; --surface: #17191A; --sunk: #0A0B0B; --raised: #1F2224;
    --ink: #F2F3F3; --ink-2: #D9DCDE; --muted: #A2A8AD; --faint: #747A80;
    --line: #272A2D; --line-strong: #3A3E42; --soft: #202325; --on-ink: #0E0F10;
    --signal: #8DA2FF; --signal-tint: #1B2247;
    --attention: #EDA744; --attention-tint: #3A2A10;
    --alert: #FF8672; --alert-tint: #401B15;
    --ok: #55C893; --ok-tint: #12301F;
    --scrim: rgba(0, 0, 0, .62);
    --shadow-pop: 0 0 0 1px #2E3235, 0 24px 60px -12px rgba(0, 0, 0, .7);
  }
}
:root[data-theme=dark] {
  color-scheme: dark;
  --ground: #0E0F10; --surface: #17191A; --sunk: #0A0B0B; --raised: #1F2224;
  --ink: #F2F3F3; --ink-2: #D9DCDE; --muted: #A2A8AD; --faint: #747A80;
  --line: #272A2D; --line-strong: #3A3E42; --soft: #202325; --on-ink: #0E0F10;
  --signal: #8DA2FF; --signal-tint: #1B2247;
  --attention: #EDA744; --attention-tint: #3A2A10;
  --alert: #FF8672; --alert-tint: #401B15;
  --ok: #55C893; --ok-tint: #12301F;
  --scrim: rgba(0, 0, 0, .62);
  --shadow-pop: 0 0 0 1px #2E3235, 0 24px 60px -12px rgba(0, 0, 0, .7);
}

/* The mark: a V in two facets, one in the text colour and one blue. Drawn inline so it follows the theme. */
.mark { width: 26px; height: 26px; flex: none; display: block; }
.mark .a { fill: currentColor; }
.mark .b { fill: var(--signal); }

/* The theme switch: system, light, dark. */
.theme-switch { display: inline-grid; grid-template-columns: repeat(3, 1fr); gap: 2px; padding: 3px; border-radius: 999px; background: var(--soft); }
.theme-switch button { display: grid; place-items: center; width: 34px; height: 28px; border: 0; border-radius: 999px; background: transparent; color: var(--muted); cursor: pointer; padding: 0; }
.theme-switch button:hover { color: var(--ink); }
.theme-switch button[aria-pressed=true] { background: var(--surface); color: var(--ink); box-shadow: 0 0 0 1px var(--line); }
.theme-switch svg { width: 16px; height: 16px; }
