@golocalinteractive/golocal-cloud-wrapper 1.0.48 → 1.0.49

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.
@@ -6,7 +6,7 @@
6
6
  *
7
7
  * This source code is licensed under the MIT license found in the
8
8
  * LICENSE file in the root directory of this source tree.
9
- */var Yr;function nc(){if(Yr)return mt;Yr=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,o,a){var s=null;if(a!==void 0&&(s=""+a),o.key!==void 0&&(s=""+o.key),"key"in o){a={};for(var i in o)i!=="key"&&(a[i]=o[i])}else a=o;return o=a.ref,{$$typeof:e,type:r,key:s,ref:o!==void 0?o:null,props:a}}return mt.Fragment=t,mt.jsx=n,mt.jsxs=n,mt}var ht={};/**
9
+ */var Yr;function oc(){if(Yr)return mt;Yr=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,o,s){var a=null;if(s!==void 0&&(a=""+s),o.key!==void 0&&(a=""+o.key),"key"in o){s={};for(var i in o)i!=="key"&&(s[i]=o[i])}else s=o;return o=s.ref,{$$typeof:e,type:r,key:a,ref:o!==void 0?o:null,props:s}}return mt.Fragment=t,mt.jsx=n,mt.jsxs=n,mt}var ht={};/**
10
10
  * @license React
11
11
  * react-jsx-runtime.development.js
12
12
  *
@@ -14,12 +14,12 @@
14
14
  *
15
15
  * This source code is licensed under the MIT license found in the
16
16
  * LICENSE file in the root directory of this source tree.
17
- */var qr;function rc(){return qr||(qr=1,process.env.NODE_ENV!=="production"&&function(){function e(y){if(y==null)return null;if(typeof y=="function")return y.$$typeof===L?null:y.displayName||y.name||null;if(typeof y=="string")return y;switch(y){case g:return"Fragment";case v:return"Profiler";case x:return"StrictMode";case _:return"Suspense";case T:return"SuspenseList";case j:return"Activity"}if(typeof y=="object")switch(typeof y.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),y.$$typeof){case b:return"Portal";case E:return(y.displayName||"Context")+".Provider";case w:return(y._context.displayName||"Context")+".Consumer";case S:var P=y.render;return y=y.displayName,y||(y=P.displayName||P.name||"",y=y!==""?"ForwardRef("+y+")":"ForwardRef"),y;case M:return P=y.displayName||null,P!==null?P:e(y.type)||"Memo";case C:P=y._payload,y=y._init;try{return e(y(P))}catch{}}return null}function t(y){return""+y}function n(y){try{t(y);var P=!1}catch{P=!0}if(P){P=console;var F=P.error,H=typeof Symbol=="function"&&Symbol.toStringTag&&y[Symbol.toStringTag]||y.constructor.name||"Object";return F.call(P,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",H),t(y)}}function r(y){if(y===g)return"<>";if(typeof y=="object"&&y!==null&&y.$$typeof===C)return"<...>";try{var P=e(y);return P?"<"+P+">":"<...>"}catch{return"<...>"}}function o(){var y=U.A;return y===null?null:y.getOwner()}function a(){return Error("react-stack-top-frame")}function s(y){if(B.call(y,"key")){var P=Object.getOwnPropertyDescriptor(y,"key").get;if(P&&P.isReactWarning)return!1}return y.key!==void 0}function i(y,P){function F(){X||(X=!0,console.error("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",P))}F.isReactWarning=!0,Object.defineProperty(y,"key",{get:F,configurable:!0})}function c(){var y=e(this.type);return V[y]||(V[y]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),y=this.props.ref,y!==void 0?y:null}function p(y,P,F,H,Z,ne,ue,Y){return F=ne.ref,y={$$typeof:h,type:y,key:P,props:ne,_owner:Z},(F!==void 0?F:null)!==null?Object.defineProperty(y,"ref",{enumerable:!1,get:c}):Object.defineProperty(y,"ref",{enumerable:!1,value:null}),y._store={},Object.defineProperty(y._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(y,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(y,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:ue}),Object.defineProperty(y,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:Y}),Object.freeze&&(Object.freeze(y.props),Object.freeze(y)),y}function d(y,P,F,H,Z,ne,ue,Y){var ee=P.children;if(ee!==void 0)if(H)if(z(ee)){for(H=0;H<ee.length;H++)f(ee[H]);Object.freeze&&Object.freeze(ee)}else console.error("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else f(ee);if(B.call(P,"key")){ee=e(y);var te=Object.keys(P).filter(function(Se){return Se!=="key"});H=0<te.length?"{key: someKey, "+te.join(": ..., ")+": ...}":"{key: someKey}",N[ee+H]||(te=0<te.length?"{"+te.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
17
+ */var qr;function sc(){return qr||(qr=1,process.env.NODE_ENV!=="production"&&function(){function e(y){if(y==null)return null;if(typeof y=="function")return y.$$typeof===L?null:y.displayName||y.name||null;if(typeof y=="string")return y;switch(y){case g:return"Fragment";case v:return"Profiler";case w:return"StrictMode";case _:return"Suspense";case T:return"SuspenseList";case j:return"Activity"}if(typeof y=="object")switch(typeof y.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),y.$$typeof){case b:return"Portal";case E:return(y.displayName||"Context")+".Provider";case x:return(y._context.displayName||"Context")+".Consumer";case S:var P=y.render;return y=y.displayName,y||(y=P.displayName||P.name||"",y=y!==""?"ForwardRef("+y+")":"ForwardRef"),y;case M:return P=y.displayName||null,P!==null?P:e(y.type)||"Memo";case C:P=y._payload,y=y._init;try{return e(y(P))}catch{}}return null}function t(y){return""+y}function n(y){try{t(y);var P=!1}catch{P=!0}if(P){P=console;var F=P.error,H=typeof Symbol=="function"&&Symbol.toStringTag&&y[Symbol.toStringTag]||y.constructor.name||"Object";return F.call(P,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",H),t(y)}}function r(y){if(y===g)return"<>";if(typeof y=="object"&&y!==null&&y.$$typeof===C)return"<...>";try{var P=e(y);return P?"<"+P+">":"<...>"}catch{return"<...>"}}function o(){var y=U.A;return y===null?null:y.getOwner()}function s(){return Error("react-stack-top-frame")}function a(y){if(B.call(y,"key")){var P=Object.getOwnPropertyDescriptor(y,"key").get;if(P&&P.isReactWarning)return!1}return y.key!==void 0}function i(y,P){function F(){X||(X=!0,console.error("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",P))}F.isReactWarning=!0,Object.defineProperty(y,"key",{get:F,configurable:!0})}function c(){var y=e(this.type);return V[y]||(V[y]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),y=this.props.ref,y!==void 0?y:null}function p(y,P,F,H,Z,ne,ue,Y){return F=ne.ref,y={$$typeof:h,type:y,key:P,props:ne,_owner:Z},(F!==void 0?F:null)!==null?Object.defineProperty(y,"ref",{enumerable:!1,get:c}):Object.defineProperty(y,"ref",{enumerable:!1,value:null}),y._store={},Object.defineProperty(y._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(y,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(y,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:ue}),Object.defineProperty(y,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:Y}),Object.freeze&&(Object.freeze(y.props),Object.freeze(y)),y}function d(y,P,F,H,Z,ne,ue,Y){var ee=P.children;if(ee!==void 0)if(H)if(z(ee)){for(H=0;H<ee.length;H++)f(ee[H]);Object.freeze&&Object.freeze(ee)}else console.error("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else f(ee);if(B.call(P,"key")){ee=e(y);var te=Object.keys(P).filter(function(Se){return Se!=="key"});H=0<te.length?"{key: someKey, "+te.join(": ..., ")+": ...}":"{key: someKey}",N[ee+H]||(te=0<te.length?"{"+te.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
18
18
  let props = %s;
19
19
  <%s {...props} />
20
20
  React keys must be passed directly to JSX without using spread:
21
21
  let props = %s;
22
- <%s key={someKey} {...props} />`,H,ee,te,ee),N[ee+H]=!0)}if(ee=null,F!==void 0&&(n(F),ee=""+F),s(P)&&(n(P.key),ee=""+P.key),"key"in P){F={};for(var se in P)se!=="key"&&(F[se]=P[se])}else F=P;return ee&&i(F,typeof y=="function"?y.displayName||y.name||"Unknown":y),p(y,ee,ne,Z,o(),F,ue,Y)}function f(y){typeof y=="object"&&y!==null&&y.$$typeof===h&&y._store&&(y._store.validated=1)}var m=I,h=Symbol.for("react.transitional.element"),b=Symbol.for("react.portal"),g=Symbol.for("react.fragment"),x=Symbol.for("react.strict_mode"),v=Symbol.for("react.profiler"),w=Symbol.for("react.consumer"),E=Symbol.for("react.context"),S=Symbol.for("react.forward_ref"),_=Symbol.for("react.suspense"),T=Symbol.for("react.suspense_list"),M=Symbol.for("react.memo"),C=Symbol.for("react.lazy"),j=Symbol.for("react.activity"),L=Symbol.for("react.client.reference"),U=m.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,B=Object.prototype.hasOwnProperty,z=Array.isArray,W=console.createTask?console.createTask:function(){return null};m={"react-stack-bottom-frame":function(y){return y()}};var X,V={},K=m["react-stack-bottom-frame"].bind(m,a)(),R=W(r(a)),N={};ht.Fragment=g,ht.jsx=function(y,P,F,H,Z){var ne=1e4>U.recentlyCreatedOwnerStacks++;return d(y,P,F,!1,H,Z,ne?Error("react-stack-top-frame"):K,ne?W(r(y)):R)},ht.jsxs=function(y,P,F,H,Z){var ne=1e4>U.recentlyCreatedOwnerStacks++;return d(y,P,F,!0,H,Z,ne?Error("react-stack-top-frame"):K,ne?W(r(y)):R)}}()),ht}var Xr;function oc(){return Xr||(Xr=1,process.env.NODE_ENV==="production"?Ot.exports=nc():Ot.exports=rc()),Ot.exports}var u=oc(),Pt={exports:{}},xn={};/**
22
+ <%s key={someKey} {...props} />`,H,ee,te,ee),N[ee+H]=!0)}if(ee=null,F!==void 0&&(n(F),ee=""+F),a(P)&&(n(P.key),ee=""+P.key),"key"in P){F={};for(var ae in P)ae!=="key"&&(F[ae]=P[ae])}else F=P;return ee&&i(F,typeof y=="function"?y.displayName||y.name||"Unknown":y),p(y,ee,ne,Z,o(),F,ue,Y)}function f(y){typeof y=="object"&&y!==null&&y.$$typeof===h&&y._store&&(y._store.validated=1)}var m=I,h=Symbol.for("react.transitional.element"),b=Symbol.for("react.portal"),g=Symbol.for("react.fragment"),w=Symbol.for("react.strict_mode"),v=Symbol.for("react.profiler"),x=Symbol.for("react.consumer"),E=Symbol.for("react.context"),S=Symbol.for("react.forward_ref"),_=Symbol.for("react.suspense"),T=Symbol.for("react.suspense_list"),M=Symbol.for("react.memo"),C=Symbol.for("react.lazy"),j=Symbol.for("react.activity"),L=Symbol.for("react.client.reference"),U=m.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,B=Object.prototype.hasOwnProperty,z=Array.isArray,W=console.createTask?console.createTask:function(){return null};m={"react-stack-bottom-frame":function(y){return y()}};var X,V={},K=m["react-stack-bottom-frame"].bind(m,s)(),R=W(r(s)),N={};ht.Fragment=g,ht.jsx=function(y,P,F,H,Z){var ne=1e4>U.recentlyCreatedOwnerStacks++;return d(y,P,F,!1,H,Z,ne?Error("react-stack-top-frame"):K,ne?W(r(y)):R)},ht.jsxs=function(y,P,F,H,Z){var ne=1e4>U.recentlyCreatedOwnerStacks++;return d(y,P,F,!0,H,Z,ne?Error("react-stack-top-frame"):K,ne?W(r(y)):R)}}()),ht}var Xr;function ac(){return Xr||(Xr=1,process.env.NODE_ENV==="production"?Ot.exports=oc():Ot.exports=sc()),Ot.exports}var u=ac(),Pt={exports:{}},wn={};/**
23
23
  * @license React
24
24
  * use-sync-external-store-shim.production.js
25
25
  *
@@ -27,7 +27,7 @@ React keys must be passed directly to JSX without using spread:
27
27
  *
28
28
  * This source code is licensed under the MIT license found in the
29
29
  * LICENSE file in the root directory of this source tree.
30
- */var Zr;function ac(){if(Zr)return xn;Zr=1;var e=I;function t(f,m){return f===m&&(f!==0||1/f===1/m)||f!==f&&m!==m}var n=typeof Object.is=="function"?Object.is:t,r=e.useState,o=e.useEffect,a=e.useLayoutEffect,s=e.useDebugValue;function i(f,m){var h=m(),b=r({inst:{value:h,getSnapshot:m}}),g=b[0].inst,x=b[1];return a(function(){g.value=h,g.getSnapshot=m,c(g)&&x({inst:g})},[f,h,m]),o(function(){return c(g)&&x({inst:g}),f(function(){c(g)&&x({inst:g})})},[f]),s(h),h}function c(f){var m=f.getSnapshot;f=f.value;try{var h=m();return!n(f,h)}catch{return!0}}function p(f,m){return m()}var d=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?p:i;return xn.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:d,xn}var wn={};/**
30
+ */var Zr;function ic(){if(Zr)return wn;Zr=1;var e=I;function t(f,m){return f===m&&(f!==0||1/f===1/m)||f!==f&&m!==m}var n=typeof Object.is=="function"?Object.is:t,r=e.useState,o=e.useEffect,s=e.useLayoutEffect,a=e.useDebugValue;function i(f,m){var h=m(),b=r({inst:{value:h,getSnapshot:m}}),g=b[0].inst,w=b[1];return s(function(){g.value=h,g.getSnapshot=m,c(g)&&w({inst:g})},[f,h,m]),o(function(){return c(g)&&w({inst:g}),f(function(){c(g)&&w({inst:g})})},[f]),a(h),h}function c(f){var m=f.getSnapshot;f=f.value;try{var h=m();return!n(f,h)}catch{return!0}}function p(f,m){return m()}var d=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?p:i;return wn.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:d,wn}var xn={};/**
31
31
  * @license React
32
32
  * use-sync-external-store-shim.development.js
33
33
  *
@@ -35,37 +35,37 @@ React keys must be passed directly to JSX without using spread:
35
35
  *
36
36
  * This source code is licensed under the MIT license found in the
37
37
  * LICENSE file in the root directory of this source tree.
38
- */var Jr;function sc(){return Jr||(Jr=1,process.env.NODE_ENV!=="production"&&function(){function e(h,b){return h===b&&(h!==0||1/h===1/b)||h!==h&&b!==b}function t(h,b){d||o.startTransition===void 0||(d=!0,console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));var g=b();if(!f){var x=b();a(g,x)||(console.error("The result of getSnapshot should be cached to avoid an infinite loop"),f=!0)}x=s({inst:{value:g,getSnapshot:b}});var v=x[0].inst,w=x[1];return c(function(){v.value=g,v.getSnapshot=b,n(v)&&w({inst:v})},[h,g,b]),i(function(){return n(v)&&w({inst:v}),h(function(){n(v)&&w({inst:v})})},[h]),p(g),g}function n(h){var b=h.getSnapshot;h=h.value;try{var g=b();return!a(h,g)}catch{return!0}}function r(h,b){return b()}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var o=I,a=typeof Object.is=="function"?Object.is:e,s=o.useState,i=o.useEffect,c=o.useLayoutEffect,p=o.useDebugValue,d=!1,f=!1,m=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?r:t;wn.useSyncExternalStore=o.useSyncExternalStore!==void 0?o.useSyncExternalStore:m,typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())}()),wn}var Qr;function ic(){return Qr||(Qr=1,process.env.NODE_ENV==="production"?Pt.exports=ac():Pt.exports=sc()),Pt.exports}var cc=ic();const eo=0,to=1,no=2,ro=3;var oo=Object.prototype.hasOwnProperty;function yn(e,t){var n,r;if(e===t)return!0;if(e&&t&&(n=e.constructor)===t.constructor){if(n===Date)return e.getTime()===t.getTime();if(n===RegExp)return e.toString()===t.toString();if(n===Array){if((r=e.length)===t.length)for(;r--&&yn(e[r],t[r]););return r===-1}if(!n||typeof e=="object"){r=0;for(n in e)if(oo.call(e,n)&&++r&&!oo.call(t,n)||!(n in t)||!yn(e[n],t[n]))return!1;return Object.keys(t).length===r}}return e!==e&&t!==t}const ke=new WeakMap,Ve=()=>{},de=Ve(),Dt=Object,q=e=>e===de,we=e=>typeof e=="function",Oe=(e,t)=>({...e,...t}),ao=e=>we(e.then),Cn={},It={},En="undefined",gt=typeof window!=En,Sn=typeof document!=En,lc=gt&&"Deno"in window,uc=()=>gt&&typeof window.requestAnimationFrame!=En,so=(e,t)=>{const n=ke.get(e);return[()=>!q(t)&&e.get(t)||Cn,r=>{if(!q(t)){const o=e.get(t);t in It||(It[t]=o),n[5](t,Oe(o,r),o||Cn)}},n[6],()=>!q(t)&&t in It?It[t]:!q(t)&&e.get(t)||Cn]};let _n=!0;const dc=()=>_n,[Rn,Mn]=gt&&window.addEventListener?[window.addEventListener.bind(window),window.removeEventListener.bind(window)]:[Ve,Ve],fc=()=>{const e=Sn&&document.visibilityState;return q(e)||e!=="hidden"},pc=e=>(Sn&&document.addEventListener("visibilitychange",e),Rn("focus",e),()=>{Sn&&document.removeEventListener("visibilitychange",e),Mn("focus",e)}),mc=e=>{const t=()=>{_n=!0,e()},n=()=>{_n=!1};return Rn("online",t),Rn("offline",n),()=>{Mn("online",t),Mn("offline",n)}},hc={isOnline:dc,isVisible:fc},gc={initFocus:pc,initReconnect:mc},io=!I.useId,vt=!gt||lc,vc=e=>uc()?window.requestAnimationFrame(e):setTimeout(e,1),jt=vt?I.useEffect:I.useLayoutEffect,An=typeof navigator<"u"&&navigator.connection,co=!vt&&An&&(["slow-2g","2g"].includes(An.effectiveType)||An.saveData),Lt=new WeakMap,Tn=(e,t)=>Dt.prototype.toString.call(e)===`[object ${t}]`;let bc=0;const Nn=e=>{const t=typeof e,n=Tn(e,"Date"),r=Tn(e,"RegExp"),o=Tn(e,"Object");let a,s;if(Dt(e)===e&&!n&&!r){if(a=Lt.get(e),a)return a;if(a=++bc+"~",Lt.set(e,a),Array.isArray(e)){for(a="@",s=0;s<e.length;s++)a+=Nn(e[s])+",";Lt.set(e,a)}if(o){a="#";const i=Dt.keys(e).sort();for(;!q(s=i.pop());)q(e[s])||(a+=s+":"+Nn(e[s])+",");Lt.set(e,a)}}else a=n?e.toJSON():t=="symbol"?e.toString():t=="string"?JSON.stringify(e):""+e;return a},kn=e=>{if(we(e))try{e=e()}catch{e=""}const t=e;return e=typeof e=="string"?e:(Array.isArray(e)?e.length:e)?Nn(e):"",[e,t]};let xc=0;const On=()=>++xc;async function lo(...e){const[t,n,r,o]=e,a=Oe({populateCache:!0,throwOnError:!0},typeof o=="boolean"?{revalidate:o}:o||{});let s=a.populateCache;const i=a.rollbackOnError;let c=a.optimisticData;const p=m=>typeof i=="function"?i(m):i!==!1,d=a.throwOnError;if(we(n)){const m=n,h=[],b=t.keys();for(const g of b)!/^\$(inf|sub)\$/.test(g)&&m(t.get(g)._k)&&h.push(g);return Promise.all(h.map(f))}return f(n);async function f(m){const[h]=kn(m);if(!h)return;const[b,g]=so(t,h),[x,v,w,E]=ke.get(t),S=()=>{const z=x[h];return(we(a.revalidate)?a.revalidate(b().data,m):a.revalidate!==!1)&&(delete w[h],delete E[h],z&&z[0])?z[0](no).then(()=>b().data):b().data};if(e.length<3)return S();let _=r,T;const M=On();v[h]=[M,0];const C=!q(c),j=b(),L=j.data,U=j._c,B=q(U)?L:U;if(C&&(c=we(c)?c(B,L):c,g({data:c,_c:B})),we(_))try{_=_(B)}catch(z){T=z}if(_&&ao(_))if(_=await _.catch(z=>{T=z}),M!==v[h][0]){if(T)throw T;return _}else T&&C&&p(T)&&(s=!0,g({data:B,_c:de}));if(s&&!T)if(we(s)){const z=s(_,B);g({data:z,error:de,_c:de})}else g({data:_,error:de,_c:de});if(v[h][1]=On(),Promise.resolve(S()).then(()=>{g({_c:de})}),T){if(d)throw T;return}return _}}const uo=(e,t)=>{for(const n in e)e[n][0]&&e[n][0](t)},fo=(e,t)=>{if(!ke.has(e)){const n=Oe(gc,t),r=Object.create(null),o=lo.bind(de,e);let a=Ve;const s=Object.create(null),i=(d,f)=>{const m=s[d]||[];return s[d]=m,m.push(f),()=>m.splice(m.indexOf(f),1)},c=(d,f,m)=>{e.set(d,f);const h=s[d];if(h)for(const b of h)b(f,m)},p=()=>{if(!ke.has(e)&&(ke.set(e,[r,Object.create(null),Object.create(null),Object.create(null),o,c,i]),!vt)){const d=n.initFocus(setTimeout.bind(de,uo.bind(de,r,eo))),f=n.initReconnect(setTimeout.bind(de,uo.bind(de,r,to)));a=()=>{d&&d(),f&&f(),ke.delete(e)}}};return p(),[e,o,p,a]}return[e,ke.get(e)[4]]},wc=(e,t,n,r,o)=>{const a=n.errorRetryCount,s=o.retryCount,i=~~((Math.random()+.5)*(1<<(s<8?s:8)))*n.errorRetryInterval;!q(a)&&s>a||setTimeout(r,i,o)},yc=yn,[Pn,Cc]=fo(new Map),po=Oe({onLoadingSlow:Ve,onSuccess:Ve,onError:Ve,onErrorRetry:wc,onDiscarded:Ve,revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0,shouldRetryOnError:!0,errorRetryInterval:co?1e4:5e3,focusThrottleInterval:5*1e3,dedupingInterval:2*1e3,loadingTimeout:co?5e3:3e3,compare:yc,isPaused:()=>!1,cache:Pn,mutate:Cc,fallback:{}},hc),mo=(e,t)=>{const n=Oe(e,t);if(t){const{use:r,fallback:o}=e,{use:a,fallback:s}=t;r&&a&&(n.use=r.concat(a)),o&&s&&(n.fallback=Oe(o,s))}return n},Dn=I.createContext({}),Ec=e=>{const{value:t}=e,n=I.useContext(Dn),r=we(t),o=I.useMemo(()=>r?t(n):t,[r,n,t]),a=I.useMemo(()=>r?o:mo(n,o),[r,n,o]),s=o&&o.provider,i=I.useRef(de);s&&!i.current&&(i.current=fo(s(a.cache||Pn),o));const c=i.current;return c&&(a.cache=c[0],a.mutate=c[1]),jt(()=>{if(c)return c[2]&&c[2](),c[3]},[]),I.createElement(Dn.Provider,Oe(e,{value:a}))},Sc="$inf$",ho=gt&&window.__SWR_DEVTOOLS_USE__,_c=ho?window.__SWR_DEVTOOLS_USE__:[],Rc=()=>{ho&&(window.__SWR_DEVTOOLS_REACT__=I)},Mc=e=>we(e[1])?[e[0],e[1],e[2]||{}]:[e[0],null,(e[1]===null?e[2]:e[1])||{}],Ac=()=>Oe(po,I.useContext(Dn)),Tc=e=>(t,n,r)=>e(t,n&&((...a)=>{const[s]=kn(t),[,,,i]=ke.get(Pn);if(s.startsWith(Sc))return n(...a);const c=i[s];return q(c)?n(...a):(delete i[s],c)}),r),Nc=_c.concat(Tc),kc=e=>function(...n){const r=Ac(),[o,a,s]=Mc(n),i=mo(r,s);let c=e;const{use:p}=i,d=(p||[]).concat(Nc);for(let f=d.length;f--;)c=d[f](c);return c(o,a||i.fetcher||null,i)},Oc=(e,t,n)=>{const r=t[e]||(t[e]=[]);return r.push(n),()=>{const o=r.indexOf(n);o>=0&&(r[o]=r[r.length-1],r.pop())}};Rc();const In=I.use||(e=>{switch(e.status){case"pending":throw e;case"fulfilled":return e.value;case"rejected":throw e.reason;default:throw e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}),e}}),jn={dedupe:!0},Pc=(e,t,n)=>{const{cache:r,compare:o,suspense:a,fallbackData:s,revalidateOnMount:i,revalidateIfStale:c,refreshInterval:p,refreshWhenHidden:d,refreshWhenOffline:f,keepPreviousData:m}=n,[h,b,g,x]=ke.get(r),[v,w]=kn(e),E=I.useRef(!1),S=I.useRef(!1),_=I.useRef(v),T=I.useRef(t),M=I.useRef(n),C=()=>M.current,j=()=>C().isVisible()&&C().isOnline(),[L,U,B,z]=so(r,v),W=I.useRef({}).current,X=q(s)?q(n.fallback)?de:n.fallback[v]:s,V=(J,Q)=>{for(const le in W){const oe=le;if(oe==="data"){if(!o(J[oe],Q[oe])&&(!q(J[oe])||!o(ne,Q[oe])))return!1}else if(Q[oe]!==J[oe])return!1}return!0},K=I.useMemo(()=>{const J=!v||!t?!1:q(i)?C().isPaused()||a?!1:c!==!1:i,Q=me=>{const Fe=Oe(me);return delete Fe._k,J?{isValidating:!0,isLoading:!0,...Fe}:Fe},le=L(),oe=z(),ve=Q(le),Ye=le===oe?ve:Q(oe);let ae=ve;return[()=>{const me=Q(L());return V(me,ae)?(ae.data=me.data,ae.isLoading=me.isLoading,ae.isValidating=me.isValidating,ae.error=me.error,ae):(ae=me,me)},()=>Ye]},[r,v]),R=cc.useSyncExternalStore(I.useCallback(J=>B(v,(Q,le)=>{V(le,Q)||J()}),[r,v]),K[0],K[1]),N=!E.current,y=h[v]&&h[v].length>0,P=R.data,F=q(P)?X&&ao(X)?In(X):X:P,H=R.error,Z=I.useRef(F),ne=m?q(P)?q(Z.current)?F:Z.current:P:F,ue=y&&!q(H)?!1:N&&!q(i)?i:C().isPaused()?!1:a?q(F)?!1:c:q(F)||c,Y=!!(v&&t&&N&&ue),ee=q(R.isValidating)?Y:R.isValidating,te=q(R.isLoading)?Y:R.isLoading,se=I.useCallback(async J=>{const Q=T.current;if(!v||!Q||S.current||C().isPaused())return!1;let le,oe,ve=!0;const Ye=J||{},ae=!g[v]||!Ye.dedupe,me=()=>io?!S.current&&v===_.current&&E.current:v===_.current,Fe={isValidating:!1,isLoading:!1},Qi=()=>{U(Fe)},ec=()=>{const xe=g[v];xe&&xe[1]===oe&&delete g[v]},tc={isValidating:!0};q(L().data)&&(tc.isLoading=!0);try{if(ae&&(U(tc),n.loadingTimeout&&q(L().data)&&setTimeout(()=>{ve&&me()&&C().onLoadingSlow(v,n)},n.loadingTimeout),g[v]=[Q(w),On()]),[le,oe]=g[v],le=await le,ae&&setTimeout(ec,n.dedupingInterval),!g[v]||g[v][1]!==oe)return ae&&me()&&C().onDiscarded(v),!1;Fe.error=de;const xe=b[v];if(!q(xe)&&(oe<=xe[0]||oe<=xe[1]||xe[1]===0))return Qi(),ae&&me()&&C().onDiscarded(v),!1;const $e=L().data;Fe.data=o($e,le)?$e:le,ae&&me()&&C().onSuccess(le,v,n)}catch(xe){ec();const $e=C(),{shouldRetryOnError:Wr}=$e;$e.isPaused()||(Fe.error=xe,ae&&me()&&($e.onError(xe,v,$e),(Wr===!0||we(Wr)&&Wr(xe))&&(!C().revalidateOnFocus||!C().revalidateOnReconnect||j())&&$e.onErrorRetry(xe,v,$e,m0=>{const Gr=h[v];Gr&&Gr[0]&&Gr[0](ro,m0)},{retryCount:(Ye.retryCount||0)+1,dedupe:!0})))}return ve=!1,Qi(),!0},[v,r]),Se=I.useCallback((...J)=>lo(r,_.current,...J),[]);if(jt(()=>{T.current=t,M.current=n,q(P)||(Z.current=P)}),jt(()=>{if(!v)return;const J=se.bind(de,jn);let Q=0;C().revalidateOnFocus&&(Q=Date.now()+C().focusThrottleInterval);const oe=Oc(v,h,(ve,Ye={})=>{if(ve==eo){const ae=Date.now();C().revalidateOnFocus&&ae>Q&&j()&&(Q=ae+C().focusThrottleInterval,J())}else if(ve==to)C().revalidateOnReconnect&&j()&&J();else{if(ve==no)return se();if(ve==ro)return se(Ye)}});return S.current=!1,_.current=v,E.current=!0,U({_k:w}),ue&&(q(F)||vt?J():vc(J)),()=>{S.current=!0,oe()}},[v]),jt(()=>{let J;function Q(){const oe=we(p)?p(L().data):p;oe&&J!==-1&&(J=setTimeout(le,oe))}function le(){!L().error&&(d||C().isVisible())&&(f||C().isOnline())?se(jn).then(Q):Q()}return Q(),()=>{J&&(clearTimeout(J),J=-1)}},[p,d,f,v]),I.useDebugValue(ne),a&&q(F)&&v){if(!io&&vt)throw new Error("Fallback data is required when using Suspense in SSR.");T.current=t,M.current=n,S.current=!1;const J=x[v];if(!q(J)){const Q=Se(J);In(Q)}if(q(H)){const Q=se(jn);q(ne)||(Q.status="fulfilled",Q.value=!0),In(Q)}else throw H}return{mutate:Se,get data(){return W.data=!0,ne},get error(){return W.error=!0,H},get isValidating(){return W.isValidating=!0,ee},get isLoading(){return W.isLoading=!0,te}}},Dc=Dt.defineProperty(Ec,"defaultValue",{value:po}),Ic=kc(Pc);function jc(e){return e&&!e.startsWith("/")?`/${e}`:e}function Lc(e){return e&&!e.endsWith("/")?`${e}/`:e}function Fc(e){return e.startsWith("/")?e.substring(1,e.length):e}const $c=e=>{const t=process.env.NEXT_PUBLIC_BASE_PATH;if(!t)return e;const n=jc(t);return Lc(n)+Fc(e)};function Vc(){const{data:e,error:t,isLoading:n,mutate:r}=Ic($c(process.env.NEXT_PUBLIC_PROFILE_ROUTE||"/auth/profile"),(...o)=>fetch(...o).then(a=>{if(!a.ok)throw new Error("Unauthorized");return a.status===204?null:a.json()}));return t?{user:null,isLoading:!1,error:t,invalidate:()=>r()}:e?{user:e,isLoading:!1,error:null,invalidate:()=>r()}:{user:e,isLoading:n,error:t,invalidate:()=>r()}}var go;(function(e){e.MISSING_SESSION="missing_session",e.MISSING_REFRESH_TOKEN="missing_refresh_token",e.FAILED_TO_REFRESH_TOKEN="failed_to_refresh_token"})(go||(go={}));var vo;(function(e){e.MISSING_SESSION="missing_session",e.MISSING_REFRESH_TOKEN="missing_refresh_token",e.FAILED_TO_EXCHANGE="failed_to_exchange_refresh_token"})(vo||(vo={}));function Hc({user:e,children:t}){return I.createElement(Dc,{value:{fallback:{[process.env.NEXT_PUBLIC_PROFILE_ROUTE||"/auth/profile"]:e}}},t)}/**
38
+ */var Jr;function cc(){return Jr||(Jr=1,process.env.NODE_ENV!=="production"&&function(){function e(h,b){return h===b&&(h!==0||1/h===1/b)||h!==h&&b!==b}function t(h,b){d||o.startTransition===void 0||(d=!0,console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));var g=b();if(!f){var w=b();s(g,w)||(console.error("The result of getSnapshot should be cached to avoid an infinite loop"),f=!0)}w=a({inst:{value:g,getSnapshot:b}});var v=w[0].inst,x=w[1];return c(function(){v.value=g,v.getSnapshot=b,n(v)&&x({inst:v})},[h,g,b]),i(function(){return n(v)&&x({inst:v}),h(function(){n(v)&&x({inst:v})})},[h]),p(g),g}function n(h){var b=h.getSnapshot;h=h.value;try{var g=b();return!s(h,g)}catch{return!0}}function r(h,b){return b()}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var o=I,s=typeof Object.is=="function"?Object.is:e,a=o.useState,i=o.useEffect,c=o.useLayoutEffect,p=o.useDebugValue,d=!1,f=!1,m=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?r:t;xn.useSyncExternalStore=o.useSyncExternalStore!==void 0?o.useSyncExternalStore:m,typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())}()),xn}var Qr;function lc(){return Qr||(Qr=1,process.env.NODE_ENV==="production"?Pt.exports=ic():Pt.exports=cc()),Pt.exports}var uc=lc();const eo=0,to=1,no=2,ro=3;var oo=Object.prototype.hasOwnProperty;function yn(e,t){var n,r;if(e===t)return!0;if(e&&t&&(n=e.constructor)===t.constructor){if(n===Date)return e.getTime()===t.getTime();if(n===RegExp)return e.toString()===t.toString();if(n===Array){if((r=e.length)===t.length)for(;r--&&yn(e[r],t[r]););return r===-1}if(!n||typeof e=="object"){r=0;for(n in e)if(oo.call(e,n)&&++r&&!oo.call(t,n)||!(n in t)||!yn(e[n],t[n]))return!1;return Object.keys(t).length===r}}return e!==e&&t!==t}const ke=new WeakMap,Ve=()=>{},de=Ve(),Dt=Object,q=e=>e===de,xe=e=>typeof e=="function",Oe=(e,t)=>({...e,...t}),so=e=>xe(e.then),Cn={},It={},En="undefined",gt=typeof window!=En,Sn=typeof document!=En,dc=gt&&"Deno"in window,fc=()=>gt&&typeof window.requestAnimationFrame!=En,ao=(e,t)=>{const n=ke.get(e);return[()=>!q(t)&&e.get(t)||Cn,r=>{if(!q(t)){const o=e.get(t);t in It||(It[t]=o),n[5](t,Oe(o,r),o||Cn)}},n[6],()=>!q(t)&&t in It?It[t]:!q(t)&&e.get(t)||Cn]};let _n=!0;const pc=()=>_n,[Rn,Mn]=gt&&window.addEventListener?[window.addEventListener.bind(window),window.removeEventListener.bind(window)]:[Ve,Ve],mc=()=>{const e=Sn&&document.visibilityState;return q(e)||e!=="hidden"},hc=e=>(Sn&&document.addEventListener("visibilitychange",e),Rn("focus",e),()=>{Sn&&document.removeEventListener("visibilitychange",e),Mn("focus",e)}),gc=e=>{const t=()=>{_n=!0,e()},n=()=>{_n=!1};return Rn("online",t),Rn("offline",n),()=>{Mn("online",t),Mn("offline",n)}},vc={isOnline:pc,isVisible:mc},bc={initFocus:hc,initReconnect:gc},io=!I.useId,vt=!gt||dc,wc=e=>fc()?window.requestAnimationFrame(e):setTimeout(e,1),jt=vt?I.useEffect:I.useLayoutEffect,An=typeof navigator<"u"&&navigator.connection,co=!vt&&An&&(["slow-2g","2g"].includes(An.effectiveType)||An.saveData),Lt=new WeakMap,Tn=(e,t)=>Dt.prototype.toString.call(e)===`[object ${t}]`;let xc=0;const Nn=e=>{const t=typeof e,n=Tn(e,"Date"),r=Tn(e,"RegExp"),o=Tn(e,"Object");let s,a;if(Dt(e)===e&&!n&&!r){if(s=Lt.get(e),s)return s;if(s=++xc+"~",Lt.set(e,s),Array.isArray(e)){for(s="@",a=0;a<e.length;a++)s+=Nn(e[a])+",";Lt.set(e,s)}if(o){s="#";const i=Dt.keys(e).sort();for(;!q(a=i.pop());)q(e[a])||(s+=a+":"+Nn(e[a])+",");Lt.set(e,s)}}else s=n?e.toJSON():t=="symbol"?e.toString():t=="string"?JSON.stringify(e):""+e;return s},kn=e=>{if(xe(e))try{e=e()}catch{e=""}const t=e;return e=typeof e=="string"?e:(Array.isArray(e)?e.length:e)?Nn(e):"",[e,t]};let yc=0;const On=()=>++yc;async function lo(...e){const[t,n,r,o]=e,s=Oe({populateCache:!0,throwOnError:!0},typeof o=="boolean"?{revalidate:o}:o||{});let a=s.populateCache;const i=s.rollbackOnError;let c=s.optimisticData;const p=m=>typeof i=="function"?i(m):i!==!1,d=s.throwOnError;if(xe(n)){const m=n,h=[],b=t.keys();for(const g of b)!/^\$(inf|sub)\$/.test(g)&&m(t.get(g)._k)&&h.push(g);return Promise.all(h.map(f))}return f(n);async function f(m){const[h]=kn(m);if(!h)return;const[b,g]=ao(t,h),[w,v,x,E]=ke.get(t),S=()=>{const z=w[h];return(xe(s.revalidate)?s.revalidate(b().data,m):s.revalidate!==!1)&&(delete x[h],delete E[h],z&&z[0])?z[0](no).then(()=>b().data):b().data};if(e.length<3)return S();let _=r,T;const M=On();v[h]=[M,0];const C=!q(c),j=b(),L=j.data,U=j._c,B=q(U)?L:U;if(C&&(c=xe(c)?c(B,L):c,g({data:c,_c:B})),xe(_))try{_=_(B)}catch(z){T=z}if(_&&so(_))if(_=await _.catch(z=>{T=z}),M!==v[h][0]){if(T)throw T;return _}else T&&C&&p(T)&&(a=!0,g({data:B,_c:de}));if(a&&!T)if(xe(a)){const z=a(_,B);g({data:z,error:de,_c:de})}else g({data:_,error:de,_c:de});if(v[h][1]=On(),Promise.resolve(S()).then(()=>{g({_c:de})}),T){if(d)throw T;return}return _}}const uo=(e,t)=>{for(const n in e)e[n][0]&&e[n][0](t)},fo=(e,t)=>{if(!ke.has(e)){const n=Oe(bc,t),r=Object.create(null),o=lo.bind(de,e);let s=Ve;const a=Object.create(null),i=(d,f)=>{const m=a[d]||[];return a[d]=m,m.push(f),()=>m.splice(m.indexOf(f),1)},c=(d,f,m)=>{e.set(d,f);const h=a[d];if(h)for(const b of h)b(f,m)},p=()=>{if(!ke.has(e)&&(ke.set(e,[r,Object.create(null),Object.create(null),Object.create(null),o,c,i]),!vt)){const d=n.initFocus(setTimeout.bind(de,uo.bind(de,r,eo))),f=n.initReconnect(setTimeout.bind(de,uo.bind(de,r,to)));s=()=>{d&&d(),f&&f(),ke.delete(e)}}};return p(),[e,o,p,s]}return[e,ke.get(e)[4]]},Cc=(e,t,n,r,o)=>{const s=n.errorRetryCount,a=o.retryCount,i=~~((Math.random()+.5)*(1<<(a<8?a:8)))*n.errorRetryInterval;!q(s)&&a>s||setTimeout(r,i,o)},Ec=yn,[Pn,Sc]=fo(new Map),po=Oe({onLoadingSlow:Ve,onSuccess:Ve,onError:Ve,onErrorRetry:Cc,onDiscarded:Ve,revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0,shouldRetryOnError:!0,errorRetryInterval:co?1e4:5e3,focusThrottleInterval:5*1e3,dedupingInterval:2*1e3,loadingTimeout:co?5e3:3e3,compare:Ec,isPaused:()=>!1,cache:Pn,mutate:Sc,fallback:{}},vc),mo=(e,t)=>{const n=Oe(e,t);if(t){const{use:r,fallback:o}=e,{use:s,fallback:a}=t;r&&s&&(n.use=r.concat(s)),o&&a&&(n.fallback=Oe(o,a))}return n},Dn=I.createContext({}),_c=e=>{const{value:t}=e,n=I.useContext(Dn),r=xe(t),o=I.useMemo(()=>r?t(n):t,[r,n,t]),s=I.useMemo(()=>r?o:mo(n,o),[r,n,o]),a=o&&o.provider,i=I.useRef(de);a&&!i.current&&(i.current=fo(a(s.cache||Pn),o));const c=i.current;return c&&(s.cache=c[0],s.mutate=c[1]),jt(()=>{if(c)return c[2]&&c[2](),c[3]},[]),I.createElement(Dn.Provider,Oe(e,{value:s}))},Rc="$inf$",ho=gt&&window.__SWR_DEVTOOLS_USE__,Mc=ho?window.__SWR_DEVTOOLS_USE__:[],Ac=()=>{ho&&(window.__SWR_DEVTOOLS_REACT__=I)},Tc=e=>xe(e[1])?[e[0],e[1],e[2]||{}]:[e[0],null,(e[1]===null?e[2]:e[1])||{}],Nc=()=>Oe(po,I.useContext(Dn)),kc=e=>(t,n,r)=>e(t,n&&((...s)=>{const[a]=kn(t),[,,,i]=ke.get(Pn);if(a.startsWith(Rc))return n(...s);const c=i[a];return q(c)?n(...s):(delete i[a],c)}),r),Oc=Mc.concat(kc),Pc=e=>function(...n){const r=Nc(),[o,s,a]=Tc(n),i=mo(r,a);let c=e;const{use:p}=i,d=(p||[]).concat(Oc);for(let f=d.length;f--;)c=d[f](c);return c(o,s||i.fetcher||null,i)},Dc=(e,t,n)=>{const r=t[e]||(t[e]=[]);return r.push(n),()=>{const o=r.indexOf(n);o>=0&&(r[o]=r[r.length-1],r.pop())}};Ac();const In=I.use||(e=>{switch(e.status){case"pending":throw e;case"fulfilled":return e.value;case"rejected":throw e.reason;default:throw e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}),e}}),jn={dedupe:!0},Ic=(e,t,n)=>{const{cache:r,compare:o,suspense:s,fallbackData:a,revalidateOnMount:i,revalidateIfStale:c,refreshInterval:p,refreshWhenHidden:d,refreshWhenOffline:f,keepPreviousData:m}=n,[h,b,g,w]=ke.get(r),[v,x]=kn(e),E=I.useRef(!1),S=I.useRef(!1),_=I.useRef(v),T=I.useRef(t),M=I.useRef(n),C=()=>M.current,j=()=>C().isVisible()&&C().isOnline(),[L,U,B,z]=ao(r,v),W=I.useRef({}).current,X=q(a)?q(n.fallback)?de:n.fallback[v]:a,V=(J,Q)=>{for(const le in W){const oe=le;if(oe==="data"){if(!o(J[oe],Q[oe])&&(!q(J[oe])||!o(ne,Q[oe])))return!1}else if(Q[oe]!==J[oe])return!1}return!0},K=I.useMemo(()=>{const J=!v||!t?!1:q(i)?C().isPaused()||s?!1:c!==!1:i,Q=me=>{const Fe=Oe(me);return delete Fe._k,J?{isValidating:!0,isLoading:!0,...Fe}:Fe},le=L(),oe=z(),ve=Q(le),Ye=le===oe?ve:Q(oe);let se=ve;return[()=>{const me=Q(L());return V(me,se)?(se.data=me.data,se.isLoading=me.isLoading,se.isValidating=me.isValidating,se.error=me.error,se):(se=me,me)},()=>Ye]},[r,v]),R=uc.useSyncExternalStore(I.useCallback(J=>B(v,(Q,le)=>{V(le,Q)||J()}),[r,v]),K[0],K[1]),N=!E.current,y=h[v]&&h[v].length>0,P=R.data,F=q(P)?X&&so(X)?In(X):X:P,H=R.error,Z=I.useRef(F),ne=m?q(P)?q(Z.current)?F:Z.current:P:F,ue=y&&!q(H)?!1:N&&!q(i)?i:C().isPaused()?!1:s?q(F)?!1:c:q(F)||c,Y=!!(v&&t&&N&&ue),ee=q(R.isValidating)?Y:R.isValidating,te=q(R.isLoading)?Y:R.isLoading,ae=I.useCallback(async J=>{const Q=T.current;if(!v||!Q||S.current||C().isPaused())return!1;let le,oe,ve=!0;const Ye=J||{},se=!g[v]||!Ye.dedupe,me=()=>io?!S.current&&v===_.current&&E.current:v===_.current,Fe={isValidating:!1,isLoading:!1},tc=()=>{U(Fe)},nc=()=>{const we=g[v];we&&we[1]===oe&&delete g[v]},rc={isValidating:!0};q(L().data)&&(rc.isLoading=!0);try{if(se&&(U(rc),n.loadingTimeout&&q(L().data)&&setTimeout(()=>{ve&&me()&&C().onLoadingSlow(v,n)},n.loadingTimeout),g[v]=[Q(x),On()]),[le,oe]=g[v],le=await le,se&&setTimeout(nc,n.dedupingInterval),!g[v]||g[v][1]!==oe)return se&&me()&&C().onDiscarded(v),!1;Fe.error=de;const we=b[v];if(!q(we)&&(oe<=we[0]||oe<=we[1]||we[1]===0))return tc(),se&&me()&&C().onDiscarded(v),!1;const $e=L().data;Fe.data=o($e,le)?$e:le,se&&me()&&C().onSuccess(le,v,n)}catch(we){nc();const $e=C(),{shouldRetryOnError:Wr}=$e;$e.isPaused()||(Fe.error=we,se&&me()&&($e.onError(we,v,$e),(Wr===!0||xe(Wr)&&Wr(we))&&(!C().revalidateOnFocus||!C().revalidateOnReconnect||j())&&$e.onErrorRetry(we,v,$e,h0=>{const Gr=h[v];Gr&&Gr[0]&&Gr[0](ro,h0)},{retryCount:(Ye.retryCount||0)+1,dedupe:!0})))}return ve=!1,tc(),!0},[v,r]),Se=I.useCallback((...J)=>lo(r,_.current,...J),[]);if(jt(()=>{T.current=t,M.current=n,q(P)||(Z.current=P)}),jt(()=>{if(!v)return;const J=ae.bind(de,jn);let Q=0;C().revalidateOnFocus&&(Q=Date.now()+C().focusThrottleInterval);const oe=Dc(v,h,(ve,Ye={})=>{if(ve==eo){const se=Date.now();C().revalidateOnFocus&&se>Q&&j()&&(Q=se+C().focusThrottleInterval,J())}else if(ve==to)C().revalidateOnReconnect&&j()&&J();else{if(ve==no)return ae();if(ve==ro)return ae(Ye)}});return S.current=!1,_.current=v,E.current=!0,U({_k:x}),ue&&(q(F)||vt?J():wc(J)),()=>{S.current=!0,oe()}},[v]),jt(()=>{let J;function Q(){const oe=xe(p)?p(L().data):p;oe&&J!==-1&&(J=setTimeout(le,oe))}function le(){!L().error&&(d||C().isVisible())&&(f||C().isOnline())?ae(jn).then(Q):Q()}return Q(),()=>{J&&(clearTimeout(J),J=-1)}},[p,d,f,v]),I.useDebugValue(ne),s&&q(F)&&v){if(!io&&vt)throw new Error("Fallback data is required when using Suspense in SSR.");T.current=t,M.current=n,S.current=!1;const J=w[v];if(!q(J)){const Q=Se(J);In(Q)}if(q(H)){const Q=ae(jn);q(ne)||(Q.status="fulfilled",Q.value=!0),In(Q)}else throw H}return{mutate:Se,get data(){return W.data=!0,ne},get error(){return W.error=!0,H},get isValidating(){return W.isValidating=!0,ee},get isLoading(){return W.isLoading=!0,te}}},jc=Dt.defineProperty(_c,"defaultValue",{value:po}),Lc=Pc(Ic);function Fc(e){return e&&!e.startsWith("/")?`/${e}`:e}function $c(e){return e&&!e.endsWith("/")?`${e}/`:e}function Vc(e){return e.startsWith("/")?e.substring(1,e.length):e}const Hc=e=>{const t=process.env.NEXT_PUBLIC_BASE_PATH;if(!t)return e;const n=Fc(t);return $c(n)+Vc(e)};function zc(){const{data:e,error:t,isLoading:n,mutate:r}=Lc(Hc(process.env.NEXT_PUBLIC_PROFILE_ROUTE||"/auth/profile"),(...o)=>fetch(...o).then(s=>{if(!s.ok)throw new Error("Unauthorized");return s.status===204?null:s.json()}));return t?{user:null,isLoading:!1,error:t,invalidate:()=>r()}:e?{user:e,isLoading:!1,error:null,invalidate:()=>r()}:{user:e,isLoading:n,error:t,invalidate:()=>r()}}var go;(function(e){e.MISSING_SESSION="missing_session",e.MISSING_REFRESH_TOKEN="missing_refresh_token",e.FAILED_TO_REFRESH_TOKEN="failed_to_refresh_token"})(go||(go={}));var vo;(function(e){e.MISSING_SESSION="missing_session",e.MISSING_REFRESH_TOKEN="missing_refresh_token",e.FAILED_TO_EXCHANGE="failed_to_exchange_refresh_token"})(vo||(vo={}));function Wc({user:e,children:t}){return I.createElement(jc,{value:{fallback:{[process.env.NEXT_PUBLIC_PROFILE_ROUTE||"/auth/profile"]:e}}},t)}/**
39
39
  * @license lucide-react v0.522.0 - ISC
40
40
  *
41
41
  * This source code is licensed under the ISC license.
42
42
  * See the LICENSE file in the root directory of this source tree.
43
- */const zc=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Wc=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,r)=>r?r.toUpperCase():n.toLowerCase()),bo=e=>{const t=Wc(e);return t.charAt(0).toUpperCase()+t.slice(1)},xo=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim(),Gc=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};/**
43
+ */const Gc=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Bc=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,r)=>r?r.toUpperCase():n.toLowerCase()),bo=e=>{const t=Bc(e);return t.charAt(0).toUpperCase()+t.slice(1)},wo=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim(),Uc=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};/**
44
44
  * @license lucide-react v0.522.0 - ISC
45
45
  *
46
46
  * This source code is licensed under the ISC license.
47
47
  * See the LICENSE file in the root directory of this source tree.
48
- */var Bc={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
48
+ */var Kc={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
49
49
  * @license lucide-react v0.522.0 - ISC
50
50
  *
51
51
  * This source code is licensed under the ISC license.
52
52
  * See the LICENSE file in the root directory of this source tree.
53
- */const Uc=I.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:a,iconNode:s,...i},c)=>I.createElement("svg",{ref:c,...Bc,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:xo("lucide",o),...!a&&!Gc(i)&&{"aria-hidden":"true"},...i},[...s.map(([p,d])=>I.createElement(p,d)),...Array.isArray(a)?a:[a]]));/**
53
+ */const Yc=I.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:s,iconNode:a,...i},c)=>I.createElement("svg",{ref:c,...Kc,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:wo("lucide",o),...!s&&!Uc(i)&&{"aria-hidden":"true"},...i},[...a.map(([p,d])=>I.createElement(p,d)),...Array.isArray(s)?s:[s]]));/**
54
54
  * @license lucide-react v0.522.0 - ISC
55
55
  *
56
56
  * This source code is licensed under the ISC license.
57
57
  * See the LICENSE file in the root directory of this source tree.
58
- */const fe=(e,t)=>{const n=I.forwardRef(({className:r,...o},a)=>I.createElement(Uc,{ref:a,iconNode:t,className:xo(`lucide-${zc(bo(e))}`,`lucide-${e}`,r),...o}));return n.displayName=bo(e),n};/**
58
+ */const fe=(e,t)=>{const n=I.forwardRef(({className:r,...o},s)=>I.createElement(Yc,{ref:s,iconNode:t,className:wo(`lucide-${Gc(bo(e))}`,`lucide-${e}`,r),...o}));return n.displayName=bo(e),n};/**
59
59
  * @license lucide-react v0.522.0 - ISC
60
60
  *
61
61
  * This source code is licensed under the ISC license.
62
62
  * See the LICENSE file in the root directory of this source tree.
63
- */const Kc=fe("book-open-text",[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M16 12h2",key:"7q9ll5"}],["path",{d:"M16 8h2",key:"msurwy"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}],["path",{d:"M6 12h2",key:"32wvfc"}],["path",{d:"M6 8h2",key:"30oboj"}]]);/**
63
+ */const qc=fe("book-open-text",[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M16 12h2",key:"7q9ll5"}],["path",{d:"M16 8h2",key:"msurwy"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}],["path",{d:"M6 12h2",key:"32wvfc"}],["path",{d:"M6 8h2",key:"30oboj"}]]);/**
64
64
  * @license lucide-react v0.522.0 - ISC
65
65
  *
66
66
  * This source code is licensed under the ISC license.
67
67
  * See the LICENSE file in the root directory of this source tree.
68
- */const Yc=fe("calendar-sync",[["path",{d:"M11 10v4h4",key:"172dkj"}],["path",{d:"m11 14 1.535-1.605a5 5 0 0 1 8 1.5",key:"vu0qm5"}],["path",{d:"M16 2v4",key:"4m81vk"}],["path",{d:"m21 18-1.535 1.605a5 5 0 0 1-8-1.5",key:"1qgeyt"}],["path",{d:"M21 22v-4h-4",key:"hrummi"}],["path",{d:"M21 8.5V6a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h4.3",key:"mctw84"}],["path",{d:"M3 10h4",key:"1el30a"}],["path",{d:"M8 2v4",key:"1cmpym"}]]);/**
68
+ */const Xc=fe("calendar-sync",[["path",{d:"M11 10v4h4",key:"172dkj"}],["path",{d:"m11 14 1.535-1.605a5 5 0 0 1 8 1.5",key:"vu0qm5"}],["path",{d:"M16 2v4",key:"4m81vk"}],["path",{d:"m21 18-1.535 1.605a5 5 0 0 1-8-1.5",key:"1qgeyt"}],["path",{d:"M21 22v-4h-4",key:"hrummi"}],["path",{d:"M21 8.5V6a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h4.3",key:"mctw84"}],["path",{d:"M3 10h4",key:"1el30a"}],["path",{d:"M8 2v4",key:"1cmpym"}]]);/**
69
69
  * @license lucide-react v0.522.0 - ISC
70
70
  *
71
71
  * This source code is licensed under the ISC license.
@@ -75,27 +75,27 @@ React keys must be passed directly to JSX without using spread:
75
75
  *
76
76
  * This source code is licensed under the ISC license.
77
77
  * See the LICENSE file in the root directory of this source tree.
78
- */const qc=fe("chart-column",[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]]);/**
78
+ */const Zc=fe("chart-column",[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]]);/**
79
79
  * @license lucide-react v0.522.0 - ISC
80
80
  *
81
81
  * This source code is licensed under the ISC license.
82
82
  * See the LICENSE file in the root directory of this source tree.
83
- */const wo=fe("chart-line",[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"m19 9-5 5-4-4-3 3",key:"2osh9i"}]]);/**
83
+ */const xo=fe("chart-line",[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"m19 9-5 5-4-4-3 3",key:"2osh9i"}]]);/**
84
84
  * @license lucide-react v0.522.0 - ISC
85
85
  *
86
86
  * This source code is licensed under the ISC license.
87
87
  * See the LICENSE file in the root directory of this source tree.
88
- */const Xc=fe("chart-pie",[["path",{d:"M21 12c.552 0 1.005-.449.95-.998a10 10 0 0 0-8.953-8.951c-.55-.055-.998.398-.998.95v8a1 1 0 0 0 1 1z",key:"pzmjnu"}],["path",{d:"M21.21 15.89A10 10 0 1 1 8 2.83",key:"k2fpak"}]]);/**
88
+ */const Jc=fe("chart-pie",[["path",{d:"M21 12c.552 0 1.005-.449.95-.998a10 10 0 0 0-8.953-8.951c-.55-.055-.998.398-.998.95v8a1 1 0 0 0 1 1z",key:"pzmjnu"}],["path",{d:"M21.21 15.89A10 10 0 1 1 8 2.83",key:"k2fpak"}]]);/**
89
89
  * @license lucide-react v0.522.0 - ISC
90
90
  *
91
91
  * This source code is licensed under the ISC license.
92
92
  * See the LICENSE file in the root directory of this source tree.
93
- */const Zc=fe("check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
93
+ */const Qc=fe("check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
94
94
  * @license lucide-react v0.522.0 - ISC
95
95
  *
96
96
  * This source code is licensed under the ISC license.
97
97
  * See the LICENSE file in the root directory of this source tree.
98
- */const Jc=fe("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
98
+ */const el=fe("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
99
99
  * @license lucide-react v0.522.0 - ISC
100
100
  *
101
101
  * This source code is licensed under the ISC license.
@@ -105,12 +105,12 @@ React keys must be passed directly to JSX without using spread:
105
105
  *
106
106
  * This source code is licensed under the ISC license.
107
107
  * See the LICENSE file in the root directory of this source tree.
108
- */const Qc=fe("circle-dollar-sign",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M16 8h-6a2 2 0 1 0 0 4h4a2 2 0 1 1 0 4H8",key:"1h4pet"}],["path",{d:"M12 18V6",key:"zqpxq5"}]]);/**
108
+ */const tl=fe("circle-dollar-sign",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M16 8h-6a2 2 0 1 0 0 4h4a2 2 0 1 1 0 4H8",key:"1h4pet"}],["path",{d:"M12 18V6",key:"zqpxq5"}]]);/**
109
109
  * @license lucide-react v0.522.0 - ISC
110
110
  *
111
111
  * This source code is licensed under the ISC license.
112
112
  * See the LICENSE file in the root directory of this source tree.
113
- */const el=fe("circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/**
113
+ */const nl=fe("circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/**
114
114
  * @license lucide-react v0.522.0 - ISC
115
115
  *
116
116
  * This source code is licensed under the ISC license.
@@ -120,12 +120,12 @@ React keys must be passed directly to JSX without using spread:
120
120
  *
121
121
  * This source code is licensed under the ISC license.
122
122
  * See the LICENSE file in the root directory of this source tree.
123
- */const tl=fe("log-out",[["path",{d:"m16 17 5-5-5-5",key:"1bji2h"}],["path",{d:"M21 12H9",key:"dn1m92"}],["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}]]);/**
123
+ */const rl=fe("log-out",[["path",{d:"m16 17 5-5-5-5",key:"1bji2h"}],["path",{d:"M21 12H9",key:"dn1m92"}],["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}]]);/**
124
124
  * @license lucide-react v0.522.0 - ISC
125
125
  *
126
126
  * This source code is licensed under the ISC license.
127
127
  * See the LICENSE file in the root directory of this source tree.
128
- */const nl=fe("panel-left",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]]);/**
128
+ */const ol=fe("panel-left",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]]);/**
129
129
  * @license lucide-react v0.522.0 - ISC
130
130
  *
131
131
  * This source code is licensed under the ISC license.
@@ -135,18 +135,18 @@ React keys must be passed directly to JSX without using spread:
135
135
  *
136
136
  * This source code is licensed under the ISC license.
137
137
  * See the LICENSE file in the root directory of this source tree.
138
- */const rl=fe("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);function So(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function $t(...e){return t=>{let n=!1;const r=e.map(o=>{const a=So(o,t);return!n&&typeof a=="function"&&(n=!0),a});if(n)return()=>{for(let o=0;o<r.length;o++){const a=r[o];typeof a=="function"?a():So(e[o],null)}}}}function ie(...e){return l.useCallback($t(...e),e)}function et(e){const t=ol(e),n=l.forwardRef((r,o)=>{const{children:a,...s}=r,i=l.Children.toArray(a),c=i.find(sl);if(c){const p=c.props.children,d=i.map(f=>f===c?l.Children.count(p)>1?l.Children.only(null):l.isValidElement(p)?p.props.children:null:f);return u.jsx(t,{...s,ref:o,children:l.isValidElement(p)?l.cloneElement(p,void 0,d):null})}return u.jsx(t,{...s,ref:o,children:a})});return n.displayName=`${e}.Slot`,n}var tt=et("Slot");function ol(e){const t=l.forwardRef((n,r)=>{const{children:o,...a}=n;if(l.isValidElement(o)){const s=cl(o),i=il(a,o.props);return o.type!==l.Fragment&&(i.ref=r?$t(r,s):s),l.cloneElement(o,i)}return l.Children.count(o)>1?l.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var _o=Symbol("radix.slottable");function al(e){const t=({children:n})=>u.jsx(u.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=_o,t}function sl(e){return l.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===_o}function il(e,t){const n={...t};for(const r in t){const o=e[r],a=t[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...i)=>{const c=a(...i);return o(...i),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...a}:r==="className"&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...e,...n}}function cl(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function Ro(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=Ro(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Mo(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=Ro(e))&&(r&&(r+=" "),r+=t);return r}const Ao=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,To=Mo,Ln=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return To(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:o,defaultVariants:a}=t,s=Object.keys(o).map(p=>{const d=n==null?void 0:n[p],f=a==null?void 0:a[p];if(d===null)return null;const m=Ao(d)||Ao(f);return o[p][m]}),i=n&&Object.entries(n).reduce((p,d)=>{let[f,m]=d;return m===void 0||(p[f]=m),p},{}),c=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((p,d)=>{let{class:f,className:m,...h}=d;return Object.entries(h).every(b=>{let[g,x]=b;return Array.isArray(x)?x.includes({...a,...i}[g]):{...a,...i}[g]===x})?[...p,f,m]:p},[]);return To(e,s,c,n==null?void 0:n.class,n==null?void 0:n.className)},Fn="-",ll=e=>{const t=dl(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{const i=s.split(Fn);return i[0]===""&&i.length!==1&&i.shift(),No(i,t)||ul(s)},getConflictingClassGroupIds:(s,i)=>{const c=n[s]||[];return i&&r[s]?[...c,...r[s]]:c}}},No=(e,t)=>{var s;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),o=r?No(e.slice(1),r):void 0;if(o)return o;if(t.validators.length===0)return;const a=e.join(Fn);return(s=t.validators.find(({validator:i})=>i(a)))==null?void 0:s.classGroupId},ko=/^\[(.+)\]$/,ul=e=>{if(ko.test(e)){const t=ko.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},dl=e=>{const{theme:t,classGroups:n}=e,r={nextPart:new Map,validators:[]};for(const o in n)$n(n[o],r,o,t);return r},$n=(e,t,n,r)=>{e.forEach(o=>{if(typeof o=="string"){const a=o===""?t:Oo(t,o);a.classGroupId=n;return}if(typeof o=="function"){if(fl(o)){$n(o(r),t,n,r);return}t.validators.push({validator:o,classGroupId:n});return}Object.entries(o).forEach(([a,s])=>{$n(s,Oo(t,a),n,r)})})},Oo=(e,t)=>{let n=e;return t.split(Fn).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},fl=e=>e.isThemeGetter,pl=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const o=(a,s)=>{n.set(a,s),t++,t>e&&(t=0,r=n,n=new Map)};return{get(a){let s=n.get(a);if(s!==void 0)return s;if((s=r.get(a))!==void 0)return o(a,s),s},set(a,s){n.has(a)?n.set(a,s):o(a,s)}}},Vn="!",Hn=":",ml=Hn.length,hl=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=o=>{const a=[];let s=0,i=0,c=0,p;for(let b=0;b<o.length;b++){let g=o[b];if(s===0&&i===0){if(g===Hn){a.push(o.slice(c,b)),c=b+ml;continue}if(g==="/"){p=b;continue}}g==="["?s++:g==="]"?s--:g==="("?i++:g===")"&&i--}const d=a.length===0?o:o.substring(c),f=gl(d),m=f!==d,h=p&&p>c?p-c:void 0;return{modifiers:a,hasImportantModifier:m,baseClassName:f,maybePostfixModifierPosition:h}};if(t){const o=t+Hn,a=r;r=s=>s.startsWith(o)?a(s.substring(o.length)):{isExternal:!0,modifiers:[],hasImportantModifier:!1,baseClassName:s,maybePostfixModifierPosition:void 0}}if(n){const o=r;r=a=>n({className:a,parseClassName:o})}return r},gl=e=>e.endsWith(Vn)?e.substring(0,e.length-1):e.startsWith(Vn)?e.substring(1):e,vl=e=>{const t=Object.fromEntries(e.orderSensitiveModifiers.map(r=>[r,!0]));return r=>{if(r.length<=1)return r;const o=[];let a=[];return r.forEach(s=>{s[0]==="["||t[s]?(o.push(...a.sort(),s),a=[]):a.push(s)}),o.push(...a.sort()),o}},bl=e=>({cache:pl(e.cacheSize),parseClassName:hl(e),sortModifiers:vl(e),...ll(e)}),xl=/\s+/,wl=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o,sortModifiers:a}=t,s=[],i=e.trim().split(xl);let c="";for(let p=i.length-1;p>=0;p-=1){const d=i[p],{isExternal:f,modifiers:m,hasImportantModifier:h,baseClassName:b,maybePostfixModifierPosition:g}=n(d);if(f){c=d+(c.length>0?" "+c:c);continue}let x=!!g,v=r(x?b.substring(0,g):b);if(!v){if(!x){c=d+(c.length>0?" "+c:c);continue}if(v=r(b),!v){c=d+(c.length>0?" "+c:c);continue}x=!1}const w=a(m).join(":"),E=h?w+Vn:w,S=E+v;if(s.includes(S))continue;s.push(S);const _=o(v,x);for(let T=0;T<_.length;++T){const M=_[T];s.push(E+M)}c=d+(c.length>0?" "+c:c)}return c};function yl(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=Po(t))&&(r&&(r+=" "),r+=n);return r}const Po=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=Po(e[r]))&&(n&&(n+=" "),n+=t);return n};function Cl(e,...t){let n,r,o,a=s;function s(c){const p=t.reduce((d,f)=>f(d),e());return n=bl(p),r=n.cache.get,o=n.cache.set,a=i,i(c)}function i(c){const p=r(c);if(p)return p;const d=wl(c,n);return o(c,d),d}return function(){return a(yl.apply(null,arguments))}}const ce=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},Do=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Io=/^\((?:(\w[\w-]*):)?(.+)\)$/i,El=/^\d+\/\d+$/,Sl=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,_l=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Rl=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Ml=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Al=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,nt=e=>El.test(e),G=e=>!!e&&!Number.isNaN(Number(e)),He=e=>!!e&&Number.isInteger(Number(e)),zn=e=>e.endsWith("%")&&G(e.slice(0,-1)),Pe=e=>Sl.test(e),Tl=()=>!0,Nl=e=>_l.test(e)&&!Rl.test(e),jo=()=>!1,kl=e=>Ml.test(e),Ol=e=>Al.test(e),Pl=e=>!k(e)&&!O(e),Dl=e=>rt(e,Ho,jo),k=e=>Do.test(e),qe=e=>rt(e,zo,Nl),Wn=e=>rt(e,$l,G),Lo=e=>rt(e,$o,jo),Il=e=>rt(e,Vo,Ol),Vt=e=>rt(e,Wo,kl),O=e=>Io.test(e),bt=e=>ot(e,zo),jl=e=>ot(e,Vl),Fo=e=>ot(e,$o),Ll=e=>ot(e,Ho),Fl=e=>ot(e,Vo),Ht=e=>ot(e,Wo,!0),rt=(e,t,n)=>{const r=Do.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},ot=(e,t,n=!1)=>{const r=Io.exec(e);return r?r[1]?t(r[1]):n:!1},$o=e=>e==="position"||e==="percentage",Vo=e=>e==="image"||e==="url",Ho=e=>e==="length"||e==="size"||e==="bg-size",zo=e=>e==="length",$l=e=>e==="number",Vl=e=>e==="family-name",Wo=e=>e==="shadow",Hl=Cl(()=>{const e=ce("color"),t=ce("font"),n=ce("text"),r=ce("font-weight"),o=ce("tracking"),a=ce("leading"),s=ce("breakpoint"),i=ce("container"),c=ce("spacing"),p=ce("radius"),d=ce("shadow"),f=ce("inset-shadow"),m=ce("text-shadow"),h=ce("drop-shadow"),b=ce("blur"),g=ce("perspective"),x=ce("aspect"),v=ce("ease"),w=ce("animate"),E=()=>["auto","avoid","all","avoid-page","page","left","right","column"],S=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],_=()=>[...S(),O,k],T=()=>["auto","hidden","clip","visible","scroll"],M=()=>["auto","contain","none"],C=()=>[O,k,c],j=()=>[nt,"full","auto",...C()],L=()=>[He,"none","subgrid",O,k],U=()=>["auto",{span:["full",He,O,k]},He,O,k],B=()=>[He,"auto",O,k],z=()=>["auto","min","max","fr",O,k],W=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],X=()=>["start","end","center","stretch","center-safe","end-safe"],V=()=>["auto",...C()],K=()=>[nt,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...C()],R=()=>[e,O,k],N=()=>[...S(),Fo,Lo,{position:[O,k]}],y=()=>["no-repeat",{repeat:["","x","y","space","round"]}],P=()=>["auto","cover","contain",Ll,Dl,{size:[O,k]}],F=()=>[zn,bt,qe],H=()=>["","none","full",p,O,k],Z=()=>["",G,bt,qe],ne=()=>["solid","dashed","dotted","double"],ue=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Y=()=>[G,zn,Fo,Lo],ee=()=>["","none",b,O,k],te=()=>["none",G,O,k],se=()=>["none",G,O,k],Se=()=>[G,O,k],Ke=()=>[nt,"full",...C()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[Pe],breakpoint:[Pe],color:[Tl],container:[Pe],"drop-shadow":[Pe],ease:["in","out","in-out"],font:[Pl],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[Pe],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[Pe],shadow:[Pe],spacing:["px",G],text:[Pe],"text-shadow":[Pe],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",nt,k,O,x]}],container:["container"],columns:[{columns:[G,k,O,i]}],"break-after":[{"break-after":E()}],"break-before":[{"break-before":E()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:_()}],overflow:[{overflow:T()}],"overflow-x":[{"overflow-x":T()}],"overflow-y":[{"overflow-y":T()}],overscroll:[{overscroll:M()}],"overscroll-x":[{"overscroll-x":M()}],"overscroll-y":[{"overscroll-y":M()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:j()}],"inset-x":[{"inset-x":j()}],"inset-y":[{"inset-y":j()}],start:[{start:j()}],end:[{end:j()}],top:[{top:j()}],right:[{right:j()}],bottom:[{bottom:j()}],left:[{left:j()}],visibility:["visible","invisible","collapse"],z:[{z:[He,"auto",O,k]}],basis:[{basis:[nt,"full","auto",i,...C()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[G,nt,"auto","initial","none",k]}],grow:[{grow:["",G,O,k]}],shrink:[{shrink:["",G,O,k]}],order:[{order:[He,"first","last","none",O,k]}],"grid-cols":[{"grid-cols":L()}],"col-start-end":[{col:U()}],"col-start":[{"col-start":B()}],"col-end":[{"col-end":B()}],"grid-rows":[{"grid-rows":L()}],"row-start-end":[{row:U()}],"row-start":[{"row-start":B()}],"row-end":[{"row-end":B()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":z()}],"auto-rows":[{"auto-rows":z()}],gap:[{gap:C()}],"gap-x":[{"gap-x":C()}],"gap-y":[{"gap-y":C()}],"justify-content":[{justify:[...W(),"normal"]}],"justify-items":[{"justify-items":[...X(),"normal"]}],"justify-self":[{"justify-self":["auto",...X()]}],"align-content":[{content:["normal",...W()]}],"align-items":[{items:[...X(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...X(),{baseline:["","last"]}]}],"place-content":[{"place-content":W()}],"place-items":[{"place-items":[...X(),"baseline"]}],"place-self":[{"place-self":["auto",...X()]}],p:[{p:C()}],px:[{px:C()}],py:[{py:C()}],ps:[{ps:C()}],pe:[{pe:C()}],pt:[{pt:C()}],pr:[{pr:C()}],pb:[{pb:C()}],pl:[{pl:C()}],m:[{m:V()}],mx:[{mx:V()}],my:[{my:V()}],ms:[{ms:V()}],me:[{me:V()}],mt:[{mt:V()}],mr:[{mr:V()}],mb:[{mb:V()}],ml:[{ml:V()}],"space-x":[{"space-x":C()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":C()}],"space-y-reverse":["space-y-reverse"],size:[{size:K()}],w:[{w:[i,"screen",...K()]}],"min-w":[{"min-w":[i,"screen","none",...K()]}],"max-w":[{"max-w":[i,"screen","none","prose",{screen:[s]},...K()]}],h:[{h:["screen","lh",...K()]}],"min-h":[{"min-h":["screen","lh","none",...K()]}],"max-h":[{"max-h":["screen","lh",...K()]}],"font-size":[{text:["base",n,bt,qe]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,O,Wn]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",zn,k]}],"font-family":[{font:[jl,k,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[o,O,k]}],"line-clamp":[{"line-clamp":[G,"none",O,Wn]}],leading:[{leading:[a,...C()]}],"list-image":[{"list-image":["none",O,k]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",O,k]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:R()}],"text-color":[{text:R()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ne(),"wavy"]}],"text-decoration-thickness":[{decoration:[G,"from-font","auto",O,qe]}],"text-decoration-color":[{decoration:R()}],"underline-offset":[{"underline-offset":[G,"auto",O,k]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:C()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",O,k]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",O,k]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:N()}],"bg-repeat":[{bg:y()}],"bg-size":[{bg:P()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},He,O,k],radial:["",O,k],conic:[He,O,k]},Fl,Il]}],"bg-color":[{bg:R()}],"gradient-from-pos":[{from:F()}],"gradient-via-pos":[{via:F()}],"gradient-to-pos":[{to:F()}],"gradient-from":[{from:R()}],"gradient-via":[{via:R()}],"gradient-to":[{to:R()}],rounded:[{rounded:H()}],"rounded-s":[{"rounded-s":H()}],"rounded-e":[{"rounded-e":H()}],"rounded-t":[{"rounded-t":H()}],"rounded-r":[{"rounded-r":H()}],"rounded-b":[{"rounded-b":H()}],"rounded-l":[{"rounded-l":H()}],"rounded-ss":[{"rounded-ss":H()}],"rounded-se":[{"rounded-se":H()}],"rounded-ee":[{"rounded-ee":H()}],"rounded-es":[{"rounded-es":H()}],"rounded-tl":[{"rounded-tl":H()}],"rounded-tr":[{"rounded-tr":H()}],"rounded-br":[{"rounded-br":H()}],"rounded-bl":[{"rounded-bl":H()}],"border-w":[{border:Z()}],"border-w-x":[{"border-x":Z()}],"border-w-y":[{"border-y":Z()}],"border-w-s":[{"border-s":Z()}],"border-w-e":[{"border-e":Z()}],"border-w-t":[{"border-t":Z()}],"border-w-r":[{"border-r":Z()}],"border-w-b":[{"border-b":Z()}],"border-w-l":[{"border-l":Z()}],"divide-x":[{"divide-x":Z()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":Z()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...ne(),"hidden","none"]}],"divide-style":[{divide:[...ne(),"hidden","none"]}],"border-color":[{border:R()}],"border-color-x":[{"border-x":R()}],"border-color-y":[{"border-y":R()}],"border-color-s":[{"border-s":R()}],"border-color-e":[{"border-e":R()}],"border-color-t":[{"border-t":R()}],"border-color-r":[{"border-r":R()}],"border-color-b":[{"border-b":R()}],"border-color-l":[{"border-l":R()}],"divide-color":[{divide:R()}],"outline-style":[{outline:[...ne(),"none","hidden"]}],"outline-offset":[{"outline-offset":[G,O,k]}],"outline-w":[{outline:["",G,bt,qe]}],"outline-color":[{outline:R()}],shadow:[{shadow:["","none",d,Ht,Vt]}],"shadow-color":[{shadow:R()}],"inset-shadow":[{"inset-shadow":["none",f,Ht,Vt]}],"inset-shadow-color":[{"inset-shadow":R()}],"ring-w":[{ring:Z()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:R()}],"ring-offset-w":[{"ring-offset":[G,qe]}],"ring-offset-color":[{"ring-offset":R()}],"inset-ring-w":[{"inset-ring":Z()}],"inset-ring-color":[{"inset-ring":R()}],"text-shadow":[{"text-shadow":["none",m,Ht,Vt]}],"text-shadow-color":[{"text-shadow":R()}],opacity:[{opacity:[G,O,k]}],"mix-blend":[{"mix-blend":[...ue(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":ue()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[G]}],"mask-image-linear-from-pos":[{"mask-linear-from":Y()}],"mask-image-linear-to-pos":[{"mask-linear-to":Y()}],"mask-image-linear-from-color":[{"mask-linear-from":R()}],"mask-image-linear-to-color":[{"mask-linear-to":R()}],"mask-image-t-from-pos":[{"mask-t-from":Y()}],"mask-image-t-to-pos":[{"mask-t-to":Y()}],"mask-image-t-from-color":[{"mask-t-from":R()}],"mask-image-t-to-color":[{"mask-t-to":R()}],"mask-image-r-from-pos":[{"mask-r-from":Y()}],"mask-image-r-to-pos":[{"mask-r-to":Y()}],"mask-image-r-from-color":[{"mask-r-from":R()}],"mask-image-r-to-color":[{"mask-r-to":R()}],"mask-image-b-from-pos":[{"mask-b-from":Y()}],"mask-image-b-to-pos":[{"mask-b-to":Y()}],"mask-image-b-from-color":[{"mask-b-from":R()}],"mask-image-b-to-color":[{"mask-b-to":R()}],"mask-image-l-from-pos":[{"mask-l-from":Y()}],"mask-image-l-to-pos":[{"mask-l-to":Y()}],"mask-image-l-from-color":[{"mask-l-from":R()}],"mask-image-l-to-color":[{"mask-l-to":R()}],"mask-image-x-from-pos":[{"mask-x-from":Y()}],"mask-image-x-to-pos":[{"mask-x-to":Y()}],"mask-image-x-from-color":[{"mask-x-from":R()}],"mask-image-x-to-color":[{"mask-x-to":R()}],"mask-image-y-from-pos":[{"mask-y-from":Y()}],"mask-image-y-to-pos":[{"mask-y-to":Y()}],"mask-image-y-from-color":[{"mask-y-from":R()}],"mask-image-y-to-color":[{"mask-y-to":R()}],"mask-image-radial":[{"mask-radial":[O,k]}],"mask-image-radial-from-pos":[{"mask-radial-from":Y()}],"mask-image-radial-to-pos":[{"mask-radial-to":Y()}],"mask-image-radial-from-color":[{"mask-radial-from":R()}],"mask-image-radial-to-color":[{"mask-radial-to":R()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":S()}],"mask-image-conic-pos":[{"mask-conic":[G]}],"mask-image-conic-from-pos":[{"mask-conic-from":Y()}],"mask-image-conic-to-pos":[{"mask-conic-to":Y()}],"mask-image-conic-from-color":[{"mask-conic-from":R()}],"mask-image-conic-to-color":[{"mask-conic-to":R()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:N()}],"mask-repeat":[{mask:y()}],"mask-size":[{mask:P()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",O,k]}],filter:[{filter:["","none",O,k]}],blur:[{blur:ee()}],brightness:[{brightness:[G,O,k]}],contrast:[{contrast:[G,O,k]}],"drop-shadow":[{"drop-shadow":["","none",h,Ht,Vt]}],"drop-shadow-color":[{"drop-shadow":R()}],grayscale:[{grayscale:["",G,O,k]}],"hue-rotate":[{"hue-rotate":[G,O,k]}],invert:[{invert:["",G,O,k]}],saturate:[{saturate:[G,O,k]}],sepia:[{sepia:["",G,O,k]}],"backdrop-filter":[{"backdrop-filter":["","none",O,k]}],"backdrop-blur":[{"backdrop-blur":ee()}],"backdrop-brightness":[{"backdrop-brightness":[G,O,k]}],"backdrop-contrast":[{"backdrop-contrast":[G,O,k]}],"backdrop-grayscale":[{"backdrop-grayscale":["",G,O,k]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[G,O,k]}],"backdrop-invert":[{"backdrop-invert":["",G,O,k]}],"backdrop-opacity":[{"backdrop-opacity":[G,O,k]}],"backdrop-saturate":[{"backdrop-saturate":[G,O,k]}],"backdrop-sepia":[{"backdrop-sepia":["",G,O,k]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":C()}],"border-spacing-x":[{"border-spacing-x":C()}],"border-spacing-y":[{"border-spacing-y":C()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",O,k]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[G,"initial",O,k]}],ease:[{ease:["linear","initial",v,O,k]}],delay:[{delay:[G,O,k]}],animate:[{animate:["none",w,O,k]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[g,O,k]}],"perspective-origin":[{"perspective-origin":_()}],rotate:[{rotate:te()}],"rotate-x":[{"rotate-x":te()}],"rotate-y":[{"rotate-y":te()}],"rotate-z":[{"rotate-z":te()}],scale:[{scale:se()}],"scale-x":[{"scale-x":se()}],"scale-y":[{"scale-y":se()}],"scale-z":[{"scale-z":se()}],"scale-3d":["scale-3d"],skew:[{skew:Se()}],"skew-x":[{"skew-x":Se()}],"skew-y":[{"skew-y":Se()}],transform:[{transform:[O,k,"","none","gpu","cpu"]}],"transform-origin":[{origin:_()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Ke()}],"translate-x":[{"translate-x":Ke()}],"translate-y":[{"translate-y":Ke()}],"translate-z":[{"translate-z":Ke()}],"translate-none":["translate-none"],accent:[{accent:R()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:R()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",O,k]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":C()}],"scroll-mx":[{"scroll-mx":C()}],"scroll-my":[{"scroll-my":C()}],"scroll-ms":[{"scroll-ms":C()}],"scroll-me":[{"scroll-me":C()}],"scroll-mt":[{"scroll-mt":C()}],"scroll-mr":[{"scroll-mr":C()}],"scroll-mb":[{"scroll-mb":C()}],"scroll-ml":[{"scroll-ml":C()}],"scroll-p":[{"scroll-p":C()}],"scroll-px":[{"scroll-px":C()}],"scroll-py":[{"scroll-py":C()}],"scroll-ps":[{"scroll-ps":C()}],"scroll-pe":[{"scroll-pe":C()}],"scroll-pt":[{"scroll-pt":C()}],"scroll-pr":[{"scroll-pr":C()}],"scroll-pb":[{"scroll-pb":C()}],"scroll-pl":[{"scroll-pl":C()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",O,k]}],fill:[{fill:["none",...R()]}],"stroke-w":[{stroke:[G,bt,qe,Wn]}],stroke:[{stroke:["none",...R()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}});function D(...e){return Hl(Mo(e))}const Go=Ln("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),zt=l.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},a)=>{const s=r?tt:"button";return u.jsx(s,{className:D(Go({variant:t,size:n,className:e})),ref:a,...o})});zt.displayName="Button";function zl({className:e,...t}){return u.jsx("div",{"data-slot":"card",className:D("bg-card text-card-foreground flex flex-col gap-4 rounded-xl py-6 shadow-sm",e),...t})}function Wl({className:e,...t}){return u.jsx("div",{"data-slot":"card-header",className:D("@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-1 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",e),...t})}function Gl({className:e,...t}){return u.jsx("div",{"data-slot":"card-title",className:D("leading-none font-semibold",e),...t})}function Bl({className:e,...t}){return u.jsx("div",{"data-slot":"card-description",className:D("text-muted-foreground text-sm",e),...t})}function Ul({className:e,...t}){return u.jsx("div",{"data-slot":"card-action",className:D("col-start-2 row-span-2 row-start-1 self-start justify-self-end",e),...t})}function Kl({className:e,...t}){return u.jsx("div",{"data-slot":"card-content",className:D("px-6",e),...t})}function Yl({className:e,...t}){return u.jsx("div",{"data-slot":"card-footer",className:D("flex items-center px-6 [.border-t]:pt-6",e),...t})}function ql(){const[e,t]=I.useState(!1);return I.useEffect(()=>{const n=()=>{t(window.innerWidth<768)};return n(),window.addEventListener("resize",n),()=>window.removeEventListener("resize",n)},[]),e}const Gn=l.forwardRef(({className:e,type:t,...n},r)=>u.jsx("input",{type:t,className:D("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:r,...n}));Gn.displayName="Input";var Xl=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],re=Xl.reduce((e,t)=>{const n=et(`Primitive.${t}`),r=l.forwardRef((o,a)=>{const{asChild:s,...i}=o,c=s?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),u.jsx(c,{...i,ref:a})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Bo(e,t){e&&Kr.flushSync(()=>e.dispatchEvent(t))}var Zl="Separator",Uo="horizontal",Jl=["horizontal","vertical"],Ko=l.forwardRef((e,t)=>{const{decorative:n,orientation:r=Uo,...o}=e,a=Ql(r)?r:Uo,i=n?{role:"none"}:{"aria-orientation":a==="vertical"?a:void 0,role:"separator"};return u.jsx(re.div,{"data-orientation":a,...i,...o,ref:t})});Ko.displayName=Zl;function Ql(e){return Jl.includes(e)}var Yo=Ko;const Wt=l.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>u.jsx(Yo,{ref:o,decorative:n,orientation:t,className:D("shrink-0 bg-border",t==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...r}));Wt.displayName=Yo.displayName;function $(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e==null||e(o),n===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}function eu(e,t){const n=l.createContext(t),r=a=>{const{children:s,...i}=a,c=l.useMemo(()=>i,Object.values(i));return u.jsx(n.Provider,{value:c,children:s})};r.displayName=e+"Provider";function o(a){const s=l.useContext(n);if(s)return s;if(t!==void 0)return t;throw new Error(`\`${a}\` must be used within \`${e}\``)}return[r,o]}function Xe(e,t=[]){let n=[];function r(a,s){const i=l.createContext(s),c=n.length;n=[...n,s];const p=f=>{var v;const{scope:m,children:h,...b}=f,g=((v=m==null?void 0:m[e])==null?void 0:v[c])||i,x=l.useMemo(()=>b,Object.values(b));return u.jsx(g.Provider,{value:x,children:h})};p.displayName=a+"Provider";function d(f,m){var g;const h=((g=m==null?void 0:m[e])==null?void 0:g[c])||i,b=l.useContext(h);if(b)return b;if(s!==void 0)return s;throw new Error(`\`${f}\` must be used within \`${a}\``)}return[p,d]}const o=()=>{const a=n.map(s=>l.createContext(s));return function(i){const c=(i==null?void 0:i[e])||a;return l.useMemo(()=>({[`__scope${e}`]:{...i,[e]:c}}),[i,c])}};return o.scopeName=e,[r,tu(o,...t)]}function tu(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(a){const s=r.reduce((i,{useScope:c,scopeName:p})=>{const f=c(a)[`__scope${p}`];return{...i,...f}},{});return l.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return n.scopeName=t.scopeName,n}var ze=globalThis!=null&&globalThis.document?l.useLayoutEffect:()=>{},nu=l[" useId ".trim().toString()]||(()=>{}),ru=0;function De(e){const[t,n]=l.useState(nu());return ze(()=>{n(r=>r??String(ru++))},[e]),e||(t?`radix-${t}`:"")}var ou=l[" useInsertionEffect ".trim().toString()]||ze;function xt({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,a,s]=au({defaultProp:t,onChange:n}),i=e!==void 0,c=i?e:o;{const d=l.useRef(e!==void 0);l.useEffect(()=>{const f=d.current;f!==i&&console.warn(`${r} is changing from ${f?"controlled":"uncontrolled"} to ${i?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=i},[i,r])}const p=l.useCallback(d=>{var f;if(i){const m=su(d)?d(e):d;m!==e&&((f=s.current)==null||f.call(s,m))}else a(d)},[i,e,a,s]);return[c,p]}function au({defaultProp:e,onChange:t}){const[n,r]=l.useState(e),o=l.useRef(n),a=l.useRef(t);return ou(()=>{a.current=t},[t]),l.useEffect(()=>{var s;o.current!==n&&((s=a.current)==null||s.call(a,n),o.current=n)},[n,o]),[n,r,a]}function su(e){return typeof e=="function"}function _e(e){const t=l.useRef(e);return l.useEffect(()=>{t.current=e}),l.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function iu(e,t=globalThis==null?void 0:globalThis.document){const n=_e(e);l.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var cu="DismissableLayer",Bn="dismissableLayer.update",lu="dismissableLayer.pointerDownOutside",uu="dismissableLayer.focusOutside",qo,Xo=l.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Gt=l.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:s,onDismiss:i,...c}=e,p=l.useContext(Xo),[d,f]=l.useState(null),m=(d==null?void 0:d.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,h]=l.useState({}),b=ie(t,M=>f(M)),g=Array.from(p.layers),[x]=[...p.layersWithOutsidePointerEventsDisabled].slice(-1),v=g.indexOf(x),w=d?g.indexOf(d):-1,E=p.layersWithOutsidePointerEventsDisabled.size>0,S=w>=v,_=pu(M=>{const C=M.target,j=[...p.branches].some(L=>L.contains(C));!S||j||(o==null||o(M),s==null||s(M),M.defaultPrevented||i==null||i())},m),T=mu(M=>{const C=M.target;[...p.branches].some(L=>L.contains(C))||(a==null||a(M),s==null||s(M),M.defaultPrevented||i==null||i())},m);return iu(M=>{w===p.layers.size-1&&(r==null||r(M),!M.defaultPrevented&&i&&(M.preventDefault(),i()))},m),l.useEffect(()=>{if(d)return n&&(p.layersWithOutsidePointerEventsDisabled.size===0&&(qo=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),p.layersWithOutsidePointerEventsDisabled.add(d)),p.layers.add(d),Zo(),()=>{n&&p.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=qo)}},[d,m,n,p]),l.useEffect(()=>()=>{d&&(p.layers.delete(d),p.layersWithOutsidePointerEventsDisabled.delete(d),Zo())},[d,p]),l.useEffect(()=>{const M=()=>h({});return document.addEventListener(Bn,M),()=>document.removeEventListener(Bn,M)},[]),u.jsx(re.div,{...c,ref:b,style:{pointerEvents:E?S?"auto":"none":void 0,...e.style},onFocusCapture:$(e.onFocusCapture,T.onFocusCapture),onBlurCapture:$(e.onBlurCapture,T.onBlurCapture),onPointerDownCapture:$(e.onPointerDownCapture,_.onPointerDownCapture)})});Gt.displayName=cu;var du="DismissableLayerBranch",fu=l.forwardRef((e,t)=>{const n=l.useContext(Xo),r=l.useRef(null),o=ie(t,r);return l.useEffect(()=>{const a=r.current;if(a)return n.branches.add(a),()=>{n.branches.delete(a)}},[n.branches]),u.jsx(re.div,{...e,ref:o})});fu.displayName=du;function pu(e,t=globalThis==null?void 0:globalThis.document){const n=_e(e),r=l.useRef(!1),o=l.useRef(()=>{});return l.useEffect(()=>{const a=i=>{if(i.target&&!r.current){let c=function(){Jo(lu,n,p,{discrete:!0})};const p={originalEvent:i};i.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);r.current=!1},s=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(s),t.removeEventListener("pointerdown",a),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function mu(e,t=globalThis==null?void 0:globalThis.document){const n=_e(e),r=l.useRef(!1);return l.useEffect(()=>{const o=a=>{a.target&&!r.current&&Jo(uu,n,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Zo(){const e=new CustomEvent(Bn);document.dispatchEvent(e)}function Jo(e,t,n,{discrete:r}){const o=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Bo(o,a):o.dispatchEvent(a)}var Un="focusScope.autoFocusOnMount",Kn="focusScope.autoFocusOnUnmount",Qo={bubbles:!1,cancelable:!0},hu="FocusScope",Yn=l.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:a,...s}=e,[i,c]=l.useState(null),p=_e(o),d=_e(a),f=l.useRef(null),m=ie(t,g=>c(g)),h=l.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;l.useEffect(()=>{if(r){let g=function(E){if(h.paused||!i)return;const S=E.target;i.contains(S)?f.current=S:We(f.current,{select:!0})},x=function(E){if(h.paused||!i)return;const S=E.relatedTarget;S!==null&&(i.contains(S)||We(f.current,{select:!0}))},v=function(E){if(document.activeElement===document.body)for(const _ of E)_.removedNodes.length>0&&We(i)};document.addEventListener("focusin",g),document.addEventListener("focusout",x);const w=new MutationObserver(v);return i&&w.observe(i,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",x),w.disconnect()}}},[r,i,h.paused]),l.useEffect(()=>{if(i){na.add(h);const g=document.activeElement;if(!i.contains(g)){const v=new CustomEvent(Un,Qo);i.addEventListener(Un,p),i.dispatchEvent(v),v.defaultPrevented||(gu(yu(ea(i)),{select:!0}),document.activeElement===g&&We(i))}return()=>{i.removeEventListener(Un,p),setTimeout(()=>{const v=new CustomEvent(Kn,Qo);i.addEventListener(Kn,d),i.dispatchEvent(v),v.defaultPrevented||We(g??document.body,{select:!0}),i.removeEventListener(Kn,d),na.remove(h)},0)}}},[i,p,d,h]);const b=l.useCallback(g=>{if(!n&&!r||h.paused)return;const x=g.key==="Tab"&&!g.altKey&&!g.ctrlKey&&!g.metaKey,v=document.activeElement;if(x&&v){const w=g.currentTarget,[E,S]=vu(w);E&&S?!g.shiftKey&&v===S?(g.preventDefault(),n&&We(E,{select:!0})):g.shiftKey&&v===E&&(g.preventDefault(),n&&We(S,{select:!0})):v===w&&g.preventDefault()}},[n,r,h.paused]);return u.jsx(re.div,{tabIndex:-1,...s,ref:m,onKeyDown:b})});Yn.displayName=hu;function gu(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(We(r,{select:t}),document.activeElement!==n)return}function vu(e){const t=ea(e),n=ta(t,e),r=ta(t.reverse(),e);return[n,r]}function ea(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function ta(e,t){for(const n of e)if(!bu(n,{upTo:t}))return n}function bu(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function xu(e){return e instanceof HTMLInputElement&&"select"in e}function We(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&xu(e)&&t&&e.select()}}var na=wu();function wu(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=ra(e,t),e.unshift(t)},remove(t){var n;e=ra(e,t),(n=e[0])==null||n.resume()}}}function ra(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function yu(e){return e.filter(t=>t.tagName!=="A")}var Cu="Portal",qn=l.forwardRef((e,t)=>{var i;const{container:n,...r}=e,[o,a]=l.useState(!1);ze(()=>a(!0),[]);const s=n||o&&((i=globalThis==null?void 0:globalThis.document)==null?void 0:i.body);return s?Br.createPortal(u.jsx(re.div,{...r,ref:t}),s):null});qn.displayName=Cu;function Eu(e,t){return l.useReducer((n,r)=>t[n][r]??n,e)}var Ie=e=>{const{present:t,children:n}=e,r=Su(t),o=typeof n=="function"?n({present:r.isPresent}):l.Children.only(n),a=ie(r.ref,_u(o));return typeof n=="function"||r.isPresent?l.cloneElement(o,{ref:a}):null};Ie.displayName="Presence";function Su(e){const[t,n]=l.useState(),r=l.useRef(null),o=l.useRef(e),a=l.useRef("none"),s=e?"mounted":"unmounted",[i,c]=Eu(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return l.useEffect(()=>{const p=Bt(r.current);a.current=i==="mounted"?p:"none"},[i]),ze(()=>{const p=r.current,d=o.current;if(d!==e){const m=a.current,h=Bt(p);e?c("MOUNT"):h==="none"||(p==null?void 0:p.display)==="none"?c("UNMOUNT"):c(d&&m!==h?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),ze(()=>{if(t){let p;const d=t.ownerDocument.defaultView??window,f=h=>{const g=Bt(r.current).includes(h.animationName);if(h.target===t&&g&&(c("ANIMATION_END"),!o.current)){const x=t.style.animationFillMode;t.style.animationFillMode="forwards",p=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=x)})}},m=h=>{h.target===t&&(a.current=Bt(r.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{d.clearTimeout(p),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(i),ref:l.useCallback(p=>{r.current=p?getComputedStyle(p):null,n(p)},[])}}function Bt(e){return(e==null?void 0:e.animationName)||"none"}function _u(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Xn=0;function oa(){l.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??aa()),document.body.insertAdjacentElement("beforeend",e[1]??aa()),Xn++,()=>{Xn===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Xn--}},[])}function aa(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var Re=function(){return Re=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])}return t},Re.apply(this,arguments)};function sa(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function Ru(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,a;r<o;r++)(a||!(r in t))&&(a||(a=Array.prototype.slice.call(t,0,r)),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var Ut="right-scroll-bar-position",Kt="width-before-scroll-bar",Mu="with-scroll-bars-hidden",Au="--removed-body-scroll-bar-size";function Zn(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Tu(e,t){var n=I.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}var Nu=typeof window<"u"?l.useLayoutEffect:l.useEffect,ia=new WeakMap;function ku(e,t){var n=Tu(null,function(r){return e.forEach(function(o){return Zn(o,r)})});return Nu(function(){var r=ia.get(n);if(r){var o=new Set(r),a=new Set(e),s=n.current;o.forEach(function(i){a.has(i)||Zn(i,null)}),a.forEach(function(i){o.has(i)||Zn(i,s)})}ia.set(n,e)},[e]),n}function Ou(e){return e}function Pu(e,t){t===void 0&&(t=Ou);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(a){var s=t(a,r);return n.push(s),function(){n=n.filter(function(i){return i!==s})}},assignSyncMedium:function(a){for(r=!0;n.length;){var s=n;n=[],s.forEach(a)}n={push:function(i){return a(i)},filter:function(){return n}}},assignMedium:function(a){r=!0;var s=[];if(n.length){var i=n;n=[],i.forEach(a),s=n}var c=function(){var d=s;s=[],d.forEach(a)},p=function(){return Promise.resolve().then(c)};p(),n={push:function(d){s.push(d),p()},filter:function(d){return s=s.filter(d),n}}}};return o}function Du(e){e===void 0&&(e={});var t=Pu(null);return t.options=Re({async:!0,ssr:!1},e),t}var ca=function(e){var t=e.sideCar,n=sa(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return l.createElement(r,Re({},n))};ca.isSideCarExport=!0;function Iu(e,t){return e.useMedium(t),ca}var la=Du(),Jn=function(){},Yt=l.forwardRef(function(e,t){var n=l.useRef(null),r=l.useState({onScrollCapture:Jn,onWheelCapture:Jn,onTouchMoveCapture:Jn}),o=r[0],a=r[1],s=e.forwardProps,i=e.children,c=e.className,p=e.removeScrollBar,d=e.enabled,f=e.shards,m=e.sideCar,h=e.noRelative,b=e.noIsolation,g=e.inert,x=e.allowPinchZoom,v=e.as,w=v===void 0?"div":v,E=e.gapMode,S=sa(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),_=m,T=ku([n,t]),M=Re(Re({},S),o);return l.createElement(l.Fragment,null,d&&l.createElement(_,{sideCar:la,removeScrollBar:p,shards:f,noRelative:h,noIsolation:b,inert:g,setCallbacks:a,allowPinchZoom:!!x,lockRef:n,gapMode:E}),s?l.cloneElement(l.Children.only(i),Re(Re({},M),{ref:T})):l.createElement(w,Re({},M,{className:c,ref:T}),i))});Yt.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},Yt.classNames={fullWidth:Kt,zeroRight:Ut};var ju=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function Lu(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=ju();return t&&e.setAttribute("nonce",t),e}function Fu(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function $u(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Vu=function(){var e=0,t=null;return{add:function(n){e==0&&(t=Lu())&&(Fu(t,n),$u(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Hu=function(){var e=Vu();return function(t,n){l.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},ua=function(){var e=Hu(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},zu={left:0,top:0,right:0,gap:0},Qn=function(e){return parseInt(e||"",10)||0},Wu=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[Qn(n),Qn(r),Qn(o)]},Gu=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return zu;var t=Wu(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},Bu=ua(),at="data-scroll-locked",Uu=function(e,t,n,r){var o=e.left,a=e.top,s=e.right,i=e.gap;return n===void 0&&(n="margin"),`
139
- .`.concat(Mu,` {
138
+ */const sl=fe("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);function So(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function $t(...e){return t=>{let n=!1;const r=e.map(o=>{const s=So(o,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let o=0;o<r.length;o++){const s=r[o];typeof s=="function"?s():So(e[o],null)}}}}function ie(...e){return l.useCallback($t(...e),e)}function et(e){const t=al(e),n=l.forwardRef((r,o)=>{const{children:s,...a}=r,i=l.Children.toArray(s),c=i.find(cl);if(c){const p=c.props.children,d=i.map(f=>f===c?l.Children.count(p)>1?l.Children.only(null):l.isValidElement(p)?p.props.children:null:f);return u.jsx(t,{...a,ref:o,children:l.isValidElement(p)?l.cloneElement(p,void 0,d):null})}return u.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}var tt=et("Slot");function al(e){const t=l.forwardRef((n,r)=>{const{children:o,...s}=n;if(l.isValidElement(o)){const a=ul(o),i=ll(s,o.props);return o.type!==l.Fragment&&(i.ref=r?$t(r,a):a),l.cloneElement(o,i)}return l.Children.count(o)>1?l.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var _o=Symbol("radix.slottable");function il(e){const t=({children:n})=>u.jsx(u.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=_o,t}function cl(e){return l.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===_o}function ll(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...i)=>{const c=s(...i);return o(...i),c}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function ul(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function Ro(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=Ro(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Mo(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=Ro(e))&&(r&&(r+=" "),r+=t);return r}const Ao=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,To=Mo,Ln=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return To(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:o,defaultVariants:s}=t,a=Object.keys(o).map(p=>{const d=n==null?void 0:n[p],f=s==null?void 0:s[p];if(d===null)return null;const m=Ao(d)||Ao(f);return o[p][m]}),i=n&&Object.entries(n).reduce((p,d)=>{let[f,m]=d;return m===void 0||(p[f]=m),p},{}),c=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((p,d)=>{let{class:f,className:m,...h}=d;return Object.entries(h).every(b=>{let[g,w]=b;return Array.isArray(w)?w.includes({...s,...i}[g]):{...s,...i}[g]===w})?[...p,f,m]:p},[]);return To(e,a,c,n==null?void 0:n.class,n==null?void 0:n.className)},Fn="-",dl=e=>{const t=pl(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:a=>{const i=a.split(Fn);return i[0]===""&&i.length!==1&&i.shift(),No(i,t)||fl(a)},getConflictingClassGroupIds:(a,i)=>{const c=n[a]||[];return i&&r[a]?[...c,...r[a]]:c}}},No=(e,t)=>{var a;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),o=r?No(e.slice(1),r):void 0;if(o)return o;if(t.validators.length===0)return;const s=e.join(Fn);return(a=t.validators.find(({validator:i})=>i(s)))==null?void 0:a.classGroupId},ko=/^\[(.+)\]$/,fl=e=>{if(ko.test(e)){const t=ko.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},pl=e=>{const{theme:t,classGroups:n}=e,r={nextPart:new Map,validators:[]};for(const o in n)$n(n[o],r,o,t);return r},$n=(e,t,n,r)=>{e.forEach(o=>{if(typeof o=="string"){const s=o===""?t:Oo(t,o);s.classGroupId=n;return}if(typeof o=="function"){if(ml(o)){$n(o(r),t,n,r);return}t.validators.push({validator:o,classGroupId:n});return}Object.entries(o).forEach(([s,a])=>{$n(a,Oo(t,s),n,r)})})},Oo=(e,t)=>{let n=e;return t.split(Fn).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},ml=e=>e.isThemeGetter,hl=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const o=(s,a)=>{n.set(s,a),t++,t>e&&(t=0,r=n,n=new Map)};return{get(s){let a=n.get(s);if(a!==void 0)return a;if((a=r.get(s))!==void 0)return o(s,a),a},set(s,a){n.has(s)?n.set(s,a):o(s,a)}}},Vn="!",Hn=":",gl=Hn.length,vl=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=o=>{const s=[];let a=0,i=0,c=0,p;for(let b=0;b<o.length;b++){let g=o[b];if(a===0&&i===0){if(g===Hn){s.push(o.slice(c,b)),c=b+gl;continue}if(g==="/"){p=b;continue}}g==="["?a++:g==="]"?a--:g==="("?i++:g===")"&&i--}const d=s.length===0?o:o.substring(c),f=bl(d),m=f!==d,h=p&&p>c?p-c:void 0;return{modifiers:s,hasImportantModifier:m,baseClassName:f,maybePostfixModifierPosition:h}};if(t){const o=t+Hn,s=r;r=a=>a.startsWith(o)?s(a.substring(o.length)):{isExternal:!0,modifiers:[],hasImportantModifier:!1,baseClassName:a,maybePostfixModifierPosition:void 0}}if(n){const o=r;r=s=>n({className:s,parseClassName:o})}return r},bl=e=>e.endsWith(Vn)?e.substring(0,e.length-1):e.startsWith(Vn)?e.substring(1):e,wl=e=>{const t=Object.fromEntries(e.orderSensitiveModifiers.map(r=>[r,!0]));return r=>{if(r.length<=1)return r;const o=[];let s=[];return r.forEach(a=>{a[0]==="["||t[a]?(o.push(...s.sort(),a),s=[]):s.push(a)}),o.push(...s.sort()),o}},xl=e=>({cache:hl(e.cacheSize),parseClassName:vl(e),sortModifiers:wl(e),...dl(e)}),yl=/\s+/,Cl=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o,sortModifiers:s}=t,a=[],i=e.trim().split(yl);let c="";for(let p=i.length-1;p>=0;p-=1){const d=i[p],{isExternal:f,modifiers:m,hasImportantModifier:h,baseClassName:b,maybePostfixModifierPosition:g}=n(d);if(f){c=d+(c.length>0?" "+c:c);continue}let w=!!g,v=r(w?b.substring(0,g):b);if(!v){if(!w){c=d+(c.length>0?" "+c:c);continue}if(v=r(b),!v){c=d+(c.length>0?" "+c:c);continue}w=!1}const x=s(m).join(":"),E=h?x+Vn:x,S=E+v;if(a.includes(S))continue;a.push(S);const _=o(v,w);for(let T=0;T<_.length;++T){const M=_[T];a.push(E+M)}c=d+(c.length>0?" "+c:c)}return c};function El(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=Po(t))&&(r&&(r+=" "),r+=n);return r}const Po=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=Po(e[r]))&&(n&&(n+=" "),n+=t);return n};function Sl(e,...t){let n,r,o,s=a;function a(c){const p=t.reduce((d,f)=>f(d),e());return n=xl(p),r=n.cache.get,o=n.cache.set,s=i,i(c)}function i(c){const p=r(c);if(p)return p;const d=Cl(c,n);return o(c,d),d}return function(){return s(El.apply(null,arguments))}}const ce=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},Do=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Io=/^\((?:(\w[\w-]*):)?(.+)\)$/i,_l=/^\d+\/\d+$/,Rl=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Ml=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Al=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Tl=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Nl=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,nt=e=>_l.test(e),G=e=>!!e&&!Number.isNaN(Number(e)),He=e=>!!e&&Number.isInteger(Number(e)),zn=e=>e.endsWith("%")&&G(e.slice(0,-1)),Pe=e=>Rl.test(e),kl=()=>!0,Ol=e=>Ml.test(e)&&!Al.test(e),jo=()=>!1,Pl=e=>Tl.test(e),Dl=e=>Nl.test(e),Il=e=>!k(e)&&!O(e),jl=e=>rt(e,Ho,jo),k=e=>Do.test(e),qe=e=>rt(e,zo,Ol),Wn=e=>rt(e,Hl,G),Lo=e=>rt(e,$o,jo),Ll=e=>rt(e,Vo,Dl),Vt=e=>rt(e,Wo,Pl),O=e=>Io.test(e),bt=e=>ot(e,zo),Fl=e=>ot(e,zl),Fo=e=>ot(e,$o),$l=e=>ot(e,Ho),Vl=e=>ot(e,Vo),Ht=e=>ot(e,Wo,!0),rt=(e,t,n)=>{const r=Do.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},ot=(e,t,n=!1)=>{const r=Io.exec(e);return r?r[1]?t(r[1]):n:!1},$o=e=>e==="position"||e==="percentage",Vo=e=>e==="image"||e==="url",Ho=e=>e==="length"||e==="size"||e==="bg-size",zo=e=>e==="length",Hl=e=>e==="number",zl=e=>e==="family-name",Wo=e=>e==="shadow",Wl=Sl(()=>{const e=ce("color"),t=ce("font"),n=ce("text"),r=ce("font-weight"),o=ce("tracking"),s=ce("leading"),a=ce("breakpoint"),i=ce("container"),c=ce("spacing"),p=ce("radius"),d=ce("shadow"),f=ce("inset-shadow"),m=ce("text-shadow"),h=ce("drop-shadow"),b=ce("blur"),g=ce("perspective"),w=ce("aspect"),v=ce("ease"),x=ce("animate"),E=()=>["auto","avoid","all","avoid-page","page","left","right","column"],S=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],_=()=>[...S(),O,k],T=()=>["auto","hidden","clip","visible","scroll"],M=()=>["auto","contain","none"],C=()=>[O,k,c],j=()=>[nt,"full","auto",...C()],L=()=>[He,"none","subgrid",O,k],U=()=>["auto",{span:["full",He,O,k]},He,O,k],B=()=>[He,"auto",O,k],z=()=>["auto","min","max","fr",O,k],W=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],X=()=>["start","end","center","stretch","center-safe","end-safe"],V=()=>["auto",...C()],K=()=>[nt,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...C()],R=()=>[e,O,k],N=()=>[...S(),Fo,Lo,{position:[O,k]}],y=()=>["no-repeat",{repeat:["","x","y","space","round"]}],P=()=>["auto","cover","contain",$l,jl,{size:[O,k]}],F=()=>[zn,bt,qe],H=()=>["","none","full",p,O,k],Z=()=>["",G,bt,qe],ne=()=>["solid","dashed","dotted","double"],ue=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Y=()=>[G,zn,Fo,Lo],ee=()=>["","none",b,O,k],te=()=>["none",G,O,k],ae=()=>["none",G,O,k],Se=()=>[G,O,k],Ke=()=>[nt,"full",...C()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[Pe],breakpoint:[Pe],color:[kl],container:[Pe],"drop-shadow":[Pe],ease:["in","out","in-out"],font:[Il],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[Pe],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[Pe],shadow:[Pe],spacing:["px",G],text:[Pe],"text-shadow":[Pe],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",nt,k,O,w]}],container:["container"],columns:[{columns:[G,k,O,i]}],"break-after":[{"break-after":E()}],"break-before":[{"break-before":E()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:_()}],overflow:[{overflow:T()}],"overflow-x":[{"overflow-x":T()}],"overflow-y":[{"overflow-y":T()}],overscroll:[{overscroll:M()}],"overscroll-x":[{"overscroll-x":M()}],"overscroll-y":[{"overscroll-y":M()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:j()}],"inset-x":[{"inset-x":j()}],"inset-y":[{"inset-y":j()}],start:[{start:j()}],end:[{end:j()}],top:[{top:j()}],right:[{right:j()}],bottom:[{bottom:j()}],left:[{left:j()}],visibility:["visible","invisible","collapse"],z:[{z:[He,"auto",O,k]}],basis:[{basis:[nt,"full","auto",i,...C()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[G,nt,"auto","initial","none",k]}],grow:[{grow:["",G,O,k]}],shrink:[{shrink:["",G,O,k]}],order:[{order:[He,"first","last","none",O,k]}],"grid-cols":[{"grid-cols":L()}],"col-start-end":[{col:U()}],"col-start":[{"col-start":B()}],"col-end":[{"col-end":B()}],"grid-rows":[{"grid-rows":L()}],"row-start-end":[{row:U()}],"row-start":[{"row-start":B()}],"row-end":[{"row-end":B()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":z()}],"auto-rows":[{"auto-rows":z()}],gap:[{gap:C()}],"gap-x":[{"gap-x":C()}],"gap-y":[{"gap-y":C()}],"justify-content":[{justify:[...W(),"normal"]}],"justify-items":[{"justify-items":[...X(),"normal"]}],"justify-self":[{"justify-self":["auto",...X()]}],"align-content":[{content:["normal",...W()]}],"align-items":[{items:[...X(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...X(),{baseline:["","last"]}]}],"place-content":[{"place-content":W()}],"place-items":[{"place-items":[...X(),"baseline"]}],"place-self":[{"place-self":["auto",...X()]}],p:[{p:C()}],px:[{px:C()}],py:[{py:C()}],ps:[{ps:C()}],pe:[{pe:C()}],pt:[{pt:C()}],pr:[{pr:C()}],pb:[{pb:C()}],pl:[{pl:C()}],m:[{m:V()}],mx:[{mx:V()}],my:[{my:V()}],ms:[{ms:V()}],me:[{me:V()}],mt:[{mt:V()}],mr:[{mr:V()}],mb:[{mb:V()}],ml:[{ml:V()}],"space-x":[{"space-x":C()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":C()}],"space-y-reverse":["space-y-reverse"],size:[{size:K()}],w:[{w:[i,"screen",...K()]}],"min-w":[{"min-w":[i,"screen","none",...K()]}],"max-w":[{"max-w":[i,"screen","none","prose",{screen:[a]},...K()]}],h:[{h:["screen","lh",...K()]}],"min-h":[{"min-h":["screen","lh","none",...K()]}],"max-h":[{"max-h":["screen","lh",...K()]}],"font-size":[{text:["base",n,bt,qe]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,O,Wn]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",zn,k]}],"font-family":[{font:[Fl,k,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[o,O,k]}],"line-clamp":[{"line-clamp":[G,"none",O,Wn]}],leading:[{leading:[s,...C()]}],"list-image":[{"list-image":["none",O,k]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",O,k]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:R()}],"text-color":[{text:R()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ne(),"wavy"]}],"text-decoration-thickness":[{decoration:[G,"from-font","auto",O,qe]}],"text-decoration-color":[{decoration:R()}],"underline-offset":[{"underline-offset":[G,"auto",O,k]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:C()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",O,k]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",O,k]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:N()}],"bg-repeat":[{bg:y()}],"bg-size":[{bg:P()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},He,O,k],radial:["",O,k],conic:[He,O,k]},Vl,Ll]}],"bg-color":[{bg:R()}],"gradient-from-pos":[{from:F()}],"gradient-via-pos":[{via:F()}],"gradient-to-pos":[{to:F()}],"gradient-from":[{from:R()}],"gradient-via":[{via:R()}],"gradient-to":[{to:R()}],rounded:[{rounded:H()}],"rounded-s":[{"rounded-s":H()}],"rounded-e":[{"rounded-e":H()}],"rounded-t":[{"rounded-t":H()}],"rounded-r":[{"rounded-r":H()}],"rounded-b":[{"rounded-b":H()}],"rounded-l":[{"rounded-l":H()}],"rounded-ss":[{"rounded-ss":H()}],"rounded-se":[{"rounded-se":H()}],"rounded-ee":[{"rounded-ee":H()}],"rounded-es":[{"rounded-es":H()}],"rounded-tl":[{"rounded-tl":H()}],"rounded-tr":[{"rounded-tr":H()}],"rounded-br":[{"rounded-br":H()}],"rounded-bl":[{"rounded-bl":H()}],"border-w":[{border:Z()}],"border-w-x":[{"border-x":Z()}],"border-w-y":[{"border-y":Z()}],"border-w-s":[{"border-s":Z()}],"border-w-e":[{"border-e":Z()}],"border-w-t":[{"border-t":Z()}],"border-w-r":[{"border-r":Z()}],"border-w-b":[{"border-b":Z()}],"border-w-l":[{"border-l":Z()}],"divide-x":[{"divide-x":Z()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":Z()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...ne(),"hidden","none"]}],"divide-style":[{divide:[...ne(),"hidden","none"]}],"border-color":[{border:R()}],"border-color-x":[{"border-x":R()}],"border-color-y":[{"border-y":R()}],"border-color-s":[{"border-s":R()}],"border-color-e":[{"border-e":R()}],"border-color-t":[{"border-t":R()}],"border-color-r":[{"border-r":R()}],"border-color-b":[{"border-b":R()}],"border-color-l":[{"border-l":R()}],"divide-color":[{divide:R()}],"outline-style":[{outline:[...ne(),"none","hidden"]}],"outline-offset":[{"outline-offset":[G,O,k]}],"outline-w":[{outline:["",G,bt,qe]}],"outline-color":[{outline:R()}],shadow:[{shadow:["","none",d,Ht,Vt]}],"shadow-color":[{shadow:R()}],"inset-shadow":[{"inset-shadow":["none",f,Ht,Vt]}],"inset-shadow-color":[{"inset-shadow":R()}],"ring-w":[{ring:Z()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:R()}],"ring-offset-w":[{"ring-offset":[G,qe]}],"ring-offset-color":[{"ring-offset":R()}],"inset-ring-w":[{"inset-ring":Z()}],"inset-ring-color":[{"inset-ring":R()}],"text-shadow":[{"text-shadow":["none",m,Ht,Vt]}],"text-shadow-color":[{"text-shadow":R()}],opacity:[{opacity:[G,O,k]}],"mix-blend":[{"mix-blend":[...ue(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":ue()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[G]}],"mask-image-linear-from-pos":[{"mask-linear-from":Y()}],"mask-image-linear-to-pos":[{"mask-linear-to":Y()}],"mask-image-linear-from-color":[{"mask-linear-from":R()}],"mask-image-linear-to-color":[{"mask-linear-to":R()}],"mask-image-t-from-pos":[{"mask-t-from":Y()}],"mask-image-t-to-pos":[{"mask-t-to":Y()}],"mask-image-t-from-color":[{"mask-t-from":R()}],"mask-image-t-to-color":[{"mask-t-to":R()}],"mask-image-r-from-pos":[{"mask-r-from":Y()}],"mask-image-r-to-pos":[{"mask-r-to":Y()}],"mask-image-r-from-color":[{"mask-r-from":R()}],"mask-image-r-to-color":[{"mask-r-to":R()}],"mask-image-b-from-pos":[{"mask-b-from":Y()}],"mask-image-b-to-pos":[{"mask-b-to":Y()}],"mask-image-b-from-color":[{"mask-b-from":R()}],"mask-image-b-to-color":[{"mask-b-to":R()}],"mask-image-l-from-pos":[{"mask-l-from":Y()}],"mask-image-l-to-pos":[{"mask-l-to":Y()}],"mask-image-l-from-color":[{"mask-l-from":R()}],"mask-image-l-to-color":[{"mask-l-to":R()}],"mask-image-x-from-pos":[{"mask-x-from":Y()}],"mask-image-x-to-pos":[{"mask-x-to":Y()}],"mask-image-x-from-color":[{"mask-x-from":R()}],"mask-image-x-to-color":[{"mask-x-to":R()}],"mask-image-y-from-pos":[{"mask-y-from":Y()}],"mask-image-y-to-pos":[{"mask-y-to":Y()}],"mask-image-y-from-color":[{"mask-y-from":R()}],"mask-image-y-to-color":[{"mask-y-to":R()}],"mask-image-radial":[{"mask-radial":[O,k]}],"mask-image-radial-from-pos":[{"mask-radial-from":Y()}],"mask-image-radial-to-pos":[{"mask-radial-to":Y()}],"mask-image-radial-from-color":[{"mask-radial-from":R()}],"mask-image-radial-to-color":[{"mask-radial-to":R()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":S()}],"mask-image-conic-pos":[{"mask-conic":[G]}],"mask-image-conic-from-pos":[{"mask-conic-from":Y()}],"mask-image-conic-to-pos":[{"mask-conic-to":Y()}],"mask-image-conic-from-color":[{"mask-conic-from":R()}],"mask-image-conic-to-color":[{"mask-conic-to":R()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:N()}],"mask-repeat":[{mask:y()}],"mask-size":[{mask:P()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",O,k]}],filter:[{filter:["","none",O,k]}],blur:[{blur:ee()}],brightness:[{brightness:[G,O,k]}],contrast:[{contrast:[G,O,k]}],"drop-shadow":[{"drop-shadow":["","none",h,Ht,Vt]}],"drop-shadow-color":[{"drop-shadow":R()}],grayscale:[{grayscale:["",G,O,k]}],"hue-rotate":[{"hue-rotate":[G,O,k]}],invert:[{invert:["",G,O,k]}],saturate:[{saturate:[G,O,k]}],sepia:[{sepia:["",G,O,k]}],"backdrop-filter":[{"backdrop-filter":["","none",O,k]}],"backdrop-blur":[{"backdrop-blur":ee()}],"backdrop-brightness":[{"backdrop-brightness":[G,O,k]}],"backdrop-contrast":[{"backdrop-contrast":[G,O,k]}],"backdrop-grayscale":[{"backdrop-grayscale":["",G,O,k]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[G,O,k]}],"backdrop-invert":[{"backdrop-invert":["",G,O,k]}],"backdrop-opacity":[{"backdrop-opacity":[G,O,k]}],"backdrop-saturate":[{"backdrop-saturate":[G,O,k]}],"backdrop-sepia":[{"backdrop-sepia":["",G,O,k]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":C()}],"border-spacing-x":[{"border-spacing-x":C()}],"border-spacing-y":[{"border-spacing-y":C()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",O,k]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[G,"initial",O,k]}],ease:[{ease:["linear","initial",v,O,k]}],delay:[{delay:[G,O,k]}],animate:[{animate:["none",x,O,k]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[g,O,k]}],"perspective-origin":[{"perspective-origin":_()}],rotate:[{rotate:te()}],"rotate-x":[{"rotate-x":te()}],"rotate-y":[{"rotate-y":te()}],"rotate-z":[{"rotate-z":te()}],scale:[{scale:ae()}],"scale-x":[{"scale-x":ae()}],"scale-y":[{"scale-y":ae()}],"scale-z":[{"scale-z":ae()}],"scale-3d":["scale-3d"],skew:[{skew:Se()}],"skew-x":[{"skew-x":Se()}],"skew-y":[{"skew-y":Se()}],transform:[{transform:[O,k,"","none","gpu","cpu"]}],"transform-origin":[{origin:_()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Ke()}],"translate-x":[{"translate-x":Ke()}],"translate-y":[{"translate-y":Ke()}],"translate-z":[{"translate-z":Ke()}],"translate-none":["translate-none"],accent:[{accent:R()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:R()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",O,k]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":C()}],"scroll-mx":[{"scroll-mx":C()}],"scroll-my":[{"scroll-my":C()}],"scroll-ms":[{"scroll-ms":C()}],"scroll-me":[{"scroll-me":C()}],"scroll-mt":[{"scroll-mt":C()}],"scroll-mr":[{"scroll-mr":C()}],"scroll-mb":[{"scroll-mb":C()}],"scroll-ml":[{"scroll-ml":C()}],"scroll-p":[{"scroll-p":C()}],"scroll-px":[{"scroll-px":C()}],"scroll-py":[{"scroll-py":C()}],"scroll-ps":[{"scroll-ps":C()}],"scroll-pe":[{"scroll-pe":C()}],"scroll-pt":[{"scroll-pt":C()}],"scroll-pr":[{"scroll-pr":C()}],"scroll-pb":[{"scroll-pb":C()}],"scroll-pl":[{"scroll-pl":C()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",O,k]}],fill:[{fill:["none",...R()]}],"stroke-w":[{stroke:[G,bt,qe,Wn]}],stroke:[{stroke:["none",...R()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}});function D(...e){return Wl(Mo(e))}const Go=Ln("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),zt=l.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const a=r?tt:"button";return u.jsx(a,{className:D(Go({variant:t,size:n,className:e})),ref:s,...o})});zt.displayName="Button";function Gl({className:e,...t}){return u.jsx("div",{"data-slot":"card",className:D("bg-card text-card-foreground flex flex-col gap-4 rounded-xl py-6 shadow-sm",e),...t})}function Bl({className:e,...t}){return u.jsx("div",{"data-slot":"card-header",className:D("@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-1 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",e),...t})}function Ul({className:e,...t}){return u.jsx("div",{"data-slot":"card-title",className:D("leading-none font-semibold",e),...t})}function Kl({className:e,...t}){return u.jsx("div",{"data-slot":"card-description",className:D("text-muted-foreground text-sm",e),...t})}function Yl({className:e,...t}){return u.jsx("div",{"data-slot":"card-action",className:D("col-start-2 row-span-2 row-start-1 self-start justify-self-end",e),...t})}function ql({className:e,...t}){return u.jsx("div",{"data-slot":"card-content",className:D("px-6",e),...t})}function Xl({className:e,...t}){return u.jsx("div",{"data-slot":"card-footer",className:D("flex items-center px-6 [.border-t]:pt-6",e),...t})}function Zl(){const[e,t]=I.useState(!1);return I.useEffect(()=>{const n=()=>{t(window.innerWidth<768)};return n(),window.addEventListener("resize",n),()=>window.removeEventListener("resize",n)},[]),e}const Gn=l.forwardRef(({className:e,type:t,...n},r)=>u.jsx("input",{type:t,className:D("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:r,...n}));Gn.displayName="Input";var Jl=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],re=Jl.reduce((e,t)=>{const n=et(`Primitive.${t}`),r=l.forwardRef((o,s)=>{const{asChild:a,...i}=o,c=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),u.jsx(c,{...i,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Bo(e,t){e&&Kr.flushSync(()=>e.dispatchEvent(t))}var Ql="Separator",Uo="horizontal",eu=["horizontal","vertical"],Ko=l.forwardRef((e,t)=>{const{decorative:n,orientation:r=Uo,...o}=e,s=tu(r)?r:Uo,i=n?{role:"none"}:{"aria-orientation":s==="vertical"?s:void 0,role:"separator"};return u.jsx(re.div,{"data-orientation":s,...i,...o,ref:t})});Ko.displayName=Ql;function tu(e){return eu.includes(e)}var Yo=Ko;const Wt=l.forwardRef(({className:e,orientation:t="horizontal",decorative:n=!0,...r},o)=>u.jsx(Yo,{ref:o,decorative:n,orientation:t,className:D("shrink-0 bg-border",t==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...r}));Wt.displayName=Yo.displayName;function $(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e==null||e(o),n===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}function nu(e,t){const n=l.createContext(t),r=s=>{const{children:a,...i}=s,c=l.useMemo(()=>i,Object.values(i));return u.jsx(n.Provider,{value:c,children:a})};r.displayName=e+"Provider";function o(s){const a=l.useContext(n);if(a)return a;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[r,o]}function Xe(e,t=[]){let n=[];function r(s,a){const i=l.createContext(a),c=n.length;n=[...n,a];const p=f=>{var v;const{scope:m,children:h,...b}=f,g=((v=m==null?void 0:m[e])==null?void 0:v[c])||i,w=l.useMemo(()=>b,Object.values(b));return u.jsx(g.Provider,{value:w,children:h})};p.displayName=s+"Provider";function d(f,m){var g;const h=((g=m==null?void 0:m[e])==null?void 0:g[c])||i,b=l.useContext(h);if(b)return b;if(a!==void 0)return a;throw new Error(`\`${f}\` must be used within \`${s}\``)}return[p,d]}const o=()=>{const s=n.map(a=>l.createContext(a));return function(i){const c=(i==null?void 0:i[e])||s;return l.useMemo(()=>({[`__scope${e}`]:{...i,[e]:c}}),[i,c])}};return o.scopeName=e,[r,ru(o,...t)]}function ru(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const a=r.reduce((i,{useScope:c,scopeName:p})=>{const f=c(s)[`__scope${p}`];return{...i,...f}},{});return l.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}var ze=globalThis!=null&&globalThis.document?l.useLayoutEffect:()=>{},ou=l[" useId ".trim().toString()]||(()=>{}),su=0;function De(e){const[t,n]=l.useState(ou());return ze(()=>{n(r=>r??String(su++))},[e]),e||(t?`radix-${t}`:"")}var au=l[" useInsertionEffect ".trim().toString()]||ze;function wt({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,s,a]=iu({defaultProp:t,onChange:n}),i=e!==void 0,c=i?e:o;{const d=l.useRef(e!==void 0);l.useEffect(()=>{const f=d.current;f!==i&&console.warn(`${r} is changing from ${f?"controlled":"uncontrolled"} to ${i?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=i},[i,r])}const p=l.useCallback(d=>{var f;if(i){const m=cu(d)?d(e):d;m!==e&&((f=a.current)==null||f.call(a,m))}else s(d)},[i,e,s,a]);return[c,p]}function iu({defaultProp:e,onChange:t}){const[n,r]=l.useState(e),o=l.useRef(n),s=l.useRef(t);return au(()=>{s.current=t},[t]),l.useEffect(()=>{var a;o.current!==n&&((a=s.current)==null||a.call(s,n),o.current=n)},[n,o]),[n,r,s]}function cu(e){return typeof e=="function"}function _e(e){const t=l.useRef(e);return l.useEffect(()=>{t.current=e}),l.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function lu(e,t=globalThis==null?void 0:globalThis.document){const n=_e(e);l.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var uu="DismissableLayer",Bn="dismissableLayer.update",du="dismissableLayer.pointerDownOutside",fu="dismissableLayer.focusOutside",qo,Xo=l.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Gt=l.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:a,onDismiss:i,...c}=e,p=l.useContext(Xo),[d,f]=l.useState(null),m=(d==null?void 0:d.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,h]=l.useState({}),b=ie(t,M=>f(M)),g=Array.from(p.layers),[w]=[...p.layersWithOutsidePointerEventsDisabled].slice(-1),v=g.indexOf(w),x=d?g.indexOf(d):-1,E=p.layersWithOutsidePointerEventsDisabled.size>0,S=x>=v,_=hu(M=>{const C=M.target,j=[...p.branches].some(L=>L.contains(C));!S||j||(o==null||o(M),a==null||a(M),M.defaultPrevented||i==null||i())},m),T=gu(M=>{const C=M.target;[...p.branches].some(L=>L.contains(C))||(s==null||s(M),a==null||a(M),M.defaultPrevented||i==null||i())},m);return lu(M=>{x===p.layers.size-1&&(r==null||r(M),!M.defaultPrevented&&i&&(M.preventDefault(),i()))},m),l.useEffect(()=>{if(d)return n&&(p.layersWithOutsidePointerEventsDisabled.size===0&&(qo=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),p.layersWithOutsidePointerEventsDisabled.add(d)),p.layers.add(d),Zo(),()=>{n&&p.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=qo)}},[d,m,n,p]),l.useEffect(()=>()=>{d&&(p.layers.delete(d),p.layersWithOutsidePointerEventsDisabled.delete(d),Zo())},[d,p]),l.useEffect(()=>{const M=()=>h({});return document.addEventListener(Bn,M),()=>document.removeEventListener(Bn,M)},[]),u.jsx(re.div,{...c,ref:b,style:{pointerEvents:E?S?"auto":"none":void 0,...e.style},onFocusCapture:$(e.onFocusCapture,T.onFocusCapture),onBlurCapture:$(e.onBlurCapture,T.onBlurCapture),onPointerDownCapture:$(e.onPointerDownCapture,_.onPointerDownCapture)})});Gt.displayName=uu;var pu="DismissableLayerBranch",mu=l.forwardRef((e,t)=>{const n=l.useContext(Xo),r=l.useRef(null),o=ie(t,r);return l.useEffect(()=>{const s=r.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),u.jsx(re.div,{...e,ref:o})});mu.displayName=pu;function hu(e,t=globalThis==null?void 0:globalThis.document){const n=_e(e),r=l.useRef(!1),o=l.useRef(()=>{});return l.useEffect(()=>{const s=i=>{if(i.target&&!r.current){let c=function(){Jo(du,n,p,{discrete:!0})};const p={originalEvent:i};i.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);r.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",s),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function gu(e,t=globalThis==null?void 0:globalThis.document){const n=_e(e),r=l.useRef(!1);return l.useEffect(()=>{const o=s=>{s.target&&!r.current&&Jo(fu,n,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Zo(){const e=new CustomEvent(Bn);document.dispatchEvent(e)}function Jo(e,t,n,{discrete:r}){const o=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?Bo(o,s):o.dispatchEvent(s)}var Un="focusScope.autoFocusOnMount",Kn="focusScope.autoFocusOnUnmount",Qo={bubbles:!1,cancelable:!0},vu="FocusScope",Yn=l.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:s,...a}=e,[i,c]=l.useState(null),p=_e(o),d=_e(s),f=l.useRef(null),m=ie(t,g=>c(g)),h=l.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;l.useEffect(()=>{if(r){let g=function(E){if(h.paused||!i)return;const S=E.target;i.contains(S)?f.current=S:We(f.current,{select:!0})},w=function(E){if(h.paused||!i)return;const S=E.relatedTarget;S!==null&&(i.contains(S)||We(f.current,{select:!0}))},v=function(E){if(document.activeElement===document.body)for(const _ of E)_.removedNodes.length>0&&We(i)};document.addEventListener("focusin",g),document.addEventListener("focusout",w);const x=new MutationObserver(v);return i&&x.observe(i,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",w),x.disconnect()}}},[r,i,h.paused]),l.useEffect(()=>{if(i){ns.add(h);const g=document.activeElement;if(!i.contains(g)){const v=new CustomEvent(Un,Qo);i.addEventListener(Un,p),i.dispatchEvent(v),v.defaultPrevented||(bu(Eu(es(i)),{select:!0}),document.activeElement===g&&We(i))}return()=>{i.removeEventListener(Un,p),setTimeout(()=>{const v=new CustomEvent(Kn,Qo);i.addEventListener(Kn,d),i.dispatchEvent(v),v.defaultPrevented||We(g??document.body,{select:!0}),i.removeEventListener(Kn,d),ns.remove(h)},0)}}},[i,p,d,h]);const b=l.useCallback(g=>{if(!n&&!r||h.paused)return;const w=g.key==="Tab"&&!g.altKey&&!g.ctrlKey&&!g.metaKey,v=document.activeElement;if(w&&v){const x=g.currentTarget,[E,S]=wu(x);E&&S?!g.shiftKey&&v===S?(g.preventDefault(),n&&We(E,{select:!0})):g.shiftKey&&v===E&&(g.preventDefault(),n&&We(S,{select:!0})):v===x&&g.preventDefault()}},[n,r,h.paused]);return u.jsx(re.div,{tabIndex:-1,...a,ref:m,onKeyDown:b})});Yn.displayName=vu;function bu(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(We(r,{select:t}),document.activeElement!==n)return}function wu(e){const t=es(e),n=ts(t,e),r=ts(t.reverse(),e);return[n,r]}function es(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function ts(e,t){for(const n of e)if(!xu(n,{upTo:t}))return n}function xu(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function yu(e){return e instanceof HTMLInputElement&&"select"in e}function We(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&yu(e)&&t&&e.select()}}var ns=Cu();function Cu(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=rs(e,t),e.unshift(t)},remove(t){var n;e=rs(e,t),(n=e[0])==null||n.resume()}}}function rs(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Eu(e){return e.filter(t=>t.tagName!=="A")}var Su="Portal",qn=l.forwardRef((e,t)=>{var i;const{container:n,...r}=e,[o,s]=l.useState(!1);ze(()=>s(!0),[]);const a=n||o&&((i=globalThis==null?void 0:globalThis.document)==null?void 0:i.body);return a?Br.createPortal(u.jsx(re.div,{...r,ref:t}),a):null});qn.displayName=Su;function _u(e,t){return l.useReducer((n,r)=>t[n][r]??n,e)}var Ie=e=>{const{present:t,children:n}=e,r=Ru(t),o=typeof n=="function"?n({present:r.isPresent}):l.Children.only(n),s=ie(r.ref,Mu(o));return typeof n=="function"||r.isPresent?l.cloneElement(o,{ref:s}):null};Ie.displayName="Presence";function Ru(e){const[t,n]=l.useState(),r=l.useRef(null),o=l.useRef(e),s=l.useRef("none"),a=e?"mounted":"unmounted",[i,c]=_u(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return l.useEffect(()=>{const p=Bt(r.current);s.current=i==="mounted"?p:"none"},[i]),ze(()=>{const p=r.current,d=o.current;if(d!==e){const m=s.current,h=Bt(p);e?c("MOUNT"):h==="none"||(p==null?void 0:p.display)==="none"?c("UNMOUNT"):c(d&&m!==h?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,c]),ze(()=>{if(t){let p;const d=t.ownerDocument.defaultView??window,f=h=>{const g=Bt(r.current).includes(h.animationName);if(h.target===t&&g&&(c("ANIMATION_END"),!o.current)){const w=t.style.animationFillMode;t.style.animationFillMode="forwards",p=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=w)})}},m=h=>{h.target===t&&(s.current=Bt(r.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{d.clearTimeout(p),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(i),ref:l.useCallback(p=>{r.current=p?getComputedStyle(p):null,n(p)},[])}}function Bt(e){return(e==null?void 0:e.animationName)||"none"}function Mu(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Xn=0;function os(){l.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??ss()),document.body.insertAdjacentElement("beforeend",e[1]??ss()),Xn++,()=>{Xn===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Xn--}},[])}function ss(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var Re=function(){return Re=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},Re.apply(this,arguments)};function as(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function Au(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,s;r<o;r++)(s||!(r in t))&&(s||(s=Array.prototype.slice.call(t,0,r)),s[r]=t[r]);return e.concat(s||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var Ut="right-scroll-bar-position",Kt="width-before-scroll-bar",Tu="with-scroll-bars-hidden",Nu="--removed-body-scroll-bar-size";function Zn(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function ku(e,t){var n=I.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}var Ou=typeof window<"u"?l.useLayoutEffect:l.useEffect,is=new WeakMap;function Pu(e,t){var n=ku(null,function(r){return e.forEach(function(o){return Zn(o,r)})});return Ou(function(){var r=is.get(n);if(r){var o=new Set(r),s=new Set(e),a=n.current;o.forEach(function(i){s.has(i)||Zn(i,null)}),s.forEach(function(i){o.has(i)||Zn(i,a)})}is.set(n,e)},[e]),n}function Du(e){return e}function Iu(e,t){t===void 0&&(t=Du);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(s){var a=t(s,r);return n.push(a),function(){n=n.filter(function(i){return i!==a})}},assignSyncMedium:function(s){for(r=!0;n.length;){var a=n;n=[],a.forEach(s)}n={push:function(i){return s(i)},filter:function(){return n}}},assignMedium:function(s){r=!0;var a=[];if(n.length){var i=n;n=[],i.forEach(s),a=n}var c=function(){var d=a;a=[],d.forEach(s)},p=function(){return Promise.resolve().then(c)};p(),n={push:function(d){a.push(d),p()},filter:function(d){return a=a.filter(d),n}}}};return o}function ju(e){e===void 0&&(e={});var t=Iu(null);return t.options=Re({async:!0,ssr:!1},e),t}var cs=function(e){var t=e.sideCar,n=as(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return l.createElement(r,Re({},n))};cs.isSideCarExport=!0;function Lu(e,t){return e.useMedium(t),cs}var ls=ju(),Jn=function(){},Yt=l.forwardRef(function(e,t){var n=l.useRef(null),r=l.useState({onScrollCapture:Jn,onWheelCapture:Jn,onTouchMoveCapture:Jn}),o=r[0],s=r[1],a=e.forwardProps,i=e.children,c=e.className,p=e.removeScrollBar,d=e.enabled,f=e.shards,m=e.sideCar,h=e.noRelative,b=e.noIsolation,g=e.inert,w=e.allowPinchZoom,v=e.as,x=v===void 0?"div":v,E=e.gapMode,S=as(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),_=m,T=Pu([n,t]),M=Re(Re({},S),o);return l.createElement(l.Fragment,null,d&&l.createElement(_,{sideCar:ls,removeScrollBar:p,shards:f,noRelative:h,noIsolation:b,inert:g,setCallbacks:s,allowPinchZoom:!!w,lockRef:n,gapMode:E}),a?l.cloneElement(l.Children.only(i),Re(Re({},M),{ref:T})):l.createElement(x,Re({},M,{className:c,ref:T}),i))});Yt.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},Yt.classNames={fullWidth:Kt,zeroRight:Ut};var Fu=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function $u(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Fu();return t&&e.setAttribute("nonce",t),e}function Vu(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Hu(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var zu=function(){var e=0,t=null;return{add:function(n){e==0&&(t=$u())&&(Vu(t,n),Hu(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Wu=function(){var e=zu();return function(t,n){l.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},us=function(){var e=Wu(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},Gu={left:0,top:0,right:0,gap:0},Qn=function(e){return parseInt(e||"",10)||0},Bu=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[Qn(n),Qn(r),Qn(o)]},Uu=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Gu;var t=Bu(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},Ku=us(),st="data-scroll-locked",Yu=function(e,t,n,r){var o=e.left,s=e.top,a=e.right,i=e.gap;return n===void 0&&(n="margin"),`
139
+ .`.concat(Tu,` {
140
140
  overflow: hidden `).concat(r,`;
141
141
  padding-right: `).concat(i,"px ").concat(r,`;
142
142
  }
143
- body[`).concat(at,`] {
143
+ body[`).concat(st,`] {
144
144
  overflow: hidden `).concat(r,`;
145
145
  overscroll-behavior: contain;
146
146
  `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
147
147
  padding-left: `.concat(o,`px;
148
- padding-top: `).concat(a,`px;
149
- padding-right: `).concat(s,`px;
148
+ padding-top: `).concat(s,`px;
149
+ padding-right: `).concat(a,`px;
150
150
  margin-left:0;
151
151
  margin-top:0;
152
152
  margin-right: `).concat(i,"px ").concat(r,`;
@@ -169,14 +169,14 @@ React keys must be passed directly to JSX without using spread:
169
169
  margin-right: 0 `).concat(r,`;
170
170
  }
171
171
 
172
- body[`).concat(at,`] {
173
- `).concat(Au,": ").concat(i,`px;
172
+ body[`).concat(st,`] {
173
+ `).concat(Nu,": ").concat(i,`px;
174
174
  }
175
- `)},da=function(){var e=parseInt(document.body.getAttribute(at)||"0",10);return isFinite(e)?e:0},Ku=function(){l.useEffect(function(){return document.body.setAttribute(at,(da()+1).toString()),function(){var e=da()-1;e<=0?document.body.removeAttribute(at):document.body.setAttribute(at,e.toString())}},[])},Yu=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r;Ku();var a=l.useMemo(function(){return Gu(o)},[o]);return l.createElement(Bu,{styles:Uu(a,!t,o,n?"":"!important")})},er=!1;if(typeof window<"u")try{var qt=Object.defineProperty({},"passive",{get:function(){return er=!0,!0}});window.addEventListener("test",qt,qt),window.removeEventListener("test",qt,qt)}catch{er=!1}var st=er?{passive:!1}:!1,qu=function(e){return e.tagName==="TEXTAREA"},fa=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!qu(e)&&n[t]==="visible")},Xu=function(e){return fa(e,"overflowY")},Zu=function(e){return fa(e,"overflowX")},pa=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var o=ma(e,r);if(o){var a=ha(e,r),s=a[1],i=a[2];if(s>i)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},Ju=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},Qu=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},ma=function(e,t){return e==="v"?Xu(t):Zu(t)},ha=function(e,t){return e==="v"?Ju(t):Qu(t)},ed=function(e,t){return e==="h"&&t==="rtl"?-1:1},td=function(e,t,n,r,o){var a=ed(e,window.getComputedStyle(t).direction),s=a*r,i=n.target,c=t.contains(i),p=!1,d=s>0,f=0,m=0;do{if(!i)break;var h=ha(e,i),b=h[0],g=h[1],x=h[2],v=g-x-a*b;(b||v)&&ma(e,i)&&(f+=v,m+=b);var w=i.parentNode;i=w&&w.nodeType===Node.DOCUMENT_FRAGMENT_NODE?w.host:w}while(!c&&i!==document.body||c&&(t.contains(i)||t===i));return(d&&Math.abs(f)<1||!d&&Math.abs(m)<1)&&(p=!0),p},Xt=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},ga=function(e){return[e.deltaX,e.deltaY]},va=function(e){return e&&"current"in e?e.current:e},nd=function(e,t){return e[0]===t[0]&&e[1]===t[1]},rd=function(e){return`
175
+ `)},ds=function(){var e=parseInt(document.body.getAttribute(st)||"0",10);return isFinite(e)?e:0},qu=function(){l.useEffect(function(){return document.body.setAttribute(st,(ds()+1).toString()),function(){var e=ds()-1;e<=0?document.body.removeAttribute(st):document.body.setAttribute(st,e.toString())}},[])},Xu=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r;qu();var s=l.useMemo(function(){return Uu(o)},[o]);return l.createElement(Ku,{styles:Yu(s,!t,o,n?"":"!important")})},er=!1;if(typeof window<"u")try{var qt=Object.defineProperty({},"passive",{get:function(){return er=!0,!0}});window.addEventListener("test",qt,qt),window.removeEventListener("test",qt,qt)}catch{er=!1}var at=er?{passive:!1}:!1,Zu=function(e){return e.tagName==="TEXTAREA"},fs=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!Zu(e)&&n[t]==="visible")},Ju=function(e){return fs(e,"overflowY")},Qu=function(e){return fs(e,"overflowX")},ps=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var o=ms(e,r);if(o){var s=hs(e,r),a=s[1],i=s[2];if(a>i)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},ed=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},td=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},ms=function(e,t){return e==="v"?Ju(t):Qu(t)},hs=function(e,t){return e==="v"?ed(t):td(t)},nd=function(e,t){return e==="h"&&t==="rtl"?-1:1},rd=function(e,t,n,r,o){var s=nd(e,window.getComputedStyle(t).direction),a=s*r,i=n.target,c=t.contains(i),p=!1,d=a>0,f=0,m=0;do{if(!i)break;var h=hs(e,i),b=h[0],g=h[1],w=h[2],v=g-w-s*b;(b||v)&&ms(e,i)&&(f+=v,m+=b);var x=i.parentNode;i=x&&x.nodeType===Node.DOCUMENT_FRAGMENT_NODE?x.host:x}while(!c&&i!==document.body||c&&(t.contains(i)||t===i));return(d&&Math.abs(f)<1||!d&&Math.abs(m)<1)&&(p=!0),p},Xt=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},gs=function(e){return[e.deltaX,e.deltaY]},vs=function(e){return e&&"current"in e?e.current:e},od=function(e,t){return e[0]===t[0]&&e[1]===t[1]},sd=function(e){return`
176
176
  .block-interactivity-`.concat(e,` {pointer-events: none;}
177
177
  .allow-interactivity-`).concat(e,` {pointer-events: all;}
178
- `)},od=0,it=[];function ad(e){var t=l.useRef([]),n=l.useRef([0,0]),r=l.useRef(),o=l.useState(od++)[0],a=l.useState(ua)[0],s=l.useRef(e);l.useEffect(function(){s.current=e},[e]),l.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var g=Ru([e.lockRef.current],(e.shards||[]).map(va),!0).filter(Boolean);return g.forEach(function(x){return x.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),g.forEach(function(x){return x.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var i=l.useCallback(function(g,x){if("touches"in g&&g.touches.length===2||g.type==="wheel"&&g.ctrlKey)return!s.current.allowPinchZoom;var v=Xt(g),w=n.current,E="deltaX"in g?g.deltaX:w[0]-v[0],S="deltaY"in g?g.deltaY:w[1]-v[1],_,T=g.target,M=Math.abs(E)>Math.abs(S)?"h":"v";if("touches"in g&&M==="h"&&T.type==="range")return!1;var C=pa(M,T);if(!C)return!0;if(C?_=M:(_=M==="v"?"h":"v",C=pa(M,T)),!C)return!1;if(!r.current&&"changedTouches"in g&&(E||S)&&(r.current=_),!_)return!0;var j=r.current||_;return td(j,x,g,j==="h"?E:S)},[]),c=l.useCallback(function(g){var x=g;if(!(!it.length||it[it.length-1]!==a)){var v="deltaY"in x?ga(x):Xt(x),w=t.current.filter(function(_){return _.name===x.type&&(_.target===x.target||x.target===_.shadowParent)&&nd(_.delta,v)})[0];if(w&&w.should){x.cancelable&&x.preventDefault();return}if(!w){var E=(s.current.shards||[]).map(va).filter(Boolean).filter(function(_){return _.contains(x.target)}),S=E.length>0?i(x,E[0]):!s.current.noIsolation;S&&x.cancelable&&x.preventDefault()}}},[]),p=l.useCallback(function(g,x,v,w){var E={name:g,delta:x,target:v,should:w,shadowParent:sd(v)};t.current.push(E),setTimeout(function(){t.current=t.current.filter(function(S){return S!==E})},1)},[]),d=l.useCallback(function(g){n.current=Xt(g),r.current=void 0},[]),f=l.useCallback(function(g){p(g.type,ga(g),g.target,i(g,e.lockRef.current))},[]),m=l.useCallback(function(g){p(g.type,Xt(g),g.target,i(g,e.lockRef.current))},[]);l.useEffect(function(){return it.push(a),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:m}),document.addEventListener("wheel",c,st),document.addEventListener("touchmove",c,st),document.addEventListener("touchstart",d,st),function(){it=it.filter(function(g){return g!==a}),document.removeEventListener("wheel",c,st),document.removeEventListener("touchmove",c,st),document.removeEventListener("touchstart",d,st)}},[]);var h=e.removeScrollBar,b=e.inert;return l.createElement(l.Fragment,null,b?l.createElement(a,{styles:rd(o)}):null,h?l.createElement(Yu,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function sd(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const id=Iu(la,ad);var tr=l.forwardRef(function(e,t){return l.createElement(Yt,Re({},e,{ref:t,sideCar:id}))});tr.classNames=Yt.classNames;var cd=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},ct=new WeakMap,Zt=new WeakMap,Jt={},nr=0,ba=function(e){return e&&(e.host||ba(e.parentNode))},ld=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=ba(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},ud=function(e,t,n,r){var o=ld(t,Array.isArray(e)?e:[e]);Jt[n]||(Jt[n]=new WeakMap);var a=Jt[n],s=[],i=new Set,c=new Set(o),p=function(f){!f||i.has(f)||(i.add(f),p(f.parentNode))};o.forEach(p);var d=function(f){!f||c.has(f)||Array.prototype.forEach.call(f.children,function(m){if(i.has(m))d(m);else try{var h=m.getAttribute(r),b=h!==null&&h!=="false",g=(ct.get(m)||0)+1,x=(a.get(m)||0)+1;ct.set(m,g),a.set(m,x),s.push(m),g===1&&b&&Zt.set(m,!0),x===1&&m.setAttribute(n,"true"),b||m.setAttribute(r,"true")}catch(v){console.error("aria-hidden: cannot operate on ",m,v)}})};return d(t),i.clear(),nr++,function(){s.forEach(function(f){var m=ct.get(f)-1,h=a.get(f)-1;ct.set(f,m),a.set(f,h),m||(Zt.has(f)||f.removeAttribute(r),Zt.delete(f)),h||f.removeAttribute(n)}),nr--,nr||(ct=new WeakMap,ct=new WeakMap,Zt=new WeakMap,Jt={})}},xa=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=cd(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live], script"))),ud(r,o,n,"aria-hidden")):function(){return null}},Qt="Dialog",[wa,O0]=Xe(Qt),[dd,ye]=wa(Qt),ya=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:a,modal:s=!0}=e,i=l.useRef(null),c=l.useRef(null),[p,d]=xt({prop:r,defaultProp:o??!1,onChange:a,caller:Qt});return u.jsx(dd,{scope:t,triggerRef:i,contentRef:c,contentId:De(),titleId:De(),descriptionId:De(),open:p,onOpenChange:d,onOpenToggle:l.useCallback(()=>d(f=>!f),[d]),modal:s,children:n})};ya.displayName=Qt;var Ca="DialogTrigger",Ea=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(Ca,n),a=ie(t,o.triggerRef);return u.jsx(re.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":ar(o.open),...r,ref:a,onClick:$(e.onClick,o.onOpenToggle)})});Ea.displayName=Ca;var rr="DialogPortal",[fd,Sa]=wa(rr,{forceMount:void 0}),_a=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,a=ye(rr,t);return u.jsx(fd,{scope:t,forceMount:n,children:l.Children.map(r,s=>u.jsx(Ie,{present:n||a.open,children:u.jsx(qn,{asChild:!0,container:o,children:s})}))})};_a.displayName=rr;var en="DialogOverlay",Ra=l.forwardRef((e,t)=>{const n=Sa(en,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,a=ye(en,e.__scopeDialog);return a.modal?u.jsx(Ie,{present:r||a.open,children:u.jsx(md,{...o,ref:t})}):null});Ra.displayName=en;var pd=et("DialogOverlay.RemoveScroll"),md=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(en,n);return u.jsx(tr,{as:pd,allowPinchZoom:!0,shards:[o.contentRef],children:u.jsx(re.div,{"data-state":ar(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),Ze="DialogContent",Ma=l.forwardRef((e,t)=>{const n=Sa(Ze,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,a=ye(Ze,e.__scopeDialog);return u.jsx(Ie,{present:r||a.open,children:a.modal?u.jsx(hd,{...o,ref:t}):u.jsx(gd,{...o,ref:t})})});Ma.displayName=Ze;var hd=l.forwardRef((e,t)=>{const n=ye(Ze,e.__scopeDialog),r=l.useRef(null),o=ie(t,n.contentRef,r);return l.useEffect(()=>{const a=r.current;if(a)return xa(a)},[]),u.jsx(Aa,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:$(e.onCloseAutoFocus,a=>{var s;a.preventDefault(),(s=n.triggerRef.current)==null||s.focus()}),onPointerDownOutside:$(e.onPointerDownOutside,a=>{const s=a.detail.originalEvent,i=s.button===0&&s.ctrlKey===!0;(s.button===2||i)&&a.preventDefault()}),onFocusOutside:$(e.onFocusOutside,a=>a.preventDefault())})}),gd=l.forwardRef((e,t)=>{const n=ye(Ze,e.__scopeDialog),r=l.useRef(!1),o=l.useRef(!1);return u.jsx(Aa,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var s,i;(s=e.onCloseAutoFocus)==null||s.call(e,a),a.defaultPrevented||(r.current||(i=n.triggerRef.current)==null||i.focus(),a.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:a=>{var c,p;(c=e.onInteractOutside)==null||c.call(e,a),a.defaultPrevented||(r.current=!0,a.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const s=a.target;((p=n.triggerRef.current)==null?void 0:p.contains(s))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&o.current&&a.preventDefault()}})}),Aa=l.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:a,...s}=e,i=ye(Ze,n),c=l.useRef(null),p=ie(t,c);return oa(),u.jsxs(u.Fragment,{children:[u.jsx(Yn,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:a,children:u.jsx(Gt,{role:"dialog",id:i.contentId,"aria-describedby":i.descriptionId,"aria-labelledby":i.titleId,"data-state":ar(i.open),...s,ref:p,onDismiss:()=>i.onOpenChange(!1)})}),u.jsxs(u.Fragment,{children:[u.jsx(vd,{titleId:i.titleId}),u.jsx(xd,{contentRef:c,descriptionId:i.descriptionId})]})]})}),or="DialogTitle",Ta=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(or,n);return u.jsx(re.h2,{id:o.titleId,...r,ref:t})});Ta.displayName=or;var Na="DialogDescription",ka=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(Na,n);return u.jsx(re.p,{id:o.descriptionId,...r,ref:t})});ka.displayName=Na;var Oa="DialogClose",Pa=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(Oa,n);return u.jsx(re.button,{type:"button",...r,ref:t,onClick:$(e.onClick,()=>o.onOpenChange(!1))})});Pa.displayName=Oa;function ar(e){return e?"open":"closed"}var Da="DialogTitleWarning",[P0,Ia]=eu(Da,{contentName:Ze,titleName:or,docsSlug:"dialog"}),vd=({titleId:e})=>{const t=Ia(Da),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
178
+ `)},ad=0,it=[];function id(e){var t=l.useRef([]),n=l.useRef([0,0]),r=l.useRef(),o=l.useState(ad++)[0],s=l.useState(us)[0],a=l.useRef(e);l.useEffect(function(){a.current=e},[e]),l.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var g=Au([e.lockRef.current],(e.shards||[]).map(vs),!0).filter(Boolean);return g.forEach(function(w){return w.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),g.forEach(function(w){return w.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var i=l.useCallback(function(g,w){if("touches"in g&&g.touches.length===2||g.type==="wheel"&&g.ctrlKey)return!a.current.allowPinchZoom;var v=Xt(g),x=n.current,E="deltaX"in g?g.deltaX:x[0]-v[0],S="deltaY"in g?g.deltaY:x[1]-v[1],_,T=g.target,M=Math.abs(E)>Math.abs(S)?"h":"v";if("touches"in g&&M==="h"&&T.type==="range")return!1;var C=ps(M,T);if(!C)return!0;if(C?_=M:(_=M==="v"?"h":"v",C=ps(M,T)),!C)return!1;if(!r.current&&"changedTouches"in g&&(E||S)&&(r.current=_),!_)return!0;var j=r.current||_;return rd(j,w,g,j==="h"?E:S)},[]),c=l.useCallback(function(g){var w=g;if(!(!it.length||it[it.length-1]!==s)){var v="deltaY"in w?gs(w):Xt(w),x=t.current.filter(function(_){return _.name===w.type&&(_.target===w.target||w.target===_.shadowParent)&&od(_.delta,v)})[0];if(x&&x.should){w.cancelable&&w.preventDefault();return}if(!x){var E=(a.current.shards||[]).map(vs).filter(Boolean).filter(function(_){return _.contains(w.target)}),S=E.length>0?i(w,E[0]):!a.current.noIsolation;S&&w.cancelable&&w.preventDefault()}}},[]),p=l.useCallback(function(g,w,v,x){var E={name:g,delta:w,target:v,should:x,shadowParent:cd(v)};t.current.push(E),setTimeout(function(){t.current=t.current.filter(function(S){return S!==E})},1)},[]),d=l.useCallback(function(g){n.current=Xt(g),r.current=void 0},[]),f=l.useCallback(function(g){p(g.type,gs(g),g.target,i(g,e.lockRef.current))},[]),m=l.useCallback(function(g){p(g.type,Xt(g),g.target,i(g,e.lockRef.current))},[]);l.useEffect(function(){return it.push(s),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:m}),document.addEventListener("wheel",c,at),document.addEventListener("touchmove",c,at),document.addEventListener("touchstart",d,at),function(){it=it.filter(function(g){return g!==s}),document.removeEventListener("wheel",c,at),document.removeEventListener("touchmove",c,at),document.removeEventListener("touchstart",d,at)}},[]);var h=e.removeScrollBar,b=e.inert;return l.createElement(l.Fragment,null,b?l.createElement(s,{styles:sd(o)}):null,h?l.createElement(Xu,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function cd(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const ld=Lu(ls,id);var tr=l.forwardRef(function(e,t){return l.createElement(Yt,Re({},e,{ref:t,sideCar:ld}))});tr.classNames=Yt.classNames;var ud=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},ct=new WeakMap,Zt=new WeakMap,Jt={},nr=0,bs=function(e){return e&&(e.host||bs(e.parentNode))},dd=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=bs(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},fd=function(e,t,n,r){var o=dd(t,Array.isArray(e)?e:[e]);Jt[n]||(Jt[n]=new WeakMap);var s=Jt[n],a=[],i=new Set,c=new Set(o),p=function(f){!f||i.has(f)||(i.add(f),p(f.parentNode))};o.forEach(p);var d=function(f){!f||c.has(f)||Array.prototype.forEach.call(f.children,function(m){if(i.has(m))d(m);else try{var h=m.getAttribute(r),b=h!==null&&h!=="false",g=(ct.get(m)||0)+1,w=(s.get(m)||0)+1;ct.set(m,g),s.set(m,w),a.push(m),g===1&&b&&Zt.set(m,!0),w===1&&m.setAttribute(n,"true"),b||m.setAttribute(r,"true")}catch(v){console.error("aria-hidden: cannot operate on ",m,v)}})};return d(t),i.clear(),nr++,function(){a.forEach(function(f){var m=ct.get(f)-1,h=s.get(f)-1;ct.set(f,m),s.set(f,h),m||(Zt.has(f)||f.removeAttribute(r),Zt.delete(f)),h||f.removeAttribute(n)}),nr--,nr||(ct=new WeakMap,ct=new WeakMap,Zt=new WeakMap,Jt={})}},ws=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=ud(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live], script"))),fd(r,o,n,"aria-hidden")):function(){return null}},Qt="Dialog",[xs,P0]=Xe(Qt),[pd,ye]=xs(Qt),ys=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:s,modal:a=!0}=e,i=l.useRef(null),c=l.useRef(null),[p,d]=wt({prop:r,defaultProp:o??!1,onChange:s,caller:Qt});return u.jsx(pd,{scope:t,triggerRef:i,contentRef:c,contentId:De(),titleId:De(),descriptionId:De(),open:p,onOpenChange:d,onOpenToggle:l.useCallback(()=>d(f=>!f),[d]),modal:a,children:n})};ys.displayName=Qt;var Cs="DialogTrigger",Es=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(Cs,n),s=ie(t,o.triggerRef);return u.jsx(re.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":sr(o.open),...r,ref:s,onClick:$(e.onClick,o.onOpenToggle)})});Es.displayName=Cs;var rr="DialogPortal",[md,Ss]=xs(rr,{forceMount:void 0}),_s=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,s=ye(rr,t);return u.jsx(md,{scope:t,forceMount:n,children:l.Children.map(r,a=>u.jsx(Ie,{present:n||s.open,children:u.jsx(qn,{asChild:!0,container:o,children:a})}))})};_s.displayName=rr;var en="DialogOverlay",Rs=l.forwardRef((e,t)=>{const n=Ss(en,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=ye(en,e.__scopeDialog);return s.modal?u.jsx(Ie,{present:r||s.open,children:u.jsx(gd,{...o,ref:t})}):null});Rs.displayName=en;var hd=et("DialogOverlay.RemoveScroll"),gd=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(en,n);return u.jsx(tr,{as:hd,allowPinchZoom:!0,shards:[o.contentRef],children:u.jsx(re.div,{"data-state":sr(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),Ze="DialogContent",Ms=l.forwardRef((e,t)=>{const n=Ss(Ze,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=ye(Ze,e.__scopeDialog);return u.jsx(Ie,{present:r||s.open,children:s.modal?u.jsx(vd,{...o,ref:t}):u.jsx(bd,{...o,ref:t})})});Ms.displayName=Ze;var vd=l.forwardRef((e,t)=>{const n=ye(Ze,e.__scopeDialog),r=l.useRef(null),o=ie(t,n.contentRef,r);return l.useEffect(()=>{const s=r.current;if(s)return ws(s)},[]),u.jsx(As,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:$(e.onCloseAutoFocus,s=>{var a;s.preventDefault(),(a=n.triggerRef.current)==null||a.focus()}),onPointerDownOutside:$(e.onPointerDownOutside,s=>{const a=s.detail.originalEvent,i=a.button===0&&a.ctrlKey===!0;(a.button===2||i)&&s.preventDefault()}),onFocusOutside:$(e.onFocusOutside,s=>s.preventDefault())})}),bd=l.forwardRef((e,t)=>{const n=ye(Ze,e.__scopeDialog),r=l.useRef(!1),o=l.useRef(!1);return u.jsx(As,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var a,i;(a=e.onCloseAutoFocus)==null||a.call(e,s),s.defaultPrevented||(r.current||(i=n.triggerRef.current)==null||i.focus(),s.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:s=>{var c,p;(c=e.onInteractOutside)==null||c.call(e,s),s.defaultPrevented||(r.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const a=s.target;((p=n.triggerRef.current)==null?void 0:p.contains(a))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),As=l.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:s,...a}=e,i=ye(Ze,n),c=l.useRef(null),p=ie(t,c);return os(),u.jsxs(u.Fragment,{children:[u.jsx(Yn,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:s,children:u.jsx(Gt,{role:"dialog",id:i.contentId,"aria-describedby":i.descriptionId,"aria-labelledby":i.titleId,"data-state":sr(i.open),...a,ref:p,onDismiss:()=>i.onOpenChange(!1)})}),u.jsxs(u.Fragment,{children:[u.jsx(wd,{titleId:i.titleId}),u.jsx(yd,{contentRef:c,descriptionId:i.descriptionId})]})]})}),or="DialogTitle",Ts=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(or,n);return u.jsx(re.h2,{id:o.titleId,...r,ref:t})});Ts.displayName=or;var Ns="DialogDescription",ks=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(Ns,n);return u.jsx(re.p,{id:o.descriptionId,...r,ref:t})});ks.displayName=Ns;var Os="DialogClose",Ps=l.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(Os,n);return u.jsx(re.button,{type:"button",...r,ref:t,onClick:$(e.onClick,()=>o.onOpenChange(!1))})});Ps.displayName=Os;function sr(e){return e?"open":"closed"}var Ds="DialogTitleWarning",[D0,Is]=nu(Ds,{contentName:Ze,titleName:or,docsSlug:"dialog"}),wd=({titleId:e})=>{const t=Is(Ds),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
179
179
 
180
180
  If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
181
181
 
182
- For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return l.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},bd="DialogDescriptionWarning",xd=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${Ia(bd).contentName}}.`;return l.useEffect(()=>{var a;const o=(a=e.current)==null?void 0:a.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},wd=ya,yd=Ea,Cd=_a,ja=Ra,La=Ma,Fa=Ta,$a=ka,Va=Pa;const Ha=wd,Ed=yd,Sd=Va,za=Cd,sr=l.forwardRef(({className:e,...t},n)=>u.jsx(ja,{className:D("fixed inset-0 z-50 bg-background/80 backdrop-blur-sm data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:n}));sr.displayName=ja.displayName;const _d=Ln("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),ir=l.forwardRef(({side:e="right",className:t,children:n,...r},o)=>u.jsxs(za,{children:[u.jsx(sr,{}),u.jsxs(La,{ref:o,className:D(_d({side:e}),t),...r,children:[n,u.jsxs(Va,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary",children:[u.jsx(rl,{className:"h-4 w-4"}),u.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));ir.displayName=La.displayName;const cr=({className:e,...t})=>u.jsx("div",{className:D("flex flex-col space-y-2 text-center sm:text-left",e),...t});cr.displayName="SheetHeader";const Wa=({className:e,...t})=>u.jsx("div",{className:D("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});Wa.displayName="SheetFooter";const lr=l.forwardRef(({className:e,...t},n)=>u.jsx(Fa,{ref:n,className:D("text-lg font-semibold text-foreground",e),...t}));lr.displayName=Fa.displayName;const ur=l.forwardRef(({className:e,...t},n)=>u.jsx($a,{ref:n,className:D("text-sm text-muted-foreground",e),...t}));ur.displayName=$a.displayName;function dr({className:e,...t}){return u.jsx("div",{className:D("animate-pulse rounded-md bg-muted",e),...t})}const Rd=["top","right","bottom","left"],Ge=Math.min,he=Math.max,tn=Math.round,nn=Math.floor,Me=e=>({x:e,y:e}),Md={left:"right",right:"left",bottom:"top",top:"bottom"},Ad={start:"end",end:"start"};function fr(e,t,n){return he(e,Ge(t,n))}function je(e,t){return typeof e=="function"?e(t):e}function Le(e){return e.split("-")[0]}function lt(e){return e.split("-")[1]}function pr(e){return e==="x"?"y":"x"}function mr(e){return e==="y"?"height":"width"}function Ae(e){return["top","bottom"].includes(Le(e))?"y":"x"}function hr(e){return pr(Ae(e))}function Td(e,t,n){n===void 0&&(n=!1);const r=lt(e),o=hr(e),a=mr(o);let s=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(s=rn(s)),[s,rn(s)]}function Nd(e){const t=rn(e);return[gr(e),t,gr(t)]}function gr(e){return e.replace(/start|end/g,t=>Ad[t])}function kd(e,t,n){const r=["left","right"],o=["right","left"],a=["top","bottom"],s=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?a:s;default:return[]}}function Od(e,t,n,r){const o=lt(e);let a=kd(Le(e),n==="start",r);return o&&(a=a.map(s=>s+"-"+o),t&&(a=a.concat(a.map(gr)))),a}function rn(e){return e.replace(/left|right|bottom|top/g,t=>Md[t])}function Pd(e){return{top:0,right:0,bottom:0,left:0,...e}}function Ga(e){return typeof e!="number"?Pd(e):{top:e,right:e,bottom:e,left:e}}function on(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function Ba(e,t,n){let{reference:r,floating:o}=e;const a=Ae(t),s=hr(t),i=mr(s),c=Le(t),p=a==="y",d=r.x+r.width/2-o.width/2,f=r.y+r.height/2-o.height/2,m=r[i]/2-o[i]/2;let h;switch(c){case"top":h={x:d,y:r.y-o.height};break;case"bottom":h={x:d,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:f};break;case"left":h={x:r.x-o.width,y:f};break;default:h={x:r.x,y:r.y}}switch(lt(t)){case"start":h[s]-=m*(n&&p?-1:1);break;case"end":h[s]+=m*(n&&p?-1:1);break}return h}const Dd=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:s}=n,i=a.filter(Boolean),c=await(s.isRTL==null?void 0:s.isRTL(t));let p=await s.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:f}=Ba(p,r,c),m=r,h={},b=0;for(let g=0;g<i.length;g++){const{name:x,fn:v}=i[g],{x:w,y:E,data:S,reset:_}=await v({x:d,y:f,initialPlacement:r,placement:m,strategy:o,middlewareData:h,rects:p,platform:s,elements:{reference:e,floating:t}});d=w??d,f=E??f,h={...h,[x]:{...h[x],...S}},_&&b<=50&&(b++,typeof _=="object"&&(_.placement&&(m=_.placement),_.rects&&(p=_.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:o}):_.rects),{x:d,y:f}=Ba(p,m,c)),g=-1)}return{x:d,y:f,placement:m,strategy:o,middlewareData:h}};async function wt(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:a,rects:s,elements:i,strategy:c}=e,{boundary:p="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:m=!1,padding:h=0}=je(t,e),b=Ga(h),x=i[m?f==="floating"?"reference":"floating":f],v=on(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(x)))==null||n?x:x.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(i.floating)),boundary:p,rootBoundary:d,strategy:c})),w=f==="floating"?{x:r,y:o,width:s.floating.width,height:s.floating.height}:s.reference,E=await(a.getOffsetParent==null?void 0:a.getOffsetParent(i.floating)),S=await(a.isElement==null?void 0:a.isElement(E))?await(a.getScale==null?void 0:a.getScale(E))||{x:1,y:1}:{x:1,y:1},_=on(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:i,rect:w,offsetParent:E,strategy:c}):w);return{top:(v.top-_.top+b.top)/S.y,bottom:(_.bottom-v.bottom+b.bottom)/S.y,left:(v.left-_.left+b.left)/S.x,right:(_.right-v.right+b.right)/S.x}}const Id=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:a,platform:s,elements:i,middlewareData:c}=t,{element:p,padding:d=0}=je(e,t)||{};if(p==null)return{};const f=Ga(d),m={x:n,y:r},h=hr(o),b=mr(h),g=await s.getDimensions(p),x=h==="y",v=x?"top":"left",w=x?"bottom":"right",E=x?"clientHeight":"clientWidth",S=a.reference[b]+a.reference[h]-m[h]-a.floating[b],_=m[h]-a.reference[h],T=await(s.getOffsetParent==null?void 0:s.getOffsetParent(p));let M=T?T[E]:0;(!M||!await(s.isElement==null?void 0:s.isElement(T)))&&(M=i.floating[E]||a.floating[b]);const C=S/2-_/2,j=M/2-g[b]/2-1,L=Ge(f[v],j),U=Ge(f[w],j),B=L,z=M-g[b]-U,W=M/2-g[b]/2+C,X=fr(B,W,z),V=!c.arrow&&lt(o)!=null&&W!==X&&a.reference[b]/2-(W<B?L:U)-g[b]/2<0,K=V?W<B?W-B:W-z:0;return{[h]:m[h]+K,data:{[h]:X,centerOffset:W-X-K,...V&&{alignmentOffset:K}},reset:V}}}),jd=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:a,rects:s,initialPlacement:i,platform:c,elements:p}=t,{mainAxis:d=!0,crossAxis:f=!0,fallbackPlacements:m,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:g=!0,...x}=je(e,t);if((n=a.arrow)!=null&&n.alignmentOffset)return{};const v=Le(o),w=Ae(i),E=Le(i)===i,S=await(c.isRTL==null?void 0:c.isRTL(p.floating)),_=m||(E||!g?[rn(i)]:Nd(i)),T=b!=="none";!m&&T&&_.push(...Od(i,g,b,S));const M=[i,..._],C=await wt(t,x),j=[];let L=((r=a.flip)==null?void 0:r.overflows)||[];if(d&&j.push(C[v]),f){const W=Td(o,s,S);j.push(C[W[0]],C[W[1]])}if(L=[...L,{placement:o,overflows:j}],!j.every(W=>W<=0)){var U,B;const W=(((U=a.flip)==null?void 0:U.index)||0)+1,X=M[W];if(X&&(!(f==="alignment"?w!==Ae(X):!1)||L.every(R=>R.overflows[0]>0&&Ae(R.placement)===w)))return{data:{index:W,overflows:L},reset:{placement:X}};let V=(B=L.filter(K=>K.overflows[0]<=0).sort((K,R)=>K.overflows[1]-R.overflows[1])[0])==null?void 0:B.placement;if(!V)switch(h){case"bestFit":{var z;const K=(z=L.filter(R=>{if(T){const N=Ae(R.placement);return N===w||N==="y"}return!0}).map(R=>[R.placement,R.overflows.filter(N=>N>0).reduce((N,y)=>N+y,0)]).sort((R,N)=>R[1]-N[1])[0])==null?void 0:z[0];K&&(V=K);break}case"initialPlacement":V=i;break}if(o!==V)return{reset:{placement:V}}}return{}}}};function Ua(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Ka(e){return Rd.some(t=>e[t]>=0)}const Ld=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=je(e,t);switch(r){case"referenceHidden":{const a=await wt(t,{...o,elementContext:"reference"}),s=Ua(a,n.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:Ka(s)}}}case"escaped":{const a=await wt(t,{...o,altBoundary:!0}),s=Ua(a,n.floating);return{data:{escapedOffsets:s,escaped:Ka(s)}}}default:return{}}}}};async function Fd(e,t){const{placement:n,platform:r,elements:o}=e,a=await(r.isRTL==null?void 0:r.isRTL(o.floating)),s=Le(n),i=lt(n),c=Ae(n)==="y",p=["left","top"].includes(s)?-1:1,d=a&&c?-1:1,f=je(t,e);let{mainAxis:m,crossAxis:h,alignmentAxis:b}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return i&&typeof b=="number"&&(h=i==="end"?b*-1:b),c?{x:h*d,y:m*p}:{x:m*p,y:h*d}}const $d=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:a,placement:s,middlewareData:i}=t,c=await Fd(t,e);return s===((n=i.offset)==null?void 0:n.placement)&&(r=i.arrow)!=null&&r.alignmentOffset?{}:{x:o+c.x,y:a+c.y,data:{...c,placement:s}}}}},Vd=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:s=!1,limiter:i={fn:x=>{let{x:v,y:w}=x;return{x:v,y:w}}},...c}=je(e,t),p={x:n,y:r},d=await wt(t,c),f=Ae(Le(o)),m=pr(f);let h=p[m],b=p[f];if(a){const x=m==="y"?"top":"left",v=m==="y"?"bottom":"right",w=h+d[x],E=h-d[v];h=fr(w,h,E)}if(s){const x=f==="y"?"top":"left",v=f==="y"?"bottom":"right",w=b+d[x],E=b-d[v];b=fr(w,b,E)}const g=i.fn({...t,[m]:h,[f]:b});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[m]:a,[f]:s}}}}}},Hd=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:a,middlewareData:s}=t,{offset:i=0,mainAxis:c=!0,crossAxis:p=!0}=je(e,t),d={x:n,y:r},f=Ae(o),m=pr(f);let h=d[m],b=d[f];const g=je(i,t),x=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(c){const E=m==="y"?"height":"width",S=a.reference[m]-a.floating[E]+x.mainAxis,_=a.reference[m]+a.reference[E]-x.mainAxis;h<S?h=S:h>_&&(h=_)}if(p){var v,w;const E=m==="y"?"width":"height",S=["top","left"].includes(Le(o)),_=a.reference[f]-a.floating[E]+(S&&((v=s.offset)==null?void 0:v[f])||0)+(S?0:x.crossAxis),T=a.reference[f]+a.reference[E]+(S?0:((w=s.offset)==null?void 0:w[f])||0)-(S?x.crossAxis:0);b<_?b=_:b>T&&(b=T)}return{[m]:h,[f]:b}}}},zd=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:a,platform:s,elements:i}=t,{apply:c=()=>{},...p}=je(e,t),d=await wt(t,p),f=Le(o),m=lt(o),h=Ae(o)==="y",{width:b,height:g}=a.floating;let x,v;f==="top"||f==="bottom"?(x=f,v=m===(await(s.isRTL==null?void 0:s.isRTL(i.floating))?"start":"end")?"left":"right"):(v=f,x=m==="end"?"top":"bottom");const w=g-d.top-d.bottom,E=b-d.left-d.right,S=Ge(g-d[x],w),_=Ge(b-d[v],E),T=!t.middlewareData.shift;let M=S,C=_;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(C=E),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(M=w),T&&!m){const L=he(d.left,0),U=he(d.right,0),B=he(d.top,0),z=he(d.bottom,0);h?C=b-2*(L!==0||U!==0?L+U:he(d.left,d.right)):M=g-2*(B!==0||z!==0?B+z:he(d.top,d.bottom))}await c({...t,availableWidth:C,availableHeight:M});const j=await s.getDimensions(i.floating);return b!==j.width||g!==j.height?{reset:{rects:!0}}:{}}}};function an(){return typeof window<"u"}function ut(e){return Ya(e)?(e.nodeName||"").toLowerCase():"#document"}function ge(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Te(e){var t;return(t=(Ya(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Ya(e){return an()?e instanceof Node||e instanceof ge(e).Node:!1}function Ce(e){return an()?e instanceof Element||e instanceof ge(e).Element:!1}function Ne(e){return an()?e instanceof HTMLElement||e instanceof ge(e).HTMLElement:!1}function qa(e){return!an()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof ge(e).ShadowRoot}function yt(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Ee(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function Wd(e){return["table","td","th"].includes(ut(e))}function sn(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function vr(e){const t=br(),n=Ce(e)?Ee(e):e;return["transform","translate","scale","rotate","perspective"].some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","translate","scale","rotate","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function Gd(e){let t=Be(e);for(;Ne(t)&&!dt(t);){if(vr(t))return t;if(sn(t))return null;t=Be(t)}return null}function br(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function dt(e){return["html","body","#document"].includes(ut(e))}function Ee(e){return ge(e).getComputedStyle(e)}function cn(e){return Ce(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Be(e){if(ut(e)==="html")return e;const t=e.assignedSlot||e.parentNode||qa(e)&&e.host||Te(e);return qa(t)?t.host:t}function Xa(e){const t=Be(e);return dt(t)?e.ownerDocument?e.ownerDocument.body:e.body:Ne(t)&&yt(t)?t:Xa(t)}function Ct(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=Xa(e),a=o===((r=e.ownerDocument)==null?void 0:r.body),s=ge(o);if(a){const i=xr(s);return t.concat(s,s.visualViewport||[],yt(o)?o:[],i&&n?Ct(i):[])}return t.concat(o,Ct(o,[],n))}function xr(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Za(e){const t=Ee(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Ne(e),a=o?e.offsetWidth:n,s=o?e.offsetHeight:r,i=tn(n)!==a||tn(r)!==s;return i&&(n=a,r=s),{width:n,height:r,$:i}}function wr(e){return Ce(e)?e:e.contextElement}function ft(e){const t=wr(e);if(!Ne(t))return Me(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=Za(t);let s=(a?tn(n.width):n.width)/r,i=(a?tn(n.height):n.height)/o;return(!s||!Number.isFinite(s))&&(s=1),(!i||!Number.isFinite(i))&&(i=1),{x:s,y:i}}const Bd=Me(0);function Ja(e){const t=ge(e);return!br()||!t.visualViewport?Bd:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Ud(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==ge(e)?!1:t}function Je(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),a=wr(e);let s=Me(1);t&&(r?Ce(r)&&(s=ft(r)):s=ft(e));const i=Ud(a,n,r)?Ja(a):Me(0);let c=(o.left+i.x)/s.x,p=(o.top+i.y)/s.y,d=o.width/s.x,f=o.height/s.y;if(a){const m=ge(a),h=r&&Ce(r)?ge(r):r;let b=m,g=xr(b);for(;g&&r&&h!==b;){const x=ft(g),v=g.getBoundingClientRect(),w=Ee(g),E=v.left+(g.clientLeft+parseFloat(w.paddingLeft))*x.x,S=v.top+(g.clientTop+parseFloat(w.paddingTop))*x.y;c*=x.x,p*=x.y,d*=x.x,f*=x.y,c+=E,p+=S,b=ge(g),g=xr(b)}}return on({width:d,height:f,x:c,y:p})}function yr(e,t){const n=cn(e).scrollLeft;return t?t.left+n:Je(Te(e)).left+n}function Qa(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-(n?0:yr(e,r)),a=r.top+t.scrollTop;return{x:o,y:a}}function Kd(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const a=o==="fixed",s=Te(r),i=t?sn(t.floating):!1;if(r===s||i&&a)return n;let c={scrollLeft:0,scrollTop:0},p=Me(1);const d=Me(0),f=Ne(r);if((f||!f&&!a)&&((ut(r)!=="body"||yt(s))&&(c=cn(r)),Ne(r))){const h=Je(r);p=ft(r),d.x=h.x+r.clientLeft,d.y=h.y+r.clientTop}const m=s&&!f&&!a?Qa(s,c,!0):Me(0);return{width:n.width*p.x,height:n.height*p.y,x:n.x*p.x-c.scrollLeft*p.x+d.x+m.x,y:n.y*p.y-c.scrollTop*p.y+d.y+m.y}}function Yd(e){return Array.from(e.getClientRects())}function qd(e){const t=Te(e),n=cn(e),r=e.ownerDocument.body,o=he(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=he(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let s=-n.scrollLeft+yr(e);const i=-n.scrollTop;return Ee(r).direction==="rtl"&&(s+=he(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:s,y:i}}function Xd(e,t){const n=ge(e),r=Te(e),o=n.visualViewport;let a=r.clientWidth,s=r.clientHeight,i=0,c=0;if(o){a=o.width,s=o.height;const p=br();(!p||p&&t==="fixed")&&(i=o.offsetLeft,c=o.offsetTop)}return{width:a,height:s,x:i,y:c}}function Zd(e,t){const n=Je(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=Ne(e)?ft(e):Me(1),s=e.clientWidth*a.x,i=e.clientHeight*a.y,c=o*a.x,p=r*a.y;return{width:s,height:i,x:c,y:p}}function es(e,t,n){let r;if(t==="viewport")r=Xd(e,n);else if(t==="document")r=qd(Te(e));else if(Ce(t))r=Zd(t,n);else{const o=Ja(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return on(r)}function ts(e,t){const n=Be(e);return n===t||!Ce(n)||dt(n)?!1:Ee(n).position==="fixed"||ts(n,t)}function Jd(e,t){const n=t.get(e);if(n)return n;let r=Ct(e,[],!1).filter(i=>Ce(i)&&ut(i)!=="body"),o=null;const a=Ee(e).position==="fixed";let s=a?Be(e):e;for(;Ce(s)&&!dt(s);){const i=Ee(s),c=vr(s);!c&&i.position==="fixed"&&(o=null),(a?!c&&!o:!c&&i.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||yt(s)&&!c&&ts(e,s))?r=r.filter(d=>d!==s):o=i,s=Be(s)}return t.set(e,r),r}function Qd(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const s=[...n==="clippingAncestors"?sn(t)?[]:Jd(t,this._c):[].concat(n),r],i=s[0],c=s.reduce((p,d)=>{const f=es(t,d,o);return p.top=he(f.top,p.top),p.right=Ge(f.right,p.right),p.bottom=Ge(f.bottom,p.bottom),p.left=he(f.left,p.left),p},es(t,i,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function ef(e){const{width:t,height:n}=Za(e);return{width:t,height:n}}function tf(e,t,n){const r=Ne(t),o=Te(t),a=n==="fixed",s=Je(e,!0,a,t);let i={scrollLeft:0,scrollTop:0};const c=Me(0);function p(){c.x=yr(o)}if(r||!r&&!a)if((ut(t)!=="body"||yt(o))&&(i=cn(t)),r){const h=Je(t,!0,a,t);c.x=h.x+t.clientLeft,c.y=h.y+t.clientTop}else o&&p();a&&!r&&o&&p();const d=o&&!r&&!a?Qa(o,i):Me(0),f=s.left+i.scrollLeft-c.x-d.x,m=s.top+i.scrollTop-c.y-d.y;return{x:f,y:m,width:s.width,height:s.height}}function Cr(e){return Ee(e).position==="static"}function ns(e,t){if(!Ne(e)||Ee(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Te(e)===n&&(n=n.ownerDocument.body),n}function rs(e,t){const n=ge(e);if(sn(e))return n;if(!Ne(e)){let o=Be(e);for(;o&&!dt(o);){if(Ce(o)&&!Cr(o))return o;o=Be(o)}return n}let r=ns(e,t);for(;r&&Wd(r)&&Cr(r);)r=ns(r,t);return r&&dt(r)&&Cr(r)&&!vr(r)?n:r||Gd(e)||n}const nf=async function(e){const t=this.getOffsetParent||rs,n=this.getDimensions,r=await n(e.floating);return{reference:tf(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function rf(e){return Ee(e).direction==="rtl"}const of={convertOffsetParentRelativeRectToViewportRelativeRect:Kd,getDocumentElement:Te,getClippingRect:Qd,getOffsetParent:rs,getElementRects:nf,getClientRects:Yd,getDimensions:ef,getScale:ft,isElement:Ce,isRTL:rf};function os(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function af(e,t){let n=null,r;const o=Te(e);function a(){var i;clearTimeout(r),(i=n)==null||i.disconnect(),n=null}function s(i,c){i===void 0&&(i=!1),c===void 0&&(c=1),a();const p=e.getBoundingClientRect(),{left:d,top:f,width:m,height:h}=p;if(i||t(),!m||!h)return;const b=nn(f),g=nn(o.clientWidth-(d+m)),x=nn(o.clientHeight-(f+h)),v=nn(d),E={rootMargin:-b+"px "+-g+"px "+-x+"px "+-v+"px",threshold:he(0,Ge(1,c))||1};let S=!0;function _(T){const M=T[0].intersectionRatio;if(M!==c){if(!S)return s();M?s(!1,M):r=setTimeout(()=>{s(!1,1e-7)},1e3)}M===1&&!os(p,e.getBoundingClientRect())&&s(),S=!1}try{n=new IntersectionObserver(_,{...E,root:o.ownerDocument})}catch{n=new IntersectionObserver(_,E)}n.observe(e)}return s(!0),a}function sf(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:i=typeof IntersectionObserver=="function",animationFrame:c=!1}=r,p=wr(e),d=o||a?[...p?Ct(p):[],...Ct(t)]:[];d.forEach(v=>{o&&v.addEventListener("scroll",n,{passive:!0}),a&&v.addEventListener("resize",n)});const f=p&&i?af(p,n):null;let m=-1,h=null;s&&(h=new ResizeObserver(v=>{let[w]=v;w&&w.target===p&&h&&(h.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var E;(E=h)==null||E.observe(t)})),n()}),p&&!c&&h.observe(p),h.observe(t));let b,g=c?Je(e):null;c&&x();function x(){const v=Je(e);g&&!os(g,v)&&n(),g=v,b=requestAnimationFrame(x)}return n(),()=>{var v;d.forEach(w=>{o&&w.removeEventListener("scroll",n),a&&w.removeEventListener("resize",n)}),f==null||f(),(v=h)==null||v.disconnect(),h=null,c&&cancelAnimationFrame(b)}}const cf=$d,lf=Vd,uf=jd,df=zd,ff=Ld,as=Id,pf=Hd,mf=(e,t,n)=>{const r=new Map,o={platform:of,...n},a={...o.platform,_c:r};return Dd(e,t,{...o,platform:a})};var hf=typeof document<"u",gf=function(){},ln=hf?I.useLayoutEffect:gf;function un(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!un(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const a=o[r];if(!(a==="_owner"&&e.$$typeof)&&!un(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function ss(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function is(e,t){const n=ss(e);return Math.round(t*n)/n}function Er(e){const t=l.useRef(e);return ln(()=>{t.current=e}),t}function vf(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:a,floating:s}={},transform:i=!0,whileElementsMounted:c,open:p}=e,[d,f]=l.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,h]=l.useState(r);un(m,r)||h(r);const[b,g]=l.useState(null),[x,v]=l.useState(null),w=l.useCallback(R=>{R!==T.current&&(T.current=R,g(R))},[]),E=l.useCallback(R=>{R!==M.current&&(M.current=R,v(R))},[]),S=a||b,_=s||x,T=l.useRef(null),M=l.useRef(null),C=l.useRef(d),j=c!=null,L=Er(c),U=Er(o),B=Er(p),z=l.useCallback(()=>{if(!T.current||!M.current)return;const R={placement:t,strategy:n,middleware:m};U.current&&(R.platform=U.current),mf(T.current,M.current,R).then(N=>{const y={...N,isPositioned:B.current!==!1};W.current&&!un(C.current,y)&&(C.current=y,Kr.flushSync(()=>{f(y)}))})},[m,t,n,U,B]);ln(()=>{p===!1&&C.current.isPositioned&&(C.current.isPositioned=!1,f(R=>({...R,isPositioned:!1})))},[p]);const W=l.useRef(!1);ln(()=>(W.current=!0,()=>{W.current=!1}),[]),ln(()=>{if(S&&(T.current=S),_&&(M.current=_),S&&_){if(L.current)return L.current(S,_,z);z()}},[S,_,z,L,j]);const X=l.useMemo(()=>({reference:T,floating:M,setReference:w,setFloating:E}),[w,E]),V=l.useMemo(()=>({reference:S,floating:_}),[S,_]),K=l.useMemo(()=>{const R={position:n,left:0,top:0};if(!V.floating)return R;const N=is(V.floating,d.x),y=is(V.floating,d.y);return i?{...R,transform:"translate("+N+"px, "+y+"px)",...ss(V.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:N,top:y}},[n,i,V.floating,d.x,d.y]);return l.useMemo(()=>({...d,update:z,refs:X,elements:V,floatingStyles:K}),[d,z,X,V,K])}const bf=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?as({element:r.current,padding:o}).fn(n):{}:r?as({element:r,padding:o}).fn(n):{}}}},xf=(e,t)=>({...cf(e),options:[e,t]}),wf=(e,t)=>({...lf(e),options:[e,t]}),yf=(e,t)=>({...pf(e),options:[e,t]}),Cf=(e,t)=>({...uf(e),options:[e,t]}),Ef=(e,t)=>({...df(e),options:[e,t]}),Sf=(e,t)=>({...ff(e),options:[e,t]}),_f=(e,t)=>({...bf(e),options:[e,t]});var Rf="Arrow",cs=l.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...a}=e;return u.jsx(re.svg,{...a,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:u.jsx("polygon",{points:"0,0 30,0 15,10"})})});cs.displayName=Rf;var Mf=cs;function Af(e){const[t,n]=l.useState(void 0);return ze(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const a=o[0];let s,i;if("borderBoxSize"in a){const c=a.borderBoxSize,p=Array.isArray(c)?c[0]:c;s=p.inlineSize,i=p.blockSize}else s=e.offsetWidth,i=e.offsetHeight;n({width:s,height:i})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var Sr="Popper",[ls,dn]=Xe(Sr),[Tf,us]=ls(Sr),ds=e=>{const{__scopePopper:t,children:n}=e,[r,o]=l.useState(null);return u.jsx(Tf,{scope:t,anchor:r,onAnchorChange:o,children:n})};ds.displayName=Sr;var fs="PopperAnchor",ps=l.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,a=us(fs,n),s=l.useRef(null),i=ie(t,s);return l.useEffect(()=>{a.onAnchorChange((r==null?void 0:r.current)||s.current)}),r?null:u.jsx(re.div,{...o,ref:i})});ps.displayName=fs;var _r="PopperContent",[Nf,kf]=ls(_r),ms=l.forwardRef((e,t)=>{var Y,ee,te,se,Se,Ke;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:a="center",alignOffset:s=0,arrowPadding:i=0,avoidCollisions:c=!0,collisionBoundary:p=[],collisionPadding:d=0,sticky:f="partial",hideWhenDetached:m=!1,updatePositionStrategy:h="optimized",onPlaced:b,...g}=e,x=us(_r,n),[v,w]=l.useState(null),E=ie(t,J=>w(J)),[S,_]=l.useState(null),T=Af(S),M=(T==null?void 0:T.width)??0,C=(T==null?void 0:T.height)??0,j=r+(a!=="center"?"-"+a:""),L=typeof d=="number"?d:{top:0,right:0,bottom:0,left:0,...d},U=Array.isArray(p)?p:[p],B=U.length>0,z={padding:L,boundary:U.filter(Pf),altBoundary:B},{refs:W,floatingStyles:X,placement:V,isPositioned:K,middlewareData:R}=vf({strategy:"fixed",placement:j,whileElementsMounted:(...J)=>sf(...J,{animationFrame:h==="always"}),elements:{reference:x.anchor},middleware:[xf({mainAxis:o+C,alignmentAxis:s}),c&&wf({mainAxis:!0,crossAxis:!1,limiter:f==="partial"?yf():void 0,...z}),c&&Cf({...z}),Ef({...z,apply:({elements:J,rects:Q,availableWidth:le,availableHeight:oe})=>{const{width:ve,height:Ye}=Q.reference,ae=J.floating.style;ae.setProperty("--radix-popper-available-width",`${le}px`),ae.setProperty("--radix-popper-available-height",`${oe}px`),ae.setProperty("--radix-popper-anchor-width",`${ve}px`),ae.setProperty("--radix-popper-anchor-height",`${Ye}px`)}}),S&&_f({element:S,padding:i}),Df({arrowWidth:M,arrowHeight:C}),m&&Sf({strategy:"referenceHidden",...z})]}),[N,y]=vs(V),P=_e(b);ze(()=>{K&&(P==null||P())},[K,P]);const F=(Y=R.arrow)==null?void 0:Y.x,H=(ee=R.arrow)==null?void 0:ee.y,Z=((te=R.arrow)==null?void 0:te.centerOffset)!==0,[ne,ue]=l.useState();return ze(()=>{v&&ue(window.getComputedStyle(v).zIndex)},[v]),u.jsx("div",{ref:W.setFloating,"data-radix-popper-content-wrapper":"",style:{...X,transform:K?X.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ne,"--radix-popper-transform-origin":[(se=R.transformOrigin)==null?void 0:se.x,(Se=R.transformOrigin)==null?void 0:Se.y].join(" "),...((Ke=R.hide)==null?void 0:Ke.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:u.jsx(Nf,{scope:n,placedSide:N,onArrowChange:_,arrowX:F,arrowY:H,shouldHideArrow:Z,children:u.jsx(re.div,{"data-side":N,"data-align":y,...g,ref:E,style:{...g.style,animation:K?void 0:"none"}})})})});ms.displayName=_r;var hs="PopperArrow",Of={top:"bottom",right:"left",bottom:"top",left:"right"},gs=l.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,a=kf(hs,r),s=Of[a.placedSide];return u.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[s]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:u.jsx(Mf,{...o,ref:n,style:{...o.style,display:"block"}})})});gs.displayName=hs;function Pf(e){return e!==null}var Df=e=>({name:"transformOrigin",options:e,fn(t){var x,v,w;const{placement:n,rects:r,middlewareData:o}=t,s=((x=o.arrow)==null?void 0:x.centerOffset)!==0,i=s?0:e.arrowWidth,c=s?0:e.arrowHeight,[p,d]=vs(n),f={start:"0%",center:"50%",end:"100%"}[d],m=(((v=o.arrow)==null?void 0:v.x)??0)+i/2,h=(((w=o.arrow)==null?void 0:w.y)??0)+c/2;let b="",g="";return p==="bottom"?(b=s?f:`${m}px`,g=`${-c}px`):p==="top"?(b=s?f:`${m}px`,g=`${r.floating.height+c}px`):p==="right"?(b=`${-c}px`,g=s?f:`${h}px`):p==="left"&&(b=`${r.floating.width+c}px`,g=s?f:`${h}px`),{data:{x:b,y:g}}}});function vs(e){const[t,n="center"]=e.split("-");return[t,n]}var Rr=ds,bs=ps,xs=ms,ws=gs,If=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),jf="VisuallyHidden",ys=l.forwardRef((e,t)=>u.jsx(re.span,{...e,ref:t,style:{...If,...e.style}}));ys.displayName=jf;var Lf=ys,[fn,D0]=Xe("Tooltip",[dn]),pn=dn(),Cs="TooltipProvider",Ff=700,Mr="tooltip.open",[$f,Ar]=fn(Cs),Es=e=>{const{__scopeTooltip:t,delayDuration:n=Ff,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:a}=e,s=l.useRef(!0),i=l.useRef(!1),c=l.useRef(0);return l.useEffect(()=>{const p=c.current;return()=>window.clearTimeout(p)},[]),u.jsx($f,{scope:t,isOpenDelayedRef:s,delayDuration:n,onOpen:l.useCallback(()=>{window.clearTimeout(c.current),s.current=!1},[]),onClose:l.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>s.current=!0,r)},[r]),isPointerInTransitRef:i,onPointerInTransitChange:l.useCallback(p=>{i.current=p},[]),disableHoverableContent:o,children:a})};Es.displayName=Cs;var Et="Tooltip",[Vf,mn]=fn(Et),Ss=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o,onOpenChange:a,disableHoverableContent:s,delayDuration:i}=e,c=Ar(Et,e.__scopeTooltip),p=pn(t),[d,f]=l.useState(null),m=De(),h=l.useRef(0),b=s??c.disableHoverableContent,g=i??c.delayDuration,x=l.useRef(!1),[v,w]=xt({prop:r,defaultProp:o??!1,onChange:M=>{M?(c.onOpen(),document.dispatchEvent(new CustomEvent(Mr))):c.onClose(),a==null||a(M)},caller:Et}),E=l.useMemo(()=>v?x.current?"delayed-open":"instant-open":"closed",[v]),S=l.useCallback(()=>{window.clearTimeout(h.current),h.current=0,x.current=!1,w(!0)},[w]),_=l.useCallback(()=>{window.clearTimeout(h.current),h.current=0,w(!1)},[w]),T=l.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>{x.current=!0,w(!0),h.current=0},g)},[g,w]);return l.useEffect(()=>()=>{h.current&&(window.clearTimeout(h.current),h.current=0)},[]),u.jsx(Rr,{...p,children:u.jsx(Vf,{scope:t,contentId:m,open:v,stateAttribute:E,trigger:d,onTriggerChange:f,onTriggerEnter:l.useCallback(()=>{c.isOpenDelayedRef.current?T():S()},[c.isOpenDelayedRef,T,S]),onTriggerLeave:l.useCallback(()=>{b?_():(window.clearTimeout(h.current),h.current=0)},[_,b]),onOpen:S,onClose:_,disableHoverableContent:b,children:n})})};Ss.displayName=Et;var Tr="TooltipTrigger",_s=l.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=mn(Tr,n),a=Ar(Tr,n),s=pn(n),i=l.useRef(null),c=ie(t,i,o.onTriggerChange),p=l.useRef(!1),d=l.useRef(!1),f=l.useCallback(()=>p.current=!1,[]);return l.useEffect(()=>()=>document.removeEventListener("pointerup",f),[f]),u.jsx(bs,{asChild:!0,...s,children:u.jsx(re.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:c,onPointerMove:$(e.onPointerMove,m=>{m.pointerType!=="touch"&&!d.current&&!a.isPointerInTransitRef.current&&(o.onTriggerEnter(),d.current=!0)}),onPointerLeave:$(e.onPointerLeave,()=>{o.onTriggerLeave(),d.current=!1}),onPointerDown:$(e.onPointerDown,()=>{o.open&&o.onClose(),p.current=!0,document.addEventListener("pointerup",f,{once:!0})}),onFocus:$(e.onFocus,()=>{p.current||o.onOpen()}),onBlur:$(e.onBlur,o.onClose),onClick:$(e.onClick,o.onClose)})})});_s.displayName=Tr;var Hf="TooltipPortal",[I0,zf]=fn(Hf,{forceMount:void 0}),pt="TooltipContent",Rs=l.forwardRef((e,t)=>{const n=zf(pt,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...a}=e,s=mn(pt,e.__scopeTooltip);return u.jsx(Ie,{present:r||s.open,children:s.disableHoverableContent?u.jsx(Ms,{side:o,...a,ref:t}):u.jsx(Wf,{side:o,...a,ref:t})})}),Wf=l.forwardRef((e,t)=>{const n=mn(pt,e.__scopeTooltip),r=Ar(pt,e.__scopeTooltip),o=l.useRef(null),a=ie(t,o),[s,i]=l.useState(null),{trigger:c,onClose:p}=n,d=o.current,{onPointerInTransitChange:f}=r,m=l.useCallback(()=>{i(null),f(!1)},[f]),h=l.useCallback((b,g)=>{const x=b.currentTarget,v={x:b.clientX,y:b.clientY},w=Yf(v,x.getBoundingClientRect()),E=qf(v,w),S=Xf(g.getBoundingClientRect()),_=Jf([...E,...S]);i(_),f(!0)},[f]);return l.useEffect(()=>()=>m(),[m]),l.useEffect(()=>{if(c&&d){const b=x=>h(x,d),g=x=>h(x,c);return c.addEventListener("pointerleave",b),d.addEventListener("pointerleave",g),()=>{c.removeEventListener("pointerleave",b),d.removeEventListener("pointerleave",g)}}},[c,d,h,m]),l.useEffect(()=>{if(s){const b=g=>{const x=g.target,v={x:g.clientX,y:g.clientY},w=(c==null?void 0:c.contains(x))||(d==null?void 0:d.contains(x)),E=!Zf(v,s);w?m():E&&(m(),p())};return document.addEventListener("pointermove",b),()=>document.removeEventListener("pointermove",b)}},[c,d,s,p,m]),u.jsx(Ms,{...e,ref:a})}),[Gf,Bf]=fn(Et,{isInside:!1}),Uf=al("TooltipContent"),Ms=l.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:a,onPointerDownOutside:s,...i}=e,c=mn(pt,n),p=pn(n),{onClose:d}=c;return l.useEffect(()=>(document.addEventListener(Mr,d),()=>document.removeEventListener(Mr,d)),[d]),l.useEffect(()=>{if(c.trigger){const f=m=>{const h=m.target;h!=null&&h.contains(c.trigger)&&d()};return window.addEventListener("scroll",f,{capture:!0}),()=>window.removeEventListener("scroll",f,{capture:!0})}},[c.trigger,d]),u.jsx(Gt,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:s,onFocusOutside:f=>f.preventDefault(),onDismiss:d,children:u.jsxs(xs,{"data-state":c.stateAttribute,...p,...i,ref:t,style:{...i.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[u.jsx(Uf,{children:r}),u.jsx(Gf,{scope:n,isInside:!0,children:u.jsx(Lf,{id:c.contentId,role:"tooltip",children:o||r})})]})})});Rs.displayName=pt;var As="TooltipArrow",Kf=l.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=pn(n);return Bf(As,n).isInside?null:u.jsx(ws,{...o,...r,ref:t})});Kf.displayName=As;function Yf(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(n,r,o,a)){case a:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function qf(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function Xf(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function Zf(e,t){const{x:n,y:r}=e;let o=!1;for(let a=0,s=t.length-1;a<t.length;s=a++){const i=t[a],c=t[s],p=i.x,d=i.y,f=c.x,m=c.y;d>r!=m>r&&n<(f-p)*(r-d)/(m-d)+p&&(o=!o)}return o}function Jf(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),Qf(t)}function Qf(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const o=e[r];for(;t.length>=2;){const a=t[t.length-1],s=t[t.length-2];if((a.x-s.x)*(o.y-s.y)>=(a.y-s.y)*(o.x-s.x))t.pop();else break}t.push(o)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;n.length>=2;){const a=n[n.length-1],s=n[n.length-2];if((a.x-s.x)*(o.y-s.y)>=(a.y-s.y)*(o.x-s.x))n.pop();else break}n.push(o)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var ep=Es,tp=Ss,np=_s,Ts=Rs;const Ns=ep,ks=tp,Os=np,Nr=l.forwardRef(({className:e,sideOffset:t=4,...n},r)=>u.jsx(Ts,{ref:r,sideOffset:t,className:D("z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...n}));Nr.displayName=Ts.displayName;const rp="sidebar_state",op=60*60*24*7,ap="16rem",sp="18rem",ip="3rem",cp="b",Ps=l.createContext(null);function St(){const e=l.useContext(Ps);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}function Ds({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:a,...s}){const i=ql(),[c,p]=l.useState(!1),[d,f]=l.useState(e),m=t??d,h=l.useCallback(v=>{const w=typeof v=="function"?v(m):v;n?n(w):f(w),document.cookie=`${rp}=${w}; path=/; max-age=${op}`},[n,m]),b=l.useCallback(()=>i?p(v=>!v):h(v=>!v),[i,h,p]);l.useEffect(()=>{const v=w=>{w.key===cp&&(w.metaKey||w.ctrlKey)&&(w.preventDefault(),b())};return window.addEventListener("keydown",v),()=>window.removeEventListener("keydown",v)},[b]);const g=m?"expanded":"collapsed",x=l.useMemo(()=>({state:g,open:m,setOpen:h,isMobile:i,openMobile:c,setOpenMobile:p,toggleSidebar:b}),[g,m,h,i,c,p,b]);return u.jsx(Ps.Provider,{value:x,children:u.jsx(Ns,{delayDuration:0,children:u.jsx("div",{"data-slot":"sidebar-wrapper",style:{"--sidebar-width":ap,"--sidebar-width-icon":ip,...o},className:D("group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex min-h-svh w-full",r),...s,children:a})})})}function Is({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...a}){const{isMobile:s,state:i,openMobile:c,setOpenMobile:p}=St();return n==="none"?u.jsx("div",{"data-slot":"sidebar",className:D("bg-white text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col",r),...a,children:o}):s?u.jsx(Ha,{open:c,onOpenChange:p,...a,children:u.jsxs(ir,{"data-sidebar":"sidebar","data-slot":"sidebar","data-mobile":"true",className:"bg-white text-sidebar-foreground w-(--sidebar-width) p-0 [&>button]:hidden",style:{"--sidebar-width":sp},side:e,children:[u.jsxs(cr,{className:"sr-only",children:[u.jsx(lr,{children:"Sidebar"}),u.jsx(ur,{children:"Displays the mobile sidebar."})]}),u.jsx("div",{className:"flex h-full w-full flex-col",children:o})]})}):u.jsxs("div",{className:"group peer text-sidebar-foreground hidden md:block","data-state":i,"data-collapsible":i==="collapsed"?n:"","data-variant":t,"data-side":e,"data-slot":"sidebar",children:[u.jsx("div",{"data-slot":"sidebar-gap",className:D("relative w-(--sidebar-width) bg-white transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]":"group-data-[collapsible=icon]:w-(--sidebar-width-icon)")}),u.jsx("div",{"data-slot":"sidebar-container",className:D("fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear md:flex",e==="left"?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]":"group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=right]:border-l",r),...a,children:u.jsx("div",{"data-sidebar":"sidebar","data-slot":"sidebar-inner",className:"bg-white group-data-[variant=floating]:border-sidebar-border flex h-full w-full flex-col px-1 py-2 group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:shadow-sm",children:o})})]})}function js({className:e,onClick:t,...n}){const{toggleSidebar:r}=St();return u.jsxs(zt,{"data-sidebar":"trigger","data-slot":"sidebar-trigger",variant:"ghost",size:"icon",className:D("size-7",e),onClick:o=>{t==null||t(o),r()},...n,children:[u.jsx(nl,{}),u.jsx("span",{className:"sr-only",children:"Toggle Sidebar"})]})}function Ls({className:e,...t}){const{toggleSidebar:n}=St();return u.jsx("button",{"data-sidebar":"rail","data-slot":"sidebar-rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:n,title:"Toggle Sidebar",className:D("hover:after:bg-sidebar-border absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear group-data-[side=left]:-right-4 group-data-[side=right]:left-0 after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] sm:flex","in-data-[side=left]:cursor-w-resize in-data-[side=right]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","hover:group-data-[collapsible=offcanvas]:bg-sidebar group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",e),...t})}function Fs({className:e,...t}){return u.jsx("main",{"data-slot":"sidebar-inset",className:D("bg-white relative flex w-full flex-1 flex-col","md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow-sm md:peer-data-[variant=inset]:peer-data-[state=collapsed]:ml-2",e),...t})}function lp({className:e,...t}){return u.jsx(Gn,{"data-slot":"sidebar-input","data-sidebar":"input",className:D("bg-background h-8 w-full shadow-none",e),...t})}function $s({className:e,...t}){return u.jsx("div",{"data-slot":"sidebar-header","data-sidebar":"header",className:D("flex flex-col gap-2 p-2",e),...t})}function up({className:e,...t}){return u.jsx("div",{"data-slot":"sidebar-footer","data-sidebar":"footer",className:D("flex flex-col gap-2 p-2",e),...t})}function dp({className:e,...t}){return u.jsx(Wt,{"data-slot":"sidebar-separator","data-sidebar":"separator",className:D("bg-sidebar-border mx-2 w-auto",e),...t})}function Vs({className:e,...t}){return u.jsx("div",{"data-slot":"sidebar-content","data-sidebar":"content",className:D("flex min-h-0 flex-1 flex-col overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),...t})}function Hs({className:e,...t}){return u.jsx("div",{"data-slot":"sidebar-group","data-sidebar":"group",className:D("relative flex w-full min-w-0 flex-col px-2 py-1",e),...t})}function fp({className:e,asChild:t=!1,...n}){const r=t?tt:"div";return u.jsx(r,{"data-slot":"sidebar-group-label","data-sidebar":"group-label",className:D("text-sidebar-foreground/70 ring-sidebar-ring flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium outline-hidden transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",e),...n})}function pp({className:e,asChild:t=!1,...n}){const r=t?tt:"button";return u.jsx(r,{"data-slot":"sidebar-group-action","data-sidebar":"group-action",className:D("text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground absolute top-3.5 right-3 flex aspect-square w-5 items-center justify-center rounded-md p-0 outline-hidden transition-transform focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 md:after:hidden","group-data-[collapsible=icon]:hidden",e),...n})}function zs({className:e,...t}){return u.jsx("div",{"data-slot":"sidebar-group-content","data-sidebar":"group-content",className:D("w-full text-sm",e),...t})}function mp({className:e,...t}){return u.jsx("ul",{"data-slot":"sidebar-menu","data-sidebar":"menu",className:D("flex w-full min-w-0 flex-col gap-1",e),...t})}function hp({className:e,...t}){return u.jsx("li",{"data-slot":"sidebar-menu-item","data-sidebar":"menu-item",className:D("group/menu-item relative",e),...t})}const gp=Ln("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-hidden ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-data-[sidebar=menu-action]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-accent data-[active=true]:font-medium data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",outline:"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm",sm:"h-7 text-xs",lg:"h-12 text-sm group-data-[collapsible=icon]:p-0!"}},defaultVariants:{variant:"default",size:"default"}});function vp({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:a,...s}){const i=e?tt:"button",{isMobile:c,state:p}=St(),d=u.jsx(i,{"data-slot":"sidebar-menu-button","data-sidebar":"menu-button","data-size":r,"data-active":t,className:D(gp({variant:n,size:r}),a),...s});return o?(typeof o=="string"&&(o={children:o}),u.jsxs(ks,{children:[u.jsx(Os,{asChild:!0,children:d}),u.jsx(Nr,{side:"right",align:"center",hidden:p!=="collapsed"||c,...o})]})):d}function bp({className:e,asChild:t=!1,showOnHover:n=!1,...r}){const o=t?tt:"button";return u.jsx(o,{"data-slot":"sidebar-menu-action","data-sidebar":"menu-action",className:D("text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground peer-hover/menu-button:text-sidebar-accent-foreground absolute top-1.5 right-1 flex aspect-square w-5 items-center justify-center rounded-md p-0 outline-hidden transition-transform focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 md:after:hidden","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",n&&"peer-data-[active=true]/menu-button:text-sidebar-accent-foreground group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 md:opacity-0",e),...r})}function xp({className:e,...t}){return u.jsx("div",{"data-slot":"sidebar-menu-badge","data-sidebar":"menu-badge",className:D("text-sidebar-foreground pointer-events-none absolute right-1 flex h-5 min-w-5 items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums select-none","peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",e),...t})}function wp({className:e,showIcon:t=!1,...n}){const r=l.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return u.jsxs("div",{"data-slot":"sidebar-menu-skeleton","data-sidebar":"menu-skeleton",className:D("flex h-8 items-center gap-2 rounded-md px-2",e),...n,children:[t&&u.jsx(dr,{className:"size-4 rounded-md","data-sidebar":"menu-skeleton-icon"}),u.jsx(dr,{className:"h-4 max-w-(--skeleton-width) flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":r}})]})}function Ws({className:e,...t}){return u.jsx("ul",{"data-slot":"sidebar-menu-sub","data-sidebar":"menu-sub",className:D("border-sidebar-border mx-3 flex min-w-0 translate-x-px flex-col gap-1 border-l px-2.5 py-0.5","group-data-[collapsible=icon]:hidden",e),...t})}function Gs({className:e,...t}){return u.jsx("li",{"data-slot":"sidebar-menu-sub-item","data-sidebar":"menu-sub-item",className:D("group/menu-sub-item relative",e),...t})}function Bs({asChild:e=!1,size:t="md",isActive:n=!1,className:r,...o}){const a=e?tt:"a";return u.jsx(a,{"data-slot":"sidebar-menu-sub-button","data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:D("text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground active:bg-sidebar-accent active:text-sidebar-accent-foreground [&>svg]:text-sidebar-accent-foreground flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 outline-hidden focus-visible:ring-2 disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0","data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground",t==="sm"&&"text-xs",t==="md"&&"text-sm","group-data-[collapsible=icon]:hidden",r),...o})}function Us({title:e,url:t,children:n,defaultOpen:r=!1,icon:o,isActive:a=!1}){const[s,i]=l.useState(r);return l.useEffect(()=>{a&&i(!0)},[a]),u.jsx(Hs,{children:u.jsxs("div",{className:"flex flex-col",children:[u.jsxs("div",{className:"flex flex-row items-center justify-between",children:[u.jsxs("a",{href:t,className:D("flex flex-1 cursor-pointer items-center gap-2 rounded-lg p-2 transition-colors hover:bg-gray-100"),children:[o&&u.jsx("span",{className:D("text-gray-600"),children:o}),u.jsx("span",{className:D("text-gray-600"),children:e})]}),u.jsx("button",{type:"button",className:"mr-3 rounded-lg p-2 text-gray-500 hover:bg-gray-100 hover:text-gray-700",onClick:c=>{c.preventDefault(),c.stopPropagation(),i(!s)},"aria-label":s?"Collapse section":"Expand section",children:s?u.jsx(Jc,{className:"h-4 w-4"}):u.jsx(yo,{className:"h-4 w-4"})})]}),u.jsx("div",{className:D("overflow-hidden transition-all",s?"max-h-96":"max-h-0"),children:n})]})})}function Ks(e){const t=e+"CollectionProvider",[n,r]=Xe(t),[o,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),s=g=>{const{scope:x,children:v}=g,w=I.useRef(null),E=I.useRef(new Map).current;return u.jsx(o,{scope:x,itemMap:E,collectionRef:w,children:v})};s.displayName=t;const i=e+"CollectionSlot",c=et(i),p=I.forwardRef((g,x)=>{const{scope:v,children:w}=g,E=a(i,v),S=ie(x,E.collectionRef);return u.jsx(c,{ref:S,children:w})});p.displayName=i;const d=e+"CollectionItemSlot",f="data-radix-collection-item",m=et(d),h=I.forwardRef((g,x)=>{const{scope:v,children:w,...E}=g,S=I.useRef(null),_=ie(x,S),T=a(d,v);return I.useEffect(()=>(T.itemMap.set(S,{ref:S,...E}),()=>void T.itemMap.delete(S))),u.jsx(m,{[f]:"",ref:_,children:w})});h.displayName=d;function b(g){const x=a(e+"CollectionConsumer",g);return I.useCallback(()=>{const w=x.collectionRef.current;if(!w)return[];const E=Array.from(w.querySelectorAll(`[${f}]`));return Array.from(x.itemMap.values()).sort((T,M)=>E.indexOf(T.ref.current)-E.indexOf(M.ref.current))},[x.collectionRef,x.itemMap])}return[{Provider:s,Slot:p,ItemSlot:h},b,r]}var yp=l.createContext(void 0);function Ys(e){const t=l.useContext(yp);return e||t||"ltr"}var kr="rovingFocusGroup.onEntryFocus",Cp={bubbles:!1,cancelable:!0},_t="RovingFocusGroup",[Or,qs,Ep]=Ks(_t),[Sp,Xs]=Xe(_t,[Ep]),[_p,Rp]=Sp(_t),Zs=l.forwardRef((e,t)=>u.jsx(Or.Provider,{scope:e.__scopeRovingFocusGroup,children:u.jsx(Or.Slot,{scope:e.__scopeRovingFocusGroup,children:u.jsx(Mp,{...e,ref:t})})}));Zs.displayName=_t;var Mp=l.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:a,currentTabStopId:s,defaultCurrentTabStopId:i,onCurrentTabStopIdChange:c,onEntryFocus:p,preventScrollOnEntryFocus:d=!1,...f}=e,m=l.useRef(null),h=ie(t,m),b=Ys(a),[g,x]=xt({prop:s,defaultProp:i??null,onChange:c,caller:_t}),[v,w]=l.useState(!1),E=_e(p),S=qs(n),_=l.useRef(!1),[T,M]=l.useState(0);return l.useEffect(()=>{const C=m.current;if(C)return C.addEventListener(kr,E),()=>C.removeEventListener(kr,E)},[E]),u.jsx(_p,{scope:n,orientation:r,dir:b,loop:o,currentTabStopId:g,onItemFocus:l.useCallback(C=>x(C),[x]),onItemShiftTab:l.useCallback(()=>w(!0),[]),onFocusableItemAdd:l.useCallback(()=>M(C=>C+1),[]),onFocusableItemRemove:l.useCallback(()=>M(C=>C-1),[]),children:u.jsx(re.div,{tabIndex:v||T===0?-1:0,"data-orientation":r,...f,ref:h,style:{outline:"none",...e.style},onMouseDown:$(e.onMouseDown,()=>{_.current=!0}),onFocus:$(e.onFocus,C=>{const j=!_.current;if(C.target===C.currentTarget&&j&&!v){const L=new CustomEvent(kr,Cp);if(C.currentTarget.dispatchEvent(L),!L.defaultPrevented){const U=S().filter(V=>V.focusable),B=U.find(V=>V.active),z=U.find(V=>V.id===g),X=[B,z,...U].filter(Boolean).map(V=>V.ref.current);ei(X,d)}}_.current=!1}),onBlur:$(e.onBlur,()=>w(!1))})})}),Js="RovingFocusGroupItem",Qs=l.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:a,children:s,...i}=e,c=De(),p=a||c,d=Rp(Js,n),f=d.currentTabStopId===p,m=qs(n),{onFocusableItemAdd:h,onFocusableItemRemove:b,currentTabStopId:g}=d;return l.useEffect(()=>{if(r)return h(),()=>b()},[r,h,b]),u.jsx(Or.ItemSlot,{scope:n,id:p,focusable:r,active:o,children:u.jsx(re.span,{tabIndex:f?0:-1,"data-orientation":d.orientation,...i,ref:t,onMouseDown:$(e.onMouseDown,x=>{r?d.onItemFocus(p):x.preventDefault()}),onFocus:$(e.onFocus,()=>d.onItemFocus(p)),onKeyDown:$(e.onKeyDown,x=>{if(x.key==="Tab"&&x.shiftKey){d.onItemShiftTab();return}if(x.target!==x.currentTarget)return;const v=Np(x,d.orientation,d.dir);if(v!==void 0){if(x.metaKey||x.ctrlKey||x.altKey||x.shiftKey)return;x.preventDefault();let E=m().filter(S=>S.focusable).map(S=>S.ref.current);if(v==="last")E.reverse();else if(v==="prev"||v==="next"){v==="prev"&&E.reverse();const S=E.indexOf(x.currentTarget);E=d.loop?kp(E,S+1):E.slice(S+1)}setTimeout(()=>ei(E))}}),children:typeof s=="function"?s({isCurrentTabStop:f,hasTabStop:g!=null}):s})})});Qs.displayName=Js;var Ap={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Tp(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function Np(e,t,n){const r=Tp(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return Ap[r]}function ei(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function kp(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Op=Zs,Pp=Qs,Pr=["Enter"," "],Dp=["ArrowDown","PageUp","Home"],ti=["ArrowUp","PageDown","End"],Ip=[...Dp,...ti],jp={ltr:[...Pr,"ArrowRight"],rtl:[...Pr,"ArrowLeft"]},Lp={ltr:["ArrowLeft"],rtl:["ArrowRight"]},Rt="Menu",[Mt,Fp,$p]=Ks(Rt),[Qe,ni]=Xe(Rt,[$p,dn,Xs]),At=dn(),ri=Xs(),[oi,Ue]=Qe(Rt),[Vp,Tt]=Qe(Rt),ai=e=>{const{__scopeMenu:t,open:n=!1,children:r,dir:o,onOpenChange:a,modal:s=!0}=e,i=At(t),[c,p]=l.useState(null),d=l.useRef(!1),f=_e(a),m=Ys(o);return l.useEffect(()=>{const h=()=>{d.current=!0,document.addEventListener("pointerdown",b,{capture:!0,once:!0}),document.addEventListener("pointermove",b,{capture:!0,once:!0})},b=()=>d.current=!1;return document.addEventListener("keydown",h,{capture:!0}),()=>{document.removeEventListener("keydown",h,{capture:!0}),document.removeEventListener("pointerdown",b,{capture:!0}),document.removeEventListener("pointermove",b,{capture:!0})}},[]),u.jsx(Rr,{...i,children:u.jsx(oi,{scope:t,open:n,onOpenChange:f,content:c,onContentChange:p,children:u.jsx(Vp,{scope:t,onClose:l.useCallback(()=>f(!1),[f]),isUsingKeyboardRef:d,dir:m,modal:s,children:r})})})};ai.displayName=Rt;var Hp="MenuAnchor",Dr=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=At(n);return u.jsx(bs,{...o,...r,ref:t})});Dr.displayName=Hp;var Ir="MenuPortal",[zp,si]=Qe(Ir,{forceMount:void 0}),ii=e=>{const{__scopeMenu:t,forceMount:n,children:r,container:o}=e,a=Ue(Ir,t);return u.jsx(zp,{scope:t,forceMount:n,children:u.jsx(Ie,{present:n||a.open,children:u.jsx(qn,{asChild:!0,container:o,children:r})})})};ii.displayName=Ir;var be="MenuContent",[Wp,jr]=Qe(be),ci=l.forwardRef((e,t)=>{const n=si(be,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,a=Ue(be,e.__scopeMenu),s=Tt(be,e.__scopeMenu);return u.jsx(Mt.Provider,{scope:e.__scopeMenu,children:u.jsx(Ie,{present:r||a.open,children:u.jsx(Mt.Slot,{scope:e.__scopeMenu,children:s.modal?u.jsx(Gp,{...o,ref:t}):u.jsx(Bp,{...o,ref:t})})})})}),Gp=l.forwardRef((e,t)=>{const n=Ue(be,e.__scopeMenu),r=l.useRef(null),o=ie(t,r);return l.useEffect(()=>{const a=r.current;if(a)return xa(a)},[]),u.jsx(Lr,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:$(e.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),Bp=l.forwardRef((e,t)=>{const n=Ue(be,e.__scopeMenu);return u.jsx(Lr,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),Up=et("MenuContent.ScrollLock"),Lr=l.forwardRef((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:o,onOpenAutoFocus:a,onCloseAutoFocus:s,disableOutsidePointerEvents:i,onEntryFocus:c,onEscapeKeyDown:p,onPointerDownOutside:d,onFocusOutside:f,onInteractOutside:m,onDismiss:h,disableOutsideScroll:b,...g}=e,x=Ue(be,n),v=Tt(be,n),w=At(n),E=ri(n),S=Fp(n),[_,T]=l.useState(null),M=l.useRef(null),C=ie(t,M,x.onContentChange),j=l.useRef(0),L=l.useRef(""),U=l.useRef(0),B=l.useRef(null),z=l.useRef("right"),W=l.useRef(0),X=b?tr:l.Fragment,V=b?{as:Up,allowPinchZoom:!0}:void 0,K=N=>{var Y,ee;const y=L.current+N,P=S().filter(te=>!te.disabled),F=document.activeElement,H=(Y=P.find(te=>te.ref.current===F))==null?void 0:Y.textValue,Z=P.map(te=>te.textValue),ne=om(Z,y,H),ue=(ee=P.find(te=>te.textValue===ne))==null?void 0:ee.ref.current;(function te(se){L.current=se,window.clearTimeout(j.current),se!==""&&(j.current=window.setTimeout(()=>te(""),1e3))})(y),ue&&setTimeout(()=>ue.focus())};l.useEffect(()=>()=>window.clearTimeout(j.current),[]),oa();const R=l.useCallback(N=>{var P,F;return z.current===((P=B.current)==null?void 0:P.side)&&sm(N,(F=B.current)==null?void 0:F.area)},[]);return u.jsx(Wp,{scope:n,searchRef:L,onItemEnter:l.useCallback(N=>{R(N)&&N.preventDefault()},[R]),onItemLeave:l.useCallback(N=>{var y;R(N)||((y=M.current)==null||y.focus(),T(null))},[R]),onTriggerLeave:l.useCallback(N=>{R(N)&&N.preventDefault()},[R]),pointerGraceTimerRef:U,onPointerGraceIntentChange:l.useCallback(N=>{B.current=N},[]),children:u.jsx(X,{...V,children:u.jsx(Yn,{asChild:!0,trapped:o,onMountAutoFocus:$(a,N=>{var y;N.preventDefault(),(y=M.current)==null||y.focus({preventScroll:!0})}),onUnmountAutoFocus:s,children:u.jsx(Gt,{asChild:!0,disableOutsidePointerEvents:i,onEscapeKeyDown:p,onPointerDownOutside:d,onFocusOutside:f,onInteractOutside:m,onDismiss:h,children:u.jsx(Op,{asChild:!0,...E,dir:v.dir,orientation:"vertical",loop:r,currentTabStopId:_,onCurrentTabStopIdChange:T,onEntryFocus:$(c,N=>{v.isUsingKeyboardRef.current||N.preventDefault()}),preventScrollOnEntryFocus:!0,children:u.jsx(xs,{role:"menu","aria-orientation":"vertical","data-state":Ri(x.open),"data-radix-menu-content":"",dir:v.dir,...w,...g,ref:C,style:{outline:"none",...g.style},onKeyDown:$(g.onKeyDown,N=>{const P=N.target.closest("[data-radix-menu-content]")===N.currentTarget,F=N.ctrlKey||N.altKey||N.metaKey,H=N.key.length===1;P&&(N.key==="Tab"&&N.preventDefault(),!F&&H&&K(N.key));const Z=M.current;if(N.target!==Z||!Ip.includes(N.key))return;N.preventDefault();const ue=S().filter(Y=>!Y.disabled).map(Y=>Y.ref.current);ti.includes(N.key)&&ue.reverse(),nm(ue)}),onBlur:$(e.onBlur,N=>{N.currentTarget.contains(N.target)||(window.clearTimeout(j.current),L.current="")}),onPointerMove:$(e.onPointerMove,kt(N=>{const y=N.target,P=W.current!==N.clientX;if(N.currentTarget.contains(y)&&P){const F=N.clientX>W.current?"right":"left";z.current=F,W.current=N.clientX}}))})})})})})})});ci.displayName=be;var Kp="MenuGroup",Fr=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.jsx(re.div,{role:"group",...r,ref:t})});Fr.displayName=Kp;var Yp="MenuLabel",li=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.jsx(re.div,{...r,ref:t})});li.displayName=Yp;var hn="MenuItem",ui="menu.itemSelect",gn=l.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:r,...o}=e,a=l.useRef(null),s=Tt(hn,e.__scopeMenu),i=jr(hn,e.__scopeMenu),c=ie(t,a),p=l.useRef(!1),d=()=>{const f=a.current;if(!n&&f){const m=new CustomEvent(ui,{bubbles:!0,cancelable:!0});f.addEventListener(ui,h=>r==null?void 0:r(h),{once:!0}),Bo(f,m),m.defaultPrevented?p.current=!1:s.onClose()}};return u.jsx(di,{...o,ref:c,disabled:n,onClick:$(e.onClick,d),onPointerDown:f=>{var m;(m=e.onPointerDown)==null||m.call(e,f),p.current=!0},onPointerUp:$(e.onPointerUp,f=>{var m;p.current||(m=f.currentTarget)==null||m.click()}),onKeyDown:$(e.onKeyDown,f=>{const m=i.searchRef.current!=="";n||m&&f.key===" "||Pr.includes(f.key)&&(f.currentTarget.click(),f.preventDefault())})})});gn.displayName=hn;var di=l.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:o,...a}=e,s=jr(hn,n),i=ri(n),c=l.useRef(null),p=ie(t,c),[d,f]=l.useState(!1),[m,h]=l.useState("");return l.useEffect(()=>{const b=c.current;b&&h((b.textContent??"").trim())},[a.children]),u.jsx(Mt.ItemSlot,{scope:n,disabled:r,textValue:o??m,children:u.jsx(Pp,{asChild:!0,...i,focusable:!r,children:u.jsx(re.div,{role:"menuitem","data-highlighted":d?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0,...a,ref:p,onPointerMove:$(e.onPointerMove,kt(b=>{r?s.onItemLeave(b):(s.onItemEnter(b),b.defaultPrevented||b.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:$(e.onPointerLeave,kt(b=>s.onItemLeave(b))),onFocus:$(e.onFocus,()=>f(!0)),onBlur:$(e.onBlur,()=>f(!1))})})})}),qp="MenuCheckboxItem",fi=l.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:r,...o}=e;return u.jsx(vi,{scope:e.__scopeMenu,checked:n,children:u.jsx(gn,{role:"menuitemcheckbox","aria-checked":vn(n)?"mixed":n,...o,ref:t,"data-state":Hr(n),onSelect:$(o.onSelect,()=>r==null?void 0:r(vn(n)?!0:!n),{checkForDefaultPrevented:!1})})})});fi.displayName=qp;var pi="MenuRadioGroup",[Xp,Zp]=Qe(pi,{value:void 0,onValueChange:()=>{}}),mi=l.forwardRef((e,t)=>{const{value:n,onValueChange:r,...o}=e,a=_e(r);return u.jsx(Xp,{scope:e.__scopeMenu,value:n,onValueChange:a,children:u.jsx(Fr,{...o,ref:t})})});mi.displayName=pi;var hi="MenuRadioItem",gi=l.forwardRef((e,t)=>{const{value:n,...r}=e,o=Zp(hi,e.__scopeMenu),a=n===o.value;return u.jsx(vi,{scope:e.__scopeMenu,checked:a,children:u.jsx(gn,{role:"menuitemradio","aria-checked":a,...r,ref:t,"data-state":Hr(a),onSelect:$(r.onSelect,()=>{var s;return(s=o.onValueChange)==null?void 0:s.call(o,n)},{checkForDefaultPrevented:!1})})})});gi.displayName=hi;var $r="MenuItemIndicator",[vi,Jp]=Qe($r,{checked:!1}),bi=l.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:r,...o}=e,a=Jp($r,n);return u.jsx(Ie,{present:r||vn(a.checked)||a.checked===!0,children:u.jsx(re.span,{...o,ref:t,"data-state":Hr(a.checked)})})});bi.displayName=$r;var Qp="MenuSeparator",xi=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.jsx(re.div,{role:"separator","aria-orientation":"horizontal",...r,ref:t})});xi.displayName=Qp;var em="MenuArrow",wi=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=At(n);return u.jsx(ws,{...o,...r,ref:t})});wi.displayName=em;var Vr="MenuSub",[tm,yi]=Qe(Vr),Ci=e=>{const{__scopeMenu:t,children:n,open:r=!1,onOpenChange:o}=e,a=Ue(Vr,t),s=At(t),[i,c]=l.useState(null),[p,d]=l.useState(null),f=_e(o);return l.useEffect(()=>(a.open===!1&&f(!1),()=>f(!1)),[a.open,f]),u.jsx(Rr,{...s,children:u.jsx(oi,{scope:t,open:r,onOpenChange:f,content:p,onContentChange:d,children:u.jsx(tm,{scope:t,contentId:De(),triggerId:De(),trigger:i,onTriggerChange:c,children:n})})})};Ci.displayName=Vr;var Nt="MenuSubTrigger",Ei=l.forwardRef((e,t)=>{const n=Ue(Nt,e.__scopeMenu),r=Tt(Nt,e.__scopeMenu),o=yi(Nt,e.__scopeMenu),a=jr(Nt,e.__scopeMenu),s=l.useRef(null),{pointerGraceTimerRef:i,onPointerGraceIntentChange:c}=a,p={__scopeMenu:e.__scopeMenu},d=l.useCallback(()=>{s.current&&window.clearTimeout(s.current),s.current=null},[]);return l.useEffect(()=>d,[d]),l.useEffect(()=>{const f=i.current;return()=>{window.clearTimeout(f),c(null)}},[i,c]),u.jsx(Dr,{asChild:!0,...p,children:u.jsx(di,{id:o.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":o.contentId,"data-state":Ri(n.open),...e,ref:$t(t,o.onTriggerChange),onClick:f=>{var m;(m=e.onClick)==null||m.call(e,f),!(e.disabled||f.defaultPrevented)&&(f.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:$(e.onPointerMove,kt(f=>{a.onItemEnter(f),!f.defaultPrevented&&!e.disabled&&!n.open&&!s.current&&(a.onPointerGraceIntentChange(null),s.current=window.setTimeout(()=>{n.onOpenChange(!0),d()},100))})),onPointerLeave:$(e.onPointerLeave,kt(f=>{var h,b;d();const m=(h=n.content)==null?void 0:h.getBoundingClientRect();if(m){const g=(b=n.content)==null?void 0:b.dataset.side,x=g==="right",v=x?-5:5,w=m[x?"left":"right"],E=m[x?"right":"left"];a.onPointerGraceIntentChange({area:[{x:f.clientX+v,y:f.clientY},{x:w,y:m.top},{x:E,y:m.top},{x:E,y:m.bottom},{x:w,y:m.bottom}],side:g}),window.clearTimeout(i.current),i.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(f),f.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:$(e.onKeyDown,f=>{var h;const m=a.searchRef.current!=="";e.disabled||m&&f.key===" "||jp[r.dir].includes(f.key)&&(n.onOpenChange(!0),(h=n.content)==null||h.focus(),f.preventDefault())})})})});Ei.displayName=Nt;var Si="MenuSubContent",_i=l.forwardRef((e,t)=>{const n=si(be,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,a=Ue(be,e.__scopeMenu),s=Tt(be,e.__scopeMenu),i=yi(Si,e.__scopeMenu),c=l.useRef(null),p=ie(t,c);return u.jsx(Mt.Provider,{scope:e.__scopeMenu,children:u.jsx(Ie,{present:r||a.open,children:u.jsx(Mt.Slot,{scope:e.__scopeMenu,children:u.jsx(Lr,{id:i.contentId,"aria-labelledby":i.triggerId,...o,ref:p,align:"start",side:s.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:d=>{var f;s.isUsingKeyboardRef.current&&((f=c.current)==null||f.focus()),d.preventDefault()},onCloseAutoFocus:d=>d.preventDefault(),onFocusOutside:$(e.onFocusOutside,d=>{d.target!==i.trigger&&a.onOpenChange(!1)}),onEscapeKeyDown:$(e.onEscapeKeyDown,d=>{s.onClose(),d.preventDefault()}),onKeyDown:$(e.onKeyDown,d=>{var h;const f=d.currentTarget.contains(d.target),m=Lp[s.dir].includes(d.key);f&&m&&(a.onOpenChange(!1),(h=i.trigger)==null||h.focus(),d.preventDefault())})})})})})});_i.displayName=Si;function Ri(e){return e?"open":"closed"}function vn(e){return e==="indeterminate"}function Hr(e){return vn(e)?"indeterminate":e?"checked":"unchecked"}function nm(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function rm(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function om(e,t,n){const o=t.length>1&&Array.from(t).every(p=>p===t[0])?t[0]:t,a=n?e.indexOf(n):-1;let s=rm(e,Math.max(a,0));o.length===1&&(s=s.filter(p=>p!==n));const c=s.find(p=>p.toLowerCase().startsWith(o.toLowerCase()));return c!==n?c:void 0}function am(e,t){const{x:n,y:r}=e;let o=!1;for(let a=0,s=t.length-1;a<t.length;s=a++){const i=t[a],c=t[s],p=i.x,d=i.y,f=c.x,m=c.y;d>r!=m>r&&n<(f-p)*(r-d)/(m-d)+p&&(o=!o)}return o}function sm(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return am(n,t)}function kt(e){return t=>t.pointerType==="mouse"?e(t):void 0}var im=ai,cm=Dr,lm=ii,um=ci,dm=Fr,fm=li,pm=gn,mm=fi,hm=mi,gm=gi,vm=bi,bm=xi,xm=wi,wm=Ci,ym=Ei,Cm=_i,bn="DropdownMenu",[Em,j0]=Xe(bn,[ni]),pe=ni(),[Sm,Mi]=Em(bn),Ai=e=>{const{__scopeDropdownMenu:t,children:n,dir:r,open:o,defaultOpen:a,onOpenChange:s,modal:i=!0}=e,c=pe(t),p=l.useRef(null),[d,f]=xt({prop:o,defaultProp:a??!1,onChange:s,caller:bn});return u.jsx(Sm,{scope:t,triggerId:De(),triggerRef:p,contentId:De(),open:d,onOpenChange:f,onOpenToggle:l.useCallback(()=>f(m=>!m),[f]),modal:i,children:u.jsx(im,{...c,open:d,onOpenChange:f,dir:r,modal:i,children:n})})};Ai.displayName=bn;var Ti="DropdownMenuTrigger",Ni=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:r=!1,...o}=e,a=Mi(Ti,n),s=pe(n);return u.jsx(cm,{asChild:!0,...s,children:u.jsx(re.button,{type:"button",id:a.triggerId,"aria-haspopup":"menu","aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":a.open?"open":"closed","data-disabled":r?"":void 0,disabled:r,...o,ref:$t(t,a.triggerRef),onPointerDown:$(e.onPointerDown,i=>{!r&&i.button===0&&i.ctrlKey===!1&&(a.onOpenToggle(),a.open||i.preventDefault())}),onKeyDown:$(e.onKeyDown,i=>{r||(["Enter"," "].includes(i.key)&&a.onOpenToggle(),i.key==="ArrowDown"&&a.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(i.key)&&i.preventDefault())})})})});Ni.displayName=Ti;var _m="DropdownMenuPortal",ki=e=>{const{__scopeDropdownMenu:t,...n}=e,r=pe(t);return u.jsx(lm,{...r,...n})};ki.displayName=_m;var Oi="DropdownMenuContent",Pi=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Mi(Oi,n),a=pe(n),s=l.useRef(!1);return u.jsx(um,{id:o.contentId,"aria-labelledby":o.triggerId,...a,...r,ref:t,onCloseAutoFocus:$(e.onCloseAutoFocus,i=>{var c;s.current||(c=o.triggerRef.current)==null||c.focus(),s.current=!1,i.preventDefault()}),onInteractOutside:$(e.onInteractOutside,i=>{const c=i.detail.originalEvent,p=c.button===0&&c.ctrlKey===!0,d=c.button===2||p;(!o.modal||d)&&(s.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Pi.displayName=Oi;var Rm="DropdownMenuGroup",Di=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(dm,{...o,...r,ref:t})});Di.displayName=Rm;var Mm="DropdownMenuLabel",Ii=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(fm,{...o,...r,ref:t})});Ii.displayName=Mm;var Am="DropdownMenuItem",ji=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(pm,{...o,...r,ref:t})});ji.displayName=Am;var Tm="DropdownMenuCheckboxItem",Li=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(mm,{...o,...r,ref:t})});Li.displayName=Tm;var Nm="DropdownMenuRadioGroup",Fi=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(hm,{...o,...r,ref:t})});Fi.displayName=Nm;var km="DropdownMenuRadioItem",$i=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(gm,{...o,...r,ref:t})});$i.displayName=km;var Om="DropdownMenuItemIndicator",Vi=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(vm,{...o,...r,ref:t})});Vi.displayName=Om;var Pm="DropdownMenuSeparator",Hi=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(bm,{...o,...r,ref:t})});Hi.displayName=Pm;var Dm="DropdownMenuArrow",Im=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(xm,{...o,...r,ref:t})});Im.displayName=Dm;var jm=e=>{const{__scopeDropdownMenu:t,children:n,open:r,onOpenChange:o,defaultOpen:a}=e,s=pe(t),[i,c]=xt({prop:r,defaultProp:a??!1,onChange:o,caller:"DropdownMenuSub"});return u.jsx(wm,{...s,open:i,onOpenChange:c,children:n})},Lm="DropdownMenuSubTrigger",zi=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(ym,{...o,...r,ref:t})});zi.displayName=Lm;var Fm="DropdownMenuSubContent",Wi=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(Cm,{...o,...r,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Wi.displayName=Fm;var $m=Ai,Vm=Ni,Gi=ki,Hm=Pi,zm=Di,Wm=Ii,Gm=ji,Bm=Li,Um=Fi,Km=$i,Bi=Vi,Ym=Hi,qm=jm,Xm=zi,Zm=Wi;function Ui({...e}){return u.jsx($m,{"data-slot":"dropdown-menu",...e})}function Jm({...e}){return u.jsx(Gi,{"data-slot":"dropdown-menu-portal",...e})}function Ki({...e}){return u.jsx(Vm,{"data-slot":"dropdown-menu-trigger",...e})}function Yi({className:e,sideOffset:t=4,...n}){return u.jsx(Gi,{children:u.jsx(Hm,{"data-slot":"dropdown-menu-content",sideOffset:t,className:D("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 max-h-(--radix-dropdown-menu-content-available-height) min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border p-1 shadow-md",e),...n})})}function Qm({...e}){return u.jsx(zm,{"data-slot":"dropdown-menu-group",...e})}function zr({className:e,inset:t,variant:n="default",...r}){return u.jsx(Gm,{"data-slot":"dropdown-menu-item","data-inset":t,"data-variant":n,className:D("focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...r})}function e0({className:e,children:t,checked:n,...r}){return u.jsxs(Bm,{"data-slot":"dropdown-menu-checkbox-item",className:D("focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),checked:n,...r,children:[u.jsx("span",{className:"pointer-events-none absolute left-2 flex size-3.5 items-center justify-center",children:u.jsx(Bi,{children:u.jsx(Zc,{className:"size-4"})})}),t]})}function t0({...e}){return u.jsx(Um,{"data-slot":"dropdown-menu-radio-group",...e})}function n0({className:e,children:t,...n}){return u.jsxs(Km,{"data-slot":"dropdown-menu-radio-item",className:D("focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...n,children:[u.jsx("span",{className:"pointer-events-none absolute left-2 flex size-3.5 items-center justify-center",children:u.jsx(Bi,{children:u.jsx(el,{className:"size-2 fill-current"})})}),t]})}function qi({className:e,inset:t,...n}){return u.jsx(Wm,{"data-slot":"dropdown-menu-label","data-inset":t,className:D("px-2 py-1.5 text-sm font-medium data-[inset]:pl-8",e),...n})}function Xi({className:e,...t}){return u.jsx(Ym,{"data-slot":"dropdown-menu-separator",className:D("bg-border -mx-1 my-1 h-px",e),...t})}function r0({className:e,...t}){return u.jsx("span",{"data-slot":"dropdown-menu-shortcut",className:D("text-muted-foreground ml-auto text-xs tracking-widest",e),...t})}function o0({...e}){return u.jsx(qm,{"data-slot":"dropdown-menu-sub",...e})}function a0({className:e,inset:t,children:n,...r}){return u.jsxs(Xm,{"data-slot":"dropdown-menu-sub-trigger","data-inset":t,className:D("focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-default items-center rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[inset]:pl-8",e),...r,children:[n,u.jsx(yo,{className:"ml-auto size-4"})]})}function s0({className:e,...t}){return u.jsx(Zm,{"data-slot":"dropdown-menu-sub-content",className:D("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg",e),...t})}const i0="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20141%2060'%3e%3cpath%20d='M0.059%2019.711V59.673H19.509V49.95H9.779V19.711H0.059Z'%20fill='%2385B9D1'%3e%3c/path%3e%3cpath%20d='M0%200L0.056%204.915V19.715H9.776V9.715H19.5V59.673H29.22V0H0Z'%20fill='%23F68029'%3e%3c/path%3e%3cpath%20d='M23.49%2019.717H9.776V29.439H23.49V19.717Z'%20fill='%23F68029'%3e%3c/path%3e%3cpath%20d='M0.0580006%2019.718L9.785%2029.445V19.718H0.0580006Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M9.777%2049.953L19.504%2059.679V49.953H9.777Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M50.213%2021.331C50.1839%2019.244%2050.325%2017.1581%2050.635%2015.094C50.8293%2013.6891%2051.2694%2012.3294%2051.935%2011.077C52.4295%2010.1519%2053.1979%209.4023%2054.135%208.93101C55.1033%208.49691%2056.1561%208.28375%2057.217%208.307C58.2628%208.27673%2059.3024%208.47715%2060.262%208.894C61.1441%209.33605%2061.8541%2010.059%2062.28%2010.949C62.8725%2012.1976%2063.2507%2013.5369%2063.399%2014.911C63.6554%2016.9922%2063.7717%2019.0882%2063.747%2021.185C63.7759%2023.338%2063.6421%2025.4901%2063.347%2027.623C63.1657%2029.0675%2062.7378%2030.4702%2062.082%2031.77C61.6022%2032.7122%2060.8471%2033.4862%2059.917%2033.989C58.9503%2034.4507%2057.888%2034.6768%2056.817%2034.649C55.7687%2034.6771%2054.7258%2034.4896%2053.753%2034.098C52.8534%2033.6775%2052.1275%2032.9579%2051.699%2032.062C51.0884%2030.7803%2050.7037%2029.4027%2050.562%2027.99C50.3018%2025.7802%2050.1852%2023.5559%2050.213%2021.331ZM54.913%2022.248C54.913%2023.6913%2054.9377%2024.9267%2054.987%2025.954C55.0147%2026.8043%2055.1127%2027.6509%2055.28%2028.485C55.3666%2029.0149%2055.5877%2029.5138%2055.922%2029.934C56.0643%2030.0868%2056.238%2030.207%2056.4312%2030.2862C56.6244%2030.3655%2056.8324%2030.4019%2057.041%2030.393C57.25%2030.3964%2057.4571%2030.3533%2057.6473%2030.2668C57.8375%2030.1803%2058.0062%2030.0526%2058.141%2029.893C58.4964%2029.4241%2058.7297%2028.8744%2058.82%2028.293C59.0025%2027.3609%2059.1128%2026.4161%2059.15%2025.467C59.2107%2024.3177%2059.2414%2022.936%2059.242%2021.322C59.242%2019.732%2059.224%2018.3747%2059.188%2017.25C59.169%2016.3373%2059.0736%2015.4278%2058.903%2014.531C58.8198%2013.9744%2058.5923%2013.4493%2058.243%2013.008C58.0929%2012.8491%2057.9104%2012.7244%2057.7078%2012.6422C57.5053%2012.5601%2057.2874%2012.5225%2057.069%2012.532C56.8667%2012.5304%2056.6668%2012.576%2056.4852%2012.6652C56.3036%2012.7544%2056.1453%2012.8848%2056.023%2013.046C55.6766%2013.5389%2055.4446%2014.103%2055.344%2014.697C55.1442%2015.6885%2055.0277%2016.695%2054.996%2017.706C54.9347%2018.9533%2054.904%2020.4697%2054.904%2022.255'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M83.329%2021.331C83.2999%2019.244%2083.441%2017.1581%2083.751%2015.094C83.9453%2013.6891%2084.3854%2012.3294%2085.051%2011.077C85.5455%2010.1519%2086.3139%209.40235%2087.251%208.93105C89.2087%208.112%2091.4106%208.09871%2093.378%208.89405C94.2601%209.33609%2094.9701%2010.0591%2095.396%2010.949C95.9885%2012.1976%2096.3667%2013.537%2096.515%2014.911C96.7714%2016.9922%2096.8877%2019.0883%2096.863%2021.185C96.8919%2023.3381%2096.7581%2025.4902%2096.463%2027.6231C96.2817%2029.0676%2095.8538%2030.4703%2095.198%2031.77C94.7182%2032.7123%2093.9631%2033.4862%2093.033%2033.989C92.0663%2034.4507%2091.004%2034.6769%2089.933%2034.649C88.8847%2034.6772%2087.8418%2034.4896%2086.869%2034.098C85.9694%2033.6775%2085.2435%2032.9579%2084.815%2032.062C84.2044%2030.7803%2083.8197%2029.4027%2083.678%2027.99C83.4178%2025.7803%2083.3012%2023.5559%2083.329%2021.331ZM88.029%2022.2481C88.029%2023.6914%2088.0537%2024.9267%2088.103%2025.954C88.1307%2026.8044%2088.2287%2027.6509%2088.396%2028.4851C88.4826%2029.015%2088.7037%2029.5139%2089.038%2029.934C89.1803%2030.0869%2089.354%2030.207%2089.5472%2030.2863C89.7404%2030.3655%2089.9484%2030.4019%2090.157%2030.393C90.366%2030.3964%2090.573%2030.3533%2090.7633%2030.2669C90.9535%2030.1804%2091.1222%2030.0527%2091.257%2029.893C91.6124%2029.4242%2091.8458%2028.8744%2091.936%2028.2931C92.1185%2027.3609%2092.2288%2026.4161%2092.266%2025.467C92.3267%2024.3177%2092.3574%2022.936%2092.358%2021.322C92.358%2019.732%2092.34%2018.3747%2092.304%2017.2501C92.2887%2016.3329%2092.1964%2015.4187%2092.028%2014.517C91.9448%2013.9605%2091.7173%2013.4354%2091.368%2012.994C91.2162%2012.8368%2091.0323%2012.7141%2090.8289%2012.6343C90.6255%2012.5544%2090.4072%2012.5192%2090.189%2012.531C89.9867%2012.5294%2089.7868%2012.575%2089.6052%2012.6643C89.4236%2012.7535%2089.2653%2012.8839%2089.143%2013.045C88.7966%2013.5379%2088.5646%2014.102%2088.464%2014.6961C88.2642%2015.6876%2088.1477%2016.6941%2088.116%2017.705C88.0547%2018.9524%2088.024%2020.4687%2088.024%2022.254'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M131.349%2034.65V8.32202H135.458V30.797H140.631V34.649L131.349%2034.65Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M71.95%2034.65V8.33203H76.059V30.796H81.232V34.648L71.95%2034.65Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M104.833%2014.692C104.934%2014.098%20105.166%2013.534%20105.512%2013.041C105.634%2012.8798%20105.793%2012.7494%20105.974%2012.6602C106.156%2012.571%20106.356%2012.5253%20106.558%2012.527H110.103V8.30798H106.703C105.642%208.2848%20104.589%208.49794%20103.621%208.93197C102.684%209.40306%20101.915%2010.1527%20101.421%2011.078C100.756%2012.3304%20100.316%2013.6901%20100.121%2015.095C99.8114%2017.1591%2099.6706%2019.245%2099.7%2021.332C99.6722%2023.5568%2099.7885%2025.7811%20100.048%2027.991C100.19%2029.4037%20100.574%2030.7812%20101.185%2032.063C101.614%2032.9584%20102.34%2033.6778%20103.239%2034.099C104.212%2034.4899%20105.255%2034.6771%20106.303%2034.649L110.103%2034.613V30.393H106.522C106.313%2030.402%20106.105%2030.3657%20105.912%2030.2866C105.719%2030.2076%20105.545%2030.0876%20105.403%2029.935C105.069%2029.5144%20104.848%2029.0152%20104.761%2028.485C104.594%2027.6509%20104.496%2026.8043%20104.468%2025.954C104.419%2024.9266%20104.394%2023.6916%20104.394%2022.249C104.394%2020.4636%20104.425%2018.9473%20104.486%2017.7C104.518%2016.6894%20104.633%2015.6832%20104.833%2014.692Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M46.728%2019.247H42.878V30.395H41.828C41.6182%2030.4039%2041.409%2030.3669%2041.2149%2030.2868C41.0208%2030.2067%2040.8465%2030.0853%2040.704%2029.931C40.3695%2029.5106%2040.1485%2029.0113%2040.062%2028.481C39.894%2027.647%2039.7956%2026.8004%2039.768%2025.95C39.7187%2024.9227%2039.6944%2023.6877%2039.695%2022.245C39.695%2020.4597%2039.7257%2018.9434%2039.787%2017.696C39.8191%2016.6854%2039.9355%2015.6792%2040.135%2014.688C40.2357%2014.094%2040.4677%2013.53%2040.814%2013.037C40.9376%2012.8768%2041.0968%2012.7476%2041.2791%2012.6598C41.4614%2012.5719%2041.6617%2012.5278%2041.864%2012.531H45.904V8.31202H42.012C40.9511%208.28877%2039.8983%208.50191%2038.93%208.93601C37.9927%209.40699%2037.2241%2010.1567%2036.73%2011.082C36.0644%2012.3344%2035.6243%2013.6941%2035.43%2015.099C35.1189%2017.1613%2034.9764%2019.2456%2035.004%2021.331C34.9762%2023.5559%2035.0925%2025.7802%2035.352%2027.99C35.494%2029.4026%2035.8787%2030.7802%2036.489%2032.062C36.9179%2032.9579%2037.6442%2033.6775%2038.544%2034.098C39.517%2034.4891%2040.5598%2034.6763%2041.608%2034.648L43.587%2034.629H46.727L46.728%2019.247Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M123.653%2029.87H118L116.691%2034.65H112.797L120.939%208L128.793%2034.65H124.856L123.653%2029.87ZM122.587%2026.212L120.893%2019.982L119.085%2026.212H122.587Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M39.016%2041.436H37.059V54.507H39.016V41.436Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M44.559%2041.436H46.384L48.331%2046.651C48.919%2048.1937%2049.4198%2049.7682%2049.831%2051.367C49.6744%2050.357%2049.5584%2049.4427%2049.483%2048.624C49.4077%2047.8054%2049.37%2047.0347%2049.37%2046.312V41.436H51.336V54.511H49.495L47.303%2048.627C47.103%2048.0797%2046.9134%2047.518%2046.734%2046.942C46.5547%2046.366%2046.39%2045.762%2046.24%2045.13C46.2274%2045.0507%2046.207%2044.9547%2046.179%2044.842C46.151%2044.7293%2046.1177%2044.5997%2046.079%2044.453C46.098%2044.6%2046.114%2044.725%2046.126%2044.829C46.138%2044.933%2046.148%2045.022%2046.154%2045.095L46.254%2046.424L46.354%2048.041C46.36%2048.131%2046.365%2048.241%2046.368%2048.371C46.371%2048.501%2046.368%2048.648%2046.368%2048.811L46.468%2054.511H44.559V41.436Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M55.493%2041.436H61.861V42.977H59.67V54.511H57.751V42.977H55.493V41.436Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M65.828%2041.436H71.028V42.926H67.787V47.065H70.665V48.555H67.787V53.016H71.028V54.506H65.828V41.436Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M75.906%2041.436H78.483C79.3332%2041.3696%2080.1787%2041.6132%2080.863%2042.122C81.2131%2042.4774%2081.4826%2042.904%2081.6531%2043.3729C81.8236%2043.8417%2081.8911%2044.3418%2081.851%2044.839C81.8876%2045.6248%2081.7066%2046.4055%2081.328%2047.095C81.1685%2047.3665%2080.9531%2047.6008%2080.696%2047.7826C80.4389%2047.9643%2080.1461%2048.0892%2079.837%2048.149L82.509%2054.507H80.525L77.863%2048.107V54.507H75.906V41.436ZM77.863%2047.227C78.1485%2047.2893%2078.4451%2047.279%2078.7256%2047.1969C79.0061%2047.1148%2079.2615%2046.9637%2079.4684%2046.7573C79.6753%2046.5509%2079.8271%2046.2959%2079.9098%2046.0156C79.9926%2045.7353%2080.0036%2045.4387%2079.942%2045.153C79.9472%2044.8034%2079.9137%2044.4543%2079.842%2044.112C79.7909%2043.8589%2079.6851%2043.62%2079.532%2043.412C79.3909%2043.2304%2079.2018%2043.0918%2078.986%2043.012C78.7308%2042.9221%2078.4615%2042.8791%2078.191%2042.885H77.862L77.863%2047.227Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M90.046%2041.06L85.913%2054.514H87.745L88.45%2051.974H91.496L92.135%2054.531H94.028L90.046%2041.06ZM88.876%2050.403L90.013%2046.703L91.048%2050.415L88.876%2050.403Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M106.344%2041.436H112.712V42.977H110.52V54.511H108.602V42.977H106.344V41.436Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M118.865%2041.462H116.908V54.533H118.865V41.462Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M134.181%2041.462H139.381V42.952H136.136V47.093H139.014V48.583H136.136V53.044H139.381V54.534H134.181V41.462Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M99.749%2044.338C99.8046%2044.0109%2099.9338%2043.7008%20100.127%2043.431C100.202%2043.3322%20100.3%2043.2523%20100.411%2043.1976C100.523%2043.1429%20100.646%2043.115%20100.77%2043.116H102.464V41.207H100.846C100.318%2041.1955%2099.7949%2041.3011%2099.313%2041.516C98.8543%2041.748%2098.4782%2042.1157%2098.236%2042.569C97.9008%2043.2016%2097.6788%2043.888%2097.58%2044.597C97.4215%2045.6561%2097.3493%2046.7263%2097.364%2047.797C97.3503%2048.9393%2097.4101%2050.0814%2097.543%2051.216C97.6145%2051.9294%2097.808%2052.6252%2098.115%2053.273C98.3244%2053.7086%2098.6776%2054.0586%2099.115%2054.264C99.6001%2054.458%20100.12%2054.5509%20100.642%2054.537L102.469%2054.52V52.61H100.755C100.629%2052.6147%20100.503%2052.592%20100.386%2052.5435C100.269%2052.495%20100.164%2052.4218%20100.078%2052.329C99.8888%2052.0951%2099.7637%2051.816%2099.715%2051.519C99.6273%2051.081%2099.5758%2050.6365%2099.561%2050.19C99.536%2049.66%2099.523%2049.014%2099.523%2048.27C99.523%2047.349%2099.539%2046.557%2099.57%2045.916C99.5873%2045.3865%2099.6485%2044.8594%2099.753%2044.34'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M128.799%2041.466L126.671%2048.91L124.671%2041.466H122.679L126.654%2054.953L130.774%2041.466H128.799Z'%20fill='%230A3763'%3e%3c/path%3e%3c/svg%3e";function c0(){const[e,t]=I.useState("");return I.useEffect(()=>{t(window.location.pathname);const r=()=>{t(window.location.pathname)},o=()=>{t(window.location.pathname)};return window.addEventListener("popstate",r),window.addEventListener("pushstate",o),window.addEventListener("replacestate",o),()=>{window.removeEventListener("popstate",r),window.removeEventListener("pushstate",o),window.removeEventListener("replacestate",o)}},[]),{currentPath:e,isActiveRoute:r=>!!(e===r||r!=="/"&&e.startsWith(r))}}const l0=I.createContext(void 0),u0=()=>{const e=I.useContext(l0);if(e===void 0)throw new Error("usePermissions must be used within PermissionsProvider");return e},d0={navMain:[{title:"Essential Insights",key:"essentialInsights",url:"/essential-insights/overall-performance",icon:u.jsx(Xc,{className:"h-5 w-5"}),items:[{title:"Overall Performance",url:"/essential-insights/overall-performance",icon:u.jsx(Co,{className:"h-4 w-4"})},{title:"Organic Performance",url:"/essential-insights/organic-performance",icon:u.jsx(wo,{className:"h-4 w-4"})},{title:"Paid Performance",url:"/essential-insights/paid-performance",icon:u.jsx(qc,{className:"h-4 w-4"})},{title:"Keyword Performance",url:"/essential-insights/keyword-performance",icon:u.jsx(wo,{className:"h-4 w-4"})},{title:"More Components",url:"/essential-insights/more-components",icon:u.jsx(Ft,{className:"h-4 w-4"})}]},{title:"Price Monster",key:"priceMonster",url:"/price-monster",icon:u.jsx(Qc,{className:"h-4 w-4"}),items:[{title:"Dashboard",url:"/price-monster/dashboard",icon:u.jsx(Ft,{className:"h-4 w-4"})},{title:"Documentation",url:"/price-monster/documentation",icon:u.jsx(Kc,{className:"h-4 w-4"})},{title:"Subscriptions",url:"/price-monster/subscriptions",icon:u.jsx(Yc,{className:"h-4 w-4"})}]},{title:"CMS",key:"web",url:"/cms",icon:u.jsx(Ft,{className:"h-4 w-4"}),items:[{title:"Dashboard",url:"/cms/dashboard",icon:u.jsx(Ft,{className:"h-4 w-4"})}]}]};function f0({...e}){const{isActiveRoute:t}=c0(),n=u0();return u.jsxs(Is,{...e,children:[u.jsx($s,{children:u.jsx("div",{className:"relative h-12 w-32 overflow-hidden",children:u.jsx("img",{src:i0,alt:"GLI Logo",className:"h-full w-full object-contain"})})}),u.jsxs(Vs,{children:[u.jsx("div",{className:"relative flex w-full min-w-0 flex-col px-2 py-1",children:u.jsx("div",{className:"flex flex-col",children:u.jsxs("a",{href:"/",className:D("flex cursor-pointer items-center gap-2 rounded-lg px-2 py-2 transition-colors","hover:bg-gray-100",t("/")&&"bg-blue-50 text-gli-bluedark font-medium"),children:[u.jsx(Co,{className:D("h-5 w-5",t("/")?"text-gli-bluedark":"text-gray-600")}),u.jsx("span",{children:"Home"})]})})}),d0.navMain.map(r=>{const o=!r.key||n[r.key],a=o&&(t(r.url)||r.items.some(s=>t(s.url)));return u.jsx(Us,{title:r.title,url:o?r.url:void 0,icon:r.icon,isActive:a,children:u.jsx(zs,{children:u.jsx(Ws,{children:r.items.map(s=>{const i=o&&t(s.url);return u.jsx(Gs,{children:u.jsx(Bs,{asChild:!0,children:u.jsxs("a",{href:o?s.url:void 0,className:D("flex items-center gap-2 pl-4 transition-colors",o?"text-muted-foreground hover:bg-muted hover:text-foreground":"text-gray-400 cursor-not-allowed opacity-50",i&&"bg-blue-50 text-gli-bluedark font-medium"),onClick:c=>{o||c.preventDefault()},children:[u.jsx("span",{className:D(i?"text-gli-bluedark":o?"text-muted-foreground":"text-gray-400"),children:s.icon}),u.jsx("span",{className:D(i?"text-gli-bluedark":o?"text-muted-foreground":"text-gray-400"),children:s.title})]})})},s.title)})})})},r.title)})]}),u.jsx(Ls,{})]})}const Zi=({onLogout:e})=>{const{user:t,error:n,isLoading:r}=Vc(),o=async()=>{try{e&&await e(),window.location.href="/auth/logout"}catch(a){console.error("Error during logout:",a),window.location.href="/auth/logout"}};return r?u.jsx("div",{className:"h-10 w-10 animate-pulse rounded-full bg-gray-200"}):n?u.jsxs("div",{children:["Error: ",n.message]}):t?u.jsx("div",{className:"relative flex items-center gap-3",children:u.jsxs(Ui,{children:[u.jsx(Ki,{asChild:!0,children:u.jsx(zt,{variant:"ghost",size:"lg",className:"rounded-full cursor-pointer p-0",children:t.picture?u.jsx("img",{src:t.picture,alt:t.name||"User profile",width:40,height:40,className:"rounded-full"}):u.jsx(Eo,{className:"h-5 w-5 text-gray-500"})})}),u.jsxs(Yi,{align:"end",className:"w-72",children:[u.jsx(qi,{children:u.jsx("div",{className:"flex flex-col space-y-1",children:u.jsxs("div",{className:"flex flex-col space-y-1",children:[u.jsx("p",{className:"text-xs text-gray-500",children:t.name}),u.jsx("p",{className:"truncate text-xs text-gray-500",children:t.email})]})})}),u.jsx(Xi,{}),u.jsx(zr,{asChild:!0,children:u.jsxs("a",{href:"/profile",className:"flex w-full cursor-default",children:[u.jsx(Eo,{className:"mr-2 h-4 w-4"}),u.jsx("span",{children:"Profile"})]})}),u.jsxs(zr,{onClick:o,children:[u.jsx(tl,{className:"mr-2 h-4 w-4"}),u.jsx("span",{children:"Sign out"})]})]})]})}):null},Ji=({onLogout:e})=>u.jsx("div",{className:"sticky top-0 z-50 bg-white",children:u.jsxs("header",{className:"flex h-16 items-center justify-between border-b bg-white px-4",children:[u.jsxs("div",{className:"flex h-full items-center gap-4 flex-1 min-w-0 overflow-hidden",children:[u.jsx(js,{}),u.jsx(Wt,{orientation:"vertical"})]}),u.jsx("div",{className:"flex-shrink-0",children:u.jsx(Zi,{onLogout:e})})]})}),p0=({children:e,onLogout:t})=>u.jsx(Hc,{children:u.jsx(Ds,{children:u.jsxs("div",{className:"flex h-screen w-full",children:[u.jsx(f0,{}),u.jsxs(Fs,{className:"flex-1 flex flex-col min-w-0",children:[u.jsx(Ji,{onLogout:t}),u.jsx("main",{className:"flex-1 bg-white overflow-auto",id:"page-content",children:e})]})]})})});A.AppHeader=Ji,A.Button=zt,A.Card=zl,A.CardAction=Ul,A.CardContent=Kl,A.CardDescription=Bl,A.CardFooter=Yl,A.CardHeader=Wl,A.CardTitle=Gl,A.CollapsibleSection=Us,A.DropdownMenu=Ui,A.DropdownMenuCheckboxItem=e0,A.DropdownMenuContent=Yi,A.DropdownMenuGroup=Qm,A.DropdownMenuItem=zr,A.DropdownMenuLabel=qi,A.DropdownMenuPortal=Jm,A.DropdownMenuRadioGroup=t0,A.DropdownMenuRadioItem=n0,A.DropdownMenuSeparator=Xi,A.DropdownMenuShortcut=r0,A.DropdownMenuSub=o0,A.DropdownMenuSubContent=s0,A.DropdownMenuSubTrigger=a0,A.DropdownMenuTrigger=Ki,A.GLICloudProvider=p0,A.Input=Gn,A.ProfileDropdown=Zi,A.Separator=Wt,A.Sheet=Ha,A.SheetClose=Sd,A.SheetContent=ir,A.SheetDescription=ur,A.SheetFooter=Wa,A.SheetHeader=cr,A.SheetOverlay=sr,A.SheetPortal=za,A.SheetTitle=lr,A.SheetTrigger=Ed,A.Sidebar=Is,A.SidebarContent=Vs,A.SidebarFooter=up,A.SidebarGroup=Hs,A.SidebarGroupAction=pp,A.SidebarGroupContent=zs,A.SidebarGroupLabel=fp,A.SidebarHeader=$s,A.SidebarInput=lp,A.SidebarInset=Fs,A.SidebarMenu=mp,A.SidebarMenuAction=bp,A.SidebarMenuBadge=xp,A.SidebarMenuButton=vp,A.SidebarMenuItem=hp,A.SidebarMenuSkeleton=wp,A.SidebarMenuSub=Ws,A.SidebarMenuSubButton=Bs,A.SidebarMenuSubItem=Gs,A.SidebarProvider=Ds,A.SidebarRail=Ls,A.SidebarSeparator=dp,A.SidebarTrigger=js,A.Skeleton=dr,A.Tooltip=ks,A.TooltipContent=Nr,A.TooltipProvider=Ns,A.TooltipTrigger=Os,A.buttonVariants=Go,A.useSidebar=St,Object.defineProperty(A,Symbol.toStringTag,{value:"Module"})});
182
+ For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return l.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},xd="DialogDescriptionWarning",yd=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${Is(xd).contentName}}.`;return l.useEffect(()=>{var s;const o=(s=e.current)==null?void 0:s.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},Cd=ys,Ed=Es,Sd=_s,js=Rs,Ls=Ms,Fs=Ts,$s=ks,Vs=Ps;const Hs=Cd,_d=Ed,Rd=Vs,zs=Sd,ar=l.forwardRef(({className:e,...t},n)=>u.jsx(js,{className:D("fixed inset-0 z-50 bg-background/80 backdrop-blur-sm data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:n}));ar.displayName=js.displayName;const Md=Ln("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4 border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),ir=l.forwardRef(({side:e="right",className:t,children:n,...r},o)=>u.jsxs(zs,{children:[u.jsx(ar,{}),u.jsxs(Ls,{ref:o,className:D(Md({side:e}),t),...r,children:[n,u.jsxs(Vs,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-secondary",children:[u.jsx(sl,{className:"h-4 w-4"}),u.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));ir.displayName=Ls.displayName;const cr=({className:e,...t})=>u.jsx("div",{className:D("flex flex-col space-y-2 text-center sm:text-left",e),...t});cr.displayName="SheetHeader";const Ws=({className:e,...t})=>u.jsx("div",{className:D("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});Ws.displayName="SheetFooter";const lr=l.forwardRef(({className:e,...t},n)=>u.jsx(Fs,{ref:n,className:D("text-lg font-semibold text-foreground",e),...t}));lr.displayName=Fs.displayName;const ur=l.forwardRef(({className:e,...t},n)=>u.jsx($s,{ref:n,className:D("text-sm text-muted-foreground",e),...t}));ur.displayName=$s.displayName;function dr({className:e,...t}){return u.jsx("div",{className:D("animate-pulse rounded-md bg-muted",e),...t})}const Ad=["top","right","bottom","left"],Ge=Math.min,he=Math.max,tn=Math.round,nn=Math.floor,Me=e=>({x:e,y:e}),Td={left:"right",right:"left",bottom:"top",top:"bottom"},Nd={start:"end",end:"start"};function fr(e,t,n){return he(e,Ge(t,n))}function je(e,t){return typeof e=="function"?e(t):e}function Le(e){return e.split("-")[0]}function lt(e){return e.split("-")[1]}function pr(e){return e==="x"?"y":"x"}function mr(e){return e==="y"?"height":"width"}function Ae(e){return["top","bottom"].includes(Le(e))?"y":"x"}function hr(e){return pr(Ae(e))}function kd(e,t,n){n===void 0&&(n=!1);const r=lt(e),o=hr(e),s=mr(o);let a=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(a=rn(a)),[a,rn(a)]}function Od(e){const t=rn(e);return[gr(e),t,gr(t)]}function gr(e){return e.replace(/start|end/g,t=>Nd[t])}function Pd(e,t,n){const r=["left","right"],o=["right","left"],s=["top","bottom"],a=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?s:a;default:return[]}}function Dd(e,t,n,r){const o=lt(e);let s=Pd(Le(e),n==="start",r);return o&&(s=s.map(a=>a+"-"+o),t&&(s=s.concat(s.map(gr)))),s}function rn(e){return e.replace(/left|right|bottom|top/g,t=>Td[t])}function Id(e){return{top:0,right:0,bottom:0,left:0,...e}}function Gs(e){return typeof e!="number"?Id(e):{top:e,right:e,bottom:e,left:e}}function on(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function Bs(e,t,n){let{reference:r,floating:o}=e;const s=Ae(t),a=hr(t),i=mr(a),c=Le(t),p=s==="y",d=r.x+r.width/2-o.width/2,f=r.y+r.height/2-o.height/2,m=r[i]/2-o[i]/2;let h;switch(c){case"top":h={x:d,y:r.y-o.height};break;case"bottom":h={x:d,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:f};break;case"left":h={x:r.x-o.width,y:f};break;default:h={x:r.x,y:r.y}}switch(lt(t)){case"start":h[a]-=m*(n&&p?-1:1);break;case"end":h[a]+=m*(n&&p?-1:1);break}return h}const jd=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:s=[],platform:a}=n,i=s.filter(Boolean),c=await(a.isRTL==null?void 0:a.isRTL(t));let p=await a.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:f}=Bs(p,r,c),m=r,h={},b=0;for(let g=0;g<i.length;g++){const{name:w,fn:v}=i[g],{x,y:E,data:S,reset:_}=await v({x:d,y:f,initialPlacement:r,placement:m,strategy:o,middlewareData:h,rects:p,platform:a,elements:{reference:e,floating:t}});d=x??d,f=E??f,h={...h,[w]:{...h[w],...S}},_&&b<=50&&(b++,typeof _=="object"&&(_.placement&&(m=_.placement),_.rects&&(p=_.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:o}):_.rects),{x:d,y:f}=Bs(p,m,c)),g=-1)}return{x:d,y:f,placement:m,strategy:o,middlewareData:h}};async function xt(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:s,rects:a,elements:i,strategy:c}=e,{boundary:p="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:m=!1,padding:h=0}=je(t,e),b=Gs(h),w=i[m?f==="floating"?"reference":"floating":f],v=on(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(w)))==null||n?w:w.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(i.floating)),boundary:p,rootBoundary:d,strategy:c})),x=f==="floating"?{x:r,y:o,width:a.floating.width,height:a.floating.height}:a.reference,E=await(s.getOffsetParent==null?void 0:s.getOffsetParent(i.floating)),S=await(s.isElement==null?void 0:s.isElement(E))?await(s.getScale==null?void 0:s.getScale(E))||{x:1,y:1}:{x:1,y:1},_=on(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:i,rect:x,offsetParent:E,strategy:c}):x);return{top:(v.top-_.top+b.top)/S.y,bottom:(_.bottom-v.bottom+b.bottom)/S.y,left:(v.left-_.left+b.left)/S.x,right:(_.right-v.right+b.right)/S.x}}const Ld=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:s,platform:a,elements:i,middlewareData:c}=t,{element:p,padding:d=0}=je(e,t)||{};if(p==null)return{};const f=Gs(d),m={x:n,y:r},h=hr(o),b=mr(h),g=await a.getDimensions(p),w=h==="y",v=w?"top":"left",x=w?"bottom":"right",E=w?"clientHeight":"clientWidth",S=s.reference[b]+s.reference[h]-m[h]-s.floating[b],_=m[h]-s.reference[h],T=await(a.getOffsetParent==null?void 0:a.getOffsetParent(p));let M=T?T[E]:0;(!M||!await(a.isElement==null?void 0:a.isElement(T)))&&(M=i.floating[E]||s.floating[b]);const C=S/2-_/2,j=M/2-g[b]/2-1,L=Ge(f[v],j),U=Ge(f[x],j),B=L,z=M-g[b]-U,W=M/2-g[b]/2+C,X=fr(B,W,z),V=!c.arrow&&lt(o)!=null&&W!==X&&s.reference[b]/2-(W<B?L:U)-g[b]/2<0,K=V?W<B?W-B:W-z:0;return{[h]:m[h]+K,data:{[h]:X,centerOffset:W-X-K,...V&&{alignmentOffset:K}},reset:V}}}),Fd=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:s,rects:a,initialPlacement:i,platform:c,elements:p}=t,{mainAxis:d=!0,crossAxis:f=!0,fallbackPlacements:m,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:g=!0,...w}=je(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const v=Le(o),x=Ae(i),E=Le(i)===i,S=await(c.isRTL==null?void 0:c.isRTL(p.floating)),_=m||(E||!g?[rn(i)]:Od(i)),T=b!=="none";!m&&T&&_.push(...Dd(i,g,b,S));const M=[i,..._],C=await xt(t,w),j=[];let L=((r=s.flip)==null?void 0:r.overflows)||[];if(d&&j.push(C[v]),f){const W=kd(o,a,S);j.push(C[W[0]],C[W[1]])}if(L=[...L,{placement:o,overflows:j}],!j.every(W=>W<=0)){var U,B;const W=(((U=s.flip)==null?void 0:U.index)||0)+1,X=M[W];if(X&&(!(f==="alignment"?x!==Ae(X):!1)||L.every(R=>R.overflows[0]>0&&Ae(R.placement)===x)))return{data:{index:W,overflows:L},reset:{placement:X}};let V=(B=L.filter(K=>K.overflows[0]<=0).sort((K,R)=>K.overflows[1]-R.overflows[1])[0])==null?void 0:B.placement;if(!V)switch(h){case"bestFit":{var z;const K=(z=L.filter(R=>{if(T){const N=Ae(R.placement);return N===x||N==="y"}return!0}).map(R=>[R.placement,R.overflows.filter(N=>N>0).reduce((N,y)=>N+y,0)]).sort((R,N)=>R[1]-N[1])[0])==null?void 0:z[0];K&&(V=K);break}case"initialPlacement":V=i;break}if(o!==V)return{reset:{placement:V}}}return{}}}};function Us(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Ks(e){return Ad.some(t=>e[t]>=0)}const $d=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=je(e,t);switch(r){case"referenceHidden":{const s=await xt(t,{...o,elementContext:"reference"}),a=Us(s,n.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:Ks(a)}}}case"escaped":{const s=await xt(t,{...o,altBoundary:!0}),a=Us(s,n.floating);return{data:{escapedOffsets:a,escaped:Ks(a)}}}default:return{}}}}};async function Vd(e,t){const{placement:n,platform:r,elements:o}=e,s=await(r.isRTL==null?void 0:r.isRTL(o.floating)),a=Le(n),i=lt(n),c=Ae(n)==="y",p=["left","top"].includes(a)?-1:1,d=s&&c?-1:1,f=je(t,e);let{mainAxis:m,crossAxis:h,alignmentAxis:b}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return i&&typeof b=="number"&&(h=i==="end"?b*-1:b),c?{x:h*d,y:m*p}:{x:m*p,y:h*d}}const Hd=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:s,placement:a,middlewareData:i}=t,c=await Vd(t,e);return a===((n=i.offset)==null?void 0:n.placement)&&(r=i.arrow)!=null&&r.alignmentOffset?{}:{x:o+c.x,y:s+c.y,data:{...c,placement:a}}}}},zd=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:s=!0,crossAxis:a=!1,limiter:i={fn:w=>{let{x:v,y:x}=w;return{x:v,y:x}}},...c}=je(e,t),p={x:n,y:r},d=await xt(t,c),f=Ae(Le(o)),m=pr(f);let h=p[m],b=p[f];if(s){const w=m==="y"?"top":"left",v=m==="y"?"bottom":"right",x=h+d[w],E=h-d[v];h=fr(x,h,E)}if(a){const w=f==="y"?"top":"left",v=f==="y"?"bottom":"right",x=b+d[w],E=b-d[v];b=fr(x,b,E)}const g=i.fn({...t,[m]:h,[f]:b});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[m]:s,[f]:a}}}}}},Wd=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:s,middlewareData:a}=t,{offset:i=0,mainAxis:c=!0,crossAxis:p=!0}=je(e,t),d={x:n,y:r},f=Ae(o),m=pr(f);let h=d[m],b=d[f];const g=je(i,t),w=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(c){const E=m==="y"?"height":"width",S=s.reference[m]-s.floating[E]+w.mainAxis,_=s.reference[m]+s.reference[E]-w.mainAxis;h<S?h=S:h>_&&(h=_)}if(p){var v,x;const E=m==="y"?"width":"height",S=["top","left"].includes(Le(o)),_=s.reference[f]-s.floating[E]+(S&&((v=a.offset)==null?void 0:v[f])||0)+(S?0:w.crossAxis),T=s.reference[f]+s.reference[E]+(S?0:((x=a.offset)==null?void 0:x[f])||0)-(S?w.crossAxis:0);b<_?b=_:b>T&&(b=T)}return{[m]:h,[f]:b}}}},Gd=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:s,platform:a,elements:i}=t,{apply:c=()=>{},...p}=je(e,t),d=await xt(t,p),f=Le(o),m=lt(o),h=Ae(o)==="y",{width:b,height:g}=s.floating;let w,v;f==="top"||f==="bottom"?(w=f,v=m===(await(a.isRTL==null?void 0:a.isRTL(i.floating))?"start":"end")?"left":"right"):(v=f,w=m==="end"?"top":"bottom");const x=g-d.top-d.bottom,E=b-d.left-d.right,S=Ge(g-d[w],x),_=Ge(b-d[v],E),T=!t.middlewareData.shift;let M=S,C=_;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(C=E),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(M=x),T&&!m){const L=he(d.left,0),U=he(d.right,0),B=he(d.top,0),z=he(d.bottom,0);h?C=b-2*(L!==0||U!==0?L+U:he(d.left,d.right)):M=g-2*(B!==0||z!==0?B+z:he(d.top,d.bottom))}await c({...t,availableWidth:C,availableHeight:M});const j=await a.getDimensions(i.floating);return b!==j.width||g!==j.height?{reset:{rects:!0}}:{}}}};function sn(){return typeof window<"u"}function ut(e){return Ys(e)?(e.nodeName||"").toLowerCase():"#document"}function ge(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Te(e){var t;return(t=(Ys(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Ys(e){return sn()?e instanceof Node||e instanceof ge(e).Node:!1}function Ce(e){return sn()?e instanceof Element||e instanceof ge(e).Element:!1}function Ne(e){return sn()?e instanceof HTMLElement||e instanceof ge(e).HTMLElement:!1}function qs(e){return!sn()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof ge(e).ShadowRoot}function yt(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=Ee(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function Bd(e){return["table","td","th"].includes(ut(e))}function an(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function vr(e){const t=br(),n=Ce(e)?Ee(e):e;return["transform","translate","scale","rotate","perspective"].some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","translate","scale","rotate","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function Ud(e){let t=Be(e);for(;Ne(t)&&!dt(t);){if(vr(t))return t;if(an(t))return null;t=Be(t)}return null}function br(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function dt(e){return["html","body","#document"].includes(ut(e))}function Ee(e){return ge(e).getComputedStyle(e)}function cn(e){return Ce(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Be(e){if(ut(e)==="html")return e;const t=e.assignedSlot||e.parentNode||qs(e)&&e.host||Te(e);return qs(t)?t.host:t}function Xs(e){const t=Be(e);return dt(t)?e.ownerDocument?e.ownerDocument.body:e.body:Ne(t)&&yt(t)?t:Xs(t)}function Ct(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=Xs(e),s=o===((r=e.ownerDocument)==null?void 0:r.body),a=ge(o);if(s){const i=wr(a);return t.concat(a,a.visualViewport||[],yt(o)?o:[],i&&n?Ct(i):[])}return t.concat(o,Ct(o,[],n))}function wr(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Zs(e){const t=Ee(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Ne(e),s=o?e.offsetWidth:n,a=o?e.offsetHeight:r,i=tn(n)!==s||tn(r)!==a;return i&&(n=s,r=a),{width:n,height:r,$:i}}function xr(e){return Ce(e)?e:e.contextElement}function ft(e){const t=xr(e);if(!Ne(t))return Me(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:s}=Zs(t);let a=(s?tn(n.width):n.width)/r,i=(s?tn(n.height):n.height)/o;return(!a||!Number.isFinite(a))&&(a=1),(!i||!Number.isFinite(i))&&(i=1),{x:a,y:i}}const Kd=Me(0);function Js(e){const t=ge(e);return!br()||!t.visualViewport?Kd:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Yd(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==ge(e)?!1:t}function Je(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),s=xr(e);let a=Me(1);t&&(r?Ce(r)&&(a=ft(r)):a=ft(e));const i=Yd(s,n,r)?Js(s):Me(0);let c=(o.left+i.x)/a.x,p=(o.top+i.y)/a.y,d=o.width/a.x,f=o.height/a.y;if(s){const m=ge(s),h=r&&Ce(r)?ge(r):r;let b=m,g=wr(b);for(;g&&r&&h!==b;){const w=ft(g),v=g.getBoundingClientRect(),x=Ee(g),E=v.left+(g.clientLeft+parseFloat(x.paddingLeft))*w.x,S=v.top+(g.clientTop+parseFloat(x.paddingTop))*w.y;c*=w.x,p*=w.y,d*=w.x,f*=w.y,c+=E,p+=S,b=ge(g),g=wr(b)}}return on({width:d,height:f,x:c,y:p})}function yr(e,t){const n=cn(e).scrollLeft;return t?t.left+n:Je(Te(e)).left+n}function Qs(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-(n?0:yr(e,r)),s=r.top+t.scrollTop;return{x:o,y:s}}function qd(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const s=o==="fixed",a=Te(r),i=t?an(t.floating):!1;if(r===a||i&&s)return n;let c={scrollLeft:0,scrollTop:0},p=Me(1);const d=Me(0),f=Ne(r);if((f||!f&&!s)&&((ut(r)!=="body"||yt(a))&&(c=cn(r)),Ne(r))){const h=Je(r);p=ft(r),d.x=h.x+r.clientLeft,d.y=h.y+r.clientTop}const m=a&&!f&&!s?Qs(a,c,!0):Me(0);return{width:n.width*p.x,height:n.height*p.y,x:n.x*p.x-c.scrollLeft*p.x+d.x+m.x,y:n.y*p.y-c.scrollTop*p.y+d.y+m.y}}function Xd(e){return Array.from(e.getClientRects())}function Zd(e){const t=Te(e),n=cn(e),r=e.ownerDocument.body,o=he(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=he(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+yr(e);const i=-n.scrollTop;return Ee(r).direction==="rtl"&&(a+=he(t.clientWidth,r.clientWidth)-o),{width:o,height:s,x:a,y:i}}function Jd(e,t){const n=ge(e),r=Te(e),o=n.visualViewport;let s=r.clientWidth,a=r.clientHeight,i=0,c=0;if(o){s=o.width,a=o.height;const p=br();(!p||p&&t==="fixed")&&(i=o.offsetLeft,c=o.offsetTop)}return{width:s,height:a,x:i,y:c}}function Qd(e,t){const n=Je(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,s=Ne(e)?ft(e):Me(1),a=e.clientWidth*s.x,i=e.clientHeight*s.y,c=o*s.x,p=r*s.y;return{width:a,height:i,x:c,y:p}}function ea(e,t,n){let r;if(t==="viewport")r=Jd(e,n);else if(t==="document")r=Zd(Te(e));else if(Ce(t))r=Qd(t,n);else{const o=Js(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return on(r)}function ta(e,t){const n=Be(e);return n===t||!Ce(n)||dt(n)?!1:Ee(n).position==="fixed"||ta(n,t)}function ef(e,t){const n=t.get(e);if(n)return n;let r=Ct(e,[],!1).filter(i=>Ce(i)&&ut(i)!=="body"),o=null;const s=Ee(e).position==="fixed";let a=s?Be(e):e;for(;Ce(a)&&!dt(a);){const i=Ee(a),c=vr(a);!c&&i.position==="fixed"&&(o=null),(s?!c&&!o:!c&&i.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||yt(a)&&!c&&ta(e,a))?r=r.filter(d=>d!==a):o=i,a=Be(a)}return t.set(e,r),r}function tf(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const a=[...n==="clippingAncestors"?an(t)?[]:ef(t,this._c):[].concat(n),r],i=a[0],c=a.reduce((p,d)=>{const f=ea(t,d,o);return p.top=he(f.top,p.top),p.right=Ge(f.right,p.right),p.bottom=Ge(f.bottom,p.bottom),p.left=he(f.left,p.left),p},ea(t,i,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function nf(e){const{width:t,height:n}=Zs(e);return{width:t,height:n}}function rf(e,t,n){const r=Ne(t),o=Te(t),s=n==="fixed",a=Je(e,!0,s,t);let i={scrollLeft:0,scrollTop:0};const c=Me(0);function p(){c.x=yr(o)}if(r||!r&&!s)if((ut(t)!=="body"||yt(o))&&(i=cn(t)),r){const h=Je(t,!0,s,t);c.x=h.x+t.clientLeft,c.y=h.y+t.clientTop}else o&&p();s&&!r&&o&&p();const d=o&&!r&&!s?Qs(o,i):Me(0),f=a.left+i.scrollLeft-c.x-d.x,m=a.top+i.scrollTop-c.y-d.y;return{x:f,y:m,width:a.width,height:a.height}}function Cr(e){return Ee(e).position==="static"}function na(e,t){if(!Ne(e)||Ee(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Te(e)===n&&(n=n.ownerDocument.body),n}function ra(e,t){const n=ge(e);if(an(e))return n;if(!Ne(e)){let o=Be(e);for(;o&&!dt(o);){if(Ce(o)&&!Cr(o))return o;o=Be(o)}return n}let r=na(e,t);for(;r&&Bd(r)&&Cr(r);)r=na(r,t);return r&&dt(r)&&Cr(r)&&!vr(r)?n:r||Ud(e)||n}const of=async function(e){const t=this.getOffsetParent||ra,n=this.getDimensions,r=await n(e.floating);return{reference:rf(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function sf(e){return Ee(e).direction==="rtl"}const af={convertOffsetParentRelativeRectToViewportRelativeRect:qd,getDocumentElement:Te,getClippingRect:tf,getOffsetParent:ra,getElementRects:of,getClientRects:Xd,getDimensions:nf,getScale:ft,isElement:Ce,isRTL:sf};function oa(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function cf(e,t){let n=null,r;const o=Te(e);function s(){var i;clearTimeout(r),(i=n)==null||i.disconnect(),n=null}function a(i,c){i===void 0&&(i=!1),c===void 0&&(c=1),s();const p=e.getBoundingClientRect(),{left:d,top:f,width:m,height:h}=p;if(i||t(),!m||!h)return;const b=nn(f),g=nn(o.clientWidth-(d+m)),w=nn(o.clientHeight-(f+h)),v=nn(d),E={rootMargin:-b+"px "+-g+"px "+-w+"px "+-v+"px",threshold:he(0,Ge(1,c))||1};let S=!0;function _(T){const M=T[0].intersectionRatio;if(M!==c){if(!S)return a();M?a(!1,M):r=setTimeout(()=>{a(!1,1e-7)},1e3)}M===1&&!oa(p,e.getBoundingClientRect())&&a(),S=!1}try{n=new IntersectionObserver(_,{...E,root:o.ownerDocument})}catch{n=new IntersectionObserver(_,E)}n.observe(e)}return a(!0),s}function lf(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:i=typeof IntersectionObserver=="function",animationFrame:c=!1}=r,p=xr(e),d=o||s?[...p?Ct(p):[],...Ct(t)]:[];d.forEach(v=>{o&&v.addEventListener("scroll",n,{passive:!0}),s&&v.addEventListener("resize",n)});const f=p&&i?cf(p,n):null;let m=-1,h=null;a&&(h=new ResizeObserver(v=>{let[x]=v;x&&x.target===p&&h&&(h.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var E;(E=h)==null||E.observe(t)})),n()}),p&&!c&&h.observe(p),h.observe(t));let b,g=c?Je(e):null;c&&w();function w(){const v=Je(e);g&&!oa(g,v)&&n(),g=v,b=requestAnimationFrame(w)}return n(),()=>{var v;d.forEach(x=>{o&&x.removeEventListener("scroll",n),s&&x.removeEventListener("resize",n)}),f==null||f(),(v=h)==null||v.disconnect(),h=null,c&&cancelAnimationFrame(b)}}const uf=Hd,df=zd,ff=Fd,pf=Gd,mf=$d,sa=Ld,hf=Wd,gf=(e,t,n)=>{const r=new Map,o={platform:af,...n},s={...o.platform,_c:r};return jd(e,t,{...o,platform:s})};var vf=typeof document<"u",bf=function(){},ln=vf?I.useLayoutEffect:bf;function un(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!un(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const s=o[r];if(!(s==="_owner"&&e.$$typeof)&&!un(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function aa(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function ia(e,t){const n=aa(e);return Math.round(t*n)/n}function Er(e){const t=l.useRef(e);return ln(()=>{t.current=e}),t}function wf(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:s,floating:a}={},transform:i=!0,whileElementsMounted:c,open:p}=e,[d,f]=l.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,h]=l.useState(r);un(m,r)||h(r);const[b,g]=l.useState(null),[w,v]=l.useState(null),x=l.useCallback(R=>{R!==T.current&&(T.current=R,g(R))},[]),E=l.useCallback(R=>{R!==M.current&&(M.current=R,v(R))},[]),S=s||b,_=a||w,T=l.useRef(null),M=l.useRef(null),C=l.useRef(d),j=c!=null,L=Er(c),U=Er(o),B=Er(p),z=l.useCallback(()=>{if(!T.current||!M.current)return;const R={placement:t,strategy:n,middleware:m};U.current&&(R.platform=U.current),gf(T.current,M.current,R).then(N=>{const y={...N,isPositioned:B.current!==!1};W.current&&!un(C.current,y)&&(C.current=y,Kr.flushSync(()=>{f(y)}))})},[m,t,n,U,B]);ln(()=>{p===!1&&C.current.isPositioned&&(C.current.isPositioned=!1,f(R=>({...R,isPositioned:!1})))},[p]);const W=l.useRef(!1);ln(()=>(W.current=!0,()=>{W.current=!1}),[]),ln(()=>{if(S&&(T.current=S),_&&(M.current=_),S&&_){if(L.current)return L.current(S,_,z);z()}},[S,_,z,L,j]);const X=l.useMemo(()=>({reference:T,floating:M,setReference:x,setFloating:E}),[x,E]),V=l.useMemo(()=>({reference:S,floating:_}),[S,_]),K=l.useMemo(()=>{const R={position:n,left:0,top:0};if(!V.floating)return R;const N=ia(V.floating,d.x),y=ia(V.floating,d.y);return i?{...R,transform:"translate("+N+"px, "+y+"px)",...aa(V.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:N,top:y}},[n,i,V.floating,d.x,d.y]);return l.useMemo(()=>({...d,update:z,refs:X,elements:V,floatingStyles:K}),[d,z,X,V,K])}const xf=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?sa({element:r.current,padding:o}).fn(n):{}:r?sa({element:r,padding:o}).fn(n):{}}}},yf=(e,t)=>({...uf(e),options:[e,t]}),Cf=(e,t)=>({...df(e),options:[e,t]}),Ef=(e,t)=>({...hf(e),options:[e,t]}),Sf=(e,t)=>({...ff(e),options:[e,t]}),_f=(e,t)=>({...pf(e),options:[e,t]}),Rf=(e,t)=>({...mf(e),options:[e,t]}),Mf=(e,t)=>({...xf(e),options:[e,t]});var Af="Arrow",ca=l.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...s}=e;return u.jsx(re.svg,{...s,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:u.jsx("polygon",{points:"0,0 30,0 15,10"})})});ca.displayName=Af;var Tf=ca;function Nf(e){const[t,n]=l.useState(void 0);return ze(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const s=o[0];let a,i;if("borderBoxSize"in s){const c=s.borderBoxSize,p=Array.isArray(c)?c[0]:c;a=p.inlineSize,i=p.blockSize}else a=e.offsetWidth,i=e.offsetHeight;n({width:a,height:i})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var Sr="Popper",[la,dn]=Xe(Sr),[kf,ua]=la(Sr),da=e=>{const{__scopePopper:t,children:n}=e,[r,o]=l.useState(null);return u.jsx(kf,{scope:t,anchor:r,onAnchorChange:o,children:n})};da.displayName=Sr;var fa="PopperAnchor",pa=l.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,s=ua(fa,n),a=l.useRef(null),i=ie(t,a);return l.useEffect(()=>{s.onAnchorChange((r==null?void 0:r.current)||a.current)}),r?null:u.jsx(re.div,{...o,ref:i})});pa.displayName=fa;var _r="PopperContent",[Of,Pf]=la(_r),ma=l.forwardRef((e,t)=>{var Y,ee,te,ae,Se,Ke;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:s="center",alignOffset:a=0,arrowPadding:i=0,avoidCollisions:c=!0,collisionBoundary:p=[],collisionPadding:d=0,sticky:f="partial",hideWhenDetached:m=!1,updatePositionStrategy:h="optimized",onPlaced:b,...g}=e,w=ua(_r,n),[v,x]=l.useState(null),E=ie(t,J=>x(J)),[S,_]=l.useState(null),T=Nf(S),M=(T==null?void 0:T.width)??0,C=(T==null?void 0:T.height)??0,j=r+(s!=="center"?"-"+s:""),L=typeof d=="number"?d:{top:0,right:0,bottom:0,left:0,...d},U=Array.isArray(p)?p:[p],B=U.length>0,z={padding:L,boundary:U.filter(If),altBoundary:B},{refs:W,floatingStyles:X,placement:V,isPositioned:K,middlewareData:R}=wf({strategy:"fixed",placement:j,whileElementsMounted:(...J)=>lf(...J,{animationFrame:h==="always"}),elements:{reference:w.anchor},middleware:[yf({mainAxis:o+C,alignmentAxis:a}),c&&Cf({mainAxis:!0,crossAxis:!1,limiter:f==="partial"?Ef():void 0,...z}),c&&Sf({...z}),_f({...z,apply:({elements:J,rects:Q,availableWidth:le,availableHeight:oe})=>{const{width:ve,height:Ye}=Q.reference,se=J.floating.style;se.setProperty("--radix-popper-available-width",`${le}px`),se.setProperty("--radix-popper-available-height",`${oe}px`),se.setProperty("--radix-popper-anchor-width",`${ve}px`),se.setProperty("--radix-popper-anchor-height",`${Ye}px`)}}),S&&Mf({element:S,padding:i}),jf({arrowWidth:M,arrowHeight:C}),m&&Rf({strategy:"referenceHidden",...z})]}),[N,y]=va(V),P=_e(b);ze(()=>{K&&(P==null||P())},[K,P]);const F=(Y=R.arrow)==null?void 0:Y.x,H=(ee=R.arrow)==null?void 0:ee.y,Z=((te=R.arrow)==null?void 0:te.centerOffset)!==0,[ne,ue]=l.useState();return ze(()=>{v&&ue(window.getComputedStyle(v).zIndex)},[v]),u.jsx("div",{ref:W.setFloating,"data-radix-popper-content-wrapper":"",style:{...X,transform:K?X.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ne,"--radix-popper-transform-origin":[(ae=R.transformOrigin)==null?void 0:ae.x,(Se=R.transformOrigin)==null?void 0:Se.y].join(" "),...((Ke=R.hide)==null?void 0:Ke.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:u.jsx(Of,{scope:n,placedSide:N,onArrowChange:_,arrowX:F,arrowY:H,shouldHideArrow:Z,children:u.jsx(re.div,{"data-side":N,"data-align":y,...g,ref:E,style:{...g.style,animation:K?void 0:"none"}})})})});ma.displayName=_r;var ha="PopperArrow",Df={top:"bottom",right:"left",bottom:"top",left:"right"},ga=l.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,s=Pf(ha,r),a=Df[s.placedSide];return u.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:u.jsx(Tf,{...o,ref:n,style:{...o.style,display:"block"}})})});ga.displayName=ha;function If(e){return e!==null}var jf=e=>({name:"transformOrigin",options:e,fn(t){var w,v,x;const{placement:n,rects:r,middlewareData:o}=t,a=((w=o.arrow)==null?void 0:w.centerOffset)!==0,i=a?0:e.arrowWidth,c=a?0:e.arrowHeight,[p,d]=va(n),f={start:"0%",center:"50%",end:"100%"}[d],m=(((v=o.arrow)==null?void 0:v.x)??0)+i/2,h=(((x=o.arrow)==null?void 0:x.y)??0)+c/2;let b="",g="";return p==="bottom"?(b=a?f:`${m}px`,g=`${-c}px`):p==="top"?(b=a?f:`${m}px`,g=`${r.floating.height+c}px`):p==="right"?(b=`${-c}px`,g=a?f:`${h}px`):p==="left"&&(b=`${r.floating.width+c}px`,g=a?f:`${h}px`),{data:{x:b,y:g}}}});function va(e){const[t,n="center"]=e.split("-");return[t,n]}var Rr=da,ba=pa,wa=ma,xa=ga,Lf=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),Ff="VisuallyHidden",ya=l.forwardRef((e,t)=>u.jsx(re.span,{...e,ref:t,style:{...Lf,...e.style}}));ya.displayName=Ff;var $f=ya,[fn,I0]=Xe("Tooltip",[dn]),pn=dn(),Ca="TooltipProvider",Vf=700,Mr="tooltip.open",[Hf,Ar]=fn(Ca),Ea=e=>{const{__scopeTooltip:t,delayDuration:n=Vf,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:s}=e,a=l.useRef(!0),i=l.useRef(!1),c=l.useRef(0);return l.useEffect(()=>{const p=c.current;return()=>window.clearTimeout(p)},[]),u.jsx(Hf,{scope:t,isOpenDelayedRef:a,delayDuration:n,onOpen:l.useCallback(()=>{window.clearTimeout(c.current),a.current=!1},[]),onClose:l.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>a.current=!0,r)},[r]),isPointerInTransitRef:i,onPointerInTransitChange:l.useCallback(p=>{i.current=p},[]),disableHoverableContent:o,children:s})};Ea.displayName=Ca;var Et="Tooltip",[zf,mn]=fn(Et),Sa=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o,onOpenChange:s,disableHoverableContent:a,delayDuration:i}=e,c=Ar(Et,e.__scopeTooltip),p=pn(t),[d,f]=l.useState(null),m=De(),h=l.useRef(0),b=a??c.disableHoverableContent,g=i??c.delayDuration,w=l.useRef(!1),[v,x]=wt({prop:r,defaultProp:o??!1,onChange:M=>{M?(c.onOpen(),document.dispatchEvent(new CustomEvent(Mr))):c.onClose(),s==null||s(M)},caller:Et}),E=l.useMemo(()=>v?w.current?"delayed-open":"instant-open":"closed",[v]),S=l.useCallback(()=>{window.clearTimeout(h.current),h.current=0,w.current=!1,x(!0)},[x]),_=l.useCallback(()=>{window.clearTimeout(h.current),h.current=0,x(!1)},[x]),T=l.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>{w.current=!0,x(!0),h.current=0},g)},[g,x]);return l.useEffect(()=>()=>{h.current&&(window.clearTimeout(h.current),h.current=0)},[]),u.jsx(Rr,{...p,children:u.jsx(zf,{scope:t,contentId:m,open:v,stateAttribute:E,trigger:d,onTriggerChange:f,onTriggerEnter:l.useCallback(()=>{c.isOpenDelayedRef.current?T():S()},[c.isOpenDelayedRef,T,S]),onTriggerLeave:l.useCallback(()=>{b?_():(window.clearTimeout(h.current),h.current=0)},[_,b]),onOpen:S,onClose:_,disableHoverableContent:b,children:n})})};Sa.displayName=Et;var Tr="TooltipTrigger",_a=l.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=mn(Tr,n),s=Ar(Tr,n),a=pn(n),i=l.useRef(null),c=ie(t,i,o.onTriggerChange),p=l.useRef(!1),d=l.useRef(!1),f=l.useCallback(()=>p.current=!1,[]);return l.useEffect(()=>()=>document.removeEventListener("pointerup",f),[f]),u.jsx(ba,{asChild:!0,...a,children:u.jsx(re.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:c,onPointerMove:$(e.onPointerMove,m=>{m.pointerType!=="touch"&&!d.current&&!s.isPointerInTransitRef.current&&(o.onTriggerEnter(),d.current=!0)}),onPointerLeave:$(e.onPointerLeave,()=>{o.onTriggerLeave(),d.current=!1}),onPointerDown:$(e.onPointerDown,()=>{o.open&&o.onClose(),p.current=!0,document.addEventListener("pointerup",f,{once:!0})}),onFocus:$(e.onFocus,()=>{p.current||o.onOpen()}),onBlur:$(e.onBlur,o.onClose),onClick:$(e.onClick,o.onClose)})})});_a.displayName=Tr;var Wf="TooltipPortal",[j0,Gf]=fn(Wf,{forceMount:void 0}),pt="TooltipContent",Ra=l.forwardRef((e,t)=>{const n=Gf(pt,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...s}=e,a=mn(pt,e.__scopeTooltip);return u.jsx(Ie,{present:r||a.open,children:a.disableHoverableContent?u.jsx(Ma,{side:o,...s,ref:t}):u.jsx(Bf,{side:o,...s,ref:t})})}),Bf=l.forwardRef((e,t)=>{const n=mn(pt,e.__scopeTooltip),r=Ar(pt,e.__scopeTooltip),o=l.useRef(null),s=ie(t,o),[a,i]=l.useState(null),{trigger:c,onClose:p}=n,d=o.current,{onPointerInTransitChange:f}=r,m=l.useCallback(()=>{i(null),f(!1)},[f]),h=l.useCallback((b,g)=>{const w=b.currentTarget,v={x:b.clientX,y:b.clientY},x=Xf(v,w.getBoundingClientRect()),E=Zf(v,x),S=Jf(g.getBoundingClientRect()),_=ep([...E,...S]);i(_),f(!0)},[f]);return l.useEffect(()=>()=>m(),[m]),l.useEffect(()=>{if(c&&d){const b=w=>h(w,d),g=w=>h(w,c);return c.addEventListener("pointerleave",b),d.addEventListener("pointerleave",g),()=>{c.removeEventListener("pointerleave",b),d.removeEventListener("pointerleave",g)}}},[c,d,h,m]),l.useEffect(()=>{if(a){const b=g=>{const w=g.target,v={x:g.clientX,y:g.clientY},x=(c==null?void 0:c.contains(w))||(d==null?void 0:d.contains(w)),E=!Qf(v,a);x?m():E&&(m(),p())};return document.addEventListener("pointermove",b),()=>document.removeEventListener("pointermove",b)}},[c,d,a,p,m]),u.jsx(Ma,{...e,ref:s})}),[Uf,Kf]=fn(Et,{isInside:!1}),Yf=il("TooltipContent"),Ma=l.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:s,onPointerDownOutside:a,...i}=e,c=mn(pt,n),p=pn(n),{onClose:d}=c;return l.useEffect(()=>(document.addEventListener(Mr,d),()=>document.removeEventListener(Mr,d)),[d]),l.useEffect(()=>{if(c.trigger){const f=m=>{const h=m.target;h!=null&&h.contains(c.trigger)&&d()};return window.addEventListener("scroll",f,{capture:!0}),()=>window.removeEventListener("scroll",f,{capture:!0})}},[c.trigger,d]),u.jsx(Gt,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:a,onFocusOutside:f=>f.preventDefault(),onDismiss:d,children:u.jsxs(wa,{"data-state":c.stateAttribute,...p,...i,ref:t,style:{...i.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[u.jsx(Yf,{children:r}),u.jsx(Uf,{scope:n,isInside:!0,children:u.jsx($f,{id:c.contentId,role:"tooltip",children:o||r})})]})})});Ra.displayName=pt;var Aa="TooltipArrow",qf=l.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=pn(n);return Kf(Aa,n).isInside?null:u.jsx(xa,{...o,...r,ref:t})});qf.displayName=Aa;function Xf(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),s=Math.abs(t.left-e.x);switch(Math.min(n,r,o,s)){case s:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function Zf(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function Jf(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function Qf(e,t){const{x:n,y:r}=e;let o=!1;for(let s=0,a=t.length-1;s<t.length;a=s++){const i=t[s],c=t[a],p=i.x,d=i.y,f=c.x,m=c.y;d>r!=m>r&&n<(f-p)*(r-d)/(m-d)+p&&(o=!o)}return o}function ep(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),tp(t)}function tp(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const o=e[r];for(;t.length>=2;){const s=t[t.length-1],a=t[t.length-2];if((s.x-a.x)*(o.y-a.y)>=(s.y-a.y)*(o.x-a.x))t.pop();else break}t.push(o)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;n.length>=2;){const s=n[n.length-1],a=n[n.length-2];if((s.x-a.x)*(o.y-a.y)>=(s.y-a.y)*(o.x-a.x))n.pop();else break}n.push(o)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var np=Ea,rp=Sa,op=_a,Ta=Ra;const Na=np,ka=rp,Oa=op,Nr=l.forwardRef(({className:e,sideOffset:t=4,...n},r)=>u.jsx(Ta,{ref:r,sideOffset:t,className:D("z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...n}));Nr.displayName=Ta.displayName;const sp="sidebar_state",ap=60*60*24*7,ip="16rem",cp="18rem",lp="3rem",up="b",Pa=l.createContext(null);function St(){const e=l.useContext(Pa);if(!e)throw new Error("useSidebar must be used within a SidebarProvider.");return e}function Da({defaultOpen:e=!0,open:t,onOpenChange:n,className:r,style:o,children:s,...a}){const i=Zl(),[c,p]=l.useState(!1),[d,f]=l.useState(e),m=t??d,h=l.useCallback(v=>{const x=typeof v=="function"?v(m):v;n?n(x):f(x),document.cookie=`${sp}=${x}; path=/; max-age=${ap}`},[n,m]),b=l.useCallback(()=>i?p(v=>!v):h(v=>!v),[i,h,p]);l.useEffect(()=>{const v=x=>{x.key===up&&(x.metaKey||x.ctrlKey)&&(x.preventDefault(),b())};return window.addEventListener("keydown",v),()=>window.removeEventListener("keydown",v)},[b]);const g=m?"expanded":"collapsed",w=l.useMemo(()=>({state:g,open:m,setOpen:h,isMobile:i,openMobile:c,setOpenMobile:p,toggleSidebar:b}),[g,m,h,i,c,p,b]);return u.jsx(Pa.Provider,{value:w,children:u.jsx(Na,{delayDuration:0,children:u.jsx("div",{"data-slot":"sidebar-wrapper",style:{"--sidebar-width":ip,"--sidebar-width-icon":lp,...o},className:D("group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex min-h-svh w-full",r),...a,children:s})})})}function Ia({side:e="left",variant:t="sidebar",collapsible:n="offcanvas",className:r,children:o,...s}){const{isMobile:a,state:i,openMobile:c,setOpenMobile:p}=St();return n==="none"?u.jsx("div",{"data-slot":"sidebar",className:D("bg-white text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col",r),...s,children:o}):a?u.jsx(Hs,{open:c,onOpenChange:p,...s,children:u.jsxs(ir,{"data-sidebar":"sidebar","data-slot":"sidebar","data-mobile":"true",className:"bg-white text-sidebar-foreground w-(--sidebar-width) p-0 [&>button]:hidden",style:{"--sidebar-width":cp},side:e,children:[u.jsxs(cr,{className:"sr-only",children:[u.jsx(lr,{children:"Sidebar"}),u.jsx(ur,{children:"Displays the mobile sidebar."})]}),u.jsx("div",{className:"flex h-full w-full flex-col",children:o})]})}):u.jsxs("div",{className:"group peer text-sidebar-foreground hidden md:block","data-state":i,"data-collapsible":i==="collapsed"?n:"","data-variant":t,"data-side":e,"data-slot":"sidebar",children:[u.jsx("div",{"data-slot":"sidebar-gap",className:D("relative w-(--sidebar-width) bg-white transition-[width] duration-200 ease-linear","group-data-[collapsible=offcanvas]:w-0","group-data-[side=right]:rotate-180",t==="floating"||t==="inset"?"group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]":"group-data-[collapsible=icon]:w-(--sidebar-width-icon)")}),u.jsx("div",{"data-slot":"sidebar-container",className:D("fixed inset-y-0 z-10 hidden h-svh w-(--sidebar-width) transition-[left,right,width] duration-200 ease-linear md:flex",e==="left"?"left-0 group-data-[collapsible=offcanvas]:left-[calc(var(--sidebar-width)*-1)]":"right-0 group-data-[collapsible=offcanvas]:right-[calc(var(--sidebar-width)*-1)]",t==="floating"||t==="inset"?"p-2 group-data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4))+2px)]":"group-data-[collapsible=icon]:w-(--sidebar-width-icon) group-data-[side=left]:border-r group-data-[side=right]:border-l",r),...s,children:u.jsx("div",{"data-sidebar":"sidebar","data-slot":"sidebar-inner",className:"bg-white group-data-[variant=floating]:border-sidebar-border flex h-full w-full flex-col px-1 py-2 group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:shadow-sm",children:o})})]})}function ja({className:e,onClick:t,...n}){const{toggleSidebar:r}=St();return u.jsxs(zt,{"data-sidebar":"trigger","data-slot":"sidebar-trigger",variant:"ghost",size:"icon",className:D("size-7",e),onClick:o=>{t==null||t(o),r()},...n,children:[u.jsx(ol,{}),u.jsx("span",{className:"sr-only",children:"Toggle Sidebar"})]})}function La({className:e,...t}){const{toggleSidebar:n}=St();return u.jsx("button",{"data-sidebar":"rail","data-slot":"sidebar-rail","aria-label":"Toggle Sidebar",tabIndex:-1,onClick:n,title:"Toggle Sidebar",className:D("hover:after:bg-sidebar-border absolute inset-y-0 z-20 hidden w-4 -translate-x-1/2 transition-all ease-linear group-data-[side=left]:-right-4 group-data-[side=right]:left-0 after:absolute after:inset-y-0 after:left-1/2 after:w-[2px] sm:flex","in-data-[side=left]:cursor-w-resize in-data-[side=right]:cursor-e-resize","[[data-side=left][data-state=collapsed]_&]:cursor-e-resize [[data-side=right][data-state=collapsed]_&]:cursor-w-resize","hover:group-data-[collapsible=offcanvas]:bg-sidebar group-data-[collapsible=offcanvas]:translate-x-0 group-data-[collapsible=offcanvas]:after:left-full","[[data-side=left][data-collapsible=offcanvas]_&]:-right-2","[[data-side=right][data-collapsible=offcanvas]_&]:-left-2",e),...t})}function Fa({className:e,...t}){return u.jsx("main",{"data-slot":"sidebar-inset",className:D("bg-white relative flex w-full flex-1 flex-col","md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow-sm md:peer-data-[variant=inset]:peer-data-[state=collapsed]:ml-2",e),...t})}function dp({className:e,...t}){return u.jsx(Gn,{"data-slot":"sidebar-input","data-sidebar":"input",className:D("bg-background h-8 w-full shadow-none",e),...t})}function $a({className:e,...t}){return u.jsx("div",{"data-slot":"sidebar-header","data-sidebar":"header",className:D("flex flex-col gap-2 p-2",e),...t})}function fp({className:e,...t}){return u.jsx("div",{"data-slot":"sidebar-footer","data-sidebar":"footer",className:D("flex flex-col gap-2 p-2",e),...t})}function pp({className:e,...t}){return u.jsx(Wt,{"data-slot":"sidebar-separator","data-sidebar":"separator",className:D("bg-sidebar-border mx-2 w-auto",e),...t})}function Va({className:e,...t}){return u.jsx("div",{"data-slot":"sidebar-content","data-sidebar":"content",className:D("flex min-h-0 flex-1 flex-col overflow-auto group-data-[collapsible=icon]:overflow-hidden",e),...t})}function Ha({className:e,...t}){return u.jsx("div",{"data-slot":"sidebar-group","data-sidebar":"group",className:D("relative flex w-full min-w-0 flex-col px-2 py-1",e),...t})}function mp({className:e,asChild:t=!1,...n}){const r=t?tt:"div";return u.jsx(r,{"data-slot":"sidebar-group-label","data-sidebar":"group-label",className:D("text-sidebar-foreground/70 ring-sidebar-ring flex h-8 shrink-0 items-center rounded-md px-2 text-xs font-medium outline-hidden transition-[margin,opacity] duration-200 ease-linear focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","group-data-[collapsible=icon]:-mt-8 group-data-[collapsible=icon]:opacity-0",e),...n})}function hp({className:e,asChild:t=!1,...n}){const r=t?tt:"button";return u.jsx(r,{"data-slot":"sidebar-group-action","data-sidebar":"group-action",className:D("text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground absolute top-3.5 right-3 flex aspect-square w-5 items-center justify-center rounded-md p-0 outline-hidden transition-transform focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 md:after:hidden","group-data-[collapsible=icon]:hidden",e),...n})}function za({className:e,...t}){return u.jsx("div",{"data-slot":"sidebar-group-content","data-sidebar":"group-content",className:D("w-full text-sm",e),...t})}function gp({className:e,...t}){return u.jsx("ul",{"data-slot":"sidebar-menu","data-sidebar":"menu",className:D("flex w-full min-w-0 flex-col gap-1",e),...t})}function vp({className:e,...t}){return u.jsx("li",{"data-slot":"sidebar-menu-item","data-sidebar":"menu-item",className:D("group/menu-item relative",e),...t})}const bp=Ln("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md p-2 text-left text-sm outline-hidden ring-sidebar-ring transition-[width,height,padding] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground focus-visible:ring-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-data-[sidebar=menu-action]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-accent data-[active=true]:font-medium data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2! [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0",{variants:{variant:{default:"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",outline:"bg-background shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm",sm:"h-7 text-xs",lg:"h-12 text-sm group-data-[collapsible=icon]:p-0!"}},defaultVariants:{variant:"default",size:"default"}});function wp({asChild:e=!1,isActive:t=!1,variant:n="default",size:r="default",tooltip:o,className:s,...a}){const i=e?tt:"button",{isMobile:c,state:p}=St(),d=u.jsx(i,{"data-slot":"sidebar-menu-button","data-sidebar":"menu-button","data-size":r,"data-active":t,className:D(bp({variant:n,size:r}),s),...a});return o?(typeof o=="string"&&(o={children:o}),u.jsxs(ka,{children:[u.jsx(Oa,{asChild:!0,children:d}),u.jsx(Nr,{side:"right",align:"center",hidden:p!=="collapsed"||c,...o})]})):d}function xp({className:e,asChild:t=!1,showOnHover:n=!1,...r}){const o=t?tt:"button";return u.jsx(o,{"data-slot":"sidebar-menu-action","data-sidebar":"menu-action",className:D("text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground peer-hover/menu-button:text-sidebar-accent-foreground absolute top-1.5 right-1 flex aspect-square w-5 items-center justify-center rounded-md p-0 outline-hidden transition-transform focus-visible:ring-2 [&>svg]:size-4 [&>svg]:shrink-0","after:absolute after:-inset-2 md:after:hidden","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",n&&"peer-data-[active=true]/menu-button:text-sidebar-accent-foreground group-focus-within/menu-item:opacity-100 group-hover/menu-item:opacity-100 data-[state=open]:opacity-100 md:opacity-0",e),...r})}function yp({className:e,...t}){return u.jsx("div",{"data-slot":"sidebar-menu-badge","data-sidebar":"menu-badge",className:D("text-sidebar-foreground pointer-events-none absolute right-1 flex h-5 min-w-5 items-center justify-center rounded-md px-1 text-xs font-medium tabular-nums select-none","peer-hover/menu-button:text-sidebar-accent-foreground peer-data-[active=true]/menu-button:text-sidebar-accent-foreground","peer-data-[size=sm]/menu-button:top-1","peer-data-[size=default]/menu-button:top-1.5","peer-data-[size=lg]/menu-button:top-2.5","group-data-[collapsible=icon]:hidden",e),...t})}function Cp({className:e,showIcon:t=!1,...n}){const r=l.useMemo(()=>`${Math.floor(Math.random()*40)+50}%`,[]);return u.jsxs("div",{"data-slot":"sidebar-menu-skeleton","data-sidebar":"menu-skeleton",className:D("flex h-8 items-center gap-2 rounded-md px-2",e),...n,children:[t&&u.jsx(dr,{className:"size-4 rounded-md","data-sidebar":"menu-skeleton-icon"}),u.jsx(dr,{className:"h-4 max-w-(--skeleton-width) flex-1","data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":r}})]})}function Wa({className:e,...t}){return u.jsx("ul",{"data-slot":"sidebar-menu-sub","data-sidebar":"menu-sub",className:D("border-sidebar-border mx-3 flex min-w-0 translate-x-px flex-col gap-1 border-l px-2.5 py-0.5","group-data-[collapsible=icon]:hidden",e),...t})}function Ga({className:e,...t}){return u.jsx("li",{"data-slot":"sidebar-menu-sub-item","data-sidebar":"menu-sub-item",className:D("group/menu-sub-item relative",e),...t})}function Ba({asChild:e=!1,size:t="md",isActive:n=!1,className:r,...o}){const s=e?tt:"a";return u.jsx(s,{"data-slot":"sidebar-menu-sub-button","data-sidebar":"menu-sub-button","data-size":t,"data-active":n,className:D("text-sidebar-foreground ring-sidebar-ring hover:bg-sidebar-accent hover:text-sidebar-accent-foreground active:bg-sidebar-accent active:text-sidebar-accent-foreground [&>svg]:text-sidebar-accent-foreground flex h-7 min-w-0 -translate-x-px items-center gap-2 overflow-hidden rounded-md px-2 outline-hidden focus-visible:ring-2 disabled:pointer-events-none disabled:opacity-50 aria-disabled:pointer-events-none aria-disabled:opacity-50 [&>span:last-child]:truncate [&>svg]:size-4 [&>svg]:shrink-0","data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground",t==="sm"&&"text-xs",t==="md"&&"text-sm","group-data-[collapsible=icon]:hidden",r),...o})}function Ua({title:e,url:t,children:n,defaultOpen:r=!1,icon:o,isActive:s=!1}){const[a,i]=l.useState(r);return l.useEffect(()=>{s&&i(!0)},[s]),u.jsx(Ha,{children:u.jsxs("div",{className:"flex flex-col",children:[u.jsxs("div",{className:"flex flex-row items-center justify-between",children:[u.jsxs("a",{href:t,className:D("flex flex-1 cursor-pointer items-center gap-2 rounded-lg p-2 transition-colors hover:bg-gray-100"),children:[o&&u.jsx("span",{className:D("text-gray-600"),children:o}),u.jsx("span",{className:D("text-gray-600"),children:e})]}),u.jsx("button",{type:"button",className:"mr-3 rounded-lg p-2 text-gray-500 hover:bg-gray-100 hover:text-gray-700",onClick:c=>{c.preventDefault(),c.stopPropagation(),i(!a)},"aria-label":a?"Collapse section":"Expand section",children:a?u.jsx(el,{className:"h-4 w-4"}):u.jsx(yo,{className:"h-4 w-4"})})]}),u.jsx("div",{className:D("overflow-hidden transition-all",a?"max-h-96":"max-h-0"),children:n})]})})}function Ka(e){const t=e+"CollectionProvider",[n,r]=Xe(t),[o,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=g=>{const{scope:w,children:v}=g,x=I.useRef(null),E=I.useRef(new Map).current;return u.jsx(o,{scope:w,itemMap:E,collectionRef:x,children:v})};a.displayName=t;const i=e+"CollectionSlot",c=et(i),p=I.forwardRef((g,w)=>{const{scope:v,children:x}=g,E=s(i,v),S=ie(w,E.collectionRef);return u.jsx(c,{ref:S,children:x})});p.displayName=i;const d=e+"CollectionItemSlot",f="data-radix-collection-item",m=et(d),h=I.forwardRef((g,w)=>{const{scope:v,children:x,...E}=g,S=I.useRef(null),_=ie(w,S),T=s(d,v);return I.useEffect(()=>(T.itemMap.set(S,{ref:S,...E}),()=>void T.itemMap.delete(S))),u.jsx(m,{[f]:"",ref:_,children:x})});h.displayName=d;function b(g){const w=s(e+"CollectionConsumer",g);return I.useCallback(()=>{const x=w.collectionRef.current;if(!x)return[];const E=Array.from(x.querySelectorAll(`[${f}]`));return Array.from(w.itemMap.values()).sort((T,M)=>E.indexOf(T.ref.current)-E.indexOf(M.ref.current))},[w.collectionRef,w.itemMap])}return[{Provider:a,Slot:p,ItemSlot:h},b,r]}var Ep=l.createContext(void 0);function Ya(e){const t=l.useContext(Ep);return e||t||"ltr"}var kr="rovingFocusGroup.onEntryFocus",Sp={bubbles:!1,cancelable:!0},_t="RovingFocusGroup",[Or,qa,_p]=Ka(_t),[Rp,Xa]=Xe(_t,[_p]),[Mp,Ap]=Rp(_t),Za=l.forwardRef((e,t)=>u.jsx(Or.Provider,{scope:e.__scopeRovingFocusGroup,children:u.jsx(Or.Slot,{scope:e.__scopeRovingFocusGroup,children:u.jsx(Tp,{...e,ref:t})})}));Za.displayName=_t;var Tp=l.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:s,currentTabStopId:a,defaultCurrentTabStopId:i,onCurrentTabStopIdChange:c,onEntryFocus:p,preventScrollOnEntryFocus:d=!1,...f}=e,m=l.useRef(null),h=ie(t,m),b=Ya(s),[g,w]=wt({prop:a,defaultProp:i??null,onChange:c,caller:_t}),[v,x]=l.useState(!1),E=_e(p),S=qa(n),_=l.useRef(!1),[T,M]=l.useState(0);return l.useEffect(()=>{const C=m.current;if(C)return C.addEventListener(kr,E),()=>C.removeEventListener(kr,E)},[E]),u.jsx(Mp,{scope:n,orientation:r,dir:b,loop:o,currentTabStopId:g,onItemFocus:l.useCallback(C=>w(C),[w]),onItemShiftTab:l.useCallback(()=>x(!0),[]),onFocusableItemAdd:l.useCallback(()=>M(C=>C+1),[]),onFocusableItemRemove:l.useCallback(()=>M(C=>C-1),[]),children:u.jsx(re.div,{tabIndex:v||T===0?-1:0,"data-orientation":r,...f,ref:h,style:{outline:"none",...e.style},onMouseDown:$(e.onMouseDown,()=>{_.current=!0}),onFocus:$(e.onFocus,C=>{const j=!_.current;if(C.target===C.currentTarget&&j&&!v){const L=new CustomEvent(kr,Sp);if(C.currentTarget.dispatchEvent(L),!L.defaultPrevented){const U=S().filter(V=>V.focusable),B=U.find(V=>V.active),z=U.find(V=>V.id===g),X=[B,z,...U].filter(Boolean).map(V=>V.ref.current);ei(X,d)}}_.current=!1}),onBlur:$(e.onBlur,()=>x(!1))})})}),Ja="RovingFocusGroupItem",Qa=l.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:s,children:a,...i}=e,c=De(),p=s||c,d=Ap(Ja,n),f=d.currentTabStopId===p,m=qa(n),{onFocusableItemAdd:h,onFocusableItemRemove:b,currentTabStopId:g}=d;return l.useEffect(()=>{if(r)return h(),()=>b()},[r,h,b]),u.jsx(Or.ItemSlot,{scope:n,id:p,focusable:r,active:o,children:u.jsx(re.span,{tabIndex:f?0:-1,"data-orientation":d.orientation,...i,ref:t,onMouseDown:$(e.onMouseDown,w=>{r?d.onItemFocus(p):w.preventDefault()}),onFocus:$(e.onFocus,()=>d.onItemFocus(p)),onKeyDown:$(e.onKeyDown,w=>{if(w.key==="Tab"&&w.shiftKey){d.onItemShiftTab();return}if(w.target!==w.currentTarget)return;const v=Op(w,d.orientation,d.dir);if(v!==void 0){if(w.metaKey||w.ctrlKey||w.altKey||w.shiftKey)return;w.preventDefault();let E=m().filter(S=>S.focusable).map(S=>S.ref.current);if(v==="last")E.reverse();else if(v==="prev"||v==="next"){v==="prev"&&E.reverse();const S=E.indexOf(w.currentTarget);E=d.loop?Pp(E,S+1):E.slice(S+1)}setTimeout(()=>ei(E))}}),children:typeof a=="function"?a({isCurrentTabStop:f,hasTabStop:g!=null}):a})})});Qa.displayName=Ja;var Np={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function kp(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function Op(e,t,n){const r=kp(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return Np[r]}function ei(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function Pp(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Dp=Za,Ip=Qa,Pr=["Enter"," "],jp=["ArrowDown","PageUp","Home"],ti=["ArrowUp","PageDown","End"],Lp=[...jp,...ti],Fp={ltr:[...Pr,"ArrowRight"],rtl:[...Pr,"ArrowLeft"]},$p={ltr:["ArrowLeft"],rtl:["ArrowRight"]},Rt="Menu",[Mt,Vp,Hp]=Ka(Rt),[Qe,ni]=Xe(Rt,[Hp,dn,Xa]),At=dn(),ri=Xa(),[oi,Ue]=Qe(Rt),[zp,Tt]=Qe(Rt),si=e=>{const{__scopeMenu:t,open:n=!1,children:r,dir:o,onOpenChange:s,modal:a=!0}=e,i=At(t),[c,p]=l.useState(null),d=l.useRef(!1),f=_e(s),m=Ya(o);return l.useEffect(()=>{const h=()=>{d.current=!0,document.addEventListener("pointerdown",b,{capture:!0,once:!0}),document.addEventListener("pointermove",b,{capture:!0,once:!0})},b=()=>d.current=!1;return document.addEventListener("keydown",h,{capture:!0}),()=>{document.removeEventListener("keydown",h,{capture:!0}),document.removeEventListener("pointerdown",b,{capture:!0}),document.removeEventListener("pointermove",b,{capture:!0})}},[]),u.jsx(Rr,{...i,children:u.jsx(oi,{scope:t,open:n,onOpenChange:f,content:c,onContentChange:p,children:u.jsx(zp,{scope:t,onClose:l.useCallback(()=>f(!1),[f]),isUsingKeyboardRef:d,dir:m,modal:a,children:r})})})};si.displayName=Rt;var Wp="MenuAnchor",Dr=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=At(n);return u.jsx(ba,{...o,...r,ref:t})});Dr.displayName=Wp;var Ir="MenuPortal",[Gp,ai]=Qe(Ir,{forceMount:void 0}),ii=e=>{const{__scopeMenu:t,forceMount:n,children:r,container:o}=e,s=Ue(Ir,t);return u.jsx(Gp,{scope:t,forceMount:n,children:u.jsx(Ie,{present:n||s.open,children:u.jsx(qn,{asChild:!0,container:o,children:r})})})};ii.displayName=Ir;var be="MenuContent",[Bp,jr]=Qe(be),ci=l.forwardRef((e,t)=>{const n=ai(be,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,s=Ue(be,e.__scopeMenu),a=Tt(be,e.__scopeMenu);return u.jsx(Mt.Provider,{scope:e.__scopeMenu,children:u.jsx(Ie,{present:r||s.open,children:u.jsx(Mt.Slot,{scope:e.__scopeMenu,children:a.modal?u.jsx(Up,{...o,ref:t}):u.jsx(Kp,{...o,ref:t})})})})}),Up=l.forwardRef((e,t)=>{const n=Ue(be,e.__scopeMenu),r=l.useRef(null),o=ie(t,r);return l.useEffect(()=>{const s=r.current;if(s)return ws(s)},[]),u.jsx(Lr,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:$(e.onFocusOutside,s=>s.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),Kp=l.forwardRef((e,t)=>{const n=Ue(be,e.__scopeMenu);return u.jsx(Lr,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),Yp=et("MenuContent.ScrollLock"),Lr=l.forwardRef((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:o,onOpenAutoFocus:s,onCloseAutoFocus:a,disableOutsidePointerEvents:i,onEntryFocus:c,onEscapeKeyDown:p,onPointerDownOutside:d,onFocusOutside:f,onInteractOutside:m,onDismiss:h,disableOutsideScroll:b,...g}=e,w=Ue(be,n),v=Tt(be,n),x=At(n),E=ri(n),S=Vp(n),[_,T]=l.useState(null),M=l.useRef(null),C=ie(t,M,w.onContentChange),j=l.useRef(0),L=l.useRef(""),U=l.useRef(0),B=l.useRef(null),z=l.useRef("right"),W=l.useRef(0),X=b?tr:l.Fragment,V=b?{as:Yp,allowPinchZoom:!0}:void 0,K=N=>{var Y,ee;const y=L.current+N,P=S().filter(te=>!te.disabled),F=document.activeElement,H=(Y=P.find(te=>te.ref.current===F))==null?void 0:Y.textValue,Z=P.map(te=>te.textValue),ne=am(Z,y,H),ue=(ee=P.find(te=>te.textValue===ne))==null?void 0:ee.ref.current;(function te(ae){L.current=ae,window.clearTimeout(j.current),ae!==""&&(j.current=window.setTimeout(()=>te(""),1e3))})(y),ue&&setTimeout(()=>ue.focus())};l.useEffect(()=>()=>window.clearTimeout(j.current),[]),os();const R=l.useCallback(N=>{var P,F;return z.current===((P=B.current)==null?void 0:P.side)&&cm(N,(F=B.current)==null?void 0:F.area)},[]);return u.jsx(Bp,{scope:n,searchRef:L,onItemEnter:l.useCallback(N=>{R(N)&&N.preventDefault()},[R]),onItemLeave:l.useCallback(N=>{var y;R(N)||((y=M.current)==null||y.focus(),T(null))},[R]),onTriggerLeave:l.useCallback(N=>{R(N)&&N.preventDefault()},[R]),pointerGraceTimerRef:U,onPointerGraceIntentChange:l.useCallback(N=>{B.current=N},[]),children:u.jsx(X,{...V,children:u.jsx(Yn,{asChild:!0,trapped:o,onMountAutoFocus:$(s,N=>{var y;N.preventDefault(),(y=M.current)==null||y.focus({preventScroll:!0})}),onUnmountAutoFocus:a,children:u.jsx(Gt,{asChild:!0,disableOutsidePointerEvents:i,onEscapeKeyDown:p,onPointerDownOutside:d,onFocusOutside:f,onInteractOutside:m,onDismiss:h,children:u.jsx(Dp,{asChild:!0,...E,dir:v.dir,orientation:"vertical",loop:r,currentTabStopId:_,onCurrentTabStopIdChange:T,onEntryFocus:$(c,N=>{v.isUsingKeyboardRef.current||N.preventDefault()}),preventScrollOnEntryFocus:!0,children:u.jsx(wa,{role:"menu","aria-orientation":"vertical","data-state":Ri(w.open),"data-radix-menu-content":"",dir:v.dir,...x,...g,ref:C,style:{outline:"none",...g.style},onKeyDown:$(g.onKeyDown,N=>{const P=N.target.closest("[data-radix-menu-content]")===N.currentTarget,F=N.ctrlKey||N.altKey||N.metaKey,H=N.key.length===1;P&&(N.key==="Tab"&&N.preventDefault(),!F&&H&&K(N.key));const Z=M.current;if(N.target!==Z||!Lp.includes(N.key))return;N.preventDefault();const ue=S().filter(Y=>!Y.disabled).map(Y=>Y.ref.current);ti.includes(N.key)&&ue.reverse(),om(ue)}),onBlur:$(e.onBlur,N=>{N.currentTarget.contains(N.target)||(window.clearTimeout(j.current),L.current="")}),onPointerMove:$(e.onPointerMove,kt(N=>{const y=N.target,P=W.current!==N.clientX;if(N.currentTarget.contains(y)&&P){const F=N.clientX>W.current?"right":"left";z.current=F,W.current=N.clientX}}))})})})})})})});ci.displayName=be;var qp="MenuGroup",Fr=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.jsx(re.div,{role:"group",...r,ref:t})});Fr.displayName=qp;var Xp="MenuLabel",li=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.jsx(re.div,{...r,ref:t})});li.displayName=Xp;var hn="MenuItem",ui="menu.itemSelect",gn=l.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:r,...o}=e,s=l.useRef(null),a=Tt(hn,e.__scopeMenu),i=jr(hn,e.__scopeMenu),c=ie(t,s),p=l.useRef(!1),d=()=>{const f=s.current;if(!n&&f){const m=new CustomEvent(ui,{bubbles:!0,cancelable:!0});f.addEventListener(ui,h=>r==null?void 0:r(h),{once:!0}),Bo(f,m),m.defaultPrevented?p.current=!1:a.onClose()}};return u.jsx(di,{...o,ref:c,disabled:n,onClick:$(e.onClick,d),onPointerDown:f=>{var m;(m=e.onPointerDown)==null||m.call(e,f),p.current=!0},onPointerUp:$(e.onPointerUp,f=>{var m;p.current||(m=f.currentTarget)==null||m.click()}),onKeyDown:$(e.onKeyDown,f=>{const m=i.searchRef.current!=="";n||m&&f.key===" "||Pr.includes(f.key)&&(f.currentTarget.click(),f.preventDefault())})})});gn.displayName=hn;var di=l.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:o,...s}=e,a=jr(hn,n),i=ri(n),c=l.useRef(null),p=ie(t,c),[d,f]=l.useState(!1),[m,h]=l.useState("");return l.useEffect(()=>{const b=c.current;b&&h((b.textContent??"").trim())},[s.children]),u.jsx(Mt.ItemSlot,{scope:n,disabled:r,textValue:o??m,children:u.jsx(Ip,{asChild:!0,...i,focusable:!r,children:u.jsx(re.div,{role:"menuitem","data-highlighted":d?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0,...s,ref:p,onPointerMove:$(e.onPointerMove,kt(b=>{r?a.onItemLeave(b):(a.onItemEnter(b),b.defaultPrevented||b.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:$(e.onPointerLeave,kt(b=>a.onItemLeave(b))),onFocus:$(e.onFocus,()=>f(!0)),onBlur:$(e.onBlur,()=>f(!1))})})})}),Zp="MenuCheckboxItem",fi=l.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:r,...o}=e;return u.jsx(vi,{scope:e.__scopeMenu,checked:n,children:u.jsx(gn,{role:"menuitemcheckbox","aria-checked":vn(n)?"mixed":n,...o,ref:t,"data-state":Hr(n),onSelect:$(o.onSelect,()=>r==null?void 0:r(vn(n)?!0:!n),{checkForDefaultPrevented:!1})})})});fi.displayName=Zp;var pi="MenuRadioGroup",[Jp,Qp]=Qe(pi,{value:void 0,onValueChange:()=>{}}),mi=l.forwardRef((e,t)=>{const{value:n,onValueChange:r,...o}=e,s=_e(r);return u.jsx(Jp,{scope:e.__scopeMenu,value:n,onValueChange:s,children:u.jsx(Fr,{...o,ref:t})})});mi.displayName=pi;var hi="MenuRadioItem",gi=l.forwardRef((e,t)=>{const{value:n,...r}=e,o=Qp(hi,e.__scopeMenu),s=n===o.value;return u.jsx(vi,{scope:e.__scopeMenu,checked:s,children:u.jsx(gn,{role:"menuitemradio","aria-checked":s,...r,ref:t,"data-state":Hr(s),onSelect:$(r.onSelect,()=>{var a;return(a=o.onValueChange)==null?void 0:a.call(o,n)},{checkForDefaultPrevented:!1})})})});gi.displayName=hi;var $r="MenuItemIndicator",[vi,em]=Qe($r,{checked:!1}),bi=l.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:r,...o}=e,s=em($r,n);return u.jsx(Ie,{present:r||vn(s.checked)||s.checked===!0,children:u.jsx(re.span,{...o,ref:t,"data-state":Hr(s.checked)})})});bi.displayName=$r;var tm="MenuSeparator",wi=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.jsx(re.div,{role:"separator","aria-orientation":"horizontal",...r,ref:t})});wi.displayName=tm;var nm="MenuArrow",xi=l.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=At(n);return u.jsx(xa,{...o,...r,ref:t})});xi.displayName=nm;var Vr="MenuSub",[rm,yi]=Qe(Vr),Ci=e=>{const{__scopeMenu:t,children:n,open:r=!1,onOpenChange:o}=e,s=Ue(Vr,t),a=At(t),[i,c]=l.useState(null),[p,d]=l.useState(null),f=_e(o);return l.useEffect(()=>(s.open===!1&&f(!1),()=>f(!1)),[s.open,f]),u.jsx(Rr,{...a,children:u.jsx(oi,{scope:t,open:r,onOpenChange:f,content:p,onContentChange:d,children:u.jsx(rm,{scope:t,contentId:De(),triggerId:De(),trigger:i,onTriggerChange:c,children:n})})})};Ci.displayName=Vr;var Nt="MenuSubTrigger",Ei=l.forwardRef((e,t)=>{const n=Ue(Nt,e.__scopeMenu),r=Tt(Nt,e.__scopeMenu),o=yi(Nt,e.__scopeMenu),s=jr(Nt,e.__scopeMenu),a=l.useRef(null),{pointerGraceTimerRef:i,onPointerGraceIntentChange:c}=s,p={__scopeMenu:e.__scopeMenu},d=l.useCallback(()=>{a.current&&window.clearTimeout(a.current),a.current=null},[]);return l.useEffect(()=>d,[d]),l.useEffect(()=>{const f=i.current;return()=>{window.clearTimeout(f),c(null)}},[i,c]),u.jsx(Dr,{asChild:!0,...p,children:u.jsx(di,{id:o.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":o.contentId,"data-state":Ri(n.open),...e,ref:$t(t,o.onTriggerChange),onClick:f=>{var m;(m=e.onClick)==null||m.call(e,f),!(e.disabled||f.defaultPrevented)&&(f.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:$(e.onPointerMove,kt(f=>{s.onItemEnter(f),!f.defaultPrevented&&!e.disabled&&!n.open&&!a.current&&(s.onPointerGraceIntentChange(null),a.current=window.setTimeout(()=>{n.onOpenChange(!0),d()},100))})),onPointerLeave:$(e.onPointerLeave,kt(f=>{var h,b;d();const m=(h=n.content)==null?void 0:h.getBoundingClientRect();if(m){const g=(b=n.content)==null?void 0:b.dataset.side,w=g==="right",v=w?-5:5,x=m[w?"left":"right"],E=m[w?"right":"left"];s.onPointerGraceIntentChange({area:[{x:f.clientX+v,y:f.clientY},{x,y:m.top},{x:E,y:m.top},{x:E,y:m.bottom},{x,y:m.bottom}],side:g}),window.clearTimeout(i.current),i.current=window.setTimeout(()=>s.onPointerGraceIntentChange(null),300)}else{if(s.onTriggerLeave(f),f.defaultPrevented)return;s.onPointerGraceIntentChange(null)}})),onKeyDown:$(e.onKeyDown,f=>{var h;const m=s.searchRef.current!=="";e.disabled||m&&f.key===" "||Fp[r.dir].includes(f.key)&&(n.onOpenChange(!0),(h=n.content)==null||h.focus(),f.preventDefault())})})})});Ei.displayName=Nt;var Si="MenuSubContent",_i=l.forwardRef((e,t)=>{const n=ai(be,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,s=Ue(be,e.__scopeMenu),a=Tt(be,e.__scopeMenu),i=yi(Si,e.__scopeMenu),c=l.useRef(null),p=ie(t,c);return u.jsx(Mt.Provider,{scope:e.__scopeMenu,children:u.jsx(Ie,{present:r||s.open,children:u.jsx(Mt.Slot,{scope:e.__scopeMenu,children:u.jsx(Lr,{id:i.contentId,"aria-labelledby":i.triggerId,...o,ref:p,align:"start",side:a.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:d=>{var f;a.isUsingKeyboardRef.current&&((f=c.current)==null||f.focus()),d.preventDefault()},onCloseAutoFocus:d=>d.preventDefault(),onFocusOutside:$(e.onFocusOutside,d=>{d.target!==i.trigger&&s.onOpenChange(!1)}),onEscapeKeyDown:$(e.onEscapeKeyDown,d=>{a.onClose(),d.preventDefault()}),onKeyDown:$(e.onKeyDown,d=>{var h;const f=d.currentTarget.contains(d.target),m=$p[a.dir].includes(d.key);f&&m&&(s.onOpenChange(!1),(h=i.trigger)==null||h.focus(),d.preventDefault())})})})})})});_i.displayName=Si;function Ri(e){return e?"open":"closed"}function vn(e){return e==="indeterminate"}function Hr(e){return vn(e)?"indeterminate":e?"checked":"unchecked"}function om(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function sm(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function am(e,t,n){const o=t.length>1&&Array.from(t).every(p=>p===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let a=sm(e,Math.max(s,0));o.length===1&&(a=a.filter(p=>p!==n));const c=a.find(p=>p.toLowerCase().startsWith(o.toLowerCase()));return c!==n?c:void 0}function im(e,t){const{x:n,y:r}=e;let o=!1;for(let s=0,a=t.length-1;s<t.length;a=s++){const i=t[s],c=t[a],p=i.x,d=i.y,f=c.x,m=c.y;d>r!=m>r&&n<(f-p)*(r-d)/(m-d)+p&&(o=!o)}return o}function cm(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return im(n,t)}function kt(e){return t=>t.pointerType==="mouse"?e(t):void 0}var lm=si,um=Dr,dm=ii,fm=ci,pm=Fr,mm=li,hm=gn,gm=fi,vm=mi,bm=gi,wm=bi,xm=wi,ym=xi,Cm=Ci,Em=Ei,Sm=_i,bn="DropdownMenu",[_m,L0]=Xe(bn,[ni]),pe=ni(),[Rm,Mi]=_m(bn),Ai=e=>{const{__scopeDropdownMenu:t,children:n,dir:r,open:o,defaultOpen:s,onOpenChange:a,modal:i=!0}=e,c=pe(t),p=l.useRef(null),[d,f]=wt({prop:o,defaultProp:s??!1,onChange:a,caller:bn});return u.jsx(Rm,{scope:t,triggerId:De(),triggerRef:p,contentId:De(),open:d,onOpenChange:f,onOpenToggle:l.useCallback(()=>f(m=>!m),[f]),modal:i,children:u.jsx(lm,{...c,open:d,onOpenChange:f,dir:r,modal:i,children:n})})};Ai.displayName=bn;var Ti="DropdownMenuTrigger",Ni=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:r=!1,...o}=e,s=Mi(Ti,n),a=pe(n);return u.jsx(um,{asChild:!0,...a,children:u.jsx(re.button,{type:"button",id:s.triggerId,"aria-haspopup":"menu","aria-expanded":s.open,"aria-controls":s.open?s.contentId:void 0,"data-state":s.open?"open":"closed","data-disabled":r?"":void 0,disabled:r,...o,ref:$t(t,s.triggerRef),onPointerDown:$(e.onPointerDown,i=>{!r&&i.button===0&&i.ctrlKey===!1&&(s.onOpenToggle(),s.open||i.preventDefault())}),onKeyDown:$(e.onKeyDown,i=>{r||(["Enter"," "].includes(i.key)&&s.onOpenToggle(),i.key==="ArrowDown"&&s.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(i.key)&&i.preventDefault())})})})});Ni.displayName=Ti;var Mm="DropdownMenuPortal",ki=e=>{const{__scopeDropdownMenu:t,...n}=e,r=pe(t);return u.jsx(dm,{...r,...n})};ki.displayName=Mm;var Oi="DropdownMenuContent",Pi=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Mi(Oi,n),s=pe(n),a=l.useRef(!1);return u.jsx(fm,{id:o.contentId,"aria-labelledby":o.triggerId,...s,...r,ref:t,onCloseAutoFocus:$(e.onCloseAutoFocus,i=>{var c;a.current||(c=o.triggerRef.current)==null||c.focus(),a.current=!1,i.preventDefault()}),onInteractOutside:$(e.onInteractOutside,i=>{const c=i.detail.originalEvent,p=c.button===0&&c.ctrlKey===!0,d=c.button===2||p;(!o.modal||d)&&(a.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Pi.displayName=Oi;var Am="DropdownMenuGroup",Di=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(pm,{...o,...r,ref:t})});Di.displayName=Am;var Tm="DropdownMenuLabel",Ii=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(mm,{...o,...r,ref:t})});Ii.displayName=Tm;var Nm="DropdownMenuItem",ji=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(hm,{...o,...r,ref:t})});ji.displayName=Nm;var km="DropdownMenuCheckboxItem",Li=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(gm,{...o,...r,ref:t})});Li.displayName=km;var Om="DropdownMenuRadioGroup",Fi=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(vm,{...o,...r,ref:t})});Fi.displayName=Om;var Pm="DropdownMenuRadioItem",$i=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(bm,{...o,...r,ref:t})});$i.displayName=Pm;var Dm="DropdownMenuItemIndicator",Vi=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(wm,{...o,...r,ref:t})});Vi.displayName=Dm;var Im="DropdownMenuSeparator",Hi=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(xm,{...o,...r,ref:t})});Hi.displayName=Im;var jm="DropdownMenuArrow",Lm=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(ym,{...o,...r,ref:t})});Lm.displayName=jm;var Fm=e=>{const{__scopeDropdownMenu:t,children:n,open:r,onOpenChange:o,defaultOpen:s}=e,a=pe(t),[i,c]=wt({prop:r,defaultProp:s??!1,onChange:o,caller:"DropdownMenuSub"});return u.jsx(Cm,{...a,open:i,onOpenChange:c,children:n})},$m="DropdownMenuSubTrigger",zi=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(Em,{...o,...r,ref:t})});zi.displayName=$m;var Vm="DropdownMenuSubContent",Wi=l.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=pe(n);return u.jsx(Sm,{...o,...r,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Wi.displayName=Vm;var Hm=Ai,zm=Ni,Gi=ki,Wm=Pi,Gm=Di,Bm=Ii,Um=ji,Km=Li,Ym=Fi,qm=$i,Bi=Vi,Xm=Hi,Zm=Fm,Jm=zi,Qm=Wi;function Ui({...e}){return u.jsx(Hm,{"data-slot":"dropdown-menu",...e})}function e0({...e}){return u.jsx(Gi,{"data-slot":"dropdown-menu-portal",...e})}function Ki({...e}){return u.jsx(zm,{"data-slot":"dropdown-menu-trigger",...e})}function Yi({className:e,sideOffset:t=4,...n}){return u.jsx(Gi,{children:u.jsx(Wm,{"data-slot":"dropdown-menu-content",sideOffset:t,className:D("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 max-h-(--radix-dropdown-menu-content-available-height) min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md border p-1 shadow-md",e),...n})})}function t0({...e}){return u.jsx(Gm,{"data-slot":"dropdown-menu-group",...e})}function zr({className:e,inset:t,variant:n="default",...r}){return u.jsx(Um,{"data-slot":"dropdown-menu-item","data-inset":t,"data-variant":n,className:D("focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...r})}function n0({className:e,children:t,checked:n,...r}){return u.jsxs(Km,{"data-slot":"dropdown-menu-checkbox-item",className:D("focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),checked:n,...r,children:[u.jsx("span",{className:"pointer-events-none absolute left-2 flex size-3.5 items-center justify-center",children:u.jsx(Bi,{children:u.jsx(Qc,{className:"size-4"})})}),t]})}function r0({...e}){return u.jsx(Ym,{"data-slot":"dropdown-menu-radio-group",...e})}function o0({className:e,children:t,...n}){return u.jsxs(qm,{"data-slot":"dropdown-menu-radio-item",className:D("focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-sm py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...n,children:[u.jsx("span",{className:"pointer-events-none absolute left-2 flex size-3.5 items-center justify-center",children:u.jsx(Bi,{children:u.jsx(nl,{className:"size-2 fill-current"})})}),t]})}function qi({className:e,inset:t,...n}){return u.jsx(Bm,{"data-slot":"dropdown-menu-label","data-inset":t,className:D("px-2 py-1.5 text-sm font-medium data-[inset]:pl-8",e),...n})}function Xi({className:e,...t}){return u.jsx(Xm,{"data-slot":"dropdown-menu-separator",className:D("bg-border -mx-1 my-1 h-px",e),...t})}function s0({className:e,...t}){return u.jsx("span",{"data-slot":"dropdown-menu-shortcut",className:D("text-muted-foreground ml-auto text-xs tracking-widest",e),...t})}function a0({...e}){return u.jsx(Zm,{"data-slot":"dropdown-menu-sub",...e})}function i0({className:e,inset:t,children:n,...r}){return u.jsxs(Jm,{"data-slot":"dropdown-menu-sub-trigger","data-inset":t,className:D("focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground flex cursor-default items-center rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[inset]:pl-8",e),...r,children:[n,u.jsx(yo,{className:"ml-auto size-4"})]})}function c0({className:e,...t}){return u.jsx(Qm,{"data-slot":"dropdown-menu-sub-content",className:D("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg",e),...t})}const l0="data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20xmlns='http://www.w3.org/2000/svg'%20viewBox='0%200%20141%2060'%3e%3cpath%20d='M0.059%2019.711V59.673H19.509V49.95H9.779V19.711H0.059Z'%20fill='%2385B9D1'%3e%3c/path%3e%3cpath%20d='M0%200L0.056%204.915V19.715H9.776V9.715H19.5V59.673H29.22V0H0Z'%20fill='%23F68029'%3e%3c/path%3e%3cpath%20d='M23.49%2019.717H9.776V29.439H23.49V19.717Z'%20fill='%23F68029'%3e%3c/path%3e%3cpath%20d='M0.0580006%2019.718L9.785%2029.445V19.718H0.0580006Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M9.777%2049.953L19.504%2059.679V49.953H9.777Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M50.213%2021.331C50.1839%2019.244%2050.325%2017.1581%2050.635%2015.094C50.8293%2013.6891%2051.2694%2012.3294%2051.935%2011.077C52.4295%2010.1519%2053.1979%209.4023%2054.135%208.93101C55.1033%208.49691%2056.1561%208.28375%2057.217%208.307C58.2628%208.27673%2059.3024%208.47715%2060.262%208.894C61.1441%209.33605%2061.8541%2010.059%2062.28%2010.949C62.8725%2012.1976%2063.2507%2013.5369%2063.399%2014.911C63.6554%2016.9922%2063.7717%2019.0882%2063.747%2021.185C63.7759%2023.338%2063.6421%2025.4901%2063.347%2027.623C63.1657%2029.0675%2062.7378%2030.4702%2062.082%2031.77C61.6022%2032.7122%2060.8471%2033.4862%2059.917%2033.989C58.9503%2034.4507%2057.888%2034.6768%2056.817%2034.649C55.7687%2034.6771%2054.7258%2034.4896%2053.753%2034.098C52.8534%2033.6775%2052.1275%2032.9579%2051.699%2032.062C51.0884%2030.7803%2050.7037%2029.4027%2050.562%2027.99C50.3018%2025.7802%2050.1852%2023.5559%2050.213%2021.331ZM54.913%2022.248C54.913%2023.6913%2054.9377%2024.9267%2054.987%2025.954C55.0147%2026.8043%2055.1127%2027.6509%2055.28%2028.485C55.3666%2029.0149%2055.5877%2029.5138%2055.922%2029.934C56.0643%2030.0868%2056.238%2030.207%2056.4312%2030.2862C56.6244%2030.3655%2056.8324%2030.4019%2057.041%2030.393C57.25%2030.3964%2057.4571%2030.3533%2057.6473%2030.2668C57.8375%2030.1803%2058.0062%2030.0526%2058.141%2029.893C58.4964%2029.4241%2058.7297%2028.8744%2058.82%2028.293C59.0025%2027.3609%2059.1128%2026.4161%2059.15%2025.467C59.2107%2024.3177%2059.2414%2022.936%2059.242%2021.322C59.242%2019.732%2059.224%2018.3747%2059.188%2017.25C59.169%2016.3373%2059.0736%2015.4278%2058.903%2014.531C58.8198%2013.9744%2058.5923%2013.4493%2058.243%2013.008C58.0929%2012.8491%2057.9104%2012.7244%2057.7078%2012.6422C57.5053%2012.5601%2057.2874%2012.5225%2057.069%2012.532C56.8667%2012.5304%2056.6668%2012.576%2056.4852%2012.6652C56.3036%2012.7544%2056.1453%2012.8848%2056.023%2013.046C55.6766%2013.5389%2055.4446%2014.103%2055.344%2014.697C55.1442%2015.6885%2055.0277%2016.695%2054.996%2017.706C54.9347%2018.9533%2054.904%2020.4697%2054.904%2022.255'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M83.329%2021.331C83.2999%2019.244%2083.441%2017.1581%2083.751%2015.094C83.9453%2013.6891%2084.3854%2012.3294%2085.051%2011.077C85.5455%2010.1519%2086.3139%209.40235%2087.251%208.93105C89.2087%208.112%2091.4106%208.09871%2093.378%208.89405C94.2601%209.33609%2094.9701%2010.0591%2095.396%2010.949C95.9885%2012.1976%2096.3667%2013.537%2096.515%2014.911C96.7714%2016.9922%2096.8877%2019.0883%2096.863%2021.185C96.8919%2023.3381%2096.7581%2025.4902%2096.463%2027.6231C96.2817%2029.0676%2095.8538%2030.4703%2095.198%2031.77C94.7182%2032.7123%2093.9631%2033.4862%2093.033%2033.989C92.0663%2034.4507%2091.004%2034.6769%2089.933%2034.649C88.8847%2034.6772%2087.8418%2034.4896%2086.869%2034.098C85.9694%2033.6775%2085.2435%2032.9579%2084.815%2032.062C84.2044%2030.7803%2083.8197%2029.4027%2083.678%2027.99C83.4178%2025.7803%2083.3012%2023.5559%2083.329%2021.331ZM88.029%2022.2481C88.029%2023.6914%2088.0537%2024.9267%2088.103%2025.954C88.1307%2026.8044%2088.2287%2027.6509%2088.396%2028.4851C88.4826%2029.015%2088.7037%2029.5139%2089.038%2029.934C89.1803%2030.0869%2089.354%2030.207%2089.5472%2030.2863C89.7404%2030.3655%2089.9484%2030.4019%2090.157%2030.393C90.366%2030.3964%2090.573%2030.3533%2090.7633%2030.2669C90.9535%2030.1804%2091.1222%2030.0527%2091.257%2029.893C91.6124%2029.4242%2091.8458%2028.8744%2091.936%2028.2931C92.1185%2027.3609%2092.2288%2026.4161%2092.266%2025.467C92.3267%2024.3177%2092.3574%2022.936%2092.358%2021.322C92.358%2019.732%2092.34%2018.3747%2092.304%2017.2501C92.2887%2016.3329%2092.1964%2015.4187%2092.028%2014.517C91.9448%2013.9605%2091.7173%2013.4354%2091.368%2012.994C91.2162%2012.8368%2091.0323%2012.7141%2090.8289%2012.6343C90.6255%2012.5544%2090.4072%2012.5192%2090.189%2012.531C89.9867%2012.5294%2089.7868%2012.575%2089.6052%2012.6643C89.4236%2012.7535%2089.2653%2012.8839%2089.143%2013.045C88.7966%2013.5379%2088.5646%2014.102%2088.464%2014.6961C88.2642%2015.6876%2088.1477%2016.6941%2088.116%2017.705C88.0547%2018.9524%2088.024%2020.4687%2088.024%2022.254'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M131.349%2034.65V8.32202H135.458V30.797H140.631V34.649L131.349%2034.65Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M71.95%2034.65V8.33203H76.059V30.796H81.232V34.648L71.95%2034.65Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M104.833%2014.692C104.934%2014.098%20105.166%2013.534%20105.512%2013.041C105.634%2012.8798%20105.793%2012.7494%20105.974%2012.6602C106.156%2012.571%20106.356%2012.5253%20106.558%2012.527H110.103V8.30798H106.703C105.642%208.2848%20104.589%208.49794%20103.621%208.93197C102.684%209.40306%20101.915%2010.1527%20101.421%2011.078C100.756%2012.3304%20100.316%2013.6901%20100.121%2015.095C99.8114%2017.1591%2099.6706%2019.245%2099.7%2021.332C99.6722%2023.5568%2099.7885%2025.7811%20100.048%2027.991C100.19%2029.4037%20100.574%2030.7812%20101.185%2032.063C101.614%2032.9584%20102.34%2033.6778%20103.239%2034.099C104.212%2034.4899%20105.255%2034.6771%20106.303%2034.649L110.103%2034.613V30.393H106.522C106.313%2030.402%20106.105%2030.3657%20105.912%2030.2866C105.719%2030.2076%20105.545%2030.0876%20105.403%2029.935C105.069%2029.5144%20104.848%2029.0152%20104.761%2028.485C104.594%2027.6509%20104.496%2026.8043%20104.468%2025.954C104.419%2024.9266%20104.394%2023.6916%20104.394%2022.249C104.394%2020.4636%20104.425%2018.9473%20104.486%2017.7C104.518%2016.6894%20104.633%2015.6832%20104.833%2014.692Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M46.728%2019.247H42.878V30.395H41.828C41.6182%2030.4039%2041.409%2030.3669%2041.2149%2030.2868C41.0208%2030.2067%2040.8465%2030.0853%2040.704%2029.931C40.3695%2029.5106%2040.1485%2029.0113%2040.062%2028.481C39.894%2027.647%2039.7956%2026.8004%2039.768%2025.95C39.7187%2024.9227%2039.6944%2023.6877%2039.695%2022.245C39.695%2020.4597%2039.7257%2018.9434%2039.787%2017.696C39.8191%2016.6854%2039.9355%2015.6792%2040.135%2014.688C40.2357%2014.094%2040.4677%2013.53%2040.814%2013.037C40.9376%2012.8768%2041.0968%2012.7476%2041.2791%2012.6598C41.4614%2012.5719%2041.6617%2012.5278%2041.864%2012.531H45.904V8.31202H42.012C40.9511%208.28877%2039.8983%208.50191%2038.93%208.93601C37.9927%209.40699%2037.2241%2010.1567%2036.73%2011.082C36.0644%2012.3344%2035.6243%2013.6941%2035.43%2015.099C35.1189%2017.1613%2034.9764%2019.2456%2035.004%2021.331C34.9762%2023.5559%2035.0925%2025.7802%2035.352%2027.99C35.494%2029.4026%2035.8787%2030.7802%2036.489%2032.062C36.9179%2032.9579%2037.6442%2033.6775%2038.544%2034.098C39.517%2034.4891%2040.5598%2034.6763%2041.608%2034.648L43.587%2034.629H46.727L46.728%2019.247Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M123.653%2029.87H118L116.691%2034.65H112.797L120.939%208L128.793%2034.65H124.856L123.653%2029.87ZM122.587%2026.212L120.893%2019.982L119.085%2026.212H122.587Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M39.016%2041.436H37.059V54.507H39.016V41.436Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M44.559%2041.436H46.384L48.331%2046.651C48.919%2048.1937%2049.4198%2049.7682%2049.831%2051.367C49.6744%2050.357%2049.5584%2049.4427%2049.483%2048.624C49.4077%2047.8054%2049.37%2047.0347%2049.37%2046.312V41.436H51.336V54.511H49.495L47.303%2048.627C47.103%2048.0797%2046.9134%2047.518%2046.734%2046.942C46.5547%2046.366%2046.39%2045.762%2046.24%2045.13C46.2274%2045.0507%2046.207%2044.9547%2046.179%2044.842C46.151%2044.7293%2046.1177%2044.5997%2046.079%2044.453C46.098%2044.6%2046.114%2044.725%2046.126%2044.829C46.138%2044.933%2046.148%2045.022%2046.154%2045.095L46.254%2046.424L46.354%2048.041C46.36%2048.131%2046.365%2048.241%2046.368%2048.371C46.371%2048.501%2046.368%2048.648%2046.368%2048.811L46.468%2054.511H44.559V41.436Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M55.493%2041.436H61.861V42.977H59.67V54.511H57.751V42.977H55.493V41.436Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M65.828%2041.436H71.028V42.926H67.787V47.065H70.665V48.555H67.787V53.016H71.028V54.506H65.828V41.436Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M75.906%2041.436H78.483C79.3332%2041.3696%2080.1787%2041.6132%2080.863%2042.122C81.2131%2042.4774%2081.4826%2042.904%2081.6531%2043.3729C81.8236%2043.8417%2081.8911%2044.3418%2081.851%2044.839C81.8876%2045.6248%2081.7066%2046.4055%2081.328%2047.095C81.1685%2047.3665%2080.9531%2047.6008%2080.696%2047.7826C80.4389%2047.9643%2080.1461%2048.0892%2079.837%2048.149L82.509%2054.507H80.525L77.863%2048.107V54.507H75.906V41.436ZM77.863%2047.227C78.1485%2047.2893%2078.4451%2047.279%2078.7256%2047.1969C79.0061%2047.1148%2079.2615%2046.9637%2079.4684%2046.7573C79.6753%2046.5509%2079.8271%2046.2959%2079.9098%2046.0156C79.9926%2045.7353%2080.0036%2045.4387%2079.942%2045.153C79.9472%2044.8034%2079.9137%2044.4543%2079.842%2044.112C79.7909%2043.8589%2079.6851%2043.62%2079.532%2043.412C79.3909%2043.2304%2079.2018%2043.0918%2078.986%2043.012C78.7308%2042.9221%2078.4615%2042.8791%2078.191%2042.885H77.862L77.863%2047.227Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M90.046%2041.06L85.913%2054.514H87.745L88.45%2051.974H91.496L92.135%2054.531H94.028L90.046%2041.06ZM88.876%2050.403L90.013%2046.703L91.048%2050.415L88.876%2050.403Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M106.344%2041.436H112.712V42.977H110.52V54.511H108.602V42.977H106.344V41.436Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M118.865%2041.462H116.908V54.533H118.865V41.462Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M134.181%2041.462H139.381V42.952H136.136V47.093H139.014V48.583H136.136V53.044H139.381V54.534H134.181V41.462Z'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M99.749%2044.338C99.8046%2044.0109%2099.9338%2043.7008%20100.127%2043.431C100.202%2043.3322%20100.3%2043.2523%20100.411%2043.1976C100.523%2043.1429%20100.646%2043.115%20100.77%2043.116H102.464V41.207H100.846C100.318%2041.1955%2099.7949%2041.3011%2099.313%2041.516C98.8543%2041.748%2098.4782%2042.1157%2098.236%2042.569C97.9008%2043.2016%2097.6788%2043.888%2097.58%2044.597C97.4215%2045.6561%2097.3493%2046.7263%2097.364%2047.797C97.3503%2048.9393%2097.4101%2050.0814%2097.543%2051.216C97.6145%2051.9294%2097.808%2052.6252%2098.115%2053.273C98.3244%2053.7086%2098.6776%2054.0586%2099.115%2054.264C99.6001%2054.458%20100.12%2054.5509%20100.642%2054.537L102.469%2054.52V52.61H100.755C100.629%2052.6147%20100.503%2052.592%20100.386%2052.5435C100.269%2052.495%20100.164%2052.4218%20100.078%2052.329C99.8888%2052.0951%2099.7637%2051.816%2099.715%2051.519C99.6273%2051.081%2099.5758%2050.6365%2099.561%2050.19C99.536%2049.66%2099.523%2049.014%2099.523%2048.27C99.523%2047.349%2099.539%2046.557%2099.57%2045.916C99.5873%2045.3865%2099.6485%2044.8594%2099.753%2044.34'%20fill='%230A3763'%3e%3c/path%3e%3cpath%20d='M128.799%2041.466L126.671%2048.91L124.671%2041.466H122.679L126.654%2054.953L130.774%2041.466H128.799Z'%20fill='%230A3763'%3e%3c/path%3e%3c/svg%3e";function u0(){const[e,t]=I.useState("");return I.useEffect(()=>{t(window.location.pathname);const r=()=>{t(window.location.pathname)},o=()=>{t(window.location.pathname)};return window.addEventListener("popstate",r),window.addEventListener("pushstate",o),window.addEventListener("replacestate",o),()=>{window.removeEventListener("popstate",r),window.removeEventListener("pushstate",o),window.removeEventListener("replacestate",o)}},[]),{currentPath:e,isActiveRoute:r=>!!(e===r||r!=="/"&&e.startsWith(r))}}const Zi=I.createContext(void 0),Ji=()=>{const e=I.useContext(Zi);if(e===void 0)throw new Error("usePermissions must be used within PermissionsProvider");return e};function d0({children:e}){const[t,n]=I.useState({essentialInsights:!1,priceMonster:!1,web:!1});return I.useEffect(()=>{fetch("/api/auth/permissions").then(r=>r.json()).then(r=>{const o=(r==null?void 0:r.userData)||{};n({essentialInsights:!!o.essentialInsights,priceMonster:!!o.priceMonster,web:!!o.web})}).catch(r=>console.error("Error fetching product access:",r))},[]),u.jsx(Zi.Provider,{value:t,children:e})}const f0={navMain:[{title:"Essential Insights",key:"essentialInsights",url:"/essential-insights/overall-performance",icon:u.jsx(Jc,{className:"h-5 w-5"}),items:[{title:"Overall Performance",url:"/essential-insights/overall-performance",icon:u.jsx(Co,{className:"h-4 w-4"})},{title:"Organic Performance",url:"/essential-insights/organic-performance",icon:u.jsx(xo,{className:"h-4 w-4"})},{title:"Paid Performance",url:"/essential-insights/paid-performance",icon:u.jsx(Zc,{className:"h-4 w-4"})},{title:"Keyword Performance",url:"/essential-insights/keyword-performance",icon:u.jsx(xo,{className:"h-4 w-4"})},{title:"More Components",url:"/essential-insights/more-components",icon:u.jsx(Ft,{className:"h-4 w-4"})}]},{title:"Price Monster",key:"priceMonster",url:"/price-monster",icon:u.jsx(tl,{className:"h-4 w-4"}),items:[{title:"Dashboard",url:"/price-monster/dashboard",icon:u.jsx(Ft,{className:"h-4 w-4"})},{title:"Documentation",url:"/price-monster/documentation",icon:u.jsx(qc,{className:"h-4 w-4"})},{title:"Subscriptions",url:"/price-monster/subscriptions",icon:u.jsx(Xc,{className:"h-4 w-4"})}]},{title:"CMS",key:"web",url:"/cms",icon:u.jsx(Ft,{className:"h-4 w-4"}),items:[{title:"Dashboard",url:"/cms/dashboard",icon:u.jsx(Ft,{className:"h-4 w-4"})}]}]};function p0({...e}){const{isActiveRoute:t}=u0(),n=Ji();return u.jsxs(Ia,{...e,children:[u.jsx($a,{children:u.jsx("div",{className:"relative h-12 w-32 overflow-hidden",children:u.jsx("img",{src:l0,alt:"GLI Logo",className:"h-full w-full object-contain"})})}),u.jsxs(Va,{children:[u.jsx("div",{className:"relative flex w-full min-w-0 flex-col px-2 py-1",children:u.jsx("div",{className:"flex flex-col",children:u.jsxs("a",{href:"/",className:D("flex cursor-pointer items-center gap-2 rounded-lg px-2 py-2 transition-colors","hover:bg-gray-100",t("/")&&"bg-blue-50 text-gli-bluedark font-medium"),children:[u.jsx(Co,{className:D("h-5 w-5",t("/")?"text-gli-bluedark":"text-gray-600")}),u.jsx("span",{children:"Home"})]})})}),f0.navMain.map(r=>{const o=!r.key||n[r.key],s=o&&(t(r.url)||r.items.some(a=>t(a.url)));return u.jsx(Ua,{title:r.title,url:o?r.url:void 0,icon:r.icon,isActive:s,children:u.jsx(za,{children:u.jsx(Wa,{children:r.items.map(a=>{const i=o&&t(a.url);return u.jsx(Ga,{children:u.jsx(Ba,{asChild:!0,children:u.jsxs("a",{href:o?a.url:void 0,className:D("flex items-center gap-2 pl-4 transition-colors",o?"text-muted-foreground hover:bg-muted hover:text-foreground":"text-gray-400 cursor-not-allowed opacity-50",i&&"bg-blue-50 text-gli-bluedark font-medium"),onClick:c=>{o||c.preventDefault()},children:[u.jsx("span",{className:D(i?"text-gli-bluedark":o?"text-muted-foreground":"text-gray-400"),children:a.icon}),u.jsx("span",{className:D(i?"text-gli-bluedark":o?"text-muted-foreground":"text-gray-400"),children:a.title})]})})},a.title)})})})},r.title)})]}),u.jsx(La,{})]})}const Qi=({onLogout:e})=>{const{user:t,error:n,isLoading:r}=zc(),o=async()=>{try{e&&await e(),window.location.href="/auth/logout"}catch(s){console.error("Error during logout:",s),window.location.href="/auth/logout"}};return r?u.jsx("div",{className:"h-10 w-10 animate-pulse rounded-full bg-gray-200"}):n?u.jsxs("div",{children:["Error: ",n.message]}):t?u.jsx("div",{className:"relative flex items-center gap-3",children:u.jsxs(Ui,{children:[u.jsx(Ki,{asChild:!0,children:u.jsx(zt,{variant:"ghost",size:"lg",className:"rounded-full cursor-pointer p-0",children:t.picture?u.jsx("img",{src:t.picture,alt:t.name||"User profile",width:40,height:40,className:"rounded-full"}):u.jsx(Eo,{className:"h-5 w-5 text-gray-500"})})}),u.jsxs(Yi,{align:"end",className:"w-72",children:[u.jsx(qi,{children:u.jsx("div",{className:"flex flex-col space-y-1",children:u.jsxs("div",{className:"flex flex-col space-y-1",children:[u.jsx("p",{className:"text-xs text-gray-500",children:t.name}),u.jsx("p",{className:"truncate text-xs text-gray-500",children:t.email})]})})}),u.jsx(Xi,{}),u.jsx(zr,{asChild:!0,children:u.jsxs("a",{href:"/profile",className:"flex w-full cursor-default",children:[u.jsx(Eo,{className:"mr-2 h-4 w-4"}),u.jsx("span",{children:"Profile"})]})}),u.jsxs(zr,{onClick:o,children:[u.jsx(rl,{className:"mr-2 h-4 w-4"}),u.jsx("span",{children:"Sign out"})]})]})]})}):null},ec=({onLogout:e})=>u.jsx("div",{className:"sticky top-0 z-50 bg-white",children:u.jsxs("header",{className:"flex h-16 items-center justify-between border-b bg-white px-4",children:[u.jsxs("div",{className:"flex h-full items-center gap-4 flex-1 min-w-0 overflow-hidden",children:[u.jsx(ja,{}),u.jsx(Wt,{orientation:"vertical"})]}),u.jsx("div",{className:"flex-shrink-0",children:u.jsx(Qi,{onLogout:e})})]})}),m0=({children:e,onLogout:t})=>u.jsx(Wc,{children:u.jsx(Da,{children:u.jsxs("div",{className:"flex h-screen w-full",children:[u.jsx(p0,{}),u.jsxs(Fa,{className:"flex-1 flex flex-col min-w-0",children:[u.jsx(ec,{onLogout:t}),u.jsx("main",{className:"flex-1 bg-white overflow-auto",id:"page-content",children:e})]})]})})});A.AppHeader=ec,A.Button=zt,A.Card=Gl,A.CardAction=Yl,A.CardContent=ql,A.CardDescription=Kl,A.CardFooter=Xl,A.CardHeader=Bl,A.CardTitle=Ul,A.CollapsibleSection=Ua,A.DropdownMenu=Ui,A.DropdownMenuCheckboxItem=n0,A.DropdownMenuContent=Yi,A.DropdownMenuGroup=t0,A.DropdownMenuItem=zr,A.DropdownMenuLabel=qi,A.DropdownMenuPortal=e0,A.DropdownMenuRadioGroup=r0,A.DropdownMenuRadioItem=o0,A.DropdownMenuSeparator=Xi,A.DropdownMenuShortcut=s0,A.DropdownMenuSub=a0,A.DropdownMenuSubContent=c0,A.DropdownMenuSubTrigger=i0,A.DropdownMenuTrigger=Ki,A.GLICloudProvider=m0,A.Input=Gn,A.PermissionsProvider=d0,A.ProfileDropdown=Qi,A.Separator=Wt,A.Sheet=Hs,A.SheetClose=Rd,A.SheetContent=ir,A.SheetDescription=ur,A.SheetFooter=Ws,A.SheetHeader=cr,A.SheetOverlay=ar,A.SheetPortal=zs,A.SheetTitle=lr,A.SheetTrigger=_d,A.Sidebar=Ia,A.SidebarContent=Va,A.SidebarFooter=fp,A.SidebarGroup=Ha,A.SidebarGroupAction=hp,A.SidebarGroupContent=za,A.SidebarGroupLabel=mp,A.SidebarHeader=$a,A.SidebarInput=dp,A.SidebarInset=Fa,A.SidebarMenu=gp,A.SidebarMenuAction=xp,A.SidebarMenuBadge=yp,A.SidebarMenuButton=wp,A.SidebarMenuItem=vp,A.SidebarMenuSkeleton=Cp,A.SidebarMenuSub=Wa,A.SidebarMenuSubButton=Ba,A.SidebarMenuSubItem=Ga,A.SidebarProvider=Da,A.SidebarRail=La,A.SidebarSeparator=pp,A.SidebarTrigger=ja,A.Skeleton=dr,A.Tooltip=ka,A.TooltipContent=Nr,A.TooltipProvider=Na,A.TooltipTrigger=Oa,A.buttonVariants=Go,A.usePermissions=Ji,A.useSidebar=St,Object.defineProperty(A,Symbol.toStringTag,{value:"Module"})});