/* Premium motion layer for the existing landing hero. */

/* Entrance states only exist when JavaScript is available. */
.hero-motion-enabled .landing-ref .hero:not(.hero-motion-visible) .hero__badge {
  opacity: 0;
  transform: translate3d(0, -10px, 0);
}

/* O H1 é o elemento de LCP, então ele precisa pintar imediatamente. */

.hero-motion-enabled .landing-ref .hero:not(.hero-motion-visible) .hero__subtitle,
.hero-motion-enabled .landing-ref .hero:not(.hero-motion-visible) .hero__chip,
.hero-motion-enabled .landing-ref .hero:not(.hero-motion-visible) .hero__micro {
  opacity: 0;
  transform: translate3d(0, 18px, 0);
}

.hero-motion-enabled .landing-ref .hero:not(.hero-motion-visible) .hero__actions {
  opacity: 0;
  transform: scale(0.97);
}

.hero-motion-enabled .landing-ref .hero:not(.hero-motion-visible) .hero__visual {
  opacity: 0;
  transform: translate3d(40px, 0, 0);
}

.hero-motion-enabled .landing-ref .hero:not(.hero-motion-visible) .hero__float--1 {
  opacity: 0;
  transform: translate3d(-12px, 0, 0);
}

.hero-motion-enabled .landing-ref .hero:not(.hero-motion-visible) .hero__float--2 {
  opacity: 0;
  transform: translate3d(0, 8px, 0) scale(0.98);
}

.hero-motion-enabled .landing-ref .hero__badge,
.hero-motion-enabled .landing-ref .hero__title,
.hero-motion-enabled .landing-ref .hero__subtitle,
.hero-motion-enabled .landing-ref .hero__chip,
.hero-motion-enabled .landing-ref .hero__actions,
.hero-motion-enabled .landing-ref .hero__micro,
.hero-motion-enabled .landing-ref .hero__visual,
.hero-motion-enabled .landing-ref .hero__float {
  transition-property: opacity, transform;
  transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
}

.hero-motion-enabled .landing-ref .hero__badge {
  transition-duration: 300ms;
}

.hero-motion-enabled .landing-ref .hero__title {
  transition-duration: 620ms;
}

.hero-motion-enabled .landing-ref .hero__title .accent {
  transition: opacity 520ms cubic-bezier(0.22, 1, 0.36, 1);
}

.hero-motion-enabled .landing-ref .hero__subtitle,
.hero-motion-enabled .landing-ref .hero__actions,
.hero-motion-enabled .landing-ref .hero__micro {
  transition-duration: 520ms;
}

.hero-motion-enabled .landing-ref .hero__chip {
  transition-property: opacity, transform;
  transition-duration: 480ms;
}

.hero-motion-enabled .landing-ref .hero-motion-settled .hero__chip {
  transition-duration: 220ms;
}

.hero-motion-enabled .landing-ref .hero__visual {
  transition-duration: 700ms;
}

.hero-motion-enabled .landing-ref .hero__float {
  transition-duration: 620ms;
}

.hero-motion-enabled .landing-ref .hero-motion-visible .hero__badge,
.hero-motion-enabled .landing-ref .hero-motion-visible .hero__title,
.hero-motion-enabled .landing-ref .hero-motion-visible .hero__subtitle,
.hero-motion-enabled .landing-ref .hero-motion-visible .hero__chip,
.hero-motion-enabled .landing-ref .hero-motion-visible .hero__actions,
.hero-motion-enabled .landing-ref .hero-motion-visible .hero__micro,
.hero-motion-enabled .landing-ref .hero-motion-visible .hero__visual,
.hero-motion-enabled .landing-ref .hero-motion-visible .hero__float {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
}

.hero-motion-enabled .landing-ref .hero-motion-visible:not(.hero-motion-settled) .hero__title {
  transition-delay: 80ms;
}

.hero-motion-enabled .landing-ref .hero-motion-visible:not(.hero-motion-settled) .hero__title .accent {
  transition-delay: 160ms;
}

.hero-motion-enabled .landing-ref .hero-motion-visible:not(.hero-motion-settled) .hero__subtitle {
  transition-delay: 210ms;
}

.hero-motion-enabled .landing-ref .hero-motion-visible:not(.hero-motion-settled) .hero__chip:nth-child(1) {
  transition-delay: 300ms;
}

.hero-motion-enabled .landing-ref .hero-motion-visible:not(.hero-motion-settled) .hero__chip:nth-child(2) {
  transition-delay: 380ms;
}

.hero-motion-enabled .landing-ref .hero-motion-visible:not(.hero-motion-settled) .hero__chip:nth-child(3) {
  transition-delay: 460ms;
}

.hero-motion-enabled .landing-ref .hero-motion-visible:not(.hero-motion-settled) .hero__chip:nth-child(4) {
  transition-delay: 540ms;
}

.hero-motion-enabled .landing-ref .hero-motion-visible:not(.hero-motion-settled) .hero__actions {
  transition-delay: 620ms;
}

.hero-motion-enabled .landing-ref .hero-motion-visible:not(.hero-motion-settled) .hero__micro {
  transition-delay: 700ms;
}

.hero-motion-enabled .landing-ref .hero-motion-visible:not(.hero-motion-settled) .hero__visual {
  transition-delay: 170ms;
}

.hero-motion-enabled .landing-ref .hero-motion-visible:not(.hero-motion-settled) .hero__float--1 {
  transition-delay: 760ms;
}

.hero-motion-enabled .landing-ref .hero-motion-visible:not(.hero-motion-settled) .hero__float--2 {
  transition-delay: 900ms;
}

/* Ambient motion uses only compositor-friendly transform and opacity. */
.landing-ref .hero-motion-live .hero__halo {
  will-change: transform, opacity;
  animation: hero-halo-breathe 8s ease-in-out infinite;
}

.landing-ref .hero-motion-live .hero__mockup {
  will-change: transform;
  animation: hero-dashboard-drift 12s ease-in-out infinite;
}

.landing-ref .hero-motion-live .hero__float--1 {
  will-change: transform;
  animation: hero-float-one 6.4s ease-in-out infinite;
}

.landing-ref .hero-motion-live .hero__float--2 {
  will-change: transform;
  animation: hero-float-two 5.6s ease-in-out infinite;
}

.landing-ref .hero-motion-live .dash-help svg {
  transform-origin: center;
  will-change: transform, opacity;
  animation: hero-automation-pulse 3s ease-in-out infinite;
}

.landing-ref .dash-calendar {
  position: relative;
}

.landing-ref .hero-motion-live .dash-calendar::after {
  content: '';
  position: absolute;
  z-index: 3;
  top: 50%;
  left: 0;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(242, 199, 184, 0.42), transparent);
  opacity: 0;
  pointer-events: none;
  will-change: transform, opacity;
  animation: hero-calendar-scan 12s ease-in-out 3.5s infinite;
}

@keyframes hero-halo-breathe {
  0%, 100% {
    opacity: 0.45;
    transform: translate3d(var(--halo-x, 0px), var(--halo-y, 0px), 0) scale(1);
  }
  50% {
    opacity: 0.6;
    transform: translate3d(var(--halo-x, 0px), var(--halo-y, 0px), 0) scale(1.05);
  }
}

@keyframes hero-dashboard-drift {
  0%, 100% {
    transform: translate3d(var(--dash-x, 0px), var(--dash-y, 0px), 0) rotateY(-2.5deg) rotateX(1deg);
  }
  50% {
    transform: translate3d(var(--dash-x, 0px), calc(var(--dash-y, 0px) - 3px), 0) rotateY(-2.5deg) rotateX(1deg);
  }
}

@keyframes hero-float-one {
  0%, 100% {
    transform: translate3d(var(--float-one-x, 0px), calc(var(--float-one-y, 0px) - 6px), 0);
  }
  50% {
    transform: translate3d(calc(var(--float-one-x, 0px) + 3px), calc(var(--float-one-y, 0px) + 6px), 0);
  }
}

@keyframes hero-float-two {
  0%, 100% {
    transform: translate3d(var(--float-two-x, 0px), calc(var(--float-two-y, 0px) + 5px), 0);
  }
  50% {
    transform: translate3d(calc(var(--float-two-x, 0px) - 2px), calc(var(--float-two-y, 0px) - 5px), 0);
  }
}

@keyframes hero-automation-pulse {
  0%, 72%, 100% { opacity: 0.72; transform: scale(1); }
  82% { opacity: 1; transform: scale(1.09); }
  91% { opacity: 0.82; transform: scale(1.025); }
}

@keyframes hero-calendar-scan {
  0%, 55% { opacity: 0; transform: translate3d(-108%, 0, 0); }
  59% { opacity: 0.18; }
  70% { opacity: 0.18; transform: translate3d(108%, 0, 0); }
  74%, 100% { opacity: 0; transform: translate3d(108%, 0, 0); }
}

/* Premium hover feedback. */
@media (hover: hover) and (pointer: fine) {
  .landing-ref .hero__actions .btn-rose:hover,
  .landing-ref .hero__actions .btn-outline-light:hover {
    transform: translateY(-1px) scale(1.03);
    transition-duration: 220ms;
  }

  .landing-ref .hero__actions .btn-rose:hover {
    box-shadow: 0 18px 39px rgba(184, 124, 106, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.52);
  }

  .landing-ref .hero__actions .btn-outline-light:hover {
    box-shadow: 0 12px 27px rgba(0, 0, 0, 0.2);
  }

  .landing-ref .hero__chip-icon {
    transform-origin: center;
    transition: transform 220ms ease;
  }

  .landing-ref .hero__chip:hover {
    transform: translate3d(0, -4px, 0);
    border-color: rgba(214, 161, 143, 0.3);
    background: rgba(255, 255, 255, 0.045);
  }

  .landing-ref .hero__chip:hover .hero__chip-icon {
    transform: rotate(4deg);
  }

  .landing-ref .header-cta .btn-rose:hover {
    transform: translateY(-1px) scale(1.02);
    box-shadow: 0 16px 36px rgba(184, 124, 106, 0.38), inset 0 1px 8px rgba(255, 255, 255, 0.18);
    transition-duration: 220ms;
  }
}

.landing-ref .site-nav a {
  position: relative;
}

.landing-ref .site-nav a::after {
  content: '';
  position: absolute;
  right: 10px;
  bottom: 4px;
  left: 10px;
  height: 1px;
  background: currentColor;
  opacity: 0.76;
  pointer-events: none;
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 200ms ease;
}

.landing-ref .site-nav a:hover::after,
.landing-ref .site-nav a:focus-visible::after {
  transform: scaleX(1);
}

@media (max-width: 720px) {
  .hero-motion-enabled .landing-ref .hero:not(.hero-motion-visible) .hero__visual {
    transform: translate3d(0, 18px, 0);
  }

  .landing-ref .hero-motion-live .hero__mockup {
    animation-name: hero-dashboard-drift-mobile;
  }

  @keyframes hero-dashboard-drift-mobile {
    0%, 100% { transform: translate3d(0, 0, 0); }
    50% { transform: translate3d(0, -1.5px, 0); }
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-motion-enabled .landing-ref .hero *,
  .landing-ref .hero .dash-calendar::after {
    animation: none !important;
    transition: none !important;
  }

  .hero-motion-enabled .landing-ref .hero .hero__badge,
  .hero-motion-enabled .landing-ref .hero .hero__title,
  .hero-motion-enabled .landing-ref .hero .hero__subtitle,
  .hero-motion-enabled .landing-ref .hero .hero__chip,
  .hero-motion-enabled .landing-ref .hero .hero__actions,
  .hero-motion-enabled .landing-ref .hero .hero__micro,
  .hero-motion-enabled .landing-ref .hero .hero__visual,
  .hero-motion-enabled .landing-ref .hero .hero__float {
    opacity: 1 !important;
    transform: none !important;
  }
}
