/* =========================================================
   SAMIFY — Decorative butterfly + music-note trail
   Isolated, self-contained overlay effect.
   Story -> Emotion -> Music
   Safe to delete this file + butterfly-fx.js + their two
   <link>/<script> tags to remove the effect completely.
   ========================================================= */

#samify-fx-layer{
  position:fixed;
  inset:0;
  pointer-events:none;
  z-index:-1; /* sits behind ALL in-flow page content, above the body background */
  overflow:hidden;
  contain:layout style size;
}

.samify-fx-butterfly{
  position:absolute;
  top:0;
  left:0;
  opacity:0;
  will-change:transform, opacity;
  transition:opacity 2.2s ease;
}

.samify-fx-butterfly svg{
  display:block;
  overflow:visible;
}

.samify-fx-wing{
  transform-box:fill-box;
  transform-origin:100% 50%;
  animation:samify-fx-flap 1.65s ease-in-out infinite;
}

.samify-fx-wing--l{transform-origin:100% 50%;}
.samify-fx-wing--r{transform-origin:0% 50%;}

@keyframes samify-fx-flap{
  0%, 100%{ transform:scaleX(1); }
  50%{ transform:scaleX(0.88); }
}

.samify-fx-note{
  position:absolute;
  top:0;
  left:0;
  font-family:Georgia, 'Times New Roman', serif;
  line-height:1;
  color:var(--ember, #C4622D);
  opacity:0;
  will-change:transform, opacity;
  user-select:none;
}

/* Lighter footprint on small screens: smaller glyphs, softer presence */
@media (max-width:640px){
  .samify-fx-note{ font-size:13px !important; }
}

/* Respect reduced-motion preference: effect is fully disabled */
@media (prefers-reduced-motion: reduce){
  #samify-fx-layer{
    display:none !important;
  }
}
