/* Full-bleed photo strip over a textured lavender board (shared asset with
   the hero section), centered heading and CTA below. */

.team {
  display: flex;
  flex-direction: column;
  gap: var(--space-60);
  padding-bottom: var(--space-60);
  background-color: var(--off-white);
  background-image: url("../../img/hero-texture.jpg");
  background-image: image-set(
    url("../../img/hero-texture.avif") type("image/avif"),
    url("../../img/hero-texture.webp") type("image/webp"),
    url("../../img/hero-texture.jpg") type("image/jpeg")
  );
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.team__strip {
  display: flex;
  width: 100%;
  max-width: var(--board-max);
  margin-inline: auto;
  background-color: var(--pure-white);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.team__photo {
  display: block;
  flex: 0 0 auto;
  width: 200px;
  height: auto;
  aspect-ratio: 288 / 418;
  object-fit: cover;
  scroll-snap-align: start;
}

.team__photo--fit {
  object-fit: contain;
}

.team__lockup {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-60);
  text-align: center;
}

.team__heading {
  max-width: 1280px;
  font-size: clamp(1.5rem, 1.1127rem + 1.5414vw, 2.5rem);
  line-height: 1.2;
  font-style: italic;
  color: var(--dozen-blue);
}

.team__cta {
  display: inline-flex;
  align-self: stretch;
  align-items: center;
  justify-content: center;
  padding: var(--space-20);
  border-radius: 60px;
  background: var(--gradient-blue-deep);
  font-family: var(--font-body);
  font-weight: var(--weight-heading);
  font-size: 1.25rem;
  line-height: 1;
  letter-spacing: -0.7px;
  color: var(--pure-white);
  text-decoration: none;
  transition:
    filter 0.2s ease,
    transform 0.2s ease;
}

.team__cta:hover,
.team__cta:focus-visible {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

@media (min-width: 1024px) {
  .team__strip {
    overflow-x: visible;
  }

  /* Five equal columns keeping the 288:418 tile ratio; at the strip's
     1440 max each tile is exactly 288x418. min-width: 0 lets the tiles
     compress below their intrinsic width instead of overflowing. */
  .team__photo {
    flex: 1 1 20%;
    min-width: 0;
    width: auto;
    height: auto;
  }

  .team__heading {
    line-height: var(--h3-leading);
    display: flex;
    align-items: center;
    justify-content: center;
    min-block-size: 4rem;
  }

  .team__cta {
    align-self: center;
    padding: var(--space-20) var(--space-40);
  }
}
