:root {
  --motion-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

.site-header {
  position: fixed;
  z-index: 90;
  gap: clamp(20px, 4vw, 64px);
  background: transparent;
  transition:
    padding 420ms var(--motion-ease),
    background-color 420ms var(--motion-ease),
    box-shadow 420ms var(--motion-ease),
    backdrop-filter 420ms var(--motion-ease);
}

.site-header .brand {
  flex: none;
  transition: width 420ms var(--motion-ease);
}

.header-nav {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: flex-end;
  gap: clamp(16px, 2.2vw, 34px);
}

.header-nav a {
  position: relative;
  flex: none;
  color: inherit;
  opacity: 0.62;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.17em;
  line-height: 1;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
  transition: opacity 180ms ease;
}

.header-nav a::after {
  position: absolute;
  right: 0;
  bottom: -8px;
  left: 0;
  height: 1px;
  background: currentColor;
  content: "";
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 180ms ease;
}

.header-nav a:hover,
.header-nav a:focus-visible,
.header-nav .header-link--title {
  opacity: 1;
}

.header-nav a:hover::after,
.header-nav a:focus-visible::after {
  transform: scaleX(1);
  transform-origin: left;
}

main section[id] {
  scroll-margin-top: 82px;
}

.site-header.is-scrolled {
  padding-top: 13px;
  padding-bottom: 13px;
  color: #fff;
  background: rgba(8, 8, 8, 0.96);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.12);
  mix-blend-mode: normal;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.site-header.is-scrolled .brand {
  width: clamp(78px, 7vw, 104px);
}

.motion-progress {
  position: fixed;
  z-index: 100;
  top: 0;
  right: 0;
  left: 0;
  height: 2px;
  background: var(--model-progress, #fff);
  mix-blend-mode: var(--model-progress-blend, difference);
  pointer-events: none;
  transform: scaleX(0);
  transform-origin: left center;
  will-change: transform;
}

html.motion-active body {
  overflow-x: clip;
}

html.motion-active .hero-copy > * {
  opacity: 0;
  transform: translate3d(0, 28px, 0);
  transition: opacity 900ms var(--motion-ease), transform 1100ms var(--motion-ease);
}

html.motion-active.motion-start .hero-copy > * {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

html.motion-active.motion-start .hero-copy > :nth-child(1) {
  transition-delay: 80ms;
}

html.motion-active.motion-start .hero-copy > :nth-child(2) {
  transition-delay: 160ms;
}

html.motion-active.motion-start .hero-copy > :nth-child(3) {
  transition-delay: 250ms;
}

html.motion-active.motion-start .hero-copy > :nth-child(4) {
  transition-delay: 340ms;
}

html.motion-active.motion-start .hero-copy > :nth-child(5) {
  transition-delay: 430ms;
}

html.motion-active [data-reveal] {
  opacity: 0;
  transform: translate3d(0, 64px, 0);
  transition:
    opacity 900ms var(--motion-ease) var(--reveal-delay, 0ms),
    transform 1100ms var(--motion-ease) var(--reveal-delay, 0ms);
  will-change: opacity, transform;
}

html.motion-active [data-reveal].is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

html.motion-active .editorial-card[data-reveal] {
  overflow: hidden;
}

html.motion-active .editorial-card[data-reveal] figcaption {
  background: var(--paper);
}

html.motion-active .editorial-card[data-reveal] img {
  transform: scale(1.075);
  transition: transform 1500ms var(--motion-ease) var(--reveal-delay, 0ms);
  will-change: transform;
}

html.motion-active .editorial-card[data-reveal].is-visible img {
  transform: scale(1);
}

html.motion-active .profile-list [data-reveal],
html.motion-active .experience-list [data-reveal] {
  transform: translate3d(34px, 0, 0);
}

html.motion-active .profile-list [data-reveal].is-visible,
html.motion-active .experience-list [data-reveal].is-visible {
  transform: translate3d(0, 0, 0);
}

@media (min-width: 821px) {
  html.motion-active .hero {
    min-height: 142svh;
    align-items: start;
  }

  html.motion-active .hero-copy,
  html.motion-active .hero-media {
    position: sticky;
    top: 0;
  }

  html.motion-active .hero-copy {
    transform: translate3d(0, var(--copy-shift, 0), 0);
    will-change: transform;
  }

  html.motion-active .hero-media img {
    transform: translate3d(0, var(--hero-shift, 0), 0) scale(var(--hero-scale, 1.08));
    transform-origin: center center;
    will-change: transform;
  }
}

@media (max-width: 820px) {
  .site-header {
    gap: 18px;
  }

  .site-header.is-scrolled {
    padding: 11px 20px;
  }

  .site-header.is-scrolled .brand {
    width: 78px;
  }

  .header-nav {
    max-width: calc(100vw - 118px);
    flex: 1 1 auto;
    justify-content: flex-start;
    gap: 18px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
  }

  .header-nav::-webkit-scrollbar {
    display: none;
  }

  .header-nav a {
    font-size: 9px;
    letter-spacing: 0.14em;
    scroll-snap-align: start;
  }

  main section[id] {
    scroll-margin-top: 72px;
  }

  html.motion-active [data-reveal] {
    transform: translate3d(0, 38px, 0);
  }

  html.motion-active [data-reveal].is-visible {
    transform: translate3d(0, 0, 0);
  }

  html.motion-active .editorial-card[data-reveal] {
    overflow: visible;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-header,
  .site-header .brand,
  .header-nav a,
  .header-nav a::after {
    transition: none;
  }

  .motion-progress {
    display: none;
  }
}
