/* ============================================================
   NEXORA FX LAYER — futuristic transitions & animations
   Everything is scoped under .fx (added by fx.js only when the
   visitor has NOT asked for reduced motion).
   ============================================================ */

@property --fx-ang{syntax:'<angle>';inherits:false;initial-value:0deg}
@keyframes fxAng{to{--fx-ang:360deg}}

/* ---------- 1. CINEMATIC BOOT SEQUENCE + IRIS TRANSITION ---------- */
.fx #preloader{
  clip-path:circle(150% at 50% 50%);
  transition:clip-path 1.1s cubic-bezier(.76,0,.24,1),visibility 0s 1.1s;
  overflow:hidden;
}
.fx #preloader.done{opacity:1;visibility:hidden;clip-path:circle(0% at 50% 50%);pointer-events:none}
.fx #preloader:after{
  content:"";position:absolute;inset:0;pointer-events:none;
  background:repeating-linear-gradient(0deg,rgba(25,230,193,.05) 0 1px,transparent 1px 4px);
}
.fx #preloader:before{
  content:"";position:absolute;left:0;right:0;top:0;height:140px;pointer-events:none;
  background:linear-gradient(180deg,transparent,rgba(25,230,193,.16),transparent);
  animation:fxPreScan 2.2s linear infinite;
}
@keyframes fxPreScan{from{transform:translateY(-140px)}to{transform:translateY(100vh)}}
.fx-pct{
  font:700 clamp(34px,6vw,54px)/1 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;
  letter-spacing:.12em;
  background:var(--grad2);background-size:300% auto;-webkit-background-clip:text;background-clip:text;color:transparent;
  animation:gradShift 3s linear infinite;
  text-shadow:0 0 30px rgba(25,230,193,.4);
}
.fx-corner{position:absolute;width:44px;height:44px;border:0 solid var(--teal);opacity:.8;pointer-events:none;filter:drop-shadow(0 0 6px var(--teal))}
.fx-corner.tl{top:28px;left:28px;border-top-width:2px;border-left-width:2px}
.fx-corner.tr{top:28px;right:28px;border-top-width:2px;border-right-width:2px}
.fx-corner.bl{bottom:28px;left:28px;border-bottom-width:2px;border-left-width:2px}
.fx-corner.br{bottom:28px;right:28px;border-bottom-width:2px;border-right-width:2px}
.fx #preloader .load-txt{font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;color:var(--teal)}

/* ---------- 2. HERO HEADLINE — 3D CHARACTER FLIP-IN + GLITCH ---------- */
.fx .hero h1 .line{perspective:800px}
.fx-w{display:inline-block;white-space:nowrap}
.fx .ch{display:inline-block;opacity:0;transform-origin:50% 100%}
.fx-go .ch{will-change:transform,opacity}
.fx-go .ch.ch-done{will-change:auto}
.fx-go .ch{animation:fxChIn .95s var(--ease) both;animation-delay:calc(var(--i)*40ms + 140ms)}
@keyframes fxChIn{
  from{opacity:0;transform:translateY(70%) rotateX(-110deg) scale(.6);filter:blur(10px)}
  60%{filter:blur(0)}
  to{opacity:1;transform:none;filter:none}
}
.fx-go .hero h1 .line:not(.typed-wrap){animation:fxGlitch 8s steps(1,end) 4.2s infinite}
@keyframes fxGlitch{
  0%,91%,100%{text-shadow:none;transform:none}
  92%{text-shadow:-3px 0 #ff4fd8,3px 0 #19e6c1;transform:translateX(3px) skewX(-5deg)}
  94%{text-shadow:3px 0 #22c9ff,-3px 0 #ff4fd8;transform:translateX(-4px)}
  96%{text-shadow:-2px 0 #19e6c1,2px 0 #7a5cff;transform:skewX(4deg)}
  98%{text-shadow:none;transform:translateX(1px)}
}

/* ---------- 3. SCROLL REVEALS — blur + 3D swing (animation based so
   the original hover / tilt transforms keep working afterwards) ---------- */
.fx .reveal.in{animation:fxRise 1.2s var(--ease) backwards}
.fx .reveal-l.in{animation:fxLeft 1.2s var(--ease) backwards}
.fx .reveal-r.in{animation:fxRight 1.2s var(--ease) backwards}
.fx .reveal-scale.in{animation:fxPop 1.2s var(--ease) backwards}
.fx [data-delay="1"].in{animation-delay:.1s}
.fx [data-delay="2"].in{animation-delay:.22s}
.fx [data-delay="3"].in{animation-delay:.34s}
.fx [data-delay="4"].in{animation-delay:.46s}
.fx [data-delay="5"].in{animation-delay:.58s}
.fx [data-delay="6"].in{animation-delay:.7s}
@keyframes fxRise{from{opacity:0;filter:blur(16px);transform:perspective(1200px) translateY(80px) rotateX(-16deg) scale(.94)}}
@keyframes fxLeft{from{opacity:0;filter:blur(14px);transform:perspective(1200px) translateX(-140px) rotateY(22deg) scale(.95)}}
@keyframes fxRight{from{opacity:0;filter:blur(14px);transform:perspective(1200px) translateX(140px) rotateY(-22deg) scale(.95)}}
@keyframes fxPop{from{opacity:0;filter:blur(18px);transform:perspective(1200px) scale(.7) rotateX(14deg)}}

/* ---------- 4. SECTION ENERGY SCAN LINE ---------- */
.fx-scan{
  contain:strict;position:absolute;left:0;top:0;width:100%;height:2px;pointer-events:none;z-index:3;opacity:0;
  background:linear-gradient(90deg,transparent,var(--teal),var(--cyan),transparent);
  box-shadow:0 0 24px 3px rgba(25,230,193,.55);
}
.fx-in>.fx-scan{animation:fxScan 1.5s var(--ease) both}
@keyframes fxScan{
  0%{transform:translateX(-100%) scaleX(.25);opacity:0}
  15%{opacity:1}
  100%{transform:translateX(100%) scaleX(.25);opacity:0}
}

/* ---------- 5. HERO — RADAR + MOUSE-DRIVEN DEPTH PARALLAX ---------- */
.fx-radar{
  position:absolute;left:50%;top:50%;width:520px;height:520px;margin:-260px 0 0 -260px;border-radius:50%;pointer-events:none;
  background:conic-gradient(from 0deg,rgba(25,230,193,0) 0deg,rgba(25,230,193,.30) 52deg,rgba(25,230,193,0) 53deg,transparent 360deg);
  -webkit-mask:radial-gradient(circle,transparent 24%,#000 25%);mask:radial-gradient(circle,transparent 24%,#000 25%);
  animation:spin 6s linear infinite;
}
.fx-radar:before{
  content:"";position:absolute;inset:0;border-radius:50%;
  background:
    linear-gradient(90deg,transparent calc(50% - .5px),rgba(34,201,255,.3) 50%,transparent calc(50% + .5px)),
    linear-gradient(0deg,transparent calc(50% - .5px),rgba(34,201,255,.3) 50%,transparent calc(50% + .5px));
}
.fx .hero-visual .hero-logo{translate:calc(var(--px,0)*26px) calc(var(--py,0)*26px)}
.fx .hero-visual .orbit.o1{translate:calc(var(--px,0)*-10px) calc(var(--py,0)*-10px)}
.fx .hero-visual .orbit.o2{translate:calc(var(--px,0)*14px) calc(var(--py,0)*14px)}
.fx .hero-visual .orbit.o3{translate:calc(var(--px,0)*-22px) calc(var(--py,0)*-22px)}
.fx .hero-visual .hero-glow{translate:calc(var(--px,0)*-36px) calc(var(--py,0)*-36px)}
.fx .hero-visual .fc1{translate:calc(var(--px,0)*52px) calc(var(--py,0)*40px)}
.fx .hero-visual .fc2{translate:calc(var(--px,0)*-44px) calc(var(--py,0)*48px)}
.fx .hero-visual .fc3{translate:calc(var(--px,0)*38px) calc(var(--py,0)*-46px)}

/* ---------- 6. NEON SPOTLIGHT BORDERS ON CARDS ---------- */
.fx-card{--fx-x:50%;--fx-y:50%}
.fx-ring{
  position:absolute;inset:0;border-radius:inherit;padding:1.5px;pointer-events:none;z-index:4;opacity:0;transition:opacity .35s;
  background:radial-gradient(340px circle at var(--fx-x) var(--fx-y),#22c9ff,rgba(25,230,193,.65) 35%,transparent 70%);
  -webkit-mask:linear-gradient(#000 0 0) content-box,linear-gradient(#000 0 0);
  -webkit-mask-composite:xor;mask-composite:exclude;
}
.fx-card:hover>.fx-ring{opacity:1}
.price-box>.fx-ring{
  opacity:1;padding:2px;
  background:conic-gradient(from var(--fx-ang),transparent 0 50%,#19e6c1,#22c9ff,#7a5cff,#ff4fd8,transparent 96%);
  animation:fxAng 6s linear infinite;
}

/* ---------- 7. CURSOR COMET TRAIL + CLICK SHOCKWAVE ---------- */
.fx-trail{position:fixed;inset:0;width:100%;height:100%;pointer-events:none;z-index:9997}
.fx-shock{
  position:fixed;width:12px;height:12px;margin:-6px 0 0 -6px;border-radius:50%;pointer-events:none;z-index:9996;
  border:2px solid var(--cyan);box-shadow:0 0 24px var(--cyan),inset 0 0 14px rgba(25,230,193,.6);
  animation:fxShock .8s cubic-bezier(.15,.7,.3,1) forwards;
}
.fx-shock.s2{border-color:var(--teal);animation-delay:.1s;opacity:0;animation-fill-mode:both}
@keyframes fxShock{from{transform:scale(1);opacity:.95}to{transform:scale(16);opacity:0}}

/* ---------- 8. PAGE-WIPE TRANSITION (section jumps) ---------- */
.fx-wipe{position:fixed;inset:0;z-index:9990;visibility:hidden;pointer-events:none;overflow:hidden}
.fx-wipe.in,.fx-wipe.out{visibility:visible}
.fx-wipe.in{pointer-events:auto}
.fx-strip{
  position:absolute;top:0;bottom:0;left:calc(var(--k)*100%/7);width:calc(100%/7 + 1px);
  transform:scaleY(0);transform-origin:top;
  background:
    repeating-linear-gradient(0deg,rgba(25,230,193,.07) 0 1px,transparent 1px 5px),
    linear-gradient(180deg,#02101c,#041a3a 60%,#0a1e5c);
  border-right:1px solid rgba(25,230,193,.35);
  box-shadow:0 0 40px rgba(25,230,193,.25);
  transition:transform .6s cubic-bezier(.77,0,.18,1) calc(var(--k)*45ms);
}
.fx-strip:after{
  content:"";position:absolute;left:0;right:0;bottom:0;height:3px;
  background:linear-gradient(90deg,var(--teal),var(--cyan));box-shadow:0 0 26px 4px var(--teal);
}
.fx-wipe.out .fx-strip:after{bottom:auto;top:0}
.fx-wipe.in .fx-strip{transform:scaleY(1);transform-origin:top}
.fx-wipe.out .fx-strip{transform:scaleY(0);transform-origin:bottom}
.fx-wlbl{
  position:absolute;left:50%;top:50%;transform:translate(-50%,-50%) scale(.9);opacity:0;
  font:800 clamp(22px,5vw,58px)/1 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;letter-spacing:.2em;text-transform:uppercase;white-space:nowrap;
  background:var(--grad2);background-size:300% auto;-webkit-background-clip:text;background-clip:text;color:transparent;
  filter:drop-shadow(0 0 24px rgba(25,230,193,.6));
  transition:opacity .3s,transform .5s var(--ease);
}
.fx-wipe.in .fx-wlbl{opacity:1;transform:translate(-50%,-50%) scale(1);transition-delay:.35s}

/* ---------- 9. SIDE HUD SECTION NAVIGATOR ---------- */
.fx-hud{position:fixed;right:14px;top:50%;transform:translateY(-50%);z-index:900;display:flex;flex-direction:column;gap:6px;opacity:0;transition:opacity .6s .4s}
.fx-go .fx-hud{opacity:1}
.fx-hud a{position:relative;display:block;width:20px;height:20px}
.fx-hud a i{position:absolute;inset:7px;border-radius:50%;background:rgba(255,255,255,.3);transition:all .35s var(--ease)}
.fx-hud a:hover i{background:var(--cyan)}
.fx-hud a.on i{inset:3px;background:var(--teal);box-shadow:0 0 14px var(--teal),0 0 0 5px rgba(25,230,193,.16)}
.fx-hud a:after{
  content:attr(data-l);position:absolute;right:30px;top:50%;transform:translate(12px,-50%);
  font:700 11px ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;letter-spacing:.2em;text-transform:uppercase;color:#fff;
  background:#000000d9;border:1px solid var(--border);padding:6px 11px;border-radius:8px;white-space:nowrap;
  opacity:0;pointer-events:none;transition:all .3s var(--ease);
}
.fx-hud a:hover:after{opacity:1;transform:translate(0,-50%)}
@media(max-width:1100px),(hover:none){.fx-hud{display:none}}

/* ---------- 10. AMBIENT: SCANNING BEAM + VELOCITY-SKEW MARQUEE ---------- */
.fx-beam{
  position:fixed;left:0;right:0;top:0;height:2px;z-index:2;pointer-events:none;opacity:.45;
  background:linear-gradient(90deg,transparent,rgba(34,201,255,.6),transparent);
  box-shadow:0 0 26px 5px rgba(34,201,255,.22);
  animation:fxBeam 12s linear infinite;will-change:transform;
}
@keyframes fxBeam{from{transform:translate3d(0,-10px,0)}to{transform:translate3d(0,100vh,0)}}
.fx .marquee{will-change:transform}
.fx .marquee .track span{transition:text-shadow .4s}

/* ---------- Small screens: keep it light ---------- */
@media(max-width:700px){
  .fx-radar{width:380px;height:380px;margin:-190px 0 0 -190px}
  .fx-corner{width:30px;height:30px}
  .fx-beam{display:none}
}
