/* ------------------------------------------------------------------
   Typography - tokens + base type styles
   Source of truth: Figma "Untitled" file, node 23:172 (type specimen).
   ------------------------------------------------------------------ */

/* Self-hosted fonts. Files live at /SiteSpecific/CustomContent/fonts/.
   URLs are all-lowercase ON PURPOSE: the IIS "LowerCaseRule" redirects any URL
   containing capitals, and that redirect breaks over HTTPS (mixed-content block).
   A lowercase URL skips the rule; Windows/IIS matches the files case-insensitively,
   so the on-disk mixed-case filenames still resolve. */

/* BDO Grotesk - static TTFs, one face per weight */
@font-face {
  font-family: "BDO Grotesk";
  src: url("/sitespecific/customcontent/fonts/bdogrotesk-regular-bf648a656fd543a.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "BDO Grotesk";
  src: url("/sitespecific/customcontent/fonts/bdogrotesk-medium-bf648a656fc86b8.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

/* DemiBold - the weight all headings use in the design */
@font-face {
  font-family: "BDO Grotesk";
  src: url("/sitespecific/customcontent/fonts/bdogrotesk-demibold-bf648a656f9c460.ttf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "BDO Grotesk";
  src: url("/sitespecific/customcontent/fonts/bdogrotesk-bold-bf648a656f8559f.ttf") format("truetype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Font families - one family for everything on this site */
  --font-body: "BDO Grotesk", "Helvetica Neue", Arial, sans-serif;
  --font-heading: var(--font-body);

  /* Font weights (named, so intent is clear at call sites) */
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-demibold: 600;
  --weight-bold: 700;

  --text-color: var(--ink, #ffffff);
  --text-muted: var(--ink-muted, rgba(255, 255, 255, 0.5));

  /* Type scale. Figma values are the DESKTOP end of each clamp; the mobile
     minimums are ours (48px h1 is unusable on a phone). Above ~960px these
     resolve to the exact designed sizes. */
  --h1: clamp(32px, 5vw,   48px);
  --h2: clamp(28px, 4.2vw, 40px);
  --h3: clamp(20px, 2.6vw, 24px);

  --text-lg: clamp(17px, 1.6vw, 20px);  /* lead / intro paragraph */
  --text-base: 16px;                    /* default body copy */
  --text-sm: 14px;                    /* default body copy */


  /* Line heights */
  --leading-tight: 1;    /* h1, h2 - "leading-none" in the design */
  --leading-body: 1.6;   /* h3 and all body copy */

  --tracking-heading: -0.03em;

  /* Vertical rhythm of the specimen stack */
  --type-stack-gap: 36px;

  /* Button label size (see buttons.css) */
  --button-text: 16px;
}

/* Default everything to the body font + base paragraph type settings */
body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: var(--weight-regular);
  line-height: var(--leading-body);
  letter-spacing: 0;
}

h4, h5, h6,
p, a, button, input, textarea, select {
  font-family: inherit;
}

/* Headings: same family, DemiBold, tightened tracking */
h1, h2, h3 {
  font-family: var(--font-heading);
  font-weight: var(--weight-demibold);
  letter-spacing: var(--tracking-heading);
}

h1 {
  font-size: var(--h1);
  line-height: var(--leading-tight);
}

h2 {
  font-size: var(--h2);
  line-height: var(--leading-tight);
}

h3 {
  font-size: var(--h3);
  line-height: var(--leading-body);
}

/* Body copy ------------------------------------------------------- */

/* Lead paragraph - the 20px intro copy */
.body-lg {
  font-size: var(--text-lg);
  font-weight: var(--weight-regular);
  line-height: var(--leading-body);
  letter-spacing: 0;
}

/* Default body copy - 16px */
.body-md {
  font-size: var(--text-base);
  font-weight: var(--weight-regular);
  line-height: var(--leading-body);
  letter-spacing: 0;
}

/* Both paragraph styles are drawn at 50% white in the design. Applied as an
   opt-in class so headings and CTAs keep full contrast. */
.text-muted {
  color: var(--text-muted);
}

/* The same muted copy on a light panel - 50% BLACK. Needed because
   .text-muted is white and vanishes on --surface-panel-invert. Same
   opt-in-modifier shape as .cc-btn--dark in buttons.css, which exists for
   exactly the same reason. */
.text-muted--invert {
  color: var(--ink-invert-muted, rgba(0, 0, 0, 0.5));
}

/* Layout helper ---------------------------------------------------- */

/* The specimen's own container: a 36px-gap vertical stack, left aligned. */
.type-stack {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--type-stack-gap);
}
