/* Shared inner-page pieces: the page hero and the section label */

/* Section label: a short turquoise rule before small caps */
.label {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin-bottom: clamp(20px, 2.4vw, 32px);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--white);
}

.label::before {
  content: "";
  width: 40px;
  height: 2px;
  background: var(--turquoise);
}

/* Forces a line break where the copy calls for one; reads as a space when styles are off */
.row {
  display: block;
}

/* A gradient row should span only its words, so the colour sweep reaches the gold end */
.grad.row {
  width: fit-content;
}

.grad {
  font-style: normal;
  background: linear-gradient(90deg, var(--turquoise) 30%, var(--yellow));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* "Back to" pill above the hero title */
.back-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: clamp(20px, 2.4vw, 32px);
  padding: 10px 22px;
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: 999px;
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
  transition:
    background-color 0.3s ease,
    color 0.3s ease;
}

.back-pill svg {
  transition: transform 0.3s ease;
}

.back-pill:hover {
  background: var(--white);
  color: var(--surface-deep);
}

.back-pill:hover svg {
  transform: translateX(-4px);
}

.js .page-hero .back-pill {
  transition:
    transform 1.4s var(--ease-out),
    opacity 1.4s var(--ease-out),
    background-color 0.3s ease,
    color 0.3s ease;
}

.js:not(.is-ready) .page-hero .back-pill {
  opacity: 0;
  transform: translateY(16px);
}

/* Page hero: headline left, lede and actions right, over the pointer glow */
.page-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  min-height: min(92svh, 920px);
  padding: calc(var(--header-h) + 64px) var(--edge) clamp(56px, 7vw, 104px);
  background: var(--surface);
}

.page-hero .dots--right {
  top: 0;
  bottom: auto;
  translate: 48% -30%;
}

/* Photo variant (OHO's About hero): darkened image, title anchored bottom-left */
.page-hero--image {
  min-height: min(80svh, 780px);
}

.page-hero__img {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.65) contrast(1.08) brightness(0.72);
  transition: transform 3s var(--ease-out);
}

.js:not(.is-ready) .page-hero__img {
  transform: scale(1.1);
}

.page-hero--image::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(0deg, rgba(36, 37, 40, 1) 0%, rgba(36, 37, 40, 0.7) 32%, rgba(36, 37, 40, 0.2) 65%, rgba(36, 37, 40, 0.6) 100%),
    linear-gradient(90deg, rgba(36, 37, 40, 0.55), rgba(36, 37, 40, 0) 60%);
}

.page-hero__inner {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--gutter);
  align-items: end;
  width: 100%;
}

.page-hero__main {
  grid-column: 1 / span 8;
}

.page-hero__title {
  font-size: clamp(3rem, 1rem + 6.4vw, 8.5rem);
  font-weight: 600;
  line-height: 0.92;
  letter-spacing: -0.05em;
}

/* Each line is a mask the words rise into, like the home hero */
.page-hero__title .line {
  display: block;
  overflow: hidden;
  padding-bottom: 0.14em;
  margin-bottom: -0.14em;
}

.page-hero__title .line > span {
  display: inline-block;
}

.page-hero__aside {
  grid-column: 9 / span 4;
  display: grid;
  gap: 28px;
  padding-bottom: 0.5em;
}

.page-hero__lede {
  font-size: clamp(17px, 1.3vw, 20px);
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.88);
}

.page-hero__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.page-hero__tags li {
  padding: 6px 12px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 500;
}

/* Entrance, driven by .is-ready on <html> */
.js .page-hero .label,
.js .page-hero__title .line > span,
.js .page-hero__aside > * {
  transition:
    transform 1.4s var(--ease-out),
    opacity 1.4s var(--ease-out);
  transition-delay: calc(var(--d, 0) * 120ms + 150ms);
}

.js:not(.is-ready) .page-hero__title .line > span {
  transform: translateY(110%);
}

.js:not(.is-ready) .page-hero .label,
.js:not(.is-ready) .page-hero__aside > * {
  opacity: 0;
  transform: translateY(16px);
}

@media (max-width: 960px) {
  .page-hero {
    min-height: 0;
    padding-top: calc(var(--header-h) + 88px);
  }

  .page-hero__main,
  .page-hero__aside {
    grid-column: 1 / -1;
  }

  .page-hero__aside {
    max-width: 62ch;
    margin-top: 36px;
  }

  .page-hero__title {
    font-size: clamp(2.6rem, 11vw, 6.5rem);
  }
}
