/* ===================================================================
   MTS Corp — v2.2 identity application ("The Forward Mark")
   ===================================================================
   Applies the v2.2 brand to the marketing site. Spec of record:
   Mts.Branding/StyleGuide/mts-style-guide.html. Palette tokens come
   from /_content/Mts.Branding/branding/brand.css (--mts-navy,
   --mts-heritage-red, --mts-paper, ...).

   Load order: theme style.css -> brand.css -> THIS FILE, so these
   rules win on document order. The premium theme is never edited;
   everything here rides its Bootstrap 5.3 CSS variables.
*/

:root,
[data-bs-theme="light"] {
  /* Registrar Navy as primary moved INTO brand.css (decision D3, 2026-08-18)
     when the product app adopted it too, so the local override that used to
     live here is gone — both properties now inherit it from the shared file. */

  /* Page ground: --mts-page-bg, the same near-white the product app's
     login/app chrome uses, so marketing and product read as one
     product family. Alternatives: #ffffff (pure white) or #FCFAF4
     (the guide's warm certificate ground). */
  --bs-body-bg:            var(--mts-page-bg);
  --bs-body-bg-rgb:        250, 251, 252;
  --bs-body-color:         var(--mts-ink);
  --bs-body-color-rgb:     20, 17, 16;
  --bs-emphasis-color:     var(--mts-ink);
  --bs-emphasis-color-rgb: 20, 17, 16;
  --bs-secondary-color:    var(--mts-text-muted);
  --bs-secondary-color-rgb: 108, 117, 125;

  /* Tints and rules follow the ground's temperature. The page ground
     is the product app's COOL near-white, so the warm Record Paper
     rule (#cfc6b3) would read khaki on form borders and checkboxes —
     these use the product's cool neutrals instead. Record Paper stays
     the paper-moment color (certificates, print, the style guide). */
  --bs-light:            var(--mts-surface);
  --bs-light-rgb:        237, 239, 243;
  --bs-tertiary-bg:      var(--mts-surface);
  --bs-tertiary-bg-rgb:  237, 239, 243;
  --bs-secondary-bg:     var(--mts-surface);
  --bs-secondary-bg-rgb: 237, 239, 243;
  --bs-border-color:     var(--mts-border);
  --bs-gray-200:         var(--mts-border); /* theme borders (sticky header etc.) */

  /* Structure: headings and dark grounds are Registrar Navy */
  --bs-dark:          var(--mts-navy);
  --bs-dark-rgb:      22, 40, 60;
  --bs-heading-color: var(--mts-navy);

  /* Links: REVISED 2026-08-18 (decision D2). This site originally made every
     link Heritage Red. The rule is now split by role and shared with the
     product app — navigation/utility links are Registrar Blue, and Heritage
     Red + the typed chevron is reserved for forward motion (hero CTAs,
     "Continue", breadcrumbs) via .chev-next. See brand.css for the reasoning:
     an all-red link layer reads as alarm in the app's dense tables, and the
     scarcity is what makes the red chevron mean "what's next" at all.
     Both values now come from brand.css; nothing is set here. */

  /* Type comes from brand.css's --bs-body-font-family (self-hosted Archivo). */
}

/* On navy grounds (footer), links are paper — red-on-navy fails the
   guide's 3:1 contrast floor and is reserved for the inverted lockup. */
[data-bs-theme="dark"] {
  --bs-link-color:           var(--mts-paper);
  --bs-link-color-rgb:       243, 238, 227;
  --bs-link-hover-color:     #ffffff;
  --bs-link-hover-color-rgb: 255, 255, 255;
}

/* Archivo everywhere the theme hardcoded its old faces (never loaded). */
h1, .h1, h2, .h2, h3, .h3, h4, .h4, h5, .h5, h6, .h6 {
  font-family: "Archivo", var(--bs-body-font-family);
}
.font-base    { font-family: "Archivo", var(--bs-body-font-family) !important; }
.font-heading { font-family: "Archivo", var(--bs-body-font-family) !important; }
.btn          { font-family: "Archivo", var(--bs-body-font-family); }

/* Display type.
   DELIBERATE DEVIATION from the guide's ramp (Display = Archivo Black
   900 / tracking -0.01em): that specimen is set at 40px, but the hero
   renders at 64px, where 900 with negative tracking closes up the
   counters and shouts. Bold 700 at default tracking is the same
   authority with air in it. Size, not weight, now separates Display
   from Heading. Weight 800 (the wordmark's own) is the middle option
   if this reads too light. */
.display-1, .display-2, .display-3, .display-4, .display-5, .display-6 {
  font-family: "Archivo", var(--bs-body-font-family);
  font-weight: 700;
  letter-spacing: 0;
}

/* .chev-next — "the next" affordance — now lives in brand.css so the product
   app and this site define it once. It also carries the Heritage Red color
   there, which used to arrive here via the site-wide red link rule (removed
   above, decision D2). Marketing CTAs keep their red chevron; ordinary
   navigation links are Registrar Blue. */

/* On navy grounds the chevron would be red-on-navy (2.3:1), which the guide
   reserves for the inverted lockup — so it goes paper along with the link. */
[data-bs-theme="dark"] .chev-next,
.bg-dark .chev-next,
footer .chev-next { color: var(--mts-paper); }
[data-bs-theme="dark"] .chev-next:hover,
.bg-dark .chev-next:hover,
footer .chev-next:hover { color: #ffffff; }
