/* Magpie design tokens: Material 3 color roles, type, shape, elevation and
   motion. Every value app.css uses comes from here. On Android 12 and up
   js/theme.js writes the 27 roles from primary to inverse-primary inline on
   <html> from the phone's own palette; error, ok, warn and scrim never move. */

:root {
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "Roboto Mono", "Droid Sans Mono", Menlo, Consolas, monospace;

  --type-headline-medium: 400 1.75rem/2.25rem var(--font);
  --type-headline-small: 400 1.5rem/2rem var(--font);
  --type-title-large: 400 1.375rem/1.75rem var(--font);
  --type-title-medium: 500 1rem/1.5rem var(--font);
  --type-title-small: 500 0.875rem/1.25rem var(--font);
  --type-body-large: 400 1rem/1.5rem var(--font);
  --type-body-medium: 400 0.875rem/1.25rem var(--font);
  --type-body-small: 400 0.75rem/1rem var(--font);
  --type-label-large: 500 0.875rem/1.25rem var(--font);
  --type-label-medium: 500 0.75rem/1rem var(--font);

  --track-title-medium: 0.009em;
  --track-title-small: 0.007em;
  --track-body-large: 0.031em;
  --track-body-medium: 0.018em;
  --track-body-small: 0.033em;
  --track-label-large: 0.007em;
  --track-label-medium: 0.042em;

  --shape-xs: 4px;
  --shape-sm: 8px;
  --shape-md: 12px;
  --shape-lg: 16px;
  --shape-xl: 28px;
  --shape-full: 9999px;

  --elev-1: 0 1px 2px rgb(0 0 0 / 0.3), 0 1px 3px 1px rgb(0 0 0 / 0.15);
  --elev-3: 0 1px 3px rgb(0 0 0 / 0.3), 0 4px 8px 3px rgb(0 0 0 / 0.15);

  --ease-standard: cubic-bezier(0.2, 0, 0, 1);
  --ease-decel: cubic-bezier(0.05, 0.7, 0.1, 1);
  --dur-short: 150ms;
  --dur-medium: 300ms;

  --state-hover: 0.08;
  --state-press: 0.1;

  /* The Android app sends --inset-* (js/shell.js); a browser and iOS fall back to env(). */
  --safe-top: var(--inset-top, env(safe-area-inset-top, 0px));
  --safe-right: var(--inset-right, env(safe-area-inset-right, 0px));
  --safe-bottom: var(--inset-bottom, env(safe-area-inset-bottom, 0px));
  --safe-left: var(--inset-left, env(safe-area-inset-left, 0px));
  /* The height of a navigation bar with buttons on it, from the shell. 0 with the gesture handle. */
  --nav-bar: 0px;

  color-scheme: light;

  --md-primary: #00687a;
  --md-on-primary: #ffffff;
  --md-primary-container: #abedff;
  --md-on-primary-container: #001f27;
  --md-secondary: #45636b;
  --md-on-secondary: #ffffff;
  --md-secondary-container: #c7e8f2;
  --md-on-secondary-container: #001f26;
  --md-tertiary: #545d7e;
  --md-on-tertiary: #ffffff;
  --md-tertiary-container: #dbe1ff;
  --md-on-tertiary-container: #0c1b36;
  --md-surface: #f3fbfd;
  --md-surface-dim: #d4dbde;
  --md-surface-bright: #f3fbfd;
  --md-surface-container-lowest: #ffffff;
  --md-surface-container-low: #edf5f7;
  --md-surface-container: #e7eff2;
  --md-surface-container-high: #e2e9ec;
  --md-surface-container-highest: #dce4e6;
  --md-on-surface: #171c1e;
  --md-on-surface-variant: #3b494d;
  --md-outline: #6b797e;
  --md-outline-variant: #bac9ce;
  --md-inverse-surface: #2b3133;
  --md-inverse-on-surface: #eaf2f4;
  --md-inverse-primary: #58d6f3;

  --md-error: #ba1a1a;
  --md-on-error: #ffffff;
  --md-error-container: #ffdad6;
  --md-on-error-container: #410002;
  --md-ok: #1b6c3a;
  --md-ok-container: #a3f5b8;
  --md-on-ok-container: #00210c;
  --md-warn-container: #ffdf9e;
  --md-on-warn-container: #261a00;
  --md-scrim: #000000;
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;

    --md-primary: #58d6f3;
    --md-on-primary: #003640;
    --md-primary-container: #004e5c;
    --md-on-primary-container: #abedff;
    --md-secondary: #acccd5;
    --md-on-secondary: #16343c;
    --md-secondary-container: #2d4b53;
    --md-on-secondary-container: #c7e8f2;
    --md-tertiary: #bcc5ea;
    --md-on-tertiary: #24304d;
    --md-tertiary-container: #3c4665;
    --md-on-tertiary-container: #dbe1ff;
    --md-surface: #0d1416;
    --md-surface-dim: #0d1416;
    --md-surface-bright: #343a3c;
    --md-surface-container-lowest: #071012;
    --md-surface-container-low: #171c1e;
    --md-surface-container: #1b2122;
    --md-surface-container-high: #252b2d;
    --md-surface-container-highest: #303638;
    --md-on-surface: #dce4e6;
    --md-on-surface-variant: #bac9ce;
    --md-outline: #849398;
    --md-outline-variant: #3b494d;
    --md-inverse-surface: #dce4e6;
    --md-inverse-on-surface: #2b3133;
    --md-inverse-primary: #00687a;

    --md-error: #ffb4ab;
    --md-on-error: #690005;
    --md-error-container: #93000a;
    --md-on-error-container: #ffdad6;
    --md-ok: #7fda9a;
    --md-ok-container: #00522a;
    --md-on-ok-container: #a3f5b8;
    --md-warn-container: #5c4300;
    --md-on-warn-container: #ffdf9e;
    --md-scrim: #000000;
  }
}
