/* ---------- Fonts (self-hosted variable fonts, latin subset) ---------- */

@font-face {
  font-family: "Playfair Display";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url("/assets/fonts/playfair-display-var.woff2") format("woff2");
}

@font-face {
  font-family: "Open Sans";
  font-style: normal;
  font-weight: 300 800;
  font-display: swap;
  src: url("/assets/fonts/open-sans-var.woff2") format("woff2");
}

/* ---------- Tokens ---------- */

:root {
  --color-bg: #ffffff;
  --color-bg-alt: #faf6f0; /* cream pulled from the banner's sandy tones (#c8a888) */
  --color-border-warm: #ebe3d8;
  /* Palette sampled from the banner photo */
  --color-teal: #319098;
  --color-teal-dark: #23696f;
  --color-red: #a7363b;
  --color-red-dark: #86282d;
  --color-navy: #32395c;
  --color-olive: #5c6b3f;
  --color-tan: #c2a387;

  --color-text: #3a3a3a;
  --color-muted: #4b4f58;
  --color-heading: var(--color-navy);
  --color-primary: var(--color-teal);
  --color-primary-dark: var(--color-teal-dark);
  --color-accent: var(--color-red);
  --color-accent-dark: var(--color-red-dark);
  --color-panel: var(--color-tan); /* block behind framed photos */
  --color-footer: var(--color-navy);
  --color-footer-text: #ffffff;
  --color-border: #d9dde2;
  --color-error: var(--color-red);
  --color-success: var(--color-olive);
  --font-heading: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: "Open Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --container: 1200px;
  --container-narrow: 820px;
  --space: clamp(2.5rem, 6vw, 5rem);
  --radius: 6px;
  /* Heading scale: five steps, every heading snaps to one */
  --fs-display: clamp(3rem, 9vw, 6.5rem);      /* home name */
  --fs-page-title: clamp(2.4rem, 6vw, 4rem);    /* subpage banner titles */
  --fs-section: clamp(1.7rem, 3.5vw, 2.4rem);   /* centered section headings */
  --fs-subheading: clamp(1.4rem, 2vw, 1.625rem); /* ledes, values title, form title */
  --fs-minor: 1.25rem;                           /* h3s, card titles */

  --hero-curve: clamp(32px, 5vw, 64px); /* bottom-left curve on banners, cut into the tan sheet */
  --hero-band: clamp(14px, 2.2vw, 26px); /* band under the banners */
  --footer-band: clamp(8px, 1.1vw, 13px); /* thinner band above the footer */
  --header-height: 139px; /* tall (unscrolled) header; body reserves this so shrinking never shifts content */
  --header-height-compact: 76px;
  --radius-lg: 18px;
  --frame-offset: clamp(8px, 1.1vw, 12px);
}

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

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 90px; /* anchor targets clear the compact fixed header */
}

body {
  margin: 0;
  padding-top: var(--header-height);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--color-text);
  background: var(--color-bg);
}

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

picture {
  display: contents;
}

/* Text links use the darker teal for AA contrast; bright teal is reserved for decorative accents */
a {
  color: var(--color-primary-dark);
  text-decoration: none;
}

a:hover,
a:focus {
  color: var(--color-navy);
  text-decoration: underline;
}

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

h1 {
  font-size: var(--fs-page-title);
}

h2 {
  font-size: var(--fs-section);
}

/* h3s are the one sans-serif heading: smaller, bold, body face */
h3 {
  font-family: var(--font-body);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

p {
  margin: 0 0 1.1em;
}

address {
  font-style: normal;
  margin: 0 0 1.1em;
}

/* Ornament divider: three small olive diamonds in a row (red is reserved for actions).
   A markdown "---" inside .prose renders the same divider. */
hr.divider,
.prose hr {
  width: 39px;
  height: 7px;
  margin: 2rem auto;
  border: 0;
  background-color: var(--color-olive);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 39 7'%3E%3Cpath d='M3.5 0 7 3.5 3.5 7 0 3.5zM19.5 0 23 3.5 19.5 7 16 3.5zM35.5 0 39 3.5 35.5 7 32 3.5z'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 39 7'%3E%3Cpath d='M3.5 0 7 3.5 3.5 7 0 3.5zM19.5 0 23 3.5 19.5 7 16 3.5zM35.5 0 39 3.5 35.5 7 32 3.5z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.container {
  width: min(100% - 2.5rem, var(--container));
  margin-inline: auto;
}

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

.center {
  text-align: center;
}

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

.section--tight {
  padding-block: calc(var(--space) * 0.75);
}

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

.section-title {
  text-align: center;
}

/* Heading mark: two hairlines with a larger teal diamond between them */
.section-title,
.page-header__title,
.mark-left {
  --mark-line: rgba(50, 57, 92, 0.25);
  --mark-diamond: var(--color-teal);
}

.section-title::after,
.page-header__title::after,
.mark-left::after {
  content: "";
  display: block;
  width: 160px;
  height: 11px;
  margin: 0.85rem auto 0;
  background:
    linear-gradient(var(--mark-line), var(--mark-line)) left center / calc(50% - 16px) 1px no-repeat,
    linear-gradient(var(--mark-line), var(--mark-line)) right center / calc(50% - 16px) 1px no-repeat;
  position: relative;
}

.section-title::before,
.page-header__title::before,
.mark-left::before {
  content: "";
  display: block;
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 11px;
  height: 11px;
  background: var(--mark-diamond);
  transform: translateX(-50%) rotate(45deg);
}

.section-title,
.page-header__title,
.mark-left {
  position: relative;
}

.lede {
  font-family: var(--font-heading);
  font-size: var(--fs-subheading);
  font-weight: 700;
  color: var(--color-heading);
}

.prose p {
  font-size: 1.02rem;
}

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

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  background: var(--color-navy);
  color: #fff;
  font-weight: 600;
  padding: 0.6rem 1rem;
  border-radius: var(--radius);
}

.skip-link:focus {
  top: 1rem;
  color: #fff; /* the global a:focus rule would otherwise turn it navy on navy */
  text-decoration: underline;
  outline-color: var(--color-tan);
}

:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: 2px;
}

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

.btn {
  display: inline-block;
  background: var(--color-accent);
  color: #fff;
  font-weight: 600;
  padding: 0.75rem 1.6rem;
  border: 0;
  border-radius: var(--radius);
  cursor: pointer;
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.3;
  transition: background 0.15s ease;
}

.btn:hover,
.btn:focus {
  background: var(--color-accent-dark);
  color: #fff;
  text-decoration: none;
}

.btn:disabled {
  opacity: 0.7;
  cursor: wait;
}

/* ---------- Image frame (blue offset block behind photos) ---------- */

.img-frame {
  position: relative;
  display: block;
  isolation: isolate;
}

.img-frame::before {
  content: "";
  position: absolute;
  top: calc(var(--frame-offset) * -1);
  right: calc(var(--frame-offset) * -1);
  bottom: var(--frame-offset);
  left: var(--frame-offset);
  background: var(--color-panel);
  border-radius: var(--radius-lg);
  z-index: -1;
}

.img-frame--olive::before {
  background: var(--color-olive);
}

.img-frame img {
  width: 100%;
  border-radius: calc(var(--radius-lg) - 6px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
}

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

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  height: var(--header-height);
  background: var(--color-bg-alt);
  box-shadow: 0 1px 0 var(--color-border-warm);
  transition: height 0.15s linear;
}

.site-header.is-scrolled {
  height: var(--header-height-compact);
}

/* Full-bleed header content: a fixed inset instead of the centered container, so the
   round logo stays near the page edge above the banner's curved corner on any screen */
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  gap: 1rem;
  width: auto;
  max-width: none;
  margin-inline: 0;
  padding-inline: clamp(1rem, 2vw, 1.75rem);
}

/* Brand: large round logo + wordmark; both scale down as the bar shrinks */
.site-header__brand {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-width: 0;
  text-decoration: none;
}

.site-header__brand:hover,
.site-header__brand:focus {
  text-decoration: none;
}

.site-header__brand img {
  flex: none;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 4px solid var(--color-tan);
  box-sizing: border-box;
  transition: width 0.15s linear, height 0.15s linear, border-width 0.15s linear;
}

.site-header.is-scrolled .site-header__brand img {
  width: 56px;
  height: 56px;
  border-width: 3px;
}

.site-header__wordmark {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
  min-width: 0;
}

.site-header__wordmark-name {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.6rem;
  color: var(--color-navy);
  white-space: nowrap;
  transition: font-size 0.15s linear;
}

.site-header__wordmark-office {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-red);
  margin-top: 0.3rem;
  white-space: nowrap;
}

/* Between the mobile breakpoint and ~960px the full nav is showing but there isn't
   room for the office line beside it, so drop the line and tighten the name */
@media (max-width: 960px) {
  .site-header__wordmark-office-rest {
    display: none;
  }

  .site-header__wordmark-name {
    font-size: 1.35rem;
  }
}

.site-header.is-scrolled .site-header__wordmark-name {
  font-size: 1.2rem;
}

.site-header.is-scrolled .site-header__wordmark-office-rest {
  display: none;
}

.site-header.is-scrolled .site-header__wordmark-office {
  margin-top: 0.15rem;
}

.site-nav ul {
  list-style: none;
  display: flex;
  gap: 0.75rem;
  margin: 0;
  padding: 0;
}

.site-nav a {
  display: inline-block;
  padding: 0.36rem 0.8rem 0.3rem; /* 1px optical shift: the line box leaves more room under the baseline */
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--color-navy);
  font-weight: 600;
  font-size: 0.92rem;
  line-height: 1.4;
}

/* Hover: 1px dark-teal pill outline */
.site-nav a:hover,
.site-nav a:focus-visible {
  border-color: var(--color-teal-dark);
  text-decoration: none;
}

/* Active page: cream text on a dark-teal pill (bright teal fails text contrast here) */
.site-nav a[aria-current="page"] {
  background: var(--color-teal-dark);
  border-color: var(--color-teal-dark);
  color: var(--color-bg-alt);
}

.site-nav a[aria-current="page"]:hover,
.site-nav a[aria-current="page"]:focus-visible {
  color: #fff;
}

.nav-toggle {
  display: none;
  background: none;
  border: 0;
  padding: 0.5rem;
  cursor: pointer;
}

.nav-toggle__bar {
  display: block;
  width: 26px;
  height: 3px;
  background: var(--color-heading);
  margin: 5px 0;
  border-radius: 2px;
}

@media (max-width: 720px) {
  :root {
    --header-height: 111px;
    --header-height-compact: 64px;
  }

  .nav-toggle {
    display: block;
  }

  .site-header__brand img {
    width: 92px;
    height: 92px;
  }

  .site-header.is-scrolled .site-header__brand img {
    width: 48px;
    height: 48px;
  }

  .site-header__brand {
    gap: 0.75rem;
  }

  .site-header__wordmark-name {
    font-size: 1.2rem;
  }

  .site-header__wordmark-office {
    font-size: 0.7rem;
    margin-top: 0.2rem;
  }

  .site-header.is-scrolled .site-header__wordmark-name {
    font-size: 1.05rem;
  }

  .site-nav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: var(--color-bg-alt);
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
  }

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

  .site-nav ul {
    flex-direction: column;
    gap: 0;
    padding: 0;
  }

  .site-nav a {
    display: block;
    padding: 0.9rem 1.5rem;
    border: 0;
    border-radius: 0;
    border-top: 1px solid var(--color-border-warm);
  }

  .site-nav a:hover,
  .site-nav a:focus-visible {
    border-color: var(--color-border-warm);
    background: rgba(194, 163, 135, 0.15);
  }
}

/* ---------- Hero band ----------
   A navy sheet behind each banner: the banner's bottom-left curve reveals it, and it
   shows as a band along the banner's bottom edge. (The footer uses the tan version.) */
.hero-band {
  background: var(--color-navy);
  padding-bottom: var(--hero-band);
}

/* home page: tan sheet behind the photo (subpages keep navy) */
.home-header .hero-band {
  background: var(--color-tan);
}

/* the home image is wrapped in <picture> by the image transform, hence the descendant selector */
.hero-band .home-header__image,
.hero-band > .page-header {
  border-bottom-left-radius: var(--hero-curve);
}

/* ---------- Home header (full-width banner, uncropped) ---------- */

.home-header__image {
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 1;
}

.home-header__text {
  padding-block: var(--space) 0;
}

.home-header__name {
  position: relative;
  font-size: var(--fs-display);
  margin-bottom: 0.35em;
  --mark-line: rgba(50, 57, 92, 0.3);
  --mark-diamond: var(--color-teal);
}

/* Exaggerated heading mark under the name: long hairlines, larger diamond */
.home-header__name::after {
  content: "";
  display: block;
  width: min(420px, 80%);
  height: 17px;
  margin: 0.3em auto 0;
  background:
    linear-gradient(var(--mark-line), var(--mark-line)) left center / calc(50% - 26px) 1px no-repeat,
    linear-gradient(var(--mark-line), var(--mark-line)) right center / calc(50% - 26px) 1px no-repeat;
}

.home-header__name::before {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 17px;
  height: 17px;
  background: var(--mark-diamond);
  transform: translateX(-50%) rotate(45deg);
}

.home-header__office {
  font-family: var(--font-heading);
  font-size: clamp(1.3rem, 2.4vw, 1.75rem);
  font-weight: 600;
  color: var(--color-heading);
  margin: 0 0 1.25rem;
}

.home-header__tagline {
  font-family: var(--font-heading);
  font-size: clamp(1.25rem, 2.6vw, 2rem);
  font-weight: 700;
  margin: 1.25rem 0 0;
}

/* ---------- Ribbon (campaign banner) ---------- */

.ribbon {
  --ribbon: var(--color-red);
  --ribbon-tail: var(--color-red-dark);
  --ribbon-fold: #5f1c20;
  --ribbon-text: var(--color-bg-alt);
  --tail: 1.1em;

  position: relative;
  display: inline-block;
  max-width: calc(100% - var(--tail) * 2);
  padding: 0.45em 1.4em;
  background: var(--ribbon);
  color: var(--ribbon-text);
  line-height: 1.25;
  letter-spacing: 0.02em;
  text-align: center;
  text-wrap: balance;
}

/* Tails: sit behind the band, offset down, with a notched outer end */
.ribbon::before,
.ribbon::after {
  content: "";
  position: absolute;
  top: 0.4em;
  width: var(--tail);
  height: 100%;
  background: var(--ribbon-tail);
  z-index: -1;
}

.ribbon::before {
  left: calc(var(--tail) * -0.75);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 0.4em 50%);
}

.ribbon::after {
  right: calc(var(--tail) * -0.75);
  clip-path: polygon(0 0, 100% 0, calc(100% - 0.4em) 50%, 100% 100%, 0 100%);
}

/* Folds: small dark wedges where the band tucks behind the tails */
.ribbon__text::before,
.ribbon__text::after {
  content: "";
  position: absolute;
  bottom: -0.4em;
  width: calc(var(--tail) * 0.25);
  height: 0.4em;
  background: var(--ribbon-fold);
}

.ribbon__text::before {
  left: 0;
  clip-path: polygon(0 0, 100% 0, 100% 100%);
}

.ribbon__text::after {
  right: 0;
  clip-path: polygon(0 0, 100% 0, 0 100%);
}

/* ---------- Page header (subpages: banner slice with title) ---------- */

.page-header {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  place-items: center;
  min-height: clamp(220px, 32vh, 340px);
  color: #fff;
}

.page-header__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* keep the Mt. Juliet sign in frame */
  object-position: 78% 35%;
  z-index: -2;
}

.page-header__overlay {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    to bottom,
    rgba(50, 57, 92, 0.55),
    rgba(50, 57, 92, 0.75)
  );
}

.page-header__content {
  padding-block: clamp(2rem, 5vw, 3.5rem);
}

.page-header__title {
  font-size: var(--fs-page-title);
  margin: 0;
  color: #fff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
}

.page-header__title {
  --mark-line: rgba(250, 246, 240, 0.5);
  --mark-diamond: var(--color-bg-alt);
}

.page-header__subtitle {
  font-family: var(--font-heading);
  font-size: clamp(1.1rem, 2.2vw, 1.5rem);
  color: var(--color-bg-alt);
  margin: 1rem 0 0;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.35);
}

/* ---------- Values (3-column) ---------- */

.values__grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1.1fr;
  grid-template-areas:
    "first second photo"
    "cta   .      photo";
  gap: 0 2.5rem;
  align-items: start;
}

.values__col {
  grid-area: first;
}

.values__col--second {
  grid-area: second;
}

.values__cta {
  grid-area: cta;
  margin: 0.5rem 0 0;
}

.values__photo {
  grid-area: photo;
}

.values__title {
  font-size: var(--fs-section); /* same step as the About Me section heading */
}

.values__col h3 {
  margin-top: 1.5rem;
}

.values__photo {
  padding: var(--frame-offset) var(--frame-offset) 0 0;
}

@media (max-width: 900px) {
  .values__grid {
    grid-template-columns: 1fr;
    grid-template-areas:
      "photo"
      "first"
      "second"
      "cta";
    gap: 0;
  }

  .values__cta {
    margin: 1rem 0 0;
  }

  .values__photo {
    margin-bottom: 2.5rem;
  }

  .values__photo {
    max-width: 480px;
    margin-inline: auto;
  }
}

/* ---------- About ---------- */

.about {
  display: grid;
  grid-template-columns: minmax(0, 480px) 1fr;
  gap: 3rem;
  align-items: center;
}

.about__photo {
  padding: var(--frame-offset) var(--frame-offset) 0 0;
}

.about__email a {
  font-family: var(--font-heading);
  font-size: 1.15rem;
}

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

/* ---------- Cards ---------- */

.card {
  background: var(--color-bg);
  border: 1px solid var(--color-border-warm);
  border-radius: var(--radius);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
}

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

.contact-cards {
  list-style: none;
  margin: 0 0 2.5rem;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
}

.contact-card {
  padding: 2rem 1.5rem;
  text-align: center;
}

.contact-card p {
  margin: 0;
  font-size: 1.05rem;
}

.contact-card__icon {
  width: 40px;
  height: 40px;
  fill: var(--color-olive);
  margin: 0 auto 1rem;
  display: block;
}

.contact-card__title {
  font-size: var(--fs-minor);
  margin-bottom: 0.75rem;
  overflow-wrap: normal; /* the email carries a <wbr> before the @ for a clean break */
}

.contact-card__title a {
  color: var(--color-heading);
}

.contact-card__title a:hover,
.contact-card__title a:focus {
  color: var(--color-primary);
  text-decoration: none;
}

.contact-form-card {
  padding: clamp(1.75rem, 5vw, 3.5rem) clamp(1.25rem, 6vw, 5rem);
}

.contact-form-card__title {
  margin-bottom: 1.75rem;
}

/* Left-aligned headings: same mark minus the left hairline (diamond, then the right hairline) */
.mark-left::after {
  margin-left: 0;
  margin-right: auto;
  width: 88px;
  background: linear-gradient(var(--mark-line), var(--mark-line)) right center / 64px 1px no-repeat;
}

.mark-left::before {
  left: 8px;
}

@media (max-width: 900px) {
  .contact-cards {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

/* ---------- Forms ---------- */

.form__field {
  margin-bottom: 1.1rem;
}

.form__field label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.35rem;
  font-size: 0.95rem;
}

.form input:not([type="hidden"]),
.form textarea {
  width: 100%;
  font: inherit;
  color: var(--color-text);
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 0.7rem 0.9rem;
}

.form input:focus,
.form textarea:focus {
  border-color: var(--color-primary);
  outline: 3px solid rgba(49, 144, 152, 0.25);
}

.form textarea {
  resize: vertical;
  min-height: 140px;
}

.form--inline .form__row {
  display: flex;
  gap: 0.75rem;
  max-width: 560px;
  margin-inline: auto;
}

.form--inline input {
  flex: 1;
}

@media (max-width: 520px) {
  .form--inline .form__row {
    flex-direction: column;
  }

  /* Stacked forms: submit buttons span the full width, matching the stacked Subscribe button */
  .form button[type="submit"] {
    display: block;
    width: 100%;
  }
}

.form__status {
  margin: 0.75rem 0 0;
  font-weight: 600;
  min-height: 1.5em;
}

.form__status.is-error {
  color: var(--color-error);
}

.form__status.is-success {
  color: var(--color-success);
}

.form.is-submitted .form__row,
.form.is-submitted .form__field,
.form.is-submitted button[type="submit"] {
  display: none;
}

.newsletter p {
  max-width: 600px;
  margin-inline: auto;
}

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

/* Tan sheet behind the footer, mirroring the hero band on the opposite corner,
   with a thinner band so it reads as a softer echo rather than a repeat. */
.footer-band {
  background: var(--color-tan);
  padding-top: var(--footer-band);
}

.footer-band > .site-footer {
  border-top-right-radius: var(--hero-curve);
}


.site-footer {
  background: var(--color-footer);
  color: var(--color-footer-text);
}

.site-footer__inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 2rem;
  padding-block: 3rem;
}

.site-footer__nav ul {
  list-style: none;
  display: flex;
  gap: 1.5rem;
  margin: 0;
  padding: 0;
}

.site-footer a {
  color: var(--color-footer-text);
  font-size: 0.9rem;
}

.site-footer__logo img {
  width: 220px;
  height: 220px;
  margin-inline: auto;
}

.site-footer__contact {
  text-align: right;
}

.site-footer__contact a {
  font-family: var(--font-heading);
  font-size: 1.15rem;
}

.site-footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-block: 1.25rem;
  font-size: 0.85rem;
  text-align: center;
}

.site-footer__bottom p {
  margin: 0;
}

@media (max-width: 800px) {
  .site-footer__inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .site-footer__nav ul {
    justify-content: center;
  }

  .site-footer__contact {
    text-align: center;
  }
}

/* The 150ms header shrink is minor functional motion and stays on; only smooth scrolling is disabled here. */
/* ---------- Desktop "ribbon" header ----------
   Above the mobile breakpoint the banner runs to the very top of the page and the header
   becomes a 60px band laid over it, 60px down, with the 120px logo straddling the band like
   a bow. On scroll the band slides up to the top edge and becomes the compact bar. */
@media (min-width: 721px) {
  :root {
    --ribbon-band: 80px;
    --ribbon-offset: 40px;
  }

  body {
    padding-top: 0; /* the banner sits behind the band, so nothing is reserved */
  }

  .site-header {
    top: var(--ribbon-offset);
    height: var(--ribbon-band);
    background: rgba(250, 246, 240, 0.96);
    box-shadow: 0 1px 0 var(--color-border-warm), 0 8px 24px rgba(50, 57, 92, 0.12);
    transition: height 0.15s linear, top 0.15s linear;
  }

  .site-header.is-scrolled {
    top: 0;
    height: var(--header-height-compact);
    box-shadow: 0 1px 0 var(--color-border-warm);
  }

  /* Translucent navy strip above the ribbon that travels with it; once the bar docks
     at the top it collapses into a solid 5px navy border along the header's top edge */
  .site-header {
    isolation: isolate;
  }

  .site-header::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: calc(var(--ribbon-offset) * -1);
    height: var(--ribbon-offset);
    background: rgba(50, 57, 92, 0.55);
    pointer-events: none;
    z-index: -1;
  }

  /* docked: the strip disappears */
  .site-header.is-scrolled::before {
    display: none;
  }

  /* logo overhangs the band above and below, with a cream ring so it reads against the photo */
  .site-header__brand img {
    width: 120px;
    height: 120px;
    box-sizing: border-box;
    margin-block: calc((var(--ribbon-band) - 120px) / 2);
    transition: width 0.15s linear, height 0.15s linear, margin 0.15s linear, border-width 0.15s linear;
  }

  .site-header.is-scrolled .site-header__brand img {
    width: 56px;
    height: 56px;
    margin-block: 0;
  }

  /* wordmark sized for the 80px band */
  .site-header__wordmark-name {
    font-size: 1.5rem;
  }

  .site-header__wordmark-office {
    margin-top: 0.15rem;
  }

  /* subpage banners: taller so the title has room below the band */
  .page-header {
    min-height: clamp(420px, 52vh, 560px);
  }

  .page-header__content {
    padding-top: calc(var(--ribbon-offset) + var(--ribbon-band) + 2.5rem);
    padding-bottom: clamp(2.5rem, 5vw, 4rem);
  }
}

/* Very narrow phones (320–400px): smaller logo and name so the wordmark clears the menu button */
@media (max-width: 400px) {
  .site-header__brand {
    gap: 0.6rem;
  }

  .site-header__brand img {
    width: 72px;
    height: 72px;
  }

  .site-header__wordmark-name {
    font-size: 1.05rem;
  }

  .site-header__wordmark-office {
    font-size: 0.62rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
