/*
 * Mercedes-Benz Trucks brand tokens.
 *
 * Source of truth: .design-sync/guidelines/colours.md, derived from
 * "Colours - Websites - Mercedes-Benz Trucks.pdf".
 *
 * ---------------------------------------------------------------------------
 * THIS FILE DECLARES CUSTOM PROPERTIES ONLY. It must never contain a rule that
 * paints something.
 *
 * It is linked by the daimler-truck and daimler-buses layouts and by the admin
 * console. _Layout_Fuso.cshtml deliberately does NOT link it, and Fuso must stay
 * that way: the Fuso brand is out of scope, and the guarantee that it cannot
 * regress is "Fuso fetches none of the new bytes". Keeping this file inert and
 * the painting in light-surface.css keeps that guarantee checkable by diff --
 * see the header of light-surface.css.
 * ---------------------------------------------------------------------------
 *
 * Values are literal hex, not var(--wb-*), for two reasons:
 *   1. The Trucks neutral ramp is NOT the Workbench grey ramp. Trucks Neutral 50
 *      is #F2F2F2; the nearest Workbench step is --wb-grey-90 (#f4f4f4) and
 *      --wb-grey-95 is #f8f8f8. Aliasing would bake in the wrong grey.
 *   2. This file then works even where globals.css is absent.
 * The blues are the exception that proves it: --wb-blue-45 IS #0078D6 and
 * --wb-blue-50 IS #008DFC, exactly.
 */

:root {
  /* ---- Neutral ramp (Trucks). Primacy six: White, 100, 300, 500, 800, Black. */
  --brand-white: #ffffff;
  --brand-neutral-50: #f2f2f2;
  --brand-neutral-100: #e6e6e6;
  --brand-neutral-200: #cccccc;
  --brand-neutral-300: #b3b3b3;
  --brand-neutral-400: #999999;
  --brand-neutral-500: #808080;
  --brand-neutral-600: #666666;
  --brand-neutral-700: #4d4d4d;
  --brand-neutral-800: #373737;
  --brand-neutral-900: #232323;
  --brand-black: #000000;

  /* ---- Pure Blue, the activation colour.
   * 550 Dark is the standard on light surfaces and the only blue usable AS a
   * background. 500 Bright is for DARK surfaces only. Contrast on white:
   * #0078D6 = 4.51:1 (passes AA with 0.01 to spare) / #008DFC = 3.38:1 (FAILS). */
  --brand-blue: #0078d6;
  --brand-blue-bright: #008dfc;
  --brand-blue-dark: #005496;

  /* ---- Indicators. Feedback only, never decorative. */
  --brand-green: #21a330;
  --brand-yellow: #facc00;
  --brand-red: #ff4a4a;
  /* #FF4A4A is 2.5:1 on white, so error TEXT uses the Workbench red-45 (#d92121,
   * 5.01:1). Keep --brand-red for fills and borders. */
  --brand-red-text: #d92121;
  --brand-red-surface: #ffeded;
  --brand-red-ink: #821414;

  /* =======================================================================
   * Semantic layer. Application CSS consumes these, not the ramp above.
   * ===================================================================== */

  --brand-surface: var(--brand-white);
  --brand-surface-sunken: var(--brand-neutral-50);
  --brand-surface-inset: var(--brand-neutral-100);
  --brand-surface-inverse: var(--brand-black);
  --brand-surface-accent: var(--brand-blue);

  /* Ink. Contrast on white: 900 = 15.7:1, 800 = 11.9:1, 600 = 5.74:1.
   * Neutral 500 (#808080) is 3.95:1 and FAILS AA -- borders and large text only,
   * never body copy. */
  --brand-ink: var(--brand-neutral-900);
  --brand-ink-muted: var(--brand-neutral-600);
  --brand-ink-inverse: var(--brand-white);
  --brand-ink-on-accent: var(--brand-white);

  --brand-divider: var(--brand-neutral-100);
  --brand-border: var(--brand-neutral-200);
  --brand-border-strong: var(--brand-neutral-300);

  /* Blue is the activation colour AND the universal hover colour, including for
   * links. An element that is already blue would swap Dark <-> Bright on hover
   * per the guideline; on a light surface that lands on Bright, which fails the
   * same guideline's own AA floor, so it darkens instead. Deliberate deviation. */
  --brand-action: var(--brand-blue);
  --brand-action-hover: var(--brand-blue-dark);
  --brand-action-on-dark: var(--brand-blue-bright);
  --brand-focus: var(--brand-blue);

  /* ---- Typography (guidelines/typography.md) --------------------------------
   * MB Corpo S Title Cond Bold is the CURRENT headline face for HBIG-H4 and is
   * used almost exclusively in uppercase. MB Corpo A Title Cond (a serif) is a
   * reminiscence of the brand's past appearance and is now used for toplines
   * and sublines ONLY. MB Corpo S Text carries everything else -- body copy,
   * captions, and the labels of navigation, buttons, dropdowns and form inputs.
   *
   * TRAP: headline and topline share the family name "MBCorpo Title" on
   * purpose, because mercedes-font.css maps ONE family to TWO different
   * typefaces by weight:
   *     weight 700 -> MBCorpoSTitle-CondBold-Web   (S Title Cond Bold)
   *     weight 400 -> MBCorpoATitleCond-Regular-Web (A Title Cond, serif)
   * So the weight is not decoration here, it SELECTS THE TYPEFACE. A stray
   * `font-weight: 400` on a headline silently swaps it to the retired serif.
   * Always pair --brand-font-headline with 700 and --brand-font-topline with
   * 400. Both faces already ship in wwwroot/assets/fonts and are declared in
   * mercedes-font.css, which every layout links -- no new font bytes. */
  --brand-font-headline: "MBCorpo Title", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --brand-font-topline: "MBCorpo Title", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --brand-font-text: "MBCorpo Text", "Helvetica Neue", Helvetica, Arial, sans-serif;

  /* ---- Framework chrome (guidelines/header.md, footer.md, elements.md) ---- */
  --brand-header-bg: var(--brand-surface-inverse);
  --brand-header-h: 72px;
  --brand-header-h-mobile: 56px;
  --brand-metabar-bg: var(--brand-neutral-50);
  --brand-metabar-h: 40px;
  --brand-btn-h: 48px;
  --brand-btn-h-mobile: 44px;
  --brand-btn-pad-x: 24px;

  /* guidelines/elements.md: "inactive = 30% reduced opacity". Applies to every
   * interactive element, Bootstrap and Workbench alike -- see light-surface.css
   * section 10, which has to override the components' shadow DOM defaults. */
  --brand-disabled-opacity: 0.3;
}
