tcce-design-system 0.3.21 → 0.3.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- (function(S,g){typeof exports=="object"&&typeof module<"u"?g(exports,require("styled-components"),require("react/jsx-runtime"),require("react"),require("react-dom"),require("formik")):typeof define=="function"&&define.amd?define(["exports","styled-components","react/jsx-runtime","react","react-dom","formik"],g):(S=typeof globalThis<"u"?globalThis:S||self,g(S["tcce-design-system-components"]={},S.styled,S["react/jsx-runtime"],S.React,S.ReactDOM,S.Formik))})(this,(function(S,g,p,m,Vn,Mc){"use strict";function Vc(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const o=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,o.get?o:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const Ue=Vc(m),En={80:g.css`
1
+ (function(C,g){typeof exports=="object"&&typeof module<"u"?g(exports,require("styled-components"),require("react/jsx-runtime"),require("react"),require("react-dom"),require("formik")):typeof define=="function"&&define.amd?define(["exports","styled-components","react/jsx-runtime","react","react-dom","formik"],g):(C=typeof globalThis<"u"?globalThis:C||self,g(C["tcce-design-system-components"]={},C.styled,C["react/jsx-runtime"],C.React,C.ReactDOM,C.Formik))})(this,(function(C,g,p,m,En,Vc){"use strict";function Ec(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const o=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,o.get?o:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const Ue=Ec(m),Dn={80:g.css`
2
2
  font-family: 'Dax', serif;
3
3
  font-size: 5em;
4
4
  font-style: normal;
@@ -40,7 +40,7 @@
40
40
  font-style: normal;
41
41
  font-weight: 700;
42
42
  line-height: 161.76%;
43
- `},Hr={80:g.css`
43
+ `},Gr={80:g.css`
44
44
  font-family: 'Dax', serif;
45
45
  font-size: 5em;
46
46
  font-style: normal;
@@ -142,19 +142,19 @@
142
142
  font-style: normal;
143
143
  font-weight: 400;
144
144
  line-height: 133%;
145
- `},jr=g.h1`
146
- ${({size:e=24})=>En[e]}
145
+ `},Ur=g.h1`
146
+ ${({size:e=24})=>Dn[e]}
147
147
  margin: 0;
148
148
  color: ${({color:e})=>e||"var(--color-main-blue-primary)"};
149
- `,Ec=g.h2`
150
- ${({size:e=24})=>Hr[e]}
149
+ `,Dc=g.h2`
150
+ ${({size:e=24})=>Gr[e]}
151
151
  margin: 0;
152
152
  color: ${({color:e})=>e||"var(--color-main-blue-primary)"};
153
153
  `,Ie=g.span`
154
154
  ${({size:e=16})=>D[e]}
155
155
  margin: 0;
156
156
  color: ${({color:e})=>e||"var(--color-main-blue-primary)"};
157
- `,Dc=g.span`
157
+ `,Fc=g.span`
158
158
  display: inline-flex;
159
159
  align-items: center;
160
160
  justify-content: center;
@@ -164,15 +164,15 @@
164
164
  outline: none;
165
165
  box-shadow: var(--shadow-hover-black-card);
166
166
  }
167
- `,Gr={tn:"1rem",sm:"1.5rem",md:"2rem",lg:"3rem"},U=({component:e,size:t="1.5rem",color:n="currentColor",className:o,iconProps:r={}})=>{const i=typeof t=="string"&&t in Gr?Gr[t]:t;return p.jsx(Dc,{$color:n,className:o,children:typeof e=="function"?p.jsx(e,{size:i,...r}):e})},Dn=m.createContext({});function Fn(e){const t=m.useRef(null);return t.current===null&&(t.current=e()),t.current}const Ur=typeof window<"u",Kr=Ur?m.useLayoutEffect:m.useEffect,Ut=m.createContext(null);function An(e,t){e.indexOf(t)===-1&&e.push(t)}function In(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const $e=(e,t,n)=>n>t?t:n<e?e:n;function Ln(e,t){return t?`${e}. For more information and steps for solving, visit https://motion.dev/troubleshooting/${t}`:e}let tt=()=>{},Ve=()=>{};typeof process<"u"&&process.env?.NODE_ENV!=="production"&&(tt=(e,t,n)=>{!e&&typeof console<"u"&&console.warn(Ln(t,n))},Ve=(e,t,n)=>{if(!e)throw new Error(Ln(t,n))});const Ee={},Wr=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function qr(e){return typeof e=="object"&&e!==null}const Yr=e=>/^0[^.\s]+$/u.test(e);function Rn(e){let t;return()=>(t===void 0&&(t=e()),t)}const pe=e=>e,Fc=(e,t)=>n=>t(e(n)),Ct=(...e)=>e.reduce(Fc),Tt=(e,t,n)=>{const o=t-e;return o===0?1:(n-e)/o};class _n{constructor(){this.subscriptions=[]}add(t){return An(this.subscriptions,t),()=>In(this.subscriptions,t)}notify(t,n,o){const r=this.subscriptions.length;if(r)if(r===1)this.subscriptions[0](t,n,o);else for(let i=0;i<r;i++){const s=this.subscriptions[i];s&&s(t,n,o)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const Pe=e=>e*1e3,ge=e=>e/1e3;function Xr(e,t){return t?e*(1e3/t):0}const Zr=new Set;function Nn(e,t,n){e||Zr.has(t)||(console.warn(Ln(t,n)),Zr.add(t))}const Jr=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Ac=1e-7,Ic=12;function Lc(e,t,n,o,r){let i,s,a=0;do s=t+(n-t)/2,i=Jr(s,o,r)-e,i>0?n=s:t=s;while(Math.abs(i)>Ac&&++a<Ic);return s}function $t(e,t,n,o){if(e===t&&n===o)return pe;const r=i=>Lc(i,0,1,e,n);return i=>i===0||i===1?i:Jr(r(i),t,o)}const Qr=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,ei=e=>t=>1-e(1-t),ti=$t(.33,1.53,.69,.99),Bn=ei(ti),ni=Qr(Bn),oi=e=>(e*=2)<1?.5*Bn(e):.5*(2-Math.pow(2,-10*(e-1))),zn=e=>1-Math.sin(Math.acos(e)),ri=ei(zn),ii=Qr(zn),Rc=$t(.42,0,1,1),_c=$t(0,0,.58,1),si=$t(.42,0,.58,1),Nc=e=>Array.isArray(e)&&typeof e[0]!="number",ai=e=>Array.isArray(e)&&typeof e[0]=="number",li={linear:pe,easeIn:Rc,easeInOut:si,easeOut:_c,circIn:zn,circInOut:ii,circOut:ri,backIn:Bn,backInOut:ni,backOut:ti,anticipate:oi},Bc=e=>typeof e=="string",ci=e=>{if(ai(e)){Ve(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");const[t,n,o,r]=e;return $t(t,n,o,r)}else if(Bc(e))return Ve(li[e]!==void 0,`Invalid easing type '${e}'`,"invalid-easing-type"),li[e];return e},Kt=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function zc(e,t){let n=new Set,o=new Set,r=!1,i=!1;const s=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1};function l(d){s.has(d)&&(c.schedule(d),e()),d(a)}const c={schedule:(d,u=!1,h=!1)=>{const v=h&&r?n:o;return u&&s.add(d),v.has(d)||v.add(d),d},cancel:d=>{o.delete(d),s.delete(d)},process:d=>{if(a=d,r){i=!0;return}r=!0,[n,o]=[o,n],n.forEach(l),n.clear(),r=!1,i&&(i=!1,c.process(d))}};return c}const Oc=40;function ui(e,t){let n=!1,o=!0;const r={delta:0,timestamp:0,isProcessing:!1},i=()=>n=!0,s=Kt.reduce((x,P)=>(x[P]=zc(i),x),{}),{setup:a,read:l,resolveKeyframes:c,preUpdate:d,update:u,preRender:h,render:f,postRender:v}=s,y=()=>{const x=Ee.useManualTiming?r.timestamp:performance.now();n=!1,Ee.useManualTiming||(r.delta=o?1e3/60:Math.max(Math.min(x-r.timestamp,Oc),1)),r.timestamp=x,r.isProcessing=!0,a.process(r),l.process(r),c.process(r),d.process(r),u.process(r),h.process(r),f.process(r),v.process(r),r.isProcessing=!1,n&&t&&(o=!1,e(y))},b=()=>{n=!0,o=!0,r.isProcessing||e(y)};return{schedule:Kt.reduce((x,P)=>{const T=s[P];return x[P]=(k,V=!1,$=!1)=>(n||b(),T.schedule(k,V,$)),x},{}),cancel:x=>{for(let P=0;P<Kt.length;P++)s[Kt[P]].cancel(x)},state:r,steps:s}}const{schedule:K,cancel:Le,state:oe,steps:On}=ui(typeof requestAnimationFrame<"u"?requestAnimationFrame:pe,!0);let Wt;function Hc(){Wt=void 0}const le={now:()=>(Wt===void 0&&le.set(oe.isProcessing||Ee.useManualTiming?oe.timestamp:performance.now()),Wt),set:e=>{Wt=e,queueMicrotask(Hc)}},di=e=>t=>typeof t=="string"&&t.startsWith(e),fi=di("--"),jc=di("var(--"),Hn=e=>jc(e)?Gc.test(e.split("/*")[0].trim()):!1,Gc=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function hi(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const nt={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Pt={...nt,transform:e=>$e(0,1,e)},qt={...nt,default:1},kt=e=>Math.round(e*1e5)/1e5,jn=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Uc(e){return e==null}const Kc=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Gn=(e,t)=>n=>!!(typeof n=="string"&&Kc.test(n)&&n.startsWith(e)||t&&!Uc(n)&&Object.prototype.hasOwnProperty.call(n,t)),mi=(e,t,n)=>o=>{if(typeof o!="string")return o;const[r,i,s,a]=o.match(jn);return{[e]:parseFloat(r),[t]:parseFloat(i),[n]:parseFloat(s),alpha:a!==void 0?parseFloat(a):1}},Wc=e=>$e(0,255,e),Un={...nt,transform:e=>Math.round(Wc(e))},Ke={test:Gn("rgb","red"),parse:mi("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:o=1})=>"rgba("+Un.transform(e)+", "+Un.transform(t)+", "+Un.transform(n)+", "+kt(Pt.transform(o))+")"};function qc(e){let t="",n="",o="",r="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),o=e.substring(5,7),r=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),o=e.substring(3,4),r=e.substring(4,5),t+=t,n+=n,o+=o,r+=r),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(o,16),alpha:r?parseInt(r,16)/255:1}}const Kn={test:Gn("#"),parse:qc,transform:Ke.transform},Mt=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Re=Mt("deg"),ke=Mt("%"),E=Mt("px"),Yc=Mt("vh"),Xc=Mt("vw"),pi={...ke,parse:e=>ke.parse(e)/100,transform:e=>ke.transform(e*100)},ot={test:Gn("hsl","hue"),parse:mi("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:o=1})=>"hsla("+Math.round(e)+", "+ke.transform(kt(t))+", "+ke.transform(kt(n))+", "+kt(Pt.transform(o))+")"},Q={test:e=>Ke.test(e)||Kn.test(e)||ot.test(e),parse:e=>Ke.test(e)?Ke.parse(e):ot.test(e)?ot.parse(e):Kn.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?Ke.transform(e):ot.transform(e),getAnimatableNone:e=>{const t=Q.parse(e);return t.alpha=0,Q.transform(t)}},Zc=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function Jc(e){return isNaN(e)&&typeof e=="string"&&(e.match(jn)?.length||0)+(e.match(Zc)?.length||0)>0}const gi="number",vi="color",Qc="var",eu="var(",yi="${}",tu=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Vt(e){const t=e.toString(),n=[],o={color:[],number:[],var:[]},r=[];let i=0;const a=t.replace(tu,l=>(Q.test(l)?(o.color.push(i),r.push(vi),n.push(Q.parse(l))):l.startsWith(eu)?(o.var.push(i),r.push(Qc),n.push(l)):(o.number.push(i),r.push(gi),n.push(parseFloat(l))),++i,yi)).split(yi);return{values:n,split:a,indexes:o,types:r}}function wi(e){return Vt(e).values}function bi(e){const{split:t,types:n}=Vt(e),o=t.length;return r=>{let i="";for(let s=0;s<o;s++)if(i+=t[s],r[s]!==void 0){const a=n[s];a===gi?i+=kt(r[s]):a===vi?i+=Q.transform(r[s]):i+=r[s]}return i}}const nu=e=>typeof e=="number"?0:Q.test(e)?Q.getAnimatableNone(e):e;function ou(e){const t=wi(e);return bi(e)(t.map(nu))}const _e={test:Jc,parse:wi,createTransformer:bi,getAnimatableNone:ou};function Wn(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function ru({hue:e,saturation:t,lightness:n,alpha:o}){e/=360,t/=100,n/=100;let r=0,i=0,s=0;if(!t)r=i=s=n;else{const a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;r=Wn(l,a,e+1/3),i=Wn(l,a,e),s=Wn(l,a,e-1/3)}return{red:Math.round(r*255),green:Math.round(i*255),blue:Math.round(s*255),alpha:o}}function Yt(e,t){return n=>n>0?t:e}const Y=(e,t,n)=>e+(t-e)*n,qn=(e,t,n)=>{const o=e*e,r=n*(t*t-o)+o;return r<0?0:Math.sqrt(r)},iu=[Kn,Ke,ot],su=e=>iu.find(t=>t.test(e));function xi(e){const t=su(e);if(tt(!!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===ot&&(n=ru(n)),n}const Si=(e,t)=>{const n=xi(e),o=xi(t);if(!n||!o)return Yt(e,t);const r={...n};return i=>(r.red=qn(n.red,o.red,i),r.green=qn(n.green,o.green,i),r.blue=qn(n.blue,o.blue,i),r.alpha=Y(n.alpha,o.alpha,i),Ke.transform(r))},Yn=new Set(["none","hidden"]);function au(e,t){return Yn.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function lu(e,t){return n=>Y(e,t,n)}function Xn(e){return typeof e=="number"?lu:typeof e=="string"?Hn(e)?Yt:Q.test(e)?Si:du:Array.isArray(e)?Ci:typeof e=="object"?Q.test(e)?Si:cu:Yt}function Ci(e,t){const n=[...e],o=n.length,r=e.map((i,s)=>Xn(i)(i,t[s]));return i=>{for(let s=0;s<o;s++)n[s]=r[s](i);return n}}function cu(e,t){const n={...e,...t},o={};for(const r in n)e[r]!==void 0&&t[r]!==void 0&&(o[r]=Xn(e[r])(e[r],t[r]));return r=>{for(const i in o)n[i]=o[i](r);return n}}function uu(e,t){const n=[],o={color:0,var:0,number:0};for(let r=0;r<t.values.length;r++){const i=t.types[r],s=e.indexes[i][o[i]],a=e.values[s]??0;n[r]=a,o[i]++}return n}const du=(e,t)=>{const n=_e.createTransformer(t),o=Vt(e),r=Vt(t);return o.indexes.var.length===r.indexes.var.length&&o.indexes.color.length===r.indexes.color.length&&o.indexes.number.length>=r.indexes.number.length?Yn.has(e)&&!r.values.length||Yn.has(t)&&!o.values.length?au(e,t):Ct(Ci(uu(o,r),r.values),n):(tt(!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"),Yt(e,t))};function Ti(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?Y(e,t,n):Xn(e)(e,t)}const fu=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>K.update(t,n),stop:()=>Le(t),now:()=>oe.isProcessing?oe.timestamp:le.now()}},$i=(e,t,n=10)=>{let o="";const r=Math.max(Math.round(t/n),2);for(let i=0;i<r;i++)o+=Math.round(e(i/(r-1))*1e4)/1e4+", ";return`linear(${o.substring(0,o.length-2)})`},Xt=2e4;function Zn(e){let t=0;const n=50;let o=e.next(t);for(;!o.done&&t<Xt;)t+=n,o=e.next(t);return t>=Xt?1/0:t}function hu(e,t=100,n){const o=n({...e,keyframes:[0,t]}),r=Math.min(Zn(o),Xt);return{type:"keyframes",ease:i=>o.next(r*i).value/t,duration:ge(r)}}const mu=5;function Pi(e,t,n){const o=Math.max(t-mu,0);return Xr(n-e(o),t-o)}const X={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},Jn=.001;function pu({duration:e=X.duration,bounce:t=X.bounce,velocity:n=X.velocity,mass:o=X.mass}){let r,i;tt(e<=Pe(X.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let s=1-t;s=$e(X.minDamping,X.maxDamping,s),e=$e(X.minDuration,X.maxDuration,ge(e)),s<1?(r=c=>{const d=c*s,u=d*e,h=d-n,f=Qn(c,s),v=Math.exp(-u);return Jn-h/f*v},i=c=>{const u=c*s*e,h=u*n+n,f=Math.pow(s,2)*Math.pow(c,2)*e,v=Math.exp(-u),y=Qn(Math.pow(c,2),s);return(-r(c)+Jn>0?-1:1)*((h-f)*v)/y}):(r=c=>{const d=Math.exp(-c*e),u=(c-n)*e+1;return-Jn+d*u},i=c=>{const d=Math.exp(-c*e),u=(n-c)*(e*e);return d*u});const a=5/e,l=vu(r,i,a);if(e=Pe(e),isNaN(l))return{stiffness:X.stiffness,damping:X.damping,duration:e};{const c=Math.pow(l,2)*o;return{stiffness:c,damping:s*2*Math.sqrt(o*c),duration:e}}}const gu=12;function vu(e,t,n){let o=n;for(let r=1;r<gu;r++)o=o-e(o)/t(o);return o}function Qn(e,t){return e*Math.sqrt(1-t*t)}const yu=["duration","bounce"],wu=["stiffness","damping","mass"];function ki(e,t){return t.some(n=>e[n]!==void 0)}function bu(e){let t={velocity:X.velocity,stiffness:X.stiffness,damping:X.damping,mass:X.mass,isResolvedFromDuration:!1,...e};if(!ki(e,wu)&&ki(e,yu))if(e.visualDuration){const n=e.visualDuration,o=2*Math.PI/(n*1.2),r=o*o,i=2*$e(.05,1,1-(e.bounce||0))*Math.sqrt(r);t={...t,mass:X.mass,stiffness:r,damping:i}}else{const n=pu(e);t={...t,...n,mass:X.mass},t.isResolvedFromDuration=!0}return t}function Zt(e=X.visualDuration,t=X.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:o,restDelta:r}=n;const i=n.keyframes[0],s=n.keyframes[n.keyframes.length-1],a={done:!1,value:i},{stiffness:l,damping:c,mass:d,duration:u,velocity:h,isResolvedFromDuration:f}=bu({...n,velocity:-ge(n.velocity||0)}),v=h||0,y=c/(2*Math.sqrt(l*d)),b=s-i,w=ge(Math.sqrt(l/d)),C=Math.abs(b)<5;o||(o=C?X.restSpeed.granular:X.restSpeed.default),r||(r=C?X.restDelta.granular:X.restDelta.default);let x;if(y<1){const T=Qn(w,y);x=k=>{const V=Math.exp(-y*w*k);return s-V*((v+y*w*b)/T*Math.sin(T*k)+b*Math.cos(T*k))}}else if(y===1)x=T=>s-Math.exp(-w*T)*(b+(v+w*b)*T);else{const T=w*Math.sqrt(y*y-1);x=k=>{const V=Math.exp(-y*w*k),$=Math.min(T*k,300);return s-V*((v+y*w*b)*Math.sinh($)+T*b*Math.cosh($))/T}}const P={calculatedDuration:f&&u||null,next:T=>{const k=x(T);if(f)a.done=T>=u;else{let V=T===0?v:0;y<1&&(V=T===0?Pe(v):Pi(x,T,k));const $=Math.abs(V)<=o,A=Math.abs(s-k)<=r;a.done=$&&A}return a.value=a.done?s:k,a},toString:()=>{const T=Math.min(Zn(P),Xt),k=$i(V=>P.next(T*V).value,T,30);return T+"ms "+k},toTransition:()=>{}};return P}Zt.applyToOptions=e=>{const t=hu(e,100,Zt);return e.ease=t.ease,e.duration=Pe(t.duration),e.type="keyframes",e};function eo({keyframes:e,velocity:t=0,power:n=.8,timeConstant:o=325,bounceDamping:r=10,bounceStiffness:i=500,modifyTarget:s,min:a,max:l,restDelta:c=.5,restSpeed:d}){const u=e[0],h={done:!1,value:u},f=$=>a!==void 0&&$<a||l!==void 0&&$>l,v=$=>a===void 0?l:l===void 0||Math.abs(a-$)<Math.abs(l-$)?a:l;let y=n*t;const b=u+y,w=s===void 0?b:s(b);w!==b&&(y=w-u);const C=$=>-y*Math.exp(-$/o),x=$=>w+C($),P=$=>{const A=C($),I=x($);h.done=Math.abs(A)<=c,h.value=h.done?w:I};let T,k;const V=$=>{f(h.value)&&(T=$,k=Zt({keyframes:[h.value,v(h.value)],velocity:Pi(x,$,h.value),damping:r,stiffness:i,restDelta:c,restSpeed:d}))};return V(0),{calculatedDuration:null,next:$=>{let A=!1;return!k&&T===void 0&&(A=!0,P($),V($)),T!==void 0&&$>=T?k.next($-T):(!A&&P($),h)}}}function xu(e,t,n){const o=[],r=n||Ee.mix||Ti,i=e.length-1;for(let s=0;s<i;s++){let a=r(e[s],e[s+1]);if(t){const l=Array.isArray(t)?t[s]||pe:t;a=Ct(l,a)}o.push(a)}return o}function Su(e,t,{clamp:n=!0,ease:o,mixer:r}={}){const i=e.length;if(Ve(i===t.length,"Both input and output ranges must be the same length","range-length"),i===1)return()=>t[0];if(i===2&&t[0]===t[1])return()=>t[1];const s=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=xu(t,o,r),l=a.length,c=d=>{if(s&&d<e[0])return t[0];let u=0;if(l>1)for(;u<e.length-2&&!(d<e[u+1]);u++);const h=Tt(e[u],e[u+1],d);return a[u](h)};return n?d=>c($e(e[0],e[i-1],d)):c}function Cu(e,t){const n=e[e.length-1];for(let o=1;o<=t;o++){const r=Tt(0,t,o);e.push(Y(n,1,r))}}function Tu(e){const t=[0];return Cu(t,e.length-1),t}function $u(e,t){return e.map(n=>n*t)}function Pu(e,t){return e.map(()=>t||si).splice(0,e.length-1)}function rt({duration:e=300,keyframes:t,times:n,ease:o="easeInOut"}){const r=Nc(o)?o.map(ci):ci(o),i={done:!1,value:t[0]},s=$u(n&&n.length===t.length?n:Tu(t),e),a=Su(s,t,{ease:Array.isArray(r)?r:Pu(t,r)});return{calculatedDuration:e,next:l=>(i.value=a(l),i.done=l>=e,i)}}const ku=e=>e!==null;function to(e,{repeat:t,repeatType:n="loop"},o,r=1){const i=e.filter(ku),a=r<0||t&&n!=="loop"&&t%2===1?0:i.length-1;return!a||o===void 0?i[a]:o}const Mu={decay:eo,inertia:eo,tween:rt,keyframes:rt,spring:Zt};function Mi(e){typeof e.type=="string"&&(e.type=Mu[e.type])}class no{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const Vu=e=>e/100;class oo extends no{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{const{motionValue:n}=this.options;n&&n.updatedAt!==le.now()&&this.tick(le.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;Mi(t);const{type:n=rt,repeat:o=0,repeatDelay:r=0,repeatType:i,velocity:s=0}=t;let{keyframes:a}=t;const l=n||rt;process.env.NODE_ENV!=="production"&&l!==rt&&Ve(a.length<=2,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${a}`,"spring-two-frames"),l!==rt&&typeof a[0]!="number"&&(this.mixKeyframes=Ct(Vu,Ti(a[0],a[1])),a=[0,100]);const c=l({...t,keyframes:a});i==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...a].reverse(),velocity:-s})),c.calculatedDuration===null&&(c.calculatedDuration=Zn(c));const{calculatedDuration:d}=c;this.calculatedDuration=d,this.resolvedDuration=d+r,this.totalDuration=this.resolvedDuration*(o+1)-r,this.generator=c}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:o,totalDuration:r,mixKeyframes:i,mirroredGenerator:s,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return o.next(0);const{delay:c=0,keyframes:d,repeat:u,repeatType:h,repeatDelay:f,type:v,onUpdate:y,finalKeyframe:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-r/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const w=this.currentTime-c*(this.playbackSpeed>=0?1:-1),C=this.playbackSpeed>=0?w<0:w>r;this.currentTime=Math.max(w,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=r);let x=this.currentTime,P=o;if(u){const $=Math.min(this.currentTime,r)/a;let A=Math.floor($),I=$%1;!I&&$>=1&&(I=1),I===1&&A--,A=Math.min(A,u+1),A%2&&(h==="reverse"?(I=1-I,f&&(I-=f/a)):h==="mirror"&&(P=s)),x=$e(0,1,I)*a}const T=C?{done:!1,value:d[0]}:P.next(x);i&&(T.value=i(T.value));let{done:k}=T;!C&&l!==null&&(k=this.playbackSpeed>=0?this.currentTime>=r:this.currentTime<=0);const V=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&k);return V&&v!==eo&&(T.value=to(d,this.options,b,this.speed)),y&&y(T.value),V&&this.finish(),T}then(t,n){return this.finished.then(t,n)}get duration(){return ge(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+ge(t)}get time(){return ge(this.currentTime)}set time(t){t=Pe(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(le.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=ge(this.currentTime))}play(){if(this.isStopped)return;const{driver:t=fu,startTime:n}=this.options;this.driver||(this.driver=t(r=>this.tick(r))),this.options.onPlay?.();const o=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=o):this.holdTime!==null?this.startTime=o-this.holdTime:this.startTime||(this.startTime=n??o),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(le.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}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}}function Eu(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const We=e=>e*180/Math.PI,ro=e=>{const t=We(Math.atan2(e[1],e[0]));return io(t)},Du={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:ro,rotateZ:ro,skewX:e=>We(Math.atan(e[1])),skewY:e=>We(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},io=e=>(e=e%360,e<0&&(e+=360),e),Vi=ro,Ei=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),Di=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),Fu={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Ei,scaleY:Di,scale:e=>(Ei(e)+Di(e))/2,rotateX:e=>io(We(Math.atan2(e[6],e[5]))),rotateY:e=>io(We(Math.atan2(-e[2],e[0]))),rotateZ:Vi,rotate:Vi,skewX:e=>We(Math.atan(e[4])),skewY:e=>We(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function so(e){return e.includes("scale")?1:0}function ao(e,t){if(!e||e==="none")return so(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let o,r;if(n)o=Fu,r=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);o=Du,r=a}if(!r)return so(t);const i=o[t],s=r[1].split(",").map(Iu);return typeof i=="function"?i(s):s[i]}const Au=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return ao(n,t)};function Iu(e){return parseFloat(e.trim())}const it=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],st=new Set(it),Fi=e=>e===nt||e===E,Lu=new Set(["x","y","z"]),Ru=it.filter(e=>!Lu.has(e));function _u(e){const t=[];return Ru.forEach(n=>{const o=e.getValue(n);o!==void 0&&(t.push([n,o.get()]),o.set(n.startsWith("scale")?1:0))}),t}const Ne={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-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})=>ao(t,"x"),y:(e,{transform:t})=>ao(t,"y")};Ne.translateX=Ne.x,Ne.translateY=Ne.y;const qe=new Set;let lo=!1,co=!1,uo=!1;function Ai(){if(co){const e=Array.from(qe).filter(o=>o.needsMeasurement),t=new Set(e.map(o=>o.element)),n=new Map;t.forEach(o=>{const r=_u(o);r.length&&(n.set(o,r),o.render())}),e.forEach(o=>o.measureInitialState()),t.forEach(o=>{o.render();const r=n.get(o);r&&r.forEach(([i,s])=>{o.getValue(i)?.set(s)})}),e.forEach(o=>o.measureEndState()),e.forEach(o=>{o.suspendedScrollY!==void 0&&window.scrollTo(0,o.suspendedScrollY)})}co=!1,lo=!1,qe.forEach(e=>e.complete(uo)),qe.clear()}function Ii(){qe.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(co=!0)})}function Nu(){uo=!0,Ii(),Ai(),uo=!1}class fo{constructor(t,n,o,r,i,s=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=o,this.motionValue=r,this.element=i,this.isAsync=s}scheduleResolve(){this.state="scheduled",this.isAsync?(qe.add(this),lo||(lo=!0,K.read(Ii),K.resolveKeyframes(Ai))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:o,motionValue:r}=this;if(t[0]===null){const i=r?.get(),s=t[t.length-1];if(i!==void 0)t[0]=i;else if(o&&n){const a=o.readValue(n,s);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=s),r&&i===void 0&&r.set(t[0])}Eu(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),qe.delete(this)}cancel(){this.state==="scheduled"&&(qe.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const Bu=e=>e.startsWith("--");function zu(e,t,n){Bu(t)?e.style.setProperty(t,n):e.style[t]=n}const Ou=Rn(()=>window.ScrollTimeline!==void 0),Hu={};function ju(e,t){const n=Rn(e);return()=>Hu[t]??n()}const Li=ju(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),Et=([e,t,n,o])=>`cubic-bezier(${e}, ${t}, ${n}, ${o})`,Ri={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Et([0,.65,.55,1]),circOut:Et([.55,0,1,.45]),backIn:Et([.31,.01,.66,-.59]),backOut:Et([.33,1.53,.69,.99])};function _i(e,t){if(e)return typeof e=="function"?Li()?$i(e,t):"ease-out":ai(e)?Et(e):Array.isArray(e)?e.map(n=>_i(n,t)||Ri.easeOut):Ri[e]}function Gu(e,t,n,{delay:o=0,duration:r=300,repeat:i=0,repeatType:s="loop",ease:a="easeOut",times:l}={},c=void 0){const d={[t]:n};l&&(d.offset=l);const u=_i(a,r);Array.isArray(u)&&(d.easing=u);const h={delay:o,duration:r,easing:Array.isArray(u)?"linear":u,fill:"both",iterations:i+1,direction:s==="reverse"?"alternate":"normal"};return c&&(h.pseudoElement=c),e.animate(d,h)}function Ni(e){return typeof e=="function"&&"applyToOptions"in e}function Uu({type:e,...t}){return Ni(e)&&Li()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class Ku extends no{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:o,keyframes:r,pseudoElement:i,allowFlatten:s=!1,finalKeyframe:a,onComplete:l}=t;this.isPseudoElement=!!i,this.allowFlatten=s,this.options=t,Ve(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");const c=Uu(t);this.animation=Gu(n,o,r,c,i),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){const d=to(r,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(d):zu(n,o,d),this.animation.cancel()}l?.(),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;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){const t=this.animation.effect?.getComputedTiming?.().duration||0;return ge(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+ge(t)}get time(){return ge(Number(this.animation.currentTime)||0)}set time(t){this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=Pe(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,observe:n}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&Ou()?(this.animation.timeline=t,pe):n(this)}}const Bi={anticipate:oi,backInOut:ni,circInOut:ii};function Wu(e){return e in Bi}function qu(e){typeof e.ease=="string"&&Wu(e.ease)&&(e.ease=Bi[e.ease])}const ho=10;class Yu extends Ku{constructor(t){qu(t),Mi(t),super(t),t.startTime!==void 0&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:o,onComplete:r,element:i,...s}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new oo({...s,autoplay:!1}),l=Math.max(ho,le.now()-this.startTime),c=$e(0,ho,l-ho);n.setWithVelocity(a.sample(Math.max(0,l-c)).value,a.sample(l).value,c),a.stop()}}const zi=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(_e.test(e)||e==="0")&&!e.startsWith("url("));function Xu(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function Zu(e,t,n,o){const r=e[0];if(r===null)return!1;if(t==="display"||t==="visibility")return!0;const i=e[e.length-1],s=zi(r,t),a=zi(i,t);return tt(s===a,`You are trying to animate ${t} from "${r}" to "${i}". "${s?i:r}" is not an animatable value.`,"value-not-animatable"),!s||!a?!1:Xu(e)||(n==="spring"||Ni(n))&&o}function mo(e){e.duration=0,e.type="keyframes"}const Ju=new Set(["opacity","clipPath","filter","transform"]),Qu=Rn(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function ed(e){const{motionValue:t,name:n,repeatDelay:o,repeatType:r,damping:i,type:s}=e;if(!(t?.owner?.current instanceof HTMLElement))return!1;const{onUpdate:l,transformTemplate:c}=t.owner.getProps();return Qu()&&n&&Ju.has(n)&&(n!=="transform"||!c)&&!l&&!o&&r!=="mirror"&&i!==0&&s!=="inertia"}const td=40;class nd extends no{constructor({autoplay:t=!0,delay:n=0,type:o="keyframes",repeat:r=0,repeatDelay:i=0,repeatType:s="loop",keyframes:a,name:l,motionValue:c,element:d,...u}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=le.now();const h={autoplay:t,delay:n,type:o,repeat:r,repeatDelay:i,repeatType:s,name:l,motionValue:c,element:d,...u},f=d?.KeyframeResolver||fo;this.keyframeResolver=new f(a,(v,y,b)=>this.onKeyframesResolved(v,y,h,!b),l,c,d),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,n,o,r){this.keyframeResolver=void 0;const{name:i,type:s,velocity:a,delay:l,isHandoff:c,onUpdate:d}=o;this.resolvedAt=le.now(),Zu(t,i,s,a)||((Ee.instantAnimations||!l)&&d?.(to(t,o,n)),t[0]=t[t.length-1],mo(o),o.repeat=0);const h={startTime:r?this.resolvedAt?this.resolvedAt-this.createdAt>td?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...o,keyframes:t},f=!c&&ed(h)?new Yu({...h,element:h.motionValue.owner.current}):new oo(h);f.finished.then(()=>this.notifyFinished()).catch(pe),this.pendingTimeline&&(this.stopTimeline=f.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=f}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),Nu()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}const od=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function rd(e){const t=od.exec(e);if(!t)return[,];const[,n,o,r]=t;return[`--${n??o}`,r]}const id=4;function Oi(e,t,n=1){Ve(n<=id,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");const[o,r]=rd(e);if(!o)return;const i=window.getComputedStyle(t).getPropertyValue(o);if(i){const s=i.trim();return Wr(s)?parseFloat(s):s}return Hn(r)?Oi(r,t,n+1):r}function po(e,t){return e?.[t]??e?.default??e}const sd={type:"spring",stiffness:500,damping:25,restSpeed:10},ad=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),ld={type:"keyframes",duration:.8},cd={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},ud=(e,{keyframes:t})=>t.length>2?ld:st.has(e)?e.startsWith("scale")?ad(t[1]):sd:cd;function dd({when:e,delay:t,delayChildren:n,staggerChildren:o,staggerDirection:r,repeat:i,repeatType:s,repeatDelay:a,from:l,elapsed:c,...d}){return!!Object.keys(d).length}const fd=e=>e!==null;function hd(e,{repeat:t,repeatType:n="loop"},o){const r=e.filter(fd),i=t&&n!=="loop"&&t%2===1?0:r.length-1;return r[i]}function Hi(e,t,n,o=0,r=1){const i=Array.from(e).sort((c,d)=>c.sortNodePosition(d)).indexOf(t),s=e.size,a=(s-1)*o;return typeof n=="function"?n(i,s):r===1?i*o:a-i*o}const go=(e,t,n,o={},r,i)=>s=>{const a=po(o,e)||{},l=a.delay||o.delay||0;let{elapsed:c=0}=o;c=c-Pe(l);const d={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-c,onUpdate:h=>{t.set(h),a.onUpdate&&a.onUpdate(h)},onComplete:()=>{s(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:i?void 0:r};dd(a)||Object.assign(d,ud(e,d)),d.duration&&(d.duration=Pe(d.duration)),d.repeatDelay&&(d.repeatDelay=Pe(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let u=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(mo(d),d.delay===0&&(u=!0)),(Ee.instantAnimations||Ee.skipAnimations)&&(u=!0,mo(d),d.delay=0),d.allowFlatten=!a.type&&!a.ease,u&&!i&&t.get()!==void 0){const h=hd(d.keyframes,a);if(h!==void 0){K.update(()=>{d.onUpdate(h),d.onComplete()});return}}return a.isSync?new oo(d):new nd(d)},ji=new Set(["width","height","top","left","right","bottom",...it]),Gi=30,md=e=>!isNaN(parseFloat(e));class pd{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=o=>{const r=le.now();if(this.updatedAt!==r&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(o),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(const i of this.dependents)i.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=le.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=md(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return process.env.NODE_ENV!=="production"&&Nn(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new _n);const o=this.events[t].add(n);return t==="change"?()=>{o(),K.read(()=>{this.events.change.getSize()||this.stop()})}:o}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,o){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-o}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=le.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Gi)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Gi);return Xr(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function at(e,t){return new pd(e,t)}function Ui(e){const t=[{},{}];return e?.values.forEach((n,o)=>{t[0][o]=n.get(),t[1][o]=n.getVelocity()}),t}function vo(e,t,n,o){if(typeof t=="function"){const[r,i]=Ui(o);t=t(n!==void 0?n:e.custom,r,i)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[r,i]=Ui(o);t=t(n!==void 0?n:e.custom,r,i)}return t}function lt(e,t,n){const o=e.getProps();return vo(o,t,n!==void 0?n:o.custom,e)}const yo=e=>Array.isArray(e);function gd(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,at(n))}function vd(e){return yo(e)?e[e.length-1]||0:e}function yd(e,t){const n=lt(e,t);let{transitionEnd:o={},transition:r={},...i}=n||{};i={...i,...o};for(const s in i){const a=vd(i[s]);gd(e,s,a)}}const ie=e=>!!(e&&e.getVelocity);function wd(e){return!!(ie(e)&&e.add)}function wo(e,t){const n=e.getValue("willChange");if(wd(n))return n.add(t);if(!n&&Ee.WillChange){const o=new Ee.WillChange("auto");e.addValue("willChange",o),o.add(t)}}function bo(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const Ki="data-"+bo("framerAppearId");function Wi(e){return e.props[Ki]}function bd({protectedKeys:e,needsAnimating:t},n){const o=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,o}function qi(e,t,{delay:n=0,transitionOverride:o,type:r}={}){let{transition:i=e.getDefaultTransition(),transitionEnd:s,...a}=t;o&&(i=o);const l=[],c=r&&e.animationState&&e.animationState.getState()[r];for(const d in a){const u=e.getValue(d,e.latestValues[d]??null),h=a[d];if(h===void 0||c&&bd(c,d))continue;const f={delay:n,...po(i||{},d)},v=u.get();if(v!==void 0&&!u.isAnimating&&!Array.isArray(h)&&h===v&&!f.velocity)continue;let y=!1;if(window.MotionHandoffAnimation){const w=Wi(e);if(w){const C=window.MotionHandoffAnimation(w,d,K);C!==null&&(f.startTime=C,y=!0)}}wo(e,d),u.start(go(d,u,h,e.shouldReduceMotion&&ji.has(d)?{type:!1}:f,e,y));const b=u.animation;b&&l.push(b)}return s&&Promise.all(l).then(()=>{K.update(()=>{s&&yd(e,s)})}),l}function xo(e,t,n={}){const o=lt(e,t,n.type==="exit"?e.presenceContext?.custom:void 0);let{transition:r=e.getDefaultTransition()||{}}=o||{};n.transitionOverride&&(r=n.transitionOverride);const i=o?()=>Promise.all(qi(e,o,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(l=0)=>{const{delayChildren:c=0,staggerChildren:d,staggerDirection:u}=r;return xd(e,t,l,c,d,u,n)}:()=>Promise.resolve(),{when:a}=r;if(a){const[l,c]=a==="beforeChildren"?[i,s]:[s,i];return l().then(()=>c())}else return Promise.all([i(),s(n.delay)])}function xd(e,t,n=0,o=0,r=0,i=1,s){const a=[];for(const l of e.variantChildren)l.notify("AnimationStart",t),a.push(xo(l,t,{...s,delay:n+(typeof o=="function"?0:o)+Hi(e.variantChildren,l,o,r,i)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(a)}function Sd(e,t,n={}){e.notify("AnimationStart",t);let o;if(Array.isArray(t)){const r=t.map(i=>xo(e,i,n));o=Promise.all(r)}else if(typeof t=="string")o=xo(e,t,n);else{const r=typeof t=="function"?lt(e,t,n.custom):t;o=Promise.all(qi(e,r,n))}return o.then(()=>{e.notify("AnimationComplete",t)})}const Cd={test:e=>e==="auto",parse:e=>e},Yi=e=>t=>t.test(e),Xi=[nt,E,ke,Re,Xc,Yc,Cd],Zi=e=>Xi.find(Yi(e));function Td(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||Yr(e):!0}const $d=new Set(["brightness","contrast","saturate","opacity"]);function Pd(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[o]=n.match(jn)||[];if(!o)return e;const r=n.replace(o,"");let i=$d.has(t)?1:0;return o!==n&&(i*=100),t+"("+i+r+")"}const kd=/\b([a-z-]*)\(.*?\)/gu,So={..._e,getAnimatableNone:e=>{const t=e.match(kd);return t?t.map(Pd).join(" "):e}},Ji={...nt,transform:Math.round},Co={borderWidth:E,borderTopWidth:E,borderRightWidth:E,borderBottomWidth:E,borderLeftWidth:E,borderRadius:E,radius:E,borderTopLeftRadius:E,borderTopRightRadius:E,borderBottomRightRadius:E,borderBottomLeftRadius:E,width:E,maxWidth:E,height:E,maxHeight:E,top:E,right:E,bottom:E,left:E,inset:E,insetBlock:E,insetBlockStart:E,insetBlockEnd:E,insetInline:E,insetInlineStart:E,insetInlineEnd:E,padding:E,paddingTop:E,paddingRight:E,paddingBottom:E,paddingLeft:E,paddingBlock:E,paddingBlockStart:E,paddingBlockEnd:E,paddingInline:E,paddingInlineStart:E,paddingInlineEnd:E,margin:E,marginTop:E,marginRight:E,marginBottom:E,marginLeft:E,marginBlock:E,marginBlockStart:E,marginBlockEnd:E,marginInline:E,marginInlineStart:E,marginInlineEnd:E,backgroundPositionX:E,backgroundPositionY:E,...{rotate:Re,rotateX:Re,rotateY:Re,rotateZ:Re,scale:qt,scaleX:qt,scaleY:qt,scaleZ:qt,skew:Re,skewX:Re,skewY:Re,distance:E,translateX:E,translateY:E,translateZ:E,x:E,y:E,z:E,perspective:E,transformPerspective:E,opacity:Pt,originX:pi,originY:pi,originZ:E},zIndex:Ji,fillOpacity:Pt,strokeOpacity:Pt,numOctaves:Ji},Md={...Co,color:Q,backgroundColor:Q,outlineColor:Q,fill:Q,stroke:Q,borderColor:Q,borderTopColor:Q,borderRightColor:Q,borderBottomColor:Q,borderLeftColor:Q,filter:So,WebkitFilter:So},Qi=e=>Md[e];function es(e,t){let n=Qi(e);return n!==So&&(n=_e),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const Vd=new Set(["auto","none","0"]);function Ed(e,t,n){let o=0,r;for(;o<e.length&&!r;){const i=e[o];typeof i=="string"&&!Vd.has(i)&&Vt(i).values.length&&(r=e[o]),o++}if(r&&n)for(const i of t)e[i]=es(n,r)}class Dd extends fo{constructor(t,n,o,r,i){super(t,n,o,r,i,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:o}=this;if(!n||!n.current)return;super.readKeyframes();for(let d=0;d<t.length;d++){let u=t[d];if(typeof u=="string"&&(u=u.trim(),Hn(u))){const h=Oi(u,n.current);h!==void 0&&(t[d]=h),d===t.length-1&&(this.finalKeyframe=u)}}if(this.resolveNoneKeyframes(),!ji.has(o)||t.length!==2)return;const[r,i]=t,s=Zi(r),a=Zi(i),l=hi(r),c=hi(i);if(l!==c&&Ne[o]){this.needsMeasurement=!0;return}if(s!==a)if(Fi(s)&&Fi(a))for(let d=0;d<t.length;d++){const u=t[d];typeof u=="string"&&(t[d]=parseFloat(u))}else Ne[o]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,o=[];for(let r=0;r<t.length;r++)(t[r]===null||Td(t[r]))&&o.push(r);o.length&&Ed(t,o,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:o}=this;if(!t||!t.current)return;o==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Ne[o](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const r=n[n.length-1];r!==void 0&&t.getValue(o,r).jump(r,!1)}measureEndState(){const{element:t,name:n,unresolvedKeyframes:o}=this;if(!t||!t.current)return;const r=t.getValue(n);r&&r.jump(this.measuredOrigin,!1);const i=o.length-1,s=o[i];o[i]=Ne[n](t.measureViewportBox(),window.getComputedStyle(t.current)),s!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=s),this.removedTransforms?.length&&this.removedTransforms.forEach(([a,l])=>{t.getValue(a).set(l)}),this.resolveNoneKeyframes()}}function Fd(e,t,n){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let o=document;const r=n?.[e]??o.querySelectorAll(e);return r?Array.from(r):[]}return Array.from(e)}const ts=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function ns(e){return qr(e)&&"offsetHeight"in e}const{schedule:To}=ui(queueMicrotask,!1),be={x:!1,y:!1};function os(){return be.x||be.y}function Ad(e){return e==="x"||e==="y"?be[e]?null:(be[e]=!0,()=>{be[e]=!1}):be.x||be.y?null:(be.x=be.y=!0,()=>{be.x=be.y=!1})}function rs(e,t){const n=Fd(e),o=new AbortController,r={passive:!0,...t,signal:o.signal};return[n,r,()=>o.abort()]}function is(e){return!(e.pointerType==="touch"||os())}function Id(e,t,n={}){const[o,r,i]=rs(e,n),s=a=>{if(!is(a))return;const{target:l}=a,c=t(l,a);if(typeof c!="function"||!l)return;const d=u=>{is(u)&&(c(u),l.removeEventListener("pointerleave",d))};l.addEventListener("pointerleave",d,r)};return o.forEach(a=>{a.addEventListener("pointerenter",s,r)}),i}const ss=(e,t)=>t?e===t?!0:ss(e,t.parentElement):!1,$o=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,Ld=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function as(e){return Ld.has(e.tagName)||e.isContentEditable===!0}const Jt=new WeakSet;function ls(e){return t=>{t.key==="Enter"&&e(t)}}function Po(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const Rd=(e,t)=>{const n=e.currentTarget;if(!n)return;const o=ls(()=>{if(Jt.has(n))return;Po(n,"down");const r=ls(()=>{Po(n,"up")}),i=()=>Po(n,"cancel");n.addEventListener("keyup",r,t),n.addEventListener("blur",i,t)});n.addEventListener("keydown",o,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",o),t)};function cs(e){return $o(e)&&!os()}function _d(e,t,n={}){const[o,r,i]=rs(e,n),s=a=>{const l=a.currentTarget;if(!cs(a))return;Jt.add(l);const c=t(l,a),d=(f,v)=>{window.removeEventListener("pointerup",u),window.removeEventListener("pointercancel",h),Jt.has(l)&&Jt.delete(l),cs(f)&&typeof c=="function"&&c(f,{success:v})},u=f=>{d(f,l===window||l===document||n.useGlobalTarget||ss(l,f.target))},h=f=>{d(f,!1)};window.addEventListener("pointerup",u,r),window.addEventListener("pointercancel",h,r)};return o.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",s,r),ns(a)&&(a.addEventListener("focus",c=>Rd(c,r)),!as(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),i}function us(e){return qr(e)&&"ownerSVGElement"in e}function Nd(e){return us(e)&&e.tagName==="svg"}const Bd=[...Xi,Q,_e],zd=e=>Bd.find(Yi(e)),ds=()=>({translate:0,scale:1,origin:0,originPoint:0}),ct=()=>({x:ds(),y:ds()}),fs=()=>({min:0,max:0}),ee=()=>({x:fs(),y:fs()}),ko={current:null},hs={current:!1},Od=typeof window<"u";function Hd(){if(hs.current=!0,!!Od)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>ko.current=e.matches;e.addEventListener("change",t),t()}else ko.current=!1}const jd=new WeakMap;function Qt(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function Dt(e){return typeof e=="string"||Array.isArray(e)}const Mo=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Vo=["initial",...Mo];function en(e){return Qt(e.animate)||Vo.some(t=>Dt(e[t]))}function ms(e){return!!(en(e)||e.variants)}function Gd(e,t,n){for(const o in t){const r=t[o],i=n[o];if(ie(r))e.addValue(o,r);else if(ie(i))e.addValue(o,at(r,{owner:e}));else if(i!==r)if(e.hasValue(o)){const s=e.getValue(o);s.liveStyle===!0?s.jump(r):s.hasAnimated||s.set(r)}else{const s=e.getStaticValue(o);e.addValue(o,at(s!==void 0?s:r,{owner:e}))}}for(const o in n)t[o]===void 0&&e.removeValue(o);return t}const ps=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let tn={};function gs(e){tn=e}function Ud(){return tn}class Kd{scrapeMotionValuesFromProps(t,n,o){return{}}constructor({parent:t,props:n,presenceContext:o,reducedMotionConfig:r,blockInitialAnimation:i,visualState:s},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=fo,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const h=le.now();this.renderScheduledAt<h&&(this.renderScheduledAt=h,K.render(this.render,!1,!0))};const{latestValues:l,renderState:c}=s;this.latestValues=l,this.baseTarget={...l},this.initialValues=n.initial?{...l}:{},this.renderState=c,this.parent=t,this.props=n,this.presenceContext=o,this.depth=t?t.depth+1:0,this.reducedMotionConfig=r,this.options=a,this.blockInitialAnimation=!!i,this.isControllingVariants=en(n),this.isVariantNode=ms(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:d,...u}=this.scrapeMotionValuesFromProps(n,{},this);for(const h in u){const f=u[h];l[h]!==void 0&&ie(f)&&f.set(l[h])}}mount(t){this.current=t,jd.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,o)=>this.bindToMotionValue(o,n)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(hs.current||Hd(),this.shouldReduceMotion=ko.current),process.env.NODE_ENV!=="production"&&Nn(this.shouldReduceMotion!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected.","reduced-motion-disabled"),this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),Le(this.notifyUpdate),Le(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const n=this.features[t];n&&(n.unmount(),n.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const o=st.has(t);o&&this.onBindTransform&&this.onBindTransform();const r=n.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&K.preRender(this.notifyUpdate),o&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let i;typeof window<"u"&&window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{r(),i&&i(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in tn){const n=tn[t];if(!n)continue;const{isEnabled:o,Feature:r}=n;if(!this.features[t]&&r&&o(this.props)&&(this.features[t]=new r(this)),this.features[t]){const i=this.features[t];i.isMounted?i.update():(i.mount(),i.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):ee()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let o=0;o<ps.length;o++){const r=ps[o];this.propEventSubscriptions[r]&&(this.propEventSubscriptions[r](),delete this.propEventSubscriptions[r]);const i="on"+r,s=t[i];s&&(this.propEventSubscriptions[r]=this.on(r,s))}this.prevMotionValues=Gd(this,this.scrapeMotionValuesFromProps(t,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const o=this.values.get(t);n!==o&&(o&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let o=this.values.get(t);return o===void 0&&n!==void 0&&(o=at(n===null?void 0:n,{owner:this}),this.addValue(t,o)),o}readValue(t,n){let o=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return o!=null&&(typeof o=="string"&&(Wr(o)||Yr(o))?o=parseFloat(o):!zd(o)&&_e.test(n)&&(o=es(t,n)),this.setBaseTarget(t,ie(o)?o.get():o)),ie(o)?o.get():o}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){const{initial:n}=this.props;let o;if(typeof n=="string"||typeof n=="object"){const i=vo(this.props,n,this.presenceContext?.custom);i&&(o=i[t])}if(n&&o!==void 0)return o;const r=this.getBaseTargetFromProps(this.props,t);return r!==void 0&&!ie(r)?r:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new _n),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){To.render(this.render)}}class Be{constructor(t){this.isMounted=!1,this.node=t}update(){}}class vs extends Kd{constructor(){super(...arguments),this.KeyframeResolver=Dd}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const o=t.style;return o?o[n]:void 0}removeValueFromRenderState(t,{vars:n,style:o}){delete n[t],delete o[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;ie(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function ys({top:e,left:t,right:n,bottom:o}){return{x:{min:t,max:n},y:{min:e,max:o}}}function Wd({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function qd(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),o=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:o.y,right:o.x}}function Eo(e){return e===void 0||e===1}function Do({scale:e,scaleX:t,scaleY:n}){return!Eo(e)||!Eo(t)||!Eo(n)}function Ye(e){return Do(e)||ws(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function ws(e){return bs(e.x)||bs(e.y)}function bs(e){return e&&e!=="0%"}function nn(e,t,n){const o=e-n,r=t*o;return n+r}function xs(e,t,n,o,r){return r!==void 0&&(e=nn(e,r,o)),nn(e,n,o)+t}function Fo(e,t=0,n=1,o,r){e.min=xs(e.min,t,n,o,r),e.max=xs(e.max,t,n,o,r)}function Ss(e,{x:t,y:n}){Fo(e.x,t.translate,t.scale,t.originPoint),Fo(e.y,n.translate,n.scale,n.originPoint)}const Cs=.999999999999,Ts=1.0000000000001;function Yd(e,t,n,o=!1){const r=n.length;if(!r)return;t.x=t.y=1;let i,s;for(let a=0;a<r;a++){i=n[a],s=i.projectionDelta;const{visualElement:l}=i.options;l&&l.props.style&&l.props.style.display==="contents"||(o&&i.options.layoutScroll&&i.scroll&&i!==i.root&&dt(e,{x:-i.scroll.offset.x,y:-i.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,Ss(e,s)),o&&Ye(i.latestValues)&&dt(e,i.latestValues))}t.x<Ts&&t.x>Cs&&(t.x=1),t.y<Ts&&t.y>Cs&&(t.y=1)}function ut(e,t){e.min=e.min+t,e.max=e.max+t}function $s(e,t,n,o,r=.5){const i=Y(e.min,e.max,r);Fo(e,t,n,i,o)}function dt(e,t){$s(e.x,t.x,t.scaleX,t.scale,t.originX),$s(e.y,t.y,t.scaleY,t.scale,t.originY)}function Ps(e,t){return ys(qd(e.getBoundingClientRect(),t))}function Xd(e,t,n){const o=Ps(e,n),{scroll:r}=t;return r&&(ut(o.x,r.offset.x),ut(o.y,r.offset.y)),o}const Zd={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Jd=it.length;function Qd(e,t,n){let o="",r=!0;for(let i=0;i<Jd;i++){const s=it[i],a=e[s];if(a===void 0)continue;let l=!0;if(typeof a=="number"?l=a===(s.startsWith("scale")?1:0):l=parseFloat(a)===0,!l||n){const c=ts(a,Co[s]);if(!l){r=!1;const d=Zd[s]||s;o+=`${d}(${c}) `}n&&(t[s]=c)}}return o=o.trim(),n?o=n(t,r?"":o):r&&(o="none"),o}function Ao(e,t,n){const{style:o,vars:r,transformOrigin:i}=e;let s=!1,a=!1;for(const l in t){const c=t[l];if(st.has(l)){s=!0;continue}else if(fi(l)){r[l]=c;continue}else{const d=ts(c,Co[l]);l.startsWith("origin")?(a=!0,i[l]=d):o[l]=d}}if(t.transform||(s||n?o.transform=Qd(t,e.transform,n):o.transform&&(o.transform="none")),a){const{originX:l="50%",originY:c="50%",originZ:d=0}=i;o.transformOrigin=`${l} ${c} ${d}`}}function ks(e,{style:t,vars:n},o,r){const i=e.style;let s;for(s in t)i[s]=t[s];r?.applyProjectionStyles(i,o);for(s in n)i.setProperty(s,n[s])}function Ms(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Ft={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(E.test(e))e=parseFloat(e);else return e;const n=Ms(e,t.target.x),o=Ms(e,t.target.y);return`${n}% ${o}%`}},ef={correct:(e,{treeScale:t,projectionDelta:n})=>{const o=e,r=_e.parse(e);if(r.length>5)return o;const i=_e.createTransformer(e),s=typeof r[0]!="number"?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;r[0+s]/=a,r[1+s]/=l;const c=Y(a,l,.5);return typeof r[2+s]=="number"&&(r[2+s]/=c),typeof r[3+s]=="number"&&(r[3+s]/=c),i(r)}},Io={borderRadius:{...Ft,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Ft,borderTopRightRadius:Ft,borderBottomLeftRadius:Ft,borderBottomRightRadius:Ft,boxShadow:ef};function Vs(e,{layout:t,layoutId:n}){return st.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Io[e]||e==="opacity")}function Lo(e,t,n){const o=e.style,r=t?.style,i={};if(!o)return i;for(const s in o)(ie(o[s])||r&&ie(r[s])||Vs(s,e)||n?.getValue(s)?.liveStyle!==void 0)&&(i[s]=o[s]);return i}function tf(e){return window.getComputedStyle(e)}class nf extends vs{constructor(){super(...arguments),this.type="html",this.renderInstance=ks}readValueFromInstance(t,n){if(st.has(n))return this.projection?.isProjecting?so(n):Au(t,n);{const o=tf(t),r=(fi(n)?o.getPropertyValue(n):o[n])||0;return typeof r=="string"?r.trim():r}}measureInstanceViewportBox(t,{transformPagePoint:n}){return Ps(t,n)}build(t,n,o){Ao(t,n,o.transformTemplate)}scrapeMotionValuesFromProps(t,n,o){return Lo(t,n,o)}}const of={offset:"stroke-dashoffset",array:"stroke-dasharray"},rf={offset:"strokeDashoffset",array:"strokeDasharray"};function sf(e,t,n=1,o=0,r=!0){e.pathLength=1;const i=r?of:rf;e[i.offset]=E.transform(-o);const s=E.transform(t),a=E.transform(n);e[i.array]=`${s} ${a}`}const af=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function Es(e,{attrX:t,attrY:n,attrScale:o,pathLength:r,pathSpacing:i=1,pathOffset:s=0,...a},l,c,d){if(Ao(e,a,c),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:u,style:h}=e;u.transform&&(h.transform=u.transform,delete u.transform),(h.transform||u.transformOrigin)&&(h.transformOrigin=u.transformOrigin??"50% 50%",delete u.transformOrigin),h.transform&&(h.transformBox=d?.transformBox??"fill-box",delete u.transformBox);for(const f of af)u[f]!==void 0&&(h[f]=u[f],delete u[f]);t!==void 0&&(u.x=t),n!==void 0&&(u.y=n),o!==void 0&&(u.scale=o),r!==void 0&&sf(u,r,i,s,!1)}const Ds=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"]),Fs=e=>typeof e=="string"&&e.toLowerCase()==="svg";function lf(e,t,n,o){ks(e,t,void 0,o);for(const r in t.attrs)e.setAttribute(Ds.has(r)?r:bo(r),t.attrs[r])}function As(e,t,n){const o=Lo(e,t,n);for(const r in e)if(ie(e[r])||ie(t[r])){const i=it.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;o[i]=e[r]}return o}class cf extends vs{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=ee}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(st.has(n)){const o=Qi(n);return o&&o.default||0}return n=Ds.has(n)?n:bo(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,o){return As(t,n,o)}build(t,n,o){Es(t,n,this.isSVGTag,o.transformTemplate,o.style)}renderInstance(t,n,o,r){lf(t,n,o,r)}mount(t){this.isSVGTag=Fs(t.tagName),super.mount(t)}}const uf=Vo.length;function Is(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?Is(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<uf;n++){const o=Vo[n],r=e.props[o];(Dt(r)||r===!1)&&(t[o]=r)}return t}function Ls(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let o=0;o<n;o++)if(t[o]!==e[o])return!1;return!0}const df=[...Mo].reverse(),ff=Mo.length;function hf(e){return t=>Promise.all(t.map(({animation:n,options:o})=>Sd(e,n,o)))}function mf(e){let t=hf(e),n=Rs(),o=!0;const r=l=>(c,d)=>{const u=lt(e,d,l==="exit"?e.presenceContext?.custom:void 0);if(u){const{transition:h,transitionEnd:f,...v}=u;c={...c,...v,...f}}return c};function i(l){t=l(e)}function s(l){const{props:c}=e,d=Is(e.parent)||{},u=[],h=new Set;let f={},v=1/0;for(let b=0;b<ff;b++){const w=df[b],C=n[w],x=c[w]!==void 0?c[w]:d[w],P=Dt(x),T=w===l?C.isActive:null;T===!1&&(v=b);let k=x===d[w]&&x!==c[w]&&P;if(k&&o&&e.manuallyAnimateOnMount&&(k=!1),C.protectedKeys={...f},!C.isActive&&T===null||!x&&!C.prevProp||Qt(x)||typeof x=="boolean")continue;const V=pf(C.prevProp,x);let $=V||w===l&&C.isActive&&!k&&P||b>v&&P,A=!1;const I=Array.isArray(x)?x:[x];let B=I.reduce(r(w),{});T===!1&&(B={});const{prevResolvedValues:H={}}=C,M={...H,...B},F=L=>{$=!0,h.has(L)&&(A=!0,h.delete(L)),C.needsAnimating[L]=!0;const j=e.getValue(L);j&&(j.liveStyle=!1)};for(const L in M){const j=B[L],te=H[L];if(f.hasOwnProperty(L))continue;let J=!1;yo(j)&&yo(te)?J=!Ls(j,te):J=j!==te,J?j!=null?F(L):h.add(L):j!==void 0&&h.has(L)?F(L):C.protectedKeys[L]=!0}C.prevProp=x,C.prevResolvedValues=B,C.isActive&&(f={...f,...B}),o&&e.blockInitialAnimation&&($=!1);const z=k&&V;$&&(!z||A)&&u.push(...I.map(L=>{const j={type:w};if(typeof L=="string"&&o&&!z&&e.manuallyAnimateOnMount&&e.parent){const{parent:te}=e,J=lt(te,L);if(te.enteringChildren&&J){const{delayChildren:ue}=J.transition||{};j.delay=Hi(te.enteringChildren,e,ue)}}return{animation:L,options:j}}))}if(h.size){const b={};if(typeof c.initial!="boolean"){const w=lt(e,Array.isArray(c.initial)?c.initial[0]:c.initial);w&&w.transition&&(b.transition=w.transition)}h.forEach(w=>{const C=e.getBaseTarget(w),x=e.getValue(w);x&&(x.liveStyle=!0),b[w]=C??null}),u.push({animation:b})}let y=!!u.length;return o&&(c.initial===!1||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(y=!1),o=!1,y?t(u):Promise.resolve()}function a(l,c){if(n[l].isActive===c)return Promise.resolve();e.variantChildren?.forEach(u=>u.animationState?.setActive(l,c)),n[l].isActive=c;const d=s(l);for(const u in n)n[u].protectedKeys={};return d}return{animateChanges:s,setActive:a,setAnimateFunction:i,getState:()=>n,reset:()=>{n=Rs()}}}function pf(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!Ls(t,e):!1}function Xe(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Rs(){return{animate:Xe(!0),whileInView:Xe(),whileHover:Xe(),whileTap:Xe(),whileDrag:Xe(),whileFocus:Xe(),exit:Xe()}}const _s=1e-4,gf=1-_s,vf=1+_s,Ns=.01,yf=0-Ns,wf=0+Ns;function ce(e){return e.max-e.min}function bf(e,t,n){return Math.abs(e-t)<=n}function Bs(e,t,n,o=.5){e.origin=o,e.originPoint=Y(t.min,t.max,e.origin),e.scale=ce(n)/ce(t),e.translate=Y(n.min,n.max,e.origin)-e.originPoint,(e.scale>=gf&&e.scale<=vf||isNaN(e.scale))&&(e.scale=1),(e.translate>=yf&&e.translate<=wf||isNaN(e.translate))&&(e.translate=0)}function At(e,t,n,o){Bs(e.x,t.x,n.x,o?o.originX:void 0),Bs(e.y,t.y,n.y,o?o.originY:void 0)}function zs(e,t,n){e.min=n.min+t.min,e.max=e.min+ce(t)}function xf(e,t,n){zs(e.x,t.x,n.x),zs(e.y,t.y,n.y)}function Os(e,t,n){e.min=t.min-n.min,e.max=e.min+ce(t)}function on(e,t,n){Os(e.x,t.x,n.x),Os(e.y,t.y,n.y)}function Hs(e,t,n,o,r){return e-=t,e=nn(e,1/n,o),r!==void 0&&(e=nn(e,1/r,o)),e}function Sf(e,t=0,n=1,o=.5,r,i=e,s=e){if(ke.test(t)&&(t=parseFloat(t),t=Y(s.min,s.max,t/100)-s.min),typeof t!="number")return;let a=Y(i.min,i.max,o);e===i&&(a-=t),e.min=Hs(e.min,t,n,a,r),e.max=Hs(e.max,t,n,a,r)}function js(e,t,[n,o,r],i,s){Sf(e,t[n],t[o],t[r],t.scale,i,s)}const Cf=["x","scaleX","originX"],Tf=["y","scaleY","originY"];function Gs(e,t,n,o){js(e.x,t,Cf,n?n.x:void 0,o?o.x:void 0),js(e.y,t,Tf,n?n.y:void 0,o?o.y:void 0)}function Us(e,t){e.min=t.min,e.max=t.max}function xe(e,t){Us(e.x,t.x),Us(e.y,t.y)}function Ks(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function Ws(e){return e.translate===0&&e.scale===1}function qs(e){return Ws(e.x)&&Ws(e.y)}function Ys(e,t){return e.min===t.min&&e.max===t.max}function $f(e,t){return Ys(e.x,t.x)&&Ys(e.y,t.y)}function Xs(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Zs(e,t){return Xs(e.x,t.x)&&Xs(e.y,t.y)}function Js(e){return ce(e.x)/ce(e.y)}function Qs(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function ve(e){return[e("x"),e("y")]}function Pf(e,t,n){let o="";const r=e.x.translate/t.x,i=e.y.translate/t.y,s=n?.z||0;if((r||i||s)&&(o=`translate3d(${r}px, ${i}px, ${s}px) `),(t.x!==1||t.y!==1)&&(o+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:c,rotate:d,rotateX:u,rotateY:h,skewX:f,skewY:v}=n;c&&(o=`perspective(${c}px) ${o}`),d&&(o+=`rotate(${d}deg) `),u&&(o+=`rotateX(${u}deg) `),h&&(o+=`rotateY(${h}deg) `),f&&(o+=`skewX(${f}deg) `),v&&(o+=`skewY(${v}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return(a!==1||l!==1)&&(o+=`scale(${a}, ${l})`),o||"none"}const ea=["TopLeft","TopRight","BottomLeft","BottomRight"],kf=ea.length,ta=e=>typeof e=="string"?parseFloat(e):e,na=e=>typeof e=="number"||E.test(e);function Mf(e,t,n,o,r,i){r?(e.opacity=Y(0,n.opacity??1,Vf(o)),e.opacityExit=Y(t.opacity??1,0,Ef(o))):i&&(e.opacity=Y(t.opacity??1,n.opacity??1,o));for(let s=0;s<kf;s++){const a=`border${ea[s]}Radius`;let l=oa(t,a),c=oa(n,a);if(l===void 0&&c===void 0)continue;l||(l=0),c||(c=0),l===0||c===0||na(l)===na(c)?(e[a]=Math.max(Y(ta(l),ta(c),o),0),(ke.test(c)||ke.test(l))&&(e[a]+="%")):e[a]=c}(t.rotate||n.rotate)&&(e.rotate=Y(t.rotate||0,n.rotate||0,o))}function oa(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const Vf=ra(0,.5,ri),Ef=ra(.5,.95,pe);function ra(e,t,n){return o=>o<e?0:o>t?1:n(Tt(e,t,o))}function Df(e,t){const n=le.now(),o=({timestamp:r})=>{const i=r-n;i>=t&&(Le(o),e(i-t))};return K.setup(o,!0),()=>Le(o)}function It(e,t,n,o={passive:!0}){return e.addEventListener(t,n,o),()=>e.removeEventListener(t,n)}function rn(e){return ie(e)?e.get():e}function Ff(e,t,n){const o=ie(e)?e:at(e);return o.start(go("",o,t,n)),o.animation}const Af=(e,t)=>e.depth-t.depth;class If{constructor(){this.children=[],this.isDirty=!1}add(t){An(this.children,t),this.isDirty=!0}remove(t){In(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(Af),this.isDirty=!1,this.children.forEach(t)}}class Lf{constructor(){this.members=[]}add(t){An(this.members,t),t.scheduleRender()}remove(t){if(In(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(r=>t===r);if(n===0)return!1;let o;for(let r=n;r>=0;r--){const i=this.members[r];if(i.isPresent!==!1){o=i;break}}return o?(this.promote(o),!0):!1}promote(t,n){const o=this.lead;if(t!==o&&(this.prevLead=o,this.lead=t,t.show(),o)){o.instance&&o.scheduleRender(),t.scheduleRender(),t.resumeFrom=o,n&&(t.resumeFrom.preserveOpacity=!0),o.snapshot&&(t.snapshot=o.snapshot,t.snapshot.latestValues=o.animationValues||o.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:r}=t.options;r===!1&&o.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:o}=t;n.onExitComplete&&n.onExitComplete(),o&&o.options.onExitComplete&&o.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const sn={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Ro=["","X","Y","Z"],Rf=1e3;let _f=0;function _o(e,t,n,o){const{latestValues:r}=t;r[e]&&(n[e]=r[e],t.setStaticValue(e,0),o&&(o[e]=0))}function ia(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=Wi(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:r,layoutId:i}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",K,!(r||i))}const{parent:o}=e;o&&!o.hasCheckedOptimisedAppear&&ia(o)}function sa({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:o,resetTransform:r}){return class{constructor(s={},a=t?.()){this.id=_f++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(zf),this.nodes.forEach(Gf),this.nodes.forEach(Uf),this.nodes.forEach(Of)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new If)}addEventListener(s,a){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new _n),this.eventHandlers.get(s).add(a)}notifyListeners(s,...a){const l=this.eventHandlers.get(s);l&&l.notify(...a)}hasListeners(s){return this.eventHandlers.has(s)}mount(s){if(this.instance)return;this.isSVG=us(s)&&!Nd(s),this.instance=s;const{layoutId:a,layout:l,visualElement:c}=this.options;if(c&&!c.current&&c.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(l||a)&&(this.isLayoutDirty=!0),e){let d,u=0;const h=()=>this.root.updateBlockedByResize=!1;K.read(()=>{u=window.innerWidth}),e(s,()=>{const f=window.innerWidth;f!==u&&(u=f,this.root.updateBlockedByResize=!0,d&&d(),d=Df(h,250),sn.hasAnimatedSinceResize&&(sn.hasAnimatedSinceResize=!1,this.nodes.forEach(ca)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&c&&(a||l)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:u,hasRelativeLayoutChanged:h,layout:f})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const v=this.options.transition||c.getDefaultTransition()||Xf,{onLayoutAnimationStart:y,onLayoutAnimationComplete:b}=c.getProps(),w=!this.targetLayout||!Zs(this.targetLayout,f),C=!u&&h;if(this.options.layoutRoot||this.resumeFrom||C||u&&(w||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const x={...po(v,"layout"),onPlay:y,onComplete:b};(c.shouldReduceMotion||this.options.layoutRoot)&&(x.delay=0,x.type=!1),this.startAnimation(x),this.setAnimationOrigin(d,C)}else u||ca(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=f})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Le(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(Kf),this.animationId++)}getTransformTemplate(){const{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&ia(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d<this.path.length;d++){const u=this.path[d];u.shouldResetTransform=!0,u.updateScroll("snapshot"),u.options.layoutRoot&&u.willUpdate(!1)}const{layoutId:a,layout:l}=this.options;if(a===void 0&&!l)return;const c=this.getTransformTemplate();this.prevTransformTemplateValue=c?c(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(aa);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(la);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(jf),this.nodes.forEach(Nf),this.nodes.forEach(Bf)):this.nodes.forEach(la),this.clearAllSnapshots();const a=le.now();oe.delta=$e(0,1e3/60,a-oe.timestamp),oe.timestamp=a,oe.isProcessing=!0,On.update.process(oe),On.preRender.process(oe),On.render.process(oe),oe.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,To.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(Hf),this.sharedNodes.forEach(Wf)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,K.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){K.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!ce(this.snapshot.measuredBox.x)&&!ce(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();const s=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=ee(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(a=!1),a&&this.instance){const l=o(this.instance);this.scroll={animationId:this.root.animationId,phase:s,isRoot:l,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!r)return;const s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!qs(this.projectionDelta),l=this.getTransformTemplate(),c=l?l(this.latestValues,""):void 0,d=c!==this.prevTransformTemplateValue;s&&this.instance&&(a||Ye(this.latestValues)||d)&&(r(this.instance,c),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){const a=this.measurePageBox();let l=this.removeElementScroll(a);return s&&(l=this.removeTransform(l)),Zf(l),{animationId:this.root.animationId,measuredBox:a,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:s}=this.options;if(!s)return ee();const a=s.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(Jf))){const{scroll:c}=this.root;c&&(ut(a.x,c.offset.x),ut(a.y,c.offset.y))}return a}removeElementScroll(s){const a=ee();if(xe(a,s),this.scroll?.wasRoot)return a;for(let l=0;l<this.path.length;l++){const c=this.path[l],{scroll:d,options:u}=c;c!==this.root&&d&&u.layoutScroll&&(d.wasRoot&&xe(a,s),ut(a.x,d.offset.x),ut(a.y,d.offset.y))}return a}applyTransform(s,a=!1){const l=ee();xe(l,s);for(let c=0;c<this.path.length;c++){const d=this.path[c];!a&&d.options.layoutScroll&&d.scroll&&d!==d.root&&dt(l,{x:-d.scroll.offset.x,y:-d.scroll.offset.y}),Ye(d.latestValues)&&dt(l,d.latestValues)}return Ye(this.latestValues)&&dt(l,this.latestValues),l}removeTransform(s){const a=ee();xe(a,s);for(let l=0;l<this.path.length;l++){const c=this.path[l];if(!c.instance||!Ye(c.latestValues))continue;Do(c.latestValues)&&c.updateSnapshot();const d=ee(),u=c.measurePageBox();xe(d,u),Gs(a,c.latestValues,c.snapshot?c.snapshot.layoutBox:void 0,d)}return Ye(this.latestValues)&&Gs(a,this.latestValues),a}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==oe.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const l=!!this.resumingFrom||this!==a;if(!(s||l&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:d,layoutId:u}=this.options;if(!this.layout||!(d||u))return;this.resolvedRelativeTargetAt=oe.timestamp;const h=this.getClosestProjectingParent();h&&this.linkedParentVersion!==h.layoutVersion&&!h.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(h&&h.layout?this.createRelativeTarget(h,this.layout.layoutBox,h.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=ee(),this.targetWithTransforms=ee()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),xf(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):xe(this.target,this.layout.layoutBox),Ss(this.target,this.targetDelta)):xe(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,h&&!!h.resumingFrom==!!this.resumingFrom&&!h.options.layoutScroll&&h.target&&this.animationProgress!==1?this.createRelativeTarget(h,this.target,h.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||Do(this.parent.latestValues)||ws(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(s,a,l){this.relativeParent=s,this.linkedParentVersion=s.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=ee(),this.relativeTargetOrigin=ee(),on(this.relativeTargetOrigin,a,l),xe(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){const s=this.getLead(),a=!!this.resumingFrom||this!==s;let l=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(l=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===oe.timestamp&&(l=!1),l)return;const{layout:c,layoutId:d}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(c||d))return;xe(this.layoutCorrected,this.layout.layoutBox);const u=this.treeScale.x,h=this.treeScale.y;Yd(this.layoutCorrected,this.treeScale,this.path,a),s.layout&&!s.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(s.target=s.layout.layoutBox,s.targetWithTransforms=ee());const{target:f}=s;if(!f){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Ks(this.prevProjectionDelta.x,this.projectionDelta.x),Ks(this.prevProjectionDelta.y,this.projectionDelta.y)),At(this.projectionDelta,this.layoutCorrected,f,this.latestValues),(this.treeScale.x!==u||this.treeScale.y!==h||!Qs(this.projectionDelta.x,this.prevProjectionDelta.x)||!Qs(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",f))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){if(this.options.visualElement?.scheduleRender(),s){const a=this.getStack();a&&a.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=ct(),this.projectionDelta=ct(),this.projectionDeltaWithTransform=ct()}setAnimationOrigin(s,a=!1){const l=this.snapshot,c=l?l.latestValues:{},d={...this.latestValues},u=ct();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const h=ee(),f=l?l.source:void 0,v=this.layout?this.layout.source:void 0,y=f!==v,b=this.getStack(),w=!b||b.members.length<=1,C=!!(y&&!w&&this.options.crossfade===!0&&!this.path.some(Yf));this.animationProgress=0;let x;this.mixTargetDelta=P=>{const T=P/1e3;ua(u.x,s.x,T),ua(u.y,s.y,T),this.setTargetDelta(u),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(on(h,this.layout.layoutBox,this.relativeParent.layout.layoutBox),qf(this.relativeTarget,this.relativeTargetOrigin,h,T),x&&$f(this.relativeTarget,x)&&(this.isProjectionDirty=!1),x||(x=ee()),xe(x,this.relativeTarget)),y&&(this.animationValues=d,Mf(d,c,this.latestValues,T,C,w)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=T},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(Le(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=K.update(()=>{sn.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=at(0)),this.currentAnimation=Ff(this.motionValue,[0,1e3],{...s,velocity:0,isSync:!0,onUpdate:a=>{this.mixTargetDelta(a),s.onUpdate&&s.onUpdate(a)},onStop:()=>{},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Rf),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:a,target:l,layout:c,latestValues:d}=s;if(!(!a||!l||!c)){if(this!==s&&this.layout&&c&&pa(this.options.animationType,this.layout.layoutBox,c.layoutBox)){l=this.target||ee();const u=ce(this.layout.layoutBox.x);l.x.min=s.target.x.min,l.x.max=l.x.min+u;const h=ce(this.layout.layoutBox.y);l.y.min=s.target.y.min,l.y.max=l.y.min+h}xe(a,l),dt(a,d),At(this.projectionDeltaWithTransform,this.layoutCorrected,a,d)}}registerSharedNode(s,a){this.sharedNodes.has(s)||this.sharedNodes.set(s,new Lf),this.sharedNodes.get(s).add(a);const c=a.options.initialPromotionConfig;a.promote({transition:c?c.transition:void 0,preserveFollowOpacity:c&&c.shouldPreserveFollowOpacity?c.shouldPreserveFollowOpacity(a):void 0})}isLead(){const s=this.getStack();return s?s.lead===this:!0}getLead(){const{layoutId:s}=this.options;return s?this.getStack()?.lead||this:this}getPrevLead(){const{layoutId:s}=this.options;return s?this.getStack()?.prevLead:void 0}getStack(){const{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:a,preserveFollowOpacity:l}={}){const c=this.getStack();c&&c.promote(this,l),s&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){const{visualElement:s}=this.options;if(!s)return;let a=!1;const{latestValues:l}=s;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const c={};l.z&&_o("z",s,c,this.animationValues);for(let d=0;d<Ro.length;d++)_o(`rotate${Ro[d]}`,s,c,this.animationValues),_o(`skew${Ro[d]}`,s,c,this.animationValues);s.render();for(const d in c)s.setStaticValue(d,c[d]),this.animationValues&&(this.animationValues[d]=c[d]);s.scheduleRender()}applyProjectionStyles(s,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){s.visibility="hidden";return}const l=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,s.visibility="",s.opacity="",s.pointerEvents=rn(a?.pointerEvents)||"",s.transform=l?l(this.latestValues,""):"none";return}const c=this.getLead();if(!this.projectionDelta||!this.layout||!c.target){this.options.layoutId&&(s.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,s.pointerEvents=rn(a?.pointerEvents)||""),this.hasProjected&&!Ye(this.latestValues)&&(s.transform=l?l({},""):"none",this.hasProjected=!1);return}s.visibility="";const d=c.animationValues||c.latestValues;this.applyTransformsToTarget();let u=Pf(this.projectionDeltaWithTransform,this.treeScale,d);l&&(u=l(d,u)),s.transform=u;const{x:h,y:f}=this.projectionDelta;s.transformOrigin=`${h.origin*100}% ${f.origin*100}% 0`,c.animationValues?s.opacity=c===this?d.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:d.opacityExit:s.opacity=c===this?d.opacity!==void 0?d.opacity:"":d.opacityExit!==void 0?d.opacityExit:0;for(const v in Io){if(d[v]===void 0)continue;const{correct:y,applyTo:b,isCSSVariable:w}=Io[v],C=u==="none"?d[v]:y(d[v],c);if(b){const x=b.length;for(let P=0;P<x;P++)s[b[P]]=C}else w?this.options.visualElement.renderState.vars[v]=C:s[v]=C}this.options.layoutId&&(s.pointerEvents=c===this?rn(a?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>s.currentAnimation?.stop()),this.root.nodes.forEach(aa),this.root.sharedNodes.clear()}}}function Nf(e){e.updateLayout()}function Bf(e){const t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:n,measuredBox:o}=e.layout,{animationType:r}=e.options,i=t.source!==e.layout.source;r==="size"?ve(d=>{const u=i?t.measuredBox[d]:t.layoutBox[d],h=ce(u);u.min=n[d].min,u.max=u.min+h}):pa(r,t.layoutBox,n)&&ve(d=>{const u=i?t.measuredBox[d]:t.layoutBox[d],h=ce(n[d]);u.max=u.min+h,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+h)});const s=ct();At(s,n,t.layoutBox);const a=ct();i?At(a,e.applyTransform(o,!0),t.measuredBox):At(a,n,t.layoutBox);const l=!qs(s);let c=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:u,layout:h}=d;if(u&&h){const f=ee();on(f,t.layoutBox,u.layoutBox);const v=ee();on(v,n,h.layoutBox),Zs(f,v)||(c=!0),d.options.layoutRoot&&(e.relativeTarget=v,e.relativeTargetOrigin=f,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:n,snapshot:t,delta:a,layoutDelta:s,hasLayoutChanged:l,hasRelativeLayoutChanged:c})}else if(e.isLead()){const{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function zf(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function Of(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Hf(e){e.clearSnapshot()}function aa(e){e.clearMeasurements()}function la(e){e.isLayoutDirty=!1}function jf(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function ca(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Gf(e){e.resolveTargetDelta()}function Uf(e){e.calcProjection()}function Kf(e){e.resetSkewAndRotation()}function Wf(e){e.removeLeadSnapshot()}function ua(e,t,n){e.translate=Y(t.translate,0,n),e.scale=Y(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function da(e,t,n,o){e.min=Y(t.min,n.min,o),e.max=Y(t.max,n.max,o)}function qf(e,t,n,o){da(e.x,t.x,n.x,o),da(e.y,t.y,n.y,o)}function Yf(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const Xf={duration:.45,ease:[.4,0,.1,1]},fa=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),ha=fa("applewebkit/")&&!fa("chrome/")?Math.round:pe;function ma(e){e.min=ha(e.min),e.max=ha(e.max)}function Zf(e){ma(e.x),ma(e.y)}function pa(e,t,n){return e==="position"||e==="preserve-aspect"&&!bf(Js(t),Js(n),.2)}function Jf(e){return e!==e.root&&e.scroll?.wasRoot}const Qf=sa({attachResizeListener:(e,t)=>It(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),No={current:void 0},ga=sa({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!No.current){const e=new Qf({});e.mount(window),e.setOptions({layoutScroll:!0}),No.current=e}return No.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),Bo=m.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function va(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function eh(...e){return t=>{let n=!1;const o=e.map(r=>{const i=va(r,t);return!n&&typeof i=="function"&&(n=!0),i});if(n)return()=>{for(let r=0;r<o.length;r++){const i=o[r];typeof i=="function"?i():va(e[r],null)}}}}function th(...e){return Ue.useCallback(eh(...e),e)}class nh extends Ue.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const o=n.offsetParent,r=ns(o)&&o.offsetWidth||0,i=this.props.sizeRef.current;i.height=n.offsetHeight||0,i.width=n.offsetWidth||0,i.top=n.offsetTop,i.left=n.offsetLeft,i.right=r-i.width-i.left}return null}componentDidUpdate(){}render(){return this.props.children}}function oh({children:e,isPresent:t,anchorX:n,root:o}){const r=m.useId(),i=m.useRef(null),s=m.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:a}=m.useContext(Bo),l=e.props?.ref??e?.ref,c=th(i,l);return m.useInsertionEffect(()=>{const{width:d,height:u,top:h,left:f,right:v}=s.current;if(t||!i.current||!d||!u)return;const y=n==="left"?`left: ${f}`:`right: ${v}`;i.current.dataset.motionPopId=r;const b=document.createElement("style");a&&(b.nonce=a);const w=o??document.head;return w.appendChild(b),b.sheet&&b.sheet.insertRule(`
167
+ `,Wr={tn:"1rem",sm:"1.5rem",md:"2rem",lg:"3rem"},U=({component:e,size:t="1.5rem",color:n="currentColor",className:o,iconProps:r={}})=>{const i=typeof t=="string"&&t in Wr?Wr[t]:t;return p.jsx(Fc,{$color:n,className:o,children:typeof e=="function"?p.jsx(e,{size:i,...r}):e})},Fn=m.createContext({});function An(e){const t=m.useRef(null);return t.current===null&&(t.current=e()),t.current}const Kr=typeof window<"u",qr=Kr?m.useLayoutEffect:m.useEffect,Wt=m.createContext(null);function In(e,t){e.indexOf(t)===-1&&e.push(t)}function Ln(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const $e=(e,t,n)=>n>t?t:n<e?e:n;function Rn(e,t){return t?`${e}. For more information and steps for solving, visit https://motion.dev/troubleshooting/${t}`:e}let nt=()=>{},Ve=()=>{};typeof process<"u"&&process.env?.NODE_ENV!=="production"&&(nt=(e,t,n)=>{!e&&typeof console<"u"&&console.warn(Rn(t,n))},Ve=(e,t,n)=>{if(!e)throw new Error(Rn(t,n))});const Ee={},Yr=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function Xr(e){return typeof e=="object"&&e!==null}const Zr=e=>/^0[^.\s]+$/u.test(e);function _n(e){let t;return()=>(t===void 0&&(t=e()),t)}const pe=e=>e,Ac=(e,t)=>n=>t(e(n)),Tt=(...e)=>e.reduce(Ac),$t=(e,t,n)=>{const o=t-e;return o===0?1:(n-e)/o};class Bn{constructor(){this.subscriptions=[]}add(t){return In(this.subscriptions,t),()=>Ln(this.subscriptions,t)}notify(t,n,o){const r=this.subscriptions.length;if(r)if(r===1)this.subscriptions[0](t,n,o);else for(let i=0;i<r;i++){const s=this.subscriptions[i];s&&s(t,n,o)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const Pe=e=>e*1e3,ge=e=>e/1e3;function Jr(e,t){return t?e*(1e3/t):0}const Qr=new Set;function Nn(e,t,n){e||Qr.has(t)||(console.warn(Rn(t,n)),Qr.add(t))}const ei=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Ic=1e-7,Lc=12;function Rc(e,t,n,o,r){let i,s,a=0;do s=t+(n-t)/2,i=ei(s,o,r)-e,i>0?n=s:t=s;while(Math.abs(i)>Ic&&++a<Lc);return s}function Pt(e,t,n,o){if(e===t&&n===o)return pe;const r=i=>Rc(i,0,1,e,n);return i=>i===0||i===1?i:ei(r(i),t,o)}const ti=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,ni=e=>t=>1-e(1-t),oi=Pt(.33,1.53,.69,.99),zn=ni(oi),ri=ti(zn),ii=e=>(e*=2)<1?.5*zn(e):.5*(2-Math.pow(2,-10*(e-1))),On=e=>1-Math.sin(Math.acos(e)),si=ni(On),ai=ti(On),_c=Pt(.42,0,1,1),Bc=Pt(0,0,.58,1),li=Pt(.42,0,.58,1),Nc=e=>Array.isArray(e)&&typeof e[0]!="number",ci=e=>Array.isArray(e)&&typeof e[0]=="number",ui={linear:pe,easeIn:_c,easeInOut:li,easeOut:Bc,circIn:On,circInOut:ai,circOut:si,backIn:zn,backInOut:ri,backOut:oi,anticipate:ii},zc=e=>typeof e=="string",di=e=>{if(ci(e)){Ve(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");const[t,n,o,r]=e;return Pt(t,n,o,r)}else if(zc(e))return Ve(ui[e]!==void 0,`Invalid easing type '${e}'`,"invalid-easing-type"),ui[e];return e},Kt=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function Oc(e,t){let n=new Set,o=new Set,r=!1,i=!1;const s=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1};function l(d){s.has(d)&&(c.schedule(d),e()),d(a)}const c={schedule:(d,u=!1,f=!1)=>{const v=f&&r?n:o;return u&&s.add(d),v.has(d)||v.add(d),d},cancel:d=>{o.delete(d),s.delete(d)},process:d=>{if(a=d,r){i=!0;return}r=!0,[n,o]=[o,n],n.forEach(l),n.clear(),r=!1,i&&(i=!1,c.process(d))}};return c}const Hc=40;function fi(e,t){let n=!1,o=!0;const r={delta:0,timestamp:0,isProcessing:!1},i=()=>n=!0,s=Kt.reduce((x,P)=>(x[P]=Oc(i),x),{}),{setup:a,read:l,resolveKeyframes:c,preUpdate:d,update:u,preRender:f,render:h,postRender:v}=s,y=()=>{const x=Ee.useManualTiming?r.timestamp:performance.now();n=!1,Ee.useManualTiming||(r.delta=o?1e3/60:Math.max(Math.min(x-r.timestamp,Hc),1)),r.timestamp=x,r.isProcessing=!0,a.process(r),l.process(r),c.process(r),d.process(r),u.process(r),f.process(r),h.process(r),v.process(r),r.isProcessing=!1,n&&t&&(o=!1,e(y))},b=()=>{n=!0,o=!0,r.isProcessing||e(y)};return{schedule:Kt.reduce((x,P)=>{const T=s[P];return x[P]=(k,V=!1,$=!1)=>(n||b(),T.schedule(k,V,$)),x},{}),cancel:x=>{for(let P=0;P<Kt.length;P++)s[Kt[P]].cancel(x)},state:r,steps:s}}const{schedule:W,cancel:Le,state:oe,steps:Hn}=fi(typeof requestAnimationFrame<"u"?requestAnimationFrame:pe,!0);let qt;function jc(){qt=void 0}const le={now:()=>(qt===void 0&&le.set(oe.isProcessing||Ee.useManualTiming?oe.timestamp:performance.now()),qt),set:e=>{qt=e,queueMicrotask(jc)}},hi=e=>t=>typeof t=="string"&&t.startsWith(e),mi=hi("--"),Gc=hi("var(--"),jn=e=>Gc(e)?Uc.test(e.split("/*")[0].trim()):!1,Uc=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function pi(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const ot={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},kt={...ot,transform:e=>$e(0,1,e)},Yt={...ot,default:1},Mt=e=>Math.round(e*1e5)/1e5,Gn=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Wc(e){return e==null}const Kc=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Un=(e,t)=>n=>!!(typeof n=="string"&&Kc.test(n)&&n.startsWith(e)||t&&!Wc(n)&&Object.prototype.hasOwnProperty.call(n,t)),gi=(e,t,n)=>o=>{if(typeof o!="string")return o;const[r,i,s,a]=o.match(Gn);return{[e]:parseFloat(r),[t]:parseFloat(i),[n]:parseFloat(s),alpha:a!==void 0?parseFloat(a):1}},qc=e=>$e(0,255,e),Wn={...ot,transform:e=>Math.round(qc(e))},We={test:Un("rgb","red"),parse:gi("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:o=1})=>"rgba("+Wn.transform(e)+", "+Wn.transform(t)+", "+Wn.transform(n)+", "+Mt(kt.transform(o))+")"};function Yc(e){let t="",n="",o="",r="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),o=e.substring(5,7),r=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),o=e.substring(3,4),r=e.substring(4,5),t+=t,n+=n,o+=o,r+=r),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(o,16),alpha:r?parseInt(r,16)/255:1}}const Kn={test:Un("#"),parse:Yc,transform:We.transform},Vt=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Re=Vt("deg"),ke=Vt("%"),E=Vt("px"),Xc=Vt("vh"),Zc=Vt("vw"),vi={...ke,parse:e=>ke.parse(e)/100,transform:e=>ke.transform(e*100)},rt={test:Un("hsl","hue"),parse:gi("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:o=1})=>"hsla("+Math.round(e)+", "+ke.transform(Mt(t))+", "+ke.transform(Mt(n))+", "+Mt(kt.transform(o))+")"},Q={test:e=>We.test(e)||Kn.test(e)||rt.test(e),parse:e=>We.test(e)?We.parse(e):rt.test(e)?rt.parse(e):Kn.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?We.transform(e):rt.transform(e),getAnimatableNone:e=>{const t=Q.parse(e);return t.alpha=0,Q.transform(t)}},Jc=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function Qc(e){return isNaN(e)&&typeof e=="string"&&(e.match(Gn)?.length||0)+(e.match(Jc)?.length||0)>0}const yi="number",wi="color",eu="var",tu="var(",bi="${}",nu=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Et(e){const t=e.toString(),n=[],o={color:[],number:[],var:[]},r=[];let i=0;const a=t.replace(nu,l=>(Q.test(l)?(o.color.push(i),r.push(wi),n.push(Q.parse(l))):l.startsWith(tu)?(o.var.push(i),r.push(eu),n.push(l)):(o.number.push(i),r.push(yi),n.push(parseFloat(l))),++i,bi)).split(bi);return{values:n,split:a,indexes:o,types:r}}function xi(e){return Et(e).values}function Si(e){const{split:t,types:n}=Et(e),o=t.length;return r=>{let i="";for(let s=0;s<o;s++)if(i+=t[s],r[s]!==void 0){const a=n[s];a===yi?i+=Mt(r[s]):a===wi?i+=Q.transform(r[s]):i+=r[s]}return i}}const ou=e=>typeof e=="number"?0:Q.test(e)?Q.getAnimatableNone(e):e;function ru(e){const t=xi(e);return Si(e)(t.map(ou))}const _e={test:Qc,parse:xi,createTransformer:Si,getAnimatableNone:ru};function qn(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function iu({hue:e,saturation:t,lightness:n,alpha:o}){e/=360,t/=100,n/=100;let r=0,i=0,s=0;if(!t)r=i=s=n;else{const a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;r=qn(l,a,e+1/3),i=qn(l,a,e),s=qn(l,a,e-1/3)}return{red:Math.round(r*255),green:Math.round(i*255),blue:Math.round(s*255),alpha:o}}function Xt(e,t){return n=>n>0?t:e}const Y=(e,t,n)=>e+(t-e)*n,Yn=(e,t,n)=>{const o=e*e,r=n*(t*t-o)+o;return r<0?0:Math.sqrt(r)},su=[Kn,We,rt],au=e=>su.find(t=>t.test(e));function Ci(e){const t=au(e);if(nt(!!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===rt&&(n=iu(n)),n}const Ti=(e,t)=>{const n=Ci(e),o=Ci(t);if(!n||!o)return Xt(e,t);const r={...n};return i=>(r.red=Yn(n.red,o.red,i),r.green=Yn(n.green,o.green,i),r.blue=Yn(n.blue,o.blue,i),r.alpha=Y(n.alpha,o.alpha,i),We.transform(r))},Xn=new Set(["none","hidden"]);function lu(e,t){return Xn.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function cu(e,t){return n=>Y(e,t,n)}function Zn(e){return typeof e=="number"?cu:typeof e=="string"?jn(e)?Xt:Q.test(e)?Ti:fu:Array.isArray(e)?$i:typeof e=="object"?Q.test(e)?Ti:uu:Xt}function $i(e,t){const n=[...e],o=n.length,r=e.map((i,s)=>Zn(i)(i,t[s]));return i=>{for(let s=0;s<o;s++)n[s]=r[s](i);return n}}function uu(e,t){const n={...e,...t},o={};for(const r in n)e[r]!==void 0&&t[r]!==void 0&&(o[r]=Zn(e[r])(e[r],t[r]));return r=>{for(const i in o)n[i]=o[i](r);return n}}function du(e,t){const n=[],o={color:0,var:0,number:0};for(let r=0;r<t.values.length;r++){const i=t.types[r],s=e.indexes[i][o[i]],a=e.values[s]??0;n[r]=a,o[i]++}return n}const fu=(e,t)=>{const n=_e.createTransformer(t),o=Et(e),r=Et(t);return o.indexes.var.length===r.indexes.var.length&&o.indexes.color.length===r.indexes.color.length&&o.indexes.number.length>=r.indexes.number.length?Xn.has(e)&&!r.values.length||Xn.has(t)&&!o.values.length?lu(e,t):Tt($i(du(o,r),r.values),n):(nt(!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"),Xt(e,t))};function Pi(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?Y(e,t,n):Zn(e)(e,t)}const hu=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>W.update(t,n),stop:()=>Le(t),now:()=>oe.isProcessing?oe.timestamp:le.now()}},ki=(e,t,n=10)=>{let o="";const r=Math.max(Math.round(t/n),2);for(let i=0;i<r;i++)o+=Math.round(e(i/(r-1))*1e4)/1e4+", ";return`linear(${o.substring(0,o.length-2)})`},Zt=2e4;function Jn(e){let t=0;const n=50;let o=e.next(t);for(;!o.done&&t<Zt;)t+=n,o=e.next(t);return t>=Zt?1/0:t}function mu(e,t=100,n){const o=n({...e,keyframes:[0,t]}),r=Math.min(Jn(o),Zt);return{type:"keyframes",ease:i=>o.next(r*i).value/t,duration:ge(r)}}const pu=5;function Mi(e,t,n){const o=Math.max(t-pu,0);return Jr(n-e(o),t-o)}const X={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},Qn=.001;function gu({duration:e=X.duration,bounce:t=X.bounce,velocity:n=X.velocity,mass:o=X.mass}){let r,i;nt(e<=Pe(X.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let s=1-t;s=$e(X.minDamping,X.maxDamping,s),e=$e(X.minDuration,X.maxDuration,ge(e)),s<1?(r=c=>{const d=c*s,u=d*e,f=d-n,h=eo(c,s),v=Math.exp(-u);return Qn-f/h*v},i=c=>{const u=c*s*e,f=u*n+n,h=Math.pow(s,2)*Math.pow(c,2)*e,v=Math.exp(-u),y=eo(Math.pow(c,2),s);return(-r(c)+Qn>0?-1:1)*((f-h)*v)/y}):(r=c=>{const d=Math.exp(-c*e),u=(c-n)*e+1;return-Qn+d*u},i=c=>{const d=Math.exp(-c*e),u=(n-c)*(e*e);return d*u});const a=5/e,l=yu(r,i,a);if(e=Pe(e),isNaN(l))return{stiffness:X.stiffness,damping:X.damping,duration:e};{const c=Math.pow(l,2)*o;return{stiffness:c,damping:s*2*Math.sqrt(o*c),duration:e}}}const vu=12;function yu(e,t,n){let o=n;for(let r=1;r<vu;r++)o=o-e(o)/t(o);return o}function eo(e,t){return e*Math.sqrt(1-t*t)}const wu=["duration","bounce"],bu=["stiffness","damping","mass"];function Vi(e,t){return t.some(n=>e[n]!==void 0)}function xu(e){let t={velocity:X.velocity,stiffness:X.stiffness,damping:X.damping,mass:X.mass,isResolvedFromDuration:!1,...e};if(!Vi(e,bu)&&Vi(e,wu))if(e.visualDuration){const n=e.visualDuration,o=2*Math.PI/(n*1.2),r=o*o,i=2*$e(.05,1,1-(e.bounce||0))*Math.sqrt(r);t={...t,mass:X.mass,stiffness:r,damping:i}}else{const n=gu(e);t={...t,...n,mass:X.mass},t.isResolvedFromDuration=!0}return t}function Jt(e=X.visualDuration,t=X.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:o,restDelta:r}=n;const i=n.keyframes[0],s=n.keyframes[n.keyframes.length-1],a={done:!1,value:i},{stiffness:l,damping:c,mass:d,duration:u,velocity:f,isResolvedFromDuration:h}=xu({...n,velocity:-ge(n.velocity||0)}),v=f||0,y=c/(2*Math.sqrt(l*d)),b=s-i,w=ge(Math.sqrt(l/d)),S=Math.abs(b)<5;o||(o=S?X.restSpeed.granular:X.restSpeed.default),r||(r=S?X.restDelta.granular:X.restDelta.default);let x;if(y<1){const T=eo(w,y);x=k=>{const V=Math.exp(-y*w*k);return s-V*((v+y*w*b)/T*Math.sin(T*k)+b*Math.cos(T*k))}}else if(y===1)x=T=>s-Math.exp(-w*T)*(b+(v+w*b)*T);else{const T=w*Math.sqrt(y*y-1);x=k=>{const V=Math.exp(-y*w*k),$=Math.min(T*k,300);return s-V*((v+y*w*b)*Math.sinh($)+T*b*Math.cosh($))/T}}const P={calculatedDuration:h&&u||null,next:T=>{const k=x(T);if(h)a.done=T>=u;else{let V=T===0?v:0;y<1&&(V=T===0?Pe(v):Mi(x,T,k));const $=Math.abs(V)<=o,A=Math.abs(s-k)<=r;a.done=$&&A}return a.value=a.done?s:k,a},toString:()=>{const T=Math.min(Jn(P),Zt),k=ki(V=>P.next(T*V).value,T,30);return T+"ms "+k},toTransition:()=>{}};return P}Jt.applyToOptions=e=>{const t=mu(e,100,Jt);return e.ease=t.ease,e.duration=Pe(t.duration),e.type="keyframes",e};function to({keyframes:e,velocity:t=0,power:n=.8,timeConstant:o=325,bounceDamping:r=10,bounceStiffness:i=500,modifyTarget:s,min:a,max:l,restDelta:c=.5,restSpeed:d}){const u=e[0],f={done:!1,value:u},h=$=>a!==void 0&&$<a||l!==void 0&&$>l,v=$=>a===void 0?l:l===void 0||Math.abs(a-$)<Math.abs(l-$)?a:l;let y=n*t;const b=u+y,w=s===void 0?b:s(b);w!==b&&(y=w-u);const S=$=>-y*Math.exp(-$/o),x=$=>w+S($),P=$=>{const A=S($),I=x($);f.done=Math.abs(A)<=c,f.value=f.done?w:I};let T,k;const V=$=>{h(f.value)&&(T=$,k=Jt({keyframes:[f.value,v(f.value)],velocity:Mi(x,$,f.value),damping:r,stiffness:i,restDelta:c,restSpeed:d}))};return V(0),{calculatedDuration:null,next:$=>{let A=!1;return!k&&T===void 0&&(A=!0,P($),V($)),T!==void 0&&$>=T?k.next($-T):(!A&&P($),f)}}}function Su(e,t,n){const o=[],r=n||Ee.mix||Pi,i=e.length-1;for(let s=0;s<i;s++){let a=r(e[s],e[s+1]);if(t){const l=Array.isArray(t)?t[s]||pe:t;a=Tt(l,a)}o.push(a)}return o}function Cu(e,t,{clamp:n=!0,ease:o,mixer:r}={}){const i=e.length;if(Ve(i===t.length,"Both input and output ranges must be the same length","range-length"),i===1)return()=>t[0];if(i===2&&t[0]===t[1])return()=>t[1];const s=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=Su(t,o,r),l=a.length,c=d=>{if(s&&d<e[0])return t[0];let u=0;if(l>1)for(;u<e.length-2&&!(d<e[u+1]);u++);const f=$t(e[u],e[u+1],d);return a[u](f)};return n?d=>c($e(e[0],e[i-1],d)):c}function Tu(e,t){const n=e[e.length-1];for(let o=1;o<=t;o++){const r=$t(0,t,o);e.push(Y(n,1,r))}}function $u(e){const t=[0];return Tu(t,e.length-1),t}function Pu(e,t){return e.map(n=>n*t)}function ku(e,t){return e.map(()=>t||li).splice(0,e.length-1)}function it({duration:e=300,keyframes:t,times:n,ease:o="easeInOut"}){const r=Nc(o)?o.map(di):di(o),i={done:!1,value:t[0]},s=Pu(n&&n.length===t.length?n:$u(t),e),a=Cu(s,t,{ease:Array.isArray(r)?r:ku(t,r)});return{calculatedDuration:e,next:l=>(i.value=a(l),i.done=l>=e,i)}}const Mu=e=>e!==null;function no(e,{repeat:t,repeatType:n="loop"},o,r=1){const i=e.filter(Mu),a=r<0||t&&n!=="loop"&&t%2===1?0:i.length-1;return!a||o===void 0?i[a]:o}const Vu={decay:to,inertia:to,tween:it,keyframes:it,spring:Jt};function Ei(e){typeof e.type=="string"&&(e.type=Vu[e.type])}class oo{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const Eu=e=>e/100;class ro extends oo{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{const{motionValue:n}=this.options;n&&n.updatedAt!==le.now()&&this.tick(le.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;Ei(t);const{type:n=it,repeat:o=0,repeatDelay:r=0,repeatType:i,velocity:s=0}=t;let{keyframes:a}=t;const l=n||it;process.env.NODE_ENV!=="production"&&l!==it&&Ve(a.length<=2,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${a}`,"spring-two-frames"),l!==it&&typeof a[0]!="number"&&(this.mixKeyframes=Tt(Eu,Pi(a[0],a[1])),a=[0,100]);const c=l({...t,keyframes:a});i==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...a].reverse(),velocity:-s})),c.calculatedDuration===null&&(c.calculatedDuration=Jn(c));const{calculatedDuration:d}=c;this.calculatedDuration=d,this.resolvedDuration=d+r,this.totalDuration=this.resolvedDuration*(o+1)-r,this.generator=c}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:o,totalDuration:r,mixKeyframes:i,mirroredGenerator:s,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return o.next(0);const{delay:c=0,keyframes:d,repeat:u,repeatType:f,repeatDelay:h,type:v,onUpdate:y,finalKeyframe:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-r/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const w=this.currentTime-c*(this.playbackSpeed>=0?1:-1),S=this.playbackSpeed>=0?w<0:w>r;this.currentTime=Math.max(w,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=r);let x=this.currentTime,P=o;if(u){const $=Math.min(this.currentTime,r)/a;let A=Math.floor($),I=$%1;!I&&$>=1&&(I=1),I===1&&A--,A=Math.min(A,u+1),A%2&&(f==="reverse"?(I=1-I,h&&(I-=h/a)):f==="mirror"&&(P=s)),x=$e(0,1,I)*a}const T=S?{done:!1,value:d[0]}:P.next(x);i&&(T.value=i(T.value));let{done:k}=T;!S&&l!==null&&(k=this.playbackSpeed>=0?this.currentTime>=r:this.currentTime<=0);const V=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&k);return V&&v!==to&&(T.value=no(d,this.options,b,this.speed)),y&&y(T.value),V&&this.finish(),T}then(t,n){return this.finished.then(t,n)}get duration(){return ge(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+ge(t)}get time(){return ge(this.currentTime)}set time(t){t=Pe(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(le.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=ge(this.currentTime))}play(){if(this.isStopped)return;const{driver:t=hu,startTime:n}=this.options;this.driver||(this.driver=t(r=>this.tick(r))),this.options.onPlay?.();const o=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=o):this.holdTime!==null?this.startTime=o-this.holdTime:this.startTime||(this.startTime=n??o),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(le.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}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}}function Du(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const Ke=e=>e*180/Math.PI,io=e=>{const t=Ke(Math.atan2(e[1],e[0]));return so(t)},Fu={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:io,rotateZ:io,skewX:e=>Ke(Math.atan(e[1])),skewY:e=>Ke(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},so=e=>(e=e%360,e<0&&(e+=360),e),Di=io,Fi=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),Ai=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),Au={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Fi,scaleY:Ai,scale:e=>(Fi(e)+Ai(e))/2,rotateX:e=>so(Ke(Math.atan2(e[6],e[5]))),rotateY:e=>so(Ke(Math.atan2(-e[2],e[0]))),rotateZ:Di,rotate:Di,skewX:e=>Ke(Math.atan(e[4])),skewY:e=>Ke(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function ao(e){return e.includes("scale")?1:0}function lo(e,t){if(!e||e==="none")return ao(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let o,r;if(n)o=Au,r=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);o=Fu,r=a}if(!r)return ao(t);const i=o[t],s=r[1].split(",").map(Lu);return typeof i=="function"?i(s):s[i]}const Iu=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return lo(n,t)};function Lu(e){return parseFloat(e.trim())}const st=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],at=new Set(st),Ii=e=>e===ot||e===E,Ru=new Set(["x","y","z"]),_u=st.filter(e=>!Ru.has(e));function Bu(e){const t=[];return _u.forEach(n=>{const o=e.getValue(n);o!==void 0&&(t.push([n,o.get()]),o.set(n.startsWith("scale")?1:0))}),t}const Be={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-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})=>lo(t,"x"),y:(e,{transform:t})=>lo(t,"y")};Be.translateX=Be.x,Be.translateY=Be.y;const qe=new Set;let co=!1,uo=!1,fo=!1;function Li(){if(uo){const e=Array.from(qe).filter(o=>o.needsMeasurement),t=new Set(e.map(o=>o.element)),n=new Map;t.forEach(o=>{const r=Bu(o);r.length&&(n.set(o,r),o.render())}),e.forEach(o=>o.measureInitialState()),t.forEach(o=>{o.render();const r=n.get(o);r&&r.forEach(([i,s])=>{o.getValue(i)?.set(s)})}),e.forEach(o=>o.measureEndState()),e.forEach(o=>{o.suspendedScrollY!==void 0&&window.scrollTo(0,o.suspendedScrollY)})}uo=!1,co=!1,qe.forEach(e=>e.complete(fo)),qe.clear()}function Ri(){qe.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(uo=!0)})}function Nu(){fo=!0,Ri(),Li(),fo=!1}class ho{constructor(t,n,o,r,i,s=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=o,this.motionValue=r,this.element=i,this.isAsync=s}scheduleResolve(){this.state="scheduled",this.isAsync?(qe.add(this),co||(co=!0,W.read(Ri),W.resolveKeyframes(Li))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:o,motionValue:r}=this;if(t[0]===null){const i=r?.get(),s=t[t.length-1];if(i!==void 0)t[0]=i;else if(o&&n){const a=o.readValue(n,s);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=s),r&&i===void 0&&r.set(t[0])}Du(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),qe.delete(this)}cancel(){this.state==="scheduled"&&(qe.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const zu=e=>e.startsWith("--");function Ou(e,t,n){zu(t)?e.style.setProperty(t,n):e.style[t]=n}const Hu=_n(()=>window.ScrollTimeline!==void 0),ju={};function Gu(e,t){const n=_n(e);return()=>ju[t]??n()}const _i=Gu(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),Dt=([e,t,n,o])=>`cubic-bezier(${e}, ${t}, ${n}, ${o})`,Bi={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Dt([0,.65,.55,1]),circOut:Dt([.55,0,1,.45]),backIn:Dt([.31,.01,.66,-.59]),backOut:Dt([.33,1.53,.69,.99])};function Ni(e,t){if(e)return typeof e=="function"?_i()?ki(e,t):"ease-out":ci(e)?Dt(e):Array.isArray(e)?e.map(n=>Ni(n,t)||Bi.easeOut):Bi[e]}function Uu(e,t,n,{delay:o=0,duration:r=300,repeat:i=0,repeatType:s="loop",ease:a="easeOut",times:l}={},c=void 0){const d={[t]:n};l&&(d.offset=l);const u=Ni(a,r);Array.isArray(u)&&(d.easing=u);const f={delay:o,duration:r,easing:Array.isArray(u)?"linear":u,fill:"both",iterations:i+1,direction:s==="reverse"?"alternate":"normal"};return c&&(f.pseudoElement=c),e.animate(d,f)}function zi(e){return typeof e=="function"&&"applyToOptions"in e}function Wu({type:e,...t}){return zi(e)&&_i()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class Ku extends oo{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:o,keyframes:r,pseudoElement:i,allowFlatten:s=!1,finalKeyframe:a,onComplete:l}=t;this.isPseudoElement=!!i,this.allowFlatten=s,this.options=t,Ve(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");const c=Wu(t);this.animation=Uu(n,o,r,c,i),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){const d=no(r,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(d):Ou(n,o,d),this.animation.cancel()}l?.(),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;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){const t=this.animation.effect?.getComputedTiming?.().duration||0;return ge(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+ge(t)}get time(){return ge(Number(this.animation.currentTime)||0)}set time(t){this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=Pe(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,observe:n}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&Hu()?(this.animation.timeline=t,pe):n(this)}}const Oi={anticipate:ii,backInOut:ri,circInOut:ai};function qu(e){return e in Oi}function Yu(e){typeof e.ease=="string"&&qu(e.ease)&&(e.ease=Oi[e.ease])}const mo=10;class Xu extends Ku{constructor(t){Yu(t),Ei(t),super(t),t.startTime!==void 0&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:o,onComplete:r,element:i,...s}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new ro({...s,autoplay:!1}),l=Math.max(mo,le.now()-this.startTime),c=$e(0,mo,l-mo);n.setWithVelocity(a.sample(Math.max(0,l-c)).value,a.sample(l).value,c),a.stop()}}const Hi=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(_e.test(e)||e==="0")&&!e.startsWith("url("));function Zu(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function Ju(e,t,n,o){const r=e[0];if(r===null)return!1;if(t==="display"||t==="visibility")return!0;const i=e[e.length-1],s=Hi(r,t),a=Hi(i,t);return nt(s===a,`You are trying to animate ${t} from "${r}" to "${i}". "${s?i:r}" is not an animatable value.`,"value-not-animatable"),!s||!a?!1:Zu(e)||(n==="spring"||zi(n))&&o}function po(e){e.duration=0,e.type="keyframes"}const Qu=new Set(["opacity","clipPath","filter","transform"]),ed=_n(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function td(e){const{motionValue:t,name:n,repeatDelay:o,repeatType:r,damping:i,type:s}=e;if(!(t?.owner?.current instanceof HTMLElement))return!1;const{onUpdate:l,transformTemplate:c}=t.owner.getProps();return ed()&&n&&Qu.has(n)&&(n!=="transform"||!c)&&!l&&!o&&r!=="mirror"&&i!==0&&s!=="inertia"}const nd=40;class od extends oo{constructor({autoplay:t=!0,delay:n=0,type:o="keyframes",repeat:r=0,repeatDelay:i=0,repeatType:s="loop",keyframes:a,name:l,motionValue:c,element:d,...u}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=le.now();const f={autoplay:t,delay:n,type:o,repeat:r,repeatDelay:i,repeatType:s,name:l,motionValue:c,element:d,...u},h=d?.KeyframeResolver||ho;this.keyframeResolver=new h(a,(v,y,b)=>this.onKeyframesResolved(v,y,f,!b),l,c,d),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,n,o,r){this.keyframeResolver=void 0;const{name:i,type:s,velocity:a,delay:l,isHandoff:c,onUpdate:d}=o;this.resolvedAt=le.now(),Ju(t,i,s,a)||((Ee.instantAnimations||!l)&&d?.(no(t,o,n)),t[0]=t[t.length-1],po(o),o.repeat=0);const f={startTime:r?this.resolvedAt?this.resolvedAt-this.createdAt>nd?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...o,keyframes:t},h=!c&&td(f)?new Xu({...f,element:f.motionValue.owner.current}):new ro(f);h.finished.then(()=>this.notifyFinished()).catch(pe),this.pendingTimeline&&(this.stopTimeline=h.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=h}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),Nu()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}const rd=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function id(e){const t=rd.exec(e);if(!t)return[,];const[,n,o,r]=t;return[`--${n??o}`,r]}const sd=4;function ji(e,t,n=1){Ve(n<=sd,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");const[o,r]=id(e);if(!o)return;const i=window.getComputedStyle(t).getPropertyValue(o);if(i){const s=i.trim();return Yr(s)?parseFloat(s):s}return jn(r)?ji(r,t,n+1):r}function go(e,t){return e?.[t]??e?.default??e}const ad={type:"spring",stiffness:500,damping:25,restSpeed:10},ld=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),cd={type:"keyframes",duration:.8},ud={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},dd=(e,{keyframes:t})=>t.length>2?cd:at.has(e)?e.startsWith("scale")?ld(t[1]):ad:ud;function fd({when:e,delay:t,delayChildren:n,staggerChildren:o,staggerDirection:r,repeat:i,repeatType:s,repeatDelay:a,from:l,elapsed:c,...d}){return!!Object.keys(d).length}const hd=e=>e!==null;function md(e,{repeat:t,repeatType:n="loop"},o){const r=e.filter(hd),i=t&&n!=="loop"&&t%2===1?0:r.length-1;return r[i]}function Gi(e,t,n,o=0,r=1){const i=Array.from(e).sort((c,d)=>c.sortNodePosition(d)).indexOf(t),s=e.size,a=(s-1)*o;return typeof n=="function"?n(i,s):r===1?i*o:a-i*o}const vo=(e,t,n,o={},r,i)=>s=>{const a=go(o,e)||{},l=a.delay||o.delay||0;let{elapsed:c=0}=o;c=c-Pe(l);const d={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-c,onUpdate:f=>{t.set(f),a.onUpdate&&a.onUpdate(f)},onComplete:()=>{s(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:i?void 0:r};fd(a)||Object.assign(d,dd(e,d)),d.duration&&(d.duration=Pe(d.duration)),d.repeatDelay&&(d.repeatDelay=Pe(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let u=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(po(d),d.delay===0&&(u=!0)),(Ee.instantAnimations||Ee.skipAnimations)&&(u=!0,po(d),d.delay=0),d.allowFlatten=!a.type&&!a.ease,u&&!i&&t.get()!==void 0){const f=md(d.keyframes,a);if(f!==void 0){W.update(()=>{d.onUpdate(f),d.onComplete()});return}}return a.isSync?new ro(d):new od(d)},Ui=new Set(["width","height","top","left","right","bottom",...st]),Wi=30,pd=e=>!isNaN(parseFloat(e));class gd{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=o=>{const r=le.now();if(this.updatedAt!==r&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(o),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(const i of this.dependents)i.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=le.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=pd(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return process.env.NODE_ENV!=="production"&&Nn(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new Bn);const o=this.events[t].add(n);return t==="change"?()=>{o(),W.read(()=>{this.events.change.getSize()||this.stop()})}:o}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,o){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-o}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=le.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Wi)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Wi);return Jr(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function lt(e,t){return new gd(e,t)}function Ki(e){const t=[{},{}];return e?.values.forEach((n,o)=>{t[0][o]=n.get(),t[1][o]=n.getVelocity()}),t}function yo(e,t,n,o){if(typeof t=="function"){const[r,i]=Ki(o);t=t(n!==void 0?n:e.custom,r,i)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[r,i]=Ki(o);t=t(n!==void 0?n:e.custom,r,i)}return t}function ct(e,t,n){const o=e.getProps();return yo(o,t,n!==void 0?n:o.custom,e)}const wo=e=>Array.isArray(e);function vd(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,lt(n))}function yd(e){return wo(e)?e[e.length-1]||0:e}function wd(e,t){const n=ct(e,t);let{transitionEnd:o={},transition:r={},...i}=n||{};i={...i,...o};for(const s in i){const a=yd(i[s]);vd(e,s,a)}}const ie=e=>!!(e&&e.getVelocity);function bd(e){return!!(ie(e)&&e.add)}function bo(e,t){const n=e.getValue("willChange");if(bd(n))return n.add(t);if(!n&&Ee.WillChange){const o=new Ee.WillChange("auto");e.addValue("willChange",o),o.add(t)}}function xo(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const qi="data-"+xo("framerAppearId");function Yi(e){return e.props[qi]}function xd({protectedKeys:e,needsAnimating:t},n){const o=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,o}function Xi(e,t,{delay:n=0,transitionOverride:o,type:r}={}){let{transition:i=e.getDefaultTransition(),transitionEnd:s,...a}=t;o&&(i=o);const l=[],c=r&&e.animationState&&e.animationState.getState()[r];for(const d in a){const u=e.getValue(d,e.latestValues[d]??null),f=a[d];if(f===void 0||c&&xd(c,d))continue;const h={delay:n,...go(i||{},d)},v=u.get();if(v!==void 0&&!u.isAnimating&&!Array.isArray(f)&&f===v&&!h.velocity)continue;let y=!1;if(window.MotionHandoffAnimation){const w=Yi(e);if(w){const S=window.MotionHandoffAnimation(w,d,W);S!==null&&(h.startTime=S,y=!0)}}bo(e,d),u.start(vo(d,u,f,e.shouldReduceMotion&&Ui.has(d)?{type:!1}:h,e,y));const b=u.animation;b&&l.push(b)}return s&&Promise.all(l).then(()=>{W.update(()=>{s&&wd(e,s)})}),l}function So(e,t,n={}){const o=ct(e,t,n.type==="exit"?e.presenceContext?.custom:void 0);let{transition:r=e.getDefaultTransition()||{}}=o||{};n.transitionOverride&&(r=n.transitionOverride);const i=o?()=>Promise.all(Xi(e,o,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(l=0)=>{const{delayChildren:c=0,staggerChildren:d,staggerDirection:u}=r;return Sd(e,t,l,c,d,u,n)}:()=>Promise.resolve(),{when:a}=r;if(a){const[l,c]=a==="beforeChildren"?[i,s]:[s,i];return l().then(()=>c())}else return Promise.all([i(),s(n.delay)])}function Sd(e,t,n=0,o=0,r=0,i=1,s){const a=[];for(const l of e.variantChildren)l.notify("AnimationStart",t),a.push(So(l,t,{...s,delay:n+(typeof o=="function"?0:o)+Gi(e.variantChildren,l,o,r,i)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(a)}function Cd(e,t,n={}){e.notify("AnimationStart",t);let o;if(Array.isArray(t)){const r=t.map(i=>So(e,i,n));o=Promise.all(r)}else if(typeof t=="string")o=So(e,t,n);else{const r=typeof t=="function"?ct(e,t,n.custom):t;o=Promise.all(Xi(e,r,n))}return o.then(()=>{e.notify("AnimationComplete",t)})}const Td={test:e=>e==="auto",parse:e=>e},Zi=e=>t=>t.test(e),Ji=[ot,E,ke,Re,Zc,Xc,Td],Qi=e=>Ji.find(Zi(e));function $d(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||Zr(e):!0}const Pd=new Set(["brightness","contrast","saturate","opacity"]);function kd(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[o]=n.match(Gn)||[];if(!o)return e;const r=n.replace(o,"");let i=Pd.has(t)?1:0;return o!==n&&(i*=100),t+"("+i+r+")"}const Md=/\b([a-z-]*)\(.*?\)/gu,Co={..._e,getAnimatableNone:e=>{const t=e.match(Md);return t?t.map(kd).join(" "):e}},es={...ot,transform:Math.round},To={borderWidth:E,borderTopWidth:E,borderRightWidth:E,borderBottomWidth:E,borderLeftWidth:E,borderRadius:E,radius:E,borderTopLeftRadius:E,borderTopRightRadius:E,borderBottomRightRadius:E,borderBottomLeftRadius:E,width:E,maxWidth:E,height:E,maxHeight:E,top:E,right:E,bottom:E,left:E,inset:E,insetBlock:E,insetBlockStart:E,insetBlockEnd:E,insetInline:E,insetInlineStart:E,insetInlineEnd:E,padding:E,paddingTop:E,paddingRight:E,paddingBottom:E,paddingLeft:E,paddingBlock:E,paddingBlockStart:E,paddingBlockEnd:E,paddingInline:E,paddingInlineStart:E,paddingInlineEnd:E,margin:E,marginTop:E,marginRight:E,marginBottom:E,marginLeft:E,marginBlock:E,marginBlockStart:E,marginBlockEnd:E,marginInline:E,marginInlineStart:E,marginInlineEnd:E,backgroundPositionX:E,backgroundPositionY:E,...{rotate:Re,rotateX:Re,rotateY:Re,rotateZ:Re,scale:Yt,scaleX:Yt,scaleY:Yt,scaleZ:Yt,skew:Re,skewX:Re,skewY:Re,distance:E,translateX:E,translateY:E,translateZ:E,x:E,y:E,z:E,perspective:E,transformPerspective:E,opacity:kt,originX:vi,originY:vi,originZ:E},zIndex:es,fillOpacity:kt,strokeOpacity:kt,numOctaves:es},Vd={...To,color:Q,backgroundColor:Q,outlineColor:Q,fill:Q,stroke:Q,borderColor:Q,borderTopColor:Q,borderRightColor:Q,borderBottomColor:Q,borderLeftColor:Q,filter:Co,WebkitFilter:Co},ts=e=>Vd[e];function ns(e,t){let n=ts(e);return n!==Co&&(n=_e),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const Ed=new Set(["auto","none","0"]);function Dd(e,t,n){let o=0,r;for(;o<e.length&&!r;){const i=e[o];typeof i=="string"&&!Ed.has(i)&&Et(i).values.length&&(r=e[o]),o++}if(r&&n)for(const i of t)e[i]=ns(n,r)}class Fd extends ho{constructor(t,n,o,r,i){super(t,n,o,r,i,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:o}=this;if(!n||!n.current)return;super.readKeyframes();for(let d=0;d<t.length;d++){let u=t[d];if(typeof u=="string"&&(u=u.trim(),jn(u))){const f=ji(u,n.current);f!==void 0&&(t[d]=f),d===t.length-1&&(this.finalKeyframe=u)}}if(this.resolveNoneKeyframes(),!Ui.has(o)||t.length!==2)return;const[r,i]=t,s=Qi(r),a=Qi(i),l=pi(r),c=pi(i);if(l!==c&&Be[o]){this.needsMeasurement=!0;return}if(s!==a)if(Ii(s)&&Ii(a))for(let d=0;d<t.length;d++){const u=t[d];typeof u=="string"&&(t[d]=parseFloat(u))}else Be[o]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,o=[];for(let r=0;r<t.length;r++)(t[r]===null||$d(t[r]))&&o.push(r);o.length&&Dd(t,o,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:o}=this;if(!t||!t.current)return;o==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Be[o](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const r=n[n.length-1];r!==void 0&&t.getValue(o,r).jump(r,!1)}measureEndState(){const{element:t,name:n,unresolvedKeyframes:o}=this;if(!t||!t.current)return;const r=t.getValue(n);r&&r.jump(this.measuredOrigin,!1);const i=o.length-1,s=o[i];o[i]=Be[n](t.measureViewportBox(),window.getComputedStyle(t.current)),s!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=s),this.removedTransforms?.length&&this.removedTransforms.forEach(([a,l])=>{t.getValue(a).set(l)}),this.resolveNoneKeyframes()}}function Ad(e,t,n){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let o=document;const r=n?.[e]??o.querySelectorAll(e);return r?Array.from(r):[]}return Array.from(e)}const os=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function rs(e){return Xr(e)&&"offsetHeight"in e}const{schedule:$o}=fi(queueMicrotask,!1),be={x:!1,y:!1};function is(){return be.x||be.y}function Id(e){return e==="x"||e==="y"?be[e]?null:(be[e]=!0,()=>{be[e]=!1}):be.x||be.y?null:(be.x=be.y=!0,()=>{be.x=be.y=!1})}function ss(e,t){const n=Ad(e),o=new AbortController,r={passive:!0,...t,signal:o.signal};return[n,r,()=>o.abort()]}function as(e){return!(e.pointerType==="touch"||is())}function Ld(e,t,n={}){const[o,r,i]=ss(e,n),s=a=>{if(!as(a))return;const{target:l}=a,c=t(l,a);if(typeof c!="function"||!l)return;const d=u=>{as(u)&&(c(u),l.removeEventListener("pointerleave",d))};l.addEventListener("pointerleave",d,r)};return o.forEach(a=>{a.addEventListener("pointerenter",s,r)}),i}const ls=(e,t)=>t?e===t?!0:ls(e,t.parentElement):!1,Po=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,Rd=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function cs(e){return Rd.has(e.tagName)||e.isContentEditable===!0}const Qt=new WeakSet;function us(e){return t=>{t.key==="Enter"&&e(t)}}function ko(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const _d=(e,t)=>{const n=e.currentTarget;if(!n)return;const o=us(()=>{if(Qt.has(n))return;ko(n,"down");const r=us(()=>{ko(n,"up")}),i=()=>ko(n,"cancel");n.addEventListener("keyup",r,t),n.addEventListener("blur",i,t)});n.addEventListener("keydown",o,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",o),t)};function ds(e){return Po(e)&&!is()}function Bd(e,t,n={}){const[o,r,i]=ss(e,n),s=a=>{const l=a.currentTarget;if(!ds(a))return;Qt.add(l);const c=t(l,a),d=(h,v)=>{window.removeEventListener("pointerup",u),window.removeEventListener("pointercancel",f),Qt.has(l)&&Qt.delete(l),ds(h)&&typeof c=="function"&&c(h,{success:v})},u=h=>{d(h,l===window||l===document||n.useGlobalTarget||ls(l,h.target))},f=h=>{d(h,!1)};window.addEventListener("pointerup",u,r),window.addEventListener("pointercancel",f,r)};return o.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",s,r),rs(a)&&(a.addEventListener("focus",c=>_d(c,r)),!cs(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),i}function fs(e){return Xr(e)&&"ownerSVGElement"in e}function Nd(e){return fs(e)&&e.tagName==="svg"}const zd=[...Ji,Q,_e],Od=e=>zd.find(Zi(e)),hs=()=>({translate:0,scale:1,origin:0,originPoint:0}),ut=()=>({x:hs(),y:hs()}),ms=()=>({min:0,max:0}),ee=()=>({x:ms(),y:ms()}),Mo={current:null},ps={current:!1},Hd=typeof window<"u";function jd(){if(ps.current=!0,!!Hd)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Mo.current=e.matches;e.addEventListener("change",t),t()}else Mo.current=!1}const Gd=new WeakMap;function en(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function Ft(e){return typeof e=="string"||Array.isArray(e)}const Vo=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Eo=["initial",...Vo];function tn(e){return en(e.animate)||Eo.some(t=>Ft(e[t]))}function gs(e){return!!(tn(e)||e.variants)}function Ud(e,t,n){for(const o in t){const r=t[o],i=n[o];if(ie(r))e.addValue(o,r);else if(ie(i))e.addValue(o,lt(r,{owner:e}));else if(i!==r)if(e.hasValue(o)){const s=e.getValue(o);s.liveStyle===!0?s.jump(r):s.hasAnimated||s.set(r)}else{const s=e.getStaticValue(o);e.addValue(o,lt(s!==void 0?s:r,{owner:e}))}}for(const o in n)t[o]===void 0&&e.removeValue(o);return t}const vs=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let nn={};function ys(e){nn=e}function Wd(){return nn}class Kd{scrapeMotionValuesFromProps(t,n,o){return{}}constructor({parent:t,props:n,presenceContext:o,reducedMotionConfig:r,blockInitialAnimation:i,visualState:s},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=ho,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const f=le.now();this.renderScheduledAt<f&&(this.renderScheduledAt=f,W.render(this.render,!1,!0))};const{latestValues:l,renderState:c}=s;this.latestValues=l,this.baseTarget={...l},this.initialValues=n.initial?{...l}:{},this.renderState=c,this.parent=t,this.props=n,this.presenceContext=o,this.depth=t?t.depth+1:0,this.reducedMotionConfig=r,this.options=a,this.blockInitialAnimation=!!i,this.isControllingVariants=tn(n),this.isVariantNode=gs(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:d,...u}=this.scrapeMotionValuesFromProps(n,{},this);for(const f in u){const h=u[f];l[f]!==void 0&&ie(h)&&h.set(l[f])}}mount(t){this.current=t,Gd.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,o)=>this.bindToMotionValue(o,n)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(ps.current||jd(),this.shouldReduceMotion=Mo.current),process.env.NODE_ENV!=="production"&&Nn(this.shouldReduceMotion!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected.","reduced-motion-disabled"),this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),Le(this.notifyUpdate),Le(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const n=this.features[t];n&&(n.unmount(),n.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const o=at.has(t);o&&this.onBindTransform&&this.onBindTransform();const r=n.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&W.preRender(this.notifyUpdate),o&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let i;typeof window<"u"&&window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{r(),i&&i(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in nn){const n=nn[t];if(!n)continue;const{isEnabled:o,Feature:r}=n;if(!this.features[t]&&r&&o(this.props)&&(this.features[t]=new r(this)),this.features[t]){const i=this.features[t];i.isMounted?i.update():(i.mount(),i.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):ee()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let o=0;o<vs.length;o++){const r=vs[o];this.propEventSubscriptions[r]&&(this.propEventSubscriptions[r](),delete this.propEventSubscriptions[r]);const i="on"+r,s=t[i];s&&(this.propEventSubscriptions[r]=this.on(r,s))}this.prevMotionValues=Ud(this,this.scrapeMotionValuesFromProps(t,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const o=this.values.get(t);n!==o&&(o&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let o=this.values.get(t);return o===void 0&&n!==void 0&&(o=lt(n===null?void 0:n,{owner:this}),this.addValue(t,o)),o}readValue(t,n){let o=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return o!=null&&(typeof o=="string"&&(Yr(o)||Zr(o))?o=parseFloat(o):!Od(o)&&_e.test(n)&&(o=ns(t,n)),this.setBaseTarget(t,ie(o)?o.get():o)),ie(o)?o.get():o}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){const{initial:n}=this.props;let o;if(typeof n=="string"||typeof n=="object"){const i=yo(this.props,n,this.presenceContext?.custom);i&&(o=i[t])}if(n&&o!==void 0)return o;const r=this.getBaseTargetFromProps(this.props,t);return r!==void 0&&!ie(r)?r:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new Bn),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){$o.render(this.render)}}class Ne{constructor(t){this.isMounted=!1,this.node=t}update(){}}class ws extends Kd{constructor(){super(...arguments),this.KeyframeResolver=Fd}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const o=t.style;return o?o[n]:void 0}removeValueFromRenderState(t,{vars:n,style:o}){delete n[t],delete o[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;ie(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function bs({top:e,left:t,right:n,bottom:o}){return{x:{min:t,max:n},y:{min:e,max:o}}}function qd({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function Yd(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),o=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:o.y,right:o.x}}function Do(e){return e===void 0||e===1}function Fo({scale:e,scaleX:t,scaleY:n}){return!Do(e)||!Do(t)||!Do(n)}function Ye(e){return Fo(e)||xs(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function xs(e){return Ss(e.x)||Ss(e.y)}function Ss(e){return e&&e!=="0%"}function on(e,t,n){const o=e-n,r=t*o;return n+r}function Cs(e,t,n,o,r){return r!==void 0&&(e=on(e,r,o)),on(e,n,o)+t}function Ao(e,t=0,n=1,o,r){e.min=Cs(e.min,t,n,o,r),e.max=Cs(e.max,t,n,o,r)}function Ts(e,{x:t,y:n}){Ao(e.x,t.translate,t.scale,t.originPoint),Ao(e.y,n.translate,n.scale,n.originPoint)}const $s=.999999999999,Ps=1.0000000000001;function Xd(e,t,n,o=!1){const r=n.length;if(!r)return;t.x=t.y=1;let i,s;for(let a=0;a<r;a++){i=n[a],s=i.projectionDelta;const{visualElement:l}=i.options;l&&l.props.style&&l.props.style.display==="contents"||(o&&i.options.layoutScroll&&i.scroll&&i!==i.root&&ft(e,{x:-i.scroll.offset.x,y:-i.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,Ts(e,s)),o&&Ye(i.latestValues)&&ft(e,i.latestValues))}t.x<Ps&&t.x>$s&&(t.x=1),t.y<Ps&&t.y>$s&&(t.y=1)}function dt(e,t){e.min=e.min+t,e.max=e.max+t}function ks(e,t,n,o,r=.5){const i=Y(e.min,e.max,r);Ao(e,t,n,i,o)}function ft(e,t){ks(e.x,t.x,t.scaleX,t.scale,t.originX),ks(e.y,t.y,t.scaleY,t.scale,t.originY)}function Ms(e,t){return bs(Yd(e.getBoundingClientRect(),t))}function Zd(e,t,n){const o=Ms(e,n),{scroll:r}=t;return r&&(dt(o.x,r.offset.x),dt(o.y,r.offset.y)),o}const Jd={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Qd=st.length;function ef(e,t,n){let o="",r=!0;for(let i=0;i<Qd;i++){const s=st[i],a=e[s];if(a===void 0)continue;let l=!0;if(typeof a=="number"?l=a===(s.startsWith("scale")?1:0):l=parseFloat(a)===0,!l||n){const c=os(a,To[s]);if(!l){r=!1;const d=Jd[s]||s;o+=`${d}(${c}) `}n&&(t[s]=c)}}return o=o.trim(),n?o=n(t,r?"":o):r&&(o="none"),o}function Io(e,t,n){const{style:o,vars:r,transformOrigin:i}=e;let s=!1,a=!1;for(const l in t){const c=t[l];if(at.has(l)){s=!0;continue}else if(mi(l)){r[l]=c;continue}else{const d=os(c,To[l]);l.startsWith("origin")?(a=!0,i[l]=d):o[l]=d}}if(t.transform||(s||n?o.transform=ef(t,e.transform,n):o.transform&&(o.transform="none")),a){const{originX:l="50%",originY:c="50%",originZ:d=0}=i;o.transformOrigin=`${l} ${c} ${d}`}}function Vs(e,{style:t,vars:n},o,r){const i=e.style;let s;for(s in t)i[s]=t[s];r?.applyProjectionStyles(i,o);for(s in n)i.setProperty(s,n[s])}function Es(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const At={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(E.test(e))e=parseFloat(e);else return e;const n=Es(e,t.target.x),o=Es(e,t.target.y);return`${n}% ${o}%`}},tf={correct:(e,{treeScale:t,projectionDelta:n})=>{const o=e,r=_e.parse(e);if(r.length>5)return o;const i=_e.createTransformer(e),s=typeof r[0]!="number"?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;r[0+s]/=a,r[1+s]/=l;const c=Y(a,l,.5);return typeof r[2+s]=="number"&&(r[2+s]/=c),typeof r[3+s]=="number"&&(r[3+s]/=c),i(r)}},Lo={borderRadius:{...At,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:At,borderTopRightRadius:At,borderBottomLeftRadius:At,borderBottomRightRadius:At,boxShadow:tf};function Ds(e,{layout:t,layoutId:n}){return at.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Lo[e]||e==="opacity")}function Ro(e,t,n){const o=e.style,r=t?.style,i={};if(!o)return i;for(const s in o)(ie(o[s])||r&&ie(r[s])||Ds(s,e)||n?.getValue(s)?.liveStyle!==void 0)&&(i[s]=o[s]);return i}function nf(e){return window.getComputedStyle(e)}class of extends ws{constructor(){super(...arguments),this.type="html",this.renderInstance=Vs}readValueFromInstance(t,n){if(at.has(n))return this.projection?.isProjecting?ao(n):Iu(t,n);{const o=nf(t),r=(mi(n)?o.getPropertyValue(n):o[n])||0;return typeof r=="string"?r.trim():r}}measureInstanceViewportBox(t,{transformPagePoint:n}){return Ms(t,n)}build(t,n,o){Io(t,n,o.transformTemplate)}scrapeMotionValuesFromProps(t,n,o){return Ro(t,n,o)}}const rf={offset:"stroke-dashoffset",array:"stroke-dasharray"},sf={offset:"strokeDashoffset",array:"strokeDasharray"};function af(e,t,n=1,o=0,r=!0){e.pathLength=1;const i=r?rf:sf;e[i.offset]=E.transform(-o);const s=E.transform(t),a=E.transform(n);e[i.array]=`${s} ${a}`}const lf=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function Fs(e,{attrX:t,attrY:n,attrScale:o,pathLength:r,pathSpacing:i=1,pathOffset:s=0,...a},l,c,d){if(Io(e,a,c),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:u,style:f}=e;u.transform&&(f.transform=u.transform,delete u.transform),(f.transform||u.transformOrigin)&&(f.transformOrigin=u.transformOrigin??"50% 50%",delete u.transformOrigin),f.transform&&(f.transformBox=d?.transformBox??"fill-box",delete u.transformBox);for(const h of lf)u[h]!==void 0&&(f[h]=u[h],delete u[h]);t!==void 0&&(u.x=t),n!==void 0&&(u.y=n),o!==void 0&&(u.scale=o),r!==void 0&&af(u,r,i,s,!1)}const As=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"]),Is=e=>typeof e=="string"&&e.toLowerCase()==="svg";function cf(e,t,n,o){Vs(e,t,void 0,o);for(const r in t.attrs)e.setAttribute(As.has(r)?r:xo(r),t.attrs[r])}function Ls(e,t,n){const o=Ro(e,t,n);for(const r in e)if(ie(e[r])||ie(t[r])){const i=st.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;o[i]=e[r]}return o}class uf extends ws{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=ee}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(at.has(n)){const o=ts(n);return o&&o.default||0}return n=As.has(n)?n:xo(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,o){return Ls(t,n,o)}build(t,n,o){Fs(t,n,this.isSVGTag,o.transformTemplate,o.style)}renderInstance(t,n,o,r){cf(t,n,o,r)}mount(t){this.isSVGTag=Is(t.tagName),super.mount(t)}}const df=Eo.length;function Rs(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?Rs(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<df;n++){const o=Eo[n],r=e.props[o];(Ft(r)||r===!1)&&(t[o]=r)}return t}function _s(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let o=0;o<n;o++)if(t[o]!==e[o])return!1;return!0}const ff=[...Vo].reverse(),hf=Vo.length;function mf(e){return t=>Promise.all(t.map(({animation:n,options:o})=>Cd(e,n,o)))}function pf(e){let t=mf(e),n=Bs(),o=!0;const r=l=>(c,d)=>{const u=ct(e,d,l==="exit"?e.presenceContext?.custom:void 0);if(u){const{transition:f,transitionEnd:h,...v}=u;c={...c,...v,...h}}return c};function i(l){t=l(e)}function s(l){const{props:c}=e,d=Rs(e.parent)||{},u=[],f=new Set;let h={},v=1/0;for(let b=0;b<hf;b++){const w=ff[b],S=n[w],x=c[w]!==void 0?c[w]:d[w],P=Ft(x),T=w===l?S.isActive:null;T===!1&&(v=b);let k=x===d[w]&&x!==c[w]&&P;if(k&&o&&e.manuallyAnimateOnMount&&(k=!1),S.protectedKeys={...h},!S.isActive&&T===null||!x&&!S.prevProp||en(x)||typeof x=="boolean")continue;const V=gf(S.prevProp,x);let $=V||w===l&&S.isActive&&!k&&P||b>v&&P,A=!1;const I=Array.isArray(x)?x:[x];let N=I.reduce(r(w),{});T===!1&&(N={});const{prevResolvedValues:H={}}=S,M={...H,...N},F=L=>{$=!0,f.has(L)&&(A=!0,f.delete(L)),S.needsAnimating[L]=!0;const j=e.getValue(L);j&&(j.liveStyle=!1)};for(const L in M){const j=N[L],te=H[L];if(h.hasOwnProperty(L))continue;let J=!1;wo(j)&&wo(te)?J=!_s(j,te):J=j!==te,J?j!=null?F(L):f.add(L):j!==void 0&&f.has(L)?F(L):S.protectedKeys[L]=!0}S.prevProp=x,S.prevResolvedValues=N,S.isActive&&(h={...h,...N}),o&&e.blockInitialAnimation&&($=!1);const z=k&&V;$&&(!z||A)&&u.push(...I.map(L=>{const j={type:w};if(typeof L=="string"&&o&&!z&&e.manuallyAnimateOnMount&&e.parent){const{parent:te}=e,J=ct(te,L);if(te.enteringChildren&&J){const{delayChildren:ue}=J.transition||{};j.delay=Gi(te.enteringChildren,e,ue)}}return{animation:L,options:j}}))}if(f.size){const b={};if(typeof c.initial!="boolean"){const w=ct(e,Array.isArray(c.initial)?c.initial[0]:c.initial);w&&w.transition&&(b.transition=w.transition)}f.forEach(w=>{const S=e.getBaseTarget(w),x=e.getValue(w);x&&(x.liveStyle=!0),b[w]=S??null}),u.push({animation:b})}let y=!!u.length;return o&&(c.initial===!1||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(y=!1),o=!1,y?t(u):Promise.resolve()}function a(l,c){if(n[l].isActive===c)return Promise.resolve();e.variantChildren?.forEach(u=>u.animationState?.setActive(l,c)),n[l].isActive=c;const d=s(l);for(const u in n)n[u].protectedKeys={};return d}return{animateChanges:s,setActive:a,setAnimateFunction:i,getState:()=>n,reset:()=>{n=Bs()}}}function gf(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!_s(t,e):!1}function Xe(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Bs(){return{animate:Xe(!0),whileInView:Xe(),whileHover:Xe(),whileTap:Xe(),whileDrag:Xe(),whileFocus:Xe(),exit:Xe()}}const Ns=1e-4,vf=1-Ns,yf=1+Ns,zs=.01,wf=0-zs,bf=0+zs;function ce(e){return e.max-e.min}function xf(e,t,n){return Math.abs(e-t)<=n}function Os(e,t,n,o=.5){e.origin=o,e.originPoint=Y(t.min,t.max,e.origin),e.scale=ce(n)/ce(t),e.translate=Y(n.min,n.max,e.origin)-e.originPoint,(e.scale>=vf&&e.scale<=yf||isNaN(e.scale))&&(e.scale=1),(e.translate>=wf&&e.translate<=bf||isNaN(e.translate))&&(e.translate=0)}function It(e,t,n,o){Os(e.x,t.x,n.x,o?o.originX:void 0),Os(e.y,t.y,n.y,o?o.originY:void 0)}function Hs(e,t,n){e.min=n.min+t.min,e.max=e.min+ce(t)}function Sf(e,t,n){Hs(e.x,t.x,n.x),Hs(e.y,t.y,n.y)}function js(e,t,n){e.min=t.min-n.min,e.max=e.min+ce(t)}function rn(e,t,n){js(e.x,t.x,n.x),js(e.y,t.y,n.y)}function Gs(e,t,n,o,r){return e-=t,e=on(e,1/n,o),r!==void 0&&(e=on(e,1/r,o)),e}function Cf(e,t=0,n=1,o=.5,r,i=e,s=e){if(ke.test(t)&&(t=parseFloat(t),t=Y(s.min,s.max,t/100)-s.min),typeof t!="number")return;let a=Y(i.min,i.max,o);e===i&&(a-=t),e.min=Gs(e.min,t,n,a,r),e.max=Gs(e.max,t,n,a,r)}function Us(e,t,[n,o,r],i,s){Cf(e,t[n],t[o],t[r],t.scale,i,s)}const Tf=["x","scaleX","originX"],$f=["y","scaleY","originY"];function Ws(e,t,n,o){Us(e.x,t,Tf,n?n.x:void 0,o?o.x:void 0),Us(e.y,t,$f,n?n.y:void 0,o?o.y:void 0)}function Ks(e,t){e.min=t.min,e.max=t.max}function xe(e,t){Ks(e.x,t.x),Ks(e.y,t.y)}function qs(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function Ys(e){return e.translate===0&&e.scale===1}function Xs(e){return Ys(e.x)&&Ys(e.y)}function Zs(e,t){return e.min===t.min&&e.max===t.max}function Pf(e,t){return Zs(e.x,t.x)&&Zs(e.y,t.y)}function Js(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Qs(e,t){return Js(e.x,t.x)&&Js(e.y,t.y)}function ea(e){return ce(e.x)/ce(e.y)}function ta(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function ve(e){return[e("x"),e("y")]}function kf(e,t,n){let o="";const r=e.x.translate/t.x,i=e.y.translate/t.y,s=n?.z||0;if((r||i||s)&&(o=`translate3d(${r}px, ${i}px, ${s}px) `),(t.x!==1||t.y!==1)&&(o+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:c,rotate:d,rotateX:u,rotateY:f,skewX:h,skewY:v}=n;c&&(o=`perspective(${c}px) ${o}`),d&&(o+=`rotate(${d}deg) `),u&&(o+=`rotateX(${u}deg) `),f&&(o+=`rotateY(${f}deg) `),h&&(o+=`skewX(${h}deg) `),v&&(o+=`skewY(${v}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return(a!==1||l!==1)&&(o+=`scale(${a}, ${l})`),o||"none"}const na=["TopLeft","TopRight","BottomLeft","BottomRight"],Mf=na.length,oa=e=>typeof e=="string"?parseFloat(e):e,ra=e=>typeof e=="number"||E.test(e);function Vf(e,t,n,o,r,i){r?(e.opacity=Y(0,n.opacity??1,Ef(o)),e.opacityExit=Y(t.opacity??1,0,Df(o))):i&&(e.opacity=Y(t.opacity??1,n.opacity??1,o));for(let s=0;s<Mf;s++){const a=`border${na[s]}Radius`;let l=ia(t,a),c=ia(n,a);if(l===void 0&&c===void 0)continue;l||(l=0),c||(c=0),l===0||c===0||ra(l)===ra(c)?(e[a]=Math.max(Y(oa(l),oa(c),o),0),(ke.test(c)||ke.test(l))&&(e[a]+="%")):e[a]=c}(t.rotate||n.rotate)&&(e.rotate=Y(t.rotate||0,n.rotate||0,o))}function ia(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const Ef=sa(0,.5,si),Df=sa(.5,.95,pe);function sa(e,t,n){return o=>o<e?0:o>t?1:n($t(e,t,o))}function Ff(e,t){const n=le.now(),o=({timestamp:r})=>{const i=r-n;i>=t&&(Le(o),e(i-t))};return W.setup(o,!0),()=>Le(o)}function Lt(e,t,n,o={passive:!0}){return e.addEventListener(t,n,o),()=>e.removeEventListener(t,n)}function sn(e){return ie(e)?e.get():e}function Af(e,t,n){const o=ie(e)?e:lt(e);return o.start(vo("",o,t,n)),o.animation}const If=(e,t)=>e.depth-t.depth;class Lf{constructor(){this.children=[],this.isDirty=!1}add(t){In(this.children,t),this.isDirty=!0}remove(t){Ln(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(If),this.isDirty=!1,this.children.forEach(t)}}class Rf{constructor(){this.members=[]}add(t){In(this.members,t),t.scheduleRender()}remove(t){if(Ln(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(r=>t===r);if(n===0)return!1;let o;for(let r=n;r>=0;r--){const i=this.members[r];if(i.isPresent!==!1){o=i;break}}return o?(this.promote(o),!0):!1}promote(t,n){const o=this.lead;if(t!==o&&(this.prevLead=o,this.lead=t,t.show(),o)){o.instance&&o.scheduleRender(),t.scheduleRender(),t.resumeFrom=o,n&&(t.resumeFrom.preserveOpacity=!0),o.snapshot&&(t.snapshot=o.snapshot,t.snapshot.latestValues=o.animationValues||o.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:r}=t.options;r===!1&&o.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:o}=t;n.onExitComplete&&n.onExitComplete(),o&&o.options.onExitComplete&&o.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const an={hasAnimatedSinceResize:!0,hasEverUpdated:!1},_o=["","X","Y","Z"],_f=1e3;let Bf=0;function Bo(e,t,n,o){const{latestValues:r}=t;r[e]&&(n[e]=r[e],t.setStaticValue(e,0),o&&(o[e]=0))}function aa(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=Yi(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:r,layoutId:i}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",W,!(r||i))}const{parent:o}=e;o&&!o.hasCheckedOptimisedAppear&&aa(o)}function la({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:o,resetTransform:r}){return class{constructor(s={},a=t?.()){this.id=Bf++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(Of),this.nodes.forEach(Uf),this.nodes.forEach(Wf),this.nodes.forEach(Hf)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new Lf)}addEventListener(s,a){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new Bn),this.eventHandlers.get(s).add(a)}notifyListeners(s,...a){const l=this.eventHandlers.get(s);l&&l.notify(...a)}hasListeners(s){return this.eventHandlers.has(s)}mount(s){if(this.instance)return;this.isSVG=fs(s)&&!Nd(s),this.instance=s;const{layoutId:a,layout:l,visualElement:c}=this.options;if(c&&!c.current&&c.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(l||a)&&(this.isLayoutDirty=!0),e){let d,u=0;const f=()=>this.root.updateBlockedByResize=!1;W.read(()=>{u=window.innerWidth}),e(s,()=>{const h=window.innerWidth;h!==u&&(u=h,this.root.updateBlockedByResize=!0,d&&d(),d=Ff(f,250),an.hasAnimatedSinceResize&&(an.hasAnimatedSinceResize=!1,this.nodes.forEach(da)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&c&&(a||l)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:u,hasRelativeLayoutChanged:f,layout:h})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const v=this.options.transition||c.getDefaultTransition()||Zf,{onLayoutAnimationStart:y,onLayoutAnimationComplete:b}=c.getProps(),w=!this.targetLayout||!Qs(this.targetLayout,h),S=!u&&f;if(this.options.layoutRoot||this.resumeFrom||S||u&&(w||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const x={...go(v,"layout"),onPlay:y,onComplete:b};(c.shouldReduceMotion||this.options.layoutRoot)&&(x.delay=0,x.type=!1),this.startAnimation(x),this.setAnimationOrigin(d,S)}else u||da(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=h})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Le(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(Kf),this.animationId++)}getTransformTemplate(){const{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&aa(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d<this.path.length;d++){const u=this.path[d];u.shouldResetTransform=!0,u.updateScroll("snapshot"),u.options.layoutRoot&&u.willUpdate(!1)}const{layoutId:a,layout:l}=this.options;if(a===void 0&&!l)return;const c=this.getTransformTemplate();this.prevTransformTemplateValue=c?c(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(ca);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(ua);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(Gf),this.nodes.forEach(Nf),this.nodes.forEach(zf)):this.nodes.forEach(ua),this.clearAllSnapshots();const a=le.now();oe.delta=$e(0,1e3/60,a-oe.timestamp),oe.timestamp=a,oe.isProcessing=!0,Hn.update.process(oe),Hn.preRender.process(oe),Hn.render.process(oe),oe.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,$o.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(jf),this.sharedNodes.forEach(qf)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,W.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){W.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!ce(this.snapshot.measuredBox.x)&&!ce(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();const s=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=ee(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(a=!1),a&&this.instance){const l=o(this.instance);this.scroll={animationId:this.root.animationId,phase:s,isRoot:l,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!r)return;const s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!Xs(this.projectionDelta),l=this.getTransformTemplate(),c=l?l(this.latestValues,""):void 0,d=c!==this.prevTransformTemplateValue;s&&this.instance&&(a||Ye(this.latestValues)||d)&&(r(this.instance,c),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){const a=this.measurePageBox();let l=this.removeElementScroll(a);return s&&(l=this.removeTransform(l)),Jf(l),{animationId:this.root.animationId,measuredBox:a,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:s}=this.options;if(!s)return ee();const a=s.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(Qf))){const{scroll:c}=this.root;c&&(dt(a.x,c.offset.x),dt(a.y,c.offset.y))}return a}removeElementScroll(s){const a=ee();if(xe(a,s),this.scroll?.wasRoot)return a;for(let l=0;l<this.path.length;l++){const c=this.path[l],{scroll:d,options:u}=c;c!==this.root&&d&&u.layoutScroll&&(d.wasRoot&&xe(a,s),dt(a.x,d.offset.x),dt(a.y,d.offset.y))}return a}applyTransform(s,a=!1){const l=ee();xe(l,s);for(let c=0;c<this.path.length;c++){const d=this.path[c];!a&&d.options.layoutScroll&&d.scroll&&d!==d.root&&ft(l,{x:-d.scroll.offset.x,y:-d.scroll.offset.y}),Ye(d.latestValues)&&ft(l,d.latestValues)}return Ye(this.latestValues)&&ft(l,this.latestValues),l}removeTransform(s){const a=ee();xe(a,s);for(let l=0;l<this.path.length;l++){const c=this.path[l];if(!c.instance||!Ye(c.latestValues))continue;Fo(c.latestValues)&&c.updateSnapshot();const d=ee(),u=c.measurePageBox();xe(d,u),Ws(a,c.latestValues,c.snapshot?c.snapshot.layoutBox:void 0,d)}return Ye(this.latestValues)&&Ws(a,this.latestValues),a}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==oe.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const l=!!this.resumingFrom||this!==a;if(!(s||l&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:d,layoutId:u}=this.options;if(!this.layout||!(d||u))return;this.resolvedRelativeTargetAt=oe.timestamp;const f=this.getClosestProjectingParent();f&&this.linkedParentVersion!==f.layoutVersion&&!f.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(f&&f.layout?this.createRelativeTarget(f,this.layout.layoutBox,f.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=ee(),this.targetWithTransforms=ee()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),Sf(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):xe(this.target,this.layout.layoutBox),Ts(this.target,this.targetDelta)):xe(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,f&&!!f.resumingFrom==!!this.resumingFrom&&!f.options.layoutScroll&&f.target&&this.animationProgress!==1?this.createRelativeTarget(f,this.target,f.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||Fo(this.parent.latestValues)||xs(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(s,a,l){this.relativeParent=s,this.linkedParentVersion=s.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=ee(),this.relativeTargetOrigin=ee(),rn(this.relativeTargetOrigin,a,l),xe(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){const s=this.getLead(),a=!!this.resumingFrom||this!==s;let l=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(l=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===oe.timestamp&&(l=!1),l)return;const{layout:c,layoutId:d}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(c||d))return;xe(this.layoutCorrected,this.layout.layoutBox);const u=this.treeScale.x,f=this.treeScale.y;Xd(this.layoutCorrected,this.treeScale,this.path,a),s.layout&&!s.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(s.target=s.layout.layoutBox,s.targetWithTransforms=ee());const{target:h}=s;if(!h){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(qs(this.prevProjectionDelta.x,this.projectionDelta.x),qs(this.prevProjectionDelta.y,this.projectionDelta.y)),It(this.projectionDelta,this.layoutCorrected,h,this.latestValues),(this.treeScale.x!==u||this.treeScale.y!==f||!ta(this.projectionDelta.x,this.prevProjectionDelta.x)||!ta(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",h))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){if(this.options.visualElement?.scheduleRender(),s){const a=this.getStack();a&&a.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=ut(),this.projectionDelta=ut(),this.projectionDeltaWithTransform=ut()}setAnimationOrigin(s,a=!1){const l=this.snapshot,c=l?l.latestValues:{},d={...this.latestValues},u=ut();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const f=ee(),h=l?l.source:void 0,v=this.layout?this.layout.source:void 0,y=h!==v,b=this.getStack(),w=!b||b.members.length<=1,S=!!(y&&!w&&this.options.crossfade===!0&&!this.path.some(Xf));this.animationProgress=0;let x;this.mixTargetDelta=P=>{const T=P/1e3;fa(u.x,s.x,T),fa(u.y,s.y,T),this.setTargetDelta(u),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(rn(f,this.layout.layoutBox,this.relativeParent.layout.layoutBox),Yf(this.relativeTarget,this.relativeTargetOrigin,f,T),x&&Pf(this.relativeTarget,x)&&(this.isProjectionDirty=!1),x||(x=ee()),xe(x,this.relativeTarget)),y&&(this.animationValues=d,Vf(d,c,this.latestValues,T,S,w)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=T},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(Le(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=W.update(()=>{an.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=lt(0)),this.currentAnimation=Af(this.motionValue,[0,1e3],{...s,velocity:0,isSync:!0,onUpdate:a=>{this.mixTargetDelta(a),s.onUpdate&&s.onUpdate(a)},onStop:()=>{},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(_f),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:a,target:l,layout:c,latestValues:d}=s;if(!(!a||!l||!c)){if(this!==s&&this.layout&&c&&va(this.options.animationType,this.layout.layoutBox,c.layoutBox)){l=this.target||ee();const u=ce(this.layout.layoutBox.x);l.x.min=s.target.x.min,l.x.max=l.x.min+u;const f=ce(this.layout.layoutBox.y);l.y.min=s.target.y.min,l.y.max=l.y.min+f}xe(a,l),ft(a,d),It(this.projectionDeltaWithTransform,this.layoutCorrected,a,d)}}registerSharedNode(s,a){this.sharedNodes.has(s)||this.sharedNodes.set(s,new Rf),this.sharedNodes.get(s).add(a);const c=a.options.initialPromotionConfig;a.promote({transition:c?c.transition:void 0,preserveFollowOpacity:c&&c.shouldPreserveFollowOpacity?c.shouldPreserveFollowOpacity(a):void 0})}isLead(){const s=this.getStack();return s?s.lead===this:!0}getLead(){const{layoutId:s}=this.options;return s?this.getStack()?.lead||this:this}getPrevLead(){const{layoutId:s}=this.options;return s?this.getStack()?.prevLead:void 0}getStack(){const{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:a,preserveFollowOpacity:l}={}){const c=this.getStack();c&&c.promote(this,l),s&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){const{visualElement:s}=this.options;if(!s)return;let a=!1;const{latestValues:l}=s;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const c={};l.z&&Bo("z",s,c,this.animationValues);for(let d=0;d<_o.length;d++)Bo(`rotate${_o[d]}`,s,c,this.animationValues),Bo(`skew${_o[d]}`,s,c,this.animationValues);s.render();for(const d in c)s.setStaticValue(d,c[d]),this.animationValues&&(this.animationValues[d]=c[d]);s.scheduleRender()}applyProjectionStyles(s,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){s.visibility="hidden";return}const l=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,s.visibility="",s.opacity="",s.pointerEvents=sn(a?.pointerEvents)||"",s.transform=l?l(this.latestValues,""):"none";return}const c=this.getLead();if(!this.projectionDelta||!this.layout||!c.target){this.options.layoutId&&(s.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,s.pointerEvents=sn(a?.pointerEvents)||""),this.hasProjected&&!Ye(this.latestValues)&&(s.transform=l?l({},""):"none",this.hasProjected=!1);return}s.visibility="";const d=c.animationValues||c.latestValues;this.applyTransformsToTarget();let u=kf(this.projectionDeltaWithTransform,this.treeScale,d);l&&(u=l(d,u)),s.transform=u;const{x:f,y:h}=this.projectionDelta;s.transformOrigin=`${f.origin*100}% ${h.origin*100}% 0`,c.animationValues?s.opacity=c===this?d.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:d.opacityExit:s.opacity=c===this?d.opacity!==void 0?d.opacity:"":d.opacityExit!==void 0?d.opacityExit:0;for(const v in Lo){if(d[v]===void 0)continue;const{correct:y,applyTo:b,isCSSVariable:w}=Lo[v],S=u==="none"?d[v]:y(d[v],c);if(b){const x=b.length;for(let P=0;P<x;P++)s[b[P]]=S}else w?this.options.visualElement.renderState.vars[v]=S:s[v]=S}this.options.layoutId&&(s.pointerEvents=c===this?sn(a?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>s.currentAnimation?.stop()),this.root.nodes.forEach(ca),this.root.sharedNodes.clear()}}}function Nf(e){e.updateLayout()}function zf(e){const t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:n,measuredBox:o}=e.layout,{animationType:r}=e.options,i=t.source!==e.layout.source;r==="size"?ve(d=>{const u=i?t.measuredBox[d]:t.layoutBox[d],f=ce(u);u.min=n[d].min,u.max=u.min+f}):va(r,t.layoutBox,n)&&ve(d=>{const u=i?t.measuredBox[d]:t.layoutBox[d],f=ce(n[d]);u.max=u.min+f,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+f)});const s=ut();It(s,n,t.layoutBox);const a=ut();i?It(a,e.applyTransform(o,!0),t.measuredBox):It(a,n,t.layoutBox);const l=!Xs(s);let c=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:u,layout:f}=d;if(u&&f){const h=ee();rn(h,t.layoutBox,u.layoutBox);const v=ee();rn(v,n,f.layoutBox),Qs(h,v)||(c=!0),d.options.layoutRoot&&(e.relativeTarget=v,e.relativeTargetOrigin=h,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:n,snapshot:t,delta:a,layoutDelta:s,hasLayoutChanged:l,hasRelativeLayoutChanged:c})}else if(e.isLead()){const{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function Of(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function Hf(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function jf(e){e.clearSnapshot()}function ca(e){e.clearMeasurements()}function ua(e){e.isLayoutDirty=!1}function Gf(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function da(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Uf(e){e.resolveTargetDelta()}function Wf(e){e.calcProjection()}function Kf(e){e.resetSkewAndRotation()}function qf(e){e.removeLeadSnapshot()}function fa(e,t,n){e.translate=Y(t.translate,0,n),e.scale=Y(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function ha(e,t,n,o){e.min=Y(t.min,n.min,o),e.max=Y(t.max,n.max,o)}function Yf(e,t,n,o){ha(e.x,t.x,n.x,o),ha(e.y,t.y,n.y,o)}function Xf(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const Zf={duration:.45,ease:[.4,0,.1,1]},ma=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),pa=ma("applewebkit/")&&!ma("chrome/")?Math.round:pe;function ga(e){e.min=pa(e.min),e.max=pa(e.max)}function Jf(e){ga(e.x),ga(e.y)}function va(e,t,n){return e==="position"||e==="preserve-aspect"&&!xf(ea(t),ea(n),.2)}function Qf(e){return e!==e.root&&e.scroll?.wasRoot}const eh=la({attachResizeListener:(e,t)=>Lt(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),No={current:void 0},ya=la({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!No.current){const e=new eh({});e.mount(window),e.setOptions({layoutScroll:!0}),No.current=e}return No.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),zo=m.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function wa(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function th(...e){return t=>{let n=!1;const o=e.map(r=>{const i=wa(r,t);return!n&&typeof i=="function"&&(n=!0),i});if(n)return()=>{for(let r=0;r<o.length;r++){const i=o[r];typeof i=="function"?i():wa(e[r],null)}}}}function nh(...e){return Ue.useCallback(th(...e),e)}class oh extends Ue.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const o=n.offsetParent,r=rs(o)&&o.offsetWidth||0,i=this.props.sizeRef.current;i.height=n.offsetHeight||0,i.width=n.offsetWidth||0,i.top=n.offsetTop,i.left=n.offsetLeft,i.right=r-i.width-i.left}return null}componentDidUpdate(){}render(){return this.props.children}}function rh({children:e,isPresent:t,anchorX:n,root:o}){const r=m.useId(),i=m.useRef(null),s=m.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:a}=m.useContext(zo),l=e.props?.ref??e?.ref,c=nh(i,l);return m.useInsertionEffect(()=>{const{width:d,height:u,top:f,left:h,right:v}=s.current;if(t||!i.current||!d||!u)return;const y=n==="left"?`left: ${h}`:`right: ${v}`;i.current.dataset.motionPopId=r;const b=document.createElement("style");a&&(b.nonce=a);const w=o??document.head;return w.appendChild(b),b.sheet&&b.sheet.insertRule(`
168
168
  [data-motion-pop-id="${r}"] {
169
169
  position: absolute !important;
170
170
  width: ${d}px !important;
171
171
  height: ${u}px !important;
172
172
  ${y}px !important;
173
- top: ${h}px !important;
173
+ top: ${f}px !important;
174
174
  }
175
- `),()=>{w.contains(b)&&w.removeChild(b)}},[t]),p.jsx(nh,{isPresent:t,childRef:i,sizeRef:s,children:Ue.cloneElement(e,{ref:c})})}const rh=({children:e,initial:t,isPresent:n,onExitComplete:o,custom:r,presenceAffectsLayout:i,mode:s,anchorX:a,root:l})=>{const c=Fn(ih),d=m.useId();let u=!0,h=m.useMemo(()=>(u=!1,{id:d,initial:t,isPresent:n,custom:r,onExitComplete:f=>{c.set(f,!0);for(const v of c.values())if(!v)return;o&&o()},register:f=>(c.set(f,!1),()=>c.delete(f))}),[n,c,o]);return i&&u&&(h={...h}),m.useMemo(()=>{c.forEach((f,v)=>c.set(v,!1))},[n]),Ue.useEffect(()=>{!n&&!c.size&&o&&o()},[n]),s==="popLayout"&&(e=p.jsx(oh,{isPresent:n,anchorX:a,root:l,children:e})),p.jsx(Ut.Provider,{value:h,children:e})};function ih(){return new Map}function ya(e=!0){const t=m.useContext(Ut);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:o,register:r}=t,i=m.useId();m.useEffect(()=>{if(e)return r(i)},[e]);const s=m.useCallback(()=>e&&o&&o(i),[i,o,e]);return!n&&o?[!1,s]:[!0]}const an=e=>e.key||"";function wa(e){const t=[];return m.Children.forEach(e,n=>{m.isValidElement(n)&&t.push(n)}),t}const Lt=({children:e,custom:t,initial:n=!0,onExitComplete:o,presenceAffectsLayout:r=!0,mode:i="sync",propagate:s=!1,anchorX:a="left",root:l})=>{const[c,d]=ya(s),u=m.useMemo(()=>wa(e),[e]),h=s&&!c?[]:u.map(an),f=m.useRef(!0),v=m.useRef(u),y=Fn(()=>new Map),b=m.useRef(new Set),[w,C]=m.useState(u),[x,P]=m.useState(u);Kr(()=>{f.current=!1,v.current=u;for(let V=0;V<x.length;V++){const $=an(x[V]);h.includes($)?(y.delete($),b.current.delete($)):y.get($)!==!0&&y.set($,!1)}},[x,h.length,h.join("-")]);const T=[];if(u!==w){let V=[...u];for(let $=0;$<x.length;$++){const A=x[$],I=an(A);h.includes(I)||(V.splice($,0,A),T.push(A))}return i==="wait"&&T.length&&(V=T),P(wa(V)),C(u),null}process.env.NODE_ENV!=="production"&&i==="wait"&&x.length>1&&console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to "wait". This will lead to odd visual behaviour.`);const{forceRender:k}=m.useContext(Dn);return p.jsx(p.Fragment,{children:x.map(V=>{const $=an(V),A=s&&!c?!1:u===x||h.includes($),I=()=>{if(b.current.has($))return;if(b.current.add($),y.has($))y.set($,!0);else return;let B=!0;y.forEach(H=>{H||(B=!1)}),B&&(k?.(),P(v.current),s&&d?.(),o&&o())};return p.jsx(rh,{isPresent:A,initial:!f.current||n?void 0:!1,custom:t,presenceAffectsLayout:r,mode:i,root:l,onExitComplete:A?void 0:I,anchorX:a,children:V},$)})})},ba=m.createContext({strict:!1}),xa={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let Sa=!1;function sh(){if(Sa)return;const e={};for(const t in xa)e[t]={isEnabled:n=>xa[t].some(o=>!!n[o])};gs(e),Sa=!0}function Ca(){return sh(),Ud()}function ah(e){const t=Ca();for(const n in e)t[n]={...t[n],...e[n]};gs(t)}const lh=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","ignoreStrict","viewport"]);function ln(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||lh.has(e)}let Ta=e=>!ln(e);function ch(e){typeof e=="function"&&(Ta=t=>t.startsWith("on")?!ln(t):e(t))}try{ch(require("@emotion/is-prop-valid").default)}catch{}function uh(e,t,n){const o={};for(const r in e)r==="values"&&typeof e.values=="object"||(Ta(r)||n===!0&&ln(r)||!t&&!ln(r)||e.draggable&&r.startsWith("onDrag"))&&(o[r]=e[r]);return o}const cn=m.createContext({});function dh(e,t){if(en(e)){const{initial:n,animate:o}=e;return{initial:n===!1||Dt(n)?n:void 0,animate:Dt(o)?o:void 0}}return e.inherit!==!1?t:{}}function fh(e){const{initial:t,animate:n}=dh(e,m.useContext(cn));return m.useMemo(()=>({initial:t,animate:n}),[$a(t),$a(n)])}function $a(e){return Array.isArray(e)?e.join(" "):e}const zo=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Pa(e,t,n){for(const o in t)!ie(t[o])&&!Vs(o,n)&&(e[o]=t[o])}function hh({transformTemplate:e},t){return m.useMemo(()=>{const n=zo();return Ao(n,t,e),Object.assign({},n.vars,n.style)},[t])}function mh(e,t){const n=e.style||{},o={};return Pa(o,n,e),Object.assign(o,hh(e,t)),o}function ph(e,t){const n={},o=mh(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.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=o,n}const ka=()=>({...zo(),attrs:{}});function gh(e,t,n,o){const r=m.useMemo(()=>{const i=ka();return Es(i,t,Fs(o),e.transformTemplate,e.style),{...i.attrs,style:{...i.style}}},[t]);if(e.style){const i={};Pa(i,e.style,e),r.style={...i,...r.style}}return r}const vh=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Oo(e){return typeof e!="string"||e.includes("-")?!1:!!(vh.indexOf(e)>-1||/[A-Z]/u.test(e))}function yh(e,t,n,{latestValues:o},r,i=!1,s){const l=(s??Oo(e)?gh:ph)(t,o,r,e),c=uh(t,typeof e=="string",i),d=e!==m.Fragment?{...c,...l,ref:n}:{},{children:u}=t,h=m.useMemo(()=>ie(u)?u.get():u,[u]);return m.createElement(e,{...d,children:h})}function wh({scrapeMotionValuesFromProps:e,createRenderState:t},n,o,r){return{latestValues:bh(n,o,r,e),renderState:t()}}function bh(e,t,n,o){const r={},i=o(e,{});for(const h in i)r[h]=rn(i[h]);let{initial:s,animate:a}=e;const l=en(e),c=ms(e);t&&c&&!l&&e.inherit!==!1&&(s===void 0&&(s=t.initial),a===void 0&&(a=t.animate));let d=n?n.initial===!1:!1;d=d||s===!1;const u=d?a:s;if(u&&typeof u!="boolean"&&!Qt(u)){const h=Array.isArray(u)?u:[u];for(let f=0;f<h.length;f++){const v=vo(e,h[f]);if(v){const{transitionEnd:y,transition:b,...w}=v;for(const C in w){let x=w[C];if(Array.isArray(x)){const P=d?x.length-1:0;x=x[P]}x!==null&&(r[C]=x)}for(const C in y)r[C]=y[C]}}}return r}const Ma=e=>(t,n)=>{const o=m.useContext(cn),r=m.useContext(Ut),i=()=>wh(e,t,o,r);return n?i():Fn(i)},xh=Ma({scrapeMotionValuesFromProps:Lo,createRenderState:zo}),Sh=Ma({scrapeMotionValuesFromProps:As,createRenderState:ka}),Ch=Symbol.for("motionComponentSymbol");function Th(e,t,n){const o=m.useRef(n);m.useInsertionEffect(()=>{o.current=n});const r=m.useRef(null);return m.useCallback(i=>{i&&e.onMount?.(i),t&&(i?t.mount(i):t.unmount());const s=o.current;if(typeof s=="function")if(i){const a=s(i);typeof a=="function"&&(r.current=a)}else r.current?(r.current(),r.current=null):s(i);else s&&(s.current=i)},[t])}const Va=m.createContext({});function Rt(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function $h(e,t,n,o,r,i){const{visualElement:s}=m.useContext(cn),a=m.useContext(ba),l=m.useContext(Ut),c=m.useContext(Bo).reducedMotion,d=m.useRef(null);o=o||a.renderer,!d.current&&o&&(d.current=o(e,{visualState:t,parent:s,props:n,presenceContext:l,blockInitialAnimation:l?l.initial===!1:!1,reducedMotionConfig:c,isSVG:i}));const u=d.current,h=m.useContext(Va);u&&!u.projection&&r&&(u.type==="html"||u.type==="svg")&&Ph(d.current,n,r,h);const f=m.useRef(!1);m.useInsertionEffect(()=>{u&&f.current&&u.update(n,l)});const v=n[Ki],y=m.useRef(!!v&&!window.MotionHandoffIsComplete?.(v)&&window.MotionHasOptimisedAnimation?.(v));return Kr(()=>{u&&(f.current=!0,window.MotionIsMounted=!0,u.updateFeatures(),u.scheduleRenderMicrotask(),y.current&&u.animationState&&u.animationState.animateChanges())}),m.useEffect(()=>{u&&(!y.current&&u.animationState&&u.animationState.animateChanges(),y.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(v)}),y.current=!1),u.enteringChildren=void 0)}),u}function Ph(e,t,n,o){const{layoutId:r,layout:i,drag:s,dragConstraints:a,layoutScroll:l,layoutRoot:c,layoutCrossfade:d}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:Ea(e.parent)),e.projection.setOptions({layoutId:r,layout:i,alwaysMeasureLayout:!!s||a&&Rt(a),visualElement:e,animationType:typeof i=="string"?i:"both",initialPromotionConfig:o,crossfade:d,layoutScroll:l,layoutRoot:c})}function Ea(e){if(e)return e.options.allowProjection!==!1?e.projection:Ea(e.parent)}function Ho(e,{forwardMotionProps:t=!1,type:n}={},o,r){o&&ah(o);const i=n?n==="svg":Oo(e),s=i?Sh:xh;function a(c,d){let u;const h={...m.useContext(Bo),...c,layoutId:kh(c)},{isStatic:f}=h,v=fh(c),y=s(c,f);if(!f&&Ur){Mh(h,o);const b=Vh(h);u=b.MeasureLayout,v.visualElement=$h(e,y,h,r,b.ProjectionNode,i)}return p.jsxs(cn.Provider,{value:v,children:[u&&v.visualElement?p.jsx(u,{visualElement:v.visualElement,...h}):null,yh(e,c,Th(y,v.visualElement,d),y,f,t,i)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const l=m.forwardRef(a);return l[Ch]=e,l}function kh({layoutId:e}){const t=m.useContext(Dn).id;return t&&e!==void 0?t+"-"+e:e}function Mh(e,t){const n=m.useContext(ba).strict;if(process.env.NODE_ENV!=="production"&&t&&n){const o="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";e.ignoreStrict?tt(!1,o,"lazy-strict-mode"):Ve(!1,o,"lazy-strict-mode")}}function Vh(e){const t=Ca(),{drag:n,layout:o}=t;if(!n&&!o)return{};const r={...n,...o};return{MeasureLayout:n?.isEnabled(e)||o?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function Eh(e,t){if(typeof Proxy>"u")return Ho;const n=new Map,o=(i,s)=>Ho(i,s,e,t),r=(i,s)=>(process.env.NODE_ENV!=="production"&&Nn(!1,"motion() is deprecated. Use motion.create() instead."),o(i,s));return new Proxy(r,{get:(i,s)=>s==="create"?o:(n.has(s)||n.set(s,Ho(s,void 0,e,t)),n.get(s))})}const Dh=(e,t)=>t.isSVG??Oo(e)?new cf(t):new nf(t,{allowProjection:e!==m.Fragment});class Fh extends Be{constructor(t){super(t),t.animationState||(t.animationState=mf(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();Qt(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}}let Ah=0;class Ih extends Be{constructor(){super(...arguments),this.id=Ah++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:o}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===o)return;const r=this.node.animationState.setActive("exit",!t);n&&!t&&r.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const Lh={animation:{Feature:Fh},exit:{Feature:Ih}};function _t(e){return{point:{x:e.pageX,y:e.pageY}}}const Rh=e=>t=>$o(t)&&e(t,_t(t));function Nt(e,t,n,o){return It(e,t,Rh(n),o)}const Da=({current:e})=>e?e.ownerDocument.defaultView:null,Fa=(e,t)=>Math.abs(e-t);function _h(e,t){const n=Fa(e.x,t.x),o=Fa(e.y,t.y);return Math.sqrt(n**2+o**2)}const Aa=new Set(["auto","scroll"]);class Ia{constructor(t,n,{transformPagePoint:o,contextWindow:r=window,dragSnapToOrigin:i=!1,distanceThreshold:s=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=f=>{this.handleScroll(f.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const f=Go(this.lastMoveEventInfo,this.history),v=this.startEvent!==null,y=_h(f.offset,{x:0,y:0})>=this.distanceThreshold;if(!v&&!y)return;const{point:b}=f,{timestamp:w}=oe;this.history.push({...b,timestamp:w});const{onStart:C,onMove:x}=this.handlers;v||(C&&C(this.lastMoveEvent,f),this.startEvent=this.lastMoveEvent),x&&x(this.lastMoveEvent,f)},this.handlePointerMove=(f,v)=>{this.lastMoveEvent=f,this.lastMoveEventInfo=jo(v,this.transformPagePoint),K.update(this.updatePoint,!0)},this.handlePointerUp=(f,v)=>{this.end();const{onEnd:y,onSessionEnd:b,resumeAnimation:w}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&w&&w(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const C=Go(f.type==="pointercancel"?this.lastMoveEventInfo:jo(v,this.transformPagePoint),this.history);this.startEvent&&y&&y(f,C),b&&b(f,C)},!$o(t))return;this.dragSnapToOrigin=i,this.handlers=n,this.transformPagePoint=o,this.distanceThreshold=s,this.contextWindow=r||window;const l=_t(t),c=jo(l,this.transformPagePoint),{point:d}=c,{timestamp:u}=oe;this.history=[{...d,timestamp:u}];const{onSessionStart:h}=n;h&&h(t,Go(c,this.history)),this.removeListeners=Ct(Nt(this.contextWindow,"pointermove",this.handlePointerMove),Nt(this.contextWindow,"pointerup",this.handlePointerUp),Nt(this.contextWindow,"pointercancel",this.handlePointerUp)),a&&this.startScrollTracking(a)}startScrollTracking(t){let n=t.parentElement;for(;n;){const o=getComputedStyle(n);(Aa.has(o.overflowX)||Aa.has(o.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0,passive:!0}),window.addEventListener("scroll",this.onWindowScroll,{passive:!0}),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const o=t===window,r=o?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},i={x:r.x-n.x,y:r.y-n.y};i.x===0&&i.y===0||(o?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(t,r),K.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Le(this.updatePoint)}}function jo(e,t){return t?{point:t(e.point)}:e}function La(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Go({point:e},t){return{point:e,delta:La(e,Ra(t)),offset:La(e,Nh(t)),velocity:Bh(t,.1)}}function Nh(e){return e[0]}function Ra(e){return e[e.length-1]}function Bh(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,o=null;const r=Ra(e);for(;n>=0&&(o=e[n],!(r.timestamp-o.timestamp>Pe(t)));)n--;if(!o)return{x:0,y:0};const i=ge(r.timestamp-o.timestamp);if(i===0)return{x:0,y:0};const s={x:(r.x-o.x)/i,y:(r.y-o.y)/i};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function zh(e,{min:t,max:n},o){return t!==void 0&&e<t?e=o?Y(t,e,o.min):Math.max(e,t):n!==void 0&&e>n&&(e=o?Y(n,e,o.max):Math.min(e,n)),e}function _a(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function Oh(e,{top:t,left:n,bottom:o,right:r}){return{x:_a(e.x,n,r),y:_a(e.y,t,o)}}function Na(e,t){let n=t.min-e.min,o=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,o]=[o,n]),{min:n,max:o}}function Hh(e,t){return{x:Na(e.x,t.x),y:Na(e.y,t.y)}}function jh(e,t){let n=.5;const o=ce(e),r=ce(t);return r>o?n=Tt(t.min,t.max-o,e.min):o>r&&(n=Tt(e.min,e.max-r,t.min)),$e(0,1,n)}function Gh(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Uo=.35;function Uh(e=Uo){return e===!1?e=0:e===!0&&(e=Uo),{x:Ba(e,"left","right"),y:Ba(e,"top","bottom")}}function Ba(e,t,n){return{min:za(e,t),max:za(e,n)}}function za(e,t){return typeof e=="number"?e:e[t]||0}const Kh=new WeakMap;class Wh{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=ee(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:o}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const i=u=>{n?(this.stopAnimation(),this.snapToCursor(_t(u).point)):this.pauseAnimation()},s=(u,h)=>{this.stopAnimation();const{drag:f,dragPropagation:v,onDragStart:y}=this.getProps();if(f&&!v&&(this.openDragLock&&this.openDragLock(),this.openDragLock=Ad(f),!this.openDragLock))return;this.latestPointerEvent=u,this.latestPanInfo=h,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),ve(w=>{let C=this.getAxisMotionValue(w).get()||0;if(ke.test(C)){const{projection:x}=this.visualElement;if(x&&x.layout){const P=x.layout.layoutBox[w];P&&(C=ce(P)*(parseFloat(C)/100))}}this.originPoint[w]=C}),y&&K.postRender(()=>y(u,h)),wo(this.visualElement,"transform");const{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},a=(u,h)=>{this.latestPointerEvent=u,this.latestPanInfo=h;const{dragPropagation:f,dragDirectionLock:v,onDirectionLock:y,onDrag:b}=this.getProps();if(!f&&!this.openDragLock)return;const{offset:w}=h;if(v&&this.currentDirection===null){this.currentDirection=qh(w),this.currentDirection!==null&&y&&y(this.currentDirection);return}this.updateAxis("x",h.point,w),this.updateAxis("y",h.point,w),this.visualElement.render(),b&&b(u,h)},l=(u,h)=>{this.latestPointerEvent=u,this.latestPanInfo=h,this.stop(u,h),this.latestPointerEvent=null,this.latestPanInfo=null},c=()=>ve(u=>this.getAnimationState(u)==="paused"&&this.getAxisMotionValue(u).animation?.play()),{dragSnapToOrigin:d}=this.getProps();this.panSession=new Ia(t,{onSessionStart:i,onStart:s,onMove:a,onSessionEnd:l,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:d,distanceThreshold:o,contextWindow:Da(this.visualElement),element:this.visualElement.current})}stop(t,n){const o=t||this.latestPointerEvent,r=n||this.latestPanInfo,i=this.isDragging;if(this.cancel(),!i||!r||!o)return;const{velocity:s}=r;this.startAnimation(s);const{onDragEnd:a}=this.getProps();a&&K.postRender(()=>a(o,r))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:o}=this.getProps();!o&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,o){const{drag:r}=this.getProps();if(!o||!un(t,r,this.currentDirection))return;const i=this.getAxisMotionValue(t);let s=this.originPoint[t]+o[t];this.constraints&&this.constraints[t]&&(s=zh(s,this.constraints[t],this.elastic[t])),i.set(s)}resolveConstraints(){const{dragConstraints:t,dragElastic:n}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,r=this.constraints;t&&Rt(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&o?this.constraints=Oh(o.layoutBox,t):this.constraints=!1,this.elastic=Uh(n),r!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&ve(i=>{this.constraints!==!1&&this.getAxisMotionValue(i)&&(this.constraints[i]=Gh(o.layoutBox[i],this.constraints[i]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Rt(t))return!1;const o=t.current;Ve(o!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");const{projection:r}=this.visualElement;if(!r||!r.layout)return!1;const i=Xd(o,r.root,this.visualElement.getTransformPagePoint());let s=Hh(r.layout.layoutBox,i);if(n){const a=n(Wd(s));this.hasMutatedConstraints=!!a,a&&(s=ys(a))}return s}startAnimation(t){const{drag:n,dragMomentum:o,dragElastic:r,dragTransition:i,dragSnapToOrigin:s,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},c=ve(d=>{if(!un(d,n,this.currentDirection))return;let u=l&&l[d]||{};s&&(u={min:0,max:0});const h=r?200:1e6,f=r?40:1e7,v={type:"inertia",velocity:o?t[d]:0,bounceStiffness:h,bounceDamping:f,timeConstant:750,restDelta:1,restSpeed:10,...i,...u};return this.startAxisValueAnimation(d,v)});return Promise.all(c).then(a)}startAxisValueAnimation(t,n){const o=this.getAxisMotionValue(t);return wo(this.visualElement,t),o.start(go(t,o,0,n,this.visualElement,!1))}stopAnimation(){ve(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){ve(t=>this.getAxisMotionValue(t).animation?.pause())}getAnimationState(t){return this.getAxisMotionValue(t).animation?.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,o=this.visualElement.getProps(),r=o[n];return r||this.visualElement.getValue(t,(o.initial?o.initial[t]:void 0)||0)}snapToCursor(t){ve(n=>{const{drag:o}=this.getProps();if(!un(n,o,this.currentDirection))return;const{projection:r}=this.visualElement,i=this.getAxisMotionValue(n);if(r&&r.layout){const{min:s,max:a}=r.layout.layoutBox[n],l=i.get()||0;i.set(t[n]-Y(s,a,.5)+l)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:o}=this.visualElement;if(!Rt(n)||!o||!this.constraints)return;this.stopAnimation();const r={x:0,y:0};ve(s=>{const a=this.getAxisMotionValue(s);if(a&&this.constraints!==!1){const l=a.get();r[s]=jh({min:l,max:l},this.constraints[s])}});const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",o.root&&o.root.updateScroll(),o.updateLayout(),this.resolveConstraints(),ve(s=>{if(!un(s,t,null))return;const a=this.getAxisMotionValue(s),{min:l,max:c}=this.constraints[s];a.set(Y(l,c,r[s]))})}addListeners(){if(!this.visualElement.current)return;Kh.set(this.visualElement,this);const t=this.visualElement.current,n=Nt(t,"pointerdown",l=>{const{drag:c,dragListener:d=!0}=this.getProps();c&&d&&!as(l.target)&&this.start(l)}),o=()=>{const{dragConstraints:l}=this.getProps();Rt(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:r}=this.visualElement,i=r.addEventListener("measure",o);r&&!r.layout&&(r.root&&r.root.updateScroll(),r.updateLayout()),K.read(o);const s=It(window,"resize",()=>this.scalePositionWithinConstraints()),a=r.addEventListener("didUpdate",(({delta:l,hasLayoutChanged:c})=>{this.isDragging&&c&&(ve(d=>{const u=this.getAxisMotionValue(d);u&&(this.originPoint[d]+=l[d].translate,u.set(u.get()+l[d].translate))}),this.visualElement.render())}));return()=>{s(),n(),i(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:o=!1,dragPropagation:r=!1,dragConstraints:i=!1,dragElastic:s=Uo,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:o,dragPropagation:r,dragConstraints:i,dragElastic:s,dragMomentum:a}}}function un(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function qh(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class Yh extends Be{constructor(t){super(t),this.removeGroupControls=pe,this.removeListeners=pe,this.controls=new Wh(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||pe}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners()}}const Oa=e=>(t,n)=>{e&&K.postRender(()=>e(t,n))};class Xh extends Be{constructor(){super(...arguments),this.removePointerDownListener=pe}onPointerDown(t){this.session=new Ia(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Da(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:o,onPanEnd:r}=this.node.getProps();return{onSessionStart:Oa(t),onStart:Oa(n),onMove:o,onEnd:(i,s)=>{delete this.session,r&&K.postRender(()=>r(i,s))}}}mount(){this.removePointerDownListener=Nt(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let Ko=!1;class Zh extends m.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:o,layoutId:r}=this.props,{projection:i}=t;i&&(n.group&&n.group.add(i),o&&o.register&&r&&o.register(i),Ko&&i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),sn.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:o,drag:r,isPresent:i}=this.props,{projection:s}=o;return s&&(s.isPresent=i,Ko=!0,r||t.layoutDependency!==n||n===void 0||t.isPresent!==i?s.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?s.promote():s.relegate()||K.postRender(()=>{const a=s.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),To.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:o}=this.props,{projection:r}=t;Ko=!0,r&&(r.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(r),o&&o.deregister&&o.deregister(r))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function Ha(e){const[t,n]=ya(),o=m.useContext(Dn);return p.jsx(Zh,{...e,layoutGroup:o,switchLayoutGroup:m.useContext(Va),isPresent:t,safeToRemove:n})}const Jh={pan:{Feature:Xh},drag:{Feature:Yh,ProjectionNode:ga,MeasureLayout:Ha}};function ja(e,t,n){const{props:o}=e;e.animationState&&o.whileHover&&e.animationState.setActive("whileHover",n==="Start");const r="onHover"+n,i=o[r];i&&K.postRender(()=>i(t,_t(t)))}class Qh extends Be{mount(){const{current:t}=this.node;t&&(this.unmount=Id(t,(n,o)=>(ja(this.node,o,"Start"),r=>ja(this.node,r,"End"))))}unmount(){}}class em extends Be{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!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=Ct(It(this.node.current,"focus",()=>this.onFocus()),It(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Ga(e,t,n){const{props:o}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&o.whileTap&&e.animationState.setActive("whileTap",n==="Start");const r="onTap"+(n==="End"?"":n),i=o[r];i&&K.postRender(()=>i(t,_t(t)))}class tm extends Be{mount(){const{current:t}=this.node;t&&(this.unmount=_d(t,(n,o)=>(Ga(this.node,o,"Start"),(r,{success:i})=>Ga(this.node,r,i?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Wo=new WeakMap,qo=new WeakMap,nm=e=>{const t=Wo.get(e.target);t&&t(e)},om=e=>{e.forEach(nm)};function rm({root:e,...t}){const n=e||document;qo.has(n)||qo.set(n,{});const o=qo.get(n),r=JSON.stringify(t);return o[r]||(o[r]=new IntersectionObserver(om,{root:e,...t})),o[r]}function im(e,t,n){const o=rm(t);return Wo.set(e,n),o.observe(e),()=>{Wo.delete(e),o.unobserve(e)}}const sm={some:0,all:1};class am extends Be{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:o,amount:r="some",once:i}=t,s={root:n?n.current:void 0,rootMargin:o,threshold:typeof r=="number"?r:sm[r]},a=l=>{const{isIntersecting:c}=l;if(this.isInView===c||(this.isInView=c,i&&!c&&this.hasEnteredView))return;c&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",c);const{onViewportEnter:d,onViewportLeave:u}=this.node.getProps(),h=c?d:u;h&&h(l)};return im(this.node.current,s,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(lm(t,n))&&this.startObserver()}unmount(){}}function lm({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const cm={...Lh,...{inView:{Feature:am},tap:{Feature:tm},focus:{Feature:em},hover:{Feature:Qh}},...Jh,...{layout:{ProjectionNode:ga,MeasureLayout:Ha}}},De=Eh(cm,Dh),um={sm:g.css`
175
+ `),()=>{w.contains(b)&&w.removeChild(b)}},[t]),p.jsx(oh,{isPresent:t,childRef:i,sizeRef:s,children:Ue.cloneElement(e,{ref:c})})}const ih=({children:e,initial:t,isPresent:n,onExitComplete:o,custom:r,presenceAffectsLayout:i,mode:s,anchorX:a,root:l})=>{const c=An(sh),d=m.useId();let u=!0,f=m.useMemo(()=>(u=!1,{id:d,initial:t,isPresent:n,custom:r,onExitComplete:h=>{c.set(h,!0);for(const v of c.values())if(!v)return;o&&o()},register:h=>(c.set(h,!1),()=>c.delete(h))}),[n,c,o]);return i&&u&&(f={...f}),m.useMemo(()=>{c.forEach((h,v)=>c.set(v,!1))},[n]),Ue.useEffect(()=>{!n&&!c.size&&o&&o()},[n]),s==="popLayout"&&(e=p.jsx(rh,{isPresent:n,anchorX:a,root:l,children:e})),p.jsx(Wt.Provider,{value:f,children:e})};function sh(){return new Map}function ba(e=!0){const t=m.useContext(Wt);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:o,register:r}=t,i=m.useId();m.useEffect(()=>{if(e)return r(i)},[e]);const s=m.useCallback(()=>e&&o&&o(i),[i,o,e]);return!n&&o?[!1,s]:[!0]}const ln=e=>e.key||"";function xa(e){const t=[];return m.Children.forEach(e,n=>{m.isValidElement(n)&&t.push(n)}),t}const Rt=({children:e,custom:t,initial:n=!0,onExitComplete:o,presenceAffectsLayout:r=!0,mode:i="sync",propagate:s=!1,anchorX:a="left",root:l})=>{const[c,d]=ba(s),u=m.useMemo(()=>xa(e),[e]),f=s&&!c?[]:u.map(ln),h=m.useRef(!0),v=m.useRef(u),y=An(()=>new Map),b=m.useRef(new Set),[w,S]=m.useState(u),[x,P]=m.useState(u);qr(()=>{h.current=!1,v.current=u;for(let V=0;V<x.length;V++){const $=ln(x[V]);f.includes($)?(y.delete($),b.current.delete($)):y.get($)!==!0&&y.set($,!1)}},[x,f.length,f.join("-")]);const T=[];if(u!==w){let V=[...u];for(let $=0;$<x.length;$++){const A=x[$],I=ln(A);f.includes(I)||(V.splice($,0,A),T.push(A))}return i==="wait"&&T.length&&(V=T),P(xa(V)),S(u),null}process.env.NODE_ENV!=="production"&&i==="wait"&&x.length>1&&console.warn(`You're attempting to animate multiple children within AnimatePresence, but its mode is set to "wait". This will lead to odd visual behaviour.`);const{forceRender:k}=m.useContext(Fn);return p.jsx(p.Fragment,{children:x.map(V=>{const $=ln(V),A=s&&!c?!1:u===x||f.includes($),I=()=>{if(b.current.has($))return;if(b.current.add($),y.has($))y.set($,!0);else return;let N=!0;y.forEach(H=>{H||(N=!1)}),N&&(k?.(),P(v.current),s&&d?.(),o&&o())};return p.jsx(ih,{isPresent:A,initial:!h.current||n?void 0:!1,custom:t,presenceAffectsLayout:r,mode:i,root:l,onExitComplete:A?void 0:I,anchorX:a,children:V},$)})})},Sa=m.createContext({strict:!1}),Ca={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let Ta=!1;function ah(){if(Ta)return;const e={};for(const t in Ca)e[t]={isEnabled:n=>Ca[t].some(o=>!!n[o])};ys(e),Ta=!0}function $a(){return ah(),Wd()}function lh(e){const t=$a();for(const n in e)t[n]={...t[n],...e[n]};ys(t)}const ch=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","ignoreStrict","viewport"]);function cn(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||ch.has(e)}let Pa=e=>!cn(e);function uh(e){typeof e=="function"&&(Pa=t=>t.startsWith("on")?!cn(t):e(t))}try{uh(require("@emotion/is-prop-valid").default)}catch{}function dh(e,t,n){const o={};for(const r in e)r==="values"&&typeof e.values=="object"||(Pa(r)||n===!0&&cn(r)||!t&&!cn(r)||e.draggable&&r.startsWith("onDrag"))&&(o[r]=e[r]);return o}const un=m.createContext({});function fh(e,t){if(tn(e)){const{initial:n,animate:o}=e;return{initial:n===!1||Ft(n)?n:void 0,animate:Ft(o)?o:void 0}}return e.inherit!==!1?t:{}}function hh(e){const{initial:t,animate:n}=fh(e,m.useContext(un));return m.useMemo(()=>({initial:t,animate:n}),[ka(t),ka(n)])}function ka(e){return Array.isArray(e)?e.join(" "):e}const Oo=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Ma(e,t,n){for(const o in t)!ie(t[o])&&!Ds(o,n)&&(e[o]=t[o])}function mh({transformTemplate:e},t){return m.useMemo(()=>{const n=Oo();return Io(n,t,e),Object.assign({},n.vars,n.style)},[t])}function ph(e,t){const n=e.style||{},o={};return Ma(o,n,e),Object.assign(o,mh(e,t)),o}function gh(e,t){const n={},o=ph(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.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=o,n}const Va=()=>({...Oo(),attrs:{}});function vh(e,t,n,o){const r=m.useMemo(()=>{const i=Va();return Fs(i,t,Is(o),e.transformTemplate,e.style),{...i.attrs,style:{...i.style}}},[t]);if(e.style){const i={};Ma(i,e.style,e),r.style={...i,...r.style}}return r}const yh=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Ho(e){return typeof e!="string"||e.includes("-")?!1:!!(yh.indexOf(e)>-1||/[A-Z]/u.test(e))}function wh(e,t,n,{latestValues:o},r,i=!1,s){const l=(s??Ho(e)?vh:gh)(t,o,r,e),c=dh(t,typeof e=="string",i),d=e!==m.Fragment?{...c,...l,ref:n}:{},{children:u}=t,f=m.useMemo(()=>ie(u)?u.get():u,[u]);return m.createElement(e,{...d,children:f})}function bh({scrapeMotionValuesFromProps:e,createRenderState:t},n,o,r){return{latestValues:xh(n,o,r,e),renderState:t()}}function xh(e,t,n,o){const r={},i=o(e,{});for(const f in i)r[f]=sn(i[f]);let{initial:s,animate:a}=e;const l=tn(e),c=gs(e);t&&c&&!l&&e.inherit!==!1&&(s===void 0&&(s=t.initial),a===void 0&&(a=t.animate));let d=n?n.initial===!1:!1;d=d||s===!1;const u=d?a:s;if(u&&typeof u!="boolean"&&!en(u)){const f=Array.isArray(u)?u:[u];for(let h=0;h<f.length;h++){const v=yo(e,f[h]);if(v){const{transitionEnd:y,transition:b,...w}=v;for(const S in w){let x=w[S];if(Array.isArray(x)){const P=d?x.length-1:0;x=x[P]}x!==null&&(r[S]=x)}for(const S in y)r[S]=y[S]}}}return r}const Ea=e=>(t,n)=>{const o=m.useContext(un),r=m.useContext(Wt),i=()=>bh(e,t,o,r);return n?i():An(i)},Sh=Ea({scrapeMotionValuesFromProps:Ro,createRenderState:Oo}),Ch=Ea({scrapeMotionValuesFromProps:Ls,createRenderState:Va}),Th=Symbol.for("motionComponentSymbol");function $h(e,t,n){const o=m.useRef(n);m.useInsertionEffect(()=>{o.current=n});const r=m.useRef(null);return m.useCallback(i=>{i&&e.onMount?.(i),t&&(i?t.mount(i):t.unmount());const s=o.current;if(typeof s=="function")if(i){const a=s(i);typeof a=="function"&&(r.current=a)}else r.current?(r.current(),r.current=null):s(i);else s&&(s.current=i)},[t])}const Da=m.createContext({});function _t(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function Ph(e,t,n,o,r,i){const{visualElement:s}=m.useContext(un),a=m.useContext(Sa),l=m.useContext(Wt),c=m.useContext(zo).reducedMotion,d=m.useRef(null);o=o||a.renderer,!d.current&&o&&(d.current=o(e,{visualState:t,parent:s,props:n,presenceContext:l,blockInitialAnimation:l?l.initial===!1:!1,reducedMotionConfig:c,isSVG:i}));const u=d.current,f=m.useContext(Da);u&&!u.projection&&r&&(u.type==="html"||u.type==="svg")&&kh(d.current,n,r,f);const h=m.useRef(!1);m.useInsertionEffect(()=>{u&&h.current&&u.update(n,l)});const v=n[qi],y=m.useRef(!!v&&!window.MotionHandoffIsComplete?.(v)&&window.MotionHasOptimisedAnimation?.(v));return qr(()=>{u&&(h.current=!0,window.MotionIsMounted=!0,u.updateFeatures(),u.scheduleRenderMicrotask(),y.current&&u.animationState&&u.animationState.animateChanges())}),m.useEffect(()=>{u&&(!y.current&&u.animationState&&u.animationState.animateChanges(),y.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(v)}),y.current=!1),u.enteringChildren=void 0)}),u}function kh(e,t,n,o){const{layoutId:r,layout:i,drag:s,dragConstraints:a,layoutScroll:l,layoutRoot:c,layoutCrossfade:d}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:Fa(e.parent)),e.projection.setOptions({layoutId:r,layout:i,alwaysMeasureLayout:!!s||a&&_t(a),visualElement:e,animationType:typeof i=="string"?i:"both",initialPromotionConfig:o,crossfade:d,layoutScroll:l,layoutRoot:c})}function Fa(e){if(e)return e.options.allowProjection!==!1?e.projection:Fa(e.parent)}function jo(e,{forwardMotionProps:t=!1,type:n}={},o,r){o&&lh(o);const i=n?n==="svg":Ho(e),s=i?Ch:Sh;function a(c,d){let u;const f={...m.useContext(zo),...c,layoutId:Mh(c)},{isStatic:h}=f,v=hh(c),y=s(c,h);if(!h&&Kr){Vh(f,o);const b=Eh(f);u=b.MeasureLayout,v.visualElement=Ph(e,y,f,r,b.ProjectionNode,i)}return p.jsxs(un.Provider,{value:v,children:[u&&v.visualElement?p.jsx(u,{visualElement:v.visualElement,...f}):null,wh(e,c,$h(y,v.visualElement,d),y,h,t,i)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const l=m.forwardRef(a);return l[Th]=e,l}function Mh({layoutId:e}){const t=m.useContext(Fn).id;return t&&e!==void 0?t+"-"+e:e}function Vh(e,t){const n=m.useContext(Sa).strict;if(process.env.NODE_ENV!=="production"&&t&&n){const o="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";e.ignoreStrict?nt(!1,o,"lazy-strict-mode"):Ve(!1,o,"lazy-strict-mode")}}function Eh(e){const t=$a(),{drag:n,layout:o}=t;if(!n&&!o)return{};const r={...n,...o};return{MeasureLayout:n?.isEnabled(e)||o?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function Dh(e,t){if(typeof Proxy>"u")return jo;const n=new Map,o=(i,s)=>jo(i,s,e,t),r=(i,s)=>(process.env.NODE_ENV!=="production"&&Nn(!1,"motion() is deprecated. Use motion.create() instead."),o(i,s));return new Proxy(r,{get:(i,s)=>s==="create"?o:(n.has(s)||n.set(s,jo(s,void 0,e,t)),n.get(s))})}const Fh=(e,t)=>t.isSVG??Ho(e)?new uf(t):new of(t,{allowProjection:e!==m.Fragment});class Ah extends Ne{constructor(t){super(t),t.animationState||(t.animationState=pf(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();en(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}}let Ih=0;class Lh extends Ne{constructor(){super(...arguments),this.id=Ih++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:o}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===o)return;const r=this.node.animationState.setActive("exit",!t);n&&!t&&r.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const Rh={animation:{Feature:Ah},exit:{Feature:Lh}};function Bt(e){return{point:{x:e.pageX,y:e.pageY}}}const _h=e=>t=>Po(t)&&e(t,Bt(t));function Nt(e,t,n,o){return Lt(e,t,_h(n),o)}const Aa=({current:e})=>e?e.ownerDocument.defaultView:null,Ia=(e,t)=>Math.abs(e-t);function Bh(e,t){const n=Ia(e.x,t.x),o=Ia(e.y,t.y);return Math.sqrt(n**2+o**2)}const La=new Set(["auto","scroll"]);class Ra{constructor(t,n,{transformPagePoint:o,contextWindow:r=window,dragSnapToOrigin:i=!1,distanceThreshold:s=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=h=>{this.handleScroll(h.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const h=Uo(this.lastMoveEventInfo,this.history),v=this.startEvent!==null,y=Bh(h.offset,{x:0,y:0})>=this.distanceThreshold;if(!v&&!y)return;const{point:b}=h,{timestamp:w}=oe;this.history.push({...b,timestamp:w});const{onStart:S,onMove:x}=this.handlers;v||(S&&S(this.lastMoveEvent,h),this.startEvent=this.lastMoveEvent),x&&x(this.lastMoveEvent,h)},this.handlePointerMove=(h,v)=>{this.lastMoveEvent=h,this.lastMoveEventInfo=Go(v,this.transformPagePoint),W.update(this.updatePoint,!0)},this.handlePointerUp=(h,v)=>{this.end();const{onEnd:y,onSessionEnd:b,resumeAnimation:w}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&w&&w(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const S=Uo(h.type==="pointercancel"?this.lastMoveEventInfo:Go(v,this.transformPagePoint),this.history);this.startEvent&&y&&y(h,S),b&&b(h,S)},!Po(t))return;this.dragSnapToOrigin=i,this.handlers=n,this.transformPagePoint=o,this.distanceThreshold=s,this.contextWindow=r||window;const l=Bt(t),c=Go(l,this.transformPagePoint),{point:d}=c,{timestamp:u}=oe;this.history=[{...d,timestamp:u}];const{onSessionStart:f}=n;f&&f(t,Uo(c,this.history)),this.removeListeners=Tt(Nt(this.contextWindow,"pointermove",this.handlePointerMove),Nt(this.contextWindow,"pointerup",this.handlePointerUp),Nt(this.contextWindow,"pointercancel",this.handlePointerUp)),a&&this.startScrollTracking(a)}startScrollTracking(t){let n=t.parentElement;for(;n;){const o=getComputedStyle(n);(La.has(o.overflowX)||La.has(o.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0,passive:!0}),window.addEventListener("scroll",this.onWindowScroll,{passive:!0}),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const o=t===window,r=o?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},i={x:r.x-n.x,y:r.y-n.y};i.x===0&&i.y===0||(o?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(t,r),W.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Le(this.updatePoint)}}function Go(e,t){return t?{point:t(e.point)}:e}function _a(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Uo({point:e},t){return{point:e,delta:_a(e,Ba(t)),offset:_a(e,Nh(t)),velocity:zh(t,.1)}}function Nh(e){return e[0]}function Ba(e){return e[e.length-1]}function zh(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,o=null;const r=Ba(e);for(;n>=0&&(o=e[n],!(r.timestamp-o.timestamp>Pe(t)));)n--;if(!o)return{x:0,y:0};const i=ge(r.timestamp-o.timestamp);if(i===0)return{x:0,y:0};const s={x:(r.x-o.x)/i,y:(r.y-o.y)/i};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function Oh(e,{min:t,max:n},o){return t!==void 0&&e<t?e=o?Y(t,e,o.min):Math.max(e,t):n!==void 0&&e>n&&(e=o?Y(n,e,o.max):Math.min(e,n)),e}function Na(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function Hh(e,{top:t,left:n,bottom:o,right:r}){return{x:Na(e.x,n,r),y:Na(e.y,t,o)}}function za(e,t){let n=t.min-e.min,o=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,o]=[o,n]),{min:n,max:o}}function jh(e,t){return{x:za(e.x,t.x),y:za(e.y,t.y)}}function Gh(e,t){let n=.5;const o=ce(e),r=ce(t);return r>o?n=$t(t.min,t.max-o,e.min):o>r&&(n=$t(e.min,e.max-r,t.min)),$e(0,1,n)}function Uh(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Wo=.35;function Wh(e=Wo){return e===!1?e=0:e===!0&&(e=Wo),{x:Oa(e,"left","right"),y:Oa(e,"top","bottom")}}function Oa(e,t,n){return{min:Ha(e,t),max:Ha(e,n)}}function Ha(e,t){return typeof e=="number"?e:e[t]||0}const Kh=new WeakMap;class qh{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=ee(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:o}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const i=u=>{n?(this.stopAnimation(),this.snapToCursor(Bt(u).point)):this.pauseAnimation()},s=(u,f)=>{this.stopAnimation();const{drag:h,dragPropagation:v,onDragStart:y}=this.getProps();if(h&&!v&&(this.openDragLock&&this.openDragLock(),this.openDragLock=Id(h),!this.openDragLock))return;this.latestPointerEvent=u,this.latestPanInfo=f,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),ve(w=>{let S=this.getAxisMotionValue(w).get()||0;if(ke.test(S)){const{projection:x}=this.visualElement;if(x&&x.layout){const P=x.layout.layoutBox[w];P&&(S=ce(P)*(parseFloat(S)/100))}}this.originPoint[w]=S}),y&&W.postRender(()=>y(u,f)),bo(this.visualElement,"transform");const{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},a=(u,f)=>{this.latestPointerEvent=u,this.latestPanInfo=f;const{dragPropagation:h,dragDirectionLock:v,onDirectionLock:y,onDrag:b}=this.getProps();if(!h&&!this.openDragLock)return;const{offset:w}=f;if(v&&this.currentDirection===null){this.currentDirection=Yh(w),this.currentDirection!==null&&y&&y(this.currentDirection);return}this.updateAxis("x",f.point,w),this.updateAxis("y",f.point,w),this.visualElement.render(),b&&b(u,f)},l=(u,f)=>{this.latestPointerEvent=u,this.latestPanInfo=f,this.stop(u,f),this.latestPointerEvent=null,this.latestPanInfo=null},c=()=>ve(u=>this.getAnimationState(u)==="paused"&&this.getAxisMotionValue(u).animation?.play()),{dragSnapToOrigin:d}=this.getProps();this.panSession=new Ra(t,{onSessionStart:i,onStart:s,onMove:a,onSessionEnd:l,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:d,distanceThreshold:o,contextWindow:Aa(this.visualElement),element:this.visualElement.current})}stop(t,n){const o=t||this.latestPointerEvent,r=n||this.latestPanInfo,i=this.isDragging;if(this.cancel(),!i||!r||!o)return;const{velocity:s}=r;this.startAnimation(s);const{onDragEnd:a}=this.getProps();a&&W.postRender(()=>a(o,r))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:o}=this.getProps();!o&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,o){const{drag:r}=this.getProps();if(!o||!dn(t,r,this.currentDirection))return;const i=this.getAxisMotionValue(t);let s=this.originPoint[t]+o[t];this.constraints&&this.constraints[t]&&(s=Oh(s,this.constraints[t],this.elastic[t])),i.set(s)}resolveConstraints(){const{dragConstraints:t,dragElastic:n}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,r=this.constraints;t&&_t(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&o?this.constraints=Hh(o.layoutBox,t):this.constraints=!1,this.elastic=Wh(n),r!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&ve(i=>{this.constraints!==!1&&this.getAxisMotionValue(i)&&(this.constraints[i]=Uh(o.layoutBox[i],this.constraints[i]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!_t(t))return!1;const o=t.current;Ve(o!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");const{projection:r}=this.visualElement;if(!r||!r.layout)return!1;const i=Zd(o,r.root,this.visualElement.getTransformPagePoint());let s=jh(r.layout.layoutBox,i);if(n){const a=n(qd(s));this.hasMutatedConstraints=!!a,a&&(s=bs(a))}return s}startAnimation(t){const{drag:n,dragMomentum:o,dragElastic:r,dragTransition:i,dragSnapToOrigin:s,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},c=ve(d=>{if(!dn(d,n,this.currentDirection))return;let u=l&&l[d]||{};s&&(u={min:0,max:0});const f=r?200:1e6,h=r?40:1e7,v={type:"inertia",velocity:o?t[d]:0,bounceStiffness:f,bounceDamping:h,timeConstant:750,restDelta:1,restSpeed:10,...i,...u};return this.startAxisValueAnimation(d,v)});return Promise.all(c).then(a)}startAxisValueAnimation(t,n){const o=this.getAxisMotionValue(t);return bo(this.visualElement,t),o.start(vo(t,o,0,n,this.visualElement,!1))}stopAnimation(){ve(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){ve(t=>this.getAxisMotionValue(t).animation?.pause())}getAnimationState(t){return this.getAxisMotionValue(t).animation?.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,o=this.visualElement.getProps(),r=o[n];return r||this.visualElement.getValue(t,(o.initial?o.initial[t]:void 0)||0)}snapToCursor(t){ve(n=>{const{drag:o}=this.getProps();if(!dn(n,o,this.currentDirection))return;const{projection:r}=this.visualElement,i=this.getAxisMotionValue(n);if(r&&r.layout){const{min:s,max:a}=r.layout.layoutBox[n],l=i.get()||0;i.set(t[n]-Y(s,a,.5)+l)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:o}=this.visualElement;if(!_t(n)||!o||!this.constraints)return;this.stopAnimation();const r={x:0,y:0};ve(s=>{const a=this.getAxisMotionValue(s);if(a&&this.constraints!==!1){const l=a.get();r[s]=Gh({min:l,max:l},this.constraints[s])}});const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",o.root&&o.root.updateScroll(),o.updateLayout(),this.resolveConstraints(),ve(s=>{if(!dn(s,t,null))return;const a=this.getAxisMotionValue(s),{min:l,max:c}=this.constraints[s];a.set(Y(l,c,r[s]))})}addListeners(){if(!this.visualElement.current)return;Kh.set(this.visualElement,this);const t=this.visualElement.current,n=Nt(t,"pointerdown",l=>{const{drag:c,dragListener:d=!0}=this.getProps();c&&d&&!cs(l.target)&&this.start(l)}),o=()=>{const{dragConstraints:l}=this.getProps();_t(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:r}=this.visualElement,i=r.addEventListener("measure",o);r&&!r.layout&&(r.root&&r.root.updateScroll(),r.updateLayout()),W.read(o);const s=Lt(window,"resize",()=>this.scalePositionWithinConstraints()),a=r.addEventListener("didUpdate",(({delta:l,hasLayoutChanged:c})=>{this.isDragging&&c&&(ve(d=>{const u=this.getAxisMotionValue(d);u&&(this.originPoint[d]+=l[d].translate,u.set(u.get()+l[d].translate))}),this.visualElement.render())}));return()=>{s(),n(),i(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:o=!1,dragPropagation:r=!1,dragConstraints:i=!1,dragElastic:s=Wo,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:o,dragPropagation:r,dragConstraints:i,dragElastic:s,dragMomentum:a}}}function dn(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function Yh(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class Xh extends Ne{constructor(t){super(t),this.removeGroupControls=pe,this.removeListeners=pe,this.controls=new qh(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||pe}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners()}}const ja=e=>(t,n)=>{e&&W.postRender(()=>e(t,n))};class Zh extends Ne{constructor(){super(...arguments),this.removePointerDownListener=pe}onPointerDown(t){this.session=new Ra(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Aa(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:o,onPanEnd:r}=this.node.getProps();return{onSessionStart:ja(t),onStart:ja(n),onMove:o,onEnd:(i,s)=>{delete this.session,r&&W.postRender(()=>r(i,s))}}}mount(){this.removePointerDownListener=Nt(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let Ko=!1;class Jh extends m.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:o,layoutId:r}=this.props,{projection:i}=t;i&&(n.group&&n.group.add(i),o&&o.register&&r&&o.register(i),Ko&&i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),an.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:o,drag:r,isPresent:i}=this.props,{projection:s}=o;return s&&(s.isPresent=i,Ko=!0,r||t.layoutDependency!==n||n===void 0||t.isPresent!==i?s.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?s.promote():s.relegate()||W.postRender(()=>{const a=s.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),$o.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:o}=this.props,{projection:r}=t;Ko=!0,r&&(r.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(r),o&&o.deregister&&o.deregister(r))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function Ga(e){const[t,n]=ba(),o=m.useContext(Fn);return p.jsx(Jh,{...e,layoutGroup:o,switchLayoutGroup:m.useContext(Da),isPresent:t,safeToRemove:n})}const Qh={pan:{Feature:Zh},drag:{Feature:Xh,ProjectionNode:ya,MeasureLayout:Ga}};function Ua(e,t,n){const{props:o}=e;e.animationState&&o.whileHover&&e.animationState.setActive("whileHover",n==="Start");const r="onHover"+n,i=o[r];i&&W.postRender(()=>i(t,Bt(t)))}class em extends Ne{mount(){const{current:t}=this.node;t&&(this.unmount=Ld(t,(n,o)=>(Ua(this.node,o,"Start"),r=>Ua(this.node,r,"End"))))}unmount(){}}class tm extends Ne{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!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=Tt(Lt(this.node.current,"focus",()=>this.onFocus()),Lt(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Wa(e,t,n){const{props:o}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&o.whileTap&&e.animationState.setActive("whileTap",n==="Start");const r="onTap"+(n==="End"?"":n),i=o[r];i&&W.postRender(()=>i(t,Bt(t)))}class nm extends Ne{mount(){const{current:t}=this.node;t&&(this.unmount=Bd(t,(n,o)=>(Wa(this.node,o,"Start"),(r,{success:i})=>Wa(this.node,r,i?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const qo=new WeakMap,Yo=new WeakMap,om=e=>{const t=qo.get(e.target);t&&t(e)},rm=e=>{e.forEach(om)};function im({root:e,...t}){const n=e||document;Yo.has(n)||Yo.set(n,{});const o=Yo.get(n),r=JSON.stringify(t);return o[r]||(o[r]=new IntersectionObserver(rm,{root:e,...t})),o[r]}function sm(e,t,n){const o=im(t);return qo.set(e,n),o.observe(e),()=>{qo.delete(e),o.unobserve(e)}}const am={some:0,all:1};class lm extends Ne{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:o,amount:r="some",once:i}=t,s={root:n?n.current:void 0,rootMargin:o,threshold:typeof r=="number"?r:am[r]},a=l=>{const{isIntersecting:c}=l;if(this.isInView===c||(this.isInView=c,i&&!c&&this.hasEnteredView))return;c&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",c);const{onViewportEnter:d,onViewportLeave:u}=this.node.getProps(),f=c?d:u;f&&f(l)};return sm(this.node.current,s,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(cm(t,n))&&this.startObserver()}unmount(){}}function cm({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const um={...Rh,...{inView:{Feature:lm},tap:{Feature:nm},focus:{Feature:tm},hover:{Feature:em}},...Qh,...{layout:{ProjectionNode:ya,MeasureLayout:Ga}}},De=Dh(um,Fh),dm={sm:g.css`
176
176
  width: 1.25rem;
177
177
  height: 1.25rem;
178
178
  `,md:g.css`
@@ -184,7 +184,7 @@
184
184
  `,xl:g.css`
185
185
  width: 4rem;
186
186
  height: 4rem;
187
- `},Ua={primary:g.css`
187
+ `},Ka={primary:g.css`
188
188
  color: var(--color-main-blue-primary);
189
189
  `,orange:g.css`
190
190
  color: var(--color-main-orange-primary);
@@ -192,29 +192,29 @@
192
192
  color: var(--color-main-white);
193
193
  `,gray:g.css`
194
194
  color: var(--color-main-grey);
195
- `},dm=g.div`
195
+ `},fm=g.div`
196
196
  position: relative;
197
197
  display: block;
198
- ${({$size:e="md"})=>um[e]}
199
- ${({$color:e="primary"})=>Ua[e]}
198
+ ${({$size:e="md"})=>dm[e]}
199
+ ${({$color:e="primary"})=>Ka[e]}
200
200
  user-select: none;
201
- `,fm=g.div`
201
+ `,hm=g.div`
202
202
  display: flex;
203
203
  flex-direction: column;
204
204
  align-items: center;
205
205
  gap: 0.5rem;
206
206
  padding: 2.5px 2.5px 2.5px 0px;
207
- `,hm=g.div`
207
+ `,mm=g.div`
208
208
  display: flex;
209
209
  align-items: center;
210
210
  justify-content: center;
211
211
  min-height: 12.5rem;
212
212
  width: 100%;
213
- `,mm=g(De.p)`
213
+ `,pm=g(De.p)`
214
214
  ${D[16]}
215
- ${({$color:e="primary"})=>Ua[e]}
215
+ ${({$color:e="primary"})=>Ka[e]}
216
216
  margin: 0;
217
- `,pm=({variant:e,title:t})=>p.jsxs(De.svg,{width:"100%",height:"100%",viewBox:"0 0 50 50",style:{position:"absolute",top:0,left:0,zIndex:1,padding:"2.1px 2.5px 2.5px 0px"},animate:e==="rotate"?{rotate:[0,360]}:{scale:[1,.7,1]},transition:e==="rotate"?{repeat:1/0,duration:2,ease:"linear"}:{repeat:1/0,duration:2,ease:"easeInOut"},children:[p.jsx("g",{transform:"scale(0.15) translate(-10, -1)",children:p.jsx("path",{fill:"currentColor",d:`M67.251411,286.749390
217
+ `,gm=({variant:e,title:t})=>p.jsxs(De.svg,{width:"100%",height:"100%",viewBox:"0 0 50 50",style:{position:"absolute",top:0,left:0,zIndex:1,padding:"2.1px 2.5px 2.5px 0px"},animate:e==="rotate"?{rotate:[0,360]}:{scale:[1,.7,1]},transition:e==="rotate"?{repeat:1/0,duration:2,ease:"linear"}:{repeat:1/0,duration:2,ease:"easeInOut"},children:[p.jsx("g",{transform:"scale(0.15) translate(-10, -1)",children:p.jsx("path",{fill:"currentColor",d:`M67.251411,286.749390
218
218
  C42.999393,262.534088 27.711603,233.886490 21.140957,200.638245
219
219
  C20.527918,197.536194 19.462318,196.344513 16.327942,196.535400
220
220
  C12.711285,196.755646 9.070918,196.586609 4.251685,196.586609
@@ -231,7 +231,7 @@
231
231
  C231.681030,-17.750278 329.482361,42.974667 346.823608,138.519577
232
232
  C363.551025,230.682480 301.903687,318.479523 209.509521,332.564972
233
233
  C155.049683,340.867371 107.495514,325.072021 67.251411,286.749390
234
- z`})}),t&&p.jsx("title",{children:t})]}),dn=({size:e="md",color:t="primary",centered:n=!0,message:o,title:r,variant:i="rotate"})=>{const s=p.jsxs(fm,{children:[p.jsx(dm,{$size:e,$color:t,$variant:i,children:p.jsx(pm,{variant:i,title:r})}),o&&p.jsx(mm,{$color:t,animate:{opacity:[1,.5,1]},transition:{repeat:1/0,duration:2,ease:"easeInOut"},children:o})]});return n?p.jsx(hm,{children:s}):s},gm=g.div`
234
+ z`})}),t&&p.jsx("title",{children:t})]}),fn=({size:e="md",color:t="primary",centered:n=!0,message:o,title:r,variant:i="rotate"})=>{const s=p.jsxs(hm,{children:[p.jsx(fm,{$size:e,$color:t,$variant:i,children:p.jsx(gm,{variant:i,title:r})}),o&&p.jsx(pm,{$color:t,animate:{opacity:[1,.5,1]},transition:{repeat:1/0,duration:2,ease:"easeInOut"},children:o})]});return n?p.jsx(mm,{children:s}):s},vm=g.div`
235
235
  position: fixed;
236
236
  inset: 0;
237
237
  background-color: rgba(255, 255, 255, 0.8);
@@ -240,7 +240,7 @@
240
240
  align-items: center;
241
241
  justify-content: center;
242
242
  z-index: 50;
243
- `,vm=g.div`
243
+ `,ym=g.div`
244
244
  background-color: var(--color-main-white);
245
245
  border-radius: var(--border-radius-card);
246
246
  box-shadow: var(--shadow-black-card);
@@ -251,18 +251,18 @@
251
251
  gap: 1rem;
252
252
  width: 90%;
253
253
  max-width: 24rem;
254
- `,ym=g.h2`
255
- ${En[30]}
254
+ `,wm=g.h2`
255
+ ${Dn[30]}
256
256
  color: var(--color-main-blue-primary);
257
257
  margin: 0 auto;
258
258
  text-align: center;
259
- `,wm=({message:e="Loading...",color:t="primary",variant:n="rotate"})=>p.jsx(gm,{role:"status","aria-live":"polite",children:p.jsxs(vm,{children:[p.jsx(dn,{size:"xl",color:t,centered:!1,title:e,variant:n}),p.jsx(ym,{children:e})]})}),bm=g.div`
259
+ `,bm=({message:e="Loading...",color:t="primary",variant:n="rotate"})=>p.jsx(vm,{role:"status","aria-live":"polite",children:p.jsxs(ym,{children:[p.jsx(fn,{size:"xl",color:t,centered:!1,title:e,variant:n}),p.jsx(wm,{children:e})]})}),xm=g.div`
260
260
  display: flex;
261
261
  flex-direction: column;
262
262
  align-items: center;
263
263
  justify-content: center;
264
264
  padding: 3rem 1rem;
265
- `,xm=({message:e,color:t="primary",variant:n="rotate"})=>p.jsx(bm,{role:"status","aria-live":"polite",children:p.jsx(dn,{size:"lg",color:t,centered:!1,message:e,title:e,variant:n})}),Sm={primary:g.css`
265
+ `,Sm=({message:e,color:t="primary",variant:n="rotate"})=>p.jsx(xm,{role:"status","aria-live":"polite",children:p.jsx(fn,{size:"lg",color:t,centered:!1,message:e,title:e,variant:n})}),Cm={primary:g.css`
266
266
  background-color: var(--color-main-blue-primary);
267
267
  color: var(--color-main-white);
268
268
 
@@ -322,24 +322,24 @@
322
322
  border-color: var(--color-dark-200);
323
323
  background-color: transparent;
324
324
  }
325
- `},Cm=g.css`
325
+ `},Tm=g.css`
326
326
  background-color: var(--color-main-grey);
327
327
  color: var(--color-dark-200);
328
328
  cursor: not-allowed;
329
329
  box-shadow: none;
330
- `,Tm={sm:g.css`
331
- padding: 0.375rem 0.75rem;
330
+ `,$m={sm:g.css`
331
+ padding: 0.375rem 1.5rem;
332
332
  min-height: 2.75rem;
333
333
  ${D[12]}
334
334
  `,md:g.css`
335
- padding: 0.625rem 1.25rem;
335
+ padding: 0.625rem 1.75rem;
336
336
  min-height: 3.175rem;
337
337
  ${D[16]}
338
338
  `,lg:g.css`
339
- padding: 0.75rem 1.5rem;
339
+ padding: 0.75rem 2rem;
340
340
  min-height: 3.5rem;
341
341
  ${D[20]}
342
- `},$m=g.button`
342
+ `},Pm=g.button`
343
343
  border: none;
344
344
  border-radius: var(--border-radius-button);
345
345
  transition:
@@ -354,13 +354,13 @@
354
354
  outline: 2px solid transparent;
355
355
  outline-offset: 2px;
356
356
 
357
- ${({$variant:e})=>Sm[e]}
358
- ${({$size:e})=>Tm[e]}
357
+ ${({$variant:e})=>Cm[e]}
358
+ ${({$size:e})=>$m[e]}
359
359
 
360
360
  &:disabled {
361
- ${Cm}
361
+ ${Tm}
362
362
  }
363
- `,ft=({children:e,variant:t="primary",size:n="md",isLoading:o,disabled:r,leftIcon:i,rightIcon:s,iconSize:a="md",iconColor:l="currentColor",...c})=>p.jsxs($m,{$variant:t,$size:n,disabled:r||o,"aria-busy":o,...c,children:[i&&p.jsx(U,{color:l,size:a,component:i}),o?"Loading...":e,s&&p.jsx(U,{color:l,size:a,component:s})]}),Pm={sm:g.css`
363
+ `,ht=({children:e,variant:t="primary",size:n="md",isLoading:o,disabled:r,leftIcon:i,rightIcon:s,iconSize:a="md",iconColor:l="currentColor",...c})=>p.jsxs(Pm,{$variant:t,$size:n,disabled:r||o,"aria-busy":o,...c,children:[i&&p.jsx(U,{color:l,size:a,component:i}),o?"Loading...":e,s&&p.jsx(U,{color:l,size:a,component:s})]}),km={sm:g.css`
364
364
  padding: 0.25rem 0.625rem;
365
365
  border-radius: var(--border-radius-button);
366
366
  ${D[12]}
@@ -372,7 +372,7 @@
372
372
  padding: 0.5rem 1rem;
373
373
  border-radius: var(--border-radius-button);
374
374
  ${D[16]}
375
- `},km={primary:g.css`
375
+ `},Mm={primary:g.css`
376
376
  background-color: var(--color-main-blue-primary);
377
377
  color: var(--color-main-white);
378
378
  `,secondary:g.css`
@@ -390,7 +390,7 @@
390
390
  `,neutral:g.css`
391
391
  background-color: var(--color-light-200);
392
392
  color: var(--color-main-grey);
393
- `,outline:g.css``},Mm=g.span`
393
+ `,outline:g.css``},Vm=g.span`
394
394
  display: inline-flex;
395
395
  align-items: center;
396
396
  gap: 0.375rem;
@@ -398,15 +398,15 @@
398
398
  white-space: nowrap;
399
399
  user-select: none;
400
400
 
401
- ${({$size:e})=>Pm[e]}
402
- ${({$variant:e})=>km[e]}
401
+ ${({$size:e})=>km[e]}
402
+ ${({$variant:e})=>Mm[e]}
403
403
 
404
404
  ${({$variant:e,$outlineColor:t})=>e==="outline"?g.css`
405
405
  background-color: transparent;
406
406
  color: ${t||"var(--color-main-blue-primary)"};
407
407
  border: 1px solid ${t||"var(--color-main-blue-primary)"};
408
408
  `:""}
409
- `,Vm=({children:e,variant:t="neutral",size:n="md",color:o,leftIcon:r,rightIcon:i,iconColor:s="currentColor",iconSize:a="sm",...l})=>p.jsxs(Mm,{$variant:t,$size:n,$outlineColor:o,...l,children:[r&&p.jsx(U,{color:s,size:a,component:r}),e,i&&p.jsx(U,{color:s,size:a,component:i})]}),Em=g.div`
409
+ `,Em=({children:e,variant:t="neutral",size:n="md",color:o,leftIcon:r,rightIcon:i,iconColor:s="currentColor",iconSize:a="sm",...l})=>p.jsxs(Vm,{$variant:t,$size:n,$outlineColor:o,...l,children:[r&&p.jsx(U,{color:s,size:a,component:r}),e,i&&p.jsx(U,{color:s,size:a,component:i})]}),Dm=g.div`
410
410
  background-color: ${({$color:e})=>e};
411
411
  ${({$orientation:e,$length:t,$thickness:n})=>e==="horizontal"?`
412
412
  height: ${n||"1px"};
@@ -415,10 +415,10 @@
415
415
  width: ${n||"1px"};
416
416
  height: ${t||"100%"};
417
417
  `}
418
- `,Dm=({orientation:e="horizontal",color:t="var(--color-dark-300)",length:n,thickness:o,className:r=""})=>p.jsx(Em,{$orientation:e,$color:t,$length:n,$thickness:o,className:r,role:"separator","aria-orientation":e}),Fm=g.span`
418
+ `,Fm=({orientation:e="horizontal",color:t="var(--color-dark-300)",length:n,thickness:o,className:r=""})=>p.jsx(Dm,{$orientation:e,$color:t,$length:n,$thickness:o,className:r,role:"separator","aria-orientation":e}),Am=g.span`
419
419
  ${({$size:e})=>D[e]}
420
420
  color: ${({$color:e})=>e||"var(--color-main-grey)"};
421
- `,ht=({children:e,size:t=16,color:n,className:o,style:r})=>p.jsx(Fm,{$size:t,$color:n,className:o,style:r,children:e});function Am(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const Im=e=>{switch(e){case"success":return _m;case"info":return Bm;case"warning":return Nm;case"error":return zm;default:return null}},Lm=Array(12).fill(0),Rm=({visible:e,className:t})=>m.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},m.createElement("div",{className:"sonner-spinner"},Lm.map((n,o)=>m.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${o}`})))),_m=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),Nm=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),Bm=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),zm=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),Om=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},m.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),m.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),Hm=()=>{const[e,t]=m.useState(document.hidden);return m.useEffect(()=>{const n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e};let Yo=1;class jm{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const n=this.subscribers.indexOf(t);this.subscribers.splice(n,1)}),this.publish=t=>{this.subscribers.forEach(n=>n(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var n;const{message:o,...r}=t,i=typeof t?.id=="number"||((n=t.id)==null?void 0:n.length)>0?t.id:Yo++,s=this.toasts.find(l=>l.id===i),a=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(i)&&this.dismissedToasts.delete(i),s?this.toasts=this.toasts.map(l=>l.id===i?(this.publish({...l,...t,id:i,title:o}),{...l,...t,id:i,dismissible:a,title:o}):l):this.addToast({title:o,...r,dismissible:a,id:i}),i},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:t,dismiss:!0})))):this.toasts.forEach(n=>{this.subscribers.forEach(o=>o({id:n.id,dismiss:!0}))}),t),this.message=(t,n)=>this.create({...n,message:t}),this.error=(t,n)=>this.create({...n,message:t,type:"error"}),this.success=(t,n)=>this.create({...n,type:"success",message:t}),this.info=(t,n)=>this.create({...n,type:"info",message:t}),this.warning=(t,n)=>this.create({...n,type:"warning",message:t}),this.loading=(t,n)=>this.create({...n,type:"loading",message:t}),this.promise=(t,n)=>{if(!n)return;let o;n.loading!==void 0&&(o=this.create({...n,promise:t,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const r=Promise.resolve(t instanceof Function?t():t);let i=o!==void 0,s;const a=r.then(async c=>{if(s=["resolve",c],m.isValidElement(c))i=!1,this.create({id:o,type:"default",message:c});else if(Um(c)&&!c.ok){i=!1;const u=typeof n.error=="function"?await n.error(`HTTP error! status: ${c.status}`):n.error,h=typeof n.description=="function"?await n.description(`HTTP error! status: ${c.status}`):n.description,v=typeof u=="object"&&!m.isValidElement(u)?u:{message:u};this.create({id:o,type:"error",description:h,...v})}else if(c instanceof Error){i=!1;const u=typeof n.error=="function"?await n.error(c):n.error,h=typeof n.description=="function"?await n.description(c):n.description,v=typeof u=="object"&&!m.isValidElement(u)?u:{message:u};this.create({id:o,type:"error",description:h,...v})}else if(n.success!==void 0){i=!1;const u=typeof n.success=="function"?await n.success(c):n.success,h=typeof n.description=="function"?await n.description(c):n.description,v=typeof u=="object"&&!m.isValidElement(u)?u:{message:u};this.create({id:o,type:"success",description:h,...v})}}).catch(async c=>{if(s=["reject",c],n.error!==void 0){i=!1;const d=typeof n.error=="function"?await n.error(c):n.error,u=typeof n.description=="function"?await n.description(c):n.description,f=typeof d=="object"&&!m.isValidElement(d)?d:{message:d};this.create({id:o,type:"error",description:u,...f})}}).finally(()=>{i&&(this.dismiss(o),o=void 0),n.finally==null||n.finally.call(n)}),l=()=>new Promise((c,d)=>a.then(()=>s[0]==="reject"?d(s[1]):c(s[1])).catch(d));return typeof o!="string"&&typeof o!="number"?{unwrap:l}:Object.assign(o,{unwrap:l})},this.custom=(t,n)=>{const o=n?.id||Yo++;return this.create({jsx:t(o),id:o,...n}),o},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const de=new jm,Gm=(e,t)=>{const n=t?.id||Yo++;return de.addToast({title:e,...t,id:n}),n},Um=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",Km=Gm,Wm=()=>de.toasts,qm=()=>de.getActiveToasts(),Ym=Object.assign(Km,{success:de.success,info:de.info,warning:de.warning,error:de.error,custom:de.custom,message:de.message,promise:de.promise,dismiss:de.dismiss,loading:de.loading},{getHistory:Wm,getToasts:qm});Am("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function fn(e){return e.label!==void 0}const Xm=3,Zm="24px",Jm="16px",Ka=4e3,Qm=356,ep=14,tp=45,np=200;function Me(...e){return e.filter(Boolean).join(" ")}function op(e){const[t,n]=e.split("-"),o=[];return t&&o.push(t),n&&o.push(n),o}const rp=e=>{var t,n,o,r,i,s,a,l,c;const{invert:d,toast:u,unstyled:h,interacting:f,setHeights:v,visibleToasts:y,heights:b,index:w,toasts:C,expanded:x,removeToast:P,defaultRichColors:T,closeButton:k,style:V,cancelButtonStyle:$,actionButtonStyle:A,className:I="",descriptionClassName:B="",duration:H,position:M,gap:F,expandByDefault:z,classNames:N,icons:L,closeButtonAriaLabel:j="Close toast"}=e,[te,J]=m.useState(null),[ue,gt]=m.useState(null),[G,Z]=m.useState(!1),[W,ye]=m.useState(!1),[vt,q]=m.useState(!1),[yt,Tn]=m.useState(!1),[$n,wt]=m.useState(!1),[Fy,Br]=m.useState(0),[Ay,wc]=m.useState(0),Gt=m.useRef(u.duration||H||Ka),bc=m.useRef(null),Ae=m.useRef(null),Iy=w===0,Ly=w+1<=y,he=u.type,bt=u.dismissible!==!1,Ry=u.className||"",_y=u.descriptionClassName||"",Pn=m.useMemo(()=>b.findIndex(O=>O.toastId===u.id)||0,[b,u.id]),Ny=m.useMemo(()=>{var O;return(O=u.closeButton)!=null?O:k},[u.closeButton,k]),xc=m.useMemo(()=>u.duration||H||Ka,[u.duration,H]),zr=m.useRef(0),xt=m.useRef(0),Sc=m.useRef(0),St=m.useRef(null),[By,zy]=M.split("-"),Cc=m.useMemo(()=>b.reduce((O,ne,ae)=>ae>=Pn?O:O+ne.height,0),[b,Pn]),Tc=Hm(),Oy=u.invert||d,Or=he==="loading";xt.current=m.useMemo(()=>Pn*F+Cc,[Pn,Cc]),m.useEffect(()=>{Gt.current=xc},[xc]),m.useEffect(()=>{Z(!0)},[]),m.useEffect(()=>{const O=Ae.current;if(O){const ne=O.getBoundingClientRect().height;return wc(ne),v(ae=>[{toastId:u.id,height:ne,position:u.position},...ae]),()=>v(ae=>ae.filter(me=>me.toastId!==u.id))}},[v,u.id]),m.useLayoutEffect(()=>{if(!G)return;const O=Ae.current,ne=O.style.height;O.style.height="auto";const ae=O.getBoundingClientRect().height;O.style.height=ne,wc(ae),v(me=>me.find(re=>re.toastId===u.id)?me.map(re=>re.toastId===u.id?{...re,height:ae}:re):[{toastId:u.id,height:ae,position:u.position},...me])},[G,u.title,u.description,v,u.id,u.jsx,u.action,u.cancel]);const Ge=m.useCallback(()=>{ye(!0),Br(xt.current),v(O=>O.filter(ne=>ne.toastId!==u.id)),setTimeout(()=>{P(u)},np)},[u,P,v,xt]);m.useEffect(()=>{if(u.promise&&he==="loading"||u.duration===1/0||u.type==="loading")return;let O;return x||f||Tc?(()=>{if(Sc.current<zr.current){const me=new Date().getTime()-zr.current;Gt.current=Gt.current-me}Sc.current=new Date().getTime()})():Gt.current!==1/0&&(zr.current=new Date().getTime(),O=setTimeout(()=>{u.onAutoClose==null||u.onAutoClose.call(u,u),Ge()},Gt.current)),()=>clearTimeout(O)},[x,f,u,he,Tc,Ge]),m.useEffect(()=>{u.delete&&(Ge(),u.onDismiss==null||u.onDismiss.call(u,u))},[Ge,u.delete]);function Hy(){var O;if(L?.loading){var ne;return m.createElement("div",{className:Me(N?.loader,u==null||(ne=u.classNames)==null?void 0:ne.loader,"sonner-loader"),"data-visible":he==="loading"},L.loading)}return m.createElement(Rm,{className:Me(N?.loader,u==null||(O=u.classNames)==null?void 0:O.loader),visible:he==="loading"})}const jy=u.icon||L?.[he]||Im(he);var $c,Pc;return m.createElement("li",{tabIndex:0,ref:Ae,className:Me(I,Ry,N?.toast,u==null||(t=u.classNames)==null?void 0:t.toast,N?.default,N?.[he],u==null||(n=u.classNames)==null?void 0:n[he]),"data-sonner-toast":"","data-rich-colors":($c=u.richColors)!=null?$c:T,"data-styled":!(u.jsx||u.unstyled||h),"data-mounted":G,"data-promise":!!u.promise,"data-swiped":$n,"data-removed":W,"data-visible":Ly,"data-y-position":By,"data-x-position":zy,"data-index":w,"data-front":Iy,"data-swiping":vt,"data-dismissible":bt,"data-type":he,"data-invert":Oy,"data-swipe-out":yt,"data-swipe-direction":ue,"data-expanded":!!(x||z&&G),"data-testid":u.testId,style:{"--index":w,"--toasts-before":w,"--z-index":C.length-w,"--offset":`${W?Fy:xt.current}px`,"--initial-height":z?"auto":`${Ay}px`,...V,...u.style},onDragEnd:()=>{q(!1),J(null),St.current=null},onPointerDown:O=>{O.button!==2&&(Or||!bt||(bc.current=new Date,Br(xt.current),O.target.setPointerCapture(O.pointerId),O.target.tagName!=="BUTTON"&&(q(!0),St.current={x:O.clientX,y:O.clientY})))},onPointerUp:()=>{var O,ne,ae;if(yt||!bt)return;St.current=null;const me=Number(((O=Ae.current)==null?void 0:O.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),kn=Number(((ne=Ae.current)==null?void 0:ne.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),re=new Date().getTime()-((ae=bc.current)==null?void 0:ae.getTime()),we=te==="x"?me:kn,Mn=Math.abs(we)/re;if(Math.abs(we)>=tp||Mn>.11){Br(xt.current),u.onDismiss==null||u.onDismiss.call(u,u),gt(te==="x"?me>0?"right":"left":kn>0?"down":"up"),Ge(),Tn(!0);return}else{var Ce,Te;(Ce=Ae.current)==null||Ce.style.setProperty("--swipe-amount-x","0px"),(Te=Ae.current)==null||Te.style.setProperty("--swipe-amount-y","0px")}wt(!1),q(!1),J(null)},onPointerMove:O=>{var ne,ae,me;if(!St.current||!bt||((ne=window.getSelection())==null?void 0:ne.toString().length)>0)return;const re=O.clientY-St.current.y,we=O.clientX-St.current.x;var Mn;const Ce=(Mn=e.swipeDirections)!=null?Mn:op(M);!te&&(Math.abs(we)>1||Math.abs(re)>1)&&J(Math.abs(we)>Math.abs(re)?"x":"y");let Te={x:0,y:0};const kc=et=>1/(1.5+Math.abs(et)/20);if(te==="y"){if(Ce.includes("top")||Ce.includes("bottom"))if(Ce.includes("top")&&re<0||Ce.includes("bottom")&&re>0)Te.y=re;else{const et=re*kc(re);Te.y=Math.abs(et)<Math.abs(re)?et:re}}else if(te==="x"&&(Ce.includes("left")||Ce.includes("right")))if(Ce.includes("left")&&we<0||Ce.includes("right")&&we>0)Te.x=we;else{const et=we*kc(we);Te.x=Math.abs(et)<Math.abs(we)?et:we}(Math.abs(Te.x)>0||Math.abs(Te.y)>0)&&wt(!0),(ae=Ae.current)==null||ae.style.setProperty("--swipe-amount-x",`${Te.x}px`),(me=Ae.current)==null||me.style.setProperty("--swipe-amount-y",`${Te.y}px`)}},Ny&&!u.jsx&&he!=="loading"?m.createElement("button",{"aria-label":j,"data-disabled":Or,"data-close-button":!0,onClick:Or||!bt?()=>{}:()=>{Ge(),u.onDismiss==null||u.onDismiss.call(u,u)},className:Me(N?.closeButton,u==null||(o=u.classNames)==null?void 0:o.closeButton)},(Pc=L?.close)!=null?Pc:Om):null,(he||u.icon||u.promise)&&u.icon!==null&&(L?.[he]!==null||u.icon)?m.createElement("div",{"data-icon":"",className:Me(N?.icon,u==null||(r=u.classNames)==null?void 0:r.icon)},u.promise||u.type==="loading"&&!u.icon?u.icon||Hy():null,u.type!=="loading"?jy:null):null,m.createElement("div",{"data-content":"",className:Me(N?.content,u==null||(i=u.classNames)==null?void 0:i.content)},m.createElement("div",{"data-title":"",className:Me(N?.title,u==null||(s=u.classNames)==null?void 0:s.title)},u.jsx?u.jsx:typeof u.title=="function"?u.title():u.title),u.description?m.createElement("div",{"data-description":"",className:Me(B,_y,N?.description,u==null||(a=u.classNames)==null?void 0:a.description)},typeof u.description=="function"?u.description():u.description):null),m.isValidElement(u.cancel)?u.cancel:u.cancel&&fn(u.cancel)?m.createElement("button",{"data-button":!0,"data-cancel":!0,style:u.cancelButtonStyle||$,onClick:O=>{fn(u.cancel)&&bt&&(u.cancel.onClick==null||u.cancel.onClick.call(u.cancel,O),Ge())},className:Me(N?.cancelButton,u==null||(l=u.classNames)==null?void 0:l.cancelButton)},u.cancel.label):null,m.isValidElement(u.action)?u.action:u.action&&fn(u.action)?m.createElement("button",{"data-button":!0,"data-action":!0,style:u.actionButtonStyle||A,onClick:O=>{fn(u.action)&&(u.action.onClick==null||u.action.onClick.call(u.action,O),!O.defaultPrevented&&Ge())},className:Me(N?.actionButton,u==null||(c=u.classNames)==null?void 0:c.actionButton)},u.action.label):null)};function Wa(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function ip(e,t){const n={};return[e,t].forEach((o,r)=>{const i=r===1,s=i?"--mobile-offset":"--offset",a=i?Jm:Zm;function l(c){["top","right","bottom","left"].forEach(d=>{n[`${s}-${d}`]=typeof c=="number"?`${c}px`:c})}typeof o=="number"||typeof o=="string"?l(o):typeof o=="object"?["top","right","bottom","left"].forEach(c=>{o[c]===void 0?n[`${s}-${c}`]=a:n[`${s}-${c}`]=typeof o[c]=="number"?`${o[c]}px`:o[c]}):l(a)}),n}const sp=m.forwardRef(function(t,n){const{id:o,invert:r,position:i="bottom-right",hotkey:s=["altKey","KeyT"],expand:a,closeButton:l,className:c,offset:d,mobileOffset:u,theme:h="light",richColors:f,duration:v,style:y,visibleToasts:b=Xm,toastOptions:w,dir:C=Wa(),gap:x=ep,icons:P,containerAriaLabel:T="Notifications"}=t,[k,V]=m.useState([]),$=m.useMemo(()=>o?k.filter(G=>G.toasterId===o):k.filter(G=>!G.toasterId),[k,o]),A=m.useMemo(()=>Array.from(new Set([i].concat($.filter(G=>G.position).map(G=>G.position)))),[$,i]),[I,B]=m.useState([]),[H,M]=m.useState(!1),[F,z]=m.useState(!1),[N,L]=m.useState(h!=="system"?h:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),j=m.useRef(null),te=s.join("+").replace(/Key/g,"").replace(/Digit/g,""),J=m.useRef(null),ue=m.useRef(!1),gt=m.useCallback(G=>{V(Z=>{var W;return(W=Z.find(ye=>ye.id===G.id))!=null&&W.delete||de.dismiss(G.id),Z.filter(({id:ye})=>ye!==G.id)})},[]);return m.useEffect(()=>de.subscribe(G=>{if(G.dismiss){requestAnimationFrame(()=>{V(Z=>Z.map(W=>W.id===G.id?{...W,delete:!0}:W))});return}setTimeout(()=>{Vn.flushSync(()=>{V(Z=>{const W=Z.findIndex(ye=>ye.id===G.id);return W!==-1?[...Z.slice(0,W),{...Z[W],...G},...Z.slice(W+1)]:[G,...Z]})})})}),[k]),m.useEffect(()=>{if(h!=="system"){L(h);return}if(h==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?L("dark"):L("light")),typeof window>"u")return;const G=window.matchMedia("(prefers-color-scheme: dark)");try{G.addEventListener("change",({matches:Z})=>{L(Z?"dark":"light")})}catch{G.addListener(({matches:W})=>{try{L(W?"dark":"light")}catch(ye){console.error(ye)}})}},[h]),m.useEffect(()=>{k.length<=1&&M(!1)},[k]),m.useEffect(()=>{const G=Z=>{var W;if(s.every(q=>Z[q]||Z.code===q)){var vt;M(!0),(vt=j.current)==null||vt.focus()}Z.code==="Escape"&&(document.activeElement===j.current||(W=j.current)!=null&&W.contains(document.activeElement))&&M(!1)};return document.addEventListener("keydown",G),()=>document.removeEventListener("keydown",G)},[s]),m.useEffect(()=>{if(j.current)return()=>{J.current&&(J.current.focus({preventScroll:!0}),J.current=null,ue.current=!1)}},[j.current]),m.createElement("section",{ref:n,"aria-label":`${T} ${te}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},A.map((G,Z)=>{var W;const[ye,vt]=G.split("-");return $.length?m.createElement("ol",{key:G,dir:C==="auto"?Wa():C,tabIndex:-1,ref:j,className:c,"data-sonner-toaster":!0,"data-sonner-theme":N,"data-y-position":ye,"data-x-position":vt,style:{"--front-toast-height":`${((W=I[0])==null?void 0:W.height)||0}px`,"--width":`${Qm}px`,"--gap":`${x}px`,...y,...ip(d,u)},onBlur:q=>{ue.current&&!q.currentTarget.contains(q.relatedTarget)&&(ue.current=!1,J.current&&(J.current.focus({preventScroll:!0}),J.current=null))},onFocus:q=>{q.target instanceof HTMLElement&&q.target.dataset.dismissible==="false"||ue.current||(ue.current=!0,J.current=q.relatedTarget)},onMouseEnter:()=>M(!0),onMouseMove:()=>M(!0),onMouseLeave:()=>{F||M(!1)},onDragEnd:()=>M(!1),onPointerDown:q=>{q.target instanceof HTMLElement&&q.target.dataset.dismissible==="false"||z(!0)},onPointerUp:()=>z(!1)},$.filter(q=>!q.position&&Z===0||q.position===G).map((q,yt)=>{var Tn,$n;return m.createElement(rp,{key:q.id,icons:P,index:yt,toast:q,defaultRichColors:f,duration:(Tn=w?.duration)!=null?Tn:v,className:w?.className,descriptionClassName:w?.descriptionClassName,invert:r,visibleToasts:b,closeButton:($n=w?.closeButton)!=null?$n:l,interacting:F,position:G,style:w?.style,unstyled:w?.unstyled,classNames:w?.classNames,cancelButtonStyle:w?.cancelButtonStyle,actionButtonStyle:w?.actionButtonStyle,closeButtonAriaLabel:w?.closeButtonAriaLabel,removeToast:gt,toasts:$.filter(wt=>wt.position==q.position),heights:I.filter(wt=>wt.position==q.position),setHeights:B,expandByDefault:a,gap:x,expanded:H,swipeDirections:t.swipeDirections})})):null}))}),ap=({spinnerColor:e="orange",...t})=>p.jsx(sp,{position:"bottom-center",theme:"light",richColors:!0,visibleToasts:3,closeButton:!0,duration:3e3,mobileOffset:{bottom:"16px"},toastOptions:{className:"my-toast"},icons:{loading:p.jsx(dn,{color:e,size:"sm"})},...t}),lp={elevated:g.css`
421
+ `,mt=({children:e,size:t=16,color:n,className:o,style:r})=>p.jsx(Am,{$size:t,$color:n,className:o,style:r,children:e});function Im(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const Lm=e=>{switch(e){case"success":return Bm;case"info":return zm;case"warning":return Nm;case"error":return Om;default:return null}},Rm=Array(12).fill(0),_m=({visible:e,className:t})=>m.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},m.createElement("div",{className:"sonner-spinner"},Rm.map((n,o)=>m.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${o}`})))),Bm=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),Nm=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),zm=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),Om=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},m.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),Hm=m.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},m.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),m.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),jm=()=>{const[e,t]=m.useState(document.hidden);return m.useEffect(()=>{const n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e};let Xo=1;class Gm{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const n=this.subscribers.indexOf(t);this.subscribers.splice(n,1)}),this.publish=t=>{this.subscribers.forEach(n=>n(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var n;const{message:o,...r}=t,i=typeof t?.id=="number"||((n=t.id)==null?void 0:n.length)>0?t.id:Xo++,s=this.toasts.find(l=>l.id===i),a=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(i)&&this.dismissedToasts.delete(i),s?this.toasts=this.toasts.map(l=>l.id===i?(this.publish({...l,...t,id:i,title:o}),{...l,...t,id:i,dismissible:a,title:o}):l):this.addToast({title:o,...r,dismissible:a,id:i}),i},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:t,dismiss:!0})))):this.toasts.forEach(n=>{this.subscribers.forEach(o=>o({id:n.id,dismiss:!0}))}),t),this.message=(t,n)=>this.create({...n,message:t}),this.error=(t,n)=>this.create({...n,message:t,type:"error"}),this.success=(t,n)=>this.create({...n,type:"success",message:t}),this.info=(t,n)=>this.create({...n,type:"info",message:t}),this.warning=(t,n)=>this.create({...n,type:"warning",message:t}),this.loading=(t,n)=>this.create({...n,type:"loading",message:t}),this.promise=(t,n)=>{if(!n)return;let o;n.loading!==void 0&&(o=this.create({...n,promise:t,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const r=Promise.resolve(t instanceof Function?t():t);let i=o!==void 0,s;const a=r.then(async c=>{if(s=["resolve",c],m.isValidElement(c))i=!1,this.create({id:o,type:"default",message:c});else if(Wm(c)&&!c.ok){i=!1;const u=typeof n.error=="function"?await n.error(`HTTP error! status: ${c.status}`):n.error,f=typeof n.description=="function"?await n.description(`HTTP error! status: ${c.status}`):n.description,v=typeof u=="object"&&!m.isValidElement(u)?u:{message:u};this.create({id:o,type:"error",description:f,...v})}else if(c instanceof Error){i=!1;const u=typeof n.error=="function"?await n.error(c):n.error,f=typeof n.description=="function"?await n.description(c):n.description,v=typeof u=="object"&&!m.isValidElement(u)?u:{message:u};this.create({id:o,type:"error",description:f,...v})}else if(n.success!==void 0){i=!1;const u=typeof n.success=="function"?await n.success(c):n.success,f=typeof n.description=="function"?await n.description(c):n.description,v=typeof u=="object"&&!m.isValidElement(u)?u:{message:u};this.create({id:o,type:"success",description:f,...v})}}).catch(async c=>{if(s=["reject",c],n.error!==void 0){i=!1;const d=typeof n.error=="function"?await n.error(c):n.error,u=typeof n.description=="function"?await n.description(c):n.description,h=typeof d=="object"&&!m.isValidElement(d)?d:{message:d};this.create({id:o,type:"error",description:u,...h})}}).finally(()=>{i&&(this.dismiss(o),o=void 0),n.finally==null||n.finally.call(n)}),l=()=>new Promise((c,d)=>a.then(()=>s[0]==="reject"?d(s[1]):c(s[1])).catch(d));return typeof o!="string"&&typeof o!="number"?{unwrap:l}:Object.assign(o,{unwrap:l})},this.custom=(t,n)=>{const o=n?.id||Xo++;return this.create({jsx:t(o),id:o,...n}),o},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const de=new Gm,Um=(e,t)=>{const n=t?.id||Xo++;return de.addToast({title:e,...t,id:n}),n},Wm=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",Km=Um,qm=()=>de.toasts,Ym=()=>de.getActiveToasts(),Xm=Object.assign(Km,{success:de.success,info:de.info,warning:de.warning,error:de.error,custom:de.custom,message:de.message,promise:de.promise,dismiss:de.dismiss,loading:de.loading},{getHistory:qm,getToasts:Ym});Im("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function hn(e){return e.label!==void 0}const Zm=3,Jm="24px",Qm="16px",qa=4e3,ep=356,tp=14,np=45,op=200;function Me(...e){return e.filter(Boolean).join(" ")}function rp(e){const[t,n]=e.split("-"),o=[];return t&&o.push(t),n&&o.push(n),o}const ip=e=>{var t,n,o,r,i,s,a,l,c;const{invert:d,toast:u,unstyled:f,interacting:h,setHeights:v,visibleToasts:y,heights:b,index:w,toasts:S,expanded:x,removeToast:P,defaultRichColors:T,closeButton:k,style:V,cancelButtonStyle:$,actionButtonStyle:A,className:I="",descriptionClassName:N="",duration:H,position:M,gap:F,expandByDefault:z,classNames:B,icons:L,closeButtonAriaLabel:j="Close toast"}=e,[te,J]=m.useState(null),[ue,vt]=m.useState(null),[G,Z]=m.useState(!1),[K,ye]=m.useState(!1),[yt,q]=m.useState(!1),[wt,$n]=m.useState(!1),[Pn,bt]=m.useState(!1),[Iy,Or]=m.useState(0),[Ly,bc]=m.useState(0),Ut=m.useRef(u.duration||H||qa),xc=m.useRef(null),Ae=m.useRef(null),Ry=w===0,_y=w+1<=y,he=u.type,xt=u.dismissible!==!1,By=u.className||"",Ny=u.descriptionClassName||"",kn=m.useMemo(()=>b.findIndex(O=>O.toastId===u.id)||0,[b,u.id]),zy=m.useMemo(()=>{var O;return(O=u.closeButton)!=null?O:k},[u.closeButton,k]),Sc=m.useMemo(()=>u.duration||H||qa,[u.duration,H]),Hr=m.useRef(0),St=m.useRef(0),Cc=m.useRef(0),Ct=m.useRef(null),[Oy,Hy]=M.split("-"),Tc=m.useMemo(()=>b.reduce((O,ne,ae)=>ae>=kn?O:O+ne.height,0),[b,kn]),$c=jm(),jy=u.invert||d,jr=he==="loading";St.current=m.useMemo(()=>kn*F+Tc,[kn,Tc]),m.useEffect(()=>{Ut.current=Sc},[Sc]),m.useEffect(()=>{Z(!0)},[]),m.useEffect(()=>{const O=Ae.current;if(O){const ne=O.getBoundingClientRect().height;return bc(ne),v(ae=>[{toastId:u.id,height:ne,position:u.position},...ae]),()=>v(ae=>ae.filter(me=>me.toastId!==u.id))}},[v,u.id]),m.useLayoutEffect(()=>{if(!G)return;const O=Ae.current,ne=O.style.height;O.style.height="auto";const ae=O.getBoundingClientRect().height;O.style.height=ne,bc(ae),v(me=>me.find(re=>re.toastId===u.id)?me.map(re=>re.toastId===u.id?{...re,height:ae}:re):[{toastId:u.id,height:ae,position:u.position},...me])},[G,u.title,u.description,v,u.id,u.jsx,u.action,u.cancel]);const Ge=m.useCallback(()=>{ye(!0),Or(St.current),v(O=>O.filter(ne=>ne.toastId!==u.id)),setTimeout(()=>{P(u)},op)},[u,P,v,St]);m.useEffect(()=>{if(u.promise&&he==="loading"||u.duration===1/0||u.type==="loading")return;let O;return x||h||$c?(()=>{if(Cc.current<Hr.current){const me=new Date().getTime()-Hr.current;Ut.current=Ut.current-me}Cc.current=new Date().getTime()})():Ut.current!==1/0&&(Hr.current=new Date().getTime(),O=setTimeout(()=>{u.onAutoClose==null||u.onAutoClose.call(u,u),Ge()},Ut.current)),()=>clearTimeout(O)},[x,h,u,he,$c,Ge]),m.useEffect(()=>{u.delete&&(Ge(),u.onDismiss==null||u.onDismiss.call(u,u))},[Ge,u.delete]);function Gy(){var O;if(L?.loading){var ne;return m.createElement("div",{className:Me(B?.loader,u==null||(ne=u.classNames)==null?void 0:ne.loader,"sonner-loader"),"data-visible":he==="loading"},L.loading)}return m.createElement(_m,{className:Me(B?.loader,u==null||(O=u.classNames)==null?void 0:O.loader),visible:he==="loading"})}const Uy=u.icon||L?.[he]||Lm(he);var Pc,kc;return m.createElement("li",{tabIndex:0,ref:Ae,className:Me(I,By,B?.toast,u==null||(t=u.classNames)==null?void 0:t.toast,B?.default,B?.[he],u==null||(n=u.classNames)==null?void 0:n[he]),"data-sonner-toast":"","data-rich-colors":(Pc=u.richColors)!=null?Pc:T,"data-styled":!(u.jsx||u.unstyled||f),"data-mounted":G,"data-promise":!!u.promise,"data-swiped":Pn,"data-removed":K,"data-visible":_y,"data-y-position":Oy,"data-x-position":Hy,"data-index":w,"data-front":Ry,"data-swiping":yt,"data-dismissible":xt,"data-type":he,"data-invert":jy,"data-swipe-out":wt,"data-swipe-direction":ue,"data-expanded":!!(x||z&&G),"data-testid":u.testId,style:{"--index":w,"--toasts-before":w,"--z-index":S.length-w,"--offset":`${K?Iy:St.current}px`,"--initial-height":z?"auto":`${Ly}px`,...V,...u.style},onDragEnd:()=>{q(!1),J(null),Ct.current=null},onPointerDown:O=>{O.button!==2&&(jr||!xt||(xc.current=new Date,Or(St.current),O.target.setPointerCapture(O.pointerId),O.target.tagName!=="BUTTON"&&(q(!0),Ct.current={x:O.clientX,y:O.clientY})))},onPointerUp:()=>{var O,ne,ae;if(wt||!xt)return;Ct.current=null;const me=Number(((O=Ae.current)==null?void 0:O.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Mn=Number(((ne=Ae.current)==null?void 0:ne.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),re=new Date().getTime()-((ae=xc.current)==null?void 0:ae.getTime()),we=te==="x"?me:Mn,Vn=Math.abs(we)/re;if(Math.abs(we)>=np||Vn>.11){Or(St.current),u.onDismiss==null||u.onDismiss.call(u,u),vt(te==="x"?me>0?"right":"left":Mn>0?"down":"up"),Ge(),$n(!0);return}else{var Ce,Te;(Ce=Ae.current)==null||Ce.style.setProperty("--swipe-amount-x","0px"),(Te=Ae.current)==null||Te.style.setProperty("--swipe-amount-y","0px")}bt(!1),q(!1),J(null)},onPointerMove:O=>{var ne,ae,me;if(!Ct.current||!xt||((ne=window.getSelection())==null?void 0:ne.toString().length)>0)return;const re=O.clientY-Ct.current.y,we=O.clientX-Ct.current.x;var Vn;const Ce=(Vn=e.swipeDirections)!=null?Vn:rp(M);!te&&(Math.abs(we)>1||Math.abs(re)>1)&&J(Math.abs(we)>Math.abs(re)?"x":"y");let Te={x:0,y:0};const Mc=tt=>1/(1.5+Math.abs(tt)/20);if(te==="y"){if(Ce.includes("top")||Ce.includes("bottom"))if(Ce.includes("top")&&re<0||Ce.includes("bottom")&&re>0)Te.y=re;else{const tt=re*Mc(re);Te.y=Math.abs(tt)<Math.abs(re)?tt:re}}else if(te==="x"&&(Ce.includes("left")||Ce.includes("right")))if(Ce.includes("left")&&we<0||Ce.includes("right")&&we>0)Te.x=we;else{const tt=we*Mc(we);Te.x=Math.abs(tt)<Math.abs(we)?tt:we}(Math.abs(Te.x)>0||Math.abs(Te.y)>0)&&bt(!0),(ae=Ae.current)==null||ae.style.setProperty("--swipe-amount-x",`${Te.x}px`),(me=Ae.current)==null||me.style.setProperty("--swipe-amount-y",`${Te.y}px`)}},zy&&!u.jsx&&he!=="loading"?m.createElement("button",{"aria-label":j,"data-disabled":jr,"data-close-button":!0,onClick:jr||!xt?()=>{}:()=>{Ge(),u.onDismiss==null||u.onDismiss.call(u,u)},className:Me(B?.closeButton,u==null||(o=u.classNames)==null?void 0:o.closeButton)},(kc=L?.close)!=null?kc:Hm):null,(he||u.icon||u.promise)&&u.icon!==null&&(L?.[he]!==null||u.icon)?m.createElement("div",{"data-icon":"",className:Me(B?.icon,u==null||(r=u.classNames)==null?void 0:r.icon)},u.promise||u.type==="loading"&&!u.icon?u.icon||Gy():null,u.type!=="loading"?Uy:null):null,m.createElement("div",{"data-content":"",className:Me(B?.content,u==null||(i=u.classNames)==null?void 0:i.content)},m.createElement("div",{"data-title":"",className:Me(B?.title,u==null||(s=u.classNames)==null?void 0:s.title)},u.jsx?u.jsx:typeof u.title=="function"?u.title():u.title),u.description?m.createElement("div",{"data-description":"",className:Me(N,Ny,B?.description,u==null||(a=u.classNames)==null?void 0:a.description)},typeof u.description=="function"?u.description():u.description):null),m.isValidElement(u.cancel)?u.cancel:u.cancel&&hn(u.cancel)?m.createElement("button",{"data-button":!0,"data-cancel":!0,style:u.cancelButtonStyle||$,onClick:O=>{hn(u.cancel)&&xt&&(u.cancel.onClick==null||u.cancel.onClick.call(u.cancel,O),Ge())},className:Me(B?.cancelButton,u==null||(l=u.classNames)==null?void 0:l.cancelButton)},u.cancel.label):null,m.isValidElement(u.action)?u.action:u.action&&hn(u.action)?m.createElement("button",{"data-button":!0,"data-action":!0,style:u.actionButtonStyle||A,onClick:O=>{hn(u.action)&&(u.action.onClick==null||u.action.onClick.call(u.action,O),!O.defaultPrevented&&Ge())},className:Me(B?.actionButton,u==null||(c=u.classNames)==null?void 0:c.actionButton)},u.action.label):null)};function Ya(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function sp(e,t){const n={};return[e,t].forEach((o,r)=>{const i=r===1,s=i?"--mobile-offset":"--offset",a=i?Qm:Jm;function l(c){["top","right","bottom","left"].forEach(d=>{n[`${s}-${d}`]=typeof c=="number"?`${c}px`:c})}typeof o=="number"||typeof o=="string"?l(o):typeof o=="object"?["top","right","bottom","left"].forEach(c=>{o[c]===void 0?n[`${s}-${c}`]=a:n[`${s}-${c}`]=typeof o[c]=="number"?`${o[c]}px`:o[c]}):l(a)}),n}const ap=m.forwardRef(function(t,n){const{id:o,invert:r,position:i="bottom-right",hotkey:s=["altKey","KeyT"],expand:a,closeButton:l,className:c,offset:d,mobileOffset:u,theme:f="light",richColors:h,duration:v,style:y,visibleToasts:b=Zm,toastOptions:w,dir:S=Ya(),gap:x=tp,icons:P,containerAriaLabel:T="Notifications"}=t,[k,V]=m.useState([]),$=m.useMemo(()=>o?k.filter(G=>G.toasterId===o):k.filter(G=>!G.toasterId),[k,o]),A=m.useMemo(()=>Array.from(new Set([i].concat($.filter(G=>G.position).map(G=>G.position)))),[$,i]),[I,N]=m.useState([]),[H,M]=m.useState(!1),[F,z]=m.useState(!1),[B,L]=m.useState(f!=="system"?f:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),j=m.useRef(null),te=s.join("+").replace(/Key/g,"").replace(/Digit/g,""),J=m.useRef(null),ue=m.useRef(!1),vt=m.useCallback(G=>{V(Z=>{var K;return(K=Z.find(ye=>ye.id===G.id))!=null&&K.delete||de.dismiss(G.id),Z.filter(({id:ye})=>ye!==G.id)})},[]);return m.useEffect(()=>de.subscribe(G=>{if(G.dismiss){requestAnimationFrame(()=>{V(Z=>Z.map(K=>K.id===G.id?{...K,delete:!0}:K))});return}setTimeout(()=>{En.flushSync(()=>{V(Z=>{const K=Z.findIndex(ye=>ye.id===G.id);return K!==-1?[...Z.slice(0,K),{...Z[K],...G},...Z.slice(K+1)]:[G,...Z]})})})}),[k]),m.useEffect(()=>{if(f!=="system"){L(f);return}if(f==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?L("dark"):L("light")),typeof window>"u")return;const G=window.matchMedia("(prefers-color-scheme: dark)");try{G.addEventListener("change",({matches:Z})=>{L(Z?"dark":"light")})}catch{G.addListener(({matches:K})=>{try{L(K?"dark":"light")}catch(ye){console.error(ye)}})}},[f]),m.useEffect(()=>{k.length<=1&&M(!1)},[k]),m.useEffect(()=>{const G=Z=>{var K;if(s.every(q=>Z[q]||Z.code===q)){var yt;M(!0),(yt=j.current)==null||yt.focus()}Z.code==="Escape"&&(document.activeElement===j.current||(K=j.current)!=null&&K.contains(document.activeElement))&&M(!1)};return document.addEventListener("keydown",G),()=>document.removeEventListener("keydown",G)},[s]),m.useEffect(()=>{if(j.current)return()=>{J.current&&(J.current.focus({preventScroll:!0}),J.current=null,ue.current=!1)}},[j.current]),m.createElement("section",{ref:n,"aria-label":`${T} ${te}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},A.map((G,Z)=>{var K;const[ye,yt]=G.split("-");return $.length?m.createElement("ol",{key:G,dir:S==="auto"?Ya():S,tabIndex:-1,ref:j,className:c,"data-sonner-toaster":!0,"data-sonner-theme":B,"data-y-position":ye,"data-x-position":yt,style:{"--front-toast-height":`${((K=I[0])==null?void 0:K.height)||0}px`,"--width":`${ep}px`,"--gap":`${x}px`,...y,...sp(d,u)},onBlur:q=>{ue.current&&!q.currentTarget.contains(q.relatedTarget)&&(ue.current=!1,J.current&&(J.current.focus({preventScroll:!0}),J.current=null))},onFocus:q=>{q.target instanceof HTMLElement&&q.target.dataset.dismissible==="false"||ue.current||(ue.current=!0,J.current=q.relatedTarget)},onMouseEnter:()=>M(!0),onMouseMove:()=>M(!0),onMouseLeave:()=>{F||M(!1)},onDragEnd:()=>M(!1),onPointerDown:q=>{q.target instanceof HTMLElement&&q.target.dataset.dismissible==="false"||z(!0)},onPointerUp:()=>z(!1)},$.filter(q=>!q.position&&Z===0||q.position===G).map((q,wt)=>{var $n,Pn;return m.createElement(ip,{key:q.id,icons:P,index:wt,toast:q,defaultRichColors:h,duration:($n=w?.duration)!=null?$n:v,className:w?.className,descriptionClassName:w?.descriptionClassName,invert:r,visibleToasts:b,closeButton:(Pn=w?.closeButton)!=null?Pn:l,interacting:F,position:G,style:w?.style,unstyled:w?.unstyled,classNames:w?.classNames,cancelButtonStyle:w?.cancelButtonStyle,actionButtonStyle:w?.actionButtonStyle,closeButtonAriaLabel:w?.closeButtonAriaLabel,removeToast:vt,toasts:$.filter(bt=>bt.position==q.position),heights:I.filter(bt=>bt.position==q.position),setHeights:N,expandByDefault:a,gap:x,expanded:H,swipeDirections:t.swipeDirections})})):null}))}),lp=({spinnerColor:e="orange",...t})=>p.jsx(ap,{position:"bottom-center",theme:"light",richColors:!0,visibleToasts:3,closeButton:!0,duration:3e3,mobileOffset:{bottom:"16px"},toastOptions:{className:"my-toast"},icons:{loading:p.jsx(fn,{color:e,size:"sm"})},...t}),cp={elevated:g.css`
422
422
  background-color: var(--color-main-white);
423
423
  box-shadow: var(--shadow-black-card);
424
424
  border: none;
@@ -434,7 +434,7 @@
434
434
  background-color: var(--color-main-white);
435
435
  box-shadow: none;
436
436
  border: none;
437
- `},cp={sm:g.css`
437
+ `},up={sm:g.css`
438
438
  padding: 0.75rem;
439
439
  gap: 0.5rem;
440
440
  `,md:g.css`
@@ -443,27 +443,41 @@
443
443
  `,lg:g.css`
444
444
  padding: 1.25rem;
445
445
  gap: 0.5rem;
446
- `},up=g.css`
446
+ `},dp=g.css`
447
+ position: relative;
447
448
  transition:
448
- box-shadow 0.3s ease-out,
449
- background-color 0.3s ease-out,
450
- outline-color 0.3s ease-out;
451
- border-bottom: 2px solid transparent;
449
+ transform 0.2s cubic-bezier(0.4, 0, 0.2, 1),
450
+ box-shadow 0.2s cubic-bezier(0.4, 0, 0.2, 1),
451
+ background-color 0.2s ease-out;
452
+ cursor: pointer;
453
+
454
+ &::after {
455
+ content: '';
456
+ position: absolute;
457
+ inset: 0;
458
+ border-radius: inherit;
459
+ border: 2px solid var(--color-main-blue-primary);
460
+ opacity: 0;
461
+ transition: opacity 0.2s ease-out;
462
+ }
452
463
 
453
464
  &:hover {
454
- cursor: pointer;
455
- box-shadow: var(--shadow-hover-black-card);
456
- background-color: var(--color-main-alternative-secondary);
465
+ transform: translateY(-2px);
466
+ box-shadow:
467
+ 0 8px 16px rgba(0, 0, 0, 0.08),
468
+ 0 2px 4px rgba(0, 0, 0, 0.04);
457
469
  }
458
470
 
459
471
  &:active {
460
- border-bottom: 2px solid var(--color-main-blue-primary);
472
+ transform: translateY(0);
473
+ transition-duration: 0.1s;
461
474
  }
462
475
 
463
- &:focus-visible {
464
- outline-color: var(--color-main-blue-primary);
476
+ &:focus-visible::after {
477
+ opacity: 1;
478
+ outline: none;
465
479
  }
466
- `,dp=g.css`
480
+ `,fp=g.css`
467
481
  opacity: 0.6;
468
482
  cursor: not-allowed;
469
483
  pointer-events: none;
@@ -472,7 +486,7 @@
472
486
  transform: none;
473
487
  box-shadow: inherit;
474
488
  }
475
- `,fp=g.div`
489
+ `,hp=g.div`
476
490
  display: flex;
477
491
  flex-direction: column;
478
492
  border-radius: var(--border-radius-card);
@@ -480,11 +494,12 @@
480
494
  height: fit-content;
481
495
  outline: 2px solid transparent;
482
496
  outline-offset: -1px;
483
- ${({$variant:e})=>lp[e]}
484
- ${({$clickable:e})=>e&&up}
485
- ${({$disabled:e})=>e&&dp}
486
- ${({$size:e})=>cp[e]}
487
- `,hp=({variant:e="elevated",size:t="md",disabled:n=!1,onClick:o=void 0,children:r,...i})=>{const s=a=>{n||o&&o(a)};return p.jsx(fp,{$variant:e,$size:t,$disabled:n,$clickable:!!o,onClick:s,role:o?"button":void 0,tabIndex:o&&!n?0:void 0,onKeyDown:o&&!n?a=>{(a.key==="Enter"||a.key===" ")&&(a.preventDefault(),s(a))}:void 0,...i,children:r})},mp=g.div`
497
+
498
+ ${({$variant:e})=>cp[e]}
499
+ ${({$clickable:e})=>e&&dp}
500
+ ${({$disabled:e})=>e&&fp}
501
+ ${({$size:e})=>up[e]}
502
+ `,mp=({variant:e="elevated",size:t="md",disabled:n=!1,onClick:o=void 0,children:r,...i})=>{const s=a=>{n||o&&o(a)};return p.jsx(hp,{$variant:e,$size:t,$disabled:n,$clickable:!!o,onClick:s,role:o?"button":void 0,tabIndex:o&&!n?0:void 0,onKeyDown:o&&!n?a=>{(a.key==="Enter"||a.key===" ")&&(a.preventDefault(),s(a))}:void 0,...i,children:r})},pp=g.div`
488
503
  display: flex;
489
504
  align-items: center;
490
505
  align-self: stretch;
@@ -494,16 +509,16 @@
494
509
  border-bottom: 1px solid var(--color-divider);
495
510
  padding-bottom: 0.5rem;
496
511
  `}
497
- `,pp=({children:e,showDivider:t=!1,...n})=>p.jsx(mp,{$showDivider:t,...n,children:e}),gp=g.div`
512
+ `,gp=({children:e,showDivider:t=!1,...n})=>p.jsx(pp,{$showDivider:t,...n,children:e}),vp=g.div`
498
513
  flex: 1;
499
514
  display: flex;
500
515
  flex-direction: column;
501
- `,vp=({children:e,showDivider:t=!1,...n})=>p.jsx(gp,{$showDivider:t,...n,children:e}),yp=g.div`
516
+ `,yp=({children:e,showDivider:t=!1,...n})=>p.jsx(vp,{$showDivider:t,...n,children:e}),wp=g.div`
502
517
  display: flex;
503
518
  align-items: center;
504
519
  align-self: stretch;
505
520
  gap: 0.5rem;
506
- `,wp=({children:e,...t})=>p.jsx(yp,{...t,children:e}),bp={xs:g.css`
521
+ `,bp=({children:e,...t})=>p.jsx(wp,{...t,children:e}),xp={xs:g.css`
507
522
  ${D[12]}
508
523
  `,sm:g.css`
509
524
  ${D[12]}
@@ -511,15 +526,15 @@
511
526
  ${D[16]}
512
527
  `,lg:g.css`
513
528
  ${D[18]}
514
- `},xp=g.div`
529
+ `},Sp=g.div`
515
530
  color: var(--color-main-warning-state);
516
- ${({$size:e})=>bp[e]}
531
+ ${({$size:e})=>xp[e]}
517
532
  font-weight: 400;
518
533
  margin-top: 0.25rem;
519
534
  display: flex;
520
535
  align-items: flex-start;
521
536
  gap: 0.25rem;
522
- `,Xo=({children:e,className:t,size:n="md",...o})=>p.jsx(xp,{className:t,$size:n,...o,children:e}),Sp={xs:g.css`
537
+ `,Zo=({children:e,className:t,size:n="md",...o})=>p.jsx(Sp,{className:t,$size:n,...o,children:e}),Cp={xs:g.css`
523
538
  ${D[14]}
524
539
  `,sm:g.css`
525
540
  ${D[16]}
@@ -527,15 +542,15 @@
527
542
  ${D[24]}
528
543
  `,lg:g.css`
529
544
  ${D[30]}
530
- `},Cp=g.label`
545
+ `},Tp=g.label`
531
546
  color: var(--color-main-blue-primary);
532
- ${({$size:e})=>Sp[e]}
533
- ${({$disabled:e})=>e&&Tp}
547
+ ${({$size:e})=>Cp[e]}
548
+ ${({$disabled:e})=>e&&$p}
534
549
  cursor: ${({$disabled:e,$htmlFor:t})=>e||!t?"default":"pointer"};
535
- `,Tp=g.css`
550
+ `,$p=g.css`
536
551
  cursor: not-allowed;
537
552
  opacity: 0.6;
538
- `,hn=({children:e,htmlFor:t,className:n,required:o,disabled:r=!1,size:i="md",...s})=>p.jsxs(Cp,{className:n,htmlFor:t,$htmlFor:t,$size:i,$disabled:r,...s,children:[e,o&&p.jsx("span",{style:{color:"var(--color-main-warning-state)"},children:"*"})]}),qa=["text","email","password","number","tel","url","date","datetime-local","time","search","textarea","select","checkbox","radio","pin"],Ya=e=>qa.includes(e),ze=e=>e.map(t=>({name:t.name||"",label:t.label||"",type:t.type&&Ya(t.type)?t.type:"text",placeholder:t.placeholder,required:t.required||!1,disabled:t.disabled||!1,options:t.options||[],validation:t.validation,checkboxLabel:t.checkboxLabel,radioName:t.radioName,pinLength:t.pinLength||6,pinType:t.pinType||"number",rows:t.rows||4,size:t.size||"md",inputClassName:t.inputClassName,labelClassName:t.labelClassName,messageErrorClassName:t.messageErrorClassName})),$p=e=>e.map(t=>({value:t.value,label:t.label})),Pp={text:(e,t,n)=>ze([{name:e,label:t,type:"text",...n}])[0],email:(e,t,n)=>ze([{name:e,label:t,type:"email",required:!0,...n}])[0],password:(e,t,n)=>ze([{name:e,label:t,type:"password",required:!0,validation:{pattern:"^(?=.*[a-z])(?=.*[A-Z])(?=.*\\d)[a-zA-Z\\d@$!%*?&]{8,}$",custom:o=>{if(o&&o.length<8)return"Password must be at least 8 characters long"}},...n}])[0],select:(e,t,n,o)=>ze([{name:e,label:t,type:"select",options:n,required:!0,...o}])[0],checkbox:(e,t,n)=>ze([{name:e,label:t,type:"checkbox",checkboxLabel:t,...n}])[0],radio:(e,t,n,o)=>ze([{name:e,label:t,type:"radio",options:n,radioName:e,required:!0,...o}])[0],pin:(e,t,n=6,o)=>ze([{name:e,label:t,type:"pin",pinLength:n,pinType:"number",required:!0,validation:{custom:r=>{if(r&&r.length!==n)return`${t} must be ${n} digits long`}},...o}])[0]},kp=(e,t,n,o,r,i,s,a)=>{const{field:l,...c}=t,d={...l,...c,size:c.size,hasError:c.hasError,disabled:c.disabled,placeholder:c.placeholder,className:c.className};switch(e){case"textarea":return{component:"textarea",props:{...d,rows:s?.rows||4}};case"select":return{component:"select",props:{...d,options:n?.options||[],onOptionSelect:n?.onOptionSelect,placeholder:t.placeholder||"Selecciona una opción"}};case"checkbox":return{component:"checkbox",props:{...d,label:o?.checkboxLabel||o?.label,checked:t.field.value||o?.checked||!1}};case"radio":return{component:"radio",props:{...d,options:r?.options||[],radioName:r?.radioName||t.name,onRadioChange:r?.onRadioChange}};case"pin":return{component:"pin",props:{...d,length:i?.pinLength||6,type:i?.pinType||"number",onComplete:i?.onPinComplete}};case"password":return{component:"password",props:{...d,type:"password"}};case"search":return{component:"search",props:{...d,onSearch:a?.onSearch}};default:return{component:"base",props:{...d,type:t.type||e||"text"}}}},Ze=g.css`
553
+ `,mn=({children:e,htmlFor:t,className:n,required:o,disabled:r=!1,size:i="md",...s})=>p.jsxs(Tp,{className:n,htmlFor:t,$htmlFor:t,$size:i,$disabled:r,...s,children:[e,o&&p.jsx("span",{style:{color:"var(--color-main-warning-state)"},children:"*"})]}),Xa=["text","email","password","number","tel","url","date","datetime-local","time","search","textarea","select","checkbox","radio","pin"],Za=e=>Xa.includes(e),ze=e=>e.map(t=>({name:t.name||"",label:t.label||"",type:t.type&&Za(t.type)?t.type:"text",placeholder:t.placeholder,required:t.required||!1,disabled:t.disabled||!1,options:t.options||[],validation:t.validation,checkboxLabel:t.checkboxLabel,radioName:t.radioName,pinLength:t.pinLength||6,pinType:t.pinType||"number",rows:t.rows||4,size:t.size||"md",inputClassName:t.inputClassName,labelClassName:t.labelClassName,messageErrorClassName:t.messageErrorClassName})),Pp=e=>e.map(t=>({value:t.value,label:t.label})),kp={text:(e,t,n)=>ze([{name:e,label:t,type:"text",...n}])[0],email:(e,t,n)=>ze([{name:e,label:t,type:"email",required:!0,...n}])[0],password:(e,t,n)=>ze([{name:e,label:t,type:"password",required:!0,validation:{pattern:"^(?=.*[a-z])(?=.*[A-Z])(?=.*\\d)[a-zA-Z\\d@$!%*?&]{8,}$",custom:o=>{if(o&&o.length<8)return"Password must be at least 8 characters long"}},...n}])[0],select:(e,t,n,o)=>ze([{name:e,label:t,type:"select",options:n,required:!0,...o}])[0],checkbox:(e,t,n)=>ze([{name:e,label:t,type:"checkbox",checkboxLabel:t,...n}])[0],radio:(e,t,n,o)=>ze([{name:e,label:t,type:"radio",options:n,radioName:e,required:!0,...o}])[0],pin:(e,t,n=6,o)=>ze([{name:e,label:t,type:"pin",pinLength:n,pinType:"number",required:!0,validation:{custom:r=>{if(r&&r.length!==n)return`${t} must be ${n} digits long`}},...o}])[0]},Mp=(e,t,n,o,r,i,s,a)=>{const{field:l,...c}=t,d={...l,...c,size:c.size,hasError:c.hasError,disabled:c.disabled,placeholder:c.placeholder,className:c.className};switch(e){case"textarea":return{component:"textarea",props:{...d,rows:s?.rows||4}};case"select":return{component:"select",props:{...d,options:n?.options||[],onOptionSelect:n?.onOptionSelect,placeholder:t.placeholder||"Selecciona una opción"}};case"checkbox":return{component:"checkbox",props:{...d,label:o?.checkboxLabel||o?.label,checked:t.field.value||o?.checked||!1}};case"radio":return{component:"radio",props:{...d,options:r?.options||[],radioName:r?.radioName||t.name,onRadioChange:r?.onRadioChange}};case"pin":return{component:"pin",props:{...d,length:i?.pinLength||6,type:i?.pinType||"number",onComplete:i?.onPinComplete}};case"password":return{component:"password",props:{...d,type:"password"}};case"search":return{component:"search",props:{...d,onSearch:a?.onSearch}};default:return{component:"base",props:{...d,type:t.type||e||"text"}}}},Ze=g.css`
539
554
  display: flex;
540
555
  justify-content: space-between;
541
556
  align-items: center;
@@ -565,7 +580,7 @@
565
580
  &:disabled {
566
581
  cursor: not-allowed;
567
582
  }
568
- `,mn=g.css`
583
+ `,pn=g.css`
569
584
  width: 100%;
570
585
  border: none;
571
586
  outline: none;
@@ -593,7 +608,7 @@
593
608
  border: var(--border-input-disabled) !important;
594
609
  cursor: not-allowed;
595
610
  opacity: 0.6;
596
- `,Xa=g.css`
611
+ `,Ja=g.css`
597
612
  border: none;
598
613
  border-top: 0;
599
614
  border-right: 0;
@@ -619,61 +634,61 @@
619
634
  border-bottom: var(--border-input-focus);
620
635
  outline: none;
621
636
  }
622
- `,Bt={xs:g.css`
637
+ `,zt={xs:g.css`
623
638
  padding: 0.375rem 0.75rem;
624
- height: 2rem;
625
- ${D[16]}
639
+ height: 1.875rem;
640
+ ${D[14]}
626
641
  `,sm:g.css`
627
642
  padding: 0.5rem 1rem;
628
- height: 2.5rem;
629
- ${D[18]}
643
+ height: 2.25rem;
644
+ ${D[14]}
630
645
  `,md:g.css`
631
646
  padding: 0.5rem 1rem;
632
- height: 2.75rem;
633
- ${D[20]}
647
+ height: 2.625rem;
648
+ ${D[16]}
634
649
  `,lg:g.css`
635
650
  padding: 0.5rem 1rem;
636
651
  height: 3rem;
637
- ${D[20]}
638
- `},pn=g.css`
652
+ ${D[18]}
653
+ `},gn=g.css`
639
654
  display: flex;
640
655
  align-items: center;
641
656
  justify-content: center;
642
657
  flex-shrink: 0;
643
658
  user-select: none;
644
- `,Mp=g.div`
659
+ `,Vp=g.div`
645
660
  ${Ze}
646
- ${({$size:e})=>Bt[e]}
661
+ ${({$size:e})=>zt[e]}
647
662
  ${({$hasError:e})=>e&&Je}
648
663
  ${({$disabled:e})=>e&&Oe}
649
- ${({$isFlushed:e})=>e&&Xa}
650
- `,Vp=g.input`
651
- ${mn}
652
- `,Zo=m.forwardRef(({size:e="md",hasError:t=!1,disabled:n=!1,type:o="text",flushed:r=!1,leftIcon:i,rightIcon:s,iconSize:a="md",iconColor:l="currentColor",className:c,...d},u)=>p.jsxs(Mp,{$size:e,$hasError:t,className:c,$isFlushed:r,children:[i&&p.jsx(U,{component:i,size:a,color:n?"var(--color-dark-200)":l}),p.jsx(Vp,{ref:u,type:o,$hasError:t,disabled:n,...d}),s&&p.jsx(U,{component:s,size:a,color:n?"var(--color-dark-200)":l})]}));Zo.displayName="BaseInput";const Ep=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M13.0001 16.1716L18.3641 10.8076L19.7783 12.2218L12.0001 20L4.22192 12.2218L5.63614 10.8076L11.0001 16.1716V4H13.0001V16.1716Z"})),Za=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M11.9999 13.1714L16.9497 8.22168L18.3639 9.63589L11.9999 15.9999L5.63599 9.63589L7.0502 8.22168L11.9999 13.1714Z"})),Dp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M13.1717 12.0007L8.22192 7.05093L9.63614 5.63672L16.0001 12.0007L9.63614 18.3646L8.22192 16.9504L13.1717 12.0007Z"})),Fp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M11.9498 7.94975L10.5356 9.36396L8.00079 6.828L8.00004 20H6.00004L6.00079 6.828L3.46451 9.36396L2.05029 7.94975L7.00004 3L11.9498 7.94975ZM21.9498 16.0503L17 21L12.0503 16.0503L13.4645 14.636L16.0008 17.172L16 4H18L18.0008 17.172L20.5356 14.636L21.9498 16.0503Z"})),Ja=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M11.9997 10.5865L16.9495 5.63672L18.3637 7.05093L13.4139 12.0007L18.3637 16.9504L16.9495 18.3646L11.9997 13.4149L7.04996 18.3646L5.63574 16.9504L10.5855 12.0007L5.63574 7.05093L7.04996 5.63672L11.9997 10.5865Z"})),Ap=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M10 6V8H5V19H16V14H18V20C18 20.5523 17.5523 21 17 21H4C3.44772 21 3 20.5523 3 20V7C3 6.44772 3.44772 6 4 6H10ZM21 3V11H19L18.9999 6.413L11.2071 14.2071L9.79289 12.7929L17.5849 5H13V3H21Z"})),Ip=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M12.0003 3C17.3924 3 21.8784 6.87976 22.8189 12C21.8784 17.1202 17.3924 21 12.0003 21C6.60812 21 2.12215 17.1202 1.18164 12C2.12215 6.87976 6.60812 3 12.0003 3ZM12.0003 19C16.2359 19 19.8603 16.052 20.7777 12C19.8603 7.94803 16.2359 5 12.0003 5C7.7646 5 4.14022 7.94803 3.22278 12C4.14022 16.052 7.7646 19 12.0003 19ZM12.0003 16.5C9.51498 16.5 7.50026 14.4853 7.50026 12C7.50026 9.51472 9.51498 7.5 12.0003 7.5C14.4855 7.5 16.5003 9.51472 16.5003 12C16.5003 14.4853 14.4855 16.5 12.0003 16.5ZM12.0003 14.5C13.381 14.5 14.5003 13.3807 14.5003 12C14.5003 10.6193 13.381 9.5 12.0003 9.5C10.6196 9.5 9.50026 10.6193 9.50026 12C9.50026 13.3807 10.6196 14.5 12.0003 14.5Z"})),Lp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M17.8827 19.2968C16.1814 20.3755 14.1638 21.0002 12.0003 21.0002C6.60812 21.0002 2.12215 17.1204 1.18164 12.0002C1.61832 9.62282 2.81932 7.5129 4.52047 5.93457L1.39366 2.80777L2.80788 1.39355L22.6069 21.1925L21.1927 22.6068L17.8827 19.2968ZM5.9356 7.3497C4.60673 8.56015 3.6378 10.1672 3.22278 12.0002C4.14022 16.0521 7.7646 19.0002 12.0003 19.0002C13.5997 19.0002 15.112 18.5798 16.4243 17.8384L14.396 15.8101C13.7023 16.2472 12.8808 16.5002 12.0003 16.5002C9.51498 16.5002 7.50026 14.4854 7.50026 12.0002C7.50026 11.1196 7.75317 10.2981 8.19031 9.60442L5.9356 7.3497ZM12.9139 14.328L9.67246 11.0866C9.5613 11.3696 9.50026 11.6777 9.50026 12.0002C9.50026 13.3809 10.6196 14.5002 12.0003 14.5002C12.3227 14.5002 12.6309 14.4391 12.9139 14.328ZM20.8068 16.5925L19.376 15.1617C20.0319 14.2268 20.5154 13.1586 20.7777 12.0002C19.8603 7.94818 16.2359 5.00016 12.0003 5.00016C11.1544 5.00016 10.3329 5.11773 9.55249 5.33818L7.97446 3.76015C9.22127 3.26959 10.5793 3.00016 12.0003 3.00016C17.3924 3.00016 21.8784 6.87992 22.8189 12.0002C22.5067 13.6998 21.8038 15.2628 20.8068 16.5925ZM11.7229 7.50857C11.8146 7.50299 11.9071 7.50016 12.0003 7.50016C14.4855 7.50016 16.5003 9.51488 16.5003 12.0002C16.5003 12.0933 16.4974 12.1858 16.4919 12.2775L11.7229 7.50857Z"})),Rp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M21 4V6H20L14 15V22H10V15L4 6H3V4H21Z"})),_p=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M21 4V6H20L15 13.5V22H9V13.5L4 6H3V4H21ZM6.4037 6L11 12.8944V20H13V12.8944L17.5963 6H6.4037Z"})),Np=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M5 22C4.44772 22 4 21.5523 4 21V3C4 2.44772 4.44772 2 5 2H19C19.5523 2 20 2.44772 20 3V6H18V4H6V20H18V18H20V21C20 21.5523 19.5523 22 19 22H5ZM18 16V13H11V11H18V8L23 12L18 16Z"})),Qa=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M3 4H21V6H3V4ZM3 11H21V13H3V11ZM3 18H21V20H3V18Z"})),Bp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M20 17H22V19H2V17H4V10C4 5.58172 7.58172 2 12 2C16.4183 2 20 5.58172 20 10V17ZM9 21H15V23H9V21Z"})),zp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M20 17H22V19H2V17H4V10C4 5.58172 7.58172 2 12 2C16.4183 2 20 5.58172 20 10V17ZM18 17V10C18 6.68629 15.3137 4 12 4C8.68629 4 6 6.68629 6 10V17H18ZM9 21H15V23H9V21Z"})),el=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M18.031 16.6168L22.3137 20.8995L20.8995 22.3137L16.6168 18.031C15.0769 19.263 13.124 20 11 20C6.032 20 2 15.968 2 11C2 6.032 6.032 2 11 2C15.968 2 20 6.032 20 11C20 13.124 19.263 15.0769 18.031 16.6168ZM16.0247 15.8748C17.2475 14.6146 18 12.8956 18 11C18 7.1325 14.8675 4 11 4C7.1325 4 4 7.1325 4 11C4 14.8675 7.1325 18 11 18C12.8956 18 14.6146 17.2475 15.8748 16.0247L16.0247 15.8748Z"})),Op=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M12 12.5858L16.2426 16.8284L14.8284 18.2426L13 16.415V22H11V16.413L9.17157 18.2426L7.75736 16.8284L12 12.5858ZM12 2C15.5934 2 18.5544 4.70761 18.9541 8.19395C21.2858 8.83154 23 10.9656 23 13.5C23 16.3688 20.8036 18.7246 18.0006 18.9776L18.0009 16.9644C19.6966 16.7214 21 15.2629 21 13.5C21 11.567 19.433 10 17.5 10C17.2912 10 17.0867 10.0183 16.8887 10.054C16.9616 9.7142 17 9.36158 17 9C17 6.23858 14.7614 4 12 4C9.23858 4 7 6.23858 7 9C7 9.36158 7.03838 9.7142 7.11205 10.0533C6.91331 10.0183 6.70879 10 6.5 10C4.567 10 3 11.567 3 13.5C3 15.2003 4.21241 16.6174 5.81986 16.934L6.00005 16.9646L6.00039 18.9776C3.19696 18.7252 1 16.3692 1 13.5C1 10.9656 2.71424 8.83154 5.04648 8.19411C5.44561 4.70761 8.40661 2 12 2Z"})),Hp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M20 22H18V20C18 18.3431 16.6569 17 15 17H9C7.34315 17 6 18.3431 6 20V22H4V20C4 17.2386 6.23858 15 9 15H15C17.7614 15 20 17.2386 20 20V22ZM12 13C8.68629 13 6 10.3137 6 7C6 3.68629 8.68629 1 12 1C15.3137 1 18 3.68629 18 7C18 10.3137 15.3137 13 12 13ZM12 11C14.2091 11 16 9.20914 16 7C16 4.79086 14.2091 3 12 3C9.79086 3 8 4.79086 8 7C8 9.20914 9.79086 11 12 11Z"})),jp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M22.0003 13.0001L22.0004 11.0002L5.82845 11.0002L9.77817 7.05044L8.36396 5.63623L2 12.0002L8.36396 18.3642L9.77817 16.9499L5.8284 13.0002L22.0003 13.0001Z"})),Gp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M1.99974 13.0001L1.9996 11.0002L18.1715 11.0002L14.2218 7.05044L15.636 5.63623L22 12.0002L15.636 18.3642L14.2218 16.9499L18.1716 13.0002L1.99974 13.0001Z"})),Up=g.div`
664
+ ${({$isFlushed:e})=>e&&Ja}
665
+ `,Ep=g.input`
666
+ ${pn}
667
+ `,Jo=m.forwardRef(({size:e="md",hasError:t=!1,disabled:n=!1,type:o="text",flushed:r=!1,leftIcon:i,rightIcon:s,iconSize:a="md",iconColor:l="currentColor",className:c,...d},u)=>p.jsxs(Vp,{$size:e,$hasError:t,className:c,$isFlushed:r,children:[i&&p.jsx(U,{component:i,size:a,color:n?"var(--color-dark-200)":l}),p.jsx(Ep,{ref:u,type:o,$hasError:t,disabled:n,...d}),s&&p.jsx(U,{component:s,size:a,color:n?"var(--color-dark-200)":l})]}));Jo.displayName="BaseInput";const Dp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M13.0001 16.1716L18.3641 10.8076L19.7783 12.2218L12.0001 20L4.22192 12.2218L5.63614 10.8076L11.0001 16.1716V4H13.0001V16.1716Z"})),Fp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M11.9999 13.1714L16.9497 8.22168L18.3639 9.63589L11.9999 15.9999L5.63599 9.63589L7.0502 8.22168L11.9999 13.1714Z"})),Ap=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M13.1717 12.0007L8.22192 7.05093L9.63614 5.63672L16.0001 12.0007L9.63614 18.3646L8.22192 16.9504L13.1717 12.0007Z"})),Ip=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M11.9498 7.94975L10.5356 9.36396L8.00079 6.828L8.00004 20H6.00004L6.00079 6.828L3.46451 9.36396L2.05029 7.94975L7.00004 3L11.9498 7.94975ZM21.9498 16.0503L17 21L12.0503 16.0503L13.4645 14.636L16.0008 17.172L16 4H18L18.0008 17.172L20.5356 14.636L21.9498 16.0503Z"})),Qa=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M11.9997 10.5865L16.9495 5.63672L18.3637 7.05093L13.4139 12.0007L18.3637 16.9504L16.9495 18.3646L11.9997 13.4149L7.04996 18.3646L5.63574 16.9504L10.5855 12.0007L5.63574 7.05093L7.04996 5.63672L11.9997 10.5865Z"})),Lp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M10 6V8H5V19H16V14H18V20C18 20.5523 17.5523 21 17 21H4C3.44772 21 3 20.5523 3 20V7C3 6.44772 3.44772 6 4 6H10ZM21 3V11H19L18.9999 6.413L11.2071 14.2071L9.79289 12.7929L17.5849 5H13V3H21Z"})),Rp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M12.0003 3C17.3924 3 21.8784 6.87976 22.8189 12C21.8784 17.1202 17.3924 21 12.0003 21C6.60812 21 2.12215 17.1202 1.18164 12C2.12215 6.87976 6.60812 3 12.0003 3ZM12.0003 19C16.2359 19 19.8603 16.052 20.7777 12C19.8603 7.94803 16.2359 5 12.0003 5C7.7646 5 4.14022 7.94803 3.22278 12C4.14022 16.052 7.7646 19 12.0003 19ZM12.0003 16.5C9.51498 16.5 7.50026 14.4853 7.50026 12C7.50026 9.51472 9.51498 7.5 12.0003 7.5C14.4855 7.5 16.5003 9.51472 16.5003 12C16.5003 14.4853 14.4855 16.5 12.0003 16.5ZM12.0003 14.5C13.381 14.5 14.5003 13.3807 14.5003 12C14.5003 10.6193 13.381 9.5 12.0003 9.5C10.6196 9.5 9.50026 10.6193 9.50026 12C9.50026 13.3807 10.6196 14.5 12.0003 14.5Z"})),_p=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M17.8827 19.2968C16.1814 20.3755 14.1638 21.0002 12.0003 21.0002C6.60812 21.0002 2.12215 17.1204 1.18164 12.0002C1.61832 9.62282 2.81932 7.5129 4.52047 5.93457L1.39366 2.80777L2.80788 1.39355L22.6069 21.1925L21.1927 22.6068L17.8827 19.2968ZM5.9356 7.3497C4.60673 8.56015 3.6378 10.1672 3.22278 12.0002C4.14022 16.0521 7.7646 19.0002 12.0003 19.0002C13.5997 19.0002 15.112 18.5798 16.4243 17.8384L14.396 15.8101C13.7023 16.2472 12.8808 16.5002 12.0003 16.5002C9.51498 16.5002 7.50026 14.4854 7.50026 12.0002C7.50026 11.1196 7.75317 10.2981 8.19031 9.60442L5.9356 7.3497ZM12.9139 14.328L9.67246 11.0866C9.5613 11.3696 9.50026 11.6777 9.50026 12.0002C9.50026 13.3809 10.6196 14.5002 12.0003 14.5002C12.3227 14.5002 12.6309 14.4391 12.9139 14.328ZM20.8068 16.5925L19.376 15.1617C20.0319 14.2268 20.5154 13.1586 20.7777 12.0002C19.8603 7.94818 16.2359 5.00016 12.0003 5.00016C11.1544 5.00016 10.3329 5.11773 9.55249 5.33818L7.97446 3.76015C9.22127 3.26959 10.5793 3.00016 12.0003 3.00016C17.3924 3.00016 21.8784 6.87992 22.8189 12.0002C22.5067 13.6998 21.8038 15.2628 20.8068 16.5925ZM11.7229 7.50857C11.8146 7.50299 11.9071 7.50016 12.0003 7.50016C14.4855 7.50016 16.5003 9.51488 16.5003 12.0002C16.5003 12.0933 16.4974 12.1858 16.4919 12.2775L11.7229 7.50857Z"})),Bp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M21 4V6H20L14 15V22H10V15L4 6H3V4H21Z"})),Np=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M21 4V6H20L15 13.5V22H9V13.5L4 6H3V4H21ZM6.4037 6L11 12.8944V20H13V12.8944L17.5963 6H6.4037Z"})),zp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M5 22C4.44772 22 4 21.5523 4 21V3C4 2.44772 4.44772 2 5 2H19C19.5523 2 20 2.44772 20 3V6H18V4H6V20H18V18H20V21C20 21.5523 19.5523 22 19 22H5ZM18 16V13H11V11H18V8L23 12L18 16Z"})),el=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M3 4H21V6H3V4ZM3 11H21V13H3V11ZM3 18H21V20H3V18Z"})),Op=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M20 17H22V19H2V17H4V10C4 5.58172 7.58172 2 12 2C16.4183 2 20 5.58172 20 10V17ZM9 21H15V23H9V21Z"})),Hp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M20 17H22V19H2V17H4V10C4 5.58172 7.58172 2 12 2C16.4183 2 20 5.58172 20 10V17ZM18 17V10C18 6.68629 15.3137 4 12 4C8.68629 4 6 6.68629 6 10V17H18ZM9 21H15V23H9V21Z"})),tl=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M18.031 16.6168L22.3137 20.8995L20.8995 22.3137L16.6168 18.031C15.0769 19.263 13.124 20 11 20C6.032 20 2 15.968 2 11C2 6.032 6.032 2 11 2C15.968 2 20 6.032 20 11C20 13.124 19.263 15.0769 18.031 16.6168ZM16.0247 15.8748C17.2475 14.6146 18 12.8956 18 11C18 7.1325 14.8675 4 11 4C7.1325 4 4 7.1325 4 11C4 14.8675 7.1325 18 11 18C12.8956 18 14.6146 17.2475 15.8748 16.0247L16.0247 15.8748Z"})),jp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M12 12.5858L16.2426 16.8284L14.8284 18.2426L13 16.415V22H11V16.413L9.17157 18.2426L7.75736 16.8284L12 12.5858ZM12 2C15.5934 2 18.5544 4.70761 18.9541 8.19395C21.2858 8.83154 23 10.9656 23 13.5C23 16.3688 20.8036 18.7246 18.0006 18.9776L18.0009 16.9644C19.6966 16.7214 21 15.2629 21 13.5C21 11.567 19.433 10 17.5 10C17.2912 10 17.0867 10.0183 16.8887 10.054C16.9616 9.7142 17 9.36158 17 9C17 6.23858 14.7614 4 12 4C9.23858 4 7 6.23858 7 9C7 9.36158 7.03838 9.7142 7.11205 10.0533C6.91331 10.0183 6.70879 10 6.5 10C4.567 10 3 11.567 3 13.5C3 15.2003 4.21241 16.6174 5.81986 16.934L6.00005 16.9646L6.00039 18.9776C3.19696 18.7252 1 16.3692 1 13.5C1 10.9656 2.71424 8.83154 5.04648 8.19411C5.44561 4.70761 8.40661 2 12 2Z"})),Gp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M20 22H18V20C18 18.3431 16.6569 17 15 17H9C7.34315 17 6 18.3431 6 20V22H4V20C4 17.2386 6.23858 15 9 15H15C17.7614 15 20 17.2386 20 20V22ZM12 13C8.68629 13 6 10.3137 6 7C6 3.68629 8.68629 1 12 1C15.3137 1 18 3.68629 18 7C18 10.3137 15.3137 13 12 13ZM12 11C14.2091 11 16 9.20914 16 7C16 4.79086 14.2091 3 12 3C9.79086 3 8 4.79086 8 7C8 9.20914 9.79086 11 12 11Z"})),Up=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M22.0003 13.0001L22.0004 11.0002L5.82845 11.0002L9.77817 7.05044L8.36396 5.63623L2 12.0002L8.36396 18.3642L9.77817 16.9499L5.8284 13.0002L22.0003 13.0001Z"})),Wp=({color:e="currentColor",size:t=24,className:n,...o})=>m.createElement("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:t,height:t,fill:e,...o,className:"remixicon "+(n||"")},m.createElement("path",{d:"M1.99974 13.0001L1.9996 11.0002L18.1715 11.0002L14.2218 7.05044L15.636 5.63623L22 12.0002L15.636 18.3642L14.2218 16.9499L18.1716 13.0002L1.99974 13.0001Z"})),Kp=g.div`
653
668
  ${Ze}
654
- ${({$size:e})=>Bt[e??"md"]}
669
+ ${({$size:e})=>zt[e??"md"]}
655
670
  ${({$hasError:e})=>e&&Je}
656
671
  ${({$disabled:e})=>e&&Oe}
657
672
  position: relative;
658
- `,Kp=g.input`
659
- ${mn}
660
- `,Wp=g.span`
673
+ `,qp=g.input`
661
674
  ${pn}
675
+ `,Yp=g.span`
676
+ ${gn}
662
677
  cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
663
- `,tl=({size:e="md",leftIcon:t,iconSize:n="sm",iconColor:o="currentColor",placeholder:r="Contraseña...",hasError:i=!1,disabled:s=!1,className:a,...l})=>{const[c,d]=m.useState(!1),u=()=>d(h=>!h);return p.jsxs(Up,{$size:e,$hasError:i,$disabled:s,className:a,children:[t&&p.jsx(U,{component:t,size:n,color:s?"var(--color-dark-200)":o}),p.jsx(Kp,{type:c?"text":"password",placeholder:r,disabled:s,...l}),p.jsx(Wp,{$disabled:s,onClick:s?void 0:u,children:p.jsx(U,{component:c?Lp:Ip,size:n,color:s?"var(--color-dark-200)":o})})]})},nl=(e,t)=>{if(!t.trim())return e;const n=t.toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g,"");return e.filter(o=>o.label.toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g,"").includes(n))},Jo=e=>{const t=e.findIndex(n=>!n.disabled);return t!==-1?t:0},qp=e=>{for(let t=e.length-1;t>=0;t--)if(!e[t].disabled)return t;return e.length-1},Qo=(e,t,n)=>{let o=e;do o=(o+t+n.length)%n.length;while(n[o]?.disabled&&o!==e);return o},Yp=(e,t)=>({target:{value:String(e),name:t},currentTarget:{value:String(e),name:t}}),Xp=(e,t)=>{if(t>=0&&e.current){const n=e.current.children[t];n&&n.scrollIntoView({block:"nearest",behavior:"smooth"})}},Zp=(e,t)=>{if(typeof e=="string"||typeof e=="number"){const n=t.findIndex(o=>o.value===e);if(n!==-1&&!t[n]?.disabled)return n}return Jo(t)},Jp=({options:e,value:t,name:n,disabled:o=!1,onChange:r,onOptionSelect:i,searchable:s=!1,clearSearchOnSelect:a=!0})=>{const l=m.useRef(null),c=m.useRef(null),d=m.useRef(null),u=m.useRef(null),h=m.useRef(null),f=m.useRef(!1),v=m.useId(),[y,b]=m.useState(!1),[w,C]=m.useState(-1),[x,P]=m.useState(""),T=e.find(M=>M.value===t),k=m.useMemo(()=>s?nl(e,x):e,[e,x,s]);m.useEffect(()=>{y&&(s&&h.current?h.current.focus():c.current&&c.current.focus(),C(Zp(t,k)))},[y,k,t,s]),m.useEffect(()=>{Xp(d,w)},[w]),m.useEffect(()=>{if(!y)return;const M=F=>{l.current&&(l.current.contains(F.target)||b(!1))};return document.addEventListener("mousedown",M),()=>document.removeEventListener("mousedown",M)},[y]),m.useEffect(()=>{y?f.current=!0:f.current&&requestAnimationFrame(()=>{u.current?.focus()})},[y]);const V=M=>{M.disabled||(i?.(M),r&&r(Yp(M.value,n)),a&&P(""),b(!1),C(-1))};return{open:y,activeIndex:w,selected:T,searchQuery:x,filteredOptions:k,containerRef:l,menuRef:c,menuContentRef:d,buttonRef:u,inputRef:h,id:v,setOpen:b,setActiveIndex:C,setSearchQuery:P,commitSelection:V,handleKeyDownButton:M=>{o||(M.key==="ArrowDown"||M.key==="ArrowUp"?(M.preventDefault(),b(!0)):(M.key==="Enter"||M.key===" ")&&(M.preventDefault(),b(F=>!F)))},handleKeyDownInput:M=>{if(!o)if(M.key==="ArrowDown")M.preventDefault(),y?C(Qo(w,1,k)):b(!0);else if(M.key==="ArrowUp")M.preventDefault(),y?C(Qo(w,-1,k)):b(!0);else if(M.key==="Enter")if(M.preventDefault(),y&&w>=0){const F=k[w];F&&!F.disabled&&V(F)}else b(!0);else M.key==="Escape"&&(M.preventDefault(),x?P(""):b(!1))},handleKeyDownMenu:M=>{if(M.key==="Escape"){M.preventDefault(),b(!1),C(-1);return}if(M.key==="ArrowDown"||M.key==="ArrowUp"){M.preventDefault();const F=M.key==="ArrowDown"?1:-1;C(Qo(w,F,k))}else if(M.key==="Enter"){M.preventDefault();const F=k[w];F&&!F.disabled&&V(F)}else M.key==="Home"?(M.preventDefault(),C(Jo(k))):M.key==="End"&&(M.preventDefault(),C(qp(k)))},handleToggle:()=>{o||b(M=>!M)},handleSearchChange:M=>{const F=M.target.value;P(F),y||b(!0),C(Jo(nl(e,F)))}}},Qp=g.div`
678
+ `,nl=({size:e="md",leftIcon:t,iconSize:n="sm",iconColor:o="currentColor",placeholder:r="Contraseña...",hasError:i=!1,disabled:s=!1,className:a,...l})=>{const[c,d]=m.useState(!1),u=()=>d(f=>!f);return p.jsxs(Kp,{$size:e,$hasError:i,$disabled:s,className:a,children:[t&&p.jsx(U,{component:t,size:n,color:s?"var(--color-dark-200)":o}),p.jsx(qp,{type:c?"text":"password",placeholder:r,disabled:s,...l}),p.jsx(Yp,{$disabled:s,onClick:s?void 0:u,children:p.jsx(U,{component:c?_p:Rp,size:n,color:s?"var(--color-dark-200)":o})})]})},ol=(e,t)=>{if(!t.trim())return e;const n=t.toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g,"");return e.filter(o=>o.label.toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g,"").includes(n))},Qo=e=>{const t=e.findIndex(n=>!n.disabled);return t!==-1?t:0},Xp=e=>{for(let t=e.length-1;t>=0;t--)if(!e[t].disabled)return t;return e.length-1},er=(e,t,n)=>{let o=e;do o=(o+t+n.length)%n.length;while(n[o]?.disabled&&o!==e);return o},Zp=(e,t)=>({target:{value:String(e),name:t},currentTarget:{value:String(e),name:t}}),Jp=(e,t)=>{if(t>=0&&e.current){const n=e.current.children[t];n&&n.scrollIntoView({block:"nearest",behavior:"smooth"})}},Qp=(e,t)=>{if(typeof e=="string"||typeof e=="number"){const n=t.findIndex(o=>o.value===e);if(n!==-1&&!t[n]?.disabled)return n}return Qo(t)},eg=({options:e,value:t,name:n,disabled:o=!1,onChange:r,onOptionSelect:i,searchable:s=!1,clearSearchOnSelect:a=!0})=>{const l=m.useRef(null),c=m.useRef(null),d=m.useRef(null),u=m.useRef(null),f=m.useRef(null),h=m.useRef(!1),v=m.useId(),[y,b]=m.useState(!1),[w,S]=m.useState(-1),[x,P]=m.useState(""),T=e.find(M=>M.value===t),k=m.useMemo(()=>s?ol(e,x):e,[e,x,s]);m.useEffect(()=>{y&&(s&&f.current?f.current.focus():c.current&&c.current.focus(),S(Qp(t,k)))},[y,k,t,s]),m.useEffect(()=>{Jp(d,w)},[w]),m.useEffect(()=>{if(!y)return;const M=F=>{l.current&&(l.current.contains(F.target)||b(!1))};return document.addEventListener("mousedown",M),()=>document.removeEventListener("mousedown",M)},[y]),m.useEffect(()=>{y?h.current=!0:h.current&&requestAnimationFrame(()=>{u.current?.focus()})},[y]);const V=M=>{M.disabled||(i?.(M),r&&r(Zp(M.value,n)),a&&P(""),b(!1),S(-1))};return{open:y,activeIndex:w,selected:T,searchQuery:x,filteredOptions:k,containerRef:l,menuRef:c,menuContentRef:d,buttonRef:u,inputRef:f,id:v,setOpen:b,setActiveIndex:S,setSearchQuery:P,commitSelection:V,handleKeyDownButton:M=>{o||(M.key==="ArrowDown"||M.key==="ArrowUp"?(M.preventDefault(),b(!0)):(M.key==="Enter"||M.key===" ")&&(M.preventDefault(),b(F=>!F)))},handleKeyDownInput:M=>{if(!o)if(M.key==="ArrowDown")M.preventDefault(),y?S(er(w,1,k)):b(!0);else if(M.key==="ArrowUp")M.preventDefault(),y?S(er(w,-1,k)):b(!0);else if(M.key==="Enter")if(M.preventDefault(),y&&w>=0){const F=k[w];F&&!F.disabled&&V(F)}else b(!0);else M.key==="Escape"&&(M.preventDefault(),x?P(""):b(!1))},handleKeyDownMenu:M=>{if(M.key==="Escape"){M.preventDefault(),b(!1),S(-1);return}if(M.key==="ArrowDown"||M.key==="ArrowUp"){M.preventDefault();const F=M.key==="ArrowDown"?1:-1;S(er(w,F,k))}else if(M.key==="Enter"){M.preventDefault();const F=k[w];F&&!F.disabled&&V(F)}else M.key==="Home"?(M.preventDefault(),S(Qo(k))):M.key==="End"&&(M.preventDefault(),S(Xp(k)))},handleToggle:()=>{o||b(M=>!M)},handleSearchChange:M=>{const F=M.target.value;P(F),y||b(!0),S(Qo(ol(e,F)))}}},tg=g.div`
664
679
  position: relative;
665
680
  width: 100%;
666
- `,eg=g.div`
667
- ${pn};
681
+ `,ng=g.div`
682
+ ${gn};
668
683
  position: absolute;
669
684
  right: 1rem;
670
685
  top: 50%;
671
686
  transform: translateY(-50%) rotate(${({$open:e})=>e?"-180deg":"0deg"});
672
687
  pointer-events: none;
673
688
  transition: transform 0.3s ease-out;
674
- `,ol=g.button`
689
+ `,rl=g.button`
675
690
  ${Ze}
676
- ${({$size:e})=>Bt[e]}
691
+ ${({$size:e})=>zt[e]}
677
692
  ${({$hasError:e})=>e&&Je}
678
693
  ${({$disabled:e})=>e&&Oe}
679
694
 
@@ -693,7 +708,7 @@
693
708
  &:hover {
694
709
  background-color: var(--color-main-alternative-secondary);
695
710
  }
696
- `,tg=g(De.ul)`
711
+ `,og=g(De.ul)`
697
712
  position: absolute;
698
713
  z-index: 50;
699
714
  left: 0;
@@ -715,11 +730,11 @@
715
730
  border: var(--border-input-focus);
716
731
  outline: none;
717
732
  }
718
- `,ng=g.div`
733
+ `,rg=g.div`
719
734
  max-height: 15rem;
720
735
  overflow-y: auto;
721
736
  outline: none;
722
- `,og=g.li`
737
+ `,ig=g.li`
723
738
  display: flex;
724
739
  align-items: center;
725
740
  gap: 0.5rem;
@@ -729,11 +744,11 @@
729
744
  cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
730
745
  user-select: none;
731
746
 
732
- ${({$size:e})=>rg[e??"md"]}
747
+ ${({$size:e})=>sg[e??"md"]}
733
748
 
734
749
  background-color: ${({$active:e})=>e?"var(--color-main-alternative-secondary)":"transparent"};
735
750
  color: ${({$disabled:e})=>e?"var(--color-dark-200)":"var(--color-main-blue-primary)"};
736
- `,rg={xs:g.css`
751
+ `,sg={xs:g.css`
737
752
  ${D[14]}
738
753
  `,sm:g.css`
739
754
  ${D[16]}
@@ -741,12 +756,31 @@
741
756
  ${D[18]}
742
757
  `,lg:g.css`
743
758
  ${D[18]}
744
- `},rl=m.forwardRef(({size:e,hasError:t,disabled:n,hasValue:o,displayText:r,open:i,inputClassName:s,onClick:a,onKeyDown:l,ariaHaspopup:c,ariaExpanded:d,ariaControls:u,ariaInvalid:h,title:f,searchable:v=!1,searchQuery:y="",searchPlaceholder:b,onSearchChange:w,onInputKeyDown:C,inputRef:x},P)=>{const T={$size:e,$hasError:t,$hasValue:o,$disabled:n,disabled:n,className:s,onClick:a,title:f,"aria-haspopup":c,"aria-expanded":d,"aria-controls":u,"aria-invalid":h},k=m.useCallback(V=>{v&&x&&"current"in x&&(x.current=V),P&&(typeof P=="function"?P(V):P&&"current"in P&&(P.current=V))},[v,x,P]);return p.jsxs(p.Fragment,{children:[v?p.jsx(ol,{...T,as:"input",type:"text",ref:k,value:i?y:r,onChange:w,onKeyDown:C,placeholder:b||r,role:"combobox","aria-autocomplete":"list",autoComplete:"off",title:f}):p.jsx(ol,{...T,type:"button",ref:k,onKeyDown:l,children:r}),p.jsx(eg,{$size:e,$disabled:n,$open:i,children:p.jsx(U,{component:Za,size:e==="sm"||e==="md"?"sm":"md",color:n?"var(--color-dark-200)":"var(--color-main-blue-primary)"})})]})});rl.displayName="SelectTrigger";const il=({option:e,size:t,active:n,selected:o,id:r,className:i,onMouseEnter:s,onClick:a})=>p.jsx(og,{id:r,className:i,role:"option",$size:t,"aria-selected":o,$active:n,$disabled:e.disabled,onMouseEnter:s,onClick:a,children:e.label});il.displayName="SelectOption";const sl=({open:e,options:t,size:n,activeIndex:o,selectedValue:r,menuRef:i,menuContentRef:s,id:a,optionsClassName:l,optionClassName:c,noResultsMessage:d="No results found",onKeyDown:u,onOptionClick:h,onOptionMouseEnter:f})=>p.jsx(Lt,{children:e&&p.jsx(tg,{ref:i,className:"custom-scrollbar",id:`${a}-listbox`,role:"listbox",tabIndex:0,"aria-activedescendant":o>=0?`${a}-option-${o}`:void 0,initial:{opacity:0,height:0,scaleY:.8},animate:{opacity:1,height:"auto",scaleY:1},exit:{opacity:0,height:0,scaleY:.8},transition:{duration:.25,ease:[.4,0,.2,1]},onKeyDown:u,children:p.jsx(ng,{ref:s,className:l,children:t.length===0?p.jsx(ht,{children:d}):t.map((v,y)=>{const b=y===o;let w=v.className??(typeof c=="string"?c:void 0);if(typeof c=="function")try{const C=c(v);C&&(w=C)}catch(C){console.error(C)}return p.jsx(il,{option:v,size:n,active:b,selected:r===v.value,id:`${a}-option-${y}`,className:w,onMouseEnter:()=>{!v.disabled&&e&&f(y)},onClick:()=>h(v)},v.value)})})})});sl.displayName="SelectMenu";const gn=m.forwardRef(({size:e="md",hasError:t=!1,disabled:n=!1,options:o=[],placeholder:r,onOptionSelect:i,onChange:s,value:a,name:l,className:c,inputClassName:d,optionsClassName:u,optionClassName:h,searchable:f=!1,searchPlaceholder:v,clearSearchOnSelect:y=!0,noResultsMessage:b},w)=>{const{open:C,activeIndex:x,selected:P,searchQuery:T,filteredOptions:k,containerRef:V,menuRef:$,menuContentRef:A,buttonRef:I,inputRef:B,id:H,setActiveIndex:M,commitSelection:F,handleKeyDownButton:z,handleKeyDownInput:N,handleKeyDownMenu:L,handleToggle:j,handleSearchChange:te}=Jp({options:o,value:a,name:l,disabled:n,onChange:s,onOptionSelect:i,searchable:f,clearSearchOnSelect:y}),J=ue=>{I.current=ue,typeof w=="function"?w(ue):w&&"current"in w&&(w.current=ue)};return p.jsxs(Qp,{ref:V,className:c,children:[l&&p.jsx("input",{type:"hidden",name:l,value:P?.value??""}),p.jsx(rl,{ref:J,size:e,hasError:t,disabled:n,hasValue:!!P,displayText:P?.label??r??"",open:C,inputClassName:d,onClick:j,onKeyDown:z,ariaHaspopup:"listbox",ariaExpanded:C,ariaControls:`${H}-listbox`,ariaInvalid:t||void 0,title:P?.label??r??"Select an option",searchable:f,searchQuery:T,searchPlaceholder:v,onSearchChange:te,onInputKeyDown:N,inputRef:B}),p.jsx(sl,{open:C,options:k,size:e,activeIndex:x,selectedValue:a,menuRef:$,menuContentRef:A,id:H,optionsClassName:u,optionClassName:h,noResultsMessage:b,onKeyDown:L,onOptionClick:F,onOptionMouseEnter:M})]})});gn.displayName="SelectInput";const ig=g.textarea`
759
+ `},il=m.forwardRef(({size:e,hasError:t,disabled:n,hasValue:o,displayText:r,open:i,inputClassName:s,onClick:a,onKeyDown:l,ariaHaspopup:c,ariaExpanded:d,ariaControls:u,ariaInvalid:f,title:h,searchable:v=!1,searchQuery:y="",searchPlaceholder:b,onSearchChange:w,onInputKeyDown:S,inputRef:x},P)=>{const T={$size:e,$hasError:t,$hasValue:o,$disabled:n,disabled:n,className:s,onClick:a,title:h,"aria-haspopup":c,"aria-expanded":d,"aria-controls":u,"aria-invalid":f},k=m.useCallback(V=>{v&&x&&"current"in x&&(x.current=V),P&&(typeof P=="function"?P(V):P&&"current"in P&&(P.current=V))},[v,x,P]);return p.jsxs(p.Fragment,{children:[v?p.jsx(rl,{...T,as:"input",type:"text",ref:k,value:i?y:r,onChange:w,onKeyDown:S,placeholder:b||r,role:"combobox","aria-autocomplete":"list",autoComplete:"off",title:h}):p.jsx(rl,{...T,type:"button",ref:k,onKeyDown:l,children:r}),p.jsx(ng,{$size:e,$disabled:n,$open:i,children:p.jsx(U,{component:Fp,size:e==="sm"||e==="md"?"sm":"md",color:n?"var(--color-dark-200)":"var(--color-main-blue-primary)"})})]})});il.displayName="SelectTrigger";const sl=({option:e,size:t,active:n,selected:o,id:r,className:i,onMouseEnter:s,onClick:a})=>p.jsx(ig,{id:r,className:i,role:"option",$size:t,"aria-selected":o,$active:n,$disabled:e.disabled,onMouseEnter:s,onClick:a,children:e.label});sl.displayName="SelectOption";const al=({open:e,options:t,size:n,activeIndex:o,selectedValue:r,menuRef:i,menuContentRef:s,id:a,optionsClassName:l,optionClassName:c,noResultsMessage:d="No results found",onKeyDown:u,onOptionClick:f,onOptionMouseEnter:h})=>p.jsx(Rt,{children:e&&p.jsx(og,{ref:i,className:"custom-scrollbar",id:`${a}-listbox`,role:"listbox",tabIndex:0,"aria-activedescendant":o>=0?`${a}-option-${o}`:void 0,initial:{opacity:0,height:0,scaleY:.8},animate:{opacity:1,height:"auto",scaleY:1},exit:{opacity:0,height:0,scaleY:.8},transition:{duration:.25,ease:[.4,0,.2,1]},onKeyDown:u,children:p.jsx(rg,{ref:s,className:l,children:t.length===0?p.jsx(mt,{children:d}):t.map((v,y)=>{const b=y===o;let w=v.className??(typeof c=="string"?c:void 0);if(typeof c=="function")try{const S=c(v);S&&(w=S)}catch(S){console.error(S)}return p.jsx(sl,{option:v,size:n,active:b,selected:r===v.value,id:`${a}-option-${y}`,className:w,onMouseEnter:()=>{!v.disabled&&e&&h(y)},onClick:()=>f(v)},v.value)})})})});al.displayName="SelectMenu";const vn=m.forwardRef(({size:e="md",hasError:t=!1,disabled:n=!1,options:o=[],placeholder:r,onOptionSelect:i,onChange:s,value:a,name:l,className:c,inputClassName:d,optionsClassName:u,optionClassName:f,searchable:h=!1,searchPlaceholder:v,clearSearchOnSelect:y=!0,noResultsMessage:b},w)=>{const{open:S,activeIndex:x,selected:P,searchQuery:T,filteredOptions:k,containerRef:V,menuRef:$,menuContentRef:A,buttonRef:I,inputRef:N,id:H,setActiveIndex:M,commitSelection:F,handleKeyDownButton:z,handleKeyDownInput:B,handleKeyDownMenu:L,handleToggle:j,handleSearchChange:te}=eg({options:o,value:a,name:l,disabled:n,onChange:s,onOptionSelect:i,searchable:h,clearSearchOnSelect:y}),J=ue=>{I.current=ue,typeof w=="function"?w(ue):w&&"current"in w&&(w.current=ue)};return p.jsxs(tg,{ref:V,className:c,children:[l&&p.jsx("input",{type:"hidden",name:l,value:P?.value??""}),p.jsx(il,{ref:J,size:e,hasError:t,disabled:n,hasValue:!!P,displayText:P?.label??r??"",open:S,inputClassName:d,onClick:j,onKeyDown:z,ariaHaspopup:"listbox",ariaExpanded:S,ariaControls:`${H}-listbox`,ariaInvalid:t||void 0,title:P?.label??r??"Select an option",searchable:h,searchQuery:T,searchPlaceholder:v,onSearchChange:te,onInputKeyDown:B,inputRef:N}),p.jsx(al,{open:S,options:k,size:e,activeIndex:x,selectedValue:a,menuRef:$,menuContentRef:A,id:H,optionsClassName:u,optionClassName:f,noResultsMessage:b,onKeyDown:L,onOptionClick:F,onOptionMouseEnter:M})]})});vn.displayName="SelectInput";const ag=g.div`
745
760
  ${Ze}
746
- ${({$size:e})=>sg[e]}
747
761
  ${({$hasError:e})=>e&&Je}
748
762
  ${({$disabled:e})=>e&&Oe}
749
- ${D[20]}
763
+ padding: 0;
764
+ align-items: flex-start;
765
+ `,ll=g.div`
766
+ display: flex;
767
+ align-items: center;
768
+ justify-content: center;
769
+ flex-shrink: 0;
770
+ padding-top: ${({$size:e})=>{switch(e){case"xs":return"0.625rem";case"sm":return"0.75rem";case"md":return"1rem";case"lg":return"1.25rem";default:return"1rem"}}};
771
+ `,lg=g.textarea`
772
+ width: 100%;
773
+ border: none;
774
+ background: transparent;
775
+ color: inherit;
776
+ outline: none;
777
+ font-size: inherit;
778
+ line-height: inherit;
779
+
780
+ ${({$size:e})=>Qe[e].textStyle}
781
+ padding: ${({$size:e,$hasLeftIcon:t,$hasRightIcon:n})=>t&&n?Qe[e].paddingWithBothIcons:t?Qe[e].paddingWithLeftIcon:n?Qe[e].paddingWithRightIcon:Qe[e].padding};
782
+
783
+ min-height: ${({$size:e})=>Qe[e].rows}em;
750
784
 
751
785
  resize: ${({$resize:e})=>e};
752
786
 
@@ -755,43 +789,32 @@
755
789
  resize: none;
756
790
  `}
757
791
 
792
+ &:disabled {
793
+ cursor: not-allowed;
794
+ opacity: 0.6;
795
+ }
796
+
758
797
  &::placeholder {
759
798
  color: var(--color-dark-200);
760
799
  opacity: 1;
761
800
  }
762
- `,sg={xs:`
763
- ${D[16]}
764
- height: 4rem;
765
- max-height: 8rem;
766
- padding: 0.75rem 1rem;
767
- `,sm:`
768
- ${D[20]}
769
- height: 6rem;
770
- max-height: 12rem;
771
- padding: 1rem 1.25rem;
772
- `,md:`
773
- ${D[24]}
774
- height: 8rem;
775
- max-height: 16rem;
776
- padding: 1rem 1.25rem;
777
- `,lg:`
778
- ${D[24]}
779
- height:12rem;
780
- max-height: 20rem;
781
- padding: 1rem 1.25rem;
782
- `},er=m.forwardRef(({size:e="md",hasError:t=!1,disabled:n=!1,resize:o="vertical",autoResize:r=!1,minRows:i=3,maxRows:s,className:a,onChange:l,...c},d)=>{const u=h=>{if(r){const f=h.target;f.style.height="auto";const v=f.scrollHeight,y=i*24,b=s?s*24:v;v>b?(f.style.height=`${b}px`,f.style.overflowY="scroll"):(f.style.height=`${Math.max(v,y)}px`,f.style.overflowY="hidden")}l?.(h)};return p.jsx(ig,{ref:d,$size:e,$hasError:t,$disabled:n,$resize:o,$autoResize:r,disabled:n,rows:i,className:a,onChange:u,...c})});er.displayName="TextAreaInput";const ag=g.div`
801
+
802
+ &:focus {
803
+ outline: none;
804
+ }
805
+ `,Qe={xs:{textStyle:D[14],rows:2,padding:"0.625rem 0.75rem",paddingWithLeftIcon:"0.625rem 0.75rem 0.625rem 0.5rem",paddingWithRightIcon:"0.625rem 0.5rem 0.625rem 0.75rem",paddingWithBothIcons:"0.625rem 0.5rem"},sm:{textStyle:D[14],rows:3,padding:"0.75rem 1rem",paddingWithLeftIcon:"0.75rem 1rem 0.75rem 0.625rem",paddingWithRightIcon:"0.75rem 0.625rem 0.75rem 1rem",paddingWithBothIcons:"0.75rem 0.625rem"},md:{textStyle:D[16],rows:5,padding:"1rem 1.25rem",paddingWithLeftIcon:"1rem 1.25rem 1rem 0.75rem",paddingWithRightIcon:"1rem 0.75rem 1rem 1.25rem",paddingWithBothIcons:"1rem 0.75rem"},lg:{textStyle:D[18],rows:8,padding:"1.25rem 1.5rem",paddingWithLeftIcon:"1.25rem 1.5rem 1.25rem 1rem",paddingWithRightIcon:"1.25rem 1rem 1.25rem 1.5rem",paddingWithBothIcons:"1.25rem 1rem"}},tr=m.forwardRef(({size:e="md",hasError:t=!1,disabled:n=!1,resize:o="vertical",autoResize:r=!1,minRows:i,maxRows:s,leftIcon:a,rightIcon:l,iconSize:c="md",iconColor:d="currentColor",className:u,onChange:f,...h},v)=>{const y=i??Qe[e].rows,b=w=>{if(r){const S=w.target;S.style.height="auto";const x=window.getComputedStyle(S),P=parseFloat(x.lineHeight),T=y*P,k=s?s*P:S.scrollHeight;S.scrollHeight>k?(S.style.height=`${k}px`,S.style.overflowY="auto"):(S.style.height=`${Math.max(S.scrollHeight,T)}px`,S.style.overflowY="hidden")}f?.(w)};return p.jsxs(ag,{$size:e,$hasError:t,$disabled:n,className:u,children:[a&&p.jsx(ll,{$size:e,children:p.jsx(U,{component:a,size:c,color:n?"var(--color-dark-200)":d,"aria-hidden":"true"})}),p.jsx(lg,{ref:v,$size:e,$hasError:t,$disabled:n,$resize:o,$autoResize:r,$hasLeftIcon:!!a,$hasRightIcon:!!l,disabled:n,rows:y,onChange:b,...h}),l&&p.jsx(ll,{$size:e,children:p.jsx(U,{component:l,size:c,color:n?"var(--color-dark-200)":d,"aria-hidden":"true"})})]})});tr.displayName="TextAreaInput";const cg=g.div`
783
806
  ${Ze}
784
- ${({$size:e})=>Bt[e??"md"]}
785
- `,lg=g.input`
786
- ${mn}
787
- `,tr=({size:e="md",leftIcon:t,rightIcon:n=el,iconSize:o="sm",iconColor:r="currentColor",placeholder:i="Buscar...",onSearch:s,className:a,...l})=>{const c=d=>{s?.(d.target.value)};return p.jsxs(ag,{$size:e,className:a,children:[t&&p.jsx(U,{component:t,size:o,color:r}),p.jsx(lg,{placeholder:i,onChange:c,...l}),n?p.jsx(U,{component:n,size:o,color:r}):p.jsx(U,{component:el,size:o,color:r})]})},cg={default:g.css`
807
+ ${({$size:e})=>zt[e??"md"]}
808
+ `,ug=g.input`
809
+ ${pn}
810
+ `,nr=({size:e="md",leftIcon:t,rightIcon:n=tl,iconSize:o="sm",iconColor:r="currentColor",placeholder:i="Buscar...",onSearch:s,className:a,...l})=>{const c=d=>{s?.(d.target.value)};return p.jsxs(cg,{$size:e,className:a,children:[t&&p.jsx(U,{component:t,size:o,color:r}),p.jsx(ug,{placeholder:i,onChange:c,...l}),n?p.jsx(U,{component:n,size:o,color:r}):p.jsx(U,{component:tl,size:o,color:r})]})},dg={default:g.css`
788
811
  min-height: 18rem;
789
812
  padding: 2rem;
790
813
  `,compact:g.css`
791
814
  min-height: 6rem;
792
815
  padding: 1rem;
793
816
  flex-direction: row;
794
- `},ug={xs:g.css`
817
+ `},fg={xs:g.css`
795
818
  ${D[12]}
796
819
  `,sm:g.css`
797
820
  ${D[12]}
@@ -799,28 +822,28 @@
799
822
  ${D[16]}
800
823
  `,lg:g.css`
801
824
  ${D[20]}
802
- `},dg=g.css`
825
+ `},hg=g.css`
803
826
  border: 2px dashed var(--color-main-input-borders);
804
827
  background-color: var(--color-main-white);
805
- `,fg=g.css`
828
+ `,mg=g.css`
806
829
  border-color: var(--color-main-blue-primary);
807
830
  background-color: var(--color-main-alternative-secondary);
808
- `,hg=g.css`
831
+ `,pg=g.css`
809
832
  border: 2px dashed var(--color-main-positive-state);
810
833
  background-color: var(--color-green-100);
811
- `,mg=g.css`
834
+ `,gg=g.css`
812
835
  border-color: var(--color-main-warning-state);
813
836
  background-color: var(--color-red-100);
814
- `,pg=g.css`
837
+ `,vg=g.css`
815
838
  border-color: var(--color-dark-200);
816
839
  cursor: not-allowed;
817
840
  opacity: 0.6;
818
- `,gg=g.div`
841
+ `,yg=g.div`
819
842
  display: flex;
820
843
  flex-direction: column;
821
844
  width: 100%;
822
- ${({$size:e})=>ug[e]}
823
- `,vg=g.div`
845
+ ${({$size:e})=>fg[e]}
846
+ `,wg=g.div`
824
847
  display: flex;
825
848
  flex-direction: column;
826
849
  align-items: center;
@@ -836,35 +859,35 @@
836
859
  outline: 2px solid transparent;
837
860
  outline-offset: 2px;
838
861
 
839
- ${({$variant:e})=>cg[e]}
840
- ${dg}
862
+ ${({$variant:e})=>dg[e]}
863
+ ${hg}
841
864
 
842
- ${({$disabled:e})=>e?pg:g.css`
865
+ ${({$disabled:e})=>e?vg:g.css`
843
866
  &:hover {
844
- ${fg}
867
+ ${mg}
845
868
  }
846
869
  `}
847
870
 
848
- ${({$isDragging:e,$disabled:t})=>e&&!t&&hg}
849
- ${({$hasError:e,$disabled:t})=>e&&!t&&mg}
871
+ ${({$isDragging:e,$disabled:t})=>e&&!t&&pg}
872
+ ${({$hasError:e,$disabled:t})=>e&&!t&&gg}
850
873
 
851
874
  &:focus-visible {
852
875
  outline-color: var(--color-main-blue-primary);
853
876
  outline-offset: 2px;
854
877
  }
855
- `,yg=g.div`
878
+ `,bg=g.div`
856
879
  color: ${({$disabled:e})=>e?"var(--color-dark-200)":"var(--color-main-blue-primary)"};
857
880
 
858
881
  strong {
859
882
  color: ${({$disabled:e})=>e?"var(--color-dark-200)":"var(--color-main-blue-primary)"};
860
883
  font-weight: 700;
861
884
  }
862
- `,wg=g.div`
885
+ `,xg=g.div`
863
886
  display: flex;
864
887
  flex-direction: column;
865
888
  gap: 0.5rem;
866
889
  margin-top: 1rem;
867
- `,bg=g.div`
890
+ `,Sg=g.div`
868
891
  display: flex;
869
892
  align-items: center;
870
893
  justify-content: space-between;
@@ -881,12 +904,12 @@
881
904
  &:hover {
882
905
  background-color: var(--color-main-alternative-secondary);
883
906
  }
884
- `,xg=g(Ie)`
907
+ `,Cg=g(Ie)`
885
908
  font-weight: 500;
886
909
  overflow: hidden;
887
910
  text-overflow: ellipsis;
888
911
  white-space: nowrap;
889
- `,Sg=g.button`
912
+ `,Tg=g.button`
890
913
  background: none;
891
914
  border: none;
892
915
  color: var(--color-dark-400);
@@ -913,12 +936,12 @@
913
936
  cursor: not-allowed;
914
937
  opacity: 0.5;
915
938
  }
916
- `,Cg=(e,t)=>{const[n,o]=m.useState(!1),r=m.useCallback(l=>{l.preventDefault(),l.stopPropagation(),t||o(!0)},[t]),i=m.useCallback(l=>{l.preventDefault(),l.stopPropagation(),t||o(!1)},[t]),s=m.useCallback(l=>{l.preventDefault(),l.stopPropagation()},[]),a=m.useCallback(l=>{l.preventDefault(),l.stopPropagation(),t||(o(!1),e(l.dataTransfer.files))},[t,e]);return m.useEffect(()=>()=>{n&&o(!1)},[n]),{isDragging:n,dragHandlers:{onDragEnter:r,onDragLeave:i,onDragOver:s,onDrop:a}}},Tg=({maxFileSize:e,accept:t,multiple:n,onError:o})=>{const[r,i]=m.useState(""),s=m.useCallback(l=>{i(l),o?.(l)},[o]),a=m.useCallback(l=>{if(e&&l.some(c=>c.size>e)){const c=e/1048576,d=c>=1?`File size exceeds maximum of ${c.toFixed(1)}MB`:`File size exceeds maximum of ${Math.round(e/1024)}KB`;return s(d),!1}if(t){const c=t.split(",").map(u=>u.trim().toLowerCase());if(l.find(u=>{const h=u.type.toLowerCase(),f=`.${u.name.split(".").pop()?.toLowerCase()}`;return!c.some(v=>{if(v===h||v===f)return!0;if(v.endsWith("/*")){const y=v.slice(0,-2);return h.startsWith(`${y}/`)}return!1})})){const u=`File type not accepted. Allowed: ${t}`;return s(u),!1}}return!n&&l.length>1?(s("Only one file is allowed"),!1):(i(""),!0)},[e,t,n,s]);return{error:r,validateFiles:a,clearError:()=>i("")}},$g=e=>{const t=["Bytes","KB","MB"],n=Math.floor(Math.log(e)/Math.log(1024));return`${(e/Math.pow(1024,n)).toFixed(2)} ${t[n]}`},al=({files:e,onRemove:t,disabled:n})=>e.length===0?null:p.jsx(wg,{children:e.map((o,r)=>p.jsxs(bg,{children:[p.jsxs("div",{className:"flex min-w-[0] flex-col gap-1",children:[p.jsx(xg,{size:14,children:o.name}),p.jsx(ht,{size:12,children:$g(o.size)})]}),p.jsx(Sg,{type:"button",onClick:()=>t(r),"aria-label":`Remove ${o.name}`,disabled:n,children:p.jsx(Ja,{})})]},`${o.name}-${r}`))}),Pg=({variant:e="default",multiple:t=!1,maxFileSize:n=10,accept:o="image/*,application/pdf",helperText:r="Upload files here",value:i,defaultValue:s,onChange:a,onError:l,onFileRemove:c,disabled:d=!1,hasError:u=!1,errorMessage:h="",className:f="",dropZoneContainerClassName:v="",size:y="md"})=>{const b=i!==void 0,[w,C]=m.useState(s||[]),x=b?i:w,P=n*1024*1024,{error:T,validateFiles:k,clearError:V}=Tg({maxFileSize:P,accept:o,multiple:t,onError:l}),$=(F,z)=>{if(!F||F.length===0)return;const N=Array.from(F);if(!k(N))return;const L=t?[...x,...N]:N;b||C(L),a?.(L,z)},A=F=>{const z=x[F],N=x.filter((L,j)=>j!==F);b||C(N),c?.(z,F),a?.(N),N.length===0&&V()},{isDragging:I,dragHandlers:B}=Cg($,d),H=u||!!T,M=h||T;return p.jsxs(gg,{$size:y,className:f,children:[p.jsxs("label",{"aria-label":"File upload area",className:`p-4 ${v}`,children:[p.jsxs(vg,{$variant:e,$isDragging:I,$hasError:H,$disabled:d,role:"button",tabIndex:d?-1:0,"aria-disabled":d,onKeyDown:F=>{(F.key==="Enter"||F.key===" ")&&(F.preventDefault(),F.currentTarget.querySelector("input")?.click())},...B,children:[p.jsx(U,{component:Op,size:"lg",color:d?"var(--color-dark-200)":"var(--color-main-blue-primary)",className:"!text-[5rem]"}),p.jsxs(yg,{$disabled:d,children:[p.jsx("strong",{children:"Click to upload"})," or drag and drop"]}),r&&!H&&p.jsx(Ie,{size:14,color:"var(--color-main-grey)",children:r})]}),p.jsx("input",{type:"file",multiple:t,accept:o,disabled:d,onChange:F=>$(F.target.files,F.nativeEvent),style:{display:"none"},"aria-label":"File input"})]}),H&&M&&p.jsx(Xo,{size:"sm",children:M}),p.jsx(al,{files:x,onRemove:A,disabled:d})]})},mt={xs:"1rem",sm:"1.25rem",md:"1.5rem",lg:"1.75rem"},kg=g.div`
939
+ `,$g=(e,t)=>{const[n,o]=m.useState(!1),r=m.useCallback(l=>{l.preventDefault(),l.stopPropagation(),t||o(!0)},[t]),i=m.useCallback(l=>{l.preventDefault(),l.stopPropagation(),t||o(!1)},[t]),s=m.useCallback(l=>{l.preventDefault(),l.stopPropagation()},[]),a=m.useCallback(l=>{l.preventDefault(),l.stopPropagation(),t||(o(!1),e(l.dataTransfer.files))},[t,e]);return m.useEffect(()=>()=>{n&&o(!1)},[n]),{isDragging:n,dragHandlers:{onDragEnter:r,onDragLeave:i,onDragOver:s,onDrop:a}}},Pg=({maxFileSize:e,accept:t,multiple:n,onError:o})=>{const[r,i]=m.useState(""),s=m.useCallback(l=>{i(l),o?.(l)},[o]),a=m.useCallback(l=>{if(e&&l.some(c=>c.size>e)){const c=e/1048576,d=c>=1?`File size exceeds maximum of ${c.toFixed(1)}MB`:`File size exceeds maximum of ${Math.round(e/1024)}KB`;return s(d),!1}if(t){const c=t.split(",").map(u=>u.trim().toLowerCase());if(l.find(u=>{const f=u.type.toLowerCase(),h=`.${u.name.split(".").pop()?.toLowerCase()}`;return!c.some(v=>{if(v===f||v===h)return!0;if(v.endsWith("/*")){const y=v.slice(0,-2);return f.startsWith(`${y}/`)}return!1})})){const u=`File type not accepted. Allowed: ${t}`;return s(u),!1}}return!n&&l.length>1?(s("Only one file is allowed"),!1):(i(""),!0)},[e,t,n,s]);return{error:r,validateFiles:a,clearError:()=>i("")}},kg=e=>{const t=["Bytes","KB","MB"],n=Math.floor(Math.log(e)/Math.log(1024));return`${(e/Math.pow(1024,n)).toFixed(2)} ${t[n]}`},cl=({files:e,onRemove:t,disabled:n})=>e.length===0?null:p.jsx(xg,{children:e.map((o,r)=>p.jsxs(Sg,{children:[p.jsxs("div",{className:"flex min-w-[0] flex-col gap-1",children:[p.jsx(Cg,{size:14,children:o.name}),p.jsx(mt,{size:12,children:kg(o.size)})]}),p.jsx(Tg,{type:"button",onClick:()=>t(r),"aria-label":`Remove ${o.name}`,disabled:n,children:p.jsx(Qa,{})})]},`${o.name}-${r}`))}),Mg=({variant:e="default",multiple:t=!1,maxFileSize:n=10,accept:o="image/*,application/pdf",helperText:r="Upload files here",value:i,defaultValue:s,onChange:a,onError:l,onFileRemove:c,disabled:d=!1,hasError:u=!1,errorMessage:f="",className:h="",dropZoneContainerClassName:v="",size:y="md"})=>{const b=i!==void 0,[w,S]=m.useState(s||[]),x=b?i:w,P=n*1024*1024,{error:T,validateFiles:k,clearError:V}=Pg({maxFileSize:P,accept:o,multiple:t,onError:l}),$=(F,z)=>{if(!F||F.length===0)return;const B=Array.from(F);if(!k(B))return;const L=t?[...x,...B]:B;b||S(L),a?.(L,z)},A=F=>{const z=x[F],B=x.filter((L,j)=>j!==F);b||S(B),c?.(z,F),a?.(B),B.length===0&&V()},{isDragging:I,dragHandlers:N}=$g($,d),H=u||!!T,M=f||T;return p.jsxs(yg,{$size:y,className:h,children:[p.jsxs("label",{"aria-label":"File upload area",className:`p-4 ${v}`,children:[p.jsxs(wg,{$variant:e,$isDragging:I,$hasError:H,$disabled:d,role:"button",tabIndex:d?-1:0,"aria-disabled":d,onKeyDown:F=>{(F.key==="Enter"||F.key===" ")&&(F.preventDefault(),F.currentTarget.querySelector("input")?.click())},...N,children:[p.jsx(U,{component:jp,size:"lg",color:d?"var(--color-dark-200)":"var(--color-main-blue-primary)",className:"!text-[5rem]"}),p.jsxs(bg,{$disabled:d,children:[p.jsx("strong",{children:"Click to upload"})," or drag and drop"]}),r&&!H&&p.jsx(Ie,{size:14,color:"var(--color-main-grey)",children:r})]}),p.jsx("input",{type:"file",multiple:t,accept:o,disabled:d,onChange:F=>$(F.target.files,F.nativeEvent),style:{display:"none"},"aria-label":"File input"})]}),H&&M&&p.jsx(Zo,{size:"sm",children:M}),p.jsx(cl,{files:x,onRemove:A,disabled:d})]})},pt={xs:"1rem",sm:"1.25rem",md:"1.5rem",lg:"1.75rem"},Vg=g.div`
917
940
  position: relative;
918
- `,Mg=g.input`
941
+ `,Eg=g.input`
919
942
  position: absolute;
920
- height: ${({$size:e})=>mt[e]};
921
- width: ${({$size:e})=>mt[e]};
943
+ height: ${({$size:e})=>pt[e]};
944
+ width: ${({$size:e})=>pt[e]};
922
945
  inset: 0;
923
946
  cursor: pointer;
924
947
  opacity: 0;
@@ -932,9 +955,9 @@
932
955
  outline-color: var(--color-main-orange-primary);
933
956
  outline-offset: 2px;
934
957
  }
935
- `,Vg=g.div`
936
- height: ${({$size:e})=>mt[e]};
937
- width: ${({$size:e})=>mt[e]};
958
+ `,Dg=g.div`
959
+ height: ${({$size:e})=>pt[e]};
960
+ width: ${({$size:e})=>pt[e]};
938
961
  border: 2px solid;
939
962
  border-radius: 0.25rem;
940
963
  display: flex;
@@ -953,31 +976,31 @@
953
976
 
954
977
  ${({$hasError:e})=>e&&Je}
955
978
  ${({$disabled:e})=>e&&Oe}
956
- ${({$checked:e})=>e&&Eg}
957
- `,Eg=g.css`
979
+ ${({$checked:e})=>e&&Fg}
980
+ `,Fg=g.css`
958
981
  background-color: var(--color-main-orange-primary);
959
982
  border-color: var(--color-main-orange-primary);
960
- `,Dg=g.svg`
961
- height: ${({$size:e})=>mt[e]};
962
- width: ${({$size:e})=>mt[e]};
983
+ `,Ag=g.svg`
984
+ height: ${({$size:e})=>pt[e]};
985
+ width: ${({$size:e})=>pt[e]};
963
986
  color: ${({$disabled:e})=>e?"var(--color-dark-200)":"white"};
964
987
  fill: none;
965
988
  stroke: currentColor;
966
- `,Fg=g.span`
989
+ `,Ig=g.span`
967
990
  display: block;
968
991
  width: ${({$size:e})=>e==="xs"?"50%":"60%"};
969
992
  height: ${({$size:e})=>e==="xs"?"1.5px":"2px"};
970
993
  background-color: white;
971
994
  border-radius: 1px;
972
- `,nr=m.forwardRef(({size:e="md",hasError:t=!1,indeterminate:n=!1,checked:o,disabled:r=!1,onChange:i,className:s,checkboxClassName:a,...l},c)=>{const d=m.useId(),u=l.id??d,h=!!o,f=m.useRef(null),v=m.useCallback(y=>{if(f.current=y,!!c)if(typeof c=="function")try{c(y)}catch{}else c.current=y},[c]);return m.useEffect(()=>{f.current&&(f.current.indeterminate=!!n)},[n]),p.jsxs(kg,{className:s,children:[p.jsx(Mg,{ref:v,type:"checkbox",checked:h||!1,disabled:r,onChange:i,id:u,name:l.name,"aria-invalid":t||void 0,"aria-disabled":r||void 0,"aria-checked":n?"mixed":h?"true":"false",$size:e,...l}),p.jsxs(Vg,{$checked:!!h||!!n,$hasError:t,$disabled:r,$size:e,className:a,children:[h&&!n&&p.jsx(Dg,{$disabled:r,$size:e,viewBox:"0 0 24 24",children:p.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:e==="xs"?2.5:3,d:"M5 13l4 4L19 7"})}),n&&p.jsx(Fg,{$size:e})]})]})});nr.displayName="CheckboxInput";const ll=({children:e,size:t="md",disabled:n=!1,htmlFor:o,onLabelClick:r,className:i,onClick:s,...a})=>{const l=c=>{n||(r&&r(),s&&s(c))};return p.jsx(hn,{size:t,disabled:n,htmlFor:o,onClick:l,className:i,...a,children:e})},Ag=g.section`
995
+ `,or=m.forwardRef(({size:e="md",hasError:t=!1,indeterminate:n=!1,checked:o,disabled:r=!1,onChange:i,className:s,checkboxClassName:a,...l},c)=>{const d=m.useId(),u=l.id??d,f=!!o,h=m.useRef(null),v=m.useCallback(y=>{if(h.current=y,!!c)if(typeof c=="function")try{c(y)}catch{}else c.current=y},[c]);return m.useEffect(()=>{h.current&&(h.current.indeterminate=!!n)},[n]),p.jsxs(Vg,{className:s,children:[p.jsx(Eg,{ref:v,type:"checkbox",checked:f||!1,disabled:r,onChange:i,id:u,name:l.name,"aria-invalid":t||void 0,"aria-disabled":r||void 0,"aria-checked":n?"mixed":f?"true":"false",$size:e,...l}),p.jsxs(Dg,{$checked:!!f||!!n,$hasError:t,$disabled:r,$size:e,className:a,children:[f&&!n&&p.jsx(Ag,{$disabled:r,$size:e,viewBox:"0 0 24 24",children:p.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:e==="xs"?2.5:3,d:"M5 13l4 4L19 7"})}),n&&p.jsx(Ig,{$size:e})]})]})});or.displayName="CheckboxInput";const ul=({children:e,size:t="md",disabled:n=!1,htmlFor:o,onLabelClick:r,className:i,onClick:s,...a})=>{const l=c=>{n||(r&&r(),s&&s(c))};return p.jsx(mn,{size:t,disabled:n,htmlFor:o,onClick:l,className:i,...a,children:e})},Lg=g.section`
973
996
  display: flex;
974
997
  align-items: center;
975
998
  justify-content: center;
976
999
  gap: 1rem;
977
- `,zt=m.forwardRef(({size:e="md",label:t,hasError:n=!1,indeterminate:o=!1,checked:r,disabled:i=!1,onChange:s,onLabelClick:a,className:l,checkboxClassName:c,labelClassName:d,...u},h)=>{const f=m.useId(),v=u.id??f;return p.jsxs(Ag,{className:l,children:[p.jsx(nr,{ref:h,size:e,hasError:n,indeterminate:o,checked:r,disabled:i,onChange:s,checkboxClassName:c,id:v,...u}),t&&p.jsx(ll,{size:e,disabled:i,htmlFor:v,onLabelClick:a,className:d,children:t})]})});zt.displayName="Checkbox";const Ig=g.div`
1000
+ `,Ot=m.forwardRef(({size:e="md",label:t,hasError:n=!1,indeterminate:o=!1,checked:r,disabled:i=!1,onChange:s,onLabelClick:a,className:l,checkboxClassName:c,labelClassName:d,...u},f)=>{const h=m.useId(),v=u.id??h;return p.jsxs(Lg,{className:l,children:[p.jsx(or,{ref:f,size:e,hasError:n,indeterminate:o,checked:r,disabled:i,onChange:s,checkboxClassName:c,id:v,...u}),t&&p.jsx(ul,{size:e,disabled:i,htmlFor:v,onLabelClick:a,className:d,children:t})]})});Ot.displayName="Checkbox";const Rg=g.div`
978
1001
  position: relative;
979
1002
  display: inline-block;
980
- `,Lg=g.input`
1003
+ `,_g=g.input`
981
1004
  ${Ze}
982
1005
  text-align: center;
983
1006
  padding: 0;
@@ -991,15 +1014,15 @@
991
1014
  &[type='number'] {
992
1015
  -moz-appearance: textfield;
993
1016
  }
994
- ${({$size:e})=>_g[e]}
995
- ${({$variant:e})=>e&&Rg[e??"outlined"]}
1017
+ ${({$size:e})=>Ng[e]}
1018
+ ${({$variant:e})=>e&&Bg[e??"outlined"]}
996
1019
  ${({$hasError:e})=>e&&Je}
997
1020
  ${({$disabled:e})=>e&&Oe}
998
1021
 
999
1022
  &:focus {
1000
1023
  border: 2px solid var(--color-main-blue-primary);
1001
1024
  }
1002
- `,Rg={outlined:`
1025
+ `,Bg={outlined:`
1003
1026
  background-color: var(--color-main-white);
1004
1027
  border: 2px solid var(--color-main-input-borders);
1005
1028
 
@@ -1018,7 +1041,7 @@
1018
1041
  background-color: var(--color-main-white);
1019
1042
  border: 2px solid var(--color-main-blue-primary);
1020
1043
  }
1021
- `},_g={xs:`
1044
+ `},Ng={xs:`
1022
1045
  padding: 0.25rem;
1023
1046
  width: 2rem;
1024
1047
  height: 2rem;
@@ -1038,13 +1061,13 @@
1038
1061
  width: 3.5rem;
1039
1062
  height: 4rem;
1040
1063
  ${D[40]}
1041
- `},or=m.forwardRef(({size:e="md",hasError:t=!1,variant:n="outlined",disabled:o=!1,className:r,maxLength:i=1,type:s="text",...a},l)=>{const c=m.useId(),d=a.id??c;return p.jsx(Ig,{children:p.jsx(Lg,{ref:l,$size:e,$hasError:t,$disabled:o,$variant:n,className:r,maxLength:i,type:s,disabled:o,id:d,"aria-invalid":t||void 0,"aria-disabled":o||void 0,...a})})});or.displayName="PinInput";const cl=(e,t,n,o,r,i,s="text",a,l)=>{const c=e.target.value;if(c.length>1)return;const d=i??r.length;if(s==="number"&&c&&!/^\d$/.test(c))return;const u=[...n];u[t]=c,o(u);const h=u.join("");a?.(h),c&&t<i-1&&r[t+1].current?.focus(),u.every(f=>f!=="")&&u.length>=d&&l?.(h)},ul=(e,t,n,o,r,i)=>{if(e.key==="Backspace"&&!n[t]&&t>0){if(n[t]){if(r){o[t-1].current?.focus();const s=[...n];s[t-1]="",r(s),i?.(s.join(""))}return}if(t>0&&(o[t-1].current?.focus(),r)){const s=[...n];s[t-1]="",r(s),i?.(s.join(""))}}e.key==="ArrowLeft"&&t>0&&o[t-1]?.current?.focus(),e.key==="ArrowRight"&&t<o.length-1&&o[t+1]?.current?.focus()},dl=(e,t,n,o,r,i,s="text",a,l)=>{e.preventDefault();const c=e.clipboardData.getData("text");if(!c)return;const d=i??r.length,u=[...n];for(let y=0;y<c.length;y++){const b=t+y;if(b>=d)break;const w=c[y];s==="number"&&!/^\d$/.test(w)||(u[b]=w)}o(u),a?.(u.join(""));const h=u.findIndex(y=>y===""),f=h!==-1?Math.min(Math.max(h,t),d-1):d-1;r[f].current?.focus();const v=u.join("");u.every(y=>y!=="")&&u.length>=d&&l?.(v)},fl=e=>Array(e).fill(null).map(()=>m.createRef()),Ng=(e,t,n="text")=>!(e.length!==t||n==="number"&&!/^\d+$/.test(e)),Bg=g.div`
1064
+ `},rr=m.forwardRef(({size:e="md",hasError:t=!1,variant:n="outlined",disabled:o=!1,className:r,maxLength:i=1,type:s="text",...a},l)=>{const c=m.useId(),d=a.id??c;return p.jsx(Rg,{children:p.jsx(_g,{ref:l,$size:e,$hasError:t,$disabled:o,$variant:n,className:r,maxLength:i,type:s,disabled:o,id:d,"aria-invalid":t||void 0,"aria-disabled":o||void 0,...a})})});rr.displayName="PinInput";const dl=(e,t,n,o,r,i,s="text",a,l)=>{const c=e.target.value;if(c.length>1)return;const d=i??r.length;if(s==="number"&&c&&!/^\d$/.test(c))return;const u=[...n];u[t]=c,o(u);const f=u.join("");a?.(f),c&&t<i-1&&r[t+1].current?.focus(),u.every(h=>h!=="")&&u.length>=d&&l?.(f)},fl=(e,t,n,o,r,i)=>{if(e.key==="Backspace"&&!n[t]&&t>0){if(n[t]){if(r){o[t-1].current?.focus();const s=[...n];s[t-1]="",r(s),i?.(s.join(""))}return}if(t>0&&(o[t-1].current?.focus(),r)){const s=[...n];s[t-1]="",r(s),i?.(s.join(""))}}e.key==="ArrowLeft"&&t>0&&o[t-1]?.current?.focus(),e.key==="ArrowRight"&&t<o.length-1&&o[t+1]?.current?.focus()},hl=(e,t,n,o,r,i,s="text",a,l)=>{e.preventDefault();const c=e.clipboardData.getData("text");if(!c)return;const d=i??r.length,u=[...n];for(let y=0;y<c.length;y++){const b=t+y;if(b>=d)break;const w=c[y];s==="number"&&!/^\d$/.test(w)||(u[b]=w)}o(u),a?.(u.join(""));const f=u.findIndex(y=>y===""),h=f!==-1?Math.min(Math.max(f,t),d-1):d-1;r[h].current?.focus();const v=u.join("");u.every(y=>y!=="")&&u.length>=d&&l?.(v)},ml=e=>Array(e).fill(null).map(()=>m.createRef()),zg=(e,t,n="text")=>!(e.length!==t||n==="number"&&!/^\d+$/.test(e)),Og=g.div`
1042
1065
  display: flex;
1043
1066
  gap: 8px;
1044
1067
  align-items: center;
1045
- `,rr=({length:e=6,size:t="md",variant:n="outlined",hasError:o=!1,type:r="number",onChange:i,onComplete:s,className:a,pinInputClassName:l})=>{const[c,d]=m.useState(Array(e).fill("")),u=m.useMemo(()=>fl(e),[e]);return p.jsx(Bg,{className:a,children:Array.from({length:e},(h,f)=>p.jsx(or,{className:l,size:t,variant:n,hasError:o,value:c[f],onChange:v=>cl(v,f,c,d,u,e,r,i,s),onKeyDown:v=>ul(v,f,c,u,d,i),onPaste:v=>dl(v,f,c,d,u,e,r,i,s),ref:u[f]},f))})};rr.displayName="PinInputGroup";const zg=g.div`
1068
+ `,ir=({length:e=6,size:t="md",variant:n="outlined",hasError:o=!1,type:r="number",onChange:i,onComplete:s,className:a,pinInputClassName:l})=>{const[c,d]=m.useState(Array(e).fill("")),u=m.useMemo(()=>ml(e),[e]);return p.jsx(Og,{className:a,children:Array.from({length:e},(f,h)=>p.jsx(rr,{className:l,size:t,variant:n,hasError:o,value:c[h],onChange:v=>dl(v,h,c,d,u,e,r,i,s),onKeyDown:v=>fl(v,h,c,u,d,i),onPaste:v=>hl(v,h,c,d,u,e,r,i,s),ref:u[h]},h))})};ir.displayName="PinInputGroup";const Hg=g.div`
1046
1069
  position: relative;
1047
- `,Og=g.input`
1070
+ `,jg=g.input`
1048
1071
  position: absolute;
1049
1072
  height: 1.5rem;
1050
1073
  width: 1.5rem;
@@ -1062,9 +1085,9 @@
1062
1085
  outline-color: var(--color-main-orange-primary);
1063
1086
  outline-offset: 2px;
1064
1087
  }
1065
- `,Hg=g.css`
1088
+ `,Gg=g.css`
1066
1089
  border-color: var(--color-main-orange-primary);
1067
- `,jg=g.div`
1090
+ `,Ug=g.div`
1068
1091
  height: 1.5rem;
1069
1092
  width: 1.5rem;
1070
1093
  border: 2px solid var(--color-main-input-borders);
@@ -1085,8 +1108,8 @@
1085
1108
  ${Oe}
1086
1109
  border: 2px solid var(--color-dark-200) !important;
1087
1110
  `}
1088
- ${({$checked:e})=>e&&Hg}
1089
- `,Gg=g.span`
1111
+ ${({$checked:e})=>e&&Gg}
1112
+ `,Wg=g.span`
1090
1113
  display: block;
1091
1114
  height: 0.625rem;
1092
1115
  width: 0.625rem;
@@ -1095,21 +1118,21 @@
1095
1118
  background-color: ${({$disabled:e})=>e?"var(--color-dark-200)":"var(--color-main-orange-primary)"};
1096
1119
  opacity: ${({$checked:e})=>e?1:0};
1097
1120
  transform: ${({$checked:e})=>e?"scale(1)":"scale(0.6)"};
1098
- `,ir=m.forwardRef(({hasError:e=!1,checked:t,disabled:n=!1,onChange:o,className:r,dotClassName:i,...s},a)=>{const l=m.useId(),c=s.id??l,d=!!t,{size:u,...h}=s;return p.jsxs(zg,{className:r,children:[p.jsx(Og,{ref:a,type:"radio",id:c,checked:d||!1,disabled:n,onChange:o,"aria-invalid":e||void 0,"aria-disabled":n||void 0,"aria-checked":d?"true":"false",...h}),p.jsx(jg,{$checked:!!d,$hasError:e,$disabled:n,className:i,children:p.jsx(Gg,{$disabled:n,$checked:d})})]})});ir.displayName="RadioInputDot";const sr=({children:e,htmlFor:t,className:n,disabled:o=!1,size:r="md",...i})=>p.jsx(hn,{className:n,htmlFor:t,size:r,disabled:o,...i,children:e});sr.displayName="RadioInputLabel";const Ug=g.section`
1121
+ `,sr=m.forwardRef(({hasError:e=!1,checked:t,disabled:n=!1,onChange:o,className:r,dotClassName:i,...s},a)=>{const l=m.useId(),c=s.id??l,d=!!t,{size:u,...f}=s;return p.jsxs(Hg,{className:r,children:[p.jsx(jg,{ref:a,type:"radio",id:c,checked:d||!1,disabled:n,onChange:o,"aria-invalid":e||void 0,"aria-disabled":n||void 0,"aria-checked":d?"true":"false",...f}),p.jsx(Ug,{$checked:!!d,$hasError:e,$disabled:n,className:i,children:p.jsx(Wg,{$disabled:n,$checked:d})})]})});sr.displayName="RadioInputDot";const ar=({children:e,htmlFor:t,className:n,disabled:o=!1,size:r="md",...i})=>p.jsx(mn,{className:n,htmlFor:t,size:r,disabled:o,...i,children:e});ar.displayName="RadioInputLabel";const Kg=g.section`
1099
1122
  display: flex;
1100
1123
  align-items: center;
1101
1124
  justify-content: center;
1102
1125
  gap: 1rem;
1103
- `,ar=m.forwardRef(({size:e="md",label:t,hasError:n=!1,checked:o,disabled:r=!1,onChange:i,className:s,dotClassName:a,labelClassName:l,...c},d)=>{const u=m.useId(),h=c.id??u;return p.jsxs(Ug,{className:s,children:[p.jsx(ir,{ref:d,size:e,hasError:n,checked:o,disabled:r,onChange:i,dotClassName:a,id:h,...c}),t&&p.jsx(sr,{size:e,disabled:r,htmlFor:h,className:l,children:t})]})});ar.displayName="RadioInput";const Kg=({name:e,required:t=!1,onChange:n,onOptionSelect:o,onRadioChange:r,onPinComplete:i,options:s=[]})=>{const[a,l,c]=Mc.useField(e),d=m.useMemo(()=>!!(l.error&&(l.touched||l.value)),[l.error,l.touched,l.value]),u=m.useMemo(()=>d?l.error:void 0,[d,l.error]),h=m.useMemo(()=>a.name||e,[a.name,e]),f=m.useMemo(()=>({required:t||void 0,"aria-required":t||void 0,"aria-invalid":d||void 0,"aria-describedby":d?`${h}-error`:void 0}),[t,d,h]),v=m.useCallback(T=>{n?n(T):a.onChange(T)},[n,a]),y=m.useCallback(T=>{n?n(T):a.onChange(T)},[n,a]),b=m.useCallback(T=>{c.setValue(T.target.checked)},[c]),w=m.useCallback(T=>{a.onChange(T);const k=s.find(V=>String(V.value)===T.target.value);k&&o?.(k)},[a,s,o]),C=m.useCallback((T,k)=>{const V=T.target.value,$=typeof k=="number"?Number(V):V;c.setValue($),r?.(T)},[c,r]),x=m.useCallback(T=>{c.setValue(T)},[c]),P=m.useCallback(T=>{c.setValue(T),i?.(T)},[c,i]);return{field:a,meta:l,helpers:c,hasError:d,errorMessage:u,inputId:h,ariaProps:f,handleStandardChange:v,handleTextAreaChange:y,handleCheckboxChange:b,handleSelectChange:w,handleRadioChange:C,handlePinChange:x,handlePinComplete:P}},Wg=["text","email","number","tel","url","date","datetime-local","time"],qg=g.div`
1126
+ `,lr=m.forwardRef(({size:e="md",label:t,hasError:n=!1,checked:o,disabled:r=!1,onChange:i,className:s,dotClassName:a,labelClassName:l,...c},d)=>{const u=m.useId(),f=c.id??u;return p.jsxs(Kg,{className:s,children:[p.jsx(sr,{ref:d,size:e,hasError:n,checked:o,disabled:r,onChange:i,dotClassName:a,id:f,...c}),t&&p.jsx(ar,{size:e,disabled:r,htmlFor:f,className:l,children:t})]})});lr.displayName="RadioInput";const qg=({name:e,required:t=!1,onChange:n,onOptionSelect:o,onRadioChange:r,onPinComplete:i,options:s=[]})=>{const[a,l,c]=Vc.useField(e),d=m.useMemo(()=>!!(l.error&&(l.touched||l.value)),[l.error,l.touched,l.value]),u=m.useMemo(()=>d?l.error:void 0,[d,l.error]),f=m.useMemo(()=>a.name||e,[a.name,e]),h=m.useMemo(()=>({required:t||void 0,"aria-required":t||void 0,"aria-invalid":d||void 0,"aria-describedby":d?`${f}-error`:void 0}),[t,d,f]),v=m.useCallback(T=>{n?n(T):a.onChange(T)},[n,a]),y=m.useCallback(T=>{n?n(T):a.onChange(T)},[n,a]),b=m.useCallback(T=>{c.setValue(T.target.checked)},[c]),w=m.useCallback(T=>{a.onChange(T);const k=s.find(V=>String(V.value)===T.target.value);k&&o?.(k)},[a,s,o]),S=m.useCallback((T,k)=>{const V=T.target.value,$=typeof k=="number"?Number(V):V;c.setValue($),r?.(T)},[c,r]),x=m.useCallback(T=>{c.setValue(T)},[c]),P=m.useCallback(T=>{c.setValue(T),i?.(T)},[c,i]);return{field:a,meta:l,helpers:c,hasError:d,errorMessage:u,inputId:f,ariaProps:h,handleStandardChange:v,handleTextAreaChange:y,handleCheckboxChange:b,handleSelectChange:w,handleRadioChange:S,handlePinChange:x,handlePinComplete:P}},Yg=["text","email","number","tel","url","date","datetime-local","time"],Xg=g.div`
1104
1127
  display: flex;
1105
1128
  flex-direction: column;
1106
1129
  gap: 0.75rem;
1107
- `,hl=({type:e,inputId:t,name:n,size:o,hasError:r,disabled:i,placeholder:s,inputClassName:a,fieldValue:l,ariaProps:c,options:d=[],onSelectChange:u,optionClassName:h,optionsClassName:f,checkboxLabel:v,onCheckboxChange:y,radioName:b,onRadioChange:w,pinLength:C=6,pinType:x="number",onPinChange:P,onPinComplete:T,onStandardChange:k,onTextAreaChange:V,leftIcon:$,rightIcon:A,iconSize:I,iconColor:B,additionalProps:H={}})=>{switch(e){case"textarea":return p.jsx(er,{id:t,name:n,className:a,hasError:r,disabled:i,value:l??"",size:o,placeholder:s,onChange:V,...H,...c});case"select":{const M=H,{optionClassName:F,optionsClassName:z,...N}=M,L=F??h,j=z??f;return p.jsx(gn,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,value:l??"",onChange:u,options:d,placeholder:s||"Select",optionsClassName:j,optionClassName:L,...N,...c})}case"checkbox":return p.jsx(zt,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,checked:!!l,label:v,onChange:y,...H,...c});case"radio":{const M=d;return p.jsx(qg,{children:M.map(F=>p.jsx(ar,{name:b||n,value:F.value,label:F.label,size:o,hasError:r,disabled:i,checked:l===F.value,onChange:z=>w?.(z,F.value),...c},F.value))})}case"pin":return p.jsx(rr,{length:C,type:x,size:o,hasError:r,onChange:P,onComplete:T,...H,...c});case"password":{const{...M}=H;return p.jsx(tl,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,placeholder:s,leftIcon:$,iconSize:I,iconColor:B,onChange:k,...M,...c})}case"search":return p.jsx(tr,{className:a,size:o,placeholder:s,leftIcon:$,rightIcon:A,iconSize:I,iconColor:B,onSearch:H.onSearch,...c});default:return p.jsx(Zo,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,placeholder:s,type:Wg.includes(e)?e:"text",leftIcon:$,rightIcon:A,iconSize:I,iconColor:B,value:l??"",onChange:k,...H,...c})}};hl.displayName="FieldRenderer";const Yg=g.div`
1130
+ `,pl=({type:e,inputId:t,name:n,size:o,hasError:r,disabled:i,placeholder:s,inputClassName:a,fieldValue:l,ariaProps:c,options:d=[],onSelectChange:u,optionClassName:f,optionsClassName:h,checkboxLabel:v,onCheckboxChange:y,radioName:b,onRadioChange:w,pinLength:S=6,pinType:x="number",onPinChange:P,onPinComplete:T,onStandardChange:k,onTextAreaChange:V,leftIcon:$,rightIcon:A,iconSize:I,iconColor:N,additionalProps:H={}})=>{switch(e){case"textarea":return p.jsx(tr,{id:t,name:n,className:a,hasError:r,disabled:i,value:l??"",size:o,placeholder:s,onChange:V,...H,...c});case"select":{const M=H,{optionClassName:F,optionsClassName:z,...B}=M,L=F??f,j=z??h;return p.jsx(vn,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,value:l??"",onChange:u,options:d,placeholder:s||"Select",optionsClassName:j,optionClassName:L,...B,...c})}case"checkbox":return p.jsx(Ot,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,checked:!!l,label:v,onChange:y,...H,...c});case"radio":{const M=d;return p.jsx(Xg,{children:M.map(F=>p.jsx(lr,{name:b||n,value:F.value,label:F.label,size:o,hasError:r,disabled:i,checked:l===F.value,onChange:z=>w?.(z,F.value),...c},F.value))})}case"pin":return p.jsx(ir,{length:S,type:x,size:o,hasError:r,onChange:P,onComplete:T,...H,...c});case"password":{const{...M}=H;return p.jsx(nl,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,placeholder:s,leftIcon:$,iconSize:I,iconColor:N,onChange:k,...M,...c})}case"search":return p.jsx(nr,{className:a,size:o,placeholder:s,leftIcon:$,rightIcon:A,iconSize:I,iconColor:N,onSearch:H.onSearch,...c});default:return p.jsx(Jo,{id:t,name:n,className:a,hasError:r,disabled:i,size:o,placeholder:s,type:Yg.includes(e)?e:"text",leftIcon:$,rightIcon:A,iconSize:I,iconColor:N,value:l??"",onChange:k,...H,...c})}};pl.displayName="FieldRenderer";const Zg=g.div`
1108
1131
  display: flex;
1109
1132
  flex-direction: column;
1110
1133
  gap: 0.5rem;
1111
1134
  width: 100%;
1112
- `,Xg=m.memo(({inputId:e,label:t,size:n,required:o,disabled:r,hasError:i,errorMessage:s,isCheckbox:a=!1,className:l,labelClassName:c,messageErrorClassName:d,children:u})=>p.jsxs(Yg,{className:l,children:[t&&!a&&p.jsx(hn,{htmlFor:e,size:n,required:o,disabled:r,className:c,children:t}),u,i&&s&&p.jsx(Xo,{id:`${e}-error`,size:n,className:d,children:s})]})),Zg=({id:e,name:t,label:n,type:o="text",size:r="md",placeholder:i,disabled:s=!1,required:a=!1,options:l=[],checkboxLabel:c,radioName:d,pinLength:u=6,pinType:h="number",rows:f=4,className:v,inputClassName:y,labelClassName:b,messageErrorClassName:w,leftIcon:C,rightIcon:x,iconSize:P,iconColor:T,onOptionSelect:k,onRadioChange:V,onPinComplete:$,onChange:A,optionsClassName:I,optionClassName:B,...H})=>{const{field:M,hasError:F,errorMessage:z,inputId:N,ariaProps:L,handleStandardChange:j,handleTextAreaChange:te,handleCheckboxChange:J,handleSelectChange:ue,handleRadioChange:gt,handlePinChange:G,handlePinComplete:Z}=Kg({name:t,required:a,onChange:A,onOptionSelect:k,onRadioChange:V,onPinComplete:$,options:l}),W=e?.toString?.()||N;return p.jsx(Xg,{inputId:W,label:n,size:r,required:a,disabled:s,hasError:F,errorMessage:z,isCheckbox:o==="checkbox",className:v,labelClassName:b,messageErrorClassName:w,children:p.jsx(hl,{type:o,inputId:W,name:t,size:r,hasError:F,disabled:s,placeholder:i,inputClassName:y,fieldValue:M.value,ariaProps:L,options:l,onSelectChange:ue,checkboxLabel:c,onCheckboxChange:J,radioName:d,onRadioChange:gt,pinLength:u,pinType:h,rows:f,onPinChange:G,onPinComplete:Z,onStandardChange:j,onTextAreaChange:te,leftIcon:C,rightIcon:x,iconSize:P,iconColor:T,optionsClassName:I,optionClassName:B,additionalProps:H})})},ml={initial:{opacity:0,scale:.95},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.95},transition:{duration:.2,ease:"easeInOut"},layout:!1},lr={initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.3,ease:"easeInOut"}},Jg={fromBottom:{initial:{opacity:0,y:20},animate:{opacity:1,y:0},exit:{opacity:0,y:20},transition:{duration:.2,ease:"easeInOut"}},fromTop:{initial:{opacity:0,y:-20},animate:{opacity:1,y:0},exit:{opacity:0,y:-20},transition:{duration:.2,ease:"easeInOut"}},fromLeft:{initial:{opacity:0,x:-20},animate:{opacity:1,x:0},exit:{opacity:0,x:-20},transition:{duration:.2,ease:"easeInOut"}},fromRight:{initial:{opacity:0,x:20},animate:{opacity:1,x:0},exit:{opacity:0,x:20},transition:{duration:.2,ease:"easeInOut"}}},pl={initial:{height:0,opacity:0,y:-6},animate:{height:"auto",opacity:1,y:0},exit:{height:0,opacity:0,y:-6},transition:{duration:.2,ease:"easeInOut"}},Qg=g(De.div)`
1135
+ `,Jg=m.memo(({inputId:e,label:t,size:n,required:o,disabled:r,hasError:i,errorMessage:s,isCheckbox:a=!1,className:l,labelClassName:c,messageErrorClassName:d,children:u})=>p.jsxs(Zg,{className:l,children:[t&&!a&&p.jsx(mn,{htmlFor:e,size:n,required:o,disabled:r,className:c,children:t}),u,i&&s&&p.jsx(Zo,{id:`${e}-error`,size:n,className:d,children:s})]})),Qg=({id:e,name:t,label:n,type:o="text",size:r="md",placeholder:i,disabled:s=!1,required:a=!1,options:l=[],checkboxLabel:c,radioName:d,pinLength:u=6,pinType:f="number",rows:h=4,className:v,inputClassName:y,labelClassName:b,messageErrorClassName:w,leftIcon:S,rightIcon:x,iconSize:P,iconColor:T,onOptionSelect:k,onRadioChange:V,onPinComplete:$,onChange:A,optionsClassName:I,optionClassName:N,...H})=>{const{field:M,hasError:F,errorMessage:z,inputId:B,ariaProps:L,handleStandardChange:j,handleTextAreaChange:te,handleCheckboxChange:J,handleSelectChange:ue,handleRadioChange:vt,handlePinChange:G,handlePinComplete:Z}=qg({name:t,required:a,onChange:A,onOptionSelect:k,onRadioChange:V,onPinComplete:$,options:l}),K=e?.toString?.()||B;return p.jsx(Jg,{inputId:K,label:n,size:r,required:a,disabled:s,hasError:F,errorMessage:z,isCheckbox:o==="checkbox",className:v,labelClassName:b,messageErrorClassName:w,children:p.jsx(pl,{type:o,inputId:K,name:t,size:r,hasError:F,disabled:s,placeholder:i,inputClassName:y,fieldValue:M.value,ariaProps:L,options:l,onSelectChange:ue,checkboxLabel:c,onCheckboxChange:J,radioName:d,onRadioChange:vt,pinLength:u,pinType:f,rows:h,onPinChange:G,onPinComplete:Z,onStandardChange:j,onTextAreaChange:te,leftIcon:S,rightIcon:x,iconSize:P,iconColor:T,optionsClassName:I,optionClassName:N,additionalProps:H})})},gl={initial:{opacity:0,scale:.95},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.95},transition:{duration:.2,ease:"easeInOut"},layout:!1},cr={initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.3,ease:"easeInOut"}},e0={fromBottom:{initial:{opacity:0,y:20},animate:{opacity:1,y:0},exit:{opacity:0,y:20},transition:{duration:.2,ease:"easeInOut"}},fromTop:{initial:{opacity:0,y:-20},animate:{opacity:1,y:0},exit:{opacity:0,y:-20},transition:{duration:.2,ease:"easeInOut"}},fromLeft:{initial:{opacity:0,x:-20},animate:{opacity:1,x:0},exit:{opacity:0,x:-20},transition:{duration:.2,ease:"easeInOut"}},fromRight:{initial:{opacity:0,x:20},animate:{opacity:1,x:0},exit:{opacity:0,x:20},transition:{duration:.2,ease:"easeInOut"}}},vl={initial:{height:0,opacity:0,y:-6},animate:{height:"auto",opacity:1,y:0},exit:{height:0,opacity:0,y:-6},transition:{duration:.2,ease:"easeInOut"}},t0=g(De.div)`
1113
1136
  position: fixed;
1114
1137
  inset: 0;
1115
1138
  z-index: 50;
@@ -1123,7 +1146,7 @@
1123
1146
  @media (max-width: 768px) {
1124
1147
  padding: 0.5rem;
1125
1148
  }
1126
- `,e0=g(De.div)`
1149
+ `,n0=g(De.div)`
1127
1150
  position: relative;
1128
1151
  display: flex;
1129
1152
  flex-direction: column;
@@ -1150,7 +1173,7 @@
1150
1173
  outline: none;
1151
1174
  box-shadow: var(--shadow-hover-black-card);
1152
1175
  }
1153
- `,t0=g.button`
1176
+ `,o0=g.button`
1154
1177
  position: absolute;
1155
1178
  top: 1rem;
1156
1179
  right: 1rem;
@@ -1169,7 +1192,7 @@
1169
1192
  transform: scale(1.1);
1170
1193
  outline: none;
1171
1194
  }
1172
- `,n0=e=>{const t=m.useRef(null),n=m.useRef(null);return m.useEffect(()=>{if(!e)return;n.current=document.activeElement;const o=t.current,r=()=>{o&&(o.hasAttribute("tabindex")||o.setAttribute("tabindex","-1"),o.focus())},i=window.setTimeout(r,0),s=l=>{const c=["a[href]","area[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])","iframe","object","embed",'[tabindex]:not([tabindex="-1"])','[contenteditable="true"]'];return Array.from(l.querySelectorAll(c.join(","))).filter(d=>!!(d.offsetWidth||d.offsetHeight||d.getClientRects().length))},a=l=>{if(l.key!=="Tab"||!o)return;const c=s(o);if(c.length===0){l.preventDefault(),o.focus();return}const d=c[0],u=c[c.length-1],h=document.activeElement;!l.shiftKey&&h===u?(l.preventDefault(),d.focus()):l.shiftKey&&h===d&&(l.preventDefault(),u.focus())};return document.addEventListener("keydown",a),()=>{window.clearTimeout(i),document.removeEventListener("keydown",a),n.current&&n.current.focus()}},[e]),t},o0=(e,t,n=!0)=>{m.useEffect(()=>{if(!e||!n)return;const o=r=>{r.key==="Escape"&&t()};return document.addEventListener("keydown",o),()=>document.removeEventListener("keydown",o)},[e,t,n])},r0=e=>{m.useEffect(()=>(e?document.body.style.overflow="hidden":document.body.style.overflow="",()=>{document.body.style.overflow=""}),[e])},gl=({isOpen:e,onClose:t,children:n,className:o,closeOnBackdropClick:r=!0,showCloseButton:i=!1,size:s="md",fullScreen:a=!1,closeOnEsc:l=!0,ariaLabel:c,ariaLabelledBy:d,ariaDescribedBy:u})=>{const h=n0(e);o0(e,t,l),r0(e);const f=y=>{r&&y.target===y.currentTarget&&t()},v=p.jsx(Lt,{children:e&&p.jsx(Qg,{...lr,onClick:f,children:p.jsxs(e0,{...ml,ref:h,$size:s,$fullScreen:a,className:o,onClick:y=>y.stopPropagation(),role:"dialog","aria-modal":"true","aria-label":c,"aria-labelledby":c?void 0:d,"aria-describedby":u,children:[i&&p.jsx(t0,{className:`${pn} cursor-pointer`,onClick:t,"aria-label":"Close dialog",children:p.jsx(U,{component:Ja,size:"sm"})}),n]})})});return typeof document>"u"?v:Vn.createPortal(v,document.body)},i0=g.div`
1195
+ `,r0=e=>{const t=m.useRef(null),n=m.useRef(null);return m.useEffect(()=>{if(!e)return;n.current=document.activeElement;const o=t.current,r=()=>{o&&(o.hasAttribute("tabindex")||o.setAttribute("tabindex","-1"),o.focus())},i=window.setTimeout(r,0),s=l=>{const c=["a[href]","area[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])","iframe","object","embed",'[tabindex]:not([tabindex="-1"])','[contenteditable="true"]'];return Array.from(l.querySelectorAll(c.join(","))).filter(d=>!!(d.offsetWidth||d.offsetHeight||d.getClientRects().length))},a=l=>{if(l.key!=="Tab"||!o)return;const c=s(o);if(c.length===0){l.preventDefault(),o.focus();return}const d=c[0],u=c[c.length-1],f=document.activeElement;!l.shiftKey&&f===u?(l.preventDefault(),d.focus()):l.shiftKey&&f===d&&(l.preventDefault(),u.focus())};return document.addEventListener("keydown",a),()=>{window.clearTimeout(i),document.removeEventListener("keydown",a),n.current&&n.current.focus()}},[e]),t},i0=(e,t,n=!0)=>{m.useEffect(()=>{if(!e||!n)return;const o=r=>{r.key==="Escape"&&t()};return document.addEventListener("keydown",o),()=>document.removeEventListener("keydown",o)},[e,t,n])},s0=e=>{m.useEffect(()=>(e?document.body.style.overflow="hidden":document.body.style.overflow="",()=>{document.body.style.overflow=""}),[e])},yl=({isOpen:e,onClose:t,children:n,className:o,closeOnBackdropClick:r=!0,showCloseButton:i=!1,size:s="md",fullScreen:a=!1,closeOnEsc:l=!0,ariaLabel:c,ariaLabelledBy:d,ariaDescribedBy:u})=>{const f=r0(e);i0(e,t,l),s0(e);const h=y=>{r&&y.target===y.currentTarget&&t()},v=p.jsx(Rt,{children:e&&p.jsx(t0,{...cr,onClick:h,children:p.jsxs(n0,{...gl,ref:f,$size:s,$fullScreen:a,className:o,onClick:y=>y.stopPropagation(),role:"dialog","aria-modal":"true","aria-label":c,"aria-labelledby":c?void 0:d,"aria-describedby":u,children:[i&&p.jsx(o0,{className:`${gn} cursor-pointer`,onClick:t,"aria-label":"Close dialog",children:p.jsx(U,{component:Qa,size:"sm"})}),n]})})});return typeof document>"u"?v:En.createPortal(v,document.body)},a0=g.div`
1173
1196
  display: flex;
1174
1197
  align-items: center;
1175
1198
  justify-content: space-between;
@@ -1202,7 +1225,7 @@
1202
1225
  flex-shrink: 0;
1203
1226
  margin-left: auto;
1204
1227
  }
1205
- `,vl=({showDivider:e=!1,variant:t="default",children:n,className:o,...r})=>p.jsx(i0,{$showDivider:e,$variant:t,className:o,...r,children:n}),s0=g.div`
1228
+ `,wl=({showDivider:e=!1,variant:t="default",children:n,className:o,...r})=>p.jsx(a0,{$showDivider:e,$variant:t,className:o,...r,children:n}),l0=g.div`
1206
1229
  position: relative;
1207
1230
  display: flex;
1208
1231
  flex-direction: column;
@@ -1215,7 +1238,7 @@
1215
1238
  ${({$showTopDivider:e})=>e&&"border-top: 1px solid var(--color-main-light-borders);"}
1216
1239
 
1217
1240
  ${({$showBottomDivider:e})=>e&&"border-bottom: 1px solid var(--color-main-light-borders);"}
1218
- `,yl=({children:e,padded:t=!0,showTopDivider:n=!1,showBottomDivider:o=!1,className:r,...i})=>p.jsx(s0,{$padded:t,$showTopDivider:n,$showBottomDivider:o,className:r,...i,children:e}),a0=g.div`
1241
+ `,bl=({children:e,padded:t=!0,showTopDivider:n=!1,showBottomDivider:o=!1,className:r,...i})=>p.jsx(l0,{$padded:t,$showTopDivider:n,$showBottomDivider:o,className:r,...i,children:e}),c0=g.div`
1219
1242
  display: flex;
1220
1243
  align-items: center;
1221
1244
  width: 100%;
@@ -1231,20 +1254,20 @@
1231
1254
  bottom: 0;
1232
1255
  background: var(--color-main-white);
1233
1256
  `}
1234
- `,wl=({align:e="end",showDivider:t=!1,gap:n=8,sticky:o=!1,children:r,className:i,...s})=>p.jsx(a0,{$align:e,$showDivider:t,$gap:n,$sticky:o,className:i,...s,children:r}),l0=({isOpen:e,onAccept:t,onCancel:n,title:o,subtitle:r,content:i,bodyFooter:s,confirmationLabel:a="I have read and agree to the Terms and Conditions",acceptLabel:l="Accept",cancelLabel:c="Cancel",size:d="md",fullScreen:u=!1,showCloseButton:h=!0,closeOnBackdropClick:f=!1,containerClassName:v,headerClassName:y,bodyClassName:b,footerClassName:w,initiallyConfirmed:C=!1,onConfirmChange:x})=>{const[P,T]=m.useState(C);m.useEffect(()=>{e||T(C)},[e,C]);const k=V=>{T(V),x?.(V)};return p.jsxs(gl,{isOpen:e,onClose:n,size:d,fullScreen:u,showCloseButton:h,closeOnBackdropClick:f,ariaLabelledBy:"tac-title",ariaDescribedBy:"tac-subtitle",className:`${v} !h-fit !max-w-[60rem]`,children:[p.jsx(vl,{showDivider:!0,className:y,children:p.jsx(jr,{id:"tac-title",size:20,children:o})}),p.jsxs(yl,{padded:!0,showBottomDivider:!0,className:b,children:[r&&p.jsx(Ie,{id:"tac-subtitle",size:16,children:r}),i,s]}),p.jsxs(wl,{showDivider:!0,align:"space-between",className:w,children:[p.jsx(zt,{label:a,checked:P,onChange:V=>k(V.target.checked)}),p.jsxs("div",{style:{display:"flex",gap:"0.5rem"},children:[p.jsx(ft,{variant:"secondary",onClick:n,children:c}),p.jsx(ft,{variant:"primary",onClick:t,disabled:!P,children:l})]})]})]})},c0=g.keyframes`
1257
+ `,xl=({align:e="end",showDivider:t=!1,gap:n=8,sticky:o=!1,children:r,className:i,...s})=>p.jsx(c0,{$align:e,$showDivider:t,$gap:n,$sticky:o,className:i,...s,children:r}),u0=({isOpen:e,onAccept:t,onCancel:n,title:o,subtitle:r,content:i,bodyFooter:s,confirmationLabel:a="I have read and agree to the Terms and Conditions",acceptLabel:l="Accept",cancelLabel:c="Cancel",size:d="md",fullScreen:u=!1,showCloseButton:f=!0,closeOnBackdropClick:h=!1,containerClassName:v,headerClassName:y,bodyClassName:b,footerClassName:w,initiallyConfirmed:S=!1,onConfirmChange:x})=>{const[P,T]=m.useState(S);m.useEffect(()=>{e||T(S)},[e,S]);const k=V=>{T(V),x?.(V)};return p.jsxs(yl,{isOpen:e,onClose:n,size:d,fullScreen:u,showCloseButton:f,closeOnBackdropClick:h,ariaLabelledBy:"tac-title",ariaDescribedBy:"tac-subtitle",className:`${v} !h-fit !max-w-[60rem]`,children:[p.jsx(wl,{showDivider:!0,className:y,children:p.jsx(Ur,{id:"tac-title",size:20,children:o})}),p.jsxs(bl,{padded:!0,showBottomDivider:!0,className:b,children:[r&&p.jsx(Ie,{id:"tac-subtitle",size:16,children:r}),i,s]}),p.jsxs(xl,{showDivider:!0,align:"space-between",className:w,children:[p.jsx(Ot,{label:a,checked:P,onChange:V=>k(V.target.checked)}),p.jsxs("div",{style:{display:"flex",gap:"0.5rem"},children:[p.jsx(ht,{variant:"secondary",onClick:n,children:c}),p.jsx(ht,{variant:"primary",onClick:t,disabled:!P,children:l})]})]})]})},d0=g.keyframes`
1235
1258
  from {
1236
1259
  opacity: 0;
1237
1260
  }
1238
1261
  to {
1239
1262
  opacity: 1;
1240
1263
  }
1241
- `,u0=g.div`
1264
+ `,f0=g.div`
1242
1265
  position: relative;
1243
1266
  display: inline-block;
1244
- `,d0=g.div`
1267
+ `,h0=g.div`
1245
1268
  display: inline-block;
1246
1269
  cursor: pointer;
1247
- `,f0=e=>{switch(e){case"top":return g.css`
1270
+ `,m0=e=>{switch(e){case"top":return g.css`
1248
1271
  bottom: 100%;
1249
1272
  left: 50%;
1250
1273
  transform: translateX(-50%);
@@ -1264,7 +1287,7 @@
1264
1287
  top: 50%;
1265
1288
  transform: translateY(-50%);
1266
1289
  margin-left: 0.5rem;
1267
- `;default:return g.css``}},h0=g.div`
1290
+ `;default:return g.css``}},p0=g.div`
1268
1291
  position: absolute;
1269
1292
  z-index: 9999;
1270
1293
  pointer-events: auto;
@@ -1281,11 +1304,11 @@
1281
1304
  word-wrap: break-word;
1282
1305
 
1283
1306
  /* Animation */
1284
- animation: ${c0} 0.2s ease-in-out;
1307
+ animation: ${d0} 0.2s ease-in-out;
1285
1308
 
1286
1309
  /* Position based on placement */
1287
- ${({$placement:e})=>f0(e)}
1288
- `,m0=e=>{switch(e){case"top":return g.css`
1310
+ ${({$placement:e})=>m0(e)}
1311
+ `,g0=e=>{switch(e){case"top":return g.css`
1289
1312
  bottom: -0.25rem;
1290
1313
  left: 50%;
1291
1314
  transform: translateX(-50%) rotate(45deg);
@@ -1301,20 +1324,20 @@
1301
1324
  left: -0.25rem;
1302
1325
  top: 50%;
1303
1326
  transform: translateY(-50%) rotate(45deg);
1304
- `;default:return g.css``}},p0=g.div`
1327
+ `;default:return g.css``}},v0=g.div`
1305
1328
  position: absolute;
1306
1329
  width: 0.5rem;
1307
1330
  height: 0.5rem;
1308
1331
  background-color: var(--color-dark-600);
1309
1332
 
1310
- ${({$placement:e})=>m0(e)}
1311
- `,bl=({content:e,children:t,placement:n="bottom",trigger:o="hover",className:r="",arrowClassName:i="",delay:s=200,showArrow:a=!0})=>{const[l,c]=m.useState(!1),d=m.useRef(null),u=m.useRef(null),h=m.useRef(null);m.useEffect(()=>{if(o!=="click"||!l)return;const w=C=>{u.current&&!u.current.contains(C.target)&&h.current&&!h.current.contains(C.target)&&c(!1)};return document.addEventListener("mousedown",w),()=>document.removeEventListener("mousedown",w)},[l,o]),m.useEffect(()=>()=>{d.current&&clearTimeout(d.current)},[]);const b=o==="hover"?{onMouseEnter:()=>{d.current&&clearTimeout(d.current),d.current=setTimeout(()=>c(!0),s)},onMouseLeave:()=>{d.current&&clearTimeout(d.current),d.current=setTimeout(()=>c(!1),100)}}:{onClick:()=>{c(w=>!w)}};return p.jsxs(u0,{children:[p.jsx(d0,{ref:h,...b,children:t}),l&&p.jsxs(h0,{ref:u,$placement:n,className:r,role:"tooltip","aria-hidden":!l,children:[e,a&&p.jsx(p0,{$placement:n,className:i})]})]})};bl.displayName="Tooltip";const cr=m.createContext(void 0),xl=({children:e})=>{const[t,n]=m.useState(!0),[o,r]=m.useState(!1);return p.jsx(cr.Provider,{value:{isCollapsed:t,setIsCollapsed:n,isMobileOpen:o,setIsMobileOpen:r},children:e})},ur=()=>{const e=m.useContext(cr);if(!e)throw new Error("useSidebar must be used within a SidebarProvider");return e},dr=(e=[],t=[])=>!t||t.length===0?!1:t.includes("all")?!0:e.map(o=>o.name).some(o=>t.includes(o)),g0=g.css`
1333
+ ${({$placement:e})=>g0(e)}
1334
+ `,Sl=({content:e,children:t,placement:n="bottom",trigger:o="hover",className:r="",arrowClassName:i="",delay:s=200,showArrow:a=!0})=>{const[l,c]=m.useState(!1),d=m.useRef(null),u=m.useRef(null),f=m.useRef(null);m.useEffect(()=>{if(o!=="click"||!l)return;const w=S=>{u.current&&!u.current.contains(S.target)&&f.current&&!f.current.contains(S.target)&&c(!1)};return document.addEventListener("mousedown",w),()=>document.removeEventListener("mousedown",w)},[l,o]),m.useEffect(()=>()=>{d.current&&clearTimeout(d.current)},[]);const b=o==="hover"?{onMouseEnter:()=>{d.current&&clearTimeout(d.current),d.current=setTimeout(()=>c(!0),s)},onMouseLeave:()=>{d.current&&clearTimeout(d.current),d.current=setTimeout(()=>c(!1),100)}}:{onClick:()=>{c(w=>!w)}};return p.jsxs(f0,{children:[p.jsx(h0,{ref:f,...b,children:t}),l&&p.jsxs(p0,{ref:u,$placement:n,className:r,role:"tooltip","aria-hidden":!l,children:[e,a&&p.jsx(v0,{$placement:n,className:i})]})]})};Sl.displayName="Tooltip";const ur=m.createContext(void 0),Cl=({children:e})=>{const[t,n]=m.useState(!0),[o,r]=m.useState(!1);return p.jsx(ur.Provider,{value:{isCollapsed:t,setIsCollapsed:n,isMobileOpen:o,setIsMobileOpen:r},children:e})},dr=()=>{const e=m.useContext(ur);if(!e)throw new Error("useSidebar must be used within a SidebarProvider");return e},fr=(e=[],t=[])=>!t||t.length===0?!1:t.includes("all")?!0:e.map(o=>o.name).some(o=>t.includes(o)),y0=g.css`
1312
1335
  display: flex;
1313
1336
  align-items: center;
1314
1337
  justify-content: center;
1315
1338
  flex-shrink: 0;
1316
1339
  user-select: none;
1317
- `,Sl=`
1340
+ `,Tl=`
1318
1341
  width: 100%;
1319
1342
  display: flex;
1320
1343
  align-items: center;
@@ -1331,8 +1354,8 @@
1331
1354
  outline-color: var(--color-main-blue-primary);
1332
1355
  outline-offset: -2px;
1333
1356
  }
1334
- `,v0=g.button`
1335
- ${Sl}
1357
+ `,w0=g.button`
1358
+ ${Tl}
1336
1359
 
1337
1360
  // Level-based padding
1338
1361
  padding: ${({$level:e})=>e===0?"0.75rem 0.875rem":"0.55rem 0.75rem"};
@@ -1351,8 +1374,8 @@
1351
1374
  }
1352
1375
 
1353
1376
  ${({$collapsed:e})=>e?"justify-content: center;":""}
1354
- `,y0=g.button`
1355
- ${Sl}
1377
+ `,b0=g.button`
1378
+ ${Tl}
1356
1379
 
1357
1380
  // Level-based padding
1358
1381
  padding: ${({$level:e})=>e===0?"0.75rem 0.875rem":"0.55rem 0.75rem"};
@@ -1371,36 +1394,36 @@
1371
1394
  }
1372
1395
 
1373
1396
  ${({$collapsed:e})=>e?"justify-content: center;":""}
1374
- `,w0=g.span`
1397
+ `,x0=g.span`
1375
1398
  display: inline-flex;
1376
1399
  align-items: center;
1377
1400
  gap: 0.75rem;
1378
1401
  min-width: 0;
1379
- `,b0=g(Ie)`
1402
+ `,S0=g(Ie)`
1380
1403
  font-weight: ${({$level:e})=>e===0?600:500};
1381
1404
  color: var(--color-main-blue-primary);
1382
1405
  white-space: nowrap;
1383
1406
  overflow: hidden;
1384
1407
  text-overflow: ellipsis;
1385
- `,x0=g(De.div)`
1408
+ `,C0=g(De.div)`
1386
1409
  background-color: transparent;
1387
1410
  overflow: hidden;
1388
1411
  will-change: height, opacity, transform;
1389
- `,S0=g.div`
1412
+ `,T0=g.div`
1390
1413
  width: 100%;
1391
1414
  ${({$level:e})=>e>0?"border-top: 1px solid var(--color-light-200);":""}
1392
- `,C0=g.span`
1415
+ `,$0=g.span`
1393
1416
  width: 0.625rem;
1394
1417
  height: 0.125rem;
1395
1418
  background: var(--color-main-blue-primary);
1396
1419
  border-radius: 1px;
1397
1420
  flex: 0 0 auto;
1398
- `,T0=g.div`
1399
- ${g0}
1421
+ `,P0=g.div`
1422
+ ${y0}
1400
1423
  transform: rotate(${({$open:e})=>e?"90deg":"0deg"});
1401
1424
  pointer-events: none;
1402
1425
  transition: transform 0.3s ease-out;
1403
- `,Cl=({item:e,userPermissions:t,level:n=0,activePath:o,onNavigate:r})=>{const[i,s]=m.useState(!1),{isCollapsed:a,setIsMobileOpen:l,setIsCollapsed:c}=ur(),d=m.useMemo(()=>(e.children||[]).filter(x=>dr(t,x.requiredPermissions)),[e.children,t]);if(!m.useMemo(()=>dr(t,e.requiredPermissions),[t,e.requiredPermissions]))return null;const h=d.length>0,f=e.href||e.path||"",v=!!(f&&o&&o.startsWith(f)),y=()=>{a&&c(!1),s(x=>!x)},b=()=>{a&&c(!1),e.href&&r?.(e.href)},w=async()=>{if(a&&c(!1),!e.path)return;const x=e.target||"_blank";try{typeof window<"u"&&(x==="_blank"?window.open(e.path,"_blank","noopener,noreferrer"):window.location.href=e.path),l&&l(!1)}catch(P){console.error("Error al navegar a microservicio:",P)}},C=()=>p.jsxs(p.Fragment,{children:[p.jsxs(w0,{children:[n>0&&!a&&p.jsx(C0,{}),e.icon&&p.jsx(U,{component:e.icon,size:n===0?"md":"sm",color:"var(--color-main-blue-primary)"}),!a&&p.jsx(b0,{$level:n,size:n===0?16:n===1?14:12,color:"var(--color-dark-700, #374151)",children:e.label})]}),!a&&h&&p.jsx(T0,{$disabled:a,$open:i,children:p.jsx(U,{component:Dp,size:"sm",color:"var(--color-main-blue-primary)"})})]});return p.jsxs(S0,{$level:n,children:[e.href&&!e.path&&!h?p.jsx(v0,{type:"button",onClick:b,$level:n,$collapsed:a,$active:v,title:a?e.label:"",children:C()}):p.jsx(y0,{type:"button",onClick:h?y:e.path?w:b,$level:n,$collapsed:a,$active:v,$expanded:i&&h,title:a?e.label:"",children:C()}),p.jsx(Lt,{initial:!1,children:!a&&i&&h&&p.jsx(x0,{$level:n+1,...pl,children:d.map(x=>p.jsx(Cl,{item:x,userPermissions:t,level:n+1,onNavigate:r,activePath:o},x.id))})})]})},Tl=g(De.div)`
1426
+ `,$l=({item:e,userPermissions:t,level:n=0,activePath:o,onNavigate:r})=>{const[i,s]=m.useState(!1),{isCollapsed:a,setIsMobileOpen:l,setIsCollapsed:c}=dr(),d=m.useMemo(()=>(e.children||[]).filter(x=>fr(t,x.requiredPermissions)),[e.children,t]);if(!m.useMemo(()=>fr(t,e.requiredPermissions),[t,e.requiredPermissions]))return null;const f=d.length>0,h=e.href||e.path||"",v=!!(h&&o&&o.startsWith(h)),y=()=>{a&&c(!1),s(x=>!x)},b=()=>{a&&c(!1),e.href&&r?.(e.href)},w=async()=>{if(a&&c(!1),!e.path)return;const x=e.target||"_blank";try{typeof window<"u"&&(x==="_blank"?window.open(e.path,"_blank","noopener,noreferrer"):window.location.href=e.path),l&&l(!1)}catch(P){console.error("Error al navegar a microservicio:",P)}},S=()=>p.jsxs(p.Fragment,{children:[p.jsxs(x0,{children:[n>0&&!a&&p.jsx($0,{}),e.icon&&p.jsx(U,{component:e.icon,size:n===0?"md":"sm",color:"var(--color-main-blue-primary)"}),!a&&p.jsx(S0,{$level:n,size:n===0?16:n===1?14:12,color:"var(--color-dark-700, #374151)",children:e.label})]}),!a&&f&&p.jsx(P0,{$disabled:a,$open:i,children:p.jsx(U,{component:Ap,size:"sm",color:"var(--color-main-blue-primary)"})})]});return p.jsxs(T0,{$level:n,children:[e.href&&!e.path&&!f?p.jsx(w0,{type:"button",onClick:b,$level:n,$collapsed:a,$active:v,title:a?e.label:"",children:S()}):p.jsx(b0,{type:"button",onClick:f?y:e.path?w:b,$level:n,$collapsed:a,$active:v,$expanded:i&&f,title:a?e.label:"",children:S()}),p.jsx(Rt,{initial:!1,children:!a&&i&&f&&p.jsx(C0,{$level:n+1,...vl,children:d.map(x=>p.jsx($l,{item:x,userPermissions:t,level:n+1,onNavigate:r,activePath:o},x.id))})})]})},Pl=g(De.div)`
1404
1427
  position: fixed;
1405
1428
  inset: 0;
1406
1429
  background: rgba(0, 0, 0, 0.5);
@@ -1409,7 +1432,7 @@
1409
1432
  @media (max-width: 767px) {
1410
1433
  display: block;
1411
1434
  }
1412
- `,$l=g.aside`
1435
+ `,kl=g.aside`
1413
1436
  position: fixed;
1414
1437
  left: 0;
1415
1438
  top: 0;
@@ -1428,7 +1451,7 @@
1428
1451
  @media (min-width: 768px) {
1429
1452
  transform: translateX(0);
1430
1453
  }
1431
- `,Pl=g.div`
1454
+ `,Ml=g.div`
1432
1455
  display: flex;
1433
1456
  align-items: center;
1434
1457
  justify-content: space-between;
@@ -1436,11 +1459,11 @@
1436
1459
  padding: 1rem;
1437
1460
 
1438
1461
  ${({$collapsed:e})=>e?"flex-direction: column":""};
1439
- `,kl=g.div`
1462
+ `,Vl=g.div`
1440
1463
  display: flex;
1441
1464
  align-items: center;
1442
1465
  gap: 0.5rem;
1443
- `,Ml=g.nav`
1466
+ `,El=g.nav`
1444
1467
  display: flex;
1445
1468
  flex-direction: column;
1446
1469
  justify-content: flex-start;
@@ -1448,7 +1471,7 @@
1448
1471
  flex: 1;
1449
1472
  overflow-y: auto;
1450
1473
  padding: 0.25rem 0;
1451
- `,Vl=g.button`
1474
+ `,Dl=g.button`
1452
1475
  display: flex;
1453
1476
  align-items: center;
1454
1477
  justify-content: center;
@@ -1474,7 +1497,7 @@
1474
1497
  @media (max-width: 767px) {
1475
1498
  display: none;
1476
1499
  }
1477
- `,El=g.button`
1500
+ `,Fl=g.button`
1478
1501
  position: fixed;
1479
1502
  top: 0.5rem;
1480
1503
  left: 1rem;
@@ -1485,7 +1508,13 @@
1485
1508
  @media (min-width: 768px) {
1486
1509
  display: none;
1487
1510
  }
1488
- `,fr=({navigationConfig:e,activePath:t,logoImgExpanded:n,logoImgCollapsed:o,onNavigate:r=()=>{},userPermissions:i=[]})=>{const{isCollapsed:s,setIsCollapsed:a,isMobileOpen:l,setIsMobileOpen:c}=ur(),d=u=>{r(u),typeof window<"u"&&window.innerWidth<768&&c(!1)};return p.jsxs(p.Fragment,{children:[p.jsx(Lt,{children:l&&p.jsx(Tl,{...lr,onClick:()=>c(!1)})}),p.jsxs($l,{$collapsed:l?!1:s,$open:l,children:[p.jsxs(Pl,{$collapsed:s,children:[p.jsx(kl,{children:s?o:n}),p.jsx(Vl,{onClick:()=>a(!s),"aria-label":"Toggle collapse",children:p.jsx(U,{component:Qa,size:"md",color:"var(--color-main-blue-primary)"})})]}),p.jsx(Ml,{children:e.map(u=>p.jsx(Cl,{item:u,onNavigate:d,activePath:t,userPermissions:i},u.id))})]}),p.jsx(El,{onClick:()=>{c(!0),a(!0)},$hidden:l,children:p.jsx(U,{component:Qa,size:30})})]})};fr.displayName="Sidebar";const Dl={underlined:g.css`
1511
+ `,hr=({navigationConfig:e,activePath:t,logoImgExpanded:n,logoImgCollapsed:o,onNavigate:r=()=>{},userPermissions:i=[]})=>{const{isCollapsed:s,setIsCollapsed:a,isMobileOpen:l,setIsMobileOpen:c}=dr(),d=u=>{r(u),typeof window<"u"&&window.innerWidth<768&&c(!1)};return p.jsxs(p.Fragment,{children:[p.jsx(Rt,{children:l&&p.jsx(Pl,{...cr,onClick:()=>c(!1)})}),p.jsxs(kl,{$collapsed:l?!1:s,$open:l,children:[p.jsxs(Ml,{$collapsed:s,children:[p.jsx(Vl,{children:s?o:n}),p.jsx(Dl,{onClick:()=>a(!s),"aria-label":"Toggle collapse",children:p.jsx(U,{component:el,size:"md",color:"var(--color-main-blue-primary)"})})]}),p.jsx(El,{children:e.map(u=>p.jsx($l,{item:u,onNavigate:d,activePath:t,userPermissions:i},u.id))})]}),p.jsx(Fl,{onClick:()=>{c(!0),a(!0)},$hidden:l,children:p.jsx(U,{component:el,size:30})})]})};hr.displayName="Sidebar";const k0=g.css`
1512
+ &:visited {
1513
+ color: var(--color-main-orange-primary);
1514
+ text-decoration: underline;
1515
+ text-decoration-thickness: 1px;
1516
+ }
1517
+ `,Al={underlined:g.css`
1489
1518
  color: var(--color-main-grey);
1490
1519
  text-decoration-thickness: 1px;
1491
1520
  text-underline-offset: 2px;
@@ -1499,18 +1528,16 @@
1499
1528
  color: var(--color-main-orange-primary);
1500
1529
  text-decoration: underline;
1501
1530
  transform: translateY(1px);
1531
+
1532
+ @media (preferes-reduced-motion: reduce) {
1533
+ transform: none;
1534
+ }
1502
1535
  }
1503
1536
 
1504
1537
  &:focus-visible {
1505
1538
  outline-color: var(--color-main-blue-primary);
1506
1539
  outline-offset: 2px;
1507
1540
  }
1508
-
1509
- &:visited {
1510
- color: var(--color-main-orange-primary);
1511
- text-decoration: underline;
1512
- text-decoration-thickness: 1px;
1513
- }
1514
1541
  `,plain:g.css`
1515
1542
  color: var(--color-main-grey);
1516
1543
  text-decoration: none;
@@ -1528,20 +1555,17 @@
1528
1555
  text-decoration-thickness: 1px;
1529
1556
  text-underline-offset: 2px;
1530
1557
  transform: translateY(1px);
1558
+
1559
+ @media (preferes-reduced-motion: reduce) {
1560
+ transform: none;
1561
+ }
1531
1562
  }
1532
1563
 
1533
1564
  &:focus-visible {
1534
1565
  outline-color: var(--color-main-blue-primary);
1535
1566
  outline-offset: 2px;
1536
1567
  }
1537
-
1538
- &:visited {
1539
- color: var(--color-main-orange-primary);
1540
- text-decoration: underline;
1541
- text-decoration-thickness: 1px;
1542
- text-underline-offset: 2px;
1543
- }
1544
- `},Fl=g.css`
1568
+ `},Il=g.css`
1545
1569
  color: var(--color-dark-200);
1546
1570
  cursor: not-allowed;
1547
1571
  pointer-events: none;
@@ -1559,7 +1583,10 @@
1559
1583
  text-decoration: none;
1560
1584
  transform: none;
1561
1585
  }
1562
- `,Al={sm:g.css`
1586
+ `,mr={xs:g.css`
1587
+ gap: 0.25rem;
1588
+ ${D[12]}
1589
+ `,sm:g.css`
1563
1590
  gap: 0.25rem;
1564
1591
  ${D[14]}
1565
1592
  `,md:g.css`
@@ -1568,7 +1595,7 @@
1568
1595
  `,lg:g.css`
1569
1596
  gap: 0.75rem;
1570
1597
  ${D[20]}
1571
- `},$0=g.a`
1598
+ `},M0=g.a`
1572
1599
  display: inline-flex;
1573
1600
  align-items: center;
1574
1601
  border-radius: 0.25rem;
@@ -1581,11 +1608,13 @@
1581
1608
  background-color 0.3s ease-in-out;
1582
1609
 
1583
1610
  cursor: pointer;
1611
+ touch-action: manipulation;
1584
1612
 
1585
- ${({$size:e})=>Al[e]}
1586
- ${({$variant:e})=>Dl[e]}
1587
- ${({$disabled:e})=>e&&Fl}
1588
- `,P0=g.styled.span`
1613
+ ${({$size:e})=>e in mr?mr[e]:D[e]||D[16]}
1614
+ ${({$variant:e})=>Al[e]}
1615
+ ${({$disabled:e})=>e&&Il}
1616
+ ${({$isExternal:e})=>e&&k0}
1617
+ `,V0=g.styled.span`
1589
1618
  flex: 1 1 auto;
1590
1619
  min-width: 0;
1591
1620
  transition:
@@ -1599,10 +1628,10 @@
1599
1628
  text-overflow: ellipsis;
1600
1629
  white-space: nowrap;
1601
1630
  `};
1602
- `,Il=m.forwardRef(({id:e,size:t="md",variant:n="underlined",children:o,href:r,target:i,rel:s,className:a,disabled:l=!1,tabIndex:c,leftIcon:d,rightIcon:u,iconSize:h="tn",truncate:f=!1,"aria-label":v,"aria-describedby":y,onClick:b,...w},C)=>{const x=m.useCallback(T=>{if(l){T.preventDefault();return}b?.(T)},[l,b]),P={href:l?void 0:r,target:i||void 0,rel:s??(i==="_blank"?"noopener noreferrer":void 0),onClick:x,"aria-label":v??o,"aria-describedby":y,tabIndex:l?-1:c??0,...w};return p.jsxs($0,{id:e,$variant:n,$size:t,$disabled:l,className:a,ref:C,...P,children:[d&&p.jsx(U,{component:d,size:h,color:"currentColor"}),p.jsx(P0,{$truncate:f,children:o}),i==="_blank"&&!u&&p.jsx(U,{component:Ap,size:t==="lg"?"sm":h,color:"currentColor"}),u&&p.jsx(U,{component:u,size:h,color:"currentColor"})]})});Il.displayName="Link";function k0(){return{accessor:(e,t)=>typeof e=="function"?{...t,accessorFn:e}:{...t,accessorKey:e},display:e=>e,group:e=>e}}function He(e,t){return typeof e=="function"?e(t):e}function fe(e,t){return n=>{t.setState(o=>({...o,[e]:He(n,o[e])}))}}function vn(e){return e instanceof Function}function M0(e){return Array.isArray(e)&&e.every(t=>typeof t=="number")}function V0(e,t){const n=[],o=r=>{r.forEach(i=>{n.push(i);const s=t(i);s!=null&&s.length&&o(s)})};return o(e),n}function R(e,t,n){let o=[],r;return i=>{let s;n.key&&n.debug&&(s=Date.now());const a=e(i);if(!(a.length!==o.length||a.some((d,u)=>o[u]!==d)))return r;o=a;let c;if(n.key&&n.debug&&(c=Date.now()),r=t(...a),n==null||n.onChange==null||n.onChange(r),n.key&&n.debug&&n!=null&&n.debug()){const d=Math.round((Date.now()-s)*100)/100,u=Math.round((Date.now()-c)*100)/100,h=u/16,f=(v,y)=>{for(v=String(v);v.length<y;)v=" "+v;return v};console.info(`%c⏱ ${f(u,5)} /${f(d,5)} ms`,`
1631
+ `,Ll=m.forwardRef(({id:e,size:t="md",variant:n="underlined",children:o,href:r,target:i,rel:s,className:a,disabled:l=!1,tabIndex:c,leftIcon:d,rightIcon:u,iconSize:f="tn",truncate:h=!1,"aria-label":v,"aria-describedby":y,onClick:b,...w},S)=>{const x=m.useCallback(k=>{if(l){k.preventDefault();return}b?.(k)},[l,b]),P={href:l?void 0:r,target:i||void 0,rel:s??(i==="_blank"?"noopener noreferrer":void 0),onClick:x,"aria-label":v??o,"aria-describedby":y,tabIndex:l?-1:c??0,...w},T=i==="_blank"||i==="_top"||i==="_parent";return p.jsxs(M0,{id:e,$variant:n,$size:t,$disabled:l,$isExternal:T,className:a,ref:S,...P,children:[d&&p.jsx(U,{component:d,size:f,color:"currentColor","aria-hidden":"true"}),p.jsx(V0,{$truncate:h,children:o}),i==="_blank"&&!u&&p.jsx(U,{component:Lp,size:t==="lg"?"sm":f,color:"currentColor","aria-hidden":"true"}),u&&p.jsx(U,{component:u,size:f,color:"currentColor"})]})});Ll.displayName="Link";function E0(){return{accessor:(e,t)=>typeof e=="function"?{...t,accessorFn:e}:{...t,accessorKey:e},display:e=>e,group:e=>e}}function He(e,t){return typeof e=="function"?e(t):e}function fe(e,t){return n=>{t.setState(o=>({...o,[e]:He(n,o[e])}))}}function yn(e){return e instanceof Function}function D0(e){return Array.isArray(e)&&e.every(t=>typeof t=="number")}function F0(e,t){const n=[],o=r=>{r.forEach(i=>{n.push(i);const s=t(i);s!=null&&s.length&&o(s)})};return o(e),n}function R(e,t,n){let o=[],r;return i=>{let s;n.key&&n.debug&&(s=Date.now());const a=e(i);if(!(a.length!==o.length||a.some((d,u)=>o[u]!==d)))return r;o=a;let c;if(n.key&&n.debug&&(c=Date.now()),r=t(...a),n==null||n.onChange==null||n.onChange(r),n.key&&n.debug&&n!=null&&n.debug()){const d=Math.round((Date.now()-s)*100)/100,u=Math.round((Date.now()-c)*100)/100,f=u/16,h=(v,y)=>{for(v=String(v);v.length<y;)v=" "+v;return v};console.info(`%c⏱ ${h(u,5)} /${h(d,5)} ms`,`
1603
1632
  font-size: .6rem;
1604
1633
  font-weight: bold;
1605
- color: hsl(${Math.max(0,Math.min(120-120*h,120))}deg 100% 31%);`,n?.key)}return r}}function _(e,t,n,o){return{debug:()=>{var r;return(r=e?.debugAll)!=null?r:e[t]},key:process.env.NODE_ENV==="development"&&n,onChange:o}}function E0(e,t,n,o){const r=()=>{var s;return(s=i.getValue())!=null?s:e.options.renderFallbackValue},i={id:`${t.id}_${n.id}`,row:t,column:n,getValue:()=>t.getValue(o),renderValue:r,getContext:R(()=>[e,n,t,i],(s,a,l,c)=>({table:s,column:a,row:l,cell:c,getValue:c.getValue,renderValue:c.renderValue}),_(e.options,"debugCells","cell.getContext"))};return e._features.forEach(s=>{s.createCell==null||s.createCell(i,n,t,e)},{}),i}function D0(e,t,n,o){var r,i;const a={...e._getDefaultColumnDef(),...t},l=a.accessorKey;let c=(r=(i=a.id)!=null?i:l?typeof String.prototype.replaceAll=="function"?l.replaceAll(".","_"):l.replace(/\./g,"_"):void 0)!=null?r:typeof a.header=="string"?a.header:void 0,d;if(a.accessorFn?d=a.accessorFn:l&&(l.includes(".")?d=h=>{let f=h;for(const y of l.split(".")){var v;f=(v=f)==null?void 0:v[y],process.env.NODE_ENV!=="production"&&f===void 0&&console.warn(`"${y}" in deeply nested key "${l}" returned undefined.`)}return f}:d=h=>h[a.accessorKey]),!c)throw process.env.NODE_ENV!=="production"?new Error(a.accessorFn?"Columns require an id when using an accessorFn":"Columns require an id when using a non-string header"):new Error;let u={id:`${String(c)}`,accessorFn:d,parent:o,depth:n,columnDef:a,columns:[],getFlatColumns:R(()=>[!0],()=>{var h;return[u,...(h=u.columns)==null?void 0:h.flatMap(f=>f.getFlatColumns())]},_(e.options,"debugColumns","column.getFlatColumns")),getLeafColumns:R(()=>[e._getOrderColumnsFn()],h=>{var f;if((f=u.columns)!=null&&f.length){let v=u.columns.flatMap(y=>y.getLeafColumns());return h(v)}return[u]},_(e.options,"debugColumns","column.getLeafColumns"))};for(const h of e._features)h.createColumn==null||h.createColumn(u,e);return u}const se="debugHeaders";function Ll(e,t,n){var o;let i={id:(o=n.id)!=null?o:t.id,column:t,index:n.index,isPlaceholder:!!n.isPlaceholder,placeholderId:n.placeholderId,depth:n.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const s=[],a=l=>{l.subHeaders&&l.subHeaders.length&&l.subHeaders.map(a),s.push(l)};return a(i),s},getContext:()=>({table:e,header:i,column:t})};return e._features.forEach(s=>{s.createHeader==null||s.createHeader(i,e)}),i}const F0={createTable:e=>{e.getHeaderGroups=R(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,o,r)=>{var i,s;const a=(i=o?.map(u=>n.find(h=>h.id===u)).filter(Boolean))!=null?i:[],l=(s=r?.map(u=>n.find(h=>h.id===u)).filter(Boolean))!=null?s:[],c=n.filter(u=>!(o!=null&&o.includes(u.id))&&!(r!=null&&r.includes(u.id)));return yn(t,[...a,...c,...l],e)},_(e.options,se,"getHeaderGroups")),e.getCenterHeaderGroups=R(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,o,r)=>(n=n.filter(i=>!(o!=null&&o.includes(i.id))&&!(r!=null&&r.includes(i.id))),yn(t,n,e,"center")),_(e.options,se,"getCenterHeaderGroups")),e.getLeftHeaderGroups=R(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left],(t,n,o)=>{var r;const i=(r=o?.map(s=>n.find(a=>a.id===s)).filter(Boolean))!=null?r:[];return yn(t,i,e,"left")},_(e.options,se,"getLeftHeaderGroups")),e.getRightHeaderGroups=R(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right],(t,n,o)=>{var r;const i=(r=o?.map(s=>n.find(a=>a.id===s)).filter(Boolean))!=null?r:[];return yn(t,i,e,"right")},_(e.options,se,"getRightHeaderGroups")),e.getFooterGroups=R(()=>[e.getHeaderGroups()],t=>[...t].reverse(),_(e.options,se,"getFooterGroups")),e.getLeftFooterGroups=R(()=>[e.getLeftHeaderGroups()],t=>[...t].reverse(),_(e.options,se,"getLeftFooterGroups")),e.getCenterFooterGroups=R(()=>[e.getCenterHeaderGroups()],t=>[...t].reverse(),_(e.options,se,"getCenterFooterGroups")),e.getRightFooterGroups=R(()=>[e.getRightHeaderGroups()],t=>[...t].reverse(),_(e.options,se,"getRightFooterGroups")),e.getFlatHeaders=R(()=>[e.getHeaderGroups()],t=>t.map(n=>n.headers).flat(),_(e.options,se,"getFlatHeaders")),e.getLeftFlatHeaders=R(()=>[e.getLeftHeaderGroups()],t=>t.map(n=>n.headers).flat(),_(e.options,se,"getLeftFlatHeaders")),e.getCenterFlatHeaders=R(()=>[e.getCenterHeaderGroups()],t=>t.map(n=>n.headers).flat(),_(e.options,se,"getCenterFlatHeaders")),e.getRightFlatHeaders=R(()=>[e.getRightHeaderGroups()],t=>t.map(n=>n.headers).flat(),_(e.options,se,"getRightFlatHeaders")),e.getCenterLeafHeaders=R(()=>[e.getCenterFlatHeaders()],t=>t.filter(n=>{var o;return!((o=n.subHeaders)!=null&&o.length)}),_(e.options,se,"getCenterLeafHeaders")),e.getLeftLeafHeaders=R(()=>[e.getLeftFlatHeaders()],t=>t.filter(n=>{var o;return!((o=n.subHeaders)!=null&&o.length)}),_(e.options,se,"getLeftLeafHeaders")),e.getRightLeafHeaders=R(()=>[e.getRightFlatHeaders()],t=>t.filter(n=>{var o;return!((o=n.subHeaders)!=null&&o.length)}),_(e.options,se,"getRightLeafHeaders")),e.getLeafHeaders=R(()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()],(t,n,o)=>{var r,i,s,a,l,c;return[...(r=(i=t[0])==null?void 0:i.headers)!=null?r:[],...(s=(a=n[0])==null?void 0:a.headers)!=null?s:[],...(l=(c=o[0])==null?void 0:c.headers)!=null?l:[]].map(d=>d.getLeafHeaders()).flat()},_(e.options,se,"getLeafHeaders"))}};function yn(e,t,n,o){var r,i;let s=0;const a=function(h,f){f===void 0&&(f=1),s=Math.max(s,f),h.filter(v=>v.getIsVisible()).forEach(v=>{var y;(y=v.columns)!=null&&y.length&&a(v.columns,f+1)},0)};a(e);let l=[];const c=(h,f)=>{const v={depth:f,id:[o,`${f}`].filter(Boolean).join("_"),headers:[]},y=[];h.forEach(b=>{const w=[...y].reverse()[0],C=b.column.depth===v.depth;let x,P=!1;if(C&&b.column.parent?x=b.column.parent:(x=b.column,P=!0),w&&w?.column===x)w.subHeaders.push(b);else{const T=Ll(n,x,{id:[o,f,x.id,b?.id].filter(Boolean).join("_"),isPlaceholder:P,placeholderId:P?`${y.filter(k=>k.column===x).length}`:void 0,depth:f,index:y.length});T.subHeaders.push(b),y.push(T)}v.headers.push(b),b.headerGroup=v}),l.push(v),f>0&&c(y,f-1)},d=t.map((h,f)=>Ll(n,h,{depth:s,index:f}));c(d,s-1),l.reverse();const u=h=>h.filter(v=>v.column.getIsVisible()).map(v=>{let y=0,b=0,w=[0];v.subHeaders&&v.subHeaders.length?(w=[],u(v.subHeaders).forEach(x=>{let{colSpan:P,rowSpan:T}=x;y+=P,w.push(T)})):y=1;const C=Math.min(...w);return b=b+C,v.colSpan=y,v.rowSpan=b,{colSpan:y,rowSpan:b}});return u((r=(i=l[0])==null?void 0:i.headers)!=null?r:[]),l}const hr=(e,t,n,o,r,i,s)=>{let a={id:t,index:o,original:n,depth:r,parentId:s,_valuesCache:{},_uniqueValuesCache:{},getValue:l=>{if(a._valuesCache.hasOwnProperty(l))return a._valuesCache[l];const c=e.getColumn(l);if(c!=null&&c.accessorFn)return a._valuesCache[l]=c.accessorFn(a.original,o),a._valuesCache[l]},getUniqueValues:l=>{if(a._uniqueValuesCache.hasOwnProperty(l))return a._uniqueValuesCache[l];const c=e.getColumn(l);if(c!=null&&c.accessorFn)return c.columnDef.getUniqueValues?(a._uniqueValuesCache[l]=c.columnDef.getUniqueValues(a.original,o),a._uniqueValuesCache[l]):(a._uniqueValuesCache[l]=[a.getValue(l)],a._uniqueValuesCache[l])},renderValue:l=>{var c;return(c=a.getValue(l))!=null?c:e.options.renderFallbackValue},subRows:[],getLeafRows:()=>V0(a.subRows,l=>l.subRows),getParentRow:()=>a.parentId?e.getRow(a.parentId,!0):void 0,getParentRows:()=>{let l=[],c=a;for(;;){const d=c.getParentRow();if(!d)break;l.push(d),c=d}return l.reverse()},getAllCells:R(()=>[e.getAllLeafColumns()],l=>l.map(c=>E0(e,a,c,c.id)),_(e.options,"debugRows","getAllCells")),_getAllCellsByColumnId:R(()=>[a.getAllCells()],l=>l.reduce((c,d)=>(c[d.column.id]=d,c),{}),_(e.options,"debugRows","getAllCellsByColumnId"))};for(let l=0;l<e._features.length;l++){const c=e._features[l];c==null||c.createRow==null||c.createRow(a,e)}return a},A0={createColumn:(e,t)=>{e._getFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),e.getFacetedRowModel=()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),e._getFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),e.getFacetedUniqueValues=()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,e._getFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),e.getFacetedMinMaxValues=()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}},Rl=(e,t,n)=>{var o,r;const i=n==null||(o=n.toString())==null?void 0:o.toLowerCase();return!!(!((r=e.getValue(t))==null||(r=r.toString())==null||(r=r.toLowerCase())==null)&&r.includes(i))};Rl.autoRemove=e=>Se(e);const _l=(e,t,n)=>{var o;return!!(!((o=e.getValue(t))==null||(o=o.toString())==null)&&o.includes(n))};_l.autoRemove=e=>Se(e);const Nl=(e,t,n)=>{var o;return((o=e.getValue(t))==null||(o=o.toString())==null?void 0:o.toLowerCase())===n?.toLowerCase()};Nl.autoRemove=e=>Se(e);const Bl=(e,t,n)=>{var o;return(o=e.getValue(t))==null?void 0:o.includes(n)};Bl.autoRemove=e=>Se(e);const zl=(e,t,n)=>!n.some(o=>{var r;return!((r=e.getValue(t))!=null&&r.includes(o))});zl.autoRemove=e=>Se(e)||!(e!=null&&e.length);const Ol=(e,t,n)=>n.some(o=>{var r;return(r=e.getValue(t))==null?void 0:r.includes(o)});Ol.autoRemove=e=>Se(e)||!(e!=null&&e.length);const Hl=(e,t,n)=>e.getValue(t)===n;Hl.autoRemove=e=>Se(e);const jl=(e,t,n)=>e.getValue(t)==n;jl.autoRemove=e=>Se(e);const mr=(e,t,n)=>{let[o,r]=n;const i=e.getValue(t);return i>=o&&i<=r};mr.resolveFilterValue=e=>{let[t,n]=e,o=typeof t!="number"?parseFloat(t):t,r=typeof n!="number"?parseFloat(n):n,i=t===null||Number.isNaN(o)?-1/0:o,s=n===null||Number.isNaN(r)?1/0:r;if(i>s){const a=i;i=s,s=a}return[i,s]},mr.autoRemove=e=>Se(e)||Se(e[0])&&Se(e[1]);const Fe={includesString:Rl,includesStringSensitive:_l,equalsString:Nl,arrIncludes:Bl,arrIncludesAll:zl,arrIncludesSome:Ol,equals:Hl,weakEquals:jl,inNumberRange:mr};function Se(e){return e==null||e===""}const I0={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],...e}),getDefaultOptions:e=>({onColumnFiltersChange:fe("columnFilters",e),filterFromLeafRows:!1,maxLeafRowFilterDepth:100}),createColumn:(e,t)=>{e.getAutoFilterFn=()=>{const n=t.getCoreRowModel().flatRows[0],o=n?.getValue(e.id);return typeof o=="string"?Fe.includesString:typeof o=="number"?Fe.inNumberRange:typeof o=="boolean"||o!==null&&typeof o=="object"?Fe.equals:Array.isArray(o)?Fe.arrIncludes:Fe.weakEquals},e.getFilterFn=()=>{var n,o;return vn(e.columnDef.filterFn)?e.columnDef.filterFn:e.columnDef.filterFn==="auto"?e.getAutoFilterFn():(n=(o=t.options.filterFns)==null?void 0:o[e.columnDef.filterFn])!=null?n:Fe[e.columnDef.filterFn]},e.getCanFilter=()=>{var n,o,r;return((n=e.columnDef.enableColumnFilter)!=null?n:!0)&&((o=t.options.enableColumnFilters)!=null?o:!0)&&((r=t.options.enableFilters)!=null?r:!0)&&!!e.accessorFn},e.getIsFiltered=()=>e.getFilterIndex()>-1,e.getFilterValue=()=>{var n;return(n=t.getState().columnFilters)==null||(n=n.find(o=>o.id===e.id))==null?void 0:n.value},e.getFilterIndex=()=>{var n,o;return(n=(o=t.getState().columnFilters)==null?void 0:o.findIndex(r=>r.id===e.id))!=null?n:-1},e.setFilterValue=n=>{t.setColumnFilters(o=>{const r=e.getFilterFn(),i=o?.find(d=>d.id===e.id),s=He(n,i?i.value:void 0);if(Gl(r,s,e)){var a;return(a=o?.filter(d=>d.id!==e.id))!=null?a:[]}const l={id:e.id,value:s};if(i){var c;return(c=o?.map(d=>d.id===e.id?l:d))!=null?c:[]}return o!=null&&o.length?[...o,l]:[l]})}},createRow:(e,t)=>{e.columnFilters={},e.columnFiltersMeta={}},createTable:e=>{e.setColumnFilters=t=>{const n=e.getAllLeafColumns(),o=r=>{var i;return(i=He(t,r))==null?void 0:i.filter(s=>{const a=n.find(l=>l.id===s.id);if(a){const l=a.getFilterFn();if(Gl(l,s.value,a))return!1}return!0})};e.options.onColumnFiltersChange==null||e.options.onColumnFiltersChange(o)},e.resetColumnFilters=t=>{var n,o;e.setColumnFilters(t?[]:(n=(o=e.initialState)==null?void 0:o.columnFilters)!=null?n:[])},e.getPreFilteredRowModel=()=>e.getCoreRowModel(),e.getFilteredRowModel=()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel())}};function Gl(e,t,n){return(e&&e.autoRemove?e.autoRemove(t,n):!1)||typeof t>"u"||typeof t=="string"&&!t}const pr={sum:(e,t,n)=>n.reduce((o,r)=>{const i=r.getValue(e);return o+(typeof i=="number"?i:0)},0),min:(e,t,n)=>{let o;return n.forEach(r=>{const i=r.getValue(e);i!=null&&(o>i||o===void 0&&i>=i)&&(o=i)}),o},max:(e,t,n)=>{let o;return n.forEach(r=>{const i=r.getValue(e);i!=null&&(o<i||o===void 0&&i>=i)&&(o=i)}),o},extent:(e,t,n)=>{let o,r;return n.forEach(i=>{const s=i.getValue(e);s!=null&&(o===void 0?s>=s&&(o=r=s):(o>s&&(o=s),r<s&&(r=s)))}),[o,r]},mean:(e,t)=>{let n=0,o=0;if(t.forEach(r=>{let i=r.getValue(e);i!=null&&(i=+i)>=i&&(++n,o+=i)}),n)return o/n},median:(e,t)=>{if(!t.length)return;const n=t.map(i=>i.getValue(e));if(!M0(n))return;if(n.length===1)return n[0];const o=Math.floor(n.length/2),r=n.sort((i,s)=>i-s);return n.length%2!==0?r[o]:(r[o-1]+r[o])/2},unique:(e,t)=>Array.from(new Set(t.map(n=>n.getValue(e))).values()),uniqueCount:(e,t)=>new Set(t.map(n=>n.getValue(e))).size,count:(e,t)=>t.length},L0={getDefaultColumnDef:()=>({aggregatedCell:e=>{var t,n;return(t=(n=e.getValue())==null||n.toString==null?void 0:n.toString())!=null?t:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:fe("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,t)=>{e.toggleGrouping=()=>{t.setGrouping(n=>n!=null&&n.includes(e.id)?n.filter(o=>o!==e.id):[...n??[],e.id])},e.getCanGroup=()=>{var n,o;return((n=e.columnDef.enableGrouping)!=null?n:!0)&&((o=t.options.enableGrouping)!=null?o:!0)&&(!!e.accessorFn||!!e.columnDef.getGroupingValue)},e.getIsGrouped=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.includes(e.id)},e.getGroupedIndex=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.indexOf(e.id)},e.getToggleGroupingHandler=()=>{const n=e.getCanGroup();return()=>{n&&e.toggleGrouping()}},e.getAutoAggregationFn=()=>{const n=t.getCoreRowModel().flatRows[0],o=n?.getValue(e.id);if(typeof o=="number")return pr.sum;if(Object.prototype.toString.call(o)==="[object Date]")return pr.extent},e.getAggregationFn=()=>{var n,o;if(!e)throw new Error;return vn(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:e.columnDef.aggregationFn==="auto"?e.getAutoAggregationFn():(n=(o=t.options.aggregationFns)==null?void 0:o[e.columnDef.aggregationFn])!=null?n:pr[e.columnDef.aggregationFn]}},createTable:e=>{e.setGrouping=t=>e.options.onGroupingChange==null?void 0:e.options.onGroupingChange(t),e.resetGrouping=t=>{var n,o;e.setGrouping(t?[]:(n=(o=e.initialState)==null?void 0:o.grouping)!=null?n:[])},e.getPreGroupedRowModel=()=>e.getFilteredRowModel(),e.getGroupedRowModel=()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())},createRow:(e,t)=>{e.getIsGrouped=()=>!!e.groupingColumnId,e.getGroupingValue=n=>{if(e._groupingValuesCache.hasOwnProperty(n))return e._groupingValuesCache[n];const o=t.getColumn(n);return o!=null&&o.columnDef.getGroupingValue?(e._groupingValuesCache[n]=o.columnDef.getGroupingValue(e.original),e._groupingValuesCache[n]):e.getValue(n)},e._groupingValuesCache={}},createCell:(e,t,n,o)=>{e.getIsGrouped=()=>t.getIsGrouped()&&t.id===n.groupingColumnId,e.getIsPlaceholder=()=>!e.getIsGrouped()&&t.getIsGrouped(),e.getIsAggregated=()=>{var r;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!!((r=n.subRows)!=null&&r.length)}}};function R0(e,t,n){if(!(t!=null&&t.length)||!n)return e;const o=e.filter(i=>!t.includes(i.id));return n==="remove"?o:[...t.map(i=>e.find(s=>s.id===i)).filter(Boolean),...o]}const _0={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:fe("columnOrder",e)}),createColumn:(e,t)=>{e.getIndex=R(n=>[Ot(t,n)],n=>n.findIndex(o=>o.id===e.id),_(t.options,"debugColumns","getIndex")),e.getIsFirstColumn=n=>{var o;return((o=Ot(t,n)[0])==null?void 0:o.id)===e.id},e.getIsLastColumn=n=>{var o;const r=Ot(t,n);return((o=r[r.length-1])==null?void 0:o.id)===e.id}},createTable:e=>{e.setColumnOrder=t=>e.options.onColumnOrderChange==null?void 0:e.options.onColumnOrderChange(t),e.resetColumnOrder=t=>{var n;e.setColumnOrder(t?[]:(n=e.initialState.columnOrder)!=null?n:[])},e._getOrderColumnsFn=R(()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode],(t,n,o)=>r=>{let i=[];if(!(t!=null&&t.length))i=r;else{const s=[...t],a=[...r];for(;a.length&&s.length;){const l=s.shift(),c=a.findIndex(d=>d.id===l);c>-1&&i.push(a.splice(c,1)[0])}i=[...i,...a]}return R0(i,n,o)},_(e.options,"debugTable","_getOrderColumnsFn"))}},gr=()=>({left:[],right:[]}),N0={getInitialState:e=>({columnPinning:gr(),...e}),getDefaultOptions:e=>({onColumnPinningChange:fe("columnPinning",e)}),createColumn:(e,t)=>{e.pin=n=>{const o=e.getLeafColumns().map(r=>r.id).filter(Boolean);t.setColumnPinning(r=>{var i,s;if(n==="right"){var a,l;return{left:((a=r?.left)!=null?a:[]).filter(u=>!(o!=null&&o.includes(u))),right:[...((l=r?.right)!=null?l:[]).filter(u=>!(o!=null&&o.includes(u))),...o]}}if(n==="left"){var c,d;return{left:[...((c=r?.left)!=null?c:[]).filter(u=>!(o!=null&&o.includes(u))),...o],right:((d=r?.right)!=null?d:[]).filter(u=>!(o!=null&&o.includes(u)))}}return{left:((i=r?.left)!=null?i:[]).filter(u=>!(o!=null&&o.includes(u))),right:((s=r?.right)!=null?s:[]).filter(u=>!(o!=null&&o.includes(u)))}})},e.getCanPin=()=>e.getLeafColumns().some(o=>{var r,i,s;return((r=o.columnDef.enablePinning)!=null?r:!0)&&((i=(s=t.options.enableColumnPinning)!=null?s:t.options.enablePinning)!=null?i:!0)}),e.getIsPinned=()=>{const n=e.getLeafColumns().map(a=>a.id),{left:o,right:r}=t.getState().columnPinning,i=n.some(a=>o?.includes(a)),s=n.some(a=>r?.includes(a));return i?"left":s?"right":!1},e.getPinnedIndex=()=>{var n,o;const r=e.getIsPinned();return r?(n=(o=t.getState().columnPinning)==null||(o=o[r])==null?void 0:o.indexOf(e.id))!=null?n:-1:0}},createRow:(e,t)=>{e.getCenterVisibleCells=R(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right],(n,o,r)=>{const i=[...o??[],...r??[]];return n.filter(s=>!i.includes(s.column.id))},_(t.options,"debugRows","getCenterVisibleCells")),e.getLeftVisibleCells=R(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left],(n,o)=>(o??[]).map(i=>n.find(s=>s.column.id===i)).filter(Boolean).map(i=>({...i,position:"left"})),_(t.options,"debugRows","getLeftVisibleCells")),e.getRightVisibleCells=R(()=>[e._getAllVisibleCells(),t.getState().columnPinning.right],(n,o)=>(o??[]).map(i=>n.find(s=>s.column.id===i)).filter(Boolean).map(i=>({...i,position:"right"})),_(t.options,"debugRows","getRightVisibleCells"))},createTable:e=>{e.setColumnPinning=t=>e.options.onColumnPinningChange==null?void 0:e.options.onColumnPinningChange(t),e.resetColumnPinning=t=>{var n,o;return e.setColumnPinning(t?gr():(n=(o=e.initialState)==null?void 0:o.columnPinning)!=null?n:gr())},e.getIsSomeColumnsPinned=t=>{var n;const o=e.getState().columnPinning;if(!t){var r,i;return!!((r=o.left)!=null&&r.length||(i=o.right)!=null&&i.length)}return!!((n=o[t])!=null&&n.length)},e.getLeftLeafColumns=R(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left],(t,n)=>(n??[]).map(o=>t.find(r=>r.id===o)).filter(Boolean),_(e.options,"debugColumns","getLeftLeafColumns")),e.getRightLeafColumns=R(()=>[e.getAllLeafColumns(),e.getState().columnPinning.right],(t,n)=>(n??[]).map(o=>t.find(r=>r.id===o)).filter(Boolean),_(e.options,"debugColumns","getRightLeafColumns")),e.getCenterLeafColumns=R(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,o)=>{const r=[...n??[],...o??[]];return t.filter(i=>!r.includes(i.id))},_(e.options,"debugColumns","getCenterLeafColumns"))}};function B0(e){return e||(typeof document<"u"?document:null)}const wn={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},vr=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}),z0={getDefaultColumnDef:()=>wn,getInitialState:e=>({columnSizing:{},columnSizingInfo:vr(),...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",columnResizeDirection:"ltr",onColumnSizingChange:fe("columnSizing",e),onColumnSizingInfoChange:fe("columnSizingInfo",e)}),createColumn:(e,t)=>{e.getSize=()=>{var n,o,r;const i=t.getState().columnSizing[e.id];return Math.min(Math.max((n=e.columnDef.minSize)!=null?n:wn.minSize,(o=i??e.columnDef.size)!=null?o:wn.size),(r=e.columnDef.maxSize)!=null?r:wn.maxSize)},e.getStart=R(n=>[n,Ot(t,n),t.getState().columnSizing],(n,o)=>o.slice(0,e.getIndex(n)).reduce((r,i)=>r+i.getSize(),0),_(t.options,"debugColumns","getStart")),e.getAfter=R(n=>[n,Ot(t,n),t.getState().columnSizing],(n,o)=>o.slice(e.getIndex(n)+1).reduce((r,i)=>r+i.getSize(),0),_(t.options,"debugColumns","getAfter")),e.resetSize=()=>{t.setColumnSizing(n=>{let{[e.id]:o,...r}=n;return r})},e.getCanResize=()=>{var n,o;return((n=e.columnDef.enableResizing)!=null?n:!0)&&((o=t.options.enableColumnResizing)!=null?o:!0)},e.getIsResizing=()=>t.getState().columnSizingInfo.isResizingColumn===e.id},createHeader:(e,t)=>{e.getSize=()=>{let n=0;const o=r=>{if(r.subHeaders.length)r.subHeaders.forEach(o);else{var i;n+=(i=r.column.getSize())!=null?i:0}};return o(e),n},e.getStart=()=>{if(e.index>0){const n=e.headerGroup.headers[e.index-1];return n.getStart()+n.getSize()}return 0},e.getResizeHandler=n=>{const o=t.getColumn(e.column.id),r=o?.getCanResize();return i=>{if(!o||!r||(i.persist==null||i.persist(),yr(i)&&i.touches&&i.touches.length>1))return;const s=e.getSize(),a=e?e.getLeafHeaders().map(w=>[w.column.id,w.column.getSize()]):[[o.id,o.getSize()]],l=yr(i)?Math.round(i.touches[0].clientX):i.clientX,c={},d=(w,C)=>{typeof C=="number"&&(t.setColumnSizingInfo(x=>{var P,T;const k=t.options.columnResizeDirection==="rtl"?-1:1,V=(C-((P=x?.startOffset)!=null?P:0))*k,$=Math.max(V/((T=x?.startSize)!=null?T:0),-.999999);return x.columnSizingStart.forEach(A=>{let[I,B]=A;c[I]=Math.round(Math.max(B+B*$,0)*100)/100}),{...x,deltaOffset:V,deltaPercentage:$}}),(t.options.columnResizeMode==="onChange"||w==="end")&&t.setColumnSizing(x=>({...x,...c})))},u=w=>d("move",w),h=w=>{d("end",w),t.setColumnSizingInfo(C=>({...C,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}))},f=B0(n),v={moveHandler:w=>u(w.clientX),upHandler:w=>{f?.removeEventListener("mousemove",v.moveHandler),f?.removeEventListener("mouseup",v.upHandler),h(w.clientX)}},y={moveHandler:w=>(w.cancelable&&(w.preventDefault(),w.stopPropagation()),u(w.touches[0].clientX),!1),upHandler:w=>{var C;f?.removeEventListener("touchmove",y.moveHandler),f?.removeEventListener("touchend",y.upHandler),w.cancelable&&(w.preventDefault(),w.stopPropagation()),h((C=w.touches[0])==null?void 0:C.clientX)}},b=O0()?{passive:!1}:!1;yr(i)?(f?.addEventListener("touchmove",y.moveHandler,b),f?.addEventListener("touchend",y.upHandler,b)):(f?.addEventListener("mousemove",v.moveHandler,b),f?.addEventListener("mouseup",v.upHandler,b)),t.setColumnSizingInfo(w=>({...w,startOffset:l,startSize:s,deltaOffset:0,deltaPercentage:0,columnSizingStart:a,isResizingColumn:o.id}))}}},createTable:e=>{e.setColumnSizing=t=>e.options.onColumnSizingChange==null?void 0:e.options.onColumnSizingChange(t),e.setColumnSizingInfo=t=>e.options.onColumnSizingInfoChange==null?void 0:e.options.onColumnSizingInfoChange(t),e.resetColumnSizing=t=>{var n;e.setColumnSizing(t?{}:(n=e.initialState.columnSizing)!=null?n:{})},e.resetHeaderSizeInfo=t=>{var n;e.setColumnSizingInfo(t?vr():(n=e.initialState.columnSizingInfo)!=null?n:vr())},e.getTotalSize=()=>{var t,n;return(t=(n=e.getHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0},e.getLeftTotalSize=()=>{var t,n;return(t=(n=e.getLeftHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0},e.getCenterTotalSize=()=>{var t,n;return(t=(n=e.getCenterHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0},e.getRightTotalSize=()=>{var t,n;return(t=(n=e.getRightHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0}}};let bn=null;function O0(){if(typeof bn=="boolean")return bn;let e=!1;try{const t={get passive(){return e=!0,!1}},n=()=>{};window.addEventListener("test",n,t),window.removeEventListener("test",n)}catch{e=!1}return bn=e,bn}function yr(e){return e.type==="touchstart"}const H0={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:fe("columnVisibility",e)}),createColumn:(e,t)=>{e.toggleVisibility=n=>{e.getCanHide()&&t.setColumnVisibility(o=>({...o,[e.id]:n??!e.getIsVisible()}))},e.getIsVisible=()=>{var n,o;const r=e.columns;return(n=r.length?r.some(i=>i.getIsVisible()):(o=t.getState().columnVisibility)==null?void 0:o[e.id])!=null?n:!0},e.getCanHide=()=>{var n,o;return((n=e.columnDef.enableHiding)!=null?n:!0)&&((o=t.options.enableHiding)!=null?o:!0)},e.getToggleVisibilityHandler=()=>n=>{e.toggleVisibility==null||e.toggleVisibility(n.target.checked)}},createRow:(e,t)=>{e._getAllVisibleCells=R(()=>[e.getAllCells(),t.getState().columnVisibility],n=>n.filter(o=>o.column.getIsVisible()),_(t.options,"debugRows","_getAllVisibleCells")),e.getVisibleCells=R(()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()],(n,o,r)=>[...n,...o,...r],_(t.options,"debugRows","getVisibleCells"))},createTable:e=>{const t=(n,o)=>R(()=>[o(),o().filter(r=>r.getIsVisible()).map(r=>r.id).join("_")],r=>r.filter(i=>i.getIsVisible==null?void 0:i.getIsVisible()),_(e.options,"debugColumns",n));e.getVisibleFlatColumns=t("getVisibleFlatColumns",()=>e.getAllFlatColumns()),e.getVisibleLeafColumns=t("getVisibleLeafColumns",()=>e.getAllLeafColumns()),e.getLeftVisibleLeafColumns=t("getLeftVisibleLeafColumns",()=>e.getLeftLeafColumns()),e.getRightVisibleLeafColumns=t("getRightVisibleLeafColumns",()=>e.getRightLeafColumns()),e.getCenterVisibleLeafColumns=t("getCenterVisibleLeafColumns",()=>e.getCenterLeafColumns()),e.setColumnVisibility=n=>e.options.onColumnVisibilityChange==null?void 0:e.options.onColumnVisibilityChange(n),e.resetColumnVisibility=n=>{var o;e.setColumnVisibility(n?{}:(o=e.initialState.columnVisibility)!=null?o:{})},e.toggleAllColumnsVisible=n=>{var o;n=(o=n)!=null?o:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce((r,i)=>({...r,[i.id]:n||!(i.getCanHide!=null&&i.getCanHide())}),{}))},e.getIsAllColumnsVisible=()=>!e.getAllLeafColumns().some(n=>!(n.getIsVisible!=null&&n.getIsVisible())),e.getIsSomeColumnsVisible=()=>e.getAllLeafColumns().some(n=>n.getIsVisible==null?void 0:n.getIsVisible()),e.getToggleAllColumnsVisibilityHandler=()=>n=>{var o;e.toggleAllColumnsVisible((o=n.target)==null?void 0:o.checked)}}};function Ot(e,t){return t?t==="center"?e.getCenterVisibleLeafColumns():t==="left"?e.getLeftVisibleLeafColumns():e.getRightVisibleLeafColumns():e.getVisibleLeafColumns()}const j0={createTable:e=>{e._getGlobalFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),e.getGlobalFacetedRowModel=()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),e._getGlobalFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),e.getGlobalFacetedUniqueValues=()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,e._getGlobalFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),e.getGlobalFacetedMinMaxValues=()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}}},G0={getInitialState:e=>({globalFilter:void 0,...e}),getDefaultOptions:e=>({onGlobalFilterChange:fe("globalFilter",e),globalFilterFn:"auto",getColumnCanGlobalFilter:t=>{var n;const o=(n=e.getCoreRowModel().flatRows[0])==null||(n=n._getAllCellsByColumnId()[t.id])==null?void 0:n.getValue();return typeof o=="string"||typeof o=="number"}}),createColumn:(e,t)=>{e.getCanGlobalFilter=()=>{var n,o,r,i;return((n=e.columnDef.enableGlobalFilter)!=null?n:!0)&&((o=t.options.enableGlobalFilter)!=null?o:!0)&&((r=t.options.enableFilters)!=null?r:!0)&&((i=t.options.getColumnCanGlobalFilter==null?void 0:t.options.getColumnCanGlobalFilter(e))!=null?i:!0)&&!!e.accessorFn}},createTable:e=>{e.getGlobalAutoFilterFn=()=>Fe.includesString,e.getGlobalFilterFn=()=>{var t,n;const{globalFilterFn:o}=e.options;return vn(o)?o:o==="auto"?e.getGlobalAutoFilterFn():(t=(n=e.options.filterFns)==null?void 0:n[o])!=null?t:Fe[o]},e.setGlobalFilter=t=>{e.options.onGlobalFilterChange==null||e.options.onGlobalFilterChange(t)},e.resetGlobalFilter=t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter)}}},U0={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:fe("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let t=!1,n=!1;e._autoResetExpanded=()=>{var o,r;if(!t){e._queue(()=>{t=!0});return}if((o=(r=e.options.autoResetAll)!=null?r:e.options.autoResetExpanded)!=null?o:!e.options.manualExpanding){if(n)return;n=!0,e._queue(()=>{e.resetExpanded(),n=!1})}},e.setExpanded=o=>e.options.onExpandedChange==null?void 0:e.options.onExpandedChange(o),e.toggleAllRowsExpanded=o=>{o??!e.getIsAllRowsExpanded()?e.setExpanded(!0):e.setExpanded({})},e.resetExpanded=o=>{var r,i;e.setExpanded(o?{}:(r=(i=e.initialState)==null?void 0:i.expanded)!=null?r:{})},e.getCanSomeRowsExpand=()=>e.getPrePaginationRowModel().flatRows.some(o=>o.getCanExpand()),e.getToggleAllRowsExpandedHandler=()=>o=>{o.persist==null||o.persist(),e.toggleAllRowsExpanded()},e.getIsSomeRowsExpanded=()=>{const o=e.getState().expanded;return o===!0||Object.values(o).some(Boolean)},e.getIsAllRowsExpanded=()=>{const o=e.getState().expanded;return typeof o=="boolean"?o===!0:!(!Object.keys(o).length||e.getRowModel().flatRows.some(r=>!r.getIsExpanded()))},e.getExpandedDepth=()=>{let o=0;return(e.getState().expanded===!0?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach(i=>{const s=i.split(".");o=Math.max(o,s.length)}),o},e.getPreExpandedRowModel=()=>e.getSortedRowModel(),e.getExpandedRowModel=()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())},createRow:(e,t)=>{e.toggleExpanded=n=>{t.setExpanded(o=>{var r;const i=o===!0?!0:!!(o!=null&&o[e.id]);let s={};if(o===!0?Object.keys(t.getRowModel().rowsById).forEach(a=>{s[a]=!0}):s=o,n=(r=n)!=null?r:!i,!i&&n)return{...s,[e.id]:!0};if(i&&!n){const{[e.id]:a,...l}=s;return l}return o})},e.getIsExpanded=()=>{var n;const o=t.getState().expanded;return!!((n=t.options.getIsRowExpanded==null?void 0:t.options.getIsRowExpanded(e))!=null?n:o===!0||o?.[e.id])},e.getCanExpand=()=>{var n,o,r;return(n=t.options.getRowCanExpand==null?void 0:t.options.getRowCanExpand(e))!=null?n:((o=t.options.enableExpanding)!=null?o:!0)&&!!((r=e.subRows)!=null&&r.length)},e.getIsAllParentsExpanded=()=>{let n=!0,o=e;for(;n&&o.parentId;)o=t.getRow(o.parentId,!0),n=o.getIsExpanded();return n},e.getToggleExpandedHandler=()=>{const n=e.getCanExpand();return()=>{n&&e.toggleExpanded()}}}},wr=0,br=10,xr=()=>({pageIndex:wr,pageSize:br}),K0={getInitialState:e=>({...e,pagination:{...xr(),...e?.pagination}}),getDefaultOptions:e=>({onPaginationChange:fe("pagination",e)}),createTable:e=>{let t=!1,n=!1;e._autoResetPageIndex=()=>{var o,r;if(!t){e._queue(()=>{t=!0});return}if((o=(r=e.options.autoResetAll)!=null?r:e.options.autoResetPageIndex)!=null?o:!e.options.manualPagination){if(n)return;n=!0,e._queue(()=>{e.resetPageIndex(),n=!1})}},e.setPagination=o=>{const r=i=>He(o,i);return e.options.onPaginationChange==null?void 0:e.options.onPaginationChange(r)},e.resetPagination=o=>{var r;e.setPagination(o?xr():(r=e.initialState.pagination)!=null?r:xr())},e.setPageIndex=o=>{e.setPagination(r=>{let i=He(o,r.pageIndex);const s=typeof e.options.pageCount>"u"||e.options.pageCount===-1?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return i=Math.max(0,Math.min(i,s)),{...r,pageIndex:i}})},e.resetPageIndex=o=>{var r,i;e.setPageIndex(o?wr:(r=(i=e.initialState)==null||(i=i.pagination)==null?void 0:i.pageIndex)!=null?r:wr)},e.resetPageSize=o=>{var r,i;e.setPageSize(o?br:(r=(i=e.initialState)==null||(i=i.pagination)==null?void 0:i.pageSize)!=null?r:br)},e.setPageSize=o=>{e.setPagination(r=>{const i=Math.max(1,He(o,r.pageSize)),s=r.pageSize*r.pageIndex,a=Math.floor(s/i);return{...r,pageIndex:a,pageSize:i}})},e.setPageCount=o=>e.setPagination(r=>{var i;let s=He(o,(i=e.options.pageCount)!=null?i:-1);return typeof s=="number"&&(s=Math.max(-1,s)),{...r,pageCount:s}}),e.getPageOptions=R(()=>[e.getPageCount()],o=>{let r=[];return o&&o>0&&(r=[...new Array(o)].fill(null).map((i,s)=>s)),r},_(e.options,"debugTable","getPageOptions")),e.getCanPreviousPage=()=>e.getState().pagination.pageIndex>0,e.getCanNextPage=()=>{const{pageIndex:o}=e.getState().pagination,r=e.getPageCount();return r===-1?!0:r===0?!1:o<r-1},e.previousPage=()=>e.setPageIndex(o=>o-1),e.nextPage=()=>e.setPageIndex(o=>o+1),e.firstPage=()=>e.setPageIndex(0),e.lastPage=()=>e.setPageIndex(e.getPageCount()-1),e.getPrePaginationRowModel=()=>e.getExpandedRowModel(),e.getPaginationRowModel=()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),e.getPageCount=()=>{var o;return(o=e.options.pageCount)!=null?o:Math.ceil(e.getRowCount()/e.getState().pagination.pageSize)},e.getRowCount=()=>{var o;return(o=e.options.rowCount)!=null?o:e.getPrePaginationRowModel().rows.length}}},Sr=()=>({top:[],bottom:[]}),W0={getInitialState:e=>({rowPinning:Sr(),...e}),getDefaultOptions:e=>({onRowPinningChange:fe("rowPinning",e)}),createRow:(e,t)=>{e.pin=(n,o,r)=>{const i=o?e.getLeafRows().map(l=>{let{id:c}=l;return c}):[],s=r?e.getParentRows().map(l=>{let{id:c}=l;return c}):[],a=new Set([...s,e.id,...i]);t.setRowPinning(l=>{var c,d;if(n==="bottom"){var u,h;return{top:((u=l?.top)!=null?u:[]).filter(y=>!(a!=null&&a.has(y))),bottom:[...((h=l?.bottom)!=null?h:[]).filter(y=>!(a!=null&&a.has(y))),...Array.from(a)]}}if(n==="top"){var f,v;return{top:[...((f=l?.top)!=null?f:[]).filter(y=>!(a!=null&&a.has(y))),...Array.from(a)],bottom:((v=l?.bottom)!=null?v:[]).filter(y=>!(a!=null&&a.has(y)))}}return{top:((c=l?.top)!=null?c:[]).filter(y=>!(a!=null&&a.has(y))),bottom:((d=l?.bottom)!=null?d:[]).filter(y=>!(a!=null&&a.has(y)))}})},e.getCanPin=()=>{var n;const{enableRowPinning:o,enablePinning:r}=t.options;return typeof o=="function"?o(e):(n=o??r)!=null?n:!0},e.getIsPinned=()=>{const n=[e.id],{top:o,bottom:r}=t.getState().rowPinning,i=n.some(a=>o?.includes(a)),s=n.some(a=>r?.includes(a));return i?"top":s?"bottom":!1},e.getPinnedIndex=()=>{var n,o;const r=e.getIsPinned();if(!r)return-1;const i=(n=r==="top"?t.getTopRows():t.getBottomRows())==null?void 0:n.map(s=>{let{id:a}=s;return a});return(o=i?.indexOf(e.id))!=null?o:-1}},createTable:e=>{e.setRowPinning=t=>e.options.onRowPinningChange==null?void 0:e.options.onRowPinningChange(t),e.resetRowPinning=t=>{var n,o;return e.setRowPinning(t?Sr():(n=(o=e.initialState)==null?void 0:o.rowPinning)!=null?n:Sr())},e.getIsSomeRowsPinned=t=>{var n;const o=e.getState().rowPinning;if(!t){var r,i;return!!((r=o.top)!=null&&r.length||(i=o.bottom)!=null&&i.length)}return!!((n=o[t])!=null&&n.length)},e._getPinnedRows=(t,n,o)=>{var r;return((r=e.options.keepPinnedRows)==null||r?(n??[]).map(s=>{const a=e.getRow(s,!0);return a.getIsAllParentsExpanded()?a:null}):(n??[]).map(s=>t.find(a=>a.id===s))).filter(Boolean).map(s=>({...s,position:o}))},e.getTopRows=R(()=>[e.getRowModel().rows,e.getState().rowPinning.top],(t,n)=>e._getPinnedRows(t,n,"top"),_(e.options,"debugRows","getTopRows")),e.getBottomRows=R(()=>[e.getRowModel().rows,e.getState().rowPinning.bottom],(t,n)=>e._getPinnedRows(t,n,"bottom"),_(e.options,"debugRows","getBottomRows")),e.getCenterRows=R(()=>[e.getRowModel().rows,e.getState().rowPinning.top,e.getState().rowPinning.bottom],(t,n,o)=>{const r=new Set([...n??[],...o??[]]);return t.filter(i=>!r.has(i.id))},_(e.options,"debugRows","getCenterRows"))}},q0={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:fe("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>{e.setRowSelection=t=>e.options.onRowSelectionChange==null?void 0:e.options.onRowSelectionChange(t),e.resetRowSelection=t=>{var n;return e.setRowSelection(t?{}:(n=e.initialState.rowSelection)!=null?n:{})},e.toggleAllRowsSelected=t=>{e.setRowSelection(n=>{t=typeof t<"u"?t:!e.getIsAllRowsSelected();const o={...n},r=e.getPreGroupedRowModel().flatRows;return t?r.forEach(i=>{i.getCanSelect()&&(o[i.id]=!0)}):r.forEach(i=>{delete o[i.id]}),o})},e.toggleAllPageRowsSelected=t=>e.setRowSelection(n=>{const o=typeof t<"u"?t:!e.getIsAllPageRowsSelected(),r={...n};return e.getRowModel().rows.forEach(i=>{Cr(r,i.id,o,!0,e)}),r}),e.getPreSelectedRowModel=()=>e.getCoreRowModel(),e.getSelectedRowModel=R(()=>[e.getState().rowSelection,e.getCoreRowModel()],(t,n)=>Object.keys(t).length?Tr(e,n):{rows:[],flatRows:[],rowsById:{}},_(e.options,"debugTable","getSelectedRowModel")),e.getFilteredSelectedRowModel=R(()=>[e.getState().rowSelection,e.getFilteredRowModel()],(t,n)=>Object.keys(t).length?Tr(e,n):{rows:[],flatRows:[],rowsById:{}},_(e.options,"debugTable","getFilteredSelectedRowModel")),e.getGroupedSelectedRowModel=R(()=>[e.getState().rowSelection,e.getSortedRowModel()],(t,n)=>Object.keys(t).length?Tr(e,n):{rows:[],flatRows:[],rowsById:{}},_(e.options,"debugTable","getGroupedSelectedRowModel")),e.getIsAllRowsSelected=()=>{const t=e.getFilteredRowModel().flatRows,{rowSelection:n}=e.getState();let o=!!(t.length&&Object.keys(n).length);return o&&t.some(r=>r.getCanSelect()&&!n[r.id])&&(o=!1),o},e.getIsAllPageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows.filter(r=>r.getCanSelect()),{rowSelection:n}=e.getState();let o=!!t.length;return o&&t.some(r=>!n[r.id])&&(o=!1),o},e.getIsSomeRowsSelected=()=>{var t;const n=Object.keys((t=e.getState().rowSelection)!=null?t:{}).length;return n>0&&n<e.getFilteredRowModel().flatRows.length},e.getIsSomePageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows;return e.getIsAllPageRowsSelected()?!1:t.filter(n=>n.getCanSelect()).some(n=>n.getIsSelected()||n.getIsSomeSelected())},e.getToggleAllRowsSelectedHandler=()=>t=>{e.toggleAllRowsSelected(t.target.checked)},e.getToggleAllPageRowsSelectedHandler=()=>t=>{e.toggleAllPageRowsSelected(t.target.checked)}},createRow:(e,t)=>{e.toggleSelected=(n,o)=>{const r=e.getIsSelected();t.setRowSelection(i=>{var s;if(n=typeof n<"u"?n:!r,e.getCanSelect()&&r===n)return i;const a={...i};return Cr(a,e.id,n,(s=o?.selectChildren)!=null?s:!0,t),a})},e.getIsSelected=()=>{const{rowSelection:n}=t.getState();return $r(e,n)},e.getIsSomeSelected=()=>{const{rowSelection:n}=t.getState();return Pr(e,n)==="some"},e.getIsAllSubRowsSelected=()=>{const{rowSelection:n}=t.getState();return Pr(e,n)==="all"},e.getCanSelect=()=>{var n;return typeof t.options.enableRowSelection=="function"?t.options.enableRowSelection(e):(n=t.options.enableRowSelection)!=null?n:!0},e.getCanSelectSubRows=()=>{var n;return typeof t.options.enableSubRowSelection=="function"?t.options.enableSubRowSelection(e):(n=t.options.enableSubRowSelection)!=null?n:!0},e.getCanMultiSelect=()=>{var n;return typeof t.options.enableMultiRowSelection=="function"?t.options.enableMultiRowSelection(e):(n=t.options.enableMultiRowSelection)!=null?n:!0},e.getToggleSelectedHandler=()=>{const n=e.getCanSelect();return o=>{var r;n&&e.toggleSelected((r=o.target)==null?void 0:r.checked)}}}},Cr=(e,t,n,o,r)=>{var i;const s=r.getRow(t,!0);n?(s.getCanMultiSelect()||Object.keys(e).forEach(a=>delete e[a]),s.getCanSelect()&&(e[t]=!0)):delete e[t],o&&(i=s.subRows)!=null&&i.length&&s.getCanSelectSubRows()&&s.subRows.forEach(a=>Cr(e,a.id,n,o,r))};function Tr(e,t){const n=e.getState().rowSelection,o=[],r={},i=function(s,a){return s.map(l=>{var c;const d=$r(l,n);if(d&&(o.push(l),r[l.id]=l),(c=l.subRows)!=null&&c.length&&(l={...l,subRows:i(l.subRows)}),d)return l}).filter(Boolean)};return{rows:i(t.rows),flatRows:o,rowsById:r}}function $r(e,t){var n;return(n=t[e.id])!=null?n:!1}function Pr(e,t,n){var o;if(!((o=e.subRows)!=null&&o.length))return!1;let r=!0,i=!1;return e.subRows.forEach(s=>{if(!(i&&!r)&&(s.getCanSelect()&&($r(s,t)?i=!0:r=!1),s.subRows&&s.subRows.length)){const a=Pr(s,t);a==="all"?i=!0:(a==="some"&&(i=!0),r=!1)}}),r?"all":i?"some":!1}const kr=/([0-9]+)/gm,Y0=(e,t,n)=>Ul(je(e.getValue(n)).toLowerCase(),je(t.getValue(n)).toLowerCase()),X0=(e,t,n)=>Ul(je(e.getValue(n)),je(t.getValue(n))),Z0=(e,t,n)=>Mr(je(e.getValue(n)).toLowerCase(),je(t.getValue(n)).toLowerCase()),J0=(e,t,n)=>Mr(je(e.getValue(n)),je(t.getValue(n))),Q0=(e,t,n)=>{const o=e.getValue(n),r=t.getValue(n);return o>r?1:o<r?-1:0},ev=(e,t,n)=>Mr(e.getValue(n),t.getValue(n));function Mr(e,t){return e===t?0:e>t?1:-1}function je(e){return typeof e=="number"?isNaN(e)||e===1/0||e===-1/0?"":String(e):typeof e=="string"?e:""}function Ul(e,t){const n=e.split(kr).filter(Boolean),o=t.split(kr).filter(Boolean);for(;n.length&&o.length;){const r=n.shift(),i=o.shift(),s=parseInt(r,10),a=parseInt(i,10),l=[s,a].sort();if(isNaN(l[0])){if(r>i)return 1;if(i>r)return-1;continue}if(isNaN(l[1]))return isNaN(s)?-1:1;if(s>a)return 1;if(a>s)return-1}return n.length-o.length}const Ht={alphanumeric:Y0,alphanumericCaseSensitive:X0,text:Z0,textCaseSensitive:J0,datetime:Q0,basic:ev},tv=[F0,H0,_0,N0,A0,I0,j0,G0,{getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto",sortUndefined:1}),getDefaultOptions:e=>({onSortingChange:fe("sorting",e),isMultiSortEvent:t=>t.shiftKey}),createColumn:(e,t)=>{e.getAutoSortingFn=()=>{const n=t.getFilteredRowModel().flatRows.slice(10);let o=!1;for(const r of n){const i=r?.getValue(e.id);if(Object.prototype.toString.call(i)==="[object Date]")return Ht.datetime;if(typeof i=="string"&&(o=!0,i.split(kr).length>1))return Ht.alphanumeric}return o?Ht.text:Ht.basic},e.getAutoSortDir=()=>{const n=t.getFilteredRowModel().flatRows[0];return typeof n?.getValue(e.id)=="string"?"asc":"desc"},e.getSortingFn=()=>{var n,o;if(!e)throw new Error;return vn(e.columnDef.sortingFn)?e.columnDef.sortingFn:e.columnDef.sortingFn==="auto"?e.getAutoSortingFn():(n=(o=t.options.sortingFns)==null?void 0:o[e.columnDef.sortingFn])!=null?n:Ht[e.columnDef.sortingFn]},e.toggleSorting=(n,o)=>{const r=e.getNextSortingOrder(),i=typeof n<"u"&&n!==null;t.setSorting(s=>{const a=s?.find(f=>f.id===e.id),l=s?.findIndex(f=>f.id===e.id);let c=[],d,u=i?n:r==="desc";if(s!=null&&s.length&&e.getCanMultiSort()&&o?a?d="toggle":d="add":s!=null&&s.length&&l!==s.length-1?d="replace":a?d="toggle":d="replace",d==="toggle"&&(i||r||(d="remove")),d==="add"){var h;c=[...s,{id:e.id,desc:u}],c.splice(0,c.length-((h=t.options.maxMultiSortColCount)!=null?h:Number.MAX_SAFE_INTEGER))}else d==="toggle"?c=s.map(f=>f.id===e.id?{...f,desc:u}:f):d==="remove"?c=s.filter(f=>f.id!==e.id):c=[{id:e.id,desc:u}];return c})},e.getFirstSortDir=()=>{var n,o;return((n=(o=e.columnDef.sortDescFirst)!=null?o:t.options.sortDescFirst)!=null?n:e.getAutoSortDir()==="desc")?"desc":"asc"},e.getNextSortingOrder=n=>{var o,r;const i=e.getFirstSortDir(),s=e.getIsSorted();return s?s!==i&&((o=t.options.enableSortingRemoval)==null||o)&&(!(n&&(r=t.options.enableMultiRemove)!=null)||r)?!1:s==="desc"?"asc":"desc":i},e.getCanSort=()=>{var n,o;return((n=e.columnDef.enableSorting)!=null?n:!0)&&((o=t.options.enableSorting)!=null?o:!0)&&!!e.accessorFn},e.getCanMultiSort=()=>{var n,o;return(n=(o=e.columnDef.enableMultiSort)!=null?o:t.options.enableMultiSort)!=null?n:!!e.accessorFn},e.getIsSorted=()=>{var n;const o=(n=t.getState().sorting)==null?void 0:n.find(r=>r.id===e.id);return o?o.desc?"desc":"asc":!1},e.getSortIndex=()=>{var n,o;return(n=(o=t.getState().sorting)==null?void 0:o.findIndex(r=>r.id===e.id))!=null?n:-1},e.clearSorting=()=>{t.setSorting(n=>n!=null&&n.length?n.filter(o=>o.id!==e.id):[])},e.getToggleSortingHandler=()=>{const n=e.getCanSort();return o=>{n&&(o.persist==null||o.persist(),e.toggleSorting==null||e.toggleSorting(void 0,e.getCanMultiSort()?t.options.isMultiSortEvent==null?void 0:t.options.isMultiSortEvent(o):!1))}}},createTable:e=>{e.setSorting=t=>e.options.onSortingChange==null?void 0:e.options.onSortingChange(t),e.resetSorting=t=>{var n,o;e.setSorting(t?[]:(n=(o=e.initialState)==null?void 0:o.sorting)!=null?n:[])},e.getPreSortedRowModel=()=>e.getGroupedRowModel(),e.getSortedRowModel=()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())}},L0,U0,K0,W0,q0,z0];function nv(e){var t,n;process.env.NODE_ENV!=="production"&&(e.debugAll||e.debugTable)&&console.info("Creating Table Instance...");const o=[...tv,...(t=e._features)!=null?t:[]];let r={_features:o};const i=r._features.reduce((h,f)=>Object.assign(h,f.getDefaultOptions==null?void 0:f.getDefaultOptions(r)),{}),s=h=>r.options.mergeOptions?r.options.mergeOptions(i,h):{...i,...h};let l={...{},...(n=e.initialState)!=null?n:{}};r._features.forEach(h=>{var f;l=(f=h.getInitialState==null?void 0:h.getInitialState(l))!=null?f:l});const c=[];let d=!1;const u={_features:o,options:{...i,...e},initialState:l,_queue:h=>{c.push(h),d||(d=!0,Promise.resolve().then(()=>{for(;c.length;)c.shift()();d=!1}).catch(f=>setTimeout(()=>{throw f})))},reset:()=>{r.setState(r.initialState)},setOptions:h=>{const f=He(h,r.options);r.options=s(f)},getState:()=>r.options.state,setState:h=>{r.options.onStateChange==null||r.options.onStateChange(h)},_getRowId:(h,f,v)=>{var y;return(y=r.options.getRowId==null?void 0:r.options.getRowId(h,f,v))!=null?y:`${v?[v.id,f].join("."):f}`},getCoreRowModel:()=>(r._getCoreRowModel||(r._getCoreRowModel=r.options.getCoreRowModel(r)),r._getCoreRowModel()),getRowModel:()=>r.getPaginationRowModel(),getRow:(h,f)=>{let v=(f?r.getPrePaginationRowModel():r.getRowModel()).rowsById[h];if(!v&&(v=r.getCoreRowModel().rowsById[h],!v))throw process.env.NODE_ENV!=="production"?new Error(`getRow could not find row with ID: ${h}`):new Error;return v},_getDefaultColumnDef:R(()=>[r.options.defaultColumn],h=>{var f;return h=(f=h)!=null?f:{},{header:v=>{const y=v.header.column.columnDef;return y.accessorKey?y.accessorKey:y.accessorFn?y.id:null},cell:v=>{var y,b;return(y=(b=v.renderValue())==null||b.toString==null?void 0:b.toString())!=null?y:null},...r._features.reduce((v,y)=>Object.assign(v,y.getDefaultColumnDef==null?void 0:y.getDefaultColumnDef()),{}),...h}},_(e,"debugColumns","_getDefaultColumnDef")),_getColumnDefs:()=>r.options.columns,getAllColumns:R(()=>[r._getColumnDefs()],h=>{const f=function(v,y,b){return b===void 0&&(b=0),v.map(w=>{const C=D0(r,w,b,y),x=w;return C.columns=x.columns?f(x.columns,C,b+1):[],C})};return f(h)},_(e,"debugColumns","getAllColumns")),getAllFlatColumns:R(()=>[r.getAllColumns()],h=>h.flatMap(f=>f.getFlatColumns()),_(e,"debugColumns","getAllFlatColumns")),_getAllFlatColumnsById:R(()=>[r.getAllFlatColumns()],h=>h.reduce((f,v)=>(f[v.id]=v,f),{}),_(e,"debugColumns","getAllFlatColumnsById")),getAllLeafColumns:R(()=>[r.getAllColumns(),r._getOrderColumnsFn()],(h,f)=>{let v=h.flatMap(y=>y.getLeafColumns());return f(v)},_(e,"debugColumns","getAllLeafColumns")),getColumn:h=>{const f=r._getAllFlatColumnsById()[h];return process.env.NODE_ENV!=="production"&&!f&&console.error(`[Table] Column with id '${h}' does not exist.`),f}};Object.assign(r,u);for(let h=0;h<r._features.length;h++){const f=r._features[h];f==null||f.createTable==null||f.createTable(r)}return r}function ov(){return e=>R(()=>[e.options.data],t=>{const n={rows:[],flatRows:[],rowsById:{}},o=function(r,i,s){i===void 0&&(i=0);const a=[];for(let c=0;c<r.length;c++){const d=hr(e,e._getRowId(r[c],c,s),r[c],c,i,void 0,s?.id);if(n.flatRows.push(d),n.rowsById[d.id]=d,a.push(d),e.options.getSubRows){var l;d.originalSubRows=e.options.getSubRows(r[c],c),(l=d.originalSubRows)!=null&&l.length&&(d.subRows=o(d.originalSubRows,i+1,d))}}return a};return n.rows=o(t),n},_(e.options,"debugTable","getRowModel",()=>e._autoResetPageIndex()))}function rv(e,t,n){return n.options.filterFromLeafRows?iv(e,t,n):sv(e,t,n)}function iv(e,t,n){var o;const r=[],i={},s=(o=n.options.maxLeafRowFilterDepth)!=null?o:100,a=function(l,c){c===void 0&&(c=0);const d=[];for(let h=0;h<l.length;h++){var u;let f=l[h];const v=hr(n,f.id,f.original,f.index,f.depth,void 0,f.parentId);if(v.columnFilters=f.columnFilters,(u=f.subRows)!=null&&u.length&&c<s){if(v.subRows=a(f.subRows,c+1),f=v,t(f)&&!v.subRows.length){d.push(f),i[f.id]=f,r.push(f);continue}if(t(f)||v.subRows.length){d.push(f),i[f.id]=f,r.push(f);continue}}else f=v,t(f)&&(d.push(f),i[f.id]=f,r.push(f))}return d};return{rows:a(e),flatRows:r,rowsById:i}}function sv(e,t,n){var o;const r=[],i={},s=(o=n.options.maxLeafRowFilterDepth)!=null?o:100,a=function(l,c){c===void 0&&(c=0);const d=[];for(let h=0;h<l.length;h++){let f=l[h];if(t(f)){var u;if((u=f.subRows)!=null&&u.length&&c<s){const y=hr(n,f.id,f.original,f.index,f.depth,void 0,f.parentId);y.subRows=a(f.subRows,c+1),f=y}d.push(f),r.push(f),i[f.id]=f}}return d};return{rows:a(e),flatRows:r,rowsById:i}}function av(){return e=>R(()=>[e.getPreFilteredRowModel(),e.getState().columnFilters,e.getState().globalFilter],(t,n,o)=>{if(!t.rows.length||!(n!=null&&n.length)&&!o){for(let h=0;h<t.flatRows.length;h++)t.flatRows[h].columnFilters={},t.flatRows[h].columnFiltersMeta={};return t}const r=[],i=[];(n??[]).forEach(h=>{var f;const v=e.getColumn(h.id);if(!v)return;const y=v.getFilterFn();if(!y){process.env.NODE_ENV!=="production"&&console.warn(`Could not find a valid 'column.filterFn' for column with the ID: ${v.id}.`);return}r.push({id:h.id,filterFn:y,resolvedValue:(f=y.resolveFilterValue==null?void 0:y.resolveFilterValue(h.value))!=null?f:h.value})});const s=(n??[]).map(h=>h.id),a=e.getGlobalFilterFn(),l=e.getAllLeafColumns().filter(h=>h.getCanGlobalFilter());o&&a&&l.length&&(s.push("__global__"),l.forEach(h=>{var f;i.push({id:h.id,filterFn:a,resolvedValue:(f=a.resolveFilterValue==null?void 0:a.resolveFilterValue(o))!=null?f:o})}));let c,d;for(let h=0;h<t.flatRows.length;h++){const f=t.flatRows[h];if(f.columnFilters={},r.length)for(let v=0;v<r.length;v++){c=r[v];const y=c.id;f.columnFilters[y]=c.filterFn(f,y,c.resolvedValue,b=>{f.columnFiltersMeta[y]=b})}if(i.length){for(let v=0;v<i.length;v++){d=i[v];const y=d.id;if(d.filterFn(f,y,d.resolvedValue,b=>{f.columnFiltersMeta[y]=b})){f.columnFilters.__global__=!0;break}}f.columnFilters.__global__!==!0&&(f.columnFilters.__global__=!1)}}const u=h=>{for(let f=0;f<s.length;f++)if(h.columnFilters[s[f]]===!1)return!1;return!0};return rv(t.rows,u,e)},_(e.options,"debugTable","getFilteredRowModel",()=>e._autoResetPageIndex()))}function lv(){return e=>R(()=>[e.getState().sorting,e.getPreSortedRowModel()],(t,n)=>{if(!n.rows.length||!(t!=null&&t.length))return n;const o=e.getState().sorting,r=[],i=o.filter(l=>{var c;return(c=e.getColumn(l.id))==null?void 0:c.getCanSort()}),s={};i.forEach(l=>{const c=e.getColumn(l.id);c&&(s[l.id]={sortUndefined:c.columnDef.sortUndefined,invertSorting:c.columnDef.invertSorting,sortingFn:c.getSortingFn()})});const a=l=>{const c=l.map(d=>({...d}));return c.sort((d,u)=>{for(let f=0;f<i.length;f+=1){var h;const v=i[f],y=s[v.id],b=y.sortUndefined,w=(h=v?.desc)!=null?h:!1;let C=0;if(b){const x=d.getValue(v.id),P=u.getValue(v.id),T=x===void 0,k=P===void 0;if(T||k){if(b==="first")return T?-1:1;if(b==="last")return T?1:-1;C=T&&k?0:T?b:-b}}if(C===0&&(C=y.sortingFn(d,u,v.id)),C!==0)return w&&(C*=-1),y.invertSorting&&(C*=-1),C}return d.index-u.index}),c.forEach(d=>{var u;r.push(d),(u=d.subRows)!=null&&u.length&&(d.subRows=a(d.subRows))}),c};return{rows:a(n.rows),flatRows:r,rowsById:n.rowsById}},_(e.options,"debugTable","getSortedRowModel",()=>e._autoResetPageIndex()))}function xn(e,t){return e?cv(e)?Ue.createElement(e,t):e:null}function cv(e){return uv(e)||typeof e=="function"||dv(e)}function uv(e){return typeof e=="function"&&(()=>{const t=Object.getPrototypeOf(e);return t.prototype&&t.prototype.isReactComponent})()}function dv(e){return typeof e=="object"&&typeof e.$$typeof=="symbol"&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}function fv(e){const t={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[n]=Ue.useState(()=>({current:nv(t)})),[o,r]=Ue.useState(()=>n.current.initialState);return n.current.setOptions(i=>({...i,...e,state:{...o,...e.state},onStateChange:s=>{r(s),e.onStateChange==null||e.onStateChange(s)}})),n.current}const hv=g.css`
1634
+ color: hsl(${Math.max(0,Math.min(120-120*f,120))}deg 100% 31%);`,n?.key)}return r}}function _(e,t,n,o){return{debug:()=>{var r;return(r=e?.debugAll)!=null?r:e[t]},key:process.env.NODE_ENV==="development"&&n,onChange:o}}function A0(e,t,n,o){const r=()=>{var s;return(s=i.getValue())!=null?s:e.options.renderFallbackValue},i={id:`${t.id}_${n.id}`,row:t,column:n,getValue:()=>t.getValue(o),renderValue:r,getContext:R(()=>[e,n,t,i],(s,a,l,c)=>({table:s,column:a,row:l,cell:c,getValue:c.getValue,renderValue:c.renderValue}),_(e.options,"debugCells","cell.getContext"))};return e._features.forEach(s=>{s.createCell==null||s.createCell(i,n,t,e)},{}),i}function I0(e,t,n,o){var r,i;const a={...e._getDefaultColumnDef(),...t},l=a.accessorKey;let c=(r=(i=a.id)!=null?i:l?typeof String.prototype.replaceAll=="function"?l.replaceAll(".","_"):l.replace(/\./g,"_"):void 0)!=null?r:typeof a.header=="string"?a.header:void 0,d;if(a.accessorFn?d=a.accessorFn:l&&(l.includes(".")?d=f=>{let h=f;for(const y of l.split(".")){var v;h=(v=h)==null?void 0:v[y],process.env.NODE_ENV!=="production"&&h===void 0&&console.warn(`"${y}" in deeply nested key "${l}" returned undefined.`)}return h}:d=f=>f[a.accessorKey]),!c)throw process.env.NODE_ENV!=="production"?new Error(a.accessorFn?"Columns require an id when using an accessorFn":"Columns require an id when using a non-string header"):new Error;let u={id:`${String(c)}`,accessorFn:d,parent:o,depth:n,columnDef:a,columns:[],getFlatColumns:R(()=>[!0],()=>{var f;return[u,...(f=u.columns)==null?void 0:f.flatMap(h=>h.getFlatColumns())]},_(e.options,"debugColumns","column.getFlatColumns")),getLeafColumns:R(()=>[e._getOrderColumnsFn()],f=>{var h;if((h=u.columns)!=null&&h.length){let v=u.columns.flatMap(y=>y.getLeafColumns());return f(v)}return[u]},_(e.options,"debugColumns","column.getLeafColumns"))};for(const f of e._features)f.createColumn==null||f.createColumn(u,e);return u}const se="debugHeaders";function Rl(e,t,n){var o;let i={id:(o=n.id)!=null?o:t.id,column:t,index:n.index,isPlaceholder:!!n.isPlaceholder,placeholderId:n.placeholderId,depth:n.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const s=[],a=l=>{l.subHeaders&&l.subHeaders.length&&l.subHeaders.map(a),s.push(l)};return a(i),s},getContext:()=>({table:e,header:i,column:t})};return e._features.forEach(s=>{s.createHeader==null||s.createHeader(i,e)}),i}const L0={createTable:e=>{e.getHeaderGroups=R(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,o,r)=>{var i,s;const a=(i=o?.map(u=>n.find(f=>f.id===u)).filter(Boolean))!=null?i:[],l=(s=r?.map(u=>n.find(f=>f.id===u)).filter(Boolean))!=null?s:[],c=n.filter(u=>!(o!=null&&o.includes(u.id))&&!(r!=null&&r.includes(u.id)));return wn(t,[...a,...c,...l],e)},_(e.options,se,"getHeaderGroups")),e.getCenterHeaderGroups=R(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,o,r)=>(n=n.filter(i=>!(o!=null&&o.includes(i.id))&&!(r!=null&&r.includes(i.id))),wn(t,n,e,"center")),_(e.options,se,"getCenterHeaderGroups")),e.getLeftHeaderGroups=R(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left],(t,n,o)=>{var r;const i=(r=o?.map(s=>n.find(a=>a.id===s)).filter(Boolean))!=null?r:[];return wn(t,i,e,"left")},_(e.options,se,"getLeftHeaderGroups")),e.getRightHeaderGroups=R(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right],(t,n,o)=>{var r;const i=(r=o?.map(s=>n.find(a=>a.id===s)).filter(Boolean))!=null?r:[];return wn(t,i,e,"right")},_(e.options,se,"getRightHeaderGroups")),e.getFooterGroups=R(()=>[e.getHeaderGroups()],t=>[...t].reverse(),_(e.options,se,"getFooterGroups")),e.getLeftFooterGroups=R(()=>[e.getLeftHeaderGroups()],t=>[...t].reverse(),_(e.options,se,"getLeftFooterGroups")),e.getCenterFooterGroups=R(()=>[e.getCenterHeaderGroups()],t=>[...t].reverse(),_(e.options,se,"getCenterFooterGroups")),e.getRightFooterGroups=R(()=>[e.getRightHeaderGroups()],t=>[...t].reverse(),_(e.options,se,"getRightFooterGroups")),e.getFlatHeaders=R(()=>[e.getHeaderGroups()],t=>t.map(n=>n.headers).flat(),_(e.options,se,"getFlatHeaders")),e.getLeftFlatHeaders=R(()=>[e.getLeftHeaderGroups()],t=>t.map(n=>n.headers).flat(),_(e.options,se,"getLeftFlatHeaders")),e.getCenterFlatHeaders=R(()=>[e.getCenterHeaderGroups()],t=>t.map(n=>n.headers).flat(),_(e.options,se,"getCenterFlatHeaders")),e.getRightFlatHeaders=R(()=>[e.getRightHeaderGroups()],t=>t.map(n=>n.headers).flat(),_(e.options,se,"getRightFlatHeaders")),e.getCenterLeafHeaders=R(()=>[e.getCenterFlatHeaders()],t=>t.filter(n=>{var o;return!((o=n.subHeaders)!=null&&o.length)}),_(e.options,se,"getCenterLeafHeaders")),e.getLeftLeafHeaders=R(()=>[e.getLeftFlatHeaders()],t=>t.filter(n=>{var o;return!((o=n.subHeaders)!=null&&o.length)}),_(e.options,se,"getLeftLeafHeaders")),e.getRightLeafHeaders=R(()=>[e.getRightFlatHeaders()],t=>t.filter(n=>{var o;return!((o=n.subHeaders)!=null&&o.length)}),_(e.options,se,"getRightLeafHeaders")),e.getLeafHeaders=R(()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()],(t,n,o)=>{var r,i,s,a,l,c;return[...(r=(i=t[0])==null?void 0:i.headers)!=null?r:[],...(s=(a=n[0])==null?void 0:a.headers)!=null?s:[],...(l=(c=o[0])==null?void 0:c.headers)!=null?l:[]].map(d=>d.getLeafHeaders()).flat()},_(e.options,se,"getLeafHeaders"))}};function wn(e,t,n,o){var r,i;let s=0;const a=function(f,h){h===void 0&&(h=1),s=Math.max(s,h),f.filter(v=>v.getIsVisible()).forEach(v=>{var y;(y=v.columns)!=null&&y.length&&a(v.columns,h+1)},0)};a(e);let l=[];const c=(f,h)=>{const v={depth:h,id:[o,`${h}`].filter(Boolean).join("_"),headers:[]},y=[];f.forEach(b=>{const w=[...y].reverse()[0],S=b.column.depth===v.depth;let x,P=!1;if(S&&b.column.parent?x=b.column.parent:(x=b.column,P=!0),w&&w?.column===x)w.subHeaders.push(b);else{const T=Rl(n,x,{id:[o,h,x.id,b?.id].filter(Boolean).join("_"),isPlaceholder:P,placeholderId:P?`${y.filter(k=>k.column===x).length}`:void 0,depth:h,index:y.length});T.subHeaders.push(b),y.push(T)}v.headers.push(b),b.headerGroup=v}),l.push(v),h>0&&c(y,h-1)},d=t.map((f,h)=>Rl(n,f,{depth:s,index:h}));c(d,s-1),l.reverse();const u=f=>f.filter(v=>v.column.getIsVisible()).map(v=>{let y=0,b=0,w=[0];v.subHeaders&&v.subHeaders.length?(w=[],u(v.subHeaders).forEach(x=>{let{colSpan:P,rowSpan:T}=x;y+=P,w.push(T)})):y=1;const S=Math.min(...w);return b=b+S,v.colSpan=y,v.rowSpan=b,{colSpan:y,rowSpan:b}});return u((r=(i=l[0])==null?void 0:i.headers)!=null?r:[]),l}const pr=(e,t,n,o,r,i,s)=>{let a={id:t,index:o,original:n,depth:r,parentId:s,_valuesCache:{},_uniqueValuesCache:{},getValue:l=>{if(a._valuesCache.hasOwnProperty(l))return a._valuesCache[l];const c=e.getColumn(l);if(c!=null&&c.accessorFn)return a._valuesCache[l]=c.accessorFn(a.original,o),a._valuesCache[l]},getUniqueValues:l=>{if(a._uniqueValuesCache.hasOwnProperty(l))return a._uniqueValuesCache[l];const c=e.getColumn(l);if(c!=null&&c.accessorFn)return c.columnDef.getUniqueValues?(a._uniqueValuesCache[l]=c.columnDef.getUniqueValues(a.original,o),a._uniqueValuesCache[l]):(a._uniqueValuesCache[l]=[a.getValue(l)],a._uniqueValuesCache[l])},renderValue:l=>{var c;return(c=a.getValue(l))!=null?c:e.options.renderFallbackValue},subRows:[],getLeafRows:()=>F0(a.subRows,l=>l.subRows),getParentRow:()=>a.parentId?e.getRow(a.parentId,!0):void 0,getParentRows:()=>{let l=[],c=a;for(;;){const d=c.getParentRow();if(!d)break;l.push(d),c=d}return l.reverse()},getAllCells:R(()=>[e.getAllLeafColumns()],l=>l.map(c=>A0(e,a,c,c.id)),_(e.options,"debugRows","getAllCells")),_getAllCellsByColumnId:R(()=>[a.getAllCells()],l=>l.reduce((c,d)=>(c[d.column.id]=d,c),{}),_(e.options,"debugRows","getAllCellsByColumnId"))};for(let l=0;l<e._features.length;l++){const c=e._features[l];c==null||c.createRow==null||c.createRow(a,e)}return a},R0={createColumn:(e,t)=>{e._getFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),e.getFacetedRowModel=()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),e._getFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),e.getFacetedUniqueValues=()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,e._getFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),e.getFacetedMinMaxValues=()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}},_l=(e,t,n)=>{var o,r;const i=n==null||(o=n.toString())==null?void 0:o.toLowerCase();return!!(!((r=e.getValue(t))==null||(r=r.toString())==null||(r=r.toLowerCase())==null)&&r.includes(i))};_l.autoRemove=e=>Se(e);const Bl=(e,t,n)=>{var o;return!!(!((o=e.getValue(t))==null||(o=o.toString())==null)&&o.includes(n))};Bl.autoRemove=e=>Se(e);const Nl=(e,t,n)=>{var o;return((o=e.getValue(t))==null||(o=o.toString())==null?void 0:o.toLowerCase())===n?.toLowerCase()};Nl.autoRemove=e=>Se(e);const zl=(e,t,n)=>{var o;return(o=e.getValue(t))==null?void 0:o.includes(n)};zl.autoRemove=e=>Se(e);const Ol=(e,t,n)=>!n.some(o=>{var r;return!((r=e.getValue(t))!=null&&r.includes(o))});Ol.autoRemove=e=>Se(e)||!(e!=null&&e.length);const Hl=(e,t,n)=>n.some(o=>{var r;return(r=e.getValue(t))==null?void 0:r.includes(o)});Hl.autoRemove=e=>Se(e)||!(e!=null&&e.length);const jl=(e,t,n)=>e.getValue(t)===n;jl.autoRemove=e=>Se(e);const Gl=(e,t,n)=>e.getValue(t)==n;Gl.autoRemove=e=>Se(e);const gr=(e,t,n)=>{let[o,r]=n;const i=e.getValue(t);return i>=o&&i<=r};gr.resolveFilterValue=e=>{let[t,n]=e,o=typeof t!="number"?parseFloat(t):t,r=typeof n!="number"?parseFloat(n):n,i=t===null||Number.isNaN(o)?-1/0:o,s=n===null||Number.isNaN(r)?1/0:r;if(i>s){const a=i;i=s,s=a}return[i,s]},gr.autoRemove=e=>Se(e)||Se(e[0])&&Se(e[1]);const Fe={includesString:_l,includesStringSensitive:Bl,equalsString:Nl,arrIncludes:zl,arrIncludesAll:Ol,arrIncludesSome:Hl,equals:jl,weakEquals:Gl,inNumberRange:gr};function Se(e){return e==null||e===""}const _0={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],...e}),getDefaultOptions:e=>({onColumnFiltersChange:fe("columnFilters",e),filterFromLeafRows:!1,maxLeafRowFilterDepth:100}),createColumn:(e,t)=>{e.getAutoFilterFn=()=>{const n=t.getCoreRowModel().flatRows[0],o=n?.getValue(e.id);return typeof o=="string"?Fe.includesString:typeof o=="number"?Fe.inNumberRange:typeof o=="boolean"||o!==null&&typeof o=="object"?Fe.equals:Array.isArray(o)?Fe.arrIncludes:Fe.weakEquals},e.getFilterFn=()=>{var n,o;return yn(e.columnDef.filterFn)?e.columnDef.filterFn:e.columnDef.filterFn==="auto"?e.getAutoFilterFn():(n=(o=t.options.filterFns)==null?void 0:o[e.columnDef.filterFn])!=null?n:Fe[e.columnDef.filterFn]},e.getCanFilter=()=>{var n,o,r;return((n=e.columnDef.enableColumnFilter)!=null?n:!0)&&((o=t.options.enableColumnFilters)!=null?o:!0)&&((r=t.options.enableFilters)!=null?r:!0)&&!!e.accessorFn},e.getIsFiltered=()=>e.getFilterIndex()>-1,e.getFilterValue=()=>{var n;return(n=t.getState().columnFilters)==null||(n=n.find(o=>o.id===e.id))==null?void 0:n.value},e.getFilterIndex=()=>{var n,o;return(n=(o=t.getState().columnFilters)==null?void 0:o.findIndex(r=>r.id===e.id))!=null?n:-1},e.setFilterValue=n=>{t.setColumnFilters(o=>{const r=e.getFilterFn(),i=o?.find(d=>d.id===e.id),s=He(n,i?i.value:void 0);if(Ul(r,s,e)){var a;return(a=o?.filter(d=>d.id!==e.id))!=null?a:[]}const l={id:e.id,value:s};if(i){var c;return(c=o?.map(d=>d.id===e.id?l:d))!=null?c:[]}return o!=null&&o.length?[...o,l]:[l]})}},createRow:(e,t)=>{e.columnFilters={},e.columnFiltersMeta={}},createTable:e=>{e.setColumnFilters=t=>{const n=e.getAllLeafColumns(),o=r=>{var i;return(i=He(t,r))==null?void 0:i.filter(s=>{const a=n.find(l=>l.id===s.id);if(a){const l=a.getFilterFn();if(Ul(l,s.value,a))return!1}return!0})};e.options.onColumnFiltersChange==null||e.options.onColumnFiltersChange(o)},e.resetColumnFilters=t=>{var n,o;e.setColumnFilters(t?[]:(n=(o=e.initialState)==null?void 0:o.columnFilters)!=null?n:[])},e.getPreFilteredRowModel=()=>e.getCoreRowModel(),e.getFilteredRowModel=()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel())}};function Ul(e,t,n){return(e&&e.autoRemove?e.autoRemove(t,n):!1)||typeof t>"u"||typeof t=="string"&&!t}const vr={sum:(e,t,n)=>n.reduce((o,r)=>{const i=r.getValue(e);return o+(typeof i=="number"?i:0)},0),min:(e,t,n)=>{let o;return n.forEach(r=>{const i=r.getValue(e);i!=null&&(o>i||o===void 0&&i>=i)&&(o=i)}),o},max:(e,t,n)=>{let o;return n.forEach(r=>{const i=r.getValue(e);i!=null&&(o<i||o===void 0&&i>=i)&&(o=i)}),o},extent:(e,t,n)=>{let o,r;return n.forEach(i=>{const s=i.getValue(e);s!=null&&(o===void 0?s>=s&&(o=r=s):(o>s&&(o=s),r<s&&(r=s)))}),[o,r]},mean:(e,t)=>{let n=0,o=0;if(t.forEach(r=>{let i=r.getValue(e);i!=null&&(i=+i)>=i&&(++n,o+=i)}),n)return o/n},median:(e,t)=>{if(!t.length)return;const n=t.map(i=>i.getValue(e));if(!D0(n))return;if(n.length===1)return n[0];const o=Math.floor(n.length/2),r=n.sort((i,s)=>i-s);return n.length%2!==0?r[o]:(r[o-1]+r[o])/2},unique:(e,t)=>Array.from(new Set(t.map(n=>n.getValue(e))).values()),uniqueCount:(e,t)=>new Set(t.map(n=>n.getValue(e))).size,count:(e,t)=>t.length},B0={getDefaultColumnDef:()=>({aggregatedCell:e=>{var t,n;return(t=(n=e.getValue())==null||n.toString==null?void 0:n.toString())!=null?t:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:fe("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,t)=>{e.toggleGrouping=()=>{t.setGrouping(n=>n!=null&&n.includes(e.id)?n.filter(o=>o!==e.id):[...n??[],e.id])},e.getCanGroup=()=>{var n,o;return((n=e.columnDef.enableGrouping)!=null?n:!0)&&((o=t.options.enableGrouping)!=null?o:!0)&&(!!e.accessorFn||!!e.columnDef.getGroupingValue)},e.getIsGrouped=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.includes(e.id)},e.getGroupedIndex=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.indexOf(e.id)},e.getToggleGroupingHandler=()=>{const n=e.getCanGroup();return()=>{n&&e.toggleGrouping()}},e.getAutoAggregationFn=()=>{const n=t.getCoreRowModel().flatRows[0],o=n?.getValue(e.id);if(typeof o=="number")return vr.sum;if(Object.prototype.toString.call(o)==="[object Date]")return vr.extent},e.getAggregationFn=()=>{var n,o;if(!e)throw new Error;return yn(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:e.columnDef.aggregationFn==="auto"?e.getAutoAggregationFn():(n=(o=t.options.aggregationFns)==null?void 0:o[e.columnDef.aggregationFn])!=null?n:vr[e.columnDef.aggregationFn]}},createTable:e=>{e.setGrouping=t=>e.options.onGroupingChange==null?void 0:e.options.onGroupingChange(t),e.resetGrouping=t=>{var n,o;e.setGrouping(t?[]:(n=(o=e.initialState)==null?void 0:o.grouping)!=null?n:[])},e.getPreGroupedRowModel=()=>e.getFilteredRowModel(),e.getGroupedRowModel=()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())},createRow:(e,t)=>{e.getIsGrouped=()=>!!e.groupingColumnId,e.getGroupingValue=n=>{if(e._groupingValuesCache.hasOwnProperty(n))return e._groupingValuesCache[n];const o=t.getColumn(n);return o!=null&&o.columnDef.getGroupingValue?(e._groupingValuesCache[n]=o.columnDef.getGroupingValue(e.original),e._groupingValuesCache[n]):e.getValue(n)},e._groupingValuesCache={}},createCell:(e,t,n,o)=>{e.getIsGrouped=()=>t.getIsGrouped()&&t.id===n.groupingColumnId,e.getIsPlaceholder=()=>!e.getIsGrouped()&&t.getIsGrouped(),e.getIsAggregated=()=>{var r;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!!((r=n.subRows)!=null&&r.length)}}};function N0(e,t,n){if(!(t!=null&&t.length)||!n)return e;const o=e.filter(i=>!t.includes(i.id));return n==="remove"?o:[...t.map(i=>e.find(s=>s.id===i)).filter(Boolean),...o]}const z0={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:fe("columnOrder",e)}),createColumn:(e,t)=>{e.getIndex=R(n=>[Ht(t,n)],n=>n.findIndex(o=>o.id===e.id),_(t.options,"debugColumns","getIndex")),e.getIsFirstColumn=n=>{var o;return((o=Ht(t,n)[0])==null?void 0:o.id)===e.id},e.getIsLastColumn=n=>{var o;const r=Ht(t,n);return((o=r[r.length-1])==null?void 0:o.id)===e.id}},createTable:e=>{e.setColumnOrder=t=>e.options.onColumnOrderChange==null?void 0:e.options.onColumnOrderChange(t),e.resetColumnOrder=t=>{var n;e.setColumnOrder(t?[]:(n=e.initialState.columnOrder)!=null?n:[])},e._getOrderColumnsFn=R(()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode],(t,n,o)=>r=>{let i=[];if(!(t!=null&&t.length))i=r;else{const s=[...t],a=[...r];for(;a.length&&s.length;){const l=s.shift(),c=a.findIndex(d=>d.id===l);c>-1&&i.push(a.splice(c,1)[0])}i=[...i,...a]}return N0(i,n,o)},_(e.options,"debugTable","_getOrderColumnsFn"))}},yr=()=>({left:[],right:[]}),O0={getInitialState:e=>({columnPinning:yr(),...e}),getDefaultOptions:e=>({onColumnPinningChange:fe("columnPinning",e)}),createColumn:(e,t)=>{e.pin=n=>{const o=e.getLeafColumns().map(r=>r.id).filter(Boolean);t.setColumnPinning(r=>{var i,s;if(n==="right"){var a,l;return{left:((a=r?.left)!=null?a:[]).filter(u=>!(o!=null&&o.includes(u))),right:[...((l=r?.right)!=null?l:[]).filter(u=>!(o!=null&&o.includes(u))),...o]}}if(n==="left"){var c,d;return{left:[...((c=r?.left)!=null?c:[]).filter(u=>!(o!=null&&o.includes(u))),...o],right:((d=r?.right)!=null?d:[]).filter(u=>!(o!=null&&o.includes(u)))}}return{left:((i=r?.left)!=null?i:[]).filter(u=>!(o!=null&&o.includes(u))),right:((s=r?.right)!=null?s:[]).filter(u=>!(o!=null&&o.includes(u)))}})},e.getCanPin=()=>e.getLeafColumns().some(o=>{var r,i,s;return((r=o.columnDef.enablePinning)!=null?r:!0)&&((i=(s=t.options.enableColumnPinning)!=null?s:t.options.enablePinning)!=null?i:!0)}),e.getIsPinned=()=>{const n=e.getLeafColumns().map(a=>a.id),{left:o,right:r}=t.getState().columnPinning,i=n.some(a=>o?.includes(a)),s=n.some(a=>r?.includes(a));return i?"left":s?"right":!1},e.getPinnedIndex=()=>{var n,o;const r=e.getIsPinned();return r?(n=(o=t.getState().columnPinning)==null||(o=o[r])==null?void 0:o.indexOf(e.id))!=null?n:-1:0}},createRow:(e,t)=>{e.getCenterVisibleCells=R(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right],(n,o,r)=>{const i=[...o??[],...r??[]];return n.filter(s=>!i.includes(s.column.id))},_(t.options,"debugRows","getCenterVisibleCells")),e.getLeftVisibleCells=R(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left],(n,o)=>(o??[]).map(i=>n.find(s=>s.column.id===i)).filter(Boolean).map(i=>({...i,position:"left"})),_(t.options,"debugRows","getLeftVisibleCells")),e.getRightVisibleCells=R(()=>[e._getAllVisibleCells(),t.getState().columnPinning.right],(n,o)=>(o??[]).map(i=>n.find(s=>s.column.id===i)).filter(Boolean).map(i=>({...i,position:"right"})),_(t.options,"debugRows","getRightVisibleCells"))},createTable:e=>{e.setColumnPinning=t=>e.options.onColumnPinningChange==null?void 0:e.options.onColumnPinningChange(t),e.resetColumnPinning=t=>{var n,o;return e.setColumnPinning(t?yr():(n=(o=e.initialState)==null?void 0:o.columnPinning)!=null?n:yr())},e.getIsSomeColumnsPinned=t=>{var n;const o=e.getState().columnPinning;if(!t){var r,i;return!!((r=o.left)!=null&&r.length||(i=o.right)!=null&&i.length)}return!!((n=o[t])!=null&&n.length)},e.getLeftLeafColumns=R(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left],(t,n)=>(n??[]).map(o=>t.find(r=>r.id===o)).filter(Boolean),_(e.options,"debugColumns","getLeftLeafColumns")),e.getRightLeafColumns=R(()=>[e.getAllLeafColumns(),e.getState().columnPinning.right],(t,n)=>(n??[]).map(o=>t.find(r=>r.id===o)).filter(Boolean),_(e.options,"debugColumns","getRightLeafColumns")),e.getCenterLeafColumns=R(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,o)=>{const r=[...n??[],...o??[]];return t.filter(i=>!r.includes(i.id))},_(e.options,"debugColumns","getCenterLeafColumns"))}};function H0(e){return e||(typeof document<"u"?document:null)}const bn={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},wr=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}),j0={getDefaultColumnDef:()=>bn,getInitialState:e=>({columnSizing:{},columnSizingInfo:wr(),...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",columnResizeDirection:"ltr",onColumnSizingChange:fe("columnSizing",e),onColumnSizingInfoChange:fe("columnSizingInfo",e)}),createColumn:(e,t)=>{e.getSize=()=>{var n,o,r;const i=t.getState().columnSizing[e.id];return Math.min(Math.max((n=e.columnDef.minSize)!=null?n:bn.minSize,(o=i??e.columnDef.size)!=null?o:bn.size),(r=e.columnDef.maxSize)!=null?r:bn.maxSize)},e.getStart=R(n=>[n,Ht(t,n),t.getState().columnSizing],(n,o)=>o.slice(0,e.getIndex(n)).reduce((r,i)=>r+i.getSize(),0),_(t.options,"debugColumns","getStart")),e.getAfter=R(n=>[n,Ht(t,n),t.getState().columnSizing],(n,o)=>o.slice(e.getIndex(n)+1).reduce((r,i)=>r+i.getSize(),0),_(t.options,"debugColumns","getAfter")),e.resetSize=()=>{t.setColumnSizing(n=>{let{[e.id]:o,...r}=n;return r})},e.getCanResize=()=>{var n,o;return((n=e.columnDef.enableResizing)!=null?n:!0)&&((o=t.options.enableColumnResizing)!=null?o:!0)},e.getIsResizing=()=>t.getState().columnSizingInfo.isResizingColumn===e.id},createHeader:(e,t)=>{e.getSize=()=>{let n=0;const o=r=>{if(r.subHeaders.length)r.subHeaders.forEach(o);else{var i;n+=(i=r.column.getSize())!=null?i:0}};return o(e),n},e.getStart=()=>{if(e.index>0){const n=e.headerGroup.headers[e.index-1];return n.getStart()+n.getSize()}return 0},e.getResizeHandler=n=>{const o=t.getColumn(e.column.id),r=o?.getCanResize();return i=>{if(!o||!r||(i.persist==null||i.persist(),br(i)&&i.touches&&i.touches.length>1))return;const s=e.getSize(),a=e?e.getLeafHeaders().map(w=>[w.column.id,w.column.getSize()]):[[o.id,o.getSize()]],l=br(i)?Math.round(i.touches[0].clientX):i.clientX,c={},d=(w,S)=>{typeof S=="number"&&(t.setColumnSizingInfo(x=>{var P,T;const k=t.options.columnResizeDirection==="rtl"?-1:1,V=(S-((P=x?.startOffset)!=null?P:0))*k,$=Math.max(V/((T=x?.startSize)!=null?T:0),-.999999);return x.columnSizingStart.forEach(A=>{let[I,N]=A;c[I]=Math.round(Math.max(N+N*$,0)*100)/100}),{...x,deltaOffset:V,deltaPercentage:$}}),(t.options.columnResizeMode==="onChange"||w==="end")&&t.setColumnSizing(x=>({...x,...c})))},u=w=>d("move",w),f=w=>{d("end",w),t.setColumnSizingInfo(S=>({...S,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}))},h=H0(n),v={moveHandler:w=>u(w.clientX),upHandler:w=>{h?.removeEventListener("mousemove",v.moveHandler),h?.removeEventListener("mouseup",v.upHandler),f(w.clientX)}},y={moveHandler:w=>(w.cancelable&&(w.preventDefault(),w.stopPropagation()),u(w.touches[0].clientX),!1),upHandler:w=>{var S;h?.removeEventListener("touchmove",y.moveHandler),h?.removeEventListener("touchend",y.upHandler),w.cancelable&&(w.preventDefault(),w.stopPropagation()),f((S=w.touches[0])==null?void 0:S.clientX)}},b=G0()?{passive:!1}:!1;br(i)?(h?.addEventListener("touchmove",y.moveHandler,b),h?.addEventListener("touchend",y.upHandler,b)):(h?.addEventListener("mousemove",v.moveHandler,b),h?.addEventListener("mouseup",v.upHandler,b)),t.setColumnSizingInfo(w=>({...w,startOffset:l,startSize:s,deltaOffset:0,deltaPercentage:0,columnSizingStart:a,isResizingColumn:o.id}))}}},createTable:e=>{e.setColumnSizing=t=>e.options.onColumnSizingChange==null?void 0:e.options.onColumnSizingChange(t),e.setColumnSizingInfo=t=>e.options.onColumnSizingInfoChange==null?void 0:e.options.onColumnSizingInfoChange(t),e.resetColumnSizing=t=>{var n;e.setColumnSizing(t?{}:(n=e.initialState.columnSizing)!=null?n:{})},e.resetHeaderSizeInfo=t=>{var n;e.setColumnSizingInfo(t?wr():(n=e.initialState.columnSizingInfo)!=null?n:wr())},e.getTotalSize=()=>{var t,n;return(t=(n=e.getHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0},e.getLeftTotalSize=()=>{var t,n;return(t=(n=e.getLeftHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0},e.getCenterTotalSize=()=>{var t,n;return(t=(n=e.getCenterHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0},e.getRightTotalSize=()=>{var t,n;return(t=(n=e.getRightHeaderGroups()[0])==null?void 0:n.headers.reduce((o,r)=>o+r.getSize(),0))!=null?t:0}}};let xn=null;function G0(){if(typeof xn=="boolean")return xn;let e=!1;try{const t={get passive(){return e=!0,!1}},n=()=>{};window.addEventListener("test",n,t),window.removeEventListener("test",n)}catch{e=!1}return xn=e,xn}function br(e){return e.type==="touchstart"}const U0={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:fe("columnVisibility",e)}),createColumn:(e,t)=>{e.toggleVisibility=n=>{e.getCanHide()&&t.setColumnVisibility(o=>({...o,[e.id]:n??!e.getIsVisible()}))},e.getIsVisible=()=>{var n,o;const r=e.columns;return(n=r.length?r.some(i=>i.getIsVisible()):(o=t.getState().columnVisibility)==null?void 0:o[e.id])!=null?n:!0},e.getCanHide=()=>{var n,o;return((n=e.columnDef.enableHiding)!=null?n:!0)&&((o=t.options.enableHiding)!=null?o:!0)},e.getToggleVisibilityHandler=()=>n=>{e.toggleVisibility==null||e.toggleVisibility(n.target.checked)}},createRow:(e,t)=>{e._getAllVisibleCells=R(()=>[e.getAllCells(),t.getState().columnVisibility],n=>n.filter(o=>o.column.getIsVisible()),_(t.options,"debugRows","_getAllVisibleCells")),e.getVisibleCells=R(()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()],(n,o,r)=>[...n,...o,...r],_(t.options,"debugRows","getVisibleCells"))},createTable:e=>{const t=(n,o)=>R(()=>[o(),o().filter(r=>r.getIsVisible()).map(r=>r.id).join("_")],r=>r.filter(i=>i.getIsVisible==null?void 0:i.getIsVisible()),_(e.options,"debugColumns",n));e.getVisibleFlatColumns=t("getVisibleFlatColumns",()=>e.getAllFlatColumns()),e.getVisibleLeafColumns=t("getVisibleLeafColumns",()=>e.getAllLeafColumns()),e.getLeftVisibleLeafColumns=t("getLeftVisibleLeafColumns",()=>e.getLeftLeafColumns()),e.getRightVisibleLeafColumns=t("getRightVisibleLeafColumns",()=>e.getRightLeafColumns()),e.getCenterVisibleLeafColumns=t("getCenterVisibleLeafColumns",()=>e.getCenterLeafColumns()),e.setColumnVisibility=n=>e.options.onColumnVisibilityChange==null?void 0:e.options.onColumnVisibilityChange(n),e.resetColumnVisibility=n=>{var o;e.setColumnVisibility(n?{}:(o=e.initialState.columnVisibility)!=null?o:{})},e.toggleAllColumnsVisible=n=>{var o;n=(o=n)!=null?o:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce((r,i)=>({...r,[i.id]:n||!(i.getCanHide!=null&&i.getCanHide())}),{}))},e.getIsAllColumnsVisible=()=>!e.getAllLeafColumns().some(n=>!(n.getIsVisible!=null&&n.getIsVisible())),e.getIsSomeColumnsVisible=()=>e.getAllLeafColumns().some(n=>n.getIsVisible==null?void 0:n.getIsVisible()),e.getToggleAllColumnsVisibilityHandler=()=>n=>{var o;e.toggleAllColumnsVisible((o=n.target)==null?void 0:o.checked)}}};function Ht(e,t){return t?t==="center"?e.getCenterVisibleLeafColumns():t==="left"?e.getLeftVisibleLeafColumns():e.getRightVisibleLeafColumns():e.getVisibleLeafColumns()}const W0={createTable:e=>{e._getGlobalFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),e.getGlobalFacetedRowModel=()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),e._getGlobalFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),e.getGlobalFacetedUniqueValues=()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,e._getGlobalFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),e.getGlobalFacetedMinMaxValues=()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}}},K0={getInitialState:e=>({globalFilter:void 0,...e}),getDefaultOptions:e=>({onGlobalFilterChange:fe("globalFilter",e),globalFilterFn:"auto",getColumnCanGlobalFilter:t=>{var n;const o=(n=e.getCoreRowModel().flatRows[0])==null||(n=n._getAllCellsByColumnId()[t.id])==null?void 0:n.getValue();return typeof o=="string"||typeof o=="number"}}),createColumn:(e,t)=>{e.getCanGlobalFilter=()=>{var n,o,r,i;return((n=e.columnDef.enableGlobalFilter)!=null?n:!0)&&((o=t.options.enableGlobalFilter)!=null?o:!0)&&((r=t.options.enableFilters)!=null?r:!0)&&((i=t.options.getColumnCanGlobalFilter==null?void 0:t.options.getColumnCanGlobalFilter(e))!=null?i:!0)&&!!e.accessorFn}},createTable:e=>{e.getGlobalAutoFilterFn=()=>Fe.includesString,e.getGlobalFilterFn=()=>{var t,n;const{globalFilterFn:o}=e.options;return yn(o)?o:o==="auto"?e.getGlobalAutoFilterFn():(t=(n=e.options.filterFns)==null?void 0:n[o])!=null?t:Fe[o]},e.setGlobalFilter=t=>{e.options.onGlobalFilterChange==null||e.options.onGlobalFilterChange(t)},e.resetGlobalFilter=t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter)}}},q0={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:fe("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let t=!1,n=!1;e._autoResetExpanded=()=>{var o,r;if(!t){e._queue(()=>{t=!0});return}if((o=(r=e.options.autoResetAll)!=null?r:e.options.autoResetExpanded)!=null?o:!e.options.manualExpanding){if(n)return;n=!0,e._queue(()=>{e.resetExpanded(),n=!1})}},e.setExpanded=o=>e.options.onExpandedChange==null?void 0:e.options.onExpandedChange(o),e.toggleAllRowsExpanded=o=>{o??!e.getIsAllRowsExpanded()?e.setExpanded(!0):e.setExpanded({})},e.resetExpanded=o=>{var r,i;e.setExpanded(o?{}:(r=(i=e.initialState)==null?void 0:i.expanded)!=null?r:{})},e.getCanSomeRowsExpand=()=>e.getPrePaginationRowModel().flatRows.some(o=>o.getCanExpand()),e.getToggleAllRowsExpandedHandler=()=>o=>{o.persist==null||o.persist(),e.toggleAllRowsExpanded()},e.getIsSomeRowsExpanded=()=>{const o=e.getState().expanded;return o===!0||Object.values(o).some(Boolean)},e.getIsAllRowsExpanded=()=>{const o=e.getState().expanded;return typeof o=="boolean"?o===!0:!(!Object.keys(o).length||e.getRowModel().flatRows.some(r=>!r.getIsExpanded()))},e.getExpandedDepth=()=>{let o=0;return(e.getState().expanded===!0?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach(i=>{const s=i.split(".");o=Math.max(o,s.length)}),o},e.getPreExpandedRowModel=()=>e.getSortedRowModel(),e.getExpandedRowModel=()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())},createRow:(e,t)=>{e.toggleExpanded=n=>{t.setExpanded(o=>{var r;const i=o===!0?!0:!!(o!=null&&o[e.id]);let s={};if(o===!0?Object.keys(t.getRowModel().rowsById).forEach(a=>{s[a]=!0}):s=o,n=(r=n)!=null?r:!i,!i&&n)return{...s,[e.id]:!0};if(i&&!n){const{[e.id]:a,...l}=s;return l}return o})},e.getIsExpanded=()=>{var n;const o=t.getState().expanded;return!!((n=t.options.getIsRowExpanded==null?void 0:t.options.getIsRowExpanded(e))!=null?n:o===!0||o?.[e.id])},e.getCanExpand=()=>{var n,o,r;return(n=t.options.getRowCanExpand==null?void 0:t.options.getRowCanExpand(e))!=null?n:((o=t.options.enableExpanding)!=null?o:!0)&&!!((r=e.subRows)!=null&&r.length)},e.getIsAllParentsExpanded=()=>{let n=!0,o=e;for(;n&&o.parentId;)o=t.getRow(o.parentId,!0),n=o.getIsExpanded();return n},e.getToggleExpandedHandler=()=>{const n=e.getCanExpand();return()=>{n&&e.toggleExpanded()}}}},xr=0,Sr=10,Cr=()=>({pageIndex:xr,pageSize:Sr}),Y0={getInitialState:e=>({...e,pagination:{...Cr(),...e?.pagination}}),getDefaultOptions:e=>({onPaginationChange:fe("pagination",e)}),createTable:e=>{let t=!1,n=!1;e._autoResetPageIndex=()=>{var o,r;if(!t){e._queue(()=>{t=!0});return}if((o=(r=e.options.autoResetAll)!=null?r:e.options.autoResetPageIndex)!=null?o:!e.options.manualPagination){if(n)return;n=!0,e._queue(()=>{e.resetPageIndex(),n=!1})}},e.setPagination=o=>{const r=i=>He(o,i);return e.options.onPaginationChange==null?void 0:e.options.onPaginationChange(r)},e.resetPagination=o=>{var r;e.setPagination(o?Cr():(r=e.initialState.pagination)!=null?r:Cr())},e.setPageIndex=o=>{e.setPagination(r=>{let i=He(o,r.pageIndex);const s=typeof e.options.pageCount>"u"||e.options.pageCount===-1?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return i=Math.max(0,Math.min(i,s)),{...r,pageIndex:i}})},e.resetPageIndex=o=>{var r,i;e.setPageIndex(o?xr:(r=(i=e.initialState)==null||(i=i.pagination)==null?void 0:i.pageIndex)!=null?r:xr)},e.resetPageSize=o=>{var r,i;e.setPageSize(o?Sr:(r=(i=e.initialState)==null||(i=i.pagination)==null?void 0:i.pageSize)!=null?r:Sr)},e.setPageSize=o=>{e.setPagination(r=>{const i=Math.max(1,He(o,r.pageSize)),s=r.pageSize*r.pageIndex,a=Math.floor(s/i);return{...r,pageIndex:a,pageSize:i}})},e.setPageCount=o=>e.setPagination(r=>{var i;let s=He(o,(i=e.options.pageCount)!=null?i:-1);return typeof s=="number"&&(s=Math.max(-1,s)),{...r,pageCount:s}}),e.getPageOptions=R(()=>[e.getPageCount()],o=>{let r=[];return o&&o>0&&(r=[...new Array(o)].fill(null).map((i,s)=>s)),r},_(e.options,"debugTable","getPageOptions")),e.getCanPreviousPage=()=>e.getState().pagination.pageIndex>0,e.getCanNextPage=()=>{const{pageIndex:o}=e.getState().pagination,r=e.getPageCount();return r===-1?!0:r===0?!1:o<r-1},e.previousPage=()=>e.setPageIndex(o=>o-1),e.nextPage=()=>e.setPageIndex(o=>o+1),e.firstPage=()=>e.setPageIndex(0),e.lastPage=()=>e.setPageIndex(e.getPageCount()-1),e.getPrePaginationRowModel=()=>e.getExpandedRowModel(),e.getPaginationRowModel=()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),e.getPageCount=()=>{var o;return(o=e.options.pageCount)!=null?o:Math.ceil(e.getRowCount()/e.getState().pagination.pageSize)},e.getRowCount=()=>{var o;return(o=e.options.rowCount)!=null?o:e.getPrePaginationRowModel().rows.length}}},Tr=()=>({top:[],bottom:[]}),X0={getInitialState:e=>({rowPinning:Tr(),...e}),getDefaultOptions:e=>({onRowPinningChange:fe("rowPinning",e)}),createRow:(e,t)=>{e.pin=(n,o,r)=>{const i=o?e.getLeafRows().map(l=>{let{id:c}=l;return c}):[],s=r?e.getParentRows().map(l=>{let{id:c}=l;return c}):[],a=new Set([...s,e.id,...i]);t.setRowPinning(l=>{var c,d;if(n==="bottom"){var u,f;return{top:((u=l?.top)!=null?u:[]).filter(y=>!(a!=null&&a.has(y))),bottom:[...((f=l?.bottom)!=null?f:[]).filter(y=>!(a!=null&&a.has(y))),...Array.from(a)]}}if(n==="top"){var h,v;return{top:[...((h=l?.top)!=null?h:[]).filter(y=>!(a!=null&&a.has(y))),...Array.from(a)],bottom:((v=l?.bottom)!=null?v:[]).filter(y=>!(a!=null&&a.has(y)))}}return{top:((c=l?.top)!=null?c:[]).filter(y=>!(a!=null&&a.has(y))),bottom:((d=l?.bottom)!=null?d:[]).filter(y=>!(a!=null&&a.has(y)))}})},e.getCanPin=()=>{var n;const{enableRowPinning:o,enablePinning:r}=t.options;return typeof o=="function"?o(e):(n=o??r)!=null?n:!0},e.getIsPinned=()=>{const n=[e.id],{top:o,bottom:r}=t.getState().rowPinning,i=n.some(a=>o?.includes(a)),s=n.some(a=>r?.includes(a));return i?"top":s?"bottom":!1},e.getPinnedIndex=()=>{var n,o;const r=e.getIsPinned();if(!r)return-1;const i=(n=r==="top"?t.getTopRows():t.getBottomRows())==null?void 0:n.map(s=>{let{id:a}=s;return a});return(o=i?.indexOf(e.id))!=null?o:-1}},createTable:e=>{e.setRowPinning=t=>e.options.onRowPinningChange==null?void 0:e.options.onRowPinningChange(t),e.resetRowPinning=t=>{var n,o;return e.setRowPinning(t?Tr():(n=(o=e.initialState)==null?void 0:o.rowPinning)!=null?n:Tr())},e.getIsSomeRowsPinned=t=>{var n;const o=e.getState().rowPinning;if(!t){var r,i;return!!((r=o.top)!=null&&r.length||(i=o.bottom)!=null&&i.length)}return!!((n=o[t])!=null&&n.length)},e._getPinnedRows=(t,n,o)=>{var r;return((r=e.options.keepPinnedRows)==null||r?(n??[]).map(s=>{const a=e.getRow(s,!0);return a.getIsAllParentsExpanded()?a:null}):(n??[]).map(s=>t.find(a=>a.id===s))).filter(Boolean).map(s=>({...s,position:o}))},e.getTopRows=R(()=>[e.getRowModel().rows,e.getState().rowPinning.top],(t,n)=>e._getPinnedRows(t,n,"top"),_(e.options,"debugRows","getTopRows")),e.getBottomRows=R(()=>[e.getRowModel().rows,e.getState().rowPinning.bottom],(t,n)=>e._getPinnedRows(t,n,"bottom"),_(e.options,"debugRows","getBottomRows")),e.getCenterRows=R(()=>[e.getRowModel().rows,e.getState().rowPinning.top,e.getState().rowPinning.bottom],(t,n,o)=>{const r=new Set([...n??[],...o??[]]);return t.filter(i=>!r.has(i.id))},_(e.options,"debugRows","getCenterRows"))}},Z0={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:fe("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>{e.setRowSelection=t=>e.options.onRowSelectionChange==null?void 0:e.options.onRowSelectionChange(t),e.resetRowSelection=t=>{var n;return e.setRowSelection(t?{}:(n=e.initialState.rowSelection)!=null?n:{})},e.toggleAllRowsSelected=t=>{e.setRowSelection(n=>{t=typeof t<"u"?t:!e.getIsAllRowsSelected();const o={...n},r=e.getPreGroupedRowModel().flatRows;return t?r.forEach(i=>{i.getCanSelect()&&(o[i.id]=!0)}):r.forEach(i=>{delete o[i.id]}),o})},e.toggleAllPageRowsSelected=t=>e.setRowSelection(n=>{const o=typeof t<"u"?t:!e.getIsAllPageRowsSelected(),r={...n};return e.getRowModel().rows.forEach(i=>{$r(r,i.id,o,!0,e)}),r}),e.getPreSelectedRowModel=()=>e.getCoreRowModel(),e.getSelectedRowModel=R(()=>[e.getState().rowSelection,e.getCoreRowModel()],(t,n)=>Object.keys(t).length?Pr(e,n):{rows:[],flatRows:[],rowsById:{}},_(e.options,"debugTable","getSelectedRowModel")),e.getFilteredSelectedRowModel=R(()=>[e.getState().rowSelection,e.getFilteredRowModel()],(t,n)=>Object.keys(t).length?Pr(e,n):{rows:[],flatRows:[],rowsById:{}},_(e.options,"debugTable","getFilteredSelectedRowModel")),e.getGroupedSelectedRowModel=R(()=>[e.getState().rowSelection,e.getSortedRowModel()],(t,n)=>Object.keys(t).length?Pr(e,n):{rows:[],flatRows:[],rowsById:{}},_(e.options,"debugTable","getGroupedSelectedRowModel")),e.getIsAllRowsSelected=()=>{const t=e.getFilteredRowModel().flatRows,{rowSelection:n}=e.getState();let o=!!(t.length&&Object.keys(n).length);return o&&t.some(r=>r.getCanSelect()&&!n[r.id])&&(o=!1),o},e.getIsAllPageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows.filter(r=>r.getCanSelect()),{rowSelection:n}=e.getState();let o=!!t.length;return o&&t.some(r=>!n[r.id])&&(o=!1),o},e.getIsSomeRowsSelected=()=>{var t;const n=Object.keys((t=e.getState().rowSelection)!=null?t:{}).length;return n>0&&n<e.getFilteredRowModel().flatRows.length},e.getIsSomePageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows;return e.getIsAllPageRowsSelected()?!1:t.filter(n=>n.getCanSelect()).some(n=>n.getIsSelected()||n.getIsSomeSelected())},e.getToggleAllRowsSelectedHandler=()=>t=>{e.toggleAllRowsSelected(t.target.checked)},e.getToggleAllPageRowsSelectedHandler=()=>t=>{e.toggleAllPageRowsSelected(t.target.checked)}},createRow:(e,t)=>{e.toggleSelected=(n,o)=>{const r=e.getIsSelected();t.setRowSelection(i=>{var s;if(n=typeof n<"u"?n:!r,e.getCanSelect()&&r===n)return i;const a={...i};return $r(a,e.id,n,(s=o?.selectChildren)!=null?s:!0,t),a})},e.getIsSelected=()=>{const{rowSelection:n}=t.getState();return kr(e,n)},e.getIsSomeSelected=()=>{const{rowSelection:n}=t.getState();return Mr(e,n)==="some"},e.getIsAllSubRowsSelected=()=>{const{rowSelection:n}=t.getState();return Mr(e,n)==="all"},e.getCanSelect=()=>{var n;return typeof t.options.enableRowSelection=="function"?t.options.enableRowSelection(e):(n=t.options.enableRowSelection)!=null?n:!0},e.getCanSelectSubRows=()=>{var n;return typeof t.options.enableSubRowSelection=="function"?t.options.enableSubRowSelection(e):(n=t.options.enableSubRowSelection)!=null?n:!0},e.getCanMultiSelect=()=>{var n;return typeof t.options.enableMultiRowSelection=="function"?t.options.enableMultiRowSelection(e):(n=t.options.enableMultiRowSelection)!=null?n:!0},e.getToggleSelectedHandler=()=>{const n=e.getCanSelect();return o=>{var r;n&&e.toggleSelected((r=o.target)==null?void 0:r.checked)}}}},$r=(e,t,n,o,r)=>{var i;const s=r.getRow(t,!0);n?(s.getCanMultiSelect()||Object.keys(e).forEach(a=>delete e[a]),s.getCanSelect()&&(e[t]=!0)):delete e[t],o&&(i=s.subRows)!=null&&i.length&&s.getCanSelectSubRows()&&s.subRows.forEach(a=>$r(e,a.id,n,o,r))};function Pr(e,t){const n=e.getState().rowSelection,o=[],r={},i=function(s,a){return s.map(l=>{var c;const d=kr(l,n);if(d&&(o.push(l),r[l.id]=l),(c=l.subRows)!=null&&c.length&&(l={...l,subRows:i(l.subRows)}),d)return l}).filter(Boolean)};return{rows:i(t.rows),flatRows:o,rowsById:r}}function kr(e,t){var n;return(n=t[e.id])!=null?n:!1}function Mr(e,t,n){var o;if(!((o=e.subRows)!=null&&o.length))return!1;let r=!0,i=!1;return e.subRows.forEach(s=>{if(!(i&&!r)&&(s.getCanSelect()&&(kr(s,t)?i=!0:r=!1),s.subRows&&s.subRows.length)){const a=Mr(s,t);a==="all"?i=!0:(a==="some"&&(i=!0),r=!1)}}),r?"all":i?"some":!1}const Vr=/([0-9]+)/gm,J0=(e,t,n)=>Wl(je(e.getValue(n)).toLowerCase(),je(t.getValue(n)).toLowerCase()),Q0=(e,t,n)=>Wl(je(e.getValue(n)),je(t.getValue(n))),ev=(e,t,n)=>Er(je(e.getValue(n)).toLowerCase(),je(t.getValue(n)).toLowerCase()),tv=(e,t,n)=>Er(je(e.getValue(n)),je(t.getValue(n))),nv=(e,t,n)=>{const o=e.getValue(n),r=t.getValue(n);return o>r?1:o<r?-1:0},ov=(e,t,n)=>Er(e.getValue(n),t.getValue(n));function Er(e,t){return e===t?0:e>t?1:-1}function je(e){return typeof e=="number"?isNaN(e)||e===1/0||e===-1/0?"":String(e):typeof e=="string"?e:""}function Wl(e,t){const n=e.split(Vr).filter(Boolean),o=t.split(Vr).filter(Boolean);for(;n.length&&o.length;){const r=n.shift(),i=o.shift(),s=parseInt(r,10),a=parseInt(i,10),l=[s,a].sort();if(isNaN(l[0])){if(r>i)return 1;if(i>r)return-1;continue}if(isNaN(l[1]))return isNaN(s)?-1:1;if(s>a)return 1;if(a>s)return-1}return n.length-o.length}const jt={alphanumeric:J0,alphanumericCaseSensitive:Q0,text:ev,textCaseSensitive:tv,datetime:nv,basic:ov},rv=[L0,U0,z0,O0,R0,_0,W0,K0,{getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto",sortUndefined:1}),getDefaultOptions:e=>({onSortingChange:fe("sorting",e),isMultiSortEvent:t=>t.shiftKey}),createColumn:(e,t)=>{e.getAutoSortingFn=()=>{const n=t.getFilteredRowModel().flatRows.slice(10);let o=!1;for(const r of n){const i=r?.getValue(e.id);if(Object.prototype.toString.call(i)==="[object Date]")return jt.datetime;if(typeof i=="string"&&(o=!0,i.split(Vr).length>1))return jt.alphanumeric}return o?jt.text:jt.basic},e.getAutoSortDir=()=>{const n=t.getFilteredRowModel().flatRows[0];return typeof n?.getValue(e.id)=="string"?"asc":"desc"},e.getSortingFn=()=>{var n,o;if(!e)throw new Error;return yn(e.columnDef.sortingFn)?e.columnDef.sortingFn:e.columnDef.sortingFn==="auto"?e.getAutoSortingFn():(n=(o=t.options.sortingFns)==null?void 0:o[e.columnDef.sortingFn])!=null?n:jt[e.columnDef.sortingFn]},e.toggleSorting=(n,o)=>{const r=e.getNextSortingOrder(),i=typeof n<"u"&&n!==null;t.setSorting(s=>{const a=s?.find(h=>h.id===e.id),l=s?.findIndex(h=>h.id===e.id);let c=[],d,u=i?n:r==="desc";if(s!=null&&s.length&&e.getCanMultiSort()&&o?a?d="toggle":d="add":s!=null&&s.length&&l!==s.length-1?d="replace":a?d="toggle":d="replace",d==="toggle"&&(i||r||(d="remove")),d==="add"){var f;c=[...s,{id:e.id,desc:u}],c.splice(0,c.length-((f=t.options.maxMultiSortColCount)!=null?f:Number.MAX_SAFE_INTEGER))}else d==="toggle"?c=s.map(h=>h.id===e.id?{...h,desc:u}:h):d==="remove"?c=s.filter(h=>h.id!==e.id):c=[{id:e.id,desc:u}];return c})},e.getFirstSortDir=()=>{var n,o;return((n=(o=e.columnDef.sortDescFirst)!=null?o:t.options.sortDescFirst)!=null?n:e.getAutoSortDir()==="desc")?"desc":"asc"},e.getNextSortingOrder=n=>{var o,r;const i=e.getFirstSortDir(),s=e.getIsSorted();return s?s!==i&&((o=t.options.enableSortingRemoval)==null||o)&&(!(n&&(r=t.options.enableMultiRemove)!=null)||r)?!1:s==="desc"?"asc":"desc":i},e.getCanSort=()=>{var n,o;return((n=e.columnDef.enableSorting)!=null?n:!0)&&((o=t.options.enableSorting)!=null?o:!0)&&!!e.accessorFn},e.getCanMultiSort=()=>{var n,o;return(n=(o=e.columnDef.enableMultiSort)!=null?o:t.options.enableMultiSort)!=null?n:!!e.accessorFn},e.getIsSorted=()=>{var n;const o=(n=t.getState().sorting)==null?void 0:n.find(r=>r.id===e.id);return o?o.desc?"desc":"asc":!1},e.getSortIndex=()=>{var n,o;return(n=(o=t.getState().sorting)==null?void 0:o.findIndex(r=>r.id===e.id))!=null?n:-1},e.clearSorting=()=>{t.setSorting(n=>n!=null&&n.length?n.filter(o=>o.id!==e.id):[])},e.getToggleSortingHandler=()=>{const n=e.getCanSort();return o=>{n&&(o.persist==null||o.persist(),e.toggleSorting==null||e.toggleSorting(void 0,e.getCanMultiSort()?t.options.isMultiSortEvent==null?void 0:t.options.isMultiSortEvent(o):!1))}}},createTable:e=>{e.setSorting=t=>e.options.onSortingChange==null?void 0:e.options.onSortingChange(t),e.resetSorting=t=>{var n,o;e.setSorting(t?[]:(n=(o=e.initialState)==null?void 0:o.sorting)!=null?n:[])},e.getPreSortedRowModel=()=>e.getGroupedRowModel(),e.getSortedRowModel=()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())}},B0,q0,Y0,X0,Z0,j0];function iv(e){var t,n;process.env.NODE_ENV!=="production"&&(e.debugAll||e.debugTable)&&console.info("Creating Table Instance...");const o=[...rv,...(t=e._features)!=null?t:[]];let r={_features:o};const i=r._features.reduce((f,h)=>Object.assign(f,h.getDefaultOptions==null?void 0:h.getDefaultOptions(r)),{}),s=f=>r.options.mergeOptions?r.options.mergeOptions(i,f):{...i,...f};let l={...{},...(n=e.initialState)!=null?n:{}};r._features.forEach(f=>{var h;l=(h=f.getInitialState==null?void 0:f.getInitialState(l))!=null?h:l});const c=[];let d=!1;const u={_features:o,options:{...i,...e},initialState:l,_queue:f=>{c.push(f),d||(d=!0,Promise.resolve().then(()=>{for(;c.length;)c.shift()();d=!1}).catch(h=>setTimeout(()=>{throw h})))},reset:()=>{r.setState(r.initialState)},setOptions:f=>{const h=He(f,r.options);r.options=s(h)},getState:()=>r.options.state,setState:f=>{r.options.onStateChange==null||r.options.onStateChange(f)},_getRowId:(f,h,v)=>{var y;return(y=r.options.getRowId==null?void 0:r.options.getRowId(f,h,v))!=null?y:`${v?[v.id,h].join("."):h}`},getCoreRowModel:()=>(r._getCoreRowModel||(r._getCoreRowModel=r.options.getCoreRowModel(r)),r._getCoreRowModel()),getRowModel:()=>r.getPaginationRowModel(),getRow:(f,h)=>{let v=(h?r.getPrePaginationRowModel():r.getRowModel()).rowsById[f];if(!v&&(v=r.getCoreRowModel().rowsById[f],!v))throw process.env.NODE_ENV!=="production"?new Error(`getRow could not find row with ID: ${f}`):new Error;return v},_getDefaultColumnDef:R(()=>[r.options.defaultColumn],f=>{var h;return f=(h=f)!=null?h:{},{header:v=>{const y=v.header.column.columnDef;return y.accessorKey?y.accessorKey:y.accessorFn?y.id:null},cell:v=>{var y,b;return(y=(b=v.renderValue())==null||b.toString==null?void 0:b.toString())!=null?y:null},...r._features.reduce((v,y)=>Object.assign(v,y.getDefaultColumnDef==null?void 0:y.getDefaultColumnDef()),{}),...f}},_(e,"debugColumns","_getDefaultColumnDef")),_getColumnDefs:()=>r.options.columns,getAllColumns:R(()=>[r._getColumnDefs()],f=>{const h=function(v,y,b){return b===void 0&&(b=0),v.map(w=>{const S=I0(r,w,b,y),x=w;return S.columns=x.columns?h(x.columns,S,b+1):[],S})};return h(f)},_(e,"debugColumns","getAllColumns")),getAllFlatColumns:R(()=>[r.getAllColumns()],f=>f.flatMap(h=>h.getFlatColumns()),_(e,"debugColumns","getAllFlatColumns")),_getAllFlatColumnsById:R(()=>[r.getAllFlatColumns()],f=>f.reduce((h,v)=>(h[v.id]=v,h),{}),_(e,"debugColumns","getAllFlatColumnsById")),getAllLeafColumns:R(()=>[r.getAllColumns(),r._getOrderColumnsFn()],(f,h)=>{let v=f.flatMap(y=>y.getLeafColumns());return h(v)},_(e,"debugColumns","getAllLeafColumns")),getColumn:f=>{const h=r._getAllFlatColumnsById()[f];return process.env.NODE_ENV!=="production"&&!h&&console.error(`[Table] Column with id '${f}' does not exist.`),h}};Object.assign(r,u);for(let f=0;f<r._features.length;f++){const h=r._features[f];h==null||h.createTable==null||h.createTable(r)}return r}function sv(){return e=>R(()=>[e.options.data],t=>{const n={rows:[],flatRows:[],rowsById:{}},o=function(r,i,s){i===void 0&&(i=0);const a=[];for(let c=0;c<r.length;c++){const d=pr(e,e._getRowId(r[c],c,s),r[c],c,i,void 0,s?.id);if(n.flatRows.push(d),n.rowsById[d.id]=d,a.push(d),e.options.getSubRows){var l;d.originalSubRows=e.options.getSubRows(r[c],c),(l=d.originalSubRows)!=null&&l.length&&(d.subRows=o(d.originalSubRows,i+1,d))}}return a};return n.rows=o(t),n},_(e.options,"debugTable","getRowModel",()=>e._autoResetPageIndex()))}function av(e,t,n){return n.options.filterFromLeafRows?lv(e,t,n):cv(e,t,n)}function lv(e,t,n){var o;const r=[],i={},s=(o=n.options.maxLeafRowFilterDepth)!=null?o:100,a=function(l,c){c===void 0&&(c=0);const d=[];for(let f=0;f<l.length;f++){var u;let h=l[f];const v=pr(n,h.id,h.original,h.index,h.depth,void 0,h.parentId);if(v.columnFilters=h.columnFilters,(u=h.subRows)!=null&&u.length&&c<s){if(v.subRows=a(h.subRows,c+1),h=v,t(h)&&!v.subRows.length){d.push(h),i[h.id]=h,r.push(h);continue}if(t(h)||v.subRows.length){d.push(h),i[h.id]=h,r.push(h);continue}}else h=v,t(h)&&(d.push(h),i[h.id]=h,r.push(h))}return d};return{rows:a(e),flatRows:r,rowsById:i}}function cv(e,t,n){var o;const r=[],i={},s=(o=n.options.maxLeafRowFilterDepth)!=null?o:100,a=function(l,c){c===void 0&&(c=0);const d=[];for(let f=0;f<l.length;f++){let h=l[f];if(t(h)){var u;if((u=h.subRows)!=null&&u.length&&c<s){const y=pr(n,h.id,h.original,h.index,h.depth,void 0,h.parentId);y.subRows=a(h.subRows,c+1),h=y}d.push(h),r.push(h),i[h.id]=h}}return d};return{rows:a(e),flatRows:r,rowsById:i}}function uv(){return e=>R(()=>[e.getPreFilteredRowModel(),e.getState().columnFilters,e.getState().globalFilter],(t,n,o)=>{if(!t.rows.length||!(n!=null&&n.length)&&!o){for(let f=0;f<t.flatRows.length;f++)t.flatRows[f].columnFilters={},t.flatRows[f].columnFiltersMeta={};return t}const r=[],i=[];(n??[]).forEach(f=>{var h;const v=e.getColumn(f.id);if(!v)return;const y=v.getFilterFn();if(!y){process.env.NODE_ENV!=="production"&&console.warn(`Could not find a valid 'column.filterFn' for column with the ID: ${v.id}.`);return}r.push({id:f.id,filterFn:y,resolvedValue:(h=y.resolveFilterValue==null?void 0:y.resolveFilterValue(f.value))!=null?h:f.value})});const s=(n??[]).map(f=>f.id),a=e.getGlobalFilterFn(),l=e.getAllLeafColumns().filter(f=>f.getCanGlobalFilter());o&&a&&l.length&&(s.push("__global__"),l.forEach(f=>{var h;i.push({id:f.id,filterFn:a,resolvedValue:(h=a.resolveFilterValue==null?void 0:a.resolveFilterValue(o))!=null?h:o})}));let c,d;for(let f=0;f<t.flatRows.length;f++){const h=t.flatRows[f];if(h.columnFilters={},r.length)for(let v=0;v<r.length;v++){c=r[v];const y=c.id;h.columnFilters[y]=c.filterFn(h,y,c.resolvedValue,b=>{h.columnFiltersMeta[y]=b})}if(i.length){for(let v=0;v<i.length;v++){d=i[v];const y=d.id;if(d.filterFn(h,y,d.resolvedValue,b=>{h.columnFiltersMeta[y]=b})){h.columnFilters.__global__=!0;break}}h.columnFilters.__global__!==!0&&(h.columnFilters.__global__=!1)}}const u=f=>{for(let h=0;h<s.length;h++)if(f.columnFilters[s[h]]===!1)return!1;return!0};return av(t.rows,u,e)},_(e.options,"debugTable","getFilteredRowModel",()=>e._autoResetPageIndex()))}function dv(){return e=>R(()=>[e.getState().sorting,e.getPreSortedRowModel()],(t,n)=>{if(!n.rows.length||!(t!=null&&t.length))return n;const o=e.getState().sorting,r=[],i=o.filter(l=>{var c;return(c=e.getColumn(l.id))==null?void 0:c.getCanSort()}),s={};i.forEach(l=>{const c=e.getColumn(l.id);c&&(s[l.id]={sortUndefined:c.columnDef.sortUndefined,invertSorting:c.columnDef.invertSorting,sortingFn:c.getSortingFn()})});const a=l=>{const c=l.map(d=>({...d}));return c.sort((d,u)=>{for(let h=0;h<i.length;h+=1){var f;const v=i[h],y=s[v.id],b=y.sortUndefined,w=(f=v?.desc)!=null?f:!1;let S=0;if(b){const x=d.getValue(v.id),P=u.getValue(v.id),T=x===void 0,k=P===void 0;if(T||k){if(b==="first")return T?-1:1;if(b==="last")return T?1:-1;S=T&&k?0:T?b:-b}}if(S===0&&(S=y.sortingFn(d,u,v.id)),S!==0)return w&&(S*=-1),y.invertSorting&&(S*=-1),S}return d.index-u.index}),c.forEach(d=>{var u;r.push(d),(u=d.subRows)!=null&&u.length&&(d.subRows=a(d.subRows))}),c};return{rows:a(n.rows),flatRows:r,rowsById:n.rowsById}},_(e.options,"debugTable","getSortedRowModel",()=>e._autoResetPageIndex()))}function Sn(e,t){return e?fv(e)?Ue.createElement(e,t):e:null}function fv(e){return hv(e)||typeof e=="function"||mv(e)}function hv(e){return typeof e=="function"&&(()=>{const t=Object.getPrototypeOf(e);return t.prototype&&t.prototype.isReactComponent})()}function mv(e){return typeof e=="object"&&typeof e.$$typeof=="symbol"&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}function pv(e){const t={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[n]=Ue.useState(()=>({current:iv(t)})),[o,r]=Ue.useState(()=>n.current.initialState);return n.current.setOptions(i=>({...i,...e,state:{...o,...e.state},onStateChange:s=>{r(s),e.onStateChange==null||e.onStateChange(s)}})),n.current}const gv=g.css`
1606
1635
  @media (max-width: 768px) {
1607
1636
  font-size: 0.875rem;
1608
1637
 
@@ -1611,7 +1640,7 @@
1611
1640
  padding: 0.5rem 0.75rem;
1612
1641
  }
1613
1642
  }
1614
- `,mv={default:g.css`
1643
+ `,vv={default:g.css`
1615
1644
  thead tr:last-child th:first-child {
1616
1645
  border-top-left-radius: var(--border-radius-article);
1617
1646
  }
@@ -1648,7 +1677,7 @@
1648
1677
  tbody tr:last-child td:last-child {
1649
1678
  border-bottom-right-radius: var(--border-radius-article);
1650
1679
  }
1651
- `},Qe={sm:g.css`
1680
+ `},et={sm:g.css`
1652
1681
  padding: 0.5rem 1rem;
1653
1682
  min-height: 2.25rem;
1654
1683
  `,md:g.css`
@@ -1662,14 +1691,14 @@
1662
1691
  align-items: center;
1663
1692
  gap: 0.5rem;
1664
1693
  width: 100%;
1665
- `,pv=g.div`
1694
+ `,yv=g.div`
1666
1695
  position: relative;
1667
1696
  border-radius: var(--border-radius-article);
1668
1697
  overflow-y: ${({$maxHeight:e})=>e?"auto":"visible"};
1669
1698
  overflow-x: auto;
1670
1699
  max-height: ${({$maxHeight:e})=>e?typeof e=="number"?`${e}px`:e:"none"};
1671
1700
  max-width: 100%;
1672
- `,gv=g.table`
1701
+ `,wv=g.table`
1673
1702
  width: 100%;
1674
1703
  border-collapse: separate;
1675
1704
  border-spacing: 0;
@@ -1677,9 +1706,9 @@
1677
1706
  border-radius: var(--border-radius-article);
1678
1707
  border: 1px solid var(--color-main-light-borders);
1679
1708
 
1680
- ${({$variant:e})=>mv[e]}
1681
- ${hv}
1682
- `,vv=g.thead`
1709
+ ${({$variant:e})=>vv[e]}
1710
+ ${gv}
1711
+ `,bv=g.thead`
1683
1712
  ${({$sticky:e})=>e&&g.css`
1684
1713
  position: sticky;
1685
1714
  top: 0;
@@ -1689,7 +1718,7 @@
1689
1718
  & > tr > th {
1690
1719
  overflow: visible;
1691
1720
  }
1692
- `,Wl=g.tr`
1721
+ `,ql=g.tr`
1693
1722
  &:hover {
1694
1723
  background-color: var(--color-main-alternative-secondary);
1695
1724
  }
@@ -1703,7 +1732,7 @@
1703
1732
  transition: transform 0.2s ease-out;
1704
1733
  opacity: ${({$direction:e})=>e==="none"?.5:1};
1705
1734
  transform: ${({$direction:e})=>e==="asc"?"rotate(180deg)":"none"};
1706
- `;const ql=(e=!1,t=0)=>e?g.css`
1735
+ `;const Yl=(e=!1,t=0)=>e?g.css`
1707
1736
  position: sticky;
1708
1737
  ${e==="left"?`left: ${t}px;`:`right: ${t}px;`}
1709
1738
  z-index: 20;
@@ -1718,19 +1747,19 @@
1718
1747
  background-color: var(--color-main-light-borders);
1719
1748
  box-shadow: ${e==="left"?"2px 0 4px rgba(0, 0, 0, 0.3)":"-2px 0 4px rgba(0, 0, 0, 0.3)"};
1720
1749
  }
1721
- `:"",yv={sm:g.css`
1722
- ${Qe.sm}
1750
+ `:"",xv={sm:g.css`
1751
+ ${et.sm}
1723
1752
  ${D[12]}
1724
1753
  `,md:g.css`
1725
- ${Qe.md}
1754
+ ${et.md}
1726
1755
  ${D[16]}
1727
1756
  `,lg:g.css`
1728
- ${Qe.lg}
1757
+ ${et.lg}
1729
1758
  ${D[16]}
1730
- `},wv=g.th`
1759
+ `},Sv=g.th`
1731
1760
  background-color: var(--color-main-blue-primary);
1732
1761
  color: var(--color-main-white);
1733
- ${({$size:e})=>yv[e]}
1762
+ ${({$size:e})=>xv[e]}
1734
1763
  transition: background-color 0.3s ease-out, box-shadow 0.3s ease-out, border-color 0.3s ease-out;
1735
1764
  min-width: 8rem;
1736
1765
  width: ${({$width:e})=>e?typeof e=="number"?`${e}px`:e:"fit-content"};
@@ -1739,7 +1768,7 @@
1739
1768
  position: relative;
1740
1769
 
1741
1770
  // Pinned styles
1742
- ${({$pinned:e,$pinnedOffset:t})=>ql(e,t)}
1771
+ ${({$pinned:e,$pinnedOffset:t})=>Yl(e,t)}
1743
1772
 
1744
1773
  &:hover {
1745
1774
  background-color: var(--color-purple-600);
@@ -1748,10 +1777,10 @@
1748
1777
  ${({$active:e})=>e&&g.css`
1749
1778
  background-color: var(--color-blue-600);
1750
1779
  `}
1751
- `,Yl=g.div`
1780
+ `,Xl=g.div`
1752
1781
  ${Kl};
1753
1782
  justify-content: ${({$align:e})=>e||"space-between"};
1754
- `,Xl=g.button`
1783
+ `,Zl=g.button`
1755
1784
  all: unset;
1756
1785
  display: inline-flex;
1757
1786
  align-items: center;
@@ -1768,7 +1797,7 @@
1768
1797
  &:focus-visible {
1769
1798
  outline-color: var(--color-main-white);
1770
1799
  }
1771
- `,bv=g.span`
1800
+ `,Cv=g.span`
1772
1801
  display: inline-flex;
1773
1802
  align-items: center;
1774
1803
  justify-content: center;
@@ -1780,10 +1809,10 @@
1780
1809
  transform 0.25s ease-out,
1781
1810
  opacity 0.2s ease-out;
1782
1811
 
1783
- ${Xl}:hover & {
1812
+ ${Zl}:hover & {
1784
1813
  opacity: 1;
1785
1814
  }
1786
- `,xv=g.div`
1815
+ `,Tv=g.div`
1787
1816
  display: flex;
1788
1817
  align-items: center;
1789
1818
  padding: 0.5rem 0.75rem;
@@ -1803,7 +1832,7 @@
1803
1832
  input {
1804
1833
  pointer-events: none;
1805
1834
  }
1806
- `,Vr=m.memo(({value:e,label:t,checked:n,onChange:o})=>{const r=()=>{o(e,!n)};return p.jsx(xv,{onClick:r,children:p.jsx(zt,{id:e,name:e,checked:n,onChange:()=>{},size:"sm",checkboxClassName:"filter-option-checkbox",label:t})})});Vr.displayName="FilterOption";function Er(e,t,n){const o=new Set;return e.forEach((r,i)=>{let s;n?s=n(r,i):s=r[t],s!=null&&o.add(String(s))}),Array.from(o).sort((r,i)=>r.localeCompare(i))}function Dr(e,t,n){const o=n;if(!o||o.length===0)return!0;const r=e.getValue(t);return r!=null?o.includes(String(r)):!1}function Zl(e,t){if(!t||t.trim()==="")return e;const n=t.toLowerCase().trim();return e.filter(o=>o.toLowerCase().includes(n))}function Sv(e,t,n){const o={};return e.forEach((r,i)=>{let s;if(n?s=n(r,i):s=r[t],s!=null){const a=String(s);o[a]=(o[a]||0)+1}}),o}function Cv(e,t){const n=e.find(o=>o.id===t);return n?n.value?.length>0:!1}function Jl(e,t){const n=e.find(o=>o.id===t);return n?n.value||[]:[]}function Tv(e){return e.reduce((t,n)=>{const o=n.value;return t+(o?.length||0)},0)}const $v=g.div`
1835
+ `,Dr=m.memo(({value:e,label:t,checked:n,onChange:o})=>{const r=()=>{o(e,!n)};return p.jsx(Tv,{onClick:r,children:p.jsx(Ot,{id:e,name:e,checked:n,onChange:()=>{},size:"sm",checkboxClassName:"filter-option-checkbox",label:t})})});Dr.displayName="FilterOption";function Fr(e,t,n){const o=new Set;return e.forEach((r,i)=>{let s;n?s=n(r,i):s=r[t],s!=null&&o.add(String(s))}),Array.from(o).sort((r,i)=>r.localeCompare(i))}function Ar(e,t,n){const o=n;if(!o||o.length===0)return!0;const r=e.getValue(t);return r!=null?o.includes(String(r)):!1}function Jl(e,t){if(!t||t.trim()==="")return e;const n=t.toLowerCase().trim();return e.filter(o=>o.toLowerCase().includes(n))}function $v(e,t,n){const o={};return e.forEach((r,i)=>{let s;if(n?s=n(r,i):s=r[t],s!=null){const a=String(s);o[a]=(o[a]||0)+1}}),o}function Pv(e,t){const n=e.find(o=>o.id===t);return n?n.value?.length>0:!1}function Ql(e,t){const n=e.find(o=>o.id===t);return n?n.value||[]:[]}function kv(e){return e.reduce((t,n)=>{const o=n.value;return t+(o?.length||0)},0)}const Mv=g.div`
1807
1836
  position: fixed;
1808
1837
  right: 0;
1809
1838
  margin-top: 0.25rem;
@@ -1819,23 +1848,23 @@
1819
1848
  display: flex;
1820
1849
  flex-direction: column;
1821
1850
  max-height: 400px;
1822
- `,Pv=g.div`
1851
+ `,Vv=g.div`
1823
1852
  flex: 1;
1824
1853
  overflow-y: auto;
1825
1854
  padding: 0.5rem;
1826
1855
  max-height: 280px;
1827
- `,kv=g.div`
1856
+ `,Ev=g.div`
1828
1857
  display: flex;
1829
1858
  gap: 0.5rem;
1830
1859
  padding: 0.75rem;
1831
1860
  border-top: 1px solid var(--color-neutral-200);
1832
1861
  background: var(--color-neutral-50);
1833
- `,Mv=g.div`
1862
+ `,Dv=g.div`
1834
1863
  padding: 0.5rem 0.75rem;
1835
1864
  border-bottom: 1px solid var(--color-neutral-200);
1836
1865
  display: flex;
1837
1866
  gap: 0.5rem;
1838
- `,Vv=g.button`
1867
+ `,Fv=g.button`
1839
1868
  flex: 1;
1840
1869
  padding: 0.375rem 0.5rem;
1841
1870
  font-size: 0.75rem;
@@ -1854,10 +1883,10 @@
1854
1883
  &:active {
1855
1884
  transform: scale(0.98);
1856
1885
  }
1857
- `,Fr=({options:e,selectedValues:t,onChange:n,onClose:o,searchPlaceholder:r="Search...",position:i})=>{const[s,a]=m.useState(""),l=m.useMemo(()=>Zl(e,s),[e,s]),c=m.useMemo(()=>l.length===0?!1:l.every(y=>t.includes(y)),[l,t]),d=m.useCallback((y,b)=>{n(b?[...t,y]:t.filter(w=>w!==y))},[t,n]),u=m.useCallback(()=>{const y=[...new Set([...t,...l])];n(y)},[t,l,n]),h=m.useCallback(()=>{const y=t.filter(b=>!l.includes(b));n(y)},[t,l,n]),f=m.useCallback(()=>{n([])},[n]),v=m.useCallback(()=>{o()},[o]);return p.jsx(p.Fragment,{children:p.jsxs($v,{role:"dialog","aria-labelledby":"column-filter-menu-title","aria-describedby":"column-filter-menu-description",onClick:y=>y.stopPropagation(),style:{top:`${i.top}px`,left:`${i.left}px`},children:[p.jsx("div",{className:"p-2",children:p.jsx(tr,{value:s,onSearch:a,placeholder:r,size:"xs"})}),l.length>0&&p.jsx(Mv,{children:p.jsx(Vv,{onClick:c?h:u,type:"button",children:c?"Deselect All":"Select All"})}),p.jsx(Pv,{children:l.length>0?l.map(y=>p.jsx(Vr,{value:y,label:y,checked:t.includes(y),onChange:d},y)):p.jsx(ht,{children:s?"No matching options":"No options available"})}),p.jsxs(kv,{children:[p.jsx(ft,{variant:"outline",size:"sm",onClick:f,disabled:t.length===0,className:"flex-1",children:"Clear"}),p.jsx(ft,{variant:"primary",size:"sm",onClick:v,className:"flex-1",children:"Close"})]})]})})};Fr.displayName="ColumnFilterMenu";function Ev(e,t,n,o=!0){m.useEffect(()=>{if(!o)return;const r=i=>{const s=i.target;e.current&&!e.current.contains(s)&&!t.current?.contains(s)&&n()};return document.addEventListener("mousedown",r),()=>{document.removeEventListener("mousedown",r)}},[e,t,n,o])}const Dv=g.div`
1886
+ `,Ir=({options:e,selectedValues:t,onChange:n,onClose:o,searchPlaceholder:r="Search...",position:i})=>{const[s,a]=m.useState(""),l=m.useMemo(()=>Jl(e,s),[e,s]),c=m.useMemo(()=>l.length===0?!1:l.every(y=>t.includes(y)),[l,t]),d=m.useCallback((y,b)=>{n(b?[...t,y]:t.filter(w=>w!==y))},[t,n]),u=m.useCallback(()=>{const y=[...new Set([...t,...l])];n(y)},[t,l,n]),f=m.useCallback(()=>{const y=t.filter(b=>!l.includes(b));n(y)},[t,l,n]),h=m.useCallback(()=>{n([])},[n]),v=m.useCallback(()=>{o()},[o]);return p.jsx(p.Fragment,{children:p.jsxs(Mv,{role:"dialog","aria-labelledby":"column-filter-menu-title","aria-describedby":"column-filter-menu-description",onClick:y=>y.stopPropagation(),style:{top:`${i.top}px`,left:`${i.left}px`},children:[p.jsx("div",{className:"p-2",children:p.jsx(nr,{value:s,onSearch:a,placeholder:r,size:"xs"})}),l.length>0&&p.jsx(Dv,{children:p.jsx(Fv,{onClick:c?f:u,type:"button",children:c?"Deselect All":"Select All"})}),p.jsx(Vv,{children:l.length>0?l.map(y=>p.jsx(Dr,{value:y,label:y,checked:t.includes(y),onChange:d},y)):p.jsx(mt,{children:s?"No matching options":"No options available"})}),p.jsxs(Ev,{children:[p.jsx(ht,{variant:"outline",size:"sm",onClick:h,disabled:t.length===0,className:"flex-1",children:"Clear"}),p.jsx(ht,{variant:"primary",size:"sm",onClick:v,className:"flex-1",children:"Close"})]})]})})};Ir.displayName="ColumnFilterMenu";function Av(e,t,n,o=!0){m.useEffect(()=>{if(!o)return;const r=i=>{const s=i.target;e.current&&!e.current.contains(s)&&!t.current?.contains(s)&&n()};return document.addEventListener("mousedown",r),()=>{document.removeEventListener("mousedown",r)}},[e,t,n,o])}const Iv=g.div`
1858
1887
  position: relative;
1859
1888
  display: inline-flex;
1860
- `,Fv=g(ft)`
1889
+ `,Lv=g(ht)`
1861
1890
  min-height: auto;
1862
1891
  padding: 0.25rem;
1863
1892
  border: none;
@@ -1880,21 +1909,21 @@
1880
1909
  ${({$isActive:e})=>e&&`
1881
1910
  opacity: 1;
1882
1911
  `}
1883
- `,Sn=({column:e,uniqueValues:t,selectedValues:n,onChange:o})=>{const[r,i]=m.useState(!1),[s,a]=m.useState({top:0,left:0}),l=m.useRef(null),c=m.useRef(null),d=n.length>0,u=()=>{if(l.current){const y=l.current.getBoundingClientRect(),b=200,C=window.innerWidth-y.right<b;a({top:y.bottom+4,left:C?y.left:y.right-b})}},h=()=>{r||u(),i(y=>!y)},f=()=>{i(!1)},v=y=>{o(y)};return m.useEffect(()=>{const y=b=>{b.key==="Escape"&&r&&f()};return document.addEventListener("keydown",y),()=>document.removeEventListener("keydown",y)},[r]),Ev(l,c,f,r),p.jsxs(Dv,{ref:l,onClick:y=>y.stopPropagation(),children:[p.jsx(Fv,{size:"sm",onClick:h,"aria-label":`Filter ${e.id}`,"aria-expanded":r,$isActive:d,leftIcon:p.jsx(U,{component:d?Rp:_p,size:16,"aria-hidden":"true",color:"white"})}),r&&Vn.createPortal(p.jsx("div",{ref:c,children:p.jsx(Fr,{options:t,selectedValues:n,onChange:v,onClose:f,searchPlaceholder:`Search ${e.id}...`,position:s})}),document.body)]})};Sn.displayName="ColumnFilter";const Ql=e=>{const{columnFilters:t,setColumnFilters:n}=pt(),o=Jl(t,e),r=m.useCallback(i=>{const s=[...t],a=s.findIndex(l=>l.id===e);i.length>0?a>=0?s[a]={id:e,value:i}:s.push({id:e,value:i}):a>=0&&s.splice(a,1),n(s)},[t,e,n]);return{selectedValues:o,handleChange:r}},ec=g.div`
1912
+ `,Cn=({column:e,uniqueValues:t,selectedValues:n,onChange:o})=>{const[r,i]=m.useState(!1),[s,a]=m.useState({top:0,left:0}),l=m.useRef(null),c=m.useRef(null),d=n.length>0,u=()=>{if(l.current){const y=l.current.getBoundingClientRect(),b=200,S=window.innerWidth-y.right<b;a({top:y.bottom+4,left:S?y.left:y.right-b})}},f=()=>{r||u(),i(y=>!y)},h=()=>{i(!1)},v=y=>{o(y)};return m.useEffect(()=>{const y=b=>{b.key==="Escape"&&r&&h()};return document.addEventListener("keydown",y),()=>document.removeEventListener("keydown",y)},[r]),Av(l,c,h,r),p.jsxs(Iv,{ref:l,onClick:y=>y.stopPropagation(),children:[p.jsx(Lv,{size:"sm",onClick:f,"aria-label":`Filter ${e.id}`,"aria-expanded":r,$isActive:d,leftIcon:p.jsx(U,{component:d?Bp:Np,size:16,"aria-hidden":"true",color:"white"})}),r&&En.createPortal(p.jsx("div",{ref:c,children:p.jsx(Ir,{options:t,selectedValues:n,onChange:v,onClose:h,searchPlaceholder:`Search ${e.id}...`,position:s})}),document.body)]})};Cn.displayName="ColumnFilter";const ec=e=>{const{columnFilters:t,setColumnFilters:n}=gt(),o=Ql(t,e),r=m.useCallback(i=>{const s=[...t],a=s.findIndex(l=>l.id===e);i.length>0?a>=0?s[a]={id:e,value:i}:s.push({id:e,value:i}):a>=0&&s.splice(a,1),n(s)},[t,e,n]);return{selectedValues:o,handleChange:r}},tc=g.div`
1884
1913
  display: flex;
1885
1914
  align-items: center;
1886
1915
  gap: 0.25rem;
1887
1916
  width: 100%;
1888
- `,tc=({header:e})=>{const{size:t,getUniqueValues:n}=pt(),{selectedValues:o,handleChange:r}=Ql(e.column.id),i=e.column.columnDef.meta,s=e.column.getCanSort()&&i?.sortable!==!1,a=i?.filterable!==!1&&e.column.getCanFilter(),l=e.column.getIsSorted(),c=l||"none",d=e.column.id,u=a?n(d):[],h=e.column.getIsPinned(),f=h?e.column.getStart(h):0;return p.jsx(wv,{$size:i?.size||t,$active:!!l,colSpan:e.colSpan,$width:e.getSize(),$pinned:h||!1,$pinnedOffset:f,children:s?p.jsxs("section",{className:"flex",onClick:e.column.getToggleSortingHandler(),children:[p.jsx(Xl,{onClick:e.column.getToggleSortingHandler(),type:"button","aria-label":`Sort by ${xn(e.column.columnDef.header,e.getContext())}`,"aria-sort":c==="asc"?"ascending":c==="desc"?"descending":"none",children:p.jsx(Yl,{$align:i?.align,children:p.jsxs(ec,{children:[xn(e.column.columnDef.header,e.getContext()),p.jsx(bv,{$direction:c,children:c==="none"?p.jsx(U,{component:Fp,size:"tn"}):p.jsx(U,{component:Ep,size:"tn"})})]})})}),a&&p.jsx(Sn,{column:e.column,uniqueValues:u,selectedValues:o,onChange:r})]}):p.jsx(Yl,{$align:i?.align,children:p.jsxs(ec,{children:[xn(e.column.columnDef.header,e.getContext()),a&&p.jsx(Sn,{column:e.column,uniqueValues:u,selectedValues:o,onChange:r})]})})})},nc=({headerGroup:e})=>p.jsx(Wl,{children:e.headers.map(t=>p.jsx(tc,{header:t},t.id))}),oc=({headerGroups:e,stickyHeader:t,className:n})=>p.jsx(vv,{$sticky:t,className:n,children:e.map(o=>p.jsx(nc,{headerGroup:o},o.id))}),Av={sm:g.css`
1889
- ${Qe.sm}
1917
+ `,nc=({header:e})=>{const{size:t,getUniqueValues:n}=gt(),{selectedValues:o,handleChange:r}=ec(e.column.id),i=e.column.columnDef.meta,s=e.column.getCanSort()&&i?.sortable!==!1,a=i?.filterable!==!1&&e.column.getCanFilter(),l=e.column.getIsSorted(),c=l||"none",d=e.column.id,u=a?n(d):[],f=e.column.getIsPinned(),h=f?e.column.getStart(f):0;return p.jsx(Sv,{$size:i?.size||t,$active:!!l,colSpan:e.colSpan,$width:e.getSize(),$pinned:f||!1,$pinnedOffset:h,children:s?p.jsxs("section",{className:"flex",onClick:e.column.getToggleSortingHandler(),children:[p.jsx(Zl,{onClick:e.column.getToggleSortingHandler(),type:"button","aria-label":`Sort by ${Sn(e.column.columnDef.header,e.getContext())}`,"aria-sort":c==="asc"?"ascending":c==="desc"?"descending":"none",children:p.jsx(Xl,{$align:i?.align,children:p.jsxs(tc,{children:[Sn(e.column.columnDef.header,e.getContext()),p.jsx(Cv,{$direction:c,children:c==="none"?p.jsx(U,{component:Ip,size:"tn"}):p.jsx(U,{component:Dp,size:"tn"})})]})})}),a&&p.jsx(Cn,{column:e.column,uniqueValues:u,selectedValues:o,onChange:r})]}):p.jsx(Xl,{$align:i?.align,children:p.jsxs(tc,{children:[Sn(e.column.columnDef.header,e.getContext()),a&&p.jsx(Cn,{column:e.column,uniqueValues:u,selectedValues:o,onChange:r})]})})})},oc=({headerGroup:e})=>p.jsx(ql,{children:e.headers.map(t=>p.jsx(nc,{header:t},t.id))}),rc=({headerGroups:e,stickyHeader:t,className:n})=>p.jsx(bv,{$sticky:t,className:n,children:e.map(o=>p.jsx(oc,{headerGroup:o},o.id))}),Rv={sm:g.css`
1918
+ ${et.sm}
1890
1919
  ${D[14]}
1891
1920
  `,md:g.css`
1892
- ${Qe.md}
1921
+ ${et.md}
1893
1922
  ${D[14]}
1894
1923
  `,lg:g.css`
1895
- ${Qe.lg}
1924
+ ${et.lg}
1896
1925
  ${D[16]}
1897
- `},Iv=g.td`
1926
+ `},_v=g.td`
1898
1927
  ${({$width:e})=>e?g.css`
1899
1928
  min-width: ${typeof e=="number"?`${e}px`:e};
1900
1929
  width: ${typeof e=="number"?`${e}px`:e};
@@ -1906,13 +1935,13 @@
1906
1935
 
1907
1936
  vertical-align: middle;
1908
1937
  color: var(--color-main-blue-primary);
1909
- ${({$size:e})=>Av[e]}
1938
+ ${({$size:e})=>Rv[e]}
1910
1939
  text-align: ${({$align:e})=>e||"left"};
1911
1940
  border-left: 1px solid var(--color-main-light-borders);
1912
1941
  border-top: 1px solid var(--color-main-light-borders);
1913
1942
  transition: background-color 0.3s ease-out;
1914
1943
  ${({$pinned:e,$pinnedOffset:t})=>e&&g.css`
1915
- ${ql(e,t)}
1944
+ ${Yl(e,t)}
1916
1945
  background-color: var(--color-main-white);
1917
1946
  z-index: 10;
1918
1947
 
@@ -1920,12 +1949,12 @@
1920
1949
  background-color: var(--color-main-alternative-secondary);
1921
1950
  }
1922
1951
  `}
1923
- `,Lv=g.section`
1952
+ `,Bv=g.section`
1924
1953
  ${Kl};
1925
1954
  justify-content: ${({$align:e})=>e==="center"?"center":e==="right"?"flex-end":"flex-start"};
1926
1955
 
1927
1956
  width: 100%;
1928
- `,Rv=g.span`
1957
+ `,Nv=g.span`
1929
1958
  width: 100%;
1930
1959
  ${({$ellipsis:e})=>e&&g.css`
1931
1960
  min-width: 0;
@@ -1933,15 +1962,15 @@
1933
1962
  text-overflow: ellipsis;
1934
1963
  white-space: nowrap;
1935
1964
  `}
1936
- `,rc=({cell:e,rowClassName:t})=>{const{size:n}=pt(),o=e.column.columnDef.meta,r=e.getValue(),i=typeof r=="string"||typeof r=="number"?String(r):void 0,s=[o?.className||"",t||""].filter(Boolean).join(" "),a=e.column.getIsPinned(),l=a?e.column.getStart(a):0;return p.jsx(Iv,{$size:o?.size||n,$align:o?.align,$width:e.column.getSize(),$pinned:a||!1,$pinnedOffset:l,title:o?.ellipsis&&i?i:void 0,className:s,children:p.jsx(Lv,{$align:o?.align,children:p.jsx(Rv,{$ellipsis:o?.ellipsis,children:xn(e.column.columnDef.cell,e.getContext())})})})};function _v({row:e,className:t,cellClassName:n}){const{onRowClick:o}=pt(),r=!!o;return p.jsx(Wl,{$clickable:r,onClick:()=>r&&o(e.original),role:r?"button":void 0,tabIndex:r?0:void 0,className:t,children:e.getVisibleCells().map(i=>p.jsx(rc,{cell:i,rowClassName:n},i.id))})}const ic=m.memo(_v),Nv=g.keyframes`
1965
+ `,ic=({cell:e,rowClassName:t})=>{const{size:n}=gt(),o=e.column.columnDef.meta,r=e.getValue(),i=typeof r=="string"||typeof r=="number"?String(r):void 0,s=[o?.className||"",t||""].filter(Boolean).join(" "),a=e.column.getIsPinned(),l=a?e.column.getStart(a):0;return p.jsx(_v,{$size:o?.size||n,$align:o?.align,$width:e.column.getSize(),$pinned:a||!1,$pinnedOffset:l,title:o?.ellipsis&&i?i:void 0,className:s,children:p.jsx(Bv,{$align:o?.align,children:p.jsx(Nv,{$ellipsis:o?.ellipsis,children:Sn(e.column.columnDef.cell,e.getContext())})})})};function zv({row:e,className:t,cellClassName:n}){const{onRowClick:o}=gt(),r=!!o;return p.jsx(ql,{$clickable:r,onClick:()=>r&&o(e.original),role:r?"button":void 0,tabIndex:r?0:void 0,className:t,children:e.getVisibleCells().map(i=>p.jsx(ic,{cell:i,rowClassName:n},i.id))})}const sc=m.memo(zv),Ov=g.keyframes`
1937
1966
  0% {
1938
1967
  background-position: -1000px 0;
1939
1968
  }
1940
1969
  100% {
1941
1970
  background-position: 1000px 0;
1942
1971
  }
1943
- `,Bv=g.td`
1944
- ${({$size:e="md"})=>Qe[e]}
1972
+ `,Hv=g.td`
1973
+ ${({$size:e="md"})=>et[e]}
1945
1974
  background: linear-gradient(
1946
1975
  90deg,
1947
1976
  var(--color-light-200) 0%,
@@ -1949,7 +1978,7 @@
1949
1978
  var(--color-light-200) 100%
1950
1979
  );
1951
1980
  background-size: 1000px 100%;
1952
- animation: ${Nv} 2s ease-in-out infinite;
1981
+ animation: ${Ov} 2s ease-in-out infinite;
1953
1982
  border-bottom: 1px solid var(--color-light-200);
1954
1983
 
1955
1984
  &::before {
@@ -1960,11 +1989,11 @@
1960
1989
  border-radius: var(--border-radius-sm, 4px);
1961
1990
  background-color: var(--color-light-300);
1962
1991
  }
1963
- `,zv=g.tr`
1992
+ `,jv=g.tr`
1964
1993
  &:hover {
1965
1994
  background-color: transparent;
1966
1995
  }
1967
- `,Ov=e=>{const t=["60%","75%","85%","70%","80%"];return t[e%t.length]},Hv=({columnCount:e,cellWidths:t,size:n="md"})=>p.jsx(zv,{role:"row","aria-busy":"true",children:Array.from({length:e}).map((o,r)=>p.jsx(Bv,{$width:t?.[r]||Ov(r),$size:n},r))}),Cn=({rows:e,className:t,rowClassName:n,cellClassName:o,isLoading:r=!1,rowCount:i=5,columnCount:s=3})=>{const{size:a}=pt();return p.jsx("tbody",{className:t,"aria-busy":r,children:r?Array.from({length:i}).map((l,c)=>p.jsx(Hv,{columnCount:s,size:a},`skeleton-${c}`)):p.jsxs(p.Fragment,{children:[e.map(l=>{const c=typeof n=="function"?n(l):n,d=typeof o=="function"?o(l):o;return p.jsx(ic,{row:l,className:c,cellClassName:d},l.id)}),e.length===0&&p.jsx("tr",{children:p.jsx("td",{colSpan:100,className:"text-main-grey py-4 text-center",children:"No results found"})})]})})},jv=g.section`
1996
+ `,Gv=e=>{const t=["60%","75%","85%","70%","80%"];return t[e%t.length]},Uv=({columnCount:e,cellWidths:t,size:n="md"})=>p.jsx(jv,{role:"row","aria-busy":"true",children:Array.from({length:e}).map((o,r)=>p.jsx(Hv,{$width:t?.[r]||Gv(r),$size:n},r))}),Tn=({rows:e,className:t,rowClassName:n,cellClassName:o,isLoading:r=!1,rowCount:i=5,columnCount:s=3})=>{const{size:a}=gt();return p.jsx("tbody",{className:t,"aria-busy":r,children:r?Array.from({length:i}).map((l,c)=>p.jsx(Uv,{columnCount:s,size:a},`skeleton-${c}`)):p.jsxs(p.Fragment,{children:[e.map(l=>{const c=typeof n=="function"?n(l):n,d=typeof o=="function"?o(l):o;return p.jsx(sc,{row:l,className:c,cellClassName:d},l.id)}),e.length===0&&p.jsx("tr",{children:p.jsx("td",{colSpan:100,className:"text-main-grey py-4 text-center",children:"No results found"})})]})})},Wv=g.section`
1968
1997
  display: flex;
1969
1998
  align-items: center;
1970
1999
  gap: 0.5rem;
@@ -1975,7 +2004,7 @@
1975
2004
  justify-content: center;
1976
2005
  gap: 0.25rem;
1977
2006
  }
1978
- `,sc=g.button`
2007
+ `,ac=g.button`
1979
2008
  ${D[14]}
1980
2009
  display: flex;
1981
2010
  align-items: center;
@@ -2005,7 +2034,7 @@
2005
2034
  outline-color: var(--color-main-blue-primary);
2006
2035
  outline-offset: 2px;
2007
2036
  }
2008
- `,ac=g(sc)`
2037
+ `,lc=g(ac)`
2009
2038
  gap: 0.25rem;
2010
2039
  padding: 0 0.75rem;
2011
2040
  font-weight: 400;
@@ -2019,9 +2048,9 @@
2019
2048
  height: 1rem;
2020
2049
  }
2021
2050
  }
2022
- `,Gv=g(sc)`
2051
+ `,Kv=g(ac)`
2023
2052
  min-width: 2rem;
2024
- `,Uv=g.span`
2053
+ `,qv=g.span`
2025
2054
  ${D[14]}
2026
2055
  display: flex;
2027
2056
  align-items: center;
@@ -2030,7 +2059,7 @@
2030
2059
  height: 2rem;
2031
2060
  color: var(--color-main-blue-primary);
2032
2061
  user-select: none;
2033
- `,Kv=g.div`
2062
+ `,Yv=g.div`
2034
2063
  display: flex;
2035
2064
  align-items: center;
2036
2065
  gap: 0.5rem;
@@ -2049,7 +2078,7 @@
2049
2078
  justify-content: center;
2050
2079
  order: 10; /* Move to bottom on mobile */
2051
2080
  }
2052
- `,Wv=g(gn)`
2081
+ `,Xv=g(vn)`
2053
2082
  button {
2054
2083
  ${D[14]}
2055
2084
  height: 2rem;
@@ -2065,7 +2094,7 @@
2065
2094
  div {
2066
2095
  right: 10%;
2067
2096
  }
2068
- `,qv=({onPageChange:e,onPerPageChange:t,perPage:n=10,page:o=1,totalPages:r,totalRecords:i,rowsPerPageOptions:s})=>{const l=(()=>{const f=[];if(r<=7)for(let y=1;y<=r;y++)f.push(y);else{f.push(1),o>3&&f.push("...");const y=Math.max(2,o-1),b=Math.min(r-1,o+1);for(let w=y;w<=b;w++)f.push(w);o<r-2&&f.push("..."),f.push(r)}return f})(),c=[{value:10,label:"10"},{value:25,label:"25"},{value:50,label:"50"},{value:100,label:"100"}],d=i!==void 0&&i>0,u=d?(o-1)*n+1:0,h=d?Math.min(o*n,i):0;return p.jsxs(jv,{children:[d&&p.jsxs(ht,{size:14,children:["Showing ",u,"-",h," of ",i]}),p.jsxs(ac,{onClick:()=>e(o-1),$disabled:o===1,disabled:o===1,"aria-label":"Previous page",children:[p.jsx(jp,{size:24}),"Previous"]}),l.map((f,v)=>f==="..."?p.jsx(Uv,{children:"..."},`ellipsis-${v}`):p.jsx(Gv,{onClick:()=>e(f),$active:o===f,"aria-label":`Go to page ${f}`,"aria-current":o===f?"page":void 0,children:f},f)),p.jsxs(ac,{onClick:()=>e(o+1),$disabled:o===r,disabled:o===r,"aria-label":"Next page",children:["Next",p.jsx(Gp,{size:24})]}),p.jsxs(Kv,{children:[p.jsx(Wv,{size:"sm",value:n,options:s||c,onOptionSelect:f=>t(Number(f.value))}),p.jsx(ht,{size:12,children:"Rows per page"})]})]})},lc=({sorting:e,defaultSorting:t=[],onSortingChange:n})=>{const[o,r]=m.useState(t),i=e!==void 0,s=i?e:o,a=m.useCallback(c=>{const d=typeof c=="function"?c(s):c;i||r(d),n?.(d)},[i,s,n]),l=m.useCallback(c=>{i||r(c),n?.(c)},[i,n]);return{sortingState:s,handleSortingChange:a,isControlled:i,setSorting:l}},cc=({columnFilters:e,defaultColumnFilters:t=[],onColumnFiltersChange:n})=>{const[o,r]=m.useState(t),i=e!==void 0,s=i?e:o,a=m.useCallback(c=>{const d=typeof c=="function"?c(s):c;i||r(d),n?.(d)},[i,s,n]),l=m.useCallback(c=>{i||r(c),n?.(c)},[i,n]);return{columnFiltersState:s,handleColumnFiltersChange:a,isControlled:i,setColumnFilters:l}},uc=m.createContext(void 0),pt=()=>{const e=m.useContext(uc);if(!e)throw new Error("useTableContext debe usarse dentro de Table");return e},Ar=e=>{if(e.id)return e.id;if("accessorKey"in e&&e.accessorKey)return String(e.accessorKey)},dc=({data:e,columns:t,size:n="md",variant:o="default",stickyHeader:r=!1,maxHeight:i,sorting:s,defaultSorting:a,onSortingChange:l,columnFilters:c,defaultColumnFilters:d,onColumnFiltersChange:u,onRowClick:h,classNames:f,enableSorting:v=!0,manualSorting:y=!1,enableFiltering:b=!0,manualFiltering:w=!1,isLoading:C=!1,getUniqueValues:x})=>{const{sortingState:P,handleSortingChange:T,setSorting:k}=lc({sorting:s,defaultSorting:a,onSortingChange:l}),{columnFiltersState:V,handleColumnFiltersChange:$,setColumnFilters:A}=cc({columnFilters:c,defaultColumnFilters:d,onColumnFiltersChange:u}),I=m.useMemo(()=>{if(x)return null;const z=new Map;return t.forEach(N=>{const L=Ar(N);if(!L)return;const j="accessorFn"in N?N.accessorFn:void 0;z.set(L,Er(e,L,j))}),z},[e,t,x]),B=m.useMemo(()=>x||(z=>I?.get(z)||[]),[I,x]),H=m.useMemo(()=>t.map(z=>{const N=z.meta,L=N?.filterable!==!1,j={...z};return b&&L&&!z.filterFn&&(j.filterFn=Dr),N?.pinned&&(j.enablePinning=!0),j}),[t,b]),M=fv({data:e,columns:H,state:{sorting:P,columnFilters:V,columnPinning:{left:t.filter(z=>z.meta?.pinned==="left").map(z=>Ar(z)).filter(z=>z!==void 0),right:t.filter(z=>z.meta?.pinned==="right").map(z=>Ar(z)).filter(z=>z!==void 0)}},onSortingChange:T,onColumnFiltersChange:$,getCoreRowModel:ov(),getSortedRowModel:y?void 0:lv(),getFilteredRowModel:w?void 0:av(),enableSorting:v,enableSortingRemoval:!0,manualSorting:y,enableColumnFilters:b,manualFiltering:w,filterFns:{multiSelect:Dr},globalFilterFn:"includesString",enableColumnPinning:!0}),F={size:n,variant:o,sorting:P,setSorting:k,columnFilters:V,setColumnFilters:A,getUniqueValues:B,onRowClick:h};return p.jsx(uc.Provider,{value:F,children:p.jsx(pv,{$maxHeight:i,$stickyHeader:r,className:f?.wrapper,children:p.jsxs(gv,{$variant:o,className:f?.table,children:[p.jsx(oc,{headerGroups:M.getHeaderGroups(),stickyHeader:r,className:f?.header}),C?p.jsx(Cn,{rows:[],isLoading:!0,rowCount:5,columnCount:t.length,className:f?.body}):e.length===0?p.jsx(Cn,{rows:[],className:f?.body,rowClassName:f?.row}):p.jsx(Cn,{rows:M.getRowModel().rows,className:f?.body,rowClassName:f?.row,cellClassName:f?.cell})]})})})};dc.displayName="Table";function fc(e){const t={};for(const n of e)t[n.id]=n.desc?"desc":"asc";return t}function Yv(e){return Object.entries(e).map(([t,n])=>({id:t,desc:n==="desc"}))}function hc(e){return e.length===0?"":JSON.stringify(fc(e))}function Xv(e){const t=new URLSearchParams;return e.sorting&&e.sorting.length>0&&t.append("sorts",hc(e.sorting)),e.perPage&&t.append("perPage",e.perPage.toString()),e.genericSearch&&t.append("genericSearch",e.genericSearch),e.filters&&Object.keys(e.filters).length>0&&t.append("filters",JSON.stringify(e.filters)),t}const Zv=({data:e,columns:t,initialPage:n=1,initialPerPage:o=10,initialSorting:r=[],initialColumnFilters:i=[]})=>{const[s,a]=m.useState(n),[l,c]=m.useState(o),[d,u]=m.useState(r),[h,f]=m.useState(i),v=m.useMemo(()=>{const $=new Map;return t.forEach(A=>{const I=A.id??("accessorKey"in A&&A.accessorKey?String(A.accessorKey):void 0);if(!I)return;const B="accessorFn"in A?A.accessorFn:void 0;$.set(I,Er(e,I,B))}),$},[e,t]),y=m.useMemo(()=>$=>v.get($)||[],[v]),b=m.useMemo(()=>h.length===0?e:e.filter($=>h.every(A=>{const I=A.value;if(!I||I.length===0)return!0;const B=$[A.id];return B==null?!1:I.includes(String(B))})),[e,h]),w=m.useMemo(()=>d.length===0?b:[...b].sort(($,A)=>{for(const I of d){const B=$[I.id],H=A[I.id];if(B==null&&H==null)continue;if(B==null)return I.desc?-1:1;if(H==null)return I.desc?1:-1;let M=0;if(typeof B=="string"&&typeof H=="string"?M=B.localeCompare(H):typeof B=="number"&&typeof H=="number"?M=B-H:M=String(B).localeCompare(String(H)),M!==0)return I.desc?-M:M}return 0}),[b,d]),C=m.useMemo(()=>{const $=(s-1)*l,A=$+l;return w.slice($,A)},[w,s,l]),x=e.length,P=w.length,T=Math.max(1,Math.ceil(P/l)),k=m.useCallback($=>{a(Math.min($,T))},[T]),V=m.useCallback($=>{c($),a(1)},[]);return m.useMemo(()=>{s>T&&a(1)},[s,T]),{paginatedData:C,processedData:w,page:s,perPage:l,totalPages:T,totalRecords:x,filteredRecords:P,setPage:k,setPerPage:V,sorting:d,setSorting:u,columnFilters:h,setColumnFilters:f,getUniqueValues:y}};function mc(e){const t={};return e.forEach(n=>{t[n.id]=n.value}),t}function pc(e){return JSON.stringify(mc(e))}function Jv(e,t=","){const n={};return e.forEach(o=>{const r=o.value;r&&r.length>0&&(n[`filter[${o.id}]`]=r.join(t))}),n}function Qv(e){const t={};return e.forEach(n=>{const o=n.value;o&&o.length>0&&(t[`filter[${n.id}]`]=o)}),t}function ey({filters:e,sorts:t,page:n,perPage:o}){const r={};if(n!==void 0&&(r.page=n),o!==void 0&&(r.per_page=o),t&&t.length>0){const i=t.map(a=>a.id).join(","),s=t.map(a=>a.desc?"desc":"asc").join(",");r.sort_by=i,r.sort_order=s}return e&&e.length>0&&(r.filters=pc(e)),r}function ty(e,t=","){const n=typeof e=="string"?new URLSearchParams(e):e,o=[];return n.forEach((r,i)=>{const s=i.match(/^filter\[(.+)\]$/);if(s){const a=s[1],l=r.split(t).filter(Boolean);l.length>0&&o.push({id:a,value:l})}}),o}function ny(e){try{const t=JSON.parse(e);return Object.entries(t).map(([n,o])=>({id:n,value:o}))}catch{return[]}}function oy(...e){const t=new Map;return e.forEach(n=>{n.forEach(o=>{t.set(o.id,o.value)})}),Array.from(t.entries()).map(([n,o])=>({id:n,value:o}))}const ry=g.div`
2097
+ `,Zv=({onPageChange:e,onPerPageChange:t,perPage:n=10,page:o=1,totalPages:r,totalRecords:i,rowsPerPageOptions:s})=>{const l=(()=>{const h=[];if(r<=7)for(let y=1;y<=r;y++)h.push(y);else{h.push(1),o>3&&h.push("...");const y=Math.max(2,o-1),b=Math.min(r-1,o+1);for(let w=y;w<=b;w++)h.push(w);o<r-2&&h.push("..."),h.push(r)}return h})(),c=[{value:10,label:"10"},{value:25,label:"25"},{value:50,label:"50"},{value:100,label:"100"}],d=i!==void 0&&i>0,u=d?(o-1)*n+1:0,f=d?Math.min(o*n,i):0;return p.jsxs(Wv,{children:[d&&p.jsxs(mt,{size:14,children:["Showing ",u,"-",f," of ",i]}),p.jsxs(lc,{onClick:()=>e(o-1),$disabled:o===1,disabled:o===1,"aria-label":"Previous page",children:[p.jsx(Up,{size:24}),"Previous"]}),l.map((h,v)=>h==="..."?p.jsx(qv,{children:"..."},`ellipsis-${v}`):p.jsx(Kv,{onClick:()=>e(h),$active:o===h,"aria-label":`Go to page ${h}`,"aria-current":o===h?"page":void 0,children:h},h)),p.jsxs(lc,{onClick:()=>e(o+1),$disabled:o===r,disabled:o===r,"aria-label":"Next page",children:["Next",p.jsx(Wp,{size:24})]}),p.jsxs(Yv,{children:[p.jsx(Xv,{size:"sm",value:n,options:s||c,onOptionSelect:h=>t(Number(h.value))}),p.jsx(mt,{size:12,children:"Rows per page"})]})]})},cc=({sorting:e,defaultSorting:t=[],onSortingChange:n})=>{const[o,r]=m.useState(t),i=e!==void 0,s=i?e:o,a=m.useCallback(c=>{const d=typeof c=="function"?c(s):c;i||r(d),n?.(d)},[i,s,n]),l=m.useCallback(c=>{i||r(c),n?.(c)},[i,n]);return{sortingState:s,handleSortingChange:a,isControlled:i,setSorting:l}},uc=({columnFilters:e,defaultColumnFilters:t=[],onColumnFiltersChange:n})=>{const[o,r]=m.useState(t),i=e!==void 0,s=i?e:o,a=m.useCallback(c=>{const d=typeof c=="function"?c(s):c;i||r(d),n?.(d)},[i,s,n]),l=m.useCallback(c=>{i||r(c),n?.(c)},[i,n]);return{columnFiltersState:s,handleColumnFiltersChange:a,isControlled:i,setColumnFilters:l}},dc=m.createContext(void 0),gt=()=>{const e=m.useContext(dc);if(!e)throw new Error("useTableContext debe usarse dentro de Table");return e},Lr=e=>{if(e.id)return e.id;if("accessorKey"in e&&e.accessorKey)return String(e.accessorKey)},fc=({data:e,columns:t,size:n="md",variant:o="default",stickyHeader:r=!1,maxHeight:i,sorting:s,defaultSorting:a,onSortingChange:l,columnFilters:c,defaultColumnFilters:d,onColumnFiltersChange:u,onRowClick:f,classNames:h,enableSorting:v=!0,manualSorting:y=!1,enableFiltering:b=!0,manualFiltering:w=!1,isLoading:S=!1,getUniqueValues:x})=>{const{sortingState:P,handleSortingChange:T,setSorting:k}=cc({sorting:s,defaultSorting:a,onSortingChange:l}),{columnFiltersState:V,handleColumnFiltersChange:$,setColumnFilters:A}=uc({columnFilters:c,defaultColumnFilters:d,onColumnFiltersChange:u}),I=m.useMemo(()=>{if(x)return null;const z=new Map;return t.forEach(B=>{const L=Lr(B);if(!L)return;const j="accessorFn"in B?B.accessorFn:void 0;z.set(L,Fr(e,L,j))}),z},[e,t,x]),N=m.useMemo(()=>x||(z=>I?.get(z)||[]),[I,x]),H=m.useMemo(()=>t.map(z=>{const B=z.meta,L=B?.filterable!==!1,j={...z};return b&&L&&!z.filterFn&&(j.filterFn=Ar),B?.pinned&&(j.enablePinning=!0),j}),[t,b]),M=pv({data:e,columns:H,state:{sorting:P,columnFilters:V,columnPinning:{left:t.filter(z=>z.meta?.pinned==="left").map(z=>Lr(z)).filter(z=>z!==void 0),right:t.filter(z=>z.meta?.pinned==="right").map(z=>Lr(z)).filter(z=>z!==void 0)}},onSortingChange:T,onColumnFiltersChange:$,getCoreRowModel:sv(),getSortedRowModel:y?void 0:dv(),getFilteredRowModel:w?void 0:uv(),enableSorting:v,enableSortingRemoval:!0,manualSorting:y,enableColumnFilters:b,manualFiltering:w,filterFns:{multiSelect:Ar},globalFilterFn:"includesString",enableColumnPinning:!0}),F={size:n,variant:o,sorting:P,setSorting:k,columnFilters:V,setColumnFilters:A,getUniqueValues:N,onRowClick:f};return p.jsx(dc.Provider,{value:F,children:p.jsx(yv,{$maxHeight:i,$stickyHeader:r,className:h?.wrapper,children:p.jsxs(wv,{$variant:o,className:h?.table,children:[p.jsx(rc,{headerGroups:M.getHeaderGroups(),stickyHeader:r,className:h?.header}),S?p.jsx(Tn,{rows:[],isLoading:!0,rowCount:5,columnCount:t.length,className:h?.body}):e.length===0?p.jsx(Tn,{rows:[],className:h?.body,rowClassName:h?.row}):p.jsx(Tn,{rows:M.getRowModel().rows,className:h?.body,rowClassName:h?.row,cellClassName:h?.cell})]})})})};fc.displayName="Table";function hc(e){const t={};for(const n of e)t[n.id]=n.desc?"desc":"asc";return t}function Jv(e){return Object.entries(e).map(([t,n])=>({id:t,desc:n==="desc"}))}function mc(e){return e.length===0?"":JSON.stringify(hc(e))}function Qv(e){const t=new URLSearchParams;return e.sorting&&e.sorting.length>0&&t.append("sorts",mc(e.sorting)),e.perPage&&t.append("perPage",e.perPage.toString()),e.genericSearch&&t.append("genericSearch",e.genericSearch),e.filters&&Object.keys(e.filters).length>0&&t.append("filters",JSON.stringify(e.filters)),t}const ey=({data:e,columns:t,initialPage:n=1,initialPerPage:o=10,initialSorting:r=[],initialColumnFilters:i=[]})=>{const[s,a]=m.useState(n),[l,c]=m.useState(o),[d,u]=m.useState(r),[f,h]=m.useState(i),v=m.useMemo(()=>{const $=new Map;return t.forEach(A=>{const I=A.id??("accessorKey"in A&&A.accessorKey?String(A.accessorKey):void 0);if(!I)return;const N="accessorFn"in A?A.accessorFn:void 0;$.set(I,Fr(e,I,N))}),$},[e,t]),y=m.useMemo(()=>$=>v.get($)||[],[v]),b=m.useMemo(()=>f.length===0?e:e.filter($=>f.every(A=>{const I=A.value;if(!I||I.length===0)return!0;const N=$[A.id];return N==null?!1:I.includes(String(N))})),[e,f]),w=m.useMemo(()=>d.length===0?b:[...b].sort(($,A)=>{for(const I of d){const N=$[I.id],H=A[I.id];if(N==null&&H==null)continue;if(N==null)return I.desc?-1:1;if(H==null)return I.desc?1:-1;let M=0;if(typeof N=="string"&&typeof H=="string"?M=N.localeCompare(H):typeof N=="number"&&typeof H=="number"?M=N-H:M=String(N).localeCompare(String(H)),M!==0)return I.desc?-M:M}return 0}),[b,d]),S=m.useMemo(()=>{const $=(s-1)*l,A=$+l;return w.slice($,A)},[w,s,l]),x=e.length,P=w.length,T=Math.max(1,Math.ceil(P/l)),k=m.useCallback($=>{a(Math.min($,T))},[T]),V=m.useCallback($=>{c($),a(1)},[]);return m.useMemo(()=>{s>T&&a(1)},[s,T]),{paginatedData:S,processedData:w,page:s,perPage:l,totalPages:T,totalRecords:x,filteredRecords:P,setPage:k,setPerPage:V,sorting:d,setSorting:u,columnFilters:f,setColumnFilters:h,getUniqueValues:y}};function pc(e){const t={};return e.forEach(n=>{t[n.id]=n.value}),t}function gc(e){return JSON.stringify(pc(e))}function ty(e,t=","){const n={};return e.forEach(o=>{const r=o.value;r&&r.length>0&&(n[`filter[${o.id}]`]=r.join(t))}),n}function ny(e){const t={};return e.forEach(n=>{const o=n.value;o&&o.length>0&&(t[`filter[${n.id}]`]=o)}),t}function oy({filters:e,sorts:t,page:n,perPage:o}){const r={};if(n!==void 0&&(r.page=n),o!==void 0&&(r.per_page=o),t&&t.length>0){const i=t.map(a=>a.id).join(","),s=t.map(a=>a.desc?"desc":"asc").join(",");r.sort_by=i,r.sort_order=s}return e&&e.length>0&&(r.filters=gc(e)),r}function ry(e,t=","){const n=typeof e=="string"?new URLSearchParams(e):e,o=[];return n.forEach((r,i)=>{const s=i.match(/^filter\[(.+)\]$/);if(s){const a=s[1],l=r.split(t).filter(Boolean);l.length>0&&o.push({id:a,value:l})}}),o}function iy(e){try{const t=JSON.parse(e);return Object.entries(t).map(([n,o])=>({id:n,value:o}))}catch{return[]}}function sy(...e){const t=new Map;return e.forEach(n=>{n.forEach(o=>{t.set(o.id,o.value)})}),Array.from(t.entries()).map(([n,o])=>({id:n,value:o}))}const ay=g.div`
2069
2098
  position: relative;
2070
2099
  display: flex;
2071
2100
  align-items: center;
@@ -2076,14 +2105,14 @@
2076
2105
  transition: background-color 0.3s ease-out;
2077
2106
 
2078
2107
  &:hover {
2079
- background-color: var(--color-main-light-background);
2108
+ background-color: var(--color-main-light-borders);
2080
2109
  }
2081
2110
 
2082
2111
  &:focus-visible {
2083
2112
  outline: 2px solid var(--color-main-blue-primary);
2084
2113
  outline-offset: 2px;
2085
2114
  }
2086
- `,iy=g.div`
2115
+ `,ly=g.div`
2087
2116
  display: flex;
2088
2117
  flex-direction: column;
2089
2118
  align-items: flex-start;
@@ -2091,7 +2120,7 @@
2091
2120
  @media (max-width: 640px) {
2092
2121
  display: none;
2093
2122
  }
2094
- `,sy=g.div`
2123
+ `,cy=g.div`
2095
2124
  width: 2.25rem;
2096
2125
  height: 2.25rem;
2097
2126
  border-radius: 50%;
@@ -2103,7 +2132,7 @@
2103
2132
  justify-content: center;
2104
2133
  font-size: 1rem;
2105
2134
  user-select: none;
2106
- `,ay=g(De.div)`
2135
+ `;g(De.div)`
2107
2136
  display: flex;
2108
2137
  align-items: center;
2109
2138
  justify-content: center;
@@ -2112,7 +2141,7 @@
2112
2141
  @media (max-width: 640px) {
2113
2142
  display: none;
2114
2143
  }
2115
- `,ly=g(De.div)`
2144
+ `;const uy=g(De.div)`
2116
2145
  position: absolute;
2117
2146
  top: 100%;
2118
2147
  right: 0;
@@ -2122,9 +2151,9 @@
2122
2151
  border: 1px solid var(--color-main-light-borders);
2123
2152
  border-radius: var(--border-radius-article);
2124
2153
  box-shadow: var(--shadow-black-card);
2125
- z-index: 100;
2154
+ z-index: 1001;
2126
2155
  overflow: hidden;
2127
- `,cy=g.button`
2156
+ `,dy=g.button`
2128
2157
  width: 100%;
2129
2158
  display: flex;
2130
2159
  align-items: center;
@@ -2146,9 +2175,9 @@
2146
2175
  }
2147
2176
 
2148
2177
  &.danger {
2149
- color: var(--color-main-waringn-state);
2178
+ color: var(--color-main-warning-state);
2150
2179
  }
2151
- `,Ir=({user:e,onProfileClick:t,onLogout:n,menuItems:o=[]})=>{const[r,i]=m.useState(!1),s=m.useRef(null);m.useEffect(()=>{if(!r)return;const d=u=>{s.current&&!s.current.contains(u.target)&&i(!1)};return document.addEventListener("mousedown",d),()=>document.removeEventListener("mousedown",d)},[r]),m.useEffect(()=>{if(!r)return;const d=u=>{u.key==="Escape"&&i(!1)};return document.addEventListener("keydown",d),()=>document.removeEventListener("keydown",d)},[r]);const a=d=>d.split(" ").map(u=>u[0]).join("").toUpperCase().slice(0,2),c=[...[{id:"profile",label:"Profile",icon:Hp,onClick:()=>{i(!1),t?.()},variant:"default"},{id:"logout",label:"Logout",icon:Np,onClick:()=>{i(!1),n?.()},variant:"danger"}],...o];return p.jsxs("div",{ref:s,children:[p.jsxs(ry,{onClick:()=>i(!r),role:"button",tabIndex:0,onKeyDown:d=>{(d.key==="Enter"||d.key===" ")&&(d.preventDefault(),i(!r))},children:[p.jsx(sy,{className:"font-semibold!",children:a(e?.name||"")}),p.jsxs(iy,{children:[p.jsx(Ie,{size:14,className:"font-semibold!",children:e?.name||""}),p.jsx(Ie,{size:12,children:e?.roles?.[0]?.name||""})]}),p.jsx(ay,{animate:{rotate:r?-180:0},transition:{duration:.3},children:p.jsx(U,{component:Za,size:"sm",color:"var(--color-main-blue-primary)"})})]}),p.jsx(Lt,{children:r&&p.jsx(ly,{initial:{opacity:0,y:-10,scale:.95},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:-10,scale:.95},transition:{duration:.15},children:c.map(d=>p.jsx(m.Fragment,{children:p.jsxs(cy,{onClick:d.onClick,className:d.variant==="danger"?"danger":"",children:[p.jsx(U,{component:d.icon,size:"sm",color:d.variant==="danger"?"var(--color-main-warning-state)":"var(--color-main-blue-primary)"}),p.jsx(Ie,{size:14,color:`${d.variant==="danger"&&"var(--color-main-warning-state)"}`,children:d.label})]})},d.id))})})]})};Ir.displayName="UserProfile";const gc=({hasNotifications:e=!1,notificationCount:t})=>{const n=(t??0)>0||e,o=t&&t>0?t:void 0,r=o?`${o} notification${o===1?"":"s"}`:n?"New notifications":"No notifications",i=`Notifications: ${r}`;return{effectiveHasNotifications:n,displayCount:o,badgeLabel:r,bellAriaLabel:i}},uy=g.button`
2180
+ `,Rr=({user:e,onProfileClick:t,onLogout:n,menuItems:o=[]})=>{const[r,i]=m.useState(!1),s=m.useRef(null);m.useEffect(()=>{if(!r)return;const d=u=>{s.current&&!s.current.contains(u.target)&&i(!1)};return document.addEventListener("mousedown",d),()=>document.removeEventListener("mousedown",d)},[r]),m.useEffect(()=>{if(!r)return;const d=u=>{u.key==="Escape"&&i(!1)};return document.addEventListener("keydown",d),()=>document.removeEventListener("keydown",d)},[r]);const a=d=>d.split(" ").map(u=>u[0]).join("").toUpperCase().slice(0,2),c=[...[{id:"profile",label:"Profile",icon:Gp,onClick:()=>{i(!1),t?.()},variant:"default"},{id:"logout",label:"Logout",icon:zp,onClick:()=>{i(!1),n?.()},variant:"danger"}],...o];return p.jsxs("div",{ref:s,style:{position:"relative"},children:[p.jsxs(ay,{onClick:()=>i(!r),role:"button",tabIndex:0,onKeyDown:d=>{(d.key==="Enter"||d.key===" ")&&(d.preventDefault(),i(!r))},children:[p.jsxs(ly,{children:[p.jsx(Ie,{size:14,className:"font-semibold!",children:e?.name||""}),p.jsx(Ie,{size:12,children:e?.roles?.[0]?.name||""})]}),p.jsx(cy,{className:"font-semibold!",children:a(e?.name||"")})]}),p.jsx(Rt,{children:r&&p.jsx(uy,{initial:{opacity:0,y:-10,scale:.95},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:-10,scale:.95},transition:{duration:.15},children:c.map(d=>p.jsx(m.Fragment,{children:p.jsxs(dy,{onClick:d.onClick,className:d.variant==="danger"?"danger":"",children:[p.jsx(U,{component:d.icon,size:"sm",color:d.variant==="danger"?"var(--color-main-warning-state)":"var(--color-main-blue-primary)"}),p.jsx(Ie,{size:14,color:`${d.variant==="danger"&&"var(--color-main-warning-state)"}`,children:d.label})]})},d.id))})})]})};Rr.displayName="UserProfile";const vc=({hasNotifications:e=!1,notificationCount:t})=>{const n=(t??0)>0||e,o=t&&t>0?t:void 0,r=o?`${o} notification${o===1?"":"s"}`:n?"New notifications":"No notifications",i=`Notifications: ${r}`;return{effectiveHasNotifications:n,displayCount:o,badgeLabel:r,bellAriaLabel:i}},fy=g.button`
2152
2181
  position: relative;
2153
2182
  background: transparent;
2154
2183
  border: none;
@@ -2172,7 +2201,7 @@
2172
2201
  &:active {
2173
2202
  transform: scale(0.92);
2174
2203
  }
2175
- `,dy=g.span`
2204
+ `,hy=g.span`
2176
2205
  position: absolute;
2177
2206
  top: 0.35rem;
2178
2207
  right: 0.35rem;
@@ -2188,7 +2217,7 @@
2188
2217
  min-width: ${({$withCount:e})=>e?"1rem":"0.55rem"};
2189
2218
  height: ${({$withCount:e})=>e?"1rem":"0.55rem"};
2190
2219
  padding: ${({$withCount:e})=>e?"0 0.25rem":"0"};
2191
- `,Lr=({hasNotifications:e=!1,notificationCount:t,onNotificationClick:n})=>{const{effectiveHasNotifications:o,displayCount:r,bellAriaLabel:i}=gc({hasNotifications:e,notificationCount:t});return p.jsxs(uy,{onClick:n,"aria-label":i,title:i,"data-has":o||void 0,children:[p.jsx(U,{component:o?Bp:zp,size:"md",color:"var(--color-main-blue-primary)"}),o&&p.jsx(dy,{$withCount:!!r,"aria-hidden":!!r,children:r&&(r>99?"99+":r)})]})};Lr.displayName="NotificationButton";const fy=g.header`
2220
+ `,_r=({hasNotifications:e=!1,notificationCount:t,onNotificationClick:n})=>{const{effectiveHasNotifications:o,displayCount:r,bellAriaLabel:i}=vc({hasNotifications:e,notificationCount:t});return p.jsxs(fy,{onClick:n,"aria-label":i,title:i,"data-has":o||void 0,children:[p.jsx(U,{component:o?Op:Hp,size:"md",color:"var(--color-main-blue-primary)"}),o&&p.jsx(hy,{$withCount:!!r,"aria-hidden":!!r,children:r&&(r>99?"99+":r)})]})};_r.displayName="NotificationButton";const my=g.header`
2192
2221
  position: fixed;
2193
2222
  top: 0;
2194
2223
  left: 0;
@@ -2197,7 +2226,7 @@
2197
2226
  background: var(--color-main-white);
2198
2227
  border-bottom: 1px solid var(--color-main-light-borders);
2199
2228
  box-shadow: var(--shadow-black-button);
2200
- z-index: 40;
2229
+ z-index: 1000;
2201
2230
  display: flex;
2202
2231
  align-items: center;
2203
2232
  justify-content: space-between;
@@ -2208,18 +2237,18 @@
2208
2237
  align-items: center;
2209
2238
  gap: 1rem;
2210
2239
  flex: 1;
2211
- `;const hy=g.div`
2240
+ `;const py=g.div`
2212
2241
  display: flex;
2213
2242
  align-items: center;
2214
2243
  gap: 1rem;
2215
- `,my=g.div`
2244
+ `,gy=g.div`
2216
2245
  display: flex;
2217
2246
  align-items: center;
2218
2247
  justify-content: center;
2219
2248
  margin-right: 1rem;
2220
2249
  min-width: 3.125rem; /* Ensure space for logo */
2221
2250
  height: 2.5rem;
2222
- `,Rr=({logo:e,user:t,hasNotifications:n=!1,notificationCount:o,onNotificationClick:r,onUserProfileClick:i,onLogout:s,userMenuItems:a})=>p.jsxs(fy,{children:[p.jsx(my,{children:e}),p.jsxs(hy,{children:[n||o?p.jsx(Lr,{hasNotifications:n,notificationCount:o,onNotificationClick:r}):null,t&&p.jsx(Ir,{user:t,onProfileClick:i,onLogout:s,menuItems:a})]})]});Rr.displayName="Header";const py=g.main`
2251
+ `,Br=({logo:e,user:t,hasNotifications:n=!1,notificationCount:o,onNotificationClick:r,onUserProfileClick:i,onLogout:s,userMenuItems:a,className:l})=>p.jsxs(my,{className:l,children:[p.jsx(gy,{children:e}),p.jsxs(py,{children:[p.jsx(_r,{hasNotifications:n,notificationCount:o,onNotificationClick:r}),t&&p.jsx(Rr,{user:t,onProfileClick:i,onLogout:s,menuItems:a})]})]});Br.displayName="Header";const vy=g.main`
2223
2252
  flex: 1;
2224
2253
  margin-top: 4rem;
2225
2254
  /* Mobile-first: no lateral offset so content occupies full width */
@@ -2235,30 +2264,30 @@
2235
2264
  @media (min-width: 1200px) {
2236
2265
  margin-left: 5rem;
2237
2266
  }
2238
- `,_r=({children:e,className:t})=>p.jsx(py,{className:t,children:e});_r.displayName="LayoutMainContent";const gy=g.div`
2267
+ `,Nr=({children:e,className:t})=>p.jsx(vy,{className:t,children:e});Nr.displayName="LayoutMainContent";const yy=g.div`
2239
2268
  display: flex;
2240
2269
  flex-direction: column;
2241
2270
  height: 100vh;
2242
2271
  overflow: hidden;
2243
- `,vy=({children:e,navigationConfig:t,userPermissions:n=[],activePath:o,user:r,hasNotifications:i=!1,notificationCount:s,onNotificationClick:a,onUserProfileClick:l,onNavigate:c,onLogout:d,userMenuItems:u=[],contentClassName:h,logoImgCollapsed:f,logoImgExpanded:v})=>p.jsxs(gy,{children:[p.jsx(fr,{navigationConfig:t,userPermissions:n,activePath:o,logoImgCollapsed:f,logoImgExpanded:v,onNavigate:c}),p.jsx(Rr,{user:r,hasNotifications:i,notificationCount:s,onNotificationClick:a,onUserProfileClick:l,onLogout:d,userMenuItems:u}),p.jsx(_r,{className:h,children:e})]}),yy=e=>p.jsx(xl,{children:p.jsx(vy,{...e})});function wy(e,t,n){let o=`${e}=${encodeURIComponent(t)}; path=/; SameSite=Strict; Secure`;if(n){const r=new Date(Date.now()+n*864e5).toUTCString();o+=`; expires=${r}`}document.cookie=o}function by(e){return document.cookie.split("; ").reduce((t,n)=>{const o=n.split("=");return o[0]===e?decodeURIComponent(o[1]):t},"")}function xy(e){document.cookie=`${e}=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/`}const vc=m.createContext(void 0),Sy=e=>({permissions:e?.permissions?.map(t=>t.name)||[]}),Cy=({children:e,initialAbilities:t,user:n})=>{const[o,r]=m.useState(()=>n?Sy(n):t||{permissions:[]}),i=m.useCallback((c,d="any")=>(c=Array.isArray(c)?c:[c],d==="all"?c.every(u=>o.permissions.includes(u)):c.some(u=>o.permissions.includes(u))),[o.permissions]),s=m.useCallback(c=>{r(c)},[]),a=m.useCallback(()=>{r({permissions:[]})},[]),l={userAbilities:o,can:i,updateAbilities:s,setAbilities:r,clearAbilities:a};return p.jsx(vc.Provider,{value:l,children:e})},Nr=()=>{const e=m.useContext(vc);if(!e)throw new Error("useAbility must be used within an AbilityProvider");return e},Ty=(e,t="any")=>{const{can:n}=Nr();return n(e,t)},$y=m.memo(({requiredPermissions:e,mode:t="any",children:n,fallback:o=null})=>{const{can:r}=Nr();return r(e,t)?p.jsx(p.Fragment,{children:n}):o??null}),jt={sm:{circle:"2rem",fontSize:D[14],line:"2px"},md:{circle:"2.5rem",fontSize:D[18],line:"2px"},lg:{circle:"3.25rem",fontSize:D[20],line:"3px"}},Py=g.div`
2272
+ `,wy=({children:e,navigationConfig:t,userPermissions:n=[],activePath:o,user:r,hasNotifications:i=!1,notificationCount:s,onNotificationClick:a,onUserProfileClick:l,onNavigate:c,onLogout:d,userMenuItems:u=[],contentClassName:f,logoImgCollapsed:h,logoImgExpanded:v})=>p.jsxs(yy,{children:[p.jsx(hr,{navigationConfig:t,userPermissions:n,activePath:o,logoImgCollapsed:h,logoImgExpanded:v,onNavigate:c}),p.jsx(Br,{user:r,hasNotifications:i,notificationCount:s,onNotificationClick:a,onUserProfileClick:l,onLogout:d,userMenuItems:u}),p.jsx(Nr,{className:f,children:e})]}),by=e=>p.jsx(Cl,{children:p.jsx(wy,{...e})});function xy(e,t,n){let o=`${e}=${encodeURIComponent(t)}; path=/; SameSite=Strict; Secure`;if(n){const r=new Date(Date.now()+n*864e5).toUTCString();o+=`; expires=${r}`}document.cookie=o}function Sy(e){return document.cookie.split("; ").reduce((t,n)=>{const o=n.split("=");return o[0]===e?decodeURIComponent(o[1]):t},"")}function Cy(e){document.cookie=`${e}=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/`}const yc=m.createContext(void 0),Ty=e=>({permissions:e?.permissions?.map(t=>t.name)||[]}),$y=({children:e,initialAbilities:t,user:n})=>{const[o,r]=m.useState(()=>n?Ty(n):t||{permissions:[]}),i=m.useCallback((c,d="any")=>(c=Array.isArray(c)?c:[c],d==="all"?c.every(u=>o.permissions.includes(u)):c.some(u=>o.permissions.includes(u))),[o.permissions]),s=m.useCallback(c=>{r(c)},[]),a=m.useCallback(()=>{r({permissions:[]})},[]),l={userAbilities:o,can:i,updateAbilities:s,setAbilities:r,clearAbilities:a};return p.jsx(yc.Provider,{value:l,children:e})},zr=()=>{const e=m.useContext(yc);if(!e)throw new Error("useAbility must be used within an AbilityProvider");return e},Py=(e,t="any")=>{const{can:n}=zr();return n(e,t)},ky=m.memo(({requiredPermissions:e,mode:t="any",children:n,fallback:o=null})=>{const{can:r}=zr();return r(e,t)?p.jsx(p.Fragment,{children:n}):o??null}),Gt={sm:{circle:"2rem",fontSize:D[14],line:"2px"},md:{circle:"2.5rem",fontSize:D[18],line:"2px"},lg:{circle:"3.25rem",fontSize:D[20],line:"3px"}},My=g.div`
2244
2273
  display: flex;
2245
2274
  width: 100%;
2246
- `,ky=g.div`
2275
+ `,Vy=g.div`
2247
2276
  display: flex;
2248
2277
  flex-direction: ${({$orientation:e})=>e==="vertical"?"column":"row"};
2249
2278
  align-items: center;
2250
2279
  width: 100%;
2251
- `,My=g.div`
2280
+ `,Ey=g.div`
2252
2281
  display: flex;
2253
2282
  align-items: center;
2254
2283
  justify-content: center;
2255
2284
  position: relative;
2256
- `,yc=g.div`
2285
+ `,wc=g.div`
2257
2286
  display: flex;
2258
2287
  align-items: center;
2259
2288
  justify-content: center;
2260
- width: ${({$size:e})=>jt[e].circle};
2261
- height: ${({$size:e})=>jt[e].circle};
2289
+ width: ${({$size:e})=>Gt[e].circle};
2290
+ height: ${({$size:e})=>Gt[e].circle};
2262
2291
  outline-offset: 2px;
2263
2292
  outline: 2px solid transparent;
2264
2293
  border-radius: 50%;
@@ -2272,7 +2301,7 @@
2272
2301
  flex-shrink: 0;
2273
2302
  box-shadow: var(--shadow-black-button);
2274
2303
 
2275
- ${({$size:e})=>jt[e].fontSize}
2304
+ ${({$size:e})=>Gt[e].fontSize}
2276
2305
 
2277
2306
  ${({$isCompleted:e,$isActive:t})=>t?g.css`
2278
2307
  background-color: var(--color-main-blue-primary);
@@ -2299,19 +2328,19 @@
2299
2328
  box-shadow: var(--shadow-hover-black-button);
2300
2329
  }
2301
2330
  `}
2302
- `,Vy=g.div`
2331
+ `,Dy=g.div`
2303
2332
  background-color: ${({$isCompleted:e})=>e?"var(--color-main-blue-primary)":"var(--color-dark-300)"};
2304
2333
  transition: background-color 0.3s ease;
2305
2334
 
2306
2335
  ${({$orientation:e,$size:t})=>e==="vertical"?g.css`
2307
- width: ${jt[t].line};
2336
+ width: ${Gt[t].line};
2308
2337
  height: 2rem;
2309
2338
  `:g.css`
2310
- height: ${jt[t].line};
2339
+ height: ${Gt[t].line};
2311
2340
  flex: 1;
2312
2341
  min-width: 2rem;
2313
2342
  `}
2314
- `,Ey=g.span`
2343
+ `,Fy=g.span`
2315
2344
  position: absolute;
2316
2345
  ${D[14]}
2317
2346
  font-weight: 500;
@@ -2341,7 +2370,7 @@
2341
2370
  border-left-color: var(--color-main-blue-primary);
2342
2371
  }
2343
2372
 
2344
- ${yc}:hover & {
2373
+ ${wc}:hover & {
2345
2374
  opacity: 1;
2346
2375
  }
2347
- `,Dy=({steps:e,currentStep:t,orientation:n="horizontal",size:o="md",onStepClick:r,className:i})=>{const s=a=>{r?.(a)};return p.jsx(Py,{$orientation:n,className:i,children:p.jsx(ky,{$orientation:n,children:e.map((a,l)=>{const c=l===t,d=l<t,u=r!=null;return p.jsxs(p.Fragment,{children:[p.jsx(My,{$orientation:n,children:p.jsxs(yc,{$isActive:c,$isCompleted:d,$size:o,$isClickable:u,onClick:()=>u&&s(l),role:u?"button":void 0,tabIndex:u?0:void 0,"aria-current":c?"step":void 0,"aria-label":a.label,onKeyDown:h=>{u&&(h.key==="Enter"||h.key===" ")&&(h.preventDefault(),s(l))},children:[a.content??l+1,a.label&&n==="vertical"&&p.jsx(Ey,{children:a.label})]})}),l<e.length-1&&p.jsx(Vy,{$isCompleted:d,$orientation:n,$size:o})]},a.id)})})})};S.ALLOWED_INPUT_TYPES=qa,S.AbilityProvider=Cy,S.Aside=$l,S.Badge=Vm,S.BaseInput=Zo,S.BrandLogo=kl,S.Button=ft,S.Can=$y,S.Card=hp,S.CardBody=vp,S.CardFooter=wp,S.CardHeader=pp,S.Checkbox=zt,S.CheckboxInput=nr,S.CheckboxLabel=ll,S.CloseOpenButton=Vl,S.ColumnFilter=Sn,S.ColumnFilterMenu=Fr,S.Dialog=gl,S.DialogBody=yl,S.DialogFooter=wl,S.DialogHeader=vl,S.Divider=Dm,S.ErrorMessage=Xo,S.FileList=al,S.FileUpload=Pg,S.FilterOption=Vr,S.FormField=Zg,S.FullScreenSpinner=wm,S.Header=Rr,S.HeadingBold=jr,S.HeadingRegular=Ec,S.Icon=U,S.IconWrapperStyles=pn,S.InfoLabel=ht,S.Label=hn,S.Layout=yy,S.LayoutMainContent=_r,S.Link=Il,S.LinkDisabledStyles=Fl,S.LinkSizeStyles=Al,S.LinkVariantStyles=Dl,S.MobileOpenBtn=El,S.Nav=Ml,S.NotificationButton=Lr,S.Overlay=Tl,S.PasswordInput=tl,S.PinInput=or,S.PinInputGroup=rr,S.RadioInput=ar,S.RadioInputDot=ir,S.RadioInputLabel=sr,S.SearchInput=tr,S.SectionSpinner=xm,S.SelectInput=gn,S.Sidebar=fr,S.SidebarContext=cr,S.SidebarHeader=Pl,S.SidebarProvider=xl,S.Spinner=dn,S.Stepper=Dy,S.Table=dc,S.TableBody=Cn,S.TableCell=rc,S.TableHeader=oc,S.TableHeaderCell=tc,S.TableHeaderRow=nc,S.TablePagination=qv,S.TableRow=ic,S.TermsAndConditions=l0,S.Text=Ie,S.TextAreaInput=er,S.ToastProvider=ap,S.Tooltip=bl,S.UserProfile=Ir,S.baseFieldStyles=Ze,S.baseInputStyles=mn,S.bodyTextStyles=D,S.columnFiltersToArrayQueryParams=Qv,S.columnFiltersToJsonString=pc,S.columnFiltersToQueryParams=Jv,S.columnFiltersToRecord=mc,S.createBackendParams=Xv,S.createBackendParamsWithFilters=ey,S.createColumnHelper=k0,S.createFieldConfig=Pp,S.createInputRefs=fl,S.deleteCookie=xy,S.disabledStyles=Oe,S.errorStyles=Je,S.flushedStyles=Xa,S.getActiveFilterCount=Tv,S.getActiveFilterValues=Jl,S.getColumnValueCounts=Sv,S.getCookie=by,S.getPropsForInputType=kp,S.getUniqueColumnValues=Er,S.handleDigitChange=cl,S.handleKeyDown=ul,S.handlePaste=dl,S.hasActiveFilters=Cv,S.hasPermission=dr,S.headingBoldStyles=En,S.headingRegularStyles=Hr,S.isAllowedInputType=Ya,S.mergeFilters=oy,S.multiSelectFilter=Dr,S.normalizeFieldTypes=ze,S.normalizeSelectOptions=$p,S.overlayAnimation=lr,S.parseJsonToFilters=ny,S.parseQueryParamsToFilters=ty,S.searchInArray=Zl,S.setCookie=wy,S.sizeStyles=Bt,S.slideAnimation=Jg,S.smartAnimation=ml,S.sortRecordToSortingState=Yv,S.sortingStateToJsonString=hc,S.sortingStateToRecord=fc,S.submenuAnimationTopDown=pl,S.toast=Ym,S.useAbility=Nr,S.useCan=Ty,S.useColumnFilter=Ql,S.useNotifications=gc,S.useSidebar=ur,S.useTableContext=pt,S.useTableData=Zv,S.useTableFiltering=cc,S.useTableSorting=lc,S.validateCode=Ng,Object.defineProperty(S,Symbol.toStringTag,{value:"Module"})}));
2376
+ `,Ay=({steps:e,currentStep:t,orientation:n="horizontal",size:o="md",onStepClick:r,className:i})=>{const s=a=>{r?.(a)};return p.jsx(My,{$orientation:n,className:i,children:p.jsx(Vy,{$orientation:n,children:e.map((a,l)=>{const c=l===t,d=l<t,u=r!=null;return p.jsxs(p.Fragment,{children:[p.jsx(Ey,{$orientation:n,children:p.jsxs(wc,{$isActive:c,$isCompleted:d,$size:o,$isClickable:u,onClick:()=>u&&s(l),role:u?"button":void 0,tabIndex:u?0:void 0,"aria-current":c?"step":void 0,"aria-label":a.label,onKeyDown:f=>{u&&(f.key==="Enter"||f.key===" ")&&(f.preventDefault(),s(l))},children:[a.content??l+1,a.label&&n==="vertical"&&p.jsx(Fy,{children:a.label})]})}),l<e.length-1&&p.jsx(Dy,{$isCompleted:d,$orientation:n,$size:o})]},a.id)})})})};C.ALLOWED_INPUT_TYPES=Xa,C.AbilityProvider=$y,C.Aside=kl,C.Badge=Em,C.BaseInput=Jo,C.BrandLogo=Vl,C.Button=ht,C.Can=ky,C.Card=mp,C.CardBody=yp,C.CardFooter=bp,C.CardHeader=gp,C.Checkbox=Ot,C.CheckboxInput=or,C.CheckboxLabel=ul,C.CloseOpenButton=Dl,C.ColumnFilter=Cn,C.ColumnFilterMenu=Ir,C.Dialog=yl,C.DialogBody=bl,C.DialogFooter=xl,C.DialogHeader=wl,C.Divider=Fm,C.ErrorMessage=Zo,C.FileList=cl,C.FileUpload=Mg,C.FilterOption=Dr,C.FormField=Qg,C.FullScreenSpinner=bm,C.Header=Br,C.HeadingBold=Ur,C.HeadingRegular=Dc,C.Icon=U,C.IconWrapperStyles=gn,C.InfoLabel=mt,C.Label=mn,C.Layout=by,C.LayoutMainContent=Nr,C.Link=Ll,C.LinkDisabledStyles=Il,C.LinkSizeStyles=mr,C.LinkVariantStyles=Al,C.MobileOpenBtn=Fl,C.Nav=El,C.NotificationButton=_r,C.Overlay=Pl,C.PasswordInput=nl,C.PinInput=rr,C.PinInputGroup=ir,C.RadioInput=lr,C.RadioInputDot=sr,C.RadioInputLabel=ar,C.SearchInput=nr,C.SectionSpinner=Sm,C.SelectInput=vn,C.Sidebar=hr,C.SidebarContext=ur,C.SidebarHeader=Ml,C.SidebarProvider=Cl,C.Spinner=fn,C.Stepper=Ay,C.Table=fc,C.TableBody=Tn,C.TableCell=ic,C.TableHeader=rc,C.TableHeaderCell=nc,C.TableHeaderRow=oc,C.TablePagination=Zv,C.TableRow=sc,C.TermsAndConditions=u0,C.Text=Ie,C.TextAreaInput=tr,C.ToastProvider=lp,C.Tooltip=Sl,C.UserProfile=Rr,C.baseFieldStyles=Ze,C.baseInputStyles=pn,C.bodyTextStyles=D,C.columnFiltersToArrayQueryParams=ny,C.columnFiltersToJsonString=gc,C.columnFiltersToQueryParams=ty,C.columnFiltersToRecord=pc,C.createBackendParams=Qv,C.createBackendParamsWithFilters=oy,C.createColumnHelper=E0,C.createFieldConfig=kp,C.createInputRefs=ml,C.deleteCookie=Cy,C.disabledStyles=Oe,C.errorStyles=Je,C.flushedStyles=Ja,C.getActiveFilterCount=kv,C.getActiveFilterValues=Ql,C.getColumnValueCounts=$v,C.getCookie=Sy,C.getPropsForInputType=Mp,C.getUniqueColumnValues=Fr,C.handleDigitChange=dl,C.handleKeyDown=fl,C.handlePaste=hl,C.hasActiveFilters=Pv,C.hasPermission=fr,C.headingBoldStyles=Dn,C.headingRegularStyles=Gr,C.isAllowedInputType=Za,C.mergeFilters=sy,C.multiSelectFilter=Ar,C.normalizeFieldTypes=ze,C.normalizeSelectOptions=Pp,C.overlayAnimation=cr,C.parseJsonToFilters=iy,C.parseQueryParamsToFilters=ry,C.searchInArray=Jl,C.setCookie=xy,C.sizeStyles=zt,C.slideAnimation=e0,C.smartAnimation=gl,C.sortRecordToSortingState=Jv,C.sortingStateToJsonString=mc,C.sortingStateToRecord=hc,C.submenuAnimationTopDown=vl,C.toast=Xm,C.useAbility=zr,C.useCan=Py,C.useColumnFilter=ec,C.useNotifications=vc,C.useSidebar=dr,C.useTableContext=gt,C.useTableData=ey,C.useTableFiltering=uc,C.useTableSorting=cc,C.validateCode=zg,Object.defineProperty(C,Symbol.toStringTag,{value:"Module"})}));