PageSourceSearch

https://genderswap.fm/_app/immutable/nodes/5.DkaRIQ4b.js

js genderswap.fm collected 2026-10-03 23:52:28 UTC 143,375 bytes, 1 lines download raw bytes

1import{r as e,t}from"../chunks/DwTZBSUj.js";import{a as n,o as r,r as i}from"../chunks/BW02h1Jz.js";import{A as a,B as o,Ct as s,F as c,H as l,M as u,O as d,P as f,R as p,S as m,T as h,U as g,V as _,W as v,X as y,_t as b,b as x,ct as ee,dt as S,ft as C,ht as w,i as te,j as ne,k as re,lt as T,nt as ie,ot as E,r as ae,ut as oe,v as se,vt as ce,xt as D}from"../chunks/LEMyuIs8.js";import"../chunks/DB1G-0L_.js";import{d as le,i as ue,m as de,p as fe,s as pe}from"../chunks/BbbmDrWN.js";import{r as me}from"../chunks/DZ3O-gka.js";import{n as he,r as ge}from"../chunks/JWnI6gQl.js";import{t as _e}from"../chunks/DsOpQvul.js";import{n as ve,t as ye}from"../chunks/Dr6pXD-1.js";var be=`generated`,xe=`pointerdown`,Se=`pointerup`,Ce=`pointerleave`,we=`pointerout`,Te=`pointermove`,Ee=`touchstart`,De=`touchend`,Oe=`touchmove`,ke=`touchcancel`,Ae=`resize`,je=`visibilitychange`,O=`tsParticles - Error`,k=.5,A=1e3,j={x:0,y:0,z:0},Me={a:1,b:0,c:0,d:1},Ne=Math.PI*2,Pe=`true`,Fe=`false`,Ie=`canvas`,Le=.25,Re=.75,ze=-.25,Be=1.5,M;(function(e){e.bottom=`bottom`,e.bottomLeft=`bottom-left`,e.bottomRight=`bottom-right`,e.left=`left`,e.none=`none`,e.right=`right`,e.top=`top`,e.topLeft=`top-left`,e.topRight=`top-right`,e.outside=`outside`,e.inside=`inside`})(M||={});function Ve(e){return typeof e==`boolean`}function N(e){return typeof e==`string`}function P(e){return typeof e==`number`}function He(e){return typeof e==`object`&&!!e}function F(e){return Array.isArray(e)}function I(e){return e==null}var Ue=class e{constructor(e,t,n){if(this._updateFromAngle=(e,t)=>{this.x=Math.cos(e)*t,this.y=Math.sin(e)*t},!P(e)&&e){this.x=e.x,this.y=e.y;let t=e;this.z=t.z?t.z:j.z}else if(e!==void 0&&t!==void 0)this.x=e,this.y=t,this.z=n??j.z;else throw Error(`${O} Vector3d not initialized correctly`)}static get origin(){return e.create(j.x,j.y,j.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(t){return e.create(t.x,t.y,t.z)}static create(t,n,r){return new e(t,n,r)}add(t){return e.create(this.x+t.x,this.y+t.y,this.z+t.z)}addTo(e){this.x+=e.x,this.y+=e.y,this.z+=e.z}copy(){return e.clone(this)}distanceTo(e){return this.sub(e).length}distanceToSq(e){return this.sub(e).getLengthSq()}div(t){return e.create(this.x/t,this.y/t,this.z/t)}divTo(e){this.x/=e,this.y/=e,this.z/=e}getLengthSq(){return this.x**2+this.y**2}mult(t){return e.create(this.x*t,this.y*t,this.z*t)}multTo(e){this.x*=e,this.y*=e,this.z*=e}normalize(){let e=this.length;e!=0&&this.multTo(1/e)}rotate(t){return e.create(this.x*Math.cos(t)-this.y*Math.sin(t),this.x*Math.sin(t)+this.y*Math.cos(t),j.z)}setTo(e){this.x=e.x,this.y=e.y;let t=e;this.z=t.z?t.z:j.z}sub(t){return e.create(this.x-t.x,this.y-t.y,this.z-t.z)}subFrom(e){this.x-=e.x,this.y-=e.y,this.z-=e.z}},We=class e extends Ue{constructor(e,t){super(e,t,j.z)}static get origin(){return e.create(j.x,j.y)}static clone(t){return e.create(t.x,t.y)}static create(t,n){return new e(t,n)}},Ge=Math.random,Ke={nextFrame:e=>requestAnimationFrame(e),cancel:e=>cancelAnimationFrame(e)};function L(){return Ye(Ge(),0,1-2**-52)}function qe(e){return Ke.nextFrame(e)}function Je(e){Ke.cancel(e)}function Ye(e,t,n){return Math.min(Math.max(e,t),n)}function R(e){let t=Ze(e),n=Xe(e);return t===n&&(n=0),L()*(t-n)+n}function z(e){return P(e)?e:R(e)}function Xe(e){return P(e)?e:e.min}function Ze(e){return P(e)?e:e.max}function B(e,t){if(e===t||t===void 0&&P(e))return e;let n=Xe(e),r=Ze(e);return t===void 0?B(n,r):{min:Math.min(n,t),max:Math.max(r,t)}}function Qe(e,t){let n=e.x-t.x,r=e.y-t.y;return{dx:n,dy:r,distance:Math.sqrt(n**2+r**2)}}function $e(e,t){return Qe(e,t).distance}function et(e){return e*Math.PI/180}function tt(e,t,n){if(P(e))return et(e);switch(e){case M.top:return-Math.PI*k;case M.topRight:return-Math.PI*Le;case M.right:return 0;case M.bottomRight:return Math.PI*Le;case M.bottom:return Math.PI*k;case M.bottomLeft:return Math.PI*Re;case M.left:return Math.PI;case M.topLeft:return-Math.PI*Re;case M.inside:return Math.atan2(n.y-t.y,n.x-t.x);case M.outside:return Math.atan2(t.y-n.y,t.x-n.x);default:return L()*Ne}}function nt(e){let t=We.origin;return t.length=1,t.angle=e,t}function rt(e){return{x:(e.position?.x??L()*100)*e.size.width/100,y:(e.position?.y??L()*100)*e.size.height/100}}function it(e){let t={x:e.position?.x===void 0?void 0:z(e.position.x),y:e.position?.y===void 0?void 0:z(e.position.y)};return rt({size:e.size,position:t})}function at(e){return{x:e.position?.x??L()*e.size.width,y:e.position?.y??L()*e.size.height}}function ot(e){return e?e.endsWith(`%`)?parseFloat(e)/100:parseFloat(e):1}var st;(function(e){e.auto=`auto`,e.increase=`increase`,e.decrease=`decrease`,e.random=`random`})(st||={});var V;(function(e){e.increasing=`increasing`,e.decreasing=`decreasing`})(V||={});var ct;(function(e){e.none=`none`,e.max=`max`,e.min=`min`})(ct||={});var H;(function(e){e.bottom=`bottom`,e.left=`left`,e.right=`right`,e.top=`top`})(H||={});var lt;(function(e){e.precise=`precise`,e.percent=`percent`})(lt||={});var ut;(function(e){e.max=`max`,e.min=`min`,e.random=`random`})(ut||={});var dt={debug:console.debug,error:console.error,info:console.info,log:console.log,verbose:console.log,warning:console.warn};function ft(){return dt}function pt(e){let t=new Map;return(...n)=>{let r=JSON.stringify(n);if(t.has(r))return t.get(r);let i=e(...n);return t.set(r,i),i}}function mt(){return typeof window>`u`||!window||window.document===void 0||!window.document}function ht(){return!mt()&&typeof matchMedia<`u`}function gt(e){if(ht())return matchMedia(e)}function _t(e){if(!(mt()||typeof IntersectionObserver>`u`))return new IntersectionObserver(e)}function vt(e){if(!(mt()||typeof MutationObserver>`u`))return new MutationObserver(e)}function yt(e,t){return e===t||F(t)&&t.indexOf(e)>-1}async function bt(e,t){try{await document.fonts.load(`${t??`400`} 36px '${e??`Verdana`}'`)}catch{}}function xt(e){return Math.floor(L()*e.length)}
1function St(e,t,n=!0){return e[t!==void 0&&n?t%e.length:xt(e)]}function Ct(e,t,n,r,i){return wt(Tt(e,r??0),t,n,i)}function wt(e,t,n,r){let i=!0;return(!r||r===H.bottom)&&(i=e.top<t.height+n.x),i&&(!r||r===H.left)&&(i=e.right>n.x),i&&(!r||r===H.right)&&(i=e.left<t.width+n.y),i&&(!r||r===H.top)&&(i=e.bottom>n.y),i}function Tt(e,t){return{bottom:e.y+t,left:e.x-t,right:e.x+t,top:e.y-t}}function U(e,...t){for(let n of t){if(n==null)continue;if(!He(n)){e=n;continue}let t=Array.isArray(n);t&&(He(e)||!e||!Array.isArray(e))?e=[]:!t&&(He(e)||!e||Array.isArray(e))&&(e={});for(let t in n){if(t===`__proto__`)continue;let r=n[t],i=e;i[t]=He(r)&&Array.isArray(r)?r.map(e=>U(i[t],e)):U(i[t],r)}}return e}function Et(e,t){return F(e)?e.map((e,n)=>t(e,n)):t(e,0)}function W(e,t,n){return F(e)?St(e,t,n):e}function Dt(e,t){let n=e.value,r=e.animation,i={delayTime:z(r.delay)*A,enable:r.enable,value:z(e.value)*t,max:Ze(n)*t,min:Xe(n)*t,loops:0,maxLoops:z(r.count),time:0};if(r.enable){switch(i.decay=1-z(r.decay),r.mode){case st.increase:i.status=V.increasing;break;case st.decrease:i.status=V.decreasing;break;case st.random:i.status=L()>=.5?V.increasing:V.decreasing}let e=r.mode===st.auto;switch(r.startValue){case ut.min:i.value=i.min,e&&(i.status=V.increasing);break;case ut.max:i.value=i.max,e&&(i.status=V.decreasing);break;case ut.random:default:i.value=R(i),e&&(i.status=L()>=.5?V.increasing:V.decreasing)}}return i.initialValue=i.value,i}function Ot(e,t){if(e.mode!==lt.percent){let{mode:t,...n}=e;return n}return`x`in e?{x:e.x/100*t.width,y:e.y/100*t.height}:{width:e.width/100*t.width,height:e.height/100*t.height}}function kt(e,t){return Ot(e,t)}function At(e,t){return Ot(e,t)}function jt(e,t,n,r,i){switch(t){case ct.max:n>=i&&e.destroy();break;case ct.min:n<=r&&e.destroy()}}function Mt(e,t,n,r,i){if(e.destroyed||!t||!t.enable||(t.maxLoops??0)>0&&(t.loops??0)>(t.maxLoops??0))return;let a=(t.velocity??0)*i.factor,o=t.min,s=t.max,c=t.decay??1;if(t.time||=0,(t.delayTime??0)>0&&t.time<(t.delayTime??0)&&(t.time+=i.value),!((t.delayTime??0)>0&&t.time<(t.delayTime??0))){switch(t.status){case V.increasing:t.value>=s?(n?t.status=V.decreasing:t.value-=s,t.loops||=0,t.loops++):t.value+=a;break;case V.decreasing:t.value<=o?(n?t.status=V.increasing:t.value+=s,t.loops||=0,t.loops++):t.value-=a}
1t.velocity&&c!==1&&(t.velocity*=c),jt(e,r,t.value,o,s),e.destroyed||(t.value=Ye(t.value,o,s))}}function Nt(e){let t=document.createElement(`div`).style;if(!e)return t;for(let n in e){let r=e[n];if(!Object.prototype.hasOwnProperty.call(e,n)||I(r))continue;let i=e.getPropertyValue?.(r);if(!i)continue;let a=e.getPropertyPriority?.(r);a?t.setProperty?.(r,i,a):t.setProperty?.(r,i)}return t}function Pt(e){let t=document.createElement(`div`).style,n={width:`100%`,height:`100%`,margin:`0`,padding:`0`,borderWidth:`0`,position:`fixed`,zIndex:e.toString(10),"z-index":e.toString(10),top:`0`,left:`0`};for(let e in n){let r=n[e];t.setProperty(e,r)}return t}var Ft=pt(Pt),It;(function(e){e.darken=`darken`,e.enlighten=`enlighten`})(It||={});function Lt(e,t){if(t){for(let n of e.colorManagers.values())if(t.startsWith(n.stringPrefix))return n.parseString(t)}}function Rt(e,t,n,r=!0){if(!t)return;let i=N(t)?{value:t}:t;if(N(i.value))return zt(e,i.value,n,r);if(F(i.value))return Rt(e,{value:St(i.value,n,r)});for(let t of e.colorManagers.values()){let e=t.handleRangeColor(i);if(e)return e}}function zt(e,t,n,r=!0){if(!t)return;let i=N(t)?{value:t}:t;if(N(i.value))return i.value===`random`?Gt():Ht(e,i.value);if(F(i.value))return zt(e,{value:St(i.value,n,r)});for(let t of e.colorManagers.values()){let e=t.handleColor(i);if(e)return e}}function Bt(e,t,n,r=!0){let i=Rt(e,t,n,r);return i?Vt(i):void 0}function Vt(e){let t=e.r/255,n=e.g/255,r=e.b/255,i=Math.max(t,n,r),a=Math.min(t,n,r),o={h:0,l:(i+a)*k,s:0};return i!==a&&(o.s=o.l<.5?(i-a)/(i+a):(i-a)/(2-i-a),o.h=t===i?(n-r)/(i-a):o.h=n===i?2+(r-t)/(i-a):4+(t-n)/(i-a)),o.l*=100,o.s*=100,o.h*=60,o.h<0&&(o.h+=360),o.h>=360&&(o.h-=360),o}function Ht(e,t){return Lt(e,t)}function Ut(e){let t=(e.h%360+360)%360,n=Math.max(0,Math.min(100,e.s)),r=Math.max(0,Math.min(100,e.l)),i=t/360,a=n/100,o=r/100;if(n===0){let e=Math.round(o*255);return{r:e,g:e,b:e}}let s=(e,t,n)=>(n<0&&n++,n>1&&n--,n*6<1?e+(t-e)*6*n:n*2<1?t:n*3<2?e+(t-e)*(.6666666666666666-n)*6:e),c=o<.5?o*(1+a):o+a-o*a,l=2*o-c,u=1/3,d=Math.min(255,255*s(l,c,i+u)),f=Math.min(255,255*s(l,c,i)),p=Math.min(255,255*s(l,c,i-u));return{r:Math.round(d),g:Math.round(f),b:Math.round(p)}}function Wt(e){let t=Ut(e);return{a:e.a,b:t.b,g:t.g,r:t.r}}function Gt(e){let t=e??0;return{b:Math.floor(R(B(t,256))),g:Math.floor(R(B(t,256))),r:Math.floor(R(B(t,256)))}}function Kt(e,t){return`rgba(${e.r}, ${e.g}, ${e.b}, ${t??1})`}function qt(e,t){return`hsla(${e.h}, ${e.s}%, ${e.l}%, ${t??1})`}function Jt(e){return e===void 0?void 0:{h:e.h.value,s:e.s.value,l:e.l.value}}function Yt(e,t,n){let r={h:{enable:!1,value:e.h},s:{enable:!1,value:e.s},l:{enable:!1,value:e.l}};return t&&(Xt(r.h,t.h,n),Xt(r.s,t.s,n),Xt(r.l,t.l,n)),r}function Xt(e,t,n){e.enable=t.enable,e.enable?(e.velocity=z(t.speed)/100*n,e.decay=1-z(t.decay),e.status=V.increasing,e.loops=0,e.maxLoops=z(t.count),e.time=0,e.delayTime=z(t.delay)*A,t.sync||(e.velocity*=L(),e.value*=L()),e.initialValue=e.value,e.offset=B(t.offset)):e.velocity=0}function Zt(e,t,n,r){if(!e||!e.enable||(e.maxLoops??0)>0&&(e.loops??0)>(e.maxLoops??0)||(e.time||=0,(e.delayTime??0)>0&&e.time<(e.delayTime??0)&&(e.time+=r.value),(e.delayTime??0)>0&&e.time<(e.delayTime??0)))return;let i=e.offset?R(e.offset):0,a=(e.velocity??0)*r.factor+i*3.6,o=e.decay??1,s=Ze(t),c=Xe(t);!n||e.status===V.increasing?(e.value+=a,e.value>s&&(e.loops||=0,e.loops++,n?e.status=V.decreasing:e.value-=s)):(e.value-=a,e.value<0&&(e.loops||=0,e.loops++,e.status=V.increasing)),e.velocity&&o!==1&&(e.velocity*=o),e.value=Ye(e.value,c,s)}function Qt(e,t){if(!e)return;let{h:n,s:r,l:i}=e,a={h:{min:0,max:360},s:{min:0,max:100},l:{min:0,max:100}};n&&Zt(n,a.h,!1,t),r&&Zt(r,a.s,!0,t),i&&Zt(i,a.l,!0,t)}function $t(e,t,n){e.fillStyle=n??`rgba(0,0,0,0)`,e.fillRect(j.x,j.y,t.width,t.height)}function en(e,t,n,r){n&&(e.globalAlpha=r,e.drawImage(n,j.x,j.y,t.width,t.height),e.globalAlpha=1)}function tn(e,t){e.clearRect(j.x,j.y,t.width,t.height)}function nn(e){let{container:t,context:n,particle:r,delta:i,colorStyles:a,backgroundMask:o,composite:s,radius:c,opacity:l,shadow:u,transform:d}=e,f=r.getPosition(),p=r.rotation+(r.pathRotation?r.velocity.angle:0),m={sin:Math.sin(p),cos:Math.cos(p)},h=!!p,g={a:m.cos*(d.a??Me.a),b:h?m.sin*(d.b??1):d.b??Me.b,c:h?-m.sin*(d.c??1):d.c??Me.c,d:m.cos*(d.d??Me.d)};n.setTransform(g.a,g.b,g.c,g.d,f.x,f.y),o&&(n.globalCompositeOperation=s);let _=r.shadowColor;u.enable&&_&&(n.shadowBlur=u.blur,n.shadowColor=Kt(_),n.shadowOffsetX=u.offset.x,n.shadowOffsetY=u.offset.y),a.fill&&(n.fillStyle=a.fill);let v=r.strokeWidth??0;n.lineWidth=v,a.stroke&&(n.strokeStyle=a.stroke);let y={container:t,context:n,particle:r,radius:c,opacity:l,delta:i,transformData:g,strokeWidth:v};an(y),on(y),rn(y),n.globalCompositeOperation=`source-over`,n.resetTransform()}
1function rn(e){let{container:t,context:n,particle:r,radius:i,opacity:a,delta:o,transformData:s}=e;if(!r.effect)return;let c=t.effectDrawers.get(r.effect);c&&c.draw({context:n,particle:r,radius:i,opacity:a,delta:o,pixelRatio:t.retina.pixelRatio,transformData:{...s}})}function an(e){let{container:t,context:n,particle:r,radius:i,opacity:a,delta:o,strokeWidth:s,transformData:c}=e;if(!r.shape)return;let l=t.shapeDrawers.get(r.shape);l&&(n.beginPath(),l.draw({context:n,particle:r,radius:i,opacity:a,delta:o,pixelRatio:t.retina.pixelRatio,transformData:{...c}}),r.shapeClose&&n.closePath(),s>0&&n.stroke(),r.shapeFill&&n.fill())}function on(e){let{container:t,context:n,particle:r,radius:i,opacity:a,delta:o,transformData:s}=e;if(!r.shape)return;let c=t.shapeDrawers.get(r.shape);c?.afterDraw&&c.afterDraw({context:n,particle:r,radius:i,opacity:a,delta:o,pixelRatio:t.retina.pixelRatio,transformData:{...s}})}function sn(e,t,n){t.draw&&t.draw(e,n)}function cn(e,t,n,r){t.drawParticle&&t.drawParticle(e,n,r)}function ln(e,t,n){return{h:e.h,s:e.s,l:e.l+(t===It.darken?-1:1)*n}}function un(e,t,n){let r=t[n];r!==void 0&&(e[n]=(e[n]??1)*r)}function dn(e,t,n=!1){if(!t)return;let r=e;if(!r)return;let i=r.style;if(!i)return;let a=new Set;for(let e in i)Object.prototype.hasOwnProperty.call(i,e)&&a.add(i[e]);for(let e in t)Object.prototype.hasOwnProperty.call(t,e)&&a.add(t[e]);for(let e of a){let r=t.getPropertyValue(e);r?i.setProperty(e,r,n?`important`:``):i.removeProperty(e)}}var fn=class{constructor(e,t){this.container=e,this._applyPostDrawUpdaters=e=>{for(let t of this._postDrawUpdaters)t.afterDraw?.(e)},this._applyPreDrawUpdaters=(e,t,n,r,i,a)=>{for(let o of this._preDrawUpdaters){if(o.getColorStyles){let{fill:a,stroke:s}=o.getColorStyles(t,e,n,r);a&&(i.fill=a),s&&(i.stroke=s)}if(o.getTransformValues){let e=o.getTransformValues(t);for(let t in e)un(a,e,t)}o.beforeDraw?.(t)}},this._applyResizePlugins=()=>{for(let e of this._resizePlugins)e.resize?.()},this._getPluginParticleColors=e=>{let t,n;for(let r of this._colorPlugins)if(!t&&r.particleFillColor&&(t=Bt(this._engine,r.particleFillColor(e))),!n&&r.particleStrokeColor&&(n=Bt(this._engine,r.particleStrokeColor(e))),t&&n)break;return[t,n]},this._initCover=async()=>{let e=this.container.actualOptions.backgroundMask.cover,t=e.color;if(t){let n=Rt(this._engine,t);if(n){let t={...n,a:e.opacity};this._coverColorStyle=Kt(t,t.a)}}else await new Promise((t,n)=>{if(!e.image)return;let r=document.createElement(`img`);r.addEventListener(`load`,()=>{this._coverImage={image:r,opacity:e.opacity},t()}),r.addEventListener(`error`,e=>{n(e.error)}),r.src=e.image})},this._initStyle=()=>{let e=this.element,t=this.container.actualOptions;if(e){this._fullScreen?this._setFullScreenStyle():this._resetOriginalStyle();for(let n in t.style){if(!n||!t.style||!Object.prototype.hasOwnProperty.call(t.style,n))continue;let r=t.style[n];r&&e.style.setProperty(n,r,`important`)}}},this._initTrail=async()=>{let e=this.container.actualOptions.particles.move.trail,t=e.fill;if(!e.enable)return;let n=1/e.length;if(t.color){let e=Rt(this._engine,t.color);if(!e)return;this._trailFill={color:{...e},opacity:n}}else await new Promise((e,r)=>{if(!t.image)return;let i=document.createElement(`img`);i.addEventListener(`load`,()=>{this._trailFill={image:i,opacity:n},e()}),i.addEventListener(`error`,e=>{r(e.error)}),i.src=t.image})},this._paintBase=e=>{this.draw(t=>$t(t,this.size,e))},this._paintImage=(e,t)=>{this.draw(n=>en(n,this.size,e,t))},this._repairStyle=()=>{let e=this.element;if(!e)return;this._safeMutationObserver(e=>
1e.disconnect()),this._initStyle(),this.initBackground();let t=this._pointerEvents;e.style.pointerEvents=t,e.setAttribute(`pointer-events`,t),this._safeMutationObserver(t=>{e&&e instanceof Node&&t.observe(e,{attributes:!0})})},this._resetOriginalStyle=()=>{let e=this.element,t=this._originalStyle;e&&t&&dn(e,t,!0)},this._safeMutationObserver=e=>{this._mutationObserver&&e(this._mutationObserver)},this._setFullScreenStyle=()=>{let e=this.element;e&&dn(e,Ft(this.container.actualOptions.fullScreen.zIndex),!0)},this._engine=t,this._standardSize={height:0,width:0};let n=e.retina.pixelRatio,r=this._standardSize;this.size={height:r.height*n,width:r.width*n},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,t=e.particles.move.trail,n=this._trailFill;e.backgroundMask.enable?this.paint():t.enable&&t.length>0&&n?n.color?this._paintBase(Kt(n.color,n.opacity)):n.image&&this._paintImage(n.image,n.opacity):e.clear&&this.draw(e=>{tn(e,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 t=this._context;if(t)return e(t)}drawAsync(e){let t=this._context;if(t)return e(t)}drawParticle(e,t){if(e.spawning||e.destroyed)return;let n=e.getRadius();if(n<=0)return;let r=e.getFillColor(),i=e.getStrokeColor()??r,[a,o]=this._getPluginParticleColors(e);a||=r,o||=i,(a||o)&&this.draw(r=>{let i=this.container,s=i.actualOptions,c=e.options.zIndex,l=1-e.zIndexFactor,u=l**c.opacityRate,d=e.bubble.opacity??e.opacity?.value??1,f=e.strokeOpacity??d,p=d*u,m=f*u,h={},g={fill:a?qt(a,p):void 0};g.stroke=o?qt(o,m):g.fill,this._applyPreDrawUpdaters(r,e,n,p,g,h),nn({container:i,context:r,particle:e,delta:t,colorStyles:g,backgroundMask:s.backgroundMask.enable,composite:s.backgroundMask.composite,radius:n*l**c.sizeRate,opacity:p,shadow:e.options.shadow,transform:h}),this._applyPostDrawUpdaters(e)})}drawParticlePlugin(e,t,n){this.draw(r=>cn(r,e,t,n))}drawPlugin(e,t){this.draw(n=>sn(n,e,t))}
1async init(){this._safeMutationObserver(e=>e.disconnect()),this._mutationObserver=vt(e=>{for(let t of e)t.type===`attributes`&&t.attributeName===`style`&&this._repairStyle()}),this.resize(),this._initStyle(),await this._initCover();try{await this._initTrail()}catch(e){ft().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.background,t=this.element;if(!t)return;let n=t.style;if(n){if(e.color){let t=Rt(this._engine,e.color);n.backgroundColor=t?Kt(t,e.opacity):``}else n.backgroundColor=``;n.backgroundImage=e.image||``,n.backgroundPosition=e.position||``,n.backgroundRepeat=e.repeat||``,n.backgroundSize=e.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&&`generated`in e.dataset?e.dataset[be]===`true`:this._generated,this.element=e,this.element.ariaHidden=`true`,this._originalStyle=Nt(this.element.style);let t=this._standardSize;t.height=e.offsetHeight,t.width=e.offsetWidth;let n=this.container.retina.pixelRatio,r=this.size;e.height=r.height=t.height*n,e.width=r.width=t.width*n,this._context=this.element.getContext(`2d`),this._safeMutationObserver(e=>
1e.disconnect()),this.container.retina.init(),this.initBackground(),this._safeMutationObserver(e=>{this.element&&this.element instanceof Node&&e.observe(this.element,{attributes:!0})})}paint(){let e=this.container.actualOptions;this.draw(t=>{e.backgroundMask.enable&&e.backgroundMask.cover?(tn(t,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,t=e.canvas._standardSize,n={width:this.element.offsetWidth,height:this.element.offsetHeight},r=e.retina.pixelRatio,i={width:n.width*r,height:n.height*r};if(n.height===t.height&&n.width===t.width&&i.height===this.element.height&&i.width===this.element.width)return!1;let a={...t};t.height=n.height,t.width=n.width;let o=this.size;return this.element.width=o.width=i.width,this.element.height=o.height=i.height,this.container.started&&e.particles.setResizeFactor({width:t.width/a.width,height:t.height/a.height}),!0}setPointerEvents(e){this.element&&(this._pointerEvents=e,this._repairStyle())}stop(){this._safeMutationObserver(e=>e.disconnect()),this._mutationObserver=void 0,this.draw(e=>tn(e,this.size))}async windowResize(){if(!this.element||!this.resize())return;let e=this.container,t=e.updateActualOptions();e.particles.setDensity(),this._applyResizePlugins(),t&&await e.refresh()}},pn;(function(e){e.canvas=`canvas`,e.parent=`parent`,e.window=`window`})(pn||={});function G(e,t,n,r,i){if(r){let r={passive:!0};Ve(i)?r.capture=i:i!==void 0&&(r=i),e.addEventListener(t,n,r)}else{let r=i;e.removeEventListener(t,n,r)}}var mn=class{constructor(e){this.container=e,this._doMouseTouchClick=e=>{let t=this.container,n=t.actualOptions;if(this._canPush){let e=t.interactivity.mouse,r=e.position;if(!r)return;e.clickPosition={...r},e.clickTime=new Date().getTime();let i=n.interactivity.events.onClick;Et(i.mode,e=>this.container.handleClickMode(e))}e.type===`touchend`&&setTimeout(()=>this._mouseTouchFinish(),500)},this._handleThemeChange=e=>{let t=e,n=this.container,r=n.options,i=r.defaultThemes,a=t.matches?i.dark:i.light;r.themes.find(e=>e.name===a)?.default.auto&&n.loadTheme(a)},this._handleVisibilityChange=()=>{let e=this.container,t=e.actualOptions;this._mouseTouchFinish(),t.pauseOnBlur&&(document?.hidden?(e.pageHidden=!0,e.pause()):(e.pageHidden=!1,e.animationStatus?e.play(!0):e.draw(!0)))},this._handleWindowResize=()=>{this._resizeTimeout&&(clearTimeout(this._resizeTimeout),delete this._resizeTimeout);let e=async()=>{await this.container.canvas?.windowResize()};this._resizeTimeout=setTimeout(()=>void e(),this.container.actualOptions.interactivity.events.resize.delay*A)},this._manageInteractivityListeners=(e,t)=>{let n=this._handlers,r=this.container,i=r.actualOptions,a=r.interactivity.element;if(!a)return;let o=a,s=r.canvas;s.setPointerEvents(o===s.element?`initial`:`none`),(i.interactivity.events.onHover.enable||i.interactivity.events.onClick.enable)&&(G(a,Te,n.mouseMove,t),G(a,Ee,n.touchStart,t),G(a,Oe,n.touchMove,t),i.interactivity.events.onClick.enable?(G(a,De,n.touchEndClick,t),G(a,Se,n.mouseUp,t),G(a,xe,n.mouseDown,t)):G(a,De,n.touchEnd,t),G(a,e,n.mouseLeave,t),G(a,ke,n.touchCancel,t))},this._manageListeners=e=>{let t=this._handlers,n=this.container,r=n.actualOptions.interactivity.detectsOn,i=n.canvas.element,a=Ce;r===pn.window?(n.interactivity.element=window,a=we):r===pn.parent&&i?n.interactivity.element=i.parentElement??i.parentNode:n.interactivity.element=i,this._manageMediaMatch(e),this._manageResize(e),this._manageInteractivityListeners(a,e),document&&G(document,je,t.visibilityChange,e,!1)},this._manageMediaMatch=e=>{let t=this._handlers,n=gt(`(prefers-color-scheme: dark)`);if(n){if(n.addEventListener!==void 0){G(n,`change`,t.themeChange,e);return}n.addListener!==void 0&&(e?n.addListener(t.oldThemeChange):n.removeListener(t.oldThemeChange))}},this._manageResize=e=>{let t=this._handlers,n=this.container;if(!n.actualOptions.interactivity.events.resize)return;if(typeof ResizeObserver>`u`){G(window,Ae,t.resize,e);return}let r=n.canvas.element;this._resizeObserver&&!e?(r&&this._resizeObserver.unobserve(r),this._resizeObserver.disconnect(),delete this._resizeObserver):!this._resizeObserver&&e&&r&&(this._resizeObserver=new ResizeObserver(e=>{e.find(e=>e.target===r)&&this._handleWindowResize()}),this._resizeObserver.observe(r))},this._mouseDown=()=>{let{interactivity:e}=this.container;if(!e)return;let{mouse:t}=e;t.clicking=!0,t.downPosition=t.position},this._mouseTouchClick=e=>{let t=this.container,n=t.actualOptions,{mouse:r}=t.interactivity;r.inside=!0;let i=!1,a=r.position;if(a&&n.interactivity.events.onClick.enable){for(let e of t.plugins.values())if(e.clickPositionValid&&
1(i=e.clickPositionValid(a),i))break;i||this._doMouseTouchClick(e),r.clicking=!1}},this._mouseTouchFinish=()=>{let e=this.container.interactivity;if(!e)return;let t=e.mouse;delete t.position,delete t.clickPosition,delete t.downPosition,e.status=Ce,t.inside=!1,t.clicking=!1},this._mouseTouchMove=e=>{let t=this.container,n=t.actualOptions,r=t.interactivity,i=t.canvas.element;if(!r?.element)return;r.mouse.inside=!0;let a;if(e.type.startsWith(`pointer`)){this._canPush=!0;let t=e;if(r.element===window){if(i){let e=i.getBoundingClientRect();a={x:t.clientX-e.left,y:t.clientY-e.top}}}else if(n.interactivity.detectsOn===pn.parent){let e=t.target,n=t.currentTarget;if(e&&n&&i){let r=e.getBoundingClientRect(),o=n.getBoundingClientRect(),s=i.getBoundingClientRect();a={x:t.offsetX+2*r.left-(o.left+s.left),y:t.offsetY+2*r.top-(o.top+s.top)}}else a={x:t.offsetX??t.clientX,y:t.offsetY??t.clientY}}else t.target===i&&(a={x:t.offsetX??t.clientX,y:t.offsetY??t.clientY})}else if(this._canPush=e.type!==`touchmove`,i){let t=e,n=t.touches[t.touches.length-1],r=i.getBoundingClientRect();a={x:n.clientX-(r.left??0),y:n.clientY-(r.top??0)}}let o=t.retina.pixelRatio;a&&(a.x*=o,a.y*=o),r.mouse.position=a,r.status=Te},this._touchEnd=e=>{let t=e,n=Array.from(t.changedTouches);for(let e of n)this._touches.delete(e.identifier);this._mouseTouchFinish()},this._touchEndClick=e=>{let t=e,n=Array.from(t.changedTouches);for(let e of n)this._touches.delete(e.identifier);this._mouseTouchClick(e)},this._touchStart=e=>{let t=e,n=Array.from(t.changedTouches);for(let e of n)this._touches.set(e.identifier,performance.now());this._mouseTouchMove(e)},this._canPush=!0,this._touches=new Map,this._handlers={mouseDown:()=>this._mouseDown(),mouseLeave:()=>this._mouseTouchFinish(),mouseMove:e=>this._mouseTouchMove(e),mouseUp:e=>this._mouseTouchClick(e),touchStart:e=>this._touchStart(e),touchMove:e=>this._mouseTouchMove(e),touchEnd:e=>this._touchEnd(e),touchCancel:e=>this._touchEnd(e),touchEndClick:e=>this._touchEndClick(e),visibilityChange:()=>this._handleVisibilityChange(),themeChange:e=>this._handleThemeChange(e),oldThemeChange:e=>this._handleThemeChange(e),resize:()=>{this._handleWindowResize()}}}addListeners(){this._manageListeners(!0)}removeListeners(){this._manageListeners(!1)}},K;(function(e){e.configAdded=`configAdded`,e.containerInit=`containerInit`,e.particlesSetup=`particlesSetup`,e.containerStarted=`containerStarted`,e.containerStopped=`containerStopped`,e.containerDestroyed=`containerDestroyed`,e.containerPaused=`containerPaused`,e.containerPlay=`containerPlay`,e.containerBuilt=`containerBuilt`,e.particleAdded=`particleAdded`,e.particleDestroyed=`particleDestroyed`,e.particleRemoved=`particleRemoved`})(K||={});var hn=class e{constructor(){this.value=``}static create(t,n){let r=new e;return r.load(t),n!==void 0&&(N(n)||F(n)?r.load({value:n}):r.load(n)),r}load(e){I(e)||I(e.value)||(this.value=e.value)}},gn=class{constructor(){this.color=new hn,this.color.value=``,this.image=``,this.position=``,this.repeat=``,this.size=``,this.opacity=1}load(e){I(e)||(e.color!==void 0&&(this.color=hn.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))}},_n=class{constructor(){this.opacity=1}load(e){I(e)||(e.color!==void 0&&(this.color=hn.create(this.color,e.color)),e.image!==void 0&&(this.image=e.image),e.opacity!==void 0&&(this.opacity=e.opacity))}},vn=class{constructor(){this.composite=`destination-out`,this.cover=new _n,this.enable=!1}load(e){if(!I(e)){if(e.composite!==void 0&&(this.composite=e.composite),e.cover!==void 0){let t=e.cover,n=N(e.cover)?{color:e.cover}:e.cover;this.cover.load(t.color!==void 0||t.image!==void 0?t:{color:n})}e.enable!==void 0&&(this.enable=e.enable)}}},yn=class{constructor(){this.enable=!0,this.zIndex=0}load(e){I(e)||(e.enable!==void 0&&(this.enable=e.enable),e.zIndex!==void 0&&(this.zIndex=e.zIndex))}},bn=class{constructor(){this.enable=!1,this.mode=[]}load(e){I(e)||(e.enable!==void 0&&(this.enable=e.enable),e.mode!==void 0&&(this.mode=e.mode))}},xn;(function(e){e.circle=`circle`,e.rectangle=`rectangle`})(xn||={});var Sn=class{constructor(){this.selectors=[],this.enable=!1,this.mode=[],this.type=xn.circle}load(e){I(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.t
1ype=e.type))}},Cn=class{constructor(){this.enable=!1,this.force=2,this.smooth=10}load(e){I(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))}},wn=class{constructor(){this.enable=!1,this.mode=[],this.parallax=new Cn}load(e){I(e)||(e.enable!==void 0&&(this.enable=e.enable),e.mode!==void 0&&(this.mode=e.mode),this.parallax.load(e.parallax))}},Tn=class{constructor(){this.delay=.5,this.enable=!0}load(e){I(e)||(e.delay!==void 0&&(this.delay=e.delay),e.enable!==void 0&&(this.enable=e.enable))}},En=class{constructor(){this.onClick=new bn,this.onDiv=new Sn,this.onHover=new wn,this.resize=new Tn}load(e){if(I(e))return;this.onClick.load(e.onClick);let t=e.onDiv;t!==void 0&&(this.onDiv=Et(t,e=>{let t=new Sn;return t.load(e),t})),this.onHover.load(e.onHover),this.resize.load(e.resize)}},Dn=class{constructor(e,t){this._engine=e,this._container=t}load(e){if(I(e)||!this._container)return;let t=this._engine.interactors.get(this._container);if(t)for(let n of t)n.loadModeOptions&&n.loadModeOptions(this,e)}},On=class{constructor(e,t){this.detectsOn=pn.window,this.events=new En,this.modes=new Dn(e,t)}load(e){if(I(e))return;let t=e.detectsOn;t!==void 0&&(this.detectsOn=t),this.events.load(e.events),this.modes.load(e.modes)}},kn=class{load(e){I(e)||(e.position&&(this.position={x:e.position.x??50,y:e.position.y??50,mode:e.position.mode??lt.percent}),e.options&&(this.options=U({},e.options)))}},An;(function(e){e.screen=`screen`,e.canvas=`canvas`})(An||={});var jn=class{constructor(){this.maxWidth=1/0,this.options={},this.mode=An.canvas}load(e){I(e)||(I(e.maxWidth)||(this.maxWidth=e.maxWidth),I(e.mode)||(this.mode=e.mode===An.screen?An.screen:An.canvas),I(e.options)||(this.options=U({},e.options)))}},Mn;(function(e){e.any=`any`,e.dark=`dark`,e.light=`light`})(Mn||={});var Nn=class{constructor(){this.auto=!1,this.mode=Mn.any,this.value=!1}load(e){I(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))}},Pn=class{constructor(){this.name=``,this.default=new Nn}load(e){I(e)||(e.name!==void 0&&(this.name=e.name),this.default.load(e.default),e.options!==void 0&&(this.options=U({},e.options)))}},Fn=class{constructor(){this.count=0,this.enable=!1,this.speed=1,this.decay=0,this.delay=0,this.sync=!1}load(e){I(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))}},In=class extends Fn{constructor(){super(),this.mode=st.auto,this.startValue=ut.random}load(e){super.load(e),!I(e)&&(e.mode!==void 0&&(this.mode=e.mode),e.startValue!==void 0&&(this.startValue=e.startValue))}},Ln=class extends Fn{constructor(){super(),this.offset=0,this.sync=!0}load(e){super.load(e),!I(e)&&e.offset!==void 0&&(this.offset=B(e.offset))}},Rn=class{constructor(){this.h=new Ln,this.s=new Ln,this.l=new Ln}load(e){I(e)||(this.h.load(e.h),this.s.load(e.s),this.l.load(e.l))}},zn=class e extends hn{constructor(){super(),this.animation=new Rn}static create(t,n){let r=new e;return r.load(t),n!==void 0&&(N(n)||F(n)?r.load({value:n}):r.load(n)),r}load(e){if(super.load(e),I(e))return;let t=e.animation;t!==void 0&&(t.enable===void 0?this.animation.load(e.animation):this.animation.h.load(t))}},Bn;(function(e){e.absorb=`absorb`,e.bounce=`bounce`,e.destroy=`destroy`})(Bn||={});var Vn=class{constructor(){this.speed=2}load(e){I(e)||e.speed!==void 0&&(this.speed=e.speed)}},Hn=class{constructor(){this.enable=!0,this.retries=0}load(e){I(e)||(e.enable!==void 0&&(this.enable=e.enable),e.retries!==void 0&&(this.retries=e.retries))}},Un=class{constructor(){this.value=0}load(e){I(e)||I(e.value)||(this.value=B(e.value))}},Wn=class extends Un{constructor(){super(),this.animation=new Fn}load(e){if(super.load(e),I(e))return;let t=e.animation;t!==void 0&&this.animation.load(t)}},Gn=class extends Wn{constructor(){super(),this.animation=new In}load(e){super.load(e)}},Kn=class extends Un{constructor(){super(),this.value=1}},qn=class{constructor(){this.horizontal=new Kn,this.vertical=new Kn}load(e){I(e)||(this.horizontal.load(e.horizontal),this.vertical.load(e.vertical))}},Jn=class{constructor(){this.absorb=new Vn,this.bounce=new qn,this.enable=!1,this.maxSpeed=50,this.mode=Bn.bounce,this.overlap=new Hn}load(e){I(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))}},Yn=class{constructor(){this.close=!0,this.fill=!0,this.options={},this.type=[]}load(e){if(I(e))return;let t=e.options;if(t!==void 0)for(let e in t){let n=t[e];n&&(this.options[e]=U(this.options[e]??{},n))}e.close!==void 0&&(this.close=e.close),e.fill!==void 0&&(this.fill=e.fill),e.type!==void 0&&(this.t
1ype=e.type)}},Xn=class{constructor(){this.offset=0,this.value=90}load(e){I(e)||(e.offset!==void 0&&(this.offset=B(e.offset)),e.value!==void 0&&(this.value=B(e.value)))}},Zn=class{constructor(){this.distance=200,this.enable=!1,this.rotate={x:3e3,y:3e3}}load(e){if(!I(e)&&(e.distance!==void 0&&(this.distance=B(e.distance)),e.enable!==void 0&&(this.enable=e.enable),e.rotate)){let t=e.rotate.x;t!==void 0&&(this.rotate.x=t);let n=e.rotate.y;n!==void 0&&(this.rotate.y=n)}}},Qn=class{constructor(){this.x=50,this.y=50,this.mode=lt.percent,this.radius=0}load(e){I(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))}},$n=class{constructor(){this.acceleration=9.81,this.enable=!1,this.inverse=!1,this.maxSpeed=50}load(e){I(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)))}},er=class{constructor(){this.clamp=!0,this.delay=new Un,this.enable=!1,this.options={}}load(e){I(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=U(this.options,e.options)))}},tr=class{load(e){I(e)||(e.color!==void 0&&(this.color=hn.create(this.color,e.color)),e.image!==void 0&&(this.image=e.image))}},nr=class{constructor(){this.enable=!1,this.length=10,this.fill=new tr}load(e){I(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))}},q;(function(e){e.bounce=`bounce`,e.none=`none`,e.out=`out`,e.destroy=`destroy`,e.split=`split`})(q||={});var rr=class{constructor(){this.default=q.out}load(e){I(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)}},ir=class{constructor(){this.acceleration=0,this.enable=!1}load(e){I(e)||(e.acceleration!==void 0&&(this.acceleration=B(e.acceleration)),e.enable!==void 0&&(this.enable=e.enable),e.position&&(this.position=U({},e.position)))}},ar=class{constructor(){this.angle=new Xn,this.attract=new Zn,this.center=new Qn,this.decay=0,this.distance={},this.direction=M.none,this.drift=0,this.enable=!1,this.gravity=new $n,this.path=new er,this.outModes=new rr,this.random=!1,this.size=!1,this.speed=2,this.spin=new ir,this.straight=!1,this.trail=new nr,this.vibrate=!1,this.warp=!1}load(e){if(I(e))return;this.angle.load(P(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=P(e.distance)?{horizontal:e.distance,vertical:e.distance}:{...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 t=e.outModes;t!==void 0&&(He(t)?this.outModes.load(t):this.outModes.load({default:t})),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)}},or=class extends In{constructor(){super(),this.destroy=ct.none,this.speed=2}load(e){super.load(e),!I(e)&&e.destroy!==void 0&&(this.destroy=e.destroy)}},sr=class extends Gn{constructor(){super(),this.animation=new or,this.value=1}load(e){if(I(e))return;super.load(e);let t=e.animation;t!==void 0&&this.animation.load(t)}},cr=class{constructor(){this.enable=!1,this.width=1920,this.height=1080}load(e){if(I(e))return;e.enable!==void 0&&(this.enable=e.enable);let t=e.width;t!==void 0&&(this.width=t);let n=e.height;n!==void 0&&(this.height=n)}},lr;(function(e){e.delete=`delete`,e.wait=`wait`})(lr||={});var ur=class{constructor(){this.mode=lr.delete,this.value=0}load(e){I(e)||(e.mode!==void 0&&(this.mode=e.mode),e.value!==void 0&&(this.value=e.value))}},dr=class{constructor(){this.density=new cr,this.limit=new ur,this.value=0}load(e){I(e)||(this.density.load(e.density),this.limit.load(e.limit),e.value!==void 0&&(this.value=e.value))}},fr=class{constructor(){this.blur=0,this.color=new hn,this.enable=!1,this.offset={x:0,y:0},this.color.value=`#000`}load(e){I(e)||(e.blur!==void 0&&(this.blur=e.blur),this.color=hn.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)))}},pr=class{constructor(){this.close=!0,this.fill=!0,this.options={},this.type=`circle`}load(e){if(I(e))return;let t=e.options;if(t!==void 0)for(let e in t){let n=t[e];n&&(this.options[e]=U(this.options[e]??{},n))}e.close!==void 0&&(this.close=e.close),e.fill!==void 0&&(this.fill=e.fill),e.type!==void 0&&(this.t
1ype=e.type)}},mr=class extends In{constructor(){super(),this.destroy=ct.none,this.speed=5}load(e){super.load(e),!I(e)&&e.destroy!==void 0&&(this.destroy=e.destroy)}},hr=class extends Gn{constructor(){super(),this.animation=new mr,this.value=3}load(e){if(super.load(e),I(e))return;let t=e.animation;t!==void 0&&this.animation.load(t)}},gr=class{constructor(){this.width=0}load(e){I(e)||(e.color!==void 0&&(this.color=zn.create(this.color,e.color)),e.width!==void 0&&(this.width=B(e.width)),e.opacity!==void 0&&(this.opacity=B(e.opacity)))}},_r=class extends Un{constructor(){super(),this.opacityRate=1,this.sizeRate=1,this.velocityRate=1}load(e){super.load(e),!I(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))}},vr=class{constructor(e,t){this._engine=e,this._container=t,this.bounce=new qn,this.collisions=new Jn,this.color=new zn,this.color.value=`#fff`,this.effect=new Yn,this.groups={},this.move=new ar,this.number=new dr,this.opacity=new sr,this.reduceDuplicates=!1,this.shadow=new fr,this.shape=new pr,this.size=new hr,this.stroke=new gr,this.zIndex=new _r}load(e){if(I(e))return;if(e.groups!==void 0)for(let t of Object.keys(e.groups)){if(!Object.hasOwn(e.groups,t))continue;let n=e.groups[t];n!==void 0&&(this.groups[t]=U(this.groups[t]??{},n))}e.reduceDuplicates!==void 0&&(this.reduceDuplicates=e.reduceDuplicates),this.bounce.load(e.bounce),this.color.load(zn.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=U({},e.interactivity));let t=e.stroke;if(t&&(this.stroke=Et(t,e=>{let t=new gr;return t.load(e),t})),this._container){let t=this._engine.updaters.get(this._container);if(t)for(let n of t)n.loadOptions&&n.loadOptions(this,e);let n=this._engine.interactors.get(this._container);if(n)for(let t of n)t.loadParticlesOptions&&t.loadParticlesOptions(this,e)}}};function yr(e,...t){for(let n of t)e.load(n)}function br(e,t,...n){let r=new vr(e,t);return yr(r,...n),r}var xr=class{constructor(e,t){this._findDefaultTheme=e=>this.themes.find(t=>t.default.value&&t.default.mode===e)??this.themes.find(e=>e.default.value&&e.default.mode===Mn.any),this._importPreset=e=>{this.load(this._engine.getPreset(e))},this._engine=e,this._container=t,this.autoPlay=!0,this.background=new gn,this.backgroundMask=new vn,this.clear=!0,this.defaultThemes={},this.delay=0,this.fullScreen=new yn,this.detectRetina=!0,this.duration=0,this.fpsLimit=120,this.interactivity=new On(e,t),this.manualParticles=[],this.particles=br(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(I(e))return;e.preset!==void 0&&Et(e.preset,e=>this._importPreset(e)),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 t=e.detectRetina;t!==void 0&&(this.detectRetina=t),e.duration!==void 0&&(this.duration=B(e.duration));let n=e.fpsLimit;n!==void 0&&(this.fpsLimit=n),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 r=e.fullScreen;Ve(r)?this.fullScreen.enable=r:this.fullScreen.load(r),this.backgroundMask.load(e.backgroundMask),this.interactivity.load(e.interactivity),e.manualParticles&&(this.manualParticles=e.manualParticles.map(e=>{let t=new kn;return t.load(e),t})),this.particles.load(e.particles),this.style=U(this.style,e.style),this._engine.loadOptions(this,e),e.smooth!==void 0&&(this.smooth=e.smooth);let i=this._engine.interactors.get(this._container);if(i)for(let t of i)t.loadOptions&&t.loadOptions(this,e);if(e.responsive!==void 0)for(let t of e.responsive){let e=new jn;e.load(t),this.responsive.push(e)}if(this.responsive.sort((e,t)=>
1e.maxWidth-t.maxWidth),e.themes!==void 0)for(let t of e.themes){let e=this.themes.find(e=>e.name===t.name);if(e)e.load(t);else{let e=new Pn;e.load(t),this.themes.push(e)}}this.defaultThemes.dark=this._findDefaultTheme(Mn.dark)?.name,this.defaultThemes.light=this._findDefaultTheme(Mn.light)?.name}setResponsive(e,t,n){this.load(n);let r=this.responsive.find(n=>n.mode===An.screen&&screen?n.maxWidth>screen.availWidth:n.maxWidth*t>e);return this.load(r?.options),r?.maxWidth}setTheme(e){if(e){let t=this.themes.find(t=>t.name===e);t&&this.load(t.options)}else{let e=gt(`(prefers-color-scheme: dark)`)?.matches,t=this._findDefaultTheme(e?Mn.dark:Mn.light);t&&this.load(t.options)}}},Sr;(function(e){e.external=`external`,e.particles=`particles`})(Sr||={});var Cr=class{constructor(e,t){this.container=t,this._engine=e,this._interactors=[],this._externalInteractors=[],this._particleInteractors=[]}externalInteract(e){for(let t of this._externalInteractors)t.isEnabled()&&t.interact(e)}handleClickMode(e){for(let t of this._externalInteractors)t.handleClickMode?.(e)}
1async init(){this._interactors=await this._engine.getInteractors(this.container,!0),this._externalInteractors=[],this._particleInteractors=[];for(let e of this._interactors){switch(e.type){case Sr.external:this._externalInteractors.push(e);break;case Sr.particles:this._particleInteractors.push(e)}e.init()}}particlesInteract(e,t){for(let n of this._externalInteractors)n.clear(e,t);for(let n of this._particleInteractors)n.isEnabled(e)&&n.interact(e,t)}reset(e){for(let t of this._externalInteractors)t.isEnabled()&&t.reset(e);for(let t of this._particleInteractors)t.isEnabled(e)&&t.reset(e)}},J;(function(e){e.normal=`normal`,e.inside=`inside`,e.outside=`outside`})(J||={});function wr(e,t,n,r){let i=t.options[e];if(i)return U({close:t.close,fill:t.fill},W(i,n,r))}function Tr(e,t,n,r){let i=t.options[e];if(i)return U({close:t.close,fill:t.fill},W(i,n,r))}function Er(e){if(!yt(e.outMode,e.checkModes))return;let t=e.radius*2;e.coord>e.maxCoord-t?e.setCb(-e.radius):e.coord<t&&e.setCb(e.radius)}var Dr=class{constructor(e,t){this.container=t,this._calcPosition=(e,t,n,r=0)=>{for(let r of e.plugins.values()){let e=r.particlePosition===void 0?void 0:r.particlePosition(t,this);if(e)return Ue.create(e.x,e.y,n)}let i=e.canvas.size,a=at({size:i,position:t}),o=Ue.create(a.x,a.y,n),s=this.getRadius(),c=this.options.move.outModes,l=t=>{Er({outMode:t,checkModes:[q.bounce],coord:o.x,maxCoord:e.canvas.size.width,setCb:e=>o.x+=e,radius:s})},u=t=>{Er({outMode:t,checkModes:[q.bounce],coord:o.y,maxCoord:e.canvas.size.height,setCb:e=>o.y+=e,radius:s})};return l(c.left??c.default),l(c.right??c.default),u(c.top??c.default),u(c.bottom??c.default),this._checkOverlap(o,r)?this._calcPosition(e,void 0,n,r+1):o},this._calculateVelocity=()=>{let e=nt(this.direction).copy(),t=this.options.move;if(t.direction===M.inside||t.direction===M.outside)return e;let n=et(z(t.angle.value)),r=et(z(t.angle.offset)),i={left:r-n*k,right:r+n*k};return t.straight||(e.angle+=R(B(i.left,i.right))),t.random&&typeof t.speed==`number`&&(e.length*=L()),e},this._checkOverlap=(e,t=0)=>{let n=this.options.collisions,r=this.getRadius();if(!n.enable)return!1;let i=n.overlap;if(i.enable)return!1;let a=i.retries;if(a>=0&&t>a)throw Error(`${O} particle is overlapping and can't be placed`);return!!this.container.particles.find(t=>$e(e,t.position)<r+t.getRadius())},this._getRollColor=e=>{if(!e||!this.roll||!this.backColor&&!this.roll.alter)return e;let t=this.roll.horizontal&&this.roll.vertical?2:1,n=this.roll.horizontal?Math.PI*k:0;return Math.floor(((this.roll.angle??0)+n)/(Math.PI/t))%2?this.backColor?this.backColor:this.roll.alter?ln(e,this.roll.alter.type,this.roll.alter.value):e:e},this._initPosition=e=>{let t=this.container,n=z(this.options.zIndex.value);this.position=this._calcPosition(t,e,Ye(n,0,t.zLayers)),this.initialPosition=this.position.copy();let r=t.canvas.size;switch(this.moveCenter={...kt(this.options.move.center,r),radius:this.options.move.center.radius??0,mode:this.options.move.center.mode??lt.percent},this.direction=tt(this.options.move.direction,this.position,this.moveCenter),this.options.move.direction){case M.inside:this.outType=J.inside;break;case M.outside:this.outType=J.outside}this.offset=We.origin},this._engine=e}destroy(e){if(this.unbreakable||this.destroyed)return;this.destroyed=!0,this.bubble.inRange=!1,this.slow.inRange=!1;let t=this.container,n=this.pathGenerator;t.shapeDrawers.get(this.shape)?.particleDestroy?.(this);for(let n of t.plugins.values())n.particleDestroyed?.(this,e);for(let n of t.particles.updaters)n.particleDestroyed?.(this,e);n?.reset(this),this._engine.dispatchEvent(K.particleDestroyed,{container:this.container,data:{particle:this}})}draw(e){let t=this.container,n=t.canvas;for(let r of t.plugins.values())n.drawParticlePlugin(r,this,e);n.drawParticle(this,e)}getFillColor(){return this._getRollColor(this.bubble.color??Jt(this.color))}getMass(){return this.getRadius()**2*Math.PI*k}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??Jt(this.strokeColor))}init(e,t,n,r){let i=this.container,a=this._engine;this.id=e,this.group=r,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=J.normal,this.ignoresResizeRatio=!0;let o=i.retina.pixelRatio,s=i.actualOptions,c=br(this._engine,i,s.particles),{reduceDuplicates:l}=c,u=c.effect.type,d=c.shape.type;this.effect=W(u,this.id,l),this.shape=W(d,this.id,l);let f=c.effect,p=c.shape;if(n){if(n.effect?.type){let e=n.effect.type,t=W(e,this.id,l);t&&(this.effect=t,f.load(n.effect))}if(n.shape?.type){let e=n.shape.type,t=W(e,this.id,l);t&&(this.shape=t,p.load(n.shape))}}if(this.effect===`random`){let e=[...this.container.effectDrawers.keys()];this.effect=e[Math.floor(L()*e.length)]}if(this.shape===`random`){let e=[...this.container.shapeDrawers.keys()];this.shape=e[Math.floor(L()*e.length)]}this.effectData=wr(this.effect,f,this.id,l),this.shapeData=Tr(this.shape,p,this.id,l),c.load(n);let m=this.effectData;m&&c.load(m.particles);let h=this.shapeData;h&&c.load(h.particles);let g=new On(a,i);g.load(i.actualOptions.interactivity),g.load(c.interactivity),this.interactivity=g,this.effectFill=m?.fill??c.effect.fill,this.effectClose=m?.close??c.effect.close,this.shapeFill=h?.fill??c.shape.fill,this.shapeClose=h?.close??c.shape.close,this.options=c;let _=this.options.move.path;this.pathDelay=z(_.delay.value)*A,_.generator&&(this.pathGenerator=this._engine.getPathGenerator(_.generator),this.pathGenerator&&i.addPath(_.generator,this.pathGenerator)&&this.pathGenerator.init(i)),i.retina.initParticle(this),this.size=Dt(this.options.size,o),this.bubble={inRange:!1},this.slow={inRange:!1,factor:1},this._initPosition(t),this.initialVelocity=this._calculateVelocity(),this.velocity=this.initialVelocity.copy(),this.moveDecay=1-z(this.options.move.decay);let v=i.particles;v.setLastZIndex(this.position.z),this.zIndexFactor=this.position.z/i.zL
1ayers,this.sides=24;let y=i.effectDrawers.get(this.effect);y||(y=this._engine.getEffectDrawer(this.effect),y&&i.effectDrawers.set(this.effect,y)),y?.loadEffect&&y.loadEffect(this);let b=i.shapeDrawers.get(this.shape);b||(b=this._engine.getShapeDrawer(this.shape),b&&i.shapeDrawers.set(this.shape,b)),b?.loadShape&&b.loadShape(this);let x=b?.getSidesCount;x&&(this.sides=x(this)),this.spawning=!1,this.shadowColor=Rt(this._engine,this.options.shadow.color);for(let e of v.updaters)e.init(this);for(let e of v.movers)e.init?.(this);y?.particleInit?.(i,this),b?.particleInit?.(i,this);for(let e of i.plugins.values())e.particleCreated?.(this)}isInsideCanvas(){let e=this.getRadius(),t=this.container.canvas.size,n=this.position;return n.x>=-e&&n.y>=-e&&n.y<=t.height+e&&n.x<=t.width+e}isVisible(){return!this.destroyed&&!this.spawning&&this.isInsideCanvas()}reset(){for(let e of this.container.particles.updaters)e.reset?.(this)}},Or=class{constructor(e,t){this.position=e,this.particle=t}},kr;(function(e){e.circle=`circle`,e.rectangle=`rectangle`})(kr||={});var Ar=class{constructor(e,t,n){this.position={x:e,y:t},this.type=n}},jr=class e extends Ar{constructor(e,t,n){super(e,t,kr.circle),this.radius=n}contains(e){return $e(e,this.position)<=this.radius}intersects(t){let n=this.position,r=t.position,i={x:Math.abs(r.x-n.x),y:Math.abs(r.y-n.y)},a=this.radius;if(t instanceof e||t.type===kr.circle)return a+t.radius>Math.sqrt(i.x**2+i.y**2);if(t instanceof Mr||t.type===kr.rectangle){let{width:e,height:n}=t.size;return(i.x-e)**2+(i.y-n)**2<=a**2||i.x<=a+e&&i.y<=a+n||i.x<=e||i.y<=n}return!1}},Mr=class e extends Ar{constructor(e,t,n,r){super(e,t,kr.rectangle),this.size={height:r,width:n}}contains(e){let t=this.size.width,n=this.size.height,r=this.position;return e.x>=r.x&&e.x<=r.x+t&&e.y>=r.y&&e.y<=r.y+n}intersects(t){if(t instanceof jr)return t.intersects(this);let n=this.size.width,r=this.size.height,i=this.position,a=t.position,o=t instanceof e?t.size:{width:0,height:0},s=o.width,c=o.height;return a.x<i.x+n&&a.x+s>i.x&&a.y<i.y+r&&a.y+c>i.y}},Nr=class e{constructor(t,n){this.rectangle=t,this.capacity=n,this._subdivide=()=>{let{x:t,y:n}=this.rectangle.position,{width:r,height:i}=this.rectangle.size,{capacity:a}=this;for(let o=0;o<4;o++){let s=o%2;this._subs.push(new e(new Mr(t+r*k*s,n+i*k*(Math.round(o*k)-s),r*k,i*k),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(t=>t.insert(e))):!1}query(e,t){let n=[];if(!e.intersects(this.rectangle))return[];for(let r of this._points)!e.contains(r.position)&&$e(e.position,r.position)>r.particle.getRadius()&&(!t||t(r.particle))||n.push(r.particle);if(this._divided)for(let r of this._subs)n.push(...r.query(e,t));return n}queryCircle(e,t,n){return this.query(new jr(e.x,e.y,t),n)}queryRectangle(e,t,n){return this.query(new Mr(e.x,e.y,t.width,t.height),n)}},Pr=e=>{let{height:t,width:n}=e;return new Mr(ze*n,ze*t,Be*n,Be*t)},Fr=class{constructor(e,t){this._addToPool=(...e)=>{this._pool.push(...e)},this._applyDensity=(e,t,n,r)=>{let i=e.number;if(!e.number.density?.enable){n===void 0?this._limit=i.limit.value:(r?.number.limit?.value??i.limit.value)&&this._groupLimits.set(n,r?.number.limit?.value??i.limit.value);return}let a=this._initDensityFactor(i.density),o=i.value,s=i.limit.value>0?i.limit.value:o,c=Math.min(o,s)*a+t,l=Math.min(this.count,this.filter(e=>e.group===n).length);n===void 0?this._limit=i.limit.value*a:this._groupLimits.set(n,i.limit.value*a),l<c?this.push(Math.abs(c-l),void 0,e,n):l>c&&this.removeQuantity(l-c,n)},this._initDensityFactor=e=>{let t=this._container;if(!t.canvas.element||!e.enable)return 1;let n=t.canvas.element,r=t.retina.pixelRatio;return n.width*n.height/(e.height*e.width*r**2)},this._pushParticle=(e,t,n,r)=>{try{let i=this._pool.pop();i||=new Dr(this._engine,this._container),i.init(this._nextId,e,t,n);let a=!0;return r&&(a=r(i)),a?(this._array.push(i),this._zArray.push(i),this._nextId++,this._engine.dispatchEvent(K.particleAdded,{container:this._container,data:{particle:i}}),i):void 0}catch(e){ft().warning(`${O} adding particle: ${e}`)}}
1,this._removeParticle=(e,t,n)=>{let r=this._array[e];if(!r||r.group!==t)return!1;let i=this._zArray.indexOf(r);return this._array.splice(e,1),this._zArray.splice(i,1),r.destroy(n),this._engine.dispatchEvent(K.particleRemoved,{container:this._container,data:{particle:r}}),this._addToPool(r),!0},this._engine=e,this._container=t,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 Cr(e,t),this._pluginsInitialized=!1;let n=t.canvas.size;this.quadTree=new Nr(Pr(n),4),this.movers=[],this.updaters=[]}get count(){return this._array.length}addManualParticles(){let e=this._container;e.actualOptions.manualParticles.forEach(t=>this.addParticle(t.position?kt(t.position,e.canvas.size):void 0,t.options))}addParticle(e,t,n,r){let i=this._container.actualOptions.particles.number.limit.mode,a=n===void 0?this._limit:this._groupLimits.get(n)??this._limit,o=this.count;if(a>0)switch(i){case lr.delete:{let e=o+1-a;e>0&&this.removeQuantity(e);break}case lr.wait:if(o>=a)return}return this._pushParticle(e,t,n,r)}clear(){this._array=[],this._zArray=[],this._pluginsInitialized=!1}destroy(){this._array=[],this._zArray=[],this.movers=[],this.updaters=[]}draw(e){let t=this._container,n=t.canvas;n.clear(),this.update(e);for(let r of t.plugins.values())n.drawPlugin(r,e);for(let t of this._zArray)t.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)}
1async init(){let e=this._container,t=e.actualOptions;this._lastZIndex=0,this._needsSort=!1,await this.initPlugins();let n=!1;for(let t of e.plugins.values())if(n=t.particlesInitialization?.()??n,n)break;if(this.addManualParticles(),!n){let e=t.particles,n=e.groups;for(let t in n){let r=n[t];for(let n=this.count,i=0;i<r.number?.value&&n<e.number.value;n++,i++)this.addParticle(void 0,r,t)}for(let t=this.count;t<e.number.value;t++)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 t of e.pathGenerators.values())t.init(e)}push(e,t,n,r){for(let i=0;i<e;i++)this.addParticle(t?.position,n,r)}async redraw(){this.clear(),await this.init(),this.draw({value:0,factor:0})}remove(e,t,n){this.removeAt(this._array.indexOf(e),void 0,t,n)}removeAt(e,t=1,n,r){if(e<0||e>this.count)return;let i=0;for(let a=e;i<t&&a<this.count;a++)this._removeParticle(a,n,r)&&(a--,i++)}removeQuantity(e,t){this.removeAt(0,e,t)}setDensity(){let e=this._container.actualOptions,t=e.particles.groups,n=e.manualParticles.length;for(let e in t)this._applyDensity(t[e],n,e);this._applyDensity(e.particles,n)}setLastZIndex(e){this._lastZIndex=e,this._needsSort=this._needsSort||this._lastZIndex<e}setResizeFactor(e){this._resizeFactor=e}update(e){let t=this._container,n=new Set;this.quadTree=new Nr(Pr(t.canvas.size),4);for(let e of t.pathGenerators.values())e.update();for(let n of t.plugins.values())n.update?.(e);let r=this._resizeFactor;for(let t of this._array){r&&!t.ignoresResizeRatio&&(t.position.x*=r.width,t.position.y*=r.height,t.initialPosition.x*=r.width,t.initialPosition.y*=r.height),t.ignoresResizeRatio=!1,this._interactionManager.reset(t);for(let n of this._container.plugins.values()){if(t.destroyed)break;n.particleUpdate?.(t,e)}for(let n of this.movers)n.isEnabled(t)&&n.move(t,e);if(t.destroyed){n.add(t);continue}this.quadTree.insert(new Or(t.getPosition(),t))}if(n.size){let e=e=>!n.has(e);this._array=this.filter(e),this._zArray=this._zArray.filter(e);for(let e of n)this._engine.dispatchEvent(K.particleRemoved,{container:this._container,data:{particle:e}});this._addToPool(...n)}this._interactionManager.externalInteract(e);for(let t of this._array){for(let n of this.updaters)n.update(t,e);!t.destroyed&&!t.spawning&&this._interactionManager.particlesInteract(t,e)}if(delete this._resizeFactor,this._needsSort){let e=this._zArray;e.sort((e,t)=>t.position.z-e.position.z||e.id-t.id),this._lastZIndex=e[e.length-1].position.z,this._needsSort=!1}}},Ir=class{constructor(e){this.container=e,this.pixelRatio=1,this.reduceFactor=1}init(){let e=this.container,t=e.actualOptions;this.pixelRatio=!t.detectRetina||mt()?1:devicePixelRatio,this.reduceFactor=1;let n=this.pixelRatio,r=e.canvas;if(r.element){let e=r.element;r.size.width=e.offsetWidth*n,r.size.height=e.offsetHeight*n}let i=t.particles,a=i.move;this.maxSpeed=z(a.gravity.maxSpeed)*n,this.sizeAnimationSpeed=z(i.size.animation.speed)*n}initParticle(e){let t=e.options,n=this.pixelRatio,r=t.move,i=r.distance,a=e.retina;a.moveDrift=z(r.drift)*n,a.moveSpeed=z(r.speed)*n,a.sizeAnimationSpeed=z(t.size.animation.speed)*n;let o=a.maxDistance;o.horizontal=i.horizontal===void 0?void 0:i.horizontal*n,o.vertical=i.vertical===void 0?void 0:i.vertical*n,a.maxSpeed=z(r.gravity.maxSpeed)*n}};function Y(e){return e&&!e.destroyed}function Lr(e,t=60,n=!1){return{value:e,factor:n?60/t:60*e/A}}function Rr(e,t,...n){let r=new xr(e,t);return yr(r,...n),r}var zr=class{constructor(e,t,n){this._intersectionManager=e=>{if(Y(this)&&this.actualOptions.pauseOnOutsideViewport)for(let t of e)t.target===this.interactivity.element&&(t.isIntersecting?this.play():this.pause())},this._nextFrame=e=>{try{if(!this._smooth&&this._lastFrameTime!==void 0&&e<this._lastFrameTime+1e3/this.fpsLimit){this.draw(!1);return}this._lastFrameTime??=e;let t=Lr(e-this._lastFrameTime,this.fpsLimit,this._smooth);if(this.addLifeTime(t.value),this._lastFrameTime=e,t.value>1e3){this.draw(!1);return}if(this.particles.draw(t),!this.alive()){this.destroy();return}this.animationStatus&&this.draw(!1)}catch(e){ft().error(`${O} in animation loop`,e)}},this._engine=e,this.id=Symbol(t),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=n,this._initialSourceOptions=n,this.retina=new Ir(this),this.canvas=new fn(this,this._engine),this.particles=new Fr(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=Rr(this._engine,this),this.actualOptions=Rr(this._engine,this),this._eventListeners=new mn(this),this._intersectionObserver=_t(e=>this._intersectionManager(e)),this._engine.dispatchEvent(K.containerBuilt,{container:this})}get animationStatus(){return!this._paused&&!this.pageHidden&&Y(this)}get options(){return this._options}get sourceOptions(){return this._sourceOptions}addClickHandler(e){if(!Y(this))return;let t=this.interactivity.element;if(!t)return;let n=(t,n,r)=>{if(!Y(this))return;let i=this.retina.pixelRatio,a={x:n.x*i,y:n.y*i};e(t,this.particles.quadTree.queryCircle(a,r*i))},r=e=>{if(!Y(this))return;let t=e,r={x:t.offsetX||t.clientX,y:t.offsetY||t.clientY};n(e,r,1)},i=()=>{Y(this)&&(c=!0,l=!1)},a=()=>{Y(this)&&(l=!0)},o=e=>{if(Y(this)){if(c&&!l){let t=e,r=t.touches[t.touches.length-1];if(!r&&(r=t.changedTouches[t.changedTouches.length-1],!r))return;let i=this.canvas.element,a=i?i.getBoundingClientRect():void 0,o={x:r.clientX-(a?a.left:0),y:r.clientY-(a?a.top:0)};n(e,o,Math.max(r.radiusX,r.radiusY))}c=!1,l=!1}},s=()=>{Y(this)&&(c=!1,l=!1)},c=!1,l=!1;this._clickHandlers.set(`click`,r),this._clickHandlers.set(`touchstart`,i),this._clickHandlers.set(`touchmove`,a),this._clickHandlers.set(`touchend`,o),this._clickHandlers.set(`touchcancel`,s);for(let[e,n]of this._clickHandlers)t.addEventListener(e,n)}addLifeTime(e){this._lifeTime+=e}addPath(e,t,n=!1){return!Y(this)||!n&&this.pathGenerators.has(e)?!1:(this.pathGenerators.set(e,t),!0)}alive(){return!this._duration||this._lifeTime<=this._duration}clearClickHandlers(){if(Y(this)){for(let[e,t]of this._clickHandlers)this.interactivity.element?.removeEventListener(e,t);this._clickHandlers.clear()}}destroy(e=!0){if(Y(this)){this.stop(),this.clearClickHandlers(),this.particles.destroy(),this.canvas.destroy();for(let e of this.effectDrawers.values())e.destroy?.(this);for(let e of this.shapeDrawers.values())e.destroy?.(this);for(let e of this.effectDrawers.keys())this.effectDrawers.delete(e);for(let e of this.shapeDrawers.keys())this.shapeDrawers.delete(e);
1if(this._engine.clearPlugins(this),this.destroyed=!0,e){let e=this._engine.items,t=e.findIndex(e=>e===this);t>=0&&e.splice(t,1)}this._engine.dispatchEvent(K.containerDestroyed,{container:this})}}draw(e){if(!Y(this))return;let t=e,n=e=>{t&&=(this._lastFrameTime=void 0,!1),this._nextFrame(e)};this._drawAnimationFrame=qe(e=>n(e))}async export(e,t={}){for(let n of this.plugins.values()){if(!n.export)continue;let r=await n.export(e,t);if(r.supported)return r.blob}ft().error(`${O} - Export plugin with type ${e} not found`)}handleClickMode(e){if(Y(this)){this.particles.handleClickMode(e);for(let t of this.plugins.values())t.handleClickMode?.(e)}}async init(){if(!Y(this))return;let e=this._engine.getSupportedEffects();for(let t of e){let e=this._engine.getEffectDrawer(t);e&&this.effectDrawers.set(t,e)}let t=this._engine.getSupportedShapes();for(let e of t){let t=this._engine.getShapeDrawer(e);t&&this.shapeDrawers.set(e,t)}await this.particles.initPlugins(),this._options=Rr(this._engine,this,this._initialSourceOptions,this.sourceOptions),this.actualOptions=Rr(this._engine,this,this._options);let n=await this._engine.getAvailablePlugins(this);for(let[e,t]of n)this.plugins.set(e,t);this.retina.init(),await this.canvas.init(),this.updateActualOptions(),this.canvas.initBackgroun
1d(),this.canvas.resize();let{zLayers:r,duration:i,delay:a,fpsLimit:o,smooth:s}=this.actualOptions;this.zLayers=r,this._duration=z(i)*A,this._delay=z(a)*A,this._lifeTime=0,this.fpsLimit=o>0?o:120,this._smooth=s;for(let e of this.effectDrawers.values())await e.init?.(this);for(let e of this.shapeDrawers.values())await e.init?.(this);for(let e of this.plugins.values())await e.init?.();this._engine.dispatchEvent(K.containerInit,{container:this}),await this.particles.init(),this.particles.setDensity();for(let e of this.plugins.values())e.particlesSetup?.();this._engine.dispatchEvent(K.particlesSetup,{container:this})}async loadTheme(e){Y(this)&&(this._currentTheme=e,await this.refresh())}pause(){if(Y(this)&&(this._drawAnimationFrame!==void 0&&(Je(this._drawAnimationFrame),delete this._drawAnimationFrame),!this._paused)){for(let e of this.plugins.values())e.pause?.();this.pageHidden||(this._paused=!0),this._engine.dispatchEvent(K.containerPaused,{container:this})}}play(e){if(!Y(this))return;let t=this._paused||e;if(this._firstStart&&!this.actualOptions.autoPlay){this._firstStart=!1;return}if(this._paused&&=!1,t)for(let e of this.plugins.values())e.play&&e.play();this._engine.dispatchEvent(K.containerPlay,{container:this}),this.draw(t??!1)}async refresh(){if(Y(this))return this.stop(),this.start()}async reset(e){if(Y(this))return this._initialSourceOptions=e,this._sourceOptions=e,this._options=Rr(this._engine,this,this._initialSourceOptions,this.sourceOptions),this.actualOptions=Rr(this._engine,this,this._options),this.refresh()}async start(){Y(this)&&!this.started&&(await this.init(),this.started=!0,await new Promise(e=>{let t=async()=>{this._eventListeners.addListeners(),this.interactivity.element instanceof HTMLElement&&this._intersectionObserver&&this._intersectionObserver.observe(this.interactivity.element);for(let e of this.plugins.values())await e.start?.();this._engine.dispatchEvent(K.containerStarted,{container:this}),this.play(),e()};this._delayTimeout=setTimeout(()=>void t(),this._delay)}))}stop(){if(Y(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(K.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&&(this._responsiveMaxWidth=e,!0)}},Br=class{constructor(){this._listeners=new Map}addEventListener(e,t){this.removeEventListener(e,t);let n=this._listeners.get(e);n||(n=[],this._listeners.set(e,n)),n.push(t)}dispatchEvent(e,t){this._listeners.get(e)?.forEach(e=>e(t))}hasEventListener(e){return!!this._listeners.get(e)}removeAllEventListeners(e){e?this._listeners.delete(e):this._listeners=new Map}removeEventListener(e,t){let n=this._listeners.get(e);if(!n)return;let r=n.length,i=n.indexOf(t);i<0||(r===1?this._listeners.delete(e):n.splice(i,1))}};async function Vr(e,t,n,r=!1){let i=t.get(e);return(!i||r)&&(i=await Promise.all([...n.values()].map(t=>t(e))),t.set(e,i)),i}async function Hr(e){let t=W(e.url,e.index);if(!t)return e.fallback;let n=await fetch(t);return n.ok?await n.json():(ft().error(`${O} ${n.status} while retrieving config file`),e.fallback)}var Ur=e=>{let t;if(e instanceof HTMLCanvasElement||e.tagName.toLowerCase()===`canvas`)t=e,t.dataset.generated||(t.dataset[be]=Fe);else{let n=e.getElementsByTagName(Ie);n.length?(t=n[0],t.dataset[be]=Fe):(t=document.createElement(Ie),t.dataset[be]=Pe,e.appendChild(t))}let n=`100%`;return t.style.width||(t.style.width=n),t.style.height||(t.style.height=n),t},Wr=(e,t)=>{let n=t??document.getElementById(e);return n||(n=document.createElement(`div`),n.id=e,n.dataset[be]=Pe,document.body.append(n),n)},Gr=class{constructor(){this._configs=new Map,this._domArray=[],this._eventDispatcher=new Br,this._initialized=!1,this.plugins=[],this.colorManagers=new Map,this.easingFunctions=new Map,this._initializer
1s={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[t,n]of this._configs)e[t]=n;return e}get items(){return this._domArray}get version(){return`3.9.1`}async addColorManager(e,t=!0){this.colorManagers.set(e.key,e),await this.refresh(t)}addConfig(e){let t=e.key??e.name??`default`;this._configs.set(t,e),this._eventDispatcher.dispatchEvent(K.configAdded,{data:{name:t,config:e}})}async addEasing(e,t,n=!0){this.getEasing(e)||(this.easingFunctions.set(e,t),await this.refresh(n))}async addEffect(e,t,n=!0){Et(e,e=>{this.getEffectDrawer(e)||this.effectDrawers.set(e,t)}),await this.refresh(n)}addEventListener(e,t){this._eventDispatcher.addEventListener(e,t)}async addInteractor(e,t,n=!0){this._initializers.interactors.set(e,t),await this.refresh(n)}async addMover(e,t,n=!0){this._initializers.movers.set(e,t),await this.refresh(n)}async addParticleUpdater(e,t,n=!0){this._initializers.updaters.set(e,t),await this.refresh(n)}async addPathGenerator(e,t,n=!0){this.getPathGenerator(e)||this.pathGenerators.set(e,t),await this.refresh(n)}async addPlugin(e,t=!0){this.getPlugin(e.id)||this.plugins.push(e),await this.refresh(t)}async addPreset(e,t,n=!1,r=!0){(n||!this.getPreset(e))&&this.presets.set(e,t),await this.refresh(r)}async addShape(e,t=!0){for(let t of e.validTypes)this.getShapeDrawer(t)||this.shapeDrawers.set(t,e);await this.refresh(t)}checkVersion(e){if(this.version!==e)throw 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,t){this._eventDispatcher.dispatchEvent(e,t)}dom(){return this.items}domItem(e){return this.item(e)}async getAvailablePlugins(e){let t=new Map;for(let n of this.plugins)n.needsPlugin(e.actualOptions)&&t.set(n.id,await n.getPlugin(e));return t}getEasing(e){return this.easingFunctions.get(e)??(e=>e)}getEffectDrawer(e){return this.effectDrawers.get(e)}async getInteractors(e,t=!1){return Vr(e,this.interactors,this._initializers.interactors,t)}async getMovers(e,t=!1){return Vr(e,this.movers,this._initializers.movers,t)}getPathGenerator(e){return this.pathGenerators.get(e)}getPlugin(e){return this.plugins.find(t=>t.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,t=!1){return Vr(e,this.updaters,this._initializers.updaters,t)}init(){this._initialized||=!0}item(e){let{items:t}=this,n=t[e];if(!n||n.destroyed){t.splice(e,1);return}return n}async load(e){let t=e.id??e.element?.id??`tsparticles${Math.floor(L()*1e4)}`,{index:n,url:r}=e,i=W(r?await Hr({fallback:e.options,url:r,index:n}):e.options,n),{items:a}=this,o=a.findIndex(e=>e.id.description===t),s=new zr(this,t,i);if(o>=0){let e=this.item(o),t=+!!e;e&&!e.destroyed&&e.destroy(!1),a.splice(o,t,s)}else a.push(s);let c=Ur(Wr(t,e.element));return s.canvas.loadCanvas(c),await s.start(),s}loadOptions(e,t){this.plugins.forEach(n=>n.loadOptions?.(e,t))}loadParticlesOptions(e,t,...n){let r=this.updaters.get(e);r&&r.forEach(e=>e.loadOptions?.(t,...n))}async refresh(e=!0){e&&await Promise.all(this.items.map(e=>e.refresh()))}removeEventListener(e,t){this._eventDispatcher.removeEventListener(e,t)}setOnClickHandler(e){let{items:t}=this;if(!t.length)throw Error(`${O} can only set click handlers after calling tsParticles.load()`);t.forEach(t=>t.addClickHandler(e))}};function Kr(){let e=new Gr;return e.init(),e}var X;(function(e){e.clockwise=`clockwise`,e.counterClockwise=`counter-clockwise`,e.random=`random`})(X||={});var qr=Kr();mt()||(window.tsParticles=qr);var Jr=class{constructor(){this.wait=!1}load(e){I(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))}},Yr=class{constructor(){this.quantity=1,this.delay=.1}load(e){I(e)||(e.quantity!==void 0&&(this.quantity=B(e.quantity)),e.delay!==void 0&&(this.delay=B(e.delay)))}},Xr=class{constructor(){this.color=!1,this.opacity=!1}load(e){I(e)||(e.color!==void 0&&(this.color=e.color),e.opacity!==void 0&&(this.opacity=e.opacity))}},Zr=class{constructor(){this.options={},this.replace=new Xr,this.type=`square`}load(e){I(e)||(e.options!==void 0&&(this.options=U({},e.options??{}
1)),this.replace.load(e.replace),e.type!==void 0&&(this.type=e.type))}},Qr=class{constructor(){this.mode=lt.percent,this.height=0,this.width=0}load(e){I(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))}},$r=class{constructor(){this.autoPlay=!0,this.fill=!0,this.life=new Jr,this.rate=new Yr,this.shape=new Zr,this.startCount=0}load(e){I(e)||(e.autoPlay!==void 0&&(this.autoPlay=e.autoPlay),e.size!==void 0&&(this.size||=new Qr,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=Et(e.particles,e=>U({},e)),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 zn),this.spawnColor.load(e.spawnColor)),e.startCount!==void 0&&(this.startCount=e.startCount))}},ei;(function(e){e.emitter=`emitter`})(ei||={});var ti=.5,ni=0,ri=0,ii=0,ai=0,oi=-1,si=1;function ci(e,t){e.color?e.color.value=t:e.color={value:t}}var li=class{constructor(e,t,n,r,i){this.emitters=t,this.container=n,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 e=this.options.life?.duration===void 0?void 0:z(this.options.life.duration);(this._lifeCount>0||this._immortal)&&e!==void 0&&e>0&&(this._duration=e*A)},this._setColorAnimation=(e,t,n,r=si)=>{let i=this.container;if(!e.enable)return t;let a=R(e.offset),o=z(this.options.rate.delay),s=i.retina.reduceFactor?o*A/i.retina.reduceFactor:1/0;return(t+z(e.speed??0)*i.fpsLimit/s+a*r)%n},this._engine=e,this._currentDuration=0,this._currentEmitDelay=0,this._currentSpawnDelay=0,this._initialPosition=i,r instanceof $r?this.options=r:(this.options=new $r,this.options.load(r)),this._spawnDelay=n.retina.reduceFactor?z(this.options.life.delay??ni)*A/n.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 a=U({},this.options.particles);if(a??={},a.move??={},a.move.direction??=this.options.direction,this.options.spawnColor&&(this.spawnColor=Bt(this._engine,this.options.spawnColor)),this._paused=!this.options.autoPlay,this._particlesOptions=a,this._size=this._calcSize(),this.size=At(this._size,this.container.canvas.size),this._lifeCount=this.options.life.count??oi,this._immortal=this._lifeCount<=ri,this.options.domId){let e=document.getElementById(this.options.domId);e&&(this._mutationObserver=new MutationObserver(()=>{this.resize()}),this._resizeObserver=new ResizeObserver(()=>{this.resize()}),this._mutationObserver.observe(e,{attributes:!0,attributeFilter:[`style`,`width`,`height`]}),this._resizeObserver.observe(e))}let o=this.options.shape,s=this._engine.emitterShapeManager?.getShapeGenerator(o.type);s&&(this._shape=s.generate(this.position,this.size,this.fill,o.options)),this._engine.dispatchEvent(`emitterCreated`,{container:n,data:{emitter:this}}),this.play()}externalPause(){this._paused=!0,this.pause()}externalPlay(){this._paused=!1,this.play()}
1async init(){await this._shape?.init()}pause(){this._paused||delete this._emitDelay}play(){if(this._paused||!((this._lifeCount>ri||this._immortal||!this.options.life.count)&&(this._firstSpawn||this._currentSpawnDelay>=(this._spawnDelay??ii))))return;let e=this.container;if(this._emitDelay===void 0){let t=z(this.options.rate.delay);this._emitDelay=e.retina.reduceFactor?t*A/e.retina.reduceFactor:1/0}(this._lifeCount>ri||this._immortal)&&this._prepareToDie()}resize(){let e=this._initialPosition,t=this.container;this.position=e&&Ct(e,t.canvas.size,We.origin)?e:this._calcPosition(),this._size=this._calcSize(),this.size=At(this._size,t.canvas.size),this._shape?.resize(this.position,this.size)}update(e){if(this._paused)return;let t=this.container;this._firstSpawn&&(this._firstSpawn=!1,this._currentSpawnDelay=this._spawnDelay??ii,this._currentEmitDelay=this._emitDelay??ai),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>ri||this._immortal?(this.position=this._calcPosition(),this._shape?.resize(this.position,this.size),this._spawnDelay=t.retina.reduceFactor?z(this.options.life.delay??ni)*A/t.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 t=document.getElementById(this.options.domId);if(t){let n=t.getBoundingClientRect(),r=e.retina.pixelRatio;return{x:(n.x+n.width*ti)*r,y:(n.y+n.height*ti)*r}}}return it({size:e.canvas.size,position:this.options.position})}_calcSize(){let e=this.container;if(this.options.domId){let t=document.getElementById(this.options.domId);if(t){let n=t.getBoundingClientRect();return{width:n.width*e.retina.pixelRatio,height:n.height*e.retina.pixelRatio,mode:lt.precise}}}return this.options.size??(()=>{let e=new Qr;return e.load({height:0,mode:lt.percent,width:0}),e})()}_emit(){if(this._paused)return;let e=z(this.options.rate.quantity);this._emitParticles(e)}_emitParticles(e){let t=W(this._particlesOptions),n=this.container.retina.reduceFactor;for(let r=0;r<e*n;r++){let e=U({},t);if(this.spawnColor){let t=this.options.spawnColor?.animation;if(t){let e={h:360,s:100,l:100};this.spawnColor.h=this._setColorAnimation(t.h,this.spawnColor.h,e.h,3.6),this.spawnColor.s=this._setColorAnimation(t.s,this.spawnColor.s,e.s),this.spawnColor.l=this._setColorAnimation(t.l,this.spawnColor.l,e.l)}ci(e,this.spawnColor)}let n=this.options.shape,r=this.position;if(this._shape){let t=this._shape.randomPosition();if(t){r=t.position;let i=n.replace;i.color&&t.color&&ci(e,t.color),i.opacity&&(e.opacity?e.opacity.value=t.opacity:e.opacity={value:t.opacity})}else r=null}r&&this.container.particles.addParticle(r,e)}}},ui=class{constructor(e,t){this.container=t,this._engine=e,this.array=[],this.emitters=[],this.interactivityEmitters={random:{count:1,enable:!1},value:[]},t.getEmitter=e=>e===void 0||P(e)?this.array[e??0]:this.array.find(t=>t.name===e),t.addEmitter=async(e,t)=>this.addEmitter(e,t),t.removeEmitter=e=>{let n=t.getEmitter(e);n&&this.removeEmitter(n)},t.playEmitter=e=>{let n=t.getEmitter(e);n&&n.externalPlay()},t.pauseEmitter=e=>{let n=t.getEmitter(e);n&&n.externalPause()}}async addEmitter(e,t){let n=new $r;n.load(e);let r=new li(this._engine,this,this.container,n,t);return await r.init(),this.array.push(r),r}handleClickMode(e){let t=this.emitters,n=this.interactivityEmitters;if(e!==ei.emitter)return;let r;if(n&&F(n.value)){if(n.value.length>0&&n.random.enable){r=[];let e=[];for(let t=0;t<n.random.count;
1t++){let i=xt(n.value);if(e.includes(i)&&e.length<n.value.length){t--;continue}e.push(i),r.push(St(n.value,i))}}else r=n.value}else r=n?.value;let i=r??t,a=this.container.interactivity.mouse.clickPosition;Et(i,async e=>{await this.addEmitter(e,a)})}async init(){if(this.emitters=this.container.actualOptions.emitters,this.interactivityEmitters=this.container.actualOptions.interactivity.modes.emitters,this.emitters){if(F(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 t=this.array.indexOf(e);t>=0&&this.array.splice(t,1)}resize(){for(let e of this.array)e.resize()}stop(){this.array=[]}update(e){for(let t of this.array)t.update(e)}},di=class{constructor(e){this._engine=e,this.id=`emitters`}getPlugin(e){return Promise.resolve(new ui(this._engine,e))}loadOptions(e,t){if(!this.needsPlugin(e)&&!this.needsPlugin(t))return;t?.emitters&&(e.emitters=Et(t.emitters,e=>{let t=new $r;return t.load(e),t}));let n=t?.interactivity?.modes?.emitters;if(n){if(F(n))e.interactivity.modes.emitters={random:{count:1,enable:!0},value:n.map(e=>{let t=new $r;return t.load(e),t})};else{let t=n;if(t.value!==void 0){if(F(t.value))e.interactivity.modes.emitters={random:{count:t.random.count??1,enable:t.random.enable??!1},value:t.value.map(e=>{let t=new $r;return t.load(e),t})};else{let n=new $r;n.load(t.value),e.interactivity.modes.emitters={random:{count:t.random.count??1,enable:t.random.enable??!1},value:n}}}else(e.interactivity.modes.emitters={random:{count:1,enable:!1},value:new $r}).value.load(n)}}}needsPlugin(e){if(!e)return!1;let t=e.emitters;return F(t)&&!!t.length||t!==void 0||!!e.interactivity?.events?.onClick?.mode&&yt(ei.emitter,e.interactivity.events.onClick.mode)}},fi=new Map,pi=class{constructor(e){this._engine=e}addShapeGenerator(e,t){this.getShapeGenerator(e)||fi.set(e,t)}getShapeGenerator(e){return fi.get(e)}getSupportedShapeGenerators(){return fi.keys()}};async function mi(e,t=!0){e.checkVersion(`3.9.1`),e.emitterShapeManager||=new pi(e),e.addEmitterShapeGenerator||=(t,n)=>{e.emitterShapeManager?.addShapeGenerator(t,n)};let n=new di(e);await e.addPlugin(n,t)}var hi=class{constructor(){this.angle=90,this.count=50,this.spread=45,this.startVelocity=45,this.decay=.9,this.gravity=1,this.drift=0,this.ticks=200,this.position={x:50,y:50},this.colors=[`#26ccff`,`#a25afd`,`#ff5e7e`,`#88ff5a`,`#fcff42`,`#ffa62d`,`#ff36ff`],this.shapes=[`square`,`circle`],this.scalar=1,this.zIndex=100,this.disableForReducedMotion=!0,this.flat=!1,this.shapeOptions={}}get origin(){return{x:this.position.x/100,y:this.position.y/100}}set origin(e){this.position.x=e.x*100,this.position.y=e.y*100}get particleCount(){return this.count}set particleCount(e){this.count=e}load(e){if(I(e))return;e.angle!==void 0&&(this.angle=e.angle);let t=e.count??e.particleCount;t!==void 0&&(this.count=t),e.spread!==void 0&&(this.spread=e.spread),e.startVelocity!==void 0&&(this.startVelocity=e.startVelocity),e.decay!==void 0&&(this.decay=e.decay),e.flat!==void 0&&(this.flat=e.flat),e.gravity!==void 0&&(this.gravity=e.gravity),e.drift!==void 0&&(this.drift=e.drift),e.ticks!==void 0&&(this.ticks=e.ticks);let n=e.origin;n&&!e.position&&(e.position={x:n.x===void 0?void 0:n.x*100,y:n.y===void 0?void 0:n.y*100});let r=e.position;r&&(r.x!==void 0&&(this.position.x=r.x),r.y!==void 0&&(this.position.y=r.y)),e.colors!==void 0&&(this.colors=F(e.colors)?[...e.colors]:e.colors);let i=e.shapeOptions;if(i!==void 0)for(let e in i){let t=i[e];t&&(this.shapeOptions[e]=U(this.shapeOptions[e]??{},t))}e.shapes!==void 0&&(this.shapes=F(e.shapes)?[...e.shapes]:e.shapes),e.scalar!==void 0&&(this.scalar=e.scalar),e.zIndex!==void 0&&(this.zIndex=e.zIndex),e.disableForReducedMotion!==void 0&&(this.disableForReducedMotion=e.disableForReducedMotion)}},gi=.5,_i=2,vi=0,yi=1,bi=60,xi=0,Si=.01,Ci=Math.PI*_i;function wi(e){let t=e.initialPosition,{dx:n,dy:r}=Qe(t,e.position),i=Math.abs(n),a=Math.abs(r),{maxDistance:o}=e.retina,s=o.horizontal,c=o.vertical;if(s||c){if((((s&&i>=s)??!1)||((c&&a>=c)??!1))&&!e.misplaced)e.misplaced=!!s&&i>s||!!c&&a>c,s&&(e.velocity.x=e.velocity.y*gi-e.velocity.x),c&&(e.velocity.y=e.velocity.x*gi-e.velocity.y);else if((!s||i<s)&&(!c||a<c)&&e.misplaced)e.misplaced=!1;else if(e.misplaced){let n=e.position,r=e.velocity;s&&(n.x<t.x&&r.x<vi||n.x>t.x&&r.x>vi)&&(r.x*=-L()),c&&(n.y<t.y&&r.y<vi||n.y>t.y&&r.y>
1vi)&&(r.y*=-L())}}}function Ti(e,t,n,r,i,a,o){Di(e,o);let s=e.gravity,c=s?.enable&&s.inverse?-1:yi;i&&n&&(e.velocity.x+=i*o.factor/(bi*n)),s?.enable&&n&&(e.velocity.y+=c*(s.acceleration*o.factor)/(bi*n));let l=e.moveDecay;e.velocity.multTo(l);let u=e.velocity.mult(n);s?.enable&&r>vi&&(!s.inverse&&u.y>=vi&&u.y>=r||s.inverse&&u.y<=vi&&u.y<=-r)&&(u.y=c*r,n&&(e.velocity.y=u.y/n));let d=e.options.zIndex,f=(yi-e.zIndexFactor)**d.velocityRate;u.multTo(f),u.multTo(a);let{position:p}=e;p.addTo(u),t.vibrate&&(p.x+=Math.sin(p.x*Math.cos(p.y))*a,p.y+=Math.cos(p.y*Math.sin(p.x))*a)}function Ei(e,t,n){let r=e.container;if(!e.spin)return;let i=e.spin.direction===X.clockwise,a={x:i?Math.cos:Math.sin,y:i?Math.sin:Math.cos};e.position.x=e.spin.center.x+e.spin.radius*a.x(e.spin.angle)*n,e.position.y=e.spin.center.y+e.spin.radius*a.y(e.spin.angle)*n,e.spin.radius+=e.spin.acceleration*n;let o=Math.max(r.canvas.size.width,r.canvas.size.height),s=o*gi;e.spin.radius>s?(e.spin.radius=s,e.spin.acceleration*=-1):e.spin.radius<xi&&(e.spin.radius=xi,e.spin.acceleration*=-1),e.spin.angle+=t*Si*(yi-e.spin.radius/o)}function Di(e,t){let n=e.options.move.path;if(!n.enable)return;if(e.lastPathTime<=e.pathDelay){e.lastPathTime+=t.value;return}let r=e.pathGenerator?.generate(e,t);r&&e.velocity.addTo(r),n.clamp&&(e.velocity.x=Ye(e.velocity.x,-1,yi),e.velocity.y=Ye(e.velocity.y,-1,yi)),e.lastPathTime-=e.pathDelay}function Oi(e){return e.slow.inRange?e.slow.factor:yi}function ki(e){let t=e.container,n=e.options.move.spin;if(!n.enable)return;let r=n.position??{x:50,y:50},i=.01,a={x:r.x*i*t.canvas.size.width,y:r.y*i*t.canvas.size.height},o=$e(e.getPosition(),a),s=z(n.acceleration);e.retina.spinAcceleration=s*t.retina.pixelRatio,e.spin={center:a,direction:e.velocity.x>=vi?X.clockwise:X.counterClockwise,angle:L()*Ci,radius:o,acceleration:e.retina.spinAcceleration}}var Ai=2,ji=1,Mi=1,Ni=class{init(e){let t=e.options.move.gravity;e.gravity={enable:t.enable,acceleration:z(t.acceleration),inverse:t.inverse},ki(e)}isEnabled(e){return!e.destroyed&&e.options.move.enable}move(e,t){let n=e.options,r=n.move;if(!r.enable)return;let i=e.container,a=i.retina.pixelRatio;e.retina.moveSpeed??=z(r.speed)*a,e.retina.moveDrift??=z(e.options.move.drift)*a;let o=Oi(e),s=i.retina.reduceFactor,c=e.retina.moveSpeed,l=e.retina.moveDrift,u=Ze(n.size.value)*a,d=r.size?e.getRadius()/u:ji,f=t.factor||Mi,p=c*d*o*f/Ai,m=e.retina.maxSpeed??i.retina.maxSpeed;r.spin.enable?Ei(e,p,s):Ti(e,r,p,m,l,s,t),wi(e)}};async function Pi(e,t=!0){e.checkVersion(`3.9.1`),await e.addMover(`base`,()=>Promise.resolve(new Ni),t)}var Fi=Math.PI*2,Ii=0,Li={x:0,y:0};function Ri(e){let{context:t,particle:n,radius:r}=e;n.circleRange||={min:Ii,max:Fi};let i=n.circleRange;t.arc(Li.x,Li.y,r,i.min,i.max,!1)}var zi=12,Bi=360,Vi=0,Hi=class{constructor(){this.validTypes=[`circle`]}draw(e){Ri(e)}getSidesCount(){return zi}particleInit(e,t){let n=t.shapeData?.angle??{max:Bi,min:Vi};t.circleRange=He(n)?{min:et(n.min),max:et(n.max)}:{min:Vi,max:et(n)}}};async function Ui(e,t=!0){e.checkVersion(`3.9.1`),await e.addShape(new Hi,t)}var Wi=class{constructor(e,t){this._container=e,this._engine=t}init(e){let t=Bt(this._engine,e.options.color,e.id,e.options.reduceDuplicates);t&&(e.color=Yt(t,e.options.color.animation,this._container.retina.reduceFactor))}isEnabled(e){let{h:t,s:n,l:r}=e.options.color.animation,{color:i}=e;return!e.destroyed&&!e.spawning&&(i?.h.value!==void 0&&t.enable||i?.s.value!==void 0&&n.enable||i?.l.value!==void 0&&r.enable)}update(e,t){Qt(e.color,t)}};async function Gi(e,t=!0){e.checkVersion(`3.9.1`),await e.addParticleUpdater(`color`,t=>Promise.resolve(new Wi(t,e)),t)}var Ki;(function(e){e[e.r=1]=`r`,e[e.g=2]=`g`,e[e.b=3]=`b`,e[e.a=4]=`a`})(Ki||={});var qi=/^#?([a-f\d])([a-f\d])([a-f\d])([a-f\d])?$/i,Ji=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})?$/i,Yi=16,Xi=1,Zi=255,Qi=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 t=e.replace(qi,(e,t,n,r,i)=>t+t+n+n+r+r+(i===void 0?``:i+i)),n=Ji.exec(t);return n?{a:n[Ki.a]===void 0?Xi:parseInt(n[Ki.a],Yi)/Zi,b:parseInt(n[Ki.b],Yi),g:parseInt(n[Ki.g],Yi),r:parseInt(n[Ki.r],Yi)}:void 0}};async function $i(e,t=!0){e.checkVersion(`3.9.1`),await e.addColorManager(new Qi,t)}var ea;(function(e){e[e.h=1]=`h`,e[e.s=2]=`s`,e[e.l=3]=`l`,e[e.a=5]=`a`})(ea||={});var ta=class{constructor(){this.key=`hsl`,this.stringPrefix=`hsl`}handleColor(e){let t=e.value.hsl??e.value;if(t.h!==void 0&&t.s!==void 0&&t.l!==void 0)return Ut(t)}handleRangeColor(e){let t=e.value.hsl??e.value;if(t.h!==void 0&&t.l!==void 0)return Ut({h:z(t.h),l:z(t.l),s:z(t.s)})}parseString(e){if(!e.startsWith(`hsl`))return;let t=/hsla?\(\s*(\d+)\s*[\s,]\s*(\d+)%\s*[\s,]\s*(\d+)%\s*([\s,]\s*(0|1|0?\.\d+|(\d{1,3})%)\s*)?\)/i.exec(e);return t?Wt({a:t.length>4?ot(t[ea.a]):1,h:parseInt(t[ea.h],10),l:parseInt(t[ea.l],10),s:parseInt(t[ea.s],10)}):void 0}};async function na(e,t=!0){e.checkVersion(`3.9.1`),await e.addColorManager(new ta,t)}var ra=class{constructor(e){this.container=e}init(e){let t=e.options.opacity;e.opacity=Dt(t,1);let n=t.animation;n.enable&&(e.opacity.velocity=z(n.speed)/100*this.container.retina.reduceFactor,n.sync||(e.opacity.velocity
1*=L()))}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,t){this.isEnabled(e)&&e.opacity&&Mt(e,e.opacity,!0,e.options.opacity.animation.destroy,t)}};async function ia(e,t=!0){e.checkVersion(`3.9.1`),await e.addParticleUpdater(`opacity`,e=>Promise.resolve(new ra(e)),t)}var aa=0,oa=0;function sa(e){if(e.outMode!==q.bounce&&e.outMode!==q.split||e.direction!==H.left&&e.direction!==H.right)return;e.bounds.right<oa&&e.direction===H.left?e.particle.position.x=e.size+e.offset.x:e.bounds.left>e.canvasSize.width&&e.direction===H.right&&(e.particle.position.x=e.canvasSize.width-e.size-e.offset.x);let t=e.particle.velocity.x,n=!1;if(e.direction===H.right&&e.bounds.right>=e.canvasSize.width&&t>aa||e.direction===H.left&&e.bounds.left<=oa&&t<aa){let t=z(e.particle.options.bounce.horizontal.value);e.particle.velocity.x*=-t,n=!0}if(!n)return;let r=e.offset.x+e.size;e.bounds.right>=e.canvasSize.width&&e.direction===H.right?e.particle.position.x=e.canvasSize.width-r:e.bounds.left<=oa&&e.direction===H.left&&(e.particle.position.x=r),e.outMode===q.split&&e.particle.destroy()}function ca(e){if(e.outMode!==q.bounce&&e.outMode!==q.split||e.direction!==H.bottom&&e.direction!==H.top)return;e.bounds.bottom<oa&&e.direction===H.top?e.particle.position.y=e.size+e.offset.y:e.bounds.top>e.canvasSize.height&&e.direction===H.bottom&&(e.particle.position.y=e.canvasSize.height-e.size-e.offset.y);let t=e.particle.velocity.y,n=!1;if(e.direction===H.bottom&&e.bounds.bottom>=e.canvasSize.height&&t>aa||e.direction===H.top&&e.bounds.top<=oa&&t<aa){let t=z(e.particle.options.bounce.vertical.value);e.particle.velocity.y*=-t,n=!0}if(!n)return;let r=e.offset.y+e.size;e.bounds.bottom>=e.canvasSize.height&&e.direction===H.bottom?e.particle.position.y=e.canvasSize.height-r:e.bounds.top<=oa&&e.direction===H.top&&(e.particle.position.y=r),e.outMode===q.split&&e.particle.destroy()}var la=class{constructor(e){this.container=e,this.modes=[q.bounce,q.split]}update(e,t,n,r){if(!this.modes.includes(r))return;let i=this.container,a=!1;for(let r of i.plugins.values())if(r.particleBounce!==void 0&&(a=r.particleBounce(e,n,t)),a)break;if(a)return;let o=e.getPosition(),s=e.offset,c=e.getRadius(),l=Tt(o,c),u=i.canvas.size;sa({particle:e,outMode:r,direction:t,bounds:l,canvasSize:u,offset:s,size:c}),ca({particle:e,outMode:r,direction:t,bounds:l,canvasSize:u,offset:s,size:c})}},ua=0,da=class{constructor(e){this.container=e,this.modes=[q.destroy]}update(e,t,n,r){if(!this.modes.includes(r))return;let i=this.container;switch(e.outType){case J.normal:case J.outside:if(Ct(e.position,i.canvas.size,We.origin,e.getRadius(),t))return;break;case J.inside:{let{dx:t,dy:n}=Qe(e.position,e.moveCenter),{x:r,y:i}=e.velocity;if(r<ua&&t>e.moveCenter.radius||i<ua&&n>e.moveCenter.radius||r>=ua&&t<-e.moveCenter.radius||i>=ua&&n<-e.moveCenter.radius)return;break}}i.particles.remove(e,e.group,!0)}},fa=0,pa=class{constructor(e){this.container=e,this.modes=[q.none]}update(e,t,n,r){if(!this.modes.includes(r)||((e.options.move.distance.horizontal&&(t===H.left||t===H.right))??(e.options.move.distance.vertical&&(t===H.top||t===H.bottom))))return;let i=e.options.move.gravity,a=this.container,o=a.canvas.size,s=e.getRadius();if(i.enable){let n=e.position;(!i.inverse&&n.y>o.height+s&&t===H.bottom||i.inverse&&n.y<-s&&t===H.top)&&a.particles.remove(e)}else{if(e.velocity.y>fa&&e.position.y<=o.height+s||e.velocity.y<fa&&e.position.y>=-s||e.velocity.x>fa&&e.position.x<=o.width+s||e.velocity.x<fa&&e.position.x>=-s)return;Ct(e.position,a.canvas.size,We.origin,s,t)||a.particles.remove(e)}}},ma=0,ha=0,ga=class{constructor(e){this.container=e,this.modes=[q.out]}update(e,t,n,r){if(!this.modes.includes(r))return;let i=this.container;switch(e.outType){case J.inside:{let{x:t,y:n}=e.velocity,r=We.origin;r.length=e.moveCenter.radius,r.angle=e.velocity.angle+Math.PI,r.addTo(We.create(e.moveCenter));let{dx:a,dy:o}=Qe(e.position,r);if(t<=ma&&a>=ha||n<=ma&&o>=ha||t>=ma&&a<=ha||n>=ma&&o<=ha)return;
1e.position.x=Math.floor(R({min:0,max:i.canvas.size.width})),e.position.y=Math.floor(R({min:0,max:i.canvas.size.height}));let{dx:s,dy:c}=Qe(e.position,e.moveCenter);e.direction=Math.atan2(-c,-s),e.velocity.angle=e.direction;break}default:if(Ct(e.position,i.canvas.size,We.origin,e.getRadius(),t))return;switch(e.outType){case J.outside:{e.position.x=Math.floor(R({min:-e.moveCenter.radius,max:e.moveCenter.radius}))+e.moveCenter.x,e.position.y=Math.floor(R({min:-e.moveCenter.radius,max:e.moveCenter.radius}))+e.moveCenter.y;let{dx:t,dy:n}=Qe(e.position,e.moveCenter);e.moveCenter.radius&&(e.direction=Math.atan2(n,t),e.velocity.angle=e.direction);break}case J.normal:{let n=e.options.move.warp,r=i.canvas.size,a={bottom:r.height+e.getRadius()+e.offset.y,left:-e.getRadius()-e.offset.x,right:r.width+e.getRadius()+e.offset.x,top:-e.getRadius()-e.offset.y},o=e.getRadius(),s=Tt(e.position,o);t===H.right&&s.left>r.width+e.offset.x?(e.position.x=a.left,e.initialPosition.x=e.position.x,n||(e.position.y=L()*r.height,e.initialPosition.y=e.position.y)):t===H.left&&s.right<-e.offset.x&&(e.position.x=a.right,e.initialPosition.x=e.position.x,n||(e.position.y=L()*r.height,e.initialPosition.y=e.position.y)),t===H.bottom&&s.top>r.height+e.offset.y?(n||(e.position.x=L()*r.width,e.initialPosition.x=e.position.x),e.position.y=a.top,e.initialPosition.y=e.position.y):t===H.top&&s.bottom<-e.offset.y&&(n||(e.position.x=L()*r.width,e.initialPosition.x=e.position.x),e.position.y=a.bottom,e.initialPosition.y=e.position.y);break}}}}},_a=(e,t)=>e.default===t||e.bottom===t||e.left===t||e.right===t||e.top===t,va=class{constructor(e){this._addUpdaterIfMissing=(e,t,n)=>{let r=e.options.move.outModes;!this.updaters.has(t)&&_a(r,t)&&this.updaters.set(t,n(this.container))},this._updateOutMode=(e,t,n,r)=>{for(let i of this.updaters.values())i.update(e,r,t,n)},this.container=e,this.updaters=new Map}init(e){this._addUpdaterIfMissing(e,q.bounce,e=>new la(e)),this._addUpdaterIfMissing(e,q.out,e=>new ga(e)),this._addUpdaterIfMissing(e,q.destroy,e=>new da(e)),this._addUpdaterIfMissing(e,q.none,e=>new pa(e))}isEnabled(e){return!e.destroyed&&!e.spawning}update(e,t){let n=e.options.move.outModes;this._updateOutMode(e,t,n.bottom??n.default,H.bottom),this._updateOutMode(e,t,n.left??n.default,H.left),this._updateOutMode(e,t,n.right??n.default,H.right),this._updateOutMode(e,t,n.top??n.default,H.top)}};async function ya(e,t=!0){e.checkVersion(`3.9.1`),await e.addParticleUpdater(`outModes`,e=>Promise.resolve(new va(e)),t)}var ba;(function(e){e[e.r=1]=`r`,e[e.g=2]=`g`,e[e.b=3]=`b`,e[e.a=5]=`a`})(ba||={});var xa=class{constructor(){this.key=`rgb`,this.stringPrefix=`rgb`}handleColor(e){let t=e.value.rgb??e.value;if(t.r!==void 0)return t}handleRangeColor(e){let t=e.value.rgb??e.value;if(t.r!==void 0)return{r:z(t.r),g:z(t.g),b:z(t.b)}}parseString(e){if(!e.startsWith(this.stringPrefix))return;let t=/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.exec(e);return t?{a:t.length>4?ot(t[ba.a]):1,b:parseInt(t[ba.b],10),g:parseInt(t[ba.g],10),r:parseInt(t[ba.r],10)}:void 0}};async function Sa(e,t=!0){e.checkVersion(`3.9.1`),await e.addColorManager(new xa,t)}var Ca=0,wa=class{init(e){let t=e.container,n=e.options.size.animation;n.enable&&(e.size.velocity=(e.retina.sizeAnimationSpeed??t.retina.sizeAnimationSpeed)/100*t.retina.reduceFactor,n.sync||(e.size.velocity*=L()))}isEnabled(e){return!e.destroyed&&!e.spawning&&e.size.enable&&((e.size.maxLoops??Ca)<=Ca||(e.size.maxLoops??Ca)>Ca&&(e.size.loops??Ca)<(e.size.maxLoops??Ca))}reset(e){e.size.loops=Ca}update(e,t){this.isEnabled(e)&&Mt(e,e.size,!0,e.options.size.animation.destroy,t)}};async function Ta(e,t=!0){e.checkVersion(`3.9.1`),await e.addParticleUpdater(`size`,()=>Promise.resolve(new wa),t)}async function Ea(e,t=!0){e.checkVersion(`3.9.1`),await $i(e,!1),await na(e,!1),await Sa(e,!1),await Pi(e,!1),await Ui(e,!1),await Gi(e,!1),await ia(e,!1),await ya(e,!1),await Ta(e,!1),await e.refresh(t)}function Da(e,t){if(!t.segments.length||!t.segments[0].values.length)return;let{context:n,radius:r}=e;n.moveTo(t.segments[0].values[0].x*r,t.segments[0].values[0].y*r);for(let e of t.segments)n.bezierCurveTo(e.values[1].x*r,e.values[1].y*r,e.values[2].x*r,e.values[2].y*r,e.values[3].x*r,e.values[3].y*r);for(let e=t.segments.length-1;e>=0;e--){let i=t.segments[e];n.bezierCurveTo(-i.values[2].x*r,i.values[2].y*r,-i.values[1].x*r,i.values[1].y*r,-i.values[0].x*r,i.values[0].y*r)}}var Z=1/2,Oa={heart:{segments:[{values:[{x:0,y:Z},{x:0,y:Z},{x:Z,y:0},{x:Z,y:-.5/2}]},{values:[{x:Z,y:-.5/2},{x:Z,y:-.5/2},{x:Z,y:-.5},{x:Z/2,y:-.5}]},{values:[{x:Z/2,y:-.5},{x:Z/2,y:-.5},{x:0,y:-.5},{x:0,y:-.5/2}]}]},diamond:{segments:[{values:[{x:0,y:Z},{x:0,y:Z},{x:3*Z/4,y:0},{x:3*Z/4,y:0}]},{values:[{x:3*Z/4,y:0},{x:3*Z/4,y:0},{x:0,y:-.5},{x:0,y:-.5}]}]},club:{segments:[{values:[{x:0,y:-.5},{x:0,y:-.5},{x:Z/2,y:-.5},{x:Z/2,y:-.5/2}]},{values:[{x:Z/2,y:-.5/2},{x:Z/2,y:-.5/2},{x:Z,y:-.5/2},{x:Z,y:0}]},{values:[{x:Z,y:0},{x:Z,y:0},{x:Z,y:Z/2},{x:Z/2,y:Z/2}]},{values:[{x:Z/2,y:Z/2},{x:Z/2,y:Z/2},{x:Z/8,y:Z/2},{x:Z/8,y:Z/8}]},{values:[{x:Z/8,y:Z/8},{x:Z/8,y:Z/2},{x:Z/2,y:Z},{x:Z/2,y:Z}]},{values:[{x:Z/2,y:Z},{x:Z/2,y:Z},{x:0,y:Z},{x:0,y:Z}]}]},spade:{segments:[{values:[{x:0,y:-.5},{x:0,y:-.5},{x:Z,y:-.5/2},{x:Z,y:0}]},{values:[{x:Z,y:0},{x:Z,y:0},{x:Z,y:Z/2},{x:Z/2,y:Z/2}]},{values:[{x:Z/2,y:Z/2},{x:Z/2,y:Z/2},{x:Z/8,y:Z/2},{x:Z/8,y:Z/8}]},{values:[{x:Z/8,y:Z/8},{x:Z/8,y:Z/2},{x:Z/2,y:Z},{x:Z/2,y:Z}]},{values:[{x:Z/2,y:Z},{x:Z/2,y:Z},{x:0,y:Z},{x:0,y:Z}]}]}},ka=class{constructor(){this.validTypes=[`club`,`clubs`]}draw(e){Da(e,Oa.club)}},Aa=class{constructor(){this.validTypes=[`diamond`,`diamonds`]}draw(e){Da(e,Oa.diamond)}},ja=class{constructor(){this.validTypes=[`heart`,`hearts`]}draw(e){Da(e,Oa.heart)}},Ma=class{constructor(){this.validTypes=[`spade`,`spades`]}draw(e){Da(e,Oa.spade)}};async function Na(e,t=!0){e.checkVersion(`3.9.1`),await e.addShape(new Ma,t),await e.addShape(new ja,t),await e.addShape(new Aa,t),await e.addShape(new ka,t)}
1function Pa(e,t){let{context:n,opacity:r}=e,i=n.globalAlpha;if(!t)return;let a=t.width,o=a*.5;n.globalAlpha=r,n.drawImage(t,-o,-o,a,a),n.globalAlpha=i}var Fa=`"Twemoji Mozilla", Apple Color Emoji, "Segoe UI Emoji", "Noto Color Emoji", "EmojiOne Color"`,Ia=0,La=class{constructor(){this.validTypes=[`emoji`],this._emojiShapeDict=new Map}destroy(){for(let[e,t]of this._emojiShapeDict)t instanceof ImageBitmap&&t?.close(),this._emojiShapeDict.delete(e)}draw(e){let t=e.particle.emojiDataKey;if(!t)return;let n=this._emojiShapeDict.get(t);n&&Pa(e,n)}async init(e){let t=e.actualOptions,{validTypes:n}=this;if(!n.find(e=>yt(e,t.particles.shape.type)))return;let r=[bt(Fa)],i=n.map(e=>t.particles.shape.options[e]).find(e=>!!e);i&&Et(i,e=>{e.font&&r.push(bt(e.font))}),await Promise.all(r)}particleDestroy(e){e.emojiDataKey=void 0}particleInit(e,t){let n=t.shapeData;if(!n?.value)return;let r=W(n.value,t.randomIndexData);if(!r)return;let i=typeof r==`string`?{font:n.font??Fa,padding:n.padding??Ia,value:r}:{font:Fa,padding:Ia,...n,...r},a=i.font,o=i.value,s=`${o}_${a}`;if(this._emojiShapeDict.has(s)){t.emojiDataKey=s;return}let c=i.padding*2,l=Ze(t.size.value),u=l+c,d=u*2,f;if(typeof OffscreenCanvas<`u`){let e=new OffscreenCanvas(d,d),t=e.getContext(`2d`);if(!t)return;t.font=`400 ${l*2}px ${a}`,t.textBaseline=`middle`,t.textAlign=`center`,t.fillText(o,u,u),f=e.transferToImageBitmap()}else{let e=document.createElement(`canvas`);e.width=d,e.height=d;let t=e.getContext(`2d`);if(!t)return;t.font=`400 ${l*2}px ${a}`,t.textBaseline=`middle`,t.textAlign=`center`,t.fillText(o,u,u),f=e}this._emojiShapeDict.set(s,f),t.emojiDataKey=s}};async function Ra(e,t=!0){e.checkVersion(`3.9.1`),await e.addShape(new La,t)}var za=.5,Ba=2;function Va(e){let{context:t,radius:n}=e,r=n*Ba,i=n*za,a=n+i,o=-n,s=-n;t.moveTo(o,s+i),t.quadraticCurveTo(o,s,o+i,s),t.quadraticCurveTo(o+n,s,o+n,s+i),t.quadraticCurveTo(o+n,s,o+a,s),t.quadraticCurveTo(o+r,s,o+r,s+i),t.quadraticCurveTo(o+r,s+n,o+a,s+a),t.lineTo(o+n,s+r),t.lineTo(o+i,s+a),t.quadraticCurveTo(o,s+n,o,s+i)}var Ha=class{constructor(){this.validTypes=[`heart`]}draw(e){Va(e)}};async function Ua(e,t=!0){e.checkVersion(`3.9.1`),await e.addShape(new Ha,t)}var Wa=0,Ga=1,Ka=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d.]+%?\))|currentcolor/gi;function qa(e,t,n){let{svgData:r}=e;if(!r)return``;let i=qt(t,n);if(r.includes(`fill`))return r.replace(Ka,()=>i);let a=r.indexOf(`>`);return`${r.substring(Wa,a)} fill="${i}"${r.substring(a)}`}async function Ja(e){return new Promise(t=>{e.loading=!0;let n=new Image;e.element=n,n.addEventListener(`load`,()=>{e.loading=!1,t()}),n.addEventListener(`error`,()=>{e.element=void 0,e.error=!0,e.loading=!1,ft().error(`${O} loading image: ${e.source}`),t()}),n.src=e.source})}async function Ya(e){if(e.type!==`svg`){await Ja(e);return}e.loading=!0;let t=await fetch(e.source);t.ok?e.svgData=await t.text():(ft().error(`${O} Image not found`),e.error=!0),e.loading=!1}function Xa(e,t,n,r){let i=qa(e,n,r.opacity?.value??Ga),a={color:n,gif:t.gif,data:{...e,svgData:i},loaded:!1,ratio:t.width/t.height,replaceColor:t.replaceColor,source:t.src};return new Promise(t=>{let n=new Blob([i],{type:`image/svg+xml`}),r=URL||window.URL||window.webkitURL||window,o=r.createObjectURL(n),s=new Image;s.addEventListener(`load`,()=>{a.loaded=!0,a.element=s,t(a),r.revokeObjectURL(o)});let c=async()=>{r.revokeObjectURL(o);let n={...e,error:!1,loading:!0};await Ja(n),a.loaded=!0,a.element=n.element,t(a)};s.addEventListener(`error`,()=>void c()),s.src=o})}var Za=[0,4,2,1],Qa=[8,8,4,2],$a=class{constructor(e){this.pos=0,this.data=new Uint8ClampedArray(e)}getString(e){let t=this.data.slice(this.pos,this.pos+e);return this.pos+=t.length,t.reduce((e,t)=>e+String.fromCharCode(t),``)}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=``,t=0;do{t=this.data[this.pos++];for(let n=t;--n>=0;e+=String.fromCharCode(this.data[this.pos++]));}while(t!==0);return e}readSubBlocksBin(){let e=this.data[this.pos],t=0;for(let n=0;e!==0;n+=e+1,e=this.data[this.pos+n])t+=e;let n=new Uint8Array(t);e=this.data[this.pos++];for(let t=0;e!==0;e=this.data[this.pos++])for(let r=e;--r>=0;n[t++]=this.data[this.pos++]);return n}skipSubBlocks(){for(;this.data[this.pos]!==0;this.pos+=this.data[this.pos]+1);this.pos++}},Q;
1(function(e){e[e.Replace=0]=`Replace`,e[e.Combine=1]=`Combine`,e[e.RestoreBackground=2]=`RestoreBackground`,e[e.RestorePrevious=3]=`RestorePrevious`,e[e.UndefinedA=4]=`UndefinedA`,e[e.UndefinedB=5]=`UndefinedB`,e[e.UndefinedC=6]=`UndefinedC`,e[e.UndefinedD=7]=`UndefinedD`})(Q||={});var eo;(function(e){e[e.Extension=33]=`Extension`,e[e.ApplicationExtension=255]=`ApplicationExtension`,e[e.GraphicsControlExtension=249]=`GraphicsControlExtension`,e[e.PlainTextExtension=1]=`PlainTextExtension`,e[e.CommentExtension=254]=`CommentExtension`,e[e.Image=44]=`Image`,e[e.EndOfFile=59]=`EndOfFile`})(eo||={});var $={x:0,y:0},to=0,no=.5,ro=0,io=0,ao=0;function oo(e,t){let n=[];for(let r=0;r<t;r++)n.push({r:e.data[e.pos],g:e.data[e.pos+1],b:e.data[e.pos+2]}),e.pos+=3;return n}function so(e,t,n,r){switch(e.nextByte()){case eo.GraphicsControlExtension:{let i=t.frames[n(!1)];e.pos++;let a=e.nextByte();i.GCreserved=(a&224)>>>5,i.disposalMethod=(a&28)>>>2,i.userInputDelayFlag=(a&2)==2;let o=(a&1)==1;i.delayTime=e.nextTwoBytes()*10;let s=e.nextByte();o&&r(s),e.pos++;break}case eo.ApplicationExtension:{e.pos++;let n={identifier:e.getString(8),authenticationCode:e.getString(3),data:e.readSubBlocksBin()};t.applicationExtensions.push(n);break}case eo.CommentExtension:t.comments.push([n(!1),e.readSubBlocks()]);break;case eo.PlainTextExtension:if(t.globalColorTable.length===0)throw EvalError(`plain text extension without global color table`);e.pos++,t.frames[n(!1)].plainTextData={left:e.nextTwoBytes(),top:e.nextTwoBytes(),width:e.nextTwoBytes(),height:e.nextTwoBytes(),charSize:{width:e.nextTwoBytes(),height:e.nextTwoBytes()},foregroundColor:e.nextByte(),backgroundColor:e.nextByte(),text:e.readSubBlocks()};break;default:e.skipSubBlocks()}}async function co(e,t,n,r,i,a){let o=t.frames[r(!0)];o.left=e.nextTwoBytes(),o.top=e.nextTwoBytes(),o.width=e.nextTwoBytes(),o.height=e.nextTwoBytes();let s=e.nextByte(),c=(s&128)==128,l=(s&64)==64;o.sortFlag=(s&32)==32,o.reserved=(s&24)>>>3;let u=1<<(s&7)+1;c&&(o.localColorTable=oo(e,u));let d=e=>{let{r,g:a,b:s}=(c?o.localColorTable:t.globalColorTable)[e];return e===i(null)?{r,g:a,b:s,a:n?~~((r+a+s)/3):0}:{r,g:a,b:s,a:255}},f=(()=>{try{return new ImageData(o.width,o.height,{colorSpace:`srgb`})}catch(e){if(e instanceof DOMException&&e.name===`IndexSizeError`)return null;throw e}})();if(f==null)throw EvalError(`GIF frame size is to large`);let p=e.nextByte(),m=e.readSubBlocksBin(),h=1<<p,g=(e,t)=>{let n=e>>>3,r=e&7;return(m[n]+(m[n+1]<<8)+(m[n+2]<<16)&(1<<t)-1<<r)>>>r};if(l){for(let n=0,i=p+1,s=0,c=[[0]],l=0;l<4;l++){if(Za[l]<o.height){let e=0,t=0,r=!1;for(;!r;){let a=n;if(n=g(s,i),s+=i+1,n===h){i=p+1,c.length=h+2;for(let e=0;e<c.length;e++)c[e]=e<h?[e]:[]}else{n>=c.length?c.push(c[a].concat(c[a][0])):a!==h&&c.push(c[a].concat(c[n][0]));for(let r of c[n]){let{r:n,g:i,b:a,a:s}=d(r);f.data.set([n,i,a,s],Za[l]*o.width+Qa[l]*t+e%(o.width*4)),e+=4}c.length===1<<i&&i<12&&i++}e===o.width*4*(t+1)&&(t++,Za[l]+Qa[l]*t>=o.height&&(r=!0))}}a?.(e.pos/(e.data.length-1),r(!1)+1,f,{x:o.left,y:o.top},{width:t.width,height:t.height})}o.image=f,o.bitmap=await createImageBitmap(f)}else{let n=0,i=p+1,s=0,c=-4,l=!1,u=[[0]];for(;!l;){let e=n;if(n=g(s,i),s+=i,n===h){i=p+1,u.length=h+2;for(let e=0;e<u.length;e++)u[e]=e<h?[e]:[]}else{if(n===h+1){l=!0;break}n>=u.length?u.push(u[e].concat(u[e][0])):e!==h&&u.push(u[e].concat(u[n][0]));for(let e of u[n]){let{r:t,g:n,b:r,a:i}=d(e);f.data.set([t,n,r,i],c+=4)}u.length>=1<<i&&i<12&&i++}}o.image=f,o.bitmap=await createImageBitmap(f),a?.((e.pos+1)/e.data.length,r(!1)+1,o.image,{x:o.left,y:o.top},{width:t.width,height:t.height})}}async function lo(e,t,n,r,i,a){switch(e.nextByte()){case eo.EndOfFile:return!0;case eo.Image:await co(e,t,n,r,i,a);break;case eo.Extension:so(e,t,r,i);break;default:throw EvalError(`undefined block found`)}return!1}function uo(e){for(let t of e.applicationExtensions)if(t.identifier+t.authenticationCode===`NETSCAPE2.0`)return t.data[1]+(t.data[2]<<8);return NaN}async function fo(e,t,n){n||=!1;let r=await fetch(e);if(!r.ok&&r.status===404)throw EvalError(`file not found`);let i=await r.arrayBuffer(),a={width:0,height:0,totalTime:0,colorRes:0,pixelAspectRatio:0,frames:[],sortFlag:!1,globalColorTable:[],backgroundImage:new ImageData(1,1,{colorSpace:`srgb`}),comments:[],applicationExtensions:[]},o=new $a(new Uint8ClampedArray(i));if(o.getString(6)!==`GIF89a`)throw Error(`not a supported GIF file`);a.width=o.nextTwoBytes(),a.height=o.nextTwoBytes();let s=o.nextByte(),c=(s&128)==128;a.colorRes=(s&112)>>>4,a.sortFlag=(s&8)==8;let l=1<<(s&7)+1,u=o.nextByte();a.pixelAspectRatio=o.nextByte(),a.pixelAspectRatio!==0&&(a.pixelAspectRatio=(a.pixelAspectRatio+15)/64),c&&(a.globalColorTable=oo(o,l));let d=(()=>{try{return new ImageData(a.width,a.height,{colorSpace:`srgb`})}catch(e){if(e instanceof DOMException&&e.name===`IndexSizeError`)return null;throw e}})();if(d==null)throw Error(`GIF frame size is to large`);let{r:f,g:p,b:m}=a.globalColorTable[u];d.data.set(c?[f,p,m,255]:[0,0,0,0]);for(let e=4;e<d.data.length;e*=2)d.data.copyWithin(e,0,e);a.backgroundImage=d;let h=-1,g=!0,_=-1,v=e=>(e&&(g=!0),h),y=e=>(e!=null&&(_=e),_);try{do g&&=(a.frames.push({left:0,top:0,width:0,height:0,disposalMethod:Q.Replace,image:new ImageData(1,1,{colorSpace:`srgb`}
1),plainTextData:null,userInputDelayFlag:!1,delayTime:0,sortFlag:!1,localColorTable:[],reserved:0,GCreserved:0}),h++,_=-1,!1);while(!await lo(o,a,n,v,y,t));a.frames.length--;for(let e of a.frames){if(e.userInputDelayFlag&&e.delayTime===0){a.totalTime=1/0;break}a.totalTime+=e.delayTime}return a}catch(e){throw e instanceof EvalError?Error(`error while parsing frame ${h} "${e.message}"`):e}}function po(e){let{context:t,radius:n,particle:r,delta:i}=e,a=r.image;if(!a?.gifData||!a.gif)return;let o=new OffscreenCanvas(a.gifData.width,a.gifData.height),s=o.getContext(`2d`);if(!s)throw Error(`could not create offscreen canvas context`);s.imageSmoothingQuality=`low`,s.imageSmoothingEnabled=!1,s.clearRect($.x,$.y,o.width,o.height),r.gifLoopCount===void 0&&(r.gifLoopCount=a.gifLoopCount??ao);let c=r.gifFrame??to,l={x:-a.gifData.width*no,y:-a.gifData.height*no},u=a.gifData.frames[c];if(r.gifTime===void 0&&(r.gifTime=ro),u.bitmap){switch(t.scale(n/a.gifData.width,n/a.gifData.height),u.disposalMethod){case Q.UndefinedA:case Q.UndefinedB:case Q.UndefinedC:case Q.UndefinedD:case Q.Replace:s.drawImage(u.bitmap,u.left,u.top),t.drawImage(o,l.x,l.y),s.clearRect($.x,$.y,o.width,o.height);break;case Q.Combine:s.drawImage(u.bitmap,u.left,u.top),t.drawImage(o,l.x,l.y);break;
1case Q.RestoreBackground:s.drawImage(u.bitmap,u.left,u.top),t.drawImage(o,l.x,l.y),s.clearRect($.x,$.y,o.width,o.height),a.gifData.globalColorTable.length?s.putImageData(a.gifData.backgroundImage,l.x,l.y):s.putImageData(a.gifData.frames[io].image,l.x+u.left,l.y+u.top);break;case Q.RestorePrevious:{let e=s.getImageData($.x,$.y,o.width,o.height);s.drawImage(u.bitmap,u.left,u.top),t.drawImage(o,l.x,l.y),s.clearRect($.x,$.y,o.width,o.height),s.putImageData(e,$.x,$.y)}}if(r.gifTime+=i.value,r.gifTime>u.delayTime){if(r.gifTime-=u.delayTime,++c>=a.gifData.frames.length){if(--r.gifLoopCount<=ao)return;c=io,s.clearRect($.x,$.y,o.width,o.height)}r.gifFrame=c}t.scale(a.gifData.width/n,a.gifData.height/n)}}async function mo(e){if(e.type!==`gif`){await Ja(e);return}e.loading=!0;try{e.gifData=await fo(e.source),e.gifLoopCount=uo(e.gifData)??ao,e.gifLoopCount||=1/0}catch{e.error=!0}e.loading=!1}var ho=2,go=1,_o=12,vo=1,yo=class{constructor(e){this.validTypes=[`image`,`images`],this.loadImageShape=async e=>{if(!this._engine.loadImage)throw Error(`${O} image shape not initialized`);await this._engine.loadImage({gif:e.gif,name:e.name,replaceColor:e.replaceColor??!1,src:e.src})},this._engine=e}addImage(e){this._engine.images||(this._engine.images=[]),this._engine.images.push(e)}draw(e){let{context:t,radius:n,particle:r,opacity:i}=e,a=r.image,o=a?.element;if(a){if(t.globalAlpha=i,a.gif&&a.gifData)po(e);else if(o){let e=a.ratio,r={x:-n,y:-n},i=n*ho;t.drawImage(o,r.x,r.y,i,i/e)}t.globalAlpha=go}}getSidesCount(){return _o}async init(e){let t=e.actualOptions;if(t.preload&&this._engine.loadImage)for(let e of t.preload)await this._engine.loadImage(e)}loadShape(e){if(e.shape!==`image`&&e.shape!==`images`)return;this._engine.images||(this._engine.images=[]);let t=e.shapeData;t&&(this._engine.images.find(e=>e.name===t.name||e.source===t.src)||this.loadImageShape(t).then(()=>{this.loadShape(e)}))}particleInit(e,t){if(t.shape!==`image`&&t.shape!==`images`)return;this._engine.images||(this._engine.images=[]);let n=this._engine.images,r=t.shapeData;if(!r)return;let i=t.getFillColor(),a=n.find(e=>e.name===r.name||e.source===r.src);if(!a)return;let o=r.replaceColor??a.replaceColor;if(a.loading){setTimeout(()=>{this.particleInit(e,t)});return}(async()=>{let e;e=a.svgData&&i?await Xa(a,r,i,t):{color:i,data:a,element:a.element,gif:a.gif,gifData:a.gifData,gifLoopCount:a.gifLoopCount,loaded:!0,ratio:r.width&&r.height?r.width/r.height:a.ratio??vo,replaceColor:o,source:r.src},e.ratio||(e.ratio=1);let n=r.fill??t.shapeFill,s=r.close??t.shapeClose,c={image:e,fill:n,close:s};t.image=c.image,t.shapeFill=c.fill,t.shapeClose=c.close})()}},bo=class{constructor(){this.src=``,this.gif=!1}load(e){I(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))}},xo=class{constructor(e){this.id=`imagePreloader`,this._engine=e}async getPlugin(){return await Promise.resolve(),{}}loadOptions(e,t){if(!t?.preload)return;e.preload||=[];let n=e.preload;for(let e of t.preload){let t=n.find(t=>t.name===e.name||t.src===e.src);if(t)t.load(e);else{let t=new bo;t.load(e),n.push(t)}}}needsPlugin(){return!0}},So=3;function Co(e){e.loadImage||=async t=>{if(!t.name&&!t.src)throw Error(`${O} no image source provided`);if(e.images||=[],!e.images.find(e=>e.name===t.name||e.source===t.src))try{let n={gif:t.gif??!1,name:t.name??t.src,source:t.src,type:t.src.substring(t.src.length-So),error:!1,loading:!0,replaceColor:t.replaceColor,ratio:t.width&&t.height?t.width/t.height:void 0};e.images.push(n);let r;r=t.gif?mo:t.replaceColor?Ya:Ja,await r(n)}catch{throw Error(`${O} ${t.name??t.src} not found`)}}}async function wo(e,t=!0){e.checkVersion(`3.9.1`),Co(e);let n=new xo(e);await e.addPlugin(n,t),await e.addShape(new yo(e),t)}var To=class extends Un{constructor(){super(),this.sync=!1}load(e){I(e)||(super.load(e),e.sync!==void 0&&(this.sync=e.sync))}},Eo=class extends Un{constructor(){super(),this.sync=!1}load(e){I(e)||(super.load(e),e.sync!==void 0&&(this.sync=e.sync))}},Do=class{constructor(){this.count=0,this.delay=new To,this.duration=new Eo}load(e){I(e)||(e.count!==void 0&&(this.count=e.count),this.delay.load(e.delay),this.duration.load(e.duration))}},Oo=0,ko=-1,Ao=0,jo=0;
1function Mo(e,t,n){if(!e.life)return;let r=e.life,i=!1;if(e.spawning){if(r.delayTime+=t.value,r.delayTime>=e.life.delay)i=!0,e.spawning=!1,r.delayTime=Oo,r.time=Oo;else return}if(r.duration===ko||e.spawning||(i?r.time=Oo:r.time+=t.value,r.time<r.duration))return;if(r.time=Oo,e.life.count>Ao&&e.life.count--,e.life.count===Ao){e.destroy();return}let a=B(jo,n.width),o=B(jo,n.width);e.position.x=R(a),e.position.y=R(o),e.spawning=!0,r.delayTime=Oo,r.time=Oo,e.reset();let s=e.options.life;s&&(r.delay=z(s.delay.value)*A,r.duration=z(s.duration.value)*A)}var No=0,Po=1,Fo=-1,Io=class{constructor(e){this.container=e}init(e){let t=this.container,n=e.options.life;n&&(e.life={delay:t.retina.reduceFactor?z(n.delay.value)*(n.delay.sync?Po:L())/t.retina.reduceFactor*A:No,delayTime:No,duration:t.retina.reduceFactor?z(n.duration.value)*(n.duration.sync?Po:L())/t.retina.reduceFactor*A:No,time:No,count:n.count},e.life.duration<=No&&(e.life.duration=Fo),e.life.count<=No&&(e.life.count=Fo),e.life&&(e.spawning=e.life.delay>No))}isEnabled(e){return!e.destroyed}loadOptions(e,...t){e.life||=new Do;for(let n of t)e.life.load(n?.life)}update(e,t){this.isEnabled(e)&&e.life&&Mo(e,t,this.container.canvas.size)}};async function Lo(e,t=!0){e.checkVersion(`3.9.1`),await e.addParticleUpdater(`life`,async e=>Promise.resolve(new Io(e)),t)}var Ro=class{constructor(){this.factor=4,this.value=!0}load(e){I(e)||(e.factor!==void 0&&(this.factor=e.factor),e.value!==void 0&&(this.value=e.value))}},zo=class{constructor(){this.disable=!0,this.reduce=new Ro}load(e){I(e)||(e.disable!==void 0&&(this.disable=e.disable),this.reduce.load(e.reduce))}},Bo=1,Vo=1,Ho=0,Uo=1,Wo=class{constructor(e,t){this._handleMotionChange=e=>{let t=this._container,n=t.actualOptions.motion;n&&(e.matches?n.disable?t.retina.reduceFactor=Ho:t.retina.reduceFactor=n.reduce.value?Uo/n.reduce.factor:Bo:t.retina.reduceFactor=Vo)},this._container=e,this._engine=t}async init(){let e=this._container,t=e.actualOptions.motion;if(!(t&&(t.disable||t.reduce.value))){e.retina.reduceFactor=1;return}let n=gt(`(prefers-reduced-motion: reduce)`);if(!n){e.retina.reduceFactor=Bo;return}this._handleMotionChange(n);let r=()=>{(async()=>{this._handleMotionChange(n);try{await e.refresh()}catch{}})()};n.addEventListener===void 0?n.addListener!==void 0&&n.addListener(r):n.addEventListener(`change`,r),await Promise.resolve()}},Go=class{constructor(e){this.id=`motion`,this._engine=e}getPlugin(e){return Promise.resolve(new Wo(e,this._engine))}loadOptions(e,t){if(!this.needsPlugin())return;let n=e.motion;n?.load||(e.motion=n=new zo),n.load(t?.motion)}needsPlugin(){return!0}};async function Ko(e,t=!0){e.checkVersion(`3.9.1`),await e.addPlugin(new Go(e),t)}var qo=180,Jo={x:0,y:0},Yo=2;function Xo(e,t,n){let{context:r}=e,i=n.count.numerator*n.count.denominator,a=n.count.numerator/n.count.denominator,o=qo*(a-Yo)/a,s=Math.PI-et(o);if(r){r.beginPath(),r.translate(t.x,t.y),r.moveTo(Jo.x,Jo.y);for(let e=0;e<i;e++)r.lineTo(n.length,Jo.y),r.translate(n.length,Jo.y),r.rotate(s)}}var Zo=5,Qo=class{draw(e){let{particle:t,radius:n}=e;Xo(e,this.getCenter(t,n),this.getSidesData(t,n))}getSidesCount(e){let t=e.shapeData;return Math.round(z(t?.sides??Zo))}},$o=3.5,es=2.66,ts=3,ns=class extends Qo{constructor(){super(...arguments),this.validTypes=[`polygon`]}getCenter(e,t){return{x:-t/(e.sides/$o),y:-t/(es/$o)}}getSidesData(e,t){let n=e.sides;return{count:{denominator:1,numerator:n},length:t*es/(n/ts)}}},rs=1.66,is=3,as=2,os=class extends Qo{constructor(){super(...arguments),this.validTypes=[`triangle`]}getCenter(e,t){return{x:-t,y:t/rs}}getSidesCount(){return is}getSidesData(e,t){return{count:{denominator:2,numerator:3},length:t*as}}};async function ss(e,t=!0){e.checkVersion(`3.9.1`),await e.addShape(new ns,t)}async function cs(e,t=!0){e.checkVersion(`3.9.1`),await e.addShape(new os,t)}async function ls(e,t=!0){e.checkVersion(`3.9.1`),await ss(e,t),await cs(e,t)}var us;(function(e){e.both=`both`,e.horizontal=`horizontal`,e.vertical=`vertical`})(us||={});var ds=Math.PI*2,fs=360;function ps(e,t){let n=t.options.roll;if(!n?.enable){t.roll={enable:!1,horizontal:!1,vertical:!1,angle:0,speed:0};return}if(t.roll={enable:n.enable,horizontal:n.mode===us.horizontal||n.mode===us.both,vertical:n.mode===us.vertical||n.mode===us.both,angle:L()*ds,speed:z(n.speed)/fs},n.backColor)t.backColor=Bt(e,n.backColor);else if(n.darken.enable&&n.enlighten.enable){let e=L()>=.5?It.darken:It.enlighten;t.roll.alter={type:e,value:z(e===It.darken?n.darken.value:n.enlighten.value)}}else n.darken.enable?t.roll.alter={type:It.darken,value:z(n.darken.value)}:n.enlighten.enable&&(t.roll.alter={type:It.enlighten,value:z(n.enlighten.value)})}function ms(e,t){let n=e.options.roll,r=e.roll;if(!r||!n?.enable)return;let i=r.speed*t.factor,a=ds;r.angle+=i,r.angle>a&&(r.angle-=a)}var hs=class{constructor(){this.enable=!1,this.value=0}load(e){I(e)||(e.enable!==void 0&&(this.enable=e.enable),e.value!==void 0&&(this.value=B(e.value)))}},gs=class{constructor(){this.darken=new hs,this.enable=!1,this.enlighten=new hs,this.mode=us.vertical,this.speed=25}load(e){I(e)||(e.backColor!==void 0&&(this.backColor=hn.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)))}},_s=class{constructor(e){this._engine=e}getTransformValues(e){let t=e.roll?.enable&&e.roll,n=t&&t.horizontal,r=t&&t.vertical;return{a:n?Math.cos(t.angle):void 0,d:r?Math.sin(t.angle):void 0}}init(e){ps(this._engine,e)}isEnabled(e){let t=e.options.roll;return!e.destroyed&&!e.spawning&&!!t?.enable}loadOptions(e,...t){e.roll||=new gs;for(let n of t)e.roll.load(n?.roll)}update(e,t){this.isEnabled(e)&&ms(e,t)}};async function vs(e,t=!0){e.checkVersion(`3.9.1`),await e.addParticleUpdater(`roll`,()=>Promise.resolve(new _s(e)),t)}var ys=class{constructor(){this.enable=!1,this.speed=0,this.decay=0,this.sync=!1}load(e){I(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))}},bs=class extends Un{constructor(){super(),this.animation=new ys,this.direction=X.clockwise,this.path=!1,this.value=0}load(e){I(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))}},xs=2,Ss=Math.PI*xs,Cs=1,ws=360,Ts=class{constructor(e){this.container=e}init(e){let t=e.options.rotate;if(!t)return;e.rotate={enable:t.animation.enable,value:et(z(t.value)),min:0,max:Ss},e.pathRotation=t.path;let n=t.direction;switch(n===X.random&&(n=Math.floor(L()*xs)>0?X.counterClockwise:X.clockwise),n){case X.counterClockwise:case`counterClockwise`:e.rotate.status=V.decreasing;break;case X.clockwise:e.rotate.status=V.increasing}let r=t.animation;r.enable&&(e.rotate.decay=Cs-z(r.decay),e.rotate.velocity=z(r.speed)/ws*this.container.retina.reduceFactor,r.sync||(e.rotate.velocity
1*=L())),e.rotation=e.rotate.value}isEnabled(e){let t=e.options.rotate;return t?!e.destroyed&&!e.spawning&&(!!t.value||t.animation.enable||t.path):!1}loadOptions(e,...t){e.rotate||=new bs;for(let n of t)e.rotate.load(n?.rotate)}update(e,t){this.isEnabled(e)&&(e.isRotating=!!e.rotate,e.rotate&&(Mt(e,e.rotate,!1,ct.none,t),e.rotation=e.rotate.value))}};async function Es(e,t=!0){e.checkVersion(`3.9.1`),await e.addParticleUpdater(`rotate`,e=>Promise.resolve(new Ts(e)),t)}var Ds=Math.sqrt(2),Os=2;function ks(e){let{context:t,radius:n}=e,r=n/Ds,i=r*Os;t.rect(-r,-r,i,i)}var As=4,js=class{constructor(){this.validTypes=[`edge`,`square`]}draw(e){ks(e)}getSidesCount(){return As}};async function Ms(e,t=!0){e.checkVersion(`3.9.1`),await e.addShape(new js,t)}var Ns=2,Ps={x:0,y:0};function Fs(e){let{context:t,particle:n,radius:r}=e,i=n.sides,a=n.starInset??Ns;t.moveTo(Ps.x,Ps.y-r);for(let e=0;e<i;e++)t.rotate(Math.PI/i),t.lineTo(Ps.x,Ps.y-r*a),t.rotate(Math.PI/i),t.lineTo(Ps.x,Ps.y-r)}var Is=2,Ls=5,Rs=class{constructor(){this.validTypes=[`star`]}draw(e){Fs(e)}getSidesCount(e){let t=e.shapeData;return Math.round(z(t?.sides??Ls))}particleInit(e,t){let n=t.shapeData;t.starInset=z(n?.inset??Is)}};async function zs(e,t=!0){e.checkVersion(`3.9.1`),await e.addShape(new Rs,t)}var Bs;(function(e){e.clockwise=`clockwise`,e.counterClockwise=`counter-clockwise`,e.random=`random`})(Bs||={});var Vs=class{constructor(){this.enable=!1,this.speed=0,this.decay=0,this.sync=!1}load(e){I(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))}},Hs=class extends Un{constructor(){super(),this.animation=new Vs,this.direction=Bs.clockwise,this.enable=!1,this.value=0}load(e){super.load(e),!I(e)&&(this.animation.load(e.animation),e.direction!==void 0&&(this.direction=e.direction),e.enable!==void 0&&(this.enable=e.enable))}},Us=1,Ws=2,Gs=Math.PI*Ws,Ks=360,qs=class{constructor(e){this.container=e}getTransformValues(e){let t=e.tilt?.enable&&e.tilt;return{b:t?Math.cos(t.value)*t.cosDirection:void 0,c:t?Math.sin(t.value)*t.sinDirection:void 0}}init(e){let t=e.options.tilt;if(!t)return;e.tilt={enable:t.enable,value:et(z(t.value)),sinDirection:L()>=.5?Us:-1,cosDirection:L()>=.5?Us:-1,min:0,max:Gs};let n=t.direction;switch(n===Bs.random&&(n=Math.floor(L()*Ws)>0?Bs.counterClockwise:Bs.clockwise),n){case Bs.counterClockwise:case`counterClockwise`:e.tilt.status=V.decreasing;break;case Bs.clockwise:e.tilt.status=V.increasing}let r=e.options.tilt?.animation;r?.enable&&(e.tilt.decay=Us-z(r.decay),e.tilt.velocity=z(r.speed)/Ks*this.container.retina.reduceFactor,r.sync||(e.tilt.velocity*=L()))}isEnabled(e){let t=e.options.tilt?.animation;return!e.destroyed&&!e.spawning&&!!t?.enable}loadOptions(e,...t){e.tilt||=new Hs;for(let n of t)e.tilt.load(n?.tilt)}async update(e,t){this.isEnabled(e)&&e.tilt&&(Mt(e,e.tilt,!1,ct.none,t),await Promise.resolve())}};async function Js(e,t=!0){e.checkVersion(`3.9.1`),await e.addParticleUpdater(`tilt`,e=>Promise.resolve(new qs(e)),t)}var Ys=class{constructor(){this.angle=50,this.move=10}load(e){I(e)||(e.angle!==void 0&&(this.angle=B(e.angle)),e.move!==void 0&&(this.move=B(e.move)))}},Xs=class{constructor(){this.distance=5,this.enable=!1,this.speed=new Ys}load(e){if(!I(e)&&(e.distance!==void 0&&(this.distance=B(e.distance)),e.enable!==void 0&&(this.enable=e.enable),e.speed!==void 0)){if(P(e.speed))this.speed.load({angle:e.speed});else{let t=e.speed;t.min===void 0?this.speed.load(e.speed):this.speed.load({angle:t})}}}},Zs=0,Qs=Math.PI*2,$s=60;function ec(e,t){let{wobble:n}=e.options,{container:r,wobble:i}=e;if(!n?.enable||!i)return;let a=r.retina.reduceFactor,o=i.angleSpeed*t.factor*a,s=i.moveSpeed*t.factor*a*(e.retina.wobbleDistance??Zs)/(A/$s),c=Qs,{position:l}=e;i.angle+=o,i.angle>c&&(i.angle-=c),l.x+=s*Math.cos(i.angle),l.y+=s*Math.abs(Math.sin(i.angle))}var tc=Math.PI*2,nc=360,rc=10,ic=0,ac=class{constructor(e){this.container=e}init(e){let t=e.options.wobble;e.wobble=t?.enable?{angle:L()*tc,angleSpeed:z(t.speed.angle)/nc,moveSpeed:z(t.speed.move)/rc}:{angle:0,angleSpeed:0,moveSpeed:0},e.retina.wobbleDistance=z(t?.distance??ic)*this.container.retina.pixelRatio}isEnabled(e){return!e.destroyed&&!e.spawning&&!!e.options.wobble?.enable}loadOptions(e,...t){e.wobble||=new Xs;for(let n of t)e.wobble.load(n?.wobble)}update(e,t){this.isEnabled(e)&&ec(e,t)}};async function oc(e,t=!0){e.checkVersion(`3.9.1`),await e.addParticleUpdater(`wobble`,e=>Promise.resolve(new ac(e)),t)}var sc=9.81,cc=5,lc=3,uc=1,dc=0,fc=0,pc=!1,mc=!1,hc=new Map;async function gc(e){if(!pc){if(mc)return new Promise(e=>{let t=setInterval(()=>{pc&&(clearInterval(t),e())},100)});mc=!0,e.checkVersion(`3.9.1`),await mi(e,!1),await Ko(e,!1),await Na(e,!1),await Ua(e,!1),await wo(e,!1),await ls(e,!1),await Ms(e,!1),await zs(e,!1),await Ra(e,!1),await Es(e,!1),await Lo(e,!1),await vs(e,!1),await Js(e,!1),await oc(e,!1),await Ea(e),mc=!1,pc=!0}}async function _c(e){let t=new hi;t.load(e.options);
1let n,r=t.ticks*A/(3.6*A*120);if(hc.has(e.id)&&(n=hc.get(e.id),n&&!n.destroyed)){let e=n;if(e.addEmitter){await e.addEmitter({startCount:t.count,position:t.position,size:{width:0,height:0},rate:{delay:0,quantity:0},life:{duration:.1,count:1},particles:{color:{value:t.colors},shape:{type:t.shapes,options:t.shapeOptions},life:{count:1},opacity:{value:{min:0,max:1},animation:{enable:!0,sync:!0,speed:r,startValue:`max`,destroy:`min`}},size:{value:cc*t.scalar},move:{angle:{value:t.spread,offset:0},drift:{min:-t.drift,max:t.drift},gravity:{acceleration:t.gravity*sc},speed:t.startVelocity*lc,decay:uc-t.decay,direction:-t.angle},rotate:{value:t.flat?dc:{min:0,max:360},direction:`random`,animation:{enable:!t.flat,speed:60}},tilt:{direction:`random`,enable:!t.flat,value:t.flat?fc:{min:0,max:360},animation:{enable:!0,speed:60}},roll:{darken:{enable:!0,value:25},enable:!t.flat,speed:{min:15,max:25}},wobble:{distance:30,enable:!t.flat,speed:{min:-15,max:15}}}});return}}let i={fullScreen:{enable:!e.canvas,zIndex:t.zIndex},fpsLimit:120,particles:{number:{value:0},color:{value:t.colors},shape:{type:t.shapes,options:t.shapeOptions},opacity:{value:{min:0,max:1},animation:{enable:!0,sync:!0,speed:r,startValue:`max`,destroy:`min`}},size:{value:cc*t.scalar},links:{enable:!1},life:{count:1},move:{angle:{value:t.spread,offset:0},drift:{min:-t.drift,max:t.drift},enable:!0,gravity:{enable:!0,acceleration:t.gravity*sc},speed:t.startVelocity*lc,decay:uc-t.decay,direction:-t.angle,random:!0,straight:!1,outModes:{default:`none`,bottom:`destroy`}},rotate:{value:t.flat?dc:{min:0,max:360},direction:`random`,animation:{enable:!t.flat,speed:60}},tilt:{direction:`random`,enable:!t.flat,value:t.flat?fc:{min:0,max:360},animation:{enable:!0,speed:60}}
1,roll:{darken:{enable:!0,value:25},enable:!t.flat,speed:{min:15,max:25}},wobble:{distance:30,enable:!t.flat,speed:{min:-15,max:15}}},detectRetina:!0,motion:{disable:t.disableForReducedMotion},emitters:{name:`confetti`,startCount:t.count,position:t.position,size:{width:0,height:0},rate:{delay:0,quantity:0},life:{duration:.1,count:1}}};return n=await qr.load({id:e.id,element:e.canvas,options:i}),hc.set(e.id,n),n}async function vc(e,t){await gc(qr);let n,r;return N(e)?(r=e,n=t??{}):(r=`confetti`,n=e),_c({id:r,options:n})}vc.create=async(e,t)=>{if(!e)return vc;await gc(qr);let n=e.getAttribute(`id`)??`confetti`;return e.setAttribute(`id`,n),async(r,i)=>{let a,o;return N(r)?(o=r,a=i??t):(o=n,a=r),_c({id:o,canvas:e,options:a})}},vc.init=async()=>{await gc(qr)},vc.version=`3.9.1`,mt()||(window.confetti=vc);var yc=e(t()),bc=e(ve()),xc=new Set([`$$slots`,`$$events`,`$$legacy`]),Sc=g(`<svg><path fill="currentColor" d="M23.994 6.124a9.2 9.2 0 0 0-.24-2.19c-.317-1.31-1.062-2.31-2.18-3.043a5 5 0 0 0-1.877-.726a10.5 10.5 0 0 0-1.564-.15c-.04-.003-.083-.01-.124-.013H5.986q-.227.014-.455.026c-.747.043-1.49.123-2.193.4c-1.336.53-2.3 1.452-2.865 2.78c-.192.448-.292.925-.363 1.408a11 11 0 0 0-.1 1.18c0 .032-.007.062-.01.
1093v12.223l.027.424c.05.815.154 1.624.497 2.373c.65 1.42 1.738 2.353 3.234 2.801c.42.127.856.187 1.293.228c.555.053 1.11.06 1.667.06h11.03a13 13 0 0 0 1.57-.1c.822-.106 1.596-.35 2.295-.81a5.05 5.05 0 0 0 1.88-2.207c.186-.42.293-.87.37-1.324c.113-.675.138-1.358.137-2.04c-.002-3.8 0-7.595-.003-11.393zm-6.423 3.99v5.712c0 .417-.058.827-.244 1.206c-.29.59-.76.962-1.388 1.14q-.524.15-1.07.173c-.95.045-1.773-.6-1.943-1.536a1.88 1.88 0 0 1 1.038-2.022c.323-.16.67-.25 1.018-.324c.378-.082.758-.153 1.134-.24c.274-.063.457-.23.51-.516a1 1 0 0 0 .02-.193q0-2.723-.002-5.443a.7.7 0 0 0-.026-.185c-.04-.15-.15-.243-.304-.234c-.16.01-.318.035-.475.066q-1.14.226-2.28.456l-2.325.47l-1.374.278l-.048.013c-.277.077-.377.203-.39.49q-.002.063 0 .13c-.002 2.602 0 5.204-.003 7.805c0 .42-.047.836-.215 1.227c-.278.64-.77 1.04-1.434 1.233q-.526.152-1.075.172c-.96.036-1.755-.6-1.92-1.544c-.14-.812.23-1.685 1.154-2.075c.357-.15.73-.232 1.108-.31c.287-.06.575-.116.86-.177q.574-.126.6-.714v-.15l.002-8.882c0-.123.013-.25.042-.37c.07-.285.273-.448.546-.518c.255-.066.515-.112.774-.165q1.1-.224 2.2-.444l2.27-.46l2.01-.403c.22-.043.442-.088.663-.106c.31-.025.523.17.554.482q.012.11.012.223q.003 2.866 0 5.732z"></path></svg>`);function Cc(e,t){let n=ae(t,xc);var r=Sc();se(r,()=>({viewBox:`0 0 24 24`,width:`1.2em`,height:`1.2em`,...n})),o(e,r)}var wc=new Set([`$$slots`,`$$events`,`$$legacy`]),Tc=g(`<svg><path fill="currentColor" d="M12 0C5.4 0 0 5.4 0 12s5.4 12 12 12s12-5.4 12-12S18.66 0 12 0m5.521 17.34c-.24.359-.66.48-1.021.24c-2.82-1.74-6.36-2.101-10.561-1.141c-.418.122-.779-.179-.899-.539c-.12-.421.18-.78.54-.9c4.56-1.021 8.52-.6 11.64 1.32c.42.18.479.659.301 1.02m1.44-3.3c-.301.42-.841.6-1.262.3c-3.239-1.98-8.159-2.58-11.939-1.38c-.479.12-1.02-.12-1.14-.6s.12-1.021.6-1.141C9.6 9.9 15 10.561 18.72 12.84c.361.181.54.78.241 1.2m.12-3.36C15.24 8.4 8.82 8.16 5.16 9.301c-.6.179-1.2-.181-1.38-.721c-.18-.601.18-1.2.72-1.381c4.26-1.26 11.28-1.02 15.721 1.621c.539.3.719 1.02.419 1.56c-.299.421-1.02.599-1.559.3"></path></svg>`);function Ec(e,t){let n=ae(t,wc);var r=Tc();se(r,()=>({viewBox:`0 0 24 24`,width:`1.2em`,height:`1.2em`,...n})),o(e,r)}var Dc=new Set([`$$slots`,`$$events`,`$$legacy`]),Oc=g(`<svg><path fill="currentColor" d="M12.012 3.992L8.008 7.996L4.004 3.992L0 7.996L4.004 12l4.004-4.004L12.012 12l-4.004 4.004l4.004 4.004l4.004-4.004L12.012 12l4.004-4.004zm4.03 4.004l3.979-3.979L24 7.996l-3.979 3.979z"></path></svg>`);function kc(e,t){let n=ae(t,Dc);var r=Oc();se(r,()=>({viewBox:`0 0 24 24`,width:`1.2em`,height:`1.2em`,...n})),o(e,r)}var Ac=new Set([`$$slots`,`$$events`,`$$legacy`]),jc=g(`<svg><path fill="currentColor" d="M23.498 6.186a3.02 3.02 0 0 0-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.02 3.02 0 0 0 .502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.02 3.02 0 0 0 2.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.02 3.02 0 0 0 2.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814M9.545 15.568V8.432L15.818 12z"></path></svg>`);function Mc(e,t){let n=ae(t,Ac);var r=jc();se(r,()=>({viewBox:`0 0 24 24`,width:`1.2em`,height:`1.2em`,...n})),o(e,r)}var Nc=(e,t=s,n=s)=>{var r=Ic(),i=T(r),a=e=>{var r=Fc();Ec(T(r),{}),D(r),E(()=>{x(r,`href`,t().spotify_url),x(r,`aria-label`,`Listen to ${n()} on Spotify`)}),o(e,r)};u(i,e=>{t().spotify_url&&e(a)});var c=C(i,2),l=e=>{var r=Fc();Cc(T(r),{}),D(r),E(()=>{x(r,`href`,t().apple_music_url),x(r,`aria-label`,`Listen to ${n()} on Apple Music`)}),o(e,r)};u(c,e=>{t().apple_music_url&&e(l)});var d=C(c,2);Mc(T(d),{}),D(d);var f=C(d,2),p=e=>{var r=Fc();kc(T(r),{}),D(r),E(()=>{x(r,`href`,t().tidal_url),x(r,`aria-label`,`Listen to ${n()} on Tidal`)}
1),o(e,r)};u(f,e=>{t().tidal_url&&e(p)}),D(r),E(e=>{x(d,`href`,e),x(d,`aria-label`,`Find ${n()} on YouTube`)},[()=>fe(t().name,t().artists)]),o(e,r)},Pc=(e,t=s,n=s)=>{var r=zc(),i=T(r),c=T(i);ne(c,()=>t().artwork,e=>{var n=Lc();E((e,r)=>{x(n,`src`,e),x(n,`srcset`,r),x(n,`alt`,`${t().album_name} album art`)},[()=>ge(t().artwork,384),()=>he(t().artwork)]),o(e,n)}),D(i);var l=C(i,2);Nc(l,t,n);var d=C(l,2),f=T(d),m=T(f),h=S(m,!0),g=C(m,2),_=S(g,!0),b=C(g,2);re(b,21,()=>t().artists,a,(e,n,r)=>{var i=Rc(),a=oe(i),s=S(a,!0),c=C(a),l=e=>{var t=v();t.nodeValue=`, `,o(e,t)};u(c,e=>{r<t().artists.length-1&&e(l)}),E((e,t)=>{x(a,`href`,e),p(s,t)},[()=>pe(y(n)),()=>de(y(n))]),o(e,i)}),D(b),D(f);var ee=C(f,2),w=T(ee),te=S(w,!0),ie=C(w,4),ae=S(ie,!0);D(ee),D(d),D(r),E((e,r)=>{p(h,n()===`cover`?`Cover`:`Original`),p(_,e),p(te,r),p(ae,t().album_year)},[()=>de(t().name),()=>de(t().album_name)]),o(e,r)},Fc=l(`<a class="svelte-hy7b9a"><!></a>`),Ic=l(`<div class="song-links svelte-hy7b9a"><!> <!> <a class="svelte-hy7b9a"><!></a> <!></div>`),Lc=l(`<img class="album-art svelte-hy7b9a" sizes="min(48.7vw - 1.24rem, 19.25rem)" fetchpriority="high" itemprop="image"/>`),Rc=l(`<a class="svelte-hy7b9a"> </a><!>`,1),zc=l(`<div class="track svelte-hy7b9a" itemprop="track" itemscope="" itemtype="https://schema.org/MusicRecording"><div class="album svelte-hy7b9a"><!></div> <!> <div class="info svelte-hy7b9a"><div class="heading svelte-hy7b9a"><span class="version svelte-hy7b9a"> </span> <h2 class="name svelte-hy7b9a" itemprop="name"> </h2> <div class="artist svelte-hy7b9a" itemprop="byArtist"></div></div> <div class="album-info svelte-hy7b9a"><span class="album-name"> </span> <span aria-hidden="true">&middot;</span> <time class="album-year" itemprop="datePublished"> </time></div></div></div>`),Bc=l(`<div class="compare svelte-hy7b9a"><!> <!></div>`);function Vc(e,t){ce(t,!0);let n=w(()=>t.cover.original),r=w(()=>t.cover.cover);var i=Bc(),a=T(i);Pc(a,()=>y(r),()=>`cover`),Pc(C(a,2),()=>y(n),()=>`original`),D(i),o(e,i),b()}var Hc=l(`<div class="item svelte-7j2d47"><!></div>`),Uc=l(`<aside class="related svelte-7j2d47" aria-labelledby="related-title"><h2 id="related-title" class="title svelte-7j2d47">Related</h2> <div class="list svelte-7j2d47"></div></aside>`);function Wc(e,t){ce(t,!0);var n=_(),r=oe(n);ne(r,()=>t.covers,e=>{var n=_(),r=oe(n),i=e=>{var n=Uc(),r=C(T(n),2);re(r,23,()=>t.covers,e=>e.slug,(e,t,n)=>{var r=Hc(),i=T(r);{let e=w(()=>y(n)>=4);_e(i,te(()=>y(t),{get lazy(){return y(e)},tintOnHover:!1,sizes:`clamp(8.75rem, 7.5rem + 3vw, 12rem)`}))}D(r),o(e,r)}),D(r),D(n),o(e,n)};u(r,e=>{t.covers.length&&e(i)}),o(e,n)}),o(e,n),b()}var Gc=l(`<div class="sparkle svelte-zro88m"><div class="sparkle-lines svelte-zro88m"><svg width="520" height="520" viewBox="0 0 520 520" fill="none" xmlns="http://www.w3.org/2000/svg" class="svelte-zro88m"><path class="vertical svelte-zro88m" d="M260 20L284 260L260 500L236 260L260 20Z" fill="currentColor"></path><path class="horizontal svelte-zro88m" d="M500 260L260 284L20 260L260 236L500 260Z" fill="currentColor"></path></svg></div></div>`);function Kc(e){var t=Gc();o(e,t)}var qc=l(`<span class="count svelte-1famv1g"> </span>`),Jc=l(`<a> <!></a>`),Yc=l(`<div class="tag svelte-1famv1g"> <!></div>`);function Xc(e,t){var n=_(),r=oe(n),i=e=>{var n=Jc();let r;var i=T(n),a=C(i),s=e=>{var n=qc(),r=S(n,!0);E(()=>p(r,t.count)),o(e,n)};u(a,e=>{t.count&&e(s)}),D(n),E(()=>{x(n,`href`,t.url),r=m(n,1,`tag svelte-1famv1g`,null,r,{active:t.isActive}),p(i,`${t.text??``} `)}),o(e,n)},a=e=>{var n=Yc(),r=T(n),i=C(r),a=e=>{var n=qc(),r=S(n,!0);E(()=>p(r,t.count)),o(e,n)};u(i,e=>{t.count&&e(a)}),D(n),E(()=>p(r,`${t.text??``} `)),o(e,n)};u(r,e=>{t.url?e(i):e(a,-1)}),o(e,n)}var Zc=l(`<div class="tags svelte-ujjnkz"><!></div>`);function Qc(e,t){var n=Zc(),r=T(n);c(r,()=>t.children??s),D(n),o(e,n)}var $c=l(`<meta name="description"/> <link rel="canonical"/> <meta property="og:image"/> <meta property="og:image:alt"/> <meta property="og:image:width"/> <meta property="og:image:height"/> <!>`,1),el=l(`<p class="description svelte-dv4vg2"> </p>`),tl=l(`<!> <div class="layout svelte-dv4vg2"><div class="main svelte-dv4vg2"><header class="header svelte-dv4vg2"><h1 class="title svelte-dv4vg2"> <!></h1> <div class="subtitle svelte-dv4vg2"><a class="artist svelte-dv4vg2"> </a> <a class="artist svelte-dv4vg2"> </a></div> <!></header> <div class="comparison svelte-dv4vg2"><!></div> <footer class="footer svelte-dv4vg2"><!> <span> <time> </time></span></footer></div> <!></div>`,1);function nl(e,t){ce(t,!0);let s=w(()=>
1me.url.searchParams.get(`new`)===`true`),c=e=>!!e&&/^#[0-9a-f]{6}$/i.test(e),l=w(()=>t.data.cover.album_color),m=w(()=>{let e=t.data.cover.album_color,n=t.data.original.album_color;return!c(e)||!c(n)||e===n?null:[e,n]});yc.default.extend(bc.default);let g=w(()=>(0,yc.default)(t.data.created_at).fromNow());f(async()=>{let e=e=>{let t=(e,t)=>(window.innerWidth-400)/1200*(t-e)+e,n=t(1.4,1.8),r=t(85,120),i=t(20,45),a=t(40,80),o=t(8,20),s={scalar:n,colors:[`--color-text`,`--color-surface-raised`].map(ue),shapes:[`square`],gravity:2,ticks:30,disableForReducedMotion:!0},c={left:{count:a,startVelocity:r-10,angle:90-i,origin:{x:0,y:1},spread:o},right:{count:a,startVelocity:r-10,angle:90+i,origin:{x:1,y:1},spread:o},bottom:{count:a*2,startVelocity:r,angle:90,origin:{x:.5,y:1},spread:o*2.5}};vc({...s,...c[e]})};y(s)&&(setTimeout(()=>e(`left`),1e3),setTimeout(()=>e(`right`),1600),setTimeout(()=>e(`bottom`),3e3))});var v=tl();h(`dv4vg2`,e=>{var r=$c(),a=oe(r),s=C(a,2),f=C(s,2),p=C(f,2),m=C(p,2),h=C(m,2),g=C(h,2),v=e=>{var t=_(),n=oe(t);d(n,()=>`<style>:root { --color-page: ${y(l)}; }</style>`),o(e,t)},b=w(()=>c(y(l)));u(g,e=>{y(b)&&e(v)}),E(()=>{x(a,`content`,t.data.description??`Some covers deliver the age-old simple pleasures of drag.`),x(s,`href`,`${n}${me.url.pathname}`),x(f,`content`,`${me.url.origin}${me.url.pathname}/og.jpg`),x(p,`content`,t.data.pageTitle),x(m,`content`,`${i}`),x(h,`content`,`630`)}),ie(()=>{ee.title=t.data.title??``}),o(e,r)});var te=oe(v),ne=e=>{ye(e,{get colors(){return y(m)}})};u(te,e=>{y(m)&&e(ne)});var ae=C(te,2),se=T(ae),de=T(se),fe=T(de),he=T(fe,!0),ge=C(he),_e=e=>{Kc(e,{})};
1u(ge,e=>{y(s)&&e(_e)}),D(fe);var ve=C(fe,2),be=T(ve),xe=S(be,!0),Se=C(be);Se.nodeValue=` covering  `;var Ce=C(Se),we=S(Ce,!0);D(ve);var Te=C(ve,2),Ee=e=>{Qc(e,{children:(e,n)=>{var i=_(),s=oe(i);re(s,17,()=>le(t.data.tags),a,(e,t)=>{{let n=w(()=>`/${r[y(t)].slug}`);Xc(e,{get text(){return r[y(t)].label},get url(){return y(n)}})}}),o(e,i)},$$slots:{default:!0}})};u(Te,e=>{t.data.tags&&e(Ee)}),D(de);var De=C(de,2);Vc(T(De),{get cover(){return t.data}}),D(De);var Oe=C(De,2),ke=T(Oe),Ae=e=>{var n=el(),r=S(n,!0);E(()=>p(r,t.data.description)),o(e,n)};u(ke,e=>{t.data.description&&e(Ae)});var je=C(ke,2),O=T(je),k=C(O),A=S(k,!0);D(je),D(Oe),D(se),Wc(C(se,2),{get covers(){return t.data.related}}),D(ae),E((e,n)=>{p(he,t.data.pageTitle),x(be,`href`,e),p(xe,t.data.cover.artists[0]),x(Ce,`href`,n),p(we,t.data.original.artists[0]),p(O,`Added ${t.data.contributor?`by ${t.data.contributor}`:`anonymously`} `),x(k,`datetime`,t.data.created_at),p(A,y(g))},[()=>pe(t.data.cover.artists[0]),()=>pe(t.data.original.artists[0])]),o(e,v),b()}export{nl as component};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.