/*
 * DamageBrief brand layer — loaded FIRST by every layout (the app, the sign-in page, the public landing page):
 * the palette as custom properties and the self-hosted typeface. application.css (the dark Bootstrap theme) and
 * landing.css read these tokens; nothing else defines a brand colour. Logo files and how they are generated:
 * script/brand/build (sources in app/assets/images/brand). Usage notes: docs/changes/brand.md.
 */

/* Inter (SIL OFL 1.1 — app/assets/fonts/inter/OFL.txt), variable weight 100–900, self-hosted (the CSP allows fonts
   from this origin only) and digested by Propshaft (app/assets/fonts/inter → /assets/inter/…-<digest>.woff2, cached
   for good). Two subsets: the browser fetches latin-ext only for a page that shows those letters —
   Lithuanian ą č ę ė į š ų ū ž, Polish, Czech, Hungarian… — so client names and cities render in Inter too. */
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/assets/inter/inter-latin-wght-normal-1f021a24.woff2") format("woff2-variations");
  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;
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/assets/inter/inter-latin-ext-wght-normal-65edaaef.woff2") format("woff2-variations");
  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;
}

:root {
  /* Blue — trust, the tile, actions. 500 is the app's primary (buttons); 300/400 read on dark, 600 on light. */
  --db-blue-900: #0f2140;
  --db-blue-700: #2453a6;
  --db-blue-600: #2f6fd0;
  --db-blue-500: #3f7fd6;
  --db-blue-400: #5b9bff;
  --db-blue-300: #82b4ff;
  --db-blue-100: #dce9fb;

  /* Amber — the dented corner: damage, attention. An accent only: never a large area, never body text. */
  --db-amber-500: #f5a524;
  --db-amber-300: #ffc861;

  /* Slate — the dark surfaces of the app, and its text. 900 is the page, 850 raised surfaces, 700 borders. */
  --db-slate-950: #101318;
  --db-slate-900: #15181e;
  --db-slate-850: #1c2128;
  --db-slate-800: #242a33;
  --db-slate-700: #2b313b;
  --db-slate-500: #69727f;
  --db-slate-400: #8b95a3;
  --db-slate-200: #c7ced8;
  --db-slate-100: #e8edf3;

  /* Paper — the report itself: ink on a cool white. */
  --db-paper: #f6f8fc;
  --db-paper-line: #dbe3ee;
  --db-ink: #0f1b2d;
  --db-ink-soft: #4a5a70;

  /* The mark's tile, for anything that echoes it. */
  --db-tile: linear-gradient(135deg, #4a8ae6 0%, #2453a6 100%);

  --db-font-sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --db-font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

/* The wordmark as live text (LayoutHelper#brand_wordmark): sharp at any size, selectable, in the page's font.
   Two tones of the one name — on dark backgrounds; .wordmark-on-light flips them for paper. */
.wordmark { font-family: var(--db-font-sans); font-weight: 700; letter-spacing: -0.012em; white-space: nowrap; }
.wordmark-a { color: var(--db-slate-100); }
.wordmark-b { color: var(--db-blue-300); }
.wordmark-on-light .wordmark-a { color: var(--db-ink); }
.wordmark-on-light .wordmark-b { color: var(--db-blue-600); }
.brand-mark { display: block; flex: none; }
