function Tt(t,e){t.indexOf(e)===-1&&t.push(e)}function St(t,e){const n=t.indexOf(e);n>-1&&t.splice(n,1)}const lt=(t,e,n)=>Math.min(Math.max(n,t),e),b={duration:.3,delay:0,endDelay:0,repeat:0,easing:"ease"},j=t=>typeof t=="number",R=t=>Array.isArray(t)&&!j(t[0]),Ot=(t,e,n)=>{const i=e-t;return((n-t)%i+i)%i+t};function ut(t,e){return R(t)?t[Ot(0,t.length,e)]:t}const Q=(t,e,n)=>-n*t+n*e+t,ft=()=>{},M=t=>t,N=(t,e,n)=>e-t===0?1:(n-t)/(e-t);function Y(t,e){const n=t[t.length-1];for(let i=1;i<=e;i++){const s=N(0,e,i);t.push(Q(n,1,s))}}function ht(t){const e=[0];return Y(e,t-1),e}function At(t,e=ht(t.length),n=M){const i=t.length,s=i-e.length;return s>0&&Y(e,s),a=>{let r=0;for(;rArray.isArray(t)&&j(t[0]),K=t=>typeof t=="object"&&!!t.createAnimation,$=t=>typeof t=="function",pt=t=>typeof t=="string",U={ms:t=>t*1e3,s:t=>t/1e3},mt=(t,e,n)=>(((1-3*n+3*e)*t+(3*n-6*e))*t+3*e)*t,Et=1e-7,wt=12;function xt(t,e,n,i,s){let a,r,l=0;do r=e+(n-e)/2,a=mt(r,i,s)-t,a>0?n=r:e=r;while(Math.abs(a)>Et&&++lxt(a,0,1,t,n);return a=>a===0||a===1?a:mt(s(a),e,i)}const Dt=(t,e="end")=>n=>{n=e==="end"?Math.min(n,.999):Math.max(n,.001);const i=n*t,s=e==="end"?Math.floor(i):Math.ceil(i);return lt(0,1,s/t)},it={ease:_(.25,.1,.25,1),"ease-in":_(.42,0,1,1),"ease-in-out":_(.42,0,.58,1),"ease-out":_(0,0,.58,1)},Mt=/\((.*?)\)/;function G(t){if($(t))return t;if(dt(t))return _(...t);if(it[t])return it[t];if(t.startsWith("steps")){const e=Mt.exec(t);if(e){const n=e[1].split(",");return Dt(parseFloat(n[0]),n[1].trim())}}return M}class Pt{constructor(e,n=[0,1],{easing:i,duration:s=b.duration,delay:a=b.delay,endDelay:r=b.endDelay,repeat:l=b.repeat,offset:h,direction:d="normal"}={}){if(this.startTime=null,this.rate=1,this.t=0,this.cancelTimestamp=null,this.easing=M,this.duration=0,this.totalDuration=0,this.repeat=0,this.playState="idle",this.finished=new Promise((p,c)=>{this.resolve=p,this.reject=c}),i=i||b.easing,K(i)){const p=i.createAnimation(n);i=p.easing,n=p.keyframes||n,s=p.duration||s}this.repeat=l,this.easing=R(i)?M:G(i),this.updateDuration(s);const x=At(n,h,R(i)?i.map(G):M);this.tick=p=>{var c;a=a;let m=0;this.pauseTime!==void 0?m=this.pauseTime:m=(p-this.startTime)*this.rate,this.t=m,m/=1e3,m=Math.max(m-a,0),this.playState==="finished"&&this.pauseTime===void 0&&(m=this.totalDuration);const S=m/this.duration;let g=Math.floor(S),f=S%1;!f&&S>=1&&(f=1),f===1&&g--;const A=g%2;(d==="reverse"||d==="alternate"&&A||d==="alternate-reverse"&&!A)&&(f=1-f);const O=m>=this.totalDuration?1:Math.min(f,1),T=x(this.easing(O));e(T),this.pauseTime===void 0&&(this.playState==="finished"||m>=this.totalDuration+r)?(this.playState="finished",(c=this.resolve)===null||c===void 0||c.call(this,T)):this.playState!=="idle"&&(this.frameRequestId=requestAnimationFrame(this.tick))},this.play()}play(){const e=performance.now();this.playState="running",this.pauseTime!==void 0?this.startTime=e-this.pauseTime:this.startTime||(this.startTime=e),this.cancelTimestamp=this.startTime,this.pauseTime=void 0,this.frameRequestId=requestAnimationFrame(this.tick)}pause(){this.playState="paused",this.pauseTime=this.t}finish(){this.playState="finished",this.tick(0)}stop(){var e;this.playState="idle",this.frameRequestId!==void 0&&cancelAnimationFrame(this.frameRequestId),(e=this.reject)===null||e===void 0||e.call(this,!1)}cancel(){this.stop(),this.tick(this.cancelTimestamp)}reverse(){this.rate*=-1}commitStyles(){}updateDuration(e){this.duration=e,this.totalDuration=e*(this.repeat+1)}get currentTime(){return this.t}set currentTime(e){this.pauseTime!==void 0||this.rate===0?this.pauseTime=e:this.startTime=performance.now()-e/this.rate}get playbackRate(){return this.rate}set playbackRate(e){this.rate=e}}var Ft=function(){};class It{setAnimation(e){this.animation=e,e?.finished.then(()=>this.clearAnimation()).catch(()=>{})}clearAnimation(){this.animation=this.generator=void 0}}const X=new WeakMap;function gt(t){return X.has(t)||X.set(t,{transforms:[],values:new Map}),X.get(t)}function Rt(t,e){return t.has(e)||t.set(e,new It),t.get(e)}const jt=["","X","Y","Z"],Vt=["translate","scale","rotate","skew"],L={x:"translateX",y:"translateY",z:"translateZ"},st={syntax:"",initialValue:"0deg",toDefaultUnit:t=>t+"deg"},_t={translate:{syntax:"",initialValue:"0px",toDefaultUnit:t=>t+"px"},rotate:st,scale:{syntax:"",initialValue:1,toDefaultUnit:M},skew:st},z=new Map,tt=t=>`--motion-${t}`,B=["x","y","z"];Vt.forEach(t=>{jt.forEach(e=>{B.push(t+e),z.set(tt(t+e),_t[t])})});const Ut=(t,e)=>B.indexOf(t)-B.indexOf(e),$t=new Set(B),yt=t=>$t.has(t),zt=(t,e)=>{L[e]&&(e=L[e]);const{transforms:n}=gt(t);Tt(n,e),t.style.transform=Ct(n)},Ct=t=>t.sort(Ut).reduce(qt,"").trim(),qt=(t,e)=>`${t} ${e}(var(${tt(e)}))`,H=t=>t.startsWith("--"),at=new Set;function Kt(t){if(!at.has(t)){at.add(t);try{const{syntax:e,initialValue:n}=z.has(t)?z.get(t):{};CSS.registerProperty({name:t,inherits:!1,syntax:e,initialValue:n})}catch{}}}const Z=(t,e)=>document.createElement("div").animate(t,e),rt={cssRegisterProperty:()=>typeof CSS<"u"&&Object.hasOwnProperty.call(CSS,"registerProperty"),waapi:()=>Object.hasOwnProperty.call(Element.prototype,"animate"),partialKeyframes:()=>{try{Z({opacity:[1]})}catch{return!1}return!0},finished:()=>!!Z({opacity:[0,1]},{duration:.001}).finished,linearEasing:()=>{try{Z({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0}},k={},I={};for(const t in rt)I[t]=()=>(k[t]===void 0&&(k[t]=rt[t]()),k[t]);const Lt=.015,Bt=(t,e)=>{let n="";const i=Math.round(e/Lt);for(let s=0;s$(t)?I.linearEasing()?`linear(${Bt(t,e)})`:b.easing:dt(t)?Nt(t):t,Nt=([t,e,n,i])=>`cubic-bezier(${t}, ${e}, ${n}, ${i})`;function Wt(t,e){for(let n=0;nArray.isArray(t)?t:[t];function J(t){return L[t]&&(t=L[t]),yt(t)?tt(t):t}const q={get:(t,e)=>{e=J(e);let n=H(e)?t.style.getPropertyValue(e):getComputedStyle(t)[e];if(!n&&n!==0){const i=z.get(e);i&&(n=i.initialValue)}return n},set:(t,e,n)=>{e=J(e),H(e)?t.style.setProperty(e,n):t.style[e]=n}};function bt(t,e=!0){if(!(!t||t.playState==="finished"))try{t.stop?t.stop():(e&&t.commitStyles(),t.cancel())}catch{}}function Xt(t,e){var n;let i=e?.toDefaultUnit||M;const s=t[t.length-1];if(pt(s)){const a=((n=s.match(/(-?[\d.]+)([a-z%]*)/))===null||n===void 0?void 0:n[2])||"";a&&(i=r=>r+a)}return i}function Zt(){return window.__MOTION_DEV_TOOLS_RECORD}function kt(t,e,n,i={},s){const a=Zt(),r=i.record!==!1&&a;let l,{duration:h=b.duration,delay:d=b.delay,endDelay:x=b.endDelay,repeat:p=b.repeat,easing:c=b.easing,persist:m=!1,direction:S,offset:g,allowWebkitAcceleration:f=!1}=i;const A=gt(t),O=yt(e);let T=I.waapi();O&&zt(t,e);const y=J(e),D=Rt(A.values,y),v=z.get(y);return bt(D.animation,!(K(c)&&D.generator)&&i.record!==!1),()=>{const P=()=>{var u,E;return(E=(u=q.get(t,y))!==null&&u!==void 0?u:v?.initialValue)!==null&&E!==void 0?E:0};let o=Wt(vt(n),P);const V=Xt(o,v);if(K(c)){const u=c.createAnimation(o,e!=="opacity",P,y,D);c=u.easing,o=u.keyframes||o,h=u.duration||h}if(H(y)&&(I.cssRegisterProperty()?Kt(y):T=!1),O&&!I.linearEasing()&&($(c)||R(c)&&c.some($))&&(T=!1),T){v&&(o=o.map(w=>j(w)?v.toDefaultUnit(w):w)),o.length===1&&(!I.partialKeyframes()||r)&&o.unshift(P());const u={delay:U.ms(d),duration:U.ms(h),endDelay:U.ms(x),easing:R(c)?void 0:ot(c,h),direction:S,iterations:p+1,fill:"both"};l=t.animate({[y]:o,offset:g,easing:R(c)?c.map(w=>ot(w,h)):void 0},u),l.finished||(l.finished=new Promise((w,C)=>{l.onfinish=w,l.oncancel=C}));const E=o[o.length-1];l.finished.then(()=>{m||(q.set(t,y,E),l.cancel())}).catch(ft),f||(l.playbackRate=1.000001)}else if(s&&O)o=o.map(u=>typeof u=="string"?parseFloat(u):u),o.length===1&&o.unshift(parseFloat(P())),l=new s(u=>{q.set(t,y,V?V(u):u)},o,Object.assign(Object.assign({},i),{duration:h,easing:c}));else{const u=o[o.length-1];q.set(t,y,v&&j(u)?v.toDefaultUnit(u):u)}return r&&a(t,e,o,{duration:h,delay:d,easing:c,repeat:p,offset:g},"motion-one"),D.setAnimation(l),l}}const Gt=(t,e)=>t[e]?Object.assign(Object.assign({},t),t[e]):Object.assign({},t);function Ht(t,e){var n;return typeof t=="string"?e?((n=e[t])!==null&&n!==void 0||(e[t]=document.querySelectorAll(t)),t=e[t]):t=document.querySelectorAll(t):t instanceof Element&&(t=[t]),Array.from(t||[])}const Jt=t=>t(),Qt=(t,e,n=b.duration)=>new Proxy({animations:t.map(Jt).filter(Boolean),duration:n,options:e},te),Yt=t=>t.animations[0],te={get:(t,e)=>{const n=Yt(t);switch(e){case"duration":return t.duration;case"currentTime":return U.s(n?.[e]||0);case"playbackRate":case"playState":return n?.[e];case"finished":return t.finished||(t.finished=Promise.all(t.animations.map(ee)).catch(ft)),t.finished;case"stop":return()=>{t.animations.forEach(i=>bt(i))};case"forEachNative":return i=>{t.animations.forEach(s=>i(s,t))};default:return typeof n?.[e]>"u"?void 0:()=>t.animations.forEach(i=>i[e]())}},set:(t,e,n)=>{switch(e){case"currentTime":n=U.ms(n);case"playbackRate":for(let i=0;it.finished;function fe(t=.1,{start:e=0,from:n=0,easing:i}={}){return(s,a)=>{const r=j(n)?n:ne(n,a),l=Math.abs(r-s);let h=t*l;if(i){const d=a*t;h=G(i)(h/d)*d}return e+h}}function ne(t,e){if(t==="first")return 0;{const n=e-1;return t==="last"?n:n/2}}function ie(t,e,n){return $(t)?t(e,n):t}function se(t,e){var n={};for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&e.indexOf(i)<0&&(n[i]=t[i]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(t);se&&s.atkt(...a,Pt)).filter(Boolean);return Qt(s,e,(n=i[0])===null||n===void 0?void 0:n[3].duration)}function ce(t,e={}){var{defaultOptions:n={}}=e,i=se(e,["defaultOptions"]);const s=[],a=new Map,r={},l=new Map;let h=0,d=0,x=0;for(let p=0;p1);const W=E.createAnimation(o,v!=="opacity",()=>0,v);E=W.easing,o=W.keyframes||o,u=W.duration||u}const w=ie(g.delay,T,O)||0,C=d+w,et=C+u;let{offset:F=ht(o.length)}=V;F.length===1&&F[0]===0&&(F[1]=1);const nt=F.length-o.length;nt>0&&Y(F,nt),o.length===1&&o.unshift(null),re(P,o,E,F,C,et),f=Math.max(w+u,f),x=Math.max(et,x)}}h=d,d+=f}return a.forEach((p,c)=>{for(const m in p){const S=p[m];S.sort(oe);const g=[],f=[],A=[];for(let O=0;O