/* ==========================================================================
   PAGE: CONTACT
   ========================================================================== */

/* --------------------------------------------------------------------------
   BANNER  →  <ContactHero />

   Not the shared .page-hero. Everywhere else the banner sells something; on a
   contact page the banner IS the content, so the illustration slot holds the
   route between the two offices and the three ways to reach them.
   -------------------------------------------------------------------------- */
.contact-hero {
  position: relative;
  padding-block: clamp(3.5rem, 2rem + 5vw, 5.07rem);   /* matches .page-hero */
  background-color: #f7f8fa;
  background-image: url("../../img/hero-bg.png");
  background-size: cover;
  background-position: center;
  border-bottom: 1px solid var(--c-border);
  overflow: hidden;
  isolation: isolate;
}

/* Washes the photographic pattern back so the copy stays readable — the same
   treatment .page-hero uses, mirrored because the panel sits on the right. */
.contact-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.95) 0%,
      rgba(255, 255, 255, 0.86) 45%,
      rgba(255, 255, 255, 0.72) 100%
    ),
    radial-gradient(110% 130% at 8% 0%, var(--c-tint-indigo) 0%, rgba(244, 245, 255, 0) 62%);
}

.contact-hero__pill {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin: 1.25rem 0 1rem;
  padding: 0.35rem 0.9rem;
  border-radius: var(--r-pill);
  background: var(--c-white);
  border: 1px solid var(--c-border-mid);
  box-shadow: var(--sh-card);
  font-family: var(--font-body);
  font-size: var(--fs-2xs);
  font-weight: var(--fw-semibold);
  letter-spacing: 0.7px;
  text-transform: uppercase;
  color: var(--c-navy-900);
}

.contact-hero__ping {
  width: 8px;
  height: 8px;
  border-radius: var(--r-pill);
  background: #29b767;
  box-shadow: 0 0 0 0 rgba(41, 183, 103, 0.55);
  animation: contact-ping 2.4s var(--ease) infinite;
}

@keyframes contact-ping {
  70% { box-shadow: 0 0 0 9px rgba(41, 183, 103, 0); }
  100% { box-shadow: 0 0 0 0 rgba(41, 183, 103, 0); }
}

.contact-hero__title {
  font-family: var(--font-body);
  font-size: var(--fs-display);
  font-weight: var(--fw-bold);
  line-height: 1.15;
  letter-spacing: -0.44px;
  color: var(--c-ink-900);
  margin: 0 0 1rem;
  max-width: 20ch;
}

.contact-hero__title .text-brand {
  display: block;
  color: var(--c-primary);
}

/* Body size, matching .page-hero__lead and .overview__text. */
.contact-hero__lead {
  font-family: var(--font-body);
  font-size: var(--fs-body);
  font-weight: var(--fw-light);
  line-height: var(--lh-relaxed);
  color: var(--c-ink-850);
  max-width: 34rem;
  margin: 0 0 1.75rem;
}

/* ---- the route panel ------------------------------------------------ */
.route {
  padding: clamp(1.25rem, 1rem + 1.2vw, 1.48rem);
  border-radius: var(--r-lg);
  background: var(--c-white);
  border: 1px solid var(--c-border-mid);
  box-shadow: var(--sh-card);
}

.route__art {
  display: block;
  width: 100%;
  height: auto;
}

.route__city {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1.4px;
  fill: var(--c-navy-900);
}

.route__meta {
  font-family: var(--font-body);
  font-size: 10.5px;
  font-weight: 300;
  fill: var(--c-ink-400);
}

/* The dashes travel along the arc; the dot rides it. Both stop for anyone
   who has asked for reduced motion. */
.route__path {
  animation: route-dash 2.4s linear infinite;
}

@keyframes route-dash {
  to { stroke-dashoffset: -32; }
}

@media (prefers-reduced-motion: reduce) {
  .route__path { animation: none; }
  .route__pulse { display: none; }
  .contact-hero__ping { animation: none; }
}

/* Stacked, not a three-column strip: a phone number is long enough that three
   across wrapped mid-number at every width between 1200 and 1500. */
.route__actions {
  display: grid;
  gap: 0.55rem;
  margin-top: 1.1rem;
  padding-top: 1.1rem;
  border-top: 1px solid var(--c-border);
}

.route__action {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 0.9rem;
  border: 1px solid var(--c-border-mid);
  border-radius: var(--r-md);
  background: var(--c-white);
  text-align: left;
  transition: border-color var(--t-base), box-shadow var(--t-base), transform var(--t-base);
}

.route__action:hover {
  border-color: transparent;
  box-shadow: var(--sh-card-hover);
  transform: translateX(3px);
}

.route__icon {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: var(--r-sm);
  background: var(--c-tint-indigo);
  color: var(--c-primary);
}

.route__icon svg {
  width: 17px;
  height: 17px;
}

.route__label {
  display: block;
  font-family: var(--font-body);
  font-size: var(--fs-2xs);
  font-weight: var(--fw-semibold);
  letter-spacing: 0.7px;
  text-transform: uppercase;
  color: var(--c-ink-400);
}

.route__value {
  display: block;
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--c-navy-900);
}

@media (max-width: 575.98px) {
  .contact-hero__title {
    max-width: none;
  }
}

/* --------------------------------------------------------------------------
   REGION SWITCH  →  <RegionSwitch />
   The domain decides the default; this lets a visitor override it.
   -------------------------------------------------------------------------- */
.region-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding-block: 1.1rem;
  border-bottom: 1px solid var(--c-border);
}

.region-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.3rem;
  background: var(--c-surface-alt);
  border: 1px solid var(--c-border-mid);
  border-radius: var(--r-pill);
}

.region-switch__btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 1rem;
  border-radius: var(--r-pill);
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--c-ink-500);
  transition: background var(--t-base), color var(--t-base), box-shadow var(--t-base);
}

.region-switch__btn.is-active {
  background: var(--c-white);
  color: var(--c-navy-900);
  box-shadow: var(--sh-card);
}

.region-switch__flag {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: var(--fw-bold);
  letter-spacing: 0.6px;
  color: var(--c-primary);
}

.region-note {
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  color: var(--c-ink-400);
}

/* --------------------------------------------------------------------------
   OFFICE CARD  →  <OfficeCard />
   -------------------------------------------------------------------------- */
.office-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.office {
  position: relative;
  flex: 1 1 24rem;
  display: flex;
  flex-direction: column;
  padding: clamp(1.6rem, 1.2rem + 1.4vw, 1.87rem);
  background: var(--c-white);
  border: 1px solid var(--c-border-mid);
  border-radius: var(--r-lg);
  transition: box-shadow var(--t-base), border-color var(--t-base);
}

.office:hover {
  border-color: transparent;
  box-shadow: var(--sh-card-hover);
}

/* The office leading for this domain gets the emphasis. */
.office.is-lead {
  background:
    radial-gradient(120% 110% at 0% 0%, var(--c-tint-indigo) 0%, rgba(244, 245, 255, 0) 55%),
    var(--c-white);
  border-color: transparent;
  box-shadow: 0 14px 40px rgba(11, 28, 45, 0.10);
  outline: 2px solid var(--c-primary);
  outline-offset: -2px;
}

.office__badge {
  position: absolute;
  top: -11px;
  left: clamp(1.6rem, 1.2rem + 1.4vw, 2.4rem);
  display: none;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.75rem;
  border-radius: var(--r-pill);
  background: var(--c-primary);
  color: var(--c-white);
  font-family: var(--font-body);
  font-size: 0.68rem;
  font-weight: var(--fw-bold);
  letter-spacing: 0.7px;
  text-transform: uppercase;
}

.office.is-lead .office__badge {
  display: inline-flex;
}

.office__head {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
  margin-bottom: 1.25rem;
}

.office__flag {
  width: 52px;
  height: 52px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: var(--r-md);
  background: var(--c-tint-indigo);
  color: var(--c-primary);
}

.office__flag svg {
  width: 24px;
  height: 24px;
}

.office__region {
  display: block;
  font-family: var(--font-body);
  font-size: var(--fs-2xs);
  font-weight: var(--fw-semibold);
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--c-primary);
  margin-bottom: 0.2rem;
}

.office__city {
  font-family: var(--font-heading);
  font-size: var(--fs-h2-sm);
  font-weight: var(--fw-semibold);
  color: var(--c-navy-900);
  margin: 0;
}

.office__entity {
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--c-ink-800);
  margin-bottom: 0.3rem;
}

.office__role {
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: var(--fw-light);
  line-height: var(--lh-relaxed);
  color: var(--c-ink-500);
  margin-bottom: 1.35rem;
}

.office__rows {
  display: grid;
  gap: 0;
  margin-bottom: 1.4rem;
}

.office__row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 0 0.85rem;
  align-items: start;
  padding-block: 0.85rem;
  border-top: 1px solid var(--c-border);
}

.office__icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: var(--r-sm);
  background: var(--c-surface-alt);
  color: var(--c-primary);
}

.office__icon svg {
  width: 16px;
  height: 16px;
}

.office__label {
  display: block;
  font-family: var(--font-body);
  font-size: var(--fs-2xs);
  font-weight: var(--fw-medium);
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--c-ink-400);
  margin-bottom: 0.15rem;
}

.office__value {
  font-family: var(--font-body);
  font-size: var(--fs-body);
  font-weight: var(--fw-medium);
  line-height: 1.55;
  color: var(--c-navy-900);
}

.office__value a {
  color: inherit;
}

.office__value a:hover {
  color: var(--c-primary);
}

/* A field the client still has to supply — visibly incomplete on purpose. */
.office__todo {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: var(--fw-light);
  font-style: italic;
  color: var(--c-ink-400);
}

.office__todo::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: var(--r-pill);
  background: var(--c-star);
}

.office__foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
}

/* --------------------------------------------------------------------------
   MAP EMBED  →  <MapPanel />
   -------------------------------------------------------------------------- */
.map-panel {
  position: relative;
  border: 1px solid var(--c-border-mid);
  border-radius: var(--r-lg);
  overflow: hidden;
  background:
    repeating-linear-gradient(0deg, var(--c-tint-indigo) 0 1px, transparent 1px 42px),
    repeating-linear-gradient(90deg, var(--c-tint-indigo) 0 1px, transparent 1px 42px),
    var(--c-surface-alt);
  min-height: clamp(260px, 26vw, 380px);
  display: grid;
  place-items: center;
  text-align: center;
  padding: 2rem;
}

.map-panel__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 1rem;
  display: grid;
  place-items: center;
  border-radius: var(--r-pill);
  background: var(--c-white);
  color: var(--c-primary);
  box-shadow: var(--sh-card);
}

.map-panel__icon svg {
  width: 24px;
  height: 24px;
}

.map-panel__title {
  font-family: var(--font-heading);
  font-size: var(--fs-h4);
  font-weight: var(--fw-semibold);
  color: var(--c-navy-900);
  margin-bottom: 0.4rem;
}

.map-panel__text {
  max-width: 30rem;
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: var(--fw-light);
  line-height: var(--lh-relaxed);
  color: var(--c-ink-500);
  margin: 0 auto 1.2rem;
}

/* Live embed variant. Below md the map and the address card stack, so the
   copy never sits on top of the tiles at the width where that hurts most;
   from md up the card floats over the left of the map. */
.map-panel--live {
  display: block;
  min-height: 0;
  padding: 0;
  text-align: left;
  background: var(--c-surface-alt);
}

.map-panel__frame {
  display: block;
  width: 100%;
  height: clamp(260px, 30vw, 400px);
  border: 0;
  /* Google's tiles run a little warm against the page palette. */
  filter: saturate(0.92);
}

.map-panel__card {
  padding: 1.5rem;
  background: var(--c-white);
  border-top: 1px solid var(--c-border-mid);
}

.map-panel__eyebrow {
  display: block;
  font-family: var(--font-body);
  font-size: var(--fs-2xs);
  font-weight: var(--fw-semibold);
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--c-primary);
  margin-bottom: 0.2rem;
}

.map-panel--live .map-panel__icon {
  width: 44px;
  height: 44px;
  margin: 0 0 0.9rem;
  border: 1px solid var(--c-border-mid);
}

.map-panel--live .map-panel__icon svg {
  width: 20px;
  height: 20px;
}

.map-panel--live .map-panel__text {
  max-width: none;
  margin: 0 0 1.2rem;
}

@media (min-width: 768px) {
  .map-panel--live {
    display: grid;
    place-items: center start;
  }

  .map-panel__frame,
  .map-panel__card {
    grid-area: 1 / 1;
  }

  .map-panel__frame {
    height: clamp(340px, 34vw, 460px);
  }

  .map-panel__card {
    width: min(23rem, 46%);
    margin: 1.4rem;
    border: 1px solid var(--c-border-mid);
    border-radius: var(--r-md);
    box-shadow: var(--sh-card-hover);
  }
}
