/* ==========================================================
   SITE HEADER + PRIMARY NAV
   A sticky, always-visible header: a dark utility strip with
   phone + email, then a nav row with the wordmark, the page
   links (no hamburger), and the standing consultation CTA.
   Injected on every page by js/nav.js.
   ========================================================== */

.site-header{
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--cream-bg);
  border-bottom: 1px solid var(--line);
  font-family: var(--font-sans);
}

/* --- utility strip: contact details, always on screen --- */
.site-header__utility{
  background: var(--navy);
  color: var(--text-on-dark);
}

.site-header__utility-inner{
  max-width: 1200px;
  margin: 0 auto;
  padding: 7px var(--container-pad);
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px 24px;
  font-size: var(--size-ui);
}

.site-header__contact{
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--text-on-dark);
  letter-spacing: 0.01em;
}

.site-header__contact svg{
  width: 14px;
  height: 14px;
  opacity: 0.85;
  flex-shrink: 0;
}

.site-header__contact:hover,
.site-header__contact:focus-visible{
  text-decoration: underline;
}

/* --- main row: wordmark / nav / CTA --- */
.site-header__main{
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px var(--container-pad);
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.site-header__brand{
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
}

.site-header__brand img{
  display: block;
  height: 38.4px; /* 32px + 20% */
  width: auto;
  /* The wordmark's bounding box is centered on its full ink extent,
     but the "py" descenders (with no counterpart in "an_o") pull
     that box's center lower than the word's optical/x-height center.
     Flexbox centers the box, which leaves the readable word sitting
     visibly above the nav text's baseline — nudge it down to compensate. */
  transform: translateY(4.7px);
}

.site-nav{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: clamp(12px, 2.4vw, 30px);
  margin-left: auto;
}

.site-nav a{
  font-size: var(--size-ui);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 6px 1px;
  border-bottom: 2px solid transparent;
  transition: color var(--dur-hover) var(--ease-slow),
              border-color var(--dur-hover) var(--ease-slow);
}

.site-nav a:hover,
.site-nav a:focus-visible{
  color: var(--forest-green-ink);
}

.site-nav a[aria-current="page"]{
  color: var(--navy);
  border-bottom-color: var(--forest-green-ink);
}

/* CTA — the .site-header prefix wins the specificity fight against
   contact.css's full-width `.btn` rule. */
.site-header .site-header__cta.btn{
  flex-shrink: 0;
  width: auto;
  margin-left: var(--space-sm);
  padding: 11px 20px;
  font-size: var(--size-body-xs);
  white-space: nowrap;
}

.site-header__cta-short{ display: none; }

/* ---------------- responsive ---------------- */

/* Nav drops to its own full-width row below the wordmark + CTA. */
@media (max-width: 900px){
  .site-header__main{
    flex-wrap: wrap;
    justify-content: space-between;
    gap: var(--space-sm);
  }
  .site-nav{
    order: 3;
    width: 100%;
    margin-left: 0;
    justify-content: center;
    gap: 4px 20px;
    padding-top: 10px;
    border-top: 1px solid var(--line);
  }
  .site-header .site-header__cta.btn{
    margin-left: 0;
  }
}

@media (max-width: 520px){
  .site-header__utility-inner{
    justify-content: center;
    gap: 6px 16px;
    font-size: 12px;
  }
  .site-header__brand img{ height: 33.6px; }
  .site-header .site-header__cta.btn{
    font-size: 13px;
    padding: 10px 14px;
  }
  .site-header__cta-full{ display: none; }
  .site-header__cta-short{ display: inline; }

  /* keep the five links on a single row on a phone */
  .site-nav{
    gap: 3px 13px;
    padding-top: 8px;
  }
  .site-nav a{
    font-size: 11px;
    letter-spacing: 0.03em;
    padding: 4px 0;
  }
}
