/*
 * Launch Hero — plain scoped CSS (Webflow shadow root), mobile-first with tablet 768px / desktop 1280px.
 * The photo card, masks and glow mirror the registration hero; the content block carries the Figma launch
 * hero values (desktop: 70px inset, 26px gaps, 20/26 copy; mobile: 42/42 headline, 16/18 copy, 20px inside the photo edge).
 */

.launch-hero,
.launch-hero *,
.launch-hero *::before,
.launch-hero *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: var(--font-family, 'IBM Plex Sans'), sans-serif;
}

/* Section — fills the viewport, and grows with the content when that is taller. */

.launch-hero {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 100vw;
  height: auto;
  border-radius: 16px;
  background:
    linear-gradient(to bottom, transparent calc(100% - 200px), #000 calc(100% - 10px)),
    radial-gradient(
      334.5px 327px at 196px 1240px,
      rgba(214, 109, 0, 0.5),
      rgba(124, 57, 0, 0.5) 37.5%,
      rgba(72, 22, 5, 0.5) 72.6%,
      transparent
    ),
    #000;
  overflow: hidden;
  color: #fff;
}

@media (min-width: 768px) {
  .launch-hero {
    display: block;
    min-height: 100vh;
  }
}

/* Figma desktop-prototype is a 1102px viewport: the card is 26px in from the top and bottom, and the next
   section's 55px top padding starts 84px below the card, so the hero runs 58px past the fold. */
@media (min-width: 1280px) {
  .launch-hero {
    min-height: max(900px, calc(100vh + 58px));
    border-radius: 40px;
    /* The glow runs past the box; fade it to black at the bottom so it doesn't stop on a hard line above the next section. */
    background:
      linear-gradient(to bottom, transparent calc(100% - 260px), #000 calc(100% - 20px)),
      radial-gradient(
        58.8% 77% at 57.1% 62%,
        rgba(214, 109, 0, 0.35),
        rgba(124, 57, 0, 0.35) 37.5%,
        rgba(72, 22, 5, 0.35) 72.6%,
        transparent
      ),
      #000;
  }
}

/* Card holding the photo and content. */

.launch-hero__card {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: center;
  flex: 1 1 auto;
  width: 100%;
  min-height: max(600px, calc(100vh + 11px));
  min-height: max(600px, calc(100svh + 11px));
  height: auto;
  border-radius: 20px;
  padding: 14px 14px 51px;
}

@media (min-width: 768px) {
  .launch-hero__card {
    justify-content: flex-start;
    width: calc(100% - 66px);
    min-height: calc(100vh - 54px);
    margin: 27px auto 0;
    padding: 0;
  }
}

@media (min-width: 1280px) {
  .launch-hero__card {
    width: calc(100% - 44px);
    min-height: max(800px, calc(100vh - 52px));
    margin: 26px 0 0 22px;
    border-radius: 0;
    padding: 0;
  }
}

/* Photo inside each mask. */

.launch-hero__photo {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: var(--launch-hero-photo-position-mobile, 50% -300px);
  border-radius: 20px;
  background: #000;
}

@media (min-width: 768px) {
  .launch-hero__photo {
    object-position: var(--launch-hero-photo-position-tablet, 50% calc(100% - 80px));
    border-radius: 0;
  }
}

@media (min-width: 1280px) {
  .launch-hero__photo {
    object-position: var(--launch-hero-photo-position-desktop, 50% calc(100% - 80px));
  }
}

.launch-hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: 20px;
  background: #000;
  opacity: var(--launch-hero-overlay-opacity, 0);
  pointer-events: none;
}

@media (min-width: 768px) {
  .launch-hero__overlay {
    border-radius: 0;
  }
}

/* Masks: one per breakpoint, toggled below. */

.launch-hero__mask,
.launch-hero__glow {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 0;
  width: calc(100% - 28px);
  height: calc(100% - 65px);
}

.launch-hero__mask {
  display: none;
  mask-repeat: no-repeat;
  -webkit-mask-repeat: no-repeat;
  mask-size: 100% 100%;
  -webkit-mask-size: 100% 100%;
}

.launch-hero__mask--mobile {
  display: block;
}

@media (min-width: 768px) {
  .launch-hero__mask--mobile {
    display: none;
  }

  .launch-hero__mask--tablet {
    display: block;
  }
}

@media (min-width: 1280px) {
  .launch-hero__mask--tablet {
    display: none;
  }

  .launch-hero__mask--desktop {
    display: block;
  }
}

.launch-hero__mask::after {
  content: '';
  position: absolute;
  inset: 0;
}

/* Phones: photo framed from the text block so the face stays above the headline; black fade behind the text. */
@media (max-width: 767.98px) {
  .launch-hero__mask--mobile .launch-hero__photo {
    top: var(--launch-hero-photo-top, 0px);
    bottom: auto;
    height: var(--launch-hero-photo-height, 100%);
    object-position: var(--launch-hero-photo-position-mobile, 50% 50%);
  }

  .launch-hero__mask--mobile::after {
    background: linear-gradient(
      to bottom,
      transparent var(--launch-hero-fade-start, 60%),
      #000 var(--launch-hero-fade-end, 100%)
    );
  }
}

@media (min-width: 768px) {
  .launch-hero__mask,
  .launch-hero__glow {
    inset: 0;
    width: 100%;
    height: 100%;
  }
}

/* Mobile + tablet: 1px edge highlight following the card shape, with a warm glow at the bottom centre. */

@media (max-width: 1279.98px) {
  .launch-hero__mask::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: radial-gradient(50% 18% at 50% 100%, rgba(255, 214, 150, 0.75), transparent), rgba(255, 255, 255, 0.12);
    mask-image: var(--launch-hero-mask), var(--launch-hero-mask);
    -webkit-mask-image: var(--launch-hero-mask), var(--launch-hero-mask);
    mask-size:
      100% 100%,
      calc(100% - 2px) calc(100% - 2px);
    -webkit-mask-size:
      100% 100%,
      calc(100% - 2px) calc(100% - 2px);
    mask-position:
      0 0,
      1px 1px;
    -webkit-mask-position:
      0 0,
      1px 1px;
    mask-repeat: no-repeat;
    -webkit-mask-repeat: no-repeat;
    mask-composite: exclude;
    -webkit-mask-composite: xor;
  }
}

@media (min-width: 1280px) {
  .launch-hero__mask,
  .launch-hero__glow {
    inset: 0;
    width: 100%;
    height: 100%;
    min-height: 0;
  }

  .launch-hero__mask::after {
    background: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.3) 762px);
  }
}

/* Edge Glow host (see useEdgeGlow): its canvas reaches 110px past the card; the section clips the halo. */

.launch-hero__glow {
  pointer-events: none;
}

/* Content block */

.launch-hero__content {
  z-index: 1;
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  gap: 12px;
  padding: 0 20px 20px;
  width: 100%;
}

@media (min-width: 768px) {
  .launch-hero__content {
    gap: 31px;
    padding: 110px 52px 52px;
  }
}

@media (min-width: 1280px) {
  .launch-hero__content {
    gap: 26px;
    min-height: 0;
    padding: 120px 70px 70px;
  }
}

.launch-hero__text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
  width: 100%;
}

@media (min-width: 768px) {
  .launch-hero__text {
    gap: 31px;
  }
}

@media (min-width: 1280px) {
  .launch-hero__text {
    gap: 26px;
  }
}

.launch-hero__headline {
  width: 100%;
  font-size: 42px;
  font-weight: 500;
  line-height: 42px;
  letter-spacing: -1.26px;
  color: #fff;
  white-space: pre-line;
}

@media (min-width: 768px) {
  .launch-hero__headline {
    font-size: 56px;
    line-height: 1;
    letter-spacing: -1.68px;
  }
}

@media (min-width: 1280px) {
  .launch-hero__headline {
    max-width: max(50%, 680px);
    font-size: 88px;
    line-height: 0.99;
    letter-spacing: -1.76px;
  }
}

.launch-hero__copy {
  font-size: 16px;
  font-weight: 400;
  line-height: 18px;
  color: #fff;
  white-space: pre-line;
}

@media (min-width: 768px) {
  .launch-hero__copy {
    font-size: 20px;
    line-height: 26px;
  }
}

/* "Get Edge" pill (Figma hero `button`): mobile 181 × 18px, desktop 230 × 22.86px. */

a.launch-hero__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  min-width: 181px;
  margin: 0;
  padding: 20px 25px;
  border: 0;
  border-radius: 999px;
  background: #fff;
  color: #000;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition:
    transform 0.2s ease,
    background-color 0.2s ease,
    box-shadow 0.2s ease;
}

a.launch-hero__cta:hover {
  background: #f0dab1;
  box-shadow: 0 0 24px rgba(240, 218, 177, 0.35);
}

a.launch-hero__cta:active {
  transform: scale(0.98);
}

a.launch-hero__cta:focus-visible {
  outline: 2px solid #e0b25c;
  outline-offset: 3px;
}

@media (min-width: 768px) {
  a.launch-hero__cta {
    min-width: 230px;
    padding: 25px 32px;
    font-size: 22.86px;
  }
}

@keyframes launch_hero_rise_headline {
  from {
    opacity: 0;
    translate: 0 40px;
    filter: blur(12px);
  }
  to {
    opacity: 1;
    translate: 0 0;
    filter: blur(0);
  }
}

@keyframes launch_hero_push_in {
  from {
    scale: 1.08;
  }
  to {
    scale: 1;
  }
}

@keyframes launch_hero_rise_cta {
  from {
    opacity: 0;
    translate: 0 25px;
  }
  to {
    opacity: 1;
    translate: 0 0;
  }
}

.launch-hero__headline {
  animation: launch_hero_rise_headline 1000ms cubic-bezier(0.22, 1, 0.36, 1)
    calc(var(--launch-hero-intro-delay, 0ms) + 150ms) both;
}

.launch-hero__copy {
  animation: launch_hero_rise_headline 1000ms cubic-bezier(0.22, 1, 0.36, 1)
    calc(var(--launch-hero-intro-delay, 0ms) + 380ms) both;
}

/* Cinematic push-in: the photo settles from 108% as the page opens. */
.launch-hero__photo {
  animation: launch_hero_push_in 2600ms cubic-bezier(0.16, 1, 0.3, 1) var(--launch-hero-intro-delay, 0ms) both;
}

a.launch-hero__cta {
  animation: launch_hero_rise_cta 700ms cubic-bezier(0.22, 1, 0.36, 1) calc(var(--launch-hero-intro-delay, 0ms) + 600ms)
    both;
}

@media (prefers-reduced-motion: reduce) {
  .launch-hero__headline,
  .launch-hero__copy,
  .launch-hero__photo,
  a.launch-hero__cta {
    animation: none;
  }

  a.launch-hero__cta {
    transition: none;
  }
}

/* Parallax: as the page scrolls away from the hero, the photo drifts down at a fifth of the scroll speed and the
   text lifts and fades, so the hero sinks behind the page. Scroll-driven (no JS); unsupported browsers stay static. */
@keyframes launch_hero_drift {
  to {
    translate: 0 22vh;
  }
}

@keyframes launch_hero_lift {
  to {
    opacity: 0;
    translate: 0 -10vh;
  }
}

@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    .launch-hero__photo {
      animation:
        launch_hero_push_in 2600ms cubic-bezier(0.16, 1, 0.3, 1) var(--launch-hero-intro-delay, 0ms) both,
        launch_hero_drift linear both;
      animation-timeline: auto, scroll(root block);
      animation-range:
        normal,
        0 100vh;
    }

    .launch-hero__content {
      animation: launch_hero_lift linear both;
      animation-timeline: scroll(root block);
      animation-range: 0 80vh;
    }
  }
}

/* Time-based entrance: the whole card fades in as the Edge Preloader lifts (Intro Delay), then the text rises in. */
@keyframes launch_hero_fade_in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .launch-hero__card {
    animation: launch_hero_fade_in 1.1s cubic-bezier(0.22, 1, 0.36, 1) var(--launch-hero-intro-delay, 0ms) both;
  }
}

