/* Homepage hero slideshow */

.home-hero {
  position: relative;
  min-height: 85vh;
  overflow: hidden;
  background: #1F2478;
}

.home-hero__backgrounds {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.home-hero__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  z-index: 0;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

.home-hero__slide.is-active {
  opacity: 1;
  visibility: visible;
  z-index: 2;
}

.home-hero__slide.is-leaving {
  opacity: 1;
  visibility: visible;
  z-index: 1;
}

.home-hero__slide.is-entering {
  opacity: 1;
  visibility: visible;
  z-index: 3;
}

.home-hero__kenburns {
  position: absolute;
  inset: -8%;
  background-size: cover;
  background-position: center;
  will-change: transform;
  transform: scale(1.05);
}

.home-hero__slide.is-active .home-hero__kenburns {
  animation: heroKenBurns 22s ease-in-out infinite alternate;
}

.home-hero__kenburns--1 { animation-name: heroKenBurns1 !important; }
.home-hero__kenburns--2 { animation-name: heroKenBurns2 !important; }
.home-hero__kenburns--3 { animation-name: heroKenBurns3 !important; }
.home-hero__kenburns--4 { animation-name: heroKenBurns4 !important; }

@keyframes heroKenBurns1 {
  0% { transform: scale(1.05) translate(0, 0); }
  100% { transform: scale(1.18) translate(-2.5%, -1.5%); }
}

@keyframes heroKenBurns2 {
  0% { transform: scale(1.08) translate(-1%, 0); }
  100% { transform: scale(1.2) translate(2%, -2%); }
}

@keyframes heroKenBurns3 {
  0% { transform: scale(1.06) translate(1%, 1%); }
  100% { transform: scale(1.17) translate(-1.5%, 2%); }
}

@keyframes heroKenBurns4 {
  0% { transform: scale(1.04) translate(0, -1%); }
  100% { transform: scale(1.16) translate(2.5%, 1%); }
}

/* Slice strips for transition reveal */
.home-hero__slices {
  position: absolute;
  inset: 0;
  display: flex;
  pointer-events: none;
  opacity: 0;
  z-index: 2;
}

.home-hero__slide.is-entering .home-hero__slices {
  opacity: 1;
}

.home-hero__slide.is-entering .home-hero__kenburns {
  opacity: 0;
}

.home-hero__slide.is-active:not(.is-entering) .home-hero__slices {
  display: none;
}

.home-hero__slice {
  flex: 1 1 0;
  height: 100%;
  background-size: calc(var(--slice-total) * 100%) 100%;
  background-position: calc(var(--slice-index) * 100% / max(var(--slice-total) - 1, 1)) center;
  background-repeat: no-repeat;
  transform: translateY(105%);
  opacity: 0;
}

.home-hero__slide.is-entering .home-hero__slice {
  animation: heroSliceIn 0.85s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  animation-delay: calc(var(--slice-index) * 0.055s);
}

.home-hero__slide.is-leaving .home-hero__slice {
  display: none;
}

.home-hero__slide.is-leaving .home-hero__kenburns {
  animation: none;
  opacity: 0;
  transform: scale(1.1);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

@keyframes heroSliceIn {
  0% {
    transform: translateY(105%) scaleY(1.1);
    opacity: 0;
    filter: brightness(1.3);
  }
  60% {
    opacity: 1;
    filter: brightness(1.05);
  }
  100% {
    transform: translateY(0) scaleY(1);
    opacity: 1;
    filter: brightness(1);
  }
}

/* Lighter overlay — images stay clear, text remains readable */
.home-hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(105deg, rgba(31, 36, 120, 0.55) 0%, rgba(46, 49, 146, 0.28) 42%, rgba(46, 49, 146, 0.08) 68%, rgba(0, 0, 0, 0.05) 100%),
    linear-gradient(180deg, rgba(31, 36, 120, 0.1) 0%, transparent 35%, rgba(31, 36, 120, 0.35) 100%);
}

.home-hero__glow {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}

.home-hero__glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  animation: heroGlowDrift 8s ease-in-out infinite alternate;
}

.home-hero__glow-orb--gold {
  top: 18%;
  left: 12%;
  width: 18rem;
  height: 18rem;
  background: rgba(0, 174, 239, 0.12);
}

.home-hero__glow-orb--white {
  bottom: 20%;
  right: 15%;
  width: 16rem;
  height: 16rem;
  background: rgba(255, 255, 255, 0.08);
  animation-delay: 2s;
}

@keyframes heroGlowDrift {
  0% { transform: translate(0, 0) scale(1); opacity: 0.7; }
  100% { transform: translate(20px, -15px) scale(1.08); opacity: 1; }
}

/* Content panels */
.home-hero__panels {
  position: relative;
  display: grid;
  grid-template: 1fr / 1fr;
  min-height: 20rem;
  width: 100%;
  will-change: transform;
  transition: transform 0.15s ease-out;
}

@media (min-width: 1024px) {
  .home-hero__panels {
    min-height: 22rem;
  }
}

.home-hero__panel {
  grid-area: 1 / 1;
  opacity: 0;
  visibility: hidden;
  transform: translateY(28px);
  transition: opacity 0.55s ease, transform 0.55s ease, visibility 0.55s ease;
  pointer-events: none;
}

.home-hero__panel.is-active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

.home-hero__panel.is-exiting {
  opacity: 0;
  transform: translateY(-18px);
}

.home-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: #5BCFF5;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.home-hero__eyebrow-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.35);
}

.home-hero__eyebrow-icon svg {
  color: #fff;
  filter: drop-shadow(0 1px 2px rgba(255, 255, 255, 0.35));
}

/* Buttons with breathing effect */
.home-hero__btn {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  padding: 1rem 2rem;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.9375rem;
  transition: background 0.35s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.35s ease, color 0.35s ease, transform 0.35s ease, box-shadow 0.35s ease;
}

.home-hero__btn svg {
  color: inherit;
  transition: transform 0.35s ease;
}

.home-hero__btn:hover svg {
  transform: translateX(3px);
}

.home-hero__btn--primary {
  background: #2E3192;
  color: #fff;
  border: 2px solid transparent;
  box-shadow: 0 10px 32px rgba(46, 49, 146, 0.45);
}

.home-hero__btn--primary:hover {
  background: #1F2478;
  transform: translateY(-2px);
  box-shadow: 0 16px 40px rgba(46, 49, 146, 0.55);
}

.home-hero__btn--primary svg {
  color: #fff;
}

.home-hero__btn--ghost {
  background: transparent;
  color: #2E3192;
  border: 2px solid #fff;
  backdrop-filter: none;
  text-shadow: 0 1px 14px rgba(255, 255, 255, 0.85), 0 0 20px rgba(255, 255, 255, 0.45);
}

.home-hero__btn--ghost:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: #fff;
  color: #1F2478;
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(255, 255, 255, 0.18);
}

.hero-btn-breathe {
  animation: heroBtnBreathe 3.2s ease-in-out infinite;
}

.hero-btn-breathe--delay {
  animation-delay: 0.8s;
}

.hero-icon-breathe {
  animation: heroIconBreathe 2.8s ease-in-out infinite;
  display: inline-flex;
}

@keyframes heroBtnBreathe {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 10px 32px rgba(46, 49, 146, 0.4);
  }
  50% {
    transform: scale(1.03);
    box-shadow: 0 16px 44px rgba(46, 49, 146, 0.55);
  }
}

.home-hero__btn--ghost.hero-btn-breathe {
  animation-name: heroBtnBreatheGhost;
}

@keyframes heroBtnBreatheGhost {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 4px 20px rgba(255, 255, 255, 0.08);
  }
  50% {
    transform: scale(1.025);
    box-shadow: 0 10px 28px rgba(255, 255, 255, 0.22);
  }
}

@keyframes heroIconBreathe {
  0%, 100% { transform: scale(1) translateX(0); opacity: 1; }
  50% { transform: scale(1.12) translateX(2px); opacity: 0.92; }
}

/* Controls */
.home-hero__controls {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-bottom: env(safe-area-inset-bottom, 0);
}

.home-hero__arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(10px);
  transition: background 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
  animation: heroIconBreathe 3.5s ease-in-out infinite;
}

.home-hero__arrow svg {
  color: #fff;
  filter: drop-shadow(0 1px 3px rgba(255, 255, 255, 0.35));
}

.home-hero__arrow:hover {
  background: rgba(0, 174, 239, 0.35);
  transform: scale(1.08);
}

.home-hero__dots {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.home-hero__dot {
  width: 2.25rem;
  height: 0.3rem;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.35);
  transition: width 0.35s ease, background 0.35s ease;
}

.home-hero__dot.is-active {
  width: 2.75rem;
  background: #00AEEF;
}

.home-hero__dot:hover {
  background: rgba(0, 174, 239, 0.7);
}

.home-hero__progress {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  z-index: 20;
  background: rgba(255, 255, 255, 0.12);
}

.home-hero__progress-bar {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, #00AEEF, #5BCFF5);
  transition: width 0.1s linear;
}

@media (prefers-reduced-motion: reduce) {
  .home-hero__kenburns,
  .home-hero__slice,
  .hero-btn-breathe,
  .hero-icon-breathe,
  .home-hero__arrow,
  .home-hero__glow-orb {
    animation: none !important;
  }

  .home-hero__slide.is-entering .home-hero__slice {
    transform: none;
    opacity: 1;
  }
}
