/*
Theme Name: Mezzalingua Foundation
Description: Custom theme for the Mezzalingua Family Foundation site, built from the approved static HTML/CSS design.
Author: SherredDigital
Version: 0.12
Text Domain: mezzalingua
*/

/* ==========================================================================
   Mezzalingua Family Foundation — shared stylesheet
   ========================================================================== */

:root {
  /* Color tokens are NOT defined here. They live in inc/palettes.php, which
     holds all four brand-deck options and prints the active one as custom
     properties in wp_head. Switch palettes with MEZZALINGUA_PALETTE_DEFAULT in
     that file, or MEZZALINGUA_PALETTE in wp-config.php. The semantic aliases
     below reference whichever palette is active. */

  --color-bg: var(--color-cream-050);
  --color-surface: #ffffff;
  --color-text: var(--color-ink);
  --color-text-muted: var(--color-ink-soft);
  --color-accent: var(--color-navy-900);
  --color-accent-hover: var(--color-navy-950);

  /* One family for display and body, taken from the logo wordmark. Only the
     weights actually loaded above are used anywhere: 400 and 700. */
  --font-display: "DM Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-body: "DM Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;

  /* Spacing scale, 4px based. Every padding, margin and gap in this file is one
     of these steps — the site previously used 23 different ad-hoc values. */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-14: 56px;
  --space-16: 64px;
  --space-18: 72px;
  --space-20: 80px;
  --space-24: 96px;

  --max-width: 1120px;
  --header-height: 88px;

  /* Client selected option C2 (2026-09-08). Swap point: change this file, nothing else. */
  --logo-src: url("assets/logo.png");
}

/* ---- Typography: DM Sans, self-hosted ------------------------------------
   The wordmark in the client's logo is a geometric sans with a spurred G, a
   stemmed U and pointed A/M apexes — DM Sans matches it closely (Poppins and
   Futura both lack the G spur and run wider). Using it for both display and
   body ties the site to the mark instead of the Palatino serif that shipped
   with the 9/5 draft, which fought the logo.
   Self-hosted rather than loaded from Google's CDN: no third-party request,
   no privacy exposure. SIL Open Font License — see assets/fonts/dm-sans/LICENSE.txt.
   Only 400 and 700 are loaded, so those are the only weights the CSS uses;
   declaring 500 or 600 would silently synthesise or snap. */

@font-face {
  font-family: "DM Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("assets/fonts/dm-sans/DMSans-Regular.woff2") format("woff2");
}

@font-face {
  font-family: "DM Sans";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("assets/fonts/dm-sans/DMSans-Regular-Italic.woff2") format("woff2");
}

@font-face {
  font-family: "DM Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("assets/fonts/dm-sans/DMSans-Bold.woff2") format("woff2");
}

/* ---- Reset & base ------------------------------------------------------- */

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

html {
  scroll-behavior: smooth;
  font-family: var(--font-body);
}

/* Respect a user's reduced-motion preference rather than forcing smooth scroll. */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

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

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 0.6em;
  color: var(--color-navy-950);
}

p {
  margin: 0 0 1.1em;
}

/* A trailing margin on the last element of a block adds to that block's own
   padding, which made every section and card read bottom-heavy. Section and
   card padding owns the outer spacing; the last child never adds to it. */
.hero .container > :last-child,
.section .container > :last-child,
.prose:last-child > :last-child,
.contact-card > :last-child,
.single-content > :last-child,
.prose--letter > :last-child,
.support-item > :last-child {
  margin-bottom: 0;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space-6);
}

/* Keyboard bypass for the header, per WCAG 2.4.1. Visible only when focused. */
.skip-link {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 200;
  padding: var(--space-3) var(--space-5);
  background: var(--color-navy-950);
  color: var(--color-cream-050);
  font-weight: 700;
  text-decoration: none;
  border-radius: 0 0 4px 4px;
  transition: top 0.15s ease;
}

.skip-link:focus {
  top: 0;
}

/* One deliberate, high-contrast focus ring that reads on both light and dark
   grounds, rather than relying on each browser's default. */
:focus-visible {
  outline: 3px solid var(--color-slate-400);
  outline-offset: 2px;
}

.hero :focus-visible,
.site-footer :focus-visible,
.bleed-split--navy :focus-visible,
.section--dark :focus-visible {
  outline-color: var(--color-cream-050);
}

/* #main is focusable only as the skip-link target; it should not show a ring. */
main:focus,
main:focus-visible {
  outline: none;
}

.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;
}

/* ---- Header / nav -------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
  gap: var(--space-6);
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  text-decoration: none;
  min-width: 0;
}

.brand img {
  /* Four stacked lines now, not three: the wordmark keeps the same cap height
     at 68px that the three-line mark had at 58px. */
  height: 68px;
  width: auto;
  content: var(--logo-src);
}

.main-nav ul {
  list-style: none;
  display: flex;
  gap: var(--space-2);
  margin: 0;
  padding: 0;
}

.main-nav a {
  display: inline-block;
  padding: var(--space-3) var(--space-4);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 400;
  color: var(--color-text-muted);
  border-radius: 4px;
  transition: color 0.15s ease, background 0.15s ease;
}

.main-nav a:hover,
.main-nav a:focus-visible {
  color: var(--color-navy-950);
  background: var(--color-cream-100);
}

.main-nav a.is-active,
.main-nav .current-menu-item > a,
.main-nav .current_page_item > a {
  color: var(--color-navy-950);
  font-weight: 700;
}

.nav-toggle {
  display: none;
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  border-radius: 6px;
  width: 42px;
  height: 42px;
  padding: 0;
  cursor: pointer;
  align-items: center;
  justify-content: center;
}

.nav-toggle svg {
  width: 20px;
  height: 20px;
  stroke: var(--color-navy-950);
}

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

.btn {
  display: inline-block;
  padding: var(--space-4) var(--space-8);
  border-radius: 4px;
  font-size: 0.95rem;
  font-weight: 700;
  text-decoration: none;
  letter-spacing: 0.02em;
  border: 1px solid transparent;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn-primary {
  background: var(--color-accent);
  color: var(--color-cream-050);
}

.btn-primary:hover,
.btn-primary:focus-visible {
  background: var(--color-accent-hover);
}

.btn-secondary {
  background: transparent;
  color: var(--color-accent);
  border-color: var(--color-accent);
}

.btn-secondary:hover,
.btn-secondary:focus-visible {
  background: var(--color-accent);
  color: var(--color-cream-050);
}

.btn-ghost {
  background: transparent;
  color: var(--color-cream-050);
  border-color: rgba(247, 243, 234, 0.5);
}

.btn-ghost:hover,
.btn-ghost:focus-visible {
  background: rgba(247, 243, 234, 0.12);
  border-color: var(--color-cream-050);
}

/* ---- Hero ------------------------------------------------------------------ */

.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(155deg, var(--color-navy-950) 0%, var(--color-navy-900) 55%, var(--color-navy-800) 100%);
  color: var(--color-cream-050);
  padding: var(--space-24) 0;
}

.hero .container {
  position: relative;
  z-index: 2;
}

.hero-eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  font-weight: 700;
  /* The hero ground is a 155deg gradient that lightens toward the lower right,
     so an eyebrow's contrast depends on how far right its text runs. The full
     foundation name reaches x=566 at 1280px wide, where the ground has lifted
     to #182438 and bare --color-slate-400 lands at 4.51:1 — passing AA by
     0.01, and only at that width. Mixing the slate toward cream keeps the
     blue cast while giving 7.6:1 of headroom at every viewport. Derived from
     two palette tokens, so it holds for all four palettes. */
  color: var(--color-slate-400);
  color: color-mix(in srgb, var(--color-slate-400) 55%, var(--color-cream-100));
  margin: 0 0 var(--space-5);
}

.hero h1 {
  color: var(--color-cream-050);
  font-size: clamp(2rem, 4.4vw, 3.15rem);
  margin-bottom: 0.5em;
}

.hero p.hero-sub {
  font-family: var(--font-body);
  font-size: 1.1rem;
  color: rgba(247, 243, 234, 0.82);
}

.hero .btn-primary {
  background: var(--color-cream-050);
  color: var(--color-navy-950);
  margin-top: var(--space-2);
}

.hero .btn-primary:hover,
.hero .btn-primary:focus-visible {
  background: var(--color-cream-100);
}

/* Two hero CTAs sit in one row. The paragraph's own bottom margin is dropped so
   the hero's :last-child rule keeps the section balanced. */
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin: var(--space-2) 0 0;
}

.hero-actions .btn {
  margin-top: 0;
}

/* decorative diagonal chevron / circle motif, referenced from the wireframe */
.hero-motif {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.5;
}

.hero-motif svg {
  position: absolute;
  top: 0;
  right: 0;
  height: 100%;
  width: auto;
}

/* Motif colors live here rather than as SVG attributes so they follow the
   palette tokens; hardcoded hex in the markup stayed navy through a palette swap. */
.hero-motif circle {
  stroke: var(--color-slate-400);
}

.motif-chevron-back {
  fill: var(--color-navy-800);
}

.motif-chevron-front {
  fill: var(--color-slate-600);
}

.hero--compact {
  padding: var(--space-18) 0;
}

/* ---- Sections -------------------------------------------------------------- */

.section {
  padding: var(--space-20) 0;
}

.section + .section {
  border-top: 1px solid var(--color-border);
}

.section-alt {
  background: var(--color-cream-100);
}

/* Dark band, matching the wireframe's navy section on About. */
.section--dark {
  background: var(--color-navy-950);
  color: var(--color-cream-050);
}

.section--dark h2,
.section--dark h3 {
  color: var(--color-cream-050);
}

/* .prose sets paragraph color to --color-text, which is near-black ink. On a
   dark section that leaves 1.07:1, so the dark context has to reclaim it. */
.section--dark .prose p {
  color: var(--color-cream-100);
}

.section.section--dark .section-heading .kicker,
.section.section--dark .kicker {
  color: var(--color-slate-400);
}

.section--dark .callout {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.18);
  border-left-color: var(--color-slate-400);
  color: var(--color-cream-050);
}

.section-heading {
  margin: 0 0 var(--space-12);
  text-align: left;
}

.section-heading h2 {
  font-size: clamp(1.5rem, 2.6vw, 2rem);
}

.section-heading .kicker {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--color-slate-600);
  margin: 0 0 var(--space-3);
}

.prose {
  max-width: 100%;
}

.prose p {
  font-size: 1.05rem;
  color: var(--color-text);
}

/* How We Work opens with one paragraph carrying the whole explanation, so it
   gets a touch more size than body copy to read as a lede rather than a stray
   line under the hero. */
.prose--lede p {
  font-size: 1.15rem;
}

.section-lede {
  color: var(--color-text-muted);
}

.signature {
  font-style: italic;
  color: var(--color-text-muted);
  margin-top: -0.4em;
}

/* ---- Split sections (text beside image, per the approved wireframe) ----------- */

/* In-container two-column: body text beside an image panel. */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-12);
  align-items: center;
  margin-bottom: var(--space-14);
}

.split-media img,
.bleed-split-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 10px;
}

/* Full-bleed two-column, matching the wireframe's edge-to-edge image panels.
   The text column keeps the container's left inset so it still lines up with
   every other section; the image runs to the viewport edge. */
.bleed-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
  min-height: 520px;
}

.bleed-split-body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--space-20) var(--space-12) var(--space-20) max(var(--space-6), calc((100vw - var(--max-width)) / 2 + var(--space-6)));
}

.bleed-split-body > :last-child {
  margin-bottom: 0;
}

.bleed-split-body h2 {
  font-size: clamp(1.5rem, 2.6vw, 2rem);
}

.bleed-split-media {
  position: relative;
  min-height: 320px;
}

.bleed-split-media img {
  position: absolute;
  inset: 0;
  border-radius: 0;
}

/* Reversed: image on the left, text on the right, so the rhythm alternates. */
.bleed-split--reverse .bleed-split-media { order: 1; }
.bleed-split--reverse .bleed-split-body {
  order: 2;
  padding: var(--space-20) max(var(--space-6), calc((100vw - var(--max-width)) / 2 + var(--space-6))) var(--space-20) var(--space-12);
}

/* Navy variant: the wireframe puts white type and a light button on this one. */
.bleed-split--navy {
  background: var(--color-navy-950);
  color: var(--color-cream-050);
}

.bleed-split--navy h2 {
  color: var(--color-cream-050);
}

.bleed-split.bleed-split--navy .kicker {
  color: var(--color-slate-400);
}

.btn-on-navy {
  background: var(--color-cream-050);
  color: var(--color-navy-950);
}

.btn-on-navy:hover,
.btn-on-navy:focus-visible {
  background: var(--color-cream-100);
}

.bleed-split .kicker {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--color-slate-600);
  margin: 0 0 var(--space-3);
}

.split-excerpt {
  color: var(--color-text-muted);
  max-width: 46ch;
}

.bleed-split--navy .split-excerpt {
  color: rgba(247, 243, 234, 0.82);
}

@media (max-width: 860px) {
  .split {
    grid-template-columns: 1fr;
    gap: var(--space-8);
  }

  .bleed-split,
  .bleed-split--reverse {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  /* Image first on narrow screens regardless of desktop order. */
  .bleed-split-media { order: 1; }
  .bleed-split-body  { order: 2; }

  .bleed-split-body,
  .bleed-split--reverse .bleed-split-body {
    padding: var(--space-14) var(--space-6);
  }

  .bleed-split-media { min-height: 240px; }
}

/* A statement carrying heading weight runs much longer than a title, so cap it
   below the display size the short bleed-split headings use. */
.bleed-split--navy .bleed-split-body h2 {
  font-size: clamp(1.35rem, 2.2vw, 1.75rem);
  line-height: 1.35;
}

/* ---- Stat strip -------------------------------------------------------------- */

.stat-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-8);
  margin: 0;
}

.stat {
  border-left: 3px solid var(--color-accent);
  padding-left: var(--space-5);
}

.stat-number {
  font-family: var(--font-display);
  font-size: 2.1rem;
  font-weight: 700;
  color: var(--color-navy-950);
  display: block;
}

.stat-label {
  font-size: 0.92rem;
  color: var(--color-text-muted);
  /* At two-up the columns are ~560px, wide enough for a long label to run right
     up to the next stat's rule. Cap the measure so it wraps instead. */
  max-width: 34ch;
  display: block;
}

/* Two supported figures rather than three, so the columns stay even. */
.stat-strip--2 {
  grid-template-columns: repeat(2, 1fr);
}

/* ---- What we support -------------------------------------------------------------- */

/* Four one-line items. Deliberately lighter than .pillar-card: a rule and the
   heading carry it, because a line of copy this short in a bordered card reads
   as an empty box. */
.support-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-8);
}

.support-item {
  border-top: 2px solid var(--color-slate-400);
  padding-top: var(--space-5);
}

.support-item h3 {
  font-size: 1.05rem;
  margin-bottom: var(--space-3);
}

.support-item p {
  font-size: 0.95rem;
  margin-bottom: 0;
}

.section--dark .support-item p {
  color: rgba(240, 235, 216, 0.85);
}

/* ---- Pillars grid -------------------------------------------------------------- */

.pillars-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-8);
}

.pillar-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: var(--space-8);
}

.pillar-card h3 {
  font-size: 1.15rem;
  margin-bottom: 0.5em;
  color: var(--color-navy-950);
}

.pillar-card p {
  font-size: 0.98rem;
  color: var(--color-text-muted);
  margin-bottom: 0;
}

.pillars-footnote {
  margin: var(--space-10) 0 0;
  font-size: 0.98rem;
  color: var(--color-text-muted);
}

/* ---- Operates callout -------------------------------------------------------------- */

.callout {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-left: 4px solid var(--color-accent);
  border-radius: 8px;
  padding: var(--space-8);
}

.callout p:last-child {
  margin-bottom: 0;
}

/* ---- Media / news cards -------------------------------------------------------------- */

.news-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  column-gap: var(--space-14);
  row-gap: var(--space-10);
}

/* The wireframe lists news as plain rows divided by rules, with no card chrome. */
.news-card {
  border-bottom: 1px solid var(--color-border);
  padding: 0 0 var(--space-8);
  display: flex;
  flex-direction: column;
}

.news-card-meta {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--color-slate-600);
  margin-bottom: var(--space-3);
}

.news-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5em;
}

.news-card .excerpt {
  color: var(--color-text-muted);
  margin-bottom: var(--space-5);
}

.read-more-toggle {
  align-self: flex-start;
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  font-weight: 700;
  color: var(--color-accent);
  text-decoration: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
}

.read-more-toggle:hover {
  color: var(--color-accent-hover);
}

.read-more-toggle .chevron {
  display: inline-block;
}

.news-empty-note {
  margin-top: var(--space-10);
  font-size: 0.92rem;
  color: var(--color-text-muted);
  border-top: 1px solid var(--color-border);
  padding-top: var(--space-6);
}

/* ---- Single press release -------------------------------------------------------------- */

/* Full container width, matching every other content block on the site. */
.single-content {
  max-width: 100%;
  margin: 0;
}

/* The return action is navigation, not part of the release — set it apart. */
.single-back {
  margin: var(--space-14) 0 0;
  padding-top: var(--space-8);
  border-top: 1px solid var(--color-border);
}

/* ---- Contact page -------------------------------------------------------------- */

.contact-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: var(--space-10);
}

.contact-card h2 {
  font-size: 1.4rem;
}

/* ---- Contact form (Gravity Forms) -------------------------------------------------------------- */

.contact-form {
  margin-top: var(--space-8);
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: var(--space-10);
}

.contact-form h2 {
  font-size: 1.4rem;
}

/* Gravity Forms' Orbital theme is driven by its own custom-property API. Setting
   those rather than overriding its selectors keeps this working across upgrades.
   Field layout (Name/Email side by side) is set per-field in the form itself. */
.contact-form .gform_wrapper {
  --gf-color-primary: var(--color-accent);
  --gf-color-primary-darker: var(--color-accent-hover);
  --gf-color-primary-contrast: var(--color-cream-050);

  --gf-ctrl-btn-bg-color-primary: var(--color-accent);
  --gf-ctrl-btn-bg-color-hover-primary: var(--color-accent-hover);
  --gf-ctrl-btn-bg-color-focus-primary: var(--color-accent-hover);
  --gf-ctrl-btn-border-color-focus-primary: var(--color-accent-hover);
  --gf-ctrl-btn-padding-x: var(--space-8);

  --gf-ctrl-bg-color: var(--color-cream-050);
  --gf-ctrl-bg-color-focus: var(--color-surface);
  --gf-ctrl-bg-color-hover: var(--color-cream-050);
  --gf-ctrl-border-color: var(--color-border);
  --gf-ctrl-border-color-hover: var(--color-slate-400);
  --gf-ctrl-border-color-focus: var(--color-slate-600);
  --gf-ctrl-color: var(--color-text);
  --gf-ctrl-color-focus: var(--color-text);
  --gf-ctrl-radius: 4px;
  --gf-ctrl-size: 46px;
  --gf-ctrl-padding-x: var(--space-4);

  --gf-ctrl-label-color-primary: var(--color-navy-950);
  --gf-ctrl-label-color-req: var(--color-slate-600);
  /* GF defaults this to 500, which this theme does not load. */
  --gf-ctrl-label-font-weight-req: 700;
  --gf-font-family-primary: var(--font-body);
}

/* Orbital routes some properties through an internal --gf-local-* layer that the
   public variables above don't reach, so these few are set directly. */
.contact-form .gform_wrapper .gfield input,
.contact-form .gform_wrapper .gfield select,
.contact-form .gform_wrapper .gfield textarea {
  border-color: var(--color-border);
  background-color: var(--color-cream-050);
  color: var(--color-text);
}

.contact-form .gform_wrapper .gfield input,
.contact-form .gform_wrapper .gfield select {
  height: 46px;
}

.contact-form .gform_wrapper .gfield input:focus,
.contact-form .gform_wrapper .gfield select:focus,
.contact-form .gform_wrapper .gfield textarea:focus {
  border-color: var(--color-slate-600);
}

.contact-form .gform_wrapper .gfield_label {
  color: var(--color-navy-950);
  font-weight: 700;
}

/* Orbital ships deliberately high-specificity selectors for its submit button
   and textarea sizing (six-plus classes on one element), so matching the site's
   button proportions here needs !important rather than a specificity arms race. */
.contact-form .gform_wrapper .gform_footer .gform_button {
  height: auto !important;
  padding-block: var(--space-4) !important;
  padding-inline: var(--space-8) !important;
  /* Orbital ships 500, which this theme does not load — it silently rendered at
     400, leaving the submit button lighter than every other button on the site. */
  font-weight: 700 !important;
}


.contact-form .gform_wrapper .gfield textarea {
  height: 160px !important;
  min-height: 160px !important;
  resize: vertical;
}

.contact-card p {
  font-size: 1.02rem;
}

/* ---- Footer -------------------------------------------------------------- */

.site-footer {
  background: var(--color-navy-950);
  color: rgba(247, 243, 234, 0.72);
  padding: var(--space-12) 0;
}

.site-footer .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-family: var(--font-display);
  color: var(--color-cream-050);
  font-size: 0.95rem;
}

.footer-brand img {
  height: 54px;
  width: auto;
  filter: invert(1) brightness(1.6);
  content: var(--logo-src);
}

.footer-note {
  font-size: 0.85rem;
  max-width: 460px;
  /* Inherited paragraph margin would push this off-center against the logo and
     links in the flex row; the container's own gap owns the spacing instead. */
  margin: 0;
}

.footer-links {
  display: flex;
  gap: var(--space-5);
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-links a {
  text-decoration: none;
  font-size: 0.88rem;
  color: rgba(247, 243, 234, 0.72);
}

.footer-links a:hover {
  color: var(--color-cream-050);
}

/* ---- Responsive -------------------------------------------------------------- */

@media (max-width: 860px) {
  .stat-strip {
    grid-template-columns: 1fr;
    gap: var(--space-5);
  }

  .pillars-grid,
  .news-grid {
    grid-template-columns: 1fr;
  }

  .support-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 720px) {
  .nav-toggle {
    display: inline-flex;
  }

  .main-nav {
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    box-shadow: 0 12px 24px -12px rgba(14, 26, 43, 0.25);
    display: none;
  }

  .main-nav.is-open {
    display: block;
  }

  .main-nav ul {
    flex-direction: column;
    padding: var(--space-2) var(--space-4);
    gap: var(--space-1);
  }

  .main-nav a {
    padding: var(--space-3) var(--space-2);
    width: 100%;
  }

  .hero {
    padding: var(--space-16) 0;
  }

  .section {
    padding: var(--space-14) 0;
  }

  .site-footer .container {
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
  }
}

@media (max-width: 480px) {
  .support-grid {
    grid-template-columns: 1fr;
  }

  /* Stacked hero CTAs size to their own text, which leaves them visibly ragged.
     Stretch them to a common width so the pair reads as a set. */
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .btn {
    text-align: center;
  }

  .contact-card,
  .contact-form,
  .callout,
  .pillar-card {
    padding: var(--space-6);
  }
}
