.hero-film {
  position: relative;
  height: 100vh;
  height: 100svh;
  min-height: 620px;
  overflow: hidden;
  background-color: var(--night);
  color: var(--offwhite);
}

/* ============================================ */
/* FILM */
/* ============================================ */

.hero-film__media {
  position: absolute;
  inset: 0;
  margin: 0;
  transition: transform 2400ms cubic-bezier(0.16, 1, 0.3, 1);
}

.is-intro .hero-film__media {
  transform: scale(1.22);
}

.is-intro-flying .hero-film__media {
  transform: scale(1);
}

/* Shading holds the statement on the brightest frames (measured at 3:1 or better for the headline):
   on phones the text fills the lower two-thirds, so the fade climbs higher; wider screens gather it at the lower left */
.hero-film__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(to top, rgba(10, 26, 18, 0.94) 0%, rgba(10, 26, 18, 0.84) 45%, rgba(10, 26, 18, 0.62) 64%, rgba(10, 26, 18, 0.15) 80%, rgba(10, 26, 18, 0) 90%), linear-gradient(to bottom, rgba(10, 26, 18, 0.5) 0%, rgba(10, 26, 18, 0) 22%);
}

/* Tablet Portrait Up - Min 600px */
@media (min-width: 600px) {
  .hero-film__media::after {
    background-image: radial-gradient(ellipse 85% 85% at 18% 88%, rgba(10, 26, 18, 0.9) 0%, rgba(10, 26, 18, 0.76) 50%, rgba(10, 26, 18, 0) 82%), linear-gradient(to top, rgba(10, 26, 18, 0.92) 0%, rgba(10, 26, 18, 0.72) 40%, rgba(10, 26, 18, 0.2) 70%, rgba(10, 26, 18, 0) 84%), linear-gradient(to bottom, rgba(10, 26, 18, 0.5) 0%, rgba(10, 26, 18, 0) 22%);
  }
}

.hero-film__video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ============================================ */
/* STATEMENT */
/* ============================================ */

.hero-film__wrapper {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  padding-left: 20px;
  padding-right: 20px;
  padding-bottom: 5.5rem;
}

/* Tablet Portrait Up - Min 600px */
@media (min-width: 600px) {
  .hero-film__wrapper {
    padding-left: 32px;
    padding-right: 32px;
  }
}

/* Desktop Up - Min 1200px */
@media (min-width: 1200px) {
  .hero-film__wrapper {
    gap: 2.5rem;
    padding-left: 40px;
    padding-right: 40px;
    padding-bottom: 6rem;
  }
}

.hero-film__title {
  margin-top: 0;
  margin-bottom: 0;
  font-size: 52px;
  font-weight: 300;
  line-height: 0.94;
  letter-spacing: -0.045em;
  text-wrap: balance;
}

/* Tablet Portrait Up - Min 600px */
@media (min-width: 600px) {
  .hero-film__title {
    font-size: 76px;
  }
}

/* Tablet Landscape Up - Min 900px */
@media (min-width: 900px) {
  .hero-film__title {
    font-size: 96px;
  }
}

/* Desktop Up - Min 1200px */
@media (min-width: 1200px) {
  .hero-film__title {
    font-size: 140px;
  }
}

/* Big Desktop Up - Min 1800px */
@media (min-width: 1800px) {
  .hero-film__title {
    font-size: 196px;
  }
}

.hero-film__line {
  display: block;
  overflow: hidden;
  padding-bottom: 0.1em;
  margin-bottom: -0.1em;
}

.hero-film__line > span {
  display: block;
  animation: hero-film-line-in 1500ms cubic-bezier(0.16, 1, 0.3, 1) both;
  animation-delay: calc(var(--line) * 110ms + 250ms);
}

.is-intro .hero-film__line > span {
  animation-name: none;
  transform: translateY(110%);
}

.is-intro-flying .hero-film__line > span {
  animation-name: hero-film-line-in;
  animation-delay: calc(var(--line) * 110ms + 650ms);
}

@keyframes hero-film-line-in {
  from {
    transform: translateY(110%);
  }
  to {
    transform: translateY(0);
  }
}

/* ============================================ */
/* DESCRIPTION AND ACTIONS */
/* ============================================ */

.hero-film__footer {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  animation: hero-film-fade-in 1400ms cubic-bezier(0.16, 1, 0.3, 1) 700ms both;
}

/* Tablet Landscape Up - Min 900px */
@media (min-width: 900px) {
  .hero-film__footer {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-end;
    gap: 3rem;
  }
}

.is-intro .hero-film__footer {
  animation-name: none;
  opacity: 0;
}

.is-intro-flying .hero-film__footer {
  animation-name: hero-film-fade-in;
  animation-delay: 1150ms;
}

@keyframes hero-film-fade-in {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-film__description {
  max-width: 500px;
  margin-top: 0;
  margin-bottom: 0;
  color: rgba(244, 242, 236, 0.86);
  font-size: 17px;
  line-height: 1.55;
}

/* Desktop Up - Min 1200px */
@media (min-width: 1200px) {
  .hero-film__description {
    font-size: 18px;
  }
}

.hero-film__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* ============================================ */
/* FILM CONTROLS */
/* ============================================ */

.hero-film__toggle {
  position: absolute;
  right: 20px;
  bottom: 1.75rem;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  padding-left: 0;
  padding-right: 0;
  border: 0;
  background-color: transparent;
  color: rgba(244, 242, 236, 0.7);
  font-family: var(--body-font-family);
  font-size: 13px;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: color 300ms ease;
}

/* Tablet Portrait Up - Min 600px */
@media (min-width: 600px) {
  .hero-film__toggle {
    right: 32px;
  }
}

/* Desktop Up - Min 1200px */
@media (min-width: 1200px) {
  .hero-film__toggle {
    right: 40px;
    bottom: 2rem;
  }
}

.hero-film__toggle:hover {
  color: var(--offwhite);
}

.hero-film__toggle-icon {
  position: relative;
  width: 10px;
  height: 10px;
  border-left: 3px solid currentColor;
  border-right: 3px solid currentColor;
}

.hero-film__toggle.is-paused .hero-film__toggle-icon {
  width: 0;
  height: 0;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  border-left: 9px solid currentColor;
  border-right: 0;
}

.hero-film__caption {
  position: absolute;
  left: 20px;
  bottom: 1.75rem;
  margin-top: 0;
  margin-bottom: 0;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  color: rgba(244, 242, 236, 0.7);
  font-size: 13px;
  line-height: 1;
  letter-spacing: 0.02em;
}

/* Tablet Portrait Up - Min 600px */
@media (min-width: 600px) {
  .hero-film__caption {
    left: 32px;
  }
}

/* Desktop Up - Min 1200px */
@media (min-width: 1200px) {
  .hero-film__caption {
    left: 40px;
    bottom: 2rem;
  }
}

.is-intro .hero-film__toggle,
.is-intro .hero-film__caption {
  opacity: 0;
}

.is-intro-flying .hero-film__toggle,
.is-intro-flying .hero-film__caption {
  opacity: 1;
  transition: opacity 900ms ease 1400ms;
}

/* Reduced motion shows the opening at rest */
@media (prefers-reduced-motion: reduce) {
  .hero-film__line > span,
  .hero-film__footer {
    animation: none;
  }
}
