Files
2026-07-07 18:38:36 +05:30

3 lines
177 KiB
JavaScript

import{l as Kr,p as Jr}from"./chunk-GOGW25MK.js";import{$b as Vt,Bb as ht,Ca as Qr,Cb as Je,Db as dt,Eb as Me,P as Hr,X as Wr,Xa as Xr,Y as jr,_c as Zr,aa as $r,d as Br,e as qr,eb as Gs,jb as ft,k as Nr,kb as Yr,oa as Gr,r as Ur,yc as Qs}from"./chunk-CGTN5U7L.js";import{a as q,b as Ke,c as Vr}from"./chunk-Q7L6LLAK.js";var Se="generated",ea="pointerdown",ta="pointerup",Bt="pointerleave",ia="pointerout",he="pointermove",oa="touchstart",Xs="touchend",na="touchmove",sa="touchcancel",ra="resize",aa="visibilitychange",J="tsParticles - Error";var Y={x:0,y:0,z:0},qt={a:1,b:0,c:0,d:1},Ae="random",Nt="mid",W=2,la=Math.PI*W,di=60;var Ys="true",Zs="false",pi="canvas",Ks=0,de=2,Js=4,ca=1,er=1,tr=1,ua=4,mi=1,Ut=255,Ve=360,gi=100,yi=100,ir=0,xi=0,fa=60,ha=0,Ht=.25,or=.5+Ht,nr=0,da=1,pa=0,ma=0,ga=1,Wt=1,ya=1,sr=1,pt=0,bi=1,xa=0,ba=120,va=0,wa=0,_a=1e4,ka=0,Pa=1,et=0,vi=1,Oa=1,Ca=0,rr=1,Ma=0,Sa=0,ar=-Ht,lr=1.5,cr=0,za=1,Ra=0,jt=0;var wi=1,Da=1,mt=1,Ea=500,ur=50,Ia=0,$t=1,fr=0,hr=1,Ta=0,Be=255,_i=3,ki=6,Fa=1,La=1,Aa=0,Va=0,Ba=0,qa=0;var ee=(function(t){return t.bottom="bottom",t.bottomLeft="bottom-left",t.bottomRight="bottom-right",t.left="left",t.none="none",t.right="right",t.top="top",t.topLeft="top-left",t.topRight="top-right",t.outside="outside",t.inside="inside",t})(ee||{});function Pi(t){return typeof t=="boolean"}function ge(t){return typeof t=="string"}function Z(t){return typeof t=="number"}function ze(t){return typeof t=="object"&&t!==null}function N(t){return Array.isArray(t)}function h(t){return t==null}var gt=class t{constructor(e,i,o){if(this._updateFromAngle=(n,s)=>{this.x=Math.cos(n)*s,this.y=Math.sin(n)*s},!Z(e)&&e){this.x=e.x,this.y=e.y;let n=e;this.z=n.z?n.z:Y.z}else if(e!==void 0&&i!==void 0)this.x=e,this.y=i,this.z=o??Y.z;else throw new Error(`${J} Vector3d not initialized correctly`)}static get origin(){return t.create(Y.x,Y.y,Y.z)}get angle(){return Math.atan2(this.y,this.x)}set angle(e){this._updateFromAngle(e,this.length)}get length(){return Math.sqrt(this.getLengthSq())}set length(e){this._updateFromAngle(this.angle,e)}static clone(e){return t.create(e.x,e.y,e.z)}static create(e,i,o){return new t(e,i,o)}add(e){return t.create(this.x+e.x,this.y+e.y,this.z+e.z)}addTo(e){this.x+=e.x,this.y+=e.y,this.z+=e.z}copy(){return t.clone(this)}distanceTo(e){return this.sub(e).length}distanceToSq(e){return this.sub(e).getLengthSq()}div(e){return t.create(this.x/e,this.y/e,this.z/e)}divTo(e){this.x/=e,this.y/=e,this.z/=e}getLengthSq(){return this.x**de+this.y**de}mult(e){return t.create(this.x*e,this.y*e,this.z*e)}multTo(e){this.x*=e,this.y*=e,this.z*=e}normalize(){let e=this.length;e!=et&&this.multTo(mi/e)}rotate(e){return t.create(this.x*Math.cos(e)-this.y*Math.sin(e),this.x*Math.sin(e)+this.y*Math.cos(e),Y.z)}setTo(e){this.x=e.x,this.y=e.y;let i=e;this.z=i.z?i.z:Y.z}sub(e){return t.create(this.x-e.x,this.y-e.y,this.z-e.z)}subFrom(e){this.x-=e.x,this.y-=e.y,this.z-=e.z}},z=class t extends gt{constructor(e,i){super(e,i,Y.z)}static get origin(){return t.create(Y.x,Y.y)}static clone(e){return t.create(e.x,e.y)}static create(e,i){return new t(e,i)}};var Hu=Math.random,Na={nextFrame:t=>requestAnimationFrame(t),cancel:t=>cancelAnimationFrame(t)};function v(){return K(Hu(),0,1-Number.EPSILON)}function Ua(t){return Na.nextFrame(t)}function Ha(t){Na.cancel(t)}function K(t,e,i){return Math.min(Math.max(t,e),i)}function Oi(t,e,i,o){return Math.floor((t*i+e*o)/(i+o))}function U(t){let e=le(t),i=0,o=yt(t);return e===o&&(o=i),v()*(e-o)+o}function g(t){return Z(t)?t:U(t)}function yt(t){return Z(t)?t:t.min}function le(t){return Z(t)?t:t.max}function b(t,e){if(t===e||e===void 0&&Z(t))return t;let i=yt(t),o=le(t);return e!==void 0?{min:Math.min(i,e),max:Math.max(o,e)}:b(i,o)}function A(t,e){let i=t.x-e.x,o=t.y-e.y,n=2;return{dx:i,dy:o,distance:Math.sqrt(i**n+o**n)}}function V(t,e){return A(t,e).distance}function ue(t){return t*Math.PI/180}function Wa(t,e,i){if(Z(t))return ue(t);switch(t){case ee.top:return-Math.PI*.5;case ee.topRight:return-Math.PI*Ht;case ee.right:return ha;case ee.bottomRight:return Math.PI*Ht;case ee.bottom:return Math.PI*.5;case ee.bottomLeft:return Math.PI*or;case ee.left:return Math.PI;case ee.topLeft:return-Math.PI*or;case ee.inside:return Math.atan2(i.y-e.y,i.x-e.x);case ee.outside:return Math.atan2(e.y-i.y,e.x-i.x);default:return v()*la}}function ja(t){let e=z.origin;return e.length=1,e.angle=t,e}function dr(t,e,i,o){return z.create(t.x*(i-o)/(i+o)+e.x*W*o/(i+o),t.y)}function pr(t){return{x:(t.position?.x??v()*100)*t.size.width/100,y:(t.position?.y??v()*100)*t.size.height/100}}function Ci(t){let e={x:t.position?.x!==void 0?g(t.position.x):void 0,y:t.position?.y!==void 0?g(t.position.y):void 0};return pr({size:t.size,position:e})}function $a(t){return{x:t.position?.x??v()*t.size.width,y:t.position?.y??v()*t.size.height}}function Mi(t){return t?t.endsWith("%")?parseFloat(t)/100:parseFloat(t):1}var qe=(function(t){return t.auto="auto",t.increase="increase",t.decrease="decrease",t.random="random",t})(qe||{});var B=(function(t){return t.increasing="increasing",t.decreasing="decreasing",t})(B||{});var ye=(function(t){return t.none="none",t.max="max",t.min="min",t})(ye||{});var O=(function(t){return t.bottom="bottom",t.left="left",t.right="right",t.top="top",t})(O||{});var re=(function(t){return t.precise="precise",t.percent="percent",t})(re||{});var tt=(function(t){return t.max="max",t.min="min",t.random="random",t})(tt||{});var Wu={debug:console.debug,error:console.error,info:console.info,log:console.log,verbose:console.log,warning:console.warn};function xe(){return Wu}function ju(t){let e=new Map;return(...i)=>{let o=JSON.stringify(i);if(e.has(o))return e.get(o);let n=t(...i);return e.set(o,n),n}}function Ga(t){let e={bounced:!1},{pSide:i,pOtherSide:o,rectSide:n,rectOtherSide:s,velocity:r,factor:a}=t;return o.min<s.min||o.min>s.max||o.max<s.min||o.max>s.max||(i.max>=n.min&&i.max<=(n.max+n.min)*.5&&r>nr||i.min<=n.max&&i.min>(n.max+n.min)*.5&&r<nr)&&(e.velocity=r*-a,e.bounced=!0),e}function $u(t,e){let i=S(e,o=>t.matches(o));return N(i)?i.some(o=>o):i}function _e(){return typeof window>"u"||!window||typeof window.document>"u"||!window.document}function Gu(){return!_e()&&typeof matchMedia<"u"}function Si(t){if(Gu())return matchMedia(t)}function Qa(t){if(!(_e()||typeof IntersectionObserver>"u"))return new IntersectionObserver(t)}function Xa(t){if(!(_e()||typeof MutationObserver>"u"))return new MutationObserver(t)}function M(t,e){return t===e||N(e)&&e.indexOf(t)>-1}async function Gt(t,e){try{await document.fonts.load(`${e??"400"} 36px '${t??"Verdana"}'`)}catch{}}function mr(t){return Math.floor(v()*t.length)}function Ne(t,e,i=!0){return t[e!==void 0&&i?e%t.length:mr(t)]}function ke(t,e,i,o,n){return Qu(Ue(t,o??0),e,i,n)}function Qu(t,e,i,o){let n=!0;return(!o||o===O.bottom)&&(n=t.top<e.height+i.x),n&&(!o||o===O.left)&&(n=t.right>i.x),n&&(!o||o===O.right)&&(n=t.left<e.width+i.y),n&&(!o||o===O.top)&&(n=t.bottom>i.y),n}function Ue(t,e){return{bottom:t.y+e,left:t.x-e,right:t.x+e,top:t.y-e}}function C(t,...e){for(let i of e){if(i==null)continue;if(!ze(i)){t=i;continue}let o=Array.isArray(i);o&&(ze(t)||!t||!Array.isArray(t))?t=[]:!o&&(ze(t)||!t||Array.isArray(t))&&(t={});for(let n in i){if(n==="__proto__")continue;let s=i,r=s[n],a=t;a[n]=ze(r)&&Array.isArray(r)?r.map(l=>C(a[n],l)):C(a[n],r)}}return t}function xt(t,e){return!!Za(e,i=>i.enable&&M(t,i.mode))}function bt(t,e,i){S(e,o=>{let n=o.mode;o.enable&&M(t,n)&&Xu(o,i)})}function Xu(t,e){let i=t.selectors;S(i,o=>{e(o,t)})}function zi(t,e){if(!(!e||!t))return Za(t,i=>$u(e,i.selectors))}function Qt(t){return{position:t.getPosition(),radius:t.getRadius(),mass:t.getMass(),velocity:t.velocity,factor:z.create(g(t.options.bounce.horizontal.value),g(t.options.bounce.vertical.value))}}function Ri(t,e){let{x:i,y:o}=t.velocity.sub(e.velocity),[n,s]=[t.position,e.position],{dx:r,dy:a}=A(s,n);if(i*r+o*a<0)return;let c=-Math.atan2(a,r),u=t.mass,f=e.mass,d=t.velocity.rotate(c),p=e.velocity.rotate(c),m=dr(d,p,u,f),y=dr(p,d,u,f),x=m.rotate(-c),_=y.rotate(-c);t.velocity.x=x.x*t.factor.x,t.velocity.y=x.y*t.factor.y,e.velocity.x=_.x*e.factor.x,e.velocity.y=_.y*e.factor.y}function Ya(t,e){let i=t.getPosition(),o=t.getRadius(),n=Ue(i,o),s=t.options.bounce,r=Ga({pSide:{min:n.left,max:n.right},pOtherSide:{min:n.top,max:n.bottom},rectSide:{min:e.left,max:e.right},rectOtherSide:{min:e.top,max:e.bottom},velocity:t.velocity.x,factor:g(s.horizontal.value)});r.bounced&&(r.velocity!==void 0&&(t.velocity.x=r.velocity),r.position!==void 0&&(t.position.x=r.position));let a=Ga({pSide:{min:n.top,max:n.bottom},pOtherSide:{min:n.left,max:n.right},rectSide:{min:e.top,max:e.bottom},rectOtherSide:{min:e.left,max:e.right},velocity:t.velocity.y,factor:g(s.vertical.value)});a.bounced&&(a.velocity!==void 0&&(t.velocity.y=a.velocity),a.position!==void 0&&(t.position.y=a.position))}function S(t,e){return N(t)?t.map((o,n)=>e(o,n)):e(t,0)}function T(t,e,i){return N(t)?Ne(t,e,i):t}function Za(t,e){return N(t)?t.find((o,n)=>e(o,n)):e(t,0)?t:void 0}function Di(t,e){let i=t.value,o=t.animation,n={delayTime:g(o.delay)*1e3,enable:o.enable,value:g(t.value)*e,max:le(i)*e,min:yt(i)*e,loops:0,maxLoops:g(o.count),time:0},s=1;if(o.enable){switch(n.decay=s-g(o.decay),o.mode){case qe.increase:n.status=B.increasing;break;case qe.decrease:n.status=B.decreasing;break;case qe.random:n.status=v()>=.5?B.increasing:B.decreasing;break}let r=o.mode===qe.auto;switch(o.startValue){case tt.min:n.value=n.min,r&&(n.status=B.increasing);break;case tt.max:n.value=n.max,r&&(n.status=B.decreasing);break;case tt.random:default:n.value=U(n),r&&(n.status=v()>=.5?B.increasing:B.decreasing);break}}return n.initialValue=n.value,n}function Ka(t,e){if(!(t.mode===re.percent)){let n=t,{mode:s}=n;return Vr(n,["mode"])}return"x"in t?{x:t.x/100*e.width,y:t.y/100*e.height}:{width:t.width/100*e.width,height:t.height/100*e.height}}function Ei(t,e){return Ka(t,e)}function gr(t,e){return Ka(t,e)}function Yu(t,e,i,o,n){switch(e){case ye.max:i>=n&&t.destroy();break;case ye.min:i<=o&&t.destroy();break}}function He(t,e,i,o,n){if(t.destroyed||!e||!e.enable||(e.maxLoops??0)>0&&(e.loops??0)>(e.maxLoops??0))return;let u=(e.velocity??0)*n.factor,f=e.min,d=e.max,p=e.decay??1;if(e.time||(e.time=0),(e.delayTime??0)>0&&e.time<(e.delayTime??0)&&(e.time+=n.value),!((e.delayTime??0)>0&&e.time<(e.delayTime??0))){switch(e.status){case B.increasing:e.value>=d?(i?e.status=B.decreasing:e.value-=d,e.loops||(e.loops=0),e.loops++):e.value+=u;break;case B.decreasing:e.value<=f?(i?e.status=B.increasing:e.value+=d,e.loops||(e.loops=0),e.loops++):e.value-=u}e.velocity&&p!==1&&(e.velocity*=p),Yu(t,o,e.value,f,d),t.destroyed||(e.value=K(e.value,f,d))}}function Ja(t){let e=document.createElement("div").style;if(!t)return e;for(let i in t){let o=t[i];if(!Object.prototype.hasOwnProperty.call(t,i)||h(o))continue;let n=t.getPropertyValue?.(o);if(!n)continue;let s=t.getPropertyPriority?.(o);s?e.setProperty?.(o,n,s):e.setProperty?.(o,n)}return e}function Zu(t){let e=document.createElement("div").style,i=10,o={width:"100%",height:"100%",margin:"0",padding:"0",borderWidth:"0",position:"fixed",zIndex:t.toString(i),"z-index":t.toString(i),top:"0",left:"0"};for(let n in o){let s=o[n];e.setProperty(n,s)}return e}var el=ju(Zu);var Re=(function(t){return t.darken="darken",t.enlighten="enlighten",t})(Re||{});function Ku(t,e){if(e){for(let i of t.colorManagers.values())if(e.startsWith(i.stringPrefix))return i.parseString(e)}}function oe(t,e,i,o=!0){if(!e)return;let n=ge(e)?{value:e}:e;if(ge(n.value))return tl(t,n.value,i,o);if(N(n.value))return oe(t,{value:Ne(n.value,i,o)});for(let s of t.colorManagers.values()){let r=s.handleRangeColor(n);if(r)return r}}function tl(t,e,i,o=!0){if(!e)return;let n=ge(e)?{value:e}:e;if(ge(n.value))return n.value===Ae?ol():Ju(t,n.value);if(N(n.value))return tl(t,{value:Ne(n.value,i,o)});for(let s of t.colorManagers.values()){let r=s.handleColor(n);if(r)return r}}function ce(t,e,i,o=!0){let n=oe(t,e,i,o);return n?br(n):void 0}function br(t){let e=t.r/Ut,i=t.g/Ut,o=t.b/Ut,n=Math.max(e,i,o),s=Math.min(e,i,o),r={h:ir,l:(n+s)*.5,s:xi};return n!==s&&(r.s=r.l<.5?(n-s)/(n+s):(n-s)/(W-n-s),r.h=e===n?(i-o)/(n-s):r.h=i===n?W+(o-e)/(n-s):W*W+(e-i)/(n-s)),r.l*=yi,r.s*=gi,r.h*=fa,r.h<ir&&(r.h+=Ve),r.h>=Ve&&(r.h-=Ve),r}function Ju(t,e){return Ku(t,e)}function it(t){let e=(t.h%Ve+Ve)%Ve,i=Math.max(xi,Math.min(gi,t.s)),o=Math.max(Ta,Math.min(yi,t.l)),n=e/Ve,s=i/gi,r=o/yi;if(i===xi){let m=Math.round(r*Be);return{r:m,g:m,b:m}}let a=(m,y,x)=>{if(x<0&&x++,x>1&&x--,x*ki<1)return m+(y-m)*ki*x;if(x*W<1)return y;if(x*_i<1*W){let P=W/_i;return m+(y-m)*(P-x)*ki}return m},l=r<.5?r*(Fa+s):r+s-r*s,c=W*r-l,u=La/_i,f=Math.min(Be,Be*a(c,l,n+u)),d=Math.min(Be,Be*a(c,l,n)),p=Math.min(Be,Be*a(c,l,n-u));return{r:Math.round(f),g:Math.round(d),b:Math.round(p)}}function il(t){let e=it(t);return{a:t.a,b:e.b,g:e.g,r:e.r}}function ol(t){let e=t??Aa,i=Ut+$t;return{b:Math.floor(U(b(e,i))),g:Math.floor(U(b(e,i))),r:Math.floor(U(b(e,i)))}}function ae(t,e){return`rgba(${t.r}, ${t.g}, ${t.b}, ${e??Wt})`}function Pe(t,e){return`hsla(${t.h}, ${t.s}%, ${t.l}%, ${e??Wt})`}function Xt(t,e,i,o){let n=t,s=e;return n.r===void 0&&(n=it(t)),s.r===void 0&&(s=it(e)),{b:Oi(n.b,s.b,i,o),g:Oi(n.g,s.g,i,o),r:Oi(n.r,s.r,i,o)}}function Yt(t,e,i){if(i===Ae)return ol();if(i===Nt){let o=t.getFillColor()??t.getStrokeColor(),n=e?.getFillColor()??e?.getStrokeColor();if(o&&n&&e)return Xt(o,n,t.getRadius(),e.getRadius());{let s=o??n;if(s)return it(s)}}else return i}function Ii(t,e,i,o){let n=ge(e)?e:e.value;return n===Ae?o?oe(t,{value:n}):i?Ae:Nt:n===Nt?Nt:oe(t,{value:n})}function vr(t){return t!==void 0?{h:t.h.value,s:t.s.value,l:t.l.value}:void 0}function Ti(t,e,i){let o={h:{enable:!1,value:t.h},s:{enable:!1,value:t.s},l:{enable:!1,value:t.l}};return e&&(yr(o.h,e.h,i),yr(o.s,e.s,i),yr(o.l,e.l,i)),o}function yr(t,e,i){t.enable=e.enable,t.enable?(t.velocity=g(e.speed)/100*i,t.decay=vi-g(e.decay),t.status=B.increasing,t.loops=Ba,t.maxLoops=g(e.count),t.time=qa,t.delayTime=g(e.delay)*1e3,e.sync||(t.velocity*=v(),t.value*=v()),t.initialValue=t.value,t.offset=b(e.offset)):t.velocity=Va}function xr(t,e,i,o){if(!t||!t.enable||(t.maxLoops??0)>0&&(t.loops??0)>(t.maxLoops??0)||(t.time||(t.time=0),(t.delayTime??0)>0&&t.time<(t.delayTime??0)&&(t.time+=o.value),(t.delayTime??0)>0&&t.time<(t.delayTime??0)))return;let u=t.offset?U(t.offset):0,f=(t.velocity??0)*o.factor+u*3.6,d=t.decay??1,p=le(e),m=yt(e);!i||t.status===B.increasing?(t.value+=f,t.value>p&&(t.loops||(t.loops=0),t.loops++,i?t.status=B.decreasing:t.value-=p)):(t.value-=f,t.value<0&&(t.loops||(t.loops=0),t.loops++,t.status=B.increasing)),t.velocity&&d!==1&&(t.velocity*=d),t.value=K(t.value,m,p)}function Fi(t,e){if(!t)return;let{h:i,s:o,l:n}=t,s={h:{min:0,max:360},s:{min:0,max:100},l:{min:0,max:100}};i&&xr(i,s.h,!1,e),o&&xr(o,s.s,!0,e),n&&xr(n,s.l,!0,e)}function We(t,e,i){t.beginPath(),t.moveTo(e.x,e.y),t.lineTo(i.x,i.y),t.closePath()}function nl(t,e,i){t.fillStyle=i??"rgba(0,0,0,0)",t.fillRect(Y.x,Y.y,e.width,e.height)}function sl(t,e,i,o){i&&(t.globalAlpha=o,t.drawImage(i,Y.x,Y.y,e.width,e.height),t.globalAlpha=1)}function Li(t,e){t.clearRect(Y.x,Y.y,e.width,e.height)}function rl(t){let{container:e,context:i,particle:o,delta:n,colorStyles:s,backgroundMask:r,composite:a,radius:l,opacity:c,shadow:u,transform:f}=t,d=o.getPosition(),p=o.rotation+(o.pathRotation?o.velocity.angle:Ia),m={sin:Math.sin(p),cos:Math.cos(p)},y=!!p,x={a:m.cos*(f.a??qt.a),b:y?m.sin*(f.b??$t):f.b??qt.b,c:y?-m.sin*(f.c??$t):f.c??qt.c,d:m.cos*(f.d??qt.d)};i.setTransform(x.a,x.b,x.c,x.d,d.x,d.y),r&&(i.globalCompositeOperation=a);let _=o.shadowColor;u.enable&&_&&(i.shadowBlur=u.blur,i.shadowColor=ae(_),i.shadowOffsetX=u.offset.x,i.shadowOffsetY=u.offset.y),s.fill&&(i.fillStyle=s.fill);let w=o.strokeWidth??fr;i.lineWidth=w,s.stroke&&(i.strokeStyle=s.stroke);let P={container:e,context:i,particle:o,radius:l,opacity:c,delta:n,transformData:x,strokeWidth:w};tf(P),of(P),ef(P),i.globalCompositeOperation="source-over",i.resetTransform()}function ef(t){let{container:e,context:i,particle:o,radius:n,opacity:s,delta:r,transformData:a}=t;if(!o.effect)return;let l=e.effectDrawers.get(o.effect);l&&l.draw({context:i,particle:o,radius:n,opacity:s,delta:r,pixelRatio:e.retina.pixelRatio,transformData:q({},a)})}function tf(t){let{container:e,context:i,particle:o,radius:n,opacity:s,delta:r,strokeWidth:a,transformData:l}=t;if(!o.shape)return;let c=e.shapeDrawers.get(o.shape);c&&(i.beginPath(),c.draw({context:i,particle:o,radius:n,opacity:s,delta:r,pixelRatio:e.retina.pixelRatio,transformData:q({},l)}),o.shapeClose&&i.closePath(),a>fr&&i.stroke(),o.shapeFill&&i.fill())}function of(t){let{container:e,context:i,particle:o,radius:n,opacity:s,delta:r,transformData:a}=t;if(!o.shape)return;let l=e.shapeDrawers.get(o.shape);l?.afterDraw&&l.afterDraw({context:i,particle:o,radius:n,opacity:s,delta:r,pixelRatio:e.retina.pixelRatio,transformData:q({},a)})}function al(t,e,i){e.draw&&e.draw(t,i)}function ll(t,e,i,o){e.drawParticle&&e.drawParticle(t,i,o)}function cl(t,e,i){return{h:t.h,s:t.s,l:t.l+(e===Re.darken?-hr:hr)*i}}function nf(t,e,i){let o=e[i];o!==void 0&&(t[i]=(t[i]??da)*o)}function ul(t,e,i=!1){if(!e)return;let o=t;if(!o)return;let n=o.style;if(!n)return;let s=new Set;for(let r in n)Object.prototype.hasOwnProperty.call(n,r)&&s.add(n[r]);for(let r in e)Object.prototype.hasOwnProperty.call(e,r)&&s.add(e[r]);for(let r of s){let a=e.getPropertyValue(r);a?n.setProperty(r,a,i?"important":""):n.removeProperty(r)}}var Ai=class{constructor(e,i){this.container=e,this._applyPostDrawUpdaters=s=>{for(let r of this._postDrawUpdaters)r.afterDraw?.(s)},this._applyPreDrawUpdaters=(s,r,a,l,c,u)=>{for(let f of this._preDrawUpdaters){if(f.getColorStyles){let{fill:d,stroke:p}=f.getColorStyles(r,s,a,l);d&&(c.fill=d),p&&(c.stroke=p)}if(f.getTransformValues){let d=f.getTransformValues(r);for(let p in d)nf(u,d,p)}f.beforeDraw?.(r)}},this._applyResizePlugins=()=>{for(let s of this._resizePlugins)s.resize?.()},this._getPluginParticleColors=s=>{let r,a;for(let l of this._colorPlugins)if(!r&&l.particleFillColor&&(r=ce(this._engine,l.particleFillColor(s))),!a&&l.particleStrokeColor&&(a=ce(this._engine,l.particleStrokeColor(s))),r&&a)break;return[r,a]},this._initCover=async()=>{let s=this.container.actualOptions,r=s.backgroundMask.cover,a=r.color;if(a){let l=oe(this._engine,a);if(l){let c=Ke(q({},l),{a:r.opacity});this._coverColorStyle=ae(c,c.a)}}else await new Promise((l,c)=>{if(!r.image)return;let u=document.createElement("img");u.addEventListener("load",()=>{this._coverImage={image:u,opacity:r.opacity},l()}),u.addEventListener("error",f=>{c(f.error)}),u.src=r.image})},this._initStyle=()=>{let s=this.element,r=this.container.actualOptions;if(s){this._fullScreen?this._setFullScreenStyle():this._resetOriginalStyle();for(let a in r.style){if(!a||!r.style||!Object.prototype.hasOwnProperty.call(r.style,a))continue;let l=r.style[a];l&&s.style.setProperty(a,l,"important")}}},this._initTrail=async()=>{let s=this.container.actualOptions,r=s.particles.move.trail,a=r.fill;if(!r.enable)return;let l=mi/r.length;if(a.color){let c=oe(this._engine,a.color);if(!c)return;this._trailFill={color:q({},c),opacity:l}}else await new Promise((c,u)=>{if(!a.image)return;let f=document.createElement("img");f.addEventListener("load",()=>{this._trailFill={image:f,opacity:l},c()}),f.addEventListener("error",d=>{u(d.error)}),f.src=a.image})},this._paintBase=s=>{this.draw(r=>nl(r,this.size,s))},this._paintImage=(s,r)=>{this.draw(a=>sl(a,this.size,s,r))},this._repairStyle=()=>{let s=this.element;if(!s)return;this._safeMutationObserver(a=>a.disconnect()),this._initStyle(),this.initBackground();let r=this._pointerEvents;s.style.pointerEvents=r,s.setAttribute("pointer-events",r),this._safeMutationObserver(a=>{!s||!(s instanceof Node)||a.observe(s,{attributes:!0})})},this._resetOriginalStyle=()=>{let s=this.element,r=this._originalStyle;!s||!r||ul(s,r,!0)},this._safeMutationObserver=s=>{this._mutationObserver&&s(this._mutationObserver)},this._setFullScreenStyle=()=>{let s=this.element;s&&ul(s,el(this.container.actualOptions.fullScreen.zIndex),!0)},this._engine=i,this._standardSize={height:0,width:0};let o=e.retina.pixelRatio,n=this._standardSize;this.size={height:n.height*o,width:n.width*o},this._context=null,this._generated=!1,this._preDrawUpdaters=[],this._postDrawUpdaters=[],this._resizePlugins=[],this._colorPlugins=[],this._pointerEvents="none"}get _fullScreen(){return this.container.actualOptions.fullScreen.enable}clear(){let e=this.container.actualOptions,i=e.particles.move.trail,o=this._trailFill;e.backgroundMask.enable?this.paint():i.enable&&i.length>ma&&o?o.color?this._paintBase(ae(o.color,o.opacity)):o.image&&this._paintImage(o.image,o.opacity):e.clear&&this.draw(n=>{Li(n,this.size)})}destroy(){this.stop(),this._generated?(this.element?.remove(),this.element=void 0):this._resetOriginalStyle(),this._preDrawUpdaters=[],this._postDrawUpdaters=[],this._resizePlugins=[],this._colorPlugins=[]}draw(e){let i=this._context;if(i)return e(i)}drawAsync(e){let i=this._context;if(i)return e(i)}drawParticle(e,i){if(e.spawning||e.destroyed)return;let o=e.getRadius();if(o<=pa)return;let n=e.getFillColor(),s=e.getStrokeColor()??n,[r,a]=this._getPluginParticleColors(e);r||(r=n),a||(a=s),!(!r&&!a)&&this.draw(l=>{let c=this.container,u=c.actualOptions,f=e.options.zIndex,d=ga-e.zIndexFactor,p=d**f.opacityRate,m=e.bubble.opacity??e.opacity?.value??Wt,y=e.strokeOpacity??m,x=m*p,_=y*p,w={},P={fill:r?Pe(r,x):void 0};P.stroke=a?Pe(a,_):P.fill,this._applyPreDrawUpdaters(l,e,o,x,P,w),rl({container:c,context:l,particle:e,delta:i,colorStyles:P,backgroundMask:u.backgroundMask.enable,composite:u.backgroundMask.composite,radius:o*d**f.sizeRate,opacity:x,shadow:e.options.shadow,transform:w}),this._applyPostDrawUpdaters(e)})}drawParticlePlugin(e,i,o){this.draw(n=>ll(n,e,i,o))}drawPlugin(e,i){this.draw(o=>al(o,e,i))}async init(){this._safeMutationObserver(e=>e.disconnect()),this._mutationObserver=Xa(e=>{for(let i of e)i.type==="attributes"&&i.attributeName==="style"&&this._repairStyle()}),this.resize(),this._initStyle(),await this._initCover();try{await this._initTrail()}catch(e){xe().error(e)}this.initBackground(),this._safeMutationObserver(e=>{!this.element||!(this.element instanceof Node)||e.observe(this.element,{attributes:!0})}),this.initUpdaters(),this.initPlugins(),this.paint()}initBackground(){let e=this.container.actualOptions,i=e.background,o=this.element;if(!o)return;let n=o.style;if(n){if(i.color){let s=oe(this._engine,i.color);n.backgroundColor=s?ae(s,i.opacity):""}else n.backgroundColor="";n.backgroundImage=i.image||"",n.backgroundPosition=i.position||"",n.backgroundRepeat=i.repeat||"",n.backgroundSize=i.size||""}}initPlugins(){this._resizePlugins=[];for(let e of this.container.plugins.values())e.resize&&this._resizePlugins.push(e),(e.particleFillColor??e.particleStrokeColor)&&this._colorPlugins.push(e)}initUpdaters(){this._preDrawUpdaters=[],this._postDrawUpdaters=[];for(let e of this.container.particles.updaters)e.afterDraw&&this._postDrawUpdaters.push(e),(e.getColorStyles??e.getTransformValues??e.beforeDraw)&&this._preDrawUpdaters.push(e)}loadCanvas(e){this._generated&&this.element&&this.element.remove(),this._generated=e.dataset&&Se in e.dataset?e.dataset[Se]==="true":this._generated,this.element=e,this.element.ariaHidden="true",this._originalStyle=Ja(this.element.style);let i=this._standardSize;i.height=e.offsetHeight,i.width=e.offsetWidth;let o=this.container.retina.pixelRatio,n=this.size;e.height=n.height=i.height*o,e.width=n.width=i.width*o,this._context=this.element.getContext("2d"),this._safeMutationObserver(s=>s.disconnect()),this.container.retina.init(),this.initBackground(),this._safeMutationObserver(s=>{!this.element||!(this.element instanceof Node)||s.observe(this.element,{attributes:!0})})}paint(){let e=this.container.actualOptions;this.draw(i=>{e.backgroundMask.enable&&e.backgroundMask.cover?(Li(i,this.size),this._coverImage?this._paintImage(this._coverImage.image,this._coverImage.opacity):this._coverColorStyle?this._paintBase(this._coverColorStyle):this._paintBase()):this._paintBase()})}resize(){if(!this.element)return!1;let e=this.container,i=e.canvas._standardSize,o={width:this.element.offsetWidth,height:this.element.offsetHeight},n=e.retina.pixelRatio,s={width:o.width*n,height:o.height*n};if(o.height===i.height&&o.width===i.width&&s.height===this.element.height&&s.width===this.element.width)return!1;let r=q({},i);i.height=o.height,i.width=o.width;let a=this.size;return this.element.width=a.width=s.width,this.element.height=a.height=s.height,this.container.started&&e.particles.setResizeFactor({width:i.width/r.width,height:i.height/r.height}),!0}setPointerEvents(e){this.element&&(this._pointerEvents=e,this._repairStyle())}stop(){this._safeMutationObserver(e=>e.disconnect()),this._mutationObserver=void 0,this.draw(e=>Li(e,this.size))}async windowResize(){if(!this.element||!this.resize())return;let e=this.container,i=e.updateActualOptions();e.particles.setDensity(),this._applyResizePlugins(),i&&await e.refresh()}};var ot=(function(t){return t.canvas="canvas",t.parent="parent",t.window="window",t})(ot||{});function be(t,e,i,o,n){if(o){let s={passive:!0};Pi(n)?s.capture=n:n!==void 0&&(s=n),t.addEventListener(e,i,s)}else{let s=n;t.removeEventListener(e,i,s)}}var Vi=class{constructor(e){this.container=e,this._doMouseTouchClick=i=>{let o=this.container,n=o.actualOptions;if(this._canPush){let s=o.interactivity.mouse,r=s.position;if(!r)return;s.clickPosition=q({},r),s.clickTime=new Date().getTime();let a=n.interactivity.events.onClick;S(a.mode,l=>this.container.handleClickMode(l))}i.type==="touchend"&&setTimeout(()=>this._mouseTouchFinish(),Ea)},this._handleThemeChange=i=>{let o=i,n=this.container,s=n.options,r=s.defaultThemes,a=o.matches?r.dark:r.light;s.themes.find(c=>c.name===a)?.default.auto&&n.loadTheme(a)},this._handleVisibilityChange=()=>{let i=this.container,o=i.actualOptions;this._mouseTouchFinish(),o.pauseOnBlur&&(document?.hidden?(i.pageHidden=!0,i.pause()):(i.pageHidden=!1,i.animationStatus?i.play(!0):i.draw(!0)))},this._handleWindowResize=()=>{this._resizeTimeout&&(clearTimeout(this._resizeTimeout),delete this._resizeTimeout);let i=async()=>{await this.container.canvas?.windowResize()};this._resizeTimeout=setTimeout(()=>{i()},this.container.actualOptions.interactivity.events.resize.delay*1e3)},this._manageInteractivityListeners=(i,o)=>{let n=this._handlers,s=this.container,r=s.actualOptions,a=s.interactivity.element;if(!a)return;let l=a,c=s.canvas;c.setPointerEvents(l===c.element?"initial":"none"),(r.interactivity.events.onHover.enable||r.interactivity.events.onClick.enable)&&(be(a,he,n.mouseMove,o),be(a,oa,n.touchStart,o),be(a,na,n.touchMove,o),r.interactivity.events.onClick.enable?(be(a,Xs,n.touchEndClick,o),be(a,ta,n.mouseUp,o),be(a,ea,n.mouseDown,o)):be(a,Xs,n.touchEnd,o),be(a,i,n.mouseLeave,o),be(a,sa,n.touchCancel,o))},this._manageListeners=i=>{let o=this._handlers,n=this.container,s=n.actualOptions,r=s.interactivity.detectsOn,a=n.canvas.element,l=Bt;r===ot.window?(n.interactivity.element=window,l=ia):r===ot.parent&&a?n.interactivity.element=a.parentElement??a.parentNode:n.interactivity.element=a,this._manageMediaMatch(i),this._manageResize(i),this._manageInteractivityListeners(l,i),document&&be(document,aa,o.visibilityChange,i,!1)},this._manageMediaMatch=i=>{let o=this._handlers,n=Si("(prefers-color-scheme: dark)");if(n){if(n.addEventListener!==void 0){be(n,"change",o.themeChange,i);return}n.addListener!==void 0&&(i?n.addListener(o.oldThemeChange):n.removeListener(o.oldThemeChange))}},this._manageResize=i=>{let o=this._handlers,n=this.container;if(!n.actualOptions.interactivity.events.resize)return;if(typeof ResizeObserver>"u"){be(window,ra,o.resize,i);return}let r=n.canvas.element;this._resizeObserver&&!i?(r&&this._resizeObserver.unobserve(r),this._resizeObserver.disconnect(),delete this._resizeObserver):!this._resizeObserver&&i&&r&&(this._resizeObserver=new ResizeObserver(a=>{a.find(c=>c.target===r)&&this._handleWindowResize()}),this._resizeObserver.observe(r))},this._mouseDown=()=>{let{interactivity:i}=this.container;if(!i)return;let{mouse:o}=i;o.clicking=!0,o.downPosition=o.position},this._mouseTouchClick=i=>{let o=this.container,n=o.actualOptions,{mouse:s}=o.interactivity;s.inside=!0;let r=!1,a=s.position;if(!(!a||!n.interactivity.events.onClick.enable)){for(let l of o.plugins.values())if(l.clickPositionValid&&(r=l.clickPositionValid(a),r))break;r||this._doMouseTouchClick(i),s.clicking=!1}},this._mouseTouchFinish=()=>{let i=this.container.interactivity;if(!i)return;let o=i.mouse;delete o.position,delete o.clickPosition,delete o.downPosition,i.status=Bt,o.inside=!1,o.clicking=!1},this._mouseTouchMove=i=>{let o=this.container,n=o.actualOptions,s=o.interactivity,r=o.canvas.element;if(!s?.element)return;s.mouse.inside=!0;let a;if(i.type.startsWith("pointer")){this._canPush=!0;let c=i;if(s.element===window){if(r){let u=r.getBoundingClientRect();a={x:c.clientX-u.left,y:c.clientY-u.top}}}else if(n.interactivity.detectsOn===ot.parent){let u=c.target,f=c.currentTarget;if(u&&f&&r){let d=u.getBoundingClientRect(),p=f.getBoundingClientRect(),m=r.getBoundingClientRect();a={x:c.offsetX+W*d.left-(p.left+m.left),y:c.offsetY+W*d.top-(p.top+m.top)}}else a={x:c.offsetX??c.clientX,y:c.offsetY??c.clientY}}else c.target===r&&(a={x:c.offsetX??c.clientX,y:c.offsetY??c.clientY})}else if(this._canPush=i.type!=="touchmove",r){let c=i,u=c.touches[c.touches.length-wi],f=r.getBoundingClientRect();a={x:u.clientX-(f.left??pt),y:u.clientY-(f.top??pt)}}let l=o.retina.pixelRatio;a&&(a.x*=l,a.y*=l),s.mouse.position=a,s.status=he},this._touchEnd=i=>{let o=i,n=Array.from(o.changedTouches);for(let s of n)this._touches.delete(s.identifier);this._mouseTouchFinish()},this._touchEndClick=i=>{let o=i,n=Array.from(o.changedTouches);for(let s of n)this._touches.delete(s.identifier);this._mouseTouchClick(i)},this._touchStart=i=>{let o=i,n=Array.from(o.changedTouches);for(let s of n)this._touches.set(s.identifier,performance.now());this._mouseTouchMove(i)},this._canPush=!0,this._touches=new Map,this._handlers={mouseDown:()=>this._mouseDown(),mouseLeave:()=>this._mouseTouchFinish(),mouseMove:i=>this._mouseTouchMove(i),mouseUp:i=>this._mouseTouchClick(i),touchStart:i=>this._touchStart(i),touchMove:i=>this._mouseTouchMove(i),touchEnd:i=>this._touchEnd(i),touchCancel:i=>this._touchEnd(i),touchEndClick:i=>this._touchEndClick(i),visibilityChange:()=>this._handleVisibilityChange(),themeChange:i=>this._handleThemeChange(i),oldThemeChange:i=>this._handleThemeChange(i),resize:()=>{this._handleWindowResize()}}}addListeners(){this._manageListeners(!0)}removeListeners(){this._manageListeners(!1)}};var te=(function(t){return t.configAdded="configAdded",t.containerInit="containerInit",t.particlesSetup="particlesSetup",t.containerStarted="containerStarted",t.containerStopped="containerStopped",t.containerDestroyed="containerDestroyed",t.containerPaused="containerPaused",t.containerPlay="containerPlay",t.containerBuilt="containerBuilt",t.particleAdded="particleAdded",t.particleDestroyed="particleDestroyed",t.particleRemoved="particleRemoved",t})(te||{});var D=class t{constructor(){this.value=""}static create(e,i){let o=new t;return o.load(e),i!==void 0&&(ge(i)||N(i)?o.load({value:i}):o.load(i)),o}load(e){h(e)||h(e.value)||(this.value=e.value)}};var Bi=class{constructor(){this.color=new D,this.color.value="",this.image="",this.position="",this.repeat="",this.size="",this.opacity=1}load(e){h(e)||(e.color!==void 0&&(this.color=D.create(this.color,e.color)),e.image!==void 0&&(this.image=e.image),e.position!==void 0&&(this.position=e.position),e.repeat!==void 0&&(this.repeat=e.repeat),e.size!==void 0&&(this.size=e.size),e.opacity!==void 0&&(this.opacity=e.opacity))}};var qi=class{constructor(){this.opacity=1}load(e){h(e)||(e.color!==void 0&&(this.color=D.create(this.color,e.color)),e.image!==void 0&&(this.image=e.image),e.opacity!==void 0&&(this.opacity=e.opacity))}};var Ni=class{constructor(){this.composite="destination-out",this.cover=new qi,this.enable=!1}load(e){if(!h(e)){if(e.composite!==void 0&&(this.composite=e.composite),e.cover!==void 0){let i=e.cover,o=ge(e.cover)?{color:e.cover}:e.cover;this.cover.load(i.color!==void 0||i.image!==void 0?i:{color:o})}e.enable!==void 0&&(this.enable=e.enable)}}};var Ui=class{constructor(){this.enable=!0,this.zIndex=0}load(e){h(e)||(e.enable!==void 0&&(this.enable=e.enable),e.zIndex!==void 0&&(this.zIndex=e.zIndex))}};var Hi=class{constructor(){this.enable=!1,this.mode=[]}load(e){h(e)||(e.enable!==void 0&&(this.enable=e.enable),e.mode!==void 0&&(this.mode=e.mode))}};var De=(function(t){return t.circle="circle",t.rectangle="rectangle",t})(De||{});var Zt=class{constructor(){this.selectors=[],this.enable=!1,this.mode=[],this.type=De.circle}load(e){h(e)||(e.selectors!==void 0&&(this.selectors=e.selectors),e.enable!==void 0&&(this.enable=e.enable),e.mode!==void 0&&(this.mode=e.mode),e.type!==void 0&&(this.type=e.type))}};var Wi=class{constructor(){this.enable=!1,this.force=2,this.smooth=10}load(e){h(e)||(e.enable!==void 0&&(this.enable=e.enable),e.force!==void 0&&(this.force=e.force),e.smooth!==void 0&&(this.smooth=e.smooth))}};var ji=class{constructor(){this.enable=!1,this.mode=[],this.parallax=new Wi}load(e){h(e)||(e.enable!==void 0&&(this.enable=e.enable),e.mode!==void 0&&(this.mode=e.mode),this.parallax.load(e.parallax))}};var $i=class{constructor(){this.delay=.5,this.enable=!0}load(e){h(e)||(e.delay!==void 0&&(this.delay=e.delay),e.enable!==void 0&&(this.enable=e.enable))}};var Gi=class{constructor(){this.onClick=new Hi,this.onDiv=new Zt,this.onHover=new ji,this.resize=new $i}load(e){if(h(e))return;this.onClick.load(e.onClick);let i=e.onDiv;i!==void 0&&(this.onDiv=S(i,o=>{let n=new Zt;return n.load(o),n})),this.onHover.load(e.onHover),this.resize.load(e.resize)}};var Qi=class{constructor(e,i){this._engine=e,this._container=i}load(e){if(h(e)||!this._container)return;let i=this._engine.interactors.get(this._container);if(i)for(let o of i)o.loadModeOptions&&o.loadModeOptions(this,e)}};var vt=class{constructor(e,i){this.detectsOn=ot.window,this.events=new Gi,this.modes=new Qi(e,i)}load(e){if(h(e))return;let i=e.detectsOn;i!==void 0&&(this.detectsOn=i),this.events.load(e.events),this.modes.load(e.modes)}};var Xi=class{load(e){h(e)||(e.position&&(this.position={x:e.position.x??ur,y:e.position.y??ur,mode:e.position.mode??re.percent}),e.options&&(this.options=C({},e.options)))}};var je=(function(t){return t.screen="screen",t.canvas="canvas",t})(je||{});var Yi=class{constructor(){this.maxWidth=1/0,this.options={},this.mode=je.canvas}load(e){h(e)||(h(e.maxWidth)||(this.maxWidth=e.maxWidth),h(e.mode)||(e.mode===je.screen?this.mode=je.screen:this.mode=je.canvas),h(e.options)||(this.options=C({},e.options)))}};var Ee=(function(t){return t.any="any",t.dark="dark",t.light="light",t})(Ee||{});var Zi=class{constructor(){this.auto=!1,this.mode=Ee.any,this.value=!1}load(e){h(e)||(e.auto!==void 0&&(this.auto=e.auto),e.mode!==void 0&&(this.mode=e.mode),e.value!==void 0&&(this.value=e.value))}};var Ki=class{constructor(){this.name="",this.default=new Zi}load(e){h(e)||(e.name!==void 0&&(this.name=e.name),this.default.load(e.default),e.options!==void 0&&(this.options=C({},e.options)))}};var nt=class{constructor(){this.count=0,this.enable=!1,this.speed=1,this.decay=0,this.delay=0,this.sync=!1}load(e){h(e)||(e.count!==void 0&&(this.count=b(e.count)),e.enable!==void 0&&(this.enable=e.enable),e.speed!==void 0&&(this.speed=b(e.speed)),e.decay!==void 0&&(this.decay=b(e.decay)),e.delay!==void 0&&(this.delay=b(e.delay)),e.sync!==void 0&&(this.sync=e.sync))}},$e=class extends nt{constructor(){super(),this.mode=qe.auto,this.startValue=tt.random}load(e){super.load(e),!h(e)&&(e.mode!==void 0&&(this.mode=e.mode),e.startValue!==void 0&&(this.startValue=e.startValue))}};var wt=class extends nt{constructor(){super(),this.offset=0,this.sync=!0}load(e){super.load(e),!h(e)&&e.offset!==void 0&&(this.offset=b(e.offset))}};var Ji=class{constructor(){this.h=new wt,this.s=new wt,this.l=new wt}load(e){h(e)||(this.h.load(e.h),this.s.load(e.s),this.l.load(e.l))}};var Ie=class t extends D{constructor(){super(),this.animation=new Ji}static create(e,i){let o=new t;return o.load(e),i!==void 0&&(ge(i)||N(i)?o.load({value:i}):o.load(i)),o}load(e){if(super.load(e),h(e))return;let i=e.animation;i!==void 0&&(i.enable!==void 0?this.animation.h.load(i):this.animation.load(e.animation))}};var st=(function(t){return t.absorb="absorb",t.bounce="bounce",t.destroy="destroy",t})(st||{});var eo=class{constructor(){this.speed=2}load(e){h(e)||e.speed!==void 0&&(this.speed=e.speed)}};var to=class{constructor(){this.enable=!0,this.retries=0}load(e){h(e)||(e.enable!==void 0&&(this.enable=e.enable),e.retries!==void 0&&(this.retries=e.retries))}};var $=class{constructor(){this.value=0}load(e){h(e)||h(e.value)||(this.value=b(e.value))}},wr=class extends ${constructor(){super(),this.animation=new nt}load(e){if(super.load(e),h(e))return;let i=e.animation;i!==void 0&&this.animation.load(i)}},_t=class extends wr{constructor(){super(),this.animation=new $e}load(e){super.load(e)}};var Kt=class extends ${constructor(){super(),this.value=1}};var kt=class{constructor(){this.horizontal=new Kt,this.vertical=new Kt}load(e){h(e)||(this.horizontal.load(e.horizontal),this.vertical.load(e.vertical))}};var io=class{constructor(){this.absorb=new eo,this.bounce=new kt,this.enable=!1,this.maxSpeed=50,this.mode=st.bounce,this.overlap=new to}load(e){h(e)||(this.absorb.load(e.absorb),this.bounce.load(e.bounce),e.enable!==void 0&&(this.enable=e.enable),e.maxSpeed!==void 0&&(this.maxSpeed=b(e.maxSpeed)),e.mode!==void 0&&(this.mode=e.mode),this.overlap.load(e.overlap))}};var oo=class{constructor(){this.close=!0,this.fill=!0,this.options={},this.type=[]}load(e){if(h(e))return;let i=e.options;if(i!==void 0)for(let o in i){let n=i[o];n&&(this.options[o]=C(this.options[o]??{},n))}e.close!==void 0&&(this.close=e.close),e.fill!==void 0&&(this.fill=e.fill),e.type!==void 0&&(this.type=e.type)}};var no=class{constructor(){this.offset=0,this.value=90}load(e){h(e)||(e.offset!==void 0&&(this.offset=b(e.offset)),e.value!==void 0&&(this.value=b(e.value)))}};var so=class{constructor(){this.distance=200,this.enable=!1,this.rotate={x:3e3,y:3e3}}load(e){if(!h(e)&&(e.distance!==void 0&&(this.distance=b(e.distance)),e.enable!==void 0&&(this.enable=e.enable),e.rotate)){let i=e.rotate.x;i!==void 0&&(this.rotate.x=i);let o=e.rotate.y;o!==void 0&&(this.rotate.y=o)}}};var ro=class{constructor(){this.x=50,this.y=50,this.mode=re.percent,this.radius=0}load(e){h(e)||(e.x!==void 0&&(this.x=e.x),e.y!==void 0&&(this.y=e.y),e.mode!==void 0&&(this.mode=e.mode),e.radius!==void 0&&(this.radius=e.radius))}};var ao=class{constructor(){this.acceleration=9.81,this.enable=!1,this.inverse=!1,this.maxSpeed=50}load(e){h(e)||(e.acceleration!==void 0&&(this.acceleration=b(e.acceleration)),e.enable!==void 0&&(this.enable=e.enable),e.inverse!==void 0&&(this.inverse=e.inverse),e.maxSpeed!==void 0&&(this.maxSpeed=b(e.maxSpeed)))}};var lo=class{constructor(){this.clamp=!0,this.delay=new $,this.enable=!1,this.options={}}load(e){h(e)||(e.clamp!==void 0&&(this.clamp=e.clamp),this.delay.load(e.delay),e.enable!==void 0&&(this.enable=e.enable),this.generator=e.generator,e.options&&(this.options=C(this.options,e.options)))}};var co=class{load(e){h(e)||(e.color!==void 0&&(this.color=D.create(this.color,e.color)),e.image!==void 0&&(this.image=e.image))}};var uo=class{constructor(){this.enable=!1,this.length=10,this.fill=new co}load(e){h(e)||(e.enable!==void 0&&(this.enable=e.enable),e.fill!==void 0&&this.fill.load(e.fill),e.length!==void 0&&(this.length=e.length))}};var F=(function(t){return t.bounce="bounce",t.none="none",t.out="out",t.destroy="destroy",t.split="split",t})(F||{});var fo=class{constructor(){this.default=F.out}load(e){h(e)||(e.default!==void 0&&(this.default=e.default),this.bottom=e.bottom??e.default,this.left=e.left??e.default,this.right=e.right??e.default,this.top=e.top??e.default)}};var ho=class{constructor(){this.acceleration=0,this.enable=!1}load(e){h(e)||(e.acceleration!==void 0&&(this.acceleration=b(e.acceleration)),e.enable!==void 0&&(this.enable=e.enable),e.position&&(this.position=C({},e.position)))}};var po=class{constructor(){this.angle=new no,this.attract=new so,this.center=new ro,this.decay=0,this.distance={},this.direction=ee.none,this.drift=0,this.enable=!1,this.gravity=new ao,this.path=new lo,this.outModes=new fo,this.random=!1,this.size=!1,this.speed=2,this.spin=new ho,this.straight=!1,this.trail=new uo,this.vibrate=!1,this.warp=!1}load(e){if(h(e))return;this.angle.load(Z(e.angle)?{value:e.angle}:e.angle),this.attract.load(e.attract),this.center.load(e.center),e.decay!==void 0&&(this.decay=b(e.decay)),e.direction!==void 0&&(this.direction=e.direction),e.distance!==void 0&&(this.distance=Z(e.distance)?{horizontal:e.distance,vertical:e.distance}:q({},e.distance)),e.drift!==void 0&&(this.drift=b(e.drift)),e.enable!==void 0&&(this.enable=e.enable),this.gravity.load(e.gravity);let i=e.outModes;i!==void 0&&(ze(i)?this.outModes.load(i):this.outModes.load({default:i})),this.path.load(e.path),e.random!==void 0&&(this.random=e.random),e.size!==void 0&&(this.size=e.size),e.speed!==void 0&&(this.speed=b(e.speed)),this.spin.load(e.spin),e.straight!==void 0&&(this.straight=e.straight),this.trail.load(e.trail),e.vibrate!==void 0&&(this.vibrate=e.vibrate),e.warp!==void 0&&(this.warp=e.warp)}};var mo=class extends $e{constructor(){super(),this.destroy=ye.none,this.speed=2}load(e){super.load(e),!h(e)&&e.destroy!==void 0&&(this.destroy=e.destroy)}};var go=class extends _t{constructor(){super(),this.animation=new mo,this.value=1}load(e){if(h(e))return;super.load(e);let i=e.animation;i!==void 0&&this.animation.load(i)}};var yo=class{constructor(){this.enable=!1,this.width=1920,this.height=1080}load(e){if(h(e))return;e.enable!==void 0&&(this.enable=e.enable);let i=e.width;i!==void 0&&(this.width=i);let o=e.height;o!==void 0&&(this.height=o)}};var Pt=(function(t){return t.delete="delete",t.wait="wait",t})(Pt||{});var xo=class{constructor(){this.mode=Pt.delete,this.value=0}load(e){h(e)||(e.mode!==void 0&&(this.mode=e.mode),e.value!==void 0&&(this.value=e.value))}};var bo=class{constructor(){this.density=new yo,this.limit=new xo,this.value=0}load(e){h(e)||(this.density.load(e.density),this.limit.load(e.limit),e.value!==void 0&&(this.value=e.value))}};var vo=class{constructor(){this.blur=0,this.color=new D,this.enable=!1,this.offset={x:0,y:0},this.color.value="#000"}load(e){h(e)||(e.blur!==void 0&&(this.blur=e.blur),this.color=D.create(this.color,e.color),e.enable!==void 0&&(this.enable=e.enable),e.offset!==void 0&&(e.offset.x!==void 0&&(this.offset.x=e.offset.x),e.offset.y!==void 0&&(this.offset.y=e.offset.y)))}};var wo=class{constructor(){this.close=!0,this.fill=!0,this.options={},this.type="circle"}load(e){if(h(e))return;let i=e.options;if(i!==void 0)for(let o in i){let n=i[o];n&&(this.options[o]=C(this.options[o]??{},n))}e.close!==void 0&&(this.close=e.close),e.fill!==void 0&&(this.fill=e.fill),e.type!==void 0&&(this.type=e.type)}};var _o=class extends $e{constructor(){super(),this.destroy=ye.none,this.speed=5}load(e){super.load(e),!h(e)&&e.destroy!==void 0&&(this.destroy=e.destroy)}};var ko=class extends _t{constructor(){super(),this.animation=new _o,this.value=3}load(e){if(super.load(e),h(e))return;let i=e.animation;i!==void 0&&this.animation.load(i)}};var Jt=class{constructor(){this.width=0}load(e){h(e)||(e.color!==void 0&&(this.color=Ie.create(this.color,e.color)),e.width!==void 0&&(this.width=b(e.width)),e.opacity!==void 0&&(this.opacity=b(e.opacity)))}};var Po=class extends ${constructor(){super(),this.opacityRate=1,this.sizeRate=1,this.velocityRate=1}load(e){super.load(e),!h(e)&&(e.opacityRate!==void 0&&(this.opacityRate=e.opacityRate),e.sizeRate!==void 0&&(this.sizeRate=e.sizeRate),e.velocityRate!==void 0&&(this.velocityRate=e.velocityRate))}};var Oo=class{constructor(e,i){this._engine=e,this._container=i,this.bounce=new kt,this.collisions=new io,this.color=new Ie,this.color.value="#fff",this.effect=new oo,this.groups={},this.move=new po,this.number=new bo,this.opacity=new go,this.reduceDuplicates=!1,this.shadow=new vo,this.shape=new wo,this.size=new ko,this.stroke=new Jt,this.zIndex=new Po}load(e){if(h(e))return;if(e.groups!==void 0)for(let o of Object.keys(e.groups)){if(!Object.hasOwn(e.groups,o))continue;let n=e.groups[o];n!==void 0&&(this.groups[o]=C(this.groups[o]??{},n))}e.reduceDuplicates!==void 0&&(this.reduceDuplicates=e.reduceDuplicates),this.bounce.load(e.bounce),this.color.load(Ie.create(this.color,e.color)),this.effect.load(e.effect),this.move.load(e.move),this.number.load(e.number),this.opacity.load(e.opacity),this.shape.load(e.shape),this.size.load(e.size),this.shadow.load(e.shadow),this.zIndex.load(e.zIndex),this.collisions.load(e.collisions),e.interactivity!==void 0&&(this.interactivity=C({},e.interactivity));let i=e.stroke;if(i&&(this.stroke=S(i,o=>{let n=new Jt;return n.load(o),n})),this._container){let o=this._engine.updaters.get(this._container);if(o)for(let s of o)s.loadOptions&&s.loadOptions(this,e);let n=this._engine.interactors.get(this._container);if(n)for(let s of n)s.loadParticlesOptions&&s.loadParticlesOptions(this,e)}}};function _r(t,...e){for(let i of e)t.load(i)}function Ot(t,e,...i){let o=new Oo(t,e);return _r(o,...i),o}var Co=class{constructor(e,i){this._findDefaultTheme=o=>this.themes.find(n=>n.default.value&&n.default.mode===o)??this.themes.find(n=>n.default.value&&n.default.mode===Ee.any),this._importPreset=o=>{this.load(this._engine.getPreset(o))},this._engine=e,this._container=i,this.autoPlay=!0,this.background=new Bi,this.backgroundMask=new Ni,this.clear=!0,this.defaultThemes={},this.delay=0,this.fullScreen=new Ui,this.detectRetina=!0,this.duration=0,this.fpsLimit=120,this.interactivity=new vt(e,i),this.manualParticles=[],this.particles=Ot(this._engine,this._container),this.pauseOnBlur=!0,this.pauseOnOutsideViewport=!0,this.responsive=[],this.smooth=!1,this.style={},this.themes=[],this.zLayers=100}load(e){if(h(e))return;e.preset!==void 0&&S(e.preset,r=>this._importPreset(r)),e.autoPlay!==void 0&&(this.autoPlay=e.autoPlay),e.clear!==void 0&&(this.clear=e.clear),e.key!==void 0&&(this.key=e.key),e.name!==void 0&&(this.name=e.name),e.delay!==void 0&&(this.delay=b(e.delay));let i=e.detectRetina;i!==void 0&&(this.detectRetina=i),e.duration!==void 0&&(this.duration=b(e.duration));let o=e.fpsLimit;o!==void 0&&(this.fpsLimit=o),e.pauseOnBlur!==void 0&&(this.pauseOnBlur=e.pauseOnBlur),e.pauseOnOutsideViewport!==void 0&&(this.pauseOnOutsideViewport=e.pauseOnOutsideViewport),e.zLayers!==void 0&&(this.zLayers=e.zLayers),this.background.load(e.background);let n=e.fullScreen;Pi(n)?this.fullScreen.enable=n:this.fullScreen.load(n),this.backgroundMask.load(e.backgroundMask),this.interactivity.load(e.interactivity),e.manualParticles&&(this.manualParticles=e.manualParticles.map(r=>{let a=new Xi;return a.load(r),a})),this.particles.load(e.particles),this.style=C(this.style,e.style),this._engine.loadOptions(this,e),e.smooth!==void 0&&(this.smooth=e.smooth);let s=this._engine.interactors.get(this._container);if(s)for(let r of s)r.loadOptions&&r.loadOptions(this,e);if(e.responsive!==void 0)for(let r of e.responsive){let a=new Yi;a.load(r),this.responsive.push(a)}if(this.responsive.sort((r,a)=>r.maxWidth-a.maxWidth),e.themes!==void 0)for(let r of e.themes){let a=this.themes.find(l=>l.name===r.name);if(a)a.load(r);else{let l=new Ki;l.load(r),this.themes.push(l)}}this.defaultThemes.dark=this._findDefaultTheme(Ee.dark)?.name,this.defaultThemes.light=this._findDefaultTheme(Ee.light)?.name}setResponsive(e,i,o){this.load(o);let n=this.responsive.find(s=>s.mode===je.screen&&screen?s.maxWidth>screen.availWidth:s.maxWidth*i>e);return this.load(n?.options),n?.maxWidth}setTheme(e){if(e){let i=this.themes.find(o=>o.name===e);i&&this.load(i.options)}else{let i=Si("(prefers-color-scheme: dark)"),o=i?.matches,n=this._findDefaultTheme(o?Ee.dark:Ee.light);n&&this.load(n.options)}}};var Ge=(function(t){return t.external="external",t.particles="particles",t})(Ge||{});var Mo=class{constructor(e,i){this.container=i,this._engine=e,this._interactors=[],this._externalInteractors=[],this._particleInteractors=[]}externalInteract(e){for(let i of this._externalInteractors)i.isEnabled()&&i.interact(e)}handleClickMode(e){for(let i of this._externalInteractors)i.handleClickMode?.(e)}async init(){this._interactors=await this._engine.getInteractors(this.container,!0),this._externalInteractors=[],this._particleInteractors=[];for(let e of this._interactors){switch(e.type){case Ge.external:this._externalInteractors.push(e);break;case Ge.particles:this._particleInteractors.push(e);break}e.init()}}particlesInteract(e,i){for(let o of this._externalInteractors)o.clear(e,i);for(let o of this._particleInteractors)o.isEnabled(e)&&o.interact(e,i)}reset(e){for(let i of this._externalInteractors)i.isEnabled()&&i.reset(e);for(let i of this._particleInteractors)i.isEnabled(e)&&i.reset(e)}};var pe=(function(t){return t.normal="normal",t.inside="inside",t.outside="outside",t})(pe||{});function sf(t,e,i,o){let n=e.options[t];if(n)return C({close:e.close,fill:e.fill},T(n,i,o))}function rf(t,e,i,o){let n=e.options[t];if(n)return C({close:e.close,fill:e.fill},T(n,i,o))}function fl(t){if(!M(t.outMode,t.checkModes))return;let e=t.radius*W;t.coord>t.maxCoord-e?t.setCb(-t.radius):t.coord<e&&t.setCb(t.radius)}var So=class{constructor(e,i){this.container=i,this._calcPosition=(o,n,s,r=Ks)=>{for(let m of o.plugins.values()){let y=m.particlePosition!==void 0?m.particlePosition(n,this):void 0;if(y)return gt.create(y.x,y.y,s)}let a=o.canvas.size,l=$a({size:a,position:n}),c=gt.create(l.x,l.y,s),u=this.getRadius(),f=this.options.move.outModes,d=m=>{fl({outMode:m,checkModes:[F.bounce],coord:c.x,maxCoord:o.canvas.size.width,setCb:y=>c.x+=y,radius:u})},p=m=>{fl({outMode:m,checkModes:[F.bounce],coord:c.y,maxCoord:o.canvas.size.height,setCb:y=>c.y+=y,radius:u})};return d(f.left??f.default),d(f.right??f.default),p(f.top??f.default),p(f.bottom??f.default),this._checkOverlap(c,r)?this._calcPosition(o,void 0,s,r+Oa):c},this._calculateVelocity=()=>{let o=ja(this.direction),n=o.copy(),s=this.options.move;if(s.direction===ee.inside||s.direction===ee.outside)return n;let r=ue(g(s.angle.value)),a=ue(g(s.angle.offset)),l={left:a-r*.5,right:a+r*.5};return s.straight||(n.angle+=U(b(l.left,l.right))),s.random&&typeof s.speed=="number"&&(n.length*=v()),n},this._checkOverlap=(o,n=Ks)=>{let s=this.options.collisions,r=this.getRadius();if(!s.enable)return!1;let a=s.overlap;if(a.enable)return!1;let l=a.retries;if(l>=Ca&&n>l)throw new Error(`${J} particle is overlapping and can't be placed`);return!!this.container.particles.find(c=>V(o,c.position)<r+c.getRadius())},this._getRollColor=o=>{if(!o||!this.roll||!this.backColor&&!this.roll.alter)return o;let n=this.roll.horizontal&&this.roll.vertical?W*rr:rr,s=this.roll.horizontal?Math.PI*.5:et;return Math.floor(((this.roll.angle??et)+s)/(Math.PI/n))%W?this.backColor?this.backColor:this.roll.alter?cl(o,this.roll.alter.type,this.roll.alter.value):o:o},this._initPosition=o=>{let n=this.container,s=g(this.options.zIndex.value);this.position=this._calcPosition(n,o,K(s,Ma,n.zLayers)),this.initialPosition=this.position.copy();let r=n.canvas.size;switch(this.moveCenter=Ke(q({},Ei(this.options.move.center,r)),{radius:this.options.move.center.radius??Sa,mode:this.options.move.center.mode??re.percent}),this.direction=Wa(this.options.move.direction,this.position,this.moveCenter),this.options.move.direction){case ee.inside:this.outType=pe.inside;break;case ee.outside:this.outType=pe.outside;break}this.offset=z.origin},this._engine=e}destroy(e){if(this.unbreakable||this.destroyed)return;this.destroyed=!0,this.bubble.inRange=!1,this.slow.inRange=!1;let i=this.container,o=this.pathGenerator;i.shapeDrawers.get(this.shape)?.particleDestroy?.(this);for(let s of i.plugins.values())s.particleDestroyed?.(this,e);for(let s of i.particles.updaters)s.particleDestroyed?.(this,e);o?.reset(this),this._engine.dispatchEvent(te.particleDestroyed,{container:this.container,data:{particle:this}})}draw(e){let i=this.container,o=i.canvas;for(let n of i.plugins.values())o.drawParticlePlugin(n,this,e);o.drawParticle(this,e)}getFillColor(){return this._getRollColor(this.bubble.color??vr(this.color))}getMass(){return this.getRadius()**de*Math.PI*.5}getPosition(){return{x:this.position.x+this.offset.x,y:this.position.y+this.offset.y,z:this.position.z}}getRadius(){return this.bubble.radius??this.size.value}getStrokeColor(){return this._getRollColor(this.bubble.color??vr(this.strokeColor))}init(e,i,o,n){let s=this.container,r=this._engine;this.id=e,this.group=n,this.effectClose=!0,this.effectFill=!0,this.shapeClose=!0,this.shapeFill=!0,this.pathRotation=!1,this.lastPathTime=0,this.destroyed=!1,this.unbreakable=!1,this.isRotating=!1,this.rotation=0,this.misplaced=!1,this.retina={maxDistance:{}},this.outType=pe.normal,this.ignoresResizeRatio=!0;let a=s.retina.pixelRatio,l=s.actualOptions,c=Ot(this._engine,s,l.particles),{reduceDuplicates:u}=c,f=c.effect.type,d=c.shape.type;this.effect=T(f,this.id,u),this.shape=T(d,this.id,u);let p=c.effect,m=c.shape;if(o){if(o.effect?.type){let L=o.effect.type,se=T(L,this.id,u);se&&(this.effect=se,p.load(o.effect))}if(o.shape?.type){let L=o.shape.type,se=T(L,this.id,u);se&&(this.shape=se,m.load(o.shape))}}if(this.effect===Ae){let L=[...this.container.effectDrawers.keys()];this.effect=L[Math.floor(v()*L.length)]}if(this.shape===Ae){let L=[...this.container.shapeDrawers.keys()];this.shape=L[Math.floor(v()*L.length)]}this.effectData=sf(this.effect,p,this.id,u),this.shapeData=rf(this.shape,m,this.id,u),c.load(o);let y=this.effectData;y&&c.load(y.particles);let x=this.shapeData;x&&c.load(x.particles);let _=new vt(r,s);_.load(s.actualOptions.interactivity),_.load(c.interactivity),this.interactivity=_,this.effectFill=y?.fill??c.effect.fill,this.effectClose=y?.close??c.effect.close,this.shapeFill=x?.fill??c.shape.fill,this.shapeClose=x?.close??c.shape.close,this.options=c;let w=this.options.move.path;this.pathDelay=g(w.delay.value)*1e3,w.generator&&(this.pathGenerator=this._engine.getPathGenerator(w.generator),this.pathGenerator&&s.addPath(w.generator,this.pathGenerator)&&this.pathGenerator.init(s)),s.retina.initParticle(this),this.size=Di(this.options.size,a),this.bubble={inRange:!1},this.slow={inRange:!1,factor:1},this._initPosition(i),this.initialVelocity=this._calculateVelocity(),this.velocity=this.initialVelocity.copy(),this.moveDecay=vi-g(this.options.move.decay);let P=s.particles;P.setLastZIndex(this.position.z),this.zIndexFactor=this.position.z/s.zLayers,this.sides=24;let k=s.effectDrawers.get(this.effect);k||(k=this._engine.getEffectDrawer(this.effect),k&&s.effectDrawers.set(this.effect,k)),k?.loadEffect&&k.loadEffect(this);let I=s.shapeDrawers.get(this.shape);I||(I=this._engine.getShapeDrawer(this.shape),I&&s.shapeDrawers.set(this.shape,I)),I?.loadShape&&I.loadShape(this);let Q=I?.getSidesCount;Q&&(this.sides=Q(this)),this.spawning=!1,this.shadowColor=oe(this._engine,this.options.shadow.color);for(let L of P.updaters)L.init(this);for(let L of P.movers)L.init?.(this);k?.particleInit?.(s,this),I?.particleInit?.(s,this);for(let L of s.plugins.values())L.particleCreated?.(this)}isInsideCanvas(){let e=this.getRadius(),i=this.container.canvas.size,o=this.position;return o.x>=-e&&o.y>=-e&&o.y<=i.height+e&&o.x<=i.width+e}isVisible(){return!this.destroyed&&!this.spawning&&this.isInsideCanvas()}reset(){for(let e of this.container.particles.updaters)e.reset?.(this)}};var zo=class{constructor(e,i){this.position=e,this.particle=i}};var Ct=(function(t){return t.circle="circle",t.rectangle="rectangle",t})(Ct||{});var Ro=class{constructor(e,i,o){this.position={x:e,y:i},this.type=o}},G=class t extends Ro{constructor(e,i,o){super(e,i,Ct.circle),this.radius=o}contains(e){return V(e,this.position)<=this.radius}intersects(e){let i=this.position,o=e.position,n={x:Math.abs(o.x-i.x),y:Math.abs(o.y-i.y)},s=this.radius;if(e instanceof t||e.type===Ct.circle){let r=e,a=s+r.radius,l=Math.sqrt(n.x**de+n.y**de);return a>l}else if(e instanceof ne||e.type===Ct.rectangle){let r=e,{width:a,height:l}=r.size;return Math.pow(n.x-a,de)+Math.pow(n.y-l,de)<=s**de||n.x<=s+a&&n.y<=s+l||n.x<=a||n.y<=l}return!1}},ne=class t extends Ro{constructor(e,i,o,n){super(e,i,Ct.rectangle),this.size={height:n,width:o}}contains(e){let i=this.size.width,o=this.size.height,n=this.position;return e.x>=n.x&&e.x<=n.x+i&&e.y>=n.y&&e.y<=n.y+o}intersects(e){if(e instanceof G)return e.intersects(this);let i=this.size.width,o=this.size.height,n=this.position,s=e.position,r=e instanceof t?e.size:{width:0,height:0},a=r.width,l=r.height;return s.x<n.x+i&&s.x+a>n.x&&s.y<n.y+o&&s.y+l>n.y}};var ei=class t{constructor(e,i){this.rectangle=e,this.capacity=i,this._subdivide=()=>{let{x:o,y:n}=this.rectangle.position,{width:s,height:r}=this.rectangle.size,{capacity:a}=this;for(let l=0;l<ua;l++){let c=l%W;this._subs.push(new t(new ne(o+s*.5*c,n+r*.5*(Math.round(l*.5)-c),s*.5,r*.5),a))}this._divided=!0},this._points=[],this._divided=!1,this._subs=[]}insert(e){return this.rectangle.contains(e.position)?this._points.length<this.capacity?(this._points.push(e),!0):(this._divided||this._subdivide(),this._subs.some(i=>i.insert(e))):!1}query(e,i){let o=[];if(!e.intersects(this.rectangle))return[];for(let n of this._points)!e.contains(n.position)&&V(e.position,n.position)>n.particle.getRadius()&&(!i||i(n.particle))||o.push(n.particle);if(this._divided)for(let n of this._subs)o.push(...n.query(e,i));return o}queryCircle(e,i,o){return this.query(new G(e.x,e.y,i),o)}queryRectangle(e,i,o){return this.query(new ne(e.x,e.y,i.width,i.height),o)}};var hl=t=>{let{height:e,width:i}=t;return new ne(ar*i,ar*e,lr*i,lr*e)},Do=class{constructor(e,i){this._addToPool=(...n)=>{this._pool.push(...n)},this._applyDensity=(n,s,r,a)=>{let l=n.number;if(!n.number.density?.enable){r===void 0?this._limit=l.limit.value:(a?.number.limit?.value??l.limit.value)&&this._groupLimits.set(r,a?.number.limit?.value??l.limit.value);return}let c=this._initDensityFactor(l.density),u=l.value,f=l.limit.value>cr?l.limit.value:u,d=Math.min(u,f)*c+s,p=Math.min(this.count,this.filter(m=>m.group===r).length);r===void 0?this._limit=l.limit.value*c:this._groupLimits.set(r,l.limit.value*c),p<d?this.push(Math.abs(d-p),void 0,n,r):p>d&&this.removeQuantity(p-d,r)},this._initDensityFactor=n=>{let s=this._container;if(!s.canvas.element||!n.enable)return Da;let r=s.canvas.element,a=s.retina.pixelRatio;return r.width*r.height/(n.height*n.width*a**de)},this._pushParticle=(n,s,r,a)=>{try{let l=this._pool.pop();l||(l=new So(this._engine,this._container)),l.init(this._nextId,n,s,r);let c=!0;return a&&(c=a(l)),c?(this._array.push(l),this._zArray.push(l),this._nextId++,this._engine.dispatchEvent(te.particleAdded,{container:this._container,data:{particle:l}}),l):void 0}catch(l){xe().warning(`${J} adding particle: ${l}`)}},this._removeParticle=(n,s,r)=>{let a=this._array[n];if(!a||a.group!==s)return!1;let l=this._zArray.indexOf(a);return this._array.splice(n,mt),this._zArray.splice(l,mt),a.destroy(r),this._engine.dispatchEvent(te.particleRemoved,{container:this._container,data:{particle:a}}),this._addToPool(a),!0},this._engine=e,this._container=i,this._nextId=0,this._array=[],this._zArray=[],this._pool=[],this._limit=0,this._groupLimits=new Map,this._needsSort=!1,this._lastZIndex=0,this._interactionManager=new Mo(e,i),this._pluginsInitialized=!1;let o=i.canvas.size;this.quadTree=new ei(hl(o),Js),this.movers=[],this.updaters=[]}get count(){return this._array.length}addManualParticles(){let e=this._container;e.actualOptions.manualParticles.forEach(o=>this.addParticle(o.position?Ei(o.position,e.canvas.size):void 0,o.options))}addParticle(e,i,o,n){let s=this._container.actualOptions.particles.number.limit.mode,r=o===void 0?this._limit:this._groupLimits.get(o)??this._limit,a=this.count;if(r>cr)switch(s){case Pt.delete:{let l=a+za-r;l>Ra&&this.removeQuantity(l);break}case Pt.wait:if(a>=r)return;break}return this._pushParticle(e,i,o,n)}clear(){this._array=[],this._zArray=[],this._pluginsInitialized=!1}destroy(){this._array=[],this._zArray=[],this.movers=[],this.updaters=[]}draw(e){let i=this._container,o=i.canvas;o.clear(),this.update(e);for(let n of i.plugins.values())o.drawPlugin(n,e);for(let n of this._zArray)n.draw(e)}filter(e){return this._array.filter(e)}find(e){return this._array.find(e)}get(e){return this._array[e]}handleClickMode(e){this._interactionManager.handleClickMode(e)}async init(){let e=this._container,i=e.actualOptions;this._lastZIndex=0,this._needsSort=!1,await this.initPlugins();let o=!1;for(let n of e.plugins.values())if(o=n.particlesInitialization?.()??o,o)break;if(this.addManualParticles(),!o){let n=i.particles,s=n.groups;for(let r in s){let a=s[r];for(let l=this.count,c=0;c<a.number?.value&&l<n.number.value;l++,c++)this.addParticle(void 0,a,r)}for(let r=this.count;r<n.number.value;r++)this.addParticle()}}async initPlugins(){if(this._pluginsInitialized)return;let e=this._container;this.movers=await this._engine.getMovers(e,!0),this.updaters=await this._engine.getUpdaters(e,!0),await this._interactionManager.init();for(let i of e.pathGenerators.values())i.init(e)}push(e,i,o,n){for(let s=0;s<e;s++)this.addParticle(i?.position,o,n)}async redraw(){this.clear(),await this.init(),this.draw({value:0,factor:0})}remove(e,i,o){this.removeAt(this._array.indexOf(e),void 0,i,o)}removeAt(e,i=ca,o,n){if(e<jt||e>this.count)return;let s=0;for(let r=e;s<i&&r<this.count;r++)this._removeParticle(r,o,n)&&(r--,s++)}removeQuantity(e,i){this.removeAt(jt,e,i)}setDensity(){let e=this._container.actualOptions,i=e.particles.groups,o=e.manualParticles.length;for(let n in i)this._applyDensity(i[n],o,n);this._applyDensity(e.particles,o)}setLastZIndex(e){this._lastZIndex=e,this._needsSort=this._needsSort||this._lastZIndex<e}setResizeFactor(e){this._resizeFactor=e}update(e){let i=this._container,o=new Set;this.quadTree=new ei(hl(i.canvas.size),Js);for(let s of i.pathGenerators.values())s.update();for(let s of i.plugins.values())s.update?.(e);let n=this._resizeFactor;for(let s of this._array){n&&!s.ignoresResizeRatio&&(s.position.x*=n.width,s.position.y*=n.height,s.initialPosition.x*=n.width,s.initialPosition.y*=n.height),s.ignoresResizeRatio=!1,this._interactionManager.reset(s);for(let r of this._container.plugins.values()){if(s.destroyed)break;r.particleUpdate?.(s,e)}for(let r of this.movers)r.isEnabled(s)&&r.move(s,e);if(s.destroyed){o.add(s);continue}this.quadTree.insert(new zo(s.getPosition(),s))}if(o.size){let s=r=>!o.has(r);this._array=this.filter(s),this._zArray=this._zArray.filter(s);for(let r of o)this._engine.dispatchEvent(te.particleRemoved,{container:this._container,data:{particle:r}});this._addToPool(...o)}this._interactionManager.externalInteract(e);for(let s of this._array){for(let r of this.updaters)r.update(s,e);!s.destroyed&&!s.spawning&&this._interactionManager.particlesInteract(s,e)}if(delete this._resizeFactor,this._needsSort){let s=this._zArray;s.sort((r,a)=>a.position.z-r.position.z||r.id-a.id),this._lastZIndex=s[s.length-wi].position.z,this._needsSort=!1}}};var Eo=class{constructor(e){this.container=e,this.pixelRatio=er,this.reduceFactor=tr}init(){let e=this.container,i=e.actualOptions;this.pixelRatio=!i.detectRetina||_e()?er:devicePixelRatio,this.reduceFactor=tr;let o=this.pixelRatio,n=e.canvas;if(n.element){let a=n.element;n.size.width=a.offsetWidth*o,n.size.height=a.offsetHeight*o}let s=i.particles,r=s.move;this.maxSpeed=g(r.gravity.maxSpeed)*o,this.sizeAnimationSpeed=g(s.size.animation.speed)*o}initParticle(e){let i=e.options,o=this.pixelRatio,n=i.move,s=n.distance,r=e.retina;r.moveDrift=g(n.drift)*o,r.moveSpeed=g(n.speed)*o,r.sizeAnimationSpeed=g(i.size.animation.speed)*o;let a=r.maxDistance;a.horizontal=s.horizontal!==void 0?s.horizontal*o:void 0,a.vertical=s.vertical!==void 0?s.vertical*o:void 0,r.maxSpeed=g(n.gravity.maxSpeed)*o}};function X(t){return t&&!t.destroyed}function af(t,e=di,i=!1){return{value:t,factor:i?di/e:di*t/1e3}}function Mt(t,e,...i){let o=new Co(t,e);return _r(o,...i),o}var Io=class{constructor(e,i,o){this._intersectionManager=n=>{if(!(!X(this)||!this.actualOptions.pauseOnOutsideViewport))for(let s of n)s.target===this.interactivity.element&&(s.isIntersecting?this.play():this.pause())},this._nextFrame=n=>{try{if(!this._smooth&&this._lastFrameTime!==void 0&&n<this._lastFrameTime+1e3/this.fpsLimit){this.draw(!1);return}this._lastFrameTime??=n;let s=af(n-this._lastFrameTime,this.fpsLimit,this._smooth);if(this.addLifeTime(s.value),this._lastFrameTime=n,s.value>1e3){this.draw(!1);return}if(this.particles.draw(s),!this.alive()){this.destroy();return}this.animationStatus&&this.draw(!1)}catch(s){xe().error(`${J} in animation loop`,s)}},this._engine=e,this.id=Symbol(i),this.fpsLimit=120,this._smooth=!1,this._delay=0,this._duration=0,this._lifeTime=0,this._firstStart=!0,this.started=!1,this.destroyed=!1,this._paused=!0,this._lastFrameTime=0,this.zLayers=100,this.pageHidden=!1,this._clickHandlers=new Map,this._sourceOptions=o,this._initialSourceOptions=o,this.retina=new Eo(this),this.canvas=new Ai(this,this._engine),this.particles=new Do(this._engine,this),this.pathGenerators=new Map,this.interactivity={mouse:{clicking:!1,inside:!1}},this.plugins=new Map,this.effectDrawers=new Map,this.shapeDrawers=new Map,this._options=Mt(this._engine,this),this.actualOptions=Mt(this._engine,this),this._eventListeners=new Vi(this),this._intersectionObserver=Qa(n=>this._intersectionManager(n)),this._engine.dispatchEvent(te.containerBuilt,{container:this})}get animationStatus(){return!this._paused&&!this.pageHidden&&X(this)}get options(){return this._options}get sourceOptions(){return this._sourceOptions}addClickHandler(e){if(!X(this))return;let i=this.interactivity.element;if(!i)return;let o=(f,d,p)=>{if(!X(this))return;let m=this.retina.pixelRatio,y={x:d.x*m,y:d.y*m},x=this.particles.quadTree.queryCircle(y,p*m);e(f,x)},n=f=>{if(!X(this))return;let d=f,p={x:d.offsetX||d.clientX,y:d.offsetY||d.clientY};o(f,p,ya)},s=()=>{X(this)&&(c=!0,u=!1)},r=()=>{X(this)&&(u=!0)},a=f=>{if(X(this)){if(c&&!u){let d=f,p=d.touches[d.touches.length-sr];if(!p&&(p=d.changedTouches[d.changedTouches.length-sr],!p))return;let m=this.canvas.element,y=m?m.getBoundingClientRect():void 0,x={x:p.clientX-(y?y.left:pt),y:p.clientY-(y?y.top:pt)};o(f,x,Math.max(p.radiusX,p.radiusY))}c=!1,u=!1}},l=()=>{X(this)&&(c=!1,u=!1)},c=!1,u=!1;this._clickHandlers.set("click",n),this._clickHandlers.set("touchstart",s),this._clickHandlers.set("touchmove",r),this._clickHandlers.set("touchend",a),this._clickHandlers.set("touchcancel",l);for(let[f,d]of this._clickHandlers)i.addEventListener(f,d)}addLifeTime(e){this._lifeTime+=e}addPath(e,i,o=!1){return!X(this)||!o&&this.pathGenerators.has(e)?!1:(this.pathGenerators.set(e,i),!0)}alive(){return!this._duration||this._lifeTime<=this._duration}clearClickHandlers(){if(X(this)){for(let[e,i]of this._clickHandlers)this.interactivity.element?.removeEventListener(e,i);this._clickHandlers.clear()}}destroy(e=!0){if(X(this)){this.stop(),this.clearClickHandlers(),this.particles.destroy(),this.canvas.destroy();for(let i of this.effectDrawers.values())i.destroy?.(this);for(let i of this.shapeDrawers.values())i.destroy?.(this);for(let i of this.effectDrawers.keys())this.effectDrawers.delete(i);for(let i of this.shapeDrawers.keys())this.shapeDrawers.delete(i);if(this._engine.clearPlugins(this),this.destroyed=!0,e){let i=this._engine.items,o=i.findIndex(n=>n===this);o>=xa&&i.splice(o,bi)}this._engine.dispatchEvent(te.containerDestroyed,{container:this})}}draw(e){if(!X(this))return;let i=e,o=n=>{i&&(this._lastFrameTime=void 0,i=!1),this._nextFrame(n)};this._drawAnimationFrame=Ua(n=>o(n))}async export(e,i={}){for(let o of this.plugins.values()){if(!o.export)continue;let n=await o.export(e,i);if(n.supported)return n.blob}xe().error(`${J} - Export plugin with type ${e} not found`)}handleClickMode(e){if(X(this)){this.particles.handleClickMode(e);for(let i of this.plugins.values())i.handleClickMode?.(e)}}async init(){if(!X(this))return;let e=this._engine.getSupportedEffects();for(let c of e){let u=this._engine.getEffectDrawer(c);u&&this.effectDrawers.set(c,u)}let i=this._engine.getSupportedShapes();for(let c of i){let u=this._engine.getShapeDrawer(c);u&&this.shapeDrawers.set(c,u)}await this.particles.initPlugins(),this._options=Mt(this._engine,this,this._initialSourceOptions,this.sourceOptions),this.actualOptions=Mt(this._engine,this,this._options);let o=await this._engine.getAvailablePlugins(this);for(let[c,u]of o)this.plugins.set(c,u);this.retina.init(),await this.canvas.init(),this.updateActualOptions(),this.canvas.initBackground(),this.canvas.resize();let{zLayers:n,duration:s,delay:r,fpsLimit:a,smooth:l}=this.actualOptions;this.zLayers=n,this._duration=g(s)*1e3,this._delay=g(r)*1e3,this._lifeTime=0,this.fpsLimit=a>va?a:ba,this._smooth=l;for(let c of this.effectDrawers.values())await c.init?.(this);for(let c of this.shapeDrawers.values())await c.init?.(this);for(let c of this.plugins.values())await c.init?.();this._engine.dispatchEvent(te.containerInit,{container:this}),await this.particles.init(),this.particles.setDensity();for(let c of this.plugins.values())c.particlesSetup?.();this._engine.dispatchEvent(te.particlesSetup,{container:this})}async loadTheme(e){X(this)&&(this._currentTheme=e,await this.refresh())}pause(){if(X(this)&&(this._drawAnimationFrame!==void 0&&(Ha(this._drawAnimationFrame),delete this._drawAnimationFrame),!this._paused)){for(let e of this.plugins.values())e.pause?.();this.pageHidden||(this._paused=!0),this._engine.dispatchEvent(te.containerPaused,{container:this})}}play(e){if(!X(this))return;let i=this._paused||e;if(this._firstStart&&!this.actualOptions.autoPlay){this._firstStart=!1;return}if(this._paused&&(this._paused=!1),i)for(let o of this.plugins.values())o.play&&o.play();this._engine.dispatchEvent(te.containerPlay,{container:this}),this.draw(i??!1)}async refresh(){if(X(this))return this.stop(),this.start()}async reset(e){if(X(this))return this._initialSourceOptions=e,this._sourceOptions=e,this._options=Mt(this._engine,this,this._initialSourceOptions,this.sourceOptions),this.actualOptions=Mt(this._engine,this,this._options),this.refresh()}async start(){!X(this)||this.started||(await this.init(),this.started=!0,await new Promise(e=>{let i=async()=>{this._eventListeners.addListeners(),this.interactivity.element instanceof HTMLElement&&this._intersectionObserver&&this._intersectionObserver.observe(this.interactivity.element);for(let o of this.plugins.values())await o.start?.();this._engine.dispatchEvent(te.containerStarted,{container:this}),this.play(),e()};this._delayTimeout=setTimeout(()=>{i()},this._delay)}))}stop(){if(!(!X(this)||!this.started)){this._delayTimeout&&(clearTimeout(this._delayTimeout),delete this._delayTimeout),this._firstStart=!0,this.started=!1,this._eventListeners.removeListeners(),this.pause(),this.particles.clear(),this.canvas.stop(),this.interactivity.element instanceof HTMLElement&&this._intersectionObserver&&this._intersectionObserver.unobserve(this.interactivity.element);for(let e of this.plugins.values())e.stop?.();for(let e of this.plugins.keys())this.plugins.delete(e);this._sourceOptions=this._options,this._engine.dispatchEvent(te.containerStopped,{container:this})}}updateActualOptions(){this.actualOptions.responsive=[];let e=this.actualOptions.setResponsive(this.canvas.size.width,this.retina.pixelRatio,this._options);return this.actualOptions.setTheme(this._currentTheme),this._responsiveMaxWidth===e?!1:(this._responsiveMaxWidth=e,!0)}};var To=class{constructor(){this._listeners=new Map}addEventListener(e,i){this.removeEventListener(e,i);let o=this._listeners.get(e);o||(o=[],this._listeners.set(e,o)),o.push(i)}dispatchEvent(e,i){this._listeners.get(e)?.forEach(n=>n(i))}hasEventListener(e){return!!this._listeners.get(e)}removeAllEventListeners(e){e?this._listeners.delete(e):this._listeners=new Map}removeEventListener(e,i){let o=this._listeners.get(e);if(!o)return;let n=o.length,s=o.indexOf(i);s<jt||(n===mt?this._listeners.delete(e):o.splice(s,mt))}};async function kr(t,e,i,o=!1){let n=e.get(t);return(!n||o)&&(n=await Promise.all([...i.values()].map(s=>s(t))),e.set(t,n)),n}async function lf(t){let e=T(t.url,t.index);if(!e)return t.fallback;let i=await fetch(e);return i.ok?await i.json():(xe().error(`${J} ${i.status} while retrieving config file`),t.fallback)}var cf=t=>{let e;if(t instanceof HTMLCanvasElement||t.tagName.toLowerCase()===pi)e=t,e.dataset[Se]||(e.dataset[Se]=Zs);else{let o=t.getElementsByTagName(pi);o.length?(e=o[wa],e.dataset[Se]=Zs):(e=document.createElement(pi),e.dataset[Se]=Ys,t.appendChild(e))}let i="100%";return e.style.width||(e.style.width=i),e.style.height||(e.style.height=i),e},uf=(t,e)=>{let i=e??document.getElementById(t);return i||(i=document.createElement("div"),i.id=t,i.dataset[Se]=Ys,document.body.append(i),i)},Fo=class{constructor(){this._configs=new Map,this._domArray=[],this._eventDispatcher=new To,this._initialized=!1,this.plugins=[],this.colorManagers=new Map,this.easingFunctions=new Map,this._initializers={interactors:new Map,movers:new Map,updaters:new Map},this.interactors=new Map,this.movers=new Map,this.updaters=new Map,this.presets=new Map,this.effectDrawers=new Map,this.shapeDrawers=new Map,this.pathGenerators=new Map}get configs(){let e={};for(let[i,o]of this._configs)e[i]=o;return e}get items(){return this._domArray}get version(){return"3.9.1"}async addColorManager(e,i=!0){this.colorManagers.set(e.key,e),await this.refresh(i)}addConfig(e){let i=e.key??e.name??"default";this._configs.set(i,e),this._eventDispatcher.dispatchEvent(te.configAdded,{data:{name:i,config:e}})}async addEasing(e,i,o=!0){this.getEasing(e)||(this.easingFunctions.set(e,i),await this.refresh(o))}async addEffect(e,i,o=!0){S(e,n=>{this.getEffectDrawer(n)||this.effectDrawers.set(n,i)}),await this.refresh(o)}addEventListener(e,i){this._eventDispatcher.addEventListener(e,i)}async addInteractor(e,i,o=!0){this._initializers.interactors.set(e,i),await this.refresh(o)}async addMover(e,i,o=!0){this._initializers.movers.set(e,i),await this.refresh(o)}async addParticleUpdater(e,i,o=!0){this._initializers.updaters.set(e,i),await this.refresh(o)}async addPathGenerator(e,i,o=!0){this.getPathGenerator(e)||this.pathGenerators.set(e,i),await this.refresh(o)}async addPlugin(e,i=!0){this.getPlugin(e.id)||this.plugins.push(e),await this.refresh(i)}async addPreset(e,i,o=!1,n=!0){(o||!this.getPreset(e))&&this.presets.set(e,i),await this.refresh(n)}async addShape(e,i=!0){for(let o of e.validTypes)this.getShapeDrawer(o)||this.shapeDrawers.set(o,e);await this.refresh(i)}checkVersion(e){if(this.version!==e)throw new Error(`The tsParticles version is different from the loaded plugins version. Engine version: ${this.version}. Plugin version: ${e}`)}clearPlugins(e){this.updaters.delete(e),this.movers.delete(e),this.interactors.delete(e)}dispatchEvent(e,i){this._eventDispatcher.dispatchEvent(e,i)}dom(){return this.items}domItem(e){return this.item(e)}async getAvailablePlugins(e){let i=new Map;for(let o of this.plugins)o.needsPlugin(e.actualOptions)&&i.set(o.id,await o.getPlugin(e));return i}getEasing(e){return this.easingFunctions.get(e)??(i=>i)}getEffectDrawer(e){return this.effectDrawers.get(e)}async getInteractors(e,i=!1){return kr(e,this.interactors,this._initializers.interactors,i)}async getMovers(e,i=!1){return kr(e,this.movers,this._initializers.movers,i)}getPathGenerator(e){return this.pathGenerators.get(e)}getPlugin(e){return this.plugins.find(i=>i.id===e)}getPreset(e){return this.presets.get(e)}getShapeDrawer(e){return this.shapeDrawers.get(e)}getSupportedEffects(){return this.effectDrawers.keys()}getSupportedShapes(){return this.shapeDrawers.keys()}async getUpdaters(e,i=!1){return kr(e,this.updaters,this._initializers.updaters,i)}init(){this._initialized||(this._initialized=!0)}item(e){let{items:i}=this,o=i[e];if(!o||o.destroyed){i.splice(e,bi);return}return o}async load(e){let i=e.id??e.element?.id??`tsparticles${Math.floor(v()*_a)}`,{index:o,url:n}=e,s=n?await lf({fallback:e.options,url:n,index:o}):e.options,r=T(s,o),{items:a}=this,l=a.findIndex(d=>d.id.description===i),c=new Io(this,i,r);if(l>=ka){let d=this.item(l),p=d?Pa:et;d&&!d.destroyed&&d.destroy(!1),a.splice(l,p,c)}else a.push(c);let u=uf(i,e.element),f=cf(u);return c.canvas.loadCanvas(f),await c.start(),c}loadOptions(e,i){this.plugins.forEach(o=>o.loadOptions?.(e,i))}loadParticlesOptions(e,i,...o){let n=this.updaters.get(e);n&&n.forEach(s=>s.loadOptions?.(i,...o))}async refresh(e=!0){e&&await Promise.all(this.items.map(i=>i.refresh()))}removeEventListener(e,i){this._eventDispatcher.removeEventListener(e,i)}setOnClickHandler(e){let{items:i}=this;if(!i.length)throw new Error(`${J} can only set click handlers after calling tsParticles.load()`);i.forEach(o=>o.addClickHandler(e))}};function dl(){let t=new Fo;return t.init(),t}var H=class{constructor(e){this.type=Ge.external,this.container=e}};var Qe=class{constructor(e){this.type=Ge.particles,this.container=e}};var ie=(function(t){return t.clockwise="clockwise",t.counterClockwise="counter-clockwise",t.random="random",t})(ie||{});var Te=(function(t){return t.easeInBack="ease-in-back",t.easeInCirc="ease-in-circ",t.easeInCubic="ease-in-cubic",t.easeInLinear="ease-in-linear",t.easeInQuad="ease-in-quad",t.easeInQuart="ease-in-quart",t.easeInQuint="ease-in-quint",t.easeInExpo="ease-in-expo",t.easeInSine="ease-in-sine",t.easeOutBack="ease-out-back",t.easeOutCirc="ease-out-circ",t.easeOutCubic="ease-out-cubic",t.easeOutLinear="ease-out-linear",t.easeOutQuad="ease-out-quad",t.easeOutQuart="ease-out-quart",t.easeOutQuint="ease-out-quint",t.easeOutExpo="ease-out-expo",t.easeOutSine="ease-out-sine",t.easeInOutBack="ease-in-out-back",t.easeInOutCirc="ease-in-out-circ",t.easeInOutCubic="ease-in-out-cubic",t.easeInOutLinear="ease-in-out-linear",t.easeInOutQuad="ease-in-out-quad",t.easeInOutQuart="ease-in-out-quart",t.easeInOutQuint="ease-in-out-quint",t.easeInOutExpo="ease-in-out-expo",t.easeInOutSine="ease-in-out-sine",t})(Te||{});var ti=dl();_e()||(window.tsParticles=ti);var Lo=(()=>{class t{initialized=new qr(!1);getInstallationStatus(){return this.initialized.asObservable()}async init(i){await i(ti),this.initialized.next(!0)}static \u0275fac=function(o){return new(o||t)};static \u0275prov=Wr({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),ml=(()=>{class t{platformId;particlesService;options;url;id;particlesInit;particlesLoaded=new Gr;subscription;destroy$=new Br;container;constructor(i,o){this.platformId=i,this.particlesService=o,this.id="tsparticles"}ngOnInit(){this.subscription=this.particlesService.getInstallationStatus().subscribe(()=>{this.container?.destroy(),this.loadParticles()})}ngAfterViewInit(){Zr(this.platformId)||this.loadParticles()}ngOnDestroy(){this.container?.destroy(),this.subscription?.unsubscribe(),this.destroy$.next()}loadParticles(){let i=o=>{this.container=o,this.particlesLoaded.emit(o)};Nr(this.particlesInit?this.particlesInit(ti):Promise.resolve()).pipe(Ur(()=>ti.load({id:this.id,url:this.url,options:this.options})),Hr(this.destroy$)).subscribe(i)}static \u0275fac=function(o){return new(o||t)(Gs(Qr),Gs(Lo))};static \u0275cmp=ft({type:t,selectors:[["ngx-particles"]],inputs:{options:"options",url:"url",id:"id",particlesInit:"particlesInit"},outputs:{particlesLoaded:"particlesLoaded"},standalone:!1,decls:1,vars:1,consts:[[3,"id"]],template:function(o,n){o&1&&Me(0,"div",0),o&2&&ht("id",n.id)},encapsulation:2})}return t})(),gl=(()=>{class t{static \u0275fac=function(o){return new(o||t)};static \u0275mod=Yr({type:t});static \u0275inj=jr({providers:[Lo]})}return t})();var Ao=class{constructor(){this.radius=0,this.mass=0}load(e){h(e)||(e.mass!==void 0&&(this.mass=e.mass),e.radius!==void 0&&(this.radius=e.radius))}};var Vo=class extends ${constructor(){super(),this.density=5,this.value=50,this.limit=new Ao}load(e){h(e)||(super.load(e),e.density!==void 0&&(this.density=e.density),Z(e.limit)?this.limit.radius=e.limit:this.limit.load(e.limit))}};var Xe=class{constructor(){this.color=new D,this.color.value="#000000",this.draggable=!1,this.opacity=1,this.destroy=!0,this.orbits=!1,this.size=new Vo}load(e){h(e)||(e.color!==void 0&&(this.color=D.create(this.color,e.color)),e.draggable!==void 0&&(this.draggable=e.draggable),this.name=e.name,e.opacity!==void 0&&(this.opacity=e.opacity),e.position!==void 0&&(this.position={},e.position.x!==void 0&&(this.position.x=b(e.position.x)),e.position.y!==void 0&&(this.position.y=b(e.position.y))),e.size!==void 0&&this.size.load(e.size),e.destroy!==void 0&&(this.destroy=e.destroy),e.orbits!==void 0&&(this.orbits=e.orbits))}};var ii=(function(t){return t.absorber="absorber",t})(ii||{});var hf=2,df=.033,pf=0,mf=0,gf=0,yf=0,xf=2,yl=Math.PI*xf,xl=0,Bo=class{constructor(e,i,o,n,s){this._calcPosition=()=>{let a=Ci({size:this._container.canvas.size,position:this.options.position});return z.create(a.x,a.y)},this._updateParticlePosition=(a,l)=>{if(a.destroyed)return;let c=this._container,u=c.canvas.size;if(a.needsNewPosition){let f=pr({size:u});a.position.setTo(f),a.velocity.setTo(a.initialVelocity),a.absorberOrbit=void 0,a.needsNewPosition=!1}if(this.options.orbits){if(a.absorberOrbit===void 0&&(a.absorberOrbit=z.origin,a.absorberOrbit.length=V(a.getPosition(),this.position),a.absorberOrbit.angle=v()*yl),a.absorberOrbit.length<=this.size&&!this.options.destroy){let y=Math.min(u.width,u.height),x=1,_=.1,w=.2;a.absorberOrbit.length=y*(x+(v()*w-_))}a.absorberOrbitDirection===void 0&&(a.absorberOrbitDirection=a.velocity.x>=xl?ie.clockwise:ie.counterClockwise);let f=a.absorberOrbit.length,d=a.absorberOrbit.angle,p=a.absorberOrbitDirection;a.velocity.setTo(z.origin);let m={x:p===ie.clockwise?Math.cos:Math.sin,y:p===ie.clockwise?Math.sin:Math.cos};a.position.x=this.position.x+f*m.x(d),a.position.y=this.position.y+f*m.y(d),a.absorberOrbit.length-=l.length,a.absorberOrbit.angle+=(a.retina.moveSpeed??xl)*c.retina.pixelRatio/100*c.retina.reduceFactor}else{let f=z.origin;f.length=l.length,f.angle=l.angle,a.velocity.addTo(f)}},this._absorbers=e,this._container=i,this._engine=o,this.initialPosition=s?z.create(s.x,s.y):void 0,n instanceof Xe?this.options=n:(this.options=new Xe,this.options.load(n)),this.dragging=!1,this.name=this.options.name,this.opacity=this.options.opacity,this.size=g(this.options.size.value)*i.retina.pixelRatio,this.mass=this.size*this.options.size.density*i.retina.reduceFactor;let r=this.options.size.limit;this.limit={radius:r.radius*i.retina.pixelRatio*i.retina.reduceFactor,mass:r.mass},this.color=oe(this._engine,this.options.color)??{b:0,g:0,r:0},this.position=this.initialPosition?.copy()??this._calcPosition()}attract(e){let i=this._container,o=this.options;if(o.draggable){let c=i.interactivity.mouse;c.clicking&&c.downPosition?V(this.position,c.downPosition)<=this.size&&(this.dragging=!0):this.dragging=!1,this.dragging&&c.position&&(this.position.x=c.position.x,this.position.y=c.position.y)}let n=e.getPosition(),{dx:s,dy:r,distance:a}=A(this.position,n),l=z.create(s,r);if(l.length=this.mass/Math.pow(a,hf)*i.retina.reduceFactor,a<this.size+e.getRadius()){let c=e.getRadius()*df*i.retina.pixelRatio;this.size>e.getRadius()&&a<this.size-e.getRadius()||e.absorberOrbit!==void 0&&e.absorberOrbit.length<pf?o.destroy?e.destroy():(e.needsNewPosition=!0,this._updateParticlePosition(e,l)):(o.destroy&&(e.size.value-=c),this._updateParticlePosition(e,l)),(this.limit.radius<=mf||this.size<this.limit.radius)&&(this.size+=c),(this.limit.mass<=gf||this.mass<this.limit.mass)&&(this.mass+=c*this.options.size.density*i.retina.reduceFactor)}else this._updateParticlePosition(e,l)}draw(e){e.translate(this.position.x,this.position.y),e.beginPath(),e.arc(Y.x,Y.y,this.size,yf,yl,!1),e.closePath(),e.fillStyle=ae(this.color,this.opacity),e.fill()}resize(){let e=this.initialPosition;this.position=e&&ke(e,this._container.canvas.size,z.origin)?e:this._calcPosition()}};var bl=0,qo=class{constructor(e,i){this._container=e,this._engine=i,this.array=[],this.absorbers=[],this.interactivityAbsorbers=[],e.getAbsorber=o=>o===void 0||Z(o)?this.array[o??bl]:this.array.find(n=>n.name===o),e.addAbsorber=async(o,n)=>this.addAbsorber(o,n)}async addAbsorber(e,i){let o=new Bo(this,this._container,this._engine,e,i);return this.array.push(o),Promise.resolve(o)}draw(e){for(let i of this.array)i.draw(e)}handleClickMode(e){let i=this.absorbers,o=this.interactivityAbsorbers;if(e===ii.absorber){let n=T(o),s=n??T(i),r=this._container.interactivity.mouse.clickPosition;this.addAbsorber(s,r)}}async init(){this.absorbers=this._container.actualOptions.absorbers,this.interactivityAbsorbers=this._container.actualOptions.interactivity.modes.absorbers;let e=S(this.absorbers,async i=>{await this.addAbsorber(i)});e instanceof Array?await Promise.all(e):await e}particleUpdate(e){for(let i of this.array)if(i.attract(e),e.destroyed)break}removeAbsorber(e){let i=this.array.indexOf(e);i>=bl&&this.array.splice(i,1)}resize(){for(let e of this.array)e.resize()}stop(){this.array=[]}};var No=class{constructor(e){this.id="absorbers",this._engine=e}async getPlugin(e){return Promise.resolve(new qo(e,this._engine))}loadOptions(e,i){!this.needsPlugin(e)&&!this.needsPlugin(i)||(i?.absorbers&&(e.absorbers=S(i.absorbers,o=>{let n=new Xe;return n.load(o),n})),e.interactivity.modes.absorbers=S(i?.interactivity?.modes?.absorbers,o=>{let n=new Xe;return n.load(o),n}))}needsPlugin(e){if(!e)return!1;let i=e.absorbers;return N(i)?!!i.length:i?!0:!!(e.interactivity?.events?.onClick?.mode&&M(ii.absorber,e.interactivity.events.onClick.mode))}};async function vl(t,e=!0){t.checkVersion("3.9.1"),await t.addPlugin(new No(t),e)}var Uo=class{load(e){h(e)||(e.bottom!==void 0&&(this.bottom=b(e.bottom)),e.left!==void 0&&(this.left=b(e.left)),e.right!==void 0&&(this.right=b(e.right)),e.top!==void 0&&(this.top=b(e.top)))}};var oi=(function(t){return t.none="none",t.split="split",t})(oi||{});var Ho=class extends ${constructor(){super(),this.value=3}};var Wo=class extends ${constructor(){super(),this.value={min:4,max:9}}};var jo=class{constructor(){this.count=1,this.factor=new Ho,this.rate=new Wo,this.sizeOffset=!0}load(e){h(e)||(e.color!==void 0&&(this.color=D.create(this.color,e.color)),e.count!==void 0&&(this.count=e.count),this.factor.load(e.factor),this.rate.load(e.rate),this.particles=S(e.particles,i=>C({},i)),e.sizeOffset!==void 0&&(this.sizeOffset=e.sizeOffset),e.colorOffset&&(this.colorOffset=this.colorOffset??{},e.colorOffset.h!==void 0&&(this.colorOffset.h=e.colorOffset.h),e.colorOffset.s!==void 0&&(this.colorOffset.s=e.colorOffset.s),e.colorOffset.l!==void 0&&(this.colorOffset.l=e.colorOffset.l)))}};var $o=class{constructor(){this.bounds=new Uo,this.mode=oi.none,this.split=new jo}load(e){h(e)||(e.mode&&(this.mode=e.mode),e.bounds&&this.bounds.load(e.bounds),this.split.load(e.split))}};var Go=0,bf=.5,vf=0,wf=1,_f=500,kf=0;function Pf(t,e,i,o){let n=i.options.destroy;if(!n)return;let s=n.split,r=Ot(t,e,i.options),a=g(s.factor.value),l=i.getFillColor();s.color?r.color.load(s.color):s.colorOffset&&l?r.color.load({value:{hsl:{h:l.h+g(s.colorOffset.h??Go),s:l.s+g(s.colorOffset.s??Go),l:l.l+g(s.colorOffset.l??Go)}}}):r.color.load({value:{hsl:i.getFillColor()}}),r.move.load({center:{x:i.position.x,y:i.position.y,mode:re.precise}}),Z(r.size.value)?r.size.value/=a:(r.size.value.min/=a,r.size.value.max/=a),r.load(o);let c=s.sizeOffset?b(-i.size.value,i.size.value):Go,u={x:i.position.x+U(c),y:i.position.y+U(c)};return e.particles.addParticle(u,r,i.group,f=>f.size.value<bf?!1:(f.velocity.length=U(b(i.velocity.length,f.velocity.length)),f.splitCount=(i.splitCount??vf)+wf,f.unbreakable=!0,setTimeout(()=>{f.unbreakable=!1},_f),!0))}function wl(t,e,i){let o=i.options.destroy;if(!o)return;let n=o.split;if(n.count>=kf&&(i.splitCount===void 0||i.splitCount++>n.count))return;let s=g(n.rate.value),r=T(n.particles);for(let a=0;a<s;a++)Pf(t,e,i,r)}var Qo=class{constructor(e,i){this.container=i,this.engine=e}init(e){let i=this.container,o=e.options,n=o.destroy;if(!n)return;e.splitCount=0;let s=n.bounds;e.destroyBounds||(e.destroyBounds={});let{bottom:r,left:a,right:l,top:c}=s,{destroyBounds:u}=e,f=i.canvas.size;r&&(u.bottom=g(r)*f.height/100),a&&(u.left=g(a)*f.width/100),l&&(u.right=g(l)*f.width/100),c&&(u.top=g(c)*f.height/100)}isEnabled(e){return!e.destroyed}loadOptions(e,...i){e.destroy||(e.destroy=new $o);for(let o of i)e.destroy.load(o?.destroy)}particleDestroyed(e,i){if(i)return;let o=e.options.destroy;o&&o.mode===oi.split&&wl(this.engine,this.container,e)}update(e){if(!this.isEnabled(e))return;let i=e.getPosition(),o=e.destroyBounds;o&&(o.bottom!==void 0&&i.y>=o.bottom||o.left!==void 0&&i.x<=o.left||o.right!==void 0&&i.x>=o.right||o.top!==void 0&&i.y<=o.top)&&e.destroy()}};async function _l(t,e=!0){t.checkVersion("3.9.1"),await t.addParticleUpdater("destroy",i=>Promise.resolve(new Qo(t,i)),e)}var Xo=class{constructor(){this.wait=!1}load(e){h(e)||(e.count!==void 0&&(this.count=e.count),e.delay!==void 0&&(this.delay=b(e.delay)),e.duration!==void 0&&(this.duration=b(e.duration)),e.wait!==void 0&&(this.wait=e.wait))}};var Yo=class{constructor(){this.quantity=1,this.delay=.1}load(e){h(e)||(e.quantity!==void 0&&(this.quantity=b(e.quantity)),e.delay!==void 0&&(this.delay=b(e.delay)))}};var Zo=class{constructor(){this.color=!1,this.opacity=!1}load(e){h(e)||(e.color!==void 0&&(this.color=e.color),e.opacity!==void 0&&(this.opacity=e.opacity))}};var Ko=class{constructor(){this.options={},this.replace=new Zo,this.type="square"}load(e){h(e)||(e.options!==void 0&&(this.options=C({},e.options??{})),this.replace.load(e.replace),e.type!==void 0&&(this.type=e.type))}};var St=class{constructor(){this.mode=re.percent,this.height=0,this.width=0}load(e){h(e)||(e.mode!==void 0&&(this.mode=e.mode),e.height!==void 0&&(this.height=e.height),e.width!==void 0&&(this.width=e.width))}};var me=class{constructor(){this.autoPlay=!0,this.fill=!0,this.life=new Xo,this.rate=new Yo,this.shape=new Ko,this.startCount=0}load(e){h(e)||(e.autoPlay!==void 0&&(this.autoPlay=e.autoPlay),e.size!==void 0&&(this.size||(this.size=new St),this.size.load(e.size)),e.direction!==void 0&&(this.direction=e.direction),this.domId=e.domId,e.fill!==void 0&&(this.fill=e.fill),this.life.load(e.life),this.name=e.name,this.particles=S(e.particles,i=>C({},i)),this.rate.load(e.rate),this.shape.load(e.shape),e.position!==void 0&&(this.position={},e.position.x!==void 0&&(this.position.x=b(e.position.x)),e.position.y!==void 0&&(this.position.y=b(e.position.y))),e.spawnColor!==void 0&&(this.spawnColor===void 0&&(this.spawnColor=new Ie),this.spawnColor.load(e.spawnColor)),e.startCount!==void 0&&(this.startCount=e.startCount))}};var ni=(function(t){return t.emitter="emitter",t})(ni||{});var kl=.5,Pl=0,Jo=0,Ol=0,Of=0,Cf=-1,Mf=1;function Cl(t,e){t.color?t.color.value=e:t.color={value:e}}var en=class{constructor(e,i,o,n,s){this.emitters=i,this.container=o,this._destroy=()=>{this._mutationObserver?.disconnect(),this._mutationObserver=void 0,this._resizeObserver?.disconnect(),this._resizeObserver=void 0,this.emitters.removeEmitter(this),this._engine.dispatchEvent("emitterDestroyed",{container:this.container,data:{emitter:this}})},this._prepareToDie=()=>{if(this._paused)return;let c=this.options.life?.duration!==void 0?g(this.options.life.duration):void 0;(this._lifeCount>0||this._immortal)&&c!==void 0&&c>0&&(this._duration=c*1e3)},this._setColorAnimation=(c,u,f,d=Mf)=>{let p=this.container;if(!c.enable)return u;let m=U(c.offset),y=g(this.options.rate.delay),x=p.retina.reduceFactor?y*1e3/p.retina.reduceFactor:1/0,_=0,w=g(c.speed??_);return(u+w*p.fpsLimit/x+m*d)%f},this._engine=e,this._currentDuration=0,this._currentEmitDelay=0,this._currentSpawnDelay=0,this._initialPosition=s,n instanceof me?this.options=n:(this.options=new me,this.options.load(n)),this._spawnDelay=o.retina.reduceFactor?g(this.options.life.delay??Pl)*1e3/o.retina.reduceFactor:1/0,this.position=this._initialPosition??this._calcPosition(),this.name=this.options.name,this.fill=this.options.fill,this._firstSpawn=!this.options.life.wait,this._startParticlesAdded=!1;let r=C({},this.options.particles);if(r??={},r.move??={},r.move.direction??=this.options.direction,this.options.spawnColor&&(this.spawnColor=ce(this._engine,this.options.spawnColor)),this._paused=!this.options.autoPlay,this._particlesOptions=r,this._size=this._calcSize(),this.size=gr(this._size,this.container.canvas.size),this._lifeCount=this.options.life.count??Cf,this._immortal=this._lifeCount<=Jo,this.options.domId){let c=document.getElementById(this.options.domId);c&&(this._mutationObserver=new MutationObserver(()=>{this.resize()}),this._resizeObserver=new ResizeObserver(()=>{this.resize()}),this._mutationObserver.observe(c,{attributes:!0,attributeFilter:["style","width","height"]}),this._resizeObserver.observe(c))}let a=this.options.shape,l=this._engine.emitterShapeManager?.getShapeGenerator(a.type);l&&(this._shape=l.generate(this.position,this.size,this.fill,a.options)),this._engine.dispatchEvent("emitterCreated",{container:o,data:{emitter:this}}),this.play()}externalPause(){this._paused=!0,this.pause()}externalPlay(){this._paused=!1,this.play()}async init(){await this._shape?.init()}pause(){this._paused||delete this._emitDelay}play(){if(this._paused||!((this._lifeCount>Jo||this._immortal||!this.options.life.count)&&(this._firstSpawn||this._currentSpawnDelay>=(this._spawnDelay??Ol))))return;let e=this.container;if(this._emitDelay===void 0){let i=g(this.options.rate.delay);this._emitDelay=e.retina.reduceFactor?i*1e3/e.retina.reduceFactor:1/0}(this._lifeCount>Jo||this._immortal)&&this._prepareToDie()}resize(){let e=this._initialPosition,i=this.container;this.position=e&&ke(e,i.canvas.size,z.origin)?e:this._calcPosition(),this._size=this._calcSize(),this.size=gr(this._size,i.canvas.size),this._shape?.resize(this.position,this.size)}update(e){if(this._paused)return;let i=this.container;this._firstSpawn&&(this._firstSpawn=!1,this._currentSpawnDelay=this._spawnDelay??Ol,this._currentEmitDelay=this._emitDelay??Of),this._startParticlesAdded||(this._startParticlesAdded=!0,this._emitParticles(this.options.startCount)),this._duration!==void 0&&(this._currentDuration+=e.value,this._currentDuration>=this._duration&&(this.pause(),this._spawnDelay!==void 0&&delete this._spawnDelay,this._immortal||this._lifeCount--,this._lifeCount>Jo||this._immortal?(this.position=this._calcPosition(),this._shape?.resize(this.position,this.size),this._spawnDelay=i.retina.reduceFactor?g(this.options.life.delay??Pl)*1e3/i.retina.reduceFactor:1/0):this._destroy(),this._currentDuration-=this._duration,delete this._duration)),this._spawnDelay!==void 0&&(this._currentSpawnDelay+=e.value,this._currentSpawnDelay>=this._spawnDelay&&(this._engine.dispatchEvent("emitterPlay",{container:this.container}),this.play(),this._currentSpawnDelay-=this._currentSpawnDelay,delete this._spawnDelay)),this._emitDelay!==void 0&&(this._currentEmitDelay+=e.value,this._currentEmitDelay>=this._emitDelay&&(this._emit(),this._currentEmitDelay-=this._emitDelay))}_calcPosition(){let e=this.container;if(this.options.domId){let i=document.getElementById(this.options.domId);if(i){let o=i.getBoundingClientRect(),n=e.retina.pixelRatio;return{x:(o.x+o.width*kl)*n,y:(o.y+o.height*kl)*n}}}return Ci({size:e.canvas.size,position:this.options.position})}_calcSize(){let e=this.container;if(this.options.domId){let i=document.getElementById(this.options.domId);if(i){let o=i.getBoundingClientRect();return{width:o.width*e.retina.pixelRatio,height:o.height*e.retina.pixelRatio,mode:re.precise}}}return this.options.size??(()=>{let i=new St;return i.load({height:0,mode:re.percent,width:0}),i})()}_emit(){if(this._paused)return;let e=g(this.options.rate.quantity);this._emitParticles(e)}_emitParticles(e){let i=T(this._particlesOptions),o=this.container.retina.reduceFactor;for(let n=0;n<e*o;n++){let s=C({},i);if(this.spawnColor){let l=this.options.spawnColor?.animation;if(l){let c={h:360,s:100,l:100},u=3.6;this.spawnColor.h=this._setColorAnimation(l.h,this.spawnColor.h,c.h,u),this.spawnColor.s=this._setColorAnimation(l.s,this.spawnColor.s,c.s),this.spawnColor.l=this._setColorAnimation(l.l,this.spawnColor.l,c.l)}Cl(s,this.spawnColor)}let r=this.options.shape,a=this.position;if(this._shape){let l=this._shape.randomPosition();if(l){a=l.position;let c=r.replace;c.color&&l.color&&Cl(s,l.color),c.opacity&&(s.opacity?s.opacity.value=l.opacity:s.opacity={value:l.opacity})}else a=null}a&&this.container.particles.addParticle(a,s)}}};var tn=class{constructor(e,i){this.container=i,this._engine=e,this.array=[],this.emitters=[],this.interactivityEmitters={random:{count:1,enable:!1},value:[]};let o=0;i.getEmitter=n=>n===void 0||Z(n)?this.array[n??o]:this.array.find(s=>s.name===n),i.addEmitter=async(n,s)=>this.addEmitter(n,s),i.removeEmitter=n=>{let s=i.getEmitter(n);s&&this.removeEmitter(s)},i.playEmitter=n=>{let s=i.getEmitter(n);s&&s.externalPlay()},i.pauseEmitter=n=>{let s=i.getEmitter(n);s&&s.externalPause()}}async addEmitter(e,i){let o=new me;o.load(e);let n=new en(this._engine,this,this.container,o,i);return await n.init(),this.array.push(n),n}handleClickMode(e){let i=this.emitters,o=this.interactivityEmitters;if(e!==ni.emitter)return;let n;if(o&&N(o.value))if(o.value.length>0&&o.random.enable){n=[];let l=[];for(let c=0;c<o.random.count;c++){let u=mr(o.value);if(l.includes(u)&&l.length<o.value.length){c--;continue}l.push(u),n.push(Ne(o.value,u))}}else n=o.value;else n=o?.value;let s=n??i,r=this.container.interactivity.mouse.clickPosition;S(s,async a=>{await this.addEmitter(a,r)})}async init(){if(this.emitters=this.container.actualOptions.emitters,this.interactivityEmitters=this.container.actualOptions.interactivity.modes.emitters,!!this.emitters)if(N(this.emitters))for(let e of this.emitters)await this.addEmitter(e);else await this.addEmitter(this.emitters)}pause(){for(let e of this.array)e.pause()}play(){for(let e of this.array)e.play()}removeEmitter(e){let i=this.array.indexOf(e);i>=0&&this.array.splice(i,1)}resize(){for(let e of this.array)e.resize()}stop(){this.array=[]}update(e){for(let i of this.array)i.update(e)}};var on=class{constructor(e){this._engine=e,this.id="emitters"}getPlugin(e){return Promise.resolve(new tn(this._engine,e))}loadOptions(e,i){if(!this.needsPlugin(e)&&!this.needsPlugin(i))return;i?.emitters&&(e.emitters=S(i.emitters,n=>{let s=new me;return s.load(n),s}));let o=i?.interactivity?.modes?.emitters;if(o)if(N(o))e.interactivity.modes.emitters={random:{count:1,enable:!0},value:o.map(n=>{let s=new me;return s.load(n),s})};else{let n=o;if(n.value!==void 0)if(N(n.value))e.interactivity.modes.emitters={random:{count:n.random.count??1,enable:n.random.enable??!1},value:n.value.map(r=>{let a=new me;return a.load(r),a})};else{let r=new me;r.load(n.value),e.interactivity.modes.emitters={random:{count:n.random.count??1,enable:n.random.enable??!1},value:r}}else(e.interactivity.modes.emitters={random:{count:1,enable:!1},value:new me}).value.load(o)}}needsPlugin(e){if(!e)return!1;let i=e.emitters;return N(i)&&!!i.length||i!==void 0||!!e.interactivity?.events?.onClick?.mode&&M(ni.emitter,e.interactivity.events.onClick.mode)}};var Pr=new Map,nn=class{constructor(e){this._engine=e}addShapeGenerator(e,i){this.getShapeGenerator(e)||Pr.set(e,i)}getShapeGenerator(e){return Pr.get(e)}getSupportedShapeGenerators(){return Pr.keys()}};var zt=class{constructor(e,i,o,n){this.position=e,this.size=i,this.fill=o,this.options=n}resize(e,i){this.position=e,this.size=i}};async function Ml(t,e=!0){t.checkVersion("3.9.1"),t.emitterShapeManager||(t.emitterShapeManager=new nn(t)),t.addEmitterShapeGenerator||(t.addEmitterShapeGenerator=(o,n)=>{t.emitterShapeManager?.addShapeGenerator(o,n)});let i=new on(t);await t.addPlugin(i,e)}var si=.25,Or=2,Sf=Math.PI*Or,Sl=2,zl=.5,sn=class extends zt{constructor(e,i,o,n){super(e,i,o,n)}async init(){}randomPosition(){let e=this.size,i=this.fill,o=this.position,n=(f,d)=>{let p=v()*si,m=Math.atan(d/f*Math.tan(Sf*p)),y=v();return y<si?m:y<Or*si?Math.PI-m:y<Or*si+si?Math.PI+m:-m},s=(f,d,p)=>f*d/Math.sqrt((d*Math.cos(p))**Sl+(f*Math.sin(p))**Sl),[r,a]=[e.width*zl,e.height*zl],l=n(r,a),c=s(r,a,l),u=i?c*Math.sqrt(v()):c;return{position:{x:o.x+u*Math.cos(l),y:o.y+u*Math.sin(l)}}}};var rn=class{generate(e,i,o,n){return new sn(e,i,o,n)}};async function Rl(t,e=!0){let i=t;i.checkVersion("3.9.1"),i.addEmitterShapeGenerator?.("circle",new rn),await i.refresh(e)}var zf=4,ri=(function(t){return t[t.TopLeft=0]="TopLeft",t[t.TopRight=1]="TopRight",t[t.BottomRight=2]="BottomRight",t[t.BottomLeft=3]="BottomLeft",t})(ri||{});function Dl(t,e){return t+e*(v()-.5)}var an=class extends zt{constructor(e,i,o,n){super(e,i,o,n)}async init(){}randomPosition(){let e=this.fill,i=this.position,o=this.size;if(e)return{position:{x:Dl(i.x,o.width),y:Dl(i.y,o.height)}};{let n=o.width*.5,s=o.height*.5,r=Math.floor(v()*zf),a=(v()-.5)*W;switch(r){case ri.TopLeft:return{position:{x:i.x+a*n,y:i.y-s}};case ri.TopRight:return{position:{x:i.x-n,y:i.y+a*s}};case ri.BottomRight:return{position:{x:i.x+a*n,y:i.y+s}};case ri.BottomLeft:default:return{position:{x:i.x+n,y:i.y+a*s}}}}}};var ln=class{generate(e,i,o,n){return new an(e,i,o,n)}};async function El(t,e=!0){let i=t;i.checkVersion("3.9.1"),i.addEmitterShapeGenerator?.("square",new ln),await i.refresh(e)}var cn=class{constructor(){this.delay=1,this.pauseOnStop=!1,this.quantity=1}load(e){h(e)||(e.delay!==void 0&&(this.delay=e.delay),e.quantity!==void 0&&(this.quantity=e.quantity),e.particles!==void 0&&(this.particles=C({},e.particles)),e.pauseOnStop!==void 0&&(this.pauseOnStop=e.pauseOnStop))}};var Il="trail",un=class extends H{constructor(e){super(e),this._delay=0}clear(){}init(){}interact(e){let i=this.container,{interactivity:o}=i;if(!i.retina.reduceFactor)return;let n=i.actualOptions,s=n.interactivity.modes.trail;if(!s)return;let r=s.delay*1e3/this.container.retina.reduceFactor;if(this._delay<r&&(this._delay+=e.value),this._delay<r)return;let a=!(s.pauseOnStop&&(o.mouse.position===this._lastPosition||o.mouse.position?.x===this._lastPosition?.x&&o.mouse.position?.y===this._lastPosition?.y)),l=i.interactivity.mouse.position;l?this._lastPosition=q({},l):delete this._lastPosition,a&&i.particles.push(s.quantity,i.interactivity.mouse,s.particles),this._delay-=r}isEnabled(e){let i=this.container,o=i.actualOptions,n=i.interactivity.mouse,s=(e?.interactivity??o.interactivity).events;return n.clicking&&n.inside&&!!n.position&&M(Il,s.onClick.mode)||n.inside&&!!n.position&&M(Il,s.onHover.mode)}loadModeOptions(e,...i){e.trail||(e.trail=new cn);for(let o of i)e.trail.load(o?.trail)}reset(){}};async function Tl(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("externalTrail",i=>Promise.resolve(new un(i)),e)}var Ye=(function(t){return t.both="both",t.horizontal="horizontal",t.vertical="vertical",t})(Ye||{});var Rf=2,Fl=Math.PI*Rf,Df=360;function Ll(t,e){let i=e.options.roll;if(!i?.enable){e.roll={enable:!1,horizontal:!1,vertical:!1,angle:0,speed:0};return}if(e.roll={enable:i.enable,horizontal:i.mode===Ye.horizontal||i.mode===Ye.both,vertical:i.mode===Ye.vertical||i.mode===Ye.both,angle:v()*Fl,speed:g(i.speed)/Df},i.backColor)e.backColor=ce(t,i.backColor);else if(i.darken.enable&&i.enlighten.enable){let o=v()>=.5?Re.darken:Re.enlighten;e.roll.alter={type:o,value:g(o===Re.darken?i.darken.value:i.enlighten.value)}}else i.darken.enable?e.roll.alter={type:Re.darken,value:g(i.darken.value)}:i.enlighten.enable&&(e.roll.alter={type:Re.enlighten,value:g(i.enlighten.value)})}function Al(t,e){let i=t.options.roll,o=t.roll;if(!o||!i?.enable)return;let n=o.speed*e.factor,s=Fl;o.angle+=n,o.angle>s&&(o.angle-=s)}var ai=class{constructor(){this.enable=!1,this.value=0}load(e){h(e)||(e.enable!==void 0&&(this.enable=e.enable),e.value!==void 0&&(this.value=b(e.value)))}};var fn=class{constructor(){this.darken=new ai,this.enable=!1,this.enlighten=new ai,this.mode=Ye.vertical,this.speed=25}load(e){h(e)||(e.backColor!==void 0&&(this.backColor=D.create(this.backColor,e.backColor)),this.darken.load(e.darken),e.enable!==void 0&&(this.enable=e.enable),this.enlighten.load(e.enlighten),e.mode!==void 0&&(this.mode=e.mode),e.speed!==void 0&&(this.speed=b(e.speed)))}};var hn=class{constructor(e){this._engine=e}getTransformValues(e){let i=e.roll?.enable&&e.roll,o=i&&i.horizontal,n=i&&i.vertical;return{a:o?Math.cos(i.angle):void 0,d:n?Math.sin(i.angle):void 0}}init(e){Ll(this._engine,e)}isEnabled(e){let i=e.options.roll;return!e.destroyed&&!e.spawning&&!!i?.enable}loadOptions(e,...i){e.roll||(e.roll=new fn);for(let o of i)e.roll.load(o?.roll)}update(e,i){this.isEnabled(e)&&Al(e,i)}};async function Vl(t,e=!0){t.checkVersion("3.9.1"),await t.addParticleUpdater("roll",()=>Promise.resolve(new hn(t)),e)}var Cr=.5,Ef=2,Ze=0,ve=1,Bl=60,ql=0,If=.01,Tf=Math.PI*Ef;function Nl(t){let e=t.initialPosition,{dx:i,dy:o}=A(e,t.position),n=Math.abs(i),s=Math.abs(o),{maxDistance:r}=t.retina,a=r.horizontal,l=r.vertical;if(!a&&!l)return;let c=(a&&n>=a)??!1,u=(l&&s>=l)??!1;if((c||u)&&!t.misplaced)t.misplaced=!!a&&n>a||!!l&&s>l,a&&(t.velocity.x=t.velocity.y*Cr-t.velocity.x),l&&(t.velocity.y=t.velocity.x*Cr-t.velocity.y);else if((!a||n<a)&&(!l||s<l)&&t.misplaced)t.misplaced=!1;else if(t.misplaced){let f=t.position,d=t.velocity;a&&(f.x<e.x&&d.x<Ze||f.x>e.x&&d.x>Ze)&&(d.x*=-v()),l&&(f.y<e.y&&d.y<Ze||f.y>e.y&&d.y>Ze)&&(d.y*=-v())}}function Ul(t,e,i,o,n,s,r){Ff(t,r);let a=t.gravity,l=a?.enable&&a.inverse?-ve:ve;n&&i&&(t.velocity.x+=n*r.factor/(Bl*i)),a?.enable&&i&&(t.velocity.y+=l*(a.acceleration*r.factor)/(Bl*i));let c=t.moveDecay;t.velocity.multTo(c);let u=t.velocity.mult(i);a?.enable&&o>Ze&&(!a.inverse&&u.y>=Ze&&u.y>=o||a.inverse&&u.y<=Ze&&u.y<=-o)&&(u.y=l*o,i&&(t.velocity.y=u.y/i));let f=t.options.zIndex,d=(ve-t.zIndexFactor)**f.velocityRate;u.multTo(d),u.multTo(s);let{position:p}=t;p.addTo(u),e.vibrate&&(p.x+=Math.sin(p.x*Math.cos(p.y))*s,p.y+=Math.cos(p.y*Math.sin(p.x))*s)}function Hl(t,e,i){let o=t.container;if(!t.spin)return;let n=t.spin.direction===ie.clockwise,s={x:n?Math.cos:Math.sin,y:n?Math.sin:Math.cos};t.position.x=t.spin.center.x+t.spin.radius*s.x(t.spin.angle)*i,t.position.y=t.spin.center.y+t.spin.radius*s.y(t.spin.angle)*i,t.spin.radius+=t.spin.acceleration*i;let r=Math.max(o.canvas.size.width,o.canvas.size.height),a=r*Cr;t.spin.radius>a?(t.spin.radius=a,t.spin.acceleration*=-ve):t.spin.radius<ql&&(t.spin.radius=ql,t.spin.acceleration*=-ve),t.spin.angle+=e*If*(ve-t.spin.radius/r)}function Ff(t,e){let i=t.options,o=i.move.path;if(!o.enable)return;if(t.lastPathTime<=t.pathDelay){t.lastPathTime+=e.value;return}let s=t.pathGenerator?.generate(t,e);s&&t.velocity.addTo(s),o.clamp&&(t.velocity.x=K(t.velocity.x,-ve,ve),t.velocity.y=K(t.velocity.y,-ve,ve)),t.lastPathTime-=t.pathDelay}function Wl(t){return t.slow.inRange?t.slow.factor:ve}function jl(t){let e=t.container,i=t.options,o=i.move.spin;if(!o.enable)return;let n=o.position??{x:50,y:50},s=.01,r={x:n.x*s*e.canvas.size.width,y:n.y*s*e.canvas.size.height},a=t.getPosition(),l=V(a,r),c=g(o.acceleration);t.retina.spinAcceleration=c*e.retina.pixelRatio,t.spin={center:r,direction:t.velocity.x>=Ze?ie.clockwise:ie.counterClockwise,angle:v()*Tf,radius:l,acceleration:t.retina.spinAcceleration}}var Lf=2,Af=1,Vf=1,dn=class{init(e){let i=e.options,o=i.move.gravity;e.gravity={enable:o.enable,acceleration:g(o.acceleration),inverse:o.inverse},jl(e)}isEnabled(e){return!e.destroyed&&e.options.move.enable}move(e,i){let o=e.options,n=o.move;if(!n.enable)return;let s=e.container,r=s.retina.pixelRatio;e.retina.moveSpeed??=g(n.speed)*r,e.retina.moveDrift??=g(e.options.move.drift)*r;let a=Wl(e),l=s.retina.reduceFactor,c=e.retina.moveSpeed,u=e.retina.moveDrift,f=le(o.size.value)*r,d=n.size?e.getRadius()/f:Af,p=i.factor||Vf,m=c*d*a*p/Lf,y=e.retina.maxSpeed??s.retina.maxSpeed;n.spin.enable?Hl(e,m,l):Ul(e,n,m,y,u,l,i),Nl(e)}};async function $l(t,e=!0){t.checkVersion("3.9.1"),await t.addMover("base",()=>Promise.resolve(new dn),e)}var Bf=Math.PI*2,qf=0,Gl={x:0,y:0};function Ql(t){let{context:e,particle:i,radius:o}=t;i.circleRange||(i.circleRange={min:qf,max:Bf});let n=i.circleRange;e.arc(Gl.x,Gl.y,o,n.min,n.max,!1)}var Nf=12,Uf=360,Xl=0,pn=class{constructor(){this.validTypes=["circle"]}draw(e){Ql(e)}getSidesCount(){return Nf}particleInit(e,i){let o=i.shapeData,n=o?.angle??{max:Uf,min:Xl};i.circleRange=ze(n)?{min:ue(n.min),max:ue(n.max)}:{min:Xl,max:ue(n)}}};async function Yl(t,e=!0){t.checkVersion("3.9.1"),await t.addShape(new pn,e)}var mn=class{constructor(e,i){this._container=e,this._engine=i}init(e){let i=ce(this._engine,e.options.color,e.id,e.options.reduceDuplicates);i&&(e.color=Ti(i,e.options.color.animation,this._container.retina.reduceFactor))}isEnabled(e){let{h:i,s:o,l:n}=e.options.color.animation,{color:s}=e;return!e.destroyed&&!e.spawning&&(s?.h.value!==void 0&&i.enable||s?.s.value!==void 0&&o.enable||s?.l.value!==void 0&&n.enable)}update(e,i){Fi(e.color,i)}};async function Zl(t,e=!0){t.checkVersion("3.9.1"),await t.addParticleUpdater("color",i=>Promise.resolve(new mn(i,t)),e)}var Rt=(function(t){return t[t.r=1]="r",t[t.g=2]="g",t[t.b=3]="b",t[t.a=4]="a",t})(Rt||{}),Hf=/^#?([a-f\d])([a-f\d])([a-f\d])([a-f\d])?$/i,Wf=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})?$/i,gn=16,jf=1,$f=255,yn=class{constructor(){this.key="hex",this.stringPrefix="#"}handleColor(e){return this._parseString(e.value)}handleRangeColor(e){return this._parseString(e.value)}parseString(e){return this._parseString(e)}_parseString(e){if(typeof e!="string"||!e?.startsWith(this.stringPrefix))return;let i=e.replace(Hf,(n,s,r,a,l)=>s+s+r+r+a+a+(l!==void 0?l+l:"")),o=Wf.exec(i);return o?{a:o[Rt.a]!==void 0?parseInt(o[Rt.a],gn)/$f:jf,b:parseInt(o[Rt.b],gn),g:parseInt(o[Rt.g],gn),r:parseInt(o[Rt.r],gn)}:void 0}};async function Kl(t,e=!0){t.checkVersion("3.9.1"),await t.addColorManager(new yn,e)}var li=(function(t){return t[t.h=1]="h",t[t.s=2]="s",t[t.l=3]="l",t[t.a=5]="a",t})(li||{}),xn=class{constructor(){this.key="hsl",this.stringPrefix="hsl"}handleColor(e){let i=e.value,o=i.hsl??e.value;if(o.h!==void 0&&o.s!==void 0&&o.l!==void 0)return it(o)}handleRangeColor(e){let i=e.value,o=i.hsl??e.value;if(o.h!==void 0&&o.l!==void 0)return it({h:g(o.h),l:g(o.l),s:g(o.s)})}parseString(e){if(!e.startsWith("hsl"))return;let i=/hsla?\(\s*(\d+)\s*[\s,]\s*(\d+)%\s*[\s,]\s*(\d+)%\s*([\s,]\s*(0|1|0?\.\d+|(\d{1,3})%)\s*)?\)/i,o=i.exec(e),n=4,s=1,r=10;return o?il({a:o.length>n?Mi(o[li.a]):s,h:parseInt(o[li.h],r),l:parseInt(o[li.l],r),s:parseInt(o[li.s],r)}):void 0}};async function Jl(t,e=!0){t.checkVersion("3.9.1"),await t.addColorManager(new xn,e)}var bn=class{constructor(e){this.container=e}init(e){let i=e.options.opacity,o=1;e.opacity=Di(i,o);let n=i.animation;n.enable&&(e.opacity.velocity=g(n.speed)/100*this.container.retina.reduceFactor,n.sync||(e.opacity.velocity*=v()))}isEnabled(e){return!e.destroyed&&!e.spawning&&!!e.opacity&&e.opacity.enable&&((e.opacity.maxLoops??0)<=0||(e.opacity.maxLoops??0)>0&&(e.opacity.loops??0)<(e.opacity.maxLoops??0))}reset(e){e.opacity&&(e.opacity.time=0,e.opacity.loops=0)}update(e,i){!this.isEnabled(e)||!e.opacity||He(e,e.opacity,!0,e.options.opacity.animation.destroy,i)}};async function ec(t,e=!0){t.checkVersion("3.9.1"),await t.addParticleUpdater("opacity",i=>Promise.resolve(new bn(i)),e)}var vn=0,Dt=0;function tc(t){if(t.outMode!==F.bounce&&t.outMode!==F.split||t.direction!==O.left&&t.direction!==O.right)return;t.bounds.right<Dt&&t.direction===O.left?t.particle.position.x=t.size+t.offset.x:t.bounds.left>t.canvasSize.width&&t.direction===O.right&&(t.particle.position.x=t.canvasSize.width-t.size-t.offset.x);let e=t.particle.velocity.x,i=!1;if(t.direction===O.right&&t.bounds.right>=t.canvasSize.width&&e>vn||t.direction===O.left&&t.bounds.left<=Dt&&e<vn){let n=g(t.particle.options.bounce.horizontal.value);t.particle.velocity.x*=-n,i=!0}if(!i)return;let o=t.offset.x+t.size;t.bounds.right>=t.canvasSize.width&&t.direction===O.right?t.particle.position.x=t.canvasSize.width-o:t.bounds.left<=Dt&&t.direction===O.left&&(t.particle.position.x=o),t.outMode===F.split&&t.particle.destroy()}function ic(t){if(t.outMode!==F.bounce&&t.outMode!==F.split||t.direction!==O.bottom&&t.direction!==O.top)return;t.bounds.bottom<Dt&&t.direction===O.top?t.particle.position.y=t.size+t.offset.y:t.bounds.top>t.canvasSize.height&&t.direction===O.bottom&&(t.particle.position.y=t.canvasSize.height-t.size-t.offset.y);let e=t.particle.velocity.y,i=!1;if(t.direction===O.bottom&&t.bounds.bottom>=t.canvasSize.height&&e>vn||t.direction===O.top&&t.bounds.top<=Dt&&e<vn){let n=g(t.particle.options.bounce.vertical.value);t.particle.velocity.y*=-n,i=!0}if(!i)return;let o=t.offset.y+t.size;t.bounds.bottom>=t.canvasSize.height&&t.direction===O.bottom?t.particle.position.y=t.canvasSize.height-o:t.bounds.top<=Dt&&t.direction===O.top&&(t.particle.position.y=o),t.outMode===F.split&&t.particle.destroy()}var wn=class{constructor(e){this.container=e,this.modes=[F.bounce,F.split]}update(e,i,o,n){if(!this.modes.includes(n))return;let s=this.container,r=!1;for(let d of s.plugins.values())if(d.particleBounce!==void 0&&(r=d.particleBounce(e,o,i)),r)break;if(r)return;let a=e.getPosition(),l=e.offset,c=e.getRadius(),u=Ue(a,c),f=s.canvas.size;tc({particle:e,outMode:n,direction:i,bounds:u,canvasSize:f,offset:l,size:c}),ic({particle:e,outMode:n,direction:i,bounds:u,canvasSize:f,offset:l,size:c})}};var _n=0,kn=class{constructor(e){this.container=e,this.modes=[F.destroy]}update(e,i,o,n){if(!this.modes.includes(n))return;let s=this.container;switch(e.outType){case pe.normal:case pe.outside:if(ke(e.position,s.canvas.size,z.origin,e.getRadius(),i))return;break;case pe.inside:{let{dx:r,dy:a}=A(e.position,e.moveCenter),{x:l,y:c}=e.velocity;if(l<_n&&r>e.moveCenter.radius||c<_n&&a>e.moveCenter.radius||l>=_n&&r<-e.moveCenter.radius||c>=_n&&a<-e.moveCenter.radius)return;break}}s.particles.remove(e,e.group,!0)}};var Pn=0,On=class{constructor(e){this.container=e,this.modes=[F.none]}update(e,i,o,n){if(!this.modes.includes(n)||((e.options.move.distance.horizontal&&(i===O.left||i===O.right))??(e.options.move.distance.vertical&&(i===O.top||i===O.bottom))))return;let s=e.options.move.gravity,r=this.container,a=r.canvas.size,l=e.getRadius();if(s.enable){let c=e.position;(!s.inverse&&c.y>a.height+l&&i===O.bottom||s.inverse&&c.y<-l&&i===O.top)&&r.particles.remove(e)}else{if(e.velocity.y>Pn&&e.position.y<=a.height+l||e.velocity.y<Pn&&e.position.y>=-l||e.velocity.x>Pn&&e.position.x<=a.width+l||e.velocity.x<Pn&&e.position.x>=-l)return;ke(e.position,r.canvas.size,z.origin,l,i)||r.particles.remove(e)}}};var Cn=0,Mn=0,Sn=class{constructor(e){this.container=e,this.modes=[F.out]}update(e,i,o,n){if(!this.modes.includes(n))return;let s=this.container;switch(e.outType){case pe.inside:{let{x:r,y:a}=e.velocity,l=z.origin;l.length=e.moveCenter.radius,l.angle=e.velocity.angle+Math.PI,l.addTo(z.create(e.moveCenter));let{dx:c,dy:u}=A(e.position,l);if(r<=Cn&&c>=Mn||a<=Cn&&u>=Mn||r>=Cn&&c<=Mn||a>=Cn&&u<=Mn)return;e.position.x=Math.floor(U({min:0,max:s.canvas.size.width})),e.position.y=Math.floor(U({min:0,max:s.canvas.size.height}));let{dx:f,dy:d}=A(e.position,e.moveCenter);e.direction=Math.atan2(-d,-f),e.velocity.angle=e.direction;break}default:{if(ke(e.position,s.canvas.size,z.origin,e.getRadius(),i))return;switch(e.outType){case pe.outside:{e.position.x=Math.floor(U({min:-e.moveCenter.radius,max:e.moveCenter.radius}))+e.moveCenter.x,e.position.y=Math.floor(U({min:-e.moveCenter.radius,max:e.moveCenter.radius}))+e.moveCenter.y;let{dx:r,dy:a}=A(e.position,e.moveCenter);e.moveCenter.radius&&(e.direction=Math.atan2(a,r),e.velocity.angle=e.direction);break}case pe.normal:{let r=e.options.move.warp,a=s.canvas.size,l={bottom:a.height+e.getRadius()+e.offset.y,left:-e.getRadius()-e.offset.x,right:a.width+e.getRadius()+e.offset.x,top:-e.getRadius()-e.offset.y},c=e.getRadius(),u=Ue(e.position,c);i===O.right&&u.left>a.width+e.offset.x?(e.position.x=l.left,e.initialPosition.x=e.position.x,r||(e.position.y=v()*a.height,e.initialPosition.y=e.position.y)):i===O.left&&u.right<-e.offset.x&&(e.position.x=l.right,e.initialPosition.x=e.position.x,r||(e.position.y=v()*a.height,e.initialPosition.y=e.position.y)),i===O.bottom&&u.top>a.height+e.offset.y?(r||(e.position.x=v()*a.width,e.initialPosition.x=e.position.x),e.position.y=l.top,e.initialPosition.y=e.position.y):i===O.top&&u.bottom<-e.offset.y&&(r||(e.position.x=v()*a.width,e.initialPosition.x=e.position.x),e.position.y=l.bottom,e.initialPosition.y=e.position.y);break}}break}}}};var Gf=(t,e)=>t.default===e||t.bottom===e||t.left===e||t.right===e||t.top===e,zn=class{constructor(e){this._addUpdaterIfMissing=(i,o,n)=>{let s=i.options.move.outModes;!this.updaters.has(o)&&Gf(s,o)&&this.updaters.set(o,n(this.container))},this._updateOutMode=(i,o,n,s)=>{for(let r of this.updaters.values())r.update(i,s,o,n)},this.container=e,this.updaters=new Map}init(e){this._addUpdaterIfMissing(e,F.bounce,i=>new wn(i)),this._addUpdaterIfMissing(e,F.out,i=>new Sn(i)),this._addUpdaterIfMissing(e,F.destroy,i=>new kn(i)),this._addUpdaterIfMissing(e,F.none,i=>new On(i))}isEnabled(e){return!e.destroyed&&!e.spawning}update(e,i){let o=e.options.move.outModes;this._updateOutMode(e,i,o.bottom??o.default,O.bottom),this._updateOutMode(e,i,o.left??o.default,O.left),this._updateOutMode(e,i,o.right??o.default,O.right),this._updateOutMode(e,i,o.top??o.default,O.top)}};async function oc(t,e=!0){t.checkVersion("3.9.1"),await t.addParticleUpdater("outModes",i=>Promise.resolve(new zn(i)),e)}var ci=(function(t){return t[t.r=1]="r",t[t.g=2]="g",t[t.b=3]="b",t[t.a=5]="a",t})(ci||{}),Rn=class{constructor(){this.key="rgb",this.stringPrefix="rgb"}handleColor(e){let i=e.value,o=i.rgb??e.value;if(o.r!==void 0)return o}handleRangeColor(e){let i=e.value,o=i.rgb??e.value;if(o.r!==void 0)return{r:g(o.r),g:g(o.g),b:g(o.b)}}parseString(e){if(!e.startsWith(this.stringPrefix))return;let i=/rgba?\(\s*(\d{1,3})\s*[\s,]\s*(\d{1,3})\s*[\s,]\s*(\d{1,3})\s*([\s,]\s*(0|1|0?\.\d+|(\d{1,3})%)\s*)?\)/i,o=i.exec(e),n=10;return o?{a:o.length>4?Mi(o[ci.a]):1,b:parseInt(o[ci.b],n),g:parseInt(o[ci.g],n),r:parseInt(o[ci.r],n)}:void 0}};async function nc(t,e=!0){t.checkVersion("3.9.1"),await t.addColorManager(new Rn,e)}var rt=0,Dn=class{init(e){let i=e.container,o=e.options.size,n=o.animation;n.enable&&(e.size.velocity=(e.retina.sizeAnimationSpeed??i.retina.sizeAnimationSpeed)/100*i.retina.reduceFactor,n.sync||(e.size.velocity*=v()))}isEnabled(e){return!e.destroyed&&!e.spawning&&e.size.enable&&((e.size.maxLoops??rt)<=rt||(e.size.maxLoops??rt)>rt&&(e.size.loops??rt)<(e.size.maxLoops??rt))}reset(e){e.size.loops=rt}update(e,i){this.isEnabled(e)&&He(e,e.size,!0,e.options.size.animation.destroy,i)}};async function sc(t,e=!0){t.checkVersion("3.9.1"),await t.addParticleUpdater("size",()=>Promise.resolve(new Dn),e)}async function rc(t,e=!0){t.checkVersion("3.9.1"),await Kl(t,!1),await Jl(t,!1),await nc(t,!1),await $l(t,!1),await Yl(t,!1),await Zl(t,!1),await ec(t,!1),await oc(t,!1),await sc(t,!1),await t.refresh(e)}async function ac(t,e=!0){t.checkVersion("3.9.1"),await t.addEasing(Te.easeInQuad,i=>i**2,!1),await t.addEasing(Te.easeOutQuad,i=>1-(1-i)**2,!1),await t.addEasing(Te.easeInOutQuad,i=>i<.5?2*i**2:1-(-2*i+2)**2/2,!1),await t.refresh(e)}function lc(t,e){let{context:i,opacity:o}=t,n=.5,s=i.globalAlpha;if(!e)return;let r=e.width,a=r*n;i.globalAlpha=o,i.drawImage(e,-a,-a,r,r),i.globalAlpha=s}var Mr='"Twemoji Mozilla", Apple Color Emoji, "Segoe UI Emoji", "Noto Color Emoji", "EmojiOne Color"',cc=0,En=class{constructor(){this.validTypes=["emoji"],this._emojiShapeDict=new Map}destroy(){for(let[e,i]of this._emojiShapeDict)i instanceof ImageBitmap&&i?.close(),this._emojiShapeDict.delete(e)}draw(e){let i=e.particle.emojiDataKey;if(!i)return;let o=this._emojiShapeDict.get(i);o&&lc(e,o)}async init(e){let i=e.actualOptions,{validTypes:o}=this;if(!o.find(r=>M(r,i.particles.shape.type)))return;let n=[Gt(Mr)],s=o.map(r=>i.particles.shape.options[r]).find(r=>!!r);s&&S(s,r=>{r.font&&n.push(Gt(r.font))}),await Promise.all(n)}particleDestroy(e){e.emojiDataKey=void 0}particleInit(e,i){let n=i.shapeData;if(!n?.value)return;let s=T(n.value,i.randomIndexData);if(!s)return;let r=typeof s=="string"?{font:n.font??Mr,padding:n.padding??cc,value:s}:q(q({font:Mr,padding:cc},n),s),a=r.font,l=r.value,c=`${l}_${a}`;if(this._emojiShapeDict.has(c)){i.emojiDataKey=c;return}let u=r.padding*2,f=le(i.size.value),d=f+u,p=d*2,m;if(typeof OffscreenCanvas<"u"){let y=new OffscreenCanvas(p,p),x=y.getContext("2d");if(!x)return;x.font=`400 ${f*2}px ${a}`,x.textBaseline="middle",x.textAlign="center",x.fillText(l,d,d),m=y.transferToImageBitmap()}else{let y=document.createElement("canvas");y.width=p,y.height=p;let x=y.getContext("2d");if(!x)return;x.font=`400 ${f*2}px ${a}`,x.textBaseline="middle",x.textAlign="center",x.fillText(l,d,d),m=y}this._emojiShapeDict.set(c,m),i.emojiDataKey=c}};async function uc(t,e=!0){t.checkVersion("3.9.1"),await t.addShape(new En,e)}var Qf=1,Xf=1,fc=0;function hc(t,e,i,o,n,s){let r=e.actualOptions.interactivity.modes.attract;if(!r)return;let a=e.particles.quadTree.query(n,s);for(let l of a){let{dx:c,dy:u,distance:f}=A(l.position,i),d=r.speed*r.factor,p=K(t.getEasing(r.easing)(Xf-f/o)*d,Qf,r.maxSpeed),m=z.create(f?c/f*p:d,f?u/f*p:d);l.position.subFrom(m)}}function dc(t,e,i){e.attract||(e.attract={particles:[]});let{attract:o}=e;if(o.finish||(o.count||(o.count=0),o.count++,o.count===e.particles.count&&(o.finish=!0)),o.clicking){let n=e.interactivity.mouse.clickPosition,s=e.retina.attractModeDistance;if(!s||s<fc||!n)return;hc(t,e,n,s,new G(n.x,n.y,s),r=>i(r))}else o.clicking===!1&&(o.particles=[])}function pc(t,e,i){let o=e.interactivity.mouse.position,n=e.retina.attractModeDistance;!n||n<fc||!o||hc(t,e,o,n,new G(o.x,o.y,n),s=>i(s))}var In=class{constructor(){this.distance=200,this.duration=.4,this.easing=Te.easeOutQuad,this.factor=1,this.maxSpeed=50,this.speed=1}load(e){h(e)||(e.distance!==void 0&&(this.distance=e.distance),e.duration!==void 0&&(this.duration=e.duration),e.easing!==void 0&&(this.easing=e.easing),e.factor!==void 0&&(this.factor=e.factor),e.maxSpeed!==void 0&&(this.maxSpeed=e.maxSpeed),e.speed!==void 0&&(this.speed=e.speed))}};var ui="attract",Tn=class extends H{constructor(e,i){super(i),this._engine=e,i.attract||(i.attract={particles:[]}),this.handleClickMode=o=>{let n=this.container.actualOptions,s=n.interactivity.modes.attract;if(!(!s||o!==ui)){i.attract||(i.attract={particles:[]}),i.attract.clicking=!0,i.attract.count=0;for(let r of i.attract.particles)this.isEnabled(r)&&r.velocity.setTo(r.initialVelocity);i.attract.particles=[],i.attract.finish=!1,setTimeout(()=>{i.destroyed||(i.attract||(i.attract={particles:[]}),i.attract.clicking=!1)},s.duration*1e3)}}}clear(){}init(){let e=this.container,i=e.actualOptions.interactivity.modes.attract;i&&(e.retina.attractModeDistance=i.distance*e.retina.pixelRatio)}interact(){let e=this.container,i=e.actualOptions,o=e.interactivity.status===he,n=i.interactivity.events,{enable:s,mode:r}=n.onHover,{enable:a,mode:l}=n.onClick;o&&s&&M(ui,r)?pc(this._engine,this.container,c=>this.isEnabled(c)):a&&M(ui,l)&&dc(this._engine,this.container,c=>this.isEnabled(c))}isEnabled(e){let i=this.container,o=i.actualOptions,n=i.interactivity.mouse,s=(e?.interactivity??o.interactivity).events;if((!n.position||!s.onHover.enable)&&(!n.clickPosition||!s.onClick.enable))return!1;let r=s.onHover.mode,a=s.onClick.mode;return M(ui,r)||M(ui,a)}loadModeOptions(e,...i){e.attract||(e.attract=new In);for(let o of i)e.attract.load(o?.attract)}reset(){}};async function mc(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("externalAttract",i=>Promise.resolve(new Tn(t,i)),e)}var Yf=2,Fn=.5,Zf=Math.PI*Fn,gc=2,yc=10,Kf=0;function xc(t,e,i,o,n){let s=t.particles.quadTree.query(o,n);for(let r of s)o instanceof G?Ri(Qt(r),{position:e,radius:i,mass:i**Yf*Zf,velocity:z.origin,factor:z.origin}):o instanceof ne&&Ya(r,Ue(e,i))}function Jf(t,e,i,o){let n=document.querySelectorAll(e);n.length&&n.forEach(s=>{let r=s,a=t.retina.pixelRatio,l={x:(r.offsetLeft+r.offsetWidth*Fn)*a,y:(r.offsetTop+r.offsetHeight*Fn)*a},c=r.offsetWidth*Fn*a,u=yc*a,f=i.type===De.circle?new G(l.x,l.y,c+u):new ne(r.offsetLeft*a-u,r.offsetTop*a-u,r.offsetWidth*a+u*gc,r.offsetHeight*a+u*gc);o(l,c,f)})}function bc(t,e,i,o){bt(i,e,(n,s)=>Jf(t,n,s,(r,a,l)=>xc(t,r,a,l,o)))}function vc(t,e){let i=t.retina.pixelRatio,o=yc*i,n=t.interactivity.mouse.position,s=t.retina.bounceModeDistance;!s||s<Kf||!n||xc(t,n,s,new G(n.x,n.y,s+o),e)}var Ln=class{constructor(){this.distance=200}load(e){h(e)||e.distance!==void 0&&(this.distance=e.distance)}};var An="bounce",Vn=class extends H{constructor(e){super(e)}clear(){}init(){let e=this.container,i=e.actualOptions.interactivity.modes.bounce;i&&(e.retina.bounceModeDistance=i.distance*e.retina.pixelRatio)}interact(){let e=this.container,i=e.actualOptions,o=i.interactivity.events,n=e.interactivity.status===he,s=o.onHover.enable,r=o.onHover.mode,a=o.onDiv;n&&s&&M(An,r)?vc(this.container,l=>this.isEnabled(l)):bc(this.container,a,An,l=>this.isEnabled(l))}isEnabled(e){let i=this.container,o=i.actualOptions,n=i.interactivity.mouse,s=(e?.interactivity??o.interactivity).events,r=s.onDiv;return!!n.position&&s.onHover.enable&&M(An,s.onHover.mode)||xt(An,r)}loadModeOptions(e,...i){e.bounce||(e.bounce=new Ln);for(let o of i)e.bounce.load(o?.bounce)}reset(){}};async function wc(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("externalBounce",i=>Promise.resolve(new Vn(i)),e)}var Et=class{constructor(){this.distance=200,this.duration=.4,this.mix=!1}load(e){if(!h(e)){if(e.distance!==void 0&&(this.distance=e.distance),e.duration!==void 0&&(this.duration=e.duration),e.mix!==void 0&&(this.mix=e.mix),e.opacity!==void 0&&(this.opacity=e.opacity),e.color!==void 0){let i=N(this.color)?void 0:this.color;this.color=S(e.color,o=>D.create(i,o))}e.size!==void 0&&(this.size=e.size)}}};var Bn=class extends Et{constructor(){super(),this.selectors=[]}load(e){super.load(e),!h(e)&&e.selectors!==void 0&&(this.selectors=e.selectors)}};var qn=class extends Et{load(e){super.load(e),!h(e)&&(this.divs=S(e.divs,i=>{let o=new Bn;return o.load(i),o}))}};var Oe=(function(t){return t.color="color",t.opacity="opacity",t.size="size",t})(Oe||{});function Sr(t,e,i,o){if(e>=i){let n=t+(e-i)*o;return K(n,t,e)}else if(e<i){let n=t-(i-e)*o;return K(n,e,t)}}var at="bubble",zr=0,eh=0,th=2,_c=1,kc=1,ih=0,oh=0,Rr=.5,Dr=1,Nn=class extends H{constructor(e,i){super(e),this._clickBubble=()=>{let o=this.container,n=o.actualOptions,s=o.interactivity.mouse.clickPosition,r=n.interactivity.modes.bubble;if(!r||!s)return;o.bubble||(o.bubble={});let a=o.retina.bubbleModeDistance;if(!a||a<zr)return;let l=o.particles.quadTree.queryCircle(s,a,u=>this.isEnabled(u)),{bubble:c}=o;for(let u of l){if(!c.clicking)continue;u.bubble.inRange=!c.durationEnd;let f=u.getPosition(),d=V(f,s),p=(new Date().getTime()-(o.interactivity.mouse.clickTime??eh))/1e3;p>r.duration&&(c.durationEnd=!0),p>r.duration*th&&(c.clicking=!1,c.durationEnd=!1);let m={bubbleObj:{optValue:o.retina.bubbleModeSize,value:u.bubble.radius},particlesObj:{optValue:le(u.options.size.value)*o.retina.pixelRatio,value:u.size.value},type:Oe.size};this._process(u,d,p,m);let y={bubbleObj:{optValue:r.opacity,value:u.bubble.opacity},particlesObj:{optValue:le(u.options.opacity.value),value:u.opacity?.value??_c},type:Oe.opacity};this._process(u,d,p,y),!c.durationEnd&&d<=a?this._hoverBubbleColor(u,d):delete u.bubble.color}},this._hoverBubble=()=>{let o=this.container,n=o.interactivity.mouse.position,s=o.retina.bubbleModeDistance;if(!s||s<zr||!n)return;let r=o.particles.quadTree.queryCircle(n,s,a=>this.isEnabled(a));for(let a of r){a.bubble.inRange=!0;let l=a.getPosition(),c=V(l,n),u=kc-c/s;c<=s?u>=oh&&o.interactivity.status===he&&(this._hoverBubbleSize(a,u),this._hoverBubbleOpacity(a,u),this._hoverBubbleColor(a,u)):this.reset(a),o.interactivity.status===Bt&&this.reset(a)}},this._hoverBubbleColor=(o,n,s)=>{let r=this.container.actualOptions,a=s??r.interactivity.modes.bubble;if(a){if(!o.bubble.finalColor){let l=a.color;if(!l)return;let c=T(l);o.bubble.finalColor=ce(this._engine,c)}if(o.bubble.finalColor)if(a.mix){o.bubble.color=void 0;let l=o.getFillColor();o.bubble.color=l?br(Xt(l,o.bubble.finalColor,kc-n,n)):o.bubble.finalColor}else o.bubble.color=o.bubble.finalColor}},this._hoverBubbleOpacity=(o,n,s)=>{let r=this.container,a=r.actualOptions,l=s?.opacity??a.interactivity.modes.bubble?.opacity;if(!l)return;let c=o.options.opacity.value,u=o.opacity?.value??_c,f=Sr(u,l,le(c),n);f!==void 0&&(o.bubble.opacity=f)},this._hoverBubbleSize=(o,n,s)=>{let r=this.container,a=s?.size?s.size*r.retina.pixelRatio:r.retina.bubbleModeSize;if(a===void 0)return;let l=le(o.options.size.value)*r.retina.pixelRatio,c=o.size.value,u=Sr(c,a,l,n);u!==void 0&&(o.bubble.radius=u)},this._process=(o,n,s,r)=>{let a=this.container,l=r.bubbleObj.optValue,c=a.actualOptions,u=c.interactivity.modes.bubble;if(!u||l===void 0)return;let f=u.duration,d=a.retina.bubbleModeDistance,p=r.particlesObj.optValue,m=r.bubbleObj.value,y=r.particlesObj.value??ih,x=r.type;if(!(!d||d<zr||l===p))if(a.bubble||(a.bubble={}),a.bubble.durationEnd)m&&(x===Oe.size&&delete o.bubble.radius,x===Oe.opacity&&delete o.bubble.opacity);else if(n<=d){if((m??y)!==l){let w=y-s*(y-l)/f;x===Oe.size&&(o.bubble.radius=w),x===Oe.opacity&&(o.bubble.opacity=w)}}else x===Oe.size&&delete o.bubble.radius,x===Oe.opacity&&delete o.bubble.opacity},this._singleSelectorHover=(o,n,s)=>{let r=this.container,a=document.querySelectorAll(n),l=r.actualOptions.interactivity.modes.bubble;!l||!a.length||a.forEach(c=>{let u=c,f=r.retina.pixelRatio,d={x:(u.offsetLeft+u.offsetWidth*Rr)*f,y:(u.offsetTop+u.offsetHeight*Rr)*f},p=u.offsetWidth*Rr*f,m=s.type===De.circle?new G(d.x,d.y,p):new ne(u.offsetLeft*f,u.offsetTop*f,u.offsetWidth*f,u.offsetHeight*f),y=r.particles.quadTree.query(m,x=>this.isEnabled(x));for(let x of y){if(!m.contains(x.getPosition()))continue;x.bubble.inRange=!0;let _=l.divs,w=zi(_,u);(!x.bubble.div||x.bubble.div!==u)&&(this.clear(x,o,!0),x.bubble.div=u),this._hoverBubbleSize(x,Dr,w),this._hoverBubbleOpacity(x,Dr,w),this._hoverBubbleColor(x,Dr,w)}})},this._engine=i,e.bubble||(e.bubble={}),this.handleClickMode=o=>{o===at&&(e.bubble||(e.bubble={}),e.bubble.clicking=!0)}}clear(e,i,o){e.bubble.inRange&&!o||(delete e.bubble.div,delete e.bubble.opacity,delete e.bubble.radius,delete e.bubble.color)}init(){let e=this.container,i=e.actualOptions.interactivity.modes.bubble;i&&(e.retina.bubbleModeDistance=i.distance*e.retina.pixelRatio,i.size!==void 0&&(e.retina.bubbleModeSize=i.size*e.retina.pixelRatio))}interact(e){let i=this.container.actualOptions,o=i.interactivity.events,n=o.onHover,s=o.onClick,r=n.enable,a=n.mode,l=s.enable,c=s.mode,u=o.onDiv;r&&M(at,a)?this._hoverBubble():l&&M(at,c)?this._clickBubble():bt(at,u,(f,d)=>this._singleSelectorHover(e,f,d))}isEnabled(e){let i=this.container,o=i.actualOptions,n=i.interactivity.mouse,s=(e?.interactivity??o.interactivity).events,{onClick:r,onDiv:a,onHover:l}=s,c=xt(at,a);return c||l.enable&&n.position||r.enable&&n.clickPosition?M(at,l.mode)||M(at,r.mode)||c:!1}loadModeOptions(e,...i){e.bubble||(e.bubble=new qn);for(let o of i)e.bubble.load(o?.bubble)}reset(e){e.bubble.inRange=!1}};async function Pc(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("externalBubble",i=>Promise.resolve(new Nn(i,t)),e)}var Un=class{constructor(){this.opacity=.5}load(e){h(e)||e.opacity!==void 0&&(this.opacity=e.opacity)}};var Hn=class{constructor(){this.distance=80,this.links=new Un,this.radius=60}load(e){h(e)||(e.distance!==void 0&&(this.distance=e.distance),this.links.load(e.links),e.radius!==void 0&&(this.radius=e.radius))}};var Oc=0,Cc=1,nh=0;function sh(t,e,i,o){let n=Math.floor(i.getRadius()/e.getRadius()),s=e.getFillColor(),r=i.getFillColor();if(!s||!r)return;let a=e.getPosition(),l=i.getPosition(),c=Xt(s,r,e.getRadius(),i.getRadius()),u=t.createLinearGradient(a.x,a.y,l.x,l.y);return u.addColorStop(Oc,Pe(s,o)),u.addColorStop(K(n,Oc,Cc),ae(c,o)),u.addColorStop(Cc,Pe(r,o)),u}function rh(t,e,i,o,n){We(t,o,n),t.lineWidth=e,t.strokeStyle=i,t.stroke()}function ah(t,e,i,o){let n=t.actualOptions,s=n.interactivity.modes.connect;if(s)return sh(e,i,o,s.links.opacity)}function Mc(t,e,i){t.canvas.draw(o=>{let n=ah(t,o,e,i);if(!n)return;let s=e.getPosition(),r=i.getPosition();rh(o,e.retina.linksWidth??nh,n,s,r)})}var lh="connect",Sc=0,Wn=class extends H{constructor(e){super(e)}clear(){}init(){let e=this.container,i=e.actualOptions.interactivity.modes.connect;i&&(e.retina.connectModeDistance=i.distance*e.retina.pixelRatio,e.retina.connectModeRadius=i.radius*e.retina.pixelRatio)}interact(){let e=this.container;if(e.actualOptions.interactivity.events.onHover.enable&&e.interactivity.status==="pointermove"){let o=e.interactivity.mouse.position,{connectModeDistance:n,connectModeRadius:s}=e.retina;if(!n||n<Sc||!s||s<Sc||!o)return;let r=Math.abs(s),a=e.particles.quadTree.queryCircle(o,r,l=>this.isEnabled(l));a.forEach((l,c)=>{let u=l.getPosition(),f=1;for(let d of a.slice(c+f)){let p=d.getPosition(),m=Math.abs(n),y=Math.abs(u.x-p.x),x=Math.abs(u.y-p.y);y<m&&x<m&&Mc(e,l,d)}})}}isEnabled(e){let i=this.container,o=i.interactivity.mouse,n=(e?.interactivity??i.actualOptions.interactivity).events;return n.onHover.enable&&o.position?M(lh,n.onHover.mode):!1}loadModeOptions(e,...i){e.connect||(e.connect=new Hn);for(let o of i)e.connect.load(o?.connect)}reset(){}};async function zc(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("externalConnect",i=>Promise.resolve(new Wn(i)),e)}var jn=class{constructor(){this.blink=!1,this.consent=!1,this.opacity=1}load(e){h(e)||(e.blink!==void 0&&(this.blink=e.blink),e.color!==void 0&&(this.color=D.create(this.color,e.color)),e.consent!==void 0&&(this.consent=e.consent),e.opacity!==void 0&&(this.opacity=e.opacity))}};var $n=class{constructor(){this.distance=100,this.links=new jn}load(e){h(e)||(e.distance!==void 0&&(this.distance=e.distance),this.links.load(e.links))}};var ch=0;function uh(t,e,i,o,n,s){We(t,i,o),t.strokeStyle=ae(n,s),t.lineWidth=e,t.stroke()}function Rc(t,e,i,o,n){t.canvas.draw(s=>{let r=e.getPosition();uh(s,e.retina.linksWidth??ch,r,n,i,o)})}var fh="grab",hh=0,dh=0,Gn=class extends H{constructor(e,i){super(e),this._engine=i}clear(){}init(){let e=this.container,i=e.actualOptions.interactivity.modes.grab;i&&(e.retina.grabModeDistance=i.distance*e.retina.pixelRatio)}interact(){let e=this.container,i=e.actualOptions,o=i.interactivity;if(!o.modes.grab||!o.events.onHover.enable||e.interactivity.status!==he)return;let n=e.interactivity.mouse.position;if(!n)return;let s=e.retina.grabModeDistance;if(!s||s<hh)return;let r=e.particles.quadTree.queryCircle(n,s,a=>this.isEnabled(a));for(let a of r){let l=a.getPosition(),c=V(l,n);if(c>s)continue;let u=o.modes.grab.links,f=u.opacity,d=f-c*f/s;if(d<=dh)continue;let p=u.color??a.options.links?.color;if(!e.particles.grabLineColor&&p){let y=o.modes.grab.links;e.particles.grabLineColor=Ii(this._engine,p,y.blink,y.consent)}let m=Yt(a,void 0,e.particles.grabLineColor);m&&Rc(e,a,m,d,n)}}isEnabled(e){let i=this.container,o=i.interactivity.mouse,n=(e?.interactivity??i.actualOptions.interactivity).events;return n.onHover.enable&&!!o.position&&M(fh,n.onHover.mode)}loadModeOptions(e,...i){e.grab||(e.grab=new $n);for(let o of i)e.grab.load(o?.grab)}reset(){}};async function Dc(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("externalGrab",i=>Promise.resolve(new Gn(i,t)),e)}var ph="pause",Qn=class extends H{constructor(e){super(e),this.handleClickMode=i=>{if(i!==ph)return;let o=this.container;o.animationStatus?o.pause():o.play()}}clear(){}init(){}interact(){}isEnabled(){return!0}reset(){}};async function Ec(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("externalPause",i=>Promise.resolve(new Qn(i)),e)}var Xn=class{constructor(){this.default=!0,this.groups=[],this.quantity=4}load(e){if(h(e))return;e.default!==void 0&&(this.default=e.default),e.groups!==void 0&&(this.groups=e.groups.map(o=>o)),this.groups.length||(this.default=!0);let i=e.quantity;i!==void 0&&(this.quantity=b(i)),this.particles=S(e.particles,o=>C({},o))}};var mh="push",gh=0,Yn=class extends H{constructor(e){super(e),this.handleClickMode=i=>{if(i!==mh)return;let o=this.container,n=o.actualOptions,s=n.interactivity.modes.push;if(!s)return;let r=g(s.quantity);if(r<=gh)return;let a=Ne([void 0,...s.groups]),l=a!==void 0?o.actualOptions.particles.groups[a]:void 0,c=T(s.particles),u=C(l,c);o.particles.push(r,o.interactivity.mouse,u,a)}}clear(){}init(){}interact(){}isEnabled(){return!0}loadModeOptions(e,...i){e.push||(e.push=new Xn);for(let o of i)e.push.load(o?.push)}reset(){}};async function Ic(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("externalPush",i=>Promise.resolve(new Yn(i)),e)}var Zn=class{constructor(){this.quantity=2}load(e){if(h(e))return;let i=e.quantity;i!==void 0&&(this.quantity=b(i))}};var yh="remove",Kn=class extends H{constructor(e){super(e),this.handleClickMode=i=>{let o=this.container,n=o.actualOptions;if(!n.interactivity.modes.remove||i!==yh)return;let s=g(n.interactivity.modes.remove.quantity);o.particles.removeQuantity(s)}}clear(){}init(){}interact(){}isEnabled(){return!0}loadModeOptions(e,...i){e.remove||(e.remove=new Zn);for(let o of i)e.remove.load(o?.remove)}reset(){}};async function Tc(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("externalRemove",i=>Promise.resolve(new Kn(i)),e)}var It=class{constructor(){this.distance=200,this.duration=.4,this.factor=100,this.speed=1,this.maxSpeed=50,this.easing=Te.easeOutQuad}load(e){h(e)||(e.distance!==void 0&&(this.distance=e.distance),e.duration!==void 0&&(this.duration=e.duration),e.easing!==void 0&&(this.easing=e.easing),e.factor!==void 0&&(this.factor=e.factor),e.speed!==void 0&&(this.speed=e.speed),e.maxSpeed!==void 0&&(this.maxSpeed=e.maxSpeed))}};var Jn=class extends It{constructor(){super(),this.selectors=[]}load(e){super.load(e),!h(e)&&e.selectors!==void 0&&(this.selectors=e.selectors)}};var es=class extends It{load(e){super.load(e),!h(e)&&(this.divs=S(e.divs,i=>{let o=new Jn;return o.load(i),o}))}};var lt="repulse",xh=0,bh=6,vh=3,wh=2,_h=0,kh=0,Ph=1,Er=.5,ts=class extends H{constructor(e,i){super(i),this._clickRepulse=()=>{let o=this.container,n=o.actualOptions.interactivity.modes.repulse;if(!n)return;let s=o.repulse??{particles:[]};if(s.finish||(s.count||(s.count=0),s.count++,s.count===o.particles.count&&(s.finish=!0)),s.clicking){let r=o.retina.repulseModeDistance;if(!r||r<xh)return;let a=Math.pow(r/bh,vh),l=o.interactivity.mouse.clickPosition;if(l===void 0)return;let c=new G(l.x,l.y,a),u=o.particles.quadTree.query(c,f=>this.isEnabled(f));for(let f of u){let{dx:d,dy:p,distance:m}=A(l,f.position),y=m**wh,x=n.speed,_=-a*x/y;if(y<=a){s.particles.push(f);let w=z.create(d,p);w.length=_,f.velocity.setTo(w)}}}else if(s.clicking===!1){for(let r of s.particles)r.velocity.setTo(r.initialVelocity);s.particles=[]}},this._hoverRepulse=()=>{let o=this.container,n=o.interactivity.mouse.position,s=o.retina.repulseModeDistance;!s||s<_h||!n||this._processRepulse(n,s,new G(n.x,n.y,s))},this._processRepulse=(o,n,s,r)=>{let a=this.container,l=a.particles.quadTree.query(s,x=>this.isEnabled(x)),c=a.actualOptions.interactivity.modes.repulse;if(!c)return;let{easing:u,speed:f,factor:d,maxSpeed:p}=c,m=this._engine.getEasing(u),y=(r?.speed??f)*d;for(let x of l){let{dx:_,dy:w,distance:P}=A(x.position,o),k=K(m(Ph-P/n)*y,kh,p),I=z.create(P?_/P*k:y,P?w/P*k:y);x.position.addTo(I)}},this._singleSelectorRepulse=(o,n)=>{let s=this.container,r=s.actualOptions.interactivity.modes.repulse;if(!r)return;let a=document.querySelectorAll(o);a.length&&a.forEach(l=>{let c=l,u=s.retina.pixelRatio,f={x:(c.offsetLeft+c.offsetWidth*Er)*u,y:(c.offsetTop+c.offsetHeight*Er)*u},d=c.offsetWidth*Er*u,p=n.type===De.circle?new G(f.x,f.y,d):new ne(c.offsetLeft*u,c.offsetTop*u,c.offsetWidth*u,c.offsetHeight*u),m=r.divs,y=zi(m,c);this._processRepulse(f,d,p,y)})},this._engine=e,i.repulse||(i.repulse={particles:[]}),this.handleClickMode=o=>{let n=this.container.actualOptions,s=n.interactivity.modes.repulse;if(!s||o!==lt)return;i.repulse||(i.repulse={particles:[]});let r=i.repulse;r.clicking=!0,r.count=0;for(let a of i.repulse.particles)this.isEnabled(a)&&a.velocity.setTo(a.initialVelocity);r.particles=[],r.finish=!1,setTimeout(()=>{i.destroyed||(r.clicking=!1)},s.duration*1e3)}}clear(){}init(){let e=this.container,i=e.actualOptions.interactivity.modes.repulse;i&&(e.retina.repulseModeDistance=i.distance*e.retina.pixelRatio)}interact(){let e=this.container,i=e.actualOptions,o=e.interactivity.status===he,n=i.interactivity.events,s=n.onHover,r=s.enable,a=s.mode,l=n.onClick,c=l.enable,u=l.mode,f=n.onDiv;o&&r&&M(lt,a)?this._hoverRepulse():c&&M(lt,u)?this._clickRepulse():bt(lt,f,(d,p)=>this._singleSelectorRepulse(d,p))}isEnabled(e){let i=this.container,o=i.actualOptions,n=i.interactivity.mouse,s=(e?.interactivity??o.interactivity).events,r=s.onDiv,a=s.onHover,l=s.onClick,c=xt(lt,r);if(!(c||a.enable&&n.position||l.enable&&n.clickPosition))return!1;let u=a.mode,f=l.mode;return M(lt,u)||M(lt,f)||c}loadModeOptions(e,...i){e.repulse||(e.repulse=new es);for(let o of i)e.repulse.load(o?.repulse)}reset(){}};async function Fc(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("externalRepulse",i=>Promise.resolve(new ts(t,i)),e)}var is=class{constructor(){this.factor=3,this.radius=200}load(e){h(e)||(e.factor!==void 0&&(this.factor=e.factor),e.radius!==void 0&&(this.radius=e.radius))}};var Oh="slow",Ch=0,os=class extends H{constructor(e){super(e)}clear(e,i,o){e.slow.inRange&&!o||(e.slow.factor=1)}init(){let e=this.container,i=e.actualOptions.interactivity.modes.slow;i&&(e.retina.slowModeRadius=i.radius*e.retina.pixelRatio)}interact(){}isEnabled(e){let i=this.container,o=i.interactivity.mouse,n=(e?.interactivity??i.actualOptions.interactivity).events;return n.onHover.enable&&!!o.position&&M(Oh,n.onHover.mode)}loadModeOptions(e,...i){e.slow||(e.slow=new is);for(let o of i)e.slow.load(o?.slow)}reset(e){e.slow.inRange=!1;let i=this.container,o=i.actualOptions,n=i.interactivity.mouse.position,s=i.retina.slowModeRadius,r=o.interactivity.modes.slow;if(!r||!s||s<Ch||!n)return;let a=e.getPosition(),l=V(n,a),c=l/s,u=r.factor,{slow:f}=e;l>s||(f.inRange=!0,f.factor=c/u)}};async function Lc(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("externalSlow",i=>Promise.resolve(new os(i)),e)}var Mh=0,Sh=1,zh=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d.]+%?\))|currentcolor/gi;function Rh(t,e,i){let{svgData:o}=t;if(!o)return"";let n=Pe(e,i);if(o.includes("fill"))return o.replace(zh,()=>n);let s=o.indexOf(">");return`${o.substring(Mh,s)} fill="${n}"${o.substring(s)}`}async function Tt(t){return new Promise(e=>{t.loading=!0;let i=new Image;t.element=i,i.addEventListener("load",()=>{t.loading=!1,e()}),i.addEventListener("error",()=>{t.element=void 0,t.error=!0,t.loading=!1,xe().error(`${J} loading image: ${t.source}`),e()}),i.src=t.source})}async function Ac(t){if(t.type!=="svg"){await Tt(t);return}t.loading=!0;let e=await fetch(t.source);e.ok?t.svgData=await e.text():(xe().error(`${J} Image not found`),t.error=!0),t.loading=!1}function Vc(t,e,i,o){let n=Rh(t,i,o.opacity?.value??Sh),s={color:i,gif:e.gif,data:Ke(q({},t),{svgData:n}),loaded:!1,ratio:e.width/e.height,replaceColor:e.replaceColor,source:e.src};return new Promise(r=>{let a=new Blob([n],{type:"image/svg+xml"}),l=URL||window.URL||window.webkitURL||window,c=l.createObjectURL(a),u=new Image;u.addEventListener("load",()=>{s.loaded=!0,s.element=u,r(s),l.revokeObjectURL(c)});let f=async()=>{l.revokeObjectURL(c);let d=Ke(q({},t),{error:!1,loading:!0});await Tt(d),s.loaded=!0,s.element=d.element,r(s)};u.addEventListener("error",()=>{f()}),u.src=c})}var ns=[0,4,2,1],Ir=[8,8,4,2];var ss=class{constructor(e){this.pos=0,this.data=new Uint8ClampedArray(e)}getString(e){let i=this.data.slice(this.pos,this.pos+e);return this.pos+=i.length,i.reduce((o,n)=>o+String.fromCharCode(n),"")}nextByte(){return this.data[this.pos++]}nextTwoBytes(){return this.pos+=2,this.data[this.pos-2]+(this.data[this.pos-1]<<8)}readSubBlocks(){let e="",i=0,o=0,n=0;do{i=this.data[this.pos++];for(let s=i;--s>=o;e+=String.fromCharCode(this.data[this.pos++]));}while(i!==n);return e}readSubBlocksBin(){let e=this.data[this.pos],i=0,o=0,n=1;for(let r=0;e!==o;r+=e+n,e=this.data[this.pos+r])i+=e;let s=new Uint8Array(i);e=this.data[this.pos++];for(let r=0;e!==o;e=this.data[this.pos++])for(let a=e;--a>=o;s[r++]=this.data[this.pos++]);return s}skipSubBlocks(){for(let e=1,i=0;this.data[this.pos]!==i;this.pos+=this.data[this.pos]+e);this.pos++}};var we=(function(t){return t[t.Replace=0]="Replace",t[t.Combine=1]="Combine",t[t.RestoreBackground=2]="RestoreBackground",t[t.RestorePrevious=3]="RestorePrevious",t[t.UndefinedA=4]="UndefinedA",t[t.UndefinedB=5]="UndefinedB",t[t.UndefinedC=6]="UndefinedC",t[t.UndefinedD=7]="UndefinedD",t})(we||{});var Fe=(function(t){return t[t.Extension=33]="Extension",t[t.ApplicationExtension=255]="ApplicationExtension",t[t.GraphicsControlExtension=249]="GraphicsControlExtension",t[t.PlainTextExtension=1]="PlainTextExtension",t[t.CommentExtension=254]="CommentExtension",t[t.Image=44]="Image",t[t.EndOfFile=59]="EndOfFile",t})(Fe||{});var fe={x:0,y:0},Dh=0,Bc=.5,Eh=0,qc=0,Tr=0;function Nc(t,e){let i=[];for(let o=0;o<e;o++)i.push({r:t.data[t.pos],g:t.data[t.pos+1],b:t.data[t.pos+2]}),t.pos+=3;return i}function Ih(t,e,i,o){switch(t.nextByte()){case Fe.GraphicsControlExtension:{let n=e.frames[i(!1)];t.pos++;let s=t.nextByte();n.GCreserved=(s&224)>>>5,n.disposalMethod=(s&28)>>>2,n.userInputDelayFlag=(s&2)===2;let r=(s&1)===1;n.delayTime=t.nextTwoBytes()*10;let a=t.nextByte();r&&o(a),t.pos++;break}case Fe.ApplicationExtension:{t.pos++;let n={identifier:t.getString(8),authenticationCode:t.getString(3),data:t.readSubBlocksBin()};e.applicationExtensions.push(n);break}case Fe.CommentExtension:{e.comments.push([i(!1),t.readSubBlocks()]);break}case Fe.PlainTextExtension:{if(e.globalColorTable.length===0)throw new EvalError("plain text extension without global color table");t.pos++,e.frames[i(!1)].plainTextData={left:t.nextTwoBytes(),top:t.nextTwoBytes(),width:t.nextTwoBytes(),height:t.nextTwoBytes(),charSize:{width:t.nextTwoBytes(),height:t.nextTwoBytes()},foregroundColor:t.nextByte(),backgroundColor:t.nextByte(),text:t.readSubBlocks()};break}default:t.skipSubBlocks();break}}async function Th(t,e,i,o,n,s){let r=e.frames[o(!0)];r.left=t.nextTwoBytes(),r.top=t.nextTwoBytes(),r.width=t.nextTwoBytes(),r.height=t.nextTwoBytes();let a=t.nextByte(),l=(a&128)===128,c=(a&64)===64;r.sortFlag=(a&32)===32,r.reserved=(a&24)>>>3;let u=1<<(a&7)+1;l&&(r.localColorTable=Nc(t,u));let f=_=>{let{r:w,g:P,b:k}=(l?r.localColorTable:e.globalColorTable)[_];return _!==n(null)?{r:w,g:P,b:k,a:255}:{r:w,g:P,b:k,a:i?~~((w+P+k)/3):0}},d=(()=>{try{return new ImageData(r.width,r.height,{colorSpace:"srgb"})}catch(_){if(_ instanceof DOMException&&_.name==="IndexSizeError")return null;throw _}})();if(d==null)throw new EvalError("GIF frame size is to large");let p=t.nextByte(),m=t.readSubBlocksBin(),y=1<<p,x=(_,w)=>{let P=_>>>3,k=_&7;return(m[P]+(m[P+1]<<8)+(m[P+2]<<16)&(1<<w)-1<<k)>>>k};if(c){for(let _=0,w=p+1,P=0,k=[[0]],I=0;I<4;I++){if(ns[I]<r.height){let Q=0,L=0,se=!1;for(;!se;){let ut=_;if(_=x(P,w),P+=w+1,_===y){w=p+1,k.length=y+2;for(let Ce=0;Ce<k.length;Ce++)k[Ce]=Ce<y?[Ce]:[]}else{_>=k.length?k.push(k[ut].concat(k[ut][0])):ut!==y&&k.push(k[ut].concat(k[_][0]));for(let Ce of k[_]){let{r:js,g:$s,b:Nu,a:Uu}=f(Ce);d.data.set([js,$s,Nu,Uu],ns[I]*r.width+Ir[I]*L+Q%(r.width*4)),Q+=4}k.length===1<<w&&w<12&&w++}Q===r.width*4*(L+1)&&(L++,ns[I]+Ir[I]*L>=r.height&&(se=!0))}}s?.(t.pos/(t.data.length-1),o(!1)+1,d,{x:r.left,y:r.top},{width:e.width,height:e.height})}r.image=d,r.bitmap=await createImageBitmap(d)}else{let _=0,w=p+1,P=0,k=-4,I=!1,Q=[[0]];for(;!I;){let L=_;if(_=x(P,w),P+=w,_===y){w=p+1,Q.length=y+2;for(let se=0;se<Q.length;se++)Q[se]=se<y?[se]:[]}else{if(_===y+1){I=!0;break}_>=Q.length?Q.push(Q[L].concat(Q[L][0])):L!==y&&Q.push(Q[L].concat(Q[_][0]));for(let se of Q[_]){let{r:ut,g:Ce,b:js,a:$s}=f(se);d.data.set([ut,Ce,js,$s],k+=4)}Q.length>=1<<w&&w<12&&w++}}r.image=d,r.bitmap=await createImageBitmap(d),s?.((t.pos+1)/t.data.length,o(!1)+1,r.image,{x:r.left,y:r.top},{width:e.width,height:e.height})}}async function Fh(t,e,i,o,n,s){switch(t.nextByte()){case Fe.EndOfFile:return!0;case Fe.Image:await Th(t,e,i,o,n,s);break;case Fe.Extension:Ih(t,e,o,n);break;default:throw new EvalError("undefined block found")}return!1}function Lh(t){for(let e of t.applicationExtensions)if(e.identifier+e.authenticationCode==="NETSCAPE2.0")return e.data[1]+(e.data[2]<<8);return NaN}async function Ah(t,e,i){i||(i=!1);let o=await fetch(t);if(!o.ok&&o.status===404)throw new EvalError("file not found");let n=await o.arrayBuffer(),s={width:0,height:0,totalTime:0,colorRes:0,pixelAspectRatio:0,frames:[],sortFlag:!1,globalColorTable:[],backgroundImage:new ImageData(1,1,{colorSpace:"srgb"}),comments:[],applicationExtensions:[]},r=new ss(new Uint8ClampedArray(n));if(r.getString(6)!=="GIF89a")throw new Error("not a supported GIF file");s.width=r.nextTwoBytes(),s.height=r.nextTwoBytes();let a=r.nextByte(),l=(a&128)===128;s.colorRes=(a&112)>>>4,s.sortFlag=(a&8)===8;let c=1<<(a&7)+1,u=r.nextByte();s.pixelAspectRatio=r.nextByte(),s.pixelAspectRatio!==0&&(s.pixelAspectRatio=(s.pixelAspectRatio+15)/64),l&&(s.globalColorTable=Nc(r,c));let f=(()=>{try{return new ImageData(s.width,s.height,{colorSpace:"srgb"})}catch(k){if(k instanceof DOMException&&k.name==="IndexSizeError")return null;throw k}})();if(f==null)throw new Error("GIF frame size is to large");let{r:d,g:p,b:m}=s.globalColorTable[u];f.data.set(l?[d,p,m,255]:[0,0,0,0]);for(let k=4;k<f.data.length;k*=2)f.data.copyWithin(k,0,k);s.backgroundImage=f;let y=-1,x=!0,_=-1,w=k=>(k&&(x=!0),y),P=k=>(k!=null&&(_=k),_);try{do x&&(s.frames.push({left:0,top:0,width:0,height:0,disposalMethod:we.Replace,image:new ImageData(1,1,{colorSpace:"srgb"}),plainTextData:null,userInputDelayFlag:!1,delayTime:0,sortFlag:!1,localColorTable:[],reserved:0,GCreserved:0}),y++,_=-1,x=!1);while(!await Fh(r,s,i,w,P,e));s.frames.length--;for(let k of s.frames){if(k.userInputDelayFlag&&k.delayTime===0){s.totalTime=1/0;break}s.totalTime+=k.delayTime}return s}catch(k){throw k instanceof EvalError?new Error(`error while parsing frame ${y} "${k.message}"`):k}}function Uc(t){let{context:e,radius:i,particle:o,delta:n}=t,s=o.image;if(!s?.gifData||!s.gif)return;let r=new OffscreenCanvas(s.gifData.width,s.gifData.height),a=r.getContext("2d");if(!a)throw new Error("could not create offscreen canvas context");a.imageSmoothingQuality="low",a.imageSmoothingEnabled=!1,a.clearRect(fe.x,fe.y,r.width,r.height),o.gifLoopCount===void 0&&(o.gifLoopCount=s.gifLoopCount??Tr);let l=o.gifFrame??Dh,c={x:-s.gifData.width*Bc,y:-s.gifData.height*Bc},u=s.gifData.frames[l];if(o.gifTime===void 0&&(o.gifTime=Eh),!!u.bitmap){switch(e.scale(i/s.gifData.width,i/s.gifData.height),u.disposalMethod){case we.UndefinedA:case we.UndefinedB:case we.UndefinedC:case we.UndefinedD:case we.Replace:a.drawImage(u.bitmap,u.left,u.top),e.drawImage(r,c.x,c.y),a.clearRect(fe.x,fe.y,r.width,r.height);break;case we.Combine:a.drawImage(u.bitmap,u.left,u.top),e.drawImage(r,c.x,c.y);break;case we.RestoreBackground:a.drawImage(u.bitmap,u.left,u.top),e.drawImage(r,c.x,c.y),a.clearRect(fe.x,fe.y,r.width,r.height),s.gifData.globalColorTable.length?a.putImageData(s.gifData.backgroundImage,c.x,c.y):a.putImageData(s.gifData.frames[qc].image,c.x+u.left,c.y+u.top);break;case we.RestorePrevious:{let f=a.getImageData(fe.x,fe.y,r.width,r.height);a.drawImage(u.bitmap,u.left,u.top),e.drawImage(r,c.x,c.y),a.clearRect(fe.x,fe.y,r.width,r.height),a.putImageData(f,fe.x,fe.y)}break}if(o.gifTime+=n.value,o.gifTime>u.delayTime){if(o.gifTime-=u.delayTime,++l>=s.gifData.frames.length){if(--o.gifLoopCount<=Tr)return;l=qc,a.clearRect(fe.x,fe.y,r.width,r.height)}o.gifFrame=l}e.scale(s.gifData.width/i,s.gifData.height/i)}}async function Hc(t){if(t.type!=="gif"){await Tt(t);return}t.loading=!0;try{t.gifData=await Ah(t.source),t.gifLoopCount=Lh(t.gifData)??Tr,t.gifLoopCount||(t.gifLoopCount=1/0)}catch{t.error=!0}t.loading=!1}var Vh=2,Bh=1,qh=12,Nh=1,rs=class{constructor(e){this.validTypes=["image","images"],this.loadImageShape=async i=>{if(!this._engine.loadImage)throw new Error(`${J} image shape not initialized`);await this._engine.loadImage({gif:i.gif,name:i.name,replaceColor:i.replaceColor??!1,src:i.src})},this._engine=e}addImage(e){this._engine.images||(this._engine.images=[]),this._engine.images.push(e)}draw(e){let{context:i,radius:o,particle:n,opacity:s}=e,r=n.image,a=r?.element;if(r){if(i.globalAlpha=s,r.gif&&r.gifData)Uc(e);else if(a){let l=r.ratio,c={x:-o,y:-o},u=o*Vh;i.drawImage(a,c.x,c.y,u,u/l)}i.globalAlpha=Bh}}getSidesCount(){return qh}async init(e){let i=e.actualOptions;if(!(!i.preload||!this._engine.loadImage))for(let o of i.preload)await this._engine.loadImage(o)}loadShape(e){if(e.shape!=="image"&&e.shape!=="images")return;this._engine.images||(this._engine.images=[]);let i=e.shapeData;if(!i)return;this._engine.images.find(n=>n.name===i.name||n.source===i.src)||this.loadImageShape(i).then(()=>{this.loadShape(e)})}particleInit(e,i){if(i.shape!=="image"&&i.shape!=="images")return;this._engine.images||(this._engine.images=[]);let o=this._engine.images,n=i.shapeData;if(!n)return;let s=i.getFillColor(),r=o.find(l=>l.name===n.name||l.source===n.src);if(!r)return;let a=n.replaceColor??r.replaceColor;if(r.loading){setTimeout(()=>{this.particleInit(e,i)});return}(async()=>{let l;r.svgData&&s?l=await Vc(r,n,s,i):l={color:s,data:r,element:r.element,gif:r.gif,gifData:r.gifData,gifLoopCount:r.gifLoopCount,loaded:!0,ratio:n.width&&n.height?n.width/n.height:r.ratio??Nh,replaceColor:a,source:n.src},l.ratio||(l.ratio=1);let c=n.fill??i.shapeFill,u=n.close??i.shapeClose,f={image:l,fill:c,close:u};i.image=f.image,i.shapeFill=f.fill,i.shapeClose=f.close})()}};var as=class{constructor(){this.src="",this.gif=!1}load(e){h(e)||(e.gif!==void 0&&(this.gif=e.gif),e.height!==void 0&&(this.height=e.height),e.name!==void 0&&(this.name=e.name),e.replaceColor!==void 0&&(this.replaceColor=e.replaceColor),e.src!==void 0&&(this.src=e.src),e.width!==void 0&&(this.width=e.width))}};var ls=class{constructor(e){this.id="imagePreloader",this._engine=e}async getPlugin(){return await Promise.resolve(),{}}loadOptions(e,i){if(!i?.preload)return;e.preload||(e.preload=[]);let o=e.preload;for(let n of i.preload){let s=o.find(r=>r.name===n.name||r.src===n.src);if(s)s.load(n);else{let r=new as;r.load(n),o.push(r)}}}needsPlugin(){return!0}};var Uh=3;function Hh(t){t.loadImage||(t.loadImage=async e=>{if(!e.name&&!e.src)throw new Error(`${J} no image source provided`);if(t.images||(t.images=[]),!t.images.find(i=>i.name===e.name||i.source===e.src))try{let i={gif:e.gif??!1,name:e.name??e.src,source:e.src,type:e.src.substring(e.src.length-Uh),error:!1,loading:!0,replaceColor:e.replaceColor,ratio:e.width&&e.height?e.width/e.height:void 0};t.images.push(i);let o;e.gif?o=Hc:o=e.replaceColor?Ac:Tt,await o(i)}catch{throw new Error(`${J} ${e.name??e.src} not found`)}})}async function Wc(t,e=!0){t.checkVersion("3.9.1"),Hh(t);let i=new ls(t);await t.addPlugin(i,e),await t.addShape(new rs(t),e)}var cs=class extends ${constructor(){super(),this.sync=!1}load(e){h(e)||(super.load(e),e.sync!==void 0&&(this.sync=e.sync))}};var us=class extends ${constructor(){super(),this.sync=!1}load(e){h(e)||(super.load(e),e.sync!==void 0&&(this.sync=e.sync))}};var fs=class{constructor(){this.count=0,this.delay=new cs,this.duration=new us}load(e){h(e)||(e.count!==void 0&&(this.count=e.count),this.delay.load(e.delay),this.duration.load(e.duration))}};var Ft=0,Wh=-1,jc=0,$c=0;function Gc(t,e,i){if(!t.life)return;let o=t.life,n=!1;if(t.spawning)if(o.delayTime+=e.value,o.delayTime>=t.life.delay)n=!0,t.spawning=!1,o.delayTime=Ft,o.time=Ft;else return;if(o.duration===Wh||t.spawning||(n?o.time=Ft:o.time+=e.value,o.time<o.duration))return;if(o.time=Ft,t.life.count>jc&&t.life.count--,t.life.count===jc){t.destroy();return}let s=b($c,i.width),r=b($c,i.width);t.position.x=U(s),t.position.y=U(r),t.spawning=!0,o.delayTime=Ft,o.time=Ft,t.reset();let a=t.options.life;a&&(o.delay=g(a.delay.value)*1e3,o.duration=g(a.duration.value)*1e3)}var ct=0,Qc=1,Xc=-1,hs=class{constructor(e){this.container=e}init(e){let i=this.container,o=e.options,n=o.life;n&&(e.life={delay:i.retina.reduceFactor?g(n.delay.value)*(n.delay.sync?Qc:v())/i.retina.reduceFactor*1e3:ct,delayTime:ct,duration:i.retina.reduceFactor?g(n.duration.value)*(n.duration.sync?Qc:v())/i.retina.reduceFactor*1e3:ct,time:ct,count:n.count},e.life.duration<=ct&&(e.life.duration=Xc),e.life.count<=ct&&(e.life.count=Xc),e.life&&(e.spawning=e.life.delay>ct))}isEnabled(e){return!e.destroyed}loadOptions(e,...i){e.life||(e.life=new fs);for(let o of i)e.life.load(o?.life)}update(e,i){!this.isEnabled(e)||!e.life||Gc(e,i,this.container.canvas.size)}};async function Yc(t,e=!0){t.checkVersion("3.9.1"),await t.addParticleUpdater("life",async i=>Promise.resolve(new hs(i)),e)}function Zc(t){let{context:e,particle:i,radius:o}=t,n=i.shapeData,s=0;e.moveTo(-o,s),e.lineTo(o,s),e.lineCap=n?.cap??"butt"}var jh=1,ds=class{constructor(){this.validTypes=["line"]}draw(e){Zc(e)}getSidesCount(){return jh}};async function Kc(t,e=!0){t.checkVersion("3.9.1"),await t.addShape(new ds,e)}var Jc=.5,ps=class{init(){}isEnabled(e){return!_e()&&!e.destroyed&&e.container.actualOptions.interactivity.events.onHover.parallax.enable}move(e){let i=e.container,o=i.actualOptions,n=o.interactivity.events.onHover.parallax;if(_e()||!n.enable)return;let s=n.force,r=i.interactivity.mouse.position;if(!r)return;let a=i.canvas.size,l={x:a.width*Jc,y:a.height*Jc},c=n.smooth,u=e.getRadius()/s,f={x:(r.x-l.x)*u,y:(r.y-l.y)*u},{offset:d}=e;d.x+=(f.x-d.x)/c,d.y+=(f.y-d.y)/c}};async function eu(t,e=!0){t.checkVersion("3.9.1"),await t.addMover("parallax",()=>Promise.resolve(new ps),e)}var tu=1e3,$h=1,ms=class extends Qe{constructor(e){super(e)}clear(){}init(){}interact(e){let i=this.container;e.attractDistance===void 0&&(e.attractDistance=g(e.options.move.attract.distance)*i.retina.pixelRatio);let o=e.attractDistance,n=e.getPosition(),s=i.particles.quadTree.queryCircle(n,o);for(let r of s){if(e===r||!r.options.move.attract.enable||r.destroyed||r.spawning)continue;let a=r.getPosition(),{dx:l,dy:c}=A(n,a),u=e.options.move.attract.rotate,f=l/(u.x*tu),d=c/(u.y*tu),p=r.size.value/e.size.value,m=$h/p;e.velocity.x-=f*p,e.velocity.y-=d*p,r.velocity.x+=f*m,r.velocity.y+=d*m}}isEnabled(e){return e.options.move.attract.enable}reset(){}};async function iu(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("particlesAttract",i=>Promise.resolve(new ms(i)),e)}var Gh=.5,Qh=10,Xh=0;function ou(t,e,i,o,n,s){let r=K(t.options.collisions.absorb.speed*n.factor/Qh,Xh,o);t.size.value+=r*Gh,i.size.value-=r,o<=s&&(i.size.value=0,i.destroy())}function nu(t,e,i,o){let n=t.getRadius(),s=e.getRadius();n===void 0&&s!==void 0?t.destroy():n!==void 0&&s===void 0?e.destroy():n!==void 0&&s!==void 0&&(n>=s?ou(t,n,e,s,i,o):ou(e,s,t,n,i,o))}var su=t=>{t.collisionMaxSpeed===void 0&&(t.collisionMaxSpeed=g(t.options.collisions.maxSpeed)),t.velocity.length>t.collisionMaxSpeed&&(t.velocity.length=t.collisionMaxSpeed)};function gs(t,e){Ri(Qt(t),Qt(e)),su(t),su(e)}function ru(t,e){!t.unbreakable&&!e.unbreakable&&gs(t,e),t.getRadius()===void 0&&e.getRadius()!==void 0?t.destroy():t.getRadius()!==void 0&&e.getRadius()===void 0?e.destroy():t.getRadius()!==void 0&&e.getRadius()!==void 0&&(t.getRadius()>=e.getRadius()?e:t).destroy()}function au(t,e,i,o){switch(t.options.collisions.mode){case st.absorb:{nu(t,e,i,o);break}case st.bounce:{gs(t,e);break}case st.destroy:{ru(t,e);break}}}var Yh=2,ys=class extends Qe{constructor(e){super(e)}clear(){}init(){}interact(e,i){if(e.destroyed||e.spawning)return;let o=this.container,n=e.getPosition(),s=e.getRadius(),r=o.particles.quadTree.queryCircle(n,s*Yh);for(let a of r){if(e===a||!a.options.collisions.enable||e.options.collisions.mode!==a.options.collisions.mode||a.destroyed||a.spawning)continue;let l=a.getPosition(),c=a.getRadius();if(Math.abs(Math.round(n.z)-Math.round(l.z))>s+c)continue;let u=V(n,l),f=s+c;u>f||au(e,a,i,o.retina.pixelRatio)}}isEnabled(e){return e.options.collisions.enable}reset(){}};async function lu(t,e=!0){t.checkVersion("3.9.1"),await t.addInteractor("particlesCollisions",i=>Promise.resolve(new ys(i)),e)}var Fr=2,xs=class extends G{constructor(e,i,o,n){super(e,i,o),this.canvasSize=n,this.canvasSize=q({},n)}contains(e){let{width:i,height:o}=this.canvasSize,{x:n,y:s}=e;return super.contains(e)||super.contains({x:n-i,y:s})||super.contains({x:n-i,y:s-o})||super.contains({x:n,y:s-o})}intersects(e){if(super.intersects(e))return!0;let i=e,o=e,n={x:e.position.x-this.canvasSize.width,y:e.position.y-this.canvasSize.height};if(o.radius!==void 0){let s=new G(n.x,n.y,o.radius*Fr);return super.intersects(s)}else if(i.size!==void 0){let s=new ne(n.x,n.y,i.size.width*Fr,i.size.height*Fr);return super.intersects(s)}return!1}};var bs=class{constructor(){this.blur=5,this.color=new D,this.color.value="#000",this.enable=!1}load(e){h(e)||(e.blur!==void 0&&(this.blur=e.blur),this.color=D.create(this.color,e.color),e.enable!==void 0&&(this.enable=e.enable))}};var vs=class{constructor(){this.enable=!1,this.frequency=1}load(e){h(e)||(e.color!==void 0&&(this.color=D.create(this.color,e.color)),e.enable!==void 0&&(this.enable=e.enable),e.frequency!==void 0&&(this.frequency=e.frequency),e.opacity!==void 0&&(this.opacity=e.opacity))}};var ws=class{constructor(){this.blink=!1,this.color=new D,this.color.value="#fff",this.consent=!1,this.distance=100,this.enable=!1,this.frequency=1,this.opacity=1,this.shadow=new bs,this.triangles=new vs,this.width=1,this.warp=!1}load(e){h(e)||(e.id!==void 0&&(this.id=e.id),e.blink!==void 0&&(this.blink=e.blink),this.color=D.create(this.color,e.color),e.consent!==void 0&&(this.consent=e.consent),e.distance!==void 0&&(this.distance=e.distance),e.enable!==void 0&&(this.enable=e.enable),e.frequency!==void 0&&(this.frequency=e.frequency),e.opacity!==void 0&&(this.opacity=e.opacity),this.shadow.load(e.shadow),this.triangles.load(e.triangles),e.width!==void 0&&(this.width=e.width),e.warp!==void 0&&(this.warp=e.warp))}};var cu=2,Zh=1,_s={x:0,y:0},Kh=0;function Jh(t,e,i,o,n){let{dx:s,dy:r,distance:a}=A(t,e);if(!n||a<=i)return a;let l={x:Math.abs(s),y:Math.abs(r)},c={x:Math.min(l.x,o.width-l.x),y:Math.min(l.y,o.height-l.y)};return Math.sqrt(c.x**cu+c.y**cu)}var ks=class extends Qe{constructor(e,i){super(e),this._setColor=o=>{if(!o.options.links)return;let n=this._linkContainer,s=o.options.links,r=s.id===void 0?n.particles.linksColor:n.particles.linksColors.get(s.id);if(r)return;let a=s.color;r=Ii(this._engine,a,s.blink,s.consent),s.id===void 0?n.particles.linksColor=r:n.particles.linksColors.set(s.id,r)},this._linkContainer=e,this._engine=i}clear(){}init(){this._linkContainer.particles.linksColor=void 0,this._linkContainer.particles.linksColors=new Map}interact(e){if(!e.options.links)return;e.links=[];let i=e.getPosition(),o=this.container,n=o.canvas.size;if(i.x<_s.x||i.y<_s.y||i.x>n.width||i.y>n.height)return;let s=e.options.links,r=s.opacity,a=e.retina.linksDistance??Kh,l=s.warp,c;l?c=new xs(i.x,i.y,a,n):c=new G(i.x,i.y,a);let u=o.particles.quadTree.query(c);for(let f of u){let d=f.options.links;if(e===f||!d?.enable||s.id!==d.id||f.spawning||f.destroyed||!f.links||e.links.some(x=>x.destination===f)||f.links.some(x=>x.destination===e))continue;let p=f.getPosition();if(p.x<_s.x||p.y<_s.y||p.x>n.width||p.y>n.height)continue;let m=Jh(i,p,a,n,l&&d.warp);if(m>a)continue;let y=(Zh-m/a)*r;this._setColor(e),e.links.push({destination:f,opacity:y})}}isEnabled(e){return!!e.options.links?.enable}loadParticlesOptions(e,...i){e.links||(e.links=new ws);for(let o of i)e.links.load(o?.links)}reset(){}};async function uu(t,e=!0){await t.addInteractor("particlesLinks",async i=>Promise.resolve(new ks(i,t)),e)}function ed(t,e,i,o){t.beginPath(),t.moveTo(e.x,e.y),t.lineTo(i.x,i.y),t.lineTo(o.x,o.y),t.closePath()}function fu(t){let e=!1,{begin:i,end:o,engine:n,maxDistance:s,context:r,canvasSize:a,width:l,backgroundMask:c,colorLine:u,opacity:f,links:d}=t;if(V(i,o)<=s)We(r,i,o),e=!0;else if(d.warp){let m,y,x={x:o.x-a.width,y:o.y},_=A(i,x);if(_.distance<=s){let w=i.y-_.dy/_.dx*i.x;m={x:0,y:w},y={x:a.width,y:w}}else{let w={x:o.x,y:o.y-a.height},P=A(i,w);if(P.distance<=s){let I=-(i.y-P.dy/P.dx*i.x)/(P.dy/P.dx);m={x:I,y:0},y={x:I,y:a.height}}else{let k={x:o.x-a.width,y:o.y-a.height},I=A(i,k);if(I.distance<=s){let Q=i.y-I.dy/I.dx*i.x;m={x:-Q/(I.dy/I.dx),y:Q},y={x:m.x+a.width,y:m.y+a.height}}}}m&&y&&(We(r,i,m),We(r,o,y),e=!0)}if(!e)return;r.lineWidth=l,c.enable&&(r.globalCompositeOperation=c.composite),r.strokeStyle=ae(u,f);let{shadow:p}=d;if(p.enable){let m=oe(n,p.color);m&&(r.shadowBlur=p.blur,r.shadowColor=ae(m))}r.stroke()}function hu(t){let{context:e,pos1:i,pos2:o,pos3:n,backgroundMask:s,colorTriangle:r,opacityTriangle:a}=t;ed(e,i,o,n),s.enable&&(e.globalCompositeOperation=s.composite),e.fillStyle=ae(r,a),e.fill()}function td(t){return t.sort((e,i)=>e-i),t.join("_")}function Lr(t,e){let i=td(t.map(n=>n.id)),o=e.get(i);return o===void 0&&(o=v(),e.set(i,o)),o}var du=0,Ar=0,pu=0,id=.5,od=1,Ps=class{constructor(e,i){this._drawLinkLine=(o,n)=>{let s=o.options.links;if(!s?.enable)return;let r=this._container,a=r.actualOptions,l=n.destination,c=o.getPosition(),u=l.getPosition(),f=n.opacity;r.canvas.draw(d=>{let p,m=o.options.twinkle?.lines;if(m?.enable){let w=m.frequency,P=oe(this._engine,m.color);v()<w&&P&&(p=P,f=g(m.opacity))}if(!p){let w=s.id!==void 0?r.particles.linksColors.get(s.id):r.particles.linksColor;p=Yt(o,l,w)}if(!p)return;let y=o.retina.linksWidth??Ar,x=o.retina.linksDistance??pu,{backgroundMask:_}=a;fu({context:d,width:y,begin:c,end:u,engine:this._engine,maxDistance:x,canvasSize:r.canvas.size,links:s,backgroundMask:_,colorLine:p,opacity:f})})},this._drawLinkTriangle=(o,n,s)=>{let r=o.options.links;if(!r?.enable)return;let a=r.triangles;if(!a.enable)return;let l=this._container,c=l.actualOptions,u=n.destination,f=s.destination,d=a.opacity??(n.opacity+s.opacity)*id;d<=du||l.canvas.draw(p=>{let m=o.getPosition(),y=u.getPosition(),x=f.getPosition(),_=o.retina.linksDistance??pu;if(V(m,y)>_||V(x,y)>_||V(x,m)>_)return;let w=oe(this._engine,a.color);if(!w){let P=r.id!==void 0?l.particles.linksColors.get(r.id):l.particles.linksColor;w=Yt(o,u,P)}w&&hu({context:p,pos1:m,pos2:y,pos3:x,backgroundMask:c.backgroundMask,colorTriangle:w,opacityTriangle:d})})},this._drawTriangles=(o,n,s,r)=>{let a=s.destination;if(!(o.links?.triangles.enable&&a.options.links?.triangles.enable))return;let l=a.links?.filter(c=>{let u=this._getLinkFrequency(a,c.destination);return a.options.links&&u<=a.options.links.frequency&&r.findIndex(d=>d.destination===c.destination)>=0});if(l?.length)for(let c of l){let u=c.destination;this._getTriangleFrequency(n,a,u)>o.links.triangles.frequency||this._drawLinkTriangle(n,s,c)}},this._getLinkFrequency=(o,n)=>Lr([o,n],this._freqs.links),this._getTriangleFrequency=(o,n,s)=>Lr([o,n,s],this._freqs.triangles),this._container=e,this._engine=i,this._freqs={links:new Map,triangles:new Map}}drawParticle(e,i){let{links:o,options:n}=i;if(!o?.length)return;let s=o.filter(r=>n.links&&(n.links.frequency>=od||this._getLinkFrequency(i,r.destination)<=n.links.frequency));for(let r of s)this._drawTriangles(n,i,r,s),r.opacity>du&&(i.retina.linksWidth??Ar)>Ar&&this._drawLinkLine(i,r)}async init(){this._freqs.links=new Map,this._freqs.triangles=new Map,await Promise.resolve()}particleCreated(e){if(e.links=[],!e.options.links)return;let i=this._container.retina.pixelRatio,{retina:o}=e,{distance:n,width:s}=e.options.links;o.linksDistance=n*i,o.linksWidth=s*i}particleDestroyed(e){e.links=[]}};var Os=class{constructor(e){this.id="links",this._engine=e}getPlugin(e){return Promise.resolve(new Ps(e,this._engine))}loadOptions(){}needsPlugin(){return!0}};async function mu(t,e=!0){let i=new Os(t);await t.addPlugin(i,e)}async function gu(t,e=!0){t.checkVersion("3.9.1"),await uu(t,e),await mu(t,e)}var nd=180,Cs={x:0,y:0},sd=2;function yu(t,e,i){let{context:o}=t,n=i.count.numerator*i.count.denominator,s=i.count.numerator/i.count.denominator,r=nd*(s-sd)/s,a=Math.PI-ue(r);if(o){o.beginPath(),o.translate(e.x,e.y),o.moveTo(Cs.x,Cs.y);for(let l=0;l<n;l++)o.lineTo(i.length,Cs.y),o.translate(i.length,Cs.y),o.rotate(a)}}var rd=5,Lt=class{draw(e){let{particle:i,radius:o}=e,n=this.getCenter(i,o),s=this.getSidesData(i,o);yu(e,n,s)}getSidesCount(e){let i=e.shapeData;return Math.round(g(i?.sides??rd))}};var xu=3.5,bu=2.66,ad=3,Ms=class extends Lt{constructor(){super(...arguments),this.validTypes=["polygon"]}getCenter(e,i){return{x:-i/(e.sides/xu),y:-i/(bu/xu)}}getSidesData(e,i){let o=e.sides;return{count:{denominator:1,numerator:o},length:i*bu/(o/ad)}}};var ld=1.66,cd=3,ud=2,Ss=class extends Lt{constructor(){super(...arguments),this.validTypes=["triangle"]}getCenter(e,i){return{x:-i,y:i/ld}}getSidesCount(){return cd}getSidesData(e,i){let o=i*ud;return{count:{denominator:2,numerator:3},length:o}}};async function fd(t,e=!0){t.checkVersion("3.9.1"),await t.addShape(new Ms,e)}async function hd(t,e=!0){t.checkVersion("3.9.1"),await t.addShape(new Ss,e)}async function vu(t,e=!0){t.checkVersion("3.9.1"),await fd(t,e),await hd(t,e)}var zs=class{constructor(){this.enable=!1,this.speed=0,this.decay=0,this.sync=!1}load(e){h(e)||(e.enable!==void 0&&(this.enable=e.enable),e.speed!==void 0&&(this.speed=b(e.speed)),e.decay!==void 0&&(this.decay=b(e.decay)),e.sync!==void 0&&(this.sync=e.sync))}};var Rs=class extends ${constructor(){super(),this.animation=new zs,this.direction=ie.clockwise,this.path=!1,this.value=0}load(e){h(e)||(super.load(e),e.direction!==void 0&&(this.direction=e.direction),this.animation.load(e.animation),e.path!==void 0&&(this.path=e.path))}};var wu=2,dd=Math.PI*wu,pd=1,md=360,Ds=class{constructor(e){this.container=e}init(e){let i=e.options.rotate;if(!i)return;e.rotate={enable:i.animation.enable,value:ue(g(i.value)),min:0,max:dd},e.pathRotation=i.path;let o=i.direction;switch(o===ie.random&&(o=Math.floor(v()*wu)>0?ie.counterClockwise:ie.clockwise),o){case ie.counterClockwise:case"counterClockwise":e.rotate.status=B.decreasing;break;case ie.clockwise:e.rotate.status=B.increasing;break}let n=i.animation;n.enable&&(e.rotate.decay=pd-g(n.decay),e.rotate.velocity=g(n.speed)/md*this.container.retina.reduceFactor,n.sync||(e.rotate.velocity*=v())),e.rotation=e.rotate.value}isEnabled(e){let i=e.options.rotate;return i?!e.destroyed&&!e.spawning&&(!!i.value||i.animation.enable||i.path):!1}loadOptions(e,...i){e.rotate||(e.rotate=new Rs);for(let o of i)e.rotate.load(o?.rotate)}update(e,i){this.isEnabled(e)&&(e.isRotating=!!e.rotate,e.rotate&&(He(e,e.rotate,!1,ye.none,i),e.rotation=e.rotate.value))}};async function _u(t,e=!0){t.checkVersion("3.9.1"),await t.addParticleUpdater("rotate",i=>Promise.resolve(new Ds(i)),e)}var gd=Math.sqrt(2),yd=2;function ku(t){let{context:e,radius:i}=t,o=i/gd,n=o*yd;e.rect(-o,-o,n,n)}var xd=4,Es=class{constructor(){this.validTypes=["edge","square"]}draw(e){ku(e)}getSidesCount(){return xd}};async function Pu(t,e=!0){t.checkVersion("3.9.1"),await t.addShape(new Es,e)}var At={x:0,y:0};function Ou(t){let{context:e,particle:i,radius:o}=t,n=i.sides,s=i.starInset??2;e.moveTo(At.x,At.y-o);for(let r=0;r<n;r++)e.rotate(Math.PI/n),e.lineTo(At.x,At.y-o*s),e.rotate(Math.PI/n),e.lineTo(At.x,At.y-o)}var bd=2,vd=5,Is=class{constructor(){this.validTypes=["star"]}draw(e){Ou(e)}getSidesCount(e){let i=e.shapeData;return Math.round(g(i?.sides??vd))}particleInit(e,i){let o=i.shapeData;i.starInset=g(o?.inset??bd)}};async function Cu(t,e=!0){t.checkVersion("3.9.1"),await t.addShape(new Is,e)}var wd=1,Ts=class{constructor(e,i){this._container=e,this._engine=i}init(e){let i=this._container,o=e.options,n=T(o.stroke,e.id,o.reduceDuplicates);e.strokeWidth=g(n.width)*i.retina.pixelRatio,e.strokeOpacity=g(n.opacity??wd),e.strokeAnimation=n.color?.animation;let s=ce(this._engine,n.color)??e.getFillColor();s&&(e.strokeColor=Ti(s,e.strokeAnimation,i.retina.reduceFactor))}isEnabled(e){let i=e.strokeAnimation,{strokeColor:o}=e;return!e.destroyed&&!e.spawning&&!!i&&(o?.h.value!==void 0&&o.h.enable||o?.s.value!==void 0&&o.s.enable||o?.l.value!==void 0&&o.l.enable)}update(e,i){this.isEnabled(e)&&Fi(e.strokeColor,i)}};async function Mu(t,e=!0){t.checkVersion("3.9.1"),await t.addParticleUpdater("strokeColor",i=>Promise.resolve(new Ts(i,t)),e)}async function Su(t,e=!0){t.checkVersion("3.9.1"),await eu(t,!1),await mc(t,!1),await wc(t,!1),await Pc(t,!1),await zc(t,!1),await Dc(t,!1),await Ec(t,!1),await Ic(t,!1),await Tc(t,!1),await Fc(t,!1),await Lc(t,!1),await iu(t,!1),await lu(t,!1),await gu(t,!1),await ac(t,!1),await uc(t,!1),await Wc(t,!1),await Kc(t,!1),await vu(t,!1),await Pu(t,!1),await Cu(t,!1),await Yc(t,!1),await _u(t,!1),await Mu(t,!1),await rc(t,e)}var Ru=2,zu=.5;function Du(t){let{context:e,particle:i,radius:o,opacity:n}=t,s=i.shapeData;if(!s)return;let r=s.value;if(r===void 0)return;i.text===void 0&&(i.text=T(r,i.randomIndexData));let a=i.text,l=s.style??"",c=s.weight??"400",u=Math.round(o)*Ru,f=s.font??"Verdana",d=i.shapeFill,p=a?.split(`
`);if(p){e.font=`${l} ${c} ${u}px "${f}"`,e.globalAlpha=n;for(let m=0;m<p.length;m++)_d(e,p[m],o,n,m,d);e.globalAlpha=1}}function _d(t,e,i,o,n,s){let r=e.length*i*zu,a={x:-r,y:i*zu},l=i*Ru;s?t.fillText(e,a.x,a.y+l*n):t.strokeText(e,a.x,a.y+l*n)}var Fs=class{constructor(){this.validTypes=["text","character","char","multiline-text"]}draw(e){Du(e)}async init(e){let i=e.actualOptions,{validTypes:o}=this;if(o.find(n=>M(n,i.particles.shape.type))){let n=o.map(r=>i.particles.shape.options[r]).find(r=>!!r),s=[];S(n,r=>{s.push(Gt(r.font,r.weight))}),await Promise.all(s)}}particleInit(e,i){if(!i.shape||!this.validTypes.includes(i.shape))return;let o=i.shapeData;if(o===void 0)return;let n=o.value;n!==void 0&&(i.text=T(n,i.randomIndexData))}};async function Eu(t,e=!0){t.checkVersion("3.9.1"),await t.addShape(new Fs,e)}var Le=(function(t){return t.clockwise="clockwise",t.counterClockwise="counter-clockwise",t.random="random",t})(Le||{});var Ls=class{constructor(){this.enable=!1,this.speed=0,this.decay=0,this.sync=!1}load(e){h(e)||(e.enable!==void 0&&(this.enable=e.enable),e.speed!==void 0&&(this.speed=b(e.speed)),e.decay!==void 0&&(this.decay=b(e.decay)),e.sync!==void 0&&(this.sync=e.sync))}};var As=class extends ${constructor(){super(),this.animation=new Ls,this.direction=Le.clockwise,this.enable=!1,this.value=0}load(e){super.load(e),!h(e)&&(this.animation.load(e.animation),e.direction!==void 0&&(this.direction=e.direction),e.enable!==void 0&&(this.enable=e.enable))}};var fi=1,Iu=2,kd=Math.PI*Iu,Pd=360,Vs=class{constructor(e){this.container=e}getTransformValues(e){let i=e.tilt?.enable&&e.tilt;return{b:i?Math.cos(i.value)*i.cosDirection:void 0,c:i?Math.sin(i.value)*i.sinDirection:void 0}}init(e){let i=e.options.tilt;if(!i)return;e.tilt={enable:i.enable,value:ue(g(i.value)),sinDirection:v()>=.5?fi:-fi,cosDirection:v()>=.5?fi:-fi,min:0,max:kd};let o=i.direction;switch(o===Le.random&&(o=Math.floor(v()*Iu)>0?Le.counterClockwise:Le.clockwise),o){case Le.counterClockwise:case"counterClockwise":e.tilt.status=B.decreasing;break;case Le.clockwise:e.tilt.status=B.increasing;break}let n=e.options.tilt?.animation;n?.enable&&(e.tilt.decay=fi-g(n.decay),e.tilt.velocity=g(n.speed)/Pd*this.container.retina.reduceFactor,n.sync||(e.tilt.velocity*=v()))}isEnabled(e){let i=e.options.tilt?.animation;return!e.destroyed&&!e.spawning&&!!i?.enable}loadOptions(e,...i){e.tilt||(e.tilt=new As);for(let o of i)e.tilt.load(o?.tilt)}async update(e,i){!this.isEnabled(e)||!e.tilt||(He(e,e.tilt,!1,ye.none,i),await Promise.resolve())}};async function Tu(t,e=!0){t.checkVersion("3.9.1"),await t.addParticleUpdater("tilt",i=>Promise.resolve(new Vs(i)),e)}var hi=class{constructor(){this.enable=!1,this.frequency=.05,this.opacity=1}load(e){h(e)||(e.color!==void 0&&(this.color=D.create(this.color,e.color)),e.enable!==void 0&&(this.enable=e.enable),e.frequency!==void 0&&(this.frequency=e.frequency),e.opacity!==void 0&&(this.opacity=b(e.opacity)))}};var Bs=class{constructor(){this.lines=new hi,this.particles=new hi}load(e){h(e)||(this.lines.load(e.lines),this.particles.load(e.particles))}};var qs=class{constructor(e){this._engine=e}getColorStyles(e,i,o,n){let s=e.options,r=s.twinkle;if(!r)return{};let a=r.particles,l=a.enable&&v()<a.frequency,c=e.options.zIndex,u=1,f=(u-e.zIndexFactor)**c.opacityRate,d=l?g(a.opacity)*f:n,p=ce(this._engine,a.color),m=p?Pe(p,d):void 0,y={},x=l&&m;return y.fill=x?m:void 0,y.stroke=x?m:void 0,y}async init(){await Promise.resolve()}isEnabled(e){let i=e.options,o=i.twinkle;return o?o.particles.enable:!1}loadOptions(e,...i){e.twinkle||(e.twinkle=new Bs);for(let o of i)e.twinkle.load(o?.twinkle)}async update(){await Promise.resolve()}};async function Fu(t,e=!0){t.checkVersion("3.9.1"),await t.addParticleUpdater("twinkle",()=>Promise.resolve(new qs(t)),e)}var Ns=class{constructor(){this.angle=50,this.move=10}load(e){h(e)||(e.angle!==void 0&&(this.angle=b(e.angle)),e.move!==void 0&&(this.move=b(e.move)))}};var Us=class{constructor(){this.distance=5,this.enable=!1,this.speed=new Ns}load(e){if(!h(e)&&(e.distance!==void 0&&(this.distance=b(e.distance)),e.enable!==void 0&&(this.enable=e.enable),e.speed!==void 0))if(Z(e.speed))this.speed.load({angle:e.speed});else{let i=e.speed;i.min!==void 0?this.speed.load({angle:i}):this.speed.load(e.speed)}}};var Od=0,Cd=2,Md=Math.PI*Cd,Sd=60;function Lu(t,e){let{wobble:i}=t.options,{container:o,wobble:n}=t;if(!i?.enable||!n)return;let s=o.retina.reduceFactor,r=n.angleSpeed*e.factor*s,a=n.moveSpeed*e.factor*s,l=a*(t.retina.wobbleDistance??Od)/(1e3/Sd),c=Md,{position:u}=t;n.angle+=r,n.angle>c&&(n.angle-=c),u.x+=l*Math.cos(n.angle),u.y+=l*Math.abs(Math.sin(n.angle))}var zd=2,Rd=Math.PI*zd,Dd=360,Ed=10,Id=0,Hs=class{constructor(e){this.container=e}init(e){let i=e.options.wobble;i?.enable?e.wobble={angle:v()*Rd,angleSpeed:g(i.speed.angle)/Dd,moveSpeed:g(i.speed.move)/Ed}:e.wobble={angle:0,angleSpeed:0,moveSpeed:0},e.retina.wobbleDistance=g(i?.distance??Id)*this.container.retina.pixelRatio}isEnabled(e){return!e.destroyed&&!e.spawning&&!!e.options.wobble?.enable}loadOptions(e,...i){e.wobble||(e.wobble=new Us);for(let o of i)e.wobble.load(o?.wobble)}update(e,i){this.isEnabled(e)&&Lu(e,i)}};async function Au(t,e=!0){t.checkVersion("3.9.1"),await t.addParticleUpdater("wobble",i=>Promise.resolve(new Hs(i)),e)}async function Vu(t,e=!0){t.checkVersion("3.9.1"),await _l(t,!1),await Vl(t,!1),await Tu(t,!1),await Fu(t,!1),await Au(t,!1),await Eu(t,!1),await Tl(t,!1),await vl(t,!1),await Ml(t,!1),await Rl(t,!1),await El(t,!1),await Su(t,e)}var Ws=class t{id=Qs("tsparticles");ngParticlesService=$r(Lo);options=Qs();ngOnInit(){this.ngParticlesService.init(async e=>{await Vu(e)})}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=ft({type:t,selectors:[["spk-particles"]],inputs:{id:[1,"id"],options:[1,"options"]},decls:1,vars:2,consts:[[3,"id","options"]],template:function(i,o){i&1&&Me(0,"ngx-particles",0),i&2&&ht("id",o.id())("options",o.options())},dependencies:[gl,ml],encapsulation:2})};var Bu={fpsLimit:60,interactivity:{events:{onClick:{enable:!0},onHover:{enable:!0},resize:{enable:!0}},modes:{push:{quantity:4},repulse:{distance:200,duration:.4}}},particles:{number:{value:80,density:{enable:!0,value_area:800}},color:{value:"#845adf"},shape:{type:"circle"},opacity:{value:.5},size:{value:2,random:!0},line_linked:{enable:!0,distance:150,color:"#d1d9e0",opacity:.4,width:1},move:{enable:!0,speed:2,out_mode:"out"}}};var qu=class t{particlesOptions=Bu;static \u0275fac=function(i){return new(i||t)};static \u0275cmp=ft({type:t,selectors:[["app-error404"]],decls:20,vars:1,consts:[["id","particles-js",1,"page","error-bg","dark:!bg-bodybg"],["id","tsparticles",3,"options"],[1,"error-page"],[1,"container","text-defaulttextcolo","dark:text-defaulttextcolor/70r","text-defaultsize"],[1,"text-center","p-5","my-auto"],[1,"flex","items-center","justify-center","h-full","!text-defaulttextcolor"],[1,"xl:col-span-3"],[1,"xl:col-span-6","col-span-12"],[1,"error-text","sm:mb-0","mb-2"],[1,"text-[1.125rem]","font-semibold","mb-4"],[1,"flex","justify-center","items-center","mb-[3rem]"],[1,"xl:col-span-6","w-[50%]"],[1,"mb-0","opacity-[0.7]"],["routerLink","/dashboards/crm",1,"ti-btn","bg-primary","text-white","font-semibold"],[1,"ri-arrow-left-line","align-middle","inline-block"]],template:function(i,o){i&1&&(Je(0,"div",0),Me(1,"spk-particles",1),Je(2,"div",2)(3,"div",3)(4,"div",4)(5,"div",5),Me(6,"div",6),Je(7,"div",7)(8,"p",8),Vt(9,"404"),dt(),Je(10,"p",9),Vt(11,"Oops \u{1F62D},The page you are looking for is not available."),dt(),Je(12,"div",10)(13,"div",11)(14,"p",12),Vt(15,"We are sorry for the inconvenience,The page you are trying to access has been removed or never been existed."),dt()()(),Je(16,"a",13),Me(17,"i",14),Vt(18,"BACK TO HOME"),dt()(),Me(19,"div",6),dt()()()()()),i&2&&(Xr(),ht("options",o.particlesOptions))},dependencies:[Jr,Kr,Ws],encapsulation:2})};export{qu as Error404};