
/* @font-face lives in functions.php: the font URL must be resolved
   through get_stylesheet_directory_uri(), not a site-root path. */

/* ---------- Reset ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

/*
 * Reduced motion: shorten transitions rather than deleting them.
 *
 * A blanket 0.01ms kill removes the feedback that tells someone a button
 * responded, a menu opened, or an accordion changed state. 1ms would be the
 * same thing by another name. Instead motion is cut to a fast, non-vestibular
 * fade, and only the genuinely movement-based effects are removed: smooth
 * scrolling, and the hero video, which HeroVideo.astro drops entirely.
 */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 80ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 80ms !important;
  }
}

body,
h1,
h2,
h3,
h4,
p,
figure,
blockquote,
dl,
dd,
ul,
ol {
  margin: 0;
}

ul[class],
ol[class] {
  list-style: none;
  padding: 0;
}

img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
}

input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}

/* ---------- Base ---------- */

body {
  background: var(--msc-off-white);
  color: var(--msc-near-black);
  font-family: var(--msc-font-body);
  font-size: var(--msc-size-body);
  line-height: var(--msc-leading-body);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1,
h2 {
  font-family: var(--msc-font-display);
  font-weight: 400;
  line-height: var(--msc-leading-tight);
  letter-spacing: -0.011em;
  text-wrap: balance;
  /* "Dallas–Fort Worth" is one place name. Browsers treat the en dash as a
     break opportunity, which strands "Dallas–" at the end of a line. */
  word-break: keep-all;
}

.nowrap {
  white-space: nowrap;
}

h1 {
  font-size: var(--msc-size-h1);
}

h2 {
  font-size: var(--msc-size-h2);
}

h3,
h4 {
  font-family: var(--msc-font-body);
  font-weight: 600;
  line-height: var(--msc-leading-snug);
  text-wrap: balance;
}

h3 {
  font-size: var(--msc-size-h3);
}

h4 {
  font-size: var(--msc-size-body-lg);
}

p {
  text-wrap: pretty;
}

a {
  color: inherit;
}

strong,
b {
  font-weight: 600;
}

/* Focus ring. WCAG 2.2 asks for 3:1 against the adjacent surface, and gold
   only clears that on the dark greens: it is 1.61:1 on Off White, 1.81:1 on
   white and 2.51:1 on sage. Same problem the eyebrow has, so the same three
   cases and the same colors solve it.

   Default is red, because most of the page is a light surface, and the
   header is Off White too:
     red on Off White   6.15:1
     red on white       6.90:1
     gold on green-dark 6.56:1   (.section--dark, .footer)
     gold on green-deep 8.11:1   (.callbar)
     white on sage      4.55:1   (.section--sage) */
:focus-visible {
  outline: 2px solid var(--msc-red);
  outline-offset: 3px;
  border-radius: 2px;
}

.section--dark :focus-visible,
.footer :focus-visible,
.callbar :focus-visible {
  outline-color: var(--msc-gold);
}

.section--sage :focus-visible {
  outline-color: var(--msc-white);
}

/* The callbar's own buttons are red on green-deep. A gold ring on a red
   button is 3.81:1, which passes; red on red would vanish. */
.callbar__call:focus-visible,
.callbar__quote:focus-visible {
  outline-color: var(--msc-gold);
}

::selection {
  background: var(--msc-gold);
  color: var(--msc-green-dark);
}

/* ---------- Layout primitives ---------- */

.container {
  width: 100%;
  max-width: var(--msc-container);
  margin-inline: auto;
  padding-inline: var(--msc-gutter);
}

.container--wide {
  max-width: var(--msc-container-wide);
}

.section {
  padding-block: var(--msc-section-y);
}

.section--dark {
  background: var(--msc-green-dark);
  color: var(--msc-white);
}

.section--sage {
  background: var(--msc-green-sage);
  color: var(--msc-white);
}

.section--light {
  background: var(--msc-off-white);
  color: var(--msc-near-black);
}

.section--white {
  background: var(--msc-white);
  color: var(--msc-near-black);
}

.measure {
  max-width: var(--msc-measure);
}

.measure--narrow {
  max-width: var(--msc-measure-narrow);
}

.stack > * + * {
  margin-block-start: var(--msc-space-md);
}

.stack-lg > * + * {
  margin-block-start: var(--msc-space-lg);
}

/* Section heading + intro pairing used across pages */
.section-head {
  max-width: var(--msc-measure);
  margin-block-end: var(--msc-space-2xl);
}

.section-head > p {
  margin-block-start: var(--msc-space-md);
  font-size: var(--msc-size-body-lg);
  opacity: 0.92;
}

.eyebrow {
  font-size: var(--msc-size-caption);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: none;
  color: var(--msc-gold);
  margin-block-end: var(--msc-space-sm);
}

.section--light .eyebrow,
.section--white .eyebrow {
  /* Gold fails contrast on light surfaces (brief section 3). Never gold text
     on white: use the red accent instead. */
  color: var(--msc-red);
}

/* Sage is far lighter than Dark Green, so gold lands at 2.5:1 against it and
   fails AA. The brief only sanctions gold text on Dark Green. On sage the
   eyebrow goes white, which holds 4.55:1. */
.section--sage .eyebrow {
  color: var(--msc-white);
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--msc-space-xs);
  min-height: 48px;
  padding: 0.8rem 1.5rem;
  border: 1px solid transparent;
  border-radius: var(--msc-radius);
  font-size: var(--msc-size-button);
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  transition: background-color var(--msc-transition), border-color var(--msc-transition),
    color var(--msc-transition);
}

.btn--primary {
  background: var(--msc-red);
  color: var(--msc-white);
}

.btn--primary:hover {
  background: #8f191d;
}

.btn--secondary {
  background: transparent;
  border-color: currentColor;
  color: inherit;
}

.btn--secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

.section--light .btn--secondary:hover,
.section--white .btn--secondary:hover {
  background: rgba(34, 31, 31, 0.06);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--msc-space-md);
  align-items: center;
}

/* ---------- Rules and cards ---------- */

.rule {
  border: 0;
  height: 1px;
  background: var(--msc-hairline);
}

.card {
  background: var(--msc-off-white);
  color: var(--msc-near-black);
  border: 1px solid var(--msc-hairline-dark);
  border-radius: var(--msc-radius-card);
  padding: var(--msc-space-xl);
}

.section--dark .card,
.section--sage .card {
  background: var(--msc-green-sage);
  color: var(--msc-white);
  border-color: var(--msc-hairline);
}

/* ---------- Prose (blog + legal) ---------- */

.prose {
  max-width: var(--msc-measure);
  font-size: var(--msc-size-body-lg);
}

.prose > * + * {
  margin-block-start: var(--msc-space-lg);
}

.prose h2 {
  margin-block-start: var(--msc-space-2xl);
}

.prose h3 {
  margin-block-start: var(--msc-space-xl);
}

.prose ul,
.prose ol {
  padding-inline-start: 1.4rem;
}

.prose li + li {
  margin-block-start: var(--msc-space-xs);
}

.prose a {
  color: var(--msc-red);
  text-underline-offset: 3px;
}

.prose blockquote {
  font-family: var(--msc-font-editorial);
  font-style: italic;
  font-size: var(--msc-size-quote);
  line-height: var(--msc-leading-snug);
  border-inline-start: 2px solid var(--msc-red);
  padding-inline-start: var(--msc-space-lg);
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--msc-size-body);
}

.prose th,
.prose td {
  text-align: start;
  padding: var(--msc-space-sm) var(--msc-space-md);
  border-block-end: 1px solid var(--msc-hairline-dark);
}

.prose th {
  font-weight: 600;
}

/* ---------- Utilities ---------- */

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 200;
  padding: var(--msc-space-sm) var(--msc-space-md);
  background: var(--msc-red);
  color: var(--msc-white);
  font-weight: 600;
  text-decoration: none;
  transform: translateY(-120%);
}

.skip-link:focus {
  transform: translateY(0);
}
