.hero-content {
  position: relative;
  z-index: 2;
  align-items: center;
  justify-items: center;
}

.hero {
  --hero-parallax: 0px;
  position: relative;
  z-index: 2;
  isolation: isolate;
  min-height: 85vh;
  min-height: 85svh;
  overflow: visible;
  background: none;
}

.hero-background {
  position: absolute;
  z-index: 0;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.hero-background::before,
.hero-background::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-background::before {
  z-index: 0;
  inset: 0;
  background: url("../images/hero-h.webp") center / cover no-repeat;
}

.hero-background::after {
  display: none;
}

.hero-waves {
  position: absolute;
  z-index: 1;
  right: 0;
  bottom: -1px;
  left: 0;
  display: block;
  width: 100%;
  height: clamp(100px, 12vw, 180px);
  pointer-events: none;
}

.hero-wave-accent {
  fill: var(--brand);
}

.hero-wave-surface {
  fill: var(--paper);
}

.hero-message {
  display: grid;
  gap: 14px;
  max-width: 760px;
  text-align: center;
}

.hero-message h1,
.hero-message p {
  color: #fff;
}

.hero-message .eyebrow,
.hero-message .hero-copy {
  margin: 0;
}

.hero h1 {
  max-width: 680px;
  font-size: clamp(2.35rem, 5.5vw, 4rem);
  font-weight: 650;
  line-height: 1.04;
  letter-spacing: -0.045em;
}

.hero-copy {
  max-width: 600px;
  font-size: clamp(1rem, 1.4vw, 1.15rem);
}

.search-box,
.hero-search {
  width: 100%;
  max-width: 1024px;
  justify-self: center;
}

@media (min-width: 700px) and (max-width: 979px) {
  .search-box {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .search-box .search-term,
  .search-box button {
    grid-column: 1 / -1;
  }
}

@media (min-width: 980px) {
  .hero-background::before {
    /* Reserve only the vertical travel, avoiding extra horizontal zoom. */
    inset: -24px 0 0;
    transform: translate3d(0, clamp(0px, var(--hero-parallax), 24px), 0);
    will-change: transform;
  }

  .hero-content {
    grid-template-columns: minmax(0, 1fr);
    gap: clamp(28px, 4vw, 48px);
  }

  .hero h1 {
    font-size: 3rem;
  }

  .search-box {
    justify-self: end;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: clamp(20px, 2vw, 30px);
  }

  .search-box .search-term,
  .search-box button {
    grid-column: 1 / -1;
  }

  .search-box button {
    width: 100%;
  }
}

@media (min-width: 980px) and (prefers-reduced-motion: reduce) {
  .hero-background::before {
    inset: 0;
    transform: none;
    will-change: auto;
  }
}

@media (max-width: 699px) {
  .hero-background::before {
    background-image: url("../images/hero-v.webp");
  }

  .hero h1 {
    font-size: clamp(2.25rem, 11vw, 3.15rem);
  }

  .search-box {
    grid-template-columns: 1fr;
  }

  .search-box .search-term,
  .search-box button {
    grid-column: auto;
  }
}
