.hero-premium {
  --hero-title-x: 1px;
  --hero-title-y: 7px;
  --hero-title-scale: 1;
  --hero-body-x: 12px;
  --hero-body-y: -79px;
  --hero-body-scale: 1;
  --hero-actions-x: 5px;
  --hero-actions-y: -79px;
  --hero-actions-scale: 1;
  --hero-stage-x: 0px;
  --hero-stage-y: 0px;
  --hero-astronaut-scale: 1;
}

@media (max-width: 1024px) {
  .hero-premium {
    --hero-title-x: 0px;
    --hero-title-y: 0px;
    --hero-title-scale: 1;
    --hero-body-x: 0px;
    --hero-body-y: 0px;
    --hero-body-scale: 1;
    --hero-actions-x: 0px;
    --hero-actions-y: 0px;
    --hero-actions-scale: 1;
    --hero-stage-x: 0px;
    --hero-stage-y: 0px;
    --hero-astronaut-scale: 1;
  }
}

@media (min-width: 1025px) and (max-width: 1279px) {
  .hero-premium {
    min-height: min(100svh, 49.5rem);
    padding: calc(env(safe-area-inset-top, 0px) + 6.15rem) 0 4.85rem;
  }

  .hero-premium-shell {
    width: min(100% - 56px, 1180px);
  }

  .hero-premium-layout {
    grid-template-columns: minmax(0, 1fr) minmax(340px, 0.95fr);
    gap: clamp(1.2rem, 2.2vw, 2.5rem);
  }

  .hero-premium-copy {
    max-width: 31rem;
  }

  .hero-premium-title-lockup {
    width: min(100%, 27.75rem);
  }

  .hero-premium-body {
    max-width: min(38rem, calc(100vw - 5rem));
    margin-top: 0.95rem;
    font-size: 0.985rem;
    line-height: 1.58;
  }

  .hero-premium-actions {
    margin-top: 1.35rem;
  }

  .hero-premium-stage {
    width: min(100%, 31.5rem);
    min-height: 30.5rem;
    margin-top: 0.25rem;
  }

  .hero-premium-astronaut-wrap {
    width: min(100%, 30.75rem);
    right: -0.75rem;
    bottom: -1.15rem;
  }
}

@media (min-width: 1025px) and (max-width: 1199px) {
  .hero-premium {
    --hero-astronaut-top: 50%;
    --hero-astronaut-bottom: auto;
    --hero-astronaut-base-y: -50%;
  }
}

@media (min-width: 1200px) and (max-width: 1279px) {
  .hero-premium {
    --hero-astronaut-top: 50%;
    --hero-astronaut-bottom: auto;
    --hero-astronaut-base-y: -50%;
  }
}

@media (min-width: 861px) and (max-width: 1024px) {
  .hero-premium {
    min-height: min(100svh, 54rem);
    padding: calc(env(safe-area-inset-top, 0px) + 6.6rem) 0 5rem;
    --hero-astronaut-top: 50%;
    --hero-astronaut-bottom: auto;
    --hero-astronaut-base-y: -50%;
  }

  .hero-premium-shell {
    width: min(100% - 42px, 1024px);
  }

  .hero-premium-layout {
    grid-template-columns: minmax(0, 0.97fr) minmax(280px, 0.88fr);
    align-items: center;
    gap: clamp(0.8rem, 2vw, 1.5rem);
  }

  .hero-premium-copy {
    max-width: 24.5rem;
    margin: 0;
  }

  .hero-premium-title,
  .hero-premium-body,
  .hero-premium-actions {
    transform: none;
  }

  .hero-premium-title-lockup {
    width: min(100%, 24rem);
  }

  .hero-premium-body {
    max-width: 22rem;
    margin-top: 0.85rem;
    font-size: 0.95rem;
    line-height: 1.55;
  }

  .hero-premium-actions {
    margin-top: 1.1rem;
  }

  .hero-premium-stage {
    width: min(100%, 27rem);
    min-height: 27rem;
    margin-top: 0.25rem;
  }

  .hero-premium-astronaut-wrap {
    width: min(100%, 26.25rem);
    right: -1.15rem;
    bottom: -0.35rem;
  }
}

@media (min-width: 721px) and (max-width: 860px) {
  .hero-premium {
    align-items: flex-start;
    min-height: min(100svh, 48.5rem);
    padding: calc(env(safe-area-inset-top, 0px) + 5.5rem) 0 3.75rem;
  }

  .hero-premium-shell {
    width: calc(100% - 34px);
  }

  .hero-premium-layout {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .hero-premium-copy {
    position: relative;
    z-index: 4;
    max-width: 100%;
    min-height: 22.5rem;
    margin: 0;
  }

  .hero-premium-title,
  .hero-premium-body,
  .hero-premium-actions {
    transform: none;
  }

  .hero-premium-title-lockup {
    width: min(100%, 22.5rem);
  }

  .hero-premium-body {
    max-width: min(31rem, calc(100vw - 2.5rem));
    margin-top: 0.7rem;
    font-size: 0.95rem;
    line-height: 1.5;
  }

  .hero-premium-actions {
    margin-top: 0.9rem;
  }

  .hero-premium-stage {
    width: 100%;
    min-height: 19.25rem;
    margin-top: -10.2rem;
    z-index: 2;
  }

  .hero-premium-astronaut-wrap {
    width: min(72vw, 21.5rem);
    right: -1.35rem;
    bottom: auto;
    top: 0.4rem;
    margin: 0 0 0 auto;
  }

  .hero-premium-scroll {
    left: 50%;
    transform: translateX(-50%);
    bottom: calc(env(safe-area-inset-bottom, 0px) + 1.15rem);
  }
}

@media (min-width: 561px) and (max-width: 720px) {
  .hero-premium {
    align-items: flex-start;
    min-height: 52rem;
    padding: calc(env(safe-area-inset-top, 0px) + 6.1rem) 0 6.4rem;
  }

  .hero-premium-shell {
    width: calc(100% - 28px);
  }

  .hero-premium-layout {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .hero-premium-copy {
    position: relative;
    z-index: 4;
    max-width: 100%;
    min-height: 25.5rem;
    margin: 0;
  }

  .hero-premium-title,
  .hero-premium-body,
  .hero-premium-actions {
    transform: none;
  }

  .hero-premium-title-lockup {
    width: min(100%, 20.5rem);
  }

  .hero-premium-body {
    max-width: min(28rem, calc(100vw - 2rem));
    margin-top: 0.72rem;
    font-size: 0.95rem;
    line-height: 1.5;
  }

  .hero-premium-actions-desktop {
    display: flex;
    width: auto;
    max-width: fit-content;
  }

  .hero-premium-actions-mobile {
    display: none;
  }

  .hero-premium-actions {
    margin-top: 0.95rem;
  }

  .hero-premium-button {
    min-height: 3.3rem;
    padding: 0 1.22rem;
  }

  .hero-premium-stage {
    width: 100%;
    min-height: 20.75rem;
    margin-top: -11.4rem;
    z-index: 2;
  }

  .hero-premium-astronaut-wrap {
    width: min(83vw, 20.75rem);
    right: -1.15rem;
    bottom: auto;
    top: 1rem;
    margin: 0 0 0 auto;
  }

  .hero-premium-scroll {
    left: 50%;
    transform: translateX(-50%);
    bottom: calc(env(safe-area-inset-bottom, 0px) + 1.5rem);
  }
}

@media (max-width: 560px) {
  .hero-premium {
    align-items: flex-start;
    min-height: 48rem;
    padding: calc(env(safe-area-inset-top, 0px) + 5.8rem) 0 5.9rem;
  }

  .hero-premium-shell {
    width: calc(100% - 24px);
  }

  .hero-premium-layout {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .hero-premium-copy {
    position: relative;
    z-index: 4;
    max-width: 100%;
    min-height: 23.5rem;
    margin: 0;
  }

  .hero-premium-title,
  .hero-premium-body,
  .hero-premium-actions {
    transform: none;
  }

  .hero-premium-title-lockup {
    width: min(100%, 18.6rem);
  }

  .hero-premium-body {
    max-width: calc(100vw - 36px);
    margin-top: 0.65rem;
    font-size: 0.93rem;
    line-height: 1.48;
  }

  .hero-premium-actions-desktop {
    display: flex;
    width: auto;
    max-width: fit-content;
  }

  .hero-premium-actions-mobile {
    display: none;
  }

  .hero-premium-actions {
    margin-top: 0.85rem;
  }

  .hero-premium-button {
    min-height: 3.16rem;
    padding: 0 1.12rem;
  }

  .hero-premium-stage {
    width: 100%;
    min-height: 18.4rem;
    margin-top: -10.15rem;
    z-index: 2;
  }

  .hero-premium-astronaut-wrap {
    width: min(88vw, 18.8rem);
    right: -1.35rem;
    bottom: auto;
    top: 1rem;
    margin: 0 0 0 auto;
  }

  .hero-premium-astronaut {
    transform: translate3d(0, -4%, 0) scale(0.97);
    transform-origin: center bottom;
  }

  .hero-premium-scroll {
    left: 50%;
    transform: translateX(-50%);
    bottom: calc(env(safe-area-inset-bottom, 0px) + 1.35rem);
  }
}

@media (max-width: 430px) {
  .hero-premium-stage {
    min-height: 17.35rem;
    margin-top: -9.55rem;
  }

  .hero-premium-astronaut-wrap {
    width: min(79vw, 16.9rem);
    right: -0.3rem;
    top: 1.3rem;
  }
}

/* Final hero viewport + stacking normalization */
.hero-premium {
  min-height: 100svh;
  height: 100svh;
  overflow: clip;
}

.hero-premium-copy {
  z-index: 0;
}

.hero-premium-title,
.hero-premium-body {
  position: relative;
  z-index: 2;
}

.hero-premium-actions {
  position: relative;
  z-index: 5;
}

.hero-premium-stage {
  z-index: 3;
}

.hero-premium-scroll {
  bottom: calc(env(safe-area-inset-bottom, 0px) + clamp(0.8rem, 2vh, 1.25rem));
}

@media (min-width: 1025px) and (max-width: 1279px) {
  .hero-premium {
    min-height: 100svh;
    height: 100svh;
  }
}

@media (min-width: 861px) and (max-width: 1024px) {
  .hero-premium {
    min-height: 100svh;
    height: 100svh;
  }
}

@media (min-width: 721px) and (max-width: 860px) {
  .hero-premium {
    min-height: 100svh;
    height: 100svh;
  }
}

@media (min-width: 561px) and (max-width: 720px) {
  .hero-premium {
    min-height: 100svh;
    height: 100svh;
  }
}

@media (max-width: 560px) {
  .hero-premium {
    min-height: 100svh;
    height: 100svh;
  }

  .hero-premium-copy {
    display: flex;
    flex-direction: column;
    min-height: calc(100svh - env(safe-area-inset-top, 0px) - 5.8rem - 5.9rem);
  }

  .hero-premium-actions {
    display: none;
  }
}
