/* noXcuses V0.8 coach scenes
   Every selector is scoped away from the locked top Home demo. */

@keyframes v8CoachFloat {
  0%, 100% { transform: translate3d(0, 0, 0); }
  48% { transform: translate3d(0, -8px, 0); }
}

@keyframes v8CoachFloatReverse {
  0%, 100% { transform: translate3d(0, -3px, 0); }
  52% { transform: translate3d(0, 7px, 0); }
}

@keyframes noxLiveCoachPhoneFloat {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-6px);
  }
}

@keyframes noxLiveCoachPhoneFloatMobile {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-4px);
  }
}

@keyframes v8DuoOrbit {
  0% { transform: translate(-50%, -50%) rotate(0deg) scale(.96); opacity: .28; }
  50% { opacity: .52; }
  100% { transform: translate(-50%, -50%) rotate(360deg) scale(1.04); opacity: .28; }
}

@keyframes v8BrandBreathe {
  0%, 100% {
    opacity: .12;
    transform: translate(-50%, -50%) rotate(-5deg) scale(.97);
    filter: drop-shadow(0 0 18px rgba(255, 55, 58, .13));
  }
  50% {
    opacity: .19;
    transform: translate(-50%, -50%) rotate(-3deg) scale(1.015);
    filter: drop-shadow(0 0 34px rgba(255, 65, 52, .22));
  }
}

/* Feature card: one purpose-built training scene instead of duplicated poses. */
body[data-page="home"] .v3-avatar-feature .v8-duo-scene {
  isolation: isolate;
  height: 410px;
  margin-top: -20px;
}

body[data-page="home"] .v3-avatar-feature .v8-duo-scene::before,
body[data-page="home"] .v3-avatar-feature .v8-duo-scene::after {
  content: "";
  position: absolute;
  z-index: 0;
  left: 50%;
  top: 58%;
  width: 82%;
  aspect-ratio: 1.85 / 1;
  translate: -50% -50%;
  border: 1px solid rgba(255, 94, 67, .18);
  border-radius: 50%;
  box-shadow: 0 0 48px rgba(255, 55, 58, .08);
}

body[data-page="home"] .v3-avatar-feature .v8-duo-scene::after {
  width: 58%;
  border-color: rgba(255, 137, 86, .11);
}

body[data-page="home"] .v3-avatar-feature .v8-duo-orbit {
  position: absolute;
  z-index: 1;
  left: 50%;
  top: 57%;
  transform: translate(-50%, -50%);
  width: 72%;
  aspect-ratio: 1.7 / 1;
  border: 1px dashed rgba(255, 96, 70, .2);
  border-radius: 50%;
  animation: v8DuoOrbit 18s linear infinite;
}

body[data-page="home"] .v3-avatar-feature .v8-duo-scene > .v8-duo-training {
  position: absolute !important;
  z-index: 2;
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: contain;
  object-position: center bottom;
  filter: drop-shadow(0 24px 20px rgba(0, 0, 0, .58));
  animation: v8CoachFloat 8.4s ease-in-out -2.6s infinite !important;
}

/* Live Coach: the poses now interact with the product instead of mirroring. */
body[data-page="home"] .v3-coach-stage .v8-livecoach-man {
  z-index: 2;
  left: -54px;
  bottom: 28px;
  width: 318px;
  height: 620px;
  object-position: center bottom;
  animation: none !important;
  translate: none !important;
  transition: none !important;
}

body[data-page="home"] .v3-coach-stage .v8-livecoach-woman {
  z-index: 4;
  right: -58px;
  bottom: 6px;
  width: 350px;
  height: 535px;
  object-position: center bottom;
  animation: none !important;
  translate: none !important;
  transition: none !important;
}

body[data-page="home"] .v3-coach-stage.reveal.is-visible .v7-coach-device .phone-shell {
  animation: noxLiveCoachPhoneFloat 7.2s ease-in-out infinite;
  transform-origin: center center;
  will-change: transform;
}

/* Inner pages get distinct scale and visual weight for their role. */
body[data-page="features"] .v8-profile-guide {
  left: -58px;
  bottom: 4px;
  width: 372px;
  height: 600px;
  object-position: center bottom;
  animation: none !important;
}

body[data-page="pricing"] .v3-price-visual .v8-price-presenter {
  z-index: 4;
  right: -64px;
  bottom: -2px;
  width: 382px;
  height: 606px;
  object-position: center bottom;
  animation: v8CoachFloatReverse 9.2s ease-in-out -4s infinite;
}

body[data-page="pricing"] .v3-price-visual {
  isolation: isolate;
}

body[data-page="pricing"] .v3-price-visual .v3-inner-phone {
  z-index: 3;
  left: clamp(58px, 7.5vw, 96px);
  right: auto;
}

body[data-page="about"] .v3-about-stage > .v8-brand-presenter {
  z-index: 3;
  right: -16px;
  bottom: 0;
  width: 410px;
  height: 608px;
  object-position: center bottom;
  animation: v8CoachFloat 10s ease-in-out -5s infinite;
}

/* The brand mark is scenery, not a card: it sits behind the coach as a soft watermark. */
body[data-page="about"] .v3-about-stage {
  isolation: isolate;
}

body[data-page="about"] .v3-about-stage .v3-about-brand {
  z-index: 1;
  left: 49%;
  top: 50%;
  transform: translate(-50%, -50%) rotate(-4deg);
  width: min(520px, 76%);
  min-height: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  pointer-events: none;
  animation: v8BrandBreathe 9.5s ease-in-out -3s infinite;
}

body[data-page="about"] .v3-about-stage .v3-about-brand img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  mix-blend-mode: screen;
}

body[data-page="about"] .v3-about-stage .v3-about-brand span {
  display: none;
}

@media (max-width: 1050px) {
  body[data-page="features"] .v8-profile-guide {
    left: -18px;
    width: min(56vw, 340px);
  }

  body[data-page="pricing"] .v3-price-visual .v8-price-presenter {
    right: -12px;
    width: min(58vw, 360px);
  }

  body[data-page="pricing"] .v3-price-visual .v3-inner-phone {
    left: 8%;
  }

  body[data-page="about"] .v3-about-stage > .v8-brand-presenter {
    right: 0;
    width: min(62vw, 382px);
  }

  body[data-page="about"] .v3-about-stage .v3-about-brand {
    left: 52%;
    width: min(500px, 82%);
  }
}

@media (max-width: 820px) {
  body[data-page="home"] .v3-coach-stage .v8-livecoach-man {
    left: -3vw;
    width: min(44vw, 280px);
    height: 550px;
  }

  body[data-page="home"] .v3-coach-stage .v8-livecoach-woman {
    right: -3vw;
    width: min(47vw, 306px);
    height: 490px;
  }
}

@media (max-width: 560px) {
  body[data-page="home"] .v3-avatar-feature .v8-duo-scene {
    height: 304px;
    margin: -8px 0 14px;
  }

  body[data-page="home"] .v3-avatar-feature .v8-duo-scene::before {
    width: 94%;
  }

  body[data-page="home"] .v3-avatar-feature .v8-duo-orbit {
    width: 82%;
  }

  body[data-page="home"] .v3-coach-stage .v8-livecoach-man {
    left: -7vw;
    bottom: 42px;
    width: 48vw;
    height: 420px;
  }

  body[data-page="home"] .v3-coach-stage .v8-livecoach-woman {
    right: 1vw;
    bottom: 38px;
    width: 50vw;
    height: 360px;
  }

  body[data-page="home"] .v3-coach-stage.reveal.is-visible .v7-coach-device .phone-shell {
    animation-name: noxLiveCoachPhoneFloatMobile;
  }

  body[data-page="features"] .v8-profile-guide {
    left: -4vw;
    bottom: 4px;
    width: 52vw;
    height: 445px;
  }

  body[data-page="pricing"] .v3-price-visual .v8-price-presenter {
    right: -3vw;
    bottom: 0;
    width: 52vw;
    height: 450px;
  }

  body[data-page="pricing"] .v3-price-visual .v3-inner-phone {
    left: 11vw;
  }

  body[data-page="about"] .v3-about-stage > .v8-brand-presenter {
    right: -2vw;
    width: 58vw;
    height: 470px;
  }

  body[data-page="about"] .v3-about-stage .v3-about-brand {
    left: 54%;
    top: 52%;
    width: 92vw;
  }
}

@media (prefers-reduced-motion: reduce) {
  body[data-page="home"] .v3-avatar-feature .v8-duo-orbit,
  body[data-page="home"] .v3-avatar-feature .v8-duo-training,
  body[data-page="home"] .v3-coach-stage .v8-livecoach-man,
  body[data-page="home"] .v3-coach-stage .v8-livecoach-woman,
  body[data-page="features"] .v8-profile-guide,
  body[data-page="pricing"] .v8-price-presenter,
  body[data-page="about"] .v8-brand-presenter,
  body[data-page="about"] .v3-about-brand {
    animation: none !important;
  }

  body[data-page="home"] .v3-coach-stage .v7-coach-device .phone-shell {
    animation: none !important;
    transform: none !important;
  }

  body[data-page="home"] .v3-coach-stage .v8-livecoach-man,
  body[data-page="home"] .v3-coach-stage .v8-livecoach-woman {
    animation: none !important;
    translate: none !important;
  }
}
