/* CRAV’D: quiet motion layered after coming-soon.css. Keep the real logo intact.
   The outer logo-drop / stamp-impact elements still own their arrival animations. */
.logo-drop {
  isolation: isolate;
}

.launch-logo {
  position: relative;
  z-index: 1;
  transform-origin: 50% 65%;
  animation: launch-logo-float 6.8s ease-in-out infinite both;
}

/* Visible outer wisps sit above the image's opaque yellow padding. The two
   gradient masks leave the central wordmark clear; original image pixels stay intact. */
.logo-smoke {
  position: absolute;
  inset: -18% -6% -12%;
  z-index: 2;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(to right, #000 4%, transparent 20%, transparent 80%, #000 96%), linear-gradient(to bottom, #000 3%, transparent 27%, transparent 77%, #000 97%);
  mask-image: linear-gradient(to right, #000 4%, transparent 20%, transparent 80%, #000 96%), linear-gradient(to bottom, #000 3%, transparent 27%, transparent 77%, #000 97%);
}

.logo-smoke > i {
  position: absolute;
  top: 8%;
  left: -4%;
  width: 40%;
  height: 95%;
  border-radius: 50%;
  background:
    radial-gradient(ellipse at 38% 54%, rgba(80, 44, 29, .56), rgba(126, 83, 58, .32) 36%, transparent 74%),
    radial-gradient(ellipse at 65% 38%, rgba(255, 242, 220, .70), rgba(151, 112, 76, .28) 40%, transparent 72%);
  filter: blur(clamp(6px, 1vw, 12px));
  opacity: .22;
  --smoke-shift-x: -18px;
  --smoke-rise: -32px;
  animation: launch-smoke-drift 7.8s ease-in-out -.8s infinite both;
}

.logo-smoke > i:nth-child(2) {
  top: -18%;
  left: 31%;
  width: 38%;
  --smoke-shift-x: 16px;
  --smoke-rise: -42px;
  animation-duration: 9.2s;
  animation-delay: -3.1s;
}

.logo-smoke > i:nth-child(3) {
  top: 10%;
  left: 66%;
  width: 38%;
  --smoke-shift-x: 22px;
  --smoke-rise: -28px;
  animation-duration: 8.6s;
  animation-delay: -5.2s;
}

.launch-stamp {
  transform-origin: 50% 55%;
  animation: launch-stamp-breathe 7.6s ease-in-out infinite both;
}

/* Only an active intro adds landing delays. Without JS, content remains visible.
   Distinct animation names reset the idle effects on each explicit intro replay. */
.intro-is-playing .launch-logo {
  animation-name: launch-logo-float-after-arrival;
  animation-delay: 1.05s;
}

.intro-is-playing .logo-smoke > i {
  animation-name: launch-smoke-drift-after-arrival;
  animation-delay: 1.05s;
}

.intro-is-playing .logo-smoke > i:nth-child(2) {
  animation-delay: 1.45s;
}

.intro-is-playing .logo-smoke > i:nth-child(3) {
  animation-delay: 1.8s;
}

.intro-is-playing .launch-stamp {
  animation-name: launch-stamp-breathe-after-arrival;
  animation-delay: 1.55s;
}

@keyframes launch-logo-float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  35% { transform: translateY(-5px) rotate(.35deg); }
  70% { transform: translateY(2px) rotate(-.25deg); }
}

@keyframes launch-logo-float-after-arrival {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  35% { transform: translateY(-5px) rotate(.35deg); }
  70% { transform: translateY(2px) rotate(-.25deg); }
}

@keyframes launch-smoke-drift {
  0%, 100% { opacity: .22; transform: translate3d(0, 8px, 0) scale(.94); }
  28% { opacity: .72; }
  55% { opacity: .88; transform: translate3d(var(--smoke-shift-x), var(--smoke-rise), 0) scale(1.14); }
  82% { opacity: .48; }
}

@keyframes launch-smoke-drift-after-arrival {
  0%, 100% { opacity: .22; transform: translate3d(0, 8px, 0) scale(.94); }
  28% { opacity: .72; }
  55% { opacity: .88; transform: translate3d(var(--smoke-shift-x), var(--smoke-rise), 0) scale(1.14); }
  82% { opacity: .48; }
}

@keyframes launch-stamp-breathe {
  0%, 100% { transform: rotate(-5deg) scale(1); }
  40% { transform: rotate(-4.4deg) scale(1.012); }
  75% { transform: rotate(-5.4deg) scale(.997); }
}

@keyframes launch-stamp-breathe-after-arrival {
  0%, 100% { transform: rotate(-5deg) scale(1); }
  40% { transform: rotate(-4.4deg) scale(1.012); }
  75% { transform: rotate(-5.4deg) scale(.997); }
}

/* Freeze current frames, including a paused arrival's pending effect delays. */
.motion-is-paused .launch-logo,
.motion-is-paused .logo-smoke > i,
.motion-is-paused .launch-stamp {
  animation-play-state: paused;
}

/* Parent motion controls may explicitly opt back in with “Play motion”. */
@media (prefers-reduced-motion: reduce) {
  body:not(.motion-is-enabled) .launch-logo,
  body:not(.motion-is-enabled) .logo-smoke > i,
  body:not(.motion-is-enabled) .launch-stamp {
    animation: none !important;
  }

  body:not(.motion-is-enabled) .launch-logo {
    transform: none;
  }

  body:not(.motion-is-enabled) .logo-smoke > i {
    opacity: .5;
    transform: none;
  }

  body:not(.motion-is-enabled) .launch-stamp {
    transform: rotate(-5deg);
  }
}

.logo-drop {
  /* Change this if your transparent logo has a different filename. */
  --burn-logo: url("assets/coming-soon/clean-logo.png");
  isolation: isolate;
  overflow: visible;
}

/* Remove the old boxed smoke. */
.logo-smoke {
  display: none !important;
}

/* Keep the existing logo movement; add an edge glow. */
.launch-logo {
  position: relative;
  z-index: 2;
  filter:
    drop-shadow(0 0 2px #fff2b0)
    drop-shadow(0 -3px 6px #ff8b22);
}

.logo-drop::before,
.logo-drop::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: var(--burn-logo) center / contain no-repeat;
  transform-origin: 50% 70%;
}

/* Smoke follows the transparent logo—not its rectangle. */
.logo-drop::before {
  z-index: 0;
  opacity: 0;
  filter: brightness(0) blur(10px);
  animation: cravd-smoke-rise 5.5s linear infinite;
}

/* Flickering hot edge behind the original logo. */
.logo-drop::after {
  z-index: 1;
  filter:
    brightness(0) invert(1) sepia(1) saturate(8)
    blur(2px) drop-shadow(0 -3px 5px #ff641a);
  animation: cravd-edge-flare 1.3s ease-in-out infinite alternate;
}

/* Start after the logo lands. */
.intro-is-playing .logo-drop::before,
.intro-is-playing .logo-drop::after {
  animation-delay: 1.05s;
}

@keyframes cravd-smoke-rise {
  0% {
    opacity: 0;
    transform: translateY(0) scale(1);
    filter: brightness(0) blur(10px);
  }
  20% {
    opacity: .35;
  }
  65% {
    opacity: .24;
    transform: translateY(-42px) scale(1.04);
    filter: brightness(0) blur(17px);
  }
  100% {
    opacity: 0;
    transform: translateY(-85px) scale(1.08);
    filter: brightness(0) blur(25px);
  }
}

@keyframes cravd-edge-flare {
  0% {
    opacity: .55;
    transform: translateY(-1px) scale(1.002);
  }
  45% {
    opacity: .95;
    transform: translateY(-4px) scale(1.006);
  }
  100% {
    opacity: .7;
    transform: translateY(-2px) scale(1.003);
  }
}

/* Preserve your Pause button. */
.motion-is-paused .logo-drop::before,
.motion-is-paused .logo-drop::after {
  animation-play-state: paused;
}

@media (prefers-reduced-motion: reduce) {
  body:not(.motion-is-enabled) .logo-drop::before,
  body:not(.motion-is-enabled) .logo-drop::after {
    animation: none !important;
    opacity: 0;
  }
}

