.alta-ih {
  --ih-text: #ffffff;
  --ih-button-border: rgba(255, 255, 255, 0.55);
  --ih-button-hover: rgba(255, 255, 255, 0.1);
  --ih-title-glow: rgba(173, 152, 255, 0.65);

  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: var(--ih-text);
  font-family: "Satoshi", system-ui, -apple-system, "Segoe UI", sans-serif;
  isolation: isolate;
}

.alta-ih *,
.alta-ih *::before,
.alta-ih *::after {
  box-sizing: border-box;
}

/* ---- background layer ---- */
.alta-ih__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.alta-ih__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.alta-ih__scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
}

/* ---- content layer ---- */
.alta-ih__content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1440px;
  min-height: inherit;
  padding: 80px 32px 64px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.alta-ih__copy {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 28px;
  margin-top: auto;
}

.alta-ih__eyebrow {
  margin: 0;
  font-size: clamp(13px, 1.1vw, 16px);
  letter-spacing: 0.4em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--ih-text);
  opacity: 0.95;
}

.alta-ih__title {
  margin: 0;
  font-family: "Eurostile", "Bank Gothic", "Satoshi", sans-serif;
  font-size: clamp(64px, 11vw, 180px);
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 0.95;
  text-transform: uppercase;
  color: #ffffff;
}

.alta-ih__title--glow {
  text-shadow:
    0 0 20px var(--ih-title-glow),
    0 0 60px var(--ih-title-glow),
    0 0 120px rgba(173, 152, 255, 0.35);
}

/* SVG title mode — scales with viewport, glow via drop-shadow */
.alta-ih__title--svg {
  display: block;
  width: 100%;
  max-width: clamp(280px, 60vw, 820px);
  height: auto;
  color: #ffffff;
  text-shadow: none;
  line-height: 0;
}

.alta-ih__title--svg svg {
  display: block;
  width: 100%;
  height: auto;
  color: inherit;
}

.alta-ih__title--svg.alta-ih__title--glow {
  filter:
    drop-shadow(0 0 18px var(--ih-title-glow))
    drop-shadow(0 0 48px var(--ih-title-glow))
    drop-shadow(0 0 100px rgba(173, 152, 255, 0.35));
}

/* ---- product images flanking the title ---- */
.alta-ih__product {
  position: absolute;
  z-index: 2;
  pointer-events: none;
  user-select: none;
  width: clamp(220px, 32vw, 520px);
  height: auto;
  filter: drop-shadow(0 30px 60px rgba(0, 0, 0, 0.45));
  opacity: 0;
  will-change: transform, opacity;
}

.alta-ih__product--left {
  left: 4%;
  top: 50%;
  transform: translateY(-50%);
}

.alta-ih__product--right {
  right: 4%;
  top: 50%;
  transform: translateY(-50%);
}

/* ---- buttons (sit below the product images, near the bottom of the section) ---- */
.alta-ih__buttons {
  position: relative;
  z-index: 4;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-top: auto;
  padding-top: clamp(48px, 12vh, 140px);
}

.alta-ih__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 36px;
  border: 1px solid var(--ih-button-border);
  border-radius: 999px;
  color: var(--ih-text);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  background: transparent;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.alta-ih__button:hover {
  background: var(--ih-button-hover);
  border-color: #ffffff;
  transform: translateY(-1px);
}

/* ---- entrance animation ---- */
.alta-ih--animate .alta-ih__eyebrow {
  animation: alta-ih-fade-up 1.1s cubic-bezier(0.22, 1, 0.36, 1) 0.2s both;
}
.alta-ih--animate .alta-ih__title {
  animation: alta-ih-title-in 1.4s cubic-bezier(0.22, 1, 0.36, 1) 0.35s both;
}
.alta-ih--animate .alta-ih__buttons {
  animation: alta-ih-fade-up 1.1s cubic-bezier(0.22, 1, 0.36, 1) 0.7s both;
}

.alta-ih--animate .alta-ih__product--left {
  animation:
    alta-ih-product-in-left 1.6s cubic-bezier(0.22, 1, 0.36, 1) 0.45s both,
    alta-ih-float-left 7s ease-in-out 2.05s infinite;
}
.alta-ih--animate .alta-ih__product--right {
  animation:
    alta-ih-product-in-right 1.6s cubic-bezier(0.22, 1, 0.36, 1) 0.55s both,
    alta-ih-float-right 8s ease-in-out 2.15s infinite;
}

/* subtle title glow pulse — text variant pulses text-shadow */
.alta-ih--animate .alta-ih__title--glow:not(.alta-ih__title--svg) {
  animation:
    alta-ih-title-in 1.4s cubic-bezier(0.22, 1, 0.36, 1) 0.35s both,
    alta-ih-glow-pulse 5.5s ease-in-out 1.85s infinite;
}

/* SVG variant pulses drop-shadow filter via opacity for cheap GPU work */
.alta-ih--animate .alta-ih__title--svg.alta-ih__title--glow {
  animation:
    alta-ih-title-in 1.4s cubic-bezier(0.22, 1, 0.36, 1) 0.35s both,
    alta-ih-glow-pulse-svg 5.5s ease-in-out 1.85s infinite;
}

/* No animation: still show products */
.alta-ih:not(.alta-ih--animate) .alta-ih__product {
  opacity: 1;
}

@keyframes alta-ih-fade-up {
  0% {
    opacity: 0;
    transform: translateY(16px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes alta-ih-title-in {
  0% {
    opacity: 0;
    transform: translateY(24px) scale(0.96);
    letter-spacing: 0.06em;
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    letter-spacing: 0.02em;
  }
}

@keyframes alta-ih-product-in-left {
  0% {
    opacity: 0;
    transform: translate(-40px, calc(-50% + 8px)) rotate(-3deg);
  }
  100% {
    opacity: 1;
    transform: translate(0, -50%) rotate(0);
  }
}

@keyframes alta-ih-product-in-right {
  0% {
    opacity: 0;
    transform: translate(40px, calc(-50% + 8px)) rotate(3deg);
  }
  100% {
    opacity: 1;
    transform: translate(0, -50%) rotate(0);
  }
}

@keyframes alta-ih-float-left {
  0%, 100% {
    transform: translate(0, calc(-50% - 6px)) rotate(-0.4deg);
  }
  50% {
    transform: translate(0, calc(-50% + 6px)) rotate(0.4deg);
  }
}

@keyframes alta-ih-float-right {
  0%, 100% {
    transform: translate(0, calc(-50% + 6px)) rotate(0.4deg);
  }
  50% {
    transform: translate(0, calc(-50% - 6px)) rotate(-0.4deg);
  }
}

@keyframes alta-ih-glow-pulse {
  0%, 100% {
    text-shadow:
      0 0 20px var(--ih-title-glow),
      0 0 60px var(--ih-title-glow),
      0 0 120px rgba(173, 152, 255, 0.35);
  }
  50% {
    text-shadow:
      0 0 30px var(--ih-title-glow),
      0 0 90px var(--ih-title-glow),
      0 0 160px rgba(173, 152, 255, 0.5);
  }
}

@keyframes alta-ih-glow-pulse-svg {
  0%, 100% {
    filter:
      drop-shadow(0 0 18px var(--ih-title-glow))
      drop-shadow(0 0 48px var(--ih-title-glow))
      drop-shadow(0 0 100px rgba(173, 152, 255, 0.35));
  }
  50% {
    filter:
      drop-shadow(0 0 26px var(--ih-title-glow))
      drop-shadow(0 0 70px var(--ih-title-glow))
      drop-shadow(0 0 140px rgba(173, 152, 255, 0.5));
  }
}

@media (prefers-reduced-motion: reduce) {
  .alta-ih--animate .alta-ih__eyebrow,
  .alta-ih--animate .alta-ih__title,
  .alta-ih--animate .alta-ih__title--glow,
  .alta-ih--animate .alta-ih__buttons,
  .alta-ih--animate .alta-ih__product--left,
  .alta-ih--animate .alta-ih__product--right {
    animation: none !important;
    opacity: 1;
  }
  .alta-ih--animate .alta-ih__product--left {
    transform: translateY(-50%);
  }
  .alta-ih--animate .alta-ih__product--right {
    transform: translateY(-50%);
  }
}

/* ---- responsive ---- */
@media (max-width: 900px) {
  .alta-ih__content {
    padding: 64px 20px;
  }
  .alta-ih__product {
    width: clamp(160px, 36vw, 280px);
    opacity: 0.85;
  }
  .alta-ih__product--left {
    left: -6%;
  }
  .alta-ih__product--right {
    right: -6%;
  }
}

/* Mobile: products stack at center with slight overlap (matches the
   "AP7-PRO" mobile mockup). Title sits at top, buttons at bottom. */
@media (max-width: 640px) {
  .alta-ih__content {
    padding: 72px 20px 36px;
    justify-content: space-between;
  }
  .alta-ih__copy {
    margin-top: 0;
    gap: 18px;
  }
  .alta-ih__title:not(.alta-ih__title--svg) {
    font-size: clamp(64px, 16vw, 100px);
  }
  .alta-ih__product {
    width: 70vw;
    max-width: 360px;
    top: 50%;
    left: 50%;
    opacity: 1;
    filter: drop-shadow(0 24px 40px rgba(0, 0, 0, 0.55));
  }
  .alta-ih__product--left {
    /* front product: slightly left + forward, in front */
    right: auto;
    transform: translate(-60%, -45%);
    z-index: 3;
  }
  .alta-ih__product--right {
    /* back product: slightly right + behind, smaller */
    right: auto;
    width: 55vw;
    max-width: 280px;
    transform: translate(-25%, -55%);
    z-index: 2;
  }
  .alta-ih__buttons {
    padding-top: 0;
    gap: 12px;
    width: 100%;
  }
  .alta-ih__button {
    padding: 13px 22px;
    font-size: 12px;
    letter-spacing: 0.14em;
    flex: 1 1 0;
    min-width: 0;
  }

  /* Replace left/right slide-in animations with simple fade-in so they don't
     fight the centered transforms above. Float animation is also dropped on
     mobile — the layered positioning reads as static-but-3D already. */
  .alta-ih--animate .alta-ih__product--left,
  .alta-ih--animate .alta-ih__product--right {
    animation: alta-ih-product-fade 1s cubic-bezier(0.22, 1, 0.36, 1) 0.5s both;
  }
}

@keyframes alta-ih-product-fade {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

