body.apigraf-home .hero-slide-video {
  display: flex !important;
  align-items: flex-end !important;
  overflow: hidden;
  background: #101d35 !important;
}

body.apigraf-home .hero-slide-video-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  max-width: none;
  height: 100%;
  object-fit: cover;
  object-position: center;
  background: #101d35;
}

body.apigraf-home .hero-slide-video::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block !important;
  pointer-events: none;
  background:
    linear-gradient(180deg, rgba(8, 17, 34, 0.04) 0%, rgba(8, 17, 34, 0.16) 38%, rgba(8, 17, 34, 0.9) 100%),
    linear-gradient(90deg, rgba(8, 17, 34, 0.8) 0%, rgba(8, 17, 34, 0.28) 64%, rgba(8, 17, 34, 0.06) 100%);
}

body.apigraf-home .hero-slide-video .hero-content {
  position: relative !important;
  z-index: 2 !important;
  width: min(calc(100% - 64px), 920px) !important;
  max-width: 920px !important;
}

/* The institutional name is long: give it room to breathe without letting it
   dominate the whole hero or collide with the slider controls. */
body.apigraf-home .hero-slide-video .hero-content h1,
body.apigraf-home .hero-slide-video .hero-content h2 {
  max-width: 28ch !important;
  font-size: clamp(2.35rem, 4.2vw, 4.5rem) !important;
  line-height: 1.02 !important;
  text-wrap: balance;
}

body.apigraf-home .hero-slide-video .hero-content p {
  max-width: 62ch !important;
}

@media (max-width: 900px) {
  body.apigraf-home .hero-slide-video .hero-content {
    width: calc(100% - 40px) !important;
    max-width: none !important;
  }

  body.apigraf-home .hero-slide-video .hero-content h1,
  body.apigraf-home .hero-slide-video .hero-content h2 {
    max-width: 24ch !important;
    font-size: clamp(2.1rem, 7vw, 3.8rem) !important;
  }
}

@media (max-width: 560px) {
  body.apigraf-home .hero-slide-video .hero-content {
    width: calc(100% - 28px) !important;
  }

  body.apigraf-home .hero-slide-video .hero-content h1,
  body.apigraf-home .hero-slide-video .hero-content h2 {
    max-width: 100% !important;
    font-size: clamp(1.85rem, 9vw, 2.65rem) !important;
    line-height: 1.04 !important;
  }
}
