import{r as e,t}from"./rolldown-runtime.p8eEpTWT.mjs";import{A as n,C as r,D as i,F as a,I as o,L as s,M as c,N as l,O as u,P as d,R as f,S as p,T as m,_ as h,c as g,d as _,f as v,j as y,k as b,l as x,o as S,s as C,u as w,w as ee,y as T}from"./react.DWs40o7o.mjs";var te,E,ne,re,ie,ae,oe,se,ce,le,ue,de,fe,pe,me,he,ge,_e,ve,ye,be,xe,Se,Ce,we,Te,Ee,De,Oe,ke=t((()=>{te=Object.create,E=Object.defineProperty,ne=Object.getOwnPropertyDescriptor,re=Object.getOwnPropertyNames,ie=Object.getPrototypeOf,ae=Object.prototype.hasOwnProperty,oe=(e,t)=>(t=Symbol[e])?t:Symbol.for(`Symbol.`+e),se=e=>{throw TypeError(e)},ce=(e,t,n)=>t in e?E(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,le=(e,t)=>E(e,`name`,{value:t,configurable:!0}),ue=(t=>e===void 0?typeof Proxy<`u`?new Proxy(t,{get:(t,n)=>(e===void 0?t:e)[n]}):t:e)(function(t){if(e!==void 0)return e.apply(this,arguments);throw Error(`Dynamic require of "`+t+`" is not supported`)}),de=(e,t)=>function(){return t||(0,e[re(e)[0]])((t={exports:{}}).exports,t),t.exports},fe=(e,t)=>{for(var n in t)E(e,n,{get:t[n],enumerable:!0})},pe=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let i of re(t))!ae.call(e,i)&&i!==n&&E(e,i,{get:()=>t[i],enumerable:!(r=ne(t,i))||r.enumerable});return e},me=(e,t,n)=>(n=e==null?{}:te(ie(e)),pe(t||!e||!e.__esModule?E(n,`default`,{value:e,enumerable:!0}):n,e)),he=e=>[,,,te(e?.[oe(`metadata`)]??null)],ge=[`class`,`method`,`getter`,`setter`,`accessor`,`field`,`value`,`get`,`set`],_e=e=>e!==void 0&&typeof e!=`function`?se(`Function expected`):e,ve=(e,t,n,r,i)=>({kind:ge[e],name:t,metadata:r,addInitializer:e=>n._?se(`Already initialized`):i.push(_e(e||null))}),ye=(e,t)=>ce(t,oe(`metadata`),e[3]),be=(e,t,n,r)=>{for(var i=0,a=e[t>>1],o=a&&a.length;i{var o,s,c,l,u,d=t&7,f=!!(t&8),p=!!(t&16),m=d>3?e.length+1:d?f?1:2:0,h=ge[d+5],g=d>3&&(e[m-1]=[]),_=e[m]||(e[m]=[]),v=d&&(!p&&!f&&(i=i.prototype),d<5&&(d>3||!p)&&ne(d<4?i:{get[n](){return Te(this,a)},set[n](e){return De(this,a,e)}},n));d?p&&d<4&&le(a,(d>2?`set `:d>1?`get `:``)+n):le(i,n);for(var y=r.length-1;y>=0;y--)l=ve(d,n,c={},e[3],_),d&&(l.static=f,l.private=p,u=l.access={has:p?e=>we(i,e):e=>n in e},d^3&&(u.get=p?e=>(d^1?Te:Oe)(e,i,d^4?a:v.get):e=>e[n]),d>2&&(u.set=p?(e,t)=>De(e,i,t,d^4?a:v.set):(e,t)=>e[n]=t)),s=(0,r[y])(d?d<4?p?a:v[h]:d>4?void 0:{get:v.get,set:v.set}:i,l),c._=1,d^4||s===void 0?_e(s)&&(d>4?g.unshift(s):d?p?a=s:v[h]=s:i=s):typeof s!=`object`||!s?se(`Object expected`):(_e(o=s.get)&&(v.get=o),_e(o=s.set)&&(v.set=o),_e(o=s.init)&&g.unshift(o));return d||ye(e,i),v&&E(i,n,v),p?d^4?a:v:i},Se=(e,t,n)=>ce(e,typeof t==`symbol`?t:t+``,n),Ce=(e,t,n)=>t.has(e)||se(`Cannot `+n),we=(e,t)=>Object(t)===t?e.has(t):se(`Cannot use the "in" operator on this value`),Te=(e,t,n)=>(Ce(e,t,`read from private field`),n?n.call(e):t.get(e)),Ee=(e,t,n)=>t.has(e)?se(`Cannot add the same private member more than once`):t instanceof WeakSet?t.add(e):t.set(e,n),De=(e,t,n,r)=>(Ce(e,t,`write to private field`),r?r.call(e,n):t.set(e,n),n),Oe=(e,t,n)=>(Ce(e,t,`access private method`),n)}));function Ae(e,t){e.indexOf(t)===-1&&e.push(t)}function je(e,t){let n=e.indexOf(t);n>-1&&e.splice(n,1)}function Me([...e],t,n){let r=t<0?e.length+t:t;if(r>=0&&r(t===void 0&&(t=e()),t)}function Fe(e,t){return t?1e3/t*e:0}function Ie(e,t,n,r,i){let a,o,s=0;do o=t+(n-t)/2,a=Us(o,r,i)-e,a>0?n=o:t=o;while(Math.abs(a)>Ws&&++sIe(t,0,1,e,n);return e=>e===0||e===1?e:Us(i(e),t,r)}function Re(e,t){return ic(e)?e[Hs(0,e.length,t)]:e}function ze(e,t){let n=new Set,r=new Set,i=!1,a=!1,o=new WeakSet,s={delta:0,timestamp:0,isProcessing:!1},c=0;function l(t){o.has(t)&&(u.schedule(t),e()),c++,t(s)}let u={schedule:(e,t=!1,a=!1)=>{let s=a&&i?n:r;return t&&o.add(e),s.add(e),e},cancel:e=>{r.delete(e),o.delete(e)},process:e=>{if(s=e,i){a=!0;return}i=!0;let o=n;n=r,r=o,n.forEach(l),t&&z.value&&z.value.frameloop[t].push(c),c=0,n.clear(),i=!1,a&&(a=!1,u.process(e))}};return u}function Be(e,t){let n=!1,r=!0,i={delta:0,timestamp:0,isProcessing:!1},a=()=>n=!0,o=lc.reduce((e,n)=>(e[n]=ze(a,t?n:void 0),e),{}),{setup:s,read:c,resolveKeyframes:l,preUpdate:u,update:d,preRender:f,render:p,postRender:m}=o,h=()=>{let a=F.useManualTiming,o=a?i.timestamp:performance.now();n=!1,a||(i.delta=r?1e3/60:Math.max(Math.min(o-i.timestamp,uc),1)),i.timestamp=o,i.isProcessing=!0,s.process(i),c.process(i),l.process(i),u.process(i),d.process(i),f.process(i),p.process(i),m.process(i),i.isProcessing=!1,n&&t&&(r=!1,e(h))},g=()=>{n=!0,r=!0,i.isProcessing||e(h)};return{schedule:lc.reduce((e,t)=>{let r=o[t];return e[t]=(e,t=!1,i=!1)=>(n||g(),r.schedule(e,t,i)),e},{}),cancel:e=>{for(let t=0;t5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}function Ge(e){return isNaN(e)&&typeof e==`string`&&(e.match(Cc)?.length||0)+(e.match(Lc)?.length||0)>0}function Ke(e){let t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[],a=0;return{values:n,split:t.replace(Uc,e=>(K.test(e)?(r.color.push(a),i.push(zc),n.push(K.parse(e))):e.startsWith(Vc)?(r.var.push(a),i.push(Bc),n.push(e)):(r.number.push(a),i.push(Rc),n.push(parseFloat(e))),++a,Hc)).split(Hc),indexes:r,types:i}}function qe(e){return Ke(e).values}function Je({split:e,types:t}){let n=e.length;return r=>{let i=``;for(let a=0;aGc(e,t.split[n])))}function Ze(e,t,n){return n<0&&(n+=1),n>1&&--n,n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function Qe({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,a=0,o=0;if(!t)i=a=o=n;else{let r=n<.5?n*(1+t):n+t-n*t,s=2*n-r;i=Ze(s,r,e+1/3),a=Ze(s,r,e),o=Ze(s,r,e-1/3)}return{red:Math.round(i*255),green:Math.round(a*255),blue:Math.round(o*255),alpha:r}}function $e(e,t){return n=>n>0?t:e}function et(e){let t=Jc(e);if(Fs(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`,`color-not-animatable`),!t)return!1;let n=t.parse(e);return t===Ic&&(n=Qe(n)),n}function tt(e,t){return Xc.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function nt(e,t){return n=>J(e,t,n)}function rt(e){return typeof e==`number`?nt:typeof e==`string`?_c(e)?$e:K.test(e)?Yc:Zc:Array.isArray(e)?it:typeof e==`object`?K.test(e)?Yc:at:$e}function it(e,t){let n=[...e],r=n.length,i=e.map((e,n)=>rt(e)(e,t[n]));return e=>{for(let t=0;t{for(let t in r)n[t]=r[t](e);return n}}function ot(e,t){let n=[],r={color:0,var:0,number:0};for(let i=0;i=$c?1/0:t}function lt(e,t=100,n){let r=n({...e,keyframes:[0,t]}),i=Math.min(ct(r),$c);return{type:`keyframes`,ease:e=>r.next(i*e).value/t,duration:R(i)}}function ut(e,t){return e*Math.sqrt(1-t*t)}function dt(e,t,n){let r=n;for(let n=1;n{let r=t*o,i=r*e,a=r-n,s=ut(t,o),c=Math.exp(-i);return tl-a/s*c},a=t=>{let r=t*o*e,a=r*n+n,s=o**2*t**2*e,c=Math.exp(-r),l=ut(t**2,o);return(-i(t)+tl>0?-1:1)*((a-s)*c)/l}):(i=t=>{let r=Math.exp(-t*e),i=(t-n)*e+1;return-tl+r*i},a=t=>Math.exp(-t*e)*((n-t)*(e*e)));let s=5/e,c=dt(i,a,s);if(e=L(e),isNaN(c))return{stiffness:Y.stiffness,damping:Y.damping,duration:e};{let t=c**2*r;return{stiffness:t,damping:o*2*Math.sqrt(r*t),duration:e}}}function pt(e,t){return t.some(t=>e[t]!==void 0)}function mt(e){let t={velocity:Y.velocity,stiffness:Y.stiffness,damping:Y.damping,mass:Y.mass,isResolvedFromDuration:!1,...e};if(!pt(e,rl)&&pt(e,nl))if(t.velocity=0,e.visualDuration){let n=e.visualDuration,r=2*Math.PI/(n*1.2),i=r*r,a=2*N(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:Y.mass,stiffness:i,damping:a}}else{let n=ft({...e,velocity:0});t={...t,...n,mass:Y.mass},t.isResolvedFromDuration=!0}return t}function ht(e=Y.visualDuration,t=Y.bounce){let n=typeof e==`object`?e:{visualDuration:e,keyframes:[0,1],bounce:t},{restSpeed:r,restDelta:i}=n,a=n.keyframes[0],o=n.keyframes[n.keyframes.length-1],s={done:!1,value:a},{stiffness:c,damping:l,mass:u,duration:d,velocity:f,isResolvedFromDuration:p}=mt({...n,velocity:-R(n.velocity||0)}),m=f||0,h=l/(2*Math.sqrt(c*u)),g=o-a,_=R(Math.sqrt(c/u)),v=Math.abs(g)<5;r||=v?Y.restSpeed.granular:Y.restSpeed.default,i||=v?Y.restDelta.granular:Y.restDelta.default;let y,b,x,S,C,w;if(h<1)x=ut(_,h),S=(m+h*_*g)/x,y=e=>o-Math.exp(-h*_*e)*(S*Math.sin(x*e)+g*Math.cos(x*e)),C=h*_*S+g*x,w=h*_*g-S*x,b=e=>Math.exp(-h*_*e)*(C*Math.sin(x*e)+w*Math.cos(x*e));else if(h===1){y=e=>o-Math.exp(-_*e)*(g+(m+_*g)*e);let e=m+_*g;b=t=>Math.exp(-_*t)*(_*e*t-m)}else{let e=_*Math.sqrt(h*h-1);y=t=>{let n=Math.exp(-h*_*t),r=Math.min(e*t,300);return o-n*((m+h*_*g)*Math.sinh(r)+e*g*Math.cosh(r))/e};let t=(m+h*_*g)/e,n=h*_*t-g*e,r=h*_*g-t*e;b=t=>{let i=Math.exp(-h*_*t),a=Math.min(e*t,300);return i*(n*Math.sinh(a)+r*Math.cosh(a))}}let ee={calculatedDuration:p&&d||null,velocity:e=>L(b(e)),next:e=>{if(!p&&h<1){let t=Math.exp(-h*_*e),n=Math.sin(x*e),a=Math.cos(x*e),c=o-t*(S*n+g*a),l=L(t*(C*n+w*a));return s.done=Math.abs(l)<=r&&Math.abs(o-c)<=i,s.value=s.done?o:c,s}let t=y(e);if(p)s.done=e>=d;else{let n=L(b(e));s.done=Math.abs(n)<=r&&Math.abs(o-t)<=i}return s.value=s.done?o:t,s},toString:()=>{let e=Math.min(ct(ee),$c),t=Qc(t=>ee.next(e*t).value,e,30);return e+`ms `+t},toTransition:()=>{}};return ee}function gt(e,t,n){let r=Math.max(t-il,0);return Fe(n-e(r),t-r)}function _t({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:a=500,modifyTarget:o,min:s,max:c,restDelta:l=.5,restSpeed:u}){let d=e[0],f={done:!1,value:d},p=e=>s!==void 0&&ec,m=e=>s===void 0?c:c===void 0||Math.abs(s-e)-h*Math.exp(-e/r),y=e=>_+v(e),b=e=>{let t=v(e),n=y(e);f.done=Math.abs(t)<=l,f.value=f.done?_:n},x,S,C=e=>{p(f.value)&&(x=e,S=ht({keyframes:[f.value,m(f.value)],velocity:gt(y,e,f.value),damping:i,stiffness:a,restDelta:l,restSpeed:u}))};return C(0),{calculatedDuration:null,next:e=>{let t=!1;return!S&&x===void 0&&(t=!0,b(e),C(e)),x!==void 0&&e>=x?S.next(e-x):(!t&&b(e),f)}}}function vt(e,t,n){let r=[],i=n||F.mix||st,a=e.length-1;for(let n=0;nt[0];if(a===2&&t[0]===t[1])return()=>t[1];let o=e[0]===e[1];e[0]>e[a-1]&&(e=[...e].reverse(),t=[...t].reverse());let s=vt(t,r,i),c=s.length,l=n=>{if(o&&n1)for(;rl(N(e[0],e[a-1],t)):l}function bt(e,t){let n=e[e.length-1];for(let r=1;r<=t;r++){let i=Bs(0,t,r);e.push(J(n,1,i))}}function xt(e){let t=[0];return bt(t,e.length-1),t}function St(e,t){return e.map(e=>e*t)}function Ct(e,t){return e.map(()=>t||rc).splice(0,e.length-1)}function wt({duration:e=300,keyframes:t,times:n,ease:r=`easeInOut`}){let i=ic(r)?r.map(cc):cc(r),a={done:!1,value:t[0]},o=yt(St(n&&n.length===t.length?n:xt(t),e),t,{ease:Array.isArray(i)?i:Ct(t,i)});return{calculatedDuration:e,next:t=>(a.value=o(t),a.done=t>=e,a)}}function Tt(e,{repeat:t,repeatType:n=`loop`},r,i=1){let a=e.filter(al),o=i<0||t&&n!==`loop`&&t%2==1?0:a.length-1;return!o||r===void 0?a[o]:r}function Et(e){typeof e.type==`string`&&(e.type=sl[e.type])}function Dt(e){return new ul(e)}function Ot(e){for(let t=1;t{let r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith(`scale`)?1:0))}),t}function Nt(){if(Ol){let e=Array.from(El).filter(e=>e.needsMeasurement),t=new Set(e.map(e=>e.element)),n=new Map;t.forEach(e=>{let t=Mt(e);t.length&&(n.set(e,t),e.render())}),e.forEach(e=>e.measureInitialState()),t.forEach(e=>{e.render();let t=n.get(e);t&&t.forEach(([t,n])=>{e.getValue(t)?.set(n)})}),e.forEach(e=>e.measureEndState()),e.forEach(e=>{e.suspendedScrollY!==void 0&&f.scrollTo(0,e.suspendedScrollY)})}Ol=!1,Dl=!1,El.forEach(e=>e.complete(kl)),El.clear()}function Pt(){El.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Ol=!0)})}function Ft(){kl=!0,Pt(),Nt(),kl=!1}function It(e,t,n){jl(t)?e.style.setProperty(t,n):e.style[t]=n}function Lt(e,t){let n=Pe(e);return()=>Ml[t]??n()}function Rt(e,t){if(e)return typeof e==`function`?Fl()?Qc(e,t):`ease-out`:ac(e)?Il(e):Array.isArray(e)?e.map(e=>Rt(e,t)||Ll.easeOut):Ll[e]}function zt(e,t,n,{delay:r=0,duration:i=300,repeat:a=0,repeatType:o=`loop`,ease:s=`easeOut`,times:c}={},l=void 0){let u={[t]:n};c&&(u.offset=c);let d=Rt(s,i);Array.isArray(d)&&(u.easing=d),z.value&&pc.waapi++;let f={delay:r,duration:i,easing:Array.isArray(d)?`linear`:d,fill:`both`,iterations:a+1,direction:o===`reverse`?`alternate`:`normal`};l&&(f.pseudoElement=l);let p=e.animate(u,f);return z.value&&p.finished.finally(()=>{pc.waapi--}),p}function Bt(e){return typeof e==`function`&&`applyToOptions`in e}function Vt({type:e,...t}){return Bt(e)&&Fl()?e.applyToOptions(t):(t.duration??=300,t.ease??=`easeOut`,t)}function Ht(e){return e in zl}function Ut(e){typeof e.ease==`string`&&Ht(e.ease)&&(e.ease=zl[e.ease])}function Wt(e){e.duration=0,e.type=`keyframes`}function Gt(e){for(let t=0;tn&&(n=i)}return n}function Xt(e,t,n,r=0,i=1){let a=Array.from(e).sort((e,t)=>e.sortNodePosition(t)).indexOf(t),o=e.size,s=(o-1)*r;return typeof n==`function`?n(a,o):i===1?a*r:s-a*r}function Zt(e){let t=Zl.exec(e);if(!t)return[,];let[,n,r,i]=t;return[`--${n??r}`,i]}function Qt(e,t,n=1){P(n<=Ql,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,`max-css-var-depth`);let[r,i]=Zt(e);if(!r)return;let a=f.getComputedStyle(t).getPropertyValue(r);if(a){let e=a.trim();return Is(e)?parseFloat(e):e}return _c(i)?Qt(i,t,n+1):i}function $t(e,t){if(e?.inherit&&t){let{inherit:n,...r}=e;return{...t,...r}}return e}function en(e,t){let n=e?.[t]??e?.default??e;return n===e?n:$t(n,e)}function tn(e){for(let t in e)if(!iu.has(t))return!0;return!1}function nn(e){let t=[{},{}];return e?.values.forEach((e,n)=>{t[0][n]=e.get(),t[1][n]=e.getVelocity()}),t}function rn(e,t,n,r){if(typeof t==`function`){let[i,a]=nn(r);t=t(n===void 0?e.custom:n,i,a)}if(typeof t==`string`&&(t=e.variants&&e.variants[t]),typeof t==`function`){let[i,a]=nn(r);t=t(n===void 0?e.custom:n,i,a)}return t}function an(e,t,n){let r=e.getProps();return rn(r,t,n===void 0?r.custom:n,e)}function D(e,t){return new uu(e,t)}function on(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,D(n))}function sn(e){return du(e)?e[e.length-1]||0:e}function cn(e,t){let{transitionEnd:n={},transition:r={},...i}=an(e,t)||{};for(let t in i={...i,...n},i)on(e,t,sn(i[t]))}function ln(e){return!!(X(e)&&e.add)}function un(e,t){let n=e.getValue(`willChange`);if(ln(n))return n.add(t);if(!n&&F.WillChange){let n=new F.WillChange(`auto`);e.addValue(`willChange`,n),n.add(t)}}function dn(e){return e.replace(/([A-Z])/g,e=>`-${e.toLowerCase()}`)}function fn(e){return e.props[pu]}function pn({protectedKeys:e,needsAnimating:t},n){let r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function mn(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:a,transitionEnd:o,...s}=t,c=e.getDefaultTransition();a=a?$t(a,c):c;let l=a?.reduceMotion;r&&(a=r);let u=[],d=i&&e.animationState&&e.animationState.getState()[i];for(let t in s){let r=e.getValue(t,e.latestValues[t]??null),i=s[t];if(i===void 0||d&&pn(d,t))continue;let o={delay:n,...en(a||{},t)},c=r.get();if(c!==void 0&&!r.isAnimating()&&!Array.isArray(i)&&i===c&&!o.velocity){B.update(()=>r.set(i));continue}let p=!1;if(f.MotionHandoffAnimation){let n=fn(e);if(n){let e=f.MotionHandoffAnimation(n,t,B);e!==null&&(o.startTime=e,p=!0)}}un(e,t);let m=l??e.shouldReduceMotion;r.start(au(t,r,i,m&&ou.has(t)?{type:!1}:o,e,p));let h=r.animation;h&&u.push(h)}if(o){let t=()=>B.update(()=>{o&&cn(e,o)});u.length?Promise.all(u).then(t):t()}return u}function hn(e,t,n={}){let r=an(e,t,n.type===`exit`?e.presenceContext?.custom:void 0),{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);let a=r?()=>Promise.all(mn(e,r,n)):()=>Promise.resolve(),o=e.variantChildren&&e.variantChildren.size?(r=0)=>{let{delayChildren:a=0,staggerChildren:o,staggerDirection:s}=i;return gn(e,t,r,a,o,s,n)}:()=>Promise.resolve(),{when:s}=i;if(s){let[e,t]=s===`beforeChildren`?[a,o]:[o,a];return e().then(()=>t())}else return Promise.all([a(),o(n.delay)])}function gn(e,t,n=0,r=0,i=0,a=1,o){let s=[];for(let c of e.variantChildren)c.notify(`AnimationStart`,t),s.push(hn(c,t,{...o,delay:n+(typeof r==`function`?0:r)+Xt(e.variantChildren,c,r,i,a)}).then(()=>c.notify(`AnimationComplete`,t)));return Promise.all(s)}function _n(e,t,n={}){e.notify(`AnimationStart`,t);let r;if(Array.isArray(t)){let i=t.map(t=>hn(e,t,n));r=Promise.all(i)}else if(typeof t==`string`)r=hn(e,t,n);else{let i=typeof t==`function`?an(e,t,n.custom):t;r=Promise.all(mn(e,i,n))}return r.then(()=>{e.notify(`AnimationComplete`,t)})}function vn(e){let[t,n]=e.slice(0,-1).split(`(`);if(t===`drop-shadow`)return e;let[r]=n.match(Cc)||[];if(!r)return e;let i=n.replace(r,``),a=bu.has(t)?1:0;return r!==n&&(a*=100),t+`(`+a+i+`)`}function yn(e,t){let n=Tu(e);return Eu.has(n)||(n=q),n.getAnimatableNone?n.getAnimatableNone(t):void 0}function bn(e){return typeof e==`number`?e===0:e===null?!0:e===`none`||e===`0`||Ls(e)}function xn(e,t,n){let r=0,i;for(;re!=null)}function Cn(e){return Ne(e)&&`offsetHeight`in e&&!(`ownerSVGElement`in e)}function wn(){return Z.x||Z.y}function Tn(e){return e===`x`||e===`y`?Z[e]?null:(Z[e]=!0,()=>{Z[e]=!1}):Z.x||Z.y?null:(Z.x=Z.y=!0,()=>{Z.x=Z.y=!1})}function En(e,t){let n=Sn(e),r=new AbortController;return[n,{passive:!0,...t,signal:r.signal},()=>r.abort()]}function Dn(e){return!(e.pointerType===`touch`||wn())}function On(e,t,n={}){let[r,i,a]=En(e,n);return r.forEach(e=>{let n=!1,r=!1,a,o=()=>{e.removeEventListener(`pointerleave`,u)},s=e=>{a&&=(a(e),void 0),o()},c=e=>{n=!1,f.removeEventListener(`pointerup`,c),f.removeEventListener(`pointercancel`,c),r&&(r=!1,s(e))},l=()=>{n=!0,f.addEventListener(`pointerup`,c,i),f.addEventListener(`pointercancel`,c,i)},u=e=>{if(e.pointerType!==`touch`){if(n){r=!0;return}s(e)}};e.addEventListener(`pointerenter`,n=>{if(!Dn(n))return;r=!1;let o=t(e,n);typeof o==`function`&&(a=o,e.addEventListener(`pointerleave`,u,i))},i),e.addEventListener(`pointerdown`,l,i)}),a}function kn(e){return Pu.has(e.tagName)||e.isContentEditable===!0}function An(e){return Fu.has(e.tagName)||e.isContentEditable===!0}function jn(e){return t=>{t.key===`Enter`&&e(t)}}function Mn(e,t){e.dispatchEvent(new PointerEvent(`pointer`+t,{isPrimary:!0,bubbles:!0}))}function Nn(e){return Nu(e)&&!wn()}function Pn(e,t,n={}){let[r,i,a]=En(e,n),o=e=>{let r=e.currentTarget;if(!Nn(e)||Ru.has(e))return;Iu.add(r),n.stopPropagation&&Ru.add(e);let a=t(r,e),o=(e,t)=>{f.removeEventListener(`pointerup`,s),f.removeEventListener(`pointercancel`,c),Iu.has(r)&&Iu.delete(r),Nn(e)&&typeof a==`function`&&a(e,{success:t})},s=e=>{o(e,r===f||r===document||n.useGlobalTarget||Mu(r,e.target))},c=e=>{o(e,!1)};f.addEventListener(`pointerup`,s,i),f.addEventListener(`pointercancel`,c,i)};return r.forEach(e=>{(n.useGlobalTarget?f:e).addEventListener(`pointerdown`,o,i),Cn(e)&&(e.addEventListener(`focus`,e=>Lu(e,i)),!kn(e)&&!e.hasAttribute(`tabindex`)&&(e.tabIndex=0))}),a}function Fn(e){return Ne(e)&&`ownerSVGElement`in e}function In({target:e,borderBoxSize:t}){zu.get(e)?.forEach(n=>{n(e,{get width(){return Hu(e,t)},get height(){return Uu(e,t)}})})}function Ln(e){e.forEach(In)}function Rn(){typeof ResizeObserver>`u`||(Bu=new ResizeObserver(Ln))}function zn(e,t){Bu||Rn();let n=Sn(e);return n.forEach(e=>{let n=zu.get(e);n||(n=new Set,zu.set(e,n)),n.add(t),Bu?.observe(e)}),()=>{n.forEach(e=>{let n=zu.get(e);n?.delete(t),n?.size||Bu?.unobserve(e)})}}function Bn(){Gu=()=>{let e={get width(){return f.innerWidth},get height(){return f.innerHeight}};Wu.forEach(t=>t(e))},f.addEventListener(`resize`,Gu)}function Vn(e){return Wu.add(e),Gu||Bn(),()=>{Wu.delete(e),!Wu.size&&typeof Gu==`function`&&(f.removeEventListener(`resize`,Gu),Gu=void 0)}}function Hn(e,t){return typeof e==`function`?Vn(e):zn(e,t)}function Un(e,t){let n,r=()=>{let{currentTime:r}=t,i=(r===null?0:r.value)/100;n!==i&&e(i),n=i};return B.preUpdate(r,!0),()=>V(r)}function Wn(e){return Fn(e)&&e.tagName===`svg`}function Gn(e,t){if(e===`first`)return 0;{let n=t-1;return e===`last`?n:n/2}}function Kn(e=.1,{startDelay:t=0,from:n=0,ease:r}={}){return(i,a)=>{let o=typeof n==`number`?n:Gn(n,a),s=e*Math.abs(o-i);if(r){let t=a*e;s=cc(r)(s/t)*t}return t+s}}function qn(...e){let t=!Array.isArray(e[0]),n=t?0:-1,r=e[0+n],i=e[1+n],a=e[2+n],o=e[3+n],s=yt(i,a,o);return t?s(r):s}function Jn(e,t,n={}){let r=e.get(),i=null,a=r,o,s=typeof r==`string`?r.replace(/[\d.-]/g,``):void 0,c=()=>{i&&=(i.stop(),null),e.animation=void 0},l=()=>{let t=Xn(e.get()),r=Xn(a);if(t===r){c();return}let s=i?i.getGeneratorVelocity():e.getVelocity();c(),i=new ul({keyframes:[t,r],velocity:s,type:`spring`,restDelta:.001,restSpeed:.01,...n,onUpdate:o})},u=()=>{l(),e.animation=i??void 0,e.events.animationStart?.notify(),i?.then(()=>{e.animation=void 0,e.events.animationComplete?.notify()})};if(e.attach((e,t)=>{a=e,o=e=>t(Yn(e,s)),B.postRender(u)},c),X(t)){let r=n.skipInitialAnimation===!0,i=t.on(`change`,t=>{r?(r=!1,e.jump(Yn(t,s),!1)):e.set(Yn(t,s))}),a=e.on(`destroy`,i);return()=>{i(),a()}}return c}function Yn(e,t){return t?e+t:e}function Xn(e){return typeof e==`number`?e:parseFloat(e)}function Zn(e,t,n){let r=()=>t.set(n()),i=()=>B.preRender(r,!1,!0),a=e.map(e=>e.on(`change`,i));t.on(`destroy`,()=>{a.forEach(e=>e()),V(r)})}function Qn(e){let t=[];lu.current=t;let n=e();lu.current=void 0;let r=D(n);return Zn(t,r,e),r}function $n(e){return typeof e==`object`&&!!e&&typeof e.start==`function`}function er(e){return typeof e==`string`||Array.isArray(e)}function tr(e){return $n(e.animate)||$u.some(t=>er(e[t]))}function nr(e){return!!(tr(e)||e.variants)}function rr(e,t,n){for(let r in t){let i=t[r],a=n[r];if(X(i))e.addValue(r,i);else if(X(a))e.addValue(r,D(i,{owner:e}));else if(a!==i)if(e.hasValue(r)){let t=e.getValue(r);t.liveStyle===!0?t.jump(i):t.hasAnimated||t.set(i)}else{let t=e.getStaticValue(r);e.addValue(r,D(t===void 0?i:t,{owner:e}))}}for(let r in n)t[r]===void 0&&e.removeValue(r);return t}function ir(){if(td.current=!0,nd)if(f.matchMedia){let e=f.matchMedia(`(prefers-reduced-motion)`),t=()=>ed.current=e.matches;e.addEventListener(`change`,t),t()}else ed.current=!1}function ar(e){id=e}function or(){return id}function sr({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function cr({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function lr(e,t){if(!t)return e;let n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function ur(e){return e===void 0||e===1}function dr({scale:e,scaleX:t,scaleY:n}){return!ur(e)||!ur(t)||!ur(n)}function fr(e){return dr(e)||pr(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function pr(e){return mr(e.x)||mr(e.y)}function mr(e){return e&&e!==`0%`}function hr(e,t,n){return n+t*(e-n)}function gr(e,t,n,r,i){return i!==void 0&&(e=hr(e,i,r)),hr(e,n,r)+t}function _r(e,t=0,n=1,r,i){e.min=gr(e.min,t,n,r,i),e.max=gr(e.max,t,n,r,i)}function vr(e,{x:t,y:n}){_r(e.x,t.translate,t.scale,t.originPoint),_r(e.y,n.translate,n.scale,n.originPoint)}function yr(e,t,n,r=!1){let i=n.length;if(!i)return;t.x=t.y=1;let a,o;for(let s=0;scd&&(t.x=1),t.ycd&&(t.y=1)}function O(e,t){e.min+=t,e.max+=t}function br(e,t,n,r,i=.5){_r(e,t,n,J(e.min,e.max,i),r)}function xr(e,t){return typeof e==`string`?parseFloat(e)/100*(t.max-t.min):e}function Sr(e,t,n){let r=n??e;br(e.x,xr(t.x,r.x),t.scaleX,t.scale,t.originX),br(e.y,xr(t.y,r.y),t.scaleY,t.scale,t.originY)}function Cr(e,t){return sr(lr(e.getBoundingClientRect(),t))}function wr(e,t,n){let r=Cr(e,n),{scroll:i}=t;return i&&(O(r.x,i.offset.x),O(r.y,i.offset.y)),r}function Tr(e,t,n){let r=``,i=!0;for(let a=0;aPromise.all(t.map(({animation:t,options:n})=>_n(e,t,n)))}function Vr(e){let t=Br(e),n=Wr(),r=!0,i=!1,a=t=>(n,r)=>{let i=an(e,r,t===`exit`?e.presenceContext?.custom:void 0);if(i){let{transition:e,transitionEnd:t,...r}=i;n={...n,...r,...t}}return n};function o(n){t=n(e)}function s(o){let{props:s}=e,c=Rr(e.parent)||{},l=[],u=new Set,d={},f=1/0;for(let t=0;tf&&g,x=!1,S=Array.isArray(h)?h:[h],C=S.reduce(a(p),{});_===!1&&(C={});let{prevResolvedValues:w={}}=m,ee={...w,...C},T=t=>{b=!0,u.has(t)&&(x=!0,u.delete(t)),m.needsAnimating[t]=!0;let n=e.getValue(t);n&&(n.liveStyle=!1)};for(let e in ee){let t=C[e],n=w[e];if(d.hasOwnProperty(e))continue;let r=!1;r=du(t)&&du(n)?!zr(t,n):t!==n,r?t==null?u.add(e):T(e):t!==void 0&&u.has(e)?T(e):m.protectedKeys[e]=!0}m.prevProp=h,m.prevResolvedValues=C,m.isActive&&(d={...d,...C}),(r||i)&&e.blockInitialAnimation&&(b=!1);let te=v&&y;b&&(!te||x)&&l.push(...S.map(t=>{let n={type:p};if(typeof t==`string`&&(r||i)&&!te&&e.manuallyAnimateOnMount&&e.parent){let{parent:r}=e,i=an(r,t);if(r.enteringChildren&&i){let{delayChildren:t}=i.transition||{};n.delay=Xt(r.enteringChildren,e,t)}}return{animation:t,options:n}}))}if(u.size){let t={};if(typeof s.initial!=`boolean`){let n=an(e,Array.isArray(s.initial)?s.initial[0]:s.initial);n&&n.transition&&(t.transition=n.transition)}u.forEach(n=>{let r=e.getBaseTarget(n),i=e.getValue(n);i&&(i.liveStyle=!0),t[n]=r??null}),l.push({animation:t})}let p=!!l.length;return r&&(s.initial===!1||s.initial===s.animate)&&!e.manuallyAnimateOnMount&&(p=!1),r=!1,i=!1,p?t(l):Promise.resolve()}function c(t,r){if(n[t].isActive===r)return Promise.resolve();e.variantChildren?.forEach(e=>e.animationState?.setActive(t,r)),n[t].isActive=r;let i=s(t);for(let e in n)n[e].protectedKeys={};return i}return{animateChanges:s,setActive:c,setAnimateFunction:o,getState:()=>n,reset:()=>{n=Wr(),i=!0}}}function Hr(e,t){return typeof t==`string`?t!==e:Array.isArray(t)?!zr(t,e):!1}function Ur(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Wr(){return{animate:Ur(!0),whileInView:Ur(),whileHover:Ur(),whileTap:Ur(),whileDrag:Ur(),whileFocus:Ur(),exit:Ur()}}function Gr(e,t){e.min=t.min,e.max=t.max}function k(e,t){Gr(e.x,t.x),Gr(e.y,t.y)}function Kr(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function A(e){return e.max-e.min}function qr(e,t,n){return Math.abs(e-t)<=n}function Jr(e,t,n,r=.5){e.origin=r,e.originPoint=J(t.min,t.max,e.origin),e.scale=A(n)/A(t),e.translate=J(n.min,n.max,e.origin)-e.originPoint,(e.scale>=Dd&&e.scale<=Od||isNaN(e.scale))&&(e.scale=1),(e.translate>=Ad&&e.translate<=jd||isNaN(e.translate))&&(e.translate=0)}function Yr(e,t,n,r){Jr(e.x,t.x,n.x,r?r.originX:void 0),Jr(e.y,t.y,n.y,r?r.originY:void 0)}function Xr(e,t,n,r=0){e.min=(r?J(n.min,n.max,r):n.min)+t.min,e.max=e.min+A(t)}function Zr(e,t,n,r){Xr(e.x,t.x,n.x,r?.x),Xr(e.y,t.y,n.y,r?.y)}function Qr(e,t,n,r=0){let i=r?J(n.min,n.max,r):n.min;e.min=t.min-i,e.max=e.min+A(t)}function $r(e,t,n,r){Qr(e.x,t.x,n.x,r?.x),Qr(e.y,t.y,n.y,r?.y)}function ei(e,t,n,r,i){return e-=t,e=hr(e,1/n,r),i!==void 0&&(e=hr(e,1/i,r)),e}function ti(e,t=0,n=1,r=.5,i,a=e,o=e){if(W.test(t)&&(t=parseFloat(t),t=J(o.min,o.max,t/100)-o.min),typeof t!=`number`)return;let s=J(a.min,a.max,r);e===a&&(s-=t),e.min=ei(e.min,t,n,s,i),e.max=ei(e.max,t,n,s,i)}function ni(e,t,[n,r,i],a,o){ti(e,t[n],t[r],t[i],t.scale,a,o)}function ri(e,t,n,r){ni(e.x,t,Md,n?n.x:void 0,r?r.x:void 0),ni(e.y,t,Nd,n?n.y:void 0,r?r.y:void 0)}function ii(e){return e.translate===0&&e.scale===1}function ai(e){return ii(e.x)&&ii(e.y)}function oi(e,t){return e.min===t.min&&e.max===t.max}function si(e,t){return oi(e.x,t.x)&&oi(e.y,t.y)}function ci(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function li(e,t){return ci(e.x,t.x)&&ci(e.y,t.y)}function ui(e){return A(e.x)/A(e.y)}function di(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function j(e){return[e(`x`),e(`y`)]}function fi(e,t,n){let r=``,i=e.x.translate/t.x,a=e.y.translate/t.y,o=n?.z||0;if((i||a||o)&&(r=`translate3d(${i}px, ${a}px, ${o}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){let{transformPerspective:e,rotate:t,rotateX:i,rotateY:a,skewX:o,skewY:s}=n;e&&(r=`perspective(${e}px) ${r}`),t&&(r+=`rotate(${t}deg) `),i&&(r+=`rotateX(${i}deg) `),a&&(r+=`rotateY(${a}deg) `),o&&(r+=`skewX(${o}deg) `),s&&(r+=`skewY(${s}deg) `)}let s=e.x.scale*t.x,c=e.y.scale*t.y;return(s!==1||c!==1)&&(r+=`scale(${s}, ${c})`),r||`none`}function pi(e,t,n,r,i,a){i?(e.opacity=J(0,n.opacity??1,Rd(r)),e.opacityExit=J(t.opacity??1,0,zd(r))):a&&(e.opacity=J(t.opacity??1,n.opacity??1,r));for(let i=0;irt?1:n(Bs(e,t,r))}function gi(e,t,n){let r=X(e)?e:D(e);return r.start(au(``,r,t,n)),r.animation}function _i(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function vi(e,t){let n=U.now(),r=({timestamp:i})=>{let a=i-n;a>=t&&(V(r),e(a-t))};return B.setup(r,!0),()=>V(r)}function yi(e){return X(e)?e.get():e}function bi(e,t,n,r){let{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function xi(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;let{visualElement:t}=e.options;if(!t)return;let n=fn(t);if(f.MotionHasOptimisedAnimation(n,`transform`)){let{layout:t,layoutId:r}=e.options;f.MotionCancelOptimisedAnimation(n,`transform`,B,!(t||r))}let{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&xi(r)}function Si({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(e={},n=t?.()){this.id=qd++,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,z.value&&(Wd.nodes=Wd.calculatedTargetDeltas=Wd.calculatedProjections=0),this.nodes.forEach(Ti),this.nodes.forEach(Pi),this.nodes.forEach(Fi),this.nodes.forEach(Ei),z.addProjectionMetrics&&z.addProjectionMetrics(Wd)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let e=0;ethis.root.updateBlockedByResize=!1;B.read(()=>{r=f.innerWidth}),e(t,()=>{let e=f.innerWidth;e!==r&&(r=e,this.root.updateBlockedByResize=!0,n&&n(),n=vi(i,250),Ud.hasAnimatedSinceResize&&(Ud.hasAnimatedSinceResize=!1,this.nodes.forEach(Ni)))})}n&&this.root.registerSharedNode(n,this),this.options.animate!==!1&&i&&(n||r)&&this.addEventListener(`didUpdate`,({delta:e,hasLayoutChanged:t,hasRelativeLayoutChanged:n,layout:r})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let a=this.options.transition||i.getDefaultTransition()||Jd,{onLayoutAnimationStart:o,onLayoutAnimationComplete:s}=i.getProps(),c=!this.targetLayout||!li(this.targetLayout,r),l=!t&&n;if(this.options.layoutRoot||this.resumeFrom||l||t&&(c||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);let t={...en(a,`layout`),onPlay:o,onComplete:s};(i.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t),this.setAnimationOrigin(e,l)}else t||Ni(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=r})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let e=this.getStack();e&&e.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),V(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(Ii),this.animationId++)}getTransformTemplate(){let{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(f.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&xi(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let e=0;e{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!A(this.snapshot.measuredBox.x)&&!A(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 e=0;e{let n=t/1e3;Ri(a.x,e.x,n),Ri(a.y,e.y,n),this.setTargetDelta(a),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&($r(o,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),Bi(this.relativeTarget,this.relativeTargetOrigin,o,n),d&&si(this.relativeTarget,d)&&(this.isProjectionDirty=!1),d||=Q(),k(d,this.relativeTarget)),s&&(this.animationValues=i,pi(i,r,this.latestValues,n,u,l)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=n},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(e){this.notifyListeners(`animationStart`),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&=(V(this.pendingAnimation),void 0),this.pendingAnimation=B.update(()=>{Ud.hasAnimatedSinceResize=!0,pc.layout++,this.motionValue||=D(0),this.motionValue.jump(0,!1),this.currentAnimation=gi(this.motionValue,[0,1e3],{...e,velocity:0,isSync:!0,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onStop:()=>{pc.layout--},onComplete:()=>{pc.layout--,e.onComplete&&e.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);let e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners(`animationComplete`)}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Kd),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let e=this.getLead(),{targetWithTransforms:t,target:n,layout:r,latestValues:i}=e;if(!(!t||!n||!r)){if(this!==e&&this.layout&&r&&Wi(this.options.animationType,this.layout.layoutBox,r.layoutBox)){n=this.target||Q();let t=A(this.layout.layoutBox.x);n.x.min=e.target.x.min,n.x.max=n.x.min+t;let r=A(this.layout.layoutBox.y);n.y.min=e.target.y.min,n.y.max=n.y.min+r}k(t,n),Sr(t,i),Yr(this.projectionDeltaWithTransform,this.layoutCorrected,t,i)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new Hd),this.sharedNodes.get(e).add(t);let n=t.options.initialPromotionConfig;t.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(t):void 0})}isLead(){let e=this.getStack();return e?e.lead===this:!0}getLead(){let{layoutId:e}=this.options;return e&&this.getStack()?.lead||this}getPrevLead(){let{layoutId:e}=this.options;return e?this.getStack()?.prevLead:void 0}getStack(){let{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){let r=this.getStack();r&&r.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){let e=this.getStack();return e?e.relegate(this):!1}resetSkewAndRotation(){let{visualElement:e}=this.options;if(!e)return;let t=!1,{latestValues:n}=e;if((n.z||n.rotate||n.rotateX||n.rotateY||n.rotateZ||n.skewX||n.skewY)&&(t=!0),!t)return;let r={};n.z&&bi(`z`,e,r,this.animationValues);for(let t=0;te.currentAnimation?.stop()),this.root.nodes.forEach(Oi),this.root.sharedNodes.clear()}}}function Ci(e){e.updateLayout()}function wi(e){let t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners(`didUpdate`)){let{layoutBox:n,measuredBox:r}=e.layout,{animationType:i}=e.options,a=t.source!==e.layout.source;if(i===`size`)j(e=>{let r=a?t.measuredBox[e]:t.layoutBox[e],i=A(r);r.min=n[e].min,r.max=r.min+i});else if(i===`x`||i===`y`){let e=i===`x`?`y`:`x`;Gr(a?t.measuredBox[e]:t.layoutBox[e],n[e])}else Wi(i,t.layoutBox,n)&&j(r=>{let i=a?t.measuredBox[r]:t.layoutBox[r],o=A(n[r]);i.max=i.min+o,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[r].max=e.relativeTarget[r].min+o)});let o=Yu();Yr(o,n,t.layoutBox);let s=Yu();a?Yr(s,e.applyTransform(r,!0),t.measuredBox):Yr(s,n,t.layoutBox);let c=!ai(o),l=!1;if(!e.resumeFrom){let r=e.getClosestProjectingParent();if(r&&!r.resumeFrom){let{snapshot:i,layout:a}=r;if(i&&a){let o=e.options.layoutAnchor||void 0,s=Q();$r(s,t.layoutBox,i.layoutBox,o);let c=Q();$r(c,n,a.layoutBox,o),li(s,c)||(l=!0),r.options.layoutRoot&&(e.relativeTarget=c,e.relativeTargetOrigin=s,e.relativeParent=r)}}}e.notifyListeners(`didUpdate`,{layout:n,snapshot:t,delta:s,layoutDelta:o,hasLayoutChanged:c,hasRelativeLayoutChanged:l})}else if(e.isLead()){let{onExitComplete:t}=e.options;t&&t()}e.options.transition=void 0}function Ti(e){z.value&&Wd.nodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty),e.isTransformDirty||=e.parent.isTransformDirty)}function Ei(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Di(e){e.clearSnapshot()}function Oi(e){e.clearMeasurements()}function ki(e){e.isLayoutDirty=!0,e.updateLayout()}function Ai(e){e.isLayoutDirty=!1}function ji(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.layout,e.isLayoutDirty=!0)}function Mi(e){let{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify(`BeforeLayoutMeasure`),e.resetTransform()}function Ni(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Pi(e){e.resolveTargetDelta()}function Fi(e){e.calcProjection()}function Ii(e){e.resetSkewAndRotation()}function Li(e){e.removeLeadSnapshot()}function Ri(e,t,n){e.translate=J(t.translate,0,n),e.scale=J(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function zi(e,t,n,r){e.min=J(t.min,n.min,r),e.max=J(t.max,n.max,r)}function Bi(e,t,n,r){zi(e.x,t.x,n.x,r),zi(e.y,t.y,n.y,r)}function Vi(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}function Hi(e){e.min=Xd(e.min),e.max=Xd(e.max)}function Ui(e){Hi(e.x),Hi(e.y)}function Wi(e,t,n){return e===`position`||e===`preserve-aspect`&&!qr(ui(t),ui(n),.2)}function Gi(e){return e!==e.root&&e.scroll?.wasRoot}function Ki(){let e=new Set,t=new WeakMap,n=()=>e.forEach(Qd);return{add:r=>{e.add(r),t.set(r,r.addEventListener(`willUpdate`,n))},remove:r=>{e.delete(r);let i=t.get(r);i&&(i(),t.delete(r)),n()},dirty:n}}function qi(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}function Ji(...e){return t=>{let n=!1,r=e.map(e=>{let r=qi(e,t);return!n&&typeof r==`function`&&(n=!0),r});if(n)return()=>{for(let t=0;t{let{width:e,height:r,top:i,left:u,right:p,bottom:m}=d.current;if(t||s===!1||!l.current||!e||!r)return;let h=n===`left`?`left: ${u}`:`right: ${p}`,g=a===`bottom`?`bottom: ${m}`:`top: ${i}`;l.current.dataset.motionPopId=c;let _=document.createElement(`style`);f&&(_.nonce=f);let v=o??document.head;return v.appendChild(_),_.sheet&&_.sheet.insertRule(` [data-motion-pop-id="${c}"] { position: absolute !important; width: ${e}px !important; height: ${r}px !important; ${h}px !important; ${g}px !important; } `),()=>{l.current?.removeAttribute(`data-motion-pop-id`),v.contains(_)&&v.removeChild(_)}},[t]),g(tf,{isPresent:t,childRef:l,sizeRef:d,pop:s,children:s===!1?e:u(e,{ref:p})})}function M(e){let t=i(null);return t.current===null&&(t.current=e()),t.current}function Zi(){return new Map}function Qi(e=!0){let t=b(Ps);if(t===null)return[!0,null];let{isPresent:n,onExitComplete:r,register:i}=t,a=T();c(()=>{if(e)return i(a)},[e]);let o=y(()=>e&&r&&r(a),[a,r,e]);return!n&&r?[!1,o]:[!0]}function $i(e){let t=[];return m.forEach(e,e=>{v(e)&&t.push(e)}),t}function ea(){let e=i(!1);return Ns(()=>(e.current=!0,()=>{e.current=!1}),[]),e}function ta(){let e=ea(),[t,n]=d(0),r=y(()=>{e.current&&n(t+1)},[t]);return[y(()=>B.postRender(r),[r]),t]}function na(){if(ff)return;let e={};for(let t in df)e[t]={isEnabled:e=>df[t].some(t=>!!e[t])};ar(e),ff=!0}function ra(){return na(),or()}function ia(e){let t=ra();for(let n in e)t[n]={...t[n],...e[n]};ar(t)}function aa(e){return e.startsWith(`while`)||e.startsWith(`drag`)&&e!==`draggable`||e.startsWith(`layout`)||e.startsWith(`onTap`)||e.startsWith(`onPan`)||e.startsWith(`onLayout`)||pf.has(e)}function oa(e){typeof e==`function`&&(mf=t=>t.startsWith(`on`)?!aa(t):e(t))}function sa(e,t,n){let r={};for(let i in e)i===`values`&&typeof e.values==`object`||X(e[i])||(mf(i)||n===!0&&aa(i)||!t&&!aa(i)||e.draggable&&i.startsWith(`onDrag`))&&(r[i]=e[i]);return r}function ca({children:e,isValidProp:t,...r}){t&&oa(t);let i=b($);r={...i,...r},r.transition=$t(r.transition,i.transition),r.isStatic=M(()=>r.isStatic);let a=n(()=>r,[JSON.stringify(r.transition),r.transformPagePoint,r.reducedMotion,r.skipAnimations]);return g($.Provider,{value:a,children:e})}function la({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,i){return{latestValues:ua(n,r,i,e),renderState:t()}}function ua(e,t,n,r){let i={},a=r(e,{});for(let e in a)i[e]=yi(a[e]);let{initial:o,animate:s}=e,c=tr(e),l=nr(e);t&&l&&!c&&e.inherit!==!1&&(o===void 0&&(o=t.initial),s===void 0&&(s=t.animate));let u=n?n.initial===!1:!1;u||=o===!1;let d=u?s:o;if(d&&typeof d!=`boolean`&&!$n(d)){let t=Array.isArray(d)?d:[d];for(let n=0;n({initial:t,animate:r}),[pa(t),pa(r)])}function pa(e){return Array.isArray(e)?e.join(` `):e}function ma(e,t,n){for(let r in t)!X(t[r])&&!Ar(r,n)&&(e[r]=t[r])}function ha({transformTemplate:e},t){return n(()=>{let n=vf();return Er(n,t,e),Object.assign({},n.vars,n.style)},[t])}function ga(e,t){let n=e.style||{},r={};return ma(r,n,e),Object.assign(r,ha(e,t)),r}function _a(e,t){let n={},r=ga(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout=`none`,r.touchAction=e.drag===!0?`none`:`pan-${e.drag===`x`?`y`:`x`}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}function va(e,t,r,i){let a=n(()=>{let n=yf();return Fr(n,t,xd(i),e.transformTemplate,e.style),{...n.attrs,style:{...n.style}}},[t]);if(e.style){let t={};ma(t,e.style,e),a.style={...t,...a.style}}return a}function ya(e){return typeof e!=`string`||e.includes(`-`)?!1:!!(bf.indexOf(e)>-1||/[A-Z]/u.test(e))}function ba(e,t,r,{latestValues:i},a,o=!1,s){let c=(s??ya(e)?va:_a)(t,i,a,e),u=sa(t,typeof e==`string`,o),d=e===l?{}:{...u,...c,ref:r},{children:f}=t,p=n(()=>X(f)?f.get():f,[f]);return w(e,{...d,children:p})}function xa(e,t,n){let a=i(n);r(()=>{a.current=n});let o=i(null);return y(n=>{n&&e.onMount?.(n);let r=a.current;if(typeof r==`function`)if(n){let e=r(n);typeof e==`function`&&(o.current=e)}else o.current?(o.current(),o.current=null):r(n);else r&&(r.current=n);t&&(n?t.mount(n):t.unmount())},[t])}function Sa(e){return e&&typeof e==`object`&&Object.prototype.hasOwnProperty.call(e,`current`)}function Ca(e,t,n,a,o,s){let{visualElement:l}=b(hf),u=b(uf),d=b(Ps),p=b($),m=p.reducedMotion,h=p.skipAnimations,g=i(null),_=i(!1);a||=u.renderer,!g.current&&a&&(g.current=a(e,{visualState:t,parent:l,props:n,presenceContext:d,blockInitialAnimation:d?d.initial===!1:!1,reducedMotionConfig:m,skipAnimations:h,isSVG:s}),_.current&&g.current&&(g.current.manuallyAnimateOnMount=!0));let v=g.current,y=b(_f);v&&!v.projection&&o&&(v.type===`html`||v.type===`svg`)&&wa(g.current,n,o,y);let x=i(!1);r(()=>{v&&x.current&&v.update(n,d)});let S=n[pu],C=i(!!S&&f!==void 0&&!f.MotionHandoffIsComplete?.(S)&&f.MotionHasOptimisedAnimation?.(S));return Ns(()=>{_.current=!0,v&&(x.current=!0,f.MotionIsMounted=!0,v.updateFeatures(),v.scheduleRenderMicrotask(),C.current&&v.animationState&&v.animationState.animateChanges())}),c(()=>{v&&(!C.current&&v.animationState&&v.animationState.animateChanges(),C.current&&=(queueMicrotask(()=>{f.MotionHandoffMarkAsComplete?.(S)}),!1),v.enteringChildren=void 0)}),v}function wa(e,t,n,r){let{layoutId:i,layout:a,drag:o,dragConstraints:s,layoutScroll:c,layoutRoot:l,layoutAnchor:u,layoutCrossfade:d}=t;e.projection=new n(e.latestValues,t[`data-framer-portal-id`]?void 0:Ta(e.parent)),e.projection.setOptions({layoutId:i,layout:a,alwaysMeasureLayout:!!o||s&&Sa(s),visualElement:e,animationType:typeof a==`string`?a:`both`,initialPromotionConfig:r,crossfade:d,layoutScroll:c,layoutRoot:l,layoutAnchor:u})}function Ta(e){if(e)return e.options.allowProjection===!1?Ta(e.parent):e.projection}function Ea(e,{forwardMotionProps:t=!1,type:n}={},r,i){r&&ia(r);let a=n?n===`svg`:ya(e),o=a?Sf:xf;function s(n,s){let c,l={...b($),...n,layoutId:Da(n)},{isStatic:u}=l,d=fa(n),p=o(n,u);if(!u&&f!==void 0){Oa(l,r);let t=ka(l);c=t.MeasureLayout,d.visualElement=Ca(e,p,l,i,t.ProjectionNode,a)}return x(hf.Provider,{value:d,children:[c&&d.visualElement?g(c,{visualElement:d.visualElement,...l}):null,ba(e,n,xa(p,d.visualElement,s),p,u,t,a)]})}s.displayName=`motion.${typeof e==`string`?e:`create(${e.displayName??e.name??``})`}`;let c=h(s);return c[Cf]=e,c}function Da({layoutId:e}){let t=b(js).id;return t&&e!==void 0?t+`-`+e:e}function Oa(e,t){b(uf).strict}function ka(e){let{drag:t,layout:n}=ra();if(!t&&!n)return{};let r={...t,...n};return{MeasureLayout:t?.isEnabled(e)||n?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function Aa(e,t){if(typeof Proxy>`u`)return Ea;let n=new Map,r=(n,r)=>Ea(n,r,e,t);return new Proxy((e,t)=>r(e,t),{get:(i,a)=>a===`create`?r:(n.has(a)||n.set(a,Ea(a,void 0,e,t)),n.get(a))})}function ja(e){return{point:{x:e.pageX,y:e.pageY}}}function Ma(e,t,n,r){return _i(e,t,Of(n),r)}function Na(e,t){let n=kf(e.x,t.x),r=kf(e.y,t.y);return Math.sqrt(n**2+r**2)}function Pa(e,t){return t?{point:t(e.point)}:e}function Fa(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Ia({point:e},t){return{point:e,delta:Fa(e,Ra(t)),offset:Fa(e,La(t)),velocity:za(t,.1)}}function La(e){return e[0]}function Ra(e){return e[e.length-1]}function za(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null,i=Ra(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>L(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&i.timestamp-r.timestamp>L(t)*2&&(r=e[1]);let a=R(i.timestamp-r.timestamp);if(a===0)return{x:0,y:0};let o={x:(i.x-r.x)/a,y:(i.y-r.y)/a};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}function Ba(e,{min:t,max:n},r){return t!==void 0&&en&&(e=r?J(n,e,r.max):Math.min(e,n)),e}function Va(e,t,n){return{min:t===void 0?void 0:e.min+t,max:n===void 0?void 0:e.max+n-(e.max-e.min)}}function Ha(e,{top:t,left:n,bottom:r,right:i}){return{x:Va(e.x,n,i),y:Va(e.y,t,r)}}function Ua(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.minr?n=Bs(t.min,t.max-r,e.min):r>i&&(n=Bs(e.min,e.max-i,t.min)),N(0,1,n)}function Ka(e,t){let n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}function qa(e=Pf){return e===!1?e=0:e===!0&&(e=Pf),{x:Ja(e,`left`,`right`),y:Ja(e,`top`,`bottom`)}}function Ja(e,t,n){return{min:Ya(e,t),max:Ya(e,n)}}function Ya(e,t){return typeof e==`number`?e:e[t]||0}function Xa(e){let t=!0;return()=>{if(t){t=!1;return}e()}}function Za(e,t,n){let r=Hn(e,Xa(n)),i=Hn(t,Xa(n));return()=>{r(),i()}}function Qa(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function $a(e,t=10){let n=null;return Math.abs(e.y)>t?n=`y`:Math.abs(e.x)>t&&(n=`x`),n}function eo(e){let[t,n]=Qi(),r=b(js);return g(Vf,{...e,layoutGroup:r,switchLayoutGroup:b(_f),isPresent:t,safeToRemove:n})}function to(e,t,n){let{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive(`whileHover`,n===`Start`);let i=r[`onHover`+n];i&&B.postRender(()=>i(t,ja(t)))}function no(e,t,n){let{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive(`whileTap`,n===`Start`);let i=r[`onTap`+(n===`End`?``:n)];i&&B.postRender(()=>i(t,ja(t)))}function ro({root:e,...t}){let n=e||document;qf.has(n)||qf.set(n,{});let r=qf.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(Yf,{root:e,...t})),r[i]}function io(e,t,n){let r=ro(t);return Kf.set(e,n),r.observe(e),()=>{Kf.delete(e),r.unobserve(e)}}function ao({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}function oo(e,t,n,r){let i=n[t],{length:a,position:o}=ap[t],s=i.current,c=n.time;i.current=Math.abs(e[`scroll${o}`]),i.scrollLength=e[`scroll${a}`]-e[`client${a}`],i.offset.length=0,i.offset[0]=0,i.offset[1]=i.scrollLength,i.progress=Bs(0,i.scrollLength,i.current);let l=r-c;i.velocity=l>np?0:Fe(i.current-s,l)}function so(e,t,n){oo(e,`x`,t,n),oo(e,`y`,t,n),t.time=n}function co(e,t){let n={x:0,y:0},r=e;for(;r&&r!==t;)if(Cn(r))n.x+=r.offsetLeft,n.y+=r.offsetTop,r=r.offsetParent;else if(r.tagName===`svg`){let e=r.getBoundingClientRect();r=r.parentElement;let t=r.getBoundingClientRect();n.x+=e.left-t.left,n.y+=e.top-t.top}else if(r instanceof SVGGraphicsElement){let{x:e,y:t}=r.getBBox();n.x+=e,n.y+=t;let i=null,a=r.parentNode;for(;!i;)a.tagName===`svg`&&(i=a),a=r.parentNode;r=i}else break;return n}function lo(e,t,n=0){let r=0;if(e in op&&(e=op[e]),typeof e==`string`){let t=parseFloat(e);e.endsWith(`px`)?r=t:e.endsWith(`%`)?e=t/100:e.endsWith(`vw`)?r=t/100*document.documentElement.clientWidth:e.endsWith(`vh`)?r=t/100*document.documentElement.clientHeight:e=t}return typeof e==`number`&&(r=t*e),n+r}function uo(e,t,n,r){let i=Array.isArray(e)?e:sp,a=0,o=0;return typeof e==`number`?i=[e,e]:typeof e==`string`&&(e=e.trim(),i=e.includes(` `)?e.split(` `):[e,op[e]?e:`0`]),a=lo(i[0],n,r),o=lo(i[1],t),a-o}function fo(e){return`getBBox`in e&&e.tagName!==`svg`?e.getBBox():{width:e.clientWidth,height:e.clientHeight}}function po(e,t,n){let{offset:r=cp.All}=n,{target:i=e,axis:a=`y`}=n,o=a===`y`?`height`:`width`,s=i===e?lp:co(i,e),c=i===e?{width:e.scrollWidth,height:e.scrollHeight}:fo(i),l={width:e.clientWidth,height:e.clientHeight};t[a].offset.length=0;let u=!t[a].interpolate,d=r.length;for(let e=0;e{mo(e,r.target,n),so(e,n,t),(r.offset||r.target)&&po(e,n,r)},notify:()=>t(n)}}function go(e,{container:t=document.scrollingElement,trackContentSize:n=!1,...r}={}){if(!t)return I;let i=fp.get(t);i||(i=new Set,fp.set(t,i));let a=ho(t,e,ip(),r);if(i.add(a),!up.has(t)){let e=()=>{for(let e of i)e.measure(H.timestamp);B.preUpdate(n)},n=()=>{for(let e of i)e.notify()},r=()=>B.read(e);up.set(t,r);let a=hp(t);f.addEventListener(`resize`,r),t!==document.documentElement&&dp.set(t,Hn(t,r)),a.addEventListener(`scroll`,r),r()}if(n&&!mp.has(t)){let e=up.get(t),n={width:t.scrollWidth,height:t.scrollHeight};pp.set(t,n);let r=B.read(()=>{let r=t.scrollWidth,i=t.scrollHeight;(n.width!==r||n.height!==i)&&(e(),n.width=r,n.height=i)},!0);mp.set(t,r)}let o=up.get(t);return B.read(o,!1,!0),()=>{V(o);let e=fp.get(t);if(!e||(e.delete(a),e.size))return;let n=up.get(t);up.delete(t),n&&(hp(t).removeEventListener(`scroll`,n),dp.get(t)?.(),f.removeEventListener(`resize`,n));let r=mp.get(t);r&&(V(r),mp.delete(t)),pp.delete(t)}}function _o(e){return f===void 0?!1:e?Pl():Nl()}function vo(e){let t=e.trim().split(/\s+/);if(t.length!==2)return;let n=_p[t[0]],r=_p[t[1]];if(!(n===void 0||r===void 0))return[n,r]}function yo(e){if(e.length!==2)return;let t=[];for(let n of e)if(Array.isArray(n))t.push(n);else if(typeof n==`string`){let e=vo(n);if(!e)return;t.push(e)}else return;return t}function bo(e,t){let n=yo(e);if(!n)return!1;for(let e=0;e<2;e++){let r=n[e],i=t[e];if(r[0]!==i[0]||r[1]!==i[1])return!1}return!0}function xo(e){if(!e)return{rangeStart:`contain 0%`,rangeEnd:`contain 100%`};for(let[t,n]of gp)if(bo(e,t))return{rangeStart:`${n} 0%`,rangeEnd:`${n} 100%`}}function So(e){let t={value:0};return{currentTime:t,cancel:go(n=>{t.value=n[e.axis].progress*100},e)}}function Co({source:e,container:t,...n}){let{axis:r}=n;e&&(t=e);let i=vp.get(t);i||(i=new Map,vp.set(t,i));let a=n.target??`self`,o=i.get(a);o||(o={},i.set(a,o));let s=r+(n.offset??[]).join(`,`);return o[s]||(n.target&&_o(n.target)?xo(n.offset)?o[s]=new ViewTimeline({subject:n.target,axis:r}):o[s]=So({container:t,...n}):_o()?o[s]=new ScrollTimeline({source:t,axis:r}):o[s]=So({container:t,...n})),o[s]}function wo(e,t){let n=Co(t),r=t.target?xo(t.offset):void 0,i=t.target?_o(t.target)&&!!r:_o();return e.attachTimeline({timeline:i?n:void 0,...r&&i&&{rangeStart:r.rangeStart,rangeEnd:r.rangeEnd},observe:e=>(e.pause(),Un(t=>{e.time=e.iterationDuration*t},n))})}function To(e){return e.length===2}function Eo(e,t){return To(e)?go(n=>{e(n[t.axis].progress,n)},t):Un(e,Co(t))}function Do(e,{axis:t=`y`,container:n=document.scrollingElement,...r}={}){if(!n)return I;let i={axis:t,container:n,...r};return typeof e==`function`?Eo(e,i):wo(e,i)}function Oo(e,t,n,r){return{factory:i=>Do(i,{...t,axis:e,container:n?.current||void 0,target:r?.current||void 0}),times:[0,1],keyframes:[0,1],ease:e=>e,duration:1}}function ko(e,t){return f===void 0?!1:e?Pl()&&!!xo(t):Nl()}function Ao({container:e,target:t,...n}={}){let r=M(yp);ko(t,n.offset)&&(r.scrollXProgress.accelerate=Oo(`x`,n,e,t),r.scrollYProgress.accelerate=Oo(`y`,n,e,t));let a=i(null),o=i(!1),s=y(()=>(a.current=Do((e,{x:t,y:n})=>{r.scrollX.set(t.current),r.scrollXProgress.set(t.progress),r.scrollY.set(n.current),r.scrollYProgress.set(n.progress)},{...n,container:e?.current||void 0,target:t?.current||void 0}),()=>{a.current?.()}),[e,t,JSON.stringify(n.offset)]);return Ns(()=>{if(o.current=!1,bp(e)||bp(t)){o.current=!0;return}else return s()},[s]),c(()=>{if(o.current)return P(!bp(e),`Container ref is defined but not hydrated`,`use-scroll-ref`),P(!bp(t),`Target ref is defined but not hydrated`,`use-scroll-ref`),s()},[s]),r}function jo(e){let t=M(()=>D(e)),{isStatic:n}=b($);if(n){let[,n]=d(e);c(()=>t.on(`change`,n),[])}return t}function Mo(e,t){let n=jo(t()),r=()=>n.set(t());return r(),Ns(()=>{let t=()=>B.preRender(r,!1,!0),n=e.map(e=>e.on(`change`,t));return()=>{n.forEach(e=>e()),V(r)}}),n}function No(e){lu.current=[],e();let t=Mo(lu.current,e);return lu.current=void 0,t}function Po(e,t,n,r){if(typeof e==`function`)return No(e);if(n!==void 0&&!Array.isArray(n)&&typeof t!=`function`)return Io(e,t,n,r);let i=typeof t==`function`?t:qn(t,n,r),a=Array.isArray(e)?Fo(e,i):Fo([e],([e])=>i(e)),o=Array.isArray(e)?void 0:e.accelerate;return o&&!o.isTransformed&&typeof t!=`function`&&Array.isArray(n)&&r?.clamp!==!1&&(a.accelerate={...o,times:t,keyframes:n,isTransformed:!0,...r?.ease?{ease:r.ease}:{}}),a}function Fo(e,t){let n=M(()=>[]);return Mo(e,()=>{n.length=0;let r=e.length;for(let t=0;tObject.keys(n)),a=M(()=>({}));for(let o of i)a[o]=Po(e,t,n[o],r);return a}function Lo(e,t={}){let{isStatic:n}=b($),i=()=>X(e)?e.get():e;if(n)return Po(i);let a=jo(i());return r(()=>Jn(a,e,t),[a,JSON.stringify(t)]),a}function Ro(e,t={}){return Lo(e,{type:`spring`,...t})}function zo(e){let t=i(0),{isStatic:n}=b($);c(()=>{if(n)return;let r=({timestamp:n,delta:r})=>{t.current||=n,e(n-t.current,r)};return B.update(r,!0),()=>V(r)},[e])}function Bo(){!td.current&&ir();let[e]=d(ed.current);return e}function Vo(){let e=Bo(),{reducedMotion:t}=b($);return t===`never`?!1:t===`always`?!0:e}function Ho(e){e.values.forEach(e=>e.stop())}function Uo(e,t){[...t].reverse().forEach(n=>{let r=e.getVariant(n);r&&cn(e,r),e.variantChildren&&e.variantChildren.forEach(e=>{Uo(e,t)})})}function Wo(e,t){if(Array.isArray(t))return Uo(e,t);if(typeof t==`string`)return Uo(e,[t]);cn(e,t)}function Go(){let e=!1,t=new Set,n={subscribe(e){return t.add(e),()=>void t.delete(e)},start(n,r){P(e,`controls.start() should only be called after a component has mounted. Consider calling within a useEffect hook.`);let i=[];return t.forEach(e=>{i.push(_n(e,n,{transitionOverride:r}))}),Promise.all(i)},set(n){return P(e,`controls.set() should only be called after a component has mounted. Consider calling within a useEffect hook.`),t.forEach(e=>{Wo(e,n)})},stop(){t.forEach(e=>{Ho(e)})},mount(){return e=!0,()=>{e=!1,n.stop()}}};return n}function Ko(e){return typeof e==`object`&&!Array.isArray(e)}function qo(e,t,n,r){return e==null?[]:typeof e==`string`&&Ko(t)?Sn(e,n,r):e instanceof NodeList?Array.from(e):Array.isArray(e)?e.filter(e=>e!=null):[e]}function Jo(e,t,n){return e*(t+1)}function Yo(e,t,n,r){return typeof t==`number`?t:t.startsWith(`-`)||t.startsWith(`+`)?Math.max(0,e+parseFloat(t)):t===`<`?n:t.startsWith(`<`)?Math.max(0,n+parseFloat(t.slice(1))):r.get(t)??e}function Xo(e,t,n){for(let r=0;rt&&i.at{let c=rs(e),{delay:l=0,times:u=xt(c),type:p=t.type||`keyframes`,repeat:m,repeatType:h,repeatDelay:_=0,...v}=n,{ease:y=t.ease||`easeOut`,duration:b}=n,x=typeof l==`function`?l(o,s):l,S=c.length,C=Bt(p)?p:i?.[p||`keyframes`];if(S<=2&&C){let e=100;if(S===2&&Tp(c)){let t=c[1]-c[0];e=Math.abs(t)}let n={...t,...v};b!==void 0&&(n.duration=L(b));let r=lt(n,e,C);y=r.ease,b=r.duration}b??=a;let w=d+x;u.length===1&&u[0]===0&&(u[1]=1);let ee=u.length-c.length;if(ee>0&&bt(u,ee),c.length===1&&c.unshift(null),m){P(m{for(let i in e){let a=e[i];a.sort($o);let s=[],c=[],l=[];for(let e=0;e{if(Array.isArray(e)&&typeof e[0]==`function`){let t=e[0],n=D(0);return n.on(`change`,t),e.length===1?[n,[0,1]]:e.length===2?[n,[0,1],e[1]]:[n,e[1],e[2]]}return e}),t,n,{spring:ht}).forEach(({keyframes:e,transition:t},n)=>{r.push(...cs(n,e,t))}),r}function us(e){return Array.isArray(e)&&e.some(Array.isArray)}function ds(e={}){let{scope:t,reduceMotion:n}=e;function r(e,r,i){let a=[],o;if(us(e)){let{onComplete:i,...s}=r||{};typeof i==`function`&&(o=i),a=ls(e,n===void 0?s:{reduceMotion:n,...s},t)}else{let{onComplete:s,...c}=i||{};typeof s==`function`&&(o=s),a=cs(e,r,n===void 0?c:{reduceMotion:n,...c},t)}let s=new Xl(a);return o&&s.finished.then(o),t&&(t.animations.push(s),s.finished.then(()=>{je(t.animations,s)})),s}return r}function fs(){let e=M(Go);return Ns(e.mount,[]),e}function ps(e){return typeof e==`object`&&!!e&&Cf in e}function ms(e){if(ps(e))return e[Cf]}function hs(){return gs}function gs(e){$d.current&&($d.current.isUpdating=!1,$d.current.blockUpdate(),e&&e())}function _s(){return y(()=>{let e=$d.current;e&&e.resetTree()},[])}function vs(e,t,{root:n,margin:r,amount:i=`some`}={}){let a=Sn(e),o=new WeakMap,s=new IntersectionObserver(e=>{e.forEach(e=>{let n=o.get(e.target);if(e.isIntersecting!==!!n)if(e.isIntersecting){let n=t(e.target,e);typeof n==`function`?o.set(e.target,n):s.unobserve(e.target)}else typeof n==`function`&&(n(e),o.delete(e.target))})},{root:n,rootMargin:r,threshold:typeof i==`number`?i:Op[i]});return a.forEach(e=>s.observe(e)),()=>s.disconnect()}function ys(e,{root:t,margin:n,amount:r,once:i=!1,initial:a=!1}={}){let[o,s]=d(a);return c(()=>{if(!e.current||i&&o)return;let a=()=>(s(!0),i?void 0:()=>s(!1)),c={root:t&&t.current||void 0,margin:n,amount:r};return vs(e.current,a,c)},[t,e,n,i,r]),o}function bs(){let[e,t]=ta(),n=hs(),r=i(-1);return c(()=>{B.postRender(()=>B.postRender(()=>{t===r.current&&(F.instantAnimations=!1)}))},[t]),i=>{n(()=>{F.instantAnimations=!0,e(),i(),r.current=t+1})}}function xs(e,t,n,r){if(!r)return e;let i=e.findIndex(e=>e.value===t);if(i===-1)return e;let a=r>0?1:-1,o=e[i+a];if(!o)return e;let s=e[i],c=o.layout,l=J(c.min,c.max,.5);return a===1&&s.layout.max+n>l||a===-1&&s.layout.min+nep[t]),u=[],d=i(!1),f=i(null);P(!!a,`Reorder.Group must be provided a values prop`,`reorder-values`);let p={axis:n,groupRef:f,registerItem:(e,t)=>{let r=u.findIndex(t=>e===t.value);r===-1?u.push({value:e,layout:t[n]}):u[r].layout=t[n],u.sort(Cs)},updateOrder:(e,t,n)=>{if(d.current)return;let i=xs(u,e,t,n);if(u!==i){d.current=!0;let e=[...a];for(let t=0;t{d.current=!1});let m=e=>{f.current=e,typeof s==`function`?s(e):s&&(s.current=e)},h={overflowAnchor:`none`,...o.style};return g(l,{...o,style:h,ref:m,ignoreStrict:!0,children:g(jp.Provider,{value:p,children:e})})}function Cs(e,t){return e.layout.min-t.layout.min}function ws(){if(Rp){let e=Es(Rp,`y`);e&&(Lp.delete(e),Ip.delete(e));let t=Es(Rp,`x`);t&&t!==e&&(Lp.delete(t),Ip.delete(t)),Rp=null}}function Ts(e,t){let n=getComputedStyle(e),r=t===`x`?n.overflowX:n.overflowY,i=e===document.body||e===document.documentElement;return Fp.has(r)||i}function Es(e,t){let n=e?.parentElement;for(;n;){if(Ts(n,t))return n;n=n.parentElement}return null}function Ds(e,t,n){let r=t.getBoundingClientRect(),i=n===`x`?Math.max(0,r.left):Math.max(0,r.top),a=n===`x`?Math.min(f.innerWidth,r.right):Math.min(f.innerHeight,r.bottom),o=e-i,s=a-e;if(o0))return;Lp.set(i,o);let e=n===`x`?i.scrollWidth-(c?f.innerWidth:i.clientWidth):i.scrollHeight-(c?f.innerHeight:i.clientHeight);Ip.set(i,e)}if(a>0){let e=Ip.get(i);if((n===`x`?c?f.scrollX:i.scrollLeft:c?f.scrollY:i.scrollTop)>=e)return}n===`x`?c?f.scrollBy({left:a}):i.scrollLeft+=a:c?f.scrollBy({top:a}):i.scrollTop+=a}function ks(e,t=0){return X(e)?e:jo(t)}function As({children:e,style:t={},value:n,as:r=`li`,onDrag:i,onDragEnd:a,layout:o=!0,...s},c){let l=M(()=>ep[r]),u=b(jp),d={x:ks(t.x),y:ks(t.y)},f=Po([d.x,d.y],([e,t])=>e||t?1:`unset`);P(!!u,`Reorder.Item must be a child of Reorder.Group`,`reorder-item-child`);let{axis:p,registerItem:m,updateOrder:h,groupRef:_}=u;return g(l,{drag:p,...s,dragSnapToOrigin:!0,style:{...t,x:d.x,y:d.y,zIndex:f},layout:o,onDrag:(e,t)=>{let{velocity:r,point:a}=t;h(n,d[p].get(),r[p]),Os(_.current,a[p],p,r[p]),i&&i(e,t)},onDragEnd:(e,t)=>{ws(),a&&a(e,t)},onLayoutMeasure:e=>{m(n,e)},ref:c,ignoreStrict:!0,children:e})}var js,Ms,Ns,Ps,N,Fs,P,F,Is,Ls,I,Rs,zs,Bs,Vs,L,R,Hs,Us,Ws,Gs,Ks,qs,Js,Ys,Xs,Zs,Qs,$s,ec,tc,nc,rc,ic,ac,oc,sc,cc,z,lc,uc,B,V,H,dc,fc,U,pc,mc,hc,gc,_c,vc,yc,bc,xc,Sc,Cc,wc,Tc,Ec,Dc,Oc,kc,Ac,jc,Mc,W,G,Nc,Pc,Fc,Ic,K,Lc,Rc,zc,Bc,Vc,Hc,Uc,Wc,Gc,q,J,Kc,qc,Jc,Yc,Xc,Zc,Qc,$c,Y,el,tl,nl,rl,il,al,ol,sl,cl,ll,ul,dl,fl,pl,ml,hl,gl,_l,vl,yl,bl,xl,Sl,Cl,wl,Tl,El,Dl,Ol,kl,Al,jl,Ml,Nl,Pl,Fl,Il,Ll,Rl,zl,Bl,Vl,Hl,Ul,Wl,Gl,Kl,ql,Jl,Yl,Xl,Zl,Ql,$l,eu,tu,nu,ru,iu,au,ou,su,cu,lu,uu,du,X,fu,pu,mu,hu,gu,_u,vu,yu,bu,xu,Su,Cu,wu,Tu,Eu,Du,Ou,ku,Au,ju,Z,Mu,Nu,Pu,Fu,Iu,Lu,Ru,zu,Bu,Vu,Hu,Uu,Wu,Gu,Ku,qu,Ju,Yu,Xu,Q,Zu,Qu,$u,ed,td,nd,rd,id,ad,od,sd,cd,ld,ud,dd,fd,pd,md,hd,gd,_d,vd,yd,bd,xd,Sd,Cd,wd,Td,Ed,Dd,Od,kd,Ad,jd,Md,Nd,Pd,Fd,Id,Ld,Rd,zd,Bd,Vd,Hd,Ud,Wd,Gd,Kd,qd,Jd,Yd,Xd,Zd,Qd,$d,ef,$,tf,nf,rf,af,of,sf,cf,lf,uf,df,ff,pf,mf,hf,gf,_f,vf,yf,bf,xf,Sf,Cf,wf,Tf,Ef,Df,Of,kf,Af,jf,Mf,Nf,Pf,Ff,If,Lf,Rf,zf,Bf,Vf,Hf,Uf,Wf,Gf,Kf,qf,Jf,Yf,Xf,Zf,Qf,$f,ep,tp,np,rp,ip,ap,op,sp,cp,lp,up,dp,fp,pp,mp,hp,gp,_p,vp,yp,bp,xp,Sp,Cp,wp,Tp,Ep,Dp,Op,kp,Ap,jp,Mp,Np,Pp,Fp,Ip,Lp,Rp,zp,Bp=t((()=>{o(),ke(),ee(),S(),js=a({}),Ms=f!==void 0,Ns=Ms?p:c,Ps=a(null),N=(e,t,n)=>n>t?t:n{},P=()=>{},F={},Is=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),Ls=e=>/^0[^.\s]+$/u.test(e),I=e=>e,Rs=(e,t)=>n=>t(e(n)),zs=(...e)=>e.reduce(Rs),Bs=(e,t,n)=>{let r=t-e;return r===0?1:(n-e)/r},Vs=class{constructor(){this.subscriptions=[]}add(e){return Ae(this.subscriptions,e),()=>je(this.subscriptions,e)}notify(e,t,n){let r=this.subscriptions.length;if(r)if(r===1)this.subscriptions[0](e,t,n);else for(let i=0;ie*1e3,R=e=>e/1e3,Hs=(e,t,n)=>{let r=t-e;return((n-e)%r+r)%r+e},Us=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Ws=1e-7,Gs=12,Ks=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,qs=e=>t=>1-e(1-t),Js=Le(.33,1.53,.69,.99),Ys=qs(Js),Xs=Ks(Ys),Zs=e=>e>=1?1:(e*=2)<1?.5*Ys(e):.5*(2-2**(-10*(e-1))),Qs=e=>1-Math.sin(Math.acos(e)),$s=qs(Qs),ec=Ks(Qs),tc=Le(.42,0,1,1),nc=Le(0,0,.58,1),rc=Le(.42,0,.58,1),ic=e=>Array.isArray(e)&&typeof e[0]!=`number`,ac=e=>Array.isArray(e)&&typeof e[0]==`number`,oc={linear:I,easeIn:tc,easeInOut:rc,easeOut:nc,circIn:Qs,circInOut:ec,circOut:$s,backIn:Ys,backInOut:Xs,backOut:Js,anticipate:Zs},sc=e=>typeof e==`string`,cc=e=>{if(ac(e)){P(e.length===4,`Cubic bezier arrays must contain four numerical values.`,`cubic-bezier-length`);let[t,n,r,i]=e;return Le(t,n,r,i)}else if(sc(e))return P(oc[e]!==void 0,`Invalid easing type '${e}'`,`invalid-easing-type`),oc[e];return e},z={value:null,addProjectionMetrics:null},lc=[`setup`,`read`,`resolveKeyframes`,`preUpdate`,`update`,`preRender`,`render`,`postRender`],uc=40,{schedule:B,cancel:V,state:H,steps:dc}=Be(typeof requestAnimationFrame<`u`?requestAnimationFrame:I,!0),U={now:()=>(fc===void 0&&U.set(H.isProcessing||F.useManualTiming?H.timestamp:performance.now()),fc),set:e=>{fc=e,queueMicrotask(Ve)}},pc={layout:0,mainThread:0,waapi:0},mc=e=>t=>typeof t==`string`&&t.startsWith(e),hc=mc(`--`),gc=mc(`var(--`),_c=e=>gc(e)?vc.test(e.split(`/*`)[0].trim()):!1,vc=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,yc={test:e=>typeof e==`number`,parse:parseFloat,transform:e=>e},bc={...yc,transform:e=>N(0,1,e)},xc={...yc,default:1},Sc=e=>Math.round(e*1e5)/1e5,Cc=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu,wc=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Tc=(e,t)=>n=>!!(typeof n==`string`&&wc.test(n)&&n.startsWith(e)||t&&!Ue(n)&&Object.prototype.hasOwnProperty.call(n,t)),Ec=(e,t,n)=>r=>{if(typeof r!=`string`)return r;let[i,a,o,s]=r.match(Cc);return{[e]:parseFloat(i),[t]:parseFloat(a),[n]:parseFloat(o),alpha:s===void 0?1:parseFloat(s)}},Dc=e=>N(0,255,e),Oc={...yc,transform:e=>Math.round(Dc(e))},kc={test:Tc(`rgb`,`red`),parse:Ec(`red`,`green`,`blue`),transform:({red:e,green:t,blue:n,alpha:r=1})=>`rgba(`+Oc.transform(e)+`, `+Oc.transform(t)+`, `+Oc.transform(n)+`, `+Sc(bc.transform(r))+`)`},Ac={test:Tc(`#`),parse:We,transform:kc.transform},jc=e=>({test:t=>typeof t==`string`&&t.endsWith(e)&&t.split(` `).length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Mc=jc(`deg`),W=jc(`%`),G=jc(`px`),Nc=jc(`vh`),Pc=jc(`vw`),Fc=(()=>({...W,parse:e=>W.parse(e)/100,transform:e=>W.transform(e*100)}))(),Ic={test:Tc(`hsl`,`hue`),parse:Ec(`hue`,`saturation`,`lightness`),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>`hsla(`+Math.round(e)+`, `+W.transform(Sc(t))+`, `+W.transform(Sc(n))+`, `+Sc(bc.transform(r))+`)`},K={test:e=>kc.test(e)||Ac.test(e)||Ic.test(e),parse:e=>kc.test(e)?kc.parse(e):Ic.test(e)?Ic.parse(e):Ac.parse(e),transform:e=>typeof e==`string`?e:e.hasOwnProperty(`red`)?kc.transform(e):Ic.transform(e),getAnimatableNone:e=>{let t=K.parse(e);return t.alpha=0,K.transform(t)}},Lc=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu,Rc=`number`,zc=`color`,Bc=`var`,Vc=`var(`,Hc="${}",Uc=/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,Wc=e=>typeof e==`number`?0:K.test(e)?K.getAnimatableNone(e):e,Gc=(e,t)=>typeof e==`number`?t?.trim().endsWith(`/`)?e:0:Wc(e),q={test:Ge,parse:qe,createTransformer:Ye,getAnimatableNone:Xe},J=(e,t,n)=>e+(t-e)*n,Kc=(e,t,n)=>{let r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},qc=[Ac,kc,Ic],Jc=e=>qc.find(t=>t.test(e)),Yc=(e,t)=>{let n=et(e),r=et(t);if(!n||!r)return $e(e,t);let i={...n};return e=>(i.red=Kc(n.red,r.red,e),i.green=Kc(n.green,r.green,e),i.blue=Kc(n.blue,r.blue,e),i.alpha=J(n.alpha,r.alpha,e),kc.transform(i))},Xc=new Set([`none`,`hidden`]),Zc=(e,t)=>{let n=q.createTransformer(t),r=Ke(e),i=Ke(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?Xc.has(e)&&!i.values.length||Xc.has(t)&&!r.values.length?tt(e,t):zs(it(ot(r,i),i.values),n):(Fs(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,`complex-values-different`),$e(e,t))},Qc=(e,t,n=10)=>{let r=``,i=Math.max(Math.round(t/n),2);for(let t=0;t{let t=lt(e,100,ht);return e.ease=t.ease,e.duration=L(t.duration),e.type=`keyframes`,e},il=5,al=e=>e!==null,ol=e=>{let t=({timestamp:t})=>e(t);return{start:(e=!0)=>B.update(t,e),stop:()=>V(t),now:()=>H.isProcessing?H.timestamp:U.now()}},sl={decay:_t,inertia:_t,tween:wt,keyframes:wt,spring:ht},cl=class{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(e=>{this.resolve=e})}notifyFinished(){this.resolve()}then(e,t){return this.finished.then(e,t)}},ll=e=>e/100,ul=class extends cl{constructor(e){super(),this.state=`idle`,this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{let{motionValue:e}=this.options;e&&e.updatedAt!==U.now()&&this.tick(U.now()),this.isStopped=!0,this.state!==`idle`&&(this.teardown(),this.options.onStop?.())},pc.mainThread++,this.options=e,this.initAnimation(),this.play(),e.autoplay===!1&&this.pause()}initAnimation(){let{options:e}=this;Et(e);let{type:t=wt,repeat:n=0,repeatDelay:r=0,repeatType:i,velocity:a=0}=e,{keyframes:o}=e,s=t||wt;s!==wt&&typeof o[0]!=`number`&&(this.mixKeyframes=zs(ll,st(o[0],o[1])),o=[0,100]);let c=s({...e,keyframes:o});i===`mirror`&&(this.mirroredGenerator=s({...e,keyframes:[...o].reverse(),velocity:-a})),c.calculatedDuration===null&&(c.calculatedDuration=ct(c));let{calculatedDuration:l}=c;this.calculatedDuration=l,this.resolvedDuration=l+r,this.totalDuration=this.resolvedDuration*(n+1)-r,this.generator=c}updateTime(e){let t=Math.round(e-this.startTime)*this.playbackSpeed;this.holdTime===null?this.currentTime=t:this.currentTime=this.holdTime}tick(e,t=!1){let{generator:n,totalDuration:r,mixKeyframes:i,mirroredGenerator:a,resolvedDuration:o,calculatedDuration:s}=this;if(this.startTime===null)return n.next(0);let{delay:c=0,keyframes:l,repeat:u,repeatType:d,repeatDelay:f,type:p,onUpdate:m,finalKeyframe:h}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-r/this.speed,this.startTime)),t?this.currentTime=e:this.updateTime(e);let g=this.currentTime-c*(this.playbackSpeed>=0?1:-1),_=this.playbackSpeed>=0?g<0:g>r;this.currentTime=Math.max(g,0),this.state===`finished`&&this.holdTime===null&&(this.currentTime=r);let v=this.currentTime,y=n;if(u){let e=Math.min(this.currentTime,r)/o,t=Math.floor(e),n=e%1;!n&&e>=1&&(n=1),n===1&&t--,t=Math.min(t,u+1),t%2&&(d===`reverse`?(n=1-n,f&&(n-=f/o)):d===`mirror`&&(y=a)),v=N(0,1,n)*o}let b;_?(this.delayState.value=l[0],b=this.delayState):b=y.next(v),i&&!_&&(b.value=i(b.value));let{done:x}=b;!_&&s!==null&&(x=this.playbackSpeed>=0?this.currentTime>=r:this.currentTime<=0);let S=this.holdTime===null&&(this.state===`finished`||this.state===`running`&&x);return S&&p!==_t&&(b.value=Tt(l,this.options,h,this.speed)),m&&m(b.value),S&&this.finish(),b}then(e,t){return this.finished.then(e,t)}get duration(){return R(this.calculatedDuration)}get iterationDuration(){let{delay:e=0}=this.options||{};return this.duration+R(e)}get time(){return R(this.currentTime)}set time(e){e=L(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))}getGeneratorVelocity(){let e=this.currentTime;if(e<=0)return this.options.velocity||0;if(this.generator.velocity)return this.generator.velocity(e);let t=this.generator.next(e).value;return gt(e=>this.generator.next(e).value,e,t)}get speed(){return this.playbackSpeed}set speed(e){let t=this.playbackSpeed!==e;t&&this.driver&&this.updateTime(U.now()),this.playbackSpeed=e,t&&this.driver&&(this.time=R(this.currentTime))}play(){if(this.isStopped)return;let{driver:e=ol,startTime:t}=this.options;this.driver||=e(e=>this.tick(e)),this.options.onPlay?.();let n=this.driver.now();this.state===`finished`?(this.updateFinished(),this.startTime=n):this.holdTime===null?this.startTime||=t??n:this.startTime=n-this.holdTime,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(U.now()),this.holdTime=this.currentTime}complete(){this.state!==`running`&&this.play(),this.state=`finished`,this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state=`finished`,this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state=`idle`,this.stopDriver(),this.startTime=this.holdTime=null,pc.mainThread--}stopDriver(){this.driver&&=(this.driver.stop(),void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}attachTimeline(e){return this.options.allowFlatten&&(this.options.type=`keyframes`,this.options.ease=`linear`,this.initAnimation()),this.driver?.stop(),e.observe(this)}},dl=e=>e*180/Math.PI,fl=e=>ml(dl(Math.atan2(e[1],e[0]))),pl={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:fl,rotateZ:fl,skewX:e=>dl(Math.atan(e[1])),skewY:e=>dl(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},ml=e=>(e%=360,e<0&&(e+=360),e),hl=fl,gl=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),_l=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),vl={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:gl,scaleY:_l,scale:e=>(gl(e)+_l(e))/2,rotateX:e=>ml(dl(Math.atan2(e[6],e[5]))),rotateY:e=>ml(dl(Math.atan2(-e[2],e[0]))),rotateZ:hl,rotate:hl,skewX:e=>dl(Math.atan(e[4])),skewY:e=>dl(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2},yl=(e,t)=>{let{transform:n=`none`}=getComputedStyle(e);return At(n,t)},bl=[`transformPerspective`,`x`,`y`,`z`,`translateX`,`translateY`,`translateZ`,`scale`,`scaleX`,`scaleY`,`rotate`,`rotateX`,`rotateY`,`rotateZ`,`skew`,`skewX`,`skewY`],xl=(()=>new Set(bl))(),Sl=e=>e===yc||e===G,Cl=new Set([`x`,`y`,`z`]),wl=bl.filter(e=>!Cl.has(e)),Tl={width:({x:e},{paddingLeft:t=`0`,paddingRight:n=`0`,boxSizing:r})=>{let i=e.max-e.min;return r===`border-box`?i:i-parseFloat(t)-parseFloat(n)},height:({y:e},{paddingTop:t=`0`,paddingBottom:n=`0`,boxSizing:r})=>{let i=e.max-e.min;return r===`border-box`?i:i-parseFloat(t)-parseFloat(n)},top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>At(t,`x`),y:(e,{transform:t})=>At(t,`y`)},Tl.translateX=Tl.x,Tl.translateY=Tl.y,El=new Set,Dl=!1,Ol=!1,kl=!1,Al=class{constructor(e,t,n,r,i,a=!1){this.state=`pending`,this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...e],this.onComplete=t,this.name=n,this.motionValue=r,this.element=i,this.isAsync=a}scheduleResolve(){this.state=`scheduled`,this.isAsync?(El.add(this),Dl||(Dl=!0,B.read(Pt),B.resolveKeyframes(Nt))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:e,name:t,element:n,motionValue:r}=this;if(e[0]===null){let i=r?.get(),a=e[e.length-1];if(i!==void 0)e[0]=i;else if(n&&t){let r=n.readValue(t,a);r!=null&&(e[0]=r)}e[0]===void 0&&(e[0]=a),r&&i===void 0&&r.set(e[0])}Ot(e)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(e=!1){this.state=`complete`,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,e),El.delete(this)}cancel(){this.state===`scheduled`&&(El.delete(this),this.state=`pending`)}resume(){this.state===`pending`&&this.scheduleResolve()}},jl=e=>e.startsWith(`--`),Ml={},Nl=Lt(()=>f.ScrollTimeline!==void 0,`scrollTimeline`),Pl=Lt(()=>f.ViewTimeline!==void 0,`viewTimeline`),Fl=Lt(()=>{try{document.createElement(`div`).animate({opacity:0},{easing:`linear(0, 1)`})}catch{return!1}return!0},`linearEasing`),Il=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,Ll={linear:`linear`,ease:`ease`,easeIn:`ease-in`,easeOut:`ease-out`,easeInOut:`ease-in-out`,circIn:Il([0,.65,.55,1]),circOut:Il([.55,0,1,.45]),backIn:Il([.31,.01,.66,-.59]),backOut:Il([.33,1.53,.69,.99])},Rl=class extends cl{constructor(e){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!e)return;let{element:t,name:n,keyframes:r,pseudoElement:i,allowFlatten:a=!1,finalKeyframe:o,onComplete:s}=e;this.isPseudoElement=!!i,this.allowFlatten=a,this.options=e,P(typeof e.type!=`string`,`Mini animate() doesn't support "type" as a string.`,`mini-spring`);let c=Vt(e);this.animation=zt(t,n,r,c,i),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){let e=Tt(r,this.options,o,this.speed);this.updateMotionValue&&this.updateMotionValue(e),It(t,n,e),this.animation.cancel()}s?.(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state===`finished`&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;let{state:e}=this;e===`idle`||e===`finished`||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){let e=this.options?.element;!this.isPseudoElement&&e?.isConnected&&this.animation.commitStyles?.()}get duration(){let e=this.animation.effect?.getComputedTiming?.().duration||0;return R(Number(e))}get iterationDuration(){let{delay:e=0}=this.options||{};return this.duration+R(e)}get time(){return R(Number(this.animation.currentTime)||0)}set time(e){let t=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=L(e),t&&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?this.animation.playState:`finished`}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(e){this.manualStartTime=this.animation.startTime=e}attachTimeline({timeline:e,rangeStart:t,rangeEnd:n,observe:r}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:`linear`}),this.animation.onfinish=null,e&&Nl()?(this.animation.timeline=e,t&&(this.animation.rangeStart=t),n&&(this.animation.rangeEnd=n),I):r(this)}},zl={anticipate:Zs,backInOut:Xs,circInOut:ec},Bl=10,Vl=class extends Rl{constructor(e){Ut(e),Et(e),super(e),e.startTime!==void 0&&e.autoplay!==!1&&(this.startTime=e.startTime),this.options=e}updateMotionValue(e){let{motionValue:t,onUpdate:n,onComplete:r,element:i,...a}=this.options;if(!t)return;if(e!==void 0){t.set(e);return}let o=new ul({...a,autoplay:!1}),s=Math.max(Bl,U.now()-this.startTime),c=N(0,Bl,s-Bl),l=o.sample(s).value,{name:u}=this.options;i&&u&&It(i,u,l),t.setWithVelocity(o.sample(Math.max(0,s-c)).value,l,c),o.stop()}},Hl=new Set([`opacity`,`clipPath`,`filter`,`transform`]),Ul=/^(?:oklch|oklab|lab|lch|color|color-mix|light-dark)\(/,Wl=new Set([`color`,`backgroundColor`,`outlineColor`,`fill`,`stroke`,`borderColor`,`borderTopColor`,`borderRightColor`,`borderBottomColor`,`borderLeftColor`]),Gl=Pe(()=>Object.hasOwnProperty.call(Element.prototype,`animate`)),Kl=(e,t)=>t===`zIndex`?!1:!!(typeof e==`number`||Array.isArray(e)||typeof e==`string`&&(q.test(e)||e===`0`)&&!e.startsWith(`url(`)),ql=40,Jl=class extends cl{constructor({autoplay:e=!0,delay:t=0,type:n=`keyframes`,repeat:r=0,repeatDelay:i=0,repeatType:a=`loop`,keyframes:o,name:s,motionValue:c,element:l,...u}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=U.now();let d={autoplay:e,delay:t,type:n,repeat:r,repeatDelay:i,repeatType:a,name:s,motionValue:c,element:l,...u};this.keyframeResolver=new(l?.KeyframeResolver||Al)(o,(e,t,n)=>this.onKeyframesResolved(e,t,d,!n),s,c,l),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(e,t,n,r){this.keyframeResolver=void 0;let{name:i,type:a,velocity:o,delay:s,isHandoff:c,onUpdate:l}=n;this.resolvedAt=U.now();let u=!0;Jt(e,i,a,o)||(u=!1,(F.instantAnimations||!s)&&l?.(Tt(e,n,t)),e[0]=e[e.length-1],Wt(n),n.repeat=0);let d={startTime:r?this.resolvedAt&&this.resolvedAt-this.createdAt>ql?this.resolvedAt:this.createdAt:void 0,finalKeyframe:t,...n,keyframes:e},f=u&&!c&&Kt(d),p=d.motionValue?.owner?.current,m;if(f)try{m=new Vl({...d,element:p})}catch{m=new ul(d)}else m=new ul(d);m.finished.then(()=>{this.notifyFinished()}).catch(I),this.pendingTimeline&&=(this.stopTimeline=m.attachTimeline(this.pendingTimeline),void 0),this._animation=m}get finished(){return this._animation?this.animation.finished:this._finished}then(e,t){return this.finished.finally(e).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),Ft()),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(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}},Yl=class{constructor(e){this.stop=()=>this.runAll(`stop`),this.animations=e.filter(Boolean)}get finished(){return Promise.all(this.animations.map(e=>e.finished))}getAll(e){return this.animations[0][e]}setAll(e,t){for(let n=0;nt.attachTimeline(e));return()=>{t.forEach((e,t)=>{e&&e(),this.animations[t].stop()})}}get time(){return this.getAll(`time`)}set time(e){this.setAll(`time`,e)}get speed(){return this.getAll(`speed`)}set speed(e){this.setAll(`speed`,e)}get state(){return this.getAll(`state`)}get startTime(){return this.getAll(`startTime`)}get duration(){return Yt(this.animations,`duration`)}get iterationDuration(){return Yt(this.animations,`iterationDuration`)}runAll(e){this.animations.forEach(t=>t[e]())}play(){this.runAll(`play`)}pause(){this.runAll(`pause`)}cancel(){this.runAll(`cancel`)}complete(){this.runAll(`complete`)}},Xl=class extends Yl{then(e,t){return this.finished.finally(e).then(()=>{})}},Zl=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u,Ql=4,$l={type:`spring`,stiffness:500,damping:25,restSpeed:10},eu=e=>({type:`spring`,stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),tu={type:`keyframes`,duration:.8},nu={type:`keyframes`,ease:[.25,.1,.35,1],duration:.3},ru=(e,{keyframes:t})=>t.length>2?tu:xl.has(e)?e.startsWith(`scale`)?eu(t[1]):$l:nu,iu=new Set([`when`,`delay`,`delayChildren`,`staggerChildren`,`staggerDirection`,`repeat`,`repeatType`,`repeatDelay`,`from`,`elapsed`]),au=(e,t,n,r={},i,a)=>o=>{let s=en(r,e)||{},c=s.delay||r.delay||0,{elapsed:l=0}=r;l-=L(c);let u={keyframes:Array.isArray(n)?n:[null,n],ease:`easeOut`,velocity:t.getVelocity(),...s,delay:-l,onUpdate:e=>{t.set(e),s.onUpdate&&s.onUpdate(e)},onComplete:()=>{o(),s.onComplete&&s.onComplete()},name:e,motionValue:t,element:a?void 0:i};tn(s)||Object.assign(u,ru(e,u)),u.duration&&=L(u.duration),u.repeatDelay&&=L(u.repeatDelay),u.from!==void 0&&(u.keyframes[0]=u.from);let d=!1;if((u.type===!1||u.duration===0&&!u.repeatDelay)&&(Wt(u),u.delay===0&&(d=!0)),(F.instantAnimations||F.skipAnimations||i?.shouldSkipAnimations)&&(d=!0,Wt(u),u.delay=0),u.allowFlatten=!s.type&&!s.ease,d&&!a&&t.get()!==void 0){let e=Tt(u.keyframes,s);if(e!==void 0){B.update(()=>{u.onUpdate(e),u.onComplete()});return}}return s.isSync?new ul(u):new Jl(u)},ou=new Set([`width`,`height`,`top`,`left`,`right`,`bottom`,...bl]),su=30,cu=e=>!isNaN(parseFloat(e)),lu={current:void 0},uu=class{constructor(e,t={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=e=>{let t=U.now();if(this.updatedAt!==t&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(e),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(let e of this.dependents)e.dirty()},this.hasAnimated=!1,this.setCurrent(e),this.owner=t.owner}setCurrent(e){this.current=e,this.updatedAt=U.now(),this.canTrackVelocity===null&&e!==void 0&&(this.canTrackVelocity=cu(this.current))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return this.on(`change`,e)}on(e,t){this.events[e]||(this.events[e]=new Vs);let n=this.events[e].add(t);return e===`change`?()=>{n(),B.read(()=>{this.events.change.getSize()||this.stop()})}:n}clearListeners(){for(let e in this.events)this.events[e].clear()}attach(e,t){this.passiveEffect=e,this.stopPassiveEffect=t}set(e){this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e)}setWithVelocity(e,t,n){this.set(t),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-n}jump(e,t=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,t&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(e){this.dependents||=new Set,this.dependents.add(e)}removeDependent(e){this.dependents&&this.dependents.delete(e)}get(){return lu.current&&lu.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){let e=U.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||e-this.updatedAt>su)return 0;let t=Math.min(this.updatedAt-this.prevUpdatedAt,su);return Fe(parseFloat(this.current)-parseFloat(this.prevFrameValue),t)}start(e){return this.stop(),new Promise(t=>{this.hasAnimated=!0,this.animation=e(t),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}},du=e=>Array.isArray(e),X=e=>!!(e&&e.getVelocity),fu=`framerAppearId`,pu=`data-`+dn(fu),mu=e=>t=>t.test(e),hu=[yc,G,W,Mc,Pc,Nc,{test:e=>e===`auto`,parse:e=>e}],gu=e=>hu.find(mu(e)),_u={rotate:Mc,rotateX:Mc,rotateY:Mc,rotateZ:Mc,scale:xc,scaleX:xc,scaleY:xc,scaleZ:xc,skew:Mc,skewX:Mc,skewY:Mc,distance:G,translateX:G,translateY:G,translateZ:G,x:G,y:G,z:G,perspective:G,transformPerspective:G,opacity:bc,originX:Fc,originY:Fc,originZ:G},vu={...yc,transform:Math.round},yu={borderWidth:G,borderTopWidth:G,borderRightWidth:G,borderBottomWidth:G,borderLeftWidth:G,borderRadius:G,borderTopLeftRadius:G,borderTopRightRadius:G,borderBottomRightRadius:G,borderBottomLeftRadius:G,width:G,maxWidth:G,height:G,maxHeight:G,top:G,right:G,bottom:G,left:G,inset:G,insetBlock:G,insetBlockStart:G,insetBlockEnd:G,insetInline:G,insetInlineStart:G,insetInlineEnd:G,padding:G,paddingTop:G,paddingRight:G,paddingBottom:G,paddingLeft:G,paddingBlock:G,paddingBlockStart:G,paddingBlockEnd:G,paddingInline:G,paddingInlineStart:G,paddingInlineEnd:G,margin:G,marginTop:G,marginRight:G,marginBottom:G,marginLeft:G,marginBlock:G,marginBlockStart:G,marginBlockEnd:G,marginInline:G,marginInlineStart:G,marginInlineEnd:G,fontSize:G,backgroundPositionX:G,backgroundPositionY:G,..._u,zIndex:vu,fillOpacity:bc,strokeOpacity:bc,numOctaves:vu},bu=new Set([`brightness`,`contrast`,`saturate`,`opacity`]),xu=/\b([a-z-]*)\(.*?\)/gu,Su={...q,getAnimatableNone:e=>{let t=e.match(xu);return t?t.map(vn).join(` `):e}},Cu={...q,getAnimatableNone:e=>{let t=q.parse(e);return q.createTransformer(e)(t.map(e=>typeof e==`number`?0:typeof e==`object`?{...e,alpha:1}:e))}},wu={...yu,color:K,backgroundColor:K,outlineColor:K,fill:K,stroke:K,borderColor:K,borderTopColor:K,borderRightColor:K,borderBottomColor:K,borderLeftColor:K,filter:Su,WebkitFilter:Su,mask:Cu,WebkitMask:Cu},Tu=e=>wu[e],Eu=new Set([Su,Cu]),Du=new Set([`auto`,`none`,`0`]),Ou=class extends Al{constructor(e,t,n,r,i){super(e,t,n,r,i,!0)}readKeyframes(){let{unresolvedKeyframes:e,element:t,name:n}=this;if(!t||!t.current)return;super.readKeyframes();for(let n=0;n{e.getValue(t).set(n)}),this.resolveNoneKeyframes()}},ku=(e,t)=>t&&typeof e==`number`?t.transform(e):e,{schedule:Au,cancel:ju}=Be(queueMicrotask,!1),Z={x:!1,y:!1},Mu=(e,t)=>t?e===t?!0:Mu(e,t.parentElement):!1,Nu=e=>e.pointerType===`mouse`?typeof e.button!=`number`||e.button<=0:e.isPrimary!==!1,Pu=new Set([`BUTTON`,`INPUT`,`SELECT`,`TEXTAREA`,`A`]),Fu=new Set([`INPUT`,`SELECT`,`TEXTAREA`]),Iu=new WeakSet,Lu=(e,t)=>{let n=e.currentTarget;if(!n)return;let r=jn(()=>{if(Iu.has(n))return;Mn(n,`down`);let e=jn(()=>{Mn(n,`up`)});n.addEventListener(`keyup`,e,t),n.addEventListener(`blur`,()=>Mn(n,`cancel`),t)});n.addEventListener(`keydown`,r,t),n.addEventListener(`blur`,()=>n.removeEventListener(`keydown`,r),t)},Ru=new WeakSet,zu=new WeakMap,Vu=(e,t,n)=>(r,i)=>i&&i[0]?i[0][e+`Size`]:Fn(r)&&`getBBox`in r?r.getBBox()[t]:r[n],Hu=Vu(`inline`,`width`,`offsetWidth`),Uu=Vu(`block`,`height`,`offsetHeight`),Wu=new Set,Ku=[...hu,K,q],qu=e=>Ku.find(mu(e)),Ju=()=>({translate:0,scale:1,origin:0,originPoint:0}),Yu=()=>({x:Ju(),y:Ju()}),Xu=()=>({min:0,max:0}),Q=()=>({x:Xu(),y:Xu()}),Zu=new WeakMap,Qu=[`animate`,`whileInView`,`whileFocus`,`whileHover`,`whileTap`,`whileDrag`,`exit`],$u=[`initial`,...Qu],ed={current:null},td={current:!1},nd=f!==void 0,rd=[`AnimationStart`,`AnimationComplete`,`Update`,`BeforeLayoutMeasure`,`LayoutMeasure`,`LayoutAnimationStart`,`LayoutAnimationComplete`],id={},ad=class{scrapeMotionValuesFromProps(e,t,n){return{}}constructor({parent:e,props:t,presenceContext:n,reducedMotionConfig:r,skipAnimations:i,blockInitialAnimation:a,visualState:o},s={}){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=Al,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=()=>{let e=U.now();this.renderScheduledAtthis.bindToMotionValue(t,e)),this.reducedMotionConfig===`never`?this.shouldReduceMotion=!1:this.reducedMotionConfig===`always`?this.shouldReduceMotion=!0:(td.current||ir(),this.shouldReduceMotion=ed.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,this.parent?.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){for(let e in this.projection&&this.projection.unmount(),V(this.notifyUpdate),V(this.render),this.valueSubscriptions.forEach(e=>e()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this),this.events)this.events[e].clear();for(let e in this.features){let t=this.features[e];t&&(t.unmount(),t.isMounted=!1)}this.current=null}addChild(e){this.children.add(e),this.enteringChildren??=new Set,this.enteringChildren.add(e)}removeChild(e){this.children.delete(e),this.enteringChildren&&this.enteringChildren.delete(e)}bindToMotionValue(e,t){if(this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)(),t.accelerate&&Hl.has(e)&&this.current instanceof HTMLElement){let{factory:n,keyframes:r,times:i,ease:a,duration:o}=t.accelerate,s=new Rl({element:this.current,name:e,keyframes:r,times:i,ease:a,duration:L(o)}),c=n(s);this.valueSubscriptions.set(e,()=>{c(),s.cancel()});return}let n=xl.has(e);n&&this.onBindTransform&&this.onBindTransform();let r=t.on(`change`,t=>{this.latestValues[e]=t,this.props.onUpdate&&B.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()}),i;f!==void 0&&f.MotionCheckAppearSync&&(i=f.MotionCheckAppearSync(this,e,t)),this.valueSubscriptions.set(e,()=>{r(),i&&i(),t.owner&&t.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 id){let t=id[e];if(!t)continue;let{isEnabled:n,Feature:r}=t;if(!this.features[e]&&r&&n(this.props)&&(this.features[e]=new r(this)),this.features[e]){let t=this.features[e];t.isMounted?t.update():(t.mount(),t.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Q()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,t){this.latestValues[e]=t}update(e,t){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=t;for(let t=0;tt.variantChildren.delete(e)}addValue(e,t){let n=this.values.get(e);t!==n&&(n&&this.removeValue(e),this.bindToMotionValue(e,t),this.values.set(e,t),this.latestValues[e]=t.get())}removeValue(e){this.values.delete(e);let t=this.valueSubscriptions.get(e);t&&(t(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,t){if(this.props.values&&this.props.values[e])return this.props.values[e];let n=this.values.get(e);return n===void 0&&t!==void 0&&(n=D(t===null?void 0:t,{owner:this}),this.addValue(e,n)),n}readValue(e,t){let n=this.latestValues[e]!==void 0||!this.current?this.latestValues[e]:this.getBaseTargetFromProps(this.props,e)??this.readValueFromInstance(this.current,e,this.options);return n!=null&&(typeof n==`string`&&(Is(n)||Ls(n))?n=parseFloat(n):!qu(n)&&q.test(t)&&(n=yn(e,t)),this.setBaseTarget(e,X(n)?n.get():n)),X(n)?n.get():n}setBaseTarget(e,t){this.baseTarget[e]=t}getBaseTarget(e){let{initial:t}=this.props,n;if(typeof t==`string`||typeof t==`object`){let r=rn(this.props,t,this.presenceContext?.custom);r&&(n=r[e])}if(t&&n!==void 0)return n;let r=this.getBaseTargetFromProps(this.props,e);return r!==void 0&&!X(r)?r:this.initialValues[e]!==void 0&&n===void 0?void 0:this.baseTarget[e]}on(e,t){return this.events[e]||(this.events[e]=new Vs),this.events[e].add(t)}notify(e,...t){this.events[e]&&this.events[e].notify(...t)}scheduleRenderMicrotask(){Au.render(this.render)}},od=class extends ad{constructor(){super(...arguments),this.KeyframeResolver=Ou}sortInstanceNodePosition(e,t){return e.compareDocumentPosition(t)&2?1:-1}getBaseTargetFromProps(e,t){let n=e.style;return n?n[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:e}=this.props;X(e)&&(this.childSubscription=e.on(`change`,e=>{this.current&&(this.current.textContent=`${e}`)}))}},sd=class{constructor(e){this.isMounted=!1,this.node=e}update(){}},cd=.999999999999,ld=1.0000000000001,ud={x:`translateX`,y:`translateY`,z:`translateZ`,transformPerspective:`perspective`},dd=bl.length,fd={correct:(e,t)=>{if(!t.target)return e;if(typeof e==`string`)if(G.test(e))e=parseFloat(e);else return e;return`${Or(e,t.target.x)}% ${Or(e,t.target.y)}%`}},pd={correct:(e,{treeScale:t,projectionDelta:n})=>{let r=e,i=q.parse(e);if(i.length>5)return r;let a=q.createTransformer(e),o=typeof i[0]==`number`?0:1,s=n.x.scale*t.x,c=n.y.scale*t.y;i[0+o]/=s,i[1+o]/=c;let l=J(s,c,.5);return typeof i[2+o]==`number`&&(i[2+o]/=l),typeof i[3+o]==`number`&&(i[3+o]/=l),a(i)}},md={borderRadius:{...fd,applyTo:[`borderTopLeftRadius`,`borderTopRightRadius`,`borderBottomLeftRadius`,`borderBottomRightRadius`]},borderTopLeftRadius:fd,borderTopRightRadius:fd,borderBottomLeftRadius:fd,borderBottomRightRadius:fd,boxShadow:pd},hd=class extends od{constructor(){super(...arguments),this.type=`html`,this.renderInstance=Dr}readValueFromInstance(e,t){if(xl.has(t))return this.projection?.isProjecting?kt(t):yl(e,t);{let n=Mr(e),r=(hc(t)?n.getPropertyValue(t):n[t])||0;return typeof r==`string`?r.trim():r}}measureInstanceViewportBox(e,{transformPagePoint:t}){return Cr(e,t)}build(e,t,n){Er(e,t,n.transformTemplate)}scrapeMotionValuesFromProps(e,t,n){return jr(e,t,n)}},gd=class extends ad{constructor(){super(...arguments),this.type=`object`}readValueFromInstance(e,t){if(Nr(t,e)){let n=e[t];if(typeof n==`string`||typeof n==`number`)return n}}getBaseTargetFromProps(){}removeValueFromRenderState(e,t){delete t.output[e]}measureInstanceViewportBox(){return Q()}build(e,t){Object.assign(e.output,t)}renderInstance(e,{output:t}){Object.assign(e,t)}sortInstanceNodePosition(){return 0}},_d={offset:`stroke-dashoffset`,array:`stroke-dasharray`},vd={offset:`strokeDashoffset`,array:`strokeDasharray`},yd=[`offsetDistance`,`offsetPath`,`offsetRotate`,`offsetAnchor`],bd=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`]),xd=e=>typeof e==`string`&&e.toLowerCase()===`svg`,Sd=class extends od{constructor(){super(...arguments),this.type=`svg`,this.isSVGTag=!1,this.measureInstanceViewportBox=Q}getBaseTargetFromProps(e,t){return e[t]}readValueFromInstance(e,t){if(xl.has(t)){let e=Tu(t);return e&&e.default||0}return t=bd.has(t)?t:dn(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return Lr(e,t,n)}build(e,t,n){Fr(e,t,this.isSVGTag,n.transformTemplate,n.style)}renderInstance(e,t,n,r){Ir(e,t,n,r)}mount(e){this.isSVGTag=xd(e.tagName),super.mount(e)}},Cd=$u.length,wd=[...Qu].reverse(),Td=Qu.length,Ed=1e-4,Dd=1-Ed,Od=1+Ed,kd=.01,Ad=0-kd,jd=0+kd,Md=[`x`,`scaleX`,`originX`],Nd=[`y`,`scaleY`,`originY`],Pd=[`borderTopLeftRadius`,`borderTopRightRadius`,`borderBottomLeftRadius`,`borderBottomRightRadius`],Fd=Pd.length,Id=e=>typeof e==`string`?parseFloat(e):e,Ld=e=>typeof e==`number`||G.test(e),Rd=hi(0,.5,$s),zd=hi(.5,.95,I),Bd=(e,t)=>e.depth-t.depth,Vd=class{constructor(){this.children=[],this.isDirty=!1}add(e){Ae(this.children,e),this.isDirty=!0}remove(e){je(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(Bd),this.isDirty=!1,this.children.forEach(e)}},Hd=class{constructor(){this.members=[]}add(e){Ae(this.members,e);for(let t=this.members.length-1;t>=0;t--){let n=this.members[t];if(n===e||n===this.lead||n===this.prevLead)continue;let r=n.instance;(!r||r.isConnected===!1)&&!n.snapshot&&(je(this.members,n),n.unmount())}e.scheduleRender()}remove(e){if(je(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){let e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){for(let t=this.members.indexOf(e)-1;t>=0;t--){let e=this.members[t];if(e.isPresent!==!1&&e.instance?.isConnected!==!1)return this.promote(e),!0}return!1}promote(e,t){let n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.updateSnapshot(),e.scheduleRender();let{layoutDependency:r}=n.options,{layoutDependency:i}=e.options;(r===void 0||r!==i)&&(e.resumeFrom=n,t&&(n.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root?.isUpdating&&(e.isLayoutDirty=!0)),e.options.crossfade===!1&&n.hide()}}exitAnimationComplete(){this.members.forEach(e=>{e.options.onExitComplete?.(),e.resumingFrom?.options.onExitComplete?.()})}scheduleRender(){this.members.forEach(e=>e.instance&&e.scheduleRender(!1))}removeLeadSnapshot(){this.lead?.snapshot&&(this.lead.snapshot=void 0)}},Ud={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Wd={nodes:0,calculatedTargetDeltas:0,calculatedProjections:0},Gd=[``,`X`,`Y`,`Z`],Kd=1e3,qd=0,Jd={duration:.45,ease:[.4,0,.1,1]},Yd=e=>s!==void 0&&s.userAgent&&s.userAgent.toLowerCase().includes(e),Xd=Yd(`applewebkit/`)&&!Yd(`chrome/`)?Math.round:I,Zd=Si({attachResizeListener:(e,t)=>_i(e,`resize`,t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body?.scrollLeft||0,y:document.documentElement.scrollTop||document.body?.scrollTop||0}),checkIsScrollRoot:()=>!0}),Qd=e=>!e.isLayoutDirty&&e.willUpdate(!1),$d={current:void 0},ef=Si({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!$d.current){let e=new Zd({});e.mount(f),e.setOptions({layoutScroll:!0}),$d.current=e}return $d.current},resetTransform:(e,t)=>{e.style.transform=t===void 0?`none`:t},checkIsScrollRoot:e=>f.getComputedStyle(e).position===`fixed`}),lc.reduce((e,t)=>(e[t]=e=>V(e),e),{}),$=a({transformPagePoint:e=>e,isStatic:!1,reducedMotion:`never`}),tf=class extends _{getSnapshotBeforeUpdate(e){let t=this.props.childRef.current;if(Cn(t)&&e.isPresent&&!this.props.isPresent&&this.props.pop!==!1){let e=t.offsetParent,n=Cn(e)&&e.offsetWidth||0,r=Cn(e)&&e.offsetHeight||0,i=getComputedStyle(t),a=this.props.sizeRef.current;a.height=parseFloat(i.height),a.width=parseFloat(i.width),a.top=t.offsetTop,a.left=t.offsetLeft,a.right=n-a.width-a.left,a.bottom=r-a.height-a.top}return null}componentDidUpdate(){}render(){return this.props.children}},nf=({children:e,initial:t,isPresent:r,onExitComplete:i,custom:a,presenceAffectsLayout:o,mode:s,anchorX:l,anchorY:u,root:d})=>{let f=M(Zi),p=T(),m=!0,h=n(()=>(m=!1,{id:p,initial:t,isPresent:r,custom:a,onExitComplete:e=>{f.set(e,!0);for(let e of f.values())if(!e)return;i&&i()},register:e=>(f.set(e,!1),()=>f.delete(e))}),[r,f,i]);return o&&m&&(h={...h}),n(()=>{f.forEach((e,t)=>f.set(t,!1))},[r]),c(()=>{!r&&!f.size&&i&&i()},[r]),e=g(Xi,{pop:s===`popLayout`,isPresent:r,anchorX:l,anchorY:u,root:d,children:e}),g(Ps.Provider,{value:h,children:e})},rf=e=>e.key||``,af=({children:e,custom:t,initial:r=!0,onExitComplete:a,presenceAffectsLayout:o=!0,mode:s=`sync`,propagate:c=!1,anchorX:l=`left`,anchorY:u=`top`,root:f})=>{let[p,m]=Qi(c),h=n(()=>$i(e),[e]),_=c&&!p?[]:h.map(rf),v=i(!0),y=i(h),x=M(()=>new Map),S=i(new Set),[w,ee]=d(h),[T,te]=d(h);Ns(()=>{v.current=!1,y.current=h;for(let e=0;e{let n=rf(e),i=c&&!p?!1:h===T||_.includes(n);return g(nf,{isPresent:i,initial:!v.current||r?void 0:!1,custom:t,presenceAffectsLayout:o,mode:s,root:f,onExitComplete:i?void 0:()=>{if(S.current.has(n))return;if(x.has(n))S.current.add(n),x.set(n,!0);else return;let e=!0;x.forEach(t=>{t||(e=!1)}),e&&(ne?.(),te(y.current),c&&m?.(),a&&a())},anchorX:l,anchorY:u,children:e},n)})})},of=a(null),sf=e=>e===!0,cf=e=>sf(e===!0)||e===`id`,lf=({children:e,id:t,inherit:r=!0})=>{let a=b(js),o=b(of),[s,c]=ta(),l=i(null),u=a.id||o;l.current===null&&(cf(r)&&u&&(t=t?u+`-`+t:u),l.current={id:t,group:sf(r)&&a.group||Ki()});let d=n(()=>({...l.current,forceRender:s}),[c]);return g(js.Provider,{value:d,children:e})},uf=a({strict:!1}),df={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`]},ff=!1,pf=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`.split(`.`)),mf=e=>!aa(e);try{oa(ue(`@emotion/is-prop-valid`).default)}catch{}hf=a({}),gf=e=>(t,n)=>{let r=b(hf),i=b(Ps),a=()=>la(e,t,r,i);return n?a():M(a)},_f=a({}),vf=()=>({style:{},transform:{},transformOrigin:{},vars:{}}),yf=()=>({...vf(),attrs:{}}),bf=[`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`],xf=gf({scrapeMotionValuesFromProps:jr,createRenderState:vf}),Sf=gf({scrapeMotionValuesFromProps:Lr,createRenderState:yf}),Cf=Symbol.for(`motionComponentSymbol`),wf=class extends sd{constructor(e){super(e),e.animationState||=Vr(e)}updateAnimationControlsSubscription(){let{animate:e}=this.node.getProps();$n(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:e}=this.node.getProps(),{animate:t}=this.node.prevProps||{};e!==t&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}},Tf=0,Ef=class extends sd{constructor(){super(...arguments),this.id=Tf++,this.isExitComplete=!1}update(){if(!this.node.presenceContext)return;let{isPresent:e,onExitComplete:t}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===n)return;if(e&&n===!1){if(this.isExitComplete){let{initial:e,custom:t}=this.node.getProps();if(typeof e==`string`){let n=an(this.node,e,t);if(n){let{transition:e,transitionEnd:t,...r}=n;for(let e in r)this.node.getValue(e)?.jump(r[e])}}this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive(`exit`,!1);this.isExitComplete=!1;return}let r=this.node.animationState.setActive(`exit`,!e);t&&!e&&r.then(()=>{this.isExitComplete=!0,t(this.id)})}mount(){let{register:e,onExitComplete:t}=this.node.presenceContext||{};t&&t(this.id),e&&(this.unmount=e(this.id))}unmount(){}},Df={animation:{Feature:wf},exit:{Feature:Ef}},Of=e=>t=>Nu(t)&&e(t,ja(t)),kf=(e,t)=>Math.abs(e-t),Af=(e,t)=>t.isSVG??ya(e)?new Sd(t):new hd(t,{allowProjection:e!==l}),jf=({current:e})=>e?e.ownerDocument.defaultView:null,Mf=new Set([`auto`,`scroll`]),Nf=class{constructor(e,t,{transformPagePoint:n,contextWindow:r=f,dragSnapToOrigin:i=!1,distanceThreshold:a=3,element:o}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=f,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=e=>{this.handleScroll(e.target)},this.onWindowScroll=()=>{this.handleScroll(f)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=Pa(this.lastRawMoveEventInfo,this.transformPagePoint));let e=Ia(this.lastMoveEventInfo,this.history),t=this.startEvent!==null,n=Na(e.offset,{x:0,y:0})>=this.distanceThreshold;if(!t&&!n)return;let{point:r}=e,{timestamp:i}=H;this.history.push({...r,timestamp:i});let{onStart:a,onMove:o}=this.handlers;t||(a&&a(this.lastMoveEvent,e),this.startEvent=this.lastMoveEvent),o&&o(this.lastMoveEvent,e)},this.handlePointerMove=(e,t)=>{this.lastMoveEvent=e,this.lastRawMoveEventInfo=t,this.lastMoveEventInfo=Pa(t,this.transformPagePoint),B.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{this.end();let{onEnd:n,onSessionEnd:r,resumeAnimation:i}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&i&&i(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let a=Ia(e.type===`pointercancel`?this.lastMoveEventInfo:Pa(t,this.transformPagePoint),this.history);this.startEvent&&n&&n(e,a),r&&r(e,a)},!Nu(e))return;this.dragSnapToOrigin=i,this.handlers=t,this.transformPagePoint=n,this.distanceThreshold=a,this.contextWindow=r||f;let s=Pa(ja(e),this.transformPagePoint),{point:c}=s,{timestamp:l}=H;this.history=[{...c,timestamp:l}];let{onSessionStart:u}=t;u&&u(e,Ia(s,this.history)),this.removeListeners=zs(Ma(this.contextWindow,`pointermove`,this.handlePointerMove),Ma(this.contextWindow,`pointerup`,this.handlePointerUp),Ma(this.contextWindow,`pointercancel`,this.handlePointerUp)),o&&this.startScrollTracking(o)}startScrollTracking(e){let t=e.parentElement;for(;t;){let e=getComputedStyle(t);(Mf.has(e.overflowX)||Mf.has(e.overflowY))&&this.scrollPositions.set(t,{x:t.scrollLeft,y:t.scrollTop}),t=t.parentElement}this.scrollPositions.set(f,{x:f.scrollX,y:f.scrollY}),f.addEventListener(`scroll`,this.onElementScroll,{capture:!0}),f.addEventListener(`scroll`,this.onWindowScroll),this.removeScrollListeners=()=>{f.removeEventListener(`scroll`,this.onElementScroll,{capture:!0}),f.removeEventListener(`scroll`,this.onWindowScroll)}}handleScroll(e){let t=this.scrollPositions.get(e);if(!t)return;let n=e===f,r=n?{x:f.scrollX,y:f.scrollY}:{x:e.scrollLeft,y:e.scrollTop},i={x:r.x-t.x,y:r.y-t.y};i.x===0&&i.y===0||(n?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=i.x,this.lastMoveEventInfo.point.y+=i.y):this.history.length>0&&(this.history[0].x-=i.x,this.history[0].y-=i.y),this.scrollPositions.set(e,r),B.update(this.updatePoint,!0))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),V(this.updatePoint)}},Pf=.35,Ff=new WeakMap,If=class{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=Q(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=e}start(e,{snapToCursor:t=!1,distanceThreshold:n}={}){let{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;let i=e=>{t&&this.snapToCursor(ja(e).point),this.stopAnimation()},a=(e,t)=>{let{drag:n,dragPropagation:r,onDragStart:i}=this.getProps();if(n&&!r&&(this.openDragLock&&this.openDragLock(),this.openDragLock=Tn(n),!this.openDragLock))return;this.latestPointerEvent=e,this.latestPanInfo=t,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),j(e=>{let t=this.getAxisMotionValue(e).get()||0;if(W.test(t)){let{projection:n}=this.visualElement;if(n&&n.layout){let r=n.layout.layoutBox[e];r&&(t=A(r)*(parseFloat(t)/100))}}this.originPoint[e]=t}),i&&B.update(()=>i(e,t),!1,!0),un(this.visualElement,`transform`);let{animationState:a}=this.visualElement;a&&a.setActive(`whileDrag`,!0)},o=(e,t)=>{this.latestPointerEvent=e,this.latestPanInfo=t;let{dragPropagation:n,dragDirectionLock:r,onDirectionLock:i,onDrag:a}=this.getProps();if(!n&&!this.openDragLock)return;let{offset:o}=t;if(r&&this.currentDirection===null){this.currentDirection=$a(o),this.currentDirection!==null&&i&&i(this.currentDirection);return}this.updateAxis(`x`,t.point,o),this.updateAxis(`y`,t.point,o),this.visualElement.render(),a&&B.update(()=>a(e,t),!1,!0)},s=(e,t)=>{this.latestPointerEvent=e,this.latestPanInfo=t,this.stop(e,t),this.latestPointerEvent=null,this.latestPanInfo=null},c=()=>{let{dragSnapToOrigin:e}=this.getProps();(e||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:l}=this.getProps();this.panSession=new Nf(e,{onSessionStart:i,onStart:a,onMove:o,onSessionEnd:s,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:l,distanceThreshold:n,contextWindow:jf(this.visualElement),element:this.visualElement.current})}stop(e,t){let n=e||this.latestPointerEvent,r=t||this.latestPanInfo,i=this.isDragging;if(this.cancel(),!i||!r||!n)return;let{velocity:a}=r;this.startAnimation(a);let{onDragEnd:o}=this.getProps();o&&B.postRender(()=>o(n,r))}cancel(){this.isDragging=!1;let{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.endPanSession();let{dragPropagation:n}=this.getProps();!n&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),t&&t.setActive(`whileDrag`,!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(e,t,n){let{drag:r}=this.getProps();if(!n||!Qa(e,r,this.currentDirection))return;let i=this.getAxisMotionValue(e),a=this.originPoint[e]+n[e];this.constraints&&this.constraints[e]&&(a=Ba(a,this.constraints[e],this.elastic[e])),i.set(a)}resolveConstraints(){let{dragConstraints:e,dragElastic:t}=this.getProps(),n=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,r=this.constraints;e&&Sa(e)?this.constraints||=this.resolveRefConstraints():e&&n?this.constraints=Ha(n.layoutBox,e):this.constraints=!1,this.elastic=qa(t),r!==this.constraints&&!Sa(e)&&n&&this.constraints&&!this.hasMutatedConstraints&&j(e=>{this.constraints!==!1&&this.getAxisMotionValue(e)&&(this.constraints[e]=Ka(n.layoutBox[e],this.constraints[e]))})}resolveRefConstraints(){let{dragConstraints:e,onMeasureDragConstraints:t}=this.getProps();if(!e||!Sa(e))return!1;let n=e.current;P(n!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.",`drag-constraints-ref`);let{projection:r}=this.visualElement;if(!r||!r.layout)return!1;let i=wr(n,r.root,this.visualElement.getTransformPagePoint()),a=Wa(r.layout.layoutBox,i);if(t){let e=t(cr(a));this.hasMutatedConstraints=!!e,e&&(a=sr(e))}return a}startAnimation(e){let{drag:t,dragMomentum:n,dragElastic:r,dragTransition:i,dragSnapToOrigin:a,onDragTransitionEnd:o}=this.getProps(),s=this.constraints||{},c=j(o=>{if(!Qa(o,t,this.currentDirection))return;let c=s&&s[o]||{};(a===!0||a===o)&&(c={min:0,max:0});let l=r?200:1e6,u=r?40:1e7,d={type:`inertia`,velocity:n?e[o]:0,bounceStiffness:l,bounceDamping:u,timeConstant:750,restDelta:1,restSpeed:10,...i,...c};return this.startAxisValueAnimation(o,d)});return Promise.all(c).then(o)}startAxisValueAnimation(e,t){let n=this.getAxisMotionValue(e);return un(this.visualElement,e),n.start(au(e,n,0,t,this.visualElement,!1))}stopAnimation(){j(e=>this.getAxisMotionValue(e).stop())}getAxisMotionValue(e){let t=`_drag${e.toUpperCase()}`,n=this.visualElement.getProps();return n[t]||this.visualElement.getValue(e,(n.initial?n.initial[e]:void 0)||0)}snapToCursor(e){j(t=>{let{drag:n}=this.getProps();if(!Qa(t,n,this.currentDirection))return;let{projection:r}=this.visualElement,i=this.getAxisMotionValue(t);if(r&&r.layout){let{min:n,max:a}=r.layout.layoutBox[t],o=i.get()||0;i.set(e[t]-J(n,a,.5)+o)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!Sa(t)||!n||!this.constraints)return;this.stopAnimation();let r={x:0,y:0};j(e=>{let t=this.getAxisMotionValue(e);if(t&&this.constraints!==!1){let n=t.get();r[e]=Ga({min:n,max:n},this.constraints[e])}});let{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},``):`none`,n.root&&n.root.updateScroll(),n.updateLayout(),this.constraints=!1,this.resolveConstraints(),j(t=>{if(!Qa(t,e,null))return;let n=this.getAxisMotionValue(t),{min:i,max:a}=this.constraints[t];n.set(J(i,a,r[t]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;Ff.set(this.visualElement,this);let e=this.visualElement.current,t=Ma(e,`pointerdown`,t=>{let{drag:n,dragListener:r=!0}=this.getProps(),i=t.target,a=i!==e&&An(i);n&&r&&!a&&this.start(t)}),n,r=()=>{let{dragConstraints:t}=this.getProps();Sa(t)&&t.current&&(this.constraints=this.resolveRefConstraints(),n||=Za(e,t.current,()=>this.scalePositionWithinConstraints()))},{projection:i}=this.visualElement,a=i.addEventListener(`measure`,r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),B.read(r);let o=_i(f,`resize`,()=>this.scalePositionWithinConstraints()),s=i.addEventListener(`didUpdate`,({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(j(t=>{let n=this.getAxisMotionValue(t);n&&(this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate))}),this.visualElement.render())});return()=>{o(),t(),a(),s&&s(),n&&n()}}getProps(){let e=this.visualElement.getProps(),{drag:t=!1,dragDirectionLock:n=!1,dragPropagation:r=!1,dragConstraints:i=!1,dragElastic:a=Pf,dragMomentum:o=!0}=e;return{...e,drag:t,dragDirectionLock:n,dragPropagation:r,dragConstraints:i,dragElastic:a,dragMomentum:o}}},Lf=class extends sd{constructor(e){super(e),this.removeGroupControls=I,this.removeListeners=I,this.controls=new If(e)}mount(){let{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||I}update(){let{dragControls:e}=this.node.getProps(),{dragControls:t}=this.node.prevProps||{};e!==t&&(this.removeGroupControls(),e&&(this.removeGroupControls=e.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}},Rf=e=>(t,n)=>{e&&B.update(()=>e(t,n),!1,!0)},zf=class extends sd{constructor(){super(...arguments),this.removePointerDownListener=I}onPointerDown(e){this.session=new Nf(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:jf(this.node)})}createPanHandlers(){let{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:Rf(e),onStart:Rf(t),onMove:Rf(n),onEnd:(e,t)=>{delete this.session,r&&B.postRender(()=>r(e,t))}}}mount(){this.removePointerDownListener=Ma(this.node.current,`pointerdown`,e=>this.onPointerDown(e))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}},Bf=!1,Vf=class extends _{componentDidMount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:r}=this.props,{projection:i}=e;i&&(t.group&&t.group.add(i),n&&n.register&&r&&n.register(i),Bf&&i.root.didUpdate(),i.addEventListener(`animationComplete`,()=>{this.safeToRemove()}),i.setOptions({...i.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),Ud.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){let{layoutDependency:t,visualElement:n,drag:r,isPresent:i}=this.props,{projection:a}=n;return a?(a.isPresent=i,e.layoutDependency!==t&&a.setOptions({...a.options,layoutDependency:t}),Bf=!0,r||e.layoutDependency!==t||t===void 0||e.isPresent!==i?a.willUpdate():this.safeToRemove(),e.isPresent!==i&&(i?a.promote():a.relegate()||B.postRender(()=>{let e=a.getStack();(!e||!e.members.length)&&this.safeToRemove()})),null):null}componentDidUpdate(){let{visualElement:e,layoutAnchor:t}=this.props,{projection:n}=e;n&&(n.options.layoutAnchor=t,n.root.didUpdate(),Au.postRender(()=>{!n.currentAnimation&&n.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;Bf=!0,r&&(r.scheduleCheckAfterUnmount(),t&&t.group&&t.group.remove(r),n&&n.deregister&&n.deregister(r))}safeToRemove(){let{safeToRemove:e}=this.props;e&&e()}render(){return null}},Hf={pan:{Feature:zf},drag:{Feature:Lf,ProjectionNode:ef,MeasureLayout:eo}},Uf=class extends sd{mount(){let{current:e}=this.node;e&&(this.unmount=On(e,(e,t)=>(to(this.node,t,`Start`),e=>to(this.node,e,`End`))))}unmount(){}},Wf=class extends sd{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=zs(_i(this.node.current,`focus`,()=>this.onFocus()),_i(this.node.current,`blur`,()=>this.onBlur()))}unmount(){}},Gf=class extends sd{mount(){let{current:e}=this.node;if(!e)return;let{globalTapTarget:t,propagate:n}=this.node.props;this.unmount=Pn(e,(e,t)=>(no(this.node,t,`Start`),(e,{success:t})=>no(this.node,e,t?`End`:`Cancel`)),{useGlobalTarget:t,stopPropagation:n?.tap===!1})}unmount(){}},Kf=new WeakMap,qf=new WeakMap,Jf=e=>{let t=Kf.get(e.target);t&&t(e)},Yf=e=>{e.forEach(Jf)},Xf={some:0,all:1},Zf=class extends sd{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.stopObserver?.();let{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:r=`some`,once:i}=e,a={root:t?t.current:void 0,rootMargin:n,threshold:typeof r==`number`?r:Xf[r]};this.stopObserver=io(this.node.current,a,e=>{let{isIntersecting:t}=e;if(this.isInView===t||(this.isInView=t,i&&!t&&this.hasEnteredView))return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive(`whileInView`,t);let{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),a=t?n:r;a&&a(e)})}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>`u`)return;let{props:e,prevProps:t}=this.node;[`amount`,`margin`,`root`].some(ao(e,t))&&this.startObserver()}unmount(){this.stopObserver?.(),this.hasEnteredView=!1,this.isInView=!1}},Qf={inView:{Feature:Zf},tap:{Feature:Gf},focus:{Feature:Wf},hover:{Feature:Uf}},$f={layout:{ProjectionNode:ef,MeasureLayout:eo}},ep=Aa({...Df,...Qf,...Hf,...$f},Af),tp={renderer:Af,...Df,...Qf},{...tp,...Hf,...$f},{...Df},np=50,rp=()=>({current:0,offset:[],progress:0,scrollLength:0,targetOffset:0,targetLength:0,containerLength:0,velocity:0}),ip=()=>({time:0,x:rp(),y:rp()}),ap={x:{length:`Width`,position:`Left`},y:{length:`Height`,position:`Top`}},op={start:0,center:.5,end:1},sp=[0,0],cp={Enter:[[0,1],[1,1]],Exit:[[0,0],[1,0]],Any:[[1,0],[0,1]],All:[[0,0],[1,1]]},lp={x:0,y:0},up=new WeakMap,dp=new WeakMap,fp=new WeakMap,pp=new WeakMap,mp=new WeakMap,hp=e=>e===document.scrollingElement?f:e,gp=[[cp.Enter,`entry`],[cp.Exit,`exit`],[cp.Any,`cover`],[cp.All,`contain`]],_p={start:0,end:1},vp=new Map,yp=()=>({scrollX:D(0),scrollY:D(0),scrollXProgress:D(0),scrollYProgress:D(0)}),bp=e=>e?!e.current:!1,xp=class extends uu{constructor(){super(...arguments),this.isEnabled=!1}add(e){(xl.has(e)||Hl.has(e))&&(this.isEnabled=!0,this.update())}update(){this.set(this.isEnabled?`transform`:`auto`)}},Sp=`easeInOut`,Cp=20,wp=e=>typeof e==`number`,Tp=e=>e.every(wp),Ep=ds(),Dp=fs,Op={some:0,all:1},kp=()=>({}),gf({scrapeMotionValuesFromProps:kp,createRenderState:kp}),Ap={},fe(Ap,{Group:()=>Mp,Item:()=>zp}),jp=a(null),Mp=h(Ss),Np=50,Pp=25,Fp=new Set([`auto`,`scroll`]),Ip=new WeakMap,Lp=new WeakMap,Rp=null,zp=h(As)})),Vp=t((()=>{Bp()}));export{Oe as $,Qn as A,Vo as B,D as C,ht as D,Do as E,hs as F,Zu as G,Ao as H,bs as I,xe as J,Hs as K,jo as L,Dp as M,zo as N,Kn as O,ys as P,Te as Q,Qi as R,ep as S,yi as T,Ro as U,_s as V,Po as W,he as X,ye as Y,Ee as Z,Bp as _,$ as a,X as b,Ps as c,kr as d,De as et,Ep as f,vs as g,B as h,ca as i,ke as it,ms as j,qn as k,_f as l,V as m,af as n,be as nt,F as o,Dt as p,de as q,lf as r,me as rt,uu as s,Vp as t,Se as tt,xp as u,yt as v,pu as w,aa as x,ps as y,Bo as z}; //# sourceMappingURL=motion.pkCI_qw9.mjs.map