@webmate-studio/builder 0.2.57 → 0.2.59

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- (()=>{function vr(e,t){e.indexOf(t)===-1&&e.push(t)}function de(e,t){let r=e.indexOf(t);r>-1&&e.splice(r,1)}var B=(e,t,r)=>r>t?t:r<e?e:r;var J=()=>{},N=()=>{};var k={};var Ye=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function qe(e){return typeof e=="object"&&e!==null}var Xe=e=>/^0[^.\s]+$/u.test(e);function he(e){let t;return()=>(t===void 0&&(t=e()),t)}var I=e=>e;var gi=(e,t)=>r=>t(e(r)),ge=(...e)=>e.reduce(gi);var Q=(e,t,r)=>{let n=t-e;return n===0?1:(r-e)/n};var xe=class{constructor(){this.subscriptions=[]}add(t){return vr(this.subscriptions,t),()=>de(this.subscriptions,t)}notify(t,r,n){let o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](t,r,n);else for(let i=0;i<o;i++){let s=this.subscriptions[i];s&&s(t,r,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}};var F=e=>e*1e3,R=e=>e/1e3;function ye(e,t){return t?e*(1e3/t):0}var pn=(e,t,r)=>{let n=t-e;return((r-e)%n+n)%n+e};var dn=(e,t,r)=>(((1-3*r+3*t)*e+(3*r-6*t))*e+3*t)*e,xi=1e-7,yi=12;function Ti(e,t,r,n,o){let i,s,a=0;do s=t+(r-t)/2,i=dn(s,n,o)-e,i>0?r=s:t=s;while(Math.abs(i)>xi&&++a<yi);return s}function ae(e,t,r,n){if(e===t&&r===n)return I;let o=i=>Ti(i,0,1,e,r);return i=>i===0||i===1?i:dn(o(i),t,n)}var It=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2;var Rt=e=>t=>1-e(1-t);var Bt=ae(.33,1.53,.69,.99),De=Rt(Bt),Ze=It(De);var Je=e=>(e*=2)<1?.5*De(e):.5*(2-Math.pow(2,-10*(e-1)));var Qe=e=>1-Math.sin(Math.acos(e)),Vr=Rt(Qe),et=It(Qe);var Sr=ae(.42,0,1,1),wr=ae(0,0,.58,1),tt=ae(.42,0,.58,1);var rt=e=>Array.isArray(e)&&typeof e[0]!="number";function nt(e,t){return rt(e)?e[pn(0,e.length,t)]:e}var ot=e=>Array.isArray(e)&&typeof e[0]=="number";var hn={linear:I,easeIn:Sr,easeInOut:tt,easeOut:wr,circIn:Qe,circInOut:et,circOut:Vr,backIn:De,backInOut:Ze,backOut:Bt,anticipate:Je},bi=e=>typeof e=="string",Oe=e=>{if(ot(e)){N(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");let[t,r,n,o]=e;return ae(t,r,n,o)}else if(bi(e))return N(hn[e]!==void 0,`Invalid easing type '${e}'`,"invalid-easing-type"),hn[e];return e};var it=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];var Fe={value:null,addProjectionMetrics:null};function gn(e,t){let r=new Set,n=new Set,o=!1,i=!1,s=new WeakSet,a={delta:0,timestamp:0,isProcessing:!1},l=0;function f(c){s.has(c)&&(m.schedule(c),e()),l++,c(a)}let m={schedule:(c,u=!1,h=!1)=>{let g=h&&o?r:n;return u&&s.add(c),g.has(c)||g.add(c),c},cancel:c=>{n.delete(c),s.delete(c)},process:c=>{if(a=c,o){i=!0;return}o=!0,[r,n]=[n,r],r.forEach(f),t&&Fe.value&&Fe.value.frameloop[t].push(l),l=0,r.clear(),o=!1,i&&(i=!1,m.process(c))}};return m}var vi=40;function kt(e,t){let r=!1,n=!0,o={delta:0,timestamp:0,isProcessing:!1},i=()=>r=!0,s=it.reduce((V,S)=>(V[S]=gn(i,t?S:void 0),V),{}),{setup:a,read:l,resolveKeyframes:f,preUpdate:m,update:c,preRender:u,render:h,postRender:T}=s,g=()=>{let V=k.useManualTiming?o.timestamp:performance.now();r=!1,k.useManualTiming||(o.delta=n?1e3/60:Math.max(Math.min(V-o.timestamp,vi),1)),o.timestamp=V,o.isProcessing=!0,a.process(o),l.process(o),f.process(o),m.process(o),c.process(o),u.process(o),h.process(o),T.process(o),o.isProcessing=!1,r&&t&&(n=!1,e(g))},b=()=>{r=!0,n=!0,o.isProcessing||e(g)};return{schedule:it.reduce((V,S)=>{let d=s[S];return V[S]=(v,D=!1,x=!1)=>(r||b(),d.schedule(v,D,x)),V},{}),cancel:V=>{for(let S=0;S<it.length;S++)s[it[S]].cancel(V)},state:o,steps:s}}var{schedule:O,cancel:H,state:ee,steps:Vi}=kt(typeof requestAnimationFrame<"u"?requestAnimationFrame:I,!0);var Nt;function Si(){Nt=void 0}var P={now:()=>(Nt===void 0&&P.set(ee.isProcessing||k.useManualTiming?ee.timestamp:performance.now()),Nt),set:e=>{Nt=e,queueMicrotask(Si)}};var Pe={layout:0,mainThread:0,waapi:0};var xn=e=>t=>typeof t=="string"&&t.startsWith(e),st=xn("--"),wi=xn("var(--"),Te=e=>wi(e)?Mi.test(e.split("/*")[0].trim()):!1,Mi=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;var _={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},te={..._,transform:e=>B(0,1,e)},at={..._,default:1};var le=e=>Math.round(e*1e5)/1e5;var Ie=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function yn(e){return e==null}var Tn=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu;var Re=(e,t)=>r=>!!(typeof r=="string"&&Tn.test(r)&&r.startsWith(e)||t&&!yn(r)&&Object.prototype.hasOwnProperty.call(r,t)),Kt=(e,t,r)=>n=>{if(typeof n!="string")return n;let[o,i,s,a]=n.match(Ie);return{[e]:parseFloat(o),[t]:parseFloat(i),[r]:parseFloat(s),alpha:a!==void 0?parseFloat(a):1}};var Ai=e=>B(0,255,e),Mr={..._,transform:e=>Math.round(Ai(e))},U={test:Re("rgb","red"),parse:Kt("red","green","blue"),transform:({red:e,green:t,blue:r,alpha:n=1})=>"rgba("+Mr.transform(e)+", "+Mr.transform(t)+", "+Mr.transform(r)+", "+le(te.transform(n))+")"};function Ei(e){let t="",r="",n="",o="";return e.length>5?(t=e.substring(1,3),r=e.substring(3,5),n=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),r=e.substring(2,3),n=e.substring(3,4),o=e.substring(4,5),t+=t,r+=r,n+=n,o+=o),{red:parseInt(t,16),green:parseInt(r,16),blue:parseInt(n,16),alpha:o?parseInt(o,16)/255:1}}var lt={test:Re("#"),parse:Ei,transform:U.transform};var mt=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),G=mt("deg"),re=mt("%"),p=mt("px"),Ar=mt("vh"),Er=mt("vw"),Lt={...re,parse:e=>re.parse(e)/100,transform:e=>re.transform(e*100)};var me={test:Re("hsl","hue"),parse:Kt("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:r,alpha:n=1})=>"hsla("+Math.round(e)+", "+re.transform(le(t))+", "+re.transform(le(r))+", "+le(te.transform(n))+")"};var C={test:e=>U.test(e)||lt.test(e)||me.test(e),parse:e=>U.test(e)?U.parse(e):me.test(e)?me.parse(e):lt.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?U.transform(e):me.transform(e),getAnimatableNone:e=>{let t=C.parse(e);return t.alpha=0,C.transform(t)}};var bn=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function Ci(e){return isNaN(e)&&typeof e=="string"&&(e.match(Ie)?.length||0)+(e.match(bn)?.length||0)>0}var Vn="number",Sn="color",Di="var",Oi="var(",vn="${}",Fi=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function fe(e){let t=e.toString(),r=[],n={color:[],number:[],var:[]},o=[],i=0,a=t.replace(Fi,l=>(C.test(l)?(n.color.push(i),o.push(Sn),r.push(C.parse(l))):l.startsWith(Oi)?(n.var.push(i),o.push(Di),r.push(l)):(n.number.push(i),o.push(Vn),r.push(parseFloat(l))),++i,vn)).split(vn);return{values:r,split:a,indexes:n,types:o}}function wn(e){return fe(e).values}function Mn(e){let{split:t,types:r}=fe(e),n=t.length;return o=>{let i="";for(let s=0;s<n;s++)if(i+=t[s],o[s]!==void 0){let a=r[s];a===Vn?i+=le(o[s]):a===Sn?i+=C.transform(o[s]):i+=o[s]}return i}}var Pi=e=>typeof e=="number"?0:C.test(e)?C.getAnimatableNone(e):e;function Ii(e){let t=wn(e);return Mn(e)(t.map(Pi))}var L={test:Ci,parse:wn,createTransformer:Mn,getAnimatableNone:Ii};function Cr(e,t,r){return r<0&&(r+=1),r>1&&(r-=1),r<1/6?e+(t-e)*6*r:r<1/2?t:r<2/3?e+(t-e)*(2/3-r)*6:e}function An({hue:e,saturation:t,lightness:r,alpha:n}){e/=360,t/=100,r/=100;let o=0,i=0,s=0;if(!t)o=i=s=r;else{let a=r<.5?r*(1+t):r+t-r*t,l=2*r-a;o=Cr(l,a,e+1/3),i=Cr(l,a,e),s=Cr(l,a,e-1/3)}return{red:Math.round(o*255),green:Math.round(i*255),blue:Math.round(s*255),alpha:n}}function Be(e,t){return r=>r>0?t:e}var z=(e,t,r)=>e+(t-e)*r;var Dr=(e,t,r)=>{let n=e*e,o=r*(t*t-n)+n;return o<0?0:Math.sqrt(o)},Ri=[lt,U,me],Bi=e=>Ri.find(t=>t.test(e));function En(e){let t=Bi(e);if(J(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!t)return!1;let r=t.parse(e);return t===me&&(r=An(r)),r}var Or=(e,t)=>{let r=En(e),n=En(t);if(!r||!n)return Be(e,t);let o={...r};return i=>(o.red=Dr(r.red,n.red,i),o.green=Dr(r.green,n.green,i),o.blue=Dr(r.blue,n.blue,i),o.alpha=z(r.alpha,n.alpha,i),U.transform(o))};var Wt=new Set(["none","hidden"]);function Cn(e,t){return Wt.has(e)?r=>r<=0?e:t:r=>r>=1?t:e}function ki(e,t){return r=>z(e,t,r)}function Gt(e){return typeof e=="number"?ki:typeof e=="string"?Te(e)?Be:C.test(e)?Or:Li:Array.isArray(e)?Dn:typeof e=="object"?C.test(e)?Or:Ni:Be}function Dn(e,t){let r=[...e],n=r.length,o=e.map((i,s)=>Gt(i)(i,t[s]));return i=>{for(let s=0;s<n;s++)r[s]=o[s](i);return r}}function Ni(e,t){let r={...e,...t},n={};for(let o in r)e[o]!==void 0&&t[o]!==void 0&&(n[o]=Gt(e[o])(e[o],t[o]));return o=>{for(let i in n)r[i]=n[i](o);return r}}function Ki(e,t){let r=[],n={color:0,var:0,number:0};for(let o=0;o<t.values.length;o++){let i=t.types[o],s=e.indexes[i][n[i]],a=e.values[s]??0;r[o]=a,n[i]++}return r}var Li=(e,t)=>{let r=L.createTransformer(t),n=fe(e),o=fe(t);return n.indexes.var.length===o.indexes.var.length&&n.indexes.color.length===o.indexes.color.length&&n.indexes.number.length>=o.indexes.number.length?Wt.has(e)&&!o.values.length||Wt.has(t)&&!n.values.length?Cn(e,t):ge(Dn(Ki(n,o),o.values),r):(J(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),Be(e,t))};function zt(e,t,r){return typeof e=="number"&&typeof t=="number"&&typeof r=="number"?z(e,t,r):Gt(e)(e,t)}var On=e=>{let t=({timestamp:r})=>e(r);return{start:(r=!0)=>O.update(t,r),stop:()=>H(t),now:()=>ee.isProcessing?ee.timestamp:P.now()}};var jt=(e,t,r=10)=>{let n="",o=Math.max(Math.round(t/r),2);for(let i=0;i<o;i++)n+=Math.round(e(i/(o-1))*1e4)/1e4+", ";return`linear(${n.substring(0,n.length-2)})`};function ke(e){let t=0,r=50,n=e.next(t);for(;!n.done&&t<2e4;)t+=r,n=e.next(t);return t>=2e4?1/0:t}function ft(e,t=100,r){let n=r({...e,keyframes:[0,t]}),o=Math.min(ke(n),2e4);return{type:"keyframes",ease:i=>n.next(o*i).value/t,duration:R(o)}}var Wi=5;function $t(e,t,r){let n=Math.max(t-Wi,0);return ye(r-e(n),t-n)}var M={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};var Pr=.001;function Fn({duration:e=M.duration,bounce:t=M.bounce,velocity:r=M.velocity,mass:n=M.mass}){let o,i;J(e<=F(M.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let s=1-t;s=B(M.minDamping,M.maxDamping,s),e=B(M.minDuration,M.maxDuration,R(e)),s<1?(o=f=>{let m=f*s,c=m*e,u=m-r,h=Ht(f,s),T=Math.exp(-c);return Pr-u/h*T},i=f=>{let c=f*s*e,u=c*r+r,h=Math.pow(s,2)*Math.pow(f,2)*e,T=Math.exp(-c),g=Ht(Math.pow(f,2),s);return(-o(f)+Pr>0?-1:1)*((u-h)*T)/g}):(o=f=>{let m=Math.exp(-f*e),c=(f-r)*e+1;return-Pr+m*c},i=f=>{let m=Math.exp(-f*e),c=(r-f)*(e*e);return m*c});let a=5/e,l=zi(o,i,a);if(e=F(e),isNaN(l))return{stiffness:M.stiffness,damping:M.damping,duration:e};{let f=Math.pow(l,2)*n;return{stiffness:f,damping:s*2*Math.sqrt(n*f),duration:e}}}var Gi=12;function zi(e,t,r){let n=r;for(let o=1;o<Gi;o++)n=n-e(n)/t(n);return n}function Ht(e,t){return e*Math.sqrt(1-t*t)}var ji=["duration","bounce"],$i=["stiffness","damping","mass"];function Pn(e,t){return t.some(r=>e[r]!==void 0)}function Hi(e){let t={velocity:M.velocity,stiffness:M.stiffness,damping:M.damping,mass:M.mass,isResolvedFromDuration:!1,...e};if(!Pn(e,$i)&&Pn(e,ji))if(e.visualDuration){let r=e.visualDuration,n=2*Math.PI/(r*1.2),o=n*n,i=2*B(.05,1,1-(e.bounce||0))*Math.sqrt(o);t={...t,mass:M.mass,stiffness:o,damping:i}}else{let r=Fn(e);t={...t,...r,mass:M.mass},t.isResolvedFromDuration=!0}return t}function ne(e=M.visualDuration,t=M.bounce){let r=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e,{restSpeed:n,restDelta:o}=r,i=r.keyframes[0],s=r.keyframes[r.keyframes.length-1],a={done:!1,value:i},{stiffness:l,damping:f,mass:m,duration:c,velocity:u,isResolvedFromDuration:h}=Hi({...r,velocity:-R(r.velocity||0)}),T=u||0,g=f/(2*Math.sqrt(l*m)),b=s-i,y=R(Math.sqrt(l/m)),E=Math.abs(b)<5;n||(n=E?M.restSpeed.granular:M.restSpeed.default),o||(o=E?M.restDelta.granular:M.restDelta.default);let V;if(g<1){let d=Ht(y,g);V=v=>{let D=Math.exp(-g*y*v);return s-D*((T+g*y*b)/d*Math.sin(d*v)+b*Math.cos(d*v))}}else if(g===1)V=d=>s-Math.exp(-y*d)*(b+(T+y*b)*d);else{let d=y*Math.sqrt(g*g-1);V=v=>{let D=Math.exp(-g*y*v),x=Math.min(d*v,300);return s-D*((T+g*y*b)*Math.sinh(x)+d*b*Math.cosh(x))/d}}let S={calculatedDuration:h&&c||null,next:d=>{let v=V(d);if(h)a.done=d>=c;else{let D=d===0?T:0;g<1&&(D=d===0?F(T):$t(V,d,v));let x=Math.abs(D)<=n,w=Math.abs(s-v)<=o;a.done=x&&w}return a.value=a.done?s:v,a},toString:()=>{let d=Math.min(ke(S),2e4),v=jt(D=>S.next(d*D).value,d,30);return d+"ms "+v},toTransition:()=>{}};return S}ne.applyToOptions=e=>{let t=ft(e,100,ne);return e.ease=t.ease,e.duration=F(t.duration),e.type="keyframes",e};function ct({keyframes:e,velocity:t=0,power:r=.8,timeConstant:n=325,bounceDamping:o=10,bounceStiffness:i=500,modifyTarget:s,min:a,max:l,restDelta:f=.5,restSpeed:m}){let c=e[0],u={done:!1,value:c},h=x=>a!==void 0&&x<a||l!==void 0&&x>l,T=x=>a===void 0?l:l===void 0||Math.abs(a-x)<Math.abs(l-x)?a:l,g=r*t,b=c+g,y=s===void 0?b:s(b);y!==b&&(g=y-c);let E=x=>-g*Math.exp(-x/n),V=x=>y+E(x),S=x=>{let w=E(x),K=V(x);u.done=Math.abs(w)<=f,u.value=u.done?y:K},d,v,D=x=>{h(u.value)&&(d=x,v=ne({keyframes:[u.value,T(u.value)],velocity:$t(V,x,u.value),damping:o,stiffness:i,restDelta:f,restSpeed:m}))};return D(0),{calculatedDuration:null,next:x=>{let w=!1;return!v&&d===void 0&&(w=!0,S(x),D(x)),d!==void 0&&x>=d?v.next(x-d):(!w&&S(x),u)}}}function _i(e,t,r){let n=[],o=r||k.mix||zt,i=e.length-1;for(let s=0;s<i;s++){let a=o(e[s],e[s+1]);if(t){let l=Array.isArray(t)?t[s]||I:t;a=ge(l,a)}n.push(a)}return n}function ut(e,t,{clamp:r=!0,ease:n,mixer:o}={}){let i=e.length;if(N(i===t.length,"Both input and output ranges must be the same length","range-length"),i===1)return()=>t[0];if(i===2&&t[0]===t[1])return()=>t[1];let s=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());let a=_i(t,n,o),l=a.length,f=m=>{if(s&&m<e[0])return t[0];let c=0;if(l>1)for(;c<e.length-2&&!(m<e[c+1]);c++);let u=Q(e[c],e[c+1],m);return a[c](u)};return r?m=>f(B(e[0],e[i-1],m)):f}function pt(e,t){let r=e[e.length-1];for(let n=1;n<=t;n++){let o=Q(0,t,n);e.push(z(r,1,o))}}function be(e){let t=[0];return pt(t,e.length-1),t}function In(e,t){return e.map(r=>r*t)}function Ui(e,t){return e.map(()=>t||tt).splice(0,e.length-1)}function ve({duration:e=300,keyframes:t,times:r,ease:n="easeInOut"}){let o=rt(n)?n.map(Oe):Oe(n),i={done:!1,value:t[0]},s=In(r&&r.length===t.length?r:be(t),e),a=ut(s,t,{ease:Array.isArray(o)?o:Ui(t,o)});return{calculatedDuration:e,next:l=>(i.value=a(l),i.done=l>=e,i)}}var Yi=e=>e!==null;function Ne(e,{repeat:t,repeatType:r="loop"},n,o=1){let i=e.filter(Yi),a=o<0||t&&r!=="loop"&&t%2===1?0:i.length-1;return!a||n===void 0?i[a]:n}var qi={decay:ct,inertia:ct,tween:ve,keyframes:ve,spring:ne};function _t(e){typeof e.type=="string"&&(e.type=qi[e.type])}var ce=class{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,r){return this.finished.then(t,r)}};var Xi=e=>e/100,oe=class extends ce{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{let{motionValue:r}=this.options;r&&r.updatedAt!==P.now()&&this.tick(P.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},Pe.mainThread++,this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){let{options:t}=this;_t(t);let{type:r=ve,repeat:n=0,repeatDelay:o=0,repeatType:i,velocity:s=0}=t,{keyframes:a}=t,l=r||ve;l!==ve&&typeof a[0]!="number"&&(this.mixKeyframes=ge(Xi,zt(a[0],a[1])),a=[0,100]);let f=l({...t,keyframes:a});i==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...a].reverse(),velocity:-s})),f.calculatedDuration===null&&(f.calculatedDuration=ke(f));let{calculatedDuration:m}=f;this.calculatedDuration=m,this.resolvedDuration=m+o,this.totalDuration=this.resolvedDuration*(n+1)-o,this.generator=f}updateTime(t){let r=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=r}tick(t,r=!1){let{generator:n,totalDuration:o,mixKeyframes:i,mirroredGenerator:s,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return n.next(0);let{delay:f=0,keyframes:m,repeat:c,repeatType:u,repeatDelay:h,type:T,onUpdate:g,finalKeyframe:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-o/this.speed,this.startTime)),r?this.currentTime=t:this.updateTime(t);let y=this.currentTime-f*(this.playbackSpeed>=0?1:-1),E=this.playbackSpeed>=0?y<0:y>o;this.currentTime=Math.max(y,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=o);let V=this.currentTime,S=n;if(c){let x=Math.min(this.currentTime,o)/a,w=Math.floor(x),K=x%1;!K&&x>=1&&(K=1),K===1&&w--,w=Math.min(w,c+1),!!(w%2)&&(u==="reverse"?(K=1-K,h&&(K-=h/a)):u==="mirror"&&(S=s)),V=B(0,1,K)*a}let d=E?{done:!1,value:m[0]}:S.next(V);i&&(d.value=i(d.value));let{done:v}=d;!E&&l!==null&&(v=this.playbackSpeed>=0?this.currentTime>=o:this.currentTime<=0);let D=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&v);return D&&T!==ct&&(d.value=Ne(m,this.options,b,this.speed)),g&&g(d.value),D&&this.finish(),d}then(t,r){return this.finished.then(t,r)}get duration(){return R(this.calculatedDuration)}get iterationDuration(){let{delay:t=0}=this.options||{};return this.duration+R(t)}get time(){return R(this.currentTime)}set time(t){t=F(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(P.now());let r=this.playbackSpeed!==t;this.playbackSpeed=t,r&&(this.time=R(this.currentTime))}play(){if(this.isStopped)return;let{driver:t=On,startTime:r}=this.options;this.driver||(this.driver=t(o=>this.tick(o))),this.options.onPlay?.();let n=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=n):this.holdTime!==null?this.startTime=n-this.holdTime:this.startTime||(this.startTime=r??n),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(P.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null,Pe.mainThread--}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}};function Rn(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}var Ve=e=>e*180/Math.PI,Ir=e=>{let t=Ve(Math.atan2(e[1],e[0]));return Rr(t)},Zi={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:Ir,rotateZ:Ir,skewX:e=>Ve(Math.atan(e[1])),skewY:e=>Ve(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},Rr=e=>(e=e%360,e<0&&(e+=360),e),Bn=Ir,kn=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),Nn=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),Ji={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:kn,scaleY:Nn,scale:e=>(kn(e)+Nn(e))/2,rotateX:e=>Rr(Ve(Math.atan2(e[6],e[5]))),rotateY:e=>Rr(Ve(Math.atan2(-e[2],e[0]))),rotateZ:Bn,rotate:Bn,skewX:e=>Ve(Math.atan(e[4])),skewY:e=>Ve(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function dt(e){return e.includes("scale")?1:0}function ht(e,t){if(!e||e==="none")return dt(t);let r=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u),n,o;if(r)n=Ji,o=r;else{let a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);n=Zi,o=a}if(!o)return dt(t);let i=n[t],s=o[1].split(",").map(Qi);return typeof i=="function"?i(s):s[i]}var Br=(e,t)=>{let{transform:r="none"}=getComputedStyle(e);return ht(r,t)};function Qi(e){return parseFloat(e.trim())}var j=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],W=new Set(j);var kr=e=>e===_||e===p,es=new Set(["x","y","z"]),ts=j.filter(e=>!es.has(e));function Kn(e){let t=[];return ts.forEach(r=>{let n=e.getValue(r);n!==void 0&&(t.push([r,n.get()]),n.set(r.startsWith("scale")?1:0))}),t}var ue={width:({x:e},{paddingLeft:t="0",paddingRight:r="0"})=>e.max-e.min-parseFloat(t)-parseFloat(r),height:({y:e},{paddingTop:t="0",paddingBottom:r="0"})=>e.max-e.min-parseFloat(t)-parseFloat(r),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>ht(t,"x"),y:(e,{transform:t})=>ht(t,"y")};ue.translateX=ue.x;ue.translateY=ue.y;var Se=new Set,Nr=!1,Kr=!1,Lr=!1;function Ln(){if(Kr){let e=Array.from(Se).filter(n=>n.needsMeasurement),t=new Set(e.map(n=>n.element)),r=new Map;t.forEach(n=>{let o=Kn(n);o.length&&(r.set(n,o),n.render())}),e.forEach(n=>n.measureInitialState()),t.forEach(n=>{n.render();let o=r.get(n);o&&o.forEach(([i,s])=>{n.getValue(i)?.set(s)})}),e.forEach(n=>n.measureEndState()),e.forEach(n=>{n.suspendedScrollY!==void 0&&window.scrollTo(0,n.suspendedScrollY)})}Kr=!1,Nr=!1,Se.forEach(e=>e.complete(Lr)),Se.clear()}function Wn(){Se.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Kr=!0)})}function Wr(){Lr=!0,Wn(),Ln(),Lr=!1}var ie=class{constructor(t,r,n,o,i,s=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=r,this.name=n,this.motionValue=o,this.element=i,this.isAsync=s}scheduleResolve(){this.state="scheduled",this.isAsync?(Se.add(this),Nr||(Nr=!0,O.read(Wn),O.resolveKeyframes(Ln))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:t,name:r,element:n,motionValue:o}=this;if(t[0]===null){let i=o?.get(),s=t[t.length-1];if(i!==void 0)t[0]=i;else if(n&&r){let a=n.readValue(r,s);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=s),o&&i===void 0&&o.set(t[0])}Rn(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Se.delete(this)}cancel(){this.state==="scheduled"&&(Se.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}};var Gn=e=>e.startsWith("--");function zn(e,t,r){Gn(t)?e.style.setProperty(t,r):e.style[t]=r}var gt=he(()=>window.ScrollTimeline!==void 0);var jn={};function $n(e,t){let r=he(e);return()=>jn[t]??r()}var Ut=$n(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing");var we=([e,t,r,n])=>`cubic-bezier(${e}, ${t}, ${r}, ${n})`;var Gr={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:we([0,.65,.55,1]),circOut:we([.55,0,1,.45]),backIn:we([.31,.01,.66,-.59]),backOut:we([.33,1.53,.69,.99])};function zr(e,t){if(e)return typeof e=="function"?Ut()?jt(e,t):"ease-out":ot(e)?we(e):Array.isArray(e)?e.map(r=>zr(r,t)||Gr.easeOut):Gr[e]}function Hn(e,t,r,{delay:n=0,duration:o=300,repeat:i=0,repeatType:s="loop",ease:a="easeOut",times:l}={},f=void 0){let m={[t]:r};l&&(m.offset=l);let c=zr(a,o);Array.isArray(c)&&(m.easing=c),Fe.value&&Pe.waapi++;let u={delay:n,duration:o,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:i+1,direction:s==="reverse"?"alternate":"normal"};f&&(u.pseudoElement=f);let h=e.animate(m,u);return Fe.value&&h.finished.finally(()=>{Pe.waapi--}),h}function Me(e){return typeof e=="function"&&"applyToOptions"in e}function _n({type:e,...t}){return Me(e)&&Ut()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}var Yt=class extends ce{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,!t)return;let{element:r,name:n,keyframes:o,pseudoElement:i,allowFlatten:s=!1,finalKeyframe:a,onComplete:l}=t;this.isPseudoElement=!!i,this.allowFlatten=s,this.options=t,N(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");let f=_n(t);this.animation=Hn(r,n,o,f,i),f.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){let m=Ne(o,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(m):zn(r,n,m),this.animation.cancel()}l?.(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;let{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){let t=this.animation.effect?.getComputedTiming?.().duration||0;return R(Number(t))}get iterationDuration(){let{delay:t=0}=this.options||{};return this.duration+R(t)}get time(){return R(Number(this.animation.currentTime)||0)}set time(t){this.finishedTime=null,this.animation.currentTime=F(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(t){this.animation.startTime=t}attachTimeline({timeline:t,observe:r}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&gt()?(this.animation.timeline=t,I):r(this)}};var Un={anticipate:Je,backInOut:Ze,circInOut:et};function rs(e){return e in Un}function Yn(e){typeof e.ease=="string"&&rs(e.ease)&&(e.ease=Un[e.ease])}var qn=10,qt=class extends Yt{constructor(t){Yn(t),_t(t),super(t),t.startTime&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){let{motionValue:r,onUpdate:n,onComplete:o,element:i,...s}=this.options;if(!r)return;if(t!==void 0){r.set(t);return}let a=new oe({...s,autoplay:!1}),l=F(this.finishedTime??this.time);r.setWithVelocity(a.sample(l-qn).value,a.sample(l).value,qn),a.stop()}};var jr=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(L.test(e)||e==="0")&&!e.startsWith("url("));function ns(e){let t=e[0];if(e.length===1)return!0;for(let r=0;r<e.length;r++)if(e[r]!==t)return!0}function Xn(e,t,r,n){let o=e[0];if(o===null)return!1;if(t==="display"||t==="visibility")return!0;let i=e[e.length-1],s=jr(o,t),a=jr(i,t);return J(s===a,`You are trying to animate ${t} from "${o}" to "${i}". "${s?i:o}" is not an animatable value.`,"value-not-animatable"),!s||!a?!1:ns(e)||(r==="spring"||Me(r))&&n}function Ke(e){e.duration=0,e.type="keyframes"}var os=new Set(["opacity","clipPath","filter","transform"]),is=he(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function Zn(e){let{motionValue:t,name:r,repeatDelay:n,repeatType:o,damping:i,type:s}=e;if(!(t?.owner?.current instanceof HTMLElement))return!1;let{onUpdate:l,transformTemplate:f}=t.owner.getProps();return is()&&r&&os.has(r)&&(r!=="transform"||!f)&&!l&&!n&&o!=="mirror"&&i!==0&&s!=="inertia"}var ss=40,xt=class extends ce{constructor({autoplay:t=!0,delay:r=0,type:n="keyframes",repeat:o=0,repeatDelay:i=0,repeatType:s="loop",keyframes:a,name:l,motionValue:f,element:m,...c}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=P.now();let u={autoplay:t,delay:r,type:n,repeat:o,repeatDelay:i,repeatType:s,name:l,motionValue:f,element:m,...c},h=m?.KeyframeResolver||ie;this.keyframeResolver=new h(a,(T,g,b)=>this.onKeyframesResolved(T,g,u,!b),l,f,m),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,r,n,o){this.keyframeResolver=void 0;let{name:i,type:s,velocity:a,delay:l,isHandoff:f,onUpdate:m}=n;this.resolvedAt=P.now(),Xn(t,i,s,a)||((k.instantAnimations||!l)&&m?.(Ne(t,n,r)),t[0]=t[t.length-1],Ke(n),n.repeat=0);let u={startTime:o?this.resolvedAt?this.resolvedAt-this.createdAt>ss?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:r,...n,keyframes:t},h=!f&&Zn(u)?new qt({...u,element:u.motionValue.owner.current}):new oe(u);h.finished.then(()=>this.notifyFinished()).catch(I),this.pendingTimeline&&(this.stopTimeline=h.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=h}get finished(){return this._animation?this.animation.finished:this._finished}then(t,r){return this.finished.finally(t).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),Wr()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}};var Xt=class{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}get finished(){return Promise.all(this.animations.map(t=>t.finished))}getAll(t){return this.animations[0][t]}setAll(t,r){for(let n=0;n<this.animations.length;n++)this.animations[n][t]=r}attachTimeline(t){let r=this.animations.map(n=>n.attachTimeline(t));return()=>{r.forEach((n,o)=>{n&&n(),this.animations[o].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get state(){return this.getAll("state")}get startTime(){return this.getAll("startTime")}get duration(){return Jn(this.animations,"duration")}get iterationDuration(){return Jn(this.animations,"iterationDuration")}runAll(t){this.animations.forEach(r=>r[t]())}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}};function Jn(e,t){let r=0;for(let n=0;n<e.length;n++){let o=e[n][t];o!==null&&o>r&&(r=o)}return r}var yt=class extends Xt{then(t,r){return this.finished.finally(t).then(()=>{})}};var as=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function ls(e){let t=as.exec(e);if(!t)return[,];let[,r,n,o]=t;return[`--${r??n}`,o]}var ms=4;function $r(e,t,r=1){N(r<=ms,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");let[n,o]=ls(e);if(!n)return;let i=window.getComputedStyle(t).getPropertyValue(n);if(i){let s=i.trim();return Ye(s)?parseFloat(s):s}return Te(o)?$r(o,t,r+1):o}function Tt(e,t){return e?.[t]??e?.default??e}var bt=new Set(["width","height","top","left","right","bottom",...j]);var Qn={test:e=>e==="auto",parse:e=>e};var Zt=e=>t=>t.test(e);var Hr=[_,p,re,G,Er,Ar,Qn],_r=e=>Hr.find(Zt(e));function eo(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||Xe(e):!0}var fs=new Set(["brightness","contrast","saturate","opacity"]);function cs(e){let[t,r]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;let[n]=r.match(Ie)||[];if(!n)return e;let o=r.replace(n,""),i=fs.has(t)?1:0;return n!==r&&(i*=100),t+"("+i+o+")"}var us=/\b([a-z-]*)\(.*?\)/gu,vt={...L,getAnimatableNone:e=>{let t=e.match(us);return t?t.map(cs).join(" "):e}};var Ur={..._,transform:Math.round};var to={rotate:G,rotateX:G,rotateY:G,rotateZ:G,scale:at,scaleX:at,scaleY:at,scaleZ:at,skew:G,skewX:G,skewY:G,distance:p,translateX:p,translateY:p,translateZ:p,x:p,y:p,z:p,perspective:p,transformPerspective:p,opacity:te,originX:Lt,originY:Lt,originZ:p};var Ae={borderWidth:p,borderTopWidth:p,borderRightWidth:p,borderBottomWidth:p,borderLeftWidth:p,borderRadius:p,radius:p,borderTopLeftRadius:p,borderTopRightRadius:p,borderBottomRightRadius:p,borderBottomLeftRadius:p,width:p,maxWidth:p,height:p,maxHeight:p,top:p,right:p,bottom:p,left:p,padding:p,paddingTop:p,paddingRight:p,paddingBottom:p,paddingLeft:p,margin:p,marginTop:p,marginRight:p,marginBottom:p,marginLeft:p,backgroundPositionX:p,backgroundPositionY:p,...to,zIndex:Ur,fillOpacity:te,strokeOpacity:te,numOctaves:Ur};var ro={...Ae,color:C,backgroundColor:C,outlineColor:C,fill:C,stroke:C,borderColor:C,borderTopColor:C,borderRightColor:C,borderBottomColor:C,borderLeftColor:C,filter:vt,WebkitFilter:vt},Vt=e=>ro[e];function St(e,t){let r=Vt(e);return r!==vt&&(r=L),r.getAnimatableNone?r.getAnimatableNone(t):void 0}var ps=new Set(["auto","none","0"]);function no(e,t,r){let n=0,o;for(;n<e.length&&!o;){let i=e[n];typeof i=="string"&&!ps.has(i)&&fe(i).values.length&&(o=e[n]),n++}if(o&&r)for(let i of t)e[i]=St(r,o)}var wt=class extends ie{constructor(t,r,n,o,i){super(t,r,n,o,i,!0)}readKeyframes(){let{unresolvedKeyframes:t,element:r,name:n}=this;if(!r||!r.current)return;super.readKeyframes();for(let l=0;l<t.length;l++){let f=t[l];if(typeof f=="string"&&(f=f.trim(),Te(f))){let m=$r(f,r.current);m!==void 0&&(t[l]=m),l===t.length-1&&(this.finalKeyframe=f)}}if(this.resolveNoneKeyframes(),!bt.has(n)||t.length!==2)return;let[o,i]=t,s=_r(o),a=_r(i);if(s!==a)if(kr(s)&&kr(a))for(let l=0;l<t.length;l++){let f=t[l];typeof f=="string"&&(t[l]=parseFloat(f))}else ue[n]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){let{unresolvedKeyframes:t,name:r}=this,n=[];for(let o=0;o<t.length;o++)(t[o]===null||eo(t[o]))&&n.push(o);n.length&&no(t,n,r)}measureInitialState(){let{element:t,unresolvedKeyframes:r,name:n}=this;if(!t||!t.current)return;n==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=ue[n](t.measureViewportBox(),window.getComputedStyle(t.current)),r[0]=this.measuredOrigin;let o=r[r.length-1];o!==void 0&&t.getValue(n,o).jump(o,!1)}measureEndState(){let{element:t,name:r,unresolvedKeyframes:n}=this;if(!t||!t.current)return;let o=t.getValue(r);o&&o.jump(this.measuredOrigin,!1);let i=n.length-1,s=n[i];n[i]=ue[r](t.measureViewportBox(),window.getComputedStyle(t.current)),s!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=s),this.removedTransforms?.length&&this.removedTransforms.forEach(([a,l])=>{t.getValue(a).set(l)}),this.resolveNoneKeyframes()}};function Ee(e,t,r){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let n=document;t&&(n=t.current);let o=r?.[e]??n.querySelectorAll(e);return o?Array.from(o):[]}return Array.from(e)}var Mt=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function Yr(e){return qe(e)&&"offsetHeight"in e}var oo=30,ds=e=>!isNaN(parseFloat(e)),qr={current:void 0},Jt=class{constructor(t,r={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=n=>{let o=P.now();if(this.updatedAt!==o&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(n),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(let i of this.dependents)i.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=r.owner}setCurrent(t){this.current=t,this.updatedAt=P.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=ds(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,r){this.events[t]||(this.events[t]=new xe);let n=this.events[t].add(r);return t==="change"?()=>{n(),O.read(()=>{this.events.change.getSize()||this.stop()})}:n}clearListeners(){for(let t in this.events)this.events[t].clear()}attach(t,r){this.passiveEffect=t,this.stopPassiveEffect=r}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,r,n){this.set(r),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-n}jump(t,r=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,r&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return qr.current&&qr.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){let t=P.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>oo)return 0;let r=Math.min(this.updatedAt-this.prevUpdatedAt,oo);return ye(parseFloat(this.current)-parseFloat(this.prevFrameValue),r)}start(t){return this.stop(),new Promise(r=>{this.hasAnimated=!0,this.animation=t(r),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function Y(e,t){return new Jt(e,t)}var{schedule:Xr,cancel:hs}=kt(queueMicrotask,!1);function Ce(e){return qe(e)&&"ownerSVGElement"in e}var Qt=new WeakMap,er,io=(e,t,r)=>(n,o)=>o&&o[0]?o[0][e+"Size"]:Ce(n)&&"getBBox"in n?n.getBBox()[t]:n[r],gs=io("inline","width","offsetWidth"),xs=io("block","height","offsetHeight");function ys({target:e,borderBoxSize:t}){Qt.get(e)?.forEach(r=>{r(e,{get width(){return gs(e,t)},get height(){return xs(e,t)}})})}function Ts(e){e.forEach(ys)}function bs(){typeof ResizeObserver>"u"||(er=new ResizeObserver(Ts))}function so(e,t){er||bs();let r=Ee(e);return r.forEach(n=>{let o=Qt.get(n);o||(o=new Set,Qt.set(n,o)),o.add(t),er?.observe(n)}),()=>{r.forEach(n=>{let o=Qt.get(n);o?.delete(t),o?.size||er?.unobserve(n)})}}var tr=new Set,Le;function vs(){Le=()=>{let e={get width(){return window.innerWidth},get height(){return window.innerHeight}};tr.forEach(t=>t(e))},window.addEventListener("resize",Le)}function ao(e){return tr.add(e),Le||vs(),()=>{tr.delete(e),!tr.size&&typeof Le=="function"&&(window.removeEventListener("resize",Le),Le=void 0)}}function Zr(e,t){return typeof e=="function"?ao(e):so(e,t)}function At(e,t){let r,n=()=>{let{currentTime:o}=t,s=(o===null?0:o.value)/100;r!==s&&e(s),r=s};return O.preUpdate(n,!0),()=>H(n)}function Jr(e){return Ce(e)&&e.tagName==="svg"}function lo(e,t){if(e==="first")return 0;{let r=t-1;return e==="last"?r:r/2}}function Qr(e=.1,{startDelay:t=0,from:r=0,ease:n}={}){return(o,i)=>{let s=typeof r=="number"?r:lo(r,i),a=Math.abs(s-o),l=e*a;if(n){let f=i*e;l=Oe(n)(l/f)*f}return t+l}}var A=e=>!!(e&&e.getVelocity);var Vs=[...Hr,C,L],en=e=>Vs.find(Zt(e));function Et(e){return typeof e=="object"&&!Array.isArray(e)}function rr(e,t,r,n){return typeof e=="string"&&Et(t)?Ee(e,r,n):e instanceof NodeList?Array.from(e):Array.isArray(e)?e:[e]}function mo(e,t,r){return e*(t+1)}function tn(e,t,r,n){return typeof t=="number"?t:t.startsWith("-")||t.startsWith("+")?Math.max(0,e+parseFloat(t)):t==="<"?r:t.startsWith("<")?Math.max(0,r+parseFloat(t.slice(1))):n.get(t)??e}function Ss(e,t,r){for(let n=0;n<e.length;n++){let o=e[n];o.at>t&&o.at<r&&(de(e,o),n--)}}function fo(e,t,r,n,o,i){Ss(e,o,i);for(let s=0;s<t.length;s++)e.push({value:t[s],at:z(o,i,n[s]),easing:nt(r,s)})}function co(e,t){for(let r=0;r<e.length;r++)e[r]=e[r]/(t+1)}function uo(e,t){return e.at===t.at?e.value===null?1:t.value===null?-1:0:e.at-t.at}var ws="easeInOut",Ms=20;function go(e,{defaultTransition:t={},...r}={},n,o){let i=t.duration||.3,s=new Map,a=new Map,l={},f=new Map,m=0,c=0,u=0;for(let h=0;h<e.length;h++){let T=e[h];if(typeof T=="string"){f.set(T,c);continue}else if(!Array.isArray(T)){f.set(T.name,tn(c,T.at,m,f));continue}let[g,b,y={}]=T;y.at!==void 0&&(c=tn(c,y.at,m,f));let E=0,V=(S,d,v,D=0,x=0)=>{let w=As(S),{delay:K=0,times:$=be(w),type:br="keyframes",repeat:$e,repeatType:na,repeatDelay:oa=0,...hi}=d,{ease:se=t.ease||"easeOut",duration:Z}=d,an=typeof K=="function"?K(D,x):K,ln=w.length,mn=Me(br)?br:o?.[br||"keyframes"];if(ln<=2&&mn){let He=100;if(ln===2&&Ds(w)){let _e=w[1]-w[0];He=Math.abs(_e)}let Ft={...hi};Z!==void 0&&(Ft.duration=F(Z));let Pt=ft(Ft,He,mn);se=Pt.ease,Z=Pt.duration}Z??(Z=i);let fn=c+an;$.length===1&&$[0]===0&&($[1]=1);let cn=$.length-w.length;if(cn>0&&pt($,cn),w.length===1&&w.unshift(null),$e){N($e<Ms,"Repeat count too high, must be less than 20","repeat-count-high"),Z=mo(Z,$e);let He=[...w],Ft=[...$];se=Array.isArray(se)?[...se]:[se];let Pt=[...se];for(let _e=0;_e<$e;_e++){w.push(...He);for(let Ue=0;Ue<He.length;Ue++)$.push(Ft[Ue]+(_e+1)),se.push(Ue===0?"linear":nt(Pt,Ue-1))}co($,$e)}let un=fn+Z;fo(v,w,se,$,fn,un),E=Math.max(an+Z,E),u=Math.max(un,u)};if(A(g)){let S=po(g,a);V(b,y,ho("default",S))}else{let S=rr(g,b,n,l),d=S.length;for(let v=0;v<d;v++){b=b,y=y;let D=S[v],x=po(D,a);for(let w in b)V(b[w],Es(y,w),ho(w,x),v,d)}}m=c,c+=E}return a.forEach((h,T)=>{for(let g in h){let b=h[g];b.sort(uo);let y=[],E=[],V=[];for(let d=0;d<b.length;d++){let{at:v,value:D,easing:x}=b[d];y.push(D),E.push(Q(0,u,v)),V.push(x||"easeOut")}E[0]!==0&&(E.unshift(0),y.unshift(y[0]),V.unshift(ws)),E[E.length-1]!==1&&(E.push(1),y.push(null)),s.has(T)||s.set(T,{keyframes:{},transition:{}});let S=s.get(T);S.keyframes[g]=y,S.transition[g]={...t,duration:u,ease:V,times:E,...r}}}),s}function po(e,t){return!t.has(e)&&t.set(e,{}),t.get(e)}function ho(e,t){return t[e]||(t[e]=[]),t[e]}function As(e){return Array.isArray(e)?e:[e]}function Es(e,t){return e&&e[t]?{...e,...e[t]}:{...e}}var Cs=e=>typeof e=="number",Ds=e=>e.every(Cs);var pe=new WeakMap;var xo=e=>Array.isArray(e);function yo(e){let t=[{},{}];return e?.values.forEach((r,n)=>{t[0][n]=r.get(),t[1][n]=r.getVelocity()}),t}function nr(e,t,r,n){if(typeof t=="function"){let[o,i]=yo(n);t=t(r!==void 0?r:e.custom,o,i)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){let[o,i]=yo(n);t=t(r!==void 0?r:e.custom,o,i)}return t}function To(e,t,r){let n=e.getProps();return nr(n,t,r!==void 0?r:n.custom,e)}function Os(e,t,r){e.hasValue(t)?e.getValue(t).set(r):e.addValue(t,Y(r))}function Fs(e){return xo(e)?e[e.length-1]||0:e}function bo(e,t){let r=To(e,t),{transitionEnd:n={},transition:o={},...i}=r||{};i={...i,...n};for(let s in i){let a=Fs(i[s]);Os(e,s,a)}}function vo(e){return!!(A(e)&&e.add)}function Vo(e,t){let r=e.getValue("willChange");if(vo(r))return r.add(t);if(!r&&k.WillChange){let n=new k.WillChange("auto");e.addValue("willChange",n),n.add(t)}}var We=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase();var Ps="framerAppearId",So="data-"+We(Ps);function wo(e){return e.props[So]}var Is=e=>e!==null;function Mo(e,{repeat:t,repeatType:r="loop"},n){let o=e.filter(Is),i=t&&r!=="loop"&&t%2===1?0:o.length-1;return!i||n===void 0?o[i]:n}var Rs={type:"spring",stiffness:500,damping:25,restSpeed:10},Bs=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),ks={type:"keyframes",duration:.8},Ns={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Ao=(e,{keyframes:t})=>t.length>2?ks:W.has(e)?e.startsWith("scale")?Bs(t[1]):Rs:Ns;function Eo({when:e,delay:t,delayChildren:r,staggerChildren:n,staggerDirection:o,repeat:i,repeatType:s,repeatDelay:a,from:l,elapsed:f,...m}){return!!Object.keys(m).length}var or=(e,t,r,n={},o,i)=>s=>{let a=Tt(n,e)||{},l=a.delay||n.delay||0,{elapsed:f=0}=n;f=f-F(l);let m={keyframes:Array.isArray(r)?r:[null,r],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-f,onUpdate:u=>{t.set(u),a.onUpdate&&a.onUpdate(u)},onComplete:()=>{s(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:i?void 0:o};Eo(a)||Object.assign(m,Ao(e,m)),m.duration&&(m.duration=F(m.duration)),m.repeatDelay&&(m.repeatDelay=F(m.repeatDelay)),m.from!==void 0&&(m.keyframes[0]=m.from);let c=!1;if((m.type===!1||m.duration===0&&!m.repeatDelay)&&(Ke(m),m.delay===0&&(c=!0)),(k.instantAnimations||k.skipAnimations)&&(c=!0,Ke(m),m.delay=0),m.allowFlatten=!a.type&&!a.ease,c&&!i&&t.get()!==void 0){let u=Mo(m.keyframes,a);if(u!==void 0){O.update(()=>{m.onUpdate(u),m.onComplete()});return}}return a.isSync?new oe(m):new xt(m)};function Ks({protectedKeys:e,needsAnimating:t},r){let n=e.hasOwnProperty(r)&&t[r]!==!0;return t[r]=!1,n}function Co(e,t,{delay:r=0,transitionOverride:n,type:o}={}){let{transition:i=e.getDefaultTransition(),transitionEnd:s,...a}=t;n&&(i=n);let l=[],f=o&&e.animationState&&e.animationState.getState()[o];for(let m in a){let c=e.getValue(m,e.latestValues[m]??null),u=a[m];if(u===void 0||f&&Ks(f,m))continue;let h={delay:r,...Tt(i||{},m)},T=c.get();if(T!==void 0&&!c.isAnimating&&!Array.isArray(u)&&u===T&&!h.velocity)continue;let g=!1;if(window.MotionHandoffAnimation){let y=wo(e);if(y){let E=window.MotionHandoffAnimation(y,m,O);E!==null&&(h.startTime=E,g=!0)}}Vo(e,m),c.start(or(m,c,u,e.shouldReduceMotion&&bt.has(m)?{type:!1}:h,e,g));let b=c.animation;b&&l.push(b)}return s&&Promise.all(l).then(()=>{O.update(()=>{s&&bo(e,s)})}),l}function Do({top:e,left:t,right:r,bottom:n}){return{x:{min:t,max:r},y:{min:e,max:n}}}function Oo(e,t){if(!t)return e;let r=t({x:e.left,y:e.top}),n=t({x:e.right,y:e.bottom});return{top:r.y,left:r.x,bottom:n.y,right:n.x}}function Fo(e,t){return Do(Oo(e.getBoundingClientRect(),t))}var Po={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},ir={};for(let e in Po)ir[e]={isEnabled:t=>Po[e].some(r=>!!t[r])};var Io=()=>({min:0,max:0}),Ge=()=>({x:Io(),y:Io()});var Ro=typeof window<"u";var Ct={current:null},sr={current:!1};function Bo(){if(sr.current=!0,!!Ro)if(window.matchMedia){let e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Ct.current=e.matches;e.addEventListener("change",t),t()}else Ct.current=!1}function ko(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function No(e){return typeof e=="string"||Array.isArray(e)}var Ls=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Ko=["initial",...Ls];function rn(e){return ko(e.animate)||Ko.some(t=>No(e[t]))}function Lo(e){return!!(rn(e)||e.variants)}function Wo(e,t,r){for(let n in t){let o=t[n],i=r[n];if(A(o))e.addValue(n,o);else if(A(i))e.addValue(n,Y(o,{owner:e}));else if(i!==o)if(e.hasValue(n)){let s=e.getValue(n);s.liveStyle===!0?s.jump(o):s.hasAnimated||s.set(o)}else{let s=e.getStaticValue(n);e.addValue(n,Y(s!==void 0?s:o,{owner:e}))}}for(let n in r)t[n]===void 0&&e.removeValue(n);return t}var Go=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],ze=class{scrapeMotionValuesFromProps(t,r,n){return{}}constructor({parent:t,props:r,presenceContext:n,reducedMotionConfig:o,blockInitialAnimation:i,visualState:s},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=ie,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{let u=P.now();this.renderScheduledAt<u&&(this.renderScheduledAt=u,O.render(this.render,!1,!0))};let{latestValues:l,renderState:f}=s;this.latestValues=l,this.baseTarget={...l},this.initialValues=r.initial?{...l}:{},this.renderState=f,this.parent=t,this.props=r,this.presenceContext=n,this.depth=t?t.depth+1:0,this.reducedMotionConfig=o,this.options=a,this.blockInitialAnimation=!!i,this.isControllingVariants=rn(r),this.isVariantNode=Lo(r),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);let{willChange:m,...c}=this.scrapeMotionValuesFromProps(r,{},this);for(let u in c){let h=c[u];l[u]!==void 0&&A(h)&&h.set(l[u])}}mount(t){this.current=t,pe.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((r,n)=>this.bindToMotionValue(n,r)),sr.current||Bo(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Ct.current,this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),H(this.notifyUpdate),H(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(let t in this.events)this.events[t].clear();for(let t in this.features){let r=this.features[t];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,r){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();let n=W.has(t);n&&this.onBindTransform&&this.onBindTransform();let o=r.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&O.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()}),i;window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,t,r)),this.valueSubscriptions.set(t,()=>{o(),i&&i(),r.owner&&r.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in ir){let r=ir[t];if(!r)continue;let{isEnabled:n,Feature:o}=r;if(!this.features[t]&&o&&n(this.props)&&(this.features[t]=new o(this)),this.features[t]){let i=this.features[t];i.isMounted?i.update():(i.mount(),i.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Ge()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,r){this.latestValues[t]=r}update(t,r){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=r;for(let n=0;n<Go.length;n++){let o=Go[n];this.propEventSubscriptions[o]&&(this.propEventSubscriptions[o](),delete this.propEventSubscriptions[o]);let i="on"+o,s=t[i];s&&(this.propEventSubscriptions[o]=this.on(o,s))}this.prevMotionValues=Wo(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){let r=this.getClosestVariantNode();if(r)return r.variantChildren&&r.variantChildren.add(t),()=>r.variantChildren.delete(t)}addValue(t,r){let n=this.values.get(t);r!==n&&(n&&this.removeValue(t),this.bindToMotionValue(t,r),this.values.set(t,r),this.latestValues[t]=r.get())}removeValue(t){this.values.delete(t);let r=this.valueSubscriptions.get(t);r&&(r(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,r){if(this.props.values&&this.props.values[t])return this.props.values[t];let n=this.values.get(t);return n===void 0&&r!==void 0&&(n=Y(r===null?void 0:r,{owner:this}),this.addValue(t,n)),n}readValue(t,r){let n=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return n!=null&&(typeof n=="string"&&(Ye(n)||Xe(n))?n=parseFloat(n):!en(n)&&L.test(r)&&(n=St(t,r)),this.setBaseTarget(t,A(n)?n.get():n)),A(n)?n.get():n}setBaseTarget(t,r){this.baseTarget[t]=r}getBaseTarget(t){let{initial:r}=this.props,n;if(typeof r=="string"||typeof r=="object"){let i=nr(this.props,r,this.presenceContext?.custom);i&&(n=i[t])}if(r&&n!==void 0)return n;let o=this.getBaseTargetFromProps(this.props,t);return o!==void 0&&!A(o)?o:this.initialValues[t]!==void 0&&n===void 0?void 0:this.baseTarget[t]}on(t,r){return this.events[t]||(this.events[t]=new xe),this.events[t].add(r)}notify(t,...r){this.events[t]&&this.events[t].notify(...r)}scheduleRenderMicrotask(){Xr.render(this.render)}};var je=class extends ze{constructor(){super(...arguments),this.KeyframeResolver=wt}sortInstanceNodePosition(t,r){return t.compareDocumentPosition(r)&2?1:-1}getBaseTargetFromProps(t,r){return t.style?t.style[r]:void 0}removeValueFromRenderState(t,{vars:r,style:n}){delete r[t],delete n[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:t}=this.props;A(t)&&(this.childSubscription=t.on("change",r=>{this.current&&(this.current.textContent=`${r}`)}))}};var Ws={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Gs=j.length;function zo(e,t,r){let n="",o=!0;for(let i=0;i<Gs;i++){let s=j[i],a=e[s];if(a===void 0)continue;let l=!0;if(typeof a=="number"?l=a===(s.startsWith("scale")?1:0):l=parseFloat(a)===0,!l||r){let f=Mt(a,Ae[s]);if(!l){o=!1;let m=Ws[s]||s;n+=`${m}(${f}) `}r&&(t[s]=f)}}return n=n.trim(),r?n=r(t,o?"":n):o&&(n="none"),n}function ar(e,t,r){let{style:n,vars:o,transformOrigin:i}=e,s=!1,a=!1;for(let l in t){let f=t[l];if(W.has(l)){s=!0;continue}else if(st(l)){o[l]=f;continue}else{let m=Mt(f,Ae[l]);l.startsWith("origin")?(a=!0,i[l]=m):n[l]=m}}if(t.transform||(s||r?n.transform=zo(t,e.transform,r):n.transform&&(n.transform="none")),a){let{originX:l="50%",originY:f="50%",originZ:m=0}=i;n.transformOrigin=`${l} ${f} ${m}`}}function lr(e,{style:t,vars:r},n,o){let i=e.style,s;for(s in t)i[s]=t[s];o?.applyProjectionStyles(i,n);for(s in r)i.setProperty(s,r[s])}var jo={};function $o(e,{layout:t,layoutId:r}){return W.has(e)||e.startsWith("origin")||(t||r!==void 0)&&(!!jo[e]||e==="opacity")}function mr(e,t,r){let{style:n}=e,o={};for(let i in n)(A(n[i])||t.style&&A(t.style[i])||$o(i,e)||r?.getValue(i)?.liveStyle!==void 0)&&(o[i]=n[i]);return o}function zs(e){return window.getComputedStyle(e)}var fr=class extends je{constructor(){super(...arguments),this.type="html",this.renderInstance=lr}readValueFromInstance(t,r){if(W.has(r))return this.projection?.isProjecting?dt(r):Br(t,r);{let n=zs(t),o=(st(r)?n.getPropertyValue(r):n[r])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:r}){return Fo(t,r)}build(t,r,n){ar(t,r,n.transformTemplate)}scrapeMotionValuesFromProps(t,r,n){return mr(t,r,n)}};function js(e,t){return e in t}var cr=class extends ze{constructor(){super(...arguments),this.type="object"}readValueFromInstance(t,r){if(js(r,t)){let n=t[r];if(typeof n=="string"||typeof n=="number")return n}}getBaseTargetFromProps(){}removeValueFromRenderState(t,r){delete r.output[t]}measureInstanceViewportBox(){return Ge()}build(t,r){Object.assign(t.output,r)}renderInstance(t,{output:r}){Object.assign(t,r)}sortInstanceNodePosition(){return 0}};var $s={offset:"stroke-dashoffset",array:"stroke-dasharray"},Hs={offset:"strokeDashoffset",array:"strokeDasharray"};function Ho(e,t,r=1,n=0,o=!0){e.pathLength=1;let i=o?$s:Hs;e[i.offset]=p.transform(-n);let s=p.transform(t),a=p.transform(r);e[i.array]=`${s} ${a}`}function _o(e,{attrX:t,attrY:r,attrScale:n,pathLength:o,pathSpacing:i=1,pathOffset:s=0,...a},l,f,m){if(ar(e,a,f),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};let{attrs:c,style:u}=e;c.transform&&(u.transform=c.transform,delete c.transform),(u.transform||c.transformOrigin)&&(u.transformOrigin=c.transformOrigin??"50% 50%",delete c.transformOrigin),u.transform&&(u.transformBox=m?.transformBox??"fill-box",delete c.transformBox),t!==void 0&&(c.x=t),r!==void 0&&(c.y=r),n!==void 0&&(c.scale=n),o!==void 0&&Ho(c,o,i,s,!1)}var ur=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);var Uo=e=>typeof e=="string"&&e.toLowerCase()==="svg";function Yo(e,t,r,n){lr(e,t,void 0,n);for(let o in t.attrs)e.setAttribute(ur.has(o)?o:We(o),t.attrs[o])}function qo(e,t,r){let n=mr(e,t,r);for(let o in e)if(A(e[o])||A(t[o])){let i=j.indexOf(o)!==-1?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o;n[i]=e[o]}return n}var pr=class extends je{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Ge}getBaseTargetFromProps(t,r){return t[r]}readValueFromInstance(t,r){if(W.has(r)){let n=Vt(r);return n&&n.default||0}return r=ur.has(r)?r:We(r),t.getAttribute(r)}scrapeMotionValuesFromProps(t,r,n){return qo(t,r,n)}build(t,r,n){_o(t,r,this.isSVGTag,n.transformTemplate,n.style)}renderInstance(t,r,n,o){Yo(t,r,n,o)}mount(t){this.isSVGTag=Uo(t.tagName),super.mount(t)}};function Xo(e){let t={presenceContext:null,props:{},visualState:{renderState:{transform:{},transformOrigin:{},style:{},vars:{},attrs:{}},latestValues:{}}},r=Ce(e)&&!Jr(e)?new pr(t):new fr(t);r.mount(e),pe.set(e,r)}function Zo(e){let t={presenceContext:null,props:{},visualState:{renderState:{output:{}},latestValues:{}}},r=new cr(t);r.mount(e),pe.set(e,r)}function Jo(e,t,r){let n=A(e)?e:Y(e);return n.start(or("",n,t,r)),n.animation}function _s(e,t){return A(e)||typeof e=="number"||typeof e=="string"&&!Et(t)}function dr(e,t,r,n){let o=[];if(_s(e,t))o.push(Jo(e,Et(t)&&t.default||t,r&&(r.default||r)));else{let i=rr(e,t,n),s=i.length;N(!!s,"No valid elements provided.","no-valid-elements");for(let a=0;a<s;a++){let l=i[a];N(l!==null,"You're trying to perform an animation on null. Ensure that selectors are correctly finding elements and refs are correctly hydrated.","animate-null");let f=l instanceof Element?Xo:Zo;pe.has(l)||f(l);let m=pe.get(l),c={...r};"delay"in c&&typeof c.delay=="function"&&(c.delay=c.delay(a,s)),o.push(...Co(m,{...t,transition:c},{}))}}return o}function Qo(e,t,r){let n=[];return go(e,t,r,{spring:ne}).forEach(({keyframes:i,transition:s},a)=>{n.push(...dr(a,i,s))}),n}function Us(e){return Array.isArray(e)&&e.some(Array.isArray)}function ei(e){function t(r,n,o){let i=[],s;if(Us(r))i=Qo(r,n,e);else{let{onComplete:l,...f}=o||{};typeof l=="function"&&(s=l),i=dr(r,n,f,e)}let a=new yt(i);return s&&a.finished.then(s),e&&(e.animations.push(a),a.finished.then(()=>{de(e.animations,a)})),a}return t}var q=ei();var Ys=50,ti=()=>({current:0,offset:[],progress:0,scrollLength:0,targetOffset:0,targetLength:0,containerLength:0,velocity:0}),ni=()=>({time:0,x:ti(),y:ti()}),qs={x:{length:"Width",position:"Left"},y:{length:"Height",position:"Top"}};function ri(e,t,r,n){let o=r[t],{length:i,position:s}=qs[t],a=o.current,l=r.time;o.current=e[`scroll${s}`],o.scrollLength=e[`scroll${i}`]-e[`client${i}`],o.offset.length=0,o.offset[0]=0,o.offset[1]=o.scrollLength,o.progress=Q(0,o.scrollLength,o.current);let f=n-l;o.velocity=f>Ys?0:ye(o.current-a,f)}function oi(e,t,r){ri(e,"x",t,r),ri(e,"y",t,r),t.time=r}function ii(e,t){let r={x:0,y:0},n=e;for(;n&&n!==t;)if(Yr(n))r.x+=n.offsetLeft,r.y+=n.offsetTop,n=n.offsetParent;else if(n.tagName==="svg"){let o=n.getBoundingClientRect();n=n.parentElement;let i=n.getBoundingClientRect();r.x+=o.left-i.left,r.y+=o.top-i.top}else if(n instanceof SVGGraphicsElement){let{x:o,y:i}=n.getBBox();r.x+=o,r.y+=i;let s=null,a=n.parentNode;for(;!s;)a.tagName==="svg"&&(s=a),a=n.parentNode;n=s}else break;return r}var hr={start:0,center:.5,end:1};function nn(e,t,r=0){let n=0;if(e in hr&&(e=hr[e]),typeof e=="string"){let o=parseFloat(e);e.endsWith("px")?n=o:e.endsWith("%")?e=o/100:e.endsWith("vw")?n=o/100*document.documentElement.clientWidth:e.endsWith("vh")?n=o/100*document.documentElement.clientHeight:e=o}return typeof e=="number"&&(n=t*e),r+n}var Xs=[0,0];function si(e,t,r,n){let o=Array.isArray(e)?e:Xs,i=0,s=0;return typeof e=="number"?o=[e,e]:typeof e=="string"&&(e=e.trim(),e.includes(" ")?o=e.split(" "):o=[e,hr[e]?e:"0"]),i=nn(o[0],r,n),s=nn(o[1],t),i-s}var ai={Enter:[[0,1],[1,1]],Exit:[[0,0],[1,0]],Any:[[1,0],[0,1]],All:[[0,0],[1,1]]};var Zs={x:0,y:0};function Js(e){return"getBBox"in e&&e.tagName!=="svg"?e.getBBox():{width:e.clientWidth,height:e.clientHeight}}function li(e,t,r){let{offset:n=ai.All}=r,{target:o=e,axis:i="y"}=r,s=i==="y"?"height":"width",a=o!==e?ii(o,e):Zs,l=o===e?{width:e.scrollWidth,height:e.scrollHeight}:Js(o),f={width:e.clientWidth,height:e.clientHeight};t[i].offset.length=0;let m=!t[i].interpolate,c=n.length;for(let u=0;u<c;u++){let h=si(n[u],f[s],l[s],a[i]);!m&&h!==t[i].interpolatorOffsets[u]&&(m=!0),t[i].offset[u]=h}m&&(t[i].interpolate=ut(t[i].offset,be(n),{clamp:!1}),t[i].interpolatorOffsets=[...t[i].offset]),t[i].progress=B(0,1,t[i].interpolate(t[i].current))}function Qs(e,t=e,r){if(r.x.targetOffset=0,r.y.targetOffset=0,t!==e){let n=t;for(;n&&n!==e;)r.x.targetOffset+=n.offsetLeft,r.y.targetOffset+=n.offsetTop,n=n.offsetParent}r.x.targetLength=t===e?t.scrollWidth:t.clientWidth,r.y.targetLength=t===e?t.scrollHeight:t.clientHeight,r.x.containerLength=e.clientWidth,r.y.containerLength=e.clientHeight}function mi(e,t,r,n={}){return{measure:o=>{Qs(e,n.target,r),oi(e,r,o),(n.offset||n.target)&&li(e,r,n)},notify:()=>t(r)}}var Dt=new WeakMap,fi=new WeakMap,on=new WeakMap,ci=e=>e===document.scrollingElement?window:e;function gr(e,{container:t=document.scrollingElement,...r}={}){if(!t)return I;let n=on.get(t);n||(n=new Set,on.set(t,n));let o=ni(),i=mi(t,e,o,r);if(n.add(i),!Dt.has(t)){let a=()=>{for(let c of n)c.measure(ee.timestamp);O.preUpdate(l)},l=()=>{for(let c of n)c.notify()},f=()=>O.read(a);Dt.set(t,f);let m=ci(t);window.addEventListener("resize",f,{passive:!0}),t!==document.documentElement&&fi.set(t,Zr(t,f)),m.addEventListener("scroll",f,{passive:!0}),f()}let s=Dt.get(t);return O.read(s,!1,!0),()=>{H(s);let a=on.get(t);if(!a||(a.delete(i),a.size))return;let l=Dt.get(t);Dt.delete(t),l&&(ci(t).removeEventListener("scroll",l),fi.get(t)?.(),window.removeEventListener("resize",l))}}var ui=new Map;function ea(e){let t={value:0},r=gr(n=>{t.value=n[e.axis].progress*100},e);return{currentTime:t,cancel:r}}function xr({source:e,container:t,...r}){let{axis:n}=r;e&&(t=e);let o=ui.get(t)??new Map;ui.set(t,o);let i=r.target??"self",s=o.get(i)??{},a=n+(r.offset??[]).join(",");return s[a]||(s[a]=!r.target&&gt()?new ScrollTimeline({source:t,axis:n}):ea({container:t,...r})),s[a]}function pi(e,t){let r=xr(t);return e.attachTimeline({timeline:t.target?void 0:r,observe:n=>(n.pause(),At(o=>{n.time=n.iterationDuration*o},r))})}function ta(e){return e.length===2}function di(e,t){return ta(e)?gr(r=>{e(r[t.axis].progress,r)},t):At(e,xr(t))}function yr(e,{axis:t="y",container:r=document.scrollingElement,...n}={}){if(!r)return I;let o={axis:t,container:r,...n};return typeof e=="function"?di(e,o):pi(e,o)}var ra={some:0,all:1};function X(e,t,{root:r,margin:n,amount:o="some"}={}){let i=Ee(e),s=new WeakMap,a=f=>{f.forEach(m=>{let c=s.get(m.target);if(m.isIntersecting!==!!c)if(m.isIntersecting){let u=t(m.target,m);typeof u=="function"?s.set(m.target,u):l.unobserve(m.target)}else typeof c=="function"&&(c(m),s.delete(m.target))})},l=new IntersectionObserver(a,{root:r,rootMargin:n,threshold:typeof o=="number"?o:ra[o]});return i.forEach(f=>l.observe(f)),()=>l.disconnect()}var sn={fadeIn:(e,t={})=>X(e,()=>{q(e,{opacity:[0,1]},{duration:t.duration||.8,delay:t.delay||0,easing:t.easing||"ease-out"})},{amount:t.amount||.25}),slideUp:(e,t={})=>X(e,()=>{q(e,{y:[t.distance||50,0],opacity:[0,1]},{duration:t.duration||.8,delay:t.delay||0,easing:t.easing||"ease-out"})},{amount:t.amount||.25}),slideDown:(e,t={})=>X(e,()=>{q(e,{y:[-(t.distance||50),0],opacity:[0,1]},{duration:t.duration||.8,delay:t.delay||0,easing:t.easing||"ease-out"})},{amount:t.amount||.25}),slideLeft:(e,t={})=>X(e,()=>{q(e,{x:[t.distance||50,0],opacity:[0,1]},{duration:t.duration||.8,delay:t.delay||0,easing:t.easing||"ease-out"})},{amount:t.amount||.25}),slideRight:(e,t={})=>X(e,()=>{q(e,{x:[-(t.distance||50),0],opacity:[0,1]},{duration:t.duration||.8,delay:t.delay||0,easing:t.easing||"ease-out"})},{amount:t.amount||.25}),scale:(e,t={})=>X(e,()=>{q(e,{scale:[t.from||.8,1],opacity:[0,1]},{duration:t.duration||.8,delay:t.delay||0,easing:t.easing||[.34,1.56,.64,1]})},{amount:t.amount||.25}),parallax:(e,t={})=>yr(q(e,{y:[0,t.distance||100]}),{target:e,offset:t.offset||["start end","end start"]})},Tr=class{constructor(){this.animations=[]}init(){document.querySelectorAll("[data-wms-animate]").forEach(t=>{let r=t.dataset.wmsAnimate,n={duration:parseFloat(t.dataset.wmsDuration)||void 0,delay:parseFloat(t.dataset.wmsDelay)||void 0,distance:parseFloat(t.dataset.wmsDistance)||void 0,amount:parseFloat(t.dataset.wmsAmount)||void 0,easing:parseFloat(t.dataset.wmsEasing)||void 0};if(Object.keys(n).forEach(o=>{n[o]===void 0&&delete n[o]}),sn[r])try{let o=sn[r](t,n);this.animations.push(o)}catch(o){console.error(`Failed to apply animation "${r}":`,o)}else console.warn(`Unknown animation type: "${r}"`)}),this.initScrollShrink()}initScrollShrink(){document.querySelectorAll("[data-wms-scroll-toggle]").forEach(t=>{let r=parseInt(t.dataset.wmsThreshold)||80,n=t.dataset.wmsScrollToggle||"wms-scrolled",o=document.createElement("div");o.style.height=r+"px",o.style.pointerEvents="none",t.before(o),X(o,()=>t.classList.remove(n),{root:null,margin:"0px 0px 0px 0px",amount:"any"}),new IntersectionObserver(s=>{s.forEach(a=>{a.isIntersecting||t.classList.add(n)})},{root:null,threshold:0}).observe(o)})}destroy(){this.animations=[]}},Ot;document.readyState==="loading"?document.addEventListener("DOMContentLoaded",()=>{Ot=new Tr,Ot.init()}):(Ot=new Tr,Ot.init());window.motion={animate:q,inView:X,scroll:yr,stagger:Qr,presets:sn,manager:Ot};})();
1
+ (()=>{function vr(e,t){e.indexOf(t)===-1&&e.push(t)}function de(e,t){let r=e.indexOf(t);r>-1&&e.splice(r,1)}var B=(e,t,r)=>r>t?t:r<e?e:r;var Z=()=>{},N=()=>{};var k={};var Ye=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function qe(e){return typeof e=="object"&&e!==null}var Xe=e=>/^0[^.\s]+$/u.test(e);function he(e){let t;return()=>(t===void 0&&(t=e()),t)}var I=e=>e;var gi=(e,t)=>r=>t(e(r)),ge=(...e)=>e.reduce(gi);var J=(e,t,r)=>{let n=t-e;return n===0?1:(r-e)/n};var xe=class{constructor(){this.subscriptions=[]}add(t){return vr(this.subscriptions,t),()=>de(this.subscriptions,t)}notify(t,r,n){let o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](t,r,n);else for(let i=0;i<o;i++){let s=this.subscriptions[i];s&&s(t,r,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}};var F=e=>e*1e3,R=e=>e/1e3;function ye(e,t){return t?e*(1e3/t):0}var pn=(e,t,r)=>{let n=t-e;return((r-e)%n+n)%n+e};var dn=(e,t,r)=>(((1-3*r+3*t)*e+(3*r-6*t))*e+3*t)*e,xi=1e-7,yi=12;function Ti(e,t,r,n,o){let i,s,a=0;do s=t+(r-t)/2,i=dn(s,n,o)-e,i>0?r=s:t=s;while(Math.abs(i)>xi&&++a<yi);return s}function ae(e,t,r,n){if(e===t&&r===n)return I;let o=i=>Ti(i,0,1,e,r);return i=>i===0||i===1?i:dn(o(i),t,n)}var It=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2;var Rt=e=>t=>1-e(1-t);var Bt=ae(.33,1.53,.69,.99),De=Rt(Bt),Ze=It(De);var Je=e=>(e*=2)<1?.5*De(e):.5*(2-Math.pow(2,-10*(e-1)));var Qe=e=>1-Math.sin(Math.acos(e)),Vr=Rt(Qe),et=It(Qe);var Sr=ae(.42,0,1,1),wr=ae(0,0,.58,1),tt=ae(.42,0,.58,1);var rt=e=>Array.isArray(e)&&typeof e[0]!="number";function nt(e,t){return rt(e)?e[pn(0,e.length,t)]:e}var ot=e=>Array.isArray(e)&&typeof e[0]=="number";var hn={linear:I,easeIn:Sr,easeInOut:tt,easeOut:wr,circIn:Qe,circInOut:et,circOut:Vr,backIn:De,backInOut:Ze,backOut:Bt,anticipate:Je},bi=e=>typeof e=="string",Oe=e=>{if(ot(e)){N(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");let[t,r,n,o]=e;return ae(t,r,n,o)}else if(bi(e))return N(hn[e]!==void 0,`Invalid easing type '${e}'`,"invalid-easing-type"),hn[e];return e};var it=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];var Fe={value:null,addProjectionMetrics:null};function gn(e,t){let r=new Set,n=new Set,o=!1,i=!1,s=new WeakSet,a={delta:0,timestamp:0,isProcessing:!1},l=0;function f(c){s.has(c)&&(m.schedule(c),e()),l++,c(a)}let m={schedule:(c,u=!1,h=!1)=>{let g=h&&o?r:n;return u&&s.add(c),g.has(c)||g.add(c),c},cancel:c=>{n.delete(c),s.delete(c)},process:c=>{if(a=c,o){i=!0;return}o=!0,[r,n]=[n,r],r.forEach(f),t&&Fe.value&&Fe.value.frameloop[t].push(l),l=0,r.clear(),o=!1,i&&(i=!1,m.process(c))}};return m}var vi=40;function kt(e,t){let r=!1,n=!0,o={delta:0,timestamp:0,isProcessing:!1},i=()=>r=!0,s=it.reduce((V,S)=>(V[S]=gn(i,t?S:void 0),V),{}),{setup:a,read:l,resolveKeyframes:f,preUpdate:m,update:c,preRender:u,render:h,postRender:T}=s,g=()=>{let V=k.useManualTiming?o.timestamp:performance.now();r=!1,k.useManualTiming||(o.delta=n?1e3/60:Math.max(Math.min(V-o.timestamp,vi),1)),o.timestamp=V,o.isProcessing=!0,a.process(o),l.process(o),f.process(o),m.process(o),c.process(o),u.process(o),h.process(o),T.process(o),o.isProcessing=!1,r&&t&&(n=!1,e(g))},b=()=>{r=!0,n=!0,o.isProcessing||e(g)};return{schedule:it.reduce((V,S)=>{let d=s[S];return V[S]=(v,D=!1,x=!1)=>(r||b(),d.schedule(v,D,x)),V},{}),cancel:V=>{for(let S=0;S<it.length;S++)s[it[S]].cancel(V)},state:o,steps:s}}var{schedule:O,cancel:H,state:Q,steps:Vi}=kt(typeof requestAnimationFrame<"u"?requestAnimationFrame:I,!0);var Nt;function Si(){Nt=void 0}var P={now:()=>(Nt===void 0&&P.set(Q.isProcessing||k.useManualTiming?Q.timestamp:performance.now()),Nt),set:e=>{Nt=e,queueMicrotask(Si)}};var Pe={layout:0,mainThread:0,waapi:0};var xn=e=>t=>typeof t=="string"&&t.startsWith(e),st=xn("--"),wi=xn("var(--"),Te=e=>wi(e)?Mi.test(e.split("/*")[0].trim()):!1,Mi=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;var _={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},ee={..._,transform:e=>B(0,1,e)},at={..._,default:1};var le=e=>Math.round(e*1e5)/1e5;var Ie=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function yn(e){return e==null}var Tn=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu;var Re=(e,t)=>r=>!!(typeof r=="string"&&Tn.test(r)&&r.startsWith(e)||t&&!yn(r)&&Object.prototype.hasOwnProperty.call(r,t)),Lt=(e,t,r)=>n=>{if(typeof n!="string")return n;let[o,i,s,a]=n.match(Ie);return{[e]:parseFloat(o),[t]:parseFloat(i),[r]:parseFloat(s),alpha:a!==void 0?parseFloat(a):1}};var Ai=e=>B(0,255,e),Mr={..._,transform:e=>Math.round(Ai(e))},U={test:Re("rgb","red"),parse:Lt("red","green","blue"),transform:({red:e,green:t,blue:r,alpha:n=1})=>"rgba("+Mr.transform(e)+", "+Mr.transform(t)+", "+Mr.transform(r)+", "+le(ee.transform(n))+")"};function Ei(e){let t="",r="",n="",o="";return e.length>5?(t=e.substring(1,3),r=e.substring(3,5),n=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),r=e.substring(2,3),n=e.substring(3,4),o=e.substring(4,5),t+=t,r+=r,n+=n,o+=o),{red:parseInt(t,16),green:parseInt(r,16),blue:parseInt(n,16),alpha:o?parseInt(o,16)/255:1}}var lt={test:Re("#"),parse:Ei,transform:U.transform};var mt=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),G=mt("deg"),te=mt("%"),p=mt("px"),Ar=mt("vh"),Er=mt("vw"),Kt={...te,parse:e=>te.parse(e)/100,transform:e=>te.transform(e*100)};var me={test:Re("hsl","hue"),parse:Lt("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:r,alpha:n=1})=>"hsla("+Math.round(e)+", "+te.transform(le(t))+", "+te.transform(le(r))+", "+le(ee.transform(n))+")"};var C={test:e=>U.test(e)||lt.test(e)||me.test(e),parse:e=>U.test(e)?U.parse(e):me.test(e)?me.parse(e):lt.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?U.transform(e):me.transform(e),getAnimatableNone:e=>{let t=C.parse(e);return t.alpha=0,C.transform(t)}};var bn=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function Ci(e){return isNaN(e)&&typeof e=="string"&&(e.match(Ie)?.length||0)+(e.match(bn)?.length||0)>0}var Vn="number",Sn="color",Di="var",Oi="var(",vn="${}",Fi=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function fe(e){let t=e.toString(),r=[],n={color:[],number:[],var:[]},o=[],i=0,a=t.replace(Fi,l=>(C.test(l)?(n.color.push(i),o.push(Sn),r.push(C.parse(l))):l.startsWith(Oi)?(n.var.push(i),o.push(Di),r.push(l)):(n.number.push(i),o.push(Vn),r.push(parseFloat(l))),++i,vn)).split(vn);return{values:r,split:a,indexes:n,types:o}}function wn(e){return fe(e).values}function Mn(e){let{split:t,types:r}=fe(e),n=t.length;return o=>{let i="";for(let s=0;s<n;s++)if(i+=t[s],o[s]!==void 0){let a=r[s];a===Vn?i+=le(o[s]):a===Sn?i+=C.transform(o[s]):i+=o[s]}return i}}var Pi=e=>typeof e=="number"?0:C.test(e)?C.getAnimatableNone(e):e;function Ii(e){let t=wn(e);return Mn(e)(t.map(Pi))}var K={test:Ci,parse:wn,createTransformer:Mn,getAnimatableNone:Ii};function Cr(e,t,r){return r<0&&(r+=1),r>1&&(r-=1),r<1/6?e+(t-e)*6*r:r<1/2?t:r<2/3?e+(t-e)*(2/3-r)*6:e}function An({hue:e,saturation:t,lightness:r,alpha:n}){e/=360,t/=100,r/=100;let o=0,i=0,s=0;if(!t)o=i=s=r;else{let a=r<.5?r*(1+t):r+t-r*t,l=2*r-a;o=Cr(l,a,e+1/3),i=Cr(l,a,e),s=Cr(l,a,e-1/3)}return{red:Math.round(o*255),green:Math.round(i*255),blue:Math.round(s*255),alpha:n}}function Be(e,t){return r=>r>0?t:e}var z=(e,t,r)=>e+(t-e)*r;var Dr=(e,t,r)=>{let n=e*e,o=r*(t*t-n)+n;return o<0?0:Math.sqrt(o)},Ri=[lt,U,me],Bi=e=>Ri.find(t=>t.test(e));function En(e){let t=Bi(e);if(Z(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!t)return!1;let r=t.parse(e);return t===me&&(r=An(r)),r}var Or=(e,t)=>{let r=En(e),n=En(t);if(!r||!n)return Be(e,t);let o={...r};return i=>(o.red=Dr(r.red,n.red,i),o.green=Dr(r.green,n.green,i),o.blue=Dr(r.blue,n.blue,i),o.alpha=z(r.alpha,n.alpha,i),U.transform(o))};var Wt=new Set(["none","hidden"]);function Cn(e,t){return Wt.has(e)?r=>r<=0?e:t:r=>r>=1?t:e}function ki(e,t){return r=>z(e,t,r)}function Gt(e){return typeof e=="number"?ki:typeof e=="string"?Te(e)?Be:C.test(e)?Or:Ki:Array.isArray(e)?Dn:typeof e=="object"?C.test(e)?Or:Ni:Be}function Dn(e,t){let r=[...e],n=r.length,o=e.map((i,s)=>Gt(i)(i,t[s]));return i=>{for(let s=0;s<n;s++)r[s]=o[s](i);return r}}function Ni(e,t){let r={...e,...t},n={};for(let o in r)e[o]!==void 0&&t[o]!==void 0&&(n[o]=Gt(e[o])(e[o],t[o]));return o=>{for(let i in n)r[i]=n[i](o);return r}}function Li(e,t){let r=[],n={color:0,var:0,number:0};for(let o=0;o<t.values.length;o++){let i=t.types[o],s=e.indexes[i][n[i]],a=e.values[s]??0;r[o]=a,n[i]++}return r}var Ki=(e,t)=>{let r=K.createTransformer(t),n=fe(e),o=fe(t);return n.indexes.var.length===o.indexes.var.length&&n.indexes.color.length===o.indexes.color.length&&n.indexes.number.length>=o.indexes.number.length?Wt.has(e)&&!o.values.length||Wt.has(t)&&!n.values.length?Cn(e,t):ge(Dn(Li(n,o),o.values),r):(Z(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),Be(e,t))};function zt(e,t,r){return typeof e=="number"&&typeof t=="number"&&typeof r=="number"?z(e,t,r):Gt(e)(e,t)}var On=e=>{let t=({timestamp:r})=>e(r);return{start:(r=!0)=>O.update(t,r),stop:()=>H(t),now:()=>Q.isProcessing?Q.timestamp:P.now()}};var jt=(e,t,r=10)=>{let n="",o=Math.max(Math.round(t/r),2);for(let i=0;i<o;i++)n+=Math.round(e(i/(o-1))*1e4)/1e4+", ";return`linear(${n.substring(0,n.length-2)})`};function ke(e){let t=0,r=50,n=e.next(t);for(;!n.done&&t<2e4;)t+=r,n=e.next(t);return t>=2e4?1/0:t}function ft(e,t=100,r){let n=r({...e,keyframes:[0,t]}),o=Math.min(ke(n),2e4);return{type:"keyframes",ease:i=>n.next(o*i).value/t,duration:R(o)}}var Wi=5;function $t(e,t,r){let n=Math.max(t-Wi,0);return ye(r-e(n),t-n)}var M={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};var Pr=.001;function Fn({duration:e=M.duration,bounce:t=M.bounce,velocity:r=M.velocity,mass:n=M.mass}){let o,i;Z(e<=F(M.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let s=1-t;s=B(M.minDamping,M.maxDamping,s),e=B(M.minDuration,M.maxDuration,R(e)),s<1?(o=f=>{let m=f*s,c=m*e,u=m-r,h=Ht(f,s),T=Math.exp(-c);return Pr-u/h*T},i=f=>{let c=f*s*e,u=c*r+r,h=Math.pow(s,2)*Math.pow(f,2)*e,T=Math.exp(-c),g=Ht(Math.pow(f,2),s);return(-o(f)+Pr>0?-1:1)*((u-h)*T)/g}):(o=f=>{let m=Math.exp(-f*e),c=(f-r)*e+1;return-Pr+m*c},i=f=>{let m=Math.exp(-f*e),c=(r-f)*(e*e);return m*c});let a=5/e,l=zi(o,i,a);if(e=F(e),isNaN(l))return{stiffness:M.stiffness,damping:M.damping,duration:e};{let f=Math.pow(l,2)*n;return{stiffness:f,damping:s*2*Math.sqrt(n*f),duration:e}}}var Gi=12;function zi(e,t,r){let n=r;for(let o=1;o<Gi;o++)n=n-e(n)/t(n);return n}function Ht(e,t){return e*Math.sqrt(1-t*t)}var ji=["duration","bounce"],$i=["stiffness","damping","mass"];function Pn(e,t){return t.some(r=>e[r]!==void 0)}function Hi(e){let t={velocity:M.velocity,stiffness:M.stiffness,damping:M.damping,mass:M.mass,isResolvedFromDuration:!1,...e};if(!Pn(e,$i)&&Pn(e,ji))if(e.visualDuration){let r=e.visualDuration,n=2*Math.PI/(r*1.2),o=n*n,i=2*B(.05,1,1-(e.bounce||0))*Math.sqrt(o);t={...t,mass:M.mass,stiffness:o,damping:i}}else{let r=Fn(e);t={...t,...r,mass:M.mass},t.isResolvedFromDuration=!0}return t}function re(e=M.visualDuration,t=M.bounce){let r=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e,{restSpeed:n,restDelta:o}=r,i=r.keyframes[0],s=r.keyframes[r.keyframes.length-1],a={done:!1,value:i},{stiffness:l,damping:f,mass:m,duration:c,velocity:u,isResolvedFromDuration:h}=Hi({...r,velocity:-R(r.velocity||0)}),T=u||0,g=f/(2*Math.sqrt(l*m)),b=s-i,y=R(Math.sqrt(l/m)),E=Math.abs(b)<5;n||(n=E?M.restSpeed.granular:M.restSpeed.default),o||(o=E?M.restDelta.granular:M.restDelta.default);let V;if(g<1){let d=Ht(y,g);V=v=>{let D=Math.exp(-g*y*v);return s-D*((T+g*y*b)/d*Math.sin(d*v)+b*Math.cos(d*v))}}else if(g===1)V=d=>s-Math.exp(-y*d)*(b+(T+y*b)*d);else{let d=y*Math.sqrt(g*g-1);V=v=>{let D=Math.exp(-g*y*v),x=Math.min(d*v,300);return s-D*((T+g*y*b)*Math.sinh(x)+d*b*Math.cosh(x))/d}}let S={calculatedDuration:h&&c||null,next:d=>{let v=V(d);if(h)a.done=d>=c;else{let D=d===0?T:0;g<1&&(D=d===0?F(T):$t(V,d,v));let x=Math.abs(D)<=n,w=Math.abs(s-v)<=o;a.done=x&&w}return a.value=a.done?s:v,a},toString:()=>{let d=Math.min(ke(S),2e4),v=jt(D=>S.next(d*D).value,d,30);return d+"ms "+v},toTransition:()=>{}};return S}re.applyToOptions=e=>{let t=ft(e,100,re);return e.ease=t.ease,e.duration=F(t.duration),e.type="keyframes",e};function ct({keyframes:e,velocity:t=0,power:r=.8,timeConstant:n=325,bounceDamping:o=10,bounceStiffness:i=500,modifyTarget:s,min:a,max:l,restDelta:f=.5,restSpeed:m}){let c=e[0],u={done:!1,value:c},h=x=>a!==void 0&&x<a||l!==void 0&&x>l,T=x=>a===void 0?l:l===void 0||Math.abs(a-x)<Math.abs(l-x)?a:l,g=r*t,b=c+g,y=s===void 0?b:s(b);y!==b&&(g=y-c);let E=x=>-g*Math.exp(-x/n),V=x=>y+E(x),S=x=>{let w=E(x),L=V(x);u.done=Math.abs(w)<=f,u.value=u.done?y:L},d,v,D=x=>{h(u.value)&&(d=x,v=re({keyframes:[u.value,T(u.value)],velocity:$t(V,x,u.value),damping:o,stiffness:i,restDelta:f,restSpeed:m}))};return D(0),{calculatedDuration:null,next:x=>{let w=!1;return!v&&d===void 0&&(w=!0,S(x),D(x)),d!==void 0&&x>=d?v.next(x-d):(!w&&S(x),u)}}}function _i(e,t,r){let n=[],o=r||k.mix||zt,i=e.length-1;for(let s=0;s<i;s++){let a=o(e[s],e[s+1]);if(t){let l=Array.isArray(t)?t[s]||I:t;a=ge(l,a)}n.push(a)}return n}function ut(e,t,{clamp:r=!0,ease:n,mixer:o}={}){let i=e.length;if(N(i===t.length,"Both input and output ranges must be the same length","range-length"),i===1)return()=>t[0];if(i===2&&t[0]===t[1])return()=>t[1];let s=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());let a=_i(t,n,o),l=a.length,f=m=>{if(s&&m<e[0])return t[0];let c=0;if(l>1)for(;c<e.length-2&&!(m<e[c+1]);c++);let u=J(e[c],e[c+1],m);return a[c](u)};return r?m=>f(B(e[0],e[i-1],m)):f}function pt(e,t){let r=e[e.length-1];for(let n=1;n<=t;n++){let o=J(0,t,n);e.push(z(r,1,o))}}function be(e){let t=[0];return pt(t,e.length-1),t}function In(e,t){return e.map(r=>r*t)}function Ui(e,t){return e.map(()=>t||tt).splice(0,e.length-1)}function ve({duration:e=300,keyframes:t,times:r,ease:n="easeInOut"}){let o=rt(n)?n.map(Oe):Oe(n),i={done:!1,value:t[0]},s=In(r&&r.length===t.length?r:be(t),e),a=ut(s,t,{ease:Array.isArray(o)?o:Ui(t,o)});return{calculatedDuration:e,next:l=>(i.value=a(l),i.done=l>=e,i)}}var Yi=e=>e!==null;function Ne(e,{repeat:t,repeatType:r="loop"},n,o=1){let i=e.filter(Yi),a=o<0||t&&r!=="loop"&&t%2===1?0:i.length-1;return!a||n===void 0?i[a]:n}var qi={decay:ct,inertia:ct,tween:ve,keyframes:ve,spring:re};function _t(e){typeof e.type=="string"&&(e.type=qi[e.type])}var ce=class{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,r){return this.finished.then(t,r)}};var Xi=e=>e/100,ne=class extends ce{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{let{motionValue:r}=this.options;r&&r.updatedAt!==P.now()&&this.tick(P.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},Pe.mainThread++,this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){let{options:t}=this;_t(t);let{type:r=ve,repeat:n=0,repeatDelay:o=0,repeatType:i,velocity:s=0}=t,{keyframes:a}=t,l=r||ve;l!==ve&&typeof a[0]!="number"&&(this.mixKeyframes=ge(Xi,zt(a[0],a[1])),a=[0,100]);let f=l({...t,keyframes:a});i==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...a].reverse(),velocity:-s})),f.calculatedDuration===null&&(f.calculatedDuration=ke(f));let{calculatedDuration:m}=f;this.calculatedDuration=m,this.resolvedDuration=m+o,this.totalDuration=this.resolvedDuration*(n+1)-o,this.generator=f}updateTime(t){let r=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=r}tick(t,r=!1){let{generator:n,totalDuration:o,mixKeyframes:i,mirroredGenerator:s,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return n.next(0);let{delay:f=0,keyframes:m,repeat:c,repeatType:u,repeatDelay:h,type:T,onUpdate:g,finalKeyframe:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-o/this.speed,this.startTime)),r?this.currentTime=t:this.updateTime(t);let y=this.currentTime-f*(this.playbackSpeed>=0?1:-1),E=this.playbackSpeed>=0?y<0:y>o;this.currentTime=Math.max(y,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=o);let V=this.currentTime,S=n;if(c){let x=Math.min(this.currentTime,o)/a,w=Math.floor(x),L=x%1;!L&&x>=1&&(L=1),L===1&&w--,w=Math.min(w,c+1),!!(w%2)&&(u==="reverse"?(L=1-L,h&&(L-=h/a)):u==="mirror"&&(S=s)),V=B(0,1,L)*a}let d=E?{done:!1,value:m[0]}:S.next(V);i&&(d.value=i(d.value));let{done:v}=d;!E&&l!==null&&(v=this.playbackSpeed>=0?this.currentTime>=o:this.currentTime<=0);let D=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&v);return D&&T!==ct&&(d.value=Ne(m,this.options,b,this.speed)),g&&g(d.value),D&&this.finish(),d}then(t,r){return this.finished.then(t,r)}get duration(){return R(this.calculatedDuration)}get iterationDuration(){let{delay:t=0}=this.options||{};return this.duration+R(t)}get time(){return R(this.currentTime)}set time(t){t=F(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(P.now());let r=this.playbackSpeed!==t;this.playbackSpeed=t,r&&(this.time=R(this.currentTime))}play(){if(this.isStopped)return;let{driver:t=On,startTime:r}=this.options;this.driver||(this.driver=t(o=>this.tick(o))),this.options.onPlay?.();let n=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=n):this.holdTime!==null?this.startTime=n-this.holdTime:this.startTime||(this.startTime=r??n),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(P.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null,Pe.mainThread--}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}};function Rn(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}var Ve=e=>e*180/Math.PI,Ir=e=>{let t=Ve(Math.atan2(e[1],e[0]));return Rr(t)},Zi={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:Ir,rotateZ:Ir,skewX:e=>Ve(Math.atan(e[1])),skewY:e=>Ve(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},Rr=e=>(e=e%360,e<0&&(e+=360),e),Bn=Ir,kn=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),Nn=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),Ji={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:kn,scaleY:Nn,scale:e=>(kn(e)+Nn(e))/2,rotateX:e=>Rr(Ve(Math.atan2(e[6],e[5]))),rotateY:e=>Rr(Ve(Math.atan2(-e[2],e[0]))),rotateZ:Bn,rotate:Bn,skewX:e=>Ve(Math.atan(e[4])),skewY:e=>Ve(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function dt(e){return e.includes("scale")?1:0}function ht(e,t){if(!e||e==="none")return dt(t);let r=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u),n,o;if(r)n=Ji,o=r;else{let a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);n=Zi,o=a}if(!o)return dt(t);let i=n[t],s=o[1].split(",").map(Qi);return typeof i=="function"?i(s):s[i]}var Br=(e,t)=>{let{transform:r="none"}=getComputedStyle(e);return ht(r,t)};function Qi(e){return parseFloat(e.trim())}var j=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],W=new Set(j);var kr=e=>e===_||e===p,es=new Set(["x","y","z"]),ts=j.filter(e=>!es.has(e));function Ln(e){let t=[];return ts.forEach(r=>{let n=e.getValue(r);n!==void 0&&(t.push([r,n.get()]),n.set(r.startsWith("scale")?1:0))}),t}var ue={width:({x:e},{paddingLeft:t="0",paddingRight:r="0"})=>e.max-e.min-parseFloat(t)-parseFloat(r),height:({y:e},{paddingTop:t="0",paddingBottom:r="0"})=>e.max-e.min-parseFloat(t)-parseFloat(r),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>ht(t,"x"),y:(e,{transform:t})=>ht(t,"y")};ue.translateX=ue.x;ue.translateY=ue.y;var Se=new Set,Nr=!1,Lr=!1,Kr=!1;function Kn(){if(Lr){let e=Array.from(Se).filter(n=>n.needsMeasurement),t=new Set(e.map(n=>n.element)),r=new Map;t.forEach(n=>{let o=Ln(n);o.length&&(r.set(n,o),n.render())}),e.forEach(n=>n.measureInitialState()),t.forEach(n=>{n.render();let o=r.get(n);o&&o.forEach(([i,s])=>{n.getValue(i)?.set(s)})}),e.forEach(n=>n.measureEndState()),e.forEach(n=>{n.suspendedScrollY!==void 0&&window.scrollTo(0,n.suspendedScrollY)})}Lr=!1,Nr=!1,Se.forEach(e=>e.complete(Kr)),Se.clear()}function Wn(){Se.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Lr=!0)})}function Wr(){Kr=!0,Wn(),Kn(),Kr=!1}var oe=class{constructor(t,r,n,o,i,s=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=r,this.name=n,this.motionValue=o,this.element=i,this.isAsync=s}scheduleResolve(){this.state="scheduled",this.isAsync?(Se.add(this),Nr||(Nr=!0,O.read(Wn),O.resolveKeyframes(Kn))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:t,name:r,element:n,motionValue:o}=this;if(t[0]===null){let i=o?.get(),s=t[t.length-1];if(i!==void 0)t[0]=i;else if(n&&r){let a=n.readValue(r,s);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=s),o&&i===void 0&&o.set(t[0])}Rn(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Se.delete(this)}cancel(){this.state==="scheduled"&&(Se.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}};var Gn=e=>e.startsWith("--");function zn(e,t,r){Gn(t)?e.style.setProperty(t,r):e.style[t]=r}var gt=he(()=>window.ScrollTimeline!==void 0);var jn={};function $n(e,t){let r=he(e);return()=>jn[t]??r()}var Ut=$n(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing");var we=([e,t,r,n])=>`cubic-bezier(${e}, ${t}, ${r}, ${n})`;var Gr={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:we([0,.65,.55,1]),circOut:we([.55,0,1,.45]),backIn:we([.31,.01,.66,-.59]),backOut:we([.33,1.53,.69,.99])};function zr(e,t){if(e)return typeof e=="function"?Ut()?jt(e,t):"ease-out":ot(e)?we(e):Array.isArray(e)?e.map(r=>zr(r,t)||Gr.easeOut):Gr[e]}function Hn(e,t,r,{delay:n=0,duration:o=300,repeat:i=0,repeatType:s="loop",ease:a="easeOut",times:l}={},f=void 0){let m={[t]:r};l&&(m.offset=l);let c=zr(a,o);Array.isArray(c)&&(m.easing=c),Fe.value&&Pe.waapi++;let u={delay:n,duration:o,easing:Array.isArray(c)?"linear":c,fill:"both",iterations:i+1,direction:s==="reverse"?"alternate":"normal"};f&&(u.pseudoElement=f);let h=e.animate(m,u);return Fe.value&&h.finished.finally(()=>{Pe.waapi--}),h}function Me(e){return typeof e=="function"&&"applyToOptions"in e}function _n({type:e,...t}){return Me(e)&&Ut()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}var Yt=class extends ce{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,!t)return;let{element:r,name:n,keyframes:o,pseudoElement:i,allowFlatten:s=!1,finalKeyframe:a,onComplete:l}=t;this.isPseudoElement=!!i,this.allowFlatten=s,this.options=t,N(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");let f=_n(t);this.animation=Hn(r,n,o,f,i),f.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){let m=Ne(o,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(m):zn(r,n,m),this.animation.cancel()}l?.(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;let{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){let t=this.animation.effect?.getComputedTiming?.().duration||0;return R(Number(t))}get iterationDuration(){let{delay:t=0}=this.options||{};return this.duration+R(t)}get time(){return R(Number(this.animation.currentTime)||0)}set time(t){this.finishedTime=null,this.animation.currentTime=F(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(t){this.animation.startTime=t}attachTimeline({timeline:t,observe:r}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&gt()?(this.animation.timeline=t,I):r(this)}};var Un={anticipate:Je,backInOut:Ze,circInOut:et};function rs(e){return e in Un}function Yn(e){typeof e.ease=="string"&&rs(e.ease)&&(e.ease=Un[e.ease])}var qn=10,qt=class extends Yt{constructor(t){Yn(t),_t(t),super(t),t.startTime&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){let{motionValue:r,onUpdate:n,onComplete:o,element:i,...s}=this.options;if(!r)return;if(t!==void 0){r.set(t);return}let a=new ne({...s,autoplay:!1}),l=F(this.finishedTime??this.time);r.setWithVelocity(a.sample(l-qn).value,a.sample(l).value,qn),a.stop()}};var jr=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(K.test(e)||e==="0")&&!e.startsWith("url("));function ns(e){let t=e[0];if(e.length===1)return!0;for(let r=0;r<e.length;r++)if(e[r]!==t)return!0}function Xn(e,t,r,n){let o=e[0];if(o===null)return!1;if(t==="display"||t==="visibility")return!0;let i=e[e.length-1],s=jr(o,t),a=jr(i,t);return Z(s===a,`You are trying to animate ${t} from "${o}" to "${i}". "${s?i:o}" is not an animatable value.`,"value-not-animatable"),!s||!a?!1:ns(e)||(r==="spring"||Me(r))&&n}function Le(e){e.duration=0,e.type="keyframes"}var os=new Set(["opacity","clipPath","filter","transform"]),is=he(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function Zn(e){let{motionValue:t,name:r,repeatDelay:n,repeatType:o,damping:i,type:s}=e;if(!(t?.owner?.current instanceof HTMLElement))return!1;let{onUpdate:l,transformTemplate:f}=t.owner.getProps();return is()&&r&&os.has(r)&&(r!=="transform"||!f)&&!l&&!n&&o!=="mirror"&&i!==0&&s!=="inertia"}var ss=40,xt=class extends ce{constructor({autoplay:t=!0,delay:r=0,type:n="keyframes",repeat:o=0,repeatDelay:i=0,repeatType:s="loop",keyframes:a,name:l,motionValue:f,element:m,...c}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=P.now();let u={autoplay:t,delay:r,type:n,repeat:o,repeatDelay:i,repeatType:s,name:l,motionValue:f,element:m,...c},h=m?.KeyframeResolver||oe;this.keyframeResolver=new h(a,(T,g,b)=>this.onKeyframesResolved(T,g,u,!b),l,f,m),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,r,n,o){this.keyframeResolver=void 0;let{name:i,type:s,velocity:a,delay:l,isHandoff:f,onUpdate:m}=n;this.resolvedAt=P.now(),Xn(t,i,s,a)||((k.instantAnimations||!l)&&m?.(Ne(t,n,r)),t[0]=t[t.length-1],Le(n),n.repeat=0);let u={startTime:o?this.resolvedAt?this.resolvedAt-this.createdAt>ss?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:r,...n,keyframes:t},h=!f&&Zn(u)?new qt({...u,element:u.motionValue.owner.current}):new ne(u);h.finished.then(()=>this.notifyFinished()).catch(I),this.pendingTimeline&&(this.stopTimeline=h.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=h}get finished(){return this._animation?this.animation.finished:this._finished}then(t,r){return this.finished.finally(t).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),Wr()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}};var Xt=class{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}get finished(){return Promise.all(this.animations.map(t=>t.finished))}getAll(t){return this.animations[0][t]}setAll(t,r){for(let n=0;n<this.animations.length;n++)this.animations[n][t]=r}attachTimeline(t){let r=this.animations.map(n=>n.attachTimeline(t));return()=>{r.forEach((n,o)=>{n&&n(),this.animations[o].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get state(){return this.getAll("state")}get startTime(){return this.getAll("startTime")}get duration(){return Jn(this.animations,"duration")}get iterationDuration(){return Jn(this.animations,"iterationDuration")}runAll(t){this.animations.forEach(r=>r[t]())}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}};function Jn(e,t){let r=0;for(let n=0;n<e.length;n++){let o=e[n][t];o!==null&&o>r&&(r=o)}return r}var yt=class extends Xt{then(t,r){return this.finished.finally(t).then(()=>{})}};var as=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function ls(e){let t=as.exec(e);if(!t)return[,];let[,r,n,o]=t;return[`--${r??n}`,o]}var ms=4;function $r(e,t,r=1){N(r<=ms,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");let[n,o]=ls(e);if(!n)return;let i=window.getComputedStyle(t).getPropertyValue(n);if(i){let s=i.trim();return Ye(s)?parseFloat(s):s}return Te(o)?$r(o,t,r+1):o}function Tt(e,t){return e?.[t]??e?.default??e}var bt=new Set(["width","height","top","left","right","bottom",...j]);var Qn={test:e=>e==="auto",parse:e=>e};var Zt=e=>t=>t.test(e);var Hr=[_,p,te,G,Er,Ar,Qn],_r=e=>Hr.find(Zt(e));function eo(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||Xe(e):!0}var fs=new Set(["brightness","contrast","saturate","opacity"]);function cs(e){let[t,r]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;let[n]=r.match(Ie)||[];if(!n)return e;let o=r.replace(n,""),i=fs.has(t)?1:0;return n!==r&&(i*=100),t+"("+i+o+")"}var us=/\b([a-z-]*)\(.*?\)/gu,vt={...K,getAnimatableNone:e=>{let t=e.match(us);return t?t.map(cs).join(" "):e}};var Ur={..._,transform:Math.round};var to={rotate:G,rotateX:G,rotateY:G,rotateZ:G,scale:at,scaleX:at,scaleY:at,scaleZ:at,skew:G,skewX:G,skewY:G,distance:p,translateX:p,translateY:p,translateZ:p,x:p,y:p,z:p,perspective:p,transformPerspective:p,opacity:ee,originX:Kt,originY:Kt,originZ:p};var Ae={borderWidth:p,borderTopWidth:p,borderRightWidth:p,borderBottomWidth:p,borderLeftWidth:p,borderRadius:p,radius:p,borderTopLeftRadius:p,borderTopRightRadius:p,borderBottomRightRadius:p,borderBottomLeftRadius:p,width:p,maxWidth:p,height:p,maxHeight:p,top:p,right:p,bottom:p,left:p,padding:p,paddingTop:p,paddingRight:p,paddingBottom:p,paddingLeft:p,margin:p,marginTop:p,marginRight:p,marginBottom:p,marginLeft:p,backgroundPositionX:p,backgroundPositionY:p,...to,zIndex:Ur,fillOpacity:ee,strokeOpacity:ee,numOctaves:Ur};var ro={...Ae,color:C,backgroundColor:C,outlineColor:C,fill:C,stroke:C,borderColor:C,borderTopColor:C,borderRightColor:C,borderBottomColor:C,borderLeftColor:C,filter:vt,WebkitFilter:vt},Vt=e=>ro[e];function St(e,t){let r=Vt(e);return r!==vt&&(r=K),r.getAnimatableNone?r.getAnimatableNone(t):void 0}var ps=new Set(["auto","none","0"]);function no(e,t,r){let n=0,o;for(;n<e.length&&!o;){let i=e[n];typeof i=="string"&&!ps.has(i)&&fe(i).values.length&&(o=e[n]),n++}if(o&&r)for(let i of t)e[i]=St(r,o)}var wt=class extends oe{constructor(t,r,n,o,i){super(t,r,n,o,i,!0)}readKeyframes(){let{unresolvedKeyframes:t,element:r,name:n}=this;if(!r||!r.current)return;super.readKeyframes();for(let l=0;l<t.length;l++){let f=t[l];if(typeof f=="string"&&(f=f.trim(),Te(f))){let m=$r(f,r.current);m!==void 0&&(t[l]=m),l===t.length-1&&(this.finalKeyframe=f)}}if(this.resolveNoneKeyframes(),!bt.has(n)||t.length!==2)return;let[o,i]=t,s=_r(o),a=_r(i);if(s!==a)if(kr(s)&&kr(a))for(let l=0;l<t.length;l++){let f=t[l];typeof f=="string"&&(t[l]=parseFloat(f))}else ue[n]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){let{unresolvedKeyframes:t,name:r}=this,n=[];for(let o=0;o<t.length;o++)(t[o]===null||eo(t[o]))&&n.push(o);n.length&&no(t,n,r)}measureInitialState(){let{element:t,unresolvedKeyframes:r,name:n}=this;if(!t||!t.current)return;n==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=ue[n](t.measureViewportBox(),window.getComputedStyle(t.current)),r[0]=this.measuredOrigin;let o=r[r.length-1];o!==void 0&&t.getValue(n,o).jump(o,!1)}measureEndState(){let{element:t,name:r,unresolvedKeyframes:n}=this;if(!t||!t.current)return;let o=t.getValue(r);o&&o.jump(this.measuredOrigin,!1);let i=n.length-1,s=n[i];n[i]=ue[r](t.measureViewportBox(),window.getComputedStyle(t.current)),s!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=s),this.removedTransforms?.length&&this.removedTransforms.forEach(([a,l])=>{t.getValue(a).set(l)}),this.resolveNoneKeyframes()}};function Ee(e,t,r){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let n=document;t&&(n=t.current);let o=r?.[e]??n.querySelectorAll(e);return o?Array.from(o):[]}return Array.from(e)}var Mt=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function Yr(e){return qe(e)&&"offsetHeight"in e}var oo=30,ds=e=>!isNaN(parseFloat(e)),qr={current:void 0},Jt=class{constructor(t,r={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=n=>{let o=P.now();if(this.updatedAt!==o&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(n),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(let i of this.dependents)i.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=r.owner}setCurrent(t){this.current=t,this.updatedAt=P.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=ds(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,r){this.events[t]||(this.events[t]=new xe);let n=this.events[t].add(r);return t==="change"?()=>{n(),O.read(()=>{this.events.change.getSize()||this.stop()})}:n}clearListeners(){for(let t in this.events)this.events[t].clear()}attach(t,r){this.passiveEffect=t,this.stopPassiveEffect=r}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,r,n){this.set(r),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-n}jump(t,r=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,r&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return qr.current&&qr.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){let t=P.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>oo)return 0;let r=Math.min(this.updatedAt-this.prevUpdatedAt,oo);return ye(parseFloat(this.current)-parseFloat(this.prevFrameValue),r)}start(t){return this.stop(),new Promise(r=>{this.hasAnimated=!0,this.animation=t(r),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function Y(e,t){return new Jt(e,t)}var{schedule:Xr,cancel:hs}=kt(queueMicrotask,!1);function Ce(e){return qe(e)&&"ownerSVGElement"in e}var Qt=new WeakMap,er,io=(e,t,r)=>(n,o)=>o&&o[0]?o[0][e+"Size"]:Ce(n)&&"getBBox"in n?n.getBBox()[t]:n[r],gs=io("inline","width","offsetWidth"),xs=io("block","height","offsetHeight");function ys({target:e,borderBoxSize:t}){Qt.get(e)?.forEach(r=>{r(e,{get width(){return gs(e,t)},get height(){return xs(e,t)}})})}function Ts(e){e.forEach(ys)}function bs(){typeof ResizeObserver>"u"||(er=new ResizeObserver(Ts))}function so(e,t){er||bs();let r=Ee(e);return r.forEach(n=>{let o=Qt.get(n);o||(o=new Set,Qt.set(n,o)),o.add(t),er?.observe(n)}),()=>{r.forEach(n=>{let o=Qt.get(n);o?.delete(t),o?.size||er?.unobserve(n)})}}var tr=new Set,Ke;function vs(){Ke=()=>{let e={get width(){return window.innerWidth},get height(){return window.innerHeight}};tr.forEach(t=>t(e))},window.addEventListener("resize",Ke)}function ao(e){return tr.add(e),Ke||vs(),()=>{tr.delete(e),!tr.size&&typeof Ke=="function"&&(window.removeEventListener("resize",Ke),Ke=void 0)}}function Zr(e,t){return typeof e=="function"?ao(e):so(e,t)}function At(e,t){let r,n=()=>{let{currentTime:o}=t,s=(o===null?0:o.value)/100;r!==s&&e(s),r=s};return O.preUpdate(n,!0),()=>H(n)}function Jr(e){return Ce(e)&&e.tagName==="svg"}function lo(e,t){if(e==="first")return 0;{let r=t-1;return e==="last"?r:r/2}}function Qr(e=.1,{startDelay:t=0,from:r=0,ease:n}={}){return(o,i)=>{let s=typeof r=="number"?r:lo(r,i),a=Math.abs(s-o),l=e*a;if(n){let f=i*e;l=Oe(n)(l/f)*f}return t+l}}var A=e=>!!(e&&e.getVelocity);var Vs=[...Hr,C,K],en=e=>Vs.find(Zt(e));function Et(e){return typeof e=="object"&&!Array.isArray(e)}function rr(e,t,r,n){return typeof e=="string"&&Et(t)?Ee(e,r,n):e instanceof NodeList?Array.from(e):Array.isArray(e)?e:[e]}function mo(e,t,r){return e*(t+1)}function tn(e,t,r,n){return typeof t=="number"?t:t.startsWith("-")||t.startsWith("+")?Math.max(0,e+parseFloat(t)):t==="<"?r:t.startsWith("<")?Math.max(0,r+parseFloat(t.slice(1))):n.get(t)??e}function Ss(e,t,r){for(let n=0;n<e.length;n++){let o=e[n];o.at>t&&o.at<r&&(de(e,o),n--)}}function fo(e,t,r,n,o,i){Ss(e,o,i);for(let s=0;s<t.length;s++)e.push({value:t[s],at:z(o,i,n[s]),easing:nt(r,s)})}function co(e,t){for(let r=0;r<e.length;r++)e[r]=e[r]/(t+1)}function uo(e,t){return e.at===t.at?e.value===null?1:t.value===null?-1:0:e.at-t.at}var ws="easeInOut",Ms=20;function go(e,{defaultTransition:t={},...r}={},n,o){let i=t.duration||.3,s=new Map,a=new Map,l={},f=new Map,m=0,c=0,u=0;for(let h=0;h<e.length;h++){let T=e[h];if(typeof T=="string"){f.set(T,c);continue}else if(!Array.isArray(T)){f.set(T.name,tn(c,T.at,m,f));continue}let[g,b,y={}]=T;y.at!==void 0&&(c=tn(c,y.at,m,f));let E=0,V=(S,d,v,D=0,x=0)=>{let w=As(S),{delay:L=0,times:$=be(w),type:br="keyframes",repeat:$e,repeatType:na,repeatDelay:oa=0,...hi}=d,{ease:se=t.ease||"easeOut",duration:X}=d,an=typeof L=="function"?L(D,x):L,ln=w.length,mn=Me(br)?br:o?.[br||"keyframes"];if(ln<=2&&mn){let He=100;if(ln===2&&Ds(w)){let _e=w[1]-w[0];He=Math.abs(_e)}let Ft={...hi};X!==void 0&&(Ft.duration=F(X));let Pt=ft(Ft,He,mn);se=Pt.ease,X=Pt.duration}X??(X=i);let fn=c+an;$.length===1&&$[0]===0&&($[1]=1);let cn=$.length-w.length;if(cn>0&&pt($,cn),w.length===1&&w.unshift(null),$e){N($e<Ms,"Repeat count too high, must be less than 20","repeat-count-high"),X=mo(X,$e);let He=[...w],Ft=[...$];se=Array.isArray(se)?[...se]:[se];let Pt=[...se];for(let _e=0;_e<$e;_e++){w.push(...He);for(let Ue=0;Ue<He.length;Ue++)$.push(Ft[Ue]+(_e+1)),se.push(Ue===0?"linear":nt(Pt,Ue-1))}co($,$e)}let un=fn+X;fo(v,w,se,$,fn,un),E=Math.max(an+X,E),u=Math.max(un,u)};if(A(g)){let S=po(g,a);V(b,y,ho("default",S))}else{let S=rr(g,b,n,l),d=S.length;for(let v=0;v<d;v++){b=b,y=y;let D=S[v],x=po(D,a);for(let w in b)V(b[w],Es(y,w),ho(w,x),v,d)}}m=c,c+=E}return a.forEach((h,T)=>{for(let g in h){let b=h[g];b.sort(uo);let y=[],E=[],V=[];for(let d=0;d<b.length;d++){let{at:v,value:D,easing:x}=b[d];y.push(D),E.push(J(0,u,v)),V.push(x||"easeOut")}E[0]!==0&&(E.unshift(0),y.unshift(y[0]),V.unshift(ws)),E[E.length-1]!==1&&(E.push(1),y.push(null)),s.has(T)||s.set(T,{keyframes:{},transition:{}});let S=s.get(T);S.keyframes[g]=y,S.transition[g]={...t,duration:u,ease:V,times:E,...r}}}),s}function po(e,t){return!t.has(e)&&t.set(e,{}),t.get(e)}function ho(e,t){return t[e]||(t[e]=[]),t[e]}function As(e){return Array.isArray(e)?e:[e]}function Es(e,t){return e&&e[t]?{...e,...e[t]}:{...e}}var Cs=e=>typeof e=="number",Ds=e=>e.every(Cs);var pe=new WeakMap;var xo=e=>Array.isArray(e);function yo(e){let t=[{},{}];return e?.values.forEach((r,n)=>{t[0][n]=r.get(),t[1][n]=r.getVelocity()}),t}function nr(e,t,r,n){if(typeof t=="function"){let[o,i]=yo(n);t=t(r!==void 0?r:e.custom,o,i)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){let[o,i]=yo(n);t=t(r!==void 0?r:e.custom,o,i)}return t}function To(e,t,r){let n=e.getProps();return nr(n,t,r!==void 0?r:n.custom,e)}function Os(e,t,r){e.hasValue(t)?e.getValue(t).set(r):e.addValue(t,Y(r))}function Fs(e){return xo(e)?e[e.length-1]||0:e}function bo(e,t){let r=To(e,t),{transitionEnd:n={},transition:o={},...i}=r||{};i={...i,...n};for(let s in i){let a=Fs(i[s]);Os(e,s,a)}}function vo(e){return!!(A(e)&&e.add)}function Vo(e,t){let r=e.getValue("willChange");if(vo(r))return r.add(t);if(!r&&k.WillChange){let n=new k.WillChange("auto");e.addValue("willChange",n),n.add(t)}}var We=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase();var Ps="framerAppearId",So="data-"+We(Ps);function wo(e){return e.props[So]}var Is=e=>e!==null;function Mo(e,{repeat:t,repeatType:r="loop"},n){let o=e.filter(Is),i=t&&r!=="loop"&&t%2===1?0:o.length-1;return!i||n===void 0?o[i]:n}var Rs={type:"spring",stiffness:500,damping:25,restSpeed:10},Bs=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),ks={type:"keyframes",duration:.8},Ns={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Ao=(e,{keyframes:t})=>t.length>2?ks:W.has(e)?e.startsWith("scale")?Bs(t[1]):Rs:Ns;function Eo({when:e,delay:t,delayChildren:r,staggerChildren:n,staggerDirection:o,repeat:i,repeatType:s,repeatDelay:a,from:l,elapsed:f,...m}){return!!Object.keys(m).length}var or=(e,t,r,n={},o,i)=>s=>{let a=Tt(n,e)||{},l=a.delay||n.delay||0,{elapsed:f=0}=n;f=f-F(l);let m={keyframes:Array.isArray(r)?r:[null,r],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-f,onUpdate:u=>{t.set(u),a.onUpdate&&a.onUpdate(u)},onComplete:()=>{s(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:i?void 0:o};Eo(a)||Object.assign(m,Ao(e,m)),m.duration&&(m.duration=F(m.duration)),m.repeatDelay&&(m.repeatDelay=F(m.repeatDelay)),m.from!==void 0&&(m.keyframes[0]=m.from);let c=!1;if((m.type===!1||m.duration===0&&!m.repeatDelay)&&(Le(m),m.delay===0&&(c=!0)),(k.instantAnimations||k.skipAnimations)&&(c=!0,Le(m),m.delay=0),m.allowFlatten=!a.type&&!a.ease,c&&!i&&t.get()!==void 0){let u=Mo(m.keyframes,a);if(u!==void 0){O.update(()=>{m.onUpdate(u),m.onComplete()});return}}return a.isSync?new ne(m):new xt(m)};function Ls({protectedKeys:e,needsAnimating:t},r){let n=e.hasOwnProperty(r)&&t[r]!==!0;return t[r]=!1,n}function Co(e,t,{delay:r=0,transitionOverride:n,type:o}={}){let{transition:i=e.getDefaultTransition(),transitionEnd:s,...a}=t;n&&(i=n);let l=[],f=o&&e.animationState&&e.animationState.getState()[o];for(let m in a){let c=e.getValue(m,e.latestValues[m]??null),u=a[m];if(u===void 0||f&&Ls(f,m))continue;let h={delay:r,...Tt(i||{},m)},T=c.get();if(T!==void 0&&!c.isAnimating&&!Array.isArray(u)&&u===T&&!h.velocity)continue;let g=!1;if(window.MotionHandoffAnimation){let y=wo(e);if(y){let E=window.MotionHandoffAnimation(y,m,O);E!==null&&(h.startTime=E,g=!0)}}Vo(e,m),c.start(or(m,c,u,e.shouldReduceMotion&&bt.has(m)?{type:!1}:h,e,g));let b=c.animation;b&&l.push(b)}return s&&Promise.all(l).then(()=>{O.update(()=>{s&&bo(e,s)})}),l}function Do({top:e,left:t,right:r,bottom:n}){return{x:{min:t,max:r},y:{min:e,max:n}}}function Oo(e,t){if(!t)return e;let r=t({x:e.left,y:e.top}),n=t({x:e.right,y:e.bottom});return{top:r.y,left:r.x,bottom:n.y,right:n.x}}function Fo(e,t){return Do(Oo(e.getBoundingClientRect(),t))}var Po={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},ir={};for(let e in Po)ir[e]={isEnabled:t=>Po[e].some(r=>!!t[r])};var Io=()=>({min:0,max:0}),Ge=()=>({x:Io(),y:Io()});var Ro=typeof window<"u";var Ct={current:null},sr={current:!1};function Bo(){if(sr.current=!0,!!Ro)if(window.matchMedia){let e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Ct.current=e.matches;e.addEventListener("change",t),t()}else Ct.current=!1}function ko(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function No(e){return typeof e=="string"||Array.isArray(e)}var Ks=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Lo=["initial",...Ks];function rn(e){return ko(e.animate)||Lo.some(t=>No(e[t]))}function Ko(e){return!!(rn(e)||e.variants)}function Wo(e,t,r){for(let n in t){let o=t[n],i=r[n];if(A(o))e.addValue(n,o);else if(A(i))e.addValue(n,Y(o,{owner:e}));else if(i!==o)if(e.hasValue(n)){let s=e.getValue(n);s.liveStyle===!0?s.jump(o):s.hasAnimated||s.set(o)}else{let s=e.getStaticValue(n);e.addValue(n,Y(s!==void 0?s:o,{owner:e}))}}for(let n in r)t[n]===void 0&&e.removeValue(n);return t}var Go=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],ze=class{scrapeMotionValuesFromProps(t,r,n){return{}}constructor({parent:t,props:r,presenceContext:n,reducedMotionConfig:o,blockInitialAnimation:i,visualState:s},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=oe,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{let u=P.now();this.renderScheduledAt<u&&(this.renderScheduledAt=u,O.render(this.render,!1,!0))};let{latestValues:l,renderState:f}=s;this.latestValues=l,this.baseTarget={...l},this.initialValues=r.initial?{...l}:{},this.renderState=f,this.parent=t,this.props=r,this.presenceContext=n,this.depth=t?t.depth+1:0,this.reducedMotionConfig=o,this.options=a,this.blockInitialAnimation=!!i,this.isControllingVariants=rn(r),this.isVariantNode=Ko(r),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);let{willChange:m,...c}=this.scrapeMotionValuesFromProps(r,{},this);for(let u in c){let h=c[u];l[u]!==void 0&&A(h)&&h.set(l[u])}}mount(t){this.current=t,pe.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((r,n)=>this.bindToMotionValue(n,r)),sr.current||Bo(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Ct.current,this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),H(this.notifyUpdate),H(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(let t in this.events)this.events[t].clear();for(let t in this.features){let r=this.features[t];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,r){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();let n=W.has(t);n&&this.onBindTransform&&this.onBindTransform();let o=r.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&O.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()}),i;window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,t,r)),this.valueSubscriptions.set(t,()=>{o(),i&&i(),r.owner&&r.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in ir){let r=ir[t];if(!r)continue;let{isEnabled:n,Feature:o}=r;if(!this.features[t]&&o&&n(this.props)&&(this.features[t]=new o(this)),this.features[t]){let i=this.features[t];i.isMounted?i.update():(i.mount(),i.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Ge()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,r){this.latestValues[t]=r}update(t,r){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=r;for(let n=0;n<Go.length;n++){let o=Go[n];this.propEventSubscriptions[o]&&(this.propEventSubscriptions[o](),delete this.propEventSubscriptions[o]);let i="on"+o,s=t[i];s&&(this.propEventSubscriptions[o]=this.on(o,s))}this.prevMotionValues=Wo(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){let r=this.getClosestVariantNode();if(r)return r.variantChildren&&r.variantChildren.add(t),()=>r.variantChildren.delete(t)}addValue(t,r){let n=this.values.get(t);r!==n&&(n&&this.removeValue(t),this.bindToMotionValue(t,r),this.values.set(t,r),this.latestValues[t]=r.get())}removeValue(t){this.values.delete(t);let r=this.valueSubscriptions.get(t);r&&(r(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,r){if(this.props.values&&this.props.values[t])return this.props.values[t];let n=this.values.get(t);return n===void 0&&r!==void 0&&(n=Y(r===null?void 0:r,{owner:this}),this.addValue(t,n)),n}readValue(t,r){let n=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return n!=null&&(typeof n=="string"&&(Ye(n)||Xe(n))?n=parseFloat(n):!en(n)&&K.test(r)&&(n=St(t,r)),this.setBaseTarget(t,A(n)?n.get():n)),A(n)?n.get():n}setBaseTarget(t,r){this.baseTarget[t]=r}getBaseTarget(t){let{initial:r}=this.props,n;if(typeof r=="string"||typeof r=="object"){let i=nr(this.props,r,this.presenceContext?.custom);i&&(n=i[t])}if(r&&n!==void 0)return n;let o=this.getBaseTargetFromProps(this.props,t);return o!==void 0&&!A(o)?o:this.initialValues[t]!==void 0&&n===void 0?void 0:this.baseTarget[t]}on(t,r){return this.events[t]||(this.events[t]=new xe),this.events[t].add(r)}notify(t,...r){this.events[t]&&this.events[t].notify(...r)}scheduleRenderMicrotask(){Xr.render(this.render)}};var je=class extends ze{constructor(){super(...arguments),this.KeyframeResolver=wt}sortInstanceNodePosition(t,r){return t.compareDocumentPosition(r)&2?1:-1}getBaseTargetFromProps(t,r){return t.style?t.style[r]:void 0}removeValueFromRenderState(t,{vars:r,style:n}){delete r[t],delete n[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:t}=this.props;A(t)&&(this.childSubscription=t.on("change",r=>{this.current&&(this.current.textContent=`${r}`)}))}};var Ws={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Gs=j.length;function zo(e,t,r){let n="",o=!0;for(let i=0;i<Gs;i++){let s=j[i],a=e[s];if(a===void 0)continue;let l=!0;if(typeof a=="number"?l=a===(s.startsWith("scale")?1:0):l=parseFloat(a)===0,!l||r){let f=Mt(a,Ae[s]);if(!l){o=!1;let m=Ws[s]||s;n+=`${m}(${f}) `}r&&(t[s]=f)}}return n=n.trim(),r?n=r(t,o?"":n):o&&(n="none"),n}function ar(e,t,r){let{style:n,vars:o,transformOrigin:i}=e,s=!1,a=!1;for(let l in t){let f=t[l];if(W.has(l)){s=!0;continue}else if(st(l)){o[l]=f;continue}else{let m=Mt(f,Ae[l]);l.startsWith("origin")?(a=!0,i[l]=m):n[l]=m}}if(t.transform||(s||r?n.transform=zo(t,e.transform,r):n.transform&&(n.transform="none")),a){let{originX:l="50%",originY:f="50%",originZ:m=0}=i;n.transformOrigin=`${l} ${f} ${m}`}}function lr(e,{style:t,vars:r},n,o){let i=e.style,s;for(s in t)i[s]=t[s];o?.applyProjectionStyles(i,n);for(s in r)i.setProperty(s,r[s])}var jo={};function $o(e,{layout:t,layoutId:r}){return W.has(e)||e.startsWith("origin")||(t||r!==void 0)&&(!!jo[e]||e==="opacity")}function mr(e,t,r){let{style:n}=e,o={};for(let i in n)(A(n[i])||t.style&&A(t.style[i])||$o(i,e)||r?.getValue(i)?.liveStyle!==void 0)&&(o[i]=n[i]);return o}function zs(e){return window.getComputedStyle(e)}var fr=class extends je{constructor(){super(...arguments),this.type="html",this.renderInstance=lr}readValueFromInstance(t,r){if(W.has(r))return this.projection?.isProjecting?dt(r):Br(t,r);{let n=zs(t),o=(st(r)?n.getPropertyValue(r):n[r])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:r}){return Fo(t,r)}build(t,r,n){ar(t,r,n.transformTemplate)}scrapeMotionValuesFromProps(t,r,n){return mr(t,r,n)}};function js(e,t){return e in t}var cr=class extends ze{constructor(){super(...arguments),this.type="object"}readValueFromInstance(t,r){if(js(r,t)){let n=t[r];if(typeof n=="string"||typeof n=="number")return n}}getBaseTargetFromProps(){}removeValueFromRenderState(t,r){delete r.output[t]}measureInstanceViewportBox(){return Ge()}build(t,r){Object.assign(t.output,r)}renderInstance(t,{output:r}){Object.assign(t,r)}sortInstanceNodePosition(){return 0}};var $s={offset:"stroke-dashoffset",array:"stroke-dasharray"},Hs={offset:"strokeDashoffset",array:"strokeDasharray"};function Ho(e,t,r=1,n=0,o=!0){e.pathLength=1;let i=o?$s:Hs;e[i.offset]=p.transform(-n);let s=p.transform(t),a=p.transform(r);e[i.array]=`${s} ${a}`}function _o(e,{attrX:t,attrY:r,attrScale:n,pathLength:o,pathSpacing:i=1,pathOffset:s=0,...a},l,f,m){if(ar(e,a,f),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};let{attrs:c,style:u}=e;c.transform&&(u.transform=c.transform,delete c.transform),(u.transform||c.transformOrigin)&&(u.transformOrigin=c.transformOrigin??"50% 50%",delete c.transformOrigin),u.transform&&(u.transformBox=m?.transformBox??"fill-box",delete c.transformBox),t!==void 0&&(c.x=t),r!==void 0&&(c.y=r),n!==void 0&&(c.scale=n),o!==void 0&&Ho(c,o,i,s,!1)}var ur=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);var Uo=e=>typeof e=="string"&&e.toLowerCase()==="svg";function Yo(e,t,r,n){lr(e,t,void 0,n);for(let o in t.attrs)e.setAttribute(ur.has(o)?o:We(o),t.attrs[o])}function qo(e,t,r){let n=mr(e,t,r);for(let o in e)if(A(e[o])||A(t[o])){let i=j.indexOf(o)!==-1?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o;n[i]=e[o]}return n}var pr=class extends je{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Ge}getBaseTargetFromProps(t,r){return t[r]}readValueFromInstance(t,r){if(W.has(r)){let n=Vt(r);return n&&n.default||0}return r=ur.has(r)?r:We(r),t.getAttribute(r)}scrapeMotionValuesFromProps(t,r,n){return qo(t,r,n)}build(t,r,n){_o(t,r,this.isSVGTag,n.transformTemplate,n.style)}renderInstance(t,r,n,o){Yo(t,r,n,o)}mount(t){this.isSVGTag=Uo(t.tagName),super.mount(t)}};function Xo(e){let t={presenceContext:null,props:{},visualState:{renderState:{transform:{},transformOrigin:{},style:{},vars:{},attrs:{}},latestValues:{}}},r=Ce(e)&&!Jr(e)?new pr(t):new fr(t);r.mount(e),pe.set(e,r)}function Zo(e){let t={presenceContext:null,props:{},visualState:{renderState:{output:{}},latestValues:{}}},r=new cr(t);r.mount(e),pe.set(e,r)}function Jo(e,t,r){let n=A(e)?e:Y(e);return n.start(or("",n,t,r)),n.animation}function _s(e,t){return A(e)||typeof e=="number"||typeof e=="string"&&!Et(t)}function dr(e,t,r,n){let o=[];if(_s(e,t))o.push(Jo(e,Et(t)&&t.default||t,r&&(r.default||r)));else{let i=rr(e,t,n),s=i.length;N(!!s,"No valid elements provided.","no-valid-elements");for(let a=0;a<s;a++){let l=i[a];N(l!==null,"You're trying to perform an animation on null. Ensure that selectors are correctly finding elements and refs are correctly hydrated.","animate-null");let f=l instanceof Element?Xo:Zo;pe.has(l)||f(l);let m=pe.get(l),c={...r};"delay"in c&&typeof c.delay=="function"&&(c.delay=c.delay(a,s)),o.push(...Co(m,{...t,transition:c},{}))}}return o}function Qo(e,t,r){let n=[];return go(e,t,r,{spring:re}).forEach(({keyframes:i,transition:s},a)=>{n.push(...dr(a,i,s))}),n}function Us(e){return Array.isArray(e)&&e.some(Array.isArray)}function ei(e){function t(r,n,o){let i=[],s;if(Us(r))i=Qo(r,n,e);else{let{onComplete:l,...f}=o||{};typeof l=="function"&&(s=l),i=dr(r,n,f,e)}let a=new yt(i);return s&&a.finished.then(s),e&&(e.animations.push(a),a.finished.then(()=>{de(e.animations,a)})),a}return t}var q=ei();var Ys=50,ti=()=>({current:0,offset:[],progress:0,scrollLength:0,targetOffset:0,targetLength:0,containerLength:0,velocity:0}),ni=()=>({time:0,x:ti(),y:ti()}),qs={x:{length:"Width",position:"Left"},y:{length:"Height",position:"Top"}};function ri(e,t,r,n){let o=r[t],{length:i,position:s}=qs[t],a=o.current,l=r.time;o.current=e[`scroll${s}`],o.scrollLength=e[`scroll${i}`]-e[`client${i}`],o.offset.length=0,o.offset[0]=0,o.offset[1]=o.scrollLength,o.progress=J(0,o.scrollLength,o.current);let f=n-l;o.velocity=f>Ys?0:ye(o.current-a,f)}function oi(e,t,r){ri(e,"x",t,r),ri(e,"y",t,r),t.time=r}function ii(e,t){let r={x:0,y:0},n=e;for(;n&&n!==t;)if(Yr(n))r.x+=n.offsetLeft,r.y+=n.offsetTop,n=n.offsetParent;else if(n.tagName==="svg"){let o=n.getBoundingClientRect();n=n.parentElement;let i=n.getBoundingClientRect();r.x+=o.left-i.left,r.y+=o.top-i.top}else if(n instanceof SVGGraphicsElement){let{x:o,y:i}=n.getBBox();r.x+=o,r.y+=i;let s=null,a=n.parentNode;for(;!s;)a.tagName==="svg"&&(s=a),a=n.parentNode;n=s}else break;return r}var hr={start:0,center:.5,end:1};function nn(e,t,r=0){let n=0;if(e in hr&&(e=hr[e]),typeof e=="string"){let o=parseFloat(e);e.endsWith("px")?n=o:e.endsWith("%")?e=o/100:e.endsWith("vw")?n=o/100*document.documentElement.clientWidth:e.endsWith("vh")?n=o/100*document.documentElement.clientHeight:e=o}return typeof e=="number"&&(n=t*e),r+n}var Xs=[0,0];function si(e,t,r,n){let o=Array.isArray(e)?e:Xs,i=0,s=0;return typeof e=="number"?o=[e,e]:typeof e=="string"&&(e=e.trim(),e.includes(" ")?o=e.split(" "):o=[e,hr[e]?e:"0"]),i=nn(o[0],r,n),s=nn(o[1],t),i-s}var ai={Enter:[[0,1],[1,1]],Exit:[[0,0],[1,0]],Any:[[1,0],[0,1]],All:[[0,0],[1,1]]};var Zs={x:0,y:0};function Js(e){return"getBBox"in e&&e.tagName!=="svg"?e.getBBox():{width:e.clientWidth,height:e.clientHeight}}function li(e,t,r){let{offset:n=ai.All}=r,{target:o=e,axis:i="y"}=r,s=i==="y"?"height":"width",a=o!==e?ii(o,e):Zs,l=o===e?{width:e.scrollWidth,height:e.scrollHeight}:Js(o),f={width:e.clientWidth,height:e.clientHeight};t[i].offset.length=0;let m=!t[i].interpolate,c=n.length;for(let u=0;u<c;u++){let h=si(n[u],f[s],l[s],a[i]);!m&&h!==t[i].interpolatorOffsets[u]&&(m=!0),t[i].offset[u]=h}m&&(t[i].interpolate=ut(t[i].offset,be(n),{clamp:!1}),t[i].interpolatorOffsets=[...t[i].offset]),t[i].progress=B(0,1,t[i].interpolate(t[i].current))}function Qs(e,t=e,r){if(r.x.targetOffset=0,r.y.targetOffset=0,t!==e){let n=t;for(;n&&n!==e;)r.x.targetOffset+=n.offsetLeft,r.y.targetOffset+=n.offsetTop,n=n.offsetParent}r.x.targetLength=t===e?t.scrollWidth:t.clientWidth,r.y.targetLength=t===e?t.scrollHeight:t.clientHeight,r.x.containerLength=e.clientWidth,r.y.containerLength=e.clientHeight}function mi(e,t,r,n={}){return{measure:o=>{Qs(e,n.target,r),oi(e,r,o),(n.offset||n.target)&&li(e,r,n)},notify:()=>t(r)}}var Dt=new WeakMap,fi=new WeakMap,on=new WeakMap,ci=e=>e===document.scrollingElement?window:e;function gr(e,{container:t=document.scrollingElement,...r}={}){if(!t)return I;let n=on.get(t);n||(n=new Set,on.set(t,n));let o=ni(),i=mi(t,e,o,r);if(n.add(i),!Dt.has(t)){let a=()=>{for(let c of n)c.measure(Q.timestamp);O.preUpdate(l)},l=()=>{for(let c of n)c.notify()},f=()=>O.read(a);Dt.set(t,f);let m=ci(t);window.addEventListener("resize",f,{passive:!0}),t!==document.documentElement&&fi.set(t,Zr(t,f)),m.addEventListener("scroll",f,{passive:!0}),f()}let s=Dt.get(t);return O.read(s,!1,!0),()=>{H(s);let a=on.get(t);if(!a||(a.delete(i),a.size))return;let l=Dt.get(t);Dt.delete(t),l&&(ci(t).removeEventListener("scroll",l),fi.get(t)?.(),window.removeEventListener("resize",l))}}var ui=new Map;function ea(e){let t={value:0},r=gr(n=>{t.value=n[e.axis].progress*100},e);return{currentTime:t,cancel:r}}function xr({source:e,container:t,...r}){let{axis:n}=r;e&&(t=e);let o=ui.get(t)??new Map;ui.set(t,o);let i=r.target??"self",s=o.get(i)??{},a=n+(r.offset??[]).join(",");return s[a]||(s[a]=!r.target&&gt()?new ScrollTimeline({source:t,axis:n}):ea({container:t,...r})),s[a]}function pi(e,t){let r=xr(t);return e.attachTimeline({timeline:t.target?void 0:r,observe:n=>(n.pause(),At(o=>{n.time=n.iterationDuration*o},r))})}function ta(e){return e.length===2}function di(e,t){return ta(e)?gr(r=>{e(r[t.axis].progress,r)},t):At(e,xr(t))}function yr(e,{axis:t="y",container:r=document.scrollingElement,...n}={}){if(!r)return I;let o={axis:t,container:r,...n};return typeof e=="function"?di(e,o):pi(e,o)}var ra={some:0,all:1};function ie(e,t,{root:r,margin:n,amount:o="some"}={}){let i=Ee(e),s=new WeakMap,a=f=>{f.forEach(m=>{let c=s.get(m.target);if(m.isIntersecting!==!!c)if(m.isIntersecting){let u=t(m.target,m);typeof u=="function"?s.set(m.target,u):l.unobserve(m.target)}else typeof c=="function"&&(c(m),s.delete(m.target))})},l=new IntersectionObserver(a,{root:r,rootMargin:n,threshold:typeof o=="number"?o:ra[o]});return i.forEach(f=>l.observe(f)),()=>l.disconnect()}var sn={fadeIn:(e,t={})=>ie(e,()=>{q(e,{opacity:[0,1]},{duration:t.duration||.8,delay:t.delay||0,easing:t.easing||"ease-out"})},{amount:t.amount||.25}),slideUp:(e,t={})=>ie(e,()=>{q(e,{y:[t.distance||50,0],opacity:[0,1]},{duration:t.duration||.8,delay:t.delay||0,easing:t.easing||"ease-out"})},{amount:t.amount||.25}),slideDown:(e,t={})=>ie(e,()=>{q(e,{y:[-(t.distance||50),0],opacity:[0,1]},{duration:t.duration||.8,delay:t.delay||0,easing:t.easing||"ease-out"})},{amount:t.amount||.25}),slideLeft:(e,t={})=>ie(e,()=>{q(e,{x:[t.distance||50,0],opacity:[0,1]},{duration:t.duration||.8,delay:t.delay||0,easing:t.easing||"ease-out"})},{amount:t.amount||.25}),slideRight:(e,t={})=>ie(e,()=>{q(e,{x:[-(t.distance||50),0],opacity:[0,1]},{duration:t.duration||.8,delay:t.delay||0,easing:t.easing||"ease-out"})},{amount:t.amount||.25}),scale:(e,t={})=>ie(e,()=>{q(e,{scale:[t.from||.8,1],opacity:[0,1]},{duration:t.duration||.8,delay:t.delay||0,easing:t.easing||[.34,1.56,.64,1]})},{amount:t.amount||.25}),parallax:(e,t={})=>yr(q(e,{y:[0,t.distance||100]}),{target:e,offset:t.offset||["start end","end start"]})},Tr=class{constructor(){this.animations=[]}init(){document.querySelectorAll("[data-wms-animate]").forEach(t=>{let r=t.dataset.wmsAnimate,n={duration:parseFloat(t.dataset.wmsDuration)||void 0,delay:parseFloat(t.dataset.wmsDelay)||void 0,distance:parseFloat(t.dataset.wmsDistance)||void 0,amount:parseFloat(t.dataset.wmsAmount)||void 0,easing:parseFloat(t.dataset.wmsEasing)||void 0};if(Object.keys(n).forEach(o=>{n[o]===void 0&&delete n[o]}),sn[r])try{let o=sn[r](t,n);this.animations.push(o)}catch(o){console.error(`Failed to apply animation "${r}":`,o)}else console.warn(`Unknown animation type: "${r}"`)}),this.initScrollToggle()}initScrollToggle(){document.querySelectorAll("[data-wms-scroll-toggle]").forEach(t=>{let r=parseInt(t.dataset.wmsThreshold)||80,n=t.dataset.wmsScrollToggle||"wms-scrolled",o=()=>{(window.scrollY||window.pageYOffset)>r?t.classList.contains(n)||t.classList.add(n):t.classList.contains(n)&&t.classList.remove(n)};window.addEventListener("scroll",o,{passive:!0}),o()})}destroy(){this.animations=[]}},Ot;document.readyState==="loading"?document.addEventListener("DOMContentLoaded",()=>{Ot=new Tr,Ot.init()}):(Ot=new Tr,Ot.init());window.motion={animate:q,inView:ie,scroll:yr,stagger:Qr,presets:sn,manager:Ot};})();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webmate-studio/builder",
3
- "version": "0.2.57",
3
+ "version": "0.2.59",
4
4
  "type": "module",
5
5
  "description": "Webmate Studio Component Builder",
6
6
  "keywords": [
package/src/index.js CHANGED
@@ -4,5 +4,16 @@ import { cleanComponentHTML } from './html-cleaner.js';
4
4
  import { bundleIsland, bundleComponentIslands } from './bundler.js';
5
5
  import { deduplicateCSS } from './css-deduplicator.js';
6
6
  import { markdownToHtml, processMarkdownProps } from './markdown.js';
7
+ import { readFileSync } from 'fs';
8
+ import { fileURLToPath } from 'url';
9
+ import { dirname, join } from 'path';
7
10
 
8
- export { build, generateComponentCSS, generateTailwindCSS, extractTailwindClasses, cleanComponentHTML, bundleIsland, bundleComponentIslands, deduplicateCSS, markdownToHtml, processMarkdownProps };
11
+ const __filename = fileURLToPath(import.meta.url);
12
+ const __dirname = dirname(__filename);
13
+
14
+ // Export motion-runtime.js content as string (bundled version)
15
+ function getMotionRuntime() {
16
+ return readFileSync(join(__dirname, '../dist/motion-runtime.min.js'), 'utf-8');
17
+ }
18
+
19
+ export { build, generateComponentCSS, generateTailwindCSS, extractTailwindClasses, cleanComponentHTML, bundleIsland, bundleComponentIslands, deduplicateCSS, markdownToHtml, processMarkdownProps, getMotionRuntime };
@@ -162,46 +162,30 @@ class AnimationManager {
162
162
  }
163
163
  });
164
164
 
165
- // Scroll-shrink behavior (für Headers)
166
- this.initScrollShrink();
165
+ // Scroll-toggle behavior (für Headers)
166
+ this.initScrollToggle();
167
167
  }
168
168
 
169
- initScrollShrink() {
169
+ initScrollToggle() {
170
170
  document.querySelectorAll('[data-wms-scroll-toggle]').forEach(el => {
171
171
  const threshold = parseInt(el.dataset.wmsThreshold) || 80;
172
172
  const scrolledClass = el.dataset.wmsScrollToggle || 'wms-scrolled';
173
173
 
174
- // Spacer als Intersection-Target
175
- const spacer = document.createElement('div');
176
- spacer.style.height = threshold + 'px';
177
- spacer.style.pointerEvents = 'none';
178
- el.before(spacer);
179
-
180
- // InView für Scroll-Detection
181
- inView(spacer,
182
- // onEnter
183
- () => el.classList.remove(scrolledClass),
184
- // Config
185
- {
186
- root: null,
187
- margin: '0px 0px 0px 0px',
188
- amount: 'any'
189
- }
190
- );
191
-
192
- // Reverse: wenn spacer aus Viewport geht
193
- const observer = new IntersectionObserver((entries) => {
194
- entries.forEach(entry => {
195
- if (!entry.isIntersecting) {
174
+ const checkScroll = () => {
175
+ const scrollY = window.scrollY || window.pageYOffset;
176
+ if (scrollY > threshold) {
177
+ if (!el.classList.contains(scrolledClass)) {
196
178
  el.classList.add(scrolledClass);
197
179
  }
198
- });
199
- }, {
200
- root: null,
201
- threshold: 0
202
- });
180
+ } else {
181
+ if (el.classList.contains(scrolledClass)) {
182
+ el.classList.remove(scrolledClass);
183
+ }
184
+ }
185
+ };
203
186
 
204
- observer.observe(spacer);
187
+ window.addEventListener('scroll', checkScroll, { passive: true });
188
+ checkScroll(); // Check immediately
205
189
  });
206
190
  }
207
191