.hd-hero-scroll {
  position: relative;
  margin: 0;
  min-height: calc(100svh + 28vh);
}

.hd-hero-scroll__sticky {
  position: sticky;
  top: var(--hd-topbar-height);
  z-index: 1;
  min-height: calc(100svh - var(--hd-topbar-height));
  overflow: hidden;
  display: grid;
  align-items: end;
}

.hd-hero-scroll__spacer {
  height: 28vh;
  pointer-events: none;
}

.hd-hero-scroll__media {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.hd-hero-scroll__layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform-origin: 50% 42%;
  will-change: transform, opacity;
}

.hd-hero-scroll__layer--wide {
  opacity: 1;
  transform: scale(1.12);
  transform-origin: 50% 42%;
}

.hd-hero-scroll__layer--entrance {
  opacity: 0;
  transform: scale(1.06);
}

.hd-hero-scroll__overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(34, 21, 17, 0.35) 0%, rgba(34, 21, 17, 0.55) 45%, rgba(34, 21, 17, 0.92) 100%),
    radial-gradient(ellipse at 50% 20%, transparent 0%, rgba(22, 12, 7, 0.45) 70%);
  pointer-events: none;
}

.hd-hero-scroll__content {
  position: relative;
  z-index: 2;
  width: min(var(--hd-page-width), calc(100% - var(--hd-space-md) * 2));
  max-height: calc(100svh - var(--hd-topbar-height) - var(--hd-space-sm));
  margin: 0 auto;
  padding: var(--hd-space-md) var(--hd-space-md) var(--hd-space-lg);
  overflow: auto;
  overscroll-behavior: contain;
}

.hd-hero-scroll__eyebrow {
  margin: 0 0 var(--hd-space-xs);
  font-family: var(--hd-font-family-label);
  font-size: var(--hd-font-size-label);
  letter-spacing: var(--hd-letter-spacing-label);
  text-transform: uppercase;
  color: var(--hd-color-primary);
}

.hd-hero-scroll__title {
  margin: 0 0 var(--hd-space-sm);
  font-size: clamp(32px, 4vw, 56px);
  line-height: var(--hd-line-height-tight);
  color: var(--hd-color-text-primary);
}

.hd-hero-scroll__title-sub {
  display: block;
  margin-top: 0.35em;
  font-size: clamp(16px, 2vw, 24px);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--hd-color-text-secondary);
}

.hd-hero-scroll__text {
  margin: 0 0 var(--hd-space-md);
  max-width: 42rem;
  font-size: var(--hd-font-size-body);
  line-height: var(--hd-line-height-body);
  color: var(--hd-color-text-secondary);
}

.hd-hero-scroll__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--hd-space-sm);
}

@media (max-width: 768px) {
  :root {
    --hd-topbar-height: 96px;
  }

  .hd-hero-scroll {
    min-height: calc(100svh + 18vh);
  }

  .hd-hero-scroll__spacer {
    height: 18vh;
  }

  .hd-hero-scroll__title {
    font-size: clamp(28px, 8vw, 40px);
  }

  .hd-hero-scroll__title-sub {
    font-size: clamp(15px, 4vw, 20px);
  }

  .hd-hero-scroll__text {
    font-size: clamp(14px, 3.6vw, 16px);
  }
}

@media (max-height: 760px) {
  .hd-hero-scroll__content {
    padding-top: var(--hd-space-sm);
    padding-bottom: var(--hd-space-md);
  }

  .hd-hero-scroll__title {
    font-size: clamp(26px, 4vw, 40px);
    margin-bottom: var(--hd-space-xs);
  }

  .hd-hero-scroll__text {
    margin-bottom: var(--hd-space-sm);
    font-size: 14px;
  }
}

body.admin-bar .hd-hero-scroll__sticky {
  top: calc(32px + var(--hd-topbar-height));
  min-height: calc(100svh - var(--hd-topbar-height) - 32px);
}

@media screen and (max-width: 782px) {
  body.admin-bar .hd-hero-scroll__sticky {
    top: calc(46px + var(--hd-topbar-height));
    min-height: calc(100svh - var(--hd-topbar-height) - 46px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hd-hero-scroll__sticky {
    position: relative;
    min-height: 85vh;
  }

  .hd-hero-scroll__spacer {
    display: none;
  }

  .hd-hero-scroll__layer--entrance {
    display: none;
  }

  .hd-hero-scroll__layer--wide {
    opacity: 1 !important;
    transform: none !important;
  }
}
