/* Shared dimensions for subpage hero media, never for the home page. */
.about-page .about-hero,
.wages-page .wages-hero,
.about-page .hero,
.company-profile-page .brand-hero,
.voice-page .brand-hero,
.inquiry-page .inquiry-hero,
.work-page .work-hero,
.office-page .office-hero {
  width: 100vw;
  max-width: none;
  margin-inline: calc(50% - 50vw);
}

.about-page .about-hero__visual,
.wages-page .wages-hero__visual,
.about-page .hero__image-wrap,
.company-profile-page .brand-hero__visual,
.voice-page .brand-hero__visual,
.inquiry-page .inquiry-hero__visual {
  box-sizing: border-box;
  width: 100%;
  height: 60vh;
  min-height: 0;
  max-height: none;
}

.wages-page .wages-hero__visual > img { min-height: 0; }

.work-page .work-hero,
.office-page .office-hero {
  box-sizing: border-box;
  height: 60vh;
  min-height: 0;
}

.office-page .office-hero__copy,
.office-page .office-hero__media { min-height: 0; }

.office-page .office-hero__media img { height: 100%; }

.hero-marquee {
  --hero-marquee-gap: 32px;
  box-sizing: border-box;
  width: 100vw;
  height: 52px;
  margin-inline: calc(50% - 50vw);
  overflow: hidden;
  background: #55b0b1;
}

.about-page .hero > .hero-marquee { margin-bottom: 48px; }
.about-page .hero > .quote-card { margin-top: 0; }

.hero-marquee__track {
  display: flex;
  width: max-content;
  height: 100%;
  animation: hero-marquee-scroll 32s linear infinite;
}

.hero-marquee__group {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: var(--hero-marquee-gap);
  /* Include the final gap in each repeated group's width, including the seam. */
  padding-inline-end: var(--hero-marquee-gap);
  height: 100%;
}

.hero-marquee__group img {
  display: block;
  flex: 0 0 auto;
  width: 130px;
  height: auto;
}

@keyframes hero-marquee-scroll {
  to { transform: translateX(-50%); }
}

@media (max-width: 900px) {
  .office-page .office-hero {
    position: relative;
    display: block;
    overflow: hidden;
    isolation: isolate;
  }

  .office-page .office-hero__media {
    position: absolute;
    z-index: -1;
    inset: 0;
  }

  .office-page .office-hero__media img { width: 100%; height: 100%; object-fit: cover; }

  .office-page .office-hero__copy {
    box-sizing: border-box;
    width: min(70%, 560px);
    height: 100%;
    margin: 0;
    padding: 24px clamp(22px, 5vw, 44px);
    background: linear-gradient(90deg, #fffdf9 0%, rgb(255 253 249 / 94%) 78%, transparent 100%);
  }
}

@media (max-width: 600px) {
  .hero-marquee { --hero-marquee-gap: 22px; height: 34px; }
  .hero-marquee__group img { width: 92px; }
  .office-page .office-hero {
    display: grid;
    width: 100%;
    height: auto;
    grid-template-rows: auto clamp(210px, 60vw, 260px);
    margin-inline: 0;
  }

  .office-page .office-hero__copy {
    box-sizing: border-box;
    width: 100%;
    height: auto;
    grid-row: 1;
    margin: 0;
    padding: 35px 24px 38px;
    background: #fffdf9;
  }

  .office-page .office-hero__media {
    position: static;
    z-index: auto;
    grid-row: 2;
    min-height: 0;
  }

  .office-page .office-hero__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  .office-page .office-hero__eyebrow { margin-bottom: 12px; }
  .office-page .office-hero h1 { font-size: clamp(32px, 9vw, 40px); }
  .office-page .office-hero__lead { margin-top: 16px; font-size: 14px; line-height: 1.75; }
}

@media (max-width: 767px) {
  .about-page .hero > .hero-marquee { margin-bottom: 32px; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-marquee__track { animation: none; }
}
