import{r as S,j as A,b as Do,d as Mo,B as ie}from"./index-CGDW0kIg.js";import{I as Eo}from"./input-BkpQmM2e.js";import{F as Ro}from"./Footer-letc71A_.js";import{N as Lo}from"./Navigation-nACcoftb.js";const Os=S.createContext({});function ko(t){const e=S.useRef(null);return e.current===null&&(e.current=t()),e.current}const Fo=typeof window<"u",jo=Fo?S.useLayoutEffect:S.useEffect,Ge=S.createContext(null);function He(t,e){t.indexOf(e)===-1&&t.push(e)}function Ht(t,e){const n=t.indexOf(e);n>-1&&t.splice(n,1)}const Y=(t,e,n)=>n>e?e:n<t?t:n;let _e=()=>{};const q={},Us=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t);function Ws(t){return typeof t=="object"&&t!==null}const Ks=t=>/^0[^.\s]+$/u.test(t);function zs(t){let e;return()=>(e===void 0&&(e=t()),e)}const K=t=>t,Bo=(t,e)=>n=>e(t(n)),kt=(...t)=>t.reduce(Bo),Dt=(t,e,n)=>{const s=e-t;return s===0?1:(n-t)/s};class Xe{constructor(){this.subscriptions=[]}add(e){return He(this.subscriptions,e),()=>Ht(this.subscriptions,e)}notify(e,n,s){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](e,n,s);else for(let r=0;r<i;r++){const o=this.subscriptions[r];o&&o(e,n,s)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const G=t=>t*1e3,W=t=>t/1e3;function $s(t,e){return e?t*(1e3/e):0}const Gs=(t,e,n)=>(((1-3*n+3*e)*t+(3*n-6*e))*t+3*e)*t,Io=1e-7,No=12;function Oo(t,e,n,s,i){let r,o,a=0;do o=e+(n-e)/2,r=Gs(o,s,i)-t,r>0?n=o:e=o;while(Math.abs(r)>Io&&++a<No);return o}function Ft(t,e,n,s){if(t===e&&n===s)return K;const i=r=>Oo(r,0,1,t,n);return r=>r===0||r===1?r:Gs(i(r),e,s)}const Hs=t=>e=>e<=.5?t(2*e)/2:(2-t(2*(1-e)))/2,_s=t=>e=>1-t(1-e),Xs=Ft(.33,1.53,.69,.99),Ye=_s(Xs),Ys=Hs(Ye),qs=t=>(t*=2)<1?.5*Ye(t):.5*(2-Math.pow(2,-10*(t-1))),qe=t=>1-Math.sin(Math.acos(t)),Zs=_s(qe),Qs=Hs(qe),Uo=Ft(.42,0,1,1),Wo=Ft(0,0,.58,1),Js=Ft(.42,0,.58,1),Ko=t=>Array.isArray(t)&&typeof t[0]!="number",ti=t=>Array.isArray(t)&&typeof t[0]=="number",zo={linear:K,easeIn:Uo,easeInOut:Js,easeOut:Wo,circIn:qe,circInOut:Qs,circOut:Zs,backIn:Ye,backInOut:Ys,backOut:Xs,anticipate:qs},$o=t=>typeof t=="string",Pn=t=>{if(ti(t)){_e(t.length===4);const[e,n,s,i]=t;return Ft(e,n,s,i)}else if($o(t))return zo[t];return t},It=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function Go(t,e){let n=new Set,s=new Set,i=!1,r=!1;const o=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1};function l(c){o.has(c)&&(u.schedule(c),t()),c(a)}const u={schedule:(c,h=!1,d=!1)=>{const p=d&&i?n:s;return h&&o.add(c),p.has(c)||p.add(c),c},cancel:c=>{s.delete(c),o.delete(c)},process:c=>{if(a=c,i){r=!0;return}i=!0,[n,s]=[s,n],n.forEach(l),n.clear(),i=!1,r&&(r=!1,u.process(c))}};return u}const Ho=40;function ei(t,e){let n=!1,s=!0;const i={delta:0,timestamp:0,isProcessing:!1},r=()=>n=!0,o=It.reduce((g,b)=>(g[b]=Go(r),g),{}),{setup:a,read:l,resolveKeyframes:u,preUpdate:c,update:h,preRender:d,render:f,postRender:p}=o,m=()=>{const g=q.useManualTiming?i.timestamp:performance.now();n=!1,q.useManualTiming||(i.delta=s?1e3/60:Math.max(Math.min(g-i.timestamp,Ho),1)),i.timestamp=g,i.isProcessing=!0,a.process(i),l.process(i),u.process(i),c.process(i),h.process(i),d.process(i),f.process(i),p.process(i),i.isProcessing=!1,n&&e&&(s=!1,t(m))},y=()=>{n=!0,s=!0,i.isProcessing||t(m)};return{schedule:It.reduce((g,b)=>{const w=o[b];return g[b]=(V,E=!1,P=!1)=>(n||y(),w.schedule(V,E,P)),g},{}),cancel:g=>{for(let b=0;b<It.length;b++)o[It[b]].cancel(g)},state:i,steps:o}}const{schedule:C,cancel:et,state:F,steps:oe}=ei(typeof requestAnimationFrame<"u"?requestAnimationFrame:K,!0);let Ut;function _o(){Ut=void 0}const I={now:()=>(Ut===void 0&&I.set(F.isProcessing||q.useManualTiming?F.timestamp:performance.now()),Ut),set:t=>{Ut=t,queueMicrotask(_o)}},ni=t=>e=>typeof e=="string"&&e.startsWith(t),si=ni("--"),Xo=ni("var(--"),Ze=t=>Xo(t)?Yo.test(t.split("/*")[0].trim()):!1,Yo=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function An(t){return typeof t!="string"?!1:t.split("/*")[0].includes("var(--")}const vt={test:t=>typeof t=="number",parse:parseFloat,transform:t=>t},Mt={...vt,transform:t=>Y(0,1,t)},Nt={...vt,default:1},Pt=t=>Math.round(t*1e5)/1e5,Qe=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function qo(t){return t==null}const Zo=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Je=(t,e)=>n=>!!(typeof n=="string"&&Zo.test(n)&&n.startsWith(t)||e&&!qo(n)&&Object.prototype.hasOwnProperty.call(n,e)),ii=(t,e,n)=>s=>{if(typeof s!="string")return s;const[i,r,o,a]=s.match(Qe);return{[t]:parseFloat(i),[e]:parseFloat(r),[n]:parseFloat(o),alpha:a!==void 0?parseFloat(a):1}},Qo=t=>Y(0,255,t),re={...vt,transform:t=>Math.round(Qo(t))},rt={test:Je("rgb","red"),parse:ii("red","green","blue"),transform:({red:t,green:e,blue:n,alpha:s=1})=>"rgba("+re.transform(t)+", "+re.transform(e)+", "+re.transform(n)+", "+Pt(Mt.transform(s))+")"};function Jo(t){let e="",n="",s="",i="";return t.length>5?(e=t.substring(1,3),n=t.substring(3,5),s=t.substring(5,7),i=t.substring(7,9)):(e=t.substring(1,2),n=t.substring(2,3),s=t.substring(3,4),i=t.substring(4,5),e+=e,n+=n,s+=s,i+=i),{red:parseInt(e,16),green:parseInt(n,16),blue:parseInt(s,16),alpha:i?parseInt(i,16)/255:1}}const be={test:Je("#"),parse:Jo,transform:rt.transform},jt=t=>({test:e=>typeof e=="string"&&e.endsWith(t)&&e.split(" ").length===1,parse:parseFloat,transform:e=>`${e}${t}`}),Q=jt("deg"),X=jt("%"),x=jt("px"),tr=jt("vh"),er=jt("vw"),Vn={...X,parse:t=>X.parse(t)/100,transform:t=>X.transform(t*100)},ht={test:Je("hsl","hue"),parse:ii("hue","saturation","lightness"),transform:({hue:t,saturation:e,lightness:n,alpha:s=1})=>"hsla("+Math.round(t)+", "+X.transform(Pt(e))+", "+X.transform(Pt(n))+", "+Pt(Mt.transform(s))+")"},R={test:t=>rt.test(t)||be.test(t)||ht.test(t),parse:t=>rt.test(t)?rt.parse(t):ht.test(t)?ht.parse(t):be.parse(t),transform:t=>typeof t=="string"?t:t.hasOwnProperty("red")?rt.transform(t):ht.transform(t),getAnimatableNone:t=>{const e=R.parse(t);return e.alpha=0,R.transform(e)}},nr=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function sr(t){var e,n;return isNaN(t)&&typeof t=="string"&&(((e=t.match(Qe))==null?void 0:e.length)||0)+(((n=t.match(nr))==null?void 0:n.length)||0)>0}const oi="number",ri="color",ir="var",or="var(",Cn="${}",rr=/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 Et(t){const e=t.toString(),n=[],s={color:[],number:[],var:[]},i=[];let r=0;const a=e.replace(rr,l=>(R.test(l)?(s.color.push(r),i.push(ri),n.push(R.parse(l))):l.startsWith(or)?(s.var.push(r),i.push(ir),n.push(l)):(s.number.push(r),i.push(oi),n.push(parseFloat(l))),++r,Cn)).split(Cn);return{values:n,split:a,indexes:s,types:i}}function ai(t){return Et(t).values}function li(t){const{split:e,types:n}=Et(t),s=e.length;return i=>{let r="";for(let o=0;o<s;o++)if(r+=e[o],i[o]!==void 0){const a=n[o];a===oi?r+=Pt(i[o]):a===ri?r+=R.transform(i[o]):r+=i[o]}return r}}const ar=t=>typeof t=="number"?0:R.test(t)?R.getAnimatableNone(t):t;function lr(t){const e=ai(t);return li(t)(e.map(ar))}const H={test:sr,parse:ai,createTransformer:li,getAnimatableNone:lr};function ae(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+(e-t)*6*n:n<1/2?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function cr({hue:t,saturation:e,lightness:n,alpha:s}){t/=360,e/=100,n/=100;let i=0,r=0,o=0;if(!e)i=r=o=n;else{const a=n<.5?n*(1+e):n+e-n*e,l=2*n-a;i=ae(l,a,t+1/3),r=ae(l,a,t),o=ae(l,a,t-1/3)}return{red:Math.round(i*255),green:Math.round(r*255),blue:Math.round(o*255),alpha:s}}function _t(t,e){return n=>n>0?e:t}const D=(t,e,n)=>t+(e-t)*n,le=(t,e,n)=>{const s=t*t,i=n*(e*e-s)+s;return i<0?0:Math.sqrt(i)},ur=[be,rt,ht],hr=t=>ur.find(e=>e.test(t));function Dn(t){const e=hr(t);if(!e)return!1;let n=e.parse(t);return e===ht&&(n=cr(n)),n}const Mn=(t,e)=>{const n=Dn(t),s=Dn(e);if(!n||!s)return _t(t,e);const i={...n};return r=>(i.red=le(n.red,s.red,r),i.green=le(n.green,s.green,r),i.blue=le(n.blue,s.blue,r),i.alpha=D(n.alpha,s.alpha,r),rt.transform(i))},Se=new Set(["none","hidden"]);function dr(t,e){return Se.has(t)?n=>n<=0?t:e:n=>n>=1?e:t}function fr(t,e){return n=>D(t,e,n)}function tn(t){return typeof t=="number"?fr:typeof t=="string"?Ze(t)?_t:R.test(t)?Mn:gr:Array.isArray(t)?ci:typeof t=="object"?R.test(t)?Mn:pr:_t}function ci(t,e){const n=[...t],s=n.length,i=t.map((r,o)=>tn(r)(r,e[o]));return r=>{for(let o=0;o<s;o++)n[o]=i[o](r);return n}}function pr(t,e){const n={...t,...e},s={};for(const i in n)t[i]!==void 0&&e[i]!==void 0&&(s[i]=tn(t[i])(t[i],e[i]));return i=>{for(const r in s)n[r]=s[r](i);return n}}function mr(t,e){const n=[],s={color:0,var:0,number:0};for(let i=0;i<e.values.length;i++){const r=e.types[i],o=t.indexes[r][s[r]],a=t.values[o]??0;n[i]=a,s[r]++}return n}const gr=(t,e)=>{const n=H.createTransformer(e),s=Et(t),i=Et(e);return s.indexes.var.length===i.indexes.var.length&&s.indexes.color.length===i.indexes.color.length&&s.indexes.number.length>=i.indexes.number.length?Se.has(t)&&!i.values.length||Se.has(e)&&!s.values.length?dr(t,e):kt(ci(mr(s,i),i.values),n):_t(t,e)};function ui(t,e,n){return typeof t=="number"&&typeof e=="number"&&typeof n=="number"?D(t,e,n):tn(t)(t,e)}const yr=t=>{const e=({timestamp:n})=>t(n);return{start:(n=!0)=>C.update(e,n),stop:()=>et(e),now:()=>F.isProcessing?F.timestamp:I.now()}},hi=(t,e,n=10)=>{let s="";const i=Math.max(Math.round(e/n),2);for(let r=0;r<i;r++)s+=Math.round(t(r/(i-1))*1e4)/1e4+", ";return`linear(${s.substring(0,s.length-2)})`},Xt=2e4;function en(t){let e=0;const n=50;let s=t.next(e);for(;!s.done&&e<Xt;)e+=n,s=t.next(e);return e>=Xt?1/0:e}function vr(t,e=100,n){const s=n({...t,keyframes:[0,e]}),i=Math.min(en(s),Xt);return{type:"keyframes",ease:r=>s.next(i*r).value/e,duration:W(i)}}const xr=5;function di(t,e,n){const s=Math.max(e-xr,0);return $s(n-t(s),e-s)}const 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},ce=.001;function Tr({duration:t=M.duration,bounce:e=M.bounce,velocity:n=M.velocity,mass:s=M.mass}){let i,r,o=1-e;o=Y(M.minDamping,M.maxDamping,o),t=Y(M.minDuration,M.maxDuration,W(t)),o<1?(i=u=>{const c=u*o,h=c*t,d=c-n,f=Pe(u,o),p=Math.exp(-h);return ce-d/f*p},r=u=>{const h=u*o*t,d=h*n+n,f=Math.pow(o,2)*Math.pow(u,2)*t,p=Math.exp(-h),m=Pe(Math.pow(u,2),o);return(-i(u)+ce>0?-1:1)*((d-f)*p)/m}):(i=u=>{const c=Math.exp(-u*t),h=(u-n)*t+1;return-ce+c*h},r=u=>{const c=Math.exp(-u*t),h=(n-u)*(t*t);return c*h});const a=5/t,l=br(i,r,a);if(t=G(t),isNaN(l))return{stiffness:M.stiffness,damping:M.damping,duration:t};{const u=Math.pow(l,2)*s;return{stiffness:u,damping:o*2*Math.sqrt(s*u),duration:t}}}const wr=12;function br(t,e,n){let s=n;for(let i=1;i<wr;i++)s=s-t(s)/e(s);return s}function Pe(t,e){return t*Math.sqrt(1-e*e)}const Sr=["duration","bounce"],Pr=["stiffness","damping","mass"];function En(t,e){return e.some(n=>t[n]!==void 0)}function Ar(t){let e={velocity:M.velocity,stiffness:M.stiffness,damping:M.damping,mass:M.mass,isResolvedFromDuration:!1,...t};if(!En(t,Pr)&&En(t,Sr))if(e.velocity=0,t.visualDuration){const n=t.visualDuration,s=2*Math.PI/(n*1.2),i=s*s,r=2*Y(.05,1,1-(t.bounce||0))*Math.sqrt(i);e={...e,mass:M.mass,stiffness:i,damping:r}}else{const n=Tr({...t,velocity:0});e={...e,...n,mass:M.mass},e.isResolvedFromDuration=!0}return e}function Yt(t=M.visualDuration,e=M.bounce){const n=typeof t!="object"?{visualDuration:t,keyframes:[0,1],bounce:e}:t;let{restSpeed:s,restDelta:i}=n;const r=n.keyframes[0],o=n.keyframes[n.keyframes.length-1],a={done:!1,value:r},{stiffness:l,damping:u,mass:c,duration:h,velocity:d,isResolvedFromDuration:f}=Ar({...n,velocity:-W(n.velocity||0)}),p=d||0,m=u/(2*Math.sqrt(l*c)),y=o-r,v=W(Math.sqrt(l/c)),T=Math.abs(y)<5;s||(s=T?M.restSpeed.granular:M.restSpeed.default),i||(i=T?M.restDelta.granular:M.restDelta.default);let g;if(m<1){const w=Pe(v,m);g=V=>{const E=Math.exp(-m*v*V);return o-E*((p+m*v*y)/w*Math.sin(w*V)+y*Math.cos(w*V))}}else if(m===1)g=w=>o-Math.exp(-v*w)*(y+(p+v*y)*w);else{const w=v*Math.sqrt(m*m-1);g=V=>{const E=Math.exp(-m*v*V),P=Math.min(w*V,300);return o-E*((p+m*v*y)*Math.sinh(P)+w*y*Math.cosh(P))/w}}const b={calculatedDuration:f&&h||null,next:w=>{const V=g(w);if(f)a.done=w>=h;else{let E=w===0?p:0;m<1&&(E=w===0?G(p):di(g,w,V));const P=Math.abs(E)<=s,B=Math.abs(o-V)<=i;a.done=P&&B}return a.value=a.done?o:V,a},toString:()=>{const w=Math.min(en(b),Xt),V=hi(E=>b.next(w*E).value,w,30);return w+"ms "+V},toTransition:()=>{}};return b}Yt.applyToOptions=t=>{const e=vr(t,100,Yt);return t.ease=e.ease,t.duration=G(e.duration),t.type="keyframes",t};function Ae({keyframes:t,velocity:e=0,power:n=.8,timeConstant:s=325,bounceDamping:i=10,bounceStiffness:r=500,modifyTarget:o,min:a,max:l,restDelta:u=.5,restSpeed:c}){const h=t[0],d={done:!1,value:h},f=P=>a!==void 0&&P<a||l!==void 0&&P>l,p=P=>a===void 0?l:l===void 0||Math.abs(a-P)<Math.abs(l-P)?a:l;let m=n*e;const y=h+m,v=o===void 0?y:o(y);v!==y&&(m=v-h);const T=P=>-m*Math.exp(-P/s),g=P=>v+T(P),b=P=>{const B=T(P),O=g(P);d.done=Math.abs(B)<=u,d.value=d.done?v:O};let w,V;const E=P=>{f(d.value)&&(w=P,V=Yt({keyframes:[d.value,p(d.value)],velocity:di(g,P,d.value),damping:i,stiffness:r,restDelta:u,restSpeed:c}))};return E(0),{calculatedDuration:null,next:P=>{let B=!1;return!V&&w===void 0&&(B=!0,b(P),E(P)),w!==void 0&&P>=w?V.next(P-w):(!B&&b(P),d)}}}function Vr(t,e,n){const s=[],i=n||q.mix||ui,r=t.length-1;for(let o=0;o<r;o++){let a=i(t[o],t[o+1]);if(e){const l=Array.isArray(e)?e[o]||K:e;a=kt(l,a)}s.push(a)}return s}function Cr(t,e,{clamp:n=!0,ease:s,mixer:i}={}){const r=t.length;if(_e(r===e.length),r===1)return()=>e[0];if(r===2&&e[0]===e[1])return()=>e[1];const o=t[0]===t[1];t[0]>t[r-1]&&(t=[...t].reverse(),e=[...e].reverse());const a=Vr(e,s,i),l=a.length,u=c=>{if(o&&c<t[0])return e[0];let h=0;if(l>1)for(;h<t.length-2&&!(c<t[h+1]);h++);const d=Dt(t[h],t[h+1],c);return a[h](d)};return n?c=>u(Y(t[0],t[r-1],c)):u}function Dr(t,e){const n=t[t.length-1];for(let s=1;s<=e;s++){const i=Dt(0,e,s);t.push(D(n,1,i))}}function Mr(t){const e=[0];return Dr(e,t.length-1),e}function Er(t,e){return t.map(n=>n*e)}function Rr(t,e){return t.map(()=>e||Js).splice(0,t.length-1)}function At({duration:t=300,keyframes:e,times:n,ease:s="easeInOut"}){const i=Ko(s)?s.map(Pn):Pn(s),r={done:!1,value:e[0]},o=Er(n&&n.length===e.length?n:Mr(e),t),a=Cr(o,e,{ease:Array.isArray(i)?i:Rr(e,i)});return{calculatedDuration:t,next:l=>(r.value=a(l),r.done=l>=t,r)}}const Lr=t=>t!==null;function nn(t,{repeat:e,repeatType:n="loop"},s,i=1){const r=t.filter(Lr),a=i<0||e&&n!=="loop"&&e%2===1?0:r.length-1;return!a||s===void 0?r[a]:s}const kr={decay:Ae,inertia:Ae,tween:At,keyframes:At,spring:Yt};function fi(t){typeof t.type=="string"&&(t.type=kr[t.type])}class sn{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(e=>{this.resolve=e})}notifyFinished(){this.resolve()}then(e,n){return this.finished.then(e,n)}}const Fr=t=>t/100;class on extends sn{constructor(e){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{var s,i;const{motionValue:n}=this.options;n&&n.updatedAt!==I.now()&&this.tick(I.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(i=(s=this.options).onStop)==null||i.call(s))},this.options=e,this.initAnimation(),this.play(),e.autoplay===!1&&this.pause()}initAnimation(){const{options:e}=this;fi(e);const{type:n=At,repeat:s=0,repeatDelay:i=0,repeatType:r,velocity:o=0}=e;let{keyframes:a}=e;const l=n||At;l!==At&&typeof a[0]!="number"&&(this.mixKeyframes=kt(Fr,ui(a[0],a[1])),a=[0,100]);const u=l({...e,keyframes:a});r==="mirror"&&(this.mirroredGenerator=l({...e,keyframes:[...a].reverse(),velocity:-o})),u.calculatedDuration===null&&(u.calculatedDuration=en(u));const{calculatedDuration:c}=u;this.calculatedDuration=c,this.resolvedDuration=c+i,this.totalDuration=this.resolvedDuration*(s+1)-i,this.generator=u}updateTime(e){const n=Math.round(e-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(e,n=!1){const{generator:s,totalDuration:i,mixKeyframes:r,mirroredGenerator:o,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return s.next(0);const{delay:u=0,keyframes:c,repeat:h,repeatType:d,repeatDelay:f,type:p,onUpdate:m,finalKeyframe:y}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-i/this.speed,this.startTime)),n?this.currentTime=e:this.updateTime(e);const v=this.currentTime-u*(this.playbackSpeed>=0?1:-1),T=this.playbackSpeed>=0?v<0:v>i;this.currentTime=Math.max(v,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=i);let g=this.currentTime,b=s;if(h){const P=Math.min(this.currentTime,i)/a;let B=Math.floor(P),O=P%1;!O&&P>=1&&(O=1),O===1&&B--,B=Math.min(B,h+1),!!(B%2)&&(d==="reverse"?(O=1-O,f&&(O-=f/a)):d==="mirror"&&(b=o)),g=Y(0,1,O)*a}const w=T?{done:!1,value:c[0]}:b.next(g);r&&!T&&(w.value=r(w.value));let{done:V}=w;!T&&l!==null&&(V=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const E=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&V);return E&&p!==Ae&&(w.value=nn(c,this.options,y,this.speed)),m&&m(w.value),E&&this.finish(),w}then(e,n){return this.finished.then(e,n)}get duration(){return W(this.calculatedDuration)}get iterationDuration(){const{delay:e=0}=this.options||{};return this.duration+W(e)}get time(){return W(this.currentTime)}set time(e){e=G(e),this.currentTime=e,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=e,this.tick(e))}get speed(){return this.playbackSpeed}set speed(e){const n=this.playbackSpeed!==e;n&&this.driver&&this.updateTime(I.now()),this.playbackSpeed=e,n&&this.driver&&(this.time=W(this.currentTime))}play(){var i,r;if(this.isStopped)return;const{driver:e=yr,startTime:n}=this.options;this.driver||(this.driver=e(o=>this.tick(o))),(r=(i=this.options).onPlay)==null||r.call(i);const s=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=s):this.holdTime!==null?this.startTime=s-this.holdTime:this.startTime||(this.startTime=n??s),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(I.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var e,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(e=this.options).onComplete)==null||n.call(e)}cancel(){var e,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(e=this.options).onCancel)==null||n.call(e)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}attachTimeline(e){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),e.observe(this)}}function jr(t){for(let e=1;e<t.length;e++)t[e]??(t[e]=t[e-1])}const at=t=>t*180/Math.PI,Ve=t=>{const e=at(Math.atan2(t[1],t[0]));return Ce(e)},Br={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:t=>(Math.abs(t[0])+Math.abs(t[3]))/2,rotate:Ve,rotateZ:Ve,skewX:t=>at(Math.atan(t[1])),skewY:t=>at(Math.atan(t[2])),skew:t=>(Math.abs(t[1])+Math.abs(t[2]))/2},Ce=t=>(t=t%360,t<0&&(t+=360),t),Rn=Ve,Ln=t=>Math.sqrt(t[0]*t[0]+t[1]*t[1]),kn=t=>Math.sqrt(t[4]*t[4]+t[5]*t[5]),Ir={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Ln,scaleY:kn,scale:t=>(Ln(t)+kn(t))/2,rotateX:t=>Ce(at(Math.atan2(t[6],t[5]))),rotateY:t=>Ce(at(Math.atan2(-t[2],t[0]))),rotateZ:Rn,rotate:Rn,skewX:t=>at(Math.atan(t[4])),skewY:t=>at(Math.atan(t[1])),skew:t=>(Math.abs(t[1])+Math.abs(t[4]))/2};function De(t){return t.includes("scale")?1:0}function Me(t,e){if(!t||t==="none")return De(e);const n=t.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let s,i;if(n)s=Ir,i=n;else{const a=t.match(/^matrix\(([-\d.e\s,]+)\)$/u);s=Br,i=a}if(!i)return De(e);const r=s[e],o=i[1].split(",").map(Or);return typeof r=="function"?r(o):o[r]}const Nr=(t,e)=>{const{transform:n="none"}=getComputedStyle(t);return Me(n,e)};function Or(t){return parseFloat(t.trim())}const xt=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Tt=new Set(xt),Fn=t=>t===vt||t===x,Ur=new Set(["x","y","z"]),Wr=xt.filter(t=>!Ur.has(t));function Kr(t){const e=[];return Wr.forEach(n=>{const s=t.getValue(n);s!==void 0&&(e.push([n,s.get()]),s.set(n.startsWith("scale")?1:0))}),e}const tt={width:({x:t},{paddingLeft:e="0",paddingRight:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),height:({y:t},{paddingTop:e="0",paddingBottom:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),top:(t,{top:e})=>parseFloat(e),left:(t,{left:e})=>parseFloat(e),bottom:({y:t},{top:e})=>parseFloat(e)+(t.max-t.min),right:({x:t},{left:e})=>parseFloat(e)+(t.max-t.min),x:(t,{transform:e})=>Me(e,"x"),y:(t,{transform:e})=>Me(e,"y")};tt.translateX=tt.x;tt.translateY=tt.y;const lt=new Set;let Ee=!1,Re=!1,Le=!1;function pi(){if(Re){const t=Array.from(lt).filter(s=>s.needsMeasurement),e=new Set(t.map(s=>s.element)),n=new Map;e.forEach(s=>{const i=Kr(s);i.length&&(n.set(s,i),s.render())}),t.forEach(s=>s.measureInitialState()),e.forEach(s=>{s.render();const i=n.get(s);i&&i.forEach(([r,o])=>{var a;(a=s.getValue(r))==null||a.set(o)})}),t.forEach(s=>s.measureEndState()),t.forEach(s=>{s.suspendedScrollY!==void 0&&window.scrollTo(0,s.suspendedScrollY)})}Re=!1,Ee=!1,lt.forEach(t=>t.complete(Le)),lt.clear()}function mi(){lt.forEach(t=>{t.readKeyframes(),t.needsMeasurement&&(Re=!0)})}function zr(){Le=!0,mi(),pi(),Le=!1}class rn{constructor(e,n,s,i,r,o=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...e],this.onComplete=n,this.name=s,this.motionValue=i,this.element=r,this.isAsync=o}scheduleResolve(){this.state="scheduled",this.isAsync?(lt.add(this),Ee||(Ee=!0,C.read(mi),C.resolveKeyframes(pi))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:e,name:n,element:s,motionValue:i}=this;if(e[0]===null){const r=i==null?void 0:i.get(),o=e[e.length-1];if(r!==void 0)e[0]=r;else if(s&&n){const a=s.readValue(n,o);a!=null&&(e[0]=a)}e[0]===void 0&&(e[0]=o),i&&r===void 0&&i.set(e[0])}jr(e)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(e=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,e),lt.delete(this)}cancel(){this.state==="scheduled"&&(lt.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const $r=t=>t.startsWith("--");function gi(t,e,n){$r(e)?t.style.setProperty(e,n):t.style[e]=n}const Gr={};function yi(t,e){const n=zs(t);return()=>Gr[e]??n()}const Hr=yi(()=>window.ScrollTimeline!==void 0,"scrollTimeline"),vi=yi(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),St=([t,e,n,s])=>`cubic-bezier(${t}, ${e}, ${n}, ${s})`,jn={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:St([0,.65,.55,1]),circOut:St([.55,0,1,.45]),backIn:St([.31,.01,.66,-.59]),backOut:St([.33,1.53,.69,.99])};function xi(t,e){if(t)return typeof t=="function"?vi()?hi(t,e):"ease-out":ti(t)?St(t):Array.isArray(t)?t.map(n=>xi(n,e)||jn.easeOut):jn[t]}function _r(t,e,n,{delay:s=0,duration:i=300,repeat:r=0,repeatType:o="loop",ease:a="easeOut",times:l}={},u=void 0){const c={[e]:n};l&&(c.offset=l);const h=xi(a,i);Array.isArray(h)&&(c.easing=h);const d={delay:s,duration:i,easing:Array.isArray(h)?"linear":h,fill:"both",iterations:r+1,direction:o==="reverse"?"alternate":"normal"};return u&&(d.pseudoElement=u),t.animate(c,d)}function Ti(t){return typeof t=="function"&&"applyToOptions"in t}function Xr({type:t,...e}){return Ti(t)&&vi()?t.applyToOptions(e):(e.duration??(e.duration=300),e.ease??(e.ease="easeOut"),e)}class wi extends sn{constructor(e){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!e)return;const{element:n,name:s,keyframes:i,pseudoElement:r,allowFlatten:o=!1,finalKeyframe:a,onComplete:l}=e;this.isPseudoElement=!!r,this.allowFlatten=o,this.options=e,_e(typeof e.type!="string");const u=Xr(e);this.animation=_r(n,s,i,u,r),u.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!r){const c=nn(i,this.options,a,this.speed);this.updateMotionValue&&this.updateMotionValue(c),gi(n,s,c),this.animation.cancel()}l==null||l(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var e,n;(n=(e=this.animation).finish)==null||n.call(e)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:e}=this;e==="idle"||e==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var n,s,i;const e=(n=this.options)==null?void 0:n.element;!this.isPseudoElement&&(e!=null&&e.isConnected)&&((i=(s=this.animation).commitStyles)==null||i.call(s))}get duration(){var n,s;const e=((s=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:s.call(n).duration)||0;return W(Number(e))}get iterationDuration(){const{delay:e=0}=this.options||{};return this.duration+W(e)}get time(){return W(Number(this.animation.currentTime)||0)}set time(e){const n=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=G(e),n&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(e){e<0&&(this.finishedTime=null),this.animation.playbackRate=e}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(e){this.manualStartTime=this.animation.startTime=e}attachTimeline({timeline:e,rangeStart:n,rangeEnd:s,observe:i}){var r;return this.allowFlatten&&((r=this.animation.effect)==null||r.updateTiming({easing:"linear"})),this.animation.onfinish=null,e&&Hr()?(this.animation.timeline=e,n&&(this.animation.rangeStart=n),s&&(this.animation.rangeEnd=s),K):i(this)}}const bi={anticipate:qs,backInOut:Ys,circInOut:Qs};function Yr(t){return t in bi}function qr(t){typeof t.ease=="string"&&Yr(t.ease)&&(t.ease=bi[t.ease])}const ue=10;class Zr extends wi{constructor(e){qr(e),fi(e),super(e),e.startTime!==void 0&&(this.startTime=e.startTime),this.options=e}updateMotionValue(e){const{motionValue:n,onUpdate:s,onComplete:i,element:r,...o}=this.options;if(!n)return;if(e!==void 0){n.set(e);return}const a=new on({...o,autoplay:!1}),l=Math.max(ue,I.now()-this.startTime),u=Y(0,ue,l-ue),c=a.sample(l).value,{name:h}=this.options;r&&h&&gi(r,h,c),n.setWithVelocity(a.sample(Math.max(0,l-u)).value,c,u),a.stop()}}const Bn=(t,e)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(H.test(t)||t==="0")&&!t.startsWith("url("));function Qr(t){const e=t[0];if(t.length===1)return!0;for(let n=0;n<t.length;n++)if(t[n]!==e)return!0}function Jr(t,e,n,s){const i=t[0];if(i===null)return!1;if(e==="display"||e==="visibility")return!0;const r=t[t.length-1],o=Bn(i,e),a=Bn(r,e);return!o||!a?!1:Qr(t)||(n==="spring"||Ti(n))&&s}function ke(t){t.duration=0,t.type="keyframes"}const ta=new Set(["opacity","clipPath","filter","transform"]),ea=zs(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function na(t){var c;const{motionValue:e,name:n,repeatDelay:s,repeatType:i,damping:r,type:o}=t;if(!(((c=e==null?void 0:e.owner)==null?void 0:c.current)instanceof HTMLElement))return!1;const{onUpdate:l,transformTemplate:u}=e.owner.getProps();return ea()&&n&&ta.has(n)&&(n!=="transform"||!u)&&!l&&!s&&i!=="mirror"&&r!==0&&o!=="inertia"}const sa=40;class ia extends sn{constructor({autoplay:e=!0,delay:n=0,type:s="keyframes",repeat:i=0,repeatDelay:r=0,repeatType:o="loop",keyframes:a,name:l,motionValue:u,element:c,...h}){var p;super(),this.stop=()=>{var m,y;this._animation&&(this._animation.stop(),(m=this.stopTimeline)==null||m.call(this)),(y=this.keyframeResolver)==null||y.cancel()},this.createdAt=I.now();const d={autoplay:e,delay:n,type:s,repeat:i,repeatDelay:r,repeatType:o,name:l,motionValue:u,element:c,...h},f=(c==null?void 0:c.KeyframeResolver)||rn;this.keyframeResolver=new f(a,(m,y,v)=>this.onKeyframesResolved(m,y,d,!v),l,u,c),(p=this.keyframeResolver)==null||p.scheduleResolve()}onKeyframesResolved(e,n,s,i){var y,v;this.keyframeResolver=void 0;const{name:r,type:o,velocity:a,delay:l,isHandoff:u,onUpdate:c}=s;this.resolvedAt=I.now(),Jr(e,r,o,a)||((q.instantAnimations||!l)&&(c==null||c(nn(e,s,n))),e[0]=e[e.length-1],ke(s),s.repeat=0);const d={startTime:i?this.resolvedAt?this.resolvedAt-this.createdAt>sa?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...s,keyframes:e},f=!u&&na(d),p=(v=(y=d.motionValue)==null?void 0:y.owner)==null?void 0:v.current,m=f?new Zr({...d,element:p}):new on(d);m.finished.then(()=>{this.notifyFinished()}).catch(K),this.pendingTimeline&&(this.stopTimeline=m.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=m}get finished(){return this._animation?this.animation.finished:this._finished}then(e,n){return this.finished.finally(e).then(()=>{})}get animation(){var e;return this._animation||((e=this.keyframeResolver)==null||e.resume(),zr()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(e){this.animation.time=e}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(e){this.animation.speed=e}get startTime(){return this.animation.startTime}attachTimeline(e){return this._animation?this.stopTimeline=this.animation.attachTimeline(e):this.pendingTimeline=e,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var e;this._animation&&this.animation.cancel(),(e=this.keyframeResolver)==null||e.cancel()}}function Si(t,e,n,s=0,i=1){const r=Array.from(t).sort((u,c)=>u.sortNodePosition(c)).indexOf(e),o=t.size,a=(o-1)*s;return typeof n=="function"?n(r,o):i===1?r*s:a-r*s}const oa=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function ra(t){const e=oa.exec(t);if(!e)return[,];const[,n,s,i]=e;return[`--${n??s}`,i]}function Pi(t,e,n=1){const[s,i]=ra(t);if(!s)return;const r=window.getComputedStyle(e).getPropertyValue(s);if(r){const o=r.trim();return Us(o)?parseFloat(o):o}return Ze(i)?Pi(i,e,n+1):i}const aa={type:"spring",stiffness:500,damping:25,restSpeed:10},la=t=>({type:"spring",stiffness:550,damping:t===0?2*Math.sqrt(550):30,restSpeed:10}),ca={type:"keyframes",duration:.8},ua={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},ha=(t,{keyframes:e})=>e.length>2?ca:Tt.has(t)?t.startsWith("scale")?la(e[1]):aa:ua,da=t=>t!==null;function fa(t,{repeat:e,repeatType:n="loop"},s){const i=t.filter(da),r=e&&n!=="loop"&&e%2===1?0:i.length-1;return i[r]}function Ai(t,e){if(t!=null&&t.inherit&&e){const{inherit:n,...s}=t;return{...e,...s}}return t}function an(t,e){const n=(t==null?void 0:t[e])??(t==null?void 0:t.default)??t;return n!==t?Ai(n,t):n}function pa({when:t,delay:e,delayChildren:n,staggerChildren:s,staggerDirection:i,repeat:r,repeatType:o,repeatDelay:a,from:l,elapsed:u,...c}){return!!Object.keys(c).length}const ln=(t,e,n,s={},i,r)=>o=>{const a=an(s,t)||{},l=a.delay||s.delay||0;let{elapsed:u=0}=s;u=u-G(l);const c={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:e.getVelocity(),...a,delay:-u,onUpdate:d=>{e.set(d),a.onUpdate&&a.onUpdate(d)},onComplete:()=>{o(),a.onComplete&&a.onComplete()},name:t,motionValue:e,element:r?void 0:i};pa(a)||Object.assign(c,ha(t,c)),c.duration&&(c.duration=G(c.duration)),c.repeatDelay&&(c.repeatDelay=G(c.repeatDelay)),c.from!==void 0&&(c.keyframes[0]=c.from);let h=!1;if((c.type===!1||c.duration===0&&!c.repeatDelay)&&(ke(c),c.delay===0&&(h=!0)),(q.instantAnimations||q.skipAnimations||i!=null&&i.shouldSkipAnimations)&&(h=!0,ke(c),c.delay=0),c.allowFlatten=!a.type&&!a.ease,h&&!r&&e.get()!==void 0){const d=fa(c.keyframes,a);if(d!==void 0){C.update(()=>{c.onUpdate(d),c.onComplete()});return}}return a.isSync?new on(c):new ia(c)};function In(t){const e=[{},{}];return t==null||t.values.forEach((n,s)=>{e[0][s]=n.get(),e[1][s]=n.getVelocity()}),e}function cn(t,e,n,s){if(typeof e=="function"){const[i,r]=In(s);e=e(n!==void 0?n:t.custom,i,r)}if(typeof e=="string"&&(e=t.variants&&t.variants[e]),typeof e=="function"){const[i,r]=In(s);e=e(n!==void 0?n:t.custom,i,r)}return e}function gt(t,e,n){const s=t.getProps();return cn(s,e,n!==void 0?n:s.custom,t)}const Vi=new Set(["width","height","top","left","right","bottom",...xt]),Nn=30,ma=t=>!isNaN(parseFloat(t));class ga{constructor(e,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=s=>{var r;const i=I.now();if(this.updatedAt!==i&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(s),this.current!==this.prev&&((r=this.events.change)==null||r.notify(this.current),this.dependents))for(const o of this.dependents)o.dirty()},this.hasAnimated=!1,this.setCurrent(e),this.owner=n.owner}setCurrent(e){this.current=e,this.updatedAt=I.now(),this.canTrackVelocity===null&&e!==void 0&&(this.canTrackVelocity=ma(this.current))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return this.on("change",e)}on(e,n){this.events[e]||(this.events[e]=new Xe);const s=this.events[e].add(n);return e==="change"?()=>{s(),C.read(()=>{this.events.change.getSize()||this.stop()})}:s}clearListeners(){for(const e in this.events)this.events[e].clear()}attach(e,n){this.passiveEffect=e,this.stopPassiveEffect=n}set(e){this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e)}setWithVelocity(e,n,s){this.set(n),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-s}jump(e,n=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var e;(e=this.events.change)==null||e.notify(this.current)}addDependent(e){this.dependents||(this.dependents=new Set),this.dependents.add(e)}removeDependent(e){this.dependents&&this.dependents.delete(e)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const e=I.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||e-this.updatedAt>Nn)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Nn);return $s(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(e){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=e(n),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(){var e,n;(e=this.dependents)==null||e.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function yt(t,e){return new ga(t,e)}const Fe=t=>Array.isArray(t);function ya(t,e,n){t.hasValue(e)?t.getValue(e).set(n):t.addValue(e,yt(n))}function va(t){return Fe(t)?t[t.length-1]||0:t}function xa(t,e){const n=gt(t,e);let{transitionEnd:s={},transition:i={},...r}=n||{};r={...r,...s};for(const o in r){const a=va(r[o]);ya(t,o,a)}}const j=t=>!!(t&&t.getVelocity);function Ta(t){return!!(j(t)&&t.add)}function je(t,e){const n=t.getValue("willChange");if(Ta(n))return n.add(e);if(!n&&q.WillChange){const s=new q.WillChange("auto");t.addValue("willChange",s),s.add(e)}}function un(t){return t.replace(/([A-Z])/g,e=>`-${e.toLowerCase()}`)}const wa="framerAppearId",Ci="data-"+un(wa);function Di(t){return t.props[Ci]}function ba({protectedKeys:t,needsAnimating:e},n){const s=t.hasOwnProperty(n)&&e[n]!==!0;return e[n]=!1,s}function Mi(t,e,{delay:n=0,transitionOverride:s,type:i}={}){let{transition:r,transitionEnd:o,...a}=e;const l=t.getDefaultTransition();r=r?Ai(r,l):l;const u=r==null?void 0:r.reduceMotion;s&&(r=s);const c=[],h=i&&t.animationState&&t.animationState.getState()[i];for(const d in a){const f=t.getValue(d,t.latestValues[d]??null),p=a[d];if(p===void 0||h&&ba(h,d))continue;const m={delay:n,...an(r||{},d)},y=f.get();if(y!==void 0&&!f.isAnimating&&!Array.isArray(p)&&p===y&&!m.velocity)continue;let v=!1;if(window.MotionHandoffAnimation){const b=Di(t);if(b){const w=window.MotionHandoffAnimation(b,d,C);w!==null&&(m.startTime=w,v=!0)}}je(t,d);const T=u??t.shouldReduceMotion;f.start(ln(d,f,p,T&&Vi.has(d)?{type:!1}:m,t,v));const g=f.animation;g&&c.push(g)}if(o){const d=()=>C.update(()=>{o&&xa(t,o)});c.length?Promise.all(c).then(d):d()}return c}function Be(t,e,n={}){var l;const s=gt(t,e,n.type==="exit"?(l=t.presenceContext)==null?void 0:l.custom:void 0);let{transition:i=t.getDefaultTransition()||{}}=s||{};n.transitionOverride&&(i=n.transitionOverride);const r=s?()=>Promise.all(Mi(t,s,n)):()=>Promise.resolve(),o=t.variantChildren&&t.variantChildren.size?(u=0)=>{const{delayChildren:c=0,staggerChildren:h,staggerDirection:d}=i;return Sa(t,e,u,c,h,d,n)}:()=>Promise.resolve(),{when:a}=i;if(a){const[u,c]=a==="beforeChildren"?[r,o]:[o,r];return u().then(()=>c())}else return Promise.all([r(),o(n.delay)])}function Sa(t,e,n=0,s=0,i=0,r=1,o){const a=[];for(const l of t.variantChildren)l.notify("AnimationStart",e),a.push(Be(l,e,{...o,delay:n+(typeof s=="function"?0:s)+Si(t.variantChildren,l,s,i,r)}).then(()=>l.notify("AnimationComplete",e)));return Promise.all(a)}function Pa(t,e,n={}){t.notify("AnimationStart",e);let s;if(Array.isArray(e)){const i=e.map(r=>Be(t,r,n));s=Promise.all(i)}else if(typeof e=="string")s=Be(t,e,n);else{const i=typeof e=="function"?gt(t,e,n.custom):e;s=Promise.all(Mi(t,i,n))}return s.then(()=>{t.notify("AnimationComplete",e)})}const Aa={test:t=>t==="auto",parse:t=>t},Ei=t=>e=>e.test(t),Ri=[vt,x,X,Q,er,tr,Aa],On=t=>Ri.find(Ei(t));function Va(t){return typeof t=="number"?t===0:t!==null?t==="none"||t==="0"||Ks(t):!0}const Ca=new Set(["brightness","contrast","saturate","opacity"]);function Da(t){const[e,n]=t.slice(0,-1).split("(");if(e==="drop-shadow")return t;const[s]=n.match(Qe)||[];if(!s)return t;const i=n.replace(s,"");let r=Ca.has(e)?1:0;return s!==n&&(r*=100),e+"("+r+i+")"}const Ma=/\b([a-z-]*)\(.*?\)/gu,Ie={...H,getAnimatableNone:t=>{const e=t.match(Ma);return e?e.map(Da).join(" "):t}},Ne={...H,getAnimatableNone:t=>{const e=H.parse(t);return H.createTransformer(t)(e.map(s=>typeof s=="number"?0:typeof s=="object"?{...s,alpha:1}:s))}},Un={...vt,transform:Math.round},Ea={rotate:Q,rotateX:Q,rotateY:Q,rotateZ:Q,scale:Nt,scaleX:Nt,scaleY:Nt,scaleZ:Nt,skew:Q,skewX:Q,skewY:Q,distance:x,translateX:x,translateY:x,translateZ:x,x,y:x,z:x,perspective:x,transformPerspective:x,opacity:Mt,originX:Vn,originY:Vn,originZ:x},hn={borderWidth:x,borderTopWidth:x,borderRightWidth:x,borderBottomWidth:x,borderLeftWidth:x,borderRadius:x,borderTopLeftRadius:x,borderTopRightRadius:x,borderBottomRightRadius:x,borderBottomLeftRadius:x,width:x,maxWidth:x,height:x,maxHeight:x,top:x,right:x,bottom:x,left:x,inset:x,insetBlock:x,insetBlockStart:x,insetBlockEnd:x,insetInline:x,insetInlineStart:x,insetInlineEnd:x,padding:x,paddingTop:x,paddingRight:x,paddingBottom:x,paddingLeft:x,paddingBlock:x,paddingBlockStart:x,paddingBlockEnd:x,paddingInline:x,paddingInlineStart:x,paddingInlineEnd:x,margin:x,marginTop:x,marginRight:x,marginBottom:x,marginLeft:x,marginBlock:x,marginBlockStart:x,marginBlockEnd:x,marginInline:x,marginInlineStart:x,marginInlineEnd:x,fontSize:x,backgroundPositionX:x,backgroundPositionY:x,...Ea,zIndex:Un,fillOpacity:Mt,strokeOpacity:Mt,numOctaves:Un},Ra={...hn,color:R,backgroundColor:R,outlineColor:R,fill:R,stroke:R,borderColor:R,borderTopColor:R,borderRightColor:R,borderBottomColor:R,borderLeftColor:R,filter:Ie,WebkitFilter:Ie,mask:Ne,WebkitMask:Ne},Li=t=>Ra[t],La=new Set([Ie,Ne]);function ki(t,e){let n=Li(t);return La.has(n)||(n=H),n.getAnimatableNone?n.getAnimatableNone(e):void 0}const ka=new Set(["auto","none","0"]);function Fa(t,e,n){let s=0,i;for(;s<t.length&&!i;){const r=t[s];typeof r=="string"&&!ka.has(r)&&Et(r).values.length&&(i=t[s]),s++}if(i&&n)for(const r of e)t[r]=ki(n,i)}class ja extends rn{constructor(e,n,s,i,r){super(e,n,s,i,r,!0)}readKeyframes(){const{unresolvedKeyframes:e,element:n,name:s}=this;if(!n||!n.current)return;super.readKeyframes();for(let c=0;c<e.length;c++){let h=e[c];if(typeof h=="string"&&(h=h.trim(),Ze(h))){const d=Pi(h,n.current);d!==void 0&&(e[c]=d),c===e.length-1&&(this.finalKeyframe=h)}}if(this.resolveNoneKeyframes(),!Vi.has(s)||e.length!==2)return;const[i,r]=e,o=On(i),a=On(r),l=An(i),u=An(r);if(l!==u&&tt[s]){this.needsMeasurement=!0;return}if(o!==a)if(Fn(o)&&Fn(a))for(let c=0;c<e.length;c++){const h=e[c];typeof h=="string"&&(e[c]=parseFloat(h))}else tt[s]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:e,name:n}=this,s=[];for(let i=0;i<e.length;i++)(e[i]===null||Va(e[i]))&&s.push(i);s.length&&Fa(e,s,n)}measureInitialState(){const{element:e,unresolvedKeyframes:n,name:s}=this;if(!e||!e.current)return;s==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=tt[s](e.measureViewportBox(),window.getComputedStyle(e.current)),n[0]=this.measuredOrigin;const i=n[n.length-1];i!==void 0&&e.getValue(s,i).jump(i,!1)}measureEndState(){var a;const{element:e,name:n,unresolvedKeyframes:s}=this;if(!e||!e.current)return;const i=e.getValue(n);i&&i.jump(this.measuredOrigin,!1);const r=s.length-1,o=s[r];s[r]=tt[n](e.measureViewportBox(),window.getComputedStyle(e.current)),o!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=o),(a=this.removedTransforms)!=null&&a.length&&this.removedTransforms.forEach(([l,u])=>{e.getValue(l).set(u)}),this.resolveNoneKeyframes()}}const Ba=new Set(["opacity","clipPath","filter","transform"]);function Fi(t,e,n){if(t==null)return[];if(t instanceof EventTarget)return[t];if(typeof t=="string"){let s=document;const i=(n==null?void 0:n[t])??s.querySelectorAll(t);return i?Array.from(i):[]}return Array.from(t).filter(s=>s!=null)}const ji=(t,e)=>e&&typeof t=="number"?e.transform(t):t;function Ia(t){return Ws(t)&&"offsetHeight"in t}const{schedule:dn}=ei(queueMicrotask,!1),$={x:!1,y:!1};function Bi(){return $.x||$.y}function Na(t){return t==="x"||t==="y"?$[t]?null:($[t]=!0,()=>{$[t]=!1}):$.x||$.y?null:($.x=$.y=!0,()=>{$.x=$.y=!1})}function Ii(t,e){const n=Fi(t),s=new AbortController,i={passive:!0,...e,signal:s.signal};return[n,i,()=>s.abort()]}function Oa(t){return!(t.pointerType==="touch"||Bi())}function Ua(t,e,n={}){const[s,i,r]=Ii(t,n);return s.forEach(o=>{let a=!1,l=!1,u;const c=()=>{o.removeEventListener("pointerleave",p)},h=y=>{u&&(u(y),u=void 0),c()},d=y=>{a=!1,window.removeEventListener("pointerup",d),window.removeEventListener("pointercancel",d),l&&(l=!1,h(y))},f=()=>{a=!0,window.addEventListener("pointerup",d,i),window.addEventListener("pointercancel",d,i)},p=y=>{if(y.pointerType!=="touch"){if(a){l=!0;return}h(y)}},m=y=>{if(!Oa(y))return;l=!1;const v=e(o,y);typeof v=="function"&&(u=v,o.addEventListener("pointerleave",p,i))};o.addEventListener("pointerenter",m,i),o.addEventListener("pointerdown",f,i)}),r}const Ni=(t,e)=>e?t===e?!0:Ni(t,e.parentElement):!1,fn=t=>t.pointerType==="mouse"?typeof t.button!="number"||t.button<=0:t.isPrimary!==!1,Wa=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function Ka(t){return Wa.has(t.tagName)||t.isContentEditable===!0}const za=new Set(["INPUT","SELECT","TEXTAREA"]);function $a(t){return za.has(t.tagName)||t.isContentEditable===!0}const Wt=new WeakSet;function Wn(t){return e=>{e.key==="Enter"&&t(e)}}function he(t,e){t.dispatchEvent(new PointerEvent("pointer"+e,{isPrimary:!0,bubbles:!0}))}const Ga=(t,e)=>{const n=t.currentTarget;if(!n)return;const s=Wn(()=>{if(Wt.has(n))return;he(n,"down");const i=Wn(()=>{he(n,"up")}),r=()=>he(n,"cancel");n.addEventListener("keyup",i,e),n.addEventListener("blur",r,e)});n.addEventListener("keydown",s,e),n.addEventListener("blur",()=>n.removeEventListener("keydown",s),e)};function Kn(t){return fn(t)&&!Bi()}const zn=new WeakSet;function Ha(t,e,n={}){const[s,i,r]=Ii(t,n),o=a=>{const l=a.currentTarget;if(!Kn(a)||zn.has(a))return;Wt.add(l),n.stopPropagation&&zn.add(a);const u=e(l,a),c=(f,p)=>{window.removeEventListener("pointerup",h),window.removeEventListener("pointercancel",d),Wt.has(l)&&Wt.delete(l),Kn(f)&&typeof u=="function"&&u(f,{success:p})},h=f=>{c(f,l===window||l===document||n.useGlobalTarget||Ni(l,f.target))},d=f=>{c(f,!1)};window.addEventListener("pointerup",h,i),window.addEventListener("pointercancel",d,i)};return s.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",o,i),Ia(a)&&(a.addEventListener("focus",u=>Ga(u,i)),!Ka(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),r}function pn(t){return Ws(t)&&"ownerSVGElement"in t}const Kt=new WeakMap;let J;const Oi=(t,e,n)=>(s,i)=>i&&i[0]?i[0][t+"Size"]:pn(s)&&"getBBox"in s?s.getBBox()[e]:s[n],_a=Oi("inline","width","offsetWidth"),Xa=Oi("block","height","offsetHeight");function Ya({target:t,borderBoxSize:e}){var n;(n=Kt.get(t))==null||n.forEach(s=>{s(t,{get width(){return _a(t,e)},get height(){return Xa(t,e)}})})}function qa(t){t.forEach(Ya)}function Za(){typeof ResizeObserver>"u"||(J=new ResizeObserver(qa))}function Qa(t,e){J||Za();const n=Fi(t);return n.forEach(s=>{let i=Kt.get(s);i||(i=new Set,Kt.set(s,i)),i.add(e),J==null||J.observe(s)}),()=>{n.forEach(s=>{const i=Kt.get(s);i==null||i.delete(e),i!=null&&i.size||J==null||J.unobserve(s)})}}const zt=new Set;let dt;function Ja(){dt=()=>{const t={get width(){return window.innerWidth},get height(){return window.innerHeight}};zt.forEach(e=>e(t))},window.addEventListener("resize",dt)}function tl(t){return zt.add(t),dt||Ja(),()=>{zt.delete(t),!zt.size&&typeof dt=="function"&&(window.removeEventListener("resize",dt),dt=void 0)}}function $n(t,e){return typeof t=="function"?tl(t):Qa(t,e)}function el(t){return pn(t)&&t.tagName==="svg"}const nl=[...Ri,R,H],sl=t=>nl.find(Ei(t)),Gn=()=>({translate:0,scale:1,origin:0,originPoint:0}),ft=()=>({x:Gn(),y:Gn()}),Hn=()=>({min:0,max:0}),L=()=>({x:Hn(),y:Hn()}),il=new WeakMap;function te(t){return t!==null&&typeof t=="object"&&typeof t.start=="function"}function Rt(t){return typeof t=="string"||Array.isArray(t)}const mn=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],gn=["initial",...mn];function ee(t){return te(t.animate)||gn.some(e=>Rt(t[e]))}function Ui(t){return!!(ee(t)||t.variants)}function ol(t,e,n){for(const s in e){const i=e[s],r=n[s];if(j(i))t.addValue(s,i);else if(j(r))t.addValue(s,yt(i,{owner:t}));else if(r!==i)if(t.hasValue(s)){const o=t.getValue(s);o.liveStyle===!0?o.jump(i):o.hasAnimated||o.set(i)}else{const o=t.getStaticValue(s);t.addValue(s,yt(o!==void 0?o:i,{owner:t}))}}for(const s in n)e[s]===void 0&&t.removeValue(s);return e}const Oe={current:null},Wi={current:!1},rl=typeof window<"u";function al(){if(Wi.current=!0,!!rl)if(window.matchMedia){const t=window.matchMedia("(prefers-reduced-motion)"),e=()=>Oe.current=t.matches;t.addEventListener("change",e),e()}else Oe.current=!1}const _n=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let qt={};function Ki(t){qt=t}function ll(){return qt}class cl{scrapeMotionValuesFromProps(e,n,s){return{}}constructor({parent:e,props:n,presenceContext:s,reducedMotionConfig:i,skipAnimations:r,blockInitialAnimation:o,visualState:a},l={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=rn,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,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=()=>{const f=I.now();this.renderScheduledAt<f&&(this.renderScheduledAt=f,C.render(this.render,!1,!0))};const{latestValues:u,renderState:c}=a;this.latestValues=u,this.baseTarget={...u},this.initialValues=n.initial?{...u}:{},this.renderState=c,this.parent=e,this.props=n,this.presenceContext=s,this.depth=e?e.depth+1:0,this.reducedMotionConfig=i,this.skipAnimationsConfig=r,this.options=l,this.blockInitialAnimation=!!o,this.isControllingVariants=ee(n),this.isVariantNode=Ui(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(e&&e.current);const{willChange:h,...d}=this.scrapeMotionValuesFromProps(n,{},this);for(const f in d){const p=d[f];u[f]!==void 0&&j(p)&&p.set(u[f])}}mount(e){var n,s;if(this.hasBeenMounted)for(const i in this.initialValues)(n=this.values.get(i))==null||n.jump(this.initialValues[i]),this.latestValues[i]=this.initialValues[i];this.current=e,il.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((i,r)=>this.bindToMotionValue(r,i)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(Wi.current||al(),this.shouldReduceMotion=Oe.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,(s=this.parent)==null||s.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){var e;this.projection&&this.projection.unmount(),et(this.notifyUpdate),et(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(e=this.parent)==null||e.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const s=this.features[n];s&&(s.unmount(),s.isMounted=!1)}this.current=null}addChild(e){this.children.add(e),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(e)}removeChild(e){this.children.delete(e),this.enteringChildren&&this.enteringChildren.delete(e)}bindToMotionValue(e,n){if(this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)(),n.accelerate&&Ba.has(e)&&this.current instanceof HTMLElement){const{factory:o,keyframes:a,times:l,ease:u,duration:c}=n.accelerate,h=new wi({element:this.current,name:e,keyframes:a,times:l,ease:u,duration:G(c)}),d=o(h);this.valueSubscriptions.set(e,()=>{d(),h.cancel()});return}const s=Tt.has(e);s&&this.onBindTransform&&this.onBindTransform();const i=n.on("change",o=>{this.latestValues[e]=o,this.props.onUpdate&&C.preRender(this.notifyUpdate),s&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let r;typeof window<"u"&&window.MotionCheckAppearSync&&(r=window.MotionCheckAppearSync(this,e,n)),this.valueSubscriptions.set(e,()=>{i(),r&&r(),n.owner&&n.stop()})}sortNodePosition(e){return!this.current||!this.sortInstanceNodePosition||this.type!==e.type?0:this.sortInstanceNodePosition(this.current,e.current)}updateFeatures(){let e="animation";for(e in qt){const n=qt[e];if(!n)continue;const{isEnabled:s,Feature:i}=n;if(!this.features[e]&&i&&s(this.props)&&(this.features[e]=new i(this)),this.features[e]){const r=this.features[e];r.isMounted?r.update():(r.mount(),r.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):L()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,n){this.latestValues[e]=n}update(e,n){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let s=0;s<_n.length;s++){const i=_n[s];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const r="on"+i,o=e[r];o&&(this.propEventSubscriptions[i]=this.on(i,o))}this.prevMotionValues=ol(this,this.scrapeMotionValuesFromProps(e,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]: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(e){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(e),()=>n.variantChildren.delete(e)}addValue(e,n){const s=this.values.get(e);n!==s&&(s&&this.removeValue(e),this.bindToMotionValue(e,n),this.values.set(e,n),this.latestValues[e]=n.get())}removeValue(e){this.values.delete(e);const n=this.valueSubscriptions.get(e);n&&(n(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,n){if(this.props.values&&this.props.values[e])return this.props.values[e];let s=this.values.get(e);return s===void 0&&n!==void 0&&(s=yt(n===null?void 0:n,{owner:this}),this.addValue(e,s)),s}readValue(e,n){let s=this.latestValues[e]!==void 0||!this.current?this.latestValues[e]:this.getBaseTargetFromProps(this.props,e)??this.readValueFromInstance(this.current,e,this.options);return s!=null&&(typeof s=="string"&&(Us(s)||Ks(s))?s=parseFloat(s):!sl(s)&&H.test(n)&&(s=ki(e,n)),this.setBaseTarget(e,j(s)?s.get():s)),j(s)?s.get():s}setBaseTarget(e,n){this.baseTarget[e]=n}getBaseTarget(e){var r;const{initial:n}=this.props;let s;if(typeof n=="string"||typeof n=="object"){const o=cn(this.props,n,(r=this.presenceContext)==null?void 0:r.custom);o&&(s=o[e])}if(n&&s!==void 0)return s;const i=this.getBaseTargetFromProps(this.props,e);return i!==void 0&&!j(i)?i:this.initialValues[e]!==void 0&&s===void 0?void 0:this.baseTarget[e]}on(e,n){return this.events[e]||(this.events[e]=new Xe),this.events[e].add(n)}notify(e,...n){this.events[e]&&this.events[e].notify(...n)}scheduleRenderMicrotask(){dn.render(this.render)}}class zi extends cl{constructor(){super(...arguments),this.KeyframeResolver=ja}sortInstanceNodePosition(e,n){return e.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(e,n){const s=e.style;return s?s[n]:void 0}removeValueFromRenderState(e,{vars:n,style:s}){delete n[e],delete s[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:e}=this.props;j(e)&&(this.childSubscription=e.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class nt{constructor(e){this.isMounted=!1,this.node=e}update(){}}function $i({top:t,left:e,right:n,bottom:s}){return{x:{min:e,max:n},y:{min:t,max:s}}}function ul({x:t,y:e}){return{top:e.min,right:t.max,bottom:e.max,left:t.min}}function hl(t,e){if(!e)return t;const n=e({x:t.left,y:t.top}),s=e({x:t.right,y:t.bottom});return{top:n.y,left:n.x,bottom:s.y,right:s.x}}function de(t){return t===void 0||t===1}function Ue({scale:t,scaleX:e,scaleY:n}){return!de(t)||!de(e)||!de(n)}function ot(t){return Ue(t)||Gi(t)||t.z||t.rotate||t.rotateX||t.rotateY||t.skewX||t.skewY}function Gi(t){return Xn(t.x)||Xn(t.y)}function Xn(t){return t&&t!=="0%"}function Zt(t,e,n){const s=t-n,i=e*s;return n+i}function Yn(t,e,n,s,i){return i!==void 0&&(t=Zt(t,i,s)),Zt(t,n,s)+e}function We(t,e=0,n=1,s,i){t.min=Yn(t.min,e,n,s,i),t.max=Yn(t.max,e,n,s,i)}function Hi(t,{x:e,y:n}){We(t.x,e.translate,e.scale,e.originPoint),We(t.y,n.translate,n.scale,n.originPoint)}const qn=.999999999999,Zn=1.0000000000001;function dl(t,e,n,s=!1){const i=n.length;if(!i)return;e.x=e.y=1;let r,o;for(let a=0;a<i;a++){r=n[a],o=r.projectionDelta;const{visualElement:l}=r.options;l&&l.props.style&&l.props.style.display==="contents"||(s&&r.options.layoutScroll&&r.scroll&&r!==r.root&&mt(t,{x:-r.scroll.offset.x,y:-r.scroll.offset.y}),o&&(e.x*=o.x.scale,e.y*=o.y.scale,Hi(t,o)),s&&ot(r.latestValues)&&mt(t,r.latestValues))}e.x<Zn&&e.x>qn&&(e.x=1),e.y<Zn&&e.y>qn&&(e.y=1)}function pt(t,e){t.min=t.min+e,t.max=t.max+e}function Qn(t,e,n,s,i=.5){const r=D(t.min,t.max,i);We(t,e,n,r,s)}function Jn(t,e){return typeof t=="string"?parseFloat(t)/100*(e.max-e.min):t}function mt(t,e){Qn(t.x,Jn(e.x,t.x),e.scaleX,e.scale,e.originX),Qn(t.y,Jn(e.y,t.y),e.scaleY,e.scale,e.originY)}function _i(t,e){return $i(hl(t.getBoundingClientRect(),e))}function fl(t,e,n){const s=_i(t,n),{scroll:i}=e;return i&&(pt(s.x,i.offset.x),pt(s.y,i.offset.y)),s}const pl={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},ml=xt.length;function gl(t,e,n){let s="",i=!0;for(let r=0;r<ml;r++){const o=xt[r],a=t[o];if(a===void 0)continue;let l=!0;if(typeof a=="number")l=a===(o.startsWith("scale")?1:0);else{const u=parseFloat(a);l=o.startsWith("scale")?u===1:u===0}if(!l||n){const u=ji(a,hn[o]);if(!l){i=!1;const c=pl[o]||o;s+=`${c}(${u}) `}n&&(e[o]=u)}}return s=s.trim(),n?s=n(e,i?"":s):i&&(s="none"),s}function yn(t,e,n){const{style:s,vars:i,transformOrigin:r}=t;let o=!1,a=!1;for(const l in e){const u=e[l];if(Tt.has(l)){o=!0;continue}else if(si(l)){i[l]=u;continue}else{const c=ji(u,hn[l]);l.startsWith("origin")?(a=!0,r[l]=c):s[l]=c}}if(e.transform||(o||n?s.transform=gl(e,t.transform,n):s.transform&&(s.transform="none")),a){const{originX:l="50%",originY:u="50%",originZ:c=0}=r;s.transformOrigin=`${l} ${u} ${c}`}}function Xi(t,{style:e,vars:n},s,i){const r=t.style;let o;for(o in e)r[o]=e[o];i==null||i.applyProjectionStyles(r,s);for(o in n)r.setProperty(o,n[o])}function ts(t,e){return e.max===e.min?0:t/(e.max-e.min)*100}const bt={correct:(t,e)=>{if(!e.target)return t;if(typeof t=="string")if(x.test(t))t=parseFloat(t);else return t;const n=ts(t,e.target.x),s=ts(t,e.target.y);return`${n}% ${s}%`}},yl={correct:(t,{treeScale:e,projectionDelta:n})=>{const s=t,i=H.parse(t);if(i.length>5)return s;const r=H.createTransformer(t),o=typeof i[0]!="number"?1:0,a=n.x.scale*e.x,l=n.y.scale*e.y;i[0+o]/=a,i[1+o]/=l;const u=D(a,l,.5);return typeof i[2+o]=="number"&&(i[2+o]/=u),typeof i[3+o]=="number"&&(i[3+o]/=u),r(i)}},Ke={borderRadius:{...bt,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:bt,borderTopRightRadius:bt,borderBottomLeftRadius:bt,borderBottomRightRadius:bt,boxShadow:yl};function Yi(t,{layout:e,layoutId:n}){return Tt.has(t)||t.startsWith("origin")||(e||n!==void 0)&&(!!Ke[t]||t==="opacity")}function vn(t,e,n){var o;const s=t.style,i=e==null?void 0:e.style,r={};if(!s)return r;for(const a in s)(j(s[a])||i&&j(i[a])||Yi(a,t)||((o=n==null?void 0:n.getValue(a))==null?void 0:o.liveStyle)!==void 0)&&(r[a]=s[a]);return r}function vl(t){return window.getComputedStyle(t)}class xl extends zi{constructor(){super(...arguments),this.type="html",this.renderInstance=Xi}readValueFromInstance(e,n){var s;if(Tt.has(n))return(s=this.projection)!=null&&s.isProjecting?De(n):Nr(e,n);{const i=vl(e),r=(si(n)?i.getPropertyValue(n):i[n])||0;return typeof r=="string"?r.trim():r}}measureInstanceViewportBox(e,{transformPagePoint:n}){return _i(e,n)}build(e,n,s){yn(e,n,s.transformTemplate)}scrapeMotionValuesFromProps(e,n,s){return vn(e,n,s)}}const Tl={offset:"stroke-dashoffset",array:"stroke-dasharray"},wl={offset:"strokeDashoffset",array:"strokeDasharray"};function bl(t,e,n=1,s=0,i=!0){t.pathLength=1;const r=i?Tl:wl;t[r.offset]=`${-s}`,t[r.array]=`${e} ${n}`}const Sl=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function qi(t,{attrX:e,attrY:n,attrScale:s,pathLength:i,pathSpacing:r=1,pathOffset:o=0,...a},l,u,c){if(yn(t,a,u),l){t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox);return}t.attrs=t.style,t.style={};const{attrs:h,style:d}=t;h.transform&&(d.transform=h.transform,delete h.transform),(d.transform||h.transformOrigin)&&(d.transformOrigin=h.transformOrigin??"50% 50%",delete h.transformOrigin),d.transform&&(d.transformBox=(c==null?void 0:c.transformBox)??"fill-box",delete h.transformBox);for(const f of Sl)h[f]!==void 0&&(d[f]=h[f],delete h[f]);e!==void 0&&(h.x=e),n!==void 0&&(h.y=n),s!==void 0&&(h.scale=s),i!==void 0&&bl(h,i,r,o,!1)}const Zi=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"]),Qi=t=>typeof t=="string"&&t.toLowerCase()==="svg";function Pl(t,e,n,s){Xi(t,e,void 0,s);for(const i in e.attrs)t.setAttribute(Zi.has(i)?i:un(i),e.attrs[i])}function Ji(t,e,n){const s=vn(t,e,n);for(const i in t)if(j(t[i])||j(e[i])){const r=xt.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;s[r]=t[i]}return s}class Al extends zi{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=L}getBaseTargetFromProps(e,n){return e[n]}readValueFromInstance(e,n){if(Tt.has(n)){const s=Li(n);return s&&s.default||0}return n=Zi.has(n)?n:un(n),e.getAttribute(n)}scrapeMotionValuesFromProps(e,n,s){return Ji(e,n,s)}build(e,n,s){qi(e,n,this.isSVGTag,s.transformTemplate,s.style)}renderInstance(e,n,s,i){Pl(e,n,s,i)}mount(e){this.isSVGTag=Qi(e.tagName),super.mount(e)}}const Vl=gn.length;function to(t){if(!t)return;if(!t.isControllingVariants){const n=t.parent?to(t.parent)||{}:{};return t.props.initial!==void 0&&(n.initial=t.props.initial),n}const e={};for(let n=0;n<Vl;n++){const s=gn[n],i=t.props[s];(Rt(i)||i===!1)&&(e[s]=i)}return e}function eo(t,e){if(!Array.isArray(e))return!1;const n=e.length;if(n!==t.length)return!1;for(let s=0;s<n;s++)if(e[s]!==t[s])return!1;return!0}const Cl=[...mn].reverse(),Dl=mn.length;function Ml(t){return e=>Promise.all(e.map(({animation:n,options:s})=>Pa(t,n,s)))}function El(t){let e=Ml(t),n=es(),s=!0,i=!1;const r=u=>(c,h)=>{var f;const d=gt(t,h,u==="exit"?(f=t.presenceContext)==null?void 0:f.custom:void 0);if(d){const{transition:p,transitionEnd:m,...y}=d;c={...c,...y,...m}}return c};function o(u){e=u(t)}function a(u){const{props:c}=t,h=to(t.parent)||{},d=[],f=new Set;let p={},m=1/0;for(let v=0;v<Dl;v++){const T=Cl[v],g=n[T],b=c[T]!==void 0?c[T]:h[T],w=Rt(b),V=T===u?g.isActive:null;V===!1&&(m=v);let E=b===h[T]&&b!==c[T]&&w;if(E&&(s||i)&&t.manuallyAnimateOnMount&&(E=!1),g.protectedKeys={...p},!g.isActive&&V===null||!b&&!g.prevProp||te(b)||typeof b=="boolean")continue;if(T==="exit"&&g.isActive&&V!==!0){g.prevResolvedValues&&(p={...p,...g.prevResolvedValues});continue}const P=Rl(g.prevProp,b);let B=P||T===u&&g.isActive&&!E&&w||v>m&&w,O=!1;const se=Array.isArray(b)?b:[b];let wt=se.reduce(r(T),{});V===!1&&(wt={});const{prevResolvedValues:wn={}}=g,Vo={...wn,...wt},bn=k=>{B=!0,f.has(k)&&(O=!0,f.delete(k)),g.needsAnimating[k]=!0;const U=t.getValue(k);U&&(U.liveStyle=!1)};for(const k in Vo){const U=wt[k],st=wn[k];if(p.hasOwnProperty(k))continue;let ct=!1;Fe(U)&&Fe(st)?ct=!eo(U,st):ct=U!==st,ct?U!=null?bn(k):f.add(k):U!==void 0&&f.has(k)?bn(k):g.protectedKeys[k]=!0}g.prevProp=b,g.prevResolvedValues=wt,g.isActive&&(p={...p,...wt}),(s||i)&&t.blockInitialAnimation&&(B=!1);const Sn=E&&P;B&&(!Sn||O)&&d.push(...se.map(k=>{const U={type:T};if(typeof k=="string"&&(s||i)&&!Sn&&t.manuallyAnimateOnMount&&t.parent){const{parent:st}=t,ct=gt(st,k);if(st.enteringChildren&&ct){const{delayChildren:Co}=ct.transition||{};U.delay=Si(st.enteringChildren,t,Co)}}return{animation:k,options:U}}))}if(f.size){const v={};if(typeof c.initial!="boolean"){const T=gt(t,Array.isArray(c.initial)?c.initial[0]:c.initial);T&&T.transition&&(v.transition=T.transition)}f.forEach(T=>{const g=t.getBaseTarget(T),b=t.getValue(T);b&&(b.liveStyle=!0),v[T]=g??null}),d.push({animation:v})}let y=!!d.length;return s&&(c.initial===!1||c.initial===c.animate)&&!t.manuallyAnimateOnMount&&(y=!1),s=!1,i=!1,y?e(d):Promise.resolve()}function l(u,c){var d;if(n[u].isActive===c)return Promise.resolve();(d=t.variantChildren)==null||d.forEach(f=>{var p;return(p=f.animationState)==null?void 0:p.setActive(u,c)}),n[u].isActive=c;const h=a(u);for(const f in n)n[f].protectedKeys={};return h}return{animateChanges:a,setActive:l,setAnimateFunction:o,getState:()=>n,reset:()=>{n=es(),i=!0}}}function Rl(t,e){return typeof e=="string"?e!==t:Array.isArray(e)?!eo(e,t):!1}function it(t=!1){return{isActive:t,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function es(){return{animate:it(!0),whileInView:it(),whileHover:it(),whileTap:it(),whileDrag:it(),whileFocus:it(),exit:it()}}function ns(t,e){t.min=e.min,t.max=e.max}function z(t,e){ns(t.x,e.x),ns(t.y,e.y)}function ss(t,e){t.translate=e.translate,t.scale=e.scale,t.originPoint=e.originPoint,t.origin=e.origin}const no=1e-4,Ll=1-no,kl=1+no,so=.01,Fl=0-so,jl=0+so;function N(t){return t.max-t.min}function Bl(t,e,n){return Math.abs(t-e)<=n}function is(t,e,n,s=.5){t.origin=s,t.originPoint=D(e.min,e.max,t.origin),t.scale=N(n)/N(e),t.translate=D(n.min,n.max,t.origin)-t.originPoint,(t.scale>=Ll&&t.scale<=kl||isNaN(t.scale))&&(t.scale=1),(t.translate>=Fl&&t.translate<=jl||isNaN(t.translate))&&(t.translate=0)}function Vt(t,e,n,s){is(t.x,e.x,n.x,s?s.originX:void 0),is(t.y,e.y,n.y,s?s.originY:void 0)}function os(t,e,n){t.min=n.min+e.min,t.max=t.min+N(e)}function Il(t,e,n){os(t.x,e.x,n.x),os(t.y,e.y,n.y)}function rs(t,e,n){t.min=e.min-n.min,t.max=t.min+N(e)}function Qt(t,e,n){rs(t.x,e.x,n.x),rs(t.y,e.y,n.y)}function as(t,e,n,s,i){return t-=e,t=Zt(t,1/n,s),i!==void 0&&(t=Zt(t,1/i,s)),t}function Nl(t,e=0,n=1,s=.5,i,r=t,o=t){if(X.test(e)&&(e=parseFloat(e),e=D(o.min,o.max,e/100)-o.min),typeof e!="number")return;let a=D(r.min,r.max,s);t===r&&(a-=e),t.min=as(t.min,e,n,a,i),t.max=as(t.max,e,n,a,i)}function ls(t,e,[n,s,i],r,o){Nl(t,e[n],e[s],e[i],e.scale,r,o)}const Ol=["x","scaleX","originX"],Ul=["y","scaleY","originY"];function cs(t,e,n,s){ls(t.x,e,Ol,n?n.x:void 0,s?s.x:void 0),ls(t.y,e,Ul,n?n.y:void 0,s?s.y:void 0)}function us(t){return t.translate===0&&t.scale===1}function io(t){return us(t.x)&&us(t.y)}function hs(t,e){return t.min===e.min&&t.max===e.max}function Wl(t,e){return hs(t.x,e.x)&&hs(t.y,e.y)}function ds(t,e){return Math.round(t.min)===Math.round(e.min)&&Math.round(t.max)===Math.round(e.max)}function oo(t,e){return ds(t.x,e.x)&&ds(t.y,e.y)}function fs(t){return N(t.x)/N(t.y)}function ps(t,e){return t.translate===e.translate&&t.scale===e.scale&&t.originPoint===e.originPoint}function _(t){return[t("x"),t("y")]}function Kl(t,e,n){let s="";const i=t.x.translate/e.x,r=t.y.translate/e.y,o=(n==null?void 0:n.z)||0;if((i||r||o)&&(s=`translate3d(${i}px, ${r}px, ${o}px) `),(e.x!==1||e.y!==1)&&(s+=`scale(${1/e.x}, ${1/e.y}) `),n){const{transformPerspective:u,rotate:c,rotateX:h,rotateY:d,skewX:f,skewY:p}=n;u&&(s=`perspective(${u}px) ${s}`),c&&(s+=`rotate(${c}deg) `),h&&(s+=`rotateX(${h}deg) `),d&&(s+=`rotateY(${d}deg) `),f&&(s+=`skewX(${f}deg) `),p&&(s+=`skewY(${p}deg) `)}const a=t.x.scale*e.x,l=t.y.scale*e.y;return(a!==1||l!==1)&&(s+=`scale(${a}, ${l})`),s||"none"}const ro=["TopLeft","TopRight","BottomLeft","BottomRight"],zl=ro.length,ms=t=>typeof t=="string"?parseFloat(t):t,gs=t=>typeof t=="number"||x.test(t);function $l(t,e,n,s,i,r){i?(t.opacity=D(0,n.opacity??1,Gl(s)),t.opacityExit=D(e.opacity??1,0,Hl(s))):r&&(t.opacity=D(e.opacity??1,n.opacity??1,s));for(let o=0;o<zl;o++){const a=`border${ro[o]}Radius`;let l=ys(e,a),u=ys(n,a);if(l===void 0&&u===void 0)continue;l||(l=0),u||(u=0),l===0||u===0||gs(l)===gs(u)?(t[a]=Math.max(D(ms(l),ms(u),s),0),(X.test(u)||X.test(l))&&(t[a]+="%")):t[a]=u}(e.rotate||n.rotate)&&(t.rotate=D(e.rotate||0,n.rotate||0,s))}function ys(t,e){return t[e]!==void 0?t[e]:t.borderRadius}const Gl=ao(0,.5,Zs),Hl=ao(.5,.95,K);function ao(t,e,n){return s=>s<t?0:s>e?1:n(Dt(t,e,s))}function _l(t,e,n){const s=j(t)?t:yt(t);return s.start(ln("",s,e,n)),s.animation}function Lt(t,e,n,s={passive:!0}){return t.addEventListener(e,n,s),()=>t.removeEventListener(e,n)}const Xl=(t,e)=>t.depth-e.depth;class Yl{constructor(){this.children=[],this.isDirty=!1}add(e){He(this.children,e),this.isDirty=!0}remove(e){Ht(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(Xl),this.isDirty=!1,this.children.forEach(e)}}function ql(t,e){const n=I.now(),s=({timestamp:i})=>{const r=i-n;r>=e&&(et(s),t(r-e))};return C.setup(s,!0),()=>et(s)}function $t(t){return j(t)?t.get():t}class Zl{constructor(){this.members=[]}add(e){He(this.members,e);for(let n=this.members.length-1;n>=0;n--){const s=this.members[n];if(s===e||s===this.lead||s===this.prevLead)continue;const i=s.instance;(!i||i.isConnected===!1)&&!s.snapshot&&(Ht(this.members,s),s.unmount())}e.scheduleRender()}remove(e){if(Ht(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(e){var n;for(let s=this.members.indexOf(e)-1;s>=0;s--){const i=this.members[s];if(i.isPresent!==!1&&((n=i.instance)==null?void 0:n.isConnected)!==!1)return this.promote(i),!0}return!1}promote(e,n){var i;const s=this.lead;if(e!==s&&(this.prevLead=s,this.lead=e,e.show(),s)){s.updateSnapshot(),e.scheduleRender();const{layoutDependency:r}=s.options,{layoutDependency:o}=e.options;(r===void 0||r!==o)&&(e.resumeFrom=s,n&&(s.preserveOpacity=!0),s.snapshot&&(e.snapshot=s.snapshot,e.snapshot.latestValues=s.animationValues||s.latestValues),(i=e.root)!=null&&i.isUpdating&&(e.isLayoutDirty=!0)),e.options.crossfade===!1&&s.hide()}}exitAnimationComplete(){this.members.forEach(e=>{var n,s,i,r,o;(s=(n=e.options).onExitComplete)==null||s.call(n),(o=(i=e.resumingFrom)==null?void 0:(r=i.options).onExitComplete)==null||o.call(r)})}scheduleRender(){this.members.forEach(e=>e.instance&&e.scheduleRender(!1))}removeLeadSnapshot(){var e;(e=this.lead)!=null&&e.snapshot&&(this.lead.snapshot=void 0)}}const Gt={hasAnimatedSinceResize:!0,hasEverUpdated:!1},fe=["","X","Y","Z"],Ql=1e3;let Jl=0;function pe(t,e,n,s){const{latestValues:i}=e;i[t]&&(n[t]=i[t],e.setStaticValue(t,0),s&&(s[t]=0))}function lo(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;const{visualElement:e}=t.options;if(!e)return;const n=Di(e);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:i,layoutId:r}=t.options;window.MotionCancelOptimisedAnimation(n,"transform",C,!(i||r))}const{parent:s}=t;s&&!s.hasCheckedOptimisedAppear&&lo(s)}function co({attachResizeListener:t,defaultParent:e,measureScroll:n,checkIsScrollRoot:s,resetTransform:i}){return class{constructor(o={},a=e==null?void 0:e()){this.id=Jl++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(nc),this.nodes.forEach(rc),this.nodes.forEach(ac),this.nodes.forEach(sc)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=o,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new Yl)}addEventListener(o,a){return this.eventHandlers.has(o)||this.eventHandlers.set(o,new Xe),this.eventHandlers.get(o).add(a)}notifyListeners(o,...a){const l=this.eventHandlers.get(o);l&&l.notify(...a)}hasListeners(o){return this.eventHandlers.has(o)}mount(o){if(this.instance)return;this.isSVG=pn(o)&&!el(o),this.instance=o;const{layoutId:a,layout:l,visualElement:u}=this.options;if(u&&!u.current&&u.mount(o),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(l||a)&&(this.isLayoutDirty=!0),t){let c,h=0;const d=()=>this.root.updateBlockedByResize=!1;C.read(()=>{h=window.innerWidth}),t(o,()=>{const f=window.innerWidth;f!==h&&(h=f,this.root.updateBlockedByResize=!0,c&&c(),c=ql(d,250),Gt.hasAnimatedSinceResize&&(Gt.hasAnimatedSinceResize=!1,this.nodes.forEach(Ts)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&u&&(a||l)&&this.addEventListener("didUpdate",({delta:c,hasLayoutChanged:h,hasRelativeLayoutChanged:d,layout:f})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const p=this.options.transition||u.getDefaultTransition()||dc,{onLayoutAnimationStart:m,onLayoutAnimationComplete:y}=u.getProps(),v=!this.targetLayout||!oo(this.targetLayout,f),T=!h&&d;if(this.options.layoutRoot||this.resumeFrom||T||h&&(v||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const g={...an(p,"layout"),onPlay:m,onComplete:y};(u.shouldReduceMotion||this.options.layoutRoot)&&(g.delay=0,g.type=!1),this.startAnimation(g),this.setAnimationOrigin(c,T)}else h||Ts(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=f})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const o=this.getStack();o&&o.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),et(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(lc),this.animationId++)}getTransformTemplate(){const{visualElement:o}=this.options;return o&&o.getProps().transformTemplate}willUpdate(o=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&lo(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let c=0;c<this.path.length;c++){const h=this.path[c];h.shouldResetTransform=!0,h.updateScroll("snapshot"),h.options.layoutRoot&&h.willUpdate(!1)}const{layoutId:a,layout:l}=this.options;if(a===void 0&&!l)return;const u=this.getTransformTemplate();this.prevTransformTemplateValue=u?u(this.latestValues,""):void 0,this.updateSnapshot(),o&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(vs);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(xs);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(oc),this.nodes.forEach(tc),this.nodes.forEach(ec)):this.nodes.forEach(xs),this.clearAllSnapshots();const a=I.now();F.delta=Y(0,1e3/60,a-F.timestamp),F.timestamp=a,F.isProcessing=!0,oe.update.process(F),oe.preRender.process(F),oe.render.process(F),F.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,dn.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(ic),this.sharedNodes.forEach(cc)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,C.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){C.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!N(this.snapshot.measuredBox.x)&&!N(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();const o=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=L(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,o?o.layoutBox:void 0)}updateScroll(o="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===o&&(a=!1),a&&this.instance){const l=s(this.instance);this.scroll={animationId:this.root.animationId,phase:o,isRoot:l,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!i)return;const o=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!io(this.projectionDelta),l=this.getTransformTemplate(),u=l?l(this.latestValues,""):void 0,c=u!==this.prevTransformTemplateValue;o&&this.instance&&(a||ot(this.latestValues)||c)&&(i(this.instance,u),this.shouldResetTransform=!1,this.scheduleRender())}measure(o=!0){const a=this.measurePageBox();let l=this.removeElementScroll(a);return o&&(l=this.removeTransform(l)),fc(l),{animationId:this.root.animationId,measuredBox:a,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){var u;const{visualElement:o}=this.options;if(!o)return L();const a=o.measureViewportBox();if(!(((u=this.scroll)==null?void 0:u.wasRoot)||this.path.some(pc))){const{scroll:c}=this.root;c&&(pt(a.x,c.offset.x),pt(a.y,c.offset.y))}return a}removeElementScroll(o){var l;const a=L();if(z(a,o),(l=this.scroll)!=null&&l.wasRoot)return a;for(let u=0;u<this.path.length;u++){const c=this.path[u],{scroll:h,options:d}=c;c!==this.root&&h&&d.layoutScroll&&(h.wasRoot&&z(a,o),pt(a.x,h.offset.x),pt(a.y,h.offset.y))}return a}applyTransform(o,a=!1){const l=L();z(l,o);for(let u=0;u<this.path.length;u++){const c=this.path[u];!a&&c.options.layoutScroll&&c.scroll&&c!==c.root&&mt(l,{x:-c.scroll.offset.x,y:-c.scroll.offset.y}),ot(c.latestValues)&&mt(l,c.latestValues)}return ot(this.latestValues)&&mt(l,this.latestValues),l}removeTransform(o){const a=L();z(a,o);for(let l=0;l<this.path.length;l++){const u=this.path[l];if(!u.instance||!ot(u.latestValues))continue;Ue(u.latestValues)&&u.updateSnapshot();const c=L(),h=u.measurePageBox();z(c,h),cs(a,u.latestValues,u.snapshot?u.snapshot.layoutBox:void 0,c)}return ot(this.latestValues)&&cs(a,this.latestValues),a}setTargetDelta(o){this.targetDelta=o,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(o){this.options={...this.options,...o,crossfade:o.crossfade!==void 0?o.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==F.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(o=!1){var f;const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const l=!!this.resumingFrom||this!==a;if(!(o||l&&this.isSharedProjectionDirty||this.isProjectionDirty||(f=this.parent)!=null&&f.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:c,layoutId:h}=this.options;if(!this.layout||!(c||h))return;this.resolvedRelativeTargetAt=F.timestamp;const d=this.getClosestProjectingParent();d&&this.linkedParentVersion!==d.layoutVersion&&!d.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(d&&d.layout?this.createRelativeTarget(d,this.layout.layoutBox,d.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=L(),this.targetWithTransforms=L()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),Il(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):z(this.target,this.layout.layoutBox),Hi(this.target,this.targetDelta)):z(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,d&&!!d.resumingFrom==!!this.resumingFrom&&!d.options.layoutScroll&&d.target&&this.animationProgress!==1?this.createRelativeTarget(d,this.target,d.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||Ue(this.parent.latestValues)||Gi(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(o,a,l){this.relativeParent=o,this.linkedParentVersion=o.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=L(),this.relativeTargetOrigin=L(),Qt(this.relativeTargetOrigin,a,l),z(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){var p;const o=this.getLead(),a=!!this.resumingFrom||this!==o;let l=!0;if((this.isProjectionDirty||(p=this.parent)!=null&&p.isProjectionDirty)&&(l=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===F.timestamp&&(l=!1),l)return;const{layout:u,layoutId:c}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(u||c))return;z(this.layoutCorrected,this.layout.layoutBox);const h=this.treeScale.x,d=this.treeScale.y;dl(this.layoutCorrected,this.treeScale,this.path,a),o.layout&&!o.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(o.target=o.layout.layoutBox,o.targetWithTransforms=L());const{target:f}=o;if(!f){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(ss(this.prevProjectionDelta.x,this.projectionDelta.x),ss(this.prevProjectionDelta.y,this.projectionDelta.y)),Vt(this.projectionDelta,this.layoutCorrected,f,this.latestValues),(this.treeScale.x!==h||this.treeScale.y!==d||!ps(this.projectionDelta.x,this.prevProjectionDelta.x)||!ps(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",f))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(o=!0){var a;if((a=this.options.visualElement)==null||a.scheduleRender(),o){const l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=ft(),this.projectionDelta=ft(),this.projectionDeltaWithTransform=ft()}setAnimationOrigin(o,a=!1){const l=this.snapshot,u=l?l.latestValues:{},c={...this.latestValues},h=ft();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const d=L(),f=l?l.source:void 0,p=this.layout?this.layout.source:void 0,m=f!==p,y=this.getStack(),v=!y||y.members.length<=1,T=!!(m&&!v&&this.options.crossfade===!0&&!this.path.some(hc));this.animationProgress=0;let g;this.mixTargetDelta=b=>{const w=b/1e3;ws(h.x,o.x,w),ws(h.y,o.y,w),this.setTargetDelta(h),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Qt(d,this.layout.layoutBox,this.relativeParent.layout.layoutBox),uc(this.relativeTarget,this.relativeTargetOrigin,d,w),g&&Wl(this.relativeTarget,g)&&(this.isProjectionDirty=!1),g||(g=L()),z(g,this.relativeTarget)),m&&(this.animationValues=c,$l(c,u,this.latestValues,w,T,v)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=w},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(o){var a,l,u;this.notifyListeners("animationStart"),(a=this.currentAnimation)==null||a.stop(),(u=(l=this.resumingFrom)==null?void 0:l.currentAnimation)==null||u.stop(),this.pendingAnimation&&(et(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=C.update(()=>{Gt.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=yt(0)),this.motionValue.jump(0,!1),this.currentAnimation=_l(this.motionValue,[0,1e3],{...o,velocity:0,isSync:!0,onUpdate:c=>{this.mixTargetDelta(c),o.onUpdate&&o.onUpdate(c)},onStop:()=>{},onComplete:()=>{o.onComplete&&o.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const o=this.getStack();o&&o.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Ql),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const o=this.getLead();let{targetWithTransforms:a,target:l,layout:u,latestValues:c}=o;if(!(!a||!l||!u)){if(this!==o&&this.layout&&u&&uo(this.options.animationType,this.layout.layoutBox,u.layoutBox)){l=this.target||L();const h=N(this.layout.layoutBox.x);l.x.min=o.target.x.min,l.x.max=l.x.min+h;const d=N(this.layout.layoutBox.y);l.y.min=o.target.y.min,l.y.max=l.y.min+d}z(a,l),mt(a,c),Vt(this.projectionDeltaWithTransform,this.layoutCorrected,a,c)}}registerSharedNode(o,a){this.sharedNodes.has(o)||this.sharedNodes.set(o,new Zl),this.sharedNodes.get(o).add(a);const u=a.options.initialPromotionConfig;a.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(a):void 0})}isLead(){const o=this.getStack();return o?o.lead===this:!0}getLead(){var a;const{layoutId:o}=this.options;return o?((a=this.getStack())==null?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:o}=this.options;return o?(a=this.getStack())==null?void 0:a.prevLead:void 0}getStack(){const{layoutId:o}=this.options;if(o)return this.root.sharedNodes.get(o)}promote({needsReset:o,transition:a,preserveFollowOpacity:l}={}){const u=this.getStack();u&&u.promote(this,l),o&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const o=this.getStack();return o?o.relegate(this):!1}resetSkewAndRotation(){const{visualElement:o}=this.options;if(!o)return;let a=!1;const{latestValues:l}=o;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const u={};l.z&&pe("z",o,u,this.animationValues);for(let c=0;c<fe.length;c++)pe(`rotate${fe[c]}`,o,u,this.animationValues),pe(`skew${fe[c]}`,o,u,this.animationValues);o.render();for(const c in u)o.setStaticValue(c,u[c]),this.animationValues&&(this.animationValues[c]=u[c]);o.scheduleRender()}applyProjectionStyles(o,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){o.visibility="hidden";return}const l=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,o.visibility="",o.opacity="",o.pointerEvents=$t(a==null?void 0:a.pointerEvents)||"",o.transform=l?l(this.latestValues,""):"none";return}const u=this.getLead();if(!this.projectionDelta||!this.layout||!u.target){this.options.layoutId&&(o.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,o.pointerEvents=$t(a==null?void 0:a.pointerEvents)||""),this.hasProjected&&!ot(this.latestValues)&&(o.transform=l?l({},""):"none",this.hasProjected=!1);return}o.visibility="";const c=u.animationValues||u.latestValues;this.applyTransformsToTarget();let h=Kl(this.projectionDeltaWithTransform,this.treeScale,c);l&&(h=l(c,h)),o.transform=h;const{x:d,y:f}=this.projectionDelta;o.transformOrigin=`${d.origin*100}% ${f.origin*100}% 0`,u.animationValues?o.opacity=u===this?c.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:c.opacityExit:o.opacity=u===this?c.opacity!==void 0?c.opacity:"":c.opacityExit!==void 0?c.opacityExit:0;for(const p in Ke){if(c[p]===void 0)continue;const{correct:m,applyTo:y,isCSSVariable:v}=Ke[p],T=h==="none"?c[p]:m(c[p],u);if(y){const g=y.length;for(let b=0;b<g;b++)o[y[b]]=T}else v?this.options.visualElement.renderState.vars[p]=T:o[p]=T}this.options.layoutId&&(o.pointerEvents=u===this?$t(a==null?void 0:a.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(o=>{var a;return(a=o.currentAnimation)==null?void 0:a.stop()}),this.root.nodes.forEach(vs),this.root.sharedNodes.clear()}}}function tc(t){t.updateLayout()}function ec(t){var n;const e=((n=t.resumeFrom)==null?void 0:n.snapshot)||t.snapshot;if(t.isLead()&&t.layout&&e&&t.hasListeners("didUpdate")){const{layoutBox:s,measuredBox:i}=t.layout,{animationType:r}=t.options,o=e.source!==t.layout.source;r==="size"?_(h=>{const d=o?e.measuredBox[h]:e.layoutBox[h],f=N(d);d.min=s[h].min,d.max=d.min+f}):uo(r,e.layoutBox,s)&&_(h=>{const d=o?e.measuredBox[h]:e.layoutBox[h],f=N(s[h]);d.max=d.min+f,t.relativeTarget&&!t.currentAnimation&&(t.isProjectionDirty=!0,t.relativeTarget[h].max=t.relativeTarget[h].min+f)});const a=ft();Vt(a,s,e.layoutBox);const l=ft();o?Vt(l,t.applyTransform(i,!0),e.measuredBox):Vt(l,s,e.layoutBox);const u=!io(a);let c=!1;if(!t.resumeFrom){const h=t.getClosestProjectingParent();if(h&&!h.resumeFrom){const{snapshot:d,layout:f}=h;if(d&&f){const p=L();Qt(p,e.layoutBox,d.layoutBox);const m=L();Qt(m,s,f.layoutBox),oo(p,m)||(c=!0),h.options.layoutRoot&&(t.relativeTarget=m,t.relativeTargetOrigin=p,t.relativeParent=h)}}}t.notifyListeners("didUpdate",{layout:s,snapshot:e,delta:l,layoutDelta:a,hasLayoutChanged:u,hasRelativeLayoutChanged:c})}else if(t.isLead()){const{onExitComplete:s}=t.options;s&&s()}t.options.transition=void 0}function nc(t){t.parent&&(t.isProjecting()||(t.isProjectionDirty=t.parent.isProjectionDirty),t.isSharedProjectionDirty||(t.isSharedProjectionDirty=!!(t.isProjectionDirty||t.parent.isProjectionDirty||t.parent.isSharedProjectionDirty)),t.isTransformDirty||(t.isTransformDirty=t.parent.isTransformDirty))}function sc(t){t.isProjectionDirty=t.isSharedProjectionDirty=t.isTransformDirty=!1}function ic(t){t.clearSnapshot()}function vs(t){t.clearMeasurements()}function xs(t){t.isLayoutDirty=!1}function oc(t){const{visualElement:e}=t.options;e&&e.getProps().onBeforeLayoutMeasure&&e.notify("BeforeLayoutMeasure"),t.resetTransform()}function Ts(t){t.finishAnimation(),t.targetDelta=t.relativeTarget=t.target=void 0,t.isProjectionDirty=!0}function rc(t){t.resolveTargetDelta()}function ac(t){t.calcProjection()}function lc(t){t.resetSkewAndRotation()}function cc(t){t.removeLeadSnapshot()}function ws(t,e,n){t.translate=D(e.translate,0,n),t.scale=D(e.scale,1,n),t.origin=e.origin,t.originPoint=e.originPoint}function bs(t,e,n,s){t.min=D(e.min,n.min,s),t.max=D(e.max,n.max,s)}function uc(t,e,n,s){bs(t.x,e.x,n.x,s),bs(t.y,e.y,n.y,s)}function hc(t){return t.animationValues&&t.animationValues.opacityExit!==void 0}const dc={duration:.45,ease:[.4,0,.1,1]},Ss=t=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(t),Ps=Ss("applewebkit/")&&!Ss("chrome/")?Math.round:K;function As(t){t.min=Ps(t.min),t.max=Ps(t.max)}function fc(t){As(t.x),As(t.y)}function uo(t,e,n){return t==="position"||t==="preserve-aspect"&&!Bl(fs(e),fs(n),.2)}function pc(t){var e;return t!==t.root&&((e=t.scroll)==null?void 0:e.wasRoot)}const mc=co({attachResizeListener:(t,e)=>Lt(t,"resize",e),measureScroll:()=>{var t,e;return{x:document.documentElement.scrollLeft||((t=document.body)==null?void 0:t.scrollLeft)||0,y:document.documentElement.scrollTop||((e=document.body)==null?void 0:e.scrollTop)||0}},checkIsScrollRoot:()=>!0}),me={current:void 0},ho=co({measureScroll:t=>({x:t.scrollLeft,y:t.scrollTop}),defaultParent:()=>{if(!me.current){const t=new mc({});t.mount(window),t.setOptions({layoutScroll:!0}),me.current=t}return me.current},resetTransform:(t,e)=>{t.style.transform=e!==void 0?e:"none"},checkIsScrollRoot:t=>window.getComputedStyle(t).position==="fixed"}),fo=S.createContext({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"});function gc(t=!0){const e=S.useContext(Ge);if(e===null)return[!0,null];const{isPresent:n,onExitComplete:s,register:i}=e,r=S.useId();S.useEffect(()=>{if(t)return i(r)},[t]);const o=S.useCallback(()=>t&&s&&s(r),[r,s,t]);return!n&&s?[!1,o]:[!0]}const po=S.createContext({strict:!1}),Vs={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"]};let Cs=!1;function yc(){if(Cs)return;const t={};for(const e in Vs)t[e]={isEnabled:n=>Vs[e].some(s=>!!n[s])};Ki(t),Cs=!0}function mo(){return yc(),ll()}function vc(t){const e=mo();for(const n in t)e[n]={...e[n],...t[n]};Ki(e)}const xc=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function Jt(t){return t.startsWith("while")||t.startsWith("drag")&&t!=="draggable"||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||xc.has(t)}let go=t=>!Jt(t);function Tc(t){typeof t=="function"&&(go=e=>e.startsWith("on")?!Jt(e):t(e))}try{Tc(require("@emotion/is-prop-valid").default)}catch{}function wc(t,e,n){const s={};for(const i in t)i==="values"&&typeof t.values=="object"||(go(i)||n===!0&&Jt(i)||!e&&!Jt(i)||t.draggable&&i.startsWith("onDrag"))&&(s[i]=t[i]);return s}const ne=S.createContext({});function bc(t,e){if(ee(t)){const{initial:n,animate:s}=t;return{initial:n===!1||Rt(n)?n:void 0,animate:Rt(s)?s:void 0}}return t.inherit!==!1?e:{}}function Sc(t){const{initial:e,animate:n}=bc(t,S.useContext(ne));return S.useMemo(()=>({initial:e,animate:n}),[Ds(e),Ds(n)])}function Ds(t){return Array.isArray(t)?t.join(" "):t}const xn=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function yo(t,e,n){for(const s in e)!j(e[s])&&!Yi(s,n)&&(t[s]=e[s])}function Pc({transformTemplate:t},e){return S.useMemo(()=>{const n=xn();return yn(n,e,t),Object.assign({},n.vars,n.style)},[e])}function Ac(t,e){const n=t.style||{},s={};return yo(s,n,t),Object.assign(s,Pc(t,e)),s}function Vc(t,e){const n={},s=Ac(t,e);return t.drag&&t.dragListener!==!1&&(n.draggable=!1,s.userSelect=s.WebkitUserSelect=s.WebkitTouchCallout="none",s.touchAction=t.drag===!0?"none":`pan-${t.drag==="x"?"y":"x"}`),t.tabIndex===void 0&&(t.onTap||t.onTapStart||t.whileTap)&&(n.tabIndex=0),n.style=s,n}const vo=()=>({...xn(),attrs:{}});function Cc(t,e,n,s){const i=S.useMemo(()=>{const r=vo();return qi(r,e,Qi(s),t.transformTemplate,t.style),{...r.attrs,style:{...r.style}}},[e]);if(t.style){const r={};yo(r,t.style,t),i.style={...r,...i.style}}return i}const Dc=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Tn(t){return typeof t!="string"||t.includes("-")?!1:!!(Dc.indexOf(t)>-1||/[A-Z]/u.test(t))}function Mc(t,e,n,{latestValues:s},i,r=!1,o){const l=(o??Tn(t)?Cc:Vc)(e,s,i,t),u=wc(e,typeof t=="string",r),c=t!==S.Fragment?{...u,...l,ref:n}:{},{children:h}=e,d=S.useMemo(()=>j(h)?h.get():h,[h]);return S.createElement(t,{...c,children:d})}function Ec({scrapeMotionValuesFromProps:t,createRenderState:e},n,s,i){return{latestValues:Rc(n,s,i,t),renderState:e()}}function Rc(t,e,n,s){const i={},r=s(t,{});for(const d in r)i[d]=$t(r[d]);let{initial:o,animate:a}=t;const l=ee(t),u=Ui(t);e&&u&&!l&&t.inherit!==!1&&(o===void 0&&(o=e.initial),a===void 0&&(a=e.animate));let c=n?n.initial===!1:!1;c=c||o===!1;const h=c?a:o;if(h&&typeof h!="boolean"&&!te(h)){const d=Array.isArray(h)?h:[h];for(let f=0;f<d.length;f++){const p=cn(t,d[f]);if(p){const{transitionEnd:m,transition:y,...v}=p;for(const T in v){let g=v[T];if(Array.isArray(g)){const b=c?g.length-1:0;g=g[b]}g!==null&&(i[T]=g)}for(const T in m)i[T]=m[T]}}}return i}const xo=t=>(e,n)=>{const s=S.useContext(ne),i=S.useContext(Ge),r=()=>Ec(t,e,s,i);return n?r():ko(r)},Lc=xo({scrapeMotionValuesFromProps:vn,createRenderState:xn}),kc=xo({scrapeMotionValuesFromProps:Ji,createRenderState:vo}),Fc=Symbol.for("motionComponentSymbol");function jc(t,e,n){const s=S.useRef(n);S.useInsertionEffect(()=>{s.current=n});const i=S.useRef(null);return S.useCallback(r=>{var a;r&&((a=t.onMount)==null||a.call(t,r));const o=s.current;if(typeof o=="function")if(r){const l=o(r);typeof l=="function"&&(i.current=l)}else i.current?(i.current(),i.current=null):o(r);else o&&(o.current=r);e&&(r?e.mount(r):e.unmount())},[e])}const To=S.createContext({});function ut(t){return t&&typeof t=="object"&&Object.prototype.hasOwnProperty.call(t,"current")}function Bc(t,e,n,s,i,r){var g,b;const{visualElement:o}=S.useContext(ne),a=S.useContext(po),l=S.useContext(Ge),u=S.useContext(fo),c=u.reducedMotion,h=u.skipAnimations,d=S.useRef(null),f=S.useRef(!1);s=s||a.renderer,!d.current&&s&&(d.current=s(t,{visualState:e,parent:o,props:n,presenceContext:l,blockInitialAnimation:l?l.initial===!1:!1,reducedMotionConfig:c,skipAnimations:h,isSVG:r}),f.current&&d.current&&(d.current.manuallyAnimateOnMount=!0));const p=d.current,m=S.useContext(To);p&&!p.projection&&i&&(p.type==="html"||p.type==="svg")&&Ic(d.current,n,i,m);const y=S.useRef(!1);S.useInsertionEffect(()=>{p&&y.current&&p.update(n,l)});const v=n[Ci],T=S.useRef(!!v&&typeof window<"u"&&!((g=window.MotionHandoffIsComplete)!=null&&g.call(window,v))&&((b=window.MotionHasOptimisedAnimation)==null?void 0:b.call(window,v)));return jo(()=>{f.current=!0,p&&(y.current=!0,window.MotionIsMounted=!0,p.updateFeatures(),p.scheduleRenderMicrotask(),T.current&&p.animationState&&p.animationState.animateChanges())}),S.useEffect(()=>{p&&(!T.current&&p.animationState&&p.animationState.animateChanges(),T.current&&(queueMicrotask(()=>{var w;(w=window.MotionHandoffMarkAsComplete)==null||w.call(window,v)}),T.current=!1),p.enteringChildren=void 0)}),p}function Ic(t,e,n,s){const{layoutId:i,layout:r,drag:o,dragConstraints:a,layoutScroll:l,layoutRoot:u,layoutCrossfade:c}=e;t.projection=new n(t.latestValues,e["data-framer-portal-id"]?void 0:wo(t.parent)),t.projection.setOptions({layoutId:i,layout:r,alwaysMeasureLayout:!!o||a&&ut(a),visualElement:t,animationType:typeof r=="string"?r:"both",initialPromotionConfig:s,crossfade:c,layoutScroll:l,layoutRoot:u})}function wo(t){if(t)return t.options.allowProjection!==!1?t.projection:wo(t.parent)}function ge(t,{forwardMotionProps:e=!1,type:n}={},s,i){s&&vc(s);const r=n?n==="svg":Tn(t),o=r?kc:Lc;function a(u,c){let h;const d={...S.useContext(fo),...u,layoutId:Nc(u)},{isStatic:f}=d,p=Sc(u),m=o(u,f);if(!f&&typeof window<"u"){Oc();const y=Uc(d);h=y.MeasureLayout,p.visualElement=Bc(t,m,d,i,y.ProjectionNode,r)}return A.jsxs(ne.Provider,{value:p,children:[h&&p.visualElement?A.jsx(h,{visualElement:p.visualElement,...d}):null,Mc(t,u,jc(m,p.visualElement,c),m,f,e,r)]})}a.displayName=`motion.${typeof t=="string"?t:`create(${t.displayName??t.name??""})`}`;const l=S.forwardRef(a);return l[Fc]=t,l}function Nc({layoutId:t}){const e=S.useContext(Os).id;return e&&t!==void 0?e+"-"+t:t}function Oc(t,e){S.useContext(po).strict}function Uc(t){const e=mo(),{drag:n,layout:s}=e;if(!n&&!s)return{};const i={...n,...s};return{MeasureLayout:n!=null&&n.isEnabled(t)||s!=null&&s.isEnabled(t)?i.MeasureLayout:void 0,ProjectionNode:i.ProjectionNode}}function Wc(t,e){if(typeof Proxy>"u")return ge;const n=new Map,s=(r,o)=>ge(r,o,t,e),i=(r,o)=>s(r,o);return new Proxy(i,{get:(r,o)=>o==="create"?s:(n.has(o)||n.set(o,ge(o,void 0,t,e)),n.get(o))})}const Kc=(t,e)=>e.isSVG??Tn(t)?new Al(e):new xl(e,{allowProjection:t!==S.Fragment});class zc extends nt{constructor(e){super(e),e.animationState||(e.animationState=El(e))}updateAnimationControlsSubscription(){const{animate:e}=this.node.getProps();te(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:e}=this.node.getProps(),{animate:n}=this.node.prevProps||{};e!==n&&this.updateAnimationControlsSubscription()}unmount(){var e;this.node.animationState.reset(),(e=this.unmountControls)==null||e.call(this)}}let $c=0;class Gc extends nt{constructor(){super(...arguments),this.id=$c++}update(){if(!this.node.presenceContext)return;const{isPresent:e,onExitComplete:n}=this.node.presenceContext,{isPresent:s}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===s)return;const i=this.node.animationState.setActive("exit",!e);n&&!e&&i.then(()=>{n(this.id)})}mount(){const{register:e,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),e&&(this.unmount=e(this.id))}unmount(){}}const Hc={animation:{Feature:zc},exit:{Feature:Gc}};function Bt(t){return{point:{x:t.pageX,y:t.pageY}}}const _c=t=>e=>fn(e)&&t(e,Bt(e));function Ct(t,e,n,s){return Lt(t,e,_c(n),s)}const bo=({current:t})=>t?t.ownerDocument.defaultView:null,Ms=(t,e)=>Math.abs(t-e);function Xc(t,e){const n=Ms(t.x,e.x),s=Ms(t.y,e.y);return Math.sqrt(n**2+s**2)}const Es=new Set(["auto","scroll"]);class So{constructor(e,n,{transformPagePoint:s,contextWindow:i=window,dragSnapToOrigin:r=!1,distanceThreshold:o=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=f=>{this.handleScroll(f.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const f=ve(this.lastMoveEventInfo,this.history),p=this.startEvent!==null,m=Xc(f.offset,{x:0,y:0})>=this.distanceThreshold;if(!p&&!m)return;const{point:y}=f,{timestamp:v}=F;this.history.push({...y,timestamp:v});const{onStart:T,onMove:g}=this.handlers;p||(T&&T(this.lastMoveEvent,f),this.startEvent=this.lastMoveEvent),g&&g(this.lastMoveEvent,f)},this.handlePointerMove=(f,p)=>{this.lastMoveEvent=f,this.lastMoveEventInfo=ye(p,this.transformPagePoint),C.update(this.updatePoint,!0)},this.handlePointerUp=(f,p)=>{this.end();const{onEnd:m,onSessionEnd:y,resumeAnimation:v}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&v&&v(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const T=ve(f.type==="pointercancel"?this.lastMoveEventInfo:ye(p,this.transformPagePoint),this.history);this.startEvent&&m&&m(f,T),y&&y(f,T)},!fn(e))return;this.dragSnapToOrigin=r,this.handlers=n,this.transformPagePoint=s,this.distanceThreshold=o,this.contextWindow=i||window;const l=Bt(e),u=ye(l,this.transformPagePoint),{point:c}=u,{timestamp:h}=F;this.history=[{...c,timestamp:h}];const{onSessionStart:d}=n;d&&d(e,ve(u,this.history)),this.removeListeners=kt(Ct(this.contextWindow,"pointermove",this.handlePointerMove),Ct(this.contextWindow,"pointerup",this.handlePointerUp),Ct(this.contextWindow,"pointercancel",this.handlePointerUp)),a&&this.startScrollTracking(a)}startScrollTracking(e){let n=e.parentElement;for(;n;){const s=getComputedStyle(n);(Es.has(s.overflowX)||Es.has(s.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(e){const n=this.scrollPositions.get(e);if(!n)return;const s=e===window,i=s?{x:window.scrollX,y:window.scrollY}:{x:e.scrollLeft,y:e.scrollTop},r={x:i.x-n.x,y:i.y-n.y};r.x===0&&r.y===0||(s?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=r.x,this.lastMoveEventInfo.point.y+=r.y):this.history.length>0&&(this.history[0].x-=r.x,this.history[0].y-=r.y),this.scrollPositions.set(e,i),C.update(this.updatePoint,!0))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),et(this.updatePoint)}}function ye(t,e){return e?{point:e(t.point)}:t}function Rs(t,e){return{x:t.x-e.x,y:t.y-e.y}}function ve({point:t},e){return{point:t,delta:Rs(t,Po(e)),offset:Rs(t,Yc(e)),velocity:qc(e,.1)}}function Yc(t){return t[0]}function Po(t){return t[t.length-1]}function qc(t,e){if(t.length<2)return{x:0,y:0};let n=t.length-1,s=null;const i=Po(t);for(;n>=0&&(s=t[n],!(i.timestamp-s.timestamp>G(e)));)n--;if(!s)return{x:0,y:0};s===t[0]&&t.length>2&&i.timestamp-s.timestamp>G(e)*2&&(s=t[1]);const r=W(i.timestamp-s.timestamp);if(r===0)return{x:0,y:0};const o={x:(i.x-s.x)/r,y:(i.y-s.y)/r};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}function Zc(t,{min:e,max:n},s){return e!==void 0&&t<e?t=s?D(e,t,s.min):Math.max(t,e):n!==void 0&&t>n&&(t=s?D(n,t,s.max):Math.min(t,n)),t}function Ls(t,e,n){return{min:e!==void 0?t.min+e:void 0,max:n!==void 0?t.max+n-(t.max-t.min):void 0}}function Qc(t,{top:e,left:n,bottom:s,right:i}){return{x:Ls(t.x,n,i),y:Ls(t.y,e,s)}}function ks(t,e){let n=e.min-t.min,s=e.max-t.max;return e.max-e.min<t.max-t.min&&([n,s]=[s,n]),{min:n,max:s}}function Jc(t,e){return{x:ks(t.x,e.x),y:ks(t.y,e.y)}}function tu(t,e){let n=.5;const s=N(t),i=N(e);return i>s?n=Dt(e.min,e.max-s,t.min):s>i&&(n=Dt(t.min,t.max-i,e.min)),Y(0,1,n)}function eu(t,e){const n={};return e.min!==void 0&&(n.min=e.min-t.min),e.max!==void 0&&(n.max=e.max-t.min),n}const ze=.35;function nu(t=ze){return t===!1?t=0:t===!0&&(t=ze),{x:Fs(t,"left","right"),y:Fs(t,"top","bottom")}}function Fs(t,e,n){return{min:js(t,e),max:js(t,n)}}function js(t,e){return typeof t=="number"?t:t[e]||0}const su=new WeakMap;class iu{constructor(e){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=L(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=e}start(e,{snapToCursor:n=!1,distanceThreshold:s}={}){const{presenceContext:i}=this.visualElement;if(i&&i.isPresent===!1)return;const r=h=>{n&&this.snapToCursor(Bt(h).point),this.stopAnimation()},o=(h,d)=>{const{drag:f,dragPropagation:p,onDragStart:m}=this.getProps();if(f&&!p&&(this.openDragLock&&this.openDragLock(),this.openDragLock=Na(f),!this.openDragLock))return;this.latestPointerEvent=h,this.latestPanInfo=d,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),_(v=>{let T=this.getAxisMotionValue(v).get()||0;if(X.test(T)){const{projection:g}=this.visualElement;if(g&&g.layout){const b=g.layout.layoutBox[v];b&&(T=N(b)*(parseFloat(T)/100))}}this.originPoint[v]=T}),m&&C.update(()=>m(h,d),!1,!0),je(this.visualElement,"transform");const{animationState:y}=this.visualElement;y&&y.setActive("whileDrag",!0)},a=(h,d)=>{this.latestPointerEvent=h,this.latestPanInfo=d;const{dragPropagation:f,dragDirectionLock:p,onDirectionLock:m,onDrag:y}=this.getProps();if(!f&&!this.openDragLock)return;const{offset:v}=d;if(p&&this.currentDirection===null){this.currentDirection=ru(v),this.currentDirection!==null&&m&&m(this.currentDirection);return}this.updateAxis("x",d.point,v),this.updateAxis("y",d.point,v),this.visualElement.render(),y&&C.update(()=>y(h,d),!1,!0)},l=(h,d)=>{this.latestPointerEvent=h,this.latestPanInfo=d,this.stop(h,d),this.latestPointerEvent=null,this.latestPanInfo=null},u=()=>{const{dragSnapToOrigin:h}=this.getProps();(h||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:c}=this.getProps();this.panSession=new So(e,{onSessionStart:r,onStart:o,onMove:a,onSessionEnd:l,resumeAnimation:u},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:c,distanceThreshold:s,contextWindow:bo(this.visualElement),element:this.visualElement.current})}stop(e,n){const s=e||this.latestPointerEvent,i=n||this.latestPanInfo,r=this.isDragging;if(this.cancel(),!r||!i||!s)return;const{velocity:o}=i;this.startAnimation(o);const{onDragEnd:a}=this.getProps();a&&C.postRender(()=>a(s,i))}cancel(){this.isDragging=!1;const{projection:e,animationState:n}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:s}=this.getProps();!s&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(e,n,s){const{drag:i}=this.getProps();if(!s||!Ot(e,i,this.currentDirection))return;const r=this.getAxisMotionValue(e);let o=this.originPoint[e]+s[e];this.constraints&&this.constraints[e]&&(o=Zc(o,this.constraints[e],this.elastic[e])),r.set(o)}resolveConstraints(){var r;const{dragConstraints:e,dragElastic:n}=this.getProps(),s=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(r=this.visualElement.projection)==null?void 0:r.layout,i=this.constraints;e&&ut(e)?this.constraints||(this.constraints=this.resolveRefConstraints()):e&&s?this.constraints=Qc(s.layoutBox,e):this.constraints=!1,this.elastic=nu(n),i!==this.constraints&&!ut(e)&&s&&this.constraints&&!this.hasMutatedConstraints&&_(o=>{this.constraints!==!1&&this.getAxisMotionValue(o)&&(this.constraints[o]=eu(s.layoutBox[o],this.constraints[o]))})}resolveRefConstraints(){const{dragConstraints:e,onMeasureDragConstraints:n}=this.getProps();if(!e||!ut(e))return!1;const s=e.current,{projection:i}=this.visualElement;if(!i||!i.layout)return!1;const r=fl(s,i.root,this.visualElement.getTransformPagePoint());let o=Jc(i.layout.layoutBox,r);if(n){const a=n(ul(o));this.hasMutatedConstraints=!!a,a&&(o=$i(a))}return o}startAnimation(e){const{drag:n,dragMomentum:s,dragElastic:i,dragTransition:r,dragSnapToOrigin:o,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},u=_(c=>{if(!Ot(c,n,this.currentDirection))return;let h=l&&l[c]||{};o&&(h={min:0,max:0});const d=i?200:1e6,f=i?40:1e7,p={type:"inertia",velocity:s?e[c]:0,bounceStiffness:d,bounceDamping:f,timeConstant:750,restDelta:1,restSpeed:10,...r,...h};return this.startAxisValueAnimation(c,p)});return Promise.all(u).then(a)}startAxisValueAnimation(e,n){const s=this.getAxisMotionValue(e);return je(this.visualElement,e),s.start(ln(e,s,0,n,this.visualElement,!1))}stopAnimation(){_(e=>this.getAxisMotionValue(e).stop())}getAxisMotionValue(e){const n=`_drag${e.toUpperCase()}`,s=this.visualElement.getProps(),i=s[n];return i||this.visualElement.getValue(e,(s.initial?s.initial[e]:void 0)||0)}snapToCursor(e){_(n=>{const{drag:s}=this.getProps();if(!Ot(n,s,this.currentDirection))return;const{projection:i}=this.visualElement,r=this.getAxisMotionValue(n);if(i&&i.layout){const{min:o,max:a}=i.layout.layoutBox[n],l=r.get()||0;r.set(e[n]-D(o,a,.5)+l)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:e,dragConstraints:n}=this.getProps(),{projection:s}=this.visualElement;if(!ut(n)||!s||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};_(o=>{const a=this.getAxisMotionValue(o);if(a&&this.constraints!==!1){const l=a.get();i[o]=tu({min:l,max:l},this.constraints[o])}});const{transformTemplate:r}=this.visualElement.getProps();this.visualElement.current.style.transform=r?r({},""):"none",s.root&&s.root.updateScroll(),s.updateLayout(),this.constraints=!1,this.resolveConstraints(),_(o=>{if(!Ot(o,e,null))return;const a=this.getAxisMotionValue(o),{min:l,max:u}=this.constraints[o];a.set(D(l,u,i[o]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;su.set(this.visualElement,this);const e=this.visualElement.current,n=Ct(e,"pointerdown",u=>{const{drag:c,dragListener:h=!0}=this.getProps(),d=u.target,f=d!==e&&$a(d);c&&h&&!f&&this.start(u)});let s;const i=()=>{const{dragConstraints:u}=this.getProps();ut(u)&&u.current&&(this.constraints=this.resolveRefConstraints(),s||(s=ou(e,u.current,()=>this.scalePositionWithinConstraints())))},{projection:r}=this.visualElement,o=r.addEventListener("measure",i);r&&!r.layout&&(r.root&&r.root.updateScroll(),r.updateLayout()),C.read(i);const a=Lt(window,"resize",()=>this.scalePositionWithinConstraints()),l=r.addEventListener("didUpdate",({delta:u,hasLayoutChanged:c})=>{this.isDragging&&c&&(_(h=>{const d=this.getAxisMotionValue(h);d&&(this.originPoint[h]+=u[h].translate,d.set(d.get()+u[h].translate))}),this.visualElement.render())});return()=>{a(),n(),o(),l&&l(),s&&s()}}getProps(){const e=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:s=!1,dragPropagation:i=!1,dragConstraints:r=!1,dragElastic:o=ze,dragMomentum:a=!0}=e;return{...e,drag:n,dragDirectionLock:s,dragPropagation:i,dragConstraints:r,dragElastic:o,dragMomentum:a}}}function Bs(t){let e=!0;return()=>{if(e){e=!1;return}t()}}function ou(t,e,n){const s=$n(t,Bs(n)),i=$n(e,Bs(n));return()=>{s(),i()}}function Ot(t,e,n){return(e===!0||e===t)&&(n===null||n===t)}function ru(t,e=10){let n=null;return Math.abs(t.y)>e?n="y":Math.abs(t.x)>e&&(n="x"),n}class au extends nt{constructor(e){super(e),this.removeGroupControls=K,this.removeListeners=K,this.controls=new iu(e)}mount(){const{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||K}update(){const{dragControls:e}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};e!==n&&(this.removeGroupControls(),e&&(this.removeGroupControls=e.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const xe=t=>(e,n)=>{t&&C.update(()=>t(e,n),!1,!0)};class lu extends nt{constructor(){super(...arguments),this.removePointerDownListener=K}onPointerDown(e){this.session=new So(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:bo(this.node)})}createPanHandlers(){const{onPanSessionStart:e,onPanStart:n,onPan:s,onPanEnd:i}=this.node.getProps();return{onSessionStart:xe(e),onStart:xe(n),onMove:xe(s),onEnd:(r,o)=>{delete this.session,i&&C.postRender(()=>i(r,o))}}}mount(){this.removePointerDownListener=Ct(this.node.current,"pointerdown",e=>this.onPointerDown(e))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let Te=!1;class cu extends S.Component{componentDidMount(){const{visualElement:e,layoutGroup:n,switchLayoutGroup:s,layoutId:i}=this.props,{projection:r}=e;r&&(n.group&&n.group.add(r),s&&s.register&&i&&s.register(r),Te&&r.root.didUpdate(),r.addEventListener("animationComplete",()=>{this.safeToRemove()}),r.setOptions({...r.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),Gt.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){const{layoutDependency:n,visualElement:s,drag:i,isPresent:r}=this.props,{projection:o}=s;return o&&(o.isPresent=r,e.layoutDependency!==n&&o.setOptions({...o.options,layoutDependency:n}),Te=!0,i||e.layoutDependency!==n||n===void 0||e.isPresent!==r?o.willUpdate():this.safeToRemove(),e.isPresent!==r&&(r?o.promote():o.relegate()||C.postRender(()=>{const a=o.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),dn.postRender(()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:e,layoutGroup:n,switchLayoutGroup:s}=this.props,{projection:i}=e;Te=!0,i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),s&&s.deregister&&s.deregister(i))}safeToRemove(){const{safeToRemove:e}=this.props;e&&e()}render(){return null}}function Ao(t){const[e,n]=gc(),s=S.useContext(Os);return A.jsx(cu,{...t,layoutGroup:s,switchLayoutGroup:S.useContext(To),isPresent:e,safeToRemove:n})}const uu={pan:{Feature:lu},drag:{Feature:au,ProjectionNode:ho,MeasureLayout:Ao}};function Is(t,e,n){const{props:s}=t;t.animationState&&s.whileHover&&t.animationState.setActive("whileHover",n==="Start");const i="onHover"+n,r=s[i];r&&C.postRender(()=>r(e,Bt(e)))}class hu extends nt{mount(){const{current:e}=this.node;e&&(this.unmount=Ua(e,(n,s)=>(Is(this.node,s,"Start"),i=>Is(this.node,i,"End"))))}unmount(){}}class du extends nt{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch{e=!0}!e||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=kt(Lt(this.node.current,"focus",()=>this.onFocus()),Lt(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Ns(t,e,n){const{props:s}=t;if(t.current instanceof HTMLButtonElement&&t.current.disabled)return;t.animationState&&s.whileTap&&t.animationState.setActive("whileTap",n==="Start");const i="onTap"+(n==="End"?"":n),r=s[i];r&&C.postRender(()=>r(e,Bt(e)))}class fu extends nt{mount(){const{current:e}=this.node;if(!e)return;const{globalTapTarget:n,propagate:s}=this.node.props;this.unmount=Ha(e,(i,r)=>(Ns(this.node,r,"Start"),(o,{success:a})=>Ns(this.node,o,a?"End":"Cancel")),{useGlobalTarget:n,stopPropagation:(s==null?void 0:s.tap)===!1})}unmount(){}}const $e=new WeakMap,we=new WeakMap,pu=t=>{const e=$e.get(t.target);e&&e(t)},mu=t=>{t.forEach(pu)};function gu({root:t,...e}){const n=t||document;we.has(n)||we.set(n,{});const s=we.get(n),i=JSON.stringify(e);return s[i]||(s[i]=new IntersectionObserver(mu,{root:t,...e})),s[i]}function yu(t,e,n){const s=gu(e);return $e.set(t,n),s.observe(t),()=>{$e.delete(t),s.unobserve(t)}}const vu={some:0,all:1};class xu extends nt{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:e={}}=this.node.getProps(),{root:n,margin:s,amount:i="some",once:r}=e,o={root:n?n.current:void 0,rootMargin:s,threshold:typeof i=="number"?i:vu[i]},a=l=>{const{isIntersecting:u}=l;if(this.isInView===u||(this.isInView=u,r&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:c,onViewportLeave:h}=this.node.getProps(),d=u?c:h;d&&d(l)};return yu(this.node.current,o,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:e,prevProps:n}=this.node;["amount","margin","root"].some(Tu(e,n))&&this.startObserver()}unmount(){}}function Tu({viewport:t={}},{viewport:e={}}={}){return n=>t[n]!==e[n]}const wu={inView:{Feature:xu},tap:{Feature:fu},focus:{Feature:du},hover:{Feature:hu}},bu={layout:{ProjectionNode:ho,MeasureLayout:Ao}},Su={...Hc,...wu,...uu,...bu},Z=Wc(Su,Kc),Eu=()=>{const t=Do(),e=Mo(),[n,s]=S.useState("");S.useEffect(()=>{console.error("404 Error: User attempted to access non-existent route:",t.pathname)},[t.pathname]);const i=r=>{r.preventDefault(),n.trim()&&e(`/?search=${encodeURIComponent(n.trim())}`)};return A.jsxs("div",{className:"min-h-screen flex flex-col bg-white","data-id":"dh7mhrgve","data-path":"src/pages/NotFound.tsx",children:[A.jsx(Lo,{"data-id":"xo87rjfrp","data-path":"src/pages/NotFound.tsx"}),A.jsx("div",{className:"flex-1 flex items-center justify-center px-4 pb-16",style:{paddingTop:"100px",backgroundImage:`
            linear-gradient(to right, #f0f0f0 1px, transparent 1px),
            linear-gradient(to bottom, #f0f0f0 1px, transparent 1px)
          `,backgroundSize:"40px 40px"},"data-id":"8gps4e86g","data-path":"src/pages/NotFound.tsx",children:A.jsxs(Z.div,{initial:{opacity:0,y:30},animate:{opacity:1,y:0},transition:{duration:.6},className:"text-center max-w-2xl mx-auto","data-id":"9umdodnn0","data-path":"src/pages/NotFound.tsx",children:[A.jsx(Z.div,{initial:{scale:0},animate:{scale:1},transition:{duration:.5,delay:.1,type:"spring",stiffness:200},className:"mb-8","data-id":"pinr6yc9x","data-path":"src/pages/NotFound.tsx",children:A.jsx("span",{className:"inline-block px-6 py-2 rounded-full text-white font-bold text-lg",style:{backgroundColor:"#0F2E00"},"data-id":"ov2oahpt2","data-path":"src/pages/NotFound.tsx",children:"404 Error"})}),A.jsx(Z.h1,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.5,delay:.2},className:"text-4xl md:text-5xl lg:text-6xl font-bold mb-6",style:{color:"#0F2E00"},"data-id":"nxy1mqv7f","data-path":"src/pages/NotFound.tsx",children:"Lost in the Digital Wilderness?"}),A.jsx(Z.p,{initial:{opacity:0},animate:{opacity:1},transition:{duration:.5,delay:.3},className:"text-lg md:text-xl text-gray-600 mb-10 leading-relaxed","data-id":"2tpjvt0ct","data-path":"src/pages/NotFound.tsx",children:"It looks like the link you followed has moved or no longer exists. Don't worry—we can get you back on the path to growth."}),A.jsxs(Z.div,{initial:{opacity:0,y:40},animate:{opacity:1,y:0},transition:{duration:.6,delay:.4},className:"bg-white rounded-2xl shadow-2xl p-8 mb-10 border border-gray-100",style:{boxShadow:"0 25px 50px -12px rgba(0, 0, 0, 0.15), 0 12px 24px -8px rgba(0, 0, 0, 0.1)"},"data-id":"duqcs79d0","data-path":"src/pages/NotFound.tsx",children:[A.jsx(Z.div,{initial:{rotate:-180,opacity:0},animate:{rotate:0,opacity:1},transition:{duration:.8,delay:.5,type:"spring"},className:"flex justify-center mb-6","data-id":"sjyaqhmad","data-path":"src/pages/NotFound.tsx",children:A.jsx("div",{className:"w-20 h-20 rounded-full flex items-center justify-center",style:{backgroundColor:"rgba(158, 233, 112, 0.2)"},"data-id":"ragzshn2f","data-path":"src/pages/NotFound.tsx",children:A.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"#9EE970",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:"w-10 h-10","data-id":"n4u8irpkm","data-path":"src/pages/NotFound.tsx",children:[A.jsx("circle",{cx:"12",cy:"12",r:"10","data-id":"momxnog51","data-path":"src/pages/NotFound.tsx"}),A.jsx("polygon",{points:"16.24 7.76 14.12 14.12 7.76 16.24 9.88 9.88 16.24 7.76",fill:"#9EE970",stroke:"#9EE970","data-id":"5s0vws22l","data-path":"src/pages/NotFound.tsx"})]})})}),A.jsxs("form",{onSubmit:i,className:"flex flex-col sm:flex-row gap-3","data-id":"0oztg1p0s","data-path":"src/pages/NotFound.tsx",children:[A.jsxs("div",{className:"relative flex-1","data-id":"01uhxop9z","data-path":"src/pages/NotFound.tsx",children:[A.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",className:"absolute left-4 top-1/2 transform -translate-y-1/2 w-5 h-5 text-gray-400","data-id":"w4uhyz4sm","data-path":"src/pages/NotFound.tsx",children:[A.jsx("circle",{cx:"11",cy:"11",r:"8","data-id":"e948jfpku","data-path":"src/pages/NotFound.tsx"}),A.jsx("path",{d:"m21 21-4.3-4.3","data-id":"rbv3sm1hv","data-path":"src/pages/NotFound.tsx"})]}),A.jsx(Eo,{type:"text",placeholder:"Search for what you need...",value:n,onChange:r=>s(r.target.value),className:"pl-12 pr-4 py-6 text-base rounded-xl border-gray-200 focus:border-[#9EE970] focus:ring-[#9EE970]","data-id":"u95p530rm","data-path":"src/pages/NotFound.tsx"})]}),A.jsx(ie,{type:"submit",className:"px-8 py-6 rounded-xl text-base font-semibold transition-all duration-300 hover:scale-105",style:{backgroundColor:"#9EE970",color:"#0F2E00"},"data-id":"3adpubyiq","data-path":"src/pages/NotFound.tsx",children:"Search Again"})]})]}),A.jsxs(Z.div,{initial:{opacity:0,y:20},animate:{opacity:1,y:0},transition:{duration:.5,delay:.6},className:"flex flex-col sm:flex-row gap-4 justify-center","data-id":"fnh36m2dh","data-path":"src/pages/NotFound.tsx",children:[A.jsx(ie,{asChild:!0,size:"lg",className:"px-8 py-6 rounded-xl text-base font-semibold transition-all duration-300 hover:scale-105 hover:shadow-lg",style:{backgroundColor:"#9EE970",color:"#0F2E00"},"data-id":"4dou6hrwd","data-path":"src/pages/NotFound.tsx",children:A.jsx("a",{href:"/","data-id":"6jnjc3gp7","data-path":"src/pages/NotFound.tsx",children:"Back to Homepage"})}),A.jsx(ie,{asChild:!0,variant:"outline",size:"lg",className:"px-8 py-6 rounded-xl text-base font-semibold transition-all duration-300 hover:scale-105 border-2",style:{borderColor:"#0F2E00",color:"#0F2E00",backgroundColor:"transparent"},"data-id":"sdvq3ulhj","data-path":"src/pages/NotFound.tsx",children:A.jsx("a",{href:"/services/seo","data-id":"2f6pmvila","data-path":"src/pages/NotFound.tsx",children:"View Our Services"})})]}),A.jsxs(Z.div,{initial:{opacity:0},animate:{opacity:1},transition:{duration:.5,delay:.8},className:"mt-12 pt-8 border-t border-gray-200","data-id":"n1mv73u51","data-path":"src/pages/NotFound.tsx",children:[A.jsx("p",{className:"text-gray-500 mb-4","data-id":"0faxb3ssa","data-path":"src/pages/NotFound.tsx",children:"Popular destinations:"}),A.jsx("div",{className:"flex flex-wrap justify-center gap-3","data-id":"ogmd8maie","data-path":"src/pages/NotFound.tsx",children:[{name:"SEO Services",href:"/services/seo"},{name:"Web Design",href:"/web-design-service"},{name:"Portfolio",href:"/portfolio"},{name:"Contact Us",href:"/contact"}].map(r=>A.jsx("a",{href:r.href,className:"px-4 py-2 text-sm rounded-full border border-gray-200 hover:border-[#9EE970] hover:bg-[#9EE970]/10 transition-all duration-300",style:{color:"#0F2E00"},"data-id":"6a52npe5s","data-path":"src/pages/NotFound.tsx",children:r.name},r.name))})]})]})}),A.jsx(Ro,{"data-id":"kq092ni5r","data-path":"src/pages/NotFound.tsx"})]})};export{Eu as default};