/* =================================================================
   v2 — Momentum Connect visual replica (placeholder branding: Aperture)
   Working scaffold. Sections will be replaced one by one with CHeCS content.
   ================================================================= */

/* Elms Sans for body, Aleo serif for headings — matches the legacy site. */
@import url('https://fonts.googleapis.com/css2?family=Aleo:wght@400..700&family=Elms+Sans:wght@300..700&display=swap');

/* ---------- Tokens ---------- */
:root {
  --bg: #f9f7f7;        /* page canvas — soft warm white, matches legacy --canvas */
  --bg-fade: rgba(249, 247, 247, 0); /* same as --bg with 0 alpha; used for hero bottom fade */
  --bg-deep: #eae4d8;   /* tier-1 tan (header transition / subtle surface) */
  --bg-tan: #ded4c2;    /* tier-2 tan (split-hero left panels) */
  --fg: #112d4e;        /* deep navy — matches legacy --foreground */
  --fg-muted: #4a5a73;  /* steel blue — matches legacy --foreground-muted */
  --fg-subtle: #6b6a66; /* warm grey — matches legacy --foreground-subtle */
  --inverse: #efe5d0;
  --line: #d3c7ad;
  --line-subtle: #ddd1b6;

  --card-mint: #9bb09f;
  --card-sand: #cabea8;
  --card-dark: #181715;
  --card-mauve: #a497a4;

  --font-stack: 'Elms Sans', 'Switzer', system-ui, -apple-system, 'Helvetica Neue', Helvetica, Arial, sans-serif;

  --container: 100%;        /* sections are full-bleed; constrain content with inner padding only */
  --gutter: clamp(1rem, 1.6vw, 1.5rem);  /* ~24px @ 1440 — matches Momentum's edge inset */
  --gutter-header: clamp(1.25rem, 2.8vw, 2.5rem);  /* slightly more breathing room for nav */

  --easing: cubic-bezier(0.83, 0, 0.17, 1);
  --duration: 600ms;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-stack);
  font-size: 1.125rem;
  line-height: 1.1;
  font-weight: 500;
  background: var(--bg);
  color: var(--fg);
  -webkit-font-smoothing: antialiased;
  font-feature-settings: 'kern', 'liga', 'ss01';
  text-rendering: optimizeLegibility;
}
img, svg, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; background: none; border: 0; cursor: pointer; padding: 0; color: inherit; }
ul { list-style: none; padding: 0; margin: 0; }
h1, h2, h3, h4, h5, h6, p { margin: 0; }

/* ---------- Typography ----------
   Calibrated to Momentum Connect measurements at 1440px:
   - Display H1: 81px / 1.0 / weight 500
   - Section H2: 36px / 1.0 / weight 500
   - Body/card:  18px / 1.1 / weight 500
   - tracking:   normal (0)
*/
.h-display {
  font-family: 'Aleo', serif;
  font-size: clamp(2.75rem, 5.625vw, 5rem); /* 44px → 80px */
  font-weight: 600;                          /* Switzer 600 matches Haas Grotesk 500 stroke weight */
  line-height: 1.0;
  letter-spacing: 0;
}
.h-headline {
  font-family: 'Aleo', serif;
  font-size: clamp(1.75rem, 2.5vw, 2.25rem); /* 28px → 36px */
  font-weight: 600;
  line-height: 1.0;
  letter-spacing: 0;
}
.h-section {
  font-family: 'Aleo', serif;
  font-size: clamp(1.5rem, 2vw, 1.75rem); /* 24px → 28px */
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: 0;
}
.h-card {
  font-family: 'Aleo', serif;
  font-size: 1.125rem; /* 18px */
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: 0;
}
.lead {
  font-size: 1.125rem; /* 18px */
  line-height: 1.1;
  font-weight: 500;
  letter-spacing: 0;
}
.body { font-size: 1.125rem; line-height: 1.1; font-weight: 500; }
.body-sm { font-size: 0.9375rem; line-height: 1.4; font-weight: 500; }
.eyebrow {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--fg-muted);
  letter-spacing: 0;
}
/* Eyebrow text on coloured leadership panels: muted slate fails 4.5:1
   against the mint/sand backgrounds, so use the navy --fg for AA contrast. */
.panel--mint .eyebrow,
.panel--sand .eyebrow { color: var(--fg); }

/* ---------- Layout ---------- */
.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.container--bleed { padding: 0; }
.section { padding: clamp(4rem, 7vw, 7rem) 0; }
.section--tight { padding: clamp(1.5rem, 2.25vw, 2rem) 0; }   /* trimmed to match Momentum's section heights */
.section--first { padding-top: clamp(2rem, 3vw, 3rem); }

/* Home page menu-targeted sections fill the viewport so each one stands alone
   when reached via the nav (Features / Benefits). #how is left at natural
   height so the final CTA outro can hug it without a large trailing gap. */
#features,
#benefits,
.page-about main > .section {
  min-height: 100vh;
}
/* Outro sections (short, centered copy) shouldn't be force-tall — they leave
   a huge empty gap below the text. Let them size to their content. */
.page-about main > .section:has(.section-outro) {
  min-height: 0;
}
.stack-sm > * + * { margin-top: 0.5rem; }
.stack > * + * { margin-top: 1.25rem; }
.stack-lg > * + * { margin-top: 2rem; }

/* Skip-to-main-content link for keyboard / screen reader users. Hidden until
   focused, then appears top-left for visibility. */
.skip-link {
  position: absolute;
  top: 0;
  left: 0;
  padding: 0.75rem 1rem;
  background: var(--fg);
  color: var(--bg);
  text-decoration: none;
  z-index: 1000;
  transform: translateY(-150%);
  transition: transform 150ms ease;
}
.skip-link:focus { transform: translateY(0); outline: 2px solid var(--bg); outline-offset: -4px; }

/* ---------- Header ---------- */
.site-header {
  position: absolute;             /* overlays the hero; scrolls away with content */
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1.125rem var(--gutter-header);
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}
.site-header::before {
  /* Cream → transparent gradient backdrop that extends below the header
     so the nav reads cleanly without a hard horizontal line at the bottom edge. */
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: -3rem;
  background: linear-gradient(
    to bottom,
    var(--bg) 0%,
    var(--bg) 55%,
    rgba(248, 245, 232, 0) 100%
  );
  z-index: -1;
  pointer-events: none;
}
.brand {
  display: inline-flex;
  align-items: center;
  line-height: 1;
}
.brand__logo {
  height: 44px;          /* matches footer logo */
  width: auto;
  display: block;
}

.nav {
  display: flex;
  align-items: center;
  gap: 2.25rem;
}
.nav__link {
  font-size: 0.875rem; /* 14px — matches Momentum */
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0;
  position: relative;
  padding: 0.25rem 0;
}
.nav__link[aria-current="page"]::after {
  content: '';
  position: absolute;
  left: 0; right: 0;
  bottom: -2px;
  height: 1px;
  background: var(--fg);
}
.nav__link:hover { color: var(--fg-muted); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  padding: 0.5625rem 1.5rem;          /* 9px y / 24px x — matches Momentum's 9px all-round + width */
  min-width: 11.375rem;               /* 182px — matches Momentum's wider rectangular look */
  font-size: 0.875rem;                 /* 14px */
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.3;
  transition: background 180ms ease, color 180ms ease, transform 180ms ease;
  white-space: nowrap;
  max-width: 100%;
}
.btn--ghost,
.btn--dark.btn--auto,
.btn--hero {
  min-width: 0;                        /* let hero / form / ghost CTAs size to content */
}
.btn--dark {
  background: var(--fg);
  color: #fff;
}
.btn--dark:hover { background: #2b2825; }
.btn--ghost {
  background: transparent;
  color: var(--fg);
  border: 1px solid var(--fg);
}
.btn--ghost:hover { background: var(--fg); color: #fff; }

/* ---------- Home Hero ---------- */
.home-hero {
  position: relative;
  height: clamp(520px, 85vh, 820px);
  overflow: hidden;
  background: var(--bg);
}
.home-hero::after,
.split-hero::after {
  /* Cream fade on the bottom edge so the hero blends into the next section
     without a hard horizontal line — mirrors the gradient under the header.
     bottom: -1px overlaps the next section by a pixel to hide the subpixel
     seam where the gradient's final cream pixel meets the body cream below. */
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: clamp(4rem, 7vw, 6.5rem);
  background: linear-gradient(to top, var(--bg) 0%, var(--bg-fade) 100%);
  z-index: 1;
  pointer-events: none;
}
.home-hero__bg {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  z-index: 0;
}
.home-hero__content {
  position: absolute;
  top: clamp(6rem, 8vw, 7rem);    /* clears the absolute header (~80px) */
  left: clamp(1.5rem, 4vw, 3.5rem);
  right: clamp(1.5rem, 4vw, 3.5rem);
  z-index: 2;
  max-width: min(640px, 60%);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: clamp(1.25rem, 2vw, 2rem);
  color: var(--fg);
}
.home-hero__title {
  max-width: 18ch;
  color: inherit;
}
.home-hero__lede {
  font-size: clamp(1rem, 0.5vw + 0.875rem, 1.125rem);
  line-height: 1.4;
  font-weight: 500;
  max-width: 40ch;
}
.home-hero__cta {
  margin-top: 0.25rem;
}

/* ---------- Inner page hero (about / services) ---------- */
.split-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  min-height: clamp(420px, 60vh, 620px);
}
.page-faq .split-hero__panel,
.page-about .split-hero__panel,
.page-about .panel-grid .panel--mint,
.page-about .panel-grid .panel--sand,
.page-contact .contact-hero__panel { background: #f1eeec; }
/* About leadership cards: bump role + name type one step up the scale. */
.page-about .panel-grid .eyebrow { font-size: 1rem; }
.page-about .panel-grid .panel__title { font-size: 1.5rem; line-height: 1.15; }
.split-hero__panel {
  background: var(--bg-tan);
  /* Vertical padding clears the header's cream backdrop above (~128px from
     page top) and the .split-hero::after cream fade below (~100px from
     bottom) so neither tints the h1 or the lede. */
  padding: clamp(6rem, 9vw, 7.5rem) clamp(2rem, 4vw, 4rem) clamp(5rem, 8vw, 7rem);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2rem;
}
.split-hero__panel-bottom { display: flex; flex-direction: column; gap: 1rem; align-items: flex-start; }
.split-hero__photo {
  background-size: cover;
  background-position: center;
}
/* About + FAQ hero: extend the panel bg to the full hero so the photo's
   faded left edge blends into a uniform color (no visible seam / hard edge
   at the cell boundary, including during the reveal animation). */
.page-about .split-hero,
.page-faq .split-hero { background: #f1eeec; }
.page-about .split-hero__photo,
.page-faq .split-hero__photo {
  -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 35%);
          mask-image: linear-gradient(to right, transparent 0%, #000 35%);
}
.page-about .split-hero__photo {
  /* Anchor left so the right side of the source image gets cropped instead
     of the left. Keeps more of the people-side content visible. */
  background-position: left center;
  margin-left: clamp(-4rem, -3vw, -2rem);
}
.split-hero__panel .h-display,
.contact-hero__panel .h-display {
  font-size: clamp(2.5rem, 4.75vw, 4.25rem); /* 40px → 68px in tighter panels */
}
.split-hero__panel--xl {
  padding-top: clamp(6rem, 8vw, 7rem); /* clears the absolute header, matching home-hero */
}
.split-hero__panel--xl .h-display {
  font-size: clamp(2.75rem, 5.625vw, 5rem); /* matches home-hero h-display */
}

/* ---------- Section Heads ---------- */
.section-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: end;
  margin-bottom: clamp(2rem, 4vw, 4rem);
}
.section-head--solo { grid-template-columns: 1fr; }
.section-head__title { max-width: 14ch; }
.section-head__lede { color: var(--fg); }
.section-outro {
  max-width: 70%;
  margin: clamp(2.5rem, 5vw, 4.5rem) auto 0;
  text-align: center;
  color: var(--fg);
}
.section-outro__title { margin-bottom: clamp(1.5rem, 2.5vw, 2.25rem); }
.section-outro__body { color: var(--fg); }
.section-outro__body--narrow { max-width: 56ch; margin-left: auto; margin-right: auto; }
.section-outro__body + .section-outro__body { margin-top: 1.25em; }
.section-outro__cta { display: inline-block; margin-top: clamp(2.75rem, 5vw, 4rem); }

/* Final CTA outro before the footer. The top spacing mirrors the spacing
   below the CTA (outro padding-bottom + .site-footer margin-top), so the
   gap above "60 minutes is all we need" matches the gap below the demo CTA. */
.section--cta-outro { padding-top: clamp(5rem, 10vw, 9rem); }
.section--cta-outro .section-outro { margin-top: 0; }

/* ---------- 4-up panel grid (Specializations / Approach) ---------- */
.panel-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;                            /* matches Momentum's ~6px cream gaps between cells */
}
.panel-grid--6 {
  grid-template-columns: repeat(6, 1fr);
}
.panel {
  aspect-ratio: 3 / 4;                         /* matches Momentum's 348:466 portrait cells */
  padding: clamp(1.5rem, 2.75vw, 2.5rem) clamp(1.5rem, 3vw, 2.75rem);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1.5rem;
}
.panel--mint { background: var(--card-mint); }
.panel--sand { background: var(--card-sand); }
.panel--dark { background: var(--card-dark); color: var(--inverse); }
.panel--mauve { background: var(--card-mauve); }
.panel--photo {
  background-size: cover;
  background-position: center;
}
.panel__icon {
  width: clamp(4rem, 6.25vw, 5.625rem);  /* 64 → 90px, matches Momentum's 90px square SVG */
  height: auto;
  color: var(--fg);
}
.panel__copy { display: flex; flex-direction: column; gap: 0.5rem; }
.panel__title { font-size: 1.125rem; font-weight: 500; line-height: 1.1; }
.panel__body { font-size: 1rem; line-height: 1.25; font-weight: 500; }
.panel__links { display: flex; gap: 0.625rem; align-items: center; flex-wrap: wrap; }
.panel__links a { text-decoration: underline; text-underline-offset: 3px; }
.panel__links a:hover { color: var(--fg-muted); }
.panel__links-sep { color: var(--fg-muted); }

/* ---------- Split: photo + dark sidebar with numbered items ---------- */
.advantage {
  display: grid;
  grid-template-columns: 1.7fr 1fr;        /* 63/37 — matches Momentum's measured 545px/1454px ratio */
  min-height: 0;                           /* let content set the height, no inflation */
}
.advantage__photo {
  background-size: cover;
  background-position: center;
  min-height: 380px;                       /* floor for the photo on shorter content */
}
.advantage__panel {
  background: var(--card-dark);
  color: var(--inverse);
  padding: clamp(1.5rem, 2.5vw, 2.25rem) clamp(1.5rem, 2.25vw, 2rem);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  justify-content: center;
}
.adv-item {
  padding: 0.75rem 0;
  border-top: 1px solid rgba(239, 229, 208, 0.18);
}
.adv-item:first-of-type { border-top: 0; padding-top: 0; }
.adv-item:last-of-type { padding-bottom: 0; }
.adv-item__title { font-family: 'Aleo', serif; font-size: 1.0625rem; font-weight: 700; margin-bottom: 0.375rem; letter-spacing: 0; line-height: 1.15; }
.adv-item__body { font-size: 0.9375rem; line-height: 1.25; opacity: 0.92; max-width: 52ch; }

/* ---------- Testimonials grid ---------- */
.tess {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.tess__cell {
  padding: 1.75rem 1.5rem 2rem;
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
.tess__cell:last-child { border-right: 0; }
.tess__num { font-size: 0.9375rem; font-weight: 500; color: var(--fg-muted); }
.tess__num img { display: block; width: 1.75rem; height: 1.75rem; }
.tess__title { font-family: 'Aleo', serif; font-size: 1.125rem; font-weight: 700; line-height: 1.2; margin: 0; }
.tess__quote { font-size: 1rem; line-height: 1.3; font-weight: 500; flex: 1; }
.tess__attr { font-size: 0.875rem; color: var(--fg-muted); }

/* ---------- Numbered process rows (Blueprint / Principles) ---------- */
.rows {
  border-bottom: 1px solid var(--line);
  max-width: 58rem; /* num (4.5) + label (14) + copy (~28ch) + 2 gaps ≈ 54–58rem */
  margin-left: auto;
  margin-right: auto;
}
.rows__head {
  display: grid;
  grid-template-columns: 4.5rem 14rem 1fr;
  gap: clamp(1.5rem, 3vw, 3rem);
  padding: 0 0 1rem;
}
.rows__head-title { max-width: 28ch; font-size: 1.125rem; font-weight: 500; line-height: 1.2; }
.row {
  display: grid;
  grid-template-columns: 4.5rem 14rem 1fr;
  gap: clamp(1.5rem, 3vw, 3rem);
  padding: 1.5rem 0;
  border-top: 1px solid var(--line);
  align-items: start;
}
.row__num { font-size: 0.9375rem; font-weight: 500; color: var(--fg-muted); }
.row__num img { display: block; width: 1.75rem; height: 1.75rem; }
.row__label { font-family: 'Aleo', serif; font-size: 1.125rem; font-weight: 500; letter-spacing: 0; line-height: 1.3; }
.row__copy { font-size: 1.125rem; line-height: 1.3; font-weight: 500; max-width: 56ch; }
/* Modifier: when the rows have no numbers (e.g. FAQ where icons aren't
   appropriate for 15 items), drop the first grid column. Labels in this
   layout also go bold for visual hierarchy. */
.rows--no-num .row { grid-template-columns: 14rem 1fr; }
.rows--no-num .row__label { font-weight: 700; }

/* ---------- Contact page split ---------- */
.contact-hero {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  /* Fill the viewport so the next section + footer fall below the fold. */
  min-height: 100vh;
}
/* Push panels to start right at the header's bottom edge (~80px). The header
   sits on body cream alone above the panels; the dark form starts cleanly
   below the nav instead of poking up behind it. */
.contact-hero.section--first {
  padding-top: 5rem;
}
.contact-hero__panel {
  background: var(--bg-tan);
  padding: clamp(2rem, 4vw, 4rem);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 2rem;
}
.contact-hero__form {
  background: var(--fg);
  color: var(--inverse);
  padding: clamp(2rem, 4vw, 4rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Contact + legal pages: suppress the header's cream-to-transparent backdrop.
   On contact it would smear onto the dark form; on legal pages it would tint
   the title row. Nav text stays the default dark since it sits over body cream. */
.page-contact .site-header::before,
.page-legal .site-header::before { display: none; }

/* ---------- Form ---------- */
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem 1.5rem; max-width: 640px; }
.field { display: flex; flex-direction: column; gap: 0.5rem; }
.field--full { grid-column: 1 / -1; }
.field label { font-size: 1.125rem; font-weight: 500; color: #f1eeec; }
.field input,
.field textarea,
.field select {
  background: transparent;
  border: 0;
  /* Underline must hit 3:1 (SC 1.4.11) against #112d4e form bg — solid
     --inverse (#efe5d0) gives ~8.6:1. */
  border-bottom: 1px solid var(--inverse);
  color: var(--inverse);
  font: inherit;
  font-size: 1.125rem;
  padding: 0.75rem;
  outline: none;
  border-radius: 0;
}
/* Suppress Chrome / Safari autofill's blue background tint — paint over it
   with the navy form bg via inset box-shadow, and force the cream text fill. */
.field input:-webkit-autofill,
.field input:-webkit-autofill:hover,
.field input:-webkit-autofill:focus,
.field input:-webkit-autofill:active {
  -webkit-box-shadow: 0 0 0 1000px var(--fg) inset !important;
  -webkit-text-fill-color: var(--inverse) !important;
  caret-color: var(--inverse);
  transition: background-color 5000s ease-in-out 0s;
}
.field textarea { min-height: 96px; resize: vertical; }
.field input:focus,
.field textarea:focus,
.field select:focus { border-bottom-color: var(--inverse); }
.field input::placeholder,
.field textarea::placeholder {
  /* ~5:1 against the navy form bg — meets AA for normal text. */
  color: rgba(239, 229, 208, 0.85);
  font-size: 1.125rem;
  opacity: 1; /* Firefox default lowers placeholder opacity further */
}
.field input[aria-invalid="true"],
.field textarea[aria-invalid="true"],
.field select[aria-invalid="true"] { border-bottom-color: #ff9499; }
.field__error {
  font-size: 0.75rem;
  font-weight: 500;
  color: #ff9499;
  margin-top: 0.125rem;
}
.form-submit { grid-column: 1 / -1; margin-top: 0.5rem; display: flex; flex-direction: column; gap: 0.75rem; }
.form-submit .btn { border: 1px solid #f1eeec; background: transparent; color: var(--inverse); align-self: flex-start; }
.form-submit .btn:hover { background: #f1eeec; color: var(--fg); }
.form-submit .btn:disabled { opacity: 0.6; cursor: not-allowed; }
.form__error {
  font-size: 0.8125rem;
  color: #ff9499;
}
.form__honeypot {
  position: absolute;
  left: -5000px;
  width: 1px;
  height: 1px;
  opacity: 0;
}
.form__success {
  margin-top: 1.5rem;
  padding: 1rem 1.25rem;
  background: rgba(187, 247, 208, 0.12);
  border: 1px solid rgba(187, 247, 208, 0.3);
  border-radius: 0.5rem;
  max-width: 640px;
}
.form__success-title { font-weight: 600; color: #bbf7d0; }
.form__success-body { font-size: 0.875rem; color: rgba(239, 229, 208, 0.85); margin-top: 0.25rem; }
.form__note { font-size: 0.75rem; color: rgba(239, 229, 208, 0.85); margin-top: 1rem; max-width: 640px; }
.form__hint { font-size: 0.875rem; color: rgba(239, 229, 208, 0.85); margin: 0 0 1rem; max-width: 640px; }
.field__hint { font-size: 0.8125rem; color: rgba(239, 229, 208, 0.85); margin-top: 0.25rem; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Two-column explainer ---------- */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
}
/* Match the contact-hero panels' horizontal padding so the left/right
   content lines up with the headline column and the form column above. */
.two-col > div { padding: 0 clamp(2rem, 4vw, 4rem); }
.two-col__title { font-size: 1.125rem; font-weight: 700; margin-bottom: 1rem; line-height: 1.1; }
.two-col__body { font-size: 1.125rem; line-height: 1.3; font-weight: 500; max-width: 50ch; }

/* ---------- Footer ---------- */
.site-footer {
  margin-top: clamp(5rem, 10vw, 9rem); /* substantial breathing room between the page and the footer divider */
  padding: 0 var(--gutter) 1.5rem;
}
.site-footer__grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: clamp(2rem, 4vw, 4rem);
  padding-top: clamp(3rem, 6vw, 5rem);
  margin-bottom: clamp(3rem, 5vw, 4rem);
  border-top: 1px solid var(--line);
}
.site-footer__brand { display: flex; flex-direction: column; align-items: flex-start; gap: 1.25rem; max-width: 24rem; }
.site-footer__logo { height: 44px; width: auto; display: block; }
.site-footer__tagline { font-size: 0.875rem; font-weight: 400; line-height: 1.3; color: var(--fg); margin: 0; }
.site-footer__social { font-size: 0.875rem; display: flex; gap: 1rem; }
.site-footer__social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  min-height: 24px;
  padding: 0.25rem;
  color: var(--fg);
  transition: color 200ms var(--easing);
}
.site-footer__social a:hover { color: var(--fg-muted); }
.site-footer__col-title { font-size: 0.8125rem; font-weight: 700; margin: 0 0 0.875rem; color: var(--fg-muted); letter-spacing: 0.04em; text-transform: uppercase; }
.site-footer__col ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.5rem; }
.site-footer__col a,
.site-footer__col button {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  font-size: 0.875rem;
  font-weight: 400;
  line-height: 1.3;
  color: var(--fg);
  background: none;
  border: 0;
  padding: 0.25rem 0;
  font-family: inherit;
  cursor: pointer;
  text-align: left;
  transition: color 200ms var(--easing);
}
.site-footer__col a:hover,
.site-footer__col button:hover { color: var(--fg-muted); }
.site-footer__legal {
  font-size: 0.8125rem;
  font-weight: 400;
  color: var(--fg-muted);
}

/* ---------- Leadership bio block ---------- */
.bio {
  max-width: 58rem;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 18rem) minmax(0, 1fr);
  gap: clamp(2rem, 4vw, 4rem);
  align-items: start;
  scroll-margin-top: clamp(3rem, 6vw, 5rem);
}
.bio + .bio {
  margin-top: clamp(3rem, 6vw, 5rem);
  padding-top: clamp(3rem, 6vw, 5rem);
  border-top: 1px solid var(--line);
}
.bio__header { display: flex; flex-direction: column; gap: 0.5rem; }
.bio__name { margin: 0; max-width: 14ch; }
.bio__copy { display: flex; flex-direction: column; gap: 1rem; font-size: 1rem; line-height: 1.55; color: var(--fg); }
.bio__copy p { margin: 0; }
/* Inline portrait inside each .bio — hidden by default. On small mobile,
   the panel-grid photos are hidden and these take over so each leader's
   photo + name + bio sit together as one visual block. */
.bio__photo { display: none; }
/* LinkedIn link inside .bio — desktop has it in the panel-grid above, so
   it's hidden here by default and shown on mobile (where the panel-grid is
   hidden) to keep one canonical link per leader. */
.bio__links { display: none; margin-top: 0.5rem; }
.bio__links a { text-decoration: underline; text-underline-offset: 3px; }
.bio__links a:hover { color: var(--fg-muted); }
@media (max-width: 760px) {
  .bio { grid-template-columns: 1fr; }
}

/* ---------- Legal pages (Privacy / Terms / Cookie / Acceptable Use) ----------
   Switched to Source Serif 4 for long-form reading. Loaded per-page via
   Google Fonts so the rest of the site stays on Switzer. */
.legal-doc {
  font-family: 'Source Serif 4', Georgia, 'Times New Roman', serif;
  max-width: 48rem;
  margin: 0 auto;
  /* Top padding clears the absolute header (~80px) and adds breathing room
     beneath it before the title — same idea as .split-hero__panel--xl. */
  padding: clamp(7rem, 11vw, 10rem) clamp(1.25rem, 4vw, 2rem) clamp(4rem, 8vw, 6rem);
  color: var(--fg);
  font-size: 1.0625rem;
  line-height: 1.6;
  font-weight: 400;
  /* Allow very long unbroken strings (URLs in cookie-policy) to wrap so
     narrow viewports don't get horizontal overflow. */
  overflow-wrap: anywhere;
}
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.legal-doc__header {
  border-bottom: 1px solid var(--line);
  padding-bottom: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: clamp(2rem, 4vw, 3rem);
}
.legal-doc h1 {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0 0 0.5rem;
  color: var(--fg);
}
.legal-doc__meta {
  font-size: 0.875rem;
  color: var(--fg-muted);
  font-style: italic;
  margin: 0;
}
.legal-doc h2 {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: clamp(1.375rem, 2.25vw, 1.625rem);
  font-weight: 600;
  line-height: 1.25;
  margin: clamp(2.5rem, 5vw, 3.5rem) 0 0.875rem;
  color: var(--fg);
}
.legal-doc h3 {
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: clamp(1.0625rem, 1.5vw, 1.25rem);
  font-weight: 600;
  line-height: 1.3;
  margin: 1.75rem 0 0.625rem;
  color: var(--fg);
}
.legal-doc p {
  margin: 0 0 1rem;
  color: var(--fg-muted);
}
.legal-doc ul,
.legal-doc ol {
  margin: 0 0 1rem;
  padding-left: 1.5rem;
  list-style: revert;
  color: var(--fg-muted);
}
.legal-doc li { margin-bottom: 0.5rem; }
.legal-doc li > ul,
.legal-doc li > ol { margin-top: 0.5rem; }
.legal-doc a {
  color: var(--fg);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.legal-doc a:hover { color: var(--fg-muted); }
.legal-doc strong { font-weight: 600; color: var(--fg); }
.legal-doc em { font-style: italic; }
.legal-doc address {
  font-style: normal;
  margin-top: 0.5rem;
  color: var(--fg-muted);
}
.legal-doc table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
  font-size: 0.9375rem;
  color: var(--fg-muted);
}
.legal-doc th,
.legal-doc td {
  border: 1px solid var(--line);
  padding: 0.75rem;
  text-align: left;
  vertical-align: top;
}
.legal-doc th {
  background: var(--bg-deep);
  font-weight: 600;
  color: var(--fg);
}

/* ---------- Cookie consent banner ---------- */
.cookie-consent {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 50;
  max-width: 28rem;
  margin: 0 auto;
}
.cookie-consent__card {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.12);
}
.cookie-consent__title { font-size: 1.0625rem; font-weight: 600; line-height: 1.2; margin: 0 0 0.5rem; color: var(--fg); outline: none; }
.cookie-consent__body { font-size: 0.875rem; line-height: 1.5; color: var(--fg-muted); margin: 0 0 1.25rem; }
.cookie-consent__link { color: var(--fg); font-weight: 500; text-decoration: underline; }
.cookie-consent__actions { display: flex; gap: 0.75rem; }
.cookie-consent__actions .btn { flex: 1; padding: 0.5rem 0.875rem; min-width: 0; min-height: 44px; }
.cookie-consent.is-entering { animation: cookie-consent-up 320ms var(--easing) both; }
.cookie-consent.is-leaving { animation: cookie-consent-down 220ms var(--easing) both; }
@keyframes cookie-consent-up {
  from { opacity: 0; transform: translateY(1rem); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes cookie-consent-down {
  from { opacity: 1; transform: translateY(0); }
  to   { opacity: 0; transform: translateY(1rem); }
}
@media (min-width: 720px) {
  .cookie-consent { left: auto; right: 1.5rem; bottom: 1.5rem; margin: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .cookie-consent.is-entering,
  .cookie-consent.is-leaving { animation: none; }
}

/* ---------- Utilities ---------- */
.eyebrow-row {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--fg-muted);
}
.text-muted { color: var(--fg-muted); }
.max-w-prose { max-width: 56ch; }

/* ---------- On-load reveal animations ----------
   Matches Wix Thunderbolt's motion-fadeIn + motion-revealIn entrance system.
   - `.js` class is set synchronously in <head> before paint, so CSS hides target
     elements until JS marks them [data-revealed] via IntersectionObserver.
   - Falls back to instantly visible if JS is disabled or reduced motion is preferred.
*/

@keyframes v2-fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* Reveal animates opacity + clip-path together. Starting state must be opacity:0
   alone (not a degenerate clip-path) — Chromium treats zero-area clip-paths as
   zero visible intersection, which breaks IntersectionObserver. */
@keyframes v2-reveal-in {
  0% {
    opacity: 0;
    clip-path: polygon(0% 100%, 100% 100%, 100% 100%, 0% 100%);
  }
  0.0001% {
    opacity: 1;
  }
  100% {
    /* Bottom extends to 130% so descenders (g, p, y, j, q) aren't clipped
       by the line box (line-height: 1.0 on .h-display / .h-headline). */
    clip-path: polygon(0% 0%, 100% 0%, 100% 130%, 0% 130%);
  }
}

/* Wink-in: clip-path opens from horizontal midline outward (top + bottom
   simultaneously). Used on the colored Practice Area / Specialization tiles. */
@keyframes v2-wink-in {
  0% {
    opacity: 0;
    clip-path: polygon(0% 50%, 100% 50%, 100% 50%, 0% 50%);
  }
  0.0001% {
    opacity: 1;
  }
  100% {
    clip-path: polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%);
  }
}

/* Reveal-down: clip-path opens from the top edge downward.
   Used on the Voices of Our Partners testimonial cells. */
@keyframes v2-reveal-down {
  0% {
    opacity: 0;
    clip-path: polygon(0% 0%, 100% 0%, 100% 0%, 0% 0%);
  }
  0.0001% {
    opacity: 1;
  }
  100% {
    clip-path: polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%);
  }
}

@media (prefers-reduced-motion: no-preference) {
  /* Initial hidden state for all reveal targets — opacity only so IO sees them */
  .js .h-display:not([data-revealed]),
  .js .h-headline:not([data-revealed]),
  .js .h-section:not([data-revealed]),
  .js .h-card:not([data-revealed]),
  .js .lead:not([data-revealed]),
  .js .panel:not([data-revealed]),
  .js .tess__cell:not([data-revealed]),
  .js .row:not([data-revealed]),
  .js .advantage:not([data-revealed]),
  .js .home-hero__lede:not([data-revealed]),
  .js .split-hero__photo:not([data-revealed]),
  .js .contact-hero__form:not([data-revealed]),
  .js .two-col > div:not([data-revealed]) {
    opacity: 0;
  }

  /* Default reveal: opacity fade — easing unified to cubic-bezier(0.645, 0.045, 0.355, 1)
     (easeInOutCubic) so every section shares the same motion cadence. */
  .js [data-revealed] {
    animation: 1200ms cubic-bezier(0.645, 0.045, 0.355, 1) 1ms 1 normal both v2-fade-in;
  }

  /* Colored grid tiles + the entire How We Work split (photo + dark panel together):
     wink-in clip reveal from midline outward.
     Easing matches testimonials so all three sections share the same motion cadence. */
  .js .panel:not(.panel--photo)[data-revealed],
  .js .advantage[data-revealed] {
    animation: 1200ms cubic-bezier(0.645, 0.045, 0.355, 1) 1ms 1 normal both v2-wink-in;
  }

  /* Voices of Our Partners testimonial cells: top-down clip reveal */
  .js .tess__cell[data-revealed] {
    animation: 1200ms cubic-bezier(0.645, 0.045, 0.355, 1) 1ms 1 normal both v2-reveal-down;
  }

  /* Practice Areas photo panel is static — opacity stays at 1 and no animation runs */
  .js .panel--photo:not([data-revealed]),
  .js .panel--photo[data-revealed] {
    opacity: 1;
    animation: none;
  }

  /* Big headlines: clip-path reveal (1200ms, easeInOutCubic) — overrides default */
  .js .h-display[data-revealed],
  .js .h-headline[data-revealed] {
    animation: 1200ms cubic-bezier(0.645, 0.045, 0.355, 1) 1ms 1 normal both v2-reveal-in;
  }

  /* Opt-out: anything inside a .no-reveal container stays visible immediately,
     no scroll-in animation. Use for content that should be readable even when
     the user never scrolls far enough to trigger the IntersectionObserver.
     !important needed to override the per-element [data-revealed] animations
     above, which carry higher specificity. */
  .js .no-reveal,
  .js .no-reveal * {
    opacity: 1 !important;
    animation: none !important;
    clip-path: none !important;
  }
}

/* Page transitions intentionally disabled — links navigate normally. */

/* ---------- AODA / WCAG 2.2 AA — focus, target size, scroll-margin ---------- */

/* Visible focus ring for keyboard users (SC 2.4.7). Covers every interactive
   element. Uses outline so it doesn't shift layout, and offsets for clarity. */
a:focus-visible,
button:focus-visible,
[role="button"]:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 2px;
  border-radius: 2px;
}
/* Dark-bg surfaces need a light ring instead. */
.contact-hero__form a:focus-visible,
.contact-hero__form button:focus-visible,
.contact-hero__form input:focus-visible,
.contact-hero__form textarea:focus-visible,
.contact-hero__form select:focus-visible {
  outline-color: var(--inverse);
}

/* No scroll-margin-top on hash anchors: the site header is position:absolute
   (not sticky/fixed), so it scrolls away with the page and never obscures the
   scrolled-to element. Adding scroll-margin here would leave a strip of the
   previous section visible above the target. */

/* Minimum tap-target size (SC 2.5.8 — 24x24 CSS px). Link-only navigation
   elements get padding so they hit the threshold without changing visual
   layout much. */
.nav__link {
  padding: 0.5rem 0;
  display: inline-block;
}
.site-footer__col a,
.site-footer__col button,
.panel__links a,
.legal-doc a {
  display: inline-block;
  padding: 0.25rem 0;
}

/* ---------- Mobile nav toggle (hamburger) ---------- */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  padding: 10px;
  background: transparent;
  border: 0;
  cursor: pointer;
  z-index: 200;
}
.nav-toggle__bar {
  display: block;
  width: 26px;
  height: 2px;
  background: var(--fg);
  transition: transform 200ms ease, opacity 200ms ease;
}
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .nav-toggle { display: inline-flex; }
  .nav {
    position: fixed;
    inset: 0;
    background: var(--bg);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 1.75rem;
    transform: translateX(100%);
    transition: transform 250ms ease;
    z-index: 150;
  }
  .nav.is-open { transform: translateX(0); }
  .nav__link { font-size: 1.25rem; }
  .nav .btn { padding: 0.75rem 1.5rem; font-size: 1rem; }

  /* Home hero: stack copy on top, image below — matches about/FAQ pattern.
     Drops the absolute layout. Text clears the header's cream backdrop via
     padding-top; image gets a top + bottom fade so it blends into the
     surrounding cream canvas. */
  .home-hero {
    height: auto;
    overflow: visible;
    display: flex;
    flex-direction: column;
    padding-top: clamp(7rem, 18vw, 9rem);
  }
  .home-hero::after { display: none; }
  .home-hero__content {
    order: 1;
    position: static;
    top: auto;
    left: auto;
    right: auto;
    max-width: 100%;
    padding: 0 clamp(1.5rem, 5vw, 2.5rem) clamp(2rem, 6vw, 3rem);
  }
  .home-hero__title { max-width: none; }
  .home-hero__bg {
    order: 2;
    position: static;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    object-position: 100% center;
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 15%, #000 85%, transparent 100%);
            mask-image: linear-gradient(to bottom, transparent 0%, #000 15%, #000 85%, transparent 100%);
  }

  .split-hero,
  .contact-hero,
  .advantage { grid-template-columns: 1fr; }
  .split-hero__photo,
  .advantage__photo { min-height: 320px; }

  /* About/FAQ mobile: photo is stacked below the text panel — swap the
     left-edge fade for a top-edge fade so it blends down from the panel
     bg above. Reset the desktop-only horizontal shift, and crop the left
     side of the source (where the photo has a soft vignette) by anchoring
     the position toward the right. */
  .page-about .split-hero__photo,
  .page-faq .split-hero__photo {
    margin-left: 0;
    background-position: 80% center;
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 30%);
            mask-image: linear-gradient(to bottom, transparent 0%, #000 30%);
  }

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

  .tess { grid-template-columns: repeat(2, 1fr); }
  .tess__cell:nth-child(2) { border-right: 0; }
  .tess__cell:nth-child(-n+2) { border-bottom: 1px solid var(--line); }

  .section-head,
  .two-col { grid-template-columns: 1fr; }

  .rows__head,
  .row { grid-template-columns: 3rem 1fr; }
  .rows__head-title,
  .row__label { grid-column: 2; }
  .row__copy { grid-column: 1 / -1; padding-left: 3rem; }
  /* rows--no-num: drop the (now-empty) icon column and stack label + copy
     so the label isn't pushed to the right edge on narrow screens. */
  .rows--no-num .row { grid-template-columns: 1fr; }
  .rows--no-num .row__label { grid-column: 1; }
  .rows--no-num .row__copy { grid-column: 1; padding-left: 0; }

  .form { grid-template-columns: 1fr; }

  .site-footer__grid { grid-template-columns: 1fr; }
}

@media (max-width: 540px) {
  .panel-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .panel { aspect-ratio: auto; min-height: 260px; }
  .tess { grid-template-columns: 1fr; }
  .tess__cell { border-right: 0; border-bottom: 1px solid var(--line); }
  .tess__cell:last-child { border-bottom: 0; }

  /* Mobile leadership / bio layout:
     - Hide the whole leadership panel-grid (name cards + photos). It became
       redundant on mobile once each .bio gained its own photo + LinkedIn —
       the "Our Leadership Team" h2 above stays visible as the section intro.
     - Each .bio shows its inline portrait at the top, and the LinkedIn link
       sits under the name so each leader is a single self-contained block.
     - Drop the about-page sections' 100vh min-height: it exists to make
       each section stand alone when reached via nav on desktop; on small
       mobile it becomes a giant empty gap below sections whose content has
       been hidden or compacted.
     - Collapse the now-empty leadership section's bottom padding +
       section-head margin, and trim the bios section's top padding, so the
       "Our Leadership Team" h2 sits ~40px above Candace's photo instead of
       ~160px (stacked section padding + section-head margin). */
  .page-about main > .section { min-height: 0; }
  .page-about main > .section:has(.panel-grid) { padding-bottom: 0; }
  .page-about main > .section:has(.panel-grid) .section-head { margin-bottom: 0; }
  .page-about main > .section[aria-labelledby="leadership-bios-title"] { padding-top: clamp(2rem, 5vw, 2.5rem); }
  .panel-grid { display: none; }
  .bio__photo {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    margin-bottom: clamp(1rem, 3vw, 1.5rem);
  }
  .bio__links { display: block; }
}
