/* Enterprise motion inspired by 21st.dev patterns
   (shimmer CTA, number ticker, spotlight cards, border beam, text reveal)
   Adapted to MyXavi navy/gold — vanilla CSS, no React deps. */

/* —— Shimmer button —— */
.btn-shimmer {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.btn-shimmer::before {
  content: "";
  position: absolute;
  inset: -40% -60%;
  background: linear-gradient(
    105deg,
    transparent 35%,
    rgba(255, 255, 255, 0.55) 50%,
    transparent 65%
  );
  transform: translateX(-40%) rotate(8deg);
  animation: shimmer-sweep 2.8s ease-in-out infinite;
  z-index: 1;
  pointer-events: none;
}

.btn-shimmer > * {
  position: relative;
  z-index: 2;
}

@keyframes shimmer-sweep {
  0%,
  40% {
    transform: translateX(-55%) rotate(8deg);
  }
  100% {
    transform: translateX(55%) rotate(8deg);
  }
}

/* —— Spotlight card (mouse glow) —— */
.spotlight-card {
  position: relative;
  overflow: hidden;
  --spot-x: 50%;
  --spot-y: 50%;
}

.spotlight-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    420px circle at var(--spot-x) var(--spot-y),
    rgba(199, 154, 58, 0.16),
    transparent 55%
  );
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
  z-index: 0;
}

.spotlight-card:hover::before {
  opacity: 1;
}

.spotlight-card > * {
  position: relative;
  z-index: 1;
}

.price-card.featured.spotlight-card::before {
  background: radial-gradient(
    420px circle at var(--spot-x) var(--spot-y),
    rgba(199, 154, 58, 0.28),
    transparent 55%
  );
}

/* —— Border beam —— */
.border-beam {
  position: relative;
}

.border-beam::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    120deg,
    transparent 20%,
    rgba(199, 154, 58, 0.85),
    rgba(255, 255, 255, 0.55),
    transparent 80%
  );
  background-size: 220% 220%;
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  animation: beam-move 4.5s linear infinite;
  opacity: 0.55;
  pointer-events: none;
  z-index: 2;
}

.border-beam:hover::after {
  opacity: 1;
}

@keyframes beam-move {
  0% {
    background-position: 0% 50%;
  }
  100% {
    background-position: 200% 50%;
  }
}

/* —— Number ticker —— */
.num-ticker {
  font-variant-numeric: tabular-nums;
  display: inline-block;
  min-width: 0.6em;
}

/* —— Text reveal (blur → clear) —— */
[data-reveal] h2,
[data-reveal].section-head h2,
.panel-editorial h2 {
  transition: opacity 0.75s var(--ease), transform 0.75s var(--ease), filter 0.75s var(--ease);
}

[data-reveal].is-in h2 {
  filter: none;
}

/* —— Hero: content-height, top-aligned — no empty navy bands —— */
section.hero,
#main > section.hero,
#main > .hero.stack-layer,
#main > .hero[data-stack] {
  align-items: flex-start !important;
  justify-content: flex-start !important;
  min-height: unset !important;
  height: auto !important;
  max-height: none !important;
  padding: calc(var(--nav-h) + 1.75rem) 0 1.25rem !important;
}

.hero-media::after {
  background:
    linear-gradient(105deg, rgba(8, 12, 28, 0.88) 0%, rgba(14, 21, 48, 0.55) 55%, rgba(14, 21, 48, 0.4) 100%),
    linear-gradient(180deg, rgba(8, 12, 28, 0.2) 0%, rgba(8, 12, 28, 0.78) 100%) !important;
}

.hero .brand-mark {
  /* Solid fallback first — gradient clip can fail visually */
  color: #fff !important;
  -webkit-text-fill-color: #fff;
  background: none;
  filter: none;
  font-size: clamp(2.75rem, 9vw, 5.5rem) !important;
  margin-bottom: 0.5rem !important;
  line-height: 0.95;
}

@supports ((-webkit-background-clip: text) or (background-clip: text)) {
  .hero .brand-mark {
    background: linear-gradient(120deg, #ffffff 15%, #f0d78a 55%, var(--gold) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent !important;
  }
}

.hero h1 {
  text-shadow: 0 2px 28px rgba(0, 0, 0, 0.35);
  margin-bottom: 0.75rem !important;
}

.hero-content {
  width: min(100% - 2.5rem, var(--max));
  margin-top: 0;
  animation: hero-rise 0.9s var(--ease) both;
}

@keyframes hero-rise {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

ul.hero-chips {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 0.5rem !important;
  list-style: none !important;
  margin: 1.35rem 0 0.75rem !important;
  padding: 0 !important;
}

ul.hero-chips li {
  font-family: var(--font-display);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.92);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  padding: 0.45rem 0.85rem;
  backdrop-filter: blur(8px);
  list-style: none !important;
}

ul.hero-chips li::marker {
  content: none;
}

.hero-chips .num-ticker {
  color: #f0d78a;
}

.overlap-wrap {
  margin-top: -2.5rem !important;
  padding-bottom: 0;
}

.overlap-wrap .panel-editorial {
  padding: clamp(1.5rem, 4vw, 2.5rem) !important;
}

#main > .stack-layer + .stack-layer,
#main > [data-stack] + [data-stack] {
  margin-top: 0 !important;
  box-shadow: none !important;
  border-radius: 0 !important;
}

.site-footer.stack-footer {
  margin-top: 0 !important;
}

/* —— Section rhythm tighter —— */
.section {
  padding: clamp(3.25rem, 7vw, 5.5rem) 0 !important;
}

.section-tight {
  padding: clamp(2.75rem, 5vw, 4rem) 0 !important;
}

.section-navy {
  /* avoid empty-looking bands: keep content padding moderate */
  min-height: 0 !important;
}

.pin-panel {
  min-height: auto !important;
  padding: 3rem 0 !important;
}

/* —— Mesh aurora on navy sections (enterprise depth) —— */
.section-navy::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 50% 40% at 15% 20%, rgba(199, 154, 58, 0.14), transparent 60%),
    radial-gradient(ellipse 40% 50% at 90% 80%, rgba(70, 100, 200, 0.22), transparent 55%);
  pointer-events: none;
  z-index: 0;
  animation: aurora-drift 14s ease-in-out infinite alternate;
}

.section-navy > * {
  position: relative;
  z-index: 1;
}

@keyframes aurora-drift {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
    opacity: 0.85;
  }
  100% {
    transform: translate3d(2%, -1.5%, 0) scale(1.05);
    opacity: 1;
  }
}


@media (prefers-reduced-motion: reduce) {
  .btn-shimmer::before,
  .border-beam::after,
  .section-navy::before,
  .trust-strip::after {
    animation: none !important;
  }

  [data-reveal]:not(.is-in) h2 {
    filter: none;
  }
}
