#hfx-stage{position:fixed;inset:0;overflow:hidden;pointer-events:none;z-index:99999}
#hfx-stage .hfx-item{position:absolute;will-change:transform;user-select:none}
#hfx-stage svg{display:block;width:100%;height:100%}

/* Ghost: float upward + sway */
.hfx-ghost{bottom:-120px;animation:hfx-float linear infinite}
.hfx-ghost .hfx-inner{animation:hfx-sway ease-in-out infinite alternate}
@keyframes hfx-float{
  0%{transform:translateY(0);opacity:0}
  10%{opacity:var(--o,.85)}
  90%{opacity:var(--o,.85)}
  100%{transform:translateY(calc(-100vh - 240px));opacity:0}
}
@keyframes hfx-sway{
  from{transform:translateX(-12px) rotate(-5deg)}
  to{transform:translateX(12px) rotate(5deg)}
}

/* Pumpkin: fall + spin */
.hfx-pumpkin{top:-100px;animation:hfx-fall linear infinite}
.hfx-pumpkin .hfx-inner{animation:hfx-spin linear infinite}
@keyframes hfx-fall{
  0%{transform:translateY(0);opacity:0}
  8%{opacity:var(--o,.85)}
  92%{opacity:var(--o,.85)}
  100%{transform:translateY(calc(100vh + 200px));opacity:0}
}
@keyframes hfx-spin{
  from{transform:rotate(-25deg)}
  50%{transform:rotate(25deg)}
  to{transform:rotate(-25deg)}
}

/* Bat: fly across with flapping */
.hfx-bat{left:-80px;animation:hfx-fly linear infinite}
.hfx-bat .hfx-inner{animation:hfx-flap .35s ease-in-out infinite alternate}
@keyframes hfx-fly{
  0%{transform:translate(0,0)}
  25%{transform:translate(30vw,-40px)}
  50%{transform:translate(60vw,30px)}
  75%{transform:translate(90vw,-30px)}
  100%{transform:translate(calc(100vw + 160px),10px)}
}
@keyframes hfx-flap{from{transform:scaleY(1)}to{transform:scaleY(.55)}}

/* Corner jack-o'-lantern */
.hfx-corner{left:10px;bottom:6px;width:56px;height:56px;animation:hfx-glow 2.2s ease-in-out infinite alternate}
@keyframes hfx-glow{
  from{filter:drop-shadow(0 0 6px #ff8a00) brightness(.95)}
  to{filter:drop-shadow(0 0 12px #ffb300) brightness(1.15)}
}

@media (prefers-reduced-motion:reduce){
  #hfx-stage{display:none}
}
