pitroom 0.6.5 → 0.6.7
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.
- package/.claude-plugin/plugin.json +1 -1
- package/.codex-plugin/plugin.json +1 -1
- package/CHANGELOG.md +37 -0
- package/README.md +85 -8
- package/THIRD_PARTY_NOTICES.md +25 -0
- package/dist/lib.mjs +31 -3
- package/dist/pitroom.mjs +1175 -426
- package/dist/ui/app.css +2 -0
- package/dist/ui/app.js +20 -0
- package/docs/backends.md +1 -1
- package/hooks/session-start.mjs +3 -2
- package/package.json +17 -3
- package/skills/pitroom-crew/SKILL.md +2 -1
- package/skills/using-pitroom/SKILL.md +2 -1
package/dist/ui/app.js
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
var l3=Object.create;var wv=Object.defineProperty;var u3=Object.getOwnPropertyDescriptor;var c3=Object.getOwnPropertyNames;var f3=Object.getPrototypeOf,d3=Object.prototype.hasOwnProperty;var yo=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Aa=(e,t)=>{for(var a in t)wv(e,a,{get:t[a],enumerable:!0})},m3=(e,t,a,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of c3(t))!d3.call(e,r)&&r!==a&&wv(e,r,{get:()=>t[r],enumerable:!(o=u3(t,r))||o.enumerable});return e};var T=(e,t,a)=>(a=e!=null?l3(f3(e)):{},m3(t||!e||!e.__esModule?wv(a,"default",{value:e,enumerable:!0}):a,e));var Fw=yo(ke=>{"use strict";var Dv=Symbol.for("react.transitional.element"),p3=Symbol.for("react.portal"),h3=Symbol.for("react.fragment"),g3=Symbol.for("react.strict_mode"),x3=Symbol.for("react.profiler"),y3=Symbol.for("react.consumer"),S3=Symbol.for("react.context"),b3=Symbol.for("react.forward_ref"),v3=Symbol.for("react.suspense"),C3=Symbol.for("react.memo"),Dw=Symbol.for("react.lazy"),L3=Symbol.for("react.activity"),R3=Symbol.for("react.view_transition"),Iw=Symbol.iterator;function T3(e){return e===null||typeof e!="object"?null:(e=Iw&&e[Iw]||e["@@iterator"],typeof e=="function"?e:null)}var Mw={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Pw=Object.assign,Ow={};function Xu(e,t,a){this.props=e,this.context=t,this.refs=Ow,this.updater=a||Mw}Xu.prototype.isReactComponent={};Xu.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};Xu.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function kw(){}kw.prototype=Xu.prototype;function Mv(e,t,a){this.props=e,this.context=t,this.refs=Ow,this.updater=a||Mw}var Pv=Mv.prototype=new kw;Pv.constructor=Mv;Pw(Pv,Xu.prototype);Pv.isPureReactComponent=!0;var ww=Array.isArray;function Av(){}var vt={H:null,A:null,T:null,S:null},Nw=Object.prototype.hasOwnProperty;function Ov(e,t,a){var o=a.ref;return{$$typeof:Dv,type:e,key:t,ref:o!==void 0?o:null,props:a}}function I3(e,t){return Ov(e.type,t,e.props)}function kv(e){return typeof e=="object"&&e!==null&&e.$$typeof===Dv}function w3(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(a){return t[a]})}var Ew=/\/+/g;function Ev(e,t){return typeof e=="object"&&e!==null&&e.key!=null?w3(""+e.key):t.toString(36)}function E3(e){switch(e.status){case"fulfilled":return e.value;case"rejected":throw e.reason;default:switch(typeof e.status=="string"?e.then(Av,Av):(e.status="pending",e.then(function(t){e.status==="pending"&&(e.status="fulfilled",e.value=t)},function(t){e.status==="pending"&&(e.status="rejected",e.reason=t)})),e.status){case"fulfilled":return e.value;case"rejected":throw e.reason}}throw e}function ju(e,t,a,o,r){var n=typeof e;(n==="undefined"||n==="boolean")&&(e=null);var s=!1;if(e===null)s=!0;else switch(n){case"bigint":case"string":case"number":s=!0;break;case"object":switch(e.$$typeof){case Dv:case p3:s=!0;break;case Dw:return s=e._init,ju(s(e._payload),t,a,o,r)}}if(s)return r=r(e),s=o===""?"."+Ev(e,0):o,ww(r)?(a="",s!=null&&(a=s.replace(Ew,"$&/")+"/"),ju(r,t,a,"",function(u){return u})):r!=null&&(kv(r)&&(r=I3(r,a+(r.key==null||e&&e.key===r.key?"":(""+r.key).replace(Ew,"$&/")+"/")+s)),t.push(r)),1;s=0;var i=o===""?".":o+":";if(ww(e))for(var l=0;l<e.length;l++)o=e[l],n=i+Ev(o,l),s+=ju(o,t,a,n,r);else if(l=T3(e),typeof l=="function")for(e=l.call(e),l=0;!(o=e.next()).done;)o=o.value,n=i+Ev(o,l++),s+=ju(o,t,a,n,r);else if(n==="object"){if(typeof e.then=="function")return ju(E3(e),t,a,o,r);throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.")}return s}function Lh(e,t,a){if(e==null)return e;var o=[],r=0;return ju(e,o,"","",function(n){return t.call(a,n,r++)}),o}function A3(e){if(e._status===-1){var t=e._result,a=t();a.then(function(o){(e._status===0||e._status===-1)&&(e._status=1,e._result=o,a.status===void 0&&(a.status="fulfilled",a.value=o))},function(o){(e._status===0||e._status===-1)&&(e._status=2,e._result=o,a.status===void 0&&(a.status="rejected",a.reason=o))}),e._status===-1&&(e._status=0,e._result=a)}if(e._status===1)return e._result.default;throw e._result}var Aw=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)};function Vw(e){var t=vt.T,a={};a.types=t!==null?t.types:null,vt.T=a;try{var o=e(),r=vt.S;r!==null&&r(a,o),typeof o=="object"&&o!==null&&typeof o.then=="function"&&o.then(Av,Aw)}catch(n){Aw(n)}finally{t!==null&&a.types!==null&&(t.types=a.types),vt.T=t}}function Bw(e){var t=vt.T;if(t!==null){var a=t.types;a===null?t.types=[e]:a.indexOf(e)===-1&&a.push(e)}else Vw(Bw.bind(null,e))}var D3={map:Lh,forEach:function(e,t,a){Lh(e,function(){t.apply(this,arguments)},a)},count:function(e){var t=0;return Lh(e,function(){t++}),t},toArray:function(e){return Lh(e,function(t){return t})||[]},only:function(e){if(!kv(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};ke.Activity=L3;ke.Children=D3;ke.Component=Xu;ke.Fragment=h3;ke.Profiler=x3;ke.PureComponent=Mv;ke.StrictMode=g3;ke.Suspense=v3;ke.ViewTransition=R3;ke.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=vt;ke.__COMPILER_RUNTIME={__proto__:null,c:function(e){return vt.H.useMemoCache(e)}};ke.addTransitionType=Bw;ke.cache=function(e){return function(){return e.apply(null,arguments)}};ke.cacheSignal=function(){return null};ke.cloneElement=function(e,t,a){if(e==null)throw Error("The argument must be a React element, but you passed "+e+".");var o=Pw({},e.props),r=e.key;if(t!=null)for(n in t.key!==void 0&&(r=""+t.key),t)!Nw.call(t,n)||n==="key"||n==="__self"||n==="__source"||n==="ref"&&t.ref===void 0||(o[n]=t[n]);var n=arguments.length-2;if(n===1)o.children=a;else if(1<n){for(var s=Array(n),i=0;i<n;i++)s[i]=arguments[i+2];o.children=s}return Ov(e.type,r,o)};ke.createContext=function(e){return e={$$typeof:S3,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:y3,_context:e},e};ke.createElement=function(e,t,a){var o,r={},n=null;if(t!=null)for(o in t.key!==void 0&&(n=""+t.key),t)Nw.call(t,o)&&o!=="key"&&o!=="__self"&&o!=="__source"&&(r[o]=t[o]);var s=arguments.length-2;if(s===1)r.children=a;else if(1<s){for(var i=Array(s),l=0;l<s;l++)i[l]=arguments[l+2];r.children=i}if(e&&e.defaultProps)for(o in s=e.defaultProps,s)r[o]===void 0&&(r[o]=s[o]);return Ov(e,n,r)};ke.createRef=function(){return{current:null}};ke.forwardRef=function(e){return{$$typeof:b3,render:e}};ke.isValidElement=kv;ke.lazy=function(e){return{$$typeof:Dw,_payload:{_status:-1,_result:e},_init:A3}};ke.memo=function(e,t){return{$$typeof:C3,type:e,compare:t===void 0?null:t}};ke.startTransition=Vw;ke.unstable_useCacheRefresh=function(){return vt.H.useCacheRefresh()};ke.use=function(e){return vt.H.use(e)};ke.useActionState=function(e,t,a){return vt.H.useActionState(e,t,a)};ke.useCallback=function(e,t){return vt.H.useCallback(e,t)};ke.useContext=function(e){return vt.H.useContext(e)};ke.useDebugValue=function(){};ke.useDeferredValue=function(e,t){return vt.H.useDeferredValue(e,t)};ke.useEffect=function(e,t){return vt.H.useEffect(e,t)};ke.useEffectEvent=function(e){return vt.H.useEffectEvent(e)};ke.useId=function(){return vt.H.useId()};ke.useImperativeHandle=function(e,t,a){return vt.H.useImperativeHandle(e,t,a)};ke.useInsertionEffect=function(e,t){return vt.H.useInsertionEffect(e,t)};ke.useLayoutEffect=function(e,t){return vt.H.useLayoutEffect(e,t)};ke.useMemo=function(e,t){return vt.H.useMemo(e,t)};ke.useOptimistic=function(e,t){return vt.H.useOptimistic(e,t)};ke.useReducer=function(e,t,a){return vt.H.useReducer(e,t,a)};ke.useRef=function(e){return vt.H.useRef(e)};ke.useState=function(e){return vt.H.useState(e)};ke.useSyncExternalStore=function(e,t,a){return vt.H.useSyncExternalStore(e,t,a)};ke.useTransition=function(){return vt.H.useTransition()};ke.version="19.3.0"});var M=yo((xW,_w)=>{"use strict";_w.exports=Fw()});var Kw=yo(Pt=>{"use strict";function Fv(e,t){var a=e.length;e.push(t);e:for(;0<a;){var o=a-1>>>1,r=e[o];if(0<Rh(r,t))e[o]=t,e[a]=r,a=o;else break e}}function Kr(e){return e.length===0?null:e[0]}function Ih(e){if(e.length===0)return null;var t=e[0],a=e.pop();if(a!==t){e[0]=a;e:for(var o=0,r=e.length,n=r>>>1;o<n;){var s=2*(o+1)-1,i=e[s],l=s+1,u=e[l];if(0>Rh(i,a))l<r&&0>Rh(u,i)?(e[o]=u,e[l]=a,o=l):(e[o]=i,e[s]=a,o=s);else if(l<r&&0>Rh(u,a))e[o]=u,e[l]=a,o=l;else break e}}return t}function Rh(e,t){var a=e.sortIndex-t.sortIndex;return a!==0?a:e.id-t.id}Pt.unstable_now=void 0;typeof performance=="object"&&typeof performance.now=="function"?(zw=performance,Pt.unstable_now=function(){return zw.now()}):(Nv=Date,Hw=Nv.now(),Pt.unstable_now=function(){return Nv.now()-Hw});var zw,Nv,Hw,Vn=[],Ls=[],M3=1,ar=null,Ua=3,_v=!1,vd=!1,Cd=!1,zv=!1,Gw=typeof setTimeout=="function"?setTimeout:null,jw=typeof clearTimeout=="function"?clearTimeout:null,Uw=typeof setImmediate<"u"?setImmediate:null;function Th(e){for(var t=Kr(Ls);t!==null;){if(t.callback===null)Ih(Ls);else if(t.startTime<=e)Ih(Ls),t.sortIndex=t.expirationTime,Fv(Vn,t);else break;t=Kr(Ls)}}function Hv(e){if(Cd=!1,Th(e),!vd)if(Kr(Vn)!==null)vd=!0,Wu||(Wu=!0,Yu());else{var t=Kr(Ls);t!==null&&Uv(Hv,t.startTime-e)}}var Wu=!1,Ld=-1,Xw=5,Yw=-1;function Ww(){return zv?!0:!(Pt.unstable_now()-Yw<Xw)}function Vv(){if(zv=!1,Wu){var e=Pt.unstable_now();Yw=e;var t=!0;try{e:{vd=!1,Cd&&(Cd=!1,jw(Ld),Ld=-1),_v=!0;var a=Ua;try{t:{for(Th(e),ar=Kr(Vn);ar!==null&&!(ar.expirationTime>e&&Ww());){var o=ar.callback;if(typeof o=="function"){ar.callback=null,Ua=ar.priorityLevel;var r=o(ar.expirationTime<=e);if(e=Pt.unstable_now(),typeof r=="function"){ar.callback=r,Th(e),t=!0;break t}ar===Kr(Vn)&&Ih(Vn),Th(e)}else Ih(Vn);ar=Kr(Vn)}if(ar!==null)t=!0;else{var n=Kr(Ls);n!==null&&Uv(Hv,n.startTime-e),t=!1}}break e}finally{ar=null,Ua=a,_v=!1}t=void 0}}finally{t?Yu():Wu=!1}}}var Yu;typeof Uw=="function"?Yu=function(){Uw(Vv)}:typeof MessageChannel<"u"?(Bv=new MessageChannel,qw=Bv.port2,Bv.port1.onmessage=Vv,Yu=function(){qw.postMessage(null)}):Yu=function(){Gw(Vv,0)};var Bv,qw;function Uv(e,t){Ld=Gw(function(){e(Pt.unstable_now())},t)}Pt.unstable_IdlePriority=5;Pt.unstable_ImmediatePriority=1;Pt.unstable_LowPriority=4;Pt.unstable_NormalPriority=3;Pt.unstable_Profiling=null;Pt.unstable_UserBlockingPriority=2;Pt.unstable_cancelCallback=function(e){e.callback=null};Pt.unstable_forceFrameRate=function(e){0>e||125<e?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):Xw=0<e?Math.floor(1e3/e):5};Pt.unstable_getCurrentPriorityLevel=function(){return Ua};Pt.unstable_next=function(e){switch(Ua){case 1:case 2:case 3:var t=3;break;default:t=Ua}var a=Ua;Ua=t;try{return e()}finally{Ua=a}};Pt.unstable_requestPaint=function(){zv=!0};Pt.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var a=Ua;Ua=e;try{return t()}finally{Ua=a}};Pt.unstable_scheduleCallback=function(e,t,a){var o=Pt.unstable_now();switch(typeof a=="object"&&a!==null?(a=a.delay,a=typeof a=="number"&&0<a?o+a:o):a=o,e){case 1:var r=-1;break;case 2:r=250;break;case 5:r=1073741823;break;case 4:r=1e4;break;default:r=5e3}return r=a+r,e={id:M3++,callback:t,priorityLevel:e,startTime:a,expirationTime:r,sortIndex:-1},a>o?(e.sortIndex=a,Fv(Ls,e),Kr(Vn)===null&&e===Kr(Ls)&&(Cd?(jw(Ld),Ld=-1):Cd=!0,Uv(Hv,a-o))):(e.sortIndex=r,Fv(Vn,e),vd||_v||(vd=!0,Wu||(Wu=!0,Yu()))),e};Pt.unstable_shouldYield=Ww;Pt.unstable_wrapCallback=function(e){var t=Ua;return function(){var a=Ua;Ua=t;try{return e.apply(this,arguments)}finally{Ua=a}}}});var Qw=yo((SW,Zw)=>{"use strict";Zw.exports=Kw()});var eE=yo(qa=>{"use strict";var P3=M();function $w(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var a=2;a<arguments.length;a++)t+="&args[]="+encodeURIComponent(arguments[a])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function Rs(){}var to={d:{f:Rs,r:function(){throw Error($w(522))},D:Rs,C:Rs,L:Rs,m:Rs,X:Rs,S:Rs,M:Rs},p:0,findDOMNode:null},O3=Symbol.for("react.portal"),k3=Symbol.for("react.recoverable"),Jw=Symbol.for("react.optimistic_key");function N3(e,t,a){var o=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:O3,key:o==null?null:o===Jw?Jw:""+o,children:e,containerInfo:t,implementation:a}}var Rd=P3.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function wh(e,t){if(e==="font")return"";if(typeof t=="string")return t==="use-credentials"?t:""}qa.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=to;qa.browser=function(e){return{$$typeof:k3,_reason:e}};qa.createPortal=function(e,t){var a=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error($w(299));return N3(e,t,null,a)};qa.flushSync=function(e){var t=Rd.T,a=to.p;try{if(Rd.T=null,to.p=2,e)return e()}finally{Rd.T=t,to.p=a,to.d.f()}};qa.preconnect=function(e,t){typeof e=="string"&&(t?(t=t.crossOrigin,t=typeof t=="string"?t==="use-credentials"?t:"":void 0):t=null,to.d.C(e,t))};qa.prefetchDNS=function(e){typeof e=="string"&&to.d.D(e)};qa.preinit=function(e,t){if(typeof e=="string"&&t&&typeof t.as=="string"){var a=t.as,o=wh(a,t.crossOrigin),r=typeof t.integrity=="string"?t.integrity:void 0,n=typeof t.fetchPriority=="string"?t.fetchPriority:void 0;a==="style"?to.d.S(e,typeof t.precedence=="string"?t.precedence:void 0,{crossOrigin:o,integrity:r,fetchPriority:n}):a==="script"&&to.d.X(e,{crossOrigin:o,integrity:r,fetchPriority:n,nonce:typeof t.nonce=="string"?t.nonce:void 0})}};qa.preinitModule=function(e,t){if(typeof e=="string")if(typeof t=="object"&&t!==null){if(t.as==null||t.as==="script"){var a=wh(t.as,t.crossOrigin);to.d.M(e,{crossOrigin:a,integrity:typeof t.integrity=="string"?t.integrity:void 0,nonce:typeof t.nonce=="string"?t.nonce:void 0,fetchPriority:typeof t.fetchPriority=="string"?t.fetchPriority:void 0})}}else t==null&&to.d.M(e)};qa.preload=function(e,t){if(typeof e=="string"&&typeof t=="object"&&t!==null&&typeof t.as=="string"){var a=t.as,o=wh(a,t.crossOrigin);to.d.L(e,a,{crossOrigin:o,integrity:typeof t.integrity=="string"?t.integrity:void 0,nonce:typeof t.nonce=="string"?t.nonce:void 0,type:typeof t.type=="string"?t.type:void 0,fetchPriority:typeof t.fetchPriority=="string"?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy=="string"?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet=="string"?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes=="string"?t.imageSizes:void 0,media:typeof t.media=="string"?t.media:void 0})}};qa.preloadModule=function(e,t){if(typeof e=="string")if(t){var a=wh(t.as,t.crossOrigin);to.d.m(e,{as:typeof t.as=="string"&&t.as!=="script"?t.as:void 0,crossOrigin:a,integrity:typeof t.integrity=="string"?t.integrity:void 0,nonce:typeof t.nonce=="string"?t.nonce:void 0,fetchPriority:typeof t.fetchPriority=="string"?t.fetchPriority:void 0})}else to.d.m(e)};qa.requestFormReset=function(e){to.d.r(e)};qa.unstable_batchedUpdates=function(e,t){return e(t)};qa.useFormState=function(e,t,a){return Rd.H.useFormState(e,t,a)};qa.useFormStatus=function(){return Rd.H.useHostTransitionStatus()};qa.version="19.3.0"});var Zr=yo((vW,aE)=>{"use strict";function tE(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(tE)}catch(e){console.error(e)}}tE(),aE.exports=eE()});var UP=yo(lx=>{"use strict";var ua=Qw(),HA=M(),V3=Zr();function Z(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var a=2;a<arguments.length;a++)t+="&args[]="+encodeURIComponent(arguments[a])}return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function UA(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function fm(e){for(var t=e,a=t;a&&!a.alternate;)t=a,(t.flags&4098)!==0&&(e=t.return),a=t.return;for(;t.return;)t=t.return;return t.tag===3?e:null}function qA(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function GA(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function oE(e){if(fm(e)!==e)throw Error(Z(188))}function B3(e){var t=e.alternate;if(!t){if(t=fm(e),t===null)throw Error(Z(188));return t!==e?null:e}for(var a=e,o=t;;){var r=a.return;if(r===null)break;var n=r.alternate;if(n===null){if(o=r.return,o!==null){a=o;continue}break}if(r.child===n.child){for(n=r.child;n;){if(n===a)return oE(r),e;if(n===o)return oE(r),t;n=n.sibling}throw Error(Z(188))}if(a.return!==o.return)a=r,o=n;else{for(var s=!1,i=r.child;i;){if(i===a){s=!0,a=r,o=n;break}if(i===o){s=!0,o=r,a=n;break}i=i.sibling}if(!s){for(i=n.child;i;){if(i===a){s=!0,a=n,o=r;break}if(i===o){s=!0,o=n,a=r;break}i=i.sibling}if(!s)throw Error(Z(189))}}if(a.alternate!==o)throw Error(Z(190))}if(a.tag!==3)throw Error(Z(188));return a.stateNode.current===a?e:t}function jA(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=jA(e),t!==null)return t;e=e.sibling}return null}function Ro(e,t,a,o,r,n){for(;e!==null;){if((e.tag===5||e.tag===27||e.tag===6)&&a(e,o,r,n)||(e.tag!==22||e.memoizedState===null)&&(t||e.tag!==5&&e.tag!==27)&&Ro(e.child,t,a,o,r,n))return!0;e=e.sibling}return!1}function wl(e){for(e=e.return;e!==null;){if(e.tag===3||e.tag===5||e.tag===27)return e;e=e.return}return null}function rE(e){var t=!1;for(e=e.return;e!==null&&(e.tag===4&&(t=!0),!(e.tag===3||e.tag===5||e.tag===27));)e=e.return;return t}function XA(e){var t=[null,null],a=wl(e);return a===null||YA(t,e,a.child,{foundSelf:!1}),t}function YA(e,t,a,o){for(;a!==null;){if(a===t)o.foundSelf=!0;else if(a.tag===5||a.tag===27||a.tag===6){if(o.foundSelf)return e[1]=a,!0;e[0]=a}else if((a.tag!==22||a.memoizedState===null)&&YA(e,t,a.child,o))return!0;a=a.sibling}return!1}function la(e){switch(e.tag){case 5:case 27:case 6:return e.stateNode;case 3:return e.stateNode.containerInfo;default:throw Error(Z(559))}}var tc=null,bC=null;function F3(e,t,a){return e===a?!0:e===t?(tc=e,!0):!1}function _3(e,t,a){return e===a?(bC=e,!1):e===t?(bC!==null&&(tc=e),!0):!1}function nE(e){if(e===null)return null;do e=e===null?null:e.return;while(e&&e.tag!==5&&e.tag!==27&&e.tag!==3);return e||null}function vC(e,t,a){for(var o=0,r=e;r;r=a(r))o++;r=0;for(var n=t;n;n=a(n))r++;for(;0<o-r;)e=a(e),o--;for(;0<r-o;)t=a(t),r--;for(;o--;){if(e===t||t!==null&&e===t.alternate)return e;e=a(e),t=a(t)}return null}var St=Object.assign,z3=Symbol.for("react.element"),Eh=Symbol.for("react.transitional.element"),Md=Symbol.for("react.portal"),ac=Symbol.for("react.fragment"),WA=Symbol.for("react.strict_mode"),CC=Symbol.for("react.profiler"),KA=Symbol.for("react.consumer"),an=Symbol.for("react.context"),ML=Symbol.for("react.forward_ref"),LC=Symbol.for("react.suspense"),RC=Symbol.for("react.suspense_list"),PL=Symbol.for("react.memo"),Es=Symbol.for("react.lazy");Symbol.for("react.scope");var TC=Symbol.for("react.activity"),H3=Symbol.for("react.legacy_hidden");Symbol.for("react.tracing_marker");var U3=Symbol.for("react.memo_cache_sentinel"),IC=Symbol.for("react.view_transition"),q3=Symbol.for("react.recoverable"),sE=Symbol.iterator;function Td(e){return e===null||typeof e!="object"?null:(e=sE&&e[sE]||e["@@iterator"],typeof e=="function"?e:null)}var G3=Symbol.for("react.client.reference");function wC(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===G3?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case ac:return"Fragment";case CC:return"Profiler";case WA:return"StrictMode";case LC:return"Suspense";case RC:return"SuspenseList";case TC:return"Activity";case IC:return"ViewTransition"}if(typeof e=="object")switch(e.$$typeof){case Md:return"Portal";case an:return e.displayName||"Context";case KA:return(e._context.displayName||"Context")+".Consumer";case ML:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case PL:return t=e.displayName||null,t!==null?t:wC(e.type)||"Memo";case Es:t=e._payload,e=e._init;try{return wC(e(t))}catch{}}return null}var Pd=Array.isArray,De=HA.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,nt=V3.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,pl={pending:!1,data:null,method:null,action:null},EC=[],oc=-1;function cn(e){return{current:e}}function Oa(e){0>oc||(e.current=EC[oc],EC[oc]=null,oc--)}function Rt(e,t){oc++,EC[oc]=e.current,e.current=t}var sn=cn(null),Kd=cn(null),Bs=cn(null),pg=cn(null);function hg(e,t){switch(Rt(Bs,t),Rt(Kd,e),Rt(sn,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?bA(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=bA(t),e=xP(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}Oa(sn),Rt(sn,e)}function Lc(){Oa(sn),Oa(Kd),Oa(Bs)}function AC(e){var t=e.memoizedState;t!==null&&(Oc._currentValue=t.memoizedState,Rt(pg,e)),t=sn.current;var a=xP(t,e.type);t!==a&&(Rt(Kd,e),Rt(sn,a))}function gg(e){Kd.current===e&&(Oa(sn),Oa(Kd)),pg.current===e&&(Oa(pg),Oc._currentValue=pl)}var qv,iE;function Is(e){if(qv===void 0)try{throw Error()}catch(a){var t=a.stack.trim().match(/\n( *(at )?)/);qv=t&&t[1]||"",iE=-1<a.stack.indexOf(`
|
|
2
|
+
at`)?" (<anonymous>)":-1<a.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
3
|
+
`+qv+e+iE}var Gv=!1;function jv(e,t){if(!e||Gv)return"";Gv=!0;var a=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var o={DetermineComponentFrameRoot:function(){try{if(t){var d=function(){throw Error()};if(Object.defineProperty(d.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(d,[])}catch(p){var f=p}Reflect.construct(e,[],d)}else{try{d.call()}catch(p){f=p}d=!1;try{var m=Object.getOwnPropertyDescriptor(e.prototype,"props");Object.defineProperty(e.prototype,"props",{configurable:!0,set:function(){throw Error()}}),d=!0,new e}finally{d&&(m!==void 0?Object.defineProperty(e.prototype,"props",m):delete e.prototype.props)}}}else{try{throw Error()}catch(p){f=p}(d=e())&&typeof d.catch=="function"&&d.catch(function(){})}}catch(p){if(p&&f&&typeof p.stack=="string")return[p.stack,f.stack]}return[null,null]}};o.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var r=Object.getOwnPropertyDescriptor(o.DetermineComponentFrameRoot,"name");r&&r.configurable&&Object.defineProperty(o.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var n=o.DetermineComponentFrameRoot(),s=n[0],i=n[1];if(s&&i){var l=s.split(`
|
|
4
|
+
`),u=i.split(`
|
|
5
|
+
`);for(r=o=0;o<l.length&&!l[o].includes("DetermineComponentFrameRoot");)o++;for(;r<u.length&&!u[r].includes("DetermineComponentFrameRoot");)r++;if(o===l.length||r===u.length)for(o=l.length-1,r=u.length-1;1<=o&&0<=r&&l[o]!==u[r];)r--;for(;1<=o&&0<=r;o--,r--)if(l[o]!==u[r]){if(o!==1||r!==1)do if(o--,r--,0>r||l[o]!==u[r]){var c=`
|
|
6
|
+
`+l[o].replace(" at new "," at ");return e.displayName&&c.includes("<anonymous>")&&(c=c.replace("<anonymous>",e.displayName)),c}while(1<=o&&0<=r);break}}}finally{Gv=!1,Error.prepareStackTrace=a}return(a=e?e.displayName||e.name:"")?Is(a):""}function j3(e,t){switch(e.tag){case 26:case 27:case 5:return Is(e.type);case 16:return Is("Lazy");case 13:return e.child!==t&&t!==null?Is("Suspense Fallback"):Is("Suspense");case 19:return Is("SuspenseList");case 0:case 15:return jv(e.type,!1);case 11:return jv(e.type.render,!1);case 1:return jv(e.type,!0);case 31:return Is("Activity");case 30:return Is("ViewTransition");default:return""}}function lE(e){try{var t="",a=null;do t+=j3(e,a),a=e,e=e.return;while(e);return t}catch(o){return`
|
|
7
|
+
Error generating stack: `+o.message+`
|
|
8
|
+
`+o.stack}}var DC=Object.prototype.hasOwnProperty,OL=ua.unstable_scheduleCallback,Xv=ua.unstable_cancelCallback,X3=ua.unstable_shouldYield,Y3=ua.unstable_requestPaint,Uo=ua.unstable_now,W3=ua.unstable_getCurrentPriorityLevel,ZA=ua.unstable_ImmediatePriority,QA=ua.unstable_UserBlockingPriority,xg=ua.unstable_NormalPriority,K3=ua.unstable_LowPriority,JA=ua.unstable_IdlePriority,Z3=ua.log,Q3=ua.unstable_setDisableYieldValue,dm=null,qo=null;function Ms(e){if(typeof Z3=="function"&&Q3(e),qo&&typeof qo.setStrictMode=="function")try{qo.setStrictMode(dm,e)}catch{}}var Go=Math.clz32?Math.clz32:e4,J3=Math.log,$3=Math.LN2;function e4(e){return e>>>=0,e===0?32:31-(J3(e)/$3|0)|0}var Ah=256,Dh=262144,Mh=4194304;function ul(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&-e;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function qg(e,t,a){var o=e.pendingLanes;if(o===0)return 0;var r=0,n=e.suspendedLanes,s=e.pingedLanes;e=e.warmLanes;var i=o&134217727;return i!==0?(o=i&~n,o!==0?r=ul(o):(s&=i,s!==0?r=ul(s):a||(a=i&~e,a!==0&&(r=ul(a))))):(i=o&~n,i!==0?r=ul(i):s!==0?r=ul(s):a||(a=o&~e,a!==0&&(r=ul(a)))),r===0?0:t!==0&&t!==r&&(t&n)===0&&(n=r&-r,a=t&-t,n>=a||n===32&&(a&4194048)!==0)?t:r}function mm(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function $A(e,t){(t&8)!==0&&(t|=t&32);var a=e.entangledLanes;if(a!==0)for(e=e.entanglements,a&=t;0<a;){var o=31-Go(a),r=1<<o;t|=e[o],a&=~r}return t}function t4(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function eD(){var e=Mh;return Mh<<=1,(Mh&62914560)===0&&(Mh=4194304),e}function Yv(e){for(var t=[],a=0;31>a;a++)t.push(e);return t}function pm(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function a4(e,t,a,o,r,n){var s=e.pendingLanes;e.pendingLanes=a,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=a,e.entangledLanes&=a,e.errorRecoveryDisabledLanes&=a,e.shellSuspendCounter=0;var i=e.entanglements,l=e.expirationTimes,u=e.hiddenUpdates;for(a=s&~a;0<a;){var c=31-Go(a),d=1<<c;i[c]=0,l[c]=-1;var f=u[c];if(f!==null)for(u[c]=null,c=0;c<f.length;c++){var m=f[c];m!==null&&(m.lane&=-536870913)}a&=~d}o!==0&&tD(e,o,0),n!==0&&r===0&&e.tag!==0&&(e.suspendedLanes|=n&~(s&~t))}function tD(e,t,a){e.pendingLanes|=t,e.suspendedLanes&=~t;var o=31-Go(t);e.entangledLanes|=t,e.entanglements[o]=e.entanglements[o]|1073741824|a&261930}function aD(e,t){var a=e.entangledLanes|=t;for(e=e.entanglements;a;){var o=31-Go(a),r=1<<o;r&t|e[o]&t&&(e[o]|=t),a&=~r}}function oD(e,t){var a=t&-t;return a=(a&42)!==0?1:kL(a),(a&(e.suspendedLanes|t))!==0?0:a}function kL(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function NL(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function rD(){var e=nt.p;return e!==0?e:(e=window.event,e===void 0?32:_P(e.type))}function uE(e,t){var a=nt.p;try{return nt.p=e,t()}finally{nt.p=a}}var Kn=Math.random().toString(36).slice(2),Ma="__reactFiber$"+Kn,To="__reactProps$"+Kn,Vc="__reactContainer$"+Kn,cE="__reactEvents$"+Kn,o4="__reactListeners$"+Kn,r4="__reactHandles$"+Kn,fE="__reactResources$"+Kn,hm="__reactMarker$"+Kn,yg="__reactLoad$"+Kn;function Gg(e){delete e[Ma],delete e[To],delete e[o4],delete e[r4]}function dl(e){var t;if(t=e[Ma])return t;for(var a=e.parentNode;a;){if(t=a[Vc]||a[Ma]){if(a=t.alternate,t.child!==null||a!==null&&a.child!==null)for(e=EA(e);e!==null;){if(a=e[Ma])return a;e=EA(e)}return t}e=a,a=e.parentNode}return null}function Bc(e){if(e=e[Ma]||e[Vc]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function Od(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(Z(33))}function mc(e){var t=e[fE];return t||(t=e[fE]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function ya(e){e[hm]=!0}function nD(e){e[yg]=void 0}var sD=new Set,iD={};function El(e,t){Rc(e,t),Rc(e+"Capture",t)}function Rc(e,t){for(iD[e]=t,e=0;e<t.length;e++)sD.add(t[e])}var n4=RegExp("^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$"),dE={},mE={};function s4(e){return DC.call(mE,e)?!0:DC.call(dE,e)?!1:n4.test(e)?mE[e]=!0:(dE[e]=!0,!1)}var tt=!1;function pE(){var e=tt;return tt=!1,e}function Kh(e,t,a){if(s4(t))if(a===null)e.removeAttribute(t);else{switch(typeof a){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var o=t.toLowerCase().slice(0,5);if(o!=="data-"&&o!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,a)}}function Ph(e,t,a){if(a===null)e.removeAttribute(t);else{switch(typeof a){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,a)}}function Bn(e,t,a,o){if(o===null)e.removeAttribute(a);else{switch(typeof o){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(a);return}e.setAttributeNS(t,a,o)}}function Fo(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function lD(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function i4(e,t,a){var o=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&typeof o<"u"&&typeof o.get=="function"&&typeof o.set=="function"){var r=o.get,n=o.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return r.call(this)},set:function(s){a=""+s,n.call(this,s)}}),Object.defineProperty(e,t,{enumerable:o.enumerable}),{getValue:function(){return a},setValue:function(s){a=""+s},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function MC(e){if(!e._valueTracker){var t=lD(e)?"checked":"value";e._valueTracker=i4(e,t,""+e[t])}}function uD(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var a=t.getValue(),o="";return e&&(o=lD(e)?e.checked?"true":"false":e.value),e=o,e!==a?(t.setValue(e),!0):!1}var l4=/[\n"\\]/g;function ir(e){return e.replace(l4,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function PC(e,t,a,o,r,n,s,i){e.name="",s!=null&&typeof s!="function"&&typeof s!="symbol"&&typeof s!="boolean"?e.type=s:e.removeAttribute("type"),t!=null?s==="number"?(t===0&&e.value===""||e.value!=t)&&(e.value=""+Fo(t)):e.value!==""+Fo(t)&&(e.value=""+Fo(t)):s!=="submit"&&s!=="reset"||e.removeAttribute("value"),t!=null?s==="number"&&e.value==t?Wv(e,Fo(e.value)):Wv(e,Fo(t)):a!=null?Wv(e,Fo(a)):o!=null&&e.removeAttribute("value"),r==null&&n!=null&&(e.defaultChecked=!!n),r!=null&&(e.checked=r&&typeof r!="function"&&typeof r!="symbol"),i!=null&&typeof i!="function"&&typeof i!="symbol"&&typeof i!="boolean"?e.name=""+Fo(i):e.removeAttribute("name")}function cD(e,t,a,o,r,n,s,i){if(n!=null&&typeof n!="function"&&typeof n!="symbol"&&typeof n!="boolean"&&(e.type=n),t!=null||a!=null){if(!(n!=="submit"&&n!=="reset"||t!=null)){MC(e);return}a=a!=null?""+Fo(a):"",t=t!=null?""+Fo(t):a,i||t===e.value||(e.value=t),e.defaultValue=t}o=o??r,o=typeof o!="function"&&typeof o!="symbol"&&!!o,e.checked=i?e.checked:!!o,e.defaultChecked=!!o,s!=null&&typeof s!="function"&&typeof s!="symbol"&&typeof s!="boolean"&&(e.name=s),MC(e)}function Wv(e,t){e.defaultValue!==""+t&&(e.defaultValue=""+t)}function pc(e,t,a,o){if(e=e.options,t){t={};for(var r=0;r<a.length;r++)t["$"+a[r]]=!0;for(a=0;a<e.length;a++)r=t.hasOwnProperty("$"+e[a].value),e[a].selected!==r&&(e[a].selected=r),r&&o&&(e[a].defaultSelected=!0)}else{for(a=""+Fo(a),t=null,r=0;r<e.length;r++){if(e[r].value===a){e[r].selected=!0,o&&(e[r].defaultSelected=!0);return}t!==null||e[r].disabled||(t=e[r])}t!==null&&(t.selected=!0)}}function fD(e,t,a){if(t!=null&&(t=""+Fo(t),t!==e.value&&(e.value=t),a==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=a!=null?""+Fo(a):""}function dD(e,t,a,o){if(t==null){if(o!=null){if(a!=null)throw Error(Z(92));if(Pd(o)){if(1<o.length)throw Error(Z(93));o=o[0]}a=o}a==null&&(a=""),t=a}a=Fo(t),e.defaultValue=a,o=e.textContent,o===a&&o!==""&&o!==null&&(e.value=o),MC(e)}function Tc(e,t){if(t){var a=e.firstChild;if(a&&a===e.lastChild&&a.nodeType===3){a.nodeValue=t;return}}e.textContent=t}var u4=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));function hE(e,t,a){var o=t.indexOf("--")===0;a==null||typeof a=="boolean"||a===""?o?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":o?e.setProperty(t,a):typeof a!="number"||a===0||u4.has(t)?t==="float"?e.cssFloat=a:e[t]=(""+a).trim():e[t]=a+"px"}function mD(e,t,a){if(t!=null&&typeof t!="object")throw Error(Z(62));if(e=e.style,a!=null){for(var o in a)!a.hasOwnProperty(o)||t!=null&&t.hasOwnProperty(o)||(o.indexOf("--")===0?e.setProperty(o,""):o==="float"?e.cssFloat="":e[o]="",tt=!0);for(var r in t)o=t[r],t.hasOwnProperty(r)&&a[r]!==o&&(hE(e,r,o),tt=!0)}else for(var n in t)t.hasOwnProperty(n)&&hE(e,n,t[n])}function VL(e){if(e.indexOf("-")===-1)return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var c4=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["maskType","mask-type"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),f4=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function Zh(e){return f4.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function on(){}var OC=null;function BL(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var rc=null,hc=null;function gE(e){var t=Bc(e);if(t&&(e=t.stateNode)){var a=e[To]||null;e:switch(e=t.stateNode,t.type){case"input":if(PC(e,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name),t=a.name,a.type==="radio"&&t!=null){for(a=e;a.parentNode;)a=a.parentNode;for(a=a.querySelectorAll('input[name="'+ir(""+t)+'"][type="radio"]'),t=0;t<a.length;t++){var o=a[t];if(o!==e&&o.form===e.form){var r=o[To]||null;if(!r)throw Error(Z(90));PC(o,r.value,r.defaultValue,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name)}}for(t=0;t<a.length;t++)o=a[t],o.form===e.form&&uD(o)}break e;case"textarea":fD(e,a.value,a.defaultValue);break e;case"select":t=a.value,t!=null&&pc(e,!!a.multiple,t,!1)}}}var Kv=!1;function pD(e,t,a){if(Kv)return e(t,a);Kv=!0;try{var o=e(t);return o}finally{if(Kv=!1,(rc!==null||hc!==null)&&(rx(),rc&&(t=rc,e=hc,hc=rc=null,gE(t),e)))for(t=0;t<e.length;t++)gE(e[t])}}function Zd(e,t){var a=e.stateNode;if(a===null)return null;var o=a[To]||null;if(o===null)return null;a=o[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(o=!o.disabled)||(e=e.type,o=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!o;break e;default:e=!1}if(e)return null;if(a&&typeof a!="function")throw Error(Z(231,t,typeof a));return a}var qn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),kC=!1;if(qn)try{Ku={},Object.defineProperty(Ku,"passive",{get:function(){kC=!0}}),window.addEventListener("test",Ku,Ku),window.removeEventListener("test",Ku,Ku)}catch{kC=!1}var Ku,Ps=null,FL=null,Qh=null;function hD(){if(Qh)return Qh;var e,t=FL,a=t.length,o,r="value"in Ps?Ps.value:Ps.textContent,n=r.length;for(e=0;e<a&&t[e]===r[e];e++);var s=a-e;for(o=1;o<=s&&t[a-o]===r[n-o];o++);return Qh=r.slice(e,1<o?1-o:void 0)}function Jh(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Oh(){return!0}function xE(){return!1}function no(e){function t(a,o,r,n,s){this._reactName=a,this._targetInst=r,this.type=o,this.nativeEvent=n,this.target=s,this.currentTarget=null;for(var i in e)e.hasOwnProperty(i)&&(a=e[i],this[i]=a?a(n):n[i]);return this.isDefaultPrevented=(n.defaultPrevented!=null?n.defaultPrevented:n.returnValue===!1)?Oh:xE,this.isPropagationStopped=xE,this}return St(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var a=this.nativeEvent;a&&(a.preventDefault?a.preventDefault():typeof a.returnValue!="unknown"&&(a.returnValue=!1),this.isDefaultPrevented=Oh)},stopPropagation:function(){var a=this.nativeEvent;a&&(a.stopPropagation?a.stopPropagation():typeof a.cancelBubble!="unknown"&&(a.cancelBubble=!0),this.isPropagationStopped=Oh)},persist:function(){},isPersistent:Oh}),t}var Js={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},jg=no(Js),gm=St({},Js,{view:0,detail:0}),d4=no(gm),Zv,Qv,Id,Xg=St({},gm,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:_L,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==Id&&(Id&&e.type==="mousemove"?(Zv=e.screenX-Id.screenX,Qv=e.screenY-Id.screenY):Qv=Zv=0,Id=e),Zv)},movementY:function(e){return"movementY"in e?e.movementY:Qv}}),yE=no(Xg),m4=St({},Xg,{dataTransfer:0}),p4=no(m4),h4=St({},gm,{relatedTarget:0}),Jv=no(h4),g4=St({},Js,{animationName:0,elapsedTime:0,pseudoElement:0}),x4=no(g4),y4=St({},Js,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),S4=no(y4),b4=St({},Js,{data:0}),SE=no(b4),v4={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},C4={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},L4={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function R4(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=L4[e])?!!t[e]:!1}function _L(){return R4}var T4=St({},gm,{key:function(e){if(e.key){var t=v4[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Jh(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?C4[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:_L,charCode:function(e){return e.type==="keypress"?Jh(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Jh(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),I4=no(T4),w4=St({},Xg,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),bE=no(w4),E4=St({},Js,{submitter:0}),A4=no(E4),D4=St({},gm,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:_L}),M4=no(D4),P4=St({},Js,{propertyName:0,elapsedTime:0,pseudoElement:0}),O4=no(P4),k4=St({},Xg,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),N4=no(k4),V4=St({},Js,{newState:0,oldState:0,source:0}),B4=no(V4),F4=[9,13,27,32],zL=qn&&"CompositionEvent"in window,Vd=null;qn&&"documentMode"in document&&(Vd=document.documentMode);var _4=qn&&"TextEvent"in window&&!Vd,gD=qn&&(!zL||Vd&&8<Vd&&11>=Vd),vE=" ",CE=!1;function xD(e,t){switch(e){case"keyup":return F4.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function yD(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var nc=!1;function z4(e,t){switch(e){case"compositionend":return yD(t);case"keypress":return t.which!==32?null:(CE=!0,vE);case"textInput":return e=t.data,e===vE&&CE?null:e;default:return null}}function H4(e,t){if(nc)return e==="compositionend"||!zL&&xD(e,t)?(e=hD(),Qh=FL=Ps=null,nc=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return gD&&t.locale!=="ko"?null:t.data;default:return null}}var U4={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function LE(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!U4[e.type]:t==="textarea"}function SD(e,t,a,o){rc?hc?hc.push(o):hc=[o]:rc=o,t=zg(t,"onChange"),0<t.length&&(a=new jg("onChange","change",null,a,o),e.push({event:a,listeners:t}))}var Bd=null,Qd=null;function q4(e){pP(e,0)}function Yg(e){var t=Od(e);if(uD(t))return e}function RE(e,t){if(e==="change")return t}var bD=!1;qn&&(qn?(Nh="oninput"in document,Nh||($v=document.createElement("div"),$v.setAttribute("oninput","return;"),Nh=typeof $v.oninput=="function"),kh=Nh):kh=!1,bD=kh&&(!document.documentMode||9<document.documentMode));var kh,Nh,$v;function TE(){Bd&&(Bd.detachEvent("onpropertychange",vD),Qd=Bd=null)}function vD(e){if(e.propertyName==="value"&&Yg(Qd)){var t=[];SD(t,Qd,e,BL(e)),pD(q4,t)}}function G4(e,t,a){e==="focusin"?(TE(),Bd=t,Qd=a,Bd.attachEvent("onpropertychange",vD)):e==="focusout"&&TE()}function j4(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Yg(Qd)}function X4(e,t){if(e==="click")return Yg(t)}function Y4(e,t){if(e==="input"||e==="change")return Yg(t)}function W4(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Xo=typeof Object.is=="function"?Object.is:W4;function Jd(e,t){if(Xo(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var a=Object.keys(e),o=Object.keys(t);if(a.length!==o.length)return!1;for(o=0;o<a.length;o++){var r=a[o];if(!DC.call(t,r)||!Xo(e[r],t[r]))return!1}return!0}function NC(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function IE(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function wE(e,t){var a=IE(e);e=0;for(var o;a;){if(a.nodeType===3){if(o=e+a.textContent.length,e<=t&&o>=t)return{node:a,offset:t-e};e=o}e:{for(;a;){if(a.nextSibling){a=a.nextSibling;break e}a=a.parentNode}a=void 0}a=IE(a)}}function CD(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?CD(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function LD(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=NC(e.document);t instanceof e.HTMLIFrameElement;){try{var a=typeof t.contentWindow.location.href=="string"}catch{a=!1}if(a)e=t.contentWindow;else break;t=NC(e.document)}return t}function HL(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var K4=qn&&"documentMode"in document&&11>=document.documentMode,sc=null,VC=null,Fd=null,BC=!1;function EE(e,t,a){var o=a.window===a?a.document:a.nodeType===9?a:a.ownerDocument;BC||sc==null||sc!==NC(o)||(o=sc,"selectionStart"in o&&HL(o)?o={start:o.selectionStart,end:o.selectionEnd}:(o=(o.ownerDocument&&o.ownerDocument.defaultView||window).getSelection(),o={anchorNode:o.anchorNode,anchorOffset:o.anchorOffset,focusNode:o.focusNode,focusOffset:o.focusOffset}),Fd&&Jd(Fd,o)||(Fd=o,o=zg(VC,"onSelect"),0<o.length&&(t=new jg("onSelect","select",null,t,a),e.push({event:t,listeners:o}),t.target=sc)))}function il(e,t){var a={};return a[e.toLowerCase()]=t.toLowerCase(),a["Webkit"+e]="webkit"+t,a["Moz"+e]="moz"+t,a}var ic={animationend:il("Animation","AnimationEnd"),animationiteration:il("Animation","AnimationIteration"),animationstart:il("Animation","AnimationStart"),transitionrun:il("Transition","TransitionRun"),transitionstart:il("Transition","TransitionStart"),transitioncancel:il("Transition","TransitionCancel"),transitionend:il("Transition","TransitionEnd")},eC={},RD={};qn&&(RD=document.createElement("div").style,"AnimationEvent"in window||(delete ic.animationend.animation,delete ic.animationiteration.animation,delete ic.animationstart.animation),"TransitionEvent"in window||delete ic.transitionend.transition);function Al(e){if(eC[e])return eC[e];if(!ic[e])return e;var t=ic[e],a;for(a in t)if(t.hasOwnProperty(a)&&a in RD)return eC[e]=t[a];return e}var TD=Al("animationend"),ID=Al("animationiteration"),wD=Al("animationstart"),Z4=Al("transitionrun"),Q4=Al("transitionstart"),J4=Al("transitioncancel"),ED=Al("transitionend"),AD=new Map,FC="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error fullscreenChange fullscreenError gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");FC.push("scrollEnd");function Vr(e,t){AD.set(e,t),El(t,[e])}var $4=0;function Gn(e,t){if(e.name!=null&&e.name!=="auto")return e.name;if(t.autoName!==null)return t.autoName;e=Nr.identifierPrefix;var a=$4++;return e="_"+e+"t_"+a.toString(32)+"_",t.autoName=e}function AE(e){if(e==null||typeof e=="string")return e;var t=null,a=Cc;if(a!==null)for(var o=0;o<a.length;o++){var r=e[a[o]];if(r!=null){if(r==="none")return"none";t=t==null?r:t+(" "+r)}}return t??e.default}function Zn(e,t){return e=AE(e),t=AE(t),t==null?e==="auto"?null:e:t==="auto"?null:t}var Sg=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e=="object"&&e!==null&&typeof e.message=="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)},rr=[],lc=0,UL=0;function Wg(){for(var e=lc,t=UL=lc=0;t<e;){var a=rr[t];rr[t++]=null;var o=rr[t];rr[t++]=null;var r=rr[t];rr[t++]=null;var n=rr[t];if(rr[t++]=null,o!==null&&r!==null){var s=o.pending;s===null?r.next=r:(r.next=s.next,s.next=r),o.pending=r}n!==0&&DD(a,r,n)}}function Kg(e,t,a,o){rr[lc++]=e,rr[lc++]=t,rr[lc++]=a,rr[lc++]=o,UL|=o,e.lanes|=o,e=e.alternate,e!==null&&(e.lanes|=o)}function qL(e,t,a,o){return Kg(e,t,a,o),bg(e)}function Dl(e,t){return Kg(e,null,null,t),bg(e)}function DD(e,t,a){e.lanes|=a;var o=e.alternate;o!==null&&(o.lanes|=a);for(var r=!1,n=e.return;n!==null;)n.childLanes|=a,o=n.alternate,o!==null&&(o.childLanes|=a),n.tag===22&&(e=n.stateNode,e===null||e._visibility&1||(r=!0)),e=n,n=n.return;return e.tag===3?(n=e.stateNode,r&&t!==null&&(r=31-Go(a),e=n.hiddenUpdates,o=e[r],o===null?e[r]=[t]:o.push(t),t.lane=a|536870912),n):null}function bg(e){if(50<Wd)throw Wd=0,lg=null,Error(Z(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var uc={};function eq(e,t,a,o){this.tag=e,this.key=a,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=o,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Co(e,t,a,o){return new eq(e,t,a,o)}function GL(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Hn(e,t){var a=e.alternate;return a===null?(a=Co(e.tag,t,e.key,e.mode),a.elementType=e.elementType,a.type=e.type,a.stateNode=e.stateNode,a.alternate=e,e.alternate=a):(a.pendingProps=t,a.type=e.type,a.flags=0,a.subtreeFlags=0,a.deletions=null),a.flags=e.flags&1206910976,a.childLanes=e.childLanes,a.lanes=e.lanes,a.child=e.child,a.memoizedProps=e.memoizedProps,a.memoizedState=e.memoizedState,a.updateQueue=e.updateQueue,t=e.dependencies,a.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},a.sibling=e.sibling,a.index=e.index,a.ref=e.ref,a.refCleanup=e.refCleanup,a}function MD(e,t){e.flags&=1206910978;var a=e.alternate;return a===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=a.childLanes,e.lanes=a.lanes,e.child=a.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=a.memoizedProps,e.memoizedState=a.memoizedState,e.updateQueue=a.updateQueue,e.type=a.type,t=a.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function $h(e,t,a,o,r,n){var s=0;if(o=e,typeof o=="function")GL(o)&&(s=1);else if(typeof o=="string")s=I5(e,a,sn.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(o){case TC:return e=Co(31,a,t,r),e.elementType=TC,e.lanes=n,e;case ac:return hl(a.children,r,n,t);case WA:s=8,r|=24;break;case CC:return e=Co(12,a,t,r|2),e.elementType=CC,e.lanes=n,e;case LC:return e=Co(13,a,t,r),e.elementType=LC,e.lanes=n,e;case RC:return e=Co(19,a,t,r),e.elementType=RC,e.lanes=n,e;case H3:case IC:return e=r|32,e=Co(30,a,t,e),e.elementType=IC,e.lanes=n,e.stateNode={autoName:null,paired:null,clones:null,ref:null},e;default:if(typeof o=="object"&&o!==null)switch(o.$$typeof){case an:s=10;break e;case KA:s=9;break e;case ML:s=11;break e;case PL:s=14;break e;case Es:s=16,o=null;break e}s=29,a=Error(Z(130,e===null?"null":typeof e,"")),o=null}return t=Co(s,a,t,r),t.elementType=e,t.type=o,t.lanes=n,t}function hl(e,t,a,o){return e=Co(7,e,o,t),e.lanes=a,e}function tC(e,t,a){return e=Co(6,e,null,t),e.lanes=a,e}function PD(e){var t=Co(18,null,null,0);return t.stateNode=e,t}function aC(e,t,a){return t=Co(4,e.children!==null?e.children:[],e.key,t),t.lanes=a,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var DE=new WeakMap;function lr(e,t){if(typeof e=="object"&&e!==null){var a=DE.get(e);return a!==void 0?a:(t={value:e,source:t,stack:lE(t)},DE.set(e,t),t)}return{value:e,source:t,stack:lE(t)}}var cc=[],fc=0,vg=null,$d=0,nr=[],sr=0,Ys=null,rn=1,nn="";function _n(e,t){cc[fc++]=$d,cc[fc++]=vg,vg=e,$d=t}function OD(e,t,a){nr[sr++]=rn,nr[sr++]=nn,nr[sr++]=Ys,Ys=e;var o=rn;e=nn;var r=32-Go(o)-1;o&=~(1<<r),a+=1;var n=32-Go(t)+r;if(30<n){var s=r-r%5;n=(o&(1<<s)-1).toString(32),o>>=s,r-=s,rn=1<<32-Go(t)+r|a<<r|o,nn=n+e}else rn=1<<n|a<<r|o,nn=e}function Zg(e){e.return!==null&&(_n(e,1),OD(e,1,0))}function jL(e){for(;e===vg;)vg=cc[--fc],cc[fc]=null,$d=cc[--fc],cc[fc]=null;for(;e===Ys;)Ys=nr[--sr],nr[sr]=null,nn=nr[--sr],nr[sr]=null,rn=nr[--sr],nr[sr]=null}function kD(e,t){nr[sr++]=rn,nr[sr++]=nn,nr[sr++]=Ys,rn=t.id,nn=t.overflow,Ys=e}var Sa=null,Lt=null,Ge=!1,Fs=null,ur=!1,_C=Error(Z(519));function Ws(e){var t=Error(Z(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw em(lr(t,e)),_C}function ME(e){var t=e.stateNode,a=e.type,o=e.memoizedProps;switch(t[Ma]=e,t[To]=o,a){case"dialog":Xe("cancel",t),Xe("close",t);break;case"iframe":case"object":case"embed":Xe("load",t);break;case"video":case"audio":for(a=0;a<rm.length;a++)Xe(rm[a],t);break;case"source":Xe("error",t);break;case"img":case"image":case"link":Xe("error",t),Xe("load",t);break;case"details":Xe("toggle",t);break;case"input":Xe("invalid",t),cD(t,o.value,o.defaultValue,o.checked,o.defaultChecked,o.type,o.name,!0);break;case"select":Xe("invalid",t);break;case"textarea":Xe("invalid",t),dD(t,o.value,o.defaultValue,o.children)}a=o.children,typeof a!="string"&&typeof a!="number"&&typeof a!="bigint"||t.textContent===""+a||o.suppressHydrationWarning===!0||gP(t.textContent,a)?(o.popover!=null&&(Xe("beforetoggle",t),Xe("toggle",t)),o.onScroll!=null&&Xe("scroll",t),o.onScrollEnd!=null&&Xe("scrollend",t),o.onClick!=null&&(t.onclick=on),t=!0):t=!1,t||Ws(e,!0)}function Cg(e){for(Sa=e.return;Sa;)switch(Sa.tag){case 5:case 31:case 13:ur=!1;return;case 27:case 3:ur=!0;return;default:Sa=Sa.return}}function Zu(e){if(e!==Sa)return!1;if(!Ge)return Cg(e),Ge=!0,!1;var t=e.tag,a;if((a=t!==3&&t!==27)&&((a=t===5)&&(a=e.type,a=!(a!=="form"&&a!=="button")||LL(e.type,e.memoizedProps)),a=!a),a&&Lt&&Ws(e),Cg(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(Z(317));Lt=wA(e)}else if(t===31){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(Z(317));Lt=wA(e)}else t===27?(t=Lt,$s(e.type)?(e=wL,wL=null,Lt=e):Lt=t):Lt=Sa?cr(e.stateNode.nextSibling):null;return!0}function Sl(){Lt=Sa=null,Ge=!1}function oC(){var e=Fs;return e!==null&&(bo===null?bo=e:bo.push.apply(bo,e),Fs=null),e}function em(e){Fs===null?Fs=[e]:Fs.push(e)}var zC=cn(null),Ml=null,zn=null;function Os(e,t,a){Rt(zC,t._currentValue),t._currentValue=a}function Un(e){e._currentValue=zC.current,Oa(zC)}function eg(e,t,a){for(;e!==null;){var o=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,o!==null&&(o.childLanes|=t)):o!==null&&(o.childLanes&t)!==t&&(o.childLanes|=t),e===a)break;e=e.return}}function HC(e,t,a,o){var r=e.child;for(r!==null&&(r.return=e);r!==null;){var n=r.dependencies;if(n!==null){var s=r.child;n=n.firstContext;e:for(;n!==null;){var i=n;n=r;for(var l=0;l<t.length;l++)if(i.context===t[l]){n.lanes|=a,i=n.alternate,i!==null&&(i.lanes|=a),eg(n.return,a,e),o||(s=null);break e}n=i.next}}else if(r.tag===18){if(s=r.return,s===null)throw Error(Z(341));s.lanes|=a,n=s.alternate,n!==null&&(n.lanes|=a),eg(s,a,e),s=null}else r.tag===13&&r.memoizedState!==null&&r.memoizedState.dehydrated===null?(r.lanes|=a,s=r.alternate,s!==null&&(s.lanes|=a),eg(r.return,a,e),s=r.child,s=s!==null?s.sibling:null):s=r.child;if(s!==null)s.return=r;else for(s=r;s!==null;){if(s===e){s=null;break}if(r=s.sibling,r!==null){r.return=s.return,s=r;break}s=s.return}r=s}}function bl(e,t,a,o){e=null;for(var r=t,n=!1;r!==null;){if(!n){if((r.flags&524288)!==0)n=!0;else if((r.flags&262144)!==0)break}if(r.tag===10){var s=r.alternate;if(s===null)throw Error(Z(387));if(s=s.memoizedProps,s!==null){var i=r.type;Xo(r.pendingProps.value,s.value)||(e!==null?e.push(i):e=[i])}}else if(r===pg.current){if(s=r.alternate,s===null)throw Error(Z(387));s.memoizedState.memoizedState!==r.memoizedState.memoizedState&&(e!==null?e.push(Oc):e=[Oc])}r=r.return}return e!==null&&HC(t,e,a,o),t.flags|=262144,e!==null}function Lg(e){for(e=e.firstContext;e!==null;){if(!Xo(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function vl(e){Ml=e,zn=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function Pa(e){return ND(Ml,e)}function Vh(e,t){return Ml===null&&vl(e),ND(e,t)}function ND(e,t){var a=t._currentValue;if(t={context:t,memoizedValue:a,next:null},zn===null){if(e===null)throw Error(Z(308));zn=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else zn=zn.next=t;return a}var tq=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(a,o){e.push(o)}};this.abort=function(){t.aborted=!0,e.forEach(function(a){return a()})}},aq=ua.unstable_scheduleCallback,oq=ua.unstable_NormalPriority,ta={$$typeof:an,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function XL(){return{controller:new tq,data:new Map,refCount:0}}function xm(e){e.refCount--,e.refCount===0&&aq(oq,function(){e.controller.abort()})}function PE(e,t){if((e.pendingLanes&4194048)!==0){var a=e.transitionTypes;for(a===null&&(a=e.transitionTypes=[]),e=0;e<t.length;e++){var o=t[e];a.indexOf(o)===-1&&a.push(o)}}}var kd=null;function rq(e){var t=e.transitionTypes;return e.transitionTypes=null,t}var _d=null,UC=0,Cl=0,gc=null;function nq(e,t){if(_d===null){var a=_d=[];UC=0,Cl=bR(),gc={status:"pending",value:void 0,then:function(o){a.push(o)}}}return UC++,t.then(OE,OE),t}function OE(){if(--UC===0&&(kd=null,_d!==null)){gc!==null&&(gc.status="fulfilled");var e=_d;_d=null,Cl=0,gc=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function sq(e,t){var a=[],o={status:"pending",value:null,reason:null,then:function(r){a.push(r)}};return e.then(function(){o.status="fulfilled",o.value=t;for(var r=0;r<a.length;r++)(0,a[r])(t)},function(r){for(o.status="rejected",o.reason=r,r=0;r<a.length;r++)(0,a[r])(void 0)}),o}var kE=De.S;De.S=function(e,t){if($M=Uo(),typeof t=="object"&&t!==null&&typeof t.then=="function"&&nq(e,t),kd!==null)for(var a=Dc;a!==null;)PE(a,kd),a=a.next;if(a=e.types,a!==null){for(var o=Dc;o!==null;)PE(o,a),o=o.next;if(Cl!==0){o=kd,o===null&&(o=kd=[]);for(var r=0;r<a.length;r++){var n=a[r];o.indexOf(n)===-1&&o.push(n)}}}kE!==null&&kE(e,t)};var gl=cn(null);function YL(){var e=gl.current;return e!==null?e:yt.pooledCache}function tg(e,t){t===null?Rt(gl,gl.current):Rt(gl,t.pool)}function VD(){var e=YL();return e===null?null:{parent:ta._currentValue,pool:e}}var Fc=Error(Z(460)),WL=Error(Z(474)),Qg=Error(Z(542)),Rg={then:function(){}};function NE(e){return e=e.status,e==="fulfilled"||e==="rejected"}function BD(e,t,a){switch(a=e[a],a===void 0?e.push(t):a!==t&&(t.then(on,on),t=a),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,BE(e),e===void 0&&!("reason"in t)?Error(Z(600)):e;default:if(typeof t.status=="string")t.then(on,on);else{if(e=yt,e!==null&&100<e.shellSuspendCounter)throw Error(Z(482));e=t,e.status="pending",e.then(function(o){if(t.status==="pending"){var r=t;r.status="fulfilled",r.value=o}},function(o){if(t.status==="pending"){var r=t;r.status="rejected",r.reason=o}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,BE(e),e}throw xl=t,Fc}}function cl(e){try{var t=e._init;return t(e._payload)}catch(a){throw a!==null&&typeof a=="object"&&typeof a.then=="function"?(xl=a,Fc):a}}var xl=null;function VE(){if(xl===null)throw Error(Z(459));var e=xl;return xl=null,e}function BE(e){if(e===Fc||e===Qg)throw Error(Z(483))}var xc=null,tm=0;function Bh(e){var t=tm;return tm+=1,xc===null&&(xc=[]),BD(xc,e,t)}function Ts(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function Fh(e,t){throw t.$$typeof===z3?Error(Z(525)):(e=Object.prototype.toString.call(t),Error(Z(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)))}function FD(e){function t(g,h){if(e){var x=g.deletions;x===null?(g.deletions=[h],g.flags|=16):x.push(h)}}function a(g,h){if(!e)return null;for(;h!==null;)t(g,h),h=h.sibling;return null}function o(g){for(var h=new Map;g!==null;)g.key===null?h.set(g.index,g):h.set(g.key,g),g=g.sibling;return h}function r(g,h){return g=Hn(g,h),g.index=0,g.sibling=null,g}function n(g,h,x){return g.index=x,e?(x=g.alternate,x!==null?(x=x.index,x<h?(g.flags|=2,h):x):(g.flags|=134217730,h)):(g.flags|=1048576,h)}function s(g){return e&&g.alternate===null&&(g.flags|=134217730),g}function i(g,h,x,S){return h===null||h.tag!==6?(h=tC(x,g.mode,S),h.return=g,h):(h=r(h,x),h.return=g,h)}function l(g,h,x,S){var v=x.type;return v===ac?(g=c(g,h,x.props.children,S,x.key),Ts(g,x),g):h!==null&&(h.elementType===v||typeof v=="object"&&v!==null&&v.$$typeof===Es&&cl(v)===h.type)?(h=r(h,x.props),Ts(h,x),h.return=g,h):(h=$h(x.type,x.key,x.props,null,g.mode,S),Ts(h,x),h.return=g,h)}function u(g,h,x,S){return h===null||h.tag!==4||h.stateNode.containerInfo!==x.containerInfo||h.stateNode.implementation!==x.implementation?(h=aC(x,g.mode,S),h.return=g,h):(h=r(h,x.children||[]),h.return=g,h)}function c(g,h,x,S,v){return h===null||h.tag!==7?(h=hl(x,g.mode,S,v),h.return=g,h):(h=r(h,x),h.return=g,h)}function d(g,h,x){if(typeof h=="string"&&h!==""||typeof h=="number"||typeof h=="bigint")return h=tC(""+h,g.mode,x),h.return=g,h;if(typeof h=="object"&&h!==null){switch(h.$$typeof){case Eh:return x=$h(h.type,h.key,h.props,null,g.mode,x),Ts(x,h),x.return=g,x;case Md:return h=aC(h,g.mode,x),h.return=g,h;case Es:return h=cl(h),d(g,h,x)}if(Pd(h)||Td(h))return h=hl(h,g.mode,x,null),h.return=g,h;if(typeof h.then=="function")return d(g,Bh(h),x);if(h.$$typeof===an)return d(g,Vh(g,h),x);Fh(g,h)}return null}function f(g,h,x,S){var v=h!==null?h.key:null;if(typeof x=="string"&&x!==""||typeof x=="number"||typeof x=="bigint")return v!==null?null:i(g,h,""+x,S);if(typeof x=="object"&&x!==null){switch(x.$$typeof){case Eh:return x.key===v?l(g,h,x,S):null;case Md:return x.key===v?u(g,h,x,S):null;case Es:return x=cl(x),f(g,h,x,S)}if(Pd(x)||Td(x))return v!==null?null:c(g,h,x,S,null);if(typeof x.then=="function")return f(g,h,Bh(x),S);if(x.$$typeof===an)return f(g,h,Vh(g,x),S);Fh(g,x)}return null}function m(g,h,x,S,v){if(typeof S=="string"&&S!==""||typeof S=="number"||typeof S=="bigint")return g=g.get(x)||null,i(h,g,""+S,v);if(typeof S=="object"&&S!==null){switch(S.$$typeof){case Eh:return g=g.get(S.key===null?x:S.key)||null,l(h,g,S,v);case Md:return g=g.get(S.key===null?x:S.key)||null,u(h,g,S,v);case Es:return S=cl(S),m(g,h,x,S,v)}if(Pd(S)||Td(S))return g=g.get(x)||null,c(h,g,S,v,null);if(typeof S.then=="function")return m(g,h,x,Bh(S),v);if(S.$$typeof===an)return m(g,h,x,Vh(h,S),v);Fh(h,S)}return null}function p(g,h,x,S){for(var v=null,R=null,L=h,C=h=0,E=null;L!==null&&C<x.length;C++){L.index>C?(E=L,L=null):E=L.sibling;var I=f(g,L,x[C],S);if(I===null){L===null&&(L=E);break}e&&L&&I.alternate===null&&t(g,L),h=n(I,h,C),R===null?v=I:R.sibling=I,R=I,L=E}if(C===x.length)return a(g,L),Ge&&_n(g,C),v;if(L===null){for(;C<x.length;C++)L=d(g,x[C],S),L!==null&&(h=n(L,h,C),R===null?v=L:R.sibling=L,R=L);return Ge&&_n(g,C),v}for(L=o(L);C<x.length;C++)E=m(L,g,C,x[C],S),E!==null&&(e&&(I=E.alternate,I!==null&&L.delete(I.key===null?C:I.key)),h=n(E,h,C),R===null?v=E:R.sibling=E,R=E);return e&&L.forEach(function(A){return t(g,A)}),Ge&&_n(g,C),v}function y(g,h,x,S){if(x==null)throw Error(Z(151));for(var v=null,R=null,L=h,C=h=0,E=null,I=x.next();L!==null&&!I.done;C++,I=x.next()){L.index>C?(E=L,L=null):E=L.sibling;var A=f(g,L,I.value,S);if(A===null){L===null&&(L=E);break}e&&L&&A.alternate===null&&t(g,L),h=n(A,h,C),R===null?v=A:R.sibling=A,R=A,L=E}if(I.done)return a(g,L),Ge&&_n(g,C),v;if(L===null){for(;!I.done;C++,I=x.next())I=d(g,I.value,S),I!==null&&(h=n(I,h,C),R===null?v=I:R.sibling=I,R=I);return Ge&&_n(g,C),v}for(L=o(L);!I.done;C++,I=x.next())I=m(L,g,C,I.value,S),I!==null&&(e&&(E=I.alternate,E!==null&&L.delete(E.key===null?C:E.key)),h=n(I,h,C),R===null?v=I:R.sibling=I,R=I);return e&&L.forEach(function(N){return t(g,N)}),Ge&&_n(g,C),v}function b(g,h,x,S){if(typeof x=="object"&&x!==null&&x.type===ac&&x.key===null&&x.props.ref===void 0&&(x=x.props.children),typeof x=="object"&&x!==null){switch(x.$$typeof){case Eh:e:{for(var v=x.key;h!==null;){if(h.key===v){if(v=x.type,v===ac){if(h.tag===7){a(g,h.sibling),S=r(h,x.props.children),Ts(S,x),S.return=g,g=S;break e}}else if(h.elementType===v||typeof v=="object"&&v!==null&&v.$$typeof===Es&&cl(v)===h.type){a(g,h.sibling),S=r(h,x.props),Ts(S,x),S.return=g,g=S;break e}a(g,h);break}else t(g,h);h=h.sibling}x.type===ac?(S=hl(x.props.children,g.mode,S,x.key),Ts(S,x),S.return=g,g=S):(S=$h(x.type,x.key,x.props,null,g.mode,S),Ts(S,x),S.return=g,g=S)}return s(g);case Md:e:{for(v=x.key;h!==null;){if(h.key===v)if(h.tag===4&&h.stateNode.containerInfo===x.containerInfo&&h.stateNode.implementation===x.implementation){a(g,h.sibling),S=r(h,x.children||[]),S.return=g,g=S;break e}else{a(g,h);break}else t(g,h);h=h.sibling}S=aC(x,g.mode,S),S.return=g,g=S}return s(g);case Es:return x=cl(x),b(g,h,x,S)}if(Pd(x))return p(g,h,x,S);if(Td(x)){if(v=Td(x),typeof v!="function")throw Error(Z(150));return x=v.call(x),y(g,h,x,S)}if(typeof x.then=="function")return b(g,h,Bh(x),S);if(x.$$typeof===an)return b(g,h,Vh(g,x),S);Fh(g,x)}return typeof x=="string"&&x!==""||typeof x=="number"||typeof x=="bigint"?(x=""+x,h!==null&&h.tag===6?(a(g,h.sibling),S=r(h,x),S.return=g,g=S):(a(g,h),S=tC(x,g.mode,S),S.return=g,g=S),s(g)):a(g,h)}return function(g,h,x,S){try{tm=0;var v=b(g,h,x,S);return xc=null,v}catch(L){if(L===Fc||L===Qg)throw L;var R=Co(29,L,null,g.mode);return R.lanes=S,R.return=g,R}finally{}}}var Ll=FD(!0),_D=FD(!1),As=!1;function KL(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function qC(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function _s(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function zs(e,t,a){var o=e.updateQueue;if(o===null)return null;if(o=o.shared,(rt&2)!==0){var r=o.pending;return r===null?t.next=t:(t.next=r.next,r.next=t),o.pending=t,t=bg(e),DD(e,null,a),t}return Kg(e,o,t,a),bg(e)}function zd(e,t,a){if(t=t.updateQueue,t!==null&&(t=t.shared,(a&4194048)!==0)){var o=t.lanes;o&=e.pendingLanes,a|=o,t.lanes=a,aD(e,a)}}function rC(e,t){var a=e.updateQueue,o=e.alternate;if(o!==null&&(o=o.updateQueue,a===o)){var r=null,n=null;if(a=a.firstBaseUpdate,a!==null){do{var s={lane:a.lane,tag:a.tag,payload:a.payload,callback:null,next:null};n===null?r=n=s:n=n.next=s,a=a.next}while(a!==null);n===null?r=n=t:n=n.next=t}else r=n=t;a={baseState:o.baseState,firstBaseUpdate:r,lastBaseUpdate:n,shared:o.shared,callbacks:o.callbacks},e.updateQueue=a;return}e=a.lastBaseUpdate,e===null?a.firstBaseUpdate=t:e.next=t,a.lastBaseUpdate=t}var GC=!1;function Hd(){if(GC){var e=gc;if(e!==null)throw e}}function Ud(e,t,a,o){GC=!1;var r=e.updateQueue;As=!1;var n=r.firstBaseUpdate,s=r.lastBaseUpdate,i=r.shared.pending;if(i!==null){r.shared.pending=null;var l=i,u=l.next;l.next=null,s===null?n=u:s.next=u,s=l;var c=e.alternate;c!==null&&(c=c.updateQueue,i=c.lastBaseUpdate,i!==s&&(i===null?c.firstBaseUpdate=u:i.next=u,c.lastBaseUpdate=l))}if(n!==null){var d=r.baseState;s=0,c=u=l=null,i=n;do{var f=i.lane&-536870913,m=f!==i.lane;if(m?(We&f)===f:(o&f)===f){f!==0&&f===Cl&&(GC=!0),c!==null&&(c=c.next={lane:0,tag:i.tag,payload:i.payload,callback:null,next:null});e:{var p=e,y=i;f=t;var b=a;switch(y.tag){case 1:if(p=y.payload,typeof p=="function"){d=p.call(b,d,f);break e}d=p;break e;case 3:p.flags=p.flags&-65537|128;case 0:if(p=y.payload,f=typeof p=="function"?p.call(b,d,f):p,f==null)break e;d=St({},d,f);break e;case 2:As=!0}}f=i.callback,f!==null&&(e.flags|=64,m&&(e.flags|=8192),m=r.callbacks,m===null?r.callbacks=[f]:m.push(f))}else m={lane:f,tag:i.tag,payload:i.payload,callback:i.callback,next:null},c===null?(u=c=m,l=d):c=c.next=m,s|=f;if(i=i.next,i===null){if(i=r.shared.pending,i===null)break;m=i,i=m.next,m.next=null,r.lastBaseUpdate=m,r.shared.pending=null}}while(!0);c===null&&(l=d),r.baseState=l,r.firstBaseUpdate=u,r.lastBaseUpdate=c,n===null&&(r.shared.lanes=0),Qs|=s,e.lanes=s,e.memoizedState=d}}function zD(e,t){if(typeof e!="function")throw Error(Z(191,e));e.call(t)}function HD(e,t){var a=e.callbacks;if(a!==null)for(e.callbacks=null,e=0;e<a.length;e++)zD(a[e],t)}var Ks=cn(null),Tg=cn(0);function FE(e,t){e=Wn,Rt(Tg,e),Rt(Ks,t),Wn=e|t.baseLanes}function jC(){Rt(Tg,Wn),Rt(Ks,Ks.current)}function ZL(){Wn=Tg.current,Oa(Ks),Oa(Tg)}var Va=cn(null),Ga=null;function Hs(e){var t=e.alternate;Rt(ka,ka.current&1),Rt(Va,e),Ga===null&&(t===null||Ks.current!==null||t.memoizedState!==null)&&(Ga=e)}function XC(e){Rt(ka,ka.current),Rt(Va,e),Ga===null&&(Ga=e)}function UD(e){e.tag===22?(Rt(ka,ka.current),Rt(Va,e),Ga===null&&(Ga=e)):Us()}function Us(){Rt(ka,ka.current),Rt(Va,Va.current)}function _o(e){Oa(Va),Ga===e&&(Ga=null),Oa(ka)}var ka=cn(0);function am(e,t){Rt(Va,Va.current),Rt(ka,t)}function QL(e){Oa(ka),Oa(Va),Ga===e&&(Ga=null)}function Ig(e){for(var t=e;t!==null;){if(t.tag===13){var a=t.memoizedState;if(a!==null&&(a=a.dehydrated,a===null||IL(a)||RR(a)))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!=="independent"){if((t.flags&128)!==0)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var jn=0,_e=null,ht=null,ea=null,wg=!1,yc=!1,Rl=!1,Eg=0,om=0,Sc=null,iq=0;function Ut(){throw Error(Z(321))}function JL(e,t){if(t===null)return!1;for(var a=0;a<t.length&&a<e.length;a++)if(!Xo(e[a],t[a]))return!1;return!0}function $L(e,t,a,o,r,n){return jn=n,_e=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,De.H=e===null||e.memoizedState===null?SM:bM,Rl=!1,n=a(o,r),Rl=!1,yc&&(n=GD(t,a,o,r)),qD(e),n}function qD(e){De.H=Ag;var t=ht!==null&&ht.next!==null;if(jn=0,ea=ht=_e=null,wg=!1,om=0,Sc=null,t)throw Error(Z(300));e===null||aa||(e=e.dependencies,e!==null&&Lg(e)&&(aa=!0))}function GD(e,t,a,o){_e=e;var r=0;do{if(yc&&(Sc=null),om=0,yc=!1,25<=r)throw Error(Z(301));if(r+=1,ea=ht=null,e.updateQueue!=null){var n=e.updateQueue;n.lastEffect=null,n.events=null,n.stores=null,n.memoCache!=null&&(n.memoCache.index=0)}De.H=hq,n=t(a,o)}while(yc);return n}function lq(){var e=De.H,t=e.useState()[0];return t=typeof t.then=="function"?ym(t):t,e=e.useState()[0],(ht!==null?ht.memoizedState:null)!==e&&(_e.flags|=1024),t}function eR(){var e=Eg!==0;return Eg=0,e}function tR(e,t,a){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~a}function aR(e){if(wg){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}wg=!1}jn=0,ea=ht=_e=null,yc=!1,om=Eg=0,Sc=null}function ro(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return ea===null?_e.memoizedState=ea=e:ea=ea.next=e,ea}function jt(){if(ht===null){var e=_e.alternate;e=e!==null?e.memoizedState:null}else e=ht.next;var t=ea===null?_e.memoizedState:ea.next;if(t!==null)ea=t,ht=e;else{if(e===null)throw _e.alternate===null?Error(Z(467)):Error(Z(310));ht=e,e={memoizedState:ht.memoizedState,baseState:ht.baseState,baseQueue:ht.baseQueue,queue:ht.queue,next:null},ea===null?_e.memoizedState=ea=e:ea=ea.next=e}return ea}function Jg(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function ym(e){var t=om;return om+=1,Sc===null&&(Sc=[]),e=BD(Sc,e,t),t=_e,(ea===null?t.memoizedState:ea.next)===null&&(t=t.alternate,De.H=t===null||t.memoizedState===null?SM:bM),e}function $g(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return ym(e);if(e.$$typeof===q3)return;if(e.$$typeof===an)return Pa(e)}throw Error(Z(438,String(e)))}function oR(e){var t=null,a=_e.updateQueue;if(a!==null&&(t=a.memoCache),t==null){var o=_e.alternate;o!==null&&(o=o.updateQueue,o!==null&&(o=o.memoCache,o!=null&&(t={data:o.data.map(function(r){return r.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),a===null&&(a=Jg(),_e.updateQueue=a),a.memoCache=t,a=t.data[t.index],a===void 0)for(a=t.data[t.index]=Array(e),o=0;o<e;o++)a[o]=U3;return t.index++,a}function Xn(e,t){return typeof t=="function"?t(e):t}function ag(e){var t=jt();return rR(t,ht,e)}function rR(e,t,a){var o=e.queue;if(o===null)throw Error(Z(311));o.lastRenderedReducer=a;var r=e.baseQueue,n=o.pending;if(n!==null){if(r!==null){var s=r.next;r.next=n.next,n.next=s}t.baseQueue=r=n,o.pending=null}if(n=e.baseState,r===null)e.memoizedState=n;else{t=r.next;var i=s=null,l=null,u=t,c=!1;do{var d=u.lane&-536870913;if(d!==u.lane?(We&d)===d:(jn&d)===d){var f=u.revertLane;if(f===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),d===Cl&&(c=!0);else if((jn&f)===f){u=u.next,f===Cl&&(c=!0);continue}else d={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(i=l=d,s=n):l=l.next=d,_e.lanes|=f,Qs|=f;d=u.action,Rl&&a(n,d),n=u.hasEagerState?u.eagerState:a(n,d)}else f={lane:d,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(i=l=f,s=n):l=l.next=f,_e.lanes|=d,Qs|=d;u=u.next}while(u!==null&&u!==t);if(l===null?s=n:l.next=i,!Xo(n,e.memoizedState)&&(aa=!0,c&&(a=gc,a!==null)))throw a;e.memoizedState=n,e.baseState=s,e.baseQueue=l,o.lastRenderedState=n}return r===null&&(o.lanes=0),[e.memoizedState,o.dispatch]}function nC(e){var t=jt(),a=t.queue;if(a===null)throw Error(Z(311));a.lastRenderedReducer=e;var o=a.dispatch,r=a.pending,n=t.memoizedState;if(r!==null){a.pending=null;var s=r=r.next;do n=e(n,s.action),s=s.next;while(s!==r);Xo(n,t.memoizedState)||(aa=!0),t.memoizedState=n,t.baseQueue===null&&(t.baseState=n),a.lastRenderedState=n}return[n,o]}function jD(e,t,a){var o=_e,r=jt(),n=Ge;if(n){if(a===void 0)throw Error(Z(407));a=a()}else a=t();var s=!Xo((ht||r).memoizedState,a);if(s&&(r.memoizedState=a,aa=!0),r=r.queue,nR(WD.bind(null,o,r,e),[e]),e=r.getSnapshot!==t||s||ea!==null&&(ea.memoizedState.tag&1)!==0,Ic(e?9:8,{destroy:void 0},YD.bind(null,o,r,a,t),null),e){if(o.flags|=2048,yt===null)throw Error(Z(349));n||(jn&127)!==0||XD(o,t,a)}return a}function XD(e,t,a){e.flags|=16384,e={getSnapshot:t,value:a},t=_e.updateQueue,t===null?(t=Jg(),_e.updateQueue=t,t.stores=[e]):(a=t.stores,a===null?t.stores=[e]:a.push(e))}function YD(e,t,a,o){t.value=a,t.getSnapshot=o,KD(t)&&ZD(e)}function WD(e,t,a){return a(function(){KD(t)&&ZD(e)})}function KD(e){var t=e.getSnapshot;e=e.value;try{var a=t();return!Xo(e,a)}catch{return!0}}function ZD(e){var t=Dl(e,2);t!==null&&Lo(t,e,2)}function YC(e){var t=ro();if(typeof e=="function"){var a=e;if(e=a(),Rl){Ms(!0);try{a()}finally{Ms(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xn,lastRenderedState:e},t}function QD(e,t,a,o){return e.baseState=a,rR(e,ht,typeof o=="function"?o:Xn)}function uq(e,t,a,o,r){if(tx(e))throw Error(Z(485));if(e=t.action,e!==null){var n={payload:r,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(s){n.listeners.push(s)}};De.T!==null?a(!0):n.isTransition=!1,o(n),a=t.pending,a===null?(n.next=t.pending=n,JD(t,n)):(n.next=a.next,t.pending=a.next=n)}}function JD(e,t){var a=t.action,o=t.payload,r=e.state;if(t.isTransition){var n=De.T,s={};s.types=n!==null?n.types:null,De.T=s;try{var i=a(r,o),l=De.S;l!==null&&l(s,i),_E(e,t,i)}catch(u){WC(e,t,u)}finally{n!==null&&s.types!==null&&(n.types=s.types),De.T=n}}else try{n=a(r,o),_E(e,t,n)}catch(u){WC(e,t,u)}}function _E(e,t,a){a!==null&&typeof a=="object"&&typeof a.then=="function"?a.then(function(o){zE(e,t,o)},function(o){return WC(e,t,o)}):zE(e,t,a)}function zE(e,t,a){t.status="fulfilled",t.value=a,$D(t),e.state=a,t=e.pending,t!==null&&(a=t.next,a===t?e.pending=null:(a=a.next,t.next=a,JD(e,a)))}function WC(e,t,a){var o=e.pending;if(e.pending=null,o!==null){o=o.next;do t.status="rejected",t.reason=a,$D(t),t=t.next;while(t!==o)}e.action=null}function $D(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function eM(e,t){return t}function HE(e,t){if(Ge){var a=yt.formState;if(a!==null){e:{var o=_e;if(Ge){if(Lt){t:{for(var r=Lt,n=ur;r.nodeType!==8;){if(!n){r=null;break t}if(r=cr(r.nextSibling),r===null){r=null;break t}}n=r.data,r=n==="F!"||n==="F"?r:null}if(r){Lt=cr(r.nextSibling),o=r.data==="F!";break e}}Ws(o)}o=!1}o&&(t=a[0])}}return a=ro(),a.memoizedState=a.baseState=t,o={pending:null,lanes:0,dispatch:null,lastRenderedReducer:eM,lastRenderedState:t},a.queue=o,a=gM.bind(null,_e,o),o.dispatch=a,o=YC(!1),n=uR.bind(null,_e,!1,o.queue),o=ro(),r={state:t,dispatch:null,action:e,pending:null},o.queue=r,a=uq.bind(null,_e,r,n,a),r.dispatch=a,o.memoizedState=e,[t,a,!1]}function UE(e){var t=jt();return tM(t,ht,e)}function tM(e,t,a){if(t=rR(e,t,eM)[0],e=ag(Xn)[0],typeof t=="object"&&t!==null&&typeof t.then=="function")try{var o=ym(t)}catch(s){throw s===Fc?Qg:s}else o=t;t=jt();var r=t.queue,n=r.dispatch;return a!==t.memoizedState&&(_e.flags|=2048,Ic(9,{destroy:void 0},cq.bind(null,r,a),null)),[o,n,e]}function cq(e,t){e.action=t}function qE(e){var t=jt(),a=ht;if(a!==null)return tM(t,a,e);jt(),t=t.memoizedState,a=jt();var o=a.queue.dispatch;return a.memoizedState=e,[t,o,!1]}function Ic(e,t,a,o){return e={tag:e,create:a,deps:o,inst:t,next:null},t=_e.updateQueue,t===null&&(t=Jg(),_e.updateQueue=t),a=t.lastEffect,a===null?t.lastEffect=e.next=e:(o=a.next,a.next=e,e.next=o,t.lastEffect=e),e}function aM(){return jt().memoizedState}function og(e,t,a,o){var r=ro();_e.flags|=e,r.memoizedState=Ic(1|t,{destroy:void 0},a,o===void 0?null:o)}function ex(e,t,a,o){var r=jt();o=o===void 0?null:o;var n=r.memoizedState.inst;ht!==null&&o!==null&&JL(o,ht.memoizedState.deps)?r.memoizedState=Ic(t,n,a,o):(_e.flags|=e,r.memoizedState=Ic(1|t,n,a,o))}function GE(e,t){og(8390656,8,e,t)}function nR(e,t){ex(2048,8,e,t)}function fq(e){_e.flags|=4;var t=_e.updateQueue;if(t===null)t=Jg(),_e.updateQueue=t,t.events=[e];else{var a=t.events;a===null?t.events=[e]:a.push(e)}}function oM(e){var t=jt().memoizedState;return fq({ref:t,nextImpl:e}),function(){if((rt&2)!==0)throw Error(Z(440));return t.impl.apply(void 0,arguments)}}function rM(e,t){return ex(4,2,e,t)}function nM(e,t){return ex(4,4,e,t)}function sM(e,t){if(typeof t=="function"){e=e();var a=t(e);return function(){typeof a=="function"?a():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function iM(e,t,a){a=a!=null?a.concat([e]):null,ex(4,4,sM.bind(null,t,e),a)}function sR(){}function lM(e,t){var a=jt();t=t===void 0?null:t;var o=a.memoizedState;return t!==null&&JL(t,o[1])?o[0]:(a.memoizedState=[e,t],e)}function uM(e,t){var a=jt();t=t===void 0?null:t;var o=a.memoizedState;if(t!==null&&JL(t,o[1]))return o[0];if(o=e(),Rl){Ms(!0);try{e()}finally{Ms(!1)}}return a.memoizedState=[o,t],o}function iR(e,t,a){return a===void 0||(jn&1073741824)!==0&&(We&261930)===0?e.memoizedState=t:(e.memoizedState=a,e=tP(),_e.lanes|=e,Qs|=e,a)}function cM(e,t,a,o){return Xo(a,t)?a:Ks.current!==null?(e=iR(e,a,o),Xo(e,t)||(aa=!0),e):(jn&106)===0||(jn&1073741824)!==0&&(We&261930)===0?(aa=!0,e.memoizedState=a):(e=tP(),_e.lanes|=e,Qs|=e,t)}function fM(e,t,a,o,r){var n=nt.p;nt.p=n!==0&&8>n?n:8;var s=De.T,i={};i.types=s!==null?s.types:null,De.T=i,uR(e,!1,t,a);try{var l=r(),u=De.S;if(u!==null&&u(i,l),l!==null&&typeof l=="object"&&typeof l.then=="function"){var c=sq(l,o);qd(e,t,c,jo(e))}else qd(e,t,o,jo(e))}catch(d){qd(e,t,{then:function(){},status:"rejected",reason:d},jo())}finally{nt.p=n,s!==null&&i.types!==null&&(s.types=i.types),De.T=s}}function dq(){}function KC(e,t,a,o){if(e.tag!==5)throw Error(Z(476));var r=dM(e).queue;fM(e,r,t,pl,a===null?dq:function(){return mM(e),a(o)})}function dM(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:pl,baseState:pl,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xn,lastRenderedState:pl},next:null};var a={};return t.next={memoizedState:a,baseState:a,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xn,lastRenderedState:a},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function mM(e){var t=dM(e);t.next===null&&(t=e.alternate.memoizedState),qd(e,t.next.queue,{},jo())}function lR(){return Pa(Oc)}function pM(){return jt().memoizedState}function hM(){return jt().memoizedState}function mq(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var a=jo();e=_s(a);var o=zs(t,e,a);o!==null&&(Lo(o,t,a),zd(o,t,a)),t={cache:XL()},e.payload=t;return}t=t.return}}function pq(e,t,a){var o=jo();a={lane:o,revertLane:0,gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null},tx(e)?xM(t,a):(a=qL(e,t,a,o),a!==null&&(Lo(a,e,o),yM(a,t,o)))}function gM(e,t,a){var o=jo();qd(e,t,a,o)}function qd(e,t,a,o){var r={lane:o,revertLane:0,gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null};if(tx(e))xM(t,r);else{var n=e.alternate;if(e.lanes===0&&(n===null||n.lanes===0)&&(n=t.lastRenderedReducer,n!==null))try{var s=t.lastRenderedState,i=n(s,a);if(r.hasEagerState=!0,r.eagerState=i,Xo(i,s))return Kg(e,t,r,0),yt===null&&Wg(),!1}catch{}finally{}if(a=qL(e,t,r,o),a!==null)return Lo(a,e,o),yM(a,t,o),!0}return!1}function uR(e,t,a,o){if(o={lane:2,revertLane:bR(),gesture:null,action:o,hasEagerState:!1,eagerState:null,next:null},tx(e)){if(t)throw Error(Z(479))}else t=qL(e,a,o,2),t!==null&&Lo(t,e,2)}function tx(e){var t=e.alternate;return e===_e||t!==null&&t===_e}function xM(e,t){yc=wg=!0;var a=e.pending;a===null?t.next=t:(t.next=a.next,a.next=t),e.pending=t}function yM(e,t,a){if((a&4194048)!==0){var o=t.lanes;o&=e.pendingLanes,a|=o,t.lanes=a,aD(e,a)}}var Ag={readContext:Pa,use:$g,useCallback:Ut,useContext:Ut,useEffect:Ut,useImperativeHandle:Ut,useLayoutEffect:Ut,useInsertionEffect:Ut,useMemo:Ut,useReducer:Ut,useRef:Ut,useState:Ut,useDebugValue:Ut,useDeferredValue:Ut,useTransition:Ut,useSyncExternalStore:Ut,useId:Ut,useHostTransitionStatus:Ut,useFormState:Ut,useActionState:Ut,useOptimistic:Ut,useMemoCache:Ut,useCacheRefresh:Ut,useEffectEvent:Ut},SM={readContext:Pa,use:$g,useCallback:function(e,t){return ro().memoizedState=[e,t===void 0?null:t],e},useContext:Pa,useEffect:GE,useImperativeHandle:function(e,t,a){a=a!=null?a.concat([e]):null,og(4194308,4,sM.bind(null,t,e),a)},useLayoutEffect:function(e,t){return og(4194308,4,e,t)},useInsertionEffect:function(e,t){og(4,2,e,t)},useMemo:function(e,t){var a=ro();t=t===void 0?null:t;var o=e();if(Rl){Ms(!0);try{e()}finally{Ms(!1)}}return a.memoizedState=[o,t],o},useReducer:function(e,t,a){var o=ro();if(a!==void 0){var r=a(t);if(Rl){Ms(!0);try{a(t)}finally{Ms(!1)}}}else r=t;return o.memoizedState=o.baseState=r,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:r},o.queue=e,e=e.dispatch=pq.bind(null,_e,e),[o.memoizedState,e]},useRef:function(e){var t=ro();return e={current:e},t.memoizedState=e},useState:function(e){e=YC(e);var t=e.queue,a=gM.bind(null,_e,t);return t.dispatch=a,[e.memoizedState,a]},useDebugValue:sR,useDeferredValue:function(e,t){var a=ro();return iR(a,e,t)},useTransition:function(){var e=YC(!1);return e=fM.bind(null,_e,e.queue,!0,!1),ro().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,a){var o=_e,r=ro();if(Ge){if(a===void 0)throw Error(Z(407));a=a()}else{if(a=t(),yt===null)throw Error(Z(349));(We&127)!==0||XD(o,t,a)}r.memoizedState=a;var n={value:a,getSnapshot:t};return r.queue=n,GE(WD.bind(null,o,n,e),[e]),o.flags|=2048,Ic(9,{destroy:void 0},YD.bind(null,o,n,a,t),null),a},useId:function(){var e=ro(),t=yt.identifierPrefix;if(Ge){var a=nn,o=rn;a=(o&~(1<<32-Go(o)-1)).toString(32)+a,t="_"+t+"R_"+a,a=Eg++,0<a&&(t+="H"+a.toString(32)),t+="_"}else a=iq++,t="_"+t+"r_"+a.toString(32)+"_";return e.memoizedState=t},useHostTransitionStatus:lR,useFormState:HE,useActionState:HE,useOptimistic:function(e){var t=ro();t.memoizedState=t.baseState=e;var a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=a,t=uR.bind(null,_e,!0,a),a.dispatch=t,[e,t]},useMemoCache:oR,useCacheRefresh:function(){return ro().memoizedState=mq.bind(null,_e)},useEffectEvent:function(e){var t=ro(),a={impl:e};return t.memoizedState=a,function(){if((rt&2)!==0)throw Error(Z(440));return a.impl.apply(void 0,arguments)}}},bM={readContext:Pa,use:$g,useCallback:lM,useContext:Pa,useEffect:nR,useImperativeHandle:iM,useInsertionEffect:rM,useLayoutEffect:nM,useMemo:uM,useReducer:ag,useRef:aM,useState:function(){return ag(Xn)},useDebugValue:sR,useDeferredValue:function(e,t){var a=jt();return cM(a,ht.memoizedState,e,t)},useTransition:function(){var e=ag(Xn)[0],t=jt().memoizedState;return[typeof e=="boolean"?e:ym(e),t]},useSyncExternalStore:jD,useId:pM,useHostTransitionStatus:lR,useFormState:UE,useActionState:UE,useOptimistic:function(e,t){var a=jt();return QD(a,ht,e,t)},useMemoCache:oR,useCacheRefresh:hM,useEffectEvent:oM},hq={readContext:Pa,use:$g,useCallback:lM,useContext:Pa,useEffect:nR,useImperativeHandle:iM,useInsertionEffect:rM,useLayoutEffect:nM,useMemo:uM,useReducer:nC,useRef:aM,useState:function(){return nC(Xn)},useDebugValue:sR,useDeferredValue:function(e,t){var a=jt();return ht===null?iR(a,e,t):cM(a,ht.memoizedState,e,t)},useTransition:function(){var e=nC(Xn)[0],t=jt().memoizedState;return[typeof e=="boolean"?e:ym(e),t]},useSyncExternalStore:jD,useId:pM,useHostTransitionStatus:lR,useFormState:qE,useActionState:qE,useOptimistic:function(e,t){var a=jt();return ht!==null?QD(a,ht,e,t):(a.baseState=e,[e,a.queue.dispatch])},useMemoCache:oR,useCacheRefresh:hM,useEffectEvent:oM};function sC(e,t,a,o){t=e.memoizedState,a=a(o,t),a=a==null?t:St({},t,a),e.memoizedState=a,e.lanes===0&&(e.updateQueue.baseState=a)}var ZC={enqueueSetState:function(e,t,a){e=e._reactInternals;var o=jo(),r=_s(o);r.payload=t,a!=null&&(r.callback=a),t=zs(e,r,o),t!==null&&(Lo(t,e,o),zd(t,e,o))},enqueueReplaceState:function(e,t,a){e=e._reactInternals;var o=jo(),r=_s(o);r.tag=1,r.payload=t,a!=null&&(r.callback=a),t=zs(e,r,o),t!==null&&(Lo(t,e,o),zd(t,e,o))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var a=jo(),o=_s(a);o.tag=2,t!=null&&(o.callback=t),t=zs(e,o,a),t!==null&&(Lo(t,e,a),zd(t,e,a))}};function jE(e,t,a,o,r,n,s){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(o,n,s):t.prototype&&t.prototype.isPureReactComponent?!Jd(a,o)||!Jd(r,n):!0}function XE(e,t,a,o){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(a,o),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(a,o),t.state!==e&&ZC.enqueueReplaceState(t,t.state,null)}function Tl(e,t){var a=t;if("ref"in t){a={};for(var o in t)o!=="ref"&&(a[o]=t[o])}if(e=e.defaultProps){a===t&&(a=St({},a));for(var r in e)a[r]===void 0&&(a[r]=e[r])}return a}function vM(e){Sg(e)}function CM(e){console.error(e)}function LM(e){Sg(e)}function Dg(e,t){try{var a=e.onUncaughtError;a(t.value,{componentStack:t.stack})}catch(o){setTimeout(function(){throw o})}}function YE(e,t,a){try{var o=e.onCaughtError;o(a.value,{componentStack:a.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(r){setTimeout(function(){throw r})}}function QC(e,t,a){return a=_s(a),a.tag=3,a.payload={element:null},a.callback=function(){Dg(e,t)},a}function RM(e){return e=_s(e),e.tag=3,e}function TM(e,t,a,o){var r=a.type.getDerivedStateFromError;if(typeof r=="function"){var n=o.value;e.payload=function(){return r(n)},e.callback=function(){YE(t,a,o)}}var s=a.stateNode;s!==null&&typeof s.componentDidCatch=="function"&&(e.callback=function(){YE(t,a,o),typeof r!="function"&&(qs===null?qs=new Set([this]):qs.add(this));var i=o.stack;this.componentDidCatch(o.value,{componentStack:i!==null?i:""})})}function gq(e,t,a,o,r){if(a.flags|=32768,o!==null&&typeof o=="object"&&typeof o.then=="function"){if(t=a.alternate,t!==null&&bl(t,a,r,!0),a=Va.current,a!==null){switch(a.tag){case 31:case 13:case 19:return Ga===null?Fg():a.alternate===null&&qt===0&&(qt=3),a.flags&=-257,a.flags|=65536,a.lanes=r,o===Rg?a.flags|=16384:(t=a.updateQueue,t===null?a.updateQueue=new Set([o]):t.add(o),mC(e,o,r)),!1;case 22:return a.flags|=65536,o===Rg?a.flags|=16384:(t=a.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([o])},a.updateQueue=t):(a=t.retryQueue,a===null?t.retryQueue=new Set([o]):a.add(o)),mC(e,o,r)),!1}throw Error(Z(435,a.tag))}return mC(e,o,r),Fg(),!1}if(Ge)return t=Va.current,t!==null?((t.flags&65536)===0&&(t.flags|=256),t.flags|=65536,t.lanes=r,o!==_C&&(e=Error(Z(422),{cause:o}),em(lr(e,a)))):(o!==_C&&(t=Error(Z(423),{cause:o}),em(lr(t,a))),e=e.current.alternate,e.flags|=65536,r&=-r,e.lanes|=r,o=lr(o,a),r=QC(e.stateNode,o,r),rC(e,r),qt!==4&&(qt=2)),!1;var n=Error(Z(520),{cause:o});if(n=lr(n,a),Yd===null?Yd=[n]:Yd.push(n),qt!==4&&(qt=2),t===null)return!0;o=lr(o,a),a=t;do{switch(a.tag){case 3:return a.flags|=65536,e=r&-r,a.lanes|=e,e=QC(a.stateNode,o,e),rC(a,e),!1;case 1:if(t=a.type,n=a.stateNode,(a.flags&128)===0&&(typeof t.getDerivedStateFromError=="function"||n!==null&&typeof n.componentDidCatch=="function"&&(qs===null||!qs.has(n))))return a.flags|=65536,r&=-r,a.lanes|=r,r=RM(r),TM(r,e,a,o),rC(a,r),!1;break;case 22:if(a.memoizedState!==null)return a.flags|=65536,!1}a=a.return}while(a!==null);return!1}var cR=Error(Z(461)),aa=!1;function ia(e,t,a,o){t.child=e===null?_D(t,null,a,o):Ll(t,e.child,a,o)}function WE(e,t,a,o,r){a=a.render;var n=t.ref;if("ref"in o){var s={};for(var i in o)i!=="ref"&&(s[i]=o[i])}else s=o;return vl(t),o=$L(e,t,a,s,n,r),i=eR(),e!==null&&!aa?(tR(e,t,r),Yn(e,t,r)):(Ge&&i&&Zg(t),t.flags|=1,ia(e,t,o,r),t.child)}function KE(e,t,a,o,r){if(e===null){var n=a.type;return typeof n=="function"&&!GL(n)&&n.defaultProps===void 0&&a.compare===null?(t.tag=15,t.type=n,IM(e,t,n,o,r)):(e=$h(a.type,null,o,t,t.mode,r),e.ref=t.ref,e.return=t,t.child=e)}if(n=e.child,!dR(e,r)){var s=n.memoizedProps;if(a=a.compare,a=a!==null?a:Jd,a(s,o)&&e.ref===t.ref)return Yn(e,t,r)}return t.flags|=1,e=Hn(n,o),e.ref=t.ref,e.return=t,t.child=e}function IM(e,t,a,o,r){if(e!==null){var n=e.memoizedProps;if(Jd(n,o)&&e.ref===t.ref)if(aa=!1,t.pendingProps=o=n,dR(e,r))(e.flags&131072)!==0&&(aa=!0);else return t.lanes=e.lanes,Yn(e,t,r)}return JC(e,t,a,o,r)}function wM(e,t,a,o){var r=o.children,n=e!==null?e.memoizedState:null;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),o.mode==="hidden"){if((t.flags&128)!==0){if(n=n!==null?n.baseLanes|a:a,e!==null){for(o=t.child=e.child,r=0;o!==null;)r=r|o.lanes|o.childLanes,o=o.sibling;o=r&~n}else o=0,t.child=null;return ZE(e,t,n,a,o)}if((a&536870912)!==0)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&tg(t,n!==null?n.cachePool:null),n!==null?FE(t,n):jC(),UD(t);else return o=t.lanes=536870912,ZE(e,t,n!==null?n.baseLanes|a:a,a,o)}else n!==null?(tg(t,n.cachePool),FE(t,n),Us(),t.memoizedState=null):(e!==null&&tg(t,null),jC(),Us());return ia(e,t,r,a),t.child}function Gd(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function ZE(e,t,a,o,r){var n=YL();return n=n===null?null:{parent:ta._currentValue,pool:n},t.memoizedState={baseLanes:a,cachePool:n},e!==null&&tg(t,null),jC(),UD(t),e!==null&&bl(e,t,o,!0),t.childLanes=r,null}function rg(e,t){return t=ax({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function QE(e,t,a){return Ll(t,e.child,null,a),e=rg(t,t.pendingProps),e.flags|=2,_o(t),t.memoizedState=null,e}function xq(e,t,a){var o=t.pendingProps,r=(t.flags&128)!==0;if(t.flags&=-129,e===null){if(Ge){if(o.mode==="hidden")return e=rg(t,o),t.lanes=536870912,e.memoizedState={baseLanes:0,cachePool:null},Gd(null,e);if(XC(t),(e=Lt)?(e=wP(e,ur),e=e!==null&&e.data==="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Ys!==null?{id:rn,overflow:nn}:null,retryLane:536870912,hydrationErrors:null},a=PD(e),a.return=t,t.child=a,Sa=t,Lt=null)):e=null,e===null)throw Ws(t);return t.lanes=536870912,null}return rg(t,o)}var n=e.memoizedState;if(n!==null){var s=n.dehydrated;if(XC(t),r)if(t.flags&256)t.flags&=-257,t=QE(e,t,a);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(Z(558));else if(aa||bl(e,t,a,!1),r=(a&e.childLanes)!==0,aa||r){if(Ks.current===null){if(o=yt,o!==null&&(s=oD(o,a),s!==0&&s!==n.retryLane))throw n.retryLane=s,Dl(e,s),Lo(o,e,s),cR;Fg()}t=QE(e,t,a)}else e=n.treeContext,Lt=cr(s.nextSibling),Sa=t,Ge=!0,Fs=null,ur=!1,e!==null&&kD(t,e),t=rg(t,o),t.flags|=134221824;return t}return e=Hn(e.child,{mode:o.mode,children:o.children}),e.ref=t.ref,t.child=e,e.return=t,e}function Ju(e,t){var a=t.ref;if(a===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof a!="function"&&typeof a!="object")throw Error(Z(284));(e===null||e.ref!==a)&&(t.flags|=4194816)}}function JC(e,t,a,o,r){return vl(t),a=$L(e,t,a,o,void 0,r),o=eR(),e!==null&&!aa?(tR(e,t,r),Yn(e,t,r)):(Ge&&o&&Zg(t),t.flags|=1,ia(e,t,a,r),t.child)}function JE(e,t,a,o,r,n){return vl(t),t.updateQueue=null,a=GD(t,o,a,r),qD(e),o=eR(),e!==null&&!aa?(tR(e,t,n),Yn(e,t,n)):(Ge&&o&&Zg(t),t.flags|=1,ia(e,t,a,n),t.child)}function $E(e,t,a,o,r){if(vl(t),t.stateNode===null){var n=uc,s=a.contextType;typeof s=="object"&&s!==null&&(n=Pa(s)),n=new a(o,n),t.memoizedState=n.state!==null&&n.state!==void 0?n.state:null,n.updater=ZC,t.stateNode=n,n._reactInternals=t,n=t.stateNode,n.props=o,n.state=t.memoizedState,n.refs={},KL(t),s=a.contextType,n.context=typeof s=="object"&&s!==null?Pa(s):uc,n.state=t.memoizedState,s=a.getDerivedStateFromProps,typeof s=="function"&&(sC(t,a,s,o),n.state=t.memoizedState),typeof a.getDerivedStateFromProps=="function"||typeof n.getSnapshotBeforeUpdate=="function"||typeof n.UNSAFE_componentWillMount!="function"&&typeof n.componentWillMount!="function"||(s=n.state,typeof n.componentWillMount=="function"&&n.componentWillMount(),typeof n.UNSAFE_componentWillMount=="function"&&n.UNSAFE_componentWillMount(),s!==n.state&&ZC.enqueueReplaceState(n,n.state,null),Ud(t,o,n,r),Hd(),n.state=t.memoizedState),typeof n.componentDidMount=="function"&&(t.flags|=4194308),o=!0}else if(e===null){n=t.stateNode;var i=t.memoizedProps,l=Tl(a,i);n.props=l;var u=n.context,c=a.contextType;s=uc,typeof c=="object"&&c!==null&&(s=Pa(c));var d=a.getDerivedStateFromProps;c=typeof d=="function"||typeof n.getSnapshotBeforeUpdate=="function",i=t.pendingProps!==i,c||typeof n.UNSAFE_componentWillReceiveProps!="function"&&typeof n.componentWillReceiveProps!="function"||(i||u!==s)&&XE(t,n,o,s),As=!1;var f=t.memoizedState;n.state=f,Ud(t,o,n,r),Hd(),u=t.memoizedState,i||f!==u||As?(typeof d=="function"&&(sC(t,a,d,o),u=t.memoizedState),(l=As||jE(t,a,l,o,f,u,s))?(c||typeof n.UNSAFE_componentWillMount!="function"&&typeof n.componentWillMount!="function"||(typeof n.componentWillMount=="function"&&n.componentWillMount(),typeof n.UNSAFE_componentWillMount=="function"&&n.UNSAFE_componentWillMount()),typeof n.componentDidMount=="function"&&(t.flags|=4194308)):(typeof n.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=o,t.memoizedState=u),n.props=o,n.state=u,n.context=s,o=l):(typeof n.componentDidMount=="function"&&(t.flags|=4194308),o=!1)}else{n=t.stateNode,qC(e,t),s=t.memoizedProps,c=Tl(a,s),n.props=c,d=t.pendingProps,f=n.context,u=a.contextType,l=uc,typeof u=="object"&&u!==null&&(l=Pa(u)),i=a.getDerivedStateFromProps,(u=typeof i=="function"||typeof n.getSnapshotBeforeUpdate=="function")||typeof n.UNSAFE_componentWillReceiveProps!="function"&&typeof n.componentWillReceiveProps!="function"||(s!==d||f!==l)&&XE(t,n,o,l),As=!1,f=t.memoizedState,n.state=f,Ud(t,o,n,r),Hd();var m=t.memoizedState;s!==d||f!==m||As||e!==null&&e.dependencies!==null&&Lg(e.dependencies)?(typeof i=="function"&&(sC(t,a,i,o),m=t.memoizedState),(c=As||jE(t,a,c,o,f,m,l)||e!==null&&e.dependencies!==null&&Lg(e.dependencies))?(u||typeof n.UNSAFE_componentWillUpdate!="function"&&typeof n.componentWillUpdate!="function"||(typeof n.componentWillUpdate=="function"&&n.componentWillUpdate(o,m,l),typeof n.UNSAFE_componentWillUpdate=="function"&&n.UNSAFE_componentWillUpdate(o,m,l)),typeof n.componentDidUpdate=="function"&&(t.flags|=4),typeof n.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof n.componentDidUpdate!="function"||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof n.getSnapshotBeforeUpdate!="function"||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=o,t.memoizedState=m),n.props=o,n.state=m,n.context=l,o=c):(typeof n.componentDidUpdate!="function"||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof n.getSnapshotBeforeUpdate!="function"||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),o=!1)}return n=o,Ju(e,t),o=(t.flags&128)!==0,n||o?(n=t.stateNode,a=o&&typeof a.getDerivedStateFromError!="function"?null:n.render(),t.flags|=1,e!==null&&o?(t.child=Ll(t,e.child,null,r),t.child=Ll(t,null,a,r)):ia(e,t,a,r),t.memoizedState=n.state,e=t.child):e=Yn(e,t,r),e}function eA(e,t,a,o){return Sl(),t.flags|=256,ia(e,t,a,o),t.child}var $C={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function eL(e){return{baseLanes:e,cachePool:VD()}}function tL(e,t,a){return e=e!==null?e.childLanes&~a:0,t&&(e|=Ho),e}function EM(e,t,a){var o=t.pendingProps,r=!1,n=(t.flags&128)!==0,s;if((s=n)||(s=e!==null&&e.memoizedState===null?!1:(ka.current&2)!==0),s&&(r=!0,t.flags&=-129),s=(t.flags&32)!==0,t.flags&=-33,e===null){if(Ge){if(r?Hs(t):Us(),(e=Lt)?(e=wP(e,ur),e=e!==null&&e.data!=="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Ys!==null?{id:rn,overflow:nn}:null,retryLane:536870912,hydrationErrors:null},a=PD(e),a.return=t,t.child=a,Sa=t,Lt=null)):e=null,e===null)throw Ws(t);return RR(e)?t.lanes=32:t.lanes=536870912,null}return n=o.children,o=o.fallback,r?(Us(),r=t.mode,n=ax({mode:"hidden",children:n},r),o=hl(o,r,a,null),n.return=t,o.return=t,n.sibling=o,t.child=n,o=t.child,o.memoizedState=eL(a),o.childLanes=tL(e,s,a),t.memoizedState=$C,Gd(null,o)):(Hs(t),fR(t,n))}var i=e.memoizedState;if(i!==null){var l=i.dehydrated;if(l!==null)return yq(e,t,n,s,o,l,i,a)}return r?(Us(),r=o.fallback,n=t.mode,i=e.child,l=i.sibling,o=Hn(i,{mode:"hidden",children:o.children}),o.subtreeFlags=i.subtreeFlags&1206910976,l!==null?r=Hn(l,r):(r=hl(r,n,a,null),r.flags|=2),r.return=t,o.return=t,o.sibling=r,t.child=o,Gd(null,o),o=t.child,r=e.child.memoizedState,r===null?r=eL(a):(n=r.cachePool,n!==null?(i=ta._currentValue,n=n.parent!==i?{parent:i,pool:i}:n):n=VD(),r={baseLanes:r.baseLanes|a,cachePool:n}),o.memoizedState=r,o.childLanes=tL(e,s,a),t.memoizedState=$C,Gd(e.child,o)):(Hs(t),a=e.child,e=a.sibling,a=Hn(a,{mode:"visible",children:o.children}),a.return=t,a.sibling=null,e!==null&&(s=t.deletions,s===null?(t.deletions=[e],t.flags|=16):s.push(e)),t.child=a,t.memoizedState=null,a)}function fR(e,t){return t=ax({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function ax(e,t){return e=Co(22,e,null,t),e.lanes=0,e}function _h(e,t,a){return Ll(t,e.child,null,a),e=fR(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function yq(e,t,a,o,r,n,s,i){if(a)return t.flags&256?(Hs(t),t.flags&=-257,_h(e,t,i)):t.memoizedState!==null?(Us(),t.child=e.child,t.flags|=128,null):(Us(),n=r.fallback,s=t.mode,r=ax({mode:"visible",children:r.children},s),n=hl(n,s,i,null),n.flags|=2,r.return=t,n.return=t,r.sibling=n,t.child=r,Ll(t,e.child,null,i),r=t.child,r.memoizedState=eL(i),r.childLanes=tL(e,o,i),t.memoizedState=$C,Gd(null,r));if(Hs(t),RR(n)){if(o=n.nextSibling&&n.nextSibling.dataset,o)var l=o.dgst;return o=l,o!==""&&(r=Error(Z(419)),r.stack="",r.digest=o,em({value:r,source:null,stack:null})),_h(e,t,i)}if(aa||bl(e,t,i,!1),o=(i&e.childLanes)!==0,aa||o){if(Ks.current!==null)return _h(e,t,i);if(o=yt,o!==null&&(r=oD(o,i),r!==0&&r!==s.retryLane))throw s.retryLane=r,Dl(e,r),Lo(o,e,r),cR;return IL(n)||Fg(),_h(e,t,i)}return IL(n)?(t.flags|=192,t.child=e.child,null):(e=s.treeContext,Lt=cr(n.nextSibling),Sa=t,Ge=!0,Fs=null,ur=!1,e!==null&&kD(t,e),t=fR(t,r.children),t.flags|=134221824,t)}function tA(e,t,a){e.lanes|=t;var o=e.alternate;o!==null&&(o.lanes|=t),eg(e.return,t,a)}function aA(e){for(var t=null;e!==null;){var a=e.alternate;a!==null&&Ig(a)===null&&(t=e),e=e.sibling}return t}function zh(e,t,a,o,r,n){var s=e.memoizedState;s===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:o,tail:a,tailMode:r,treeForkCount:n}:(s.isBackwards=t,s.rendering=null,s.renderingStartTime=0,s.last=o,s.tail=a,s.tailMode=r,s.treeForkCount=n)}function iC(e){var t=e.child;for(e.child=null;t!==null;){var a=t.sibling;t.sibling=e.child,e.child=t,t=a}}function aL(e,t,a){var o=t.pendingProps,r=o.revealOrder,n=o.tail;o=o.children;var s=ka.current;if(t.flags&128)return am(t,s),null;var i=(s&2)!==0;if(i?(s=s&1|2,t.flags|=128):s&=1,am(t,s),r==="backwards"&&e!==null?(iC(e),ia(e,t,o,a),iC(e)):ia(e,t,o,a),o=Ge?$d:0,!i&&e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&tA(e,a,t);else if(e.tag===19)tA(e,a,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(r){case"backwards":a=aA(t.child),a===null?(r=t.child,t.child=null):(r=a.sibling,a.sibling=null,iC(t)),zh(t,!0,r,null,n,o);break;case"unstable_legacy-backwards":for(a=null,r=t.child,t.child=null;r!==null;){if(e=r.alternate,e!==null&&Ig(e)===null){t.child=r;break}e=r.sibling,r.sibling=a,a=r,r=e}zh(t,!0,a,null,n,o);break;case"together":zh(t,!1,null,null,void 0,o);break;case"independent":t.memoizedState=null;break;default:a=aA(t.child),a===null?(r=t.child,t.child=null):(r=a.sibling,a.sibling=null),zh(t,!1,r,a,n,o)}return t.child}function oA(e,t,a){var o=t.pendingProps;return Os(t,t.type,o.value),ia(e,t,o.children,a),t.child}function Yn(e,t,a){if(e!==null&&(t.dependencies=e.dependencies),Qs|=t.lanes,(a&t.childLanes)===0)if(e!==null){if(bl(e,t,a,!1),(a&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(Z(153));if(t.child!==null){for(e=t.child,a=Hn(e,e.pendingProps),t.child=a,a.return=t;e.sibling!==null;)e=e.sibling,a=a.sibling=Hn(e,e.pendingProps),a.return=t;a.sibling=null}return t.child}function dR(e,t){return(e.lanes&t)!==0?!0:(e=e.dependencies,!!(e!==null&&Lg(e)))}function Sq(e,t,a){switch(t.tag){case 3:hg(t,t.stateNode.containerInfo),Os(t,ta,e.memoizedState.cache),Sl();break;case 27:case 5:AC(t);break;case 4:hg(t,t.stateNode.containerInfo);break;case 10:Os(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,XC(t),null;break;case 13:var o=t.memoizedState;if(o!==null){if(o.dehydrated!==null)return Hs(t),t.flags|=128,null;o=bl(e,t,a,!1);var r=t.child.childLanes;return o||(a&r)!==0?EM(e,t,a):(Hs(t),e=Yn(e,t,a),e!==null?e.sibling:null)}Hs(t);break;case 19:if(t.flags&128)return aL(e,t,a);if(r=(e.flags&128)!==0,o=(a&t.childLanes)!==0,o||(bl(e,t,a,!1),o=(a&t.childLanes)!==0),r){if(o)return aL(e,t,a);t.flags|=128}if(r=t.memoizedState,r!==null&&(r.rendering=null,r.tail=null,r.lastEffect=null),am(t,ka.current),o)break;return null;case 22:return t.lanes=0,wM(e,t,a,t.pendingProps);case 24:Os(t,ta,e.memoizedState.cache)}return Yn(e,t,a)}function AM(e,t,a){if(e!==null)if(e.memoizedProps!==t.pendingProps)aa=!0;else{if(!dR(e,a)&&(t.flags&128)===0)return aa=!1,Sq(e,t,a);aa=(e.flags&131072)!==0}else aa=!1,Ge&&(t.flags&1048576)!==0&&OD(t,$d,t.index);switch(t.lanes=0,t.tag){case 16:e:{var o=t.pendingProps;if(e=cl(t.elementType),t.type=e,typeof e=="function")GL(e)?(o=Tl(e,o),t.tag=1,t=$E(null,t,e,o,a)):(t.tag=0,t=JC(null,t,e,o,a));else{if(e!=null){var r=e.$$typeof;if(r===ML){t.tag=11,t=WE(null,t,e,o,a);break e}else if(r===PL){t.tag=14,t=KE(null,t,e,o,a);break e}else if(r===an){t.tag=10,t.type=e,t=oA(null,t,a);break e}}throw t=wC(e)||e,Error(Z(306,t,""))}}return t;case 0:return JC(e,t,t.type,t.pendingProps,a);case 1:return o=t.type,r=Tl(o,t.pendingProps),$E(e,t,o,r,a);case 3:e:{if(hg(t,t.stateNode.containerInfo),e===null)throw Error(Z(387));o=t.pendingProps;var n=t.memoizedState;r=n.element,qC(e,t),Ud(t,o,null,a);var s=t.memoizedState;if(o=s.cache,Os(t,ta,o),o!==n.cache&&HC(t,[ta],a,!0),Hd(),o=s.element,n.isDehydrated)if(n={element:o,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=n,t.memoizedState=n,t.flags&256){t=eA(e,t,o,a);break e}else if(o!==r){r=lr(Error(Z(424)),t),em(r),t=eA(e,t,o,a);break e}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}for(Lt=cr(e.firstChild),Sa=t,Ge=!0,Fs=null,ur=!0,a=_D(t,null,o,a),t.child=a;a;)a.flags=a.flags&-3|134221824,a=a.sibling}else{if(Sl(),o===r){t=Yn(e,t,a);break e}ia(e,t,o,a)}t=t.child}return t;case 26:return Ju(e,t),e===null?(a=DA(t.type,null,t.pendingProps,null))?t.memoizedState=a:Ge||(t.stateNode=yP(t.type,t.pendingProps,Bs.current,t)):t.memoizedState=DA(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return AC(t),e===null&&Ge&&(o=t.stateNode=EP(t.type,t.pendingProps,Bs.current),Sa=t,ur=!0,r=Lt,$s(t.type)?(wL=r,Lt=cr(o.firstChild)):Lt=r),ia(e,t,t.pendingProps.children,a),Ju(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&Ge&&((r=o=Lt)&&(o=f5(o,t.type,t.pendingProps,ur),o!==null?(t.stateNode=o,Sa=t,Lt=cr(o.firstChild),ur=!1,r=!0):r=!1),r||Ws(t)),AC(t),r=t.type,n=t.pendingProps,s=e!==null?e.memoizedProps:null,o=n.children,LL(r,n)?o=null:s!==null&&LL(r,s)&&(t.flags|=32),t.memoizedState!==null&&(r=$L(e,t,lq,null,null,a),Oc._currentValue=r),Ju(e,t),ia(e,t,o,a),t.child;case 6:return e===null&&Ge&&((e=a=Lt)&&(a=d5(a,t.pendingProps,ur),a!==null?(t.stateNode=a,Sa=t,Lt=null,e=!0):e=!1),e||Ws(t)),null;case 13:return EM(e,t,a);case 4:return hg(t,t.stateNode.containerInfo),o=t.pendingProps,e===null?t.child=Ll(t,null,o,a):ia(e,t,o,a),t.child;case 11:return WE(e,t,t.type,t.pendingProps,a);case 7:return o=t.pendingProps,Ju(e,t),ia(e,t,o,a),t.child;case 8:return ia(e,t,t.pendingProps.children,a),t.child;case 12:return ia(e,t,t.pendingProps.children,a),t.child;case 10:return oA(e,t,a);case 9:return r=t.type._context,o=t.pendingProps.children,vl(t),r=Pa(r),o=o(r),t.flags|=1,ia(e,t,o,a),t.child;case 14:return KE(e,t,t.type,t.pendingProps,a);case 15:return IM(e,t,t.type,t.pendingProps,a);case 19:return aL(e,t,a);case 31:return xq(e,t,a);case 22:return wM(e,t,a,t.pendingProps);case 24:return vl(t),o=Pa(ta),e===null?(r=YL(),r===null&&(r=yt,n=XL(),r.pooledCache=n,n.refCount++,n!==null&&(r.pooledCacheLanes|=a),r=n),t.memoizedState={parent:o,cache:r},KL(t),Os(t,ta,r)):((e.lanes&a)!==0&&(qC(e,t),Ud(t,null,null,a),Hd()),r=e.memoizedState,n=t.memoizedState,r.parent!==o?(r={parent:o,cache:o},t.memoizedState=r,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=r),Os(t,ta,o)):(o=n.cache,Os(t,ta,o),o!==r.cache&&HC(t,[ta],a,!0))),ia(e,t,t.pendingProps.children,a),t.child;case 30:return t.stateNode===null&&(t.stateNode={autoName:null,paired:null,clones:null,ref:null}),o=t.pendingProps,o.name!=null&&o.name!=="auto"?t.flags|=e===null?18882560:18874368:Ge&&Zg(t),e!==null&&e.memoizedProps.name!==o.name?t.flags|=4194816:Ju(e,t),ia(e,t,o.children,a),t.child;case 29:throw t.pendingProps}throw Error(Z(156,t.tag))}function Fn(e){e.flags|=4}function lC(e,t,a,o,r){var n;if((n=(e.mode&32)!==0)&&(n=a===null?OA(t,o):OA(t,o)&&(o.src!==a.src||o.srcSet!==a.srcSet)),n){if(e.flags|=16777216,(r&335544128)===r)if(e.stateNode.complete)e.flags|=8192;else if(rP())e.flags|=8192;else throw xl=Rg,WL}else e.flags&=-16777217}function rA(e,t){if(t.type!=="stylesheet"||(t.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!PP(t))if(rP())e.flags|=8192;else throw xl=Rg,WL}function Hh(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?eD():536870912,e.lanes|=t,wc|=t)}function wd(e,t){if(!Ge)switch(e.tailMode){case"visible":break;case"collapsed":for(var a=e.tail,o=null;a!==null;)a.alternate!==null&&(o=a),a=a.sibling;o===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:o.sibling=null;break;default:for(t=e.tail,a=null;t!==null;)t.alternate!==null&&(a=t),t=t.sibling;a===null?e.tail=null:a.sibling=null}}function Ct(e){var t=e.alternate!==null&&e.alternate.child===e.child,a=0,o=0;if(t)for(var r=e.child;r!==null;)a|=r.lanes|r.childLanes,o|=r.subtreeFlags&1206910976,o|=r.flags&1206910976,r.return=e,r=r.sibling;else for(r=e.child;r!==null;)a|=r.lanes|r.childLanes,o|=r.subtreeFlags,o|=r.flags,r.return=e,r=r.sibling;return e.subtreeFlags|=o,e.childLanes=a,t}function bq(e,t,a){var o=t.pendingProps;switch(jL(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Ct(t),null;case 1:return Ct(t),null;case 3:return a=t.stateNode,o=null,e!==null&&(o=e.memoizedState.cache),t.memoizedState.cache!==o&&(t.flags|=2048),Un(ta),Lc(),a.pendingContext&&(a.context=a.pendingContext,a.pendingContext=null),(e===null||e.child===null)&&(Zu(t)?Fn(t):e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,oC())),Ct(t),null;case 26:var r=t.type,n=t.memoizedState;return e===null?(Fn(t),n!==null?(Ct(t),rA(t,n)):(Ct(t),lC(t,r,null,o,a))):n?n!==e.memoizedState?(Fn(t),Ct(t),rA(t,n)):(Ct(t),t.flags&=-16777217):(e=e.memoizedProps,e!==o&&Fn(t),Ct(t),lC(t,r,e,o,a)),null;case 27:if(gg(t),a=Bs.current,r=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==o&&Fn(t);else{if(!o){if(t.stateNode===null)throw Error(Z(166));return Ct(t),t.subtreeFlags&=-33554433,null}e=sn.current,Zu(t)?ME(t,e):(e=EP(r,o,a),t.stateNode=e,Fn(t))}return Ct(t),t.subtreeFlags&=-33554433,null;case 5:if(gg(t),r=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==o&&Fn(t);else{if(!o){if(t.stateNode===null)throw Error(Z(166));return Ct(t),t.subtreeFlags&=-33554433,null}if(n=sn.current,Zu(t))ME(t,n);else{var s=sm(Bs.current);switch(n){case 1:n=s.createElementNS("http://www.w3.org/2000/svg",r);break;case 2:n=s.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;default:switch(r){case"svg":n=s.createElementNS("http://www.w3.org/2000/svg",r);break;case"math":n=s.createElementNS("http://www.w3.org/1998/Math/MathML",r);break;case"script":n=s.createElement("div"),n.innerHTML="<script><\/script>",n=n.removeChild(n.firstChild);break;case"select":n=typeof o.is=="string"?s.createElement("select",{is:o.is}):s.createElement("select"),o.multiple?n.multiple=!0:o.size&&(n.size=o.size);break;default:n=typeof o.is=="string"?s.createElement(r,{is:o.is}):s.createElement(r)}}n[Ma]=t,n[To]=o;e:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)n.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break e;for(;s.sibling===null;){if(s.return===null||s.return===t)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=n;e:switch(Na(n,r,o),r){case"button":case"input":case"select":case"textarea":o=!!o.autoFocus;break e;case"img":o=!0;break e;default:o=!1}o&&Fn(t)}}return Ct(t),t.subtreeFlags&=-33554433,lC(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,a),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==o&&Fn(t);else{if(typeof o!="string"&&t.stateNode===null)throw Error(Z(166));if(e=Bs.current,Zu(t)){if(e=t.stateNode,a=t.memoizedProps,o=null,r=Sa,r!==null)switch(r.tag){case 27:case 5:o=r.memoizedProps}e[Ma]=t,e=!!(e.nodeValue===a||o!==null&&o.suppressHydrationWarning===!0||gP(e.nodeValue,a)),e||Ws(t,!0)}else e=sm(e).createTextNode(o),e[Ma]=t,t.stateNode=e}return Ct(t),null;case 31:if(a=t.memoizedState,e===null||e.memoizedState!==null){if(o=Zu(t),a!==null){if(e===null){if(!o)throw Error(Z(318));if(e=t.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(Z(557));e[Ma]=t}else Sl(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;Ct(t),e=!1}else a=oC(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),e=!0;if(!e)return t.flags&256?(_o(t),t):(_o(t),null);if((t.flags&128)!==0)throw Error(Z(558))}return Ct(t),null;case 13:if(o=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(r=Zu(t),o!==null&&o.dehydrated!==null){if(e===null){if(!r)throw Error(Z(318));if(r=t.memoizedState,r=r!==null?r.dehydrated:null,!r)throw Error(Z(317));r[Ma]=t}else Sl(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;Ct(t),r=!1}else r=oC(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=r),r=!0;if(!r)return t.flags&256?(_o(t),t):(_o(t),null)}return _o(t),(t.flags&128)!==0?(t.lanes=a,t):(a=o!==null,e=e!==null&&e.memoizedState!==null,a&&(o=t.child,r=null,o.alternate!==null&&o.alternate.memoizedState!==null&&o.alternate.memoizedState.cachePool!==null&&(r=o.alternate.memoizedState.cachePool.pool),n=null,o.memoizedState!==null&&o.memoizedState.cachePool!==null&&(n=o.memoizedState.cachePool.pool),n!==r&&(o.flags|=2048)),a!==e&&a&&(t.child.flags|=8192),Hh(t,t.updateQueue),Ct(t),null);case 4:return Lc(),e===null&&vR(t.stateNode.containerInfo),t.flags|=67108864,Ct(t),null;case 10:return Un(t.type),Ct(t),null;case 19:if(QL(t),o=t.memoizedState,o===null)return Ct(t),null;if(r=(t.flags&128)!==0,n=o.rendering,n===null)if(r)wd(o,!1);else{if(qt!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(n=Ig(e),n!==null){for(t.flags|=128,wd(o,!1),e=n.updateQueue,t.updateQueue=e,Hh(t,e),t.subtreeFlags=0,e=a,a=t.child;a!==null;)MD(a,e),a=a.sibling;return am(t,ka.current&1|2),Ge&&_n(t,o.treeForkCount),t.child}e=e.sibling}o.tail!==null&&Uo()>Vg&&(t.flags|=128,r=!0,wd(o,!1),t.lanes=4194304)}else{if(!r)if(e=Ig(n),e!==null){if(t.flags|=128,r=!0,e=e.updateQueue,t.updateQueue=e,Hh(t,e),wd(o,!0),o.tail===null&&o.tailMode!=="collapsed"&&o.tailMode!=="visible"&&!n.alternate&&!Ge)return Ct(t),null}else 2*Uo()-o.renderingStartTime>Vg&&a!==536870912&&(t.flags|=128,r=!0,wd(o,!1),t.lanes=4194304);o.isBackwards?(n.sibling=t.child,t.child=n):(e=o.last,e!==null?e.sibling=n:t.child=n,o.last=n)}if(o.tail!==null){e=o.tail;e:{for(a=e;a!==null;){if(a.alternate!==null){a=!1;break e}a=a.sibling}a=!0}return o.rendering=e,o.tail=e.sibling,o.renderingStartTime=Uo(),e.sibling=null,n=ka.current,n=r?n&1|2:n&1,o.tailMode==="visible"||o.tailMode==="collapsed"||!a||Ge?am(t,n):(a=n,Rt(Va,t),Rt(ka,a),Ga===null&&(Ga=t)),Ge&&_n(t,o.treeForkCount),e}return Ct(t),null;case 22:case 23:return _o(t),ZL(),o=t.memoizedState!==null,e!==null?e.memoizedState!==null!==o&&(t.flags|=8192):o&&(t.flags|=8192),o?(a&536870912)!==0&&(t.flags&128)===0&&(Ct(t),t.subtreeFlags&6&&(t.flags|=8192)):Ct(t),a=t.updateQueue,a!==null&&Hh(t,a.retryQueue),a=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),o=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(o=t.memoizedState.cachePool.pool),o!==a&&(t.flags|=2048),e!==null&&Oa(gl),null;case 24:return a=null,e!==null&&(a=e.memoizedState.cache),t.memoizedState.cache!==a&&(t.flags|=2048),Un(ta),Ct(t),null;case 25:return null;case 30:return t.flags|=33554432,Ct(t),null}throw Error(Z(156,t.tag))}function vq(e,t){switch(jL(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Un(ta),Lc(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return gg(t),null;case 31:if(t.memoizedState!==null){if(_o(t),t.alternate===null)throw Error(Z(340));Sl()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(_o(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(Z(340));Sl()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return QL(t),e=t.flags,e&65536?(t.flags=e&-65537|128,e=t.memoizedState,e!==null&&(e.rendering=null,e.tail=null),t.flags|=4,t):null;case 4:return Lc(),null;case 10:return Un(t.type),null;case 22:case 23:return _o(t),ZL(),e!==null&&Oa(gl),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return Un(ta),null;case 25:return null;default:return null}}function DM(e,t){switch(jL(t),t.tag){case 3:Un(ta),Lc();break;case 26:case 27:case 5:gg(t);break;case 4:Lc();break;case 31:t.memoizedState!==null&&_o(t);break;case 13:_o(t);break;case 19:QL(t);break;case 10:Un(t.type);break;case 22:case 23:_o(t),ZL(),e!==null&&Oa(gl);break;case 24:Un(ta)}}function Sm(e,t){try{var a=t.updateQueue,o=a!==null?a.lastEffect:null;if(o!==null){var r=o.next;a=r;do{if((a.tag&e)===e){o=void 0;var n=a.create,s=a.inst;o=n(),s.destroy=o}a=a.next}while(a!==r)}}catch(i){dt(t,t.return,i)}}function Zs(e,t,a){try{var o=t.updateQueue,r=o!==null?o.lastEffect:null;if(r!==null){var n=r.next;o=n;do{if((o.tag&e)===e){var s=o.inst,i=s.destroy;if(i!==void 0){s.destroy=void 0,r=t;var l=a,u=i;try{u()}catch(c){dt(r,l,c)}}}o=o.next}while(o!==n)}}catch(c){dt(t,t.return,c)}}function MM(e){var t=e.updateQueue;if(t!==null){var a=e.stateNode;try{HD(t,a)}catch(o){dt(e,e.return,o)}}}function PM(e,t,a){a.props=Tl(e.type,e.memoizedProps),a.state=e.memoizedState;try{a.componentWillUnmount()}catch(o){dt(e,t,o)}}function en(e,t){try{var a=e.ref;if(a!==null){switch(e.tag){case 26:case 27:case 5:var o=e.stateNode;break;case 30:var r=e.stateNode,n=Gn(e.memoizedProps,r);(r.ref===null||r.ref.name!==n)&&(r.ref=CP(n)),o=r.ref;break;case 7:if(e.stateNode===null){var s=new Yo(e);Ro(e.child,!1,u5,s,void 0,void 0),e.stateNode=s}o=e.stateNode;break;default:o=e.stateNode}typeof a=="function"?e.refCleanup=a(o):a.current=o}}catch(i){dt(e,t,i)}}function Da(e,t){var a=e.ref,o=e.refCleanup;if(a!==null)if(typeof o=="function")try{o()}catch(r){dt(e,t,r)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof a=="function")try{a(null)}catch(r){dt(e,t,r)}else a.current=null}function Mg(e,t){if((e.tag===5||e.tag===27||e.tag===6)&&e.alternate===null&&t!==null)for(var a=0;a<t.length;a++)IP(e.stateNode,t[a])}function nA(e){for(var t=e.return;t!==null&&(pR(t)&&IP(e.stateNode,t.stateNode),!mR(t));)t=t.return}function jd(e){for(var t=e.return;t!==null&&(pR(t)&&c5(e.stateNode,t.stateNode),!mR(t));)t=t.return}function mR(e){return e.tag===5||e.tag===3||e.tag===27}function pR(e){return e&&e.tag===7&&e.stateNode!==null}function oL(e){var t=e.type,a=e.memoizedProps,o=e.stateNode;try{e:switch(t){case"button":case"input":case"select":case"textarea":a.autoFocus&&o.focus();break e;case"img":a.src?o.src=a.src:a.srcSet&&(o.srcset=a.srcSet)}}catch(r){dt(e,e.return,r)}}function uC(e,t,a){try{var o=e.stateNode;jq(o,e.type,a,t),o[To]=t}catch(r){dt(e,e.return,r)}}function OM(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&$s(e.type)||e.tag===4}function cC(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||OM(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&$s(e.type)||e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function rL(e,t,a,o){var r=e.tag;if(r===5||r===6)r=e.stateNode,t?(a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a).insertBefore(r,t):(t=a.nodeType===9?a.body:a.nodeName==="HTML"?a.ownerDocument.body:a,t.appendChild(r),a=a._reactRootContainer,a!=null||t.onclick!==null||(t.onclick=on)),Mg(e,o),tt=!0;else if(r!==4&&(r===27&&(Mg(e,o),o=null,$s(e.type)&&(a=e.stateNode,t=null)),e=e.child,e!==null))for(rL(e,t,a,o),e=e.sibling;e!==null;)rL(e,t,a,o),e=e.sibling}function Pg(e,t,a,o){var r=e.tag;if(r===5||r===6)r=e.stateNode,t?a.insertBefore(r,t):a.appendChild(r),Mg(e,o),tt=!0;else if(r!==4&&(r===27&&(Mg(e,o),o=null,$s(e.type)&&(a=e.stateNode)),e=e.child,e!==null))for(Pg(e,t,a,o),e=e.sibling;e!==null;)Pg(e,t,a,o),e=e.sibling}function kM(e){var t=e.stateNode,a=e.memoizedProps;try{for(var o=e.type,r=t.attributes;r.length;)t.removeAttributeNode(r[0]);Na(t,o,a),t[Ma]=e,t[To]=a}catch(n){dt(e,e.return,n)}}var Og=!1,zo=null;function sA(e){(e.tag===30||(e.subtreeFlags&33554432)!==0)&&(Og=!0)}var tn=null;function iA(){var e=tn;return tn=null,e}var vo=0;function _c(e,t,a,o,r){return vo=0,NM(e.child,t,a,o,r)}function NM(e,t,a,o,r){for(var n=!1;e!==null;){if(e.tag===5){var s=e.stateNode;if(o!==null){var i=RL(s);o.push(i),i.view&&(n=!0)}else n||RL(s).view&&(n=!0);Og=!0,SP(s,vo===0?t:t+"_"+vo,a),vo++}else(e.tag!==22||e.memoizedState===null)&&(e.tag===30&&r||NM(e.child,t,a,o,r)&&(n=!0));e=e.sibling}return n}function un(e,t){for(;e!==null;)e.tag===5?bP(e.stateNode,e.memoizedProps):(e.tag!==22||e.memoizedState===null)&&(e.tag===30&&t||un(e.child,t)),e=e.sibling}function ng(e){if((e.subtreeFlags&18874368)!==0)for(e=e.child;e!==null;){if((e.tag!==22||e.memoizedState===null)&&(ng(e),e.tag===30&&(e.flags&18874368)!==0&&e.stateNode.paired)){var t=e.memoizedProps;if(t.name==null||t.name==="auto")throw Error(Z(544));var a=t.name;t=Zn(t.default,t.share),t!=="none"&&(_c(e,a,t,null,!1)||un(e.child,!1))}e=e.sibling}}function nL(e,t){if(e.tag===30){var a=e.stateNode,o=e.memoizedProps,r=Gn(o,a),n=Zn(o.default,a.paired?o.share:o.enter);n!=="none"?_c(e,r,n,null,!1)?(ng(e),a.paired||t||Ec(e,o.onEnter)):un(e.child,!1):ng(e)}else if((e.subtreeFlags&33554432)!==0)for(e=e.child;e!==null;)nL(e,t),e=e.sibling;else ng(e)}function sL(e){if(zo!==null&&zo.size!==0){var t=zo;if((e.subtreeFlags&18874368)!==0)for(e=e.child;e!==null;){if(e.tag!==22||e.memoizedState===null){if(e.tag===30&&(e.flags&18874368)!==0){var a=e.memoizedProps,o=a.name;if(o!=null&&o!=="auto"){var r=t.get(o);if(r!==void 0){var n=Zn(a.default,a.share);if(n!=="none"&&(_c(e,o,n,null,!1)?(n=e.stateNode,r.paired=n,n.paired=r,Ec(e,a.onShare)):un(e.child,!1)),t.delete(o),t.size===0)break}}}sL(e)}e=e.sibling}}}function iL(e){if(e.tag===30){var t=e.memoizedProps,a=Gn(t,e.stateNode),o=zo!==null?zo.get(a):void 0,r=Zn(t.default,o!==void 0?t.share:t.exit);r!=="none"&&(_c(e,a,r,null,!1)?o!==void 0?(r=e.stateNode,o.paired=r,r.paired=o,zo.delete(a),Ec(e,t.onShare)):Ec(e,t.onExit):un(e.child,!1)),zo!==null&&sL(e)}else if((e.subtreeFlags&33554432)!==0)for(e=e.child;e!==null;)iL(e),e=e.sibling;else zo!==null&&sL(e)}function VM(e){for(e=e.child;e!==null;){if(e.tag===30){var t=e.memoizedProps,a=Gn(t,e.stateNode);t=Zn(t.default,t.update),e.flags&=-5,t!=="none"&&_c(e,a,t,e.memoizedState=[],!1)}else(e.subtreeFlags&33554432)!==0&&VM(e);e=e.sibling}}function lL(e){if((e.subtreeFlags&18874368)!==0)for(e=e.child;e!==null;){if(e.tag!==22||e.memoizedState===null){if(e.tag===30&&(e.flags&18874368)!==0){var t=e.stateNode;t.paired!==null&&(t.paired=null,un(e.child,!1))}lL(e)}e=e.sibling}}function sg(e){if(e.tag===30)e.stateNode.paired=null,un(e.child,!1),lL(e);else if((e.subtreeFlags&33554432)!==0)for(e=e.child;e!==null;)sg(e),e=e.sibling;else lL(e)}function BM(e){for(e=e.child;e!==null;)e.tag===30?un(e.child,!1):(e.subtreeFlags&33554432)!==0&&BM(e),e=e.sibling}function hR(e,t,a,o,r,n,s){for(var i=!1;t!==null;){if(t.tag===5){var l=t.stateNode;if(n!==null&&vo<n.length){var u=n[vo],c=RL(l);(u.view||c.view)&&(i=!0);var d;if(d=(e.flags&4)===0)if(c.clip)d=!0;else{d=u.rect;var f=c.rect;d=d.y!==f.y||d.x!==f.x||d.height!==f.height||d.width!==f.width}d&&(e.flags|=4),c.abs?c=!u.abs:(u=u.rect,c=c.rect,c=u.height!==c.height||u.width!==c.width),c&&(e.flags|=32)}else e.flags|=32;(e.flags&4)!==0&&SP(l,vo===0?a:a+"_"+vo,r),i&&(e.flags&4)!==0||(tn===null&&(tn=[]),tn.push(l,vo===0?o:o+"_"+vo,t.memoizedProps)),vo++}else(t.tag!==22||t.memoizedState===null)&&(t.tag===30&&s?e.flags|=t.flags&32:hR(e,t.child,a,o,r,n,s)&&(i=!0));t=t.sibling}return i}function FM(e,t){for(e=e.child;e!==null;){if(e.tag===30){var a=e.memoizedProps,o=e.stateNode,r=Gn(a,o),n=Zn(a.default,a.update);if(t){o=o.clones;var s=o===null?null:o.map(Qq)}else s=e.memoizedState,e.memoizedState=null;o=e;var i=e.child;vo=0,r=hR(o,i,r,r,n,s,!1),(e.flags&4)!==0&&r&&(t||Ec(e,a.onUpdate))}else(e.subtreeFlags&33554432)!==0&&FM(e,t);e=e.sibling}}var ga=!1,lt=!1,Qr=!1,fC=!1,lA=typeof WeakSet=="function"?WeakSet:Set,xa=null,Jr=!1,Nd=!1,kg=!1,uL=!1;function Cq(e,t,a){if(e=e.containerInfo,vL=kc,e=LD(e),HL(e)){if("selectionStart"in e)var o={start:e.selectionStart,end:e.selectionEnd};else e:{o=(o=e.ownerDocument)&&o.defaultView||window;var r=o.getSelection&&o.getSelection();if(r&&r.rangeCount!==0){o=r.anchorNode;var n=r.anchorOffset,s=r.focusNode;r=r.focusOffset;try{o.nodeType,s.nodeType}catch{o=null;break e}var i=0,l=-1,u=-1,c=0,d=0,f=e,m=null;t:for(;;){for(var p;f!==o||n!==0&&f.nodeType!==3||(l=i+n),f!==s||r!==0&&f.nodeType!==3||(u=i+r),f.nodeType===3&&(i+=f.nodeValue.length),(p=f.firstChild)!==null;)m=f,f=p;for(;;){if(f===e)break t;if(m===o&&++c===n&&(l=i),m===s&&++d===r&&(u=i),(p=f.nextSibling)!==null)break;f=m,m=f.parentNode}f=p}o=l===-1||u===-1?null:{start:l,end:u}}else o=null}o=o||{start:0,end:0}}else o=null;for(CL={focusedElem:e,selectionRange:o},kc=!1,a=(a&335544064)===a,xa=t,t=a?9270:1024;xa!==null;){if(e=xa,a&&(o=e.deletions,o!==null))for(n=0;n<o.length;n++)a&&iL(o[n]);if(e.alternate===null&&(e.flags&2)!==0)a&&sA(e),Uh(a);else{if(e.tag===22){if(o=e.alternate,e.memoizedState!==null){o!==null&&o.memoizedState===null&&a&&iL(o),Uh(a);continue}else if(o!==null&&o.memoizedState!==null){a&&sA(e),Uh(a);continue}}o=e.child,(e.subtreeFlags&t)!==0&&o!==null?(o.return=e,xa=o):(a&&VM(e),Uh(a))}}zo=null}function Uh(e){for(;xa!==null;){var t=xa,a=e,o=t.alternate,r=t.flags;switch(t.tag){case 0:case 11:case 15:break;case 1:if((r&1024)!==0&&o!==null){a=void 0,r=o.memoizedProps,o=o.memoizedState;var n=t.stateNode;try{var s=Tl(t.type,r);a=n.getSnapshotBeforeUpdate(s,o),n.__reactInternalSnapshotBeforeUpdate=a}catch(i){dt(t,t.return,i)}}break;case 3:if((r&1024)!==0){if(o=t.stateNode.containerInfo,a=o.nodeType,a===9)TL(o);else if(a===1)switch(o.nodeName){case"HEAD":case"HTML":case"BODY":TL(o);break;default:o.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;case 30:a&&o!==null&&(a=Gn(o.memoizedProps,o.stateNode),r=t.memoizedProps,r=Zn(r.default,r.update),r!=="none"&&_c(o,a,r,o.memoizedState=[],!0));break;default:if((r&1024)!==0)throw Error(Z(163))}if(o=t.sibling,o!==null){o.return=t.return,xa=o;break}xa=t.return}}function _M(e,t,a){var o=a.flags;switch(a.tag){case 0:case 11:case 15:$r(e,a),o&4&&Sm(5,a);break;case 1:if($r(e,a),o&4)if(e=a.stateNode,t===null)try{e.componentDidMount()}catch(s){dt(a,a.return,s)}else{var r=Tl(a.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(r,t,e.__reactInternalSnapshotBeforeUpdate)}catch(s){dt(a,a.return,s)}}o&64&&MM(a),o&512&&en(a,a.return);break;case 3:if($r(e,a),o&64&&(e=a.updateQueue,e!==null)){if(t=null,a.child!==null)switch(a.child.tag){case 27:case 5:t=a.child.stateNode;break;case 1:t=a.child.stateNode}try{HD(e,t)}catch(s){dt(a,a.return,s)}}break;case 27:t===null&&o&4&&kM(a);case 26:case 5:$r(e,a),t===null&&o&4&&oL(a),o&512&&en(a,a.return);break;case 12:$r(e,a);break;case 31:$r(e,a),o&4&&qM(e,a);break;case 13:$r(e,a),o&4&&GM(e,a),o&64&&(e=a.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(a=kq.bind(null,a),m5(e,a))));break;case 22:if(o=a.memoizedState!==null||ga,!o){var n=t!==null&&t.memoizedState!==null||lt;t=ga,r=lt,ga=o,(lt=n)&&!r?(o=2,(a.subtreeFlags&8772)!==0&&(o|=1),Pr(e,a,o)):$r(e,a),ga=t,lt=r}break;case 30:$r(e,a),o&512&&en(a,a.return);break;case 7:o&512&&en(a,a.return);default:$r(e,a)}}function cL(e,t){for(e=e.child;e!==null;)zM(e,t),e=e.sibling}function zM(e,t){switch(e.tag){case 5:case 26:try{var a=e.stateNode;if(t){var o=a.style;typeof o.setProperty=="function"?o.setProperty("display","none","important"):o.display="none"}else{var r=e.stateNode,n=e.memoizedProps.style,s=n!=null&&n.hasOwnProperty("display")?n.display:null;r.style.display=s==null||typeof s=="boolean"?"":(""+s).trim()}}catch(l){dt(e,e.return,l)}fL(e,t);break;case 6:try{e.stateNode.nodeValue=t?"":e.memoizedProps,tt=!0}catch(l){dt(e,e.return,l)}break;case 18:try{var i=e.stateNode;t?RA(i,!0):RA(e.stateNode,!1)}catch(l){dt(e,e.return,l)}break;case 22:case 23:e.memoizedState===null&&cL(e,t);break;default:cL(e,t)}}function fL(e,t){if(e.subtreeFlags&67108864)for(e=e.child;e!==null;){e:{var a=e,o=t;switch(a.tag){case 4:zM(a,o);break e;case 22:a.memoizedState===null&&fL(a,o);break e;default:fL(a,o)}}e=e.sibling}}function HM(e){var t=e.alternate;t!==null&&(e.alternate=null,HM(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&Gg(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var Ot=null,So=!1;function Mr(e,t,a){for(a=a.child;a!==null;)UM(e,t,a),a=a.sibling}function UM(e,t,a){if(qo&&typeof qo.onCommitFiberUnmount=="function")try{qo.onCommitFiberUnmount(dm,a)}catch{}switch(a.tag){case 26:lt||Da(a,t),Mr(e,t,a),a.memoizedState?a.memoizedState.count--:a.stateNode&&!lt&&(a=a.stateNode,a.parentNode.removeChild(a));break;case 27:lt||Da(a,t),jd(a);var o=Ot,r=So;$s(a.type)&&(Ot=a.stateNode,So=!1),Mr(e,t,a),AP(a.stateNode,a.type,a.memoizedProps),Ot=o,So=r;break;case 5:lt||Da(a,t),jd(a);case 6:if(a.tag===6&&jd(a),o=Ot,r=So,Ot=null,Mr(e,t,a),Ot=o,So=r,Ot!==null)if(So)try{(Ot.nodeType===9?Ot.body:Ot.nodeName==="HTML"?Ot.ownerDocument.body:Ot).removeChild(a.stateNode),tt=!0}catch(n){dt(a,t,n)}else try{Ot.removeChild(a.stateNode),tt=!0}catch(n){dt(a,t,n)}break;case 18:Ot!==null&&(So?(e=Ot,LA(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,a.stateNode),Nc(e)):LA(Ot,a.stateNode));break;case 4:o=Ot,r=So,Ot=a.stateNode.containerInfo,So=!0,Mr(e,t,a),Ot=o,So=r;break;case 0:case 11:case 14:case 15:Zs(2,a,t),lt||Zs(4,a,t),Mr(e,t,a);break;case 1:lt||(Da(a,t),o=a.stateNode,typeof o.componentWillUnmount=="function"&&PM(a,t,o)),Mr(e,t,a);break;case 21:Mr(e,t,a);break;case 22:lt=(o=lt)||a.memoizedState!==null,Mr(e,t,a),lt=o;break;case 30:Da(a,t),Mr(e,t,a);break;case 7:lt||Da(a,t),Mr(e,t,a);break;default:Mr(e,t,a)}}function qM(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Nc(e)}catch(a){dt(t,t.return,a)}}}function GM(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Nc(e)}catch(a){dt(t,t.return,a)}}function Lq(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new lA),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new lA),t;default:throw Error(Z(435,e.tag))}}function qh(e,t){var a=Lq(e);t.forEach(function(o){if(!a.has(o)){a.add(o);var r=Nq.bind(null,e,o);o.then(r,r)}})}function ao(e,t,a){var o=t.deletions;if(o!==null)for(var r=0;r<o.length;r++){var n=o[r],s=e,i=t,l=i;e:for(;l!==null;){switch(l.tag){case 27:if($s(l.type)){Ot=l.stateNode,So=!1;break e}break;case 5:Ot=l.stateNode,So=!1;break e;case 3:case 4:Ot=l.stateNode.containerInfo,So=!0;break e}l=l.return}if(Ot===null)throw Error(Z(160));UM(s,i,n),Ot=null,So=!1,s=n.alternate,s!==null&&(s.return=null),n.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)jM(t,e,a),t=t.sibling}var Or=null;function jM(e,t,a){var o=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(r&4&&(o=e.updateQueue,o=o!==null?o.events:null,o!==null))for(var n=0;n<o.length;n++){var s=o[n];s.ref.impl=s.nextImpl}ao(t,e,a),oo(e),r&4&&(Zs(3,e,e.return),Sm(3,e),Zs(5,e,e.return));break;case 1:ao(t,e,a),oo(e),r&512&&(lt||o===null||Da(o,o.return)),r&64&&ga&&(e=e.updateQueue,e!==null&&(t=e.callbacks,t!==null&&(a=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=a===null?t:a.concat(t))));break;case 26:if(n=Or,ao(t,e,a),oo(e),r&512&&(lt||o===null||Da(o,o.return)),r&4)if(r=o!==null?o.memoizedState:null,a=e.memoizedState,o===null)if(a===null)if(e.stateNode===null)if(ga)e.stateNode=yP(e.type,e.memoizedProps,t.containerInfo,e);else{e:{t=e.type,a=e.memoizedProps,r=n.ownerDocument||n;t:switch(t){case"title":o=r.getElementsByTagName("title")[0],(!o||o[hm]||o[Ma]||o.namespaceURI==="http://www.w3.org/2000/svg"||o.hasAttribute("itemprop"))&&(o=r.createElement(t),r.head.insertBefore(o,r.querySelector("head > title"))),Na(o,t,a),o[Ma]=e,ya(o),t=o;break e;case"link":if(n=PA("link","href",r).get(t+(a.href||""))){for(s=0;s<n.length;s++)if(o=n[s],o.getAttribute("href")===(a.href==null||a.href===""?null:a.href)&&o.getAttribute("rel")===(a.rel==null?null:a.rel)&&o.getAttribute("title")===(a.title==null?null:a.title)&&o.getAttribute("crossorigin")===(a.crossOrigin==null?null:a.crossOrigin)){n.splice(s,1);break t}}o=r.createElement(t),Na(o,t,a),r.head.appendChild(o);break;case"meta":if(n=PA("meta","content",r).get(t+(a.content||""))){for(s=0;s<n.length;s++)if(o=n[s],o.getAttribute("content")===(a.content==null?null:""+a.content)&&o.getAttribute("name")===(a.name==null?null:a.name)&&o.getAttribute("property")===(a.property==null?null:a.property)&&o.getAttribute("http-equiv")===(a.httpEquiv==null?null:a.httpEquiv)&&o.getAttribute("charset")===(a.charSet==null?null:a.charSet)){n.splice(s,1);break t}}o=r.createElement(t),Na(o,t,a),r.head.appendChild(o);break;default:throw Error(Z(468,t))}o[Ma]=e,ya(o),t=o}e.stateNode=t}else ga||EL(n,e.type,e.stateNode);else e.stateNode=MA(n,a,e.memoizedProps);else r!==a?(r===null?(t=o.stateNode,t===null||lt||t.parentNode.removeChild(t)):r.count--,a===null?ga||EL(n,e.type,e.stateNode):MA(n,a,e.memoizedProps)):a===null&&e.stateNode!==null&&uC(e,e.memoizedProps,o.memoizedProps);break;case 27:ao(t,e,a),oo(e),r&512&&(lt||o===null||Da(o,o.return)),o!==null&&r&4&&uC(e,e.memoizedProps,o.memoizedProps);break;case 5:if(n=Qr,Qr=!1,ao(t,e,a),Qr=n,oo(e),r&512&&(lt||o===null||Da(o,o.return)),e.flags&32){t=e.stateNode;try{Tc(t,""),tt=!0}catch(c){dt(e,e.return,c)}}r&4&&e.stateNode!=null&&(t=e.memoizedProps,uC(e,t,o!==null?o.memoizedProps:t)),r&1024&&(fC=!0);break;case 6:if(ao(t,e,a),oo(e),r&4){if(e.stateNode===null)throw Error(Z(162));t=e.memoizedProps,a=e.stateNode;try{a.nodeValue=t,tt=!0}catch(c){dt(e,e.return,c)}}break;case 3:if(tt=!1,cg=null,n=Or,Or=im(t.containerInfo),ao(t,e,a),Or=n,oo(e),r&4&&o!==null&&o.memoizedState.isDehydrated)try{Nc(t.containerInfo)}catch(c){dt(e,e.return,c)}fC&&(fC=!1,XM(e)),tt=!1;break;case 4:r=Qr,Qr=ga,o=pE(),n=Or,Or=im(e.stateNode.containerInfo),ao(t,e,a),oo(e),Or=n,tt&&Nd&&(kg=!0),tt=o,Qr=r;break;case 12:ao(t,e,a),oo(e);break;case 31:ao(t,e,a),oo(e),r&4&&(t=e.updateQueue,t!==null&&(e.updateQueue=null,qh(e,t)));break;case 13:ao(t,e,a),oo(e),e.child.flags&8192&&e.memoizedState!==null!=(o!==null&&o.memoizedState!==null)&&(ox=Uo()),r&4&&(t=e.updateQueue,t!==null&&(e.updateQueue=null,qh(e,t)));break;case 22:n=e.memoizedState!==null,s=o!==null&&o.memoizedState!==null;var i=ga,l=lt,u=Qr;ga=i||n,Qr=u||n,lt=l||s,ao(t,e,a),lt=l,Qr=u,ga=i,oo(e),r&8192&&(t=e.stateNode,t._visibility=n?t._visibility&-2:t._visibility|1,!n||o===null||s||ga||lt||(t=s||lt,a=ga,o=lt,ga=n||ga,lt=t,ws(e,2),ga=a,lt=o),!n&&Qr||cL(e,n)),r&4&&(t=e.updateQueue,t!==null&&(a=t.retryQueue,a!==null&&(t.retryQueue=null,qh(e,a))));break;case 19:ao(t,e,a),oo(e),r&4&&(t=e.updateQueue,t!==null&&(e.updateQueue=null,qh(e,t)));break;case 30:r&512&&(lt||o===null||Da(o,o.return)),r=pE(),n=Nd,s=(a&335544064)===a,i=e.memoizedProps,Nd=s&&Zn(i.default,i.update)!=="none",ao(t,e,a),oo(e),s&&o!==null&&tt&&(e.flags|=4),Nd=n,tt=r;break;case 21:break;case 7:r&512&&(lt||o===null||Da(o,o.return)),o&&o.stateNode!==null&&(o.stateNode._fragmentFiber=e);default:ao(t,e,a),oo(e)}}function oo(e){var t=e.flags;if(t&2){try{for(var a,o=e.return;o!==null;){if(OM(o)){a=o;break}o=o.return}o=null;for(var r=e.return;r!==null;){if(pR(r)){var n=r.stateNode;o===null?o=[n]:o.push(n)}if(mR(r))break;r=r.return}var s=o;if(a==null)throw Error(Z(160));switch(a.tag){case 27:var i=a.stateNode,l=cC(e);Pg(e,l,i,s);break;case 5:var u=a.stateNode;a.flags&32&&(Tc(u,""),a.flags&=-33);var c=cC(e);Pg(e,c,u,s);break;case 3:case 4:var d=a.stateNode.containerInfo,f=cC(e);rL(e,f,d,s);break;default:throw Error(Z(161))}}catch(m){dt(e,e.return,m)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function XM(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;XM(t),t.tag===5&&t.flags&1024&&(t=t.stateNode,kc=!0,t.reset(),kc=!1),e=e.sibling}}function Qu(e,t){if(t.subtreeFlags&9270)for(t=t.child;t!==null;)YM(t,e),t=t.sibling;else FM(t,!1)}function YM(e,t){var a=e.alternate;if(a===null)nL(e,!1);else switch(e.tag){case 3:if(uL=Jr=!1,iA(),Qu(t,e),!Jr&&!kg){if(e=tn,e!==null)for(var o=0;o<e.length;o+=3){a=e[o];var r=e[o+1];bP(a,e[o+2]),a=a.ownerDocument.documentElement,a!==null&&a.animate({opacity:[0,0],pointerEvents:["none","none"]},{duration:0,fill:"forwards",pseudoElement:"::view-transition-group("+r+")"})}e=t.containerInfo,e=e.nodeType===9?e.documentElement:e.ownerDocument.documentElement,e!==null&&e.style.viewTransitionName===""&&(e.style.viewTransitionName="none",e.animate({opacity:[0,0],pointerEvents:["none","none"]},{duration:0,fill:"forwards",pseudoElement:"::view-transition-group(root)"}),e.animate({width:[0,0],height:[0,0]},{duration:0,fill:"forwards",pseudoElement:"::view-transition"})),uL=!0}tn=null;break;case 5:Qu(t,e);break;case 4:o=Jr,Jr=!1,Qu(t,e),Jr&&(kg=!0),Jr=o;break;case 22:e.memoizedState===null&&(a.memoizedState!==null?nL(e,!1):Qu(t,e));break;case 30:o=Jr,r=iA(),Jr=!1,Qu(t,e),Jr&&(e.flags|=4);var n=e.memoizedProps,s=e.stateNode;t=Gn(n,s),s=Gn(a.memoizedProps,s);var i=Zn(n.default,n.update);i==="none"?t=!1:(n=a.memoizedState,a.memoizedState=null,a=e.child,vo=0,t=hR(e,a,t,s,i,n,!0),vo!==(n===null?0:n.length)&&(e.flags|=32)),(e.flags&4)!==0&&t?(Ec(e,e.memoizedProps.onUpdate),tn=r):r!==null&&(r.push.apply(r,tn),tn=r),Jr=(e.flags&32)!==0?!0:o;break;default:Qu(t,e)}}function $r(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)_M(e,t.alternate,t),t=t.sibling}function ws(e,t){for(e=e.child;e!==null;){var a=e,o=t;switch(a.tag){case 0:case 11:case 14:case 15:Zs(4,a,a.return),ws(a,o);break;case 1:Da(a,a.return);var r=a.stateNode;typeof r.componentWillUnmount=="function"&&PM(a,a.return,r),ws(a,o);break;case 27:(o&2)!==0&&AP(a.stateNode,a.type,a.memoizedProps);case 5:Da(a,a.return),a.tag!==5&&a.tag!==27||jd(a),ws(a,o);break;case 6:jd(a);break;case 26:Da(a,a.return),r=a.stateNode,a.memoizedState!==null||r===null||lt||r.parentNode.removeChild(r),ws(a,o);break;case 22:a.memoizedState===null&&ws(a,o);break;case 30:Da(a,a.return),ws(a,o);break;case 7:Da(a,a.return);default:ws(a,o)}e=e.sibling}}function Pr(e,t,a){for(a=(t.subtreeFlags&8772)!==0?a:a&-2,t=t.child;t!==null;){var o=t.alternate,r=e,n=t,s=n.flags,i=(a&1)!==0;switch(n.tag){case 0:case 11:case 15:Pr(r,n,a),Sm(4,n);break;case 1:if(Pr(r,n,a),o=n,r=o.stateNode,typeof r.componentDidMount=="function")try{r.componentDidMount()}catch(c){dt(o,o.return,c)}if(o=n,r=o.updateQueue,r!==null){var l=o.stateNode;try{var u=r.shared.hiddenCallbacks;if(u!==null)for(r.shared.hiddenCallbacks=null,r=0;r<u.length;r++)zD(u[r],l)}catch(c){dt(o,o.return,c)}}i&&s&64&&MM(n),en(n,n.return);break;case 27:(a&2)!==0&&kM(n);case 5:n.tag!==5&&n.tag!==27||nA(n),Pr(r,n,a),i&&o===null&&s&4&&oL(n),en(n,n.return);break;case 6:nA(n);break;case 26:l=n.stateNode,n.memoizedState!==null||l===null||ga||EL(im(l.ownerDocument),n.type,l),Pr(r,n,a),i&&o===null&&s&4&&oL(n),en(n,n.return);break;case 12:Pr(r,n,a);break;case 31:Pr(r,n,a),i&&s&4&&qM(r,n);break;case 13:Pr(r,n,a),i&&s&4&&GM(r,n);break;case 22:n.memoizedState===null&&Pr(r,n,a),en(n,n.return);break;case 30:Pr(r,n,a),en(n,n.return);break;case 7:en(n,n.return);default:Pr(r,n,a)}t=t.sibling}}function gR(e,t){var a=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(a=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==a&&(e!=null&&e.refCount++,a!=null&&xm(a))}function xR(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&xm(e))}function or(e,t,a,o){var r=(a&335544064)===a;if(t.subtreeFlags&(r?10262:10256))for(t=t.child;t!==null;)WM(e,t,a,o),t=t.sibling;else r&&BM(t)}function WM(e,t,a,o){var r=(a&335544064)===a;r&&t.alternate===null&&t.return!==null&&t.return.alternate!==null&&sg(t);var n=t.flags;switch(t.tag){case 0:case 11:case 15:or(e,t,a,o),n&2048&&Sm(9,t);break;case 1:or(e,t,a,o);break;case 3:or(e,t,a,o),r&&uL&&(e=e.containerInfo,e=e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,e.style.viewTransitionName==="root"&&(e.style.viewTransitionName=""),e=e.ownerDocument.documentElement,e!==null&&e.style.viewTransitionName==="none"&&(e.style.viewTransitionName="")),n&2048&&(n=null,t.alternate!==null&&(n=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==n&&(t.refCount++,n!=null&&xm(n)));break;case 12:if(n&2048){or(e,t,a,o),n=t.stateNode;try{var s=t.memoizedProps,i=s.id,l=s.onPostCommit;typeof l=="function"&&l(i,t.alternate===null?"mount":"update",n.passiveEffectDuration,-0)}catch(u){dt(t,t.return,u)}}else or(e,t,a,o);break;case 31:or(e,t,a,o);break;case 13:or(e,t,a,o);break;case 23:break;case 22:s=t.stateNode,i=t.alternate,t.memoizedState!==null?(r&&i!==null&&i.memoizedState===null&&sg(i),s._visibility&2?or(e,t,a,o):Xd(e,t)):(r&&i!==null&&i.memoizedState!==null&&sg(t),s._visibility&2?or(e,t,a,o):(s._visibility|=2,$u(e,t,a,o,(t.subtreeFlags&10256)!==0||!1))),n&2048&&gR(i,t);break;case 24:or(e,t,a,o),n&2048&&xR(t.alternate,t);break;case 30:r&&(n=t.alternate,n!==null&&(un(n.child,!0),un(t.child,!0))),or(e,t,a,o);break;default:or(e,t,a,o)}}function $u(e,t,a,o,r){for(r=r&&((t.subtreeFlags&10256)!==0||!1),t=t.child;t!==null;){var n=e,s=t,i=a,l=o,u=s.flags;switch(s.tag){case 0:case 11:case 15:$u(n,s,i,l,r),Sm(8,s);break;case 23:break;case 22:var c=s.stateNode;s.memoizedState!==null?c._visibility&2?$u(n,s,i,l,r):Xd(n,s):(c._visibility|=2,$u(n,s,i,l,r)),r&&u&2048&&gR(s.alternate,s);break;case 24:$u(n,s,i,l,r),r&&u&2048&&xR(s.alternate,s);break;default:$u(n,s,i,l,r)}t=t.sibling}}function Xd(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var a=e,o=t,r=o.flags;switch(o.tag){case 22:Xd(a,o),r&2048&&gR(o.alternate,o);break;case 24:Xd(a,o),r&2048&&xR(o.alternate,o);break;default:Xd(a,o)}t=t.sibling}}var fl=8192;function ll(e,t,a){if(e.subtreeFlags&fl)for(e=e.child;e!==null;)KM(e,t,a),e=e.sibling}function KM(e,t,a){switch(e.tag){case 26:ll(e,t,a),e.flags&fl&&(e.memoizedState!==null?w5(a,Or,e.memoizedState,e.memoizedProps):(e=e.stateNode,(t&335544128)===t&&kA(a,e)));break;case 5:ll(e,t,a),e.flags&fl&&(e=e.stateNode,(t&335544128)===t&&kA(a,e));break;case 3:case 4:var o=Or;Or=im(e.stateNode.containerInfo),ll(e,t,a),Or=o;break;case 22:e.memoizedState===null&&(o=e.alternate,o!==null&&o.memoizedState!==null?(o=fl,fl=16777216,ll(e,t,a),fl=o):ll(e,t,a));break;case 30:if((e.flags&fl)!==0&&(o=e.memoizedProps.name,o!=null&&o!=="auto")){var r=e.stateNode;r.paired=null,zo===null&&(zo=new Map),zo.set(o,r)}ll(e,t,a);break;default:ll(e,t,a)}}function ZM(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Ed(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var a=0;a<t.length;a++){var o=t[a];xa=o,JM(o,e)}ZM(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)QM(e),e=e.sibling}function QM(e){switch(e.tag){case 0:case 11:case 15:Ed(e),e.flags&2048&&Zs(9,e,e.return);break;case 3:Ed(e);break;case 12:Ed(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,ig(e)):Ed(e);break;default:Ed(e)}}function ig(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var a=0;a<t.length;a++){var o=t[a];xa=o,JM(o,e)}ZM(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Zs(8,t,t.return),ig(t);break;case 22:a=t.stateNode,a._visibility&2&&(a._visibility&=-3,ig(t));break;default:ig(t)}e=e.sibling}}function JM(e,t){for(;xa!==null;){var a=xa;switch(a.tag){case 0:case 11:case 15:Zs(8,a,t);break;case 23:case 22:if(a.memoizedState!==null&&a.memoizedState.cachePool!==null){var o=a.memoizedState.cachePool.pool;o!=null&&o.refCount++}break;case 24:xm(a.memoizedState.cache)}if(o=a.child,o!==null)o.return=a,xa=o;else e:for(a=e;xa!==null;){o=xa;var r=o.sibling,n=o.return;if(HM(o),o===a){xa=null;break e}if(r!==null){r.return=n,xa=r;break e}xa=n}}}var Rq={getCacheForType:function(e){var t=Pa(ta),a=t.data.get(e);return a===void 0&&(a=e(),t.data.set(e,a)),a},cacheSignal:function(){return Pa(ta).controller.signal}},Tq=typeof WeakMap=="function"?WeakMap:Map,rt=0,yt=null,Ye=null,We=0,ct=0,Bo=null,ks=!1,zc=!1,yR=!1,Wn=0,qt=0,Qs=0,yl=0,Ng=0,Ho=0,wc=0,Yd=null,bo=null,dL=!1,ox=0,$M=0,Vg=1/0,Bg=null,qs=null,Ft=0,Nr=null,Il=null,ln=0,mL=0,pL=null,eP=null,bc=null,vc=null,Cc=null,Wd=0,lg=null;function jo(){return(rt&2)!==0&&We!==0?We&-We:De.T!==null?bR():rD()}function tP(){if(Ho===0)if((We&536870912)===0||Ge){var e=Dh;Dh<<=1,(Dh&3932160)===0&&(Dh=262144),Ho=e}else Ho=536870912;return e=Va.current,e!==null&&(e.flags|=32),Ho}function Ec(e,t){if(t!=null){var a=e.stateNode,o=a.ref;o===null&&(o=a.ref=CP(Gn(e.memoizedProps,a))),vc===null&&(vc=[]),vc.push(t.bind(null,o))}}function Lo(e,t,a){(e===yt&&(ct===2||ct===9)||e.cancelPendingCommit!==null)&&(Ac(e,0),Ns(e,We,Ho,!1)),pm(e,a),((rt&2)===0||e!==yt)&&(e===yt&&((rt&2)===0&&(yl|=a),qt===4&&Ns(e,We,Ho,!1)),fn(e))}function aP(e,t,a){if((rt&6)!==0)throw Error(Z(327));var o=!a&&(t&127)===0&&(t&e.expiredLanes)===0||mm(e,t),r=o?Eq(e,t):dC(e,t,!0),n=o;do{if(r===0){zc&&!o&&Ns(e,t,0,!1);break}else{if(a=e.current.alternate,n&&!Iq(a)){r=dC(e,t,!1),n=!1;continue}if(r===2){if(n=t,e.errorRecoveryDisabledLanes&n)var s=0;else s=e.pendingLanes&-536870913,s=s!==0?s:s&536870912?536870912:0;if(s!==0){t=s;e:{var i=e;r=Yd;var l=i.current.memoizedState.isDehydrated;if(l&&(Ac(i,s).flags|=256),s=dC(i,s,!1),s!==2&&s!==6){if(yR&&!l){i.errorRecoveryDisabledLanes|=n,yl|=n,r=4;break e}n=bo,bo=r,n!==null&&(bo===null?bo=n:bo.push.apply(bo,n))}r=s}if(n=!1,r!==2)continue}}if(r===1){Ac(e,0),Ns(e,t,0,!0);break}e:{switch(o=e,n=r,n){case 0:case 1:throw Error(Z(345));case 4:if((t&4194048)!==t&&(t&62914560)!==t)break;case 6:Ns(o,t,Ho,!ks);break e;case 2:bo=null;break;case 3:case 5:break;default:throw Error(Z(329))}if((t&62914560)===t&&(r=ox+300-Uo(),10<r)){if(Ns(o,t,Ho,!ks),qg(o,0,!0)!==0)break e;ln=t,o.timeoutHandle=CR(uA.bind(null,o,a,bo,Bg,dL,t,Ho,yl,wc,ks,n,"Throttled",-0,0),r);break e}uA(o,a,bo,Bg,dL,t,Ho,yl,wc,ks,n,null,-0,0)}}break}while(!0);fn(e)}function uA(e,t,a,o,r,n,s,i,l,u,c,d,f,m){e.timeoutHandle=-1;var p=t.subtreeFlags,y=(n&335544064)===n;if(d=null,(y||p&8192||(p&16785408)===16785408)&&(d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:on},zo=null,KM(t,n,d),y&&(p=d,y=e.containerInfo,y=(y.nodeType===9?y:y.ownerDocument).__reactViewTransition,y!=null&&(p.count++,p.waitingForViewTransition=!0,p=lm.bind(p),y.finished.then(p,p))),p=(n&62914560)===n?ox-Uo():(n&4194048)===n?$M-Uo():0,p=E5(d,p),p!==null)){ln=n,e.cancelPendingCommit=p(fA.bind(null,e,t,n,a,o,r,s,i,l,u,c,d,null,f,m)),Ns(e,n,s,!u);return}fA(e,t,n,a,o,r,s,i,l,u,c,d)}function Iq(e){for(var t=e;;){var a=t.tag;if((a===0||a===11||a===15)&&t.flags&16384&&(a=t.updateQueue,a!==null&&(a=a.stores,a!==null)))for(var o=0;o<a.length;o++){var r=a[o],n=r.getSnapshot;r=r.value;try{if(!Xo(n(),r))return!1}catch{return!1}}if(a=t.child,t.subtreeFlags&16384&&a!==null)a.return=t,t=a;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Ns(e,t,a,o){t=$A(e,t),t&=~Ng,t&=~yl,e.suspendedLanes|=t,e.pingedLanes&=~t,o&&(e.warmLanes|=t),o=e.expirationTimes;for(var r=t;0<r;){var n=31-Go(r),s=1<<n;o[n]=-1,r&=~s}a!==0&&tD(e,a,t)}function rx(){return(rt&6)===0?(bm(0,!1),!1):!0}function SR(){if(Ye!==null){if(ct===0)var e=Ye.return;else e=Ye,zn=Ml=null,aR(e),xc=null,tm=0,e=Ye;for(;e!==null;)DM(e.alternate,e),e=e.return;Ye=null}}function Ac(e,t){var a=e.timeoutHandle;return a!==-1&&(e.timeoutHandle=-1,Wq(a)),a=e.cancelPendingCommit,a!==null&&(e.cancelPendingCommit=null,a()),ln=0,SR(),yt=e,Ye=a=Hn(e.current,null),We=t,ct=0,Bo=null,ks=!1,zc=mm(e,t),yR=!1,wc=Ho=Ng=yl=Qs=qt=0,bo=Yd=null,dL=!1,Wn=$A(e,t),Wg(),a}function oP(e,t){_e=null,De.H=Ag,t===Fc||t===Qg?(t=VE(),ct=3):t===WL?(t=VE(),ct=4):ct=t===cR?8:t!==null&&typeof t=="object"&&typeof t.then=="function"?6:1,Bo=t,Ye===null&&(qt=1,Dg(e,lr(t,e.current)))}function rP(){var e=Va.current;return e===null?!0:(We&4194048)===We?Ga===null:(We&62914560)===We||(We&536870912)!==0?e===Ga:!1}function nP(){var e=De.H;return De.H=Ag,e===null?Ag:e}function sP(){var e=De.A;return De.A=Rq,e}function Fg(){qt=4,ks||(We&4194048)!==We&&Va.current!==null||(zc=!0),(Qs&134217727)===0&&(yl&134217727)===0||yt===null||Ns(yt,We,Ho,!1)}function dC(e,t,a){var o=rt;rt|=2;var r=nP(),n=sP();(yt!==e||We!==t)&&(Bg=null,Ac(e,t)),t=!1;var s=qt;e:do try{if(ct!==0&&Ye!==null){var i=Ye,l=Bo;switch(ct){case 8:SR(),s=6;break e;case 3:case 2:case 9:case 6:Va.current===null&&(t=!0);var u=ct;if(ct=0,Bo=null,dc(e,i,l,u),a&&zc){s=0;break e}break;default:u=ct,ct=0,Bo=null,dc(e,i,l,u)}}wq(),s=qt;break}catch(c){oP(e,c)}while(!0);return t&&e.shellSuspendCounter++,zn=Ml=null,rt=o,De.H=r,De.A=n,Ye===null&&(yt=null,We=0,Wg()),s}function wq(){for(;Ye!==null;)iP(Ye)}function Eq(e,t){var a=rt;rt|=2;var o=nP(),r=sP();yt!==e||We!==t?(Bg=null,Vg=Uo()+500,Ac(e,t)):zc=mm(e,t);e:do try{if(ct!==0&&Ye!==null){t=Ye;var n=Bo;t:switch(ct){case 1:ct=0,Bo=null,dc(e,t,n,1);break;case 2:case 9:if(NE(n)){ct=0,Bo=null,cA(t);break}t=function(){ct!==2&&ct!==9||yt!==e||(ct=7),fn(e)},n.then(t,t);break e;case 3:ct=7;break e;case 4:ct=5;break e;case 7:NE(n)?(ct=0,Bo=null,cA(t)):(ct=0,Bo=null,dc(e,t,n,7));break;case 5:var s=null;switch(Ye.tag){case 26:s=Ye.memoizedState;case 5:case 27:var i=Ye;if(s?PP(s):i.stateNode.complete){ct=0,Bo=null;var l=i.sibling;if(l!==null)Ye=l;else{var u=i.return;u!==null?(Ye=u,nx(u)):Ye=null}break t}}ct=0,Bo=null,dc(e,t,n,5);break;case 6:ct=0,Bo=null,dc(e,t,n,6);break;case 8:SR(),qt=6;break e;default:throw Error(Z(462))}}Aq();break}catch(c){oP(e,c)}while(!0);return zn=Ml=null,De.H=o,De.A=r,rt=a,Ye!==null?0:(yt=null,We=0,Wg(),qt)}function Aq(){for(;Ye!==null&&!X3();)iP(Ye)}function iP(e){var t=AM(e.alternate,e,Wn);e.memoizedProps=e.pendingProps,t===null?nx(e):Ye=t}function cA(e){var t=e,a=t.alternate;switch(t.tag){case 15:case 0:t=JE(a,t,t.pendingProps,t.type,void 0,We);break;case 11:t=JE(a,t,t.pendingProps,t.type.render,t.ref,We);break;case 5:aR(t);var o=t;o===Sa&&(Ge?(Cg(o),o.tag===5&&o.stateNode!=null&&(Lt=o.stateNode)):(Cg(o),Ge=!0));default:DM(a,t),t=Ye=MD(t,Wn),t=AM(a,t,Wn)}e.memoizedProps=e.pendingProps,t===null?nx(e):Ye=t}function dc(e,t,a,o){zn=Ml=null,aR(t),xc=null,tm=0;var r=t.return;try{if(gq(e,r,t,a,We)){qt=1,Dg(e,lr(a,e.current)),Ye=null;return}}catch(n){if(r!==null)throw Ye=r,n;qt=1,Dg(e,lr(a,e.current)),Ye=null;return}t.flags&32768?(Ge||o===1?e=!0:zc||(We&536870912)!==0?e=!1:(ks=e=!0,(o===2||o===9||o===3||o===6)&&(o=Va.current,o!==null&&o.tag===13&&(o.flags|=16384))),lP(t,e)):nx(t)}function nx(e){var t=e;do{if((t.flags&32768)!==0){lP(t,ks);return}e=t.return;var a=bq(t.alternate,t,Wn);if(a!==null){Ye=a;return}if(t=t.sibling,t!==null){Ye=t;return}Ye=t=e}while(t!==null);qt===0&&(qt=5)}function lP(e,t){do{var a=vq(e.alternate,e);if(a!==null){a.flags&=32767,Ye=a;return}if(a=e.return,a!==null&&(a.flags|=32768,a.subtreeFlags=0,a.deletions=null),!t&&(e=e.sibling,e!==null)){Ye=e;return}Ye=e=a}while(e!==null);qt=6,Ye=null}function fA(e,t,a,o,r,n,s,i,l,u,c,d){e.cancelPendingCommit=null;do sx();while(Ft!==0);if((rt&6)!==0)throw Error(Z(327));if(t!==null){if(t===e.current)throw Error(Z(177));e===yt&&(Ye=yt=null,We=0),Il=t,Nr=e,ln=a,pL=r,eP=o,Dq(e,t,a,s,i,l,d)}}function Dq(e,t,a,o,r,n,s){var i=t.lanes|t.childLanes;if(mL=i,i|=UL,a4(e,a,i,o,r,n),vc=null,(a&335544064)===a?(Cc=rq(e),o=10262):(Cc=null,o=10256),(t.subtreeFlags&o)!==0||(t.flags&o)!==0?(e.callbackNode=null,e.callbackPriority=0,Vq(xg,function(){return yL(),null})):(e.callbackNode=null,e.callbackPriority=0),Og=!1,o=(t.flags&13878)!==0,(t.subtreeFlags&13878)!==0||o){o=De.T,De.T=null,r=nt.p,nt.p=2,n=rt,rt|=4;try{Cq(e,t,a)}finally{rt=n,nt.p=r,De.T=o}}Ft=1,Og?bc=e5(s,e.containerInfo,Cc,hL,gL,Pq,xL,yL,Mq,null,null):(hL(),gL(),xL())}function Mq(e){if(Ft!==0){var t=Nr.onRecoverableError;t(e,{componentStack:null})}}function Pq(){Ft===3&&(Ft=0,YM(Il,Nr),Ft=4)}function hL(){if(Ft===1){Ft=0;var e=Nr,t=Il,a=ln,o=(t.flags&13878)!==0;if((t.subtreeFlags&13878)!==0||o){o=De.T,De.T=null;var r=nt.p;nt.p=2;var n=rt;rt|=4;try{Nd=kg=!1,jM(t,e,a),a=CL;var s=LD(e.containerInfo),i=a.focusedElem,l=a.selectionRange;if(s!==i&&i&&i.ownerDocument&&CD(i.ownerDocument.documentElement,i)){if(l!==null&&HL(i)){var u=l.start,c=l.end;if(c===void 0&&(c=u),"selectionStart"in i)i.selectionStart=u,i.selectionEnd=Math.min(c,i.value.length);else{var d=i.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var m=f.getSelection(),p=i.textContent.length,y=Math.min(l.start,p),b=l.end===void 0?y:Math.min(l.end,p);!m.extend&&y>b&&(s=b,b=y,y=s);var g=wE(i,y),h=wE(i,b);if(g&&h&&(m.rangeCount!==1||m.anchorNode!==g.node||m.anchorOffset!==g.offset||m.focusNode!==h.node||m.focusOffset!==h.offset)){var x=d.createRange();x.setStart(g.node,g.offset),m.removeAllRanges(),y>b?(m.addRange(x),m.extend(h.node,h.offset)):(x.setEnd(h.node,h.offset),m.addRange(x))}}}}for(d=[],m=i;m=m.parentNode;)m.nodeType===1&&d.push({element:m,left:m.scrollLeft,top:m.scrollTop});for(typeof i.focus=="function"&&i.focus(),i=0;i<d.length;i++){var S=d[i];S.element.scrollLeft=S.left,S.element.scrollTop=S.top}}kc=!!vL,CL=vL=null}finally{rt=n,nt.p=r,De.T=o}}e.current=t,Ft=2}}function gL(){if(Ft===2){Ft=0;var e=Nr,t=Il,a=(t.flags&8772)!==0;if((t.subtreeFlags&8772)!==0||a){a=De.T,De.T=null;var o=nt.p;nt.p=2;var r=rt;rt|=4;try{_M(e,t.alternate,t)}finally{rt=r,nt.p=o,De.T=a}}Ft=3}}function xL(){if(Ft===4||Ft===3){Ft=0;var e=bc;bc=null,Y3();var t=Nr,a=Il,o=ln,r=eP,n=(o&335544064)===o?10262:10256;if((a.subtreeFlags&n)!==0||(a.flags&n)!==0?Ft=5:(Ft=0,Il=Nr=null,uP(t,t.pendingLanes)),n=t.pendingLanes,n===0&&(qs=null),NL(o),a=a.stateNode,qo&&typeof qo.onCommitFiberRoot=="function")try{qo.onCommitFiberRoot(dm,a,void 0,(a.current.flags&128)===128)}catch{}if(r!==null){a=De.T,n=nt.p,nt.p=2,De.T=null;try{for(var s=t.onRecoverableError,i=0;i<r.length;i++){var l=r[i];s(l.value,{componentStack:l.stack})}}finally{De.T=a,nt.p=n}}if(r=vc,s=Cc,Cc=null,r!==null&&(vc=null,s===null&&(s=[]),e!==null))for(l=0;l<r.length;l++)a=(0,r[l])(s),a!==void 0&&e.finished.finally(a);(ln&3)!==0&&sx(),fn(t),n=t.pendingLanes,(o&261930)!==0&&(n&42)!==0?t===lg?Wd++:(Wd=0,lg=t):(Wd=0,lg=null),bm(0,!1)}}function uP(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,xm(t)))}function sx(){return bc!==null&&(bc.skipTransition(),bc=null),hL(),gL(),xL(),yL()}function yL(){if(Ft!==5)return!1;var e=Nr,t=mL;mL=0;var a=NL(ln),o=De.T,r=nt.p;try{nt.p=32>a?32:a,De.T=null,a=pL,pL=null;var n=Nr,s=ln;if(Ft=0,Il=Nr=null,ln=0,(rt&6)!==0)throw Error(Z(331));var i=rt;if(rt|=4,QM(n.current),WM(n,n.current,s,a),rt=i,bm(0,!1),qo&&typeof qo.onPostCommitFiberRoot=="function")try{qo.onPostCommitFiberRoot(dm,n)}catch{}return!0}finally{nt.p=r,De.T=o,uP(e,t)}}function dA(e,t,a){t=lr(a,t),t=QC(e.stateNode,t,2),e=zs(e,t,2),e!==null&&(pm(e,2),fn(e))}function dt(e,t,a){if(e.tag===3)dA(e,e,a);else for(;t!==null;){if(t.tag===3){dA(t,e,a);break}else if(t.tag===1){var o=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof o.componentDidCatch=="function"&&(qs===null||!qs.has(o))){e=lr(a,e),a=RM(2),o=zs(t,a,2),o!==null&&(TM(a,o,t,e),pm(o,2),fn(o));break}}t=t.return}}function mC(e,t,a){var o=e.pingCache;if(o===null){o=e.pingCache=new Tq;var r=new Set;o.set(t,r)}else r=o.get(t),r===void 0&&(r=new Set,o.set(t,r));r.has(a)||(yR=!0,r.add(a),e=Oq.bind(null,e,t,a),t.then(e,e))}function Oq(e,t,a){var o=e.pingCache;o!==null&&o.delete(t),e.pingedLanes|=e.suspendedLanes&a,e.warmLanes&=~a,yt===e&&(We&a)===a&&((qt===4||qt===3&&(We&62914560)===We&&300>Uo()-ox)&&(rt&2)===0?Ac(e,0):Ng|=a,wc===We&&(wc=0)),fn(e)}function cP(e,t){t===0&&(t=eD()),e=Dl(e,t),e!==null&&(pm(e,t),fn(e))}function kq(e){var t=e.memoizedState,a=0;t!==null&&(a=t.retryLane),cP(e,a)}function Nq(e,t){var a=0;switch(e.tag){case 31:case 13:var o=e.stateNode,r=e.memoizedState;r!==null&&(a=r.retryLane);break;case 19:o=e.stateNode;break;case 22:o=e.stateNode._retryCache;break;default:throw Error(Z(314))}o!==null&&o.delete(t),cP(e,a)}function Vq(e,t){return OL(e,t)}var Dc=null,ec=null,SL=!1,_g=!1,pC=!1,Vs=0;function fn(e){e!==ec&&e.next===null&&(ec===null?Dc=ec=e:ec=ec.next=e),_g=!0,SL||(SL=!0,Fq())}function bm(e,t){if(!pC&&_g){pC=!0;do for(var a=!1,o=Dc;o!==null;){if(!t)if(e!==0){var r=o.pendingLanes;if(r===0)var n=0;else{var s=o.suspendedLanes,i=o.pingedLanes;n=(1<<31-Go(42|e)+1)-1,n&=r&~(s&~i),n=n&201326741?n&201326741|1:n?n|2:0}n!==0&&(a=!0,mA(o,n))}else n=We,n=qg(o,o===yt?n:0,o.cancelPendingCommit!==null||o.timeoutHandle!==-1),(n&3)===0||mm(o,n)||(a=!0,mA(o,n));o=o.next}while(a);pC=!1}}function Bq(){fP()}function fP(){_g=SL=!1;var e=0;Vs!==0&&Yq()&&(e=Vs);for(var t=Uo(),a=null,o=Dc;o!==null;){var r=o.next,n=dP(o,t);n===0?(o.next=null,a===null?Dc=r:a.next=r,r===null&&(ec=a)):(a=o,(e!==0||(n&3)!==0)&&(_g=!0)),o=r}Ft!==0&&Ft!==5||bm(e,!1),Vs!==0&&(Vs=0)}function dP(e,t){for(var a=e.suspendedLanes,o=e.pingedLanes,r=e.expirationTimes,n=e.pendingLanes&-62914561;0<n;){var s=31-Go(n),i=1<<s,l=r[s];l===-1?((i&a)===0||(i&o)!==0)&&(r[s]=t4(i,t)):l<=t&&(e.expiredLanes|=i),n&=~i}if(t=yt,a=We,a=qg(e,e===t?a:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),o=e.callbackNode,a===0||e===t&&(ct===2||ct===9)||e.cancelPendingCommit!==null)return o!==null&&o!==null&&Xv(o),e.callbackNode=null,e.callbackPriority=0;if((a&3)===0||mm(e,a)){if(t=a&-a,t===e.callbackPriority)return t;switch(o!==null&&Xv(o),NL(a)){case 2:case 8:a=QA;break;case 32:a=xg;break;case 268435456:a=JA;break;default:a=xg}return o=mP.bind(null,e),a=OL(a,o),e.callbackPriority=t,e.callbackNode=a,t}return o!==null&&o!==null&&Xv(o),e.callbackPriority=2,e.callbackNode=null,2}function mP(e,t){if(Ft!==0&&Ft!==5)return e.callbackNode=null,e.callbackPriority=0,null;var a=e.callbackNode;if(sx()&&e.callbackNode!==a)return null;var o=We;return o=qg(e,e===yt?o:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),o===0?null:(aP(e,o,t),dP(e,Uo()),e.callbackNode!=null&&e.callbackNode===a?mP.bind(null,e):null)}function mA(e,t){if(sx())return null;aP(e,t,!0)}function Fq(){Kq(function(){(rt&6)!==0?OL(ZA,Bq):fP()})}function bR(){if(Vs===0){var e=Cl;e===0&&(e=Ah,Ah<<=1,(Ah&261888)===0&&(Ah=256)),Vs=e}return Vs}function pA(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:Zh(e)}function _q(e,t,a,o,r){if(t==="submit"&&a&&a.stateNode===r){var n=pA((r[To]||null).action),s=o.submitter;s&&(t=(t=s[To]||null)?pA(t.formAction):s.getAttribute("formAction"),t!==null&&(n=t,s=null));var i=new jg("action","action",null,o,r);e.push({event:i,listeners:[{instance:null,listener:function(){if(o.defaultPrevented){if(Vs!==0){var l=new FormData(r,s);KC(a,{pending:!0,data:l,method:r.method,action:n},null,l)}}else typeof n=="function"&&(i.preventDefault(),l=new FormData(r,s),KC(a,{pending:!0,data:l,method:r.method,action:n},n,l))},currentTarget:r}]})}}for(Gh=0;Gh<FC.length;Gh++)jh=FC[Gh],hA=jh.toLowerCase(),gA=jh[0].toUpperCase()+jh.slice(1),Vr(hA,"on"+gA);var jh,hA,gA,Gh;Vr(TD,"onAnimationEnd");Vr(ID,"onAnimationIteration");Vr(wD,"onAnimationStart");Vr("dblclick","onDoubleClick");Vr("focusin","onFocus");Vr("focusout","onBlur");Vr(Z4,"onTransitionRun");Vr(Q4,"onTransitionStart");Vr(J4,"onTransitionCancel");Vr(ED,"onTransitionEnd");Rc("onMouseEnter",["mouseout","mouseover"]);Rc("onMouseLeave",["mouseout","mouseover"]);Rc("onPointerEnter",["pointerout","pointerover"]);Rc("onPointerLeave",["pointerout","pointerover"]);El("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));El("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));El("onBeforeInput",["compositionend","keypress","textInput","paste"]);El("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));El("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));El("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var rm="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),zq=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(rm));function pP(e,t){t=(t&4)!==0;for(var a=0;a<e.length;a++){var o=e[a],r=o.event;o=o.listeners;e:{var n=void 0;if(t)for(var s=o.length-1;0<=s;s--){var i=o[s],l=i.instance,u=i.currentTarget;if(i=i.listener,l!==n&&r.isPropagationStopped())break e;n=i,r.currentTarget=u;try{n(r)}catch(c){Sg(c)}r.currentTarget=null,n=l}else for(s=0;s<o.length;s++){if(i=o[s],l=i.instance,u=i.currentTarget,i=i.listener,l!==n&&r.isPropagationStopped())break e;n=i,r.currentTarget=u;try{n(r)}catch(c){Sg(c)}r.currentTarget=null,n=l}}}}function Xe(e,t){var a=t[cE];a===void 0&&(a=t[cE]=new Set);var o=e+"__bubble";a.has(o)||(hP(t,e,2,!1),a.add(o))}function hC(e,t,a){var o=0;t&&(o|=4),hP(a,e,o,t)}var Xh="_reactListening"+Math.random().toString(36).slice(2);function vR(e){if(!e[Xh]){e[Xh]=!0,sD.forEach(function(a){a!=="selectionchange"&&(zq.has(a)||hC(a,!1,e),hC(a,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Xh]||(t[Xh]=!0,hC("selectionchange",!1,t))}}function hP(e,t,a,o){switch(_P(t)){case 2:var r=P5;break;case 8:r=O5;break;default:r=ER}a=r.bind(null,t,a,e),r=void 0,!kC||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(r=!0),o?r!==void 0?e.addEventListener(t,a,{capture:!0,passive:r}):e.addEventListener(t,a,!0):r!==void 0?e.addEventListener(t,a,{passive:r}):e.addEventListener(t,a,!1)}function gC(e,t,a,o,r){var n=o;if((t&1)===0&&(t&2)===0&&o!==null)e:for(;;){if(o===null)return;var s=o.tag;if(s===3||s===4){var i=o.stateNode.containerInfo;if(i===r)break;if(s===4)for(s=o.return;s!==null;){var l=s.tag;if((l===3||l===4)&&s.stateNode.containerInfo===r)return;s=s.return}for(;i!==null;){if(s=dl(i),s===null)return;if(l=s.tag,l===5||l===6||l===26||l===27){o=n=s;continue e}i=i.parentNode}}o=o.return}pD(function(){var u=n,c=BL(a),d=[];e:{var f=AD.get(e);if(f!==void 0){var m=jg,p=e;switch(e){case"keypress":if(Jh(a)===0)break e;case"keydown":case"keyup":m=I4;break;case"focusin":p="focus",m=Jv;break;case"focusout":p="blur",m=Jv;break;case"beforeblur":case"afterblur":m=Jv;break;case"click":if(a.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":m=yE;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":m=p4;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":m=M4;break;case TD:case ID:case wD:m=x4;break;case ED:m=O4;break;case"scroll":case"scrollend":m=d4;break;case"wheel":m=N4;break;case"copy":case"cut":case"paste":m=S4;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":m=bE;break;case"submit":m=A4;break;case"toggle":case"beforetoggle":m=B4}var y=(t&4)!==0,b=!y&&(e==="scroll"||e==="scrollend"),g=y?f!==null?f+"Capture":null:f;y=[];for(var h=u,x;h!==null;){var S=h;if(x=S.stateNode,S=S.tag,S!==5&&S!==26&&S!==27||x===null||g===null||(S=Zd(h,g),S!=null&&y.push(nm(h,S,x))),b)break;h=h.return}0<y.length&&(f=new m(f,p,null,a,c),d.push({event:f,listeners:y}))}}if((t&7)===0){e:{if(m=e==="mouseover"||e==="pointerover",f=e==="mouseout"||e==="pointerout",m&&a!==OC&&(p=a.relatedTarget||a.fromElement)&&(dl(p)||p[Vc]))break e;(f||m)&&(p=c.window===c?c:(m=c.ownerDocument)?m.defaultView||m.parentWindow:window,f?(m=a.relatedTarget||a.toElement,f=u,m=m?dl(m):null,m!==null&&(b=fm(m),y=m.tag,m!==b||y!==5&&y!==27&&y!==6)&&(m=null)):(f=null,m=u),f!==m&&(y=yE,S="onMouseLeave",g="onMouseEnter",h="mouse",(e==="pointerout"||e==="pointerover")&&(y=bE,S="onPointerLeave",g="onPointerEnter",h="pointer"),b=f==null?p:Od(f),x=m==null?p:Od(m),p=new y(S,h+"leave",f,a,c),p.target=b,p.relatedTarget=x,S=null,dl(c)===u&&(y=new y(g,h+"enter",m,a,c),y.target=x,y.relatedTarget=b,S=y),b=S,y=f&&m?vC(f,m,Hq):null,f!==null&&xA(d,p,f,y,!1),m!==null&&b!==null&&xA(d,b,m,y,!0)))}e:{if(f=u?Od(u):window,m=f.nodeName&&f.nodeName.toLowerCase(),m==="select"||m==="input"&&f.type==="file")var v=RE;else if(LE(f))if(bD)v=Y4;else{v=j4;var R=G4}else m=f.nodeName,!m||m.toLowerCase()!=="input"||f.type!=="checkbox"&&f.type!=="radio"?u&&VL(u.elementType)&&(v=RE):v=X4;if(v&&(v=v(e,u))){SD(d,v,a,c);break e}R&&R(e,f,u)}switch(R=u?Od(u):window,e){case"focusin":(LE(R)||R.contentEditable==="true")&&(sc=R,VC=u,Fd=null);break;case"focusout":Fd=VC=sc=null;break;case"mousedown":BC=!0;break;case"contextmenu":case"mouseup":case"dragend":BC=!1,EE(d,a,c);break;case"selectionchange":if(K4)break;case"keydown":case"keyup":EE(d,a,c)}var L;if(zL)e:{switch(e){case"compositionstart":var C="onCompositionStart";break e;case"compositionend":C="onCompositionEnd";break e;case"compositionupdate":C="onCompositionUpdate";break e}C=void 0}else nc?xD(e,a)&&(C="onCompositionEnd"):e==="keydown"&&a.keyCode===229&&(C="onCompositionStart");C&&(gD&&a.locale!=="ko"&&(nc||C!=="onCompositionStart"?C==="onCompositionEnd"&&nc&&(L=hD()):(Ps=c,FL="value"in Ps?Ps.value:Ps.textContent,nc=!0)),R=zg(u,C),0<R.length&&(C=new SE(C,e,null,a,c),d.push({event:C,listeners:R}),L?C.data=L:(L=yD(a),L!==null&&(C.data=L)))),(L=_4?z4(e,a):H4(e,a))&&(C=zg(u,"onBeforeInput"),0<C.length&&(R=new SE("onBeforeInput","beforeinput",null,a,c),d.push({event:R,listeners:C}),R.data=L)),_q(d,e,u,a,c)}pP(d,t)})}function nm(e,t,a){return{instance:e,listener:t,currentTarget:a}}function zg(e,t){for(var a=t+"Capture",o=[];e!==null;){var r=e,n=r.stateNode;if(r=r.tag,r!==5&&r!==26&&r!==27||n===null||(r=Zd(e,a),r!=null&&o.unshift(nm(e,r,n)),r=Zd(e,t),r!=null&&o.push(nm(e,r,n))),e.tag===3)return o;e=e.return}return[]}function Hq(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function xA(e,t,a,o,r){for(var n=t._reactName,s=[];a!==null&&a!==o;){var i=a,l=i.alternate,u=i.stateNode;if(i=i.tag,l!==null&&l===o)break;i!==5&&i!==26&&i!==27||u===null||(l=u,r?(u=Zd(a,n),u!=null&&s.unshift(nm(a,u,l))):r||(u=Zd(a,n),u!=null&&s.push(nm(a,u,l)))),a=a.return}s.length!==0&&e.push({event:t,listeners:s})}var Uq=/\r\n?/g,qq=/\u0000|\uFFFD/g;function yA(e){return(typeof e=="string"?e:""+e).replace(Uq,`
|
|
9
|
+
`).replace(qq,"")}function gP(e,t){return t=yA(t),yA(e)===t}function ft(e,t,a,o,r,n){switch(a){case"children":if(typeof o=="string")t==="body"||t==="textarea"&&o===""||Tc(e,o);else if(typeof o=="number"||typeof o=="bigint")t!=="body"&&Tc(e,""+o);else return;break;case"className":Ph(e,"class",o);break;case"tabIndex":Ph(e,"tabindex",o);break;case"dir":case"role":case"viewBox":case"width":case"height":Ph(e,a,o);break;case"style":mD(e,o,n);return;case"data":if(t!=="object"){Ph(e,"data",o);break}case"src":case"href":if(o===""&&(t!=="a"||a!=="href")){e.removeAttribute(a);break}if(o==null||typeof o=="function"||typeof o=="symbol"||typeof o=="boolean"){e.removeAttribute(a);break}o=Zh(o),e.setAttribute(a,o);break;case"action":case"formAction":if(typeof o=="function"){e.setAttribute(a,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof n=="function"&&(a==="formAction"?(t!=="input"&&ft(e,t,"name",r.name,r,null),ft(e,t,"formEncType",r.formEncType,r,null),ft(e,t,"formMethod",r.formMethod,r,null),ft(e,t,"formTarget",r.formTarget,r,null)):(ft(e,t,"encType",r.encType,r,null),ft(e,t,"method",r.method,r,null),ft(e,t,"target",r.target,r,null)));if(o==null||typeof o=="symbol"||typeof o=="boolean"){e.removeAttribute(a);break}o=Zh(o),e.setAttribute(a,o);break;case"onClick":o!=null&&(e.onclick=on);return;case"onScroll":o!=null&&Xe("scroll",e);return;case"onScrollEnd":o!=null&&Xe("scrollend",e);return;case"dangerouslySetInnerHTML":if(o!=null){if(typeof o!="object"||!("__html"in o))throw Error(Z(61));if(a=o.__html,a!=null){if(r.children!=null)throw Error(Z(60));n?.__html!==a&&(e.innerHTML=a)}}break;case"multiple":e.multiple=o&&typeof o!="function"&&typeof o!="symbol";break;case"muted":e.muted=o&&typeof o!="function"&&typeof o!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(o==null||typeof o=="function"||typeof o=="boolean"||typeof o=="symbol"){e.removeAttribute("xlink:href");break}a=Zh(o),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",a);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":o!=null&&typeof o!="function"&&typeof o!="symbol"?e.setAttribute(a,o):e.removeAttribute(a);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"credentialless":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":o&&typeof o!="function"&&typeof o!="symbol"?e.setAttribute(a,""):e.removeAttribute(a);break;case"capture":case"download":o===!0?e.setAttribute(a,""):o!==!1&&o!=null&&typeof o!="function"&&typeof o!="symbol"?e.setAttribute(a,o):e.removeAttribute(a);break;case"cols":case"rows":case"size":case"span":o!=null&&typeof o!="function"&&typeof o!="symbol"&&!isNaN(o)&&1<=o?e.setAttribute(a,o):e.removeAttribute(a);break;case"rowSpan":case"start":o==null||typeof o=="function"||typeof o=="symbol"||isNaN(o)?e.removeAttribute(a):e.setAttribute(a,o);break;case"popover":Xe("beforetoggle",e),Xe("toggle",e),Kh(e,"popover",o);break;case"xlinkActuate":Bn(e,"http://www.w3.org/1999/xlink","xlink:actuate",o);break;case"xlinkArcrole":Bn(e,"http://www.w3.org/1999/xlink","xlink:arcrole",o);break;case"xlinkRole":Bn(e,"http://www.w3.org/1999/xlink","xlink:role",o);break;case"xlinkShow":Bn(e,"http://www.w3.org/1999/xlink","xlink:show",o);break;case"xlinkTitle":Bn(e,"http://www.w3.org/1999/xlink","xlink:title",o);break;case"xlinkType":Bn(e,"http://www.w3.org/1999/xlink","xlink:type",o);break;case"xmlBase":Bn(e,"http://www.w3.org/XML/1998/namespace","xml:base",o);break;case"xmlLang":Bn(e,"http://www.w3.org/XML/1998/namespace","xml:lang",o);break;case"xmlSpace":Bn(e,"http://www.w3.org/XML/1998/namespace","xml:space",o);break;case"is":Kh(e,"is",o);break;case"innerText":case"textContent":return;default:if(!(2<a.length)||a[0]!=="o"&&a[0]!=="O"||a[1]!=="n"&&a[1]!=="N")a=c4.get(a)||a,Kh(e,a,o);else return}tt=!0}function bL(e,t,a,o,r,n){switch(a){case"style":mD(e,o,n);return;case"dangerouslySetInnerHTML":if(o!=null){if(typeof o!="object"||!("__html"in o))throw Error(Z(61));if(a=o.__html,a!=null){if(r.children!=null)throw Error(Z(60));n?.__html!==a&&(e.innerHTML=a)}}break;case"children":if(typeof o=="string")Tc(e,o);else if(typeof o=="number"||typeof o=="bigint")Tc(e,""+o);else return;break;case"onScroll":o!=null&&Xe("scroll",e);return;case"onScrollEnd":o!=null&&Xe("scrollend",e);return;case"onClick":o!=null&&(e.onclick=on);return;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":return;case"innerText":case"textContent":return;default:if(!iD.hasOwnProperty(a))e:{if(a[0]==="o"&&a[1]==="n"&&(r=a.endsWith("Capture"),n=a.slice(2,r?a.length-7:void 0),t=e[To]||null,t=t!=null?t[a]:null,typeof t=="function"&&e.removeEventListener(n,t,r),typeof o=="function")){typeof t!="function"&&t!==null&&(a in e?e[a]=null:e.hasAttribute(a)&&e.removeAttribute(a)),e.addEventListener(n,o,r);break e}tt=!0,a in e?e[a]=o:o===!0?e.setAttribute(a,""):Kh(e,a,o)}return}tt=!0}function Na(e,t,a){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Xe("error",e),Xe("load",e);var o=!1,r=!1,n;for(n in a)if(a.hasOwnProperty(n)){var s=a[n];if(s!=null)switch(n){case"src":o=!0;break;case"srcSet":r=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(Z(137,t));default:ft(e,t,n,s,a,null)}}r&&ft(e,t,"srcSet",a.srcSet,a,null),o&&ft(e,t,"src",a.src,a,null);return;case"input":Xe("invalid",e);var i=n=s=r=null,l=null,u=null;for(o in a)if(a.hasOwnProperty(o)){var c=a[o];if(c!=null)switch(o){case"name":r=c;break;case"type":s=c;break;case"checked":l=c;break;case"defaultChecked":u=c;break;case"value":n=c;break;case"defaultValue":i=c;break;case"children":case"dangerouslySetInnerHTML":if(c!=null)throw Error(Z(137,t));break;default:ft(e,t,o,c,a,null)}}cD(e,n,i,l,u,s,r,!1);return;case"select":Xe("invalid",e),o=s=n=null;for(r in a)if(a.hasOwnProperty(r)&&(i=a[r],i!=null))switch(r){case"value":n=i;break;case"defaultValue":s=i;break;case"multiple":o=i;default:ft(e,t,r,i,a,null)}t=n,a=s,e.multiple=!!o,t!=null?pc(e,!!o,t,!1):a!=null&&pc(e,!!o,a,!0);return;case"textarea":Xe("invalid",e),n=r=o=null;for(s in a)if(a.hasOwnProperty(s)&&(i=a[s],i!=null))switch(s){case"value":o=i;break;case"defaultValue":r=i;break;case"children":n=i;break;case"dangerouslySetInnerHTML":if(i!=null)throw Error(Z(91));break;default:ft(e,t,s,i,a,null)}dD(e,o,r,n);return;case"option":for(l in a)if(a.hasOwnProperty(l)&&(o=a[l],o!=null))switch(l){case"selected":e.selected=o&&typeof o!="function"&&typeof o!="symbol";break;default:ft(e,t,l,o,a,null)}return;case"dialog":Xe("beforetoggle",e),Xe("toggle",e),Xe("cancel",e),Xe("close",e);break;case"iframe":case"object":Xe("load",e);break;case"video":case"audio":for(o=0;o<rm.length;o++)Xe(rm[o],e);break;case"image":Xe("error",e),Xe("load",e);break;case"details":Xe("toggle",e);break;case"embed":case"source":case"link":Xe("error",e),Xe("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(u in a)if(a.hasOwnProperty(u)&&(o=a[u],o!=null))switch(u){case"children":case"dangerouslySetInnerHTML":throw Error(Z(137,t));default:ft(e,t,u,o,a,null)}return;default:if(VL(t)){for(c in a)a.hasOwnProperty(c)&&(o=a[c],o!==void 0&&bL(e,t,c,o,a,void 0));return}}for(i in a)a.hasOwnProperty(i)&&(o=a[i],o!=null&&ft(e,t,i,o,a,null))}var Gq={};function jq(e,t,a,o){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var r=null,n=null,s=null,i=null,l=null,u=null,c=null;for(m in a){var d=a[m];if(a.hasOwnProperty(m)&&d!=null)switch(m){case"checked":break;case"value":break;case"defaultValue":l=d;default:o.hasOwnProperty(m)||ft(e,t,m,null,o,d)}}for(var f in o){var m=o[f];if(d=a[f],o.hasOwnProperty(f)&&(m!=null||d!=null))switch(f){case"type":m!==d&&(tt=!0),n=m;break;case"name":m!==d&&(tt=!0),r=m;break;case"checked":m!==d&&(tt=!0),u=m;break;case"defaultChecked":m!==d&&(tt=!0),c=m;break;case"value":m!==d&&(tt=!0),s=m;break;case"defaultValue":m!==d&&(tt=!0),i=m;break;case"children":case"dangerouslySetInnerHTML":if(m!=null)throw Error(Z(137,t));break;default:m!==d&&ft(e,t,f,m,o,d)}}PC(e,s,i,l,u,c,n,r);return;case"select":m=s=i=f=null;for(n in a)if(l=a[n],a.hasOwnProperty(n)&&l!=null)switch(n){case"value":break;case"multiple":m=l;default:o.hasOwnProperty(n)||ft(e,t,n,null,o,l)}for(r in o)if(n=o[r],l=a[r],o.hasOwnProperty(r)&&(n!=null||l!=null))switch(r){case"value":n!==l&&(tt=!0),f=n;break;case"defaultValue":n!==l&&(tt=!0),i=n;break;case"multiple":n!==l&&(tt=!0),s=n;default:n!==l&&ft(e,t,r,n,o,l)}t=i,a=s,o=m,f!=null?pc(e,!!a,f,!1):!!o!=!!a&&(t!=null?pc(e,!!a,t,!0):pc(e,!!a,a?[]:"",!1));return;case"textarea":m=f=null;for(i in a)if(r=a[i],a.hasOwnProperty(i)&&r!=null&&!o.hasOwnProperty(i))switch(i){case"value":break;case"children":break;default:ft(e,t,i,null,o,r)}for(s in o)if(r=o[s],n=a[s],o.hasOwnProperty(s)&&(r!=null||n!=null))switch(s){case"value":r!==n&&(tt=!0),f=r;break;case"defaultValue":r!==n&&(tt=!0),m=r;break;case"children":break;case"dangerouslySetInnerHTML":if(r!=null)throw Error(Z(91));break;default:r!==n&&ft(e,t,s,r,o,n)}fD(e,f,m);return;case"option":for(var p in a)if(f=a[p],a.hasOwnProperty(p)&&f!=null&&!o.hasOwnProperty(p))switch(p){case"selected":e.selected=!1;break;default:ft(e,t,p,null,o,f)}for(l in o)if(f=o[l],m=a[l],o.hasOwnProperty(l)&&f!==m&&(f!=null||m!=null))switch(l){case"selected":f!==m&&(tt=!0),e.selected=f&&typeof f!="function"&&typeof f!="symbol";break;default:ft(e,t,l,f,o,m)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var y in a)f=a[y],a.hasOwnProperty(y)&&f!=null&&!o.hasOwnProperty(y)&&ft(e,t,y,null,o,f);for(u in o)if(f=o[u],m=a[u],o.hasOwnProperty(u)&&f!==m&&(f!=null||m!=null))switch(u){case"children":case"dangerouslySetInnerHTML":if(f!=null)throw Error(Z(137,t));break;default:ft(e,t,u,f,o,m)}return;default:if(VL(t)){for(var b in a)f=a[b],a.hasOwnProperty(b)&&f!==void 0&&!o.hasOwnProperty(b)&&bL(e,t,b,void 0,o,f);for(c in o)f=o[c],m=a[c],!o.hasOwnProperty(c)||f===m||f===void 0&&m===void 0||bL(e,t,c,f,o,m);return}}for(var g in a)f=a[g],a.hasOwnProperty(g)&&f!=null&&!o.hasOwnProperty(g)&&ft(e,t,g,null,o,f);for(d in o)f=o[d],m=a[d],!o.hasOwnProperty(d)||f===m||f==null&&m==null||ft(e,t,d,f,o,m)}function SA(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function Xq(){if(typeof performance.getEntriesByType=="function"){for(var e=0,t=0,a=performance.getEntriesByType("resource"),o=0;o<a.length;o++){var r=a[o],n=r.transferSize,s=r.initiatorType,i=r.duration;if(n&&i&&SA(s)){for(s=0,i=r.responseEnd,o+=1;o<a.length;o++){var l=a[o],u=l.startTime;if(u>i)break;var c=l.transferSize,d=l.initiatorType;c&&SA(d)&&(l=l.responseEnd,s+=c*(l<i?1:(i-u)/(l-u)))}if(--o,t+=8*(n+s)/(r.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e=="number")?e:5}var vL=null,CL=null;function sm(e){return e.nodeType===9?e:e.ownerDocument}function bA(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function xP(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function yP(e,t,a,o){return a=sm(a).createElement(e),a[Ma]=o,a[To]=t,Na(a,e,t),ya(a),a}function LL(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.children=="bigint"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var xC=null;function Yq(){var e=window.event;return e&&e.type==="popstate"?e===xC?!1:(xC=e,!0):(xC=null,!1)}var CR=typeof setTimeout=="function"?setTimeout:void 0,Wq=typeof clearTimeout=="function"?clearTimeout:void 0,vA=typeof Promise=="function"?Promise:void 0,CA=typeof requestAnimationFrame=="function"?requestAnimationFrame:CR,Kq=typeof queueMicrotask=="function"?queueMicrotask:typeof vA<"u"?function(e){return vA.resolve(null).then(e).catch(Zq)}:CR;function Zq(e){setTimeout(function(){throw e})}function $s(e){return e==="head"}function LA(e,t){var a=t,o=0;do{var r=a.nextSibling;if(e.removeChild(a),r&&r.nodeType===8)if(a=r.data,a==="/$"||a==="/&"){if(o===0){e.removeChild(r),Nc(t);return}o--}else if(a==="$"||a==="$?"||a==="$~"||a==="$!"||a==="&")o++;else if(a==="html")SC(e.ownerDocument.documentElement);else if(a==="head"){a=e.ownerDocument.head,SC(a);for(var n=a.firstChild;n;){var s=n.nextSibling,i=n.nodeName;n[hm]||i==="SCRIPT"||i==="STYLE"||i==="LINK"&&n.rel.toLowerCase()==="stylesheet"||a.removeChild(n),n=s}}else a==="body"&&SC(e.ownerDocument.body);a=r}while(a);Nc(t)}function RA(e,t){var a=e;e=0;do{var o=a.nextSibling;if(a.nodeType===1?t?(a._stashedDisplay=a.style.display,a.style.display="none"):(a.style.display=a._stashedDisplay||"",a.getAttribute("style")===""&&a.removeAttribute("style")):a.nodeType===3&&(t?(a._stashedText=a.nodeValue,a.nodeValue=""):a.nodeValue=a._stashedText||""),o&&o.nodeType===8)if(a=o.data,a==="/$"){if(e===0)break;e--}else a!=="$"&&a!=="$?"&&a!=="$~"&&a!=="$!"||e++;a=o}while(a)}function SP(e,t,a){if(t=CSS.escape(t)!==t?"r-"+btoa(t).replace(/=/g,""):t,e.style.viewTransitionName=t,a!=null&&(e.style.viewTransitionClass=a),a=getComputedStyle(e),a.display==="inline"){if(t=e.getClientRects(),t.length===1)var o=1;else for(var r=o=0;r<t.length;r++){var n=t[r];0<n.width&&0<n.height&&o++}o===1&&(e=e.style,e.display=t.length===1?"inline-block":"block",e.marginTop="-"+a.paddingTop,e.marginBottom="-"+a.paddingBottom)}}function bP(e,t){e=e.style,t=t.style;var a=t!=null?t.hasOwnProperty("viewTransitionName")?t.viewTransitionName:t.hasOwnProperty("view-transition-name")?t["view-transition-name"]:null:null;e.viewTransitionName=a==null||typeof a=="boolean"?"":(""+a).trim(),a=t!=null?t.hasOwnProperty("viewTransitionClass")?t.viewTransitionClass:t.hasOwnProperty("view-transition-class")?t["view-transition-class"]:null:null,e.viewTransitionClass=a==null||typeof a=="boolean"?"":(""+a).trim(),e.display==="inline-block"&&(t==null?e.display=e.margin="":(a=t.display,e.display=a==null||typeof a=="boolean"?"":a,a=t.margin,a!=null?e.margin=a:(a=t.hasOwnProperty("marginTop")?t.marginTop:t["margin-top"],e.marginTop=a==null||typeof a=="boolean"?"":a,t=t.hasOwnProperty("marginBottom")?t.marginBottom:t["margin-bottom"],e.marginBottom=t==null||typeof t=="boolean"?"":t)))}function vP(e,t,a){return a=a.ownerDocument.defaultView,{rect:e,abs:t.position==="absolute"||t.position==="fixed",clip:t.clipPath!=="none"||t.overflow!=="visible"||t.filter!=="none"||t.mask!=="none"||t.mask!=="none"||t.borderRadius!=="0px",view:0<=e.bottom&&0<=e.right&&e.top<=a.innerHeight&&e.left<=a.innerWidth}}function RL(e){var t=e.getBoundingClientRect(),a=getComputedStyle(e);return vP(t,a,e)}function Qq(e){var t=e.getBoundingClientRect();t=new DOMRect(t.x+2e4,t.y+2e4,t.width,t.height);var a=getComputedStyle(e);return vP(t,a,e)}function Jq(e){return e.documentElement.clientHeight}function $q(e){this.addEventListener("load",e),this.addEventListener("error",e)}function e5(e,t,a,o,r,n,s,i,l){var u=t.nodeType===9?t:t.ownerDocument;try{var c=u.startViewTransition({update:function(){var f=u.defaultView,m=f.navigation&&f.navigation.transition,p=u.fonts.status;o();var y=[];if(p==="loaded"&&(Jq(u),u.fonts.status==="loading"&&y.push(u.fonts.ready)),p=y.length,e!==null)for(var b=e.suspenseyImages,g=0,h=0;h<b.length;h++){var x=b[h];if(!x.complete){var S=x.getBoundingClientRect();if(0<S.bottom&&0<S.right&&S.top<f.innerHeight&&S.left<f.innerWidth){if(g+=OP(x),g>fg){y.length=p;break}x=new Promise($q.bind(x)),y.push(x)}}}if(0<y.length)return f=Promise.race([Promise.all(y),new Promise(function(v){return setTimeout(v,500)})]).then(r,r),(m?Promise.allSettled([m.finished,f]):f).then(n,n);if(r(),m)return m.finished.then(n,n);n()},types:a});u.__reactViewTransition=c;var d=[];return c.ready.then(function(){for(var f=u.documentElement.getAnimations({subtree:!0}),m=0;m<f.length;m++){var p=f[m],y=p.effect,b=y.pseudoElement;if(b!=null&&b.startsWith("::view-transition")){d.push(p),p=y.getKeyframes();for(var g=b=void 0,h=!0,x=0;x<p.length;x++){var S=p[x],v=S.width;if(b===void 0)b=v;else if(b!==v){h=!1;break}if(v=S.height,g===void 0)g=v;else if(g!==v){h=!1;break}delete S.width,delete S.height,S.transform==="none"&&delete S.transform}h&&b!==void 0&&g!==void 0&&(y.setKeyframes(p),h=getComputedStyle(y.target,y.pseudoElement),h.width!==b||h.height!==g)&&(h=p[0],h.width=b,h.height=g,h=p[p.length-1],h.width=b,h.height=g,y.setKeyframes(p))}}s()},function(f){u.__reactViewTransition===c&&(u.__reactViewTransition=null);try{if(typeof f=="object"&&f!==null)switch(f.name){case"InvalidStateError":(f.message==="View transition was skipped because document visibility state is hidden."||f.message==="Skipping view transition because document visibility state has become hidden."||f.message==="Skipping view transition because viewport size changed."||f.message==="Transition was aborted because of invalid state")&&(f=null)}f!==null&&l(f)}finally{o(),r(),s()}}),c.finished.finally(function(){for(var f=0;f<d.length;f++)d[f].cancel();u.__reactViewTransition===c&&(u.__reactViewTransition=null),i()}),c}catch{return o(),r(),s(),null}}function ml(e,t){this._scope=document.documentElement,this._selector="::view-transition-"+e+"("+t+")"}ml.prototype.animate=function(e,t){return t=typeof t=="number"?{duration:t}:St({},t),t.pseudoElement=this._selector,this._scope.animate(e,t)};ml.prototype.getAnimations=function(){for(var e=this._scope,t=this._selector,a=e.getAnimations({subtree:!0}),o=[],r=0;r<a.length;r++){var n=a[r].effect;n!==null&&n.target===e&&n.pseudoElement===t&&o.push(a[r])}return o};ml.prototype.getComputedStyle=function(){return getComputedStyle(this._scope,this._selector)};function CP(e){return{name:e,group:new ml("group",e),imagePair:new ml("image-pair",e),old:new ml("old",e),new:new ml("new",e)}}function Yo(e){this._fragmentFiber=e,this._observers=this._eventListeners=null}Yo.prototype.addEventListener=function(e,t,a){var o=null,r=null;if(!(a!=null&&typeof a!="boolean"&&(o=a.signal||null,o!==null&&o.aborted))){this._eventListeners===null&&(this._eventListeners=[]);var n=this._eventListeners;if(LP(n,e,t,a)===-1){var s=this,i=t;a!=null&&typeof a!="boolean"&&a.once===!0&&(i=function(l){s.removeEventListener(e,t,a),typeof t=="function"?t.call(this,l):t.handleEvent(l)}),o!==null&&(r=s.removeEventListener.bind(s,e,t,a),o.addEventListener("abort",r,{once:!0}),r=o.removeEventListener.bind(o,"abort",r)),o=Mc(a),n.push({type:e,listener:t,optionsOrUseCapture:a,attachedListener:i,cleanup:r}),Ro(this._fragmentFiber.child,!1,t5,e,i,o)}this._eventListeners=n}};function t5(e,t,a,o){return la(e).addEventListener(t,a,o),!1}Yo.prototype.removeEventListener=function(e,t,a){var o=this._eventListeners;if(o!==null&&(t=LP(o,e,t,a),t!==-1)){var r=o[t];a=r.attachedListener;var n=r.cleanup;r=Mc(r.optionsOrUseCapture),Ro(this._fragmentFiber.child,!1,a5,e,a,r),o.splice(t,1),n!==null&&n()}};function a5(e,t,a,o){return la(e).removeEventListener(t,a,o),!1}function Mc(e){return e!=null&&typeof e!="boolean"&&(e.once===!0||e.signal instanceof AbortSignal)?{capture:e.capture,passive:e.passive}:e}function TA(e){return e==null?"c=0":typeof e=="boolean"?"c="+(e?"1":"0"):"c="+(e.capture?"1":"0")}function LP(e,t,a,o){if(e.length===0)return-1;o=TA(o);for(var r=0;r<e.length;r++){var n=e[r];if(n.type===t&&n.listener===a&&TA(n.optionsOrUseCapture)===o)return r}return-1}Yo.prototype.dispatchEvent=function(e){var t=wl(this._fragmentFiber);if(t===null)return!0;t=la(t);var a=this._eventListeners;if(a!==null&&0<a.length||!e.bubbles){var o=t.nodeType===9?t.createComment(""):document.createTextNode("");if(a)for(var r=0;r<a.length;r++){var n=a[r];o.addEventListener(n.type,n.attachedListener,Mc(n.optionsOrUseCapture))}if(t.appendChild(o),e=o.dispatchEvent(e),a)for(r=0;r<a.length;r++)n=a[r],o.removeEventListener(n.type,n.attachedListener,Mc(n.optionsOrUseCapture));return t.removeChild(o),e}return t.dispatchEvent(e)};Yo.prototype.focus=function(e){Ro(this._fragmentFiber.child,!0,RP,e,void 0,void 0)};function RP(e,t){return e.tag===6?!1:(e=la(e),p5(e,t))}Yo.prototype.focusLast=function(e){var t=[];Ro(this._fragmentFiber.child,!0,LR,t,void 0,void 0);for(var a=t.length-1;0<=a&&!RP(t[a],e);a--);};function LR(e,t){return t.push(e),!1}Yo.prototype.blur=function(){var e=wl(this._fragmentFiber);e!==null&&(e=la(e),e=sm(e).activeElement,e!==null&&Ro(this._fragmentFiber.child,!1,o5,e,void 0,void 0))};function o5(e,t){return e.tag===6?!1:(e=la(e),e===t||e.contains(t)?(t.blur(),!0):!1)}Yo.prototype.observeUsing=function(e){this._observers===null&&(this._observers=new Set),this._observers.add(e),Ro(this._fragmentFiber.child,!1,r5,e,void 0,void 0)};function r5(e,t){return e.tag===6||(e=la(e),t.observe(e)),!1}Yo.prototype.unobserveUsing=function(e){var t=this._observers;if(t!==null&&t.has(e)){t.delete(e),Ro(this._fragmentFiber.child,!1,n5,e,void 0,void 0);for(var a=t=0;a<kr.length;a++){var o=kr[a];o.fragmentInstance===this&&o.observer===e?e.unobserve(o.instance):kr[t++]=o}kr.length=t}};function n5(e,t){return e.tag===6||(e=la(e),t.unobserve(e)),!1}var kr=[],yC=!1;function s5(e,t,a){kr.push({fragmentInstance:e,observer:t,instance:a}),yC||(yC=!0,h5(function(){yC=!1;var o=kr;kr=[];for(var r=0;r<o.length;r++){var n=o[r];n.observer.unobserve(n.instance)}}))}Yo.prototype.getClientRects=function(){var e=[];return Ro(this._fragmentFiber.child,!1,i5,e,void 0,void 0),e};function i5(e,t){if(e.tag===6){e=e.stateNode;var a=e.ownerDocument.createRange();a.selectNodeContents(e),t.push.apply(t,a.getClientRects())}else e=la(e),t.push.apply(t,e.getClientRects());return!1}Yo.prototype.getRootNode=function(e){var t=wl(this._fragmentFiber);return t===null?this:la(t).getRootNode(e)};Yo.prototype.compareDocumentPosition=function(e){var t=wl(this._fragmentFiber);if(t===null)return Node.DOCUMENT_POSITION_DISCONNECTED;var a=[];Ro(this._fragmentFiber.child,!1,LR,a,void 0,void 0);var o=la(t);if(a.length===0){if(a=o,rE(this._fragmentFiber)){e:{for(t=this._fragmentFiber.return;t!==null;){if(t.tag===4){t=t.stateNode.containerInfo;break e}if(t.tag===3||t.tag===5||t.tag===27)break;t=t.return}t=null}t!=null&&(a=t)}t=this._fragmentFiber;var r=o=a.compareDocumentPosition(e);return a===e?r=Node.DOCUMENT_POSITION_CONTAINS:o&Node.DOCUMENT_POSITION_CONTAINED_BY&&(a=XA(t)[1],a===null?r=Node.DOCUMENT_POSITION_PRECEDING:(e=la(a).compareDocumentPosition(e),r=e===0||e&Node.DOCUMENT_POSITION_FOLLOWING?Node.DOCUMENT_POSITION_FOLLOWING:Node.DOCUMENT_POSITION_PRECEDING)),r|=Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC}t=la(a[0]),r=la(a[a.length-1]);var n=rE(this._fragmentFiber)?t.parentElement:o;if(n==null)return Node.DOCUMENT_POSITION_DISCONNECTED;o=n.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_CONTAINED_BY,n=n.compareDocumentPosition(r)&Node.DOCUMENT_POSITION_CONTAINED_BY;var s=t.compareDocumentPosition(e),i=r.compareDocumentPosition(e),l=s&Node.DOCUMENT_POSITION_CONTAINED_BY||i&Node.DOCUMENT_POSITION_CONTAINED_BY;return i=o&&n&&s&Node.DOCUMENT_POSITION_FOLLOWING&&i&Node.DOCUMENT_POSITION_PRECEDING,t=o&&t===e||n&&r===e||l||i?Node.DOCUMENT_POSITION_CONTAINED_BY:!o&&t===e||!n&&r===e?Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC:s,t&Node.DOCUMENT_POSITION_DISCONNECTED||t&Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC||l5(t,this._fragmentFiber,a[0],a[a.length-1],e)?t:Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC};function l5(e,t,a,o,r){var n=dl(r);if(e&Node.DOCUMENT_POSITION_CONTAINED_BY){if(a=!!n)e:{for(;n!==null;){if(n.tag===7&&(n===t||n.alternate===t)){a=!0;break e}n=n.return}a=!1}return a}if(e&Node.DOCUMENT_POSITION_CONTAINS){if(n===null)return n=r.ownerDocument,r===n||r===n.documentElement||r===n.body;e:{for(n=t,t=wl(t);n!==null;){if(!(n.tag!==5&&n.tag!==3&&n.tag!==27||n!==t&&n.alternate!==t)){n=!0;break e}n=n.return}n=!1}return n}return e&Node.DOCUMENT_POSITION_PRECEDING?((t=!!n)&&!(t=n===a)&&(t=vC(a,n,nE),t===null?t=!1:(Ro(t,!0,F3,n,a),n=tc,tc=null,t=n!==null)),t):e&Node.DOCUMENT_POSITION_FOLLOWING?((t=!!n)&&!(t=n===o)&&(t=vC(o,n,nE),t===null?t=!1:(Ro(t,!0,_3,n,o),n=tc,bC=tc=null,t=n!==null)),t):!1}function IA(e,t){var a=e.ownerDocument.createRange();a.selectNodeContents(e),e=a.getBoundingClientRect(),window.scrollTo(window.scrollX+e.left,t?window.scrollY+e.top:window.scrollY+e.bottom-window.innerHeight)}Yo.prototype.scrollIntoView=function(e){if(typeof e=="object")throw Error(Z(566));var t=[];Ro(this._fragmentFiber.child,!1,LR,t,void 0,void 0);var a=e!==!1;if(t.length===0){var o=XA(this._fragmentFiber);if(o=a?o[1]||o[0]||wl(this._fragmentFiber):o[0]||o[1],o===null)return;if(o.tag===6){e=la(o),IA(e,a);return}if(o=la(o),o.nodeType!==9){if(o.nodeType===11){a="host"in o?o.host:null,a!==null&&a.scrollIntoView(e);return}o.scrollIntoView(e)}}for(o=a?t.length-1:0;o!==(a?-1:t.length);){var r=t[o];r.tag===6?(r=la(r),IA(r,a)):la(r).scrollIntoView(e),o+=a?-1:1}};function u5(e,t){return e=la(e),TP(e,t),!1}function TP(e,t){e.reactFragments==null&&(e.reactFragments=new Set),e.reactFragments.add(t)}function IP(e,t){var a=t._eventListeners;if(a!==null)for(var o=0;o<a.length;o++){var r=a[o];e.addEventListener(r.type,r.attachedListener,Mc(r.optionsOrUseCapture))}e.nodeType!==3&&(a=t._observers,a!==null&&a.forEach(function(n){for(var s=0,i=0;i<kr.length;i++){var l=kr[i];(l.fragmentInstance!==t||l.observer!==n||l.instance!==e)&&(kr[s++]=l)}kr.length=s,n.observe(e)}),TP(e,t))}function c5(e,t){var a=t._eventListeners;if(a!==null)for(var o=0;o<a.length;o++){var r=a[o];e.removeEventListener(r.type,r.attachedListener,Mc(r.optionsOrUseCapture))}e.nodeType!==3&&(a=t._observers,a!==null&&a.forEach(function(n){typeof n.rootMargin=="string"?s5(t,n,e):n.unobserve(e)}),e.reactFragments!=null&&e.reactFragments.delete(t))}function TL(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var a=t;switch(t=t.nextSibling,a.nodeName){case"HTML":case"HEAD":case"BODY":TL(a),Gg(a);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(a.rel.toLowerCase()==="stylesheet")continue}e.removeChild(a)}}function f5(e,t,a,o){for(;e.nodeType===1;){var r=a;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!o&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(o){if(!e[hm])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(n=e.getAttribute("rel"),n==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(n!==r.rel||e.getAttribute("href")!==(r.href==null||r.href===""?null:r.href)||e.getAttribute("crossorigin")!==(r.crossOrigin==null?null:r.crossOrigin)||e.getAttribute("title")!==(r.title==null?null:r.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(n=e.getAttribute("src"),(n!==(r.src==null?null:r.src)||e.getAttribute("type")!==(r.type==null?null:r.type)||e.getAttribute("crossorigin")!==(r.crossOrigin==null?null:r.crossOrigin))&&n&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(t==="input"&&e.type==="hidden"){var n=r.name==null?null:""+r.name;if(r.type==="hidden"&&e.getAttribute("name")===n)return e}else return e;if(e=cr(e.nextSibling),e===null)break}return null}function d5(e,t,a){if(t==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!a||(e=cr(e.nextSibling),e===null))return null;return e}function wP(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!t||(e=cr(e.nextSibling),e===null))return null;return e}function IL(e){return e.data==="$?"||e.data==="$~"}function RR(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function m5(e,t){var a=e.ownerDocument;if(e.data==="$~")e._reactRetry=t;else if(e.data!=="$?"||a.readyState!=="loading")t();else{var o=function(){t(),a.removeEventListener("DOMContentLoaded",o)};a.addEventListener("DOMContentLoaded",o),e._reactRetry=o}}function cr(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?"||t==="$~"||t==="&"||t==="F!"||t==="F")break;if(t==="/$"||t==="/&")return null}}return e}var wL=null;function wA(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var a=e.data;if(a==="/$"||a==="/&"){if(t===0)return cr(e.nextSibling);t--}else a!=="$"&&a!=="$!"&&a!=="$?"&&a!=="$~"&&a!=="&"||t++}e=e.nextSibling}return null}function EA(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var a=e.data;if(a==="$"||a==="$!"||a==="$?"||a==="$~"||a==="&"){if(t===0)return e;t--}else a!=="/$"&&a!=="/&"||t++}e=e.previousSibling}return null}function p5(e,t){function a(){o=!0}if(e.ownerDocument.activeElement===e)return!0;var o=!1;try{e.ownerDocument.addEventListener("focus",a,!0),(e.focus||HTMLElement.prototype.focus).call(e,t)}finally{e.ownerDocument.removeEventListener("focus",a,!0)}return o}function h5(e){CA(function(){CA(function(t){return e(t)})})}function EP(e,t,a){switch(t=sm(a),e){case"html":if(e=t.documentElement,!e)throw Error(Z(452));return e;case"head":if(e=t.head,!e)throw Error(Z(453));return e;case"body":if(e=t.body,!e)throw Error(Z(454));return e;default:throw Error(Z(451))}}function AP(e,t,a){for(var o in a){var r=a[o];a.hasOwnProperty(o)&&r!=null&&ft(e,t,o,null,Gq,r)}a.dangerouslySetInnerHTML!=null&&(e.textContent=""),e.onclick===on&&(e.onclick=null),Gg(e)}function SC(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);Gg(e)}var fr=new Map,AA=new Set;function im(e){if(typeof e.getRootNode=="function"){var t=e.getRootNode();if(t.nodeType===9||t.nodeType===11)return t}return e.nodeType===9?e:e.ownerDocument}var Qn=nt.d;nt.d={f:g5,r:x5,D:y5,C:S5,L:b5,m:v5,X:L5,S:C5,M:R5};function g5(){var e=Qn.f(),t=rx();return e||t}function x5(e){var t=Bc(e);t!==null&&t.tag===5&&t.type==="form"?mM(t):Qn.r(e)}var Hc=typeof document>"u"?null:document;function DP(e,t,a){var o=Hc;if(o&&typeof t=="string"&&t){var r=ir(t);r='link[rel="'+e+'"][href="'+r+'"]',typeof a=="string"&&(r+='[crossorigin="'+a+'"]'),AA.has(r)||(AA.add(r),e={rel:e,crossOrigin:a,href:t},o.querySelector(r)===null&&(t=o.createElement("link"),Na(t,"link",e),ya(t),o.head.appendChild(t)))}}function y5(e){Qn.D(e),DP("dns-prefetch",e,null)}function S5(e,t){Qn.C(e,t),DP("preconnect",e,t)}function b5(e,t,a){Qn.L(e,t,a);var o=Hc;if(o&&e&&t){var r='link[rel="preload"][as="'+ir(t)+'"]';t==="image"&&a&&a.imageSrcSet?(r+='[imagesrcset="'+ir(a.imageSrcSet)+'"]',typeof a.imageSizes=="string"&&(r+='[imagesizes="'+ir(a.imageSizes)+'"]')):r+='[href="'+ir(e)+'"]';var n=r;switch(t){case"style":n=Pc(e);break;case"script":n=Uc(e)}if(!(fr.has(n)||(e=St({rel:"preload",href:t==="image"&&a&&a.imageSrcSet?void 0:e,as:t},a),fr.set(n,e),o.querySelector(r)!==null||t==="style"&&o.querySelector(vm(n))||t==="script"&&o.querySelector(Cm(n))))){var s=o.createElement("link");Na(s,"link",e),t==="style"&&(s[yg]=!0,s.onload=s.onerror=function(){nD(s)}),ya(s),o.head.appendChild(s)}}}function v5(e,t){Qn.m(e,t);var a=Hc;if(a&&e){var o=t&&typeof t.as=="string"?t.as:"script",r='link[rel="modulepreload"][as="'+ir(o)+'"][href="'+ir(e)+'"]',n=r;switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":n=Uc(e)}if(!fr.has(n)&&(e=St({rel:"modulepreload",href:e},t),fr.set(n,e),a.querySelector(r)===null)){switch(o){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(a.querySelector(Cm(n)))return}o=a.createElement("link"),Na(o,"link",e),ya(o),a.head.appendChild(o)}}}function C5(e,t,a){Qn.S(e,t,a);var o=Hc;if(o&&e){var r=mc(o).hoistableStyles,n=Pc(e);t=t||"default";var s=r.get(n);if(!s){var i={loading:0,preload:null};if(s=o.querySelector(vm(n)))i.loading=5;else{e=St({rel:"stylesheet",href:e,"data-precedence":t},a),(a=fr.get(n))&&TR(e,a);var l=s=o.createElement("link");ya(l),Na(l,"link",e),l._p=new Promise(function(u,c){l.onload=u,l.onerror=c}),l.addEventListener("load",function(){i.loading|=1}),l.addEventListener("error",function(){i.loading|=2}),i.loading|=4,ug(s,t,o)}s={type:"stylesheet",instance:s,count:1,state:i},r.set(n,s)}}}function L5(e,t){Qn.X(e,t);var a=Hc;if(a&&e){var o=mc(a).hoistableScripts,r=Uc(e),n=o.get(r);n||(n=a.querySelector(Cm(r)),n||(e=St({src:e,async:!0},t),(t=fr.get(r))&&IR(e,t),n=a.createElement("script"),ya(n),Na(n,"link",e),a.head.appendChild(n)),n={type:"script",instance:n,count:1,state:null},o.set(r,n))}}function R5(e,t){Qn.M(e,t);var a=Hc;if(a&&e){var o=mc(a).hoistableScripts,r=Uc(e),n=o.get(r);n||(n=a.querySelector(Cm(r)),n||(e=St({src:e,async:!0,type:"module"},t),(t=fr.get(r))&&IR(e,t),n=a.createElement("script"),ya(n),Na(n,"link",e),a.head.appendChild(n)),n={type:"script",instance:n,count:1,state:null},o.set(r,n))}}function DA(e,t,a,o){var r=(r=Bs.current)?im(r):null;if(!r)throw Error(Z(446));switch(e){case"meta":case"title":return null;case"style":return typeof a.precedence=="string"&&typeof a.href=="string"?(a=Pc(a.href),t=mc(r).hoistableStyles,o=t.get(a),o||(o={type:"style",instance:null,count:0,state:null},t.set(a,o)),o):{type:"void",instance:null,count:0,state:null};case"link":if(a.rel==="stylesheet"&&typeof a.href=="string"&&typeof a.precedence=="string"){e=Pc(a.href);var n=mc(r).hoistableStyles,s=n.get(e);if(s||(r=r.ownerDocument||r,s={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},n.set(e,s),(n=r.querySelector(vm(e)))?n._p||(s.instance=n,s.state.loading=5):(n=fr.get(e),n||(n={rel:"preload",as:"style",href:a.href,crossOrigin:a.crossOrigin,integrity:a.integrity,media:a.media,hrefLang:a.hrefLang,referrerPolicy:a.referrerPolicy},fr.set(e,n)),T5(r,e,n,s.state))),t&&o===null)throw Error(Z(528,""));return s}if(t&&o!==null)throw Error(Z(529,""));return null;case"script":return t=a.async,a=a.src,typeof a=="string"&&t&&typeof t!="function"&&typeof t!="symbol"?(a=Uc(a),t=mc(r).hoistableScripts,o=t.get(a),o||(o={type:"script",instance:null,count:0,state:null},t.set(a,o)),o):{type:"void",instance:null,count:0,state:null};default:throw Error(Z(444,e))}}function Pc(e){return'href="'+ir(e)+'"'}function vm(e){return'link[rel="stylesheet"]['+e+"]"}function MP(e){return St({},e,{"data-precedence":e.precedence,precedence:null})}function T5(e,t,a,o){if(t=e.querySelector('link[rel="preload"][as="style"]['+t+"]")){if(t[yg]!==!0){o.loading=1;return}}else t=e.createElement("link"),t[yg]=!0,t.onload=t.onerror=nD.bind(null,t),Na(t,"link",a),ya(t),e.head.appendChild(t);o.preload=t,t.addEventListener("load",function(){return o.loading|=1}),t.addEventListener("error",function(){return o.loading|=2})}function Uc(e){return'[src="'+ir(e)+'"]'}function Cm(e){return"script[async]"+e}function MA(e,t,a){if(t.count++,t.instance===null)switch(t.type){case"style":var o=e.querySelector('style[data-href~="'+ir(a.href)+'"]');if(o)return t.instance=o,ya(o),o;var r=St({},a,{"data-href":a.href,"data-precedence":a.precedence,href:null,precedence:null});return o=(e.ownerDocument||e).createElement("style"),ya(o),Na(o,"style",r),ug(o,a.precedence,e),t.instance=o;case"stylesheet":r=Pc(a.href);var n=e.querySelector(vm(r));if(n)return t.state.loading|=4,t.instance=n,ya(n),n;o=MP(a),(r=fr.get(r))&&TR(o,r),n=(e.ownerDocument||e).createElement("link"),ya(n);var s=n;return s._p=new Promise(function(i,l){s.onload=i,s.onerror=l}),Na(n,"link",o),t.state.loading|=4,ug(n,a.precedence,e),t.instance=n;case"script":return n=Uc(a.src),(r=e.querySelector(Cm(n)))?(t.instance=r,ya(r),r):(o=a,(r=fr.get(n))&&(o=St({},a),IR(o,r)),e=e.ownerDocument||e,r=e.createElement("script"),ya(r),Na(r,"link",o),e.head.appendChild(r),t.instance=r);case"void":return null;default:throw Error(Z(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(o=t.instance,t.state.loading|=4,ug(o,a.precedence,e));return t.instance}function ug(e,t,a){for(var o=a.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),r=o.length?o[o.length-1]:null,n=r,s=0;s<o.length;s++){var i=o[s];if(i.dataset.precedence===t)n=i;else if(n!==r)break}n?n.parentNode.insertBefore(e,n.nextSibling):(t=a.nodeType===9?a.head:a,t.insertBefore(e,t.firstChild))}function TR(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function IR(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}var cg=null;function PA(e,t,a){if(cg===null){var o=new Map,r=cg=new Map;r.set(a,o)}else r=cg,o=r.get(a),o||(o=new Map,r.set(a,o));if(o.has(e))return o;for(o.set(e,null),a=a.getElementsByTagName(e),r=0;r<a.length;r++){var n=a[r];if(!(n[hm]||n[Ma]||e==="link"&&n.getAttribute("rel")==="stylesheet")&&n.namespaceURI!=="http://www.w3.org/2000/svg"){var s=n.getAttribute(t)||"";s=e+s;var i=o.get(s);i?i.push(n):o.set(s,[n])}}return o}function EL(e,t,a){e=e.ownerDocument||e,e.head.insertBefore(a,t==="title"?e.querySelector("head > title"):null)}function I5(e,t,a){if(a===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!="string"||typeof t.href!="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!="string"||typeof t.href!="string"||t.href===""||t.onLoad||t.onError)break;switch(t.rel){case"stylesheet":return e=t.disabled,typeof t.precedence=="string"&&e==null;default:return!0}case"script":if(t.async&&typeof t.async!="function"&&typeof t.async!="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src=="string")return!0}return!1}function OA(e,t){return e==="img"&&t.src!=null&&t.src!==""&&t.onLoad==null&&t.loading!=="lazy"}function PP(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}function OP(e){return(e.width||100)*(e.height||100)*(typeof devicePixelRatio=="number"?devicePixelRatio:1)*.25}function kA(e,t){typeof t.decode=="function"&&(e.imgCount++,t.complete||(e.imgBytes+=OP(t),e.suspenseyImages.push(t)),e=A5.bind(e),t.decode().then(e,e))}function w5(e,t,a,o){if(a.type==="stylesheet"&&(typeof o.media!="string"||matchMedia(o.media).matches!==!1)&&(a.state.loading&4)===0){if(a.instance===null){var r=Pc(o.href),n=t.querySelector(vm(r));if(n){t=n._p,t!==null&&typeof t=="object"&&typeof t.then=="function"&&(e.count++,e=lm.bind(e),t.then(e,e)),a.state.loading|=4,a.instance=n,ya(n);return}n=t.ownerDocument||t,o=MP(o),(r=fr.get(r))&&TR(o,r),n=n.createElement("link"),ya(n);var s=n;s._p=new Promise(function(i,l){s.onload=i,s.onerror=l}),Na(n,"link",o),a.instance=n}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(a,t),(t=a.state.preload)&&(a.state.loading&3)===0&&(e.count++,a=lm.bind(e),t.addEventListener("load",a),t.addEventListener("error",a))}}var fg=0;function E5(e,t){return e.stylesheets&&e.count===0&&dg(e,e.stylesheets),0<e.count||0<e.imgCount?function(a){var o=setTimeout(function(){if(e.stylesheets&&dg(e,e.stylesheets),e.unsuspend){var n=e.unsuspend;e.unsuspend=null,n()}},6e4+t);0<e.imgBytes&&fg===0&&(fg=62500*Xq());var r=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&dg(e,e.stylesheets),e.unsuspend)){var n=e.unsuspend;e.unsuspend=null,n()}},(e.imgBytes>fg?50:800)+t);return e.unsuspend=a,function(){e.unsuspend=null,clearTimeout(o),clearTimeout(r)}}:null}function kP(e){if(e.count===0&&(e.imgCount===0||!e.waitingForImages)){if(e.stylesheets)dg(e,e.stylesheets);else if(e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}}}function lm(){this.count--,kP(this)}function A5(){this.imgCount--,kP(this)}var Hg=null;function dg(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Hg=new Map,t.forEach(D5,e),Hg=null,lm.call(e))}function D5(e,t){if(!(t.state.loading&4)){var a=Hg.get(e);if(a)var o=a.get(null);else{a=new Map,Hg.set(e,a);for(var r=e.querySelectorAll("link[data-precedence],style[data-precedence]"),n=0;n<r.length;n++){var s=r[n];(s.nodeName==="LINK"||s.getAttribute("media")!=="not all")&&(a.set(s.dataset.precedence,s),o=s)}o&&a.set(null,o)}r=t.instance,s=r.getAttribute("data-precedence"),n=a.get(s)||o,n===o&&a.set(null,r),a.set(s,r),this.count++,o=lm.bind(this),r.addEventListener("load",o),r.addEventListener("error",o),n?n.parentNode.insertBefore(r,n.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(r,e.firstChild)),t.state.loading|=4}}var Oc={$$typeof:an,Provider:null,Consumer:null,_currentValue:pl,_currentValue2:pl,_threadCount:0};function M5(e,t,a,o,r,n,s,i,l){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Yv(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Yv(0),this.hiddenUpdates=Yv(null),this.identifierPrefix=o,this.onUncaughtError=r,this.onCaughtError=n,this.onRecoverableError=s,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=l,this.transitionTypes=null,this.incompleteTransitions=new Map}function NP(e,t,a,o,r,n,s,i,l,u,c,d){return e=new M5(e,t,a,s,l,u,c,d,i),t=1,n===!0&&(t|=24),n=Co(3,null,null,t),e.current=n,n.stateNode=e,t=XL(),t.refCount++,e.pooledCache=t,t.refCount++,n.memoizedState={element:o,isDehydrated:a,cache:t},KL(n),e}function VP(e){return e?(e=uc,e):uc}function BP(e,t,a,o,r,n){r=VP(r),o.context===null?o.context=r:o.pendingContext=r,o=_s(t),o.payload={element:a},n=n===void 0?null:n,n!==null&&(o.callback=n),a=zs(e,o,t),a!==null&&(Lo(a,e,t),zd(a,e,t))}function NA(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var a=e.retryLane;e.retryLane=a!==0&&a<t?a:t}}function wR(e,t){NA(e,t),(e=e.alternate)&&NA(e,t)}function FP(e){if(e.tag===13||e.tag===31){var t=Dl(e,67108864);t!==null&&Lo(t,e,67108864),wR(e,67108864)}}function VA(e){if(e.tag===13||e.tag===31){var t=jo();t=kL(t);var a=Dl(e,t);a!==null&&Lo(a,e,t),wR(e,t)}}var kc=!0;function P5(e,t,a,o){var r=De.T;De.T=null;var n=nt.p;try{nt.p=2,ER(e,t,a,o)}finally{nt.p=n,De.T=r}}function O5(e,t,a,o){var r=De.T;De.T=null;var n=nt.p;try{nt.p=8,ER(e,t,a,o)}finally{nt.p=n,De.T=r}}function ER(e,t,a,o){if(kc){var r=AL(o);if(r===null)gC(e,t,o,Ug,a),BA(e,o);else if(N5(r,e,t,a,o))o.stopPropagation();else if(BA(e,o),t&4&&-1<k5.indexOf(e)){for(;r!==null;){var n=Bc(r);if(n!==null)switch(n.tag){case 3:if(n=n.stateNode,n.current.memoizedState.isDehydrated){var s=ul(n.pendingLanes);if(s!==0){var i=n;for(i.pendingLanes|=2,i.entangledLanes|=2;s;){var l=1<<31-Go(s);i.entanglements[1]|=l,s&=~l}fn(n),(rt&6)===0&&(Vg=Uo()+500,bm(0,!1))}}break;case 31:case 13:i=Dl(n,2),i!==null&&Lo(i,n,2),rx(),wR(n,2)}if(n=AL(o),n===null&&gC(e,t,o,Ug,a),n===r)break;r=n}r!==null&&o.stopPropagation()}else gC(e,t,o,null,a)}}function AL(e){return e=BL(e),AR(e)}var Ug=null;function AR(e){if(Ug=null,e=dl(e),e!==null){var t=fm(e);if(t===null)e=null;else{var a=t.tag;if(a===13){if(e=qA(t),e!==null)return e;e=null}else if(a===31){if(e=GA(t),e!==null)return e;e=null}else if(a===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return Ug=e,null}function _P(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"fullscreenerror":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"resize":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(W3()){case ZA:return 2;case QA:return 8;case xg:case K3:return 32;case JA:return 268435456;default:return 32}default:return 32}}var DL=!1,Gs=null,js=null,Xs=null,um=new Map,cm=new Map,Ds=[],k5="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");function BA(e,t){switch(e){case"focusin":case"focusout":Gs=null;break;case"dragenter":case"dragleave":js=null;break;case"mouseover":case"mouseout":Xs=null;break;case"pointerover":case"pointerout":um.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":cm.delete(t.pointerId)}}function Ad(e,t,a,o,r,n){return e===null||e.nativeEvent!==n?(e={blockedOn:t,domEventName:a,eventSystemFlags:o,nativeEvent:n,targetContainers:[r]},t!==null&&(t=Bc(t),t!==null&&FP(t)),e):(e.eventSystemFlags|=o,t=e.targetContainers,r!==null&&t.indexOf(r)===-1&&t.push(r),e)}function N5(e,t,a,o,r){switch(t){case"focusin":return Gs=Ad(Gs,e,t,a,o,r),!0;case"dragenter":return js=Ad(js,e,t,a,o,r),!0;case"mouseover":return Xs=Ad(Xs,e,t,a,o,r),!0;case"pointerover":var n=r.pointerId;return um.set(n,Ad(um.get(n)||null,e,t,a,o,r)),!0;case"gotpointercapture":return n=r.pointerId,cm.set(n,Ad(cm.get(n)||null,e,t,a,o,r)),!0}return!1}function zP(e){var t=dl(e.target);if(t!==null){var a=fm(t);if(a!==null){if(t=a.tag,t===13){if(t=qA(a),t!==null){e.blockedOn=t,uE(e.priority,function(){VA(a)});return}}else if(t===31){if(t=GA(a),t!==null){e.blockedOn=t,uE(e.priority,function(){VA(a)});return}}else if(t===3&&a.stateNode.current.memoizedState.isDehydrated){e.blockedOn=a.tag===3?a.stateNode.containerInfo:null;return}}}e.blockedOn=null}function mg(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var a=AL(e.nativeEvent);if(a===null){a=e.nativeEvent;var o=new a.constructor(a.type,a);OC=o,a.target.dispatchEvent(o),OC=null}else return t=Bc(a),t!==null&&FP(t),e.blockedOn=a,!1;t.shift()}return!0}function FA(e,t,a){mg(e)&&a.delete(t)}function V5(){DL=!1,Gs!==null&&mg(Gs)&&(Gs=null),js!==null&&mg(js)&&(js=null),Xs!==null&&mg(Xs)&&(Xs=null),um.forEach(FA),cm.forEach(FA)}function Yh(e,t){e.blockedOn===t&&(e.blockedOn=null,DL||(DL=!0,ua.unstable_scheduleCallback(ua.unstable_NormalPriority,V5)))}var Wh=null;function _A(e){Wh!==e&&(Wh=e,ua.unstable_scheduleCallback(ua.unstable_NormalPriority,function(){Wh===e&&(Wh=null);for(var t=0;t<e.length;t+=3){var a=e[t],o=e[t+1],r=e[t+2];if(typeof o!="function"){if(AR(o||a)===null)continue;break}var n=Bc(a);n!==null&&(e.splice(t,3),t-=3,KC(n,{pending:!0,data:r,method:a.method,action:o},o,r))}}))}function Nc(e){function t(l){return Yh(l,e)}Gs!==null&&Yh(Gs,e),js!==null&&Yh(js,e),Xs!==null&&Yh(Xs,e),um.forEach(t),cm.forEach(t);for(var a=0;a<Ds.length;a++){var o=Ds[a];o.blockedOn===e&&(o.blockedOn=null)}for(;0<Ds.length&&(a=Ds[0],a.blockedOn===null);)zP(a),a.blockedOn===null&&Ds.shift();if(a=(e.ownerDocument||e).$$reactFormReplay,a!=null)for(o=0;o<a.length;o+=3){var r=a[o],n=a[o+1],s=r[To]||null;if(typeof n=="function")s||_A(a);else if(s){var i=null;if(n&&n.hasAttribute("formAction")){if(r=n,s=n[To]||null)i=s.formAction;else if(AR(r)!==null)continue}else i=s.action;typeof i=="function"?a[o+1]=i:(a.splice(o,3),o-=3),_A(a)}}}function HP(){function e(n){n.canIntercept&&n.info==="react-transition"&&n.intercept({handler:function(){return new Promise(function(s){return r=s})},focusReset:"manual",scroll:"manual"})}function t(){r!==null&&(r(),r=null),o||setTimeout(a,20)}function a(){if(!o&&!navigation.transition){var n=navigation.currentEntry;n&&n.url!=null&&navigation.navigate(n.url,{state:n.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var o=!1,r=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",t),navigation.addEventListener("navigateerror",t),setTimeout(a,100),function(){o=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",t),navigation.removeEventListener("navigateerror",t),r!==null&&(r(),r=null)}}}function DR(e){this._internalRoot=e}ix.prototype.render=DR.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(Z(409));var a=t.current,o=jo();BP(a,o,e,t,null,null)};ix.prototype.unmount=DR.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;BP(e.current,2,null,e,null,null),rx(),t[Vc]=null}};function ix(e){this._internalRoot=e}ix.prototype.unstable_scheduleHydration=function(e){if(e){var t=rD();e={blockedOn:null,target:e,priority:t};for(var a=0;a<Ds.length&&t!==0&&t<Ds[a].priority;a++);Ds.splice(a,0,e),a===0&&zP(e)}};var zA=HA.version;if(zA!=="19.3.0")throw Error(Z(527,zA,"19.3.0"));nt.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(Z(188)):(e=Object.keys(e).join(","),Error(Z(268,e)));return e=B3(t),e=e!==null?jA(e):null,e=e===null?null:e.stateNode,e};var B5={bundleType:0,version:"19.3.0",rendererPackageName:"react-dom",currentDispatcherRef:De,reconcilerVersion:"19.3.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&(Dd=__REACT_DEVTOOLS_GLOBAL_HOOK__,!Dd.isDisabled&&Dd.supportsFiber))try{dm=Dd.inject(B5),qo=Dd}catch{}var Dd;lx.createRoot=function(e,t){if(!UA(e))throw Error(Z(299));var a=!1,o="",r=vM,n=CM,s=LM;return t!=null&&(t.unstable_strictMode===!0&&(a=!0),t.identifierPrefix!==void 0&&(o=t.identifierPrefix),t.onUncaughtError!==void 0&&(r=t.onUncaughtError),t.onCaughtError!==void 0&&(n=t.onCaughtError),t.onRecoverableError!==void 0&&(s=t.onRecoverableError)),t=NP(e,1,!1,null,null,a,o,null,r,n,s,HP),e[Vc]=t.current,vR(e),new DR(t)};lx.hydrateRoot=function(e,t,a){if(!UA(e))throw Error(Z(299));var o=!1,r="",n=vM,s=CM,i=LM,l=null;return a!=null&&(a.unstable_strictMode===!0&&(o=!0),a.identifierPrefix!==void 0&&(r=a.identifierPrefix),a.onUncaughtError!==void 0&&(n=a.onUncaughtError),a.onCaughtError!==void 0&&(s=a.onCaughtError),a.onRecoverableError!==void 0&&(i=a.onRecoverableError),a.formState!==void 0&&(l=a.formState)),t=NP(e,1,!0,t,a??null,o,r,l,n,s,i,HP),t.context=VP(null),a=t.current,o=jo(),o=kL(o),r=_s(o),r.callback=null,zs(a,r,o),a=o,t.current.lanes=a,pm(t,a),fn(t),e[Vc]=t.current,vR(e),new ix(t)};lx.version="19.3.0"});var jP=yo((LW,GP)=>{"use strict";function qP(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(qP)}catch(e){console.error(e)}}qP(),GP.exports=UP()});var xO=yo(gx=>{"use strict";var GG=Symbol.for("react.transitional.element"),jG=Symbol.for("react.fragment");function gO(e,t,a){var o=null;if(a!==void 0&&(o=""+a),t.key!==void 0&&(o=""+t.key),"key"in t){a={};for(var r in t)r!=="key"&&(a[r]=t[r])}else a=t;return t=a.ref,{$$typeof:GG,type:e,key:o,ref:t!==void 0?t:null,props:a}}gx.Fragment=jG;gx.jsx=gO;gx.jsxs=gO});var Q=yo((uQ,yO)=>{"use strict";yO.exports=xO()});var B2=yo(V2=>{"use strict";var Vf=M();function KY(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var ZY=typeof Object.is=="function"?Object.is:KY,QY=Vf.useState,JY=Vf.useEffect,$Y=Vf.useLayoutEffect,e7=Vf.useDebugValue;function t7(e,t){var a=t(),o=QY({inst:{value:a,getSnapshot:t}}),r=o[0].inst,n=o[1];return $Y(function(){r.value=a,r.getSnapshot=t,aI(r)&&n({inst:r})},[e,a,t]),JY(function(){return aI(r)&&n({inst:r}),e(function(){aI(r)&&n({inst:r})})},[e]),e7(a),a}function aI(e){var t=e.getSnapshot;e=e.value;try{var a=t();return!ZY(e,a)}catch{return!0}}function a7(e,t){return t()}var o7=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?a7:t7;V2.useSyncExternalStore=Vf.useSyncExternalStore!==void 0?Vf.useSyncExternalStore:o7});var eh=yo((wye,F2)=>{"use strict";F2.exports=B2()});var z2=yo(_2=>{"use strict";var bS=M(),r7=eh();function n7(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var s7=typeof Object.is=="function"?Object.is:n7,i7=r7.useSyncExternalStore,l7=bS.useRef,u7=bS.useEffect,c7=bS.useMemo,f7=bS.useDebugValue;_2.useSyncExternalStoreWithSelector=function(e,t,a,o,r){var n=l7(null);if(n.current===null){var s={hasValue:!1,value:null};n.current=s}else s=n.current;n=c7(function(){function l(m){if(!u){if(u=!0,c=m,m=o(m),r!==void 0&&s.hasValue){var p=s.value;if(r(p,m))return d=p}return d=m}if(p=d,s7(c,m))return p;var y=o(m);return r!==void 0&&r(p,y)?(c=m,p):(c=m,d=y)}var u=!1,c,d,f=a===void 0?null:a;return[function(){return l(t())},f===null?void 0:function(){return l(f())}]},[t,a,o,r]);var i=i7(e,n[0],n[1]);return u7(function(){s.hasValue=!0,s.value=i},[i]),f7(i),i}});var U2=yo((Aye,H2)=>{"use strict";H2.exports=z2()});var n3=T(M(),1),s3=T(jP(),1);var ux=T(M(),1);var XP=e=>e?.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();function YP(e,t,a=[]){if(t==null)throw new Error("[lucide]: iconNode is required when icon name is used");return{name:XP(e),size:24,node:t,...a.length>0?{aliases:a}:{}}}var WP=e=>{let t="",a=!1;for(let o of e){if(o==="-"||o==="_"||o<=" "){a=t.length>0;continue}t.length===0?t+=o.toLowerCase():t+=a?o.toUpperCase():o,a=!1}return t};var KP=e=>{let t=WP(e);return t.charAt(0).toUpperCase()+t.slice(1)};var Rm=T(M(),1);var Lm=(...e)=>e.filter((t,a,o)=>!!t&&t.trim()!==""&&o.indexOf(t)===a).join(" ").trim();var ei={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":2,"stroke-linecap":"round","stroke-linejoin":"round"};function MR(e){return e!=null}function ZP(e,t={}){let a=t.attributeNames??{},o=f=>a[f]??f,r=e.size??e.width??ei.width,n=e.size??e.height??ei.height,s=e.aliases?.filter(f=>typeof f=="string"&&f.trim()!=="").map(f=>`lucide-${f}`)??[],i=[...e.name?[`lucide-${e.name}`]:[],...s],l=t.className?.split(" ").filter(Boolean)??[],u=t.includeDefaultClasses===!1?Lm(...l):Lm("lucide",...i,...l),c=t.absoluteStrokeWidth?Number(t.strokeWidth??ei["stroke-width"])*Number(e.size??e.width??ei.width)/Number(t.size??t.width??ei.width):t.strokeWidth??ei["stroke-width"];return["svg",{...Object.entries(ei).reduce((f,[m,p])=>(f[o(m)]=p,f),{}),..."color"in t&&t.color&&{[o("stroke")]:t.color},..."size"in t&&MR(t.size)&&{[o("width")]:t.size,[o("height")]:t.size},..."width"in t&&MR(t.width)&&{[o("width")]:t.width},..."height"in t&&MR(t.height)&&{[o("height")]:t.height},[o("stroke-width")]:c,...u&&{[o("class")]:u},[o("viewBox")]:`0 0 ${r} ${n}`,...t.hasA11yProp===!1?{[o("aria-hidden")]:"true"}:{},..."attributes"in t&&t.attributes},e.node.map(f=>{let[m,p,y]=f,b=t.nonScalingStroke?{[o("vector-effect")]:"non-scaling-stroke",...p}:p;return y?[m,b,y]:[m,b]})]}function QP(e,t={}){return ZP(e,{...t,attributeNames:{...t.attributeNames,class:"className","stroke-width":"strokeWidth","stroke-linecap":"strokeLinecap","stroke-linejoin":"strokeLinejoin","vector-effect":"vectorEffect"}})}var JP=e=>{for(let t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0;return!1};var qc=T(M(),1);var F5=(0,qc.createContext)({});var $P=()=>(0,qc.useContext)(F5);var e1=(0,Rm.forwardRef)(({color:e,size:t,width:a,height:o,strokeWidth:r,absoluteStrokeWidth:n,nonScalingStroke:s,className:i="",children:l,iconNode:u=[],icon:c={node:u,aliases:[],size:24},...d},f)=>{let{size:m=24,strokeWidth:p=2,absoluteStrokeWidth:y=!1,nonScalingStroke:b=!1,color:g="currentColor",className:h=""}=$P()??{},x=!!l||JP(d),[S,v,R=[]]=QP(c,{color:e??g,width:a??t??m,height:o??t??m,strokeWidth:r??p,absoluteStrokeWidth:n??y,nonScalingStroke:s??b,className:Lm(h,i),hasA11yProp:x,attributes:d});return(0,Rm.createElement)(S,{ref:f,...v},[...R.map(([L,C])=>(0,Rm.createElement)(L,C)),...Array.isArray(l)?l:[l]])});function Ce(e,t=[],a=[]){let o=typeof e=="string"?YP(e,t,a):e,r=(0,ux.forwardRef)(({className:n,...s},i)=>(0,ux.createElement)(e1,{ref:i,icon:o,className:n,...s}));return o.name&&(r.displayName=KP(o.name)),r}var t1={name:"check",size:24,node:[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]};t1.node;var Jn=Ce(t1);var a1={name:"chevron-down",size:24,node:[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]};a1.node;var ti=Ce(a1);var o1={name:"chevron-up",size:24,node:[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]};o1.node;var Tm=Ce(o1);var r1={name:"circle-check",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m16 9-5.5 5.5L8 12",key:"xofnsj"}]],aliases:["check-circle-2"]};r1.node;var ai=Ce(r1);var n1={name:"circle-slash",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"9",x2:"15",y1:"15",y2:"9",key:"1dfufj"}]]};n1.node;var Im=Ce(n1);var s1={name:"circle-x",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]],aliases:["x-circle"]};s1.node;var oi=Ce(s1);var i1={name:"circle",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]};i1.node;var wm=Ce(i1);var l1={name:"clock",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 6v6l4 2",key:"mmk7yg"}]]};l1.node;var Em=Ce(l1);var u1={name:"copy",size:24,node:[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]};u1.node;var Am=Ce(u1);var c1={name:"earth",size:24,node:[["path",{d:"M21.54 15H17a2 2 0 0 0-2 2v4.54",key:"1djwo0"}],["path",{d:"M7 3.34V5a3 3 0 0 0 3 3a2 2 0 0 1 2 2c0 1.1.9 2 2 2a2 2 0 0 0 2-2c0-1.1.9-2 2-2h3.17",key:"1tzkfa"}],["path",{d:"M11 21.95V18a2 2 0 0 0-2-2a2 2 0 0 1-2-2v-1a2 2 0 0 0-2-2H2.05",key:"14pb5j"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],aliases:["globe-2"]};c1.node;var ri=Ce(c1);var f1={name:"eye",size:24,node:[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]};f1.node;var Dm=Ce(f1);var d1={name:"file-text",size:24,node:[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]};d1.node;var Mm=Ce(d1);var m1={name:"folder-search",size:24,node:[["path",{d:"M10.7 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v4.1",key:"1bw5m7"}],["path",{d:"m21 21-1.9-1.9",key:"1g2n9r"}],["circle",{cx:"17",cy:"17",r:"3",key:"18b49y"}]]};m1.node;var Pm=Ce(m1);var p1={name:"globe",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]};p1.node;var Om=Ce(p1);var h1={name:"hourglass",size:24,node:[["path",{d:"M5 22h14",key:"ehvnwv"}],["path",{d:"M5 2h14",key:"pdyrp9"}],["path",{d:"M17 22v-4.172a2 2 0 0 0-.586-1.414L12 12l-4.414 4.414A2 2 0 0 0 7 17.828V22",key:"1d314k"}],["path",{d:"M7 2v4.172a2 2 0 0 0 .586 1.414L12 12l4.414-4.414A2 2 0 0 0 17 6.172V2",key:"1vvvr6"}]]};h1.node;var km=Ce(h1);var g1={name:"image",size:24,node:[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]]};g1.node;var Nm=Ce(g1);var x1={name:"info",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]};x1.node;var Vm=Ce(x1);var y1={name:"loader-circle",size:24,node:[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],aliases:["loader-2"]};y1.node;var ni=Ce(y1);var S1={name:"message-square",size:24,node:[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}]]};S1.node;var Pl=Ce(S1);var b1={name:"moon",size:24,node:[["path",{d:"M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401",key:"kfwtm"}]]};b1.node;var Bm=Ce(b1);var v1={name:"pencil-line",size:24,node:[["path",{d:"M13 21h8",key:"1jsn5i"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}],["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}]]};v1.node;var si=Ce(v1);var C1={name:"search",size:24,node:[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]]};C1.node;var Br=Ce(C1);var L1={name:"sparkles",size:24,node:[["path",{d:"M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z",key:"1s2grr"}],["path",{d:"M20 2v4",key:"1rf3ol"}],["path",{d:"M22 4h-4",key:"gwowj6"}],["circle",{cx:"4",cy:"20",r:"2",key:"6kqj1y"}]],aliases:["stars"]};L1.node;var ii=Ce(L1);var R1={name:"square-terminal",size:24,node:[["path",{d:"m7 11 2-2-2-2",key:"1lz0vl"}],["path",{d:"M11 13h4",key:"1p7l4v"}],["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}]],aliases:["terminal-square"]};R1.node;var Fr=Ce(R1);var T1={name:"sun",size:24,node:[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]]};T1.node;var Fm=Ce(T1);var I1={name:"wrench",size:24,node:[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]]};I1.node;var li=Ce(I1);var w1={name:"x",size:24,node:[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]};w1.node;var Ol=Ce(w1);var kn=T(M(),1);async function cx(e,t={}){let a=new URLSearchParams;for(let[r,n]of Object.entries(t))n!==void 0&&n!==""&&a.set(r,String(n));let o=await fetch(`${e}${a.size?`?${a}`:""}`);if(!o.ok)throw new Error(`${e}: ${o.status}`);return o.json()}var dr={state:(e,t)=>cx("/api/state",{limit:e,group:t}),run:e=>cx(`/api/run/${e}`),history:e=>cx("/api/history",e),stats:e=>cx("/api/stats",{days:e})};var Ky=T(M(),1);function _m(e,t){if(e&&!t)return e;if(!e&&t)return t;if(e||t)return{...e,...t}}var PR={};function ja(e,t,a,o,r){if(!a&&!o&&!r&&!e)return fx(t);let n=fx(e);return t&&(n=zm(n,t)),a&&(n=zm(n,a)),o&&(n=zm(n,o)),r&&(n=zm(n,r)),n}function E1(e){if(e.length===0)return PR;if(e.length===1)return fx(e[0]);let t=fx(e[0]);for(let a=1;a<e.length;a+=1)t=zm(t,e[a]);return t}function fx(e){return OR(e)?{...D1(e,PR)}:_5(e)}function zm(e,t){return OR(t)?D1(t,e):z5(e,t)}function _5(e){let t={...e};for(let a in t){let o=t[a];A1(a,o)&&(t[a]=M1(o))}return t}function z5(e,t){if(!t)return e;for(let a in t){let o=t[a];switch(a){case"style":{e[a]=_m(e.style,o);break}case"className":{e[a]=kR(e.className,o);break}default:A1(a,o)?e[a]=H5(e[a],o):e[a]=o}}return e}function A1(e,t){let a=e.charCodeAt(0),o=e.charCodeAt(1),r=e.charCodeAt(2);return a===111&&o===110&&r>=65&&r<=90&&(typeof t=="function"||typeof t>"u")}function OR(e){return typeof e=="function"}function D1(e,t){return OR(e)?e(t):e??PR}function H5(e,t){return t?e?(...a)=>{let o=a[0];if(P1(o)){let n=o;Hm(n);let s=t(...a);return n.baseUIHandlerPrevented||e?.(...a),s}let r=t(...a);return e?.(...a),r}:M1(t):e}function M1(e){return e&&((...t)=>{let a=t[0];return P1(a)&&Hm(a),e(...t)})}function Hm(e){return e.preventBaseUIHandler=()=>{e.baseUIHandlerPrevented=!0},e}function kR(e,t){return t?e?t+" "+e:t:e}function P1(e){return e!=null&&typeof e=="object"&&"nativeEvent"in e}function U5(e,t){return function(o,...r){let n=new URL(e);return n.searchParams.set("code",o.toString()),r.forEach(s=>n.searchParams.append("args[]",s)),`${t} error #${o}; visit ${n} for the full message.`}}var q5=U5("https://base-ui.com/production-error","Base UI"),Me=q5;var ui=T(M(),1);var k1=T(M(),1),O1={};function at(e,t){let a=k1.useRef(O1);return a.current===O1&&(a.current=e(t)),a}function mr(e,t,a,o){let r=at(V1).current;return G5(r,e,t,a,o)&&B1(r,[e,t,a,o]),r.callback}function N1(e){let t=at(V1).current;return j5(t,e)&&B1(t,e),t.callback}function V1(){return{callback:null,cleanup:null,refs:[]}}function G5(e,t,a,o,r){return e.refs[0]!==t||e.refs[1]!==a||e.refs[2]!==o||e.refs[3]!==r}function j5(e,t){return e.refs.length!==t.length||e.refs.some((a,o)=>a!==t[o])}function B1(e,t){if(e.refs=t,t.every(a=>a==null)){e.callback=null;return}e.callback=a=>{if(e.cleanup&&(e.cleanup(),e.cleanup=null),a!=null){let o=Array(t.length).fill(null);for(let r=0;r<t.length;r+=1){let n=t[r];if(n!=null)switch(typeof n){case"function":{let s=n(a);typeof s=="function"&&(o[r]=s);break}case"object":{n.current=a;break}default:}}e.cleanup=()=>{for(let r=0;r<t.length;r+=1){let n=t[r];if(n!=null)switch(typeof n){case"function":{let s=o[r];typeof s=="function"?s():n(null);break}case"object":{n.current=null;break}default:}}}}}}var _1=T(M(),1);var F1=T(M(),1),X5=parseInt(F1.version,10);function Gc(e){return X5>=e}function NR(e){if(!_1.isValidElement(e))return null;let t=e,a=t.props;return(Gc(19)?a?.ref:t.ref)??null}function Ve(){}var Io=Object.freeze([]),Ke=Object.freeze({});function z1(e,t){let a={};for(let o in e){let r=e[o];if(t?.hasOwnProperty(o)){let n=t[o](r);n!=null&&Object.assign(a,n);continue}r===!0?a[`data-${o.toLowerCase()}`]="":r&&(a[`data-${o.toLowerCase()}`]=r.toString())}return a}function H1(e,t){return typeof e=="function"?e(t):e}function U1(e,t){return typeof e=="function"?e(t):e}var VR=T(M(),1);function $(e,t,a={}){let o=t.render;a.enabled!==!1&&(o=Z5(o));let r=Y5(t,a,o);if(a.enabled===!1)return null;let n=a.state??Ke;return Q5(e,o,r,n)}function Y5(e,t,a){let{className:o,style:r}=e,{state:n=Ke,ref:s,props:i,stateAttributesMapping:l,enabled:u=!0}=t,c=u?H1(o,n):void 0,d=u?U1(r,n):void 0,f=u?z1(n,l):Ke,m=u&&i?W5(i):void 0,p=u?_m(f,m)??{}:Ke;return typeof document<"u"&&(u?Array.isArray(s)?p.ref=N1([p.ref,NR(a),...s]):p.ref=mr(p.ref,NR(a),s):mr(null,null)),u?(c!==void 0&&(p.className=kR(p.className,c)),d!==void 0&&(p.style=_m(p.style,d)),p):Ke}function W5(e){return Array.isArray(e)?E1(e):ja(void 0,e)}var K5=Symbol.for("react.lazy");function Z5(e){if(e?.$$typeof!==K5)return e;let t=ui.Children.toArray(e)[0];return ui.isValidElement(t)?t:e}function Q5(e,t,a,o){if(t){if(typeof t=="function")return t(a,o);let r=ja(a,t.props);return r.ref=a.ref,ui.cloneElement(t,r)}if(e&&typeof e=="string")return J5(e,a);throw new Error(Me(8))}function J5(e,t){return e==="button"?(0,VR.createElement)("button",{type:"button",...t,key:t.key}):e==="img"?(0,VR.createElement)("img",{alt:"",...t,key:t.key}):ui.createElement(e,t)}function q1(e){return $(e.defaultTagName??"div",e,e)}function G1(e){var t,a,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var r=e.length;for(t=0;t<r;t++)e[t]&&(a=G1(e[t]))&&(o&&(o+=" "),o+=a)}else for(a in e)e[a]&&(o&&(o+=" "),o+=a);return o}function dx(){for(var e,t,a=0,o="",r=arguments.length;a<r;a++)(e=arguments[a])&&(t=G1(e))&&(o&&(o+=" "),o+=t);return o}var j1=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,X1=dx,jc=(e,t)=>a=>{var o;if(t?.variants==null)return X1(e,a?.class,a?.className);let{variants:r,defaultVariants:n}=t,s=Object.keys(r).map(u=>{let c=a?.[u],d=n?.[u];if(c===null)return null;let f=j1(c)||j1(d);return r[u][f]}),i=a&&Object.entries(a).reduce((u,c)=>{let[d,f]=c;return f===void 0||(u[d]=f),u},{}),l=t==null||(o=t.compoundVariants)===null||o===void 0?void 0:o.reduce((u,c)=>{let{class:d,className:f,...m}=c;return Object.entries(m).every(p=>{let[y,b]=p;return Array.isArray(b)?b.includes({...n,...i}[y]):{...n,...i}[y]===b})?[...u,d,f]:u},[]);return X1(e,s,l,a?.class,a?.className)};var $5=(e,t)=>{let a=new Array(e.length+t.length);for(let o=0;o<e.length;o++)a[o]=e[o];for(let o=0;o<t.length;o++)a[e.length+o]=t[o];return a},eG=(e,t)=>({classGroupId:e,validator:t}),J1=(e=new Map,t=null,a)=>({nextPart:e,validators:t,classGroupId:a});var Y1=[],tG="arbitrary..",aG=e=>{let t=rG(e),{conflictingClassGroups:a,conflictingClassGroupModifiers:o}=e;return{getClassGroupId:s=>{if(s.startsWith("[")&&s.endsWith("]"))return oG(s);let i=s.split("-"),l=i[0]===""&&i.length>1?1:0;return $1(i,l,t)},getConflictingClassGroupIds:(s,i)=>{if(i){let l=o[s],u=a[s];return l?u?$5(u,l):l:u||Y1}return a[s]||Y1}}},$1=(e,t,a)=>{if(e.length-t===0)return a.classGroupId;let r=e[t],n=a.nextPart.get(r);if(n){let u=$1(e,t+1,n);if(u)return u}let s=a.validators;if(s===null)return;let i=t===0?e.join("-"):e.slice(t).join("-"),l=s.length;for(let u=0;u<l;u++){let c=s[u];if(c.validator(i))return c.classGroupId}},oG=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{let t=e.slice(1,-1),a=t.indexOf(":"),o=t.slice(0,a);return o?tG+o:void 0})(),rG=e=>{let{theme:t,classGroups:a}=e;return nG(a,t)},nG=(e,t)=>{let a=J1();for(let o in e){let r=e[o];FR(r,a,o,t)}return a},FR=(e,t,a,o)=>{let r=e.length;for(let n=0;n<r;n++){let s=e[n];sG(s,t,a,o)}},sG=(e,t,a,o)=>{if(typeof e=="string"){iG(e,t,a);return}if(typeof e=="function"){lG(e,t,a,o);return}uG(e,t,a,o)},iG=(e,t,a)=>{let o=e===""?t:eO(t,e);o.classGroupId=a},lG=(e,t,a,o)=>{if(cG(e)){FR(e(o),t,a,o);return}t.validators===null&&(t.validators=[]),t.validators.push(eG(a,e))},uG=(e,t,a,o)=>{let r=Object.entries(e),n=r.length;for(let s=0;s<n;s++){let[i,l]=r[s];FR(l,eO(t,i),a,o)}},eO=(e,t)=>{let a=e,o=t.split("-"),r=o.length;for(let n=0;n<r;n++){let s=o[n],i=a.nextPart.get(s);i||(i=J1(),a.nextPart.set(s,i)),a=i}return a},cG=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,fG=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,a=Object.create(null),o=Object.create(null),r=(n,s)=>{a[n]=s,t++,t>e&&(t=0,o=a,a=Object.create(null))};return{get(n){let s=a[n];if(s!==void 0)return s;if((s=o[n])!==void 0)return r(n,s),s},set(n,s){n in a?a[n]=s:r(n,s)}}};var dG=[],W1=(e,t,a,o,r)=>({modifiers:e,hasImportantModifier:t,baseClassName:a,maybePostfixModifierPosition:o,isExternal:r}),mG=e=>{let{prefix:t,experimentalParseClassName:a}=e,o=r=>{let n=[],s=0,i=0,l=0,u,c=r.length;for(let y=0;y<c;y++){let b=r[y];if(s===0&&i===0){if(b===":"){n.push(r.slice(l,y)),l=y+1;continue}if(b==="/"){u=y;continue}}b==="["?s++:b==="]"?s--:b==="("?i++:b===")"&&i--}let d=n.length===0?r:r.slice(l),f=d,m=!1;d.endsWith("!")?(f=d.slice(0,-1),m=!0):d.startsWith("!")&&(f=d.slice(1),m=!0);let p=u&&u>l?u-l:void 0;return W1(n,m,f,p)};if(t){let r=t+":",n=o;o=s=>s.startsWith(r)?n(s.slice(r.length)):W1(dG,!1,s,void 0,!0)}if(a){let r=o;o=n=>a({className:n,parseClassName:r})}return o},pG=e=>{let t=new Map;return e.orderSensitiveModifiers.forEach((a,o)=>{t.set(a,1e6+o)}),a=>{let o=[],r=[];for(let n=0;n<a.length;n++){let s=a[n],i=s[0]==="[",l=t.has(s);i||l?(r.length>0&&(r.sort(),o.push(...r),r=[]),o.push(s)):r.push(s)}return r.length>0&&(r.sort(),o.push(...r)),o}},hG=e=>({cache:fG(e.cacheSize),parseClassName:mG(e),sortModifiers:pG(e),postfixLookupClassGroupIds:gG(e),...aG(e)}),gG=e=>{let t=Object.create(null),a=e.postfixLookupClassGroups;if(a)for(let o=0;o<a.length;o++)t[a[o]]=!0;return t},xG=/\s+/,yG=(e,t)=>{let{parseClassName:a,getClassGroupId:o,getConflictingClassGroupIds:r,sortModifiers:n,postfixLookupClassGroupIds:s}=t,i=[],l=e.trim().split(xG),u="";for(let c=l.length-1;c>=0;c-=1){let d=l[c],{isExternal:f,modifiers:m,hasImportantModifier:p,baseClassName:y,maybePostfixModifierPosition:b}=a(d);if(f){u=d+(u.length>0?" "+u:u);continue}let g=!!b,h;if(g){let L=y.substring(0,b);h=o(L);let C=h&&s[h]?o(y):void 0;C&&C!==h&&(h=C,g=!1)}else h=o(y);if(!h){if(!g){u=d+(u.length>0?" "+u:u);continue}if(h=o(y),!h){u=d+(u.length>0?" "+u:u);continue}g=!1}let x=m.length===0?"":m.length===1?m[0]:n(m).join(":"),S=p?x+"!":x,v=S+h;if(i.indexOf(v)>-1)continue;i.push(v);let R=r(h,g);for(let L=0;L<R.length;++L){let C=R[L];i.push(S+C)}u=d+(u.length>0?" "+u:u)}return u},SG=(...e)=>{let t=0,a,o,r="";for(;t<e.length;)(a=e[t++])&&(o=tO(a))&&(r&&(r+=" "),r+=o);return r},tO=e=>{if(typeof e=="string")return e;let t,a="";for(let o=0;o<e.length;o++)e[o]&&(t=tO(e[o]))&&(a&&(a+=" "),a+=t);return a},bG=(e,...t)=>{let a,o,r,n,s=l=>{let u=t.reduce((c,d)=>d(c),e());return a=hG(u),o=a.cache.get,r=a.cache.set,n=i,i(l)},i=l=>{let u=o(l);if(u)return u;let c=yG(l,a);return r(l,c),c};return n=s,(...l)=>n(SG(...l))},vG=[],ca=e=>{let t=a=>a[e]||vG;return t.isThemeGetter=!0,t.themeKey=e,t},aO=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,oO=/^\((?:(\w[\w-]*):)?(.+)\)$/i,CG=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,LG=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,RG=/\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$/,TG=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix|color|light-dark)\(.+\)$/,IG=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,wG=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,ci=e=>CG.test(e),je=e=>!!e&&!Number.isNaN(Number(e)),dn=e=>!!e&&Number.isInteger(Number(e)),BR=e=>e.endsWith("%")&&je(e.slice(0,-1)),$n=e=>LG.test(e),rO=()=>!0,EG=e=>RG.test(e)&&!TG.test(e),_R=()=>!1,AG=e=>IG.test(e),DG=e=>wG.test(e),MG=e=>!xe(e)&&!ye(e),PG=e=>e.startsWith("@container")&&(e[10]==="/"&&e[11]!==void 0||e[11]==="s"&&e[16]!==void 0&&e.startsWith("-size/",10)||e[11]==="n"&&e[18]!==void 0&&e.startsWith("-normal/",10)),OG=e=>fi(e,iO,_R),xe=e=>aO.test(e),kl=e=>fi(e,lO,EG),K1=e=>fi(e,HG,je),kG=e=>fi(e,cO,rO),NG=e=>fi(e,uO,_R),Z1=e=>fi(e,nO,_R),VG=e=>fi(e,sO,DG),mx=e=>fi(e,fO,AG),ye=e=>oO.test(e),Um=e=>Nl(e,lO),BG=e=>Nl(e,uO),Q1=e=>Nl(e,nO),FG=e=>Nl(e,iO),_G=e=>Nl(e,sO),px=e=>Nl(e,fO,!0),zG=e=>Nl(e,cO,!0),fi=(e,t,a)=>{let o=aO.exec(e);return o?o[1]?t(o[1]):a(o[2]):!1},Nl=(e,t,a=!1)=>{let o=oO.exec(e);return o?o[1]?t(o[1]):a:!1},nO=e=>e==="position"||e==="percentage",sO=e=>e==="image"||e==="url",iO=e=>e==="length"||e==="size"||e==="bg-size",lO=e=>e==="length",HG=e=>e==="number",uO=e=>e==="family-name",cO=e=>e==="number"||e==="weight",fO=e=>e==="shadow";var UG=()=>{let e=ca("color"),t=ca("font"),a=ca("text"),o=ca("font-weight"),r=ca("tracking"),n=ca("leading"),s=ca("breakpoint"),i=ca("container"),l=ca("spacing"),u=ca("radius"),c=ca("shadow"),d=ca("inset-shadow"),f=ca("text-shadow"),m=ca("drop-shadow"),p=ca("blur"),y=ca("perspective"),b=ca("aspect"),g=ca("ease"),h=ca("animate"),x=()=>["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"],v=()=>[...S(),ye,xe],R=()=>["auto","hidden","clip","visible","scroll"],L=()=>["auto","contain","none"],C=()=>[ye,xe,l],E=()=>[ci,"full","auto",...C()],I=()=>[dn,"none","subgrid",ye,xe],A=()=>["auto",{span:["full",dn,ye,xe]},dn,ye,xe],N=()=>[dn,"auto",ye,xe],D=()=>["auto","min","max","fr",ye,xe],F=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],k=()=>["start","end","center","stretch","center-safe","end-safe"],z=()=>["auto",...C()],q=()=>[ci,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...C()],O=()=>[i,ci,"screen","full","dvw","lvw","svw","min","max","fit",...C()],V=()=>[ci,"screen","full","lh","dvh","lvh","svh","min","max","fit",...C()],w=()=>[e,ye,xe],_=()=>[...S(),Q1,Z1,{position:[ye,xe]}],U=()=>["no-repeat",{repeat:["","x","y","space","round"]}],X=()=>["auto","cover","contain",FG,OG,{size:[ye,xe]}],P=()=>[BR,Um,kl],H=()=>["","none","full",u,ye,xe],B=()=>["",je,Um,kl],J=()=>["solid","dashed","dotted","double"],Y=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],te=()=>[je,BR,Q1,Z1],ie=()=>["","none",p,ye,xe],ce=()=>["none",je,ye,xe],ee=()=>["none",je,ye,xe],ae=()=>[je,ye,xe],me=()=>[ci,"full",...C()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[$n],breakpoint:[$n],color:[rO],container:[$n],"drop-shadow":[$n],ease:["in","out","in-out"],font:[MG],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[$n],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[$n],shadow:[$n],spacing:["px",je],text:[$n],"text-shadow":[$n],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",ci,xe,ye,b]}],container:["container"],"container-type":[{"@container":["","normal","size",ye,xe]}],"container-named":[PG],columns:[{columns:[je,"auto",xe,ye,i]}],"break-after":[{"break-after":x()}],"break-before":[{"break-before":x()}],"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:v()}],overflow:[{overflow:R()}],"overflow-x":[{"overflow-x":R()}],"overflow-y":[{"overflow-y":R()}],overscroll:[{overscroll:L()}],"overscroll-x":[{"overscroll-x":L()}],"overscroll-y":[{"overscroll-y":L()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:E()}],"inset-x":[{"inset-x":E()}],"inset-y":[{"inset-y":E()}],start:[{"inset-s":E(),start:E()}],end:[{"inset-e":E(),end:E()}],"inset-bs":[{"inset-bs":E()}],"inset-be":[{"inset-be":E()}],top:[{top:E()}],right:[{right:E()}],bottom:[{bottom:E()}],left:[{left:E()}],visibility:["visible","invisible","collapse"],z:[{z:[dn,"auto",ye,xe]}],basis:[{basis:[ci,"full","auto",i,...C()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[je,ci,"auto","initial","none",xe]}],grow:[{grow:["",je,ye,xe]}],shrink:[{shrink:["",je,ye,xe]}],order:[{order:[dn,"first","last","none",ye,xe]}],"grid-cols":[{"grid-cols":I()}],"col-start-end":[{col:A()}],"col-start":[{"col-start":N()}],"col-end":[{"col-end":N()}],"grid-rows":[{"grid-rows":I()}],"row-start-end":[{row:A()}],"row-start":[{"row-start":N()}],"row-end":[{"row-end":N()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":D()}],"auto-rows":[{"auto-rows":D()}],gap:[{gap:C()}],"gap-x":[{"gap-x":C()}],"gap-y":[{"gap-y":C()}],"justify-content":[{justify:[...F(),"normal"]}],"justify-items":[{"justify-items":[...k(),"normal"]}],"justify-self":[{"justify-self":["auto",...k()]}],"align-content":[{content:["normal",...F()]}],"align-items":[{items:[...k(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...k(),{baseline:["","last"]}]}],"place-content":[{"place-content":F()}],"place-items":[{"place-items":[...k(),"baseline"]}],"place-self":[{"place-self":["auto",...k()]}],p:[{p:C()}],px:[{px:C()}],py:[{py:C()}],ps:[{ps:C()}],pe:[{pe:C()}],pbs:[{pbs:C()}],pbe:[{pbe:C()}],pt:[{pt:C()}],pr:[{pr:C()}],pb:[{pb:C()}],pl:[{pl:C()}],m:[{m:z()}],mx:[{mx:z()}],my:[{my:z()}],ms:[{ms:z()}],me:[{me:z()}],mbs:[{mbs:z()}],mbe:[{mbe:z()}],mt:[{mt:z()}],mr:[{mr:z()}],mb:[{mb:z()}],ml:[{ml:z()}],"space-x":[{"space-x":C()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":C()}],"space-y-reverse":["space-y-reverse"],size:[{size:q()}],"inline-size":[{inline:["auto",...O()]}],"min-inline-size":[{"min-inline":["auto",...O()]}],"max-inline-size":[{"max-inline":["none",...O()]}],"block-size":[{block:["auto",...V()]}],"min-block-size":[{"min-block":["auto",...V()]}],"max-block-size":[{"max-block":["none",...V()]}],w:[{w:[i,"screen",...q()]}],"min-w":[{"min-w":[i,"screen","none",...q()]}],"max-w":[{"max-w":[i,"screen","none","prose",{screen:[s]},...q()]}],h:[{h:["screen","lh",...q()]}],"min-h":[{"min-h":["screen","lh","none",...q()]}],"max-h":[{"max-h":["screen","lh","none",...q()]}],"font-size":[{text:["base",a,Um,kl]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[o,zG,kG]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",BR,xe]}],"font-family":[{font:[BG,NG,t]}],"font-features":[{"font-features":[xe]}],"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:[r,ye,xe]}],"line-clamp":[{"line-clamp":[je,"none",ye,K1]}],leading:[{leading:["none",n,...C()]}],"list-image":[{"list-image":["none",ye,xe]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",ye,xe]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:w()}],"text-color":[{text:w()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...J(),"wavy"]}],"text-decoration-thickness":[{decoration:[je,"from-font","auto",ye,kl]}],"text-decoration-color":[{decoration:w()}],"underline-offset":[{"underline-offset":[je,"auto",ye,xe]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:C()}],"tab-size":[{tab:[dn,ye,xe]}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",ye,xe]}],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",ye,xe]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:_()}],"bg-repeat":[{bg:U()}],"bg-size":[{bg:X()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},dn,ye,xe],radial:["",ye,xe],conic:["",dn,ye,xe]},_G,VG]}],"bg-color":[{bg:w()}],"gradient-from-pos":[{from:P()}],"gradient-via-pos":[{via:P()}],"gradient-to-pos":[{to:P()}],"gradient-from":[{from:w()}],"gradient-via":[{via:w()}],"gradient-to":[{to:w()}],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:B()}],"border-w-x":[{"border-x":B()}],"border-w-y":[{"border-y":B()}],"border-w-s":[{"border-s":B()}],"border-w-e":[{"border-e":B()}],"border-w-bs":[{"border-bs":B()}],"border-w-be":[{"border-be":B()}],"border-w-t":[{"border-t":B()}],"border-w-r":[{"border-r":B()}],"border-w-b":[{"border-b":B()}],"border-w-l":[{"border-l":B()}],"divide-x":[{"divide-x":B()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":B()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...J(),"hidden","none"]}],"divide-style":[{divide:[...J(),"hidden","none"]}],"border-color":[{border:w()}],"border-color-x":[{"border-x":w()}],"border-color-y":[{"border-y":w()}],"border-color-s":[{"border-s":w()}],"border-color-e":[{"border-e":w()}],"border-color-bs":[{"border-bs":w()}],"border-color-be":[{"border-be":w()}],"border-color-t":[{"border-t":w()}],"border-color-r":[{"border-r":w()}],"border-color-b":[{"border-b":w()}],"border-color-l":[{"border-l":w()}],"divide-color":[{divide:w()}],"outline-style":[{outline:[...J(),"none","hidden"]}],"outline-offset":[{"outline-offset":[je,ye,xe]}],"outline-w":[{outline:["",je,Um,kl]}],"outline-color":[{outline:w()}],shadow:[{shadow:["","inner","none",c,px,mx]}],"shadow-color":[{shadow:w()}],"inset-shadow":[{"inset-shadow":["none",d,px,mx]}],"inset-shadow-color":[{"inset-shadow":w()}],"ring-w":[{ring:B()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:w()}],"ring-offset-w":[{"ring-offset":[je,kl]}],"ring-offset-color":[{"ring-offset":w()}],"inset-ring-w":[{"inset-ring":B()}],"inset-ring-color":[{"inset-ring":w()}],"text-shadow":[{"text-shadow":["none",f,px,mx]}],"text-shadow-color":[{"text-shadow":w()}],opacity:[{opacity:[je,ye,xe]}],"mix-blend":[{"mix-blend":[...Y(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":Y()}],"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":[je]}],"mask-image-linear-from-pos":[{"mask-linear-from":te()}],"mask-image-linear-to-pos":[{"mask-linear-to":te()}],"mask-image-linear-from-color":[{"mask-linear-from":w()}],"mask-image-linear-to-color":[{"mask-linear-to":w()}],"mask-image-t-from-pos":[{"mask-t-from":te()}],"mask-image-t-to-pos":[{"mask-t-to":te()}],"mask-image-t-from-color":[{"mask-t-from":w()}],"mask-image-t-to-color":[{"mask-t-to":w()}],"mask-image-r-from-pos":[{"mask-r-from":te()}],"mask-image-r-to-pos":[{"mask-r-to":te()}],"mask-image-r-from-color":[{"mask-r-from":w()}],"mask-image-r-to-color":[{"mask-r-to":w()}],"mask-image-b-from-pos":[{"mask-b-from":te()}],"mask-image-b-to-pos":[{"mask-b-to":te()}],"mask-image-b-from-color":[{"mask-b-from":w()}],"mask-image-b-to-color":[{"mask-b-to":w()}],"mask-image-l-from-pos":[{"mask-l-from":te()}],"mask-image-l-to-pos":[{"mask-l-to":te()}],"mask-image-l-from-color":[{"mask-l-from":w()}],"mask-image-l-to-color":[{"mask-l-to":w()}],"mask-image-x-from-pos":[{"mask-x-from":te()}],"mask-image-x-to-pos":[{"mask-x-to":te()}],"mask-image-x-from-color":[{"mask-x-from":w()}],"mask-image-x-to-color":[{"mask-x-to":w()}],"mask-image-y-from-pos":[{"mask-y-from":te()}],"mask-image-y-to-pos":[{"mask-y-to":te()}],"mask-image-y-from-color":[{"mask-y-from":w()}],"mask-image-y-to-color":[{"mask-y-to":w()}],"mask-image-radial":[{"mask-radial":[ye,xe]}],"mask-image-radial-from-pos":[{"mask-radial-from":te()}],"mask-image-radial-to-pos":[{"mask-radial-to":te()}],"mask-image-radial-from-color":[{"mask-radial-from":w()}],"mask-image-radial-to-color":[{"mask-radial-to":w()}],"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":[je]}],"mask-image-conic-from-pos":[{"mask-conic-from":te()}],"mask-image-conic-to-pos":[{"mask-conic-to":te()}],"mask-image-conic-from-color":[{"mask-conic-from":w()}],"mask-image-conic-to-color":[{"mask-conic-to":w()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:_()}],"mask-repeat":[{mask:U()}],"mask-size":[{mask:X()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",ye,xe]}],filter:[{filter:["","none",ye,xe]}],blur:[{blur:ie()}],brightness:[{brightness:[je,ye,xe]}],contrast:[{contrast:[je,ye,xe]}],"drop-shadow":[{"drop-shadow":["","none",m,px,mx]}],"drop-shadow-color":[{"drop-shadow":w()}],grayscale:[{grayscale:["",je,ye,xe]}],"hue-rotate":[{"hue-rotate":[je,ye,xe]}],invert:[{invert:["",je,ye,xe]}],saturate:[{saturate:[je,ye,xe]}],sepia:[{sepia:["",je,ye,xe]}],"backdrop-filter":[{"backdrop-filter":["","none",ye,xe]}],"backdrop-blur":[{"backdrop-blur":ie()}],"backdrop-brightness":[{"backdrop-brightness":[je,ye,xe]}],"backdrop-contrast":[{"backdrop-contrast":[je,ye,xe]}],"backdrop-grayscale":[{"backdrop-grayscale":["",je,ye,xe]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[je,ye,xe]}],"backdrop-invert":[{"backdrop-invert":["",je,ye,xe]}],"backdrop-opacity":[{"backdrop-opacity":[je,ye,xe]}],"backdrop-saturate":[{"backdrop-saturate":[je,ye,xe]}],"backdrop-sepia":[{"backdrop-sepia":["",je,ye,xe]}],"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",ye,xe]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[je,"initial",ye,xe]}],ease:[{ease:["linear","initial",g,ye,xe]}],delay:[{delay:[je,ye,xe]}],animate:[{animate:["none",h,ye,xe]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[y,ye,xe]}],"perspective-origin":[{"perspective-origin":v()}],rotate:[{rotate:ce()}],"rotate-x":[{"rotate-x":ce()}],"rotate-y":[{"rotate-y":ce()}],"rotate-z":[{"rotate-z":ce()}],scale:[{scale:ee()}],"scale-x":[{"scale-x":ee()}],"scale-y":[{"scale-y":ee()}],"scale-z":[{"scale-z":ee()}],"scale-3d":["scale-3d"],skew:[{skew:ae()}],"skew-x":[{"skew-x":ae()}],"skew-y":[{"skew-y":ae()}],transform:[{transform:[ye,xe,"","none","gpu","cpu"]}],"transform-origin":[{origin:v()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:me()}],"translate-x":[{"translate-x":me()}],"translate-y":[{"translate-y":me()}],"translate-z":[{"translate-z":me()}],"translate-none":["translate-none"],zoom:[{zoom:[dn,ye,xe]}],accent:[{accent:w()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:w()}],"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",ye,xe]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scrollbar-thumb-color":[{"scrollbar-thumb":w()}],"scrollbar-track-color":[{"scrollbar-track":w()}],"scrollbar-gutter":[{"scrollbar-gutter":["auto","stable","both"]}],"scrollbar-w":[{scrollbar:["auto","thin","none"]}],"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-mbs":[{"scroll-mbs":C()}],"scroll-mbe":[{"scroll-mbe":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-pbs":[{"scroll-pbs":C()}],"scroll-pbe":[{"scroll-pbe":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",ye,xe]}],fill:[{fill:["none",...w()]}],"stroke-w":[{stroke:[je,Um,kl,K1]}],stroke:[{stroke:["none",...w()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{"container-named":["container-type"],overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","inset-bs","inset-be","start","end","top","right","bottom","left"],"inset-x":["start","end","right","left"],"inset-y":["inset-bs","inset-be","top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pbs","pbe","pt","pr","pb","pl"],px:["ps","pe","pr","pl"],py:["pbs","pbe","pt","pb"],m:["mx","my","ms","me","mbs","mbe","mt","mr","mb","ml"],mx:["ms","me","mr","ml"],my:["mbs","mbe","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-bs","border-w-be","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-s","border-w-e","border-w-r","border-w-l"],"border-w-y":["border-w-bs","border-w-be","border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-bs","border-color-be","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-s","border-color-e","border-color-r","border-color-l"],"border-color-y":["border-color-bs","border-color-be","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-mbs","scroll-mbe","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-ms","scroll-me","scroll-mr","scroll-ml"],"scroll-my":["scroll-mbs","scroll-mbe","scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pbs","scroll-pbe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-ps","scroll-pe","scroll-pr","scroll-pl"],"scroll-py":["scroll-pbs","scroll-pbe","scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},postfixLookupClassGroups:["container-type"],orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}};var dO=bG(UG);function re(...e){return dO(dx(e))}var qG=jc("group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!",{variants:{variant:{default:"bg-primary text-primary-foreground [a]:hover:bg-primary/80",secondary:"bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80",destructive:"bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20",outline:"border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground",ghost:"hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50",link:"text-primary underline-offset-4 hover:underline"}},defaultVariants:{variant:"default"}});function hx({className:e,variant:t="default",render:a,...o}){return q1({defaultTagName:"span",props:ja({className:re(qG({variant:t}),e)},o),render:a,state:{slot:"badge",variant:t}})}var es=e=>(e=Math.max(0,Math.round(e)),e>=3600?`${Math.floor(e/3600)}h ${String(Math.floor(e%3600/60)).padStart(2,"0")}m`:e>=60?`${Math.floor(e/60)}m ${String(e%60).padStart(2,"0")}s`:`${e}s`),ts=e=>e>=1e6?`${(e/1e6).toFixed(1)}M`:e>=1e3?`${Math.round(e/1e3)}k`:String(e),pr=e=>`$${e.toFixed(2)}`;function mO(e){let t=(Date.now()-Date.parse(e))/1e3;return t<45?"just now":t<3600?`${Math.round(t/60)} min ago`:t<86400?`${Math.round(t/3600)} h ago`:t<86400*14?`${Math.round(t/86400)} d ago`:new Date(e).toLocaleDateString([],{month:"short",day:"numeric"})}function pO(e){let t=/^(\S+)(?: \((.*)\))?$/.exec(e);return{backend:t?.[1]??e,model:t?.[2]}}var hO={opencode:"var(--info)",codex:"var(--success)",claude:"var(--brand)"};var Vl=T(Q(),1);function Xc({worker:e,backend:t,model:a}){let o=e?pO(e):{backend:t??"",model:a};return(0,Vl.jsxs)(hx,{variant:"outline",className:"gap-1.5 pl-1.5",children:[(0,Vl.jsx)("span",{className:"size-1.5 rounded-full",style:{background:hO[o.backend]??"var(--muted-foreground)"}}),o.backend,o.model&&(0,Vl.jsx)("span",{className:"font-normal text-muted-foreground",children:o.model.split("/").pop()})]})}function xx({verdict:e}){let t=/PASS/.test(e)&&/APPROVED/.test(e),a=t?"Approved":/FAIL/.test(e)?"Spec fail":"Needs fixes";return(0,Vl.jsx)(hx,{className:re("border",t?"border-success/30 bg-success/10 text-success":"border-destructive/30 bg-destructive/10 text-destructive"),children:a})}function yx({children:e,tone:t}){return(0,Vl.jsx)(hx,{variant:"secondary",className:re(t==="good"&&"bg-success/10 text-success"),children:e})}var Ip=T(Q(),1),vn=T(M(),1);var SO=T(M(),1),Yc=(0,SO.createContext)({});var bO=T(M(),1);function di(e){let t=(0,bO.useRef)(null);return t.current===null&&(t.current=e()),t.current}var Sx=T(M(),1);var vO=typeof window<"u";var mi=vO?Sx.useLayoutEffect:Sx.useEffect;var Q0=T(Q(),1),HN=T(M(),1),Ti=T(M(),1);var CO=T(M(),1),pi=(0,CO.createContext)(null);var _N=T(Q(),1);function Bl(e,t){e.indexOf(t)===-1&&e.push(t)}function hi(e,t){let a=e.indexOf(t);a>-1&&e.splice(a,1)}var fa=(e,t,a)=>a>t?t:a<e?e:a;var as=()=>{},wo=()=>{};var Ba={};var Fl=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);var qm=e=>typeof e=="object"&&e!==null;var _l=e=>/^0[^.\s]+$/u.test(e);function Gm(e){let t;return()=>(t===void 0&&(t=e()),t)}var Xt=e=>e;var _r=(...e)=>e.reduce((t,a)=>o=>a(t(o)));var mn=(e,t,a)=>{let o=t-e;return o?(a-e)/o:1};var pn=class{constructor(){this.subscriptions=[]}add(t){return Bl(this.subscriptions,t),()=>this.remove(t)}remove(t){hi(this.subscriptions,t)}notify(t,a,o){let r=this.subscriptions.length;if(r)if(r===1)this.subscriptions[0](t,a,o);else for(let n=0;n<r;n++){let s=this.subscriptions[n];s&&s(t,a,o)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}};var oa=e=>e*1e3,ba=e=>e/1e3;var jm=(e,t)=>t?e*(1e3/t):0;var LO=(e,t,a)=>(((1-3*a+3*t)*e+(3*a-6*t))*e+3*t)*e,XG=1e-7,YG=12;function WG(e,t,a,o,r){let n,s,i=0;do s=t+(a-t)/2,n=LO(s,o,r)-e,n>0?a=s:t=s;while(Math.abs(n)>XG&&++i<YG);return s}function gi(e,t,a,o){if(e===t&&a===o)return Xt;let r=n=>WG(n,0,1,e,a);return n=>n===0||n===1?n:LO(r(n),t,o)}var bx=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2;var vx=e=>t=>1-e(1-t);var Cx=gi(.33,1.53,.69,.99),Wc=vx(Cx),Xm=bx(Wc);var Ym=e=>e>=1?1:(e*=2)<1?.5*Wc(e):.5*(2-Math.pow(2,-10*(e-1)));var Wm=e=>1-Math.sin(Math.acos(e)),Km=vx(Wm),Zm=bx(Wm);var zR=gi(.42,0,1,1),HR=gi(0,0,.58,1),Kc=gi(.42,0,.58,1);var UR=e=>Array.isArray(e)&&typeof e[0]!="number";var Qm=e=>Array.isArray(e)&&typeof e[0]=="number";var RO={linear:Xt,easeIn:zR,easeInOut:Kc,easeOut:HR,circIn:Wm,circInOut:Zm,circOut:Km,backIn:Wc,backInOut:Xm,backOut:Cx,anticipate:Ym},KG=e=>typeof e=="string",Lx=e=>{if(Qm(e)){wo(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");let[t,a,o,r]=e;return gi(t,a,o,r)}else if(KG(e))return wo(RO[e]!==void 0,`Invalid easing type '${e}'`,"invalid-easing-type"),RO[e];return e};var Tt={delta:0,timestamp:0,isProcessing:!1};var Rx;function ZG(){Rx=void 0}var gt={now:()=>(Rx===void 0&>.set(Tt.isProcessing||Ba.useManualTiming?Tt.timestamp:performance.now()),Rx),set:e=>{Rx=e,queueMicrotask(ZG)}};var hn=e=>Math.round(e*1e5)/1e5;var TO=e=>t=>typeof t=="string"&&t.startsWith(e),Tx=TO("--"),QG=TO("var(--"),Zc=e=>QG(e)?JG.test(e.split("/*")[0].trim()):!1,JG=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function qR(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}var gn={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},os={...gn,transform:e=>fa(0,1,e)},Jm={...gn,default:1};var Qc=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function IO(e){return e==null}var wO=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu;var Jc=(e,t)=>a=>!!(typeof a=="string"&&wO.test(a)&&a.startsWith(e)||t&&!IO(a)&&Object.prototype.hasOwnProperty.call(a,t)),Ix=(e,t,a)=>o=>{if(typeof o!="string")return o;let[r,n,s,i]=o.match(Qc);return{[e]:parseFloat(r),[t]:parseFloat(n),[a]:parseFloat(s),alpha:i!==void 0?parseFloat(i):1}};var $G=e=>fa(0,255,e),GR={...gn,transform:e=>Math.round($G(e))},xn={test:Jc("rgb","red"),parse:Ix("red","green","blue"),transform:({red:e,green:t,blue:a,alpha:o=1})=>"rgba("+GR.transform(e)+", "+GR.transform(t)+", "+GR.transform(a)+", "+hn(os.transform(o))+")"};function e6(e){let t="",a="",o="",r="";return e.length>5?(t=e.substring(1,3),a=e.substring(3,5),o=e.substring(5,7),r=e.substring(7,9)):(t=e.substring(1,2),a=e.substring(2,3),o=e.substring(3,4),r=e.substring(4,5),t+=t,a+=a,o+=o,r+=r),{red:parseInt(t,16),green:parseInt(a,16),blue:parseInt(o,16),alpha:r?parseInt(r,16)/255:1}}var $m={test:Jc("#"),parse:e6,transform:xn.transform};var ep=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),hr=ep("deg"),Xa=ep("%"),de=ep("px"),jR=ep("vh"),XR=ep("vw"),wx={...Xa,parse:e=>Xa.parse(e)/100,transform:e=>Xa.transform(e*100)};var xi={test:Jc("hsl","hue"),parse:Ix("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:a,alpha:o=1})=>"hsla("+Math.round(e)+", "+Xa.transform(hn(t))+", "+Xa.transform(hn(a))+", "+hn(os.transform(o))+")"};var Gt={test:e=>xn.test(e)||$m.test(e)||xi.test(e),parse:e=>xn.test(e)?xn.parse(e):xi.test(e)?xi.parse(e):$m.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?xn.transform(e):xi.transform(e),getAnimatableNone:e=>{let t=Gt.parse(e);return t.alpha=0,Gt.transform(t)}};var EO=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;var DO=new RegExp(Qc.source),MO=new RegExp(EO.source,"i");function t6(e){return isNaN(e)&&typeof e=="string"&&(DO.test(e)||MO.test(e))}var PO="number",OO="color",a6="var",o6="var(",AO="${}",r6=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function kO(e){let t=e.toString();return DO.test(t)||MO.test(t)}function $c(e){let t=e.toString(),a=[],o={color:[],number:[],var:[]},r=[],n=0,i=t.replace(r6,l=>(Gt.test(l)?(o.color.push(n),r.push(OO),a.push(Gt.parse(l))):l.startsWith(o6)?(o.var.push(n),r.push(a6),a.push(l)):(o.number.push(n),r.push(PO),a.push(parseFloat(l))),++n,AO)).split(AO);return{values:a,split:i,indexes:o,types:r}}function n6(e){return $c(e).values}function NO({split:e,types:t}){let a=e.length;return o=>{let r="";for(let n=0;n<a;n++)if(r+=e[n],o[n]!==void 0){let s=t[n];s===PO?r+=hn(o[n]):s===OO?r+=Gt.transform(o[n]):r+=o[n]}return r}}function s6(e){return NO($c(e))}var i6=e=>typeof e=="number"?0:Gt.test(e)?Gt.getAnimatableNone(e):e,l6=(e,t)=>typeof e=="number"?t?.trim().endsWith("/")?e:0:i6(e);function u6(e){let t=$c(e);return NO(t)(t.values.map((o,r)=>l6(o,t.split[r])))}var Yt={test:t6,parse:n6,createTransformer:s6,getAnimatableNone:u6};function YR(e,t,a){return a<0&&(a+=1),a>1&&(a-=1),a<1/6?e+(t-e)*6*a:a<1/2?t:a<2/3?e+(t-e)*(2/3-a)*6:e}function VO({hue:e,saturation:t,lightness:a,alpha:o}){e/=360,t/=100,a/=100;let r=0,n=0,s=0;if(!t)r=n=s=a;else{let i=a<.5?a*(1+t):a+t-a*t,l=2*a-i;r=YR(l,i,e+1/3),n=YR(l,i,e),s=YR(l,i,e-1/3)}return{red:Math.round(r*255),green:Math.round(n*255),blue:Math.round(s*255),alpha:o}}function ef(e,t){return a=>a>0?t:e}var qe=(e,t,a)=>e+(t-e)*a;var WR=(e,t,a)=>{let o=e*e,r=a*(t*t-o)+o;return r<0?0:Math.sqrt(r)},c6=[$m,xn,xi],f6=e=>c6.find(t=>t.test(e));function BO(e){let t=f6(e);if(!t)return as(!1,`'${e}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!1;let a=t.parse(e);return t===xi&&(a=VO(a)),a}var KR=(e,t)=>{let a=BO(e),o=BO(t);if(!a||!o)return ef(e,t);let r={...a};return n=>(r.red=WR(a.red,o.red,n),r.green=WR(a.green,o.green,n),r.blue=WR(a.blue,o.blue,n),r.alpha=qe(a.alpha,o.alpha,n),xn.transform(r))};var Ex=new Set(["none","hidden"]);function FO(e,t){return Ex.has(e)?a=>a<=0?e:t:a=>a>=1?t:e}function d6(e,t){return a=>qe(e,t,a)}function Ax(e){return typeof e=="number"?d6:typeof e=="string"?Zc(e)?ef:Gt.test(e)?KR:h6:Array.isArray(e)?_O:typeof e=="object"?Gt.test(e)?KR:m6:ef}function _O(e,t){let a=[...e],o=a.length,r=e.map((n,s)=>Ax(n)(n,t[s]));return n=>{for(let s=0;s<o;s++)a[s]=r[s](n);return a}}function m6(e,t){let a={...e,...t},o={};for(let r in a)e[r]!==void 0&&t[r]!==void 0&&(o[r]=Ax(e[r])(e[r],t[r]));return r=>{for(let n in o)a[n]=o[n](r);return a}}function p6(e,t){let a=[],o={color:0,var:0,number:0};for(let r=0;r<t.values.length;r++){let n=t.types[r],s=e.indexes[n][o[n]],i=e.values[s]??0;a[r]=i,o[n]++}return a}var h6=(e,t)=>{let a=Yt.createTransformer(t),o=$c(e),r=$c(t);return o.indexes.var.length===r.indexes.var.length&&o.indexes.color.length===r.indexes.color.length&&o.indexes.number.length>=r.indexes.number.length?Ex.has(e)&&!r.values.length||Ex.has(t)&&!o.values.length?FO(e,t):_r(_O(p6(o,r),r.values),a):(as(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),ef(e,t))};var zO=/^(-?(?:\d+(?:\.\d*)?|\.\d+))([a-z%]*)$/iu;function g6(e,t){let a=zO.exec(e);if(!a)return;let o=zO.exec(t);if(!o||a[2]!==o[2])return;let r=a[2],n=parseFloat(a[1]),s=parseFloat(o[1]);return i=>hn(qe(n,s,i))+r}function tf(e,t,a){if(typeof e=="number"&&typeof t=="number"&&typeof a=="number")return qe(e,t,a);if(typeof e=="string"&&typeof t=="string"){let r=g6(e,t);if(r)return r}return Ax(e)(e,t)}var tp=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function HO(e){let t=new Set,a=new Set,o=!1,r=!1,n=new Set,s={delta:0,timestamp:0,isProcessing:!1};function i(u){n.has(u)&&(a.add(u),e()),u(s)}let l={schedule:(u,c=!1,d=!1)=>{let m=d&&o?t:a;return c&&n.add(u),m.add(u),u},cancel:u=>{a.delete(u),n.delete(u)},process:u=>{if(s=u,o){r=!0;return}o=!0;let c=t;t=a,a=c,t.forEach(i),t.clear(),o=!1,r&&(r=!1,l.process(u))}};return l}var x6=40;function Dx(e,t,a={delta:0,timestamp:0,isProcessing:!1}){let o=!1,r=!0,n=()=>o=!0,s=tp.reduce((x,S)=>(x[S]=HO(n),x),{}),{setup:i,read:l,resolveKeyframes:u,preUpdate:c,update:d,preRender:f,render:m,postRender:p}=s,y=()=>{let x=Ba.useManualTiming,S=x?a.timestamp:performance.now();o=!1,x||(a.delta=r?1e3/60:Math.max(Math.min(S-a.timestamp,x6),1)),a.timestamp=S,a.isProcessing=!0,i.process(a),l.process(a),u.process(a),c.process(a),d.process(a),f.process(a),m.process(a),p.process(a),a.isProcessing=!1,o&&t&&(r=!1,e(y))},b=()=>{o=!0,r=!0,a.isProcessing||e(y)};return{schedule:tp.reduce((x,S)=>{let v=s[S];return x[S]=(R,L=!1,C=!1)=>(o||b(),v.schedule(R,L,C)),x},{}),cancel:x=>{for(let S=0;S<tp.length;S++)s[tp[S]].cancel(x)},state:a,steps:s}}var{schedule:ze,cancel:Eo,steps:ap}=Dx(typeof requestAnimationFrame<"u"?requestAnimationFrame:Xt,!0,Tt);var UO=e=>{let t=({timestamp:a})=>e(a);return{start:(a=!0)=>ze.update(t,a),stop:()=>Eo(t),now:()=>Tt.isProcessing?Tt.timestamp:gt.now()}};var Mx=(e,t,a=10)=>{let o="",r=Math.max(Math.round(t/a),2);for(let n=0;n<r;n++)o+=Math.round(e(n/(r-1))*1e4)/1e4+", ";return`linear(${o.substring(0,o.length-2)})`};function af(e,t=50,a=2e4,o){let r=0,n=e.next(r);for(o?.push(n.value);!n.done&&r<a;)r+=t,n=e.next(r),o?.push(n.value);return r>=a?1/0:r}function qO(e,t=100,a){let o=a({...e,keyframes:[0,t]}),r=Math.min(af(o),2e4);return{type:"keyframes",ease:n=>o.next(r*n).value/t,duration:ba(r)}}var va={stiffness:100,damping:10,mass:1,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05},GO=e=>e<0?1/Math.max(1+e,va.minDamping):Math.max(1-e,va.minDamping);function jO(e,t){if(!(e>1))return 1;let a=Math.sqrt(e*e-1),o=e-a,r=e+a,n=2*a*Math.exp(-t)*(1+t);return XO(s=>r*Math.exp(-o*s)-o*Math.exp(-r*s)-n,s=>Math.exp(-r*s)-Math.exp(-o*s),t)/t}function $R(e,t){return e*Math.sqrt(1-t*t)}var y6=12;function XO(e,t,a){let o=a;for(let r=1;r<y6;r++)o=o-e(o)/t(o);return o}var QR=.001;function S6({duration:e=va.duration,bounce:t=va.bounce}){let a,o;as(e<=oa(va.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let r=GO(t);e=fa(va.minDuration,va.maxDuration,ba(e)),r<1?(a=u=>{let c=u*r,d=c*e,f=$R(u,r),m=Math.exp(-d);return QR-c/f*m},o=u=>{let d=u*r*e,f=r*r*u*u*e,m=Math.exp(-d),p=$R(u*u,r);return(-a(u)+QR>0?-1:1)*-f*m/p}):(a=u=>{let c=Math.exp(-u*e),d=u*e+1;return-QR+c*d},o=u=>{let c=Math.exp(-u*e),d=-u*(e*e);return c*d});let n=5/e,s=XO(a,o,n),i=s*jO(r,s*e),l=i*i;return{stiffness:l,damping:r*2*Math.sqrt(l),duration:oa(e)}}var e0=(e,t)=>(t?e>=0:e>0)&&e<1/0;function JR(e,t){if(e0(e,t))return e}function b6(e){let t=JR(e.stiffness),a=JR(e.damping,!0),o=JR(e.mass),r={...e,stiffness:t??va.stiffness,damping:a??va.damping,mass:o??va.mass,isResolvedFromDuration:!1,isTimeDefined:(t??a??o)===void 0&&(e.duration!==void 0||e.bounce!==void 0)};if(r.isTimeDefined){if(e.visualDuration){let n=GO(e.bounce||0),s=2*Math.PI/(e.visualDuration*1.2)*jO(n,2*Math.PI/1.2);r.stiffness=s*s,r.damping=2*n*Math.sqrt(r.stiffness)}else Object.assign(r,S6(r)),r.isResolvedFromDuration=!0;(!e0(r.stiffness)||!e0(r.damping,!0))&&(r.stiffness=va.stiffness,r.damping=va.damping)}return r}function of(e=va.visualDuration,t=va.bounce){let a=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e,o=a.keyframes[0],r=a.keyframes[a.keyframes.length-1],n={done:!1,value:o},{stiffness:s,damping:i,mass:l,duration:u,isResolvedFromDuration:c,isTimeDefined:d}=b6({...a}),f=L=>d?0:-ba(L),m=i/(2*Math.sqrt(s*l)),p=ba(Math.sqrt(s/l)),y=m*p,b={target:r,delta:r-o,velocity:f(a.velocity||0)||0,restSpeed:0,restDelta:0},g=()=>{let L=Math.abs(b.delta)<5;b.restSpeed=a.restSpeed||(L?va.restSpeed.granular:va.restSpeed.default),b.restDelta=a.restDelta||(L?va.restDelta.granular:va.restDelta.default)};g();let h,x,S;if(m<1){let L=$R(p,m),C={A:0,sinC:0,cosC:0,t:-1,env:0,sin:0,cos:0};S=()=>{C.A=(b.velocity+y*b.delta)/L,C.sinC=y*C.A+b.delta*L,C.cosC=y*b.delta-C.A*L};let E=I=>{I!==C.t&&(C.t=I,C.env=Math.exp(-y*I),C.sin=Math.sin(L*I),C.cos=Math.cos(L*I))};h=I=>(E(I),b.target-C.env*(C.A*C.sin+b.delta*C.cos)),x=I=>(E(I),C.env*(C.sinC*C.sin+C.cosC*C.cos))}else if(m===1){h=C=>b.target-Math.exp(-p*C)*(b.delta+(b.velocity+p*b.delta)*C);let L={C:0};S=()=>{L.C=b.velocity+p*b.delta},x=C=>Math.exp(-p*C)*(p*L.C*C-b.velocity)}else{let L=p*Math.sqrt(m*m-1),C=y-L,E=y+L,I=d?1/0:300/L,A=(D,F)=>Math.exp(F>I?-D*I-y*(F-I):-D*F),N={S:0,F:0};S=()=>{let D=(b.velocity+y*b.delta)/L;N.S=(b.delta+D)/2,N.F=(b.delta-D)/2},h=D=>b.target-N.S*A(C,D)-N.F*A(E,D),x=D=>C*N.S*A(C,D)+E*N.F*A(E,D)}S();let v=c&&u||null,R={calculatedDuration:v,retarget:(L,C)=>{b.target=L[L.length-1],b.delta=b.target-L[0],b.velocity=f(C),a.restSpeed&&a.restDelta||g(),R.calculatedDuration=v,n.done=!1,S()},velocity:L=>oa(x(L)),next:L=>{let C=h(L);if(c)n.done=L>=u;else{let E=oa(x(L));n.done=Math.abs(E)<=b.restSpeed&&Math.abs(b.target-C)<=b.restDelta}return n.value=n.done?b.target:C,n},toString:()=>{let L=Math.min(af(R),2e4),C=Mx(E=>R.next(L*E).value,L,30);return L+"ms "+C},toTransition:()=>{}};return R}of.applyToOptions=e=>{let t=qO(e,100,of);return e.ease=t.ease,e.duration=oa(t.duration),e.type="keyframes",e};function op({keyframes:e,velocity:t=0,power:a=.8,timeConstant:o=325,bounceDamping:r=10,bounceStiffness:n=500,modifyTarget:s,min:i,max:l,restDelta:u=.5,restSpeed:c}){let d=e[0],f={done:!1,value:d},m=L=>L<i||L>l,p=L=>i===void 0?l:l===void 0||Math.abs(i-L)<Math.abs(l-L)?i:l,y=a*t,b=d+y,g=s===void 0?b:s(b);g!==b&&(y=g-d);let h=L=>-y*Math.exp(-L/o),x=L=>{let C=h(L);f.done=Math.abs(C)<=u,f.value=f.done?g:g+C},S,v,R=L=>{m(f.value)&&(S=L,v=of({keyframes:[f.value,p(f.value)],velocity:-h(L)/o*1e3,damping:r,stiffness:n,restDelta:u,restSpeed:c}))};return R(0),{calculatedDuration:null,next:L=>{let C=!1;return!v&&S===void 0&&(C=!0,x(L),R(L)),S!==void 0&&L>=S?v.next(L-S):(!C&&x(L),f)}}}function v6(e,t,a){let o=[],r=a||Ba.mix||tf,n=e.length-1;for(let s=0;s<n;s++){let i=r(e[s],e[s+1]);if(t){let l=Array.isArray(t)?t[s]||Xt:t;i=_r(l,i)}o.push(i)}return o}function YO(e,t,{clamp:a=!0,ease:o,mixer:r}={}){let n=e.length;if(wo(n===t.length,"Both input and output ranges must be the same length","range-length"),n===1)return()=>t[0];if(n===2&&t[0]===t[1])return()=>t[1];let s=e[0]===e[1];e[0]>e[n-1]&&(e=[...e].reverse(),t=[...t].reverse());let i=v6(t,o,r),l=i.length,u=c=>{if(s&&c<e[0])return t[0];let d=0;if(l>1)for(;d<e.length-2&&!(c<e[d+1]);d++);let f=mn(e[d],e[d+1],c);return i[d](f)};return a?c=>u(fa(e[0],e[n-1],c)):u}function WO(e,t){let a=e[e.length-1];for(let o=1;o<=t;o++){let r=mn(0,t,o);e.push(qe(a,1,r))}}function KO(e){let t=[0];return WO(t,e.length-1),t}function ZO(e,t){return e.map(a=>a*t)}function C6(e,t){return e.map(()=>t||Kc).splice(0,e.length-1)}function zl({duration:e=300,keyframes:t,times:a,ease:o="easeInOut"}){let r=UR(o)?o.map(Lx):Lx(o)||Kc,n={done:!1,value:t[0]};if(t.length===2&&!Array.isArray(r)&&(!a||a.length!==2||a[0]===0&&a[1]===1)){let[l,u]=t,c=l===u?void 0:(Ba.mix||tf)(l,u);return{calculatedDuration:e,next:d=>(n.value=c?c(r(e>0?fa(0,1,d/e):1)):u,n.done=d>=e,n)}}let s=ZO(a&&a.length===t.length?a:KO(t),e),i=YO(s,t,{ease:Array.isArray(r)?r:C6(t,r)});return{calculatedDuration:e,next:l=>(n.value=i(l),n.done=l>=e,n)}}var L6=5;function R6(e,t,a){let o=Math.max(t-L6,0);return jm(a-e(o),t-o)}function QO(e,t,a=0){return t<=0?a:e.velocity?e.velocity(t):R6(o=>e.next(o).value,t,e.next(t).value)}var T6=e=>e!==null;function yi(e,{repeat:t,repeatType:a="loop"},o,r=1){let n=e.filter(T6),i=r<0||t&&a!=="loop"&&t%2===1?0:n.length-1;return!i||o===void 0?n[i]:o}var I6={decay:op,inertia:op,tween:zl,keyframes:zl,spring:of};function Px(e){typeof e.type=="string"&&(e.type=I6[e.type])}function JO(e,t){return{kind:e,animation:t,timestamp:gt.now(),frameTimestamp:Tt.timestamp,frameIsProcessing:Tt.isProcessing}}function Ox(e,t,a){let o=globalThis.__MOTION_INSPECT__;if(o)try{o({...JO("animation-start",e),options:a?{...t,...a}:t})}catch{}}function $O(e,t){let a=globalThis.__MOTION_INSPECT__;if(a)try{a({...JO("layout-animation-start",e),node:t})}catch{}}var Si=class{constructor(){this.isResolved=!1}get finished(){return this._finished||(this._finished=this.isResolved?Promise.resolve():new Promise(t=>{this._resolve=t})),this._finished}updateFinished(){this._finished=this._resolve=void 0,this.isResolved=!1}notifyFinished(){this.isResolved=!0,this._resolve?.()}then(t,a){return this.finished.then(t,a)}};var w6=e=>e/100,rs=class extends Si{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{let{motionValue:a}=this.options;a&&a.updatedAt!==gt.now()&&this.tick(gt.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause(),Ox(this,this.options)}initAnimation(){let{options:t}=this;Px(t);let{type:a=zl,repeat:o=0,repeatDelay:r=0,repeatType:n,velocity:s=0}=t,{keyframes:i}=t,l=a||zl;l!==zl&&typeof i[0]!="number"&&(this.mixKeyframes=_r(w6,tf(i[0],i[1])),i=[0,100]);let u=l(i===t.keyframes?t:{...t,keyframes:i});n==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...i].reverse(),velocity:-s})),u.calculatedDuration===null&&(u.calculatedDuration=af(u));let{calculatedDuration:c}=u;this.calculatedDuration=c,this.resolvedDuration=c+r,this.totalDuration=this.resolvedDuration*(o+1)-r,this.generator=u}updateTime(t){let a=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=a}tick(t,a=!1){let{generator:o,totalDuration:r,mixKeyframes:n,mirroredGenerator:s,resolvedDuration:i,calculatedDuration:l}=this;if(this.startTime===null)return o.next(0);let{delay:u=0,keyframes:c,repeat:d,repeatType:f,repeatDelay:m,type:p,onUpdate:y,finalKeyframe:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-r/this.speed,this.startTime)),a?this.currentTime=t:this.updateTime(t);let g=this.currentTime-u*(this.playbackSpeed>=0?1:-1),h=this.playbackSpeed>=0?g<0:g>r;this.currentTime=Math.max(g,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=r);let x=this.currentTime,S=o;if(d){let C=Math.min(this.currentTime,r)/i,E=Math.floor(C),I=C%1;!I&&C>=1&&(I=1),I===1&&E--,E=Math.min(E,d+1),!!(E%2)&&(f==="reverse"?(I=1-I,m&&(I-=m/i)):f==="mirror"&&(S=s)),x=fa(0,1,I)*i}let v;h?(this.delayState.value=c[0],v=this.delayState):v=S.next(x),n&&!h&&(v.value=n(v.value));let{done:R}=v;!h&&l!==null&&(R=this.playbackSpeed>=0?this.currentTime>=r:this.currentTime<=0);let L=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&R);return L&&p!==op&&(v.value=yi(c,this.options,b,this.speed)),y&&y(v.value),L&&this.finish(),v}then(t,a){return this.finished.then(t,a)}get duration(){return ba(this.calculatedDuration)}get iterationDuration(){let{delay:t=0}=this.options||{};return this.duration+ba(t)}get time(){return ba(this.currentTime)}set time(t){t=oa(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=t,this.tick(t))}getGeneratorVelocity(){return QO(this.generator,this.currentTime,this.options.velocity)}get speed(){return this.playbackSpeed}set speed(t){let a=this.playbackSpeed!==t;a&&this.driver&&this.updateTime(gt.now()),this.playbackSpeed=t,a&&this.driver&&(this.time=ba(this.currentTime))}play(){if(this.isStopped)return;let{driver:t=UO,startTime:a}=this.options;this.driver||(this.driver=t(r=>this.tick(r))),this.options.onPlay?.();let o=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=o):this.holdTime!==null?this.startTime=o-this.holdTime:this.startTime||(this.startTime=a??o),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(gt.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}};var E6=new Set(["brightness","contrast","saturate","opacity"]);function A6(e){let[t,a]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;let[o]=a.match(Qc)||[];if(!o)return e;let r=a.replace(o,""),n=E6.has(t)?1:0;return o!==a&&(n*=100),t+"("+n+r+")"}var D6=/\b([a-z-]*)\(.*?\)/gu,rp={...Yt,getAnimatableNone:e=>{let t=e.match(D6);return t?t.map(A6).join(" "):e}};var np={...Yt,getAnimatableNone:e=>{let t=Yt.parse(e);return Yt.createTransformer(e)(t.map(o=>typeof o=="number"?0:typeof o=="object"?{...o,alpha:1}:o))}};var t0={...gn,transform:Math.round};var ek={rotate:hr,pathRotation:hr,rotateX:hr,rotateY:hr,rotateZ:hr,scale:Jm,scaleX:Jm,scaleY:Jm,scaleZ:Jm,skew:hr,skewX:hr,skewY:hr,distance:de,translateX:de,translateY:de,translateZ:de,x:de,y:de,z:de,perspective:de,transformPerspective:de,opacity:os,originX:wx,originY:wx,originZ:de};var Hl={borderWidth:de,borderTopWidth:de,borderRightWidth:de,borderBottomWidth:de,borderLeftWidth:de,borderRadius:de,borderTopLeftRadius:de,borderTopRightRadius:de,borderBottomRightRadius:de,borderBottomLeftRadius:de,width:de,maxWidth:de,height:de,maxHeight:de,top:de,right:de,bottom:de,left:de,inset:de,insetBlock:de,insetBlockStart:de,insetBlockEnd:de,insetInline:de,insetInlineStart:de,insetInlineEnd:de,padding:de,paddingTop:de,paddingRight:de,paddingBottom:de,paddingLeft:de,paddingBlock:de,paddingBlockStart:de,paddingBlockEnd:de,paddingInline:de,paddingInlineStart:de,paddingInlineEnd:de,margin:de,marginTop:de,marginRight:de,marginBottom:de,marginLeft:de,marginBlock:de,marginBlockStart:de,marginBlockEnd:de,marginInline:de,marginInlineStart:de,marginInlineEnd:de,fontSize:de,backgroundPositionX:de,backgroundPositionY:de,...ek,zIndex:t0,fillOpacity:os,strokeOpacity:os,numOctaves:t0};var M6={...Hl,color:Gt,backgroundColor:Gt,outlineColor:Gt,fill:Gt,stroke:Gt,borderColor:Gt,borderTopColor:Gt,borderRightColor:Gt,borderBottomColor:Gt,borderLeftColor:Gt,filter:rp,WebkitFilter:rp,mask:np,WebkitMask:np},kx=e=>M6[e];var P6=new Set([rp,np]);function rf(e,t){let a=kx(e);return P6.has(a)||(a=Yt),a.getAnimatableNone?a.getAnimatableNone(t):void 0}function tk(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}var Ul=e=>e*180/Math.PI,a0=e=>{let t=Ul(Math.atan2(e[1],e[0]));return o0(t)},O6={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:a0,rotateZ:a0,skewX:e=>Ul(Math.atan(e[1])),skewY:e=>Ul(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},o0=e=>(e=e%360,e<0&&(e+=360),e),ak=a0,ok=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),rk=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),k6={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:ok,scaleY:rk,scale:e=>(ok(e)+rk(e))/2,rotateX:e=>o0(Ul(Math.atan2(e[6],e[5]))),rotateY:e=>o0(Ul(Math.atan2(-e[2],e[0]))),rotateZ:ak,rotate:ak,skewX:e=>Ul(Math.atan(e[4])),skewY:e=>Ul(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function ql(e){return e.includes("scale")?1:0}function Nx(e,t){if(!e||e==="none")return ql(t);let a=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u),o,r;if(a)o=k6,r=a;else{let i=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);o=O6,r=i}if(!r)return ql(t);let n=o[t],s=r[1].split(",").map(N6);return typeof n=="function"?n(s):s[n]}var nk=(e,t)=>{let{transform:a="none"}=getComputedStyle(e);return Nx(a,t)};function N6(e){return parseFloat(e.trim())}var yn=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Ao=new Set([...yn,"pathRotation"]);var r0=e=>e===gn||e===de,V6=new Set(["x","y","z"]),B6=yn.filter(e=>!V6.has(e));function ik(e){let t=[];return B6.forEach(a=>{let o=e.getValue(a);if(o!==void 0){let r=o.get(),n=a.startsWith("scale")?1:0;if(r===n)return;t.push([a,r]),o.set(n)}}),t}var lk=new Set(["bottom","right"]);function sk(e,t,a,o,r,n){let s=parseFloat(e);if(!isNaN(s))return s;let{min:i,max:l}=t()[a],u=l-i;return n==="border-box"?u:u-parseFloat(o)-parseFloat(r)}var bi={width:({width:e,paddingLeft:t="0",paddingRight:a="0",boxSizing:o},r)=>sk(e,r,"x",t,a,o),height:({height:e,paddingTop:t="0",paddingBottom:a="0",boxSizing:o},r)=>sk(e,r,"y",t,a,o),top:({top:e})=>parseFloat(e),left:({left:e})=>parseFloat(e),bottom:({top:e},t)=>{let{y:a}=t();return parseFloat(e)+(a.max-a.min)},right:({left:e},t)=>{let{x:a}=t();return parseFloat(e)+(a.max-a.min)},x:({transform:e})=>Nx(e,"x"),y:({transform:e})=>Nx(e,"y")};bi.translateX=bi.x;bi.translateY=bi.y;var Gl=new Set,n0=!1,s0=!1,i0=!1;function uk(){if(s0){let e=[],t=new Set,a=new Set;Gl.forEach(r=>{r.needsMeasurement&&(e.push(r),t.add(r.element),lk.has(r.name)&&a.add(r.element))});let o=new Map;a.forEach(r=>{let n=ik(r);n.length&&(o.set(r,n),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();let n=o.get(r);n&&n.forEach(([s,i])=>{r.getValue(s)?.set(i)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}s0=!1,n0=!1,Gl.forEach(e=>e.complete(i0)),Gl.clear()}function ck(){Gl.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(s0=!0)})}function fk(){i0=!0,ck(),uk(),i0=!1}function F6(e,t,a){if(typeof e=="string"){if(Fl(e)||_l(e))return parseFloat(e);if(!Yt.test(e)&&Yt.test(a))return rf(t,a)}return e??void 0}var vi=class{constructor(t,a,o,r,n,s=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=a,this.name=o,this.motionValue=r,this.element=n,this.isAsync=s}scheduleResolve(){this.state="scheduled",this.isAsync?(Gl.add(this),n0||(n0=!0,ze.read(ck),ze.resolveKeyframes(uk))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:t,name:a,element:o,motionValue:r}=this;if(t[0]===null){let n=r?.get(),s=t[t.length-1];if(n!==void 0)t[0]=n;else if(o&&a){let i=F6(o.readValue(a,s),a,s);i!==void 0&&(t[0]=i)}t[0]===void 0&&(t[0]=s),r&&n===void 0&&r.set(t[0])}tk(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Gl.delete(this)}cancel(){this.state==="scheduled"&&(Gl.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}};var dk=e=>e.startsWith("--");function Vx(e,t,a){dk(t)?e.style.setProperty(t,a):e.style[t]=a}var mk={};function Bx(e,t){let a=Gm(e);return()=>mk[t]??a()}var pk=Bx(()=>window.ScrollTimeline!==void 0,"scrollTimeline");var Fx=Bx(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing");var jl=([e,t,a,o])=>`cubic-bezier(${e}, ${t}, ${a}, ${o})`;var l0={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:jl([0,.65,.55,1]),circOut:jl([.55,0,1,.45]),backIn:jl([.31,.01,.66,-.59]),backOut:jl([.33,1.53,.69,.99])};function u0(e,t){if(e)return typeof e=="function"?Fx()?Mx(e,t):"ease-out":Qm(e)?jl(e):Array.isArray(e)?e.map(a=>u0(a,t)||l0.easeOut):l0[e]}function hk(e,t,a,{delay:o=0,duration:r=300,repeat:n=0,repeatType:s="loop",ease:i="easeOut",times:l}={},u=void 0){let c={[t]:a};l&&(c.offset=l);let d=u0(i,r);Array.isArray(d)&&(c.easing=d);let f={delay:o,duration:r,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:n+1,direction:s==="reverse"?"alternate":"normal"};return u&&(f.pseudoElement=u),e.animate(c,f)}function _x(e){return typeof e=="function"&&"applyToOptions"in e}function gk({type:e,...t}){return _x(e)&&Fx()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}var nf=class extends Si{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;let{element:a,name:o,keyframes:r,pseudoElement:n,allowFlatten:s=!1,finalKeyframe:i,onComplete:l}=t;this.isPseudoElement=!!n,this.allowFlatten=s,this.options=t,wo(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");let u=gk(t);this.animation=hk(a,o,r,u,n),u.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!n){let c=yi(r,this.options,i,this.speed);this.updateMotionValue&&this.updateMotionValue(c),Vx(a,o,c),this.animation.cancel()}l?.(),this.notifyFinished()},Ox(this,t,u)}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;let{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){let t=this.options?.element;!this.isPseudoElement&&t?.isConnected&&this.animation.commitStyles?.()}get duration(){let t=this.animation.effect?.getComputedTiming?.().duration||0;return ba(Number(t))}get iterationDuration(){let{delay:t=0}=this.options||{};return this.duration+ba(t)}get time(){return ba(Number(this.animation.currentTime)||0)}set time(t){let a=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=oa(t),a&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,onAttach:a,observe:o}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&pk()?(this.animation.timeline=t,a?.(this.animation),Xt):o(this)}};var xk={anticipate:Ym,backInOut:Xm,circInOut:Zm};function _6(e){return e in xk}function yk(e){typeof e.ease=="string"&&_6(e.ease)&&(e.ease=xk[e.ease])}var c0=10,zx=class extends nf{constructor(t){yk(t),Px(t),super(t),t.startTime!==void 0&&t.autoplay!==!1&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){let{motionValue:a,onUpdate:o,onComplete:r,element:n,...s}=this.options;if(!a)return;if(t!==void 0){a.set(t);return}let i=new rs({...s,autoplay:!1}),l=Math.max(c0,gt.now()-this.startTime),u=fa(0,c0,l-c0),c=i.sample(l).value,{name:d}=this.options;n&&d&&Vx(n,d,c),a.setWithVelocity(i.sample(Math.max(0,l-u)).value,c,u),i.stop()}};var f0=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(Yt.test(e)||e==="0")&&!e.startsWith("url("));function z6(e){let t=e[0];if(e.length===1)return!0;for(let a=0;a<e.length;a++)if(e[a]!==t)return!0}function Sk(e,t,a,o){let r=e[0];if(r===null)return!1;if(t==="display"||t==="visibility")return!0;let n=e[e.length-1],s=f0(r,t),i=f0(n,t);return!s||!i?(s!==i&&as(!1,`You are trying to animate ${t} from "${r}" to "${n}". "${s?n:r}" is not an animatable value.`,"value-not-animatable"),!1):z6(e)||(a==="spring"||_x(a))&&o}function sp(e){e.duration=0,e.type="keyframes"}var ip=new Set(["opacity","clipPath","filter","transform","backgroundColor"]);var H6=/^(?:oklch|oklab|lab|lch|color|color-mix|light-dark)\(/;function bk(e){for(let t=0;t<e.length;t++)if(typeof e[t]=="string"&&H6.test(e[t]))return!0;return!1}var vk=new Set(["color","backgroundColor","outlineColor","fill","stroke","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"]),U6=Gm(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function Ck(e){let{motionValue:t,name:a,repeatDelay:o,repeatType:r,damping:n,type:s,keyframes:i}=e;if(!a||!(ip.has(a)||vk.has(a)))return!1;let l=t?.owner?.current;if(!(l instanceof HTMLElement)&&!(l instanceof SVGElement))return!1;let{onUpdate:u,transformTemplate:c}=t.owner.getProps();return U6()&&(ip.has(a)||vk.has(a)&&bk(i))&&(a!=="transform"||!c)&&!u&&!o&&r!=="mirror"&&n!==0&&s!=="inertia"}var q6=40,Hx=class extends Si{constructor(t){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=gt.now();let{keyframes:a,name:o,motionValue:r,element:n}=t,s=t;s.autoplay??(s.autoplay=!0),s.delay??(s.delay=0),s.type??(s.type="keyframes"),s.repeat??(s.repeat=0),s.repeatDelay??(s.repeatDelay=0),s.repeatType??(s.repeatType="loop");let i=n?.KeyframeResolver||vi;this.keyframeResolver=new i(a,(l,u,c)=>this.onKeyframesResolved(l,u,s,!c),o,r,n),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,a,o,r){this.keyframeResolver=void 0;let{name:n,type:s,velocity:i,delay:l,isHandoff:u,onUpdate:c}=o;this.resolvedAt=gt.now();let d=!0;Sk(t,n,s,i)||(d=!1,(Ba.instantAnimations||!l)&&c?.(yi(t,o,a)),t[0]=t[t.length-1],sp(o),o.repeat=0);let f=r?this.resolvedAt?this.resolvedAt-this.createdAt>q6?this.resolvedAt:this.createdAt:this.createdAt:void 0,{onComplete:m}=o;o.startTime??(o.startTime=f),o.finalKeyframe=a,o.keyframes=t,o.onComplete=()=>{m?.(),this.notifyFinished()};let p=d&&!u&&Ck(o),y;if(p){o.element=o.motionValue?.owner?.current;try{y=new zx(o)}catch{y=new rs(o)}}else y=new rs(o);this.pendingTimeline&&(this.stopTimeline=y.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=y}get finished(){return this._animation?this._animation.finished:super.finished}then(t,a){return this.finished.finally(t).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),fk()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}};function Ux(e,t,a,o=0,r=1){let n=Array.from(e).sort((u,c)=>u.sortNodePosition(c)).indexOf(t),s=e.size,i=(s-1)*o;return typeof a=="function"?a(n,s):r===1?n*o:i-n*o}var Lk=30,G6=e=>!isNaN(parseFloat(e)),Rk={current:void 0},d0=class{constructor(t,a={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=o=>{let r=gt.now();if(this.updatedAt!==r&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(o),this.current!==this.prev&&(this.notifyChange(),this.dependents))for(let n of this.dependents)n.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=a.owner}setCurrent(t){this.current=t,this.updatedAt=gt.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=G6(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,a){var o;return t==="change"?this.onChangeSubscribe(a):((o=this.events)[t]||(o[t]=new pn)).add(a)}onChangeSubscribe(t){let{events:a}=this;return!a.change&&!this.changeSubscriber?this.changeSubscriber=t:(a.change||(a.change=new pn,a.change.add(this.changeSubscriber),this.changeSubscriber=void 0),a.change.add(t)),()=>{this.changeSubscriber===t?this.changeSubscriber=void 0:a.change?.remove(t),this.stopIfUnobserved()}}stopIfUnobserved(){ze.read(()=>{!this.changeSubscriber&&!this.events.change?.getSize()&&this.stop()})}clearListeners(){this.changeSubscriber=void 0;for(let t in this.events)this.events[t].clear()}attach(t,a){this.passiveEffect=t,this.stopPassiveEffect=a}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,a,o){this.set(a),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-o}jump(t,a=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,a&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.notifyChange()}notifyChange(){let{current:t,changeSubscriber:a}=this;a?a(t):this.events.change?.notify(t)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return Rk.current&&Rk.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){let t=gt.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Lk)return 0;let a=Math.min(this.updatedAt-this.prevUpdatedAt,Lk);return jm(parseFloat(this.current)-parseFloat(this.prevFrameValue),a)}start(t){return this.stop(),new Promise(a=>{this.hasAnimated=!0;let o=!1,r;r=t(()=>{o=!0,this.events.animationComplete?.notify(),this.animation===r&&this.clearAnimation(),a()}),o||(this.animation=r),this.events.animationStart?.notify()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){this.animation=void 0}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function zr(e,t){return new d0(e,t)}function Xl(e,t){if(e?.inherit&&t){let{inherit:a,...o}=e;return{...t,...o}}return e}function sf(e,t){let a=e?.[t]??e?.default??e;return a!==e?Xl(a,e):a}var j6={type:"spring",stiffness:500,damping:25,restSpeed:10},X6=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),Y6={type:"keyframes",duration:.8},W6={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Tk=(e,{keyframes:t})=>t.length>2?Y6:Ao.has(e)?e.startsWith("scale")?X6(t[1]):j6:W6;var K6=new Set(["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);function Ik(e){for(let t in e)if(!K6.has(t))return!0;return!1}var Yl=(e,t,a,o={},r,n)=>s=>{let i=sf(o,e)||{},l=i.delay||o.delay||0,{elapsed:u=0}=o;u=u-oa(l);let c={keyframes:Array.isArray(a)?a:[null,a],ease:"easeOut",velocity:t.getVelocity(),...i,delay:-u,onUpdate:f=>{t.set(f),i.onUpdate&&i.onUpdate(f)},onComplete:()=>{s(),i.onComplete&&i.onComplete()},name:e,motionValue:t,element:n?void 0:r};Ik(i)||Object.assign(c,Tk(e,c)),c.duration&&(c.duration=oa(c.duration)),c.repeatDelay&&(c.repeatDelay=oa(c.repeatDelay)),c.from!==void 0&&(c.keyframes[0]=c.from);let d=!1;if((c.type===!1||c.duration===0&&!c.repeatDelay)&&(sp(c),c.delay===0&&(d=!0)),(Ba.instantAnimations||Ba.skipAnimations||r?.shouldSkipAnimations||i.skipAnimations)&&(d=!0,sp(c),c.delay=0),c.allowFlatten=!i.type&&!i.ease,d&&!n&&t.get()!==void 0){let f=yi(c.keyframes,i);if(f!==void 0){ze.update(()=>{c.onUpdate(f),c.onComplete()});return}}return i.isSync?new rs(c):new Hx(c)};var Z6=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Q6(e){let t=Z6.exec(e);if(!t)return[,];let[,a,o,r]=t;return[`--${a??o}`,r]}var J6=4;function m0(e,t,a=1){wo(a<=J6,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");let[o,r]=Q6(e);if(!o)return;let n=window.getComputedStyle(t).getPropertyValue(o);if(n){let s=n.trim();return Fl(s)?parseFloat(s):s}return Zc(r)?m0(r,t,a+1):r}function wk(e){let t=[{},{}];return e?.values.forEach((a,o)=>{t[0][o]=a.get(),t[1][o]=a.getVelocity()}),t}function Wl(e,t,a,o){if(typeof t=="function"){let[r,n]=wk(o);t=t(a!==void 0?a:e.custom,r,n)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){let[r,n]=wk(o);t=t(a!==void 0?a:e.custom,r,n)}return t}function Wo(e,t,a){let o=e.getProps();return Wl(o,t,a!==void 0?a:o.custom,e)}var qx=new Set(["width","height","top","left","right","bottom",...yn]);var lp=e=>Array.isArray(e);function $6(e,t,a){e.hasValue(t)?e.getValue(t).set(a):e.addValue(t,zr(a))}function e8(e){return lp(e)?e[e.length-1]||0:e}function Ek(e,t){let a=Wo(e,t),{transitionEnd:o={},transition:r={},...n}=a||{};n={...n,...o};for(let s in n){let i=e8(n[s]);$6(e,s,i)}}var mt=e=>!!(e&&e.getVelocity);function Ak(e){return!!(mt(e)&&e.add)}function lf(e,t){let a=e.getValue("willChange");if(Ak(a))return a.add(t);if(!a&&Ba.WillChange){let o=new Ba.WillChange("auto");e.addValue("willChange",o),o.add(t)}}function uf(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}var Dk="framerAppearId",up="data-"+uf(Dk);function Gx(e){return e.props[up]}var t8=typeof window<"u";function a8({protectedKeys:e,needsAnimating:t},a){let o=e.hasOwnProperty(a)&&t[a]!==!0;return t[a]=!1,o}function jx(e,t,{delay:a=0,transitionOverride:o,type:r}={}){let{transition:n,transitionEnd:s,...i}=t,l=e.getDefaultTransition();n=n?Xl(n,l):l;let u=n?.reduceMotion,c=n?.skipAnimations;o&&(n=o);let d=[],f=r&&e.animationState&&e.animationState.getState()[r],m=n?.path;m&&m.animateVisualElement(e,i,n,a,d);for(let p in i){let y=e.getValue(p,e.latestValues[p]??null),b=i[p];if(b===void 0||f&&a8(f,p))continue;let g={delay:a,...sf(n||{},p)};c&&(g.skipAnimations=!0);let h=y.get();if(h!==void 0&&!y.isAnimating()&&!Array.isArray(b)&&b===h&&!g.velocity){ze.update(()=>y.set(b));continue}let x=!1;if(t8&&window.MotionHandoffAnimation){let R=Gx(e);if(R){let L=window.MotionHandoffAnimation(R,p,ze);L!==null&&(g.startTime=L,x=!0)}}lf(e,p);let S=u??e.shouldReduceMotion;y.start(Yl(p,y,b,S&&qx.has(p)?{type:!1}:g,e,x));let v=y.animation;v&&d.push(v)}if(s){let p=()=>ze.update(()=>{s&&Ek(e,s)});d.length?Promise.all(d).then(p):p()}return d}function Xx(e,t,a={}){let o=Wo(e,t,a.type==="exit"?e.presenceContext?.custom:void 0),{transition:r=e.getDefaultTransition()||{}}=o||{};a.transitionOverride&&(r=a.transitionOverride);let n=o?()=>Promise.all(jx(e,o,a)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(l=0)=>{let{delayChildren:u=0,staggerChildren:c,staggerDirection:d}=r;return o8(e,t,l,u,c,d,a)}:()=>Promise.resolve(),{when:i}=r;if(i){let[l,u]=i==="beforeChildren"?[n,s]:[s,n];return l().then(()=>u())}else return Promise.all([n(),s(a.delay)])}function o8(e,t,a=0,o=0,r=0,n=1,s){let i=[];for(let l of e.variantChildren)l.notify("AnimationStart",t),i.push(Xx(l,t,{...s,delay:a+(typeof o=="function"?0:o)+Ux(e.variantChildren,l,o,r,n)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(i)}function Mk(e,t,a={}){e.notify("AnimationStart",t);let o;if(Array.isArray(t)){let r=t.map(n=>Xx(e,n,a));o=Promise.all(r)}else if(typeof t=="string")o=Xx(e,t,a);else{let r=typeof t=="function"?Wo(e,t,a.custom):t;o=Promise.all(jx(e,r,a))}return o.then(()=>{e.notify("AnimationComplete",t)})}var Pk={test:e=>e==="auto",parse:e=>e};var Ok=e=>t=>t.test(e);var r8=[gn,de,Xa,hr,XR,jR,Pk],p0=e=>r8.find(Ok(e));function kk(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||_l(e):!0}var n8=new Set(["auto","none","0"]);function Nk(e,t,a){let o=0,r;for(;o<e.length&&!r;){let n=e[o];typeof n=="string"&&!n8.has(n)&&kO(n)&&(r=e[o]),o++}if(r&&a)for(let n of t)e[n]!==r&&(e[n]=rf(a,r))}var Yx=class extends vi{constructor(t,a,o,r,n){super(t,a,o,r,n,!0)}readKeyframes(){let{unresolvedKeyframes:t,element:a,name:o}=this;if(!a||!a.current)return;super.readKeyframes();for(let c=0;c<t.length;c++){let d=t[c];if(typeof d=="string"&&(d=d.trim(),Zc(d))){let f=m0(d,a.current);f!==void 0&&(t[c]=f),c===t.length-1&&(this.finalKeyframe=d)}}if(this.resolveNoneKeyframes(),!qx.has(o)||t.length!==2)return;let[r,n]=t;if(typeof r=="number"&&typeof n=="number")return;let s=p0(r),i=p0(n),l=qR(r),u=qR(n);if(l!==u&&bi[o]){this.needsMeasurement=!0;return}if(s!==i)if(r0(s)&&r0(i))for(let c=0;c<t.length;c++){let d=t[c];typeof d=="string"&&(t[c]=parseFloat(d))}else bi[o]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){let{unresolvedKeyframes:t,name:a}=this,o=[];for(let r=0;r<t.length;r++)(t[r]===null||kk(t[r]))&&o.push(r);o.length&&Nk(t,o,a)}measure(){let{element:t,name:a}=this;return bi[a](window.getComputedStyle(t.current),()=>t.measureViewportBox())}measureInitialState(){let{element:t,unresolvedKeyframes:a,name:o}=this;if(!t||!t.current)return;o==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=this.measure(),a[0]=this.measuredOrigin;let r=a[a.length-1];r!==void 0&&this.motionValue?.jump(r,!1)}measureEndState(){let{element:t,unresolvedKeyframes:a}=this;if(!t||!t.current)return;this.motionValue?.jump(this.measuredOrigin,!1);let o=a.length-1,r=a[o];a[o]=this.measure(),r!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=r),this.removedTransforms?.length&&this.removedTransforms.forEach(([n,s])=>{t.getValue(n).set(s)}),this.resolveNoneKeyframes()}};var cp=["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"];function Kl(e){return qm(e)&&"offsetHeight"in e&&!("ownerSVGElement"in e)}function cf(e){return qm(e)&&"ownerSVGElement"in e}var fp=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function Wx(e,t,a){if(e==null)return[];if(e instanceof EventTarget)return[e];if(typeof e=="string"){let o=document;t&&(o=t.current);let r=a?.[e]??o.querySelectorAll(e);return r?Array.from(r):[]}return Array.from(e).filter(o=>o!=null)}var s8={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},i8=yn.length;function Vk(e,t,a){let o="",r=!0;for(let s=0;s<i8;s++){let i=yn[s],l=e[i];if(l===void 0)continue;let u=!0;if(typeof l=="number")u=l===(i.startsWith("scale")?1:0);else{let c=parseFloat(l);u=i.startsWith("scale")?c===1:c===0}if(!u||a){let c=fp(l,Hl[i]);if(!u){r=!1;let d=s8[i]||i;o+=`${d}(${c}) `}a&&(t[i]=c)}}let n=e.pathRotation;return n&&(r=!1,o+=`rotate(${fp(n,Hl.pathRotation)}) `),o=o.trim(),a?o=a(t,r?"":o):r&&(o="none"),o}function Zl(e,t,a){let{style:o,vars:r,transformOrigin:n}=e,s=!1,i=!1;for(let l in t){let u=t[l];if(Ao.has(l)){s=!0;continue}else if(Tx(l)){r[l]=u;continue}else{let c=fp(u,Hl[l]);l.startsWith("origin")?(i=!0,n[l]=c):o[l]=c}}if(t.transform||(s||a?o.transform=Vk(t,e.transform,a):o.transform&&(o.transform="none")),i){let{originX:l="50%",originY:u="50%",originZ:c=0}=n;o.transformOrigin=`${l} ${u} ${c}`}}var l8={offset:"stroke-dashoffset",array:"stroke-dasharray"},u8={offset:"strokeDashoffset",array:"strokeDasharray"};function Bk(e,t,a=1,o=0,r=!0){e.pathLength=1;let n=r?l8:u8;e[n.offset]=`${-o}`,e[n.array]=`${t} ${a}`}var h0=["transform","opacity","offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function dp(e,{attrX:t,attrY:a,attrScale:o,pathLength:r,pathSpacing:n=1,pathOffset:s=0,...i},l,u,c){if(Zl(e,i,u),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};let{attrs:d,style:f}=e;for(let m of h0)d[m]!==void 0&&(f[m]=d[m],delete d[m]);(f.transform||d.transformOrigin)&&(f.transformOrigin=d.transformOrigin??"50% 50%",delete d.transformOrigin),f.transform&&(f.transformBox=c?.transformBox??"fill-box",delete d.transformBox),t!==void 0&&(d.x=t),a!==void 0&&(d.y=a),o!==void 0&&(d.scale=o),r!==void 0&&Bk(d,r,n,s,!1)}function mp({top:e,left:t,right:a,bottom:o}){return{x:{min:t,max:a},y:{min:e,max:o}}}function g0({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function x0(e,t){if(!t)return e;let a=t({x:e.left,y:e.top}),o=t({x:e.right,y:e.bottom});return{top:a.y,left:a.x,bottom:o.y,right:o.x}}function y0(e){return e===void 0||e===1}function Kx({scale:e,scaleX:t,scaleY:a}){return!y0(e)||!y0(t)||!y0(a)}function ns(e){return Kx(e)||S0(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function S0(e){return Fk(e.x)||Fk(e.y)}function Fk(e){return e&&e!=="0%"}function pp(e,t,a){let o=e-a,r=t*o;return a+r}function _k(e,t,a,o,r){return r!==void 0&&(e=pp(e,r,o)),pp(e,a,o)+t}function b0(e,t=0,a=1,o,r){e.min=_k(e.min,t,a,o,r),e.max=_k(e.max,t,a,o,r)}function v0(e,{x:t,y:a}){b0(e.x,t.translate,t.scale,t.originPoint),b0(e.y,a.translate,a.scale,a.originPoint)}var zk=.999999999999,Hk=1.0000000000001;function Gk(e,t,a,o=!1){let r=a.length;if(!r)return;t.x=t.y=1;let n,s;for(let i=0;i<r;i++){n=a[i],s=n.projectionDelta;let{visualElement:l}=n.options;l&&l.props.style&&l.props.style.display==="contents"||(o&&n.options.layoutScroll&&n.scroll&&n!==n.root&&(gr(e.x,-n.scroll.offset.x),gr(e.y,-n.scroll.offset.y)),s&&(t.x*=s.x.scale,t.y*=s.y.scale,v0(e,s)),o&&ns(n.latestValues)&&hp(e,n.latestValues,n.layout?.layoutBox))}t.x<Hk&&t.x>zk&&(t.x=1),t.y<Hk&&t.y>zk&&(t.y=1)}function gr(e,t){e.min+=t,e.max+=t}function Uk(e,t,a,o,r=.5){let n=qe(e.min,e.max,r);b0(e,t,a,n,o)}function qk(e,t){return typeof e=="string"?parseFloat(e)/100*(t.max-t.min):e}function hp(e,t,a){let o=a??e;Uk(e.x,qk(t.x,o.x),t.scaleX,t.scale,t.originX),Uk(e.y,qk(t.y,o.y),t.scaleY,t.scale,t.originY)}function Zx(e,t){return mp(x0(e.getBoundingClientRect(),t))}function C0(e,t,a){let o=Zx(e,a),{scroll:r}=t;return r&&(gr(o.x,r.offset.x),gr(o.y,r.offset.y)),o}var{schedule:Ql,cancel:c8}=Dx(queueMicrotask,!1);var xr={x:!1,y:!1};function Qx(){return xr.x||xr.y}function L0(e){return e==="x"||e==="y"?xr[e]?null:(xr[e]=!0,()=>{xr[e]=!1}):xr.x||xr.y?null:(xr.x=xr.y=!0,()=>{xr.x=xr.y=!1})}function Jx(e,t){let a=Wx(e),o=new AbortController,r={passive:!0,...t,signal:o.signal};return[a,r,()=>o.abort()]}function f8(e){return!(e.pointerType==="touch"||Qx())}function R0(e,t,a={}){let[o,r,n]=Jx(e,a);return o.forEach(s=>{let i=!1,l=!1,u,c=()=>{s.removeEventListener("pointerleave",p)},d=b=>{u&&(u(b),u=void 0),c()},f=b=>{i=!1,window.removeEventListener("pointerup",f),window.removeEventListener("pointercancel",f),l&&(l=!1,d(b))},m=()=>{i=!0,window.addEventListener("pointerup",f,r),window.addEventListener("pointercancel",f,r)},p=b=>{if(b.pointerType!=="touch"){if(i){l=!0;return}d(b)}},y=b=>{if(!f8(b))return;l=!1;let g=t(s,b);typeof g=="function"&&(u=g,s.addEventListener("pointerleave",p,r))};s.addEventListener("pointerenter",y,r),s.addEventListener("pointerdown",m,r)}),n}var T0=(e,t)=>t?e===t?!0:T0(e,t.parentElement):!1;var Jl=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;var d8=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function I0(e){return d8.has(e.tagName)||e.isContentEditable===!0}var m8=new Set(["INPUT","SELECT","TEXTAREA"]);function w0(e){return m8.has(e.tagName)||e.isContentEditable===!0}var ff=new WeakSet;function jk(e){return t=>{t.key==="Enter"&&e(t)}}function E0(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}var Xk=(e,t)=>{let a=e.currentTarget;if(!a)return;let o=jk(()=>{if(ff.has(a))return;E0(a,"down");let r=jk(()=>{E0(a,"up")}),n=()=>E0(a,"cancel");a.addEventListener("keyup",r,t),a.addEventListener("blur",n,t)});a.addEventListener("keydown",o,t),a.addEventListener("blur",()=>a.removeEventListener("keydown",o),t)};function Yk(e){return Jl(e)&&!Qx()}var Wk=new WeakSet;function A0(e,t,a={}){let[o,r,n]=Jx(e,a),s=i=>{let l=i.currentTarget;if(!Yk(i)||Wk.has(i))return;ff.add(l),a.stopPropagation&&Wk.add(i);let u=t(l,i),c={...r,capture:!0},d=(p,y)=>{window.removeEventListener("pointerup",f,c),window.removeEventListener("pointercancel",m,c),ff.has(l)&&ff.delete(l),Yk(p)&&typeof u=="function"&&u(p,{success:y})},f=p=>{d(p,l===window||l===document||a.useGlobalTarget||T0(l,p.target))},m=p=>{d(p,!1)};window.addEventListener("pointerup",f,c),window.addEventListener("pointercancel",m,c)};return o.forEach(i=>{(a.useGlobalTarget?window:i).addEventListener("pointerdown",s,r),Kl(i)&&(i.addEventListener("focus",u=>Xk(u,r)),!I0(i)&&!i.hasAttribute("tabindex")&&(i.tabIndex=0))}),n}var $x=new WeakMap,ey,Kk=(e,t,a)=>(o,r)=>r&&r[0]?r[0][e+"Size"]:cf(o)&&"getBBox"in o?o.getBBox()[t]:o[a],p8=Kk("inline","width","offsetWidth"),h8=Kk("block","height","offsetHeight");function g8({target:e,borderBoxSize:t}){$x.get(e)?.forEach(a=>{a(e,{get width(){return p8(e,t)},get height(){return h8(e,t)}})})}function x8(e){e.forEach(g8)}function y8(){typeof ResizeObserver>"u"||(ey=new ResizeObserver(x8))}function Zk(e,t){ey||y8();let a=Wx(e);return a.forEach(o=>{let r=$x.get(o);r||(r=new Set,$x.set(o,r)),r.add(t),ey?.observe(o)}),()=>{a.forEach(o=>{let r=$x.get(o);r?.delete(t),r?.size||ey?.unobserve(o)})}}var ty=new Set,df;function S8(){df=()=>{let e={get width(){return window.innerWidth},get height(){return window.innerHeight}};ty.forEach(t=>t(e))},window.addEventListener("resize",df)}function Qk(e){return ty.add(e),df||S8(),()=>{ty.delete(e),!ty.size&&typeof df=="function"&&(window.removeEventListener("resize",df),df=void 0)}}function ay(e,t){return typeof e=="function"?Qk(e):Zk(e,t)}var $l={value:null,addProjectionMetrics:null};function Jk(e){return cf(e)&&e.tagName==="svg"}var D0=e=>typeof e=="number"?e:parseFloat(e);var M0=()=>({translate:0,scale:1,origin:0,originPoint:0}),Ci=()=>({x:M0(),y:M0()}),P0=()=>({min:0,max:0}),kt=()=>({x:P0(),y:P0()});var $k=new WeakMap;function ss(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function Sn(e){return typeof e=="string"||Array.isArray(e)}var oy=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],mf=["initial",...oy];function Li(e){if(ss(e.animate))return!0;for(let t=0;t<mf.length;t++)if(Sn(e[mf[t]]))return!0;return!1}function gp(e){return!!(Li(e)||e.variants)}function eN(e,t,a){for(let o in t){let r=t[o],n=a[o];if(mt(r))e.addValue(o,r);else if(mt(n))e.addValue(o,zr(r,{owner:e}));else if(n!==r)if(e.hasValue(o)){let s=e.getValue(o);s.liveStyle===!0?s.jump(r):s.hasAnimated||s.set(r)}else{let s=e.getStaticValue(o);e.addValue(o,zr(s!==void 0?s:r,{owner:e}))}}for(let o in a)t[o]===void 0&&e.removeValue(o);return t}var Ri={current:null},eu={current:!1};var b8=typeof window<"u";function xp(){if(eu.current=!0,!!b8)if(window.matchMedia){let e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Ri.current=e.matches;e.addEventListener("change",t),t()}else Ri.current=!1}var tN=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],ry={};function Sp(e){ry=e}function O0(){return ry}var yp=class{scrapeMotionValuesFromProps(t,a,o){return{}}constructor({parent:t,props:a,presenceContext:o,reducedMotionConfig:r,skipAnimations:n,blockInitialAnimation:s,visualState:i},l={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=vi,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{let m=gt.now();this.renderScheduledAt<m&&(this.renderScheduledAt=m,ze.render(this.render,!1,!0))};let{latestValues:u,renderState:c}=i;this.latestValues=u,this.baseTarget={...u},this.initialValues=a.initial?{...u}:{},this.renderState=c,this.parent=t,this.props=a,this.presenceContext=o,this.depth=t?t.depth+1:0,this.reducedMotionConfig=r,this.skipAnimationsConfig=n,this.options=l,this.blockInitialAnimation=!!s,this.isControllingVariants=Li(a),this.isVariantNode=gp(a),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);let{willChange:d,...f}=this.scrapeMotionValuesFromProps(a,{},this);for(let m in f){let p=f[m];u[m]!==void 0&&mt(p)&&p.set(u[m])}}mount(t){if(this.hasBeenMounted)for(let a in this.initialValues)this.values.get(a)?.jump(this.initialValues[a]),this.latestValues[a]=this.initialValues[a];this.current=t,$k.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((a,o)=>this.bindToMotionValue(o,a)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(eu.current||xp(),this.shouldReduceMotion=Ri.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,this.parent?.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){this.projection&&this.projection.unmount(),Eo(this.notifyUpdate),Eo(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(let t in this.events)this.events[t].clear();for(let t in this.features){let a=this.features[t];a&&(a.unmount(),a.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,a){if(this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)(),a.accelerate&&ip.has(t)&&this.current instanceof HTMLElement){let{factory:s,keyframes:i,times:l,ease:u,duration:c}=a.accelerate,d=new nf({element:this.current,name:t,keyframes:i,times:l,ease:u,duration:oa(c)}),f=s(d);this.valueSubscriptions.set(t,()=>{f(),d.cancel()});return}let o=Ao.has(t);o&&this.onBindTransform&&this.onBindTransform();let r=a.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&ze.preRender(this.notifyUpdate),o&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()}),n;typeof window<"u"&&window.MotionCheckAppearSync&&(n=window.MotionCheckAppearSync(this,t,a)),this.valueSubscriptions.set(t,()=>{r(),n&&n()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in ry){let a=ry[t];if(!a)continue;let{isEnabled:o,Feature:r}=a;if(!this.features[t]&&r&&o(this.props)&&(this.features[t]=new r(this)),this.features[t]){let n=this.features[t];n.isMounted?n.update():(n.mount(),n.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):kt()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,a){this.latestValues[t]=a}update(t,a){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=a;for(let o=0;o<tN.length;o++){let r=tN[o];this.propEventSubscriptions[r]&&(this.propEventSubscriptions[r](),delete this.propEventSubscriptions[r]);let n="on"+r,s=t[n];s&&(this.propEventSubscriptions[r]=this.on(r,s))}this.prevMotionValues=eN(this,this.scrapeMotionValuesFromProps(t,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){let a=this.getClosestVariantNode();if(a)return a.variantChildren&&a.variantChildren.add(t),()=>a.variantChildren.delete(t)}addValue(t,a){let o=this.values.get(t);if(a!==o){o&&this.removeValue(t),this.bindToMotionValue(t,a),this.values.set(t,a);let r=a.get();r!==void 0&&(this.latestValues[t]=r)}}removeValue(t){this.values.delete(t);let a=this.valueSubscriptions.get(t);a&&(a(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,a){if(this.props.values&&this.props.values[t])return this.props.values[t];let o=this.values.get(t);return o===void 0&&a!==void 0&&(o=zr(a??this.getDefaultValue?.(t),{owner:this}),this.addValue(t,o)),o}readValue(t,a){let o=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return o!=null&&(typeof o=="string"&&(Fl(o)||_l(o))?o=parseFloat(o):typeof o!="number"&&!Yt.test(o)&&Yt.test(a)&&(o=rf(t,a)),this.setBaseTarget(t,mt(o)?o.get():o)),mt(o)?o.get():o}setBaseTarget(t,a){this.baseTarget[t]=a}getBaseTarget(t){let{initial:a}=this.props,o;if(typeof a=="string"||typeof a=="object"){let n=Wl(this.props,a,this.presenceContext?.custom);n&&(o=n[t])}if(a&&o!==void 0)return o;let r=this.getBaseTargetFromProps(this.props,t);return r!==void 0&&!mt(r)?r:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,a){return this.events[t]||(this.events[t]=new pn),this.events[t].add(a)}notify(t,...a){this.events[t]&&this.events[t].notify(...a)}scheduleRenderMicrotask(){Ql.render(this.render)}};var pf=class extends yp{constructor(){super(...arguments),this.KeyframeResolver=Yx}sortInstanceNodePosition(t,a){return t.compareDocumentPosition(a)&2?1:-1}getBaseTargetFromProps(t,a){let o=t.style;return o?o[a]:void 0}removeValueFromRenderState(t,{vars:a,style:o}){delete a[t],delete o[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:t}=this.props;mt(t)&&(this.childSubscription=t.on("change",a=>{this.current&&(this.current.textContent=`${a}`)}))}};var da=class{constructor(t){this.isMounted=!1,this.node=t}update(){}};function ny(e,{style:t,vars:a},o,r){let n=e.style,s;for(s in t)n[s]=t[s];r?.applyProjectionStyles(n,o);for(s in a)n.setProperty(s,a[s])}var tu={};function bp(e,{layout:t,layoutId:a}){return Ao.has(e)||e.startsWith("origin")||(t||a!==void 0)&&(!!tu[e]||e==="opacity")}function au(e,t,a){let o=e.style,r=t?.style,n={};if(!o)return n;for(let s in o)(mt(o[s])||r&&mt(r[s])||bp(s,e)||a?.getValue(s)?.liveStyle!==void 0)&&(n[s]=o[s]);return n}function v8(e){return window.getComputedStyle(e)}var vp=class extends pf{constructor(){super(...arguments),this.type="html",this.renderInstance=ny}mount(t){wo(!!t.style,"motion.create() components must forward their ref to a HTML or SVG element","custom-component-ref"),super.mount(t)}readValueFromInstance(t,a){if(Ao.has(a))return this.projection?.isProjecting?ql(a):nk(t,a);{let o=v8(t),r=(Tx(a)?o.getPropertyValue(a):o[a])||0;return typeof r=="string"?r.trim():r}}measureInstanceViewportBox(t,{transformPagePoint:a}){return Zx(t,a)}build(t,a,o){Zl(t,a,o.transformTemplate)}scrapeMotionValuesFromProps(t,a,o){return au(t,a,o)}};var sy=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);var Cp=e=>typeof e=="string"&&e.toLowerCase()==="svg";function aN(e,t,a,o){ny(e,t,void 0,o);for(let r in t.attrs)e.setAttribute(sy.has(r)?r:uf(r),t.attrs[r])}function Lp(e,t,a){let o=au(e,t,a);for(let r in e)if(mt(e[r])||mt(t[r])){let n=yn.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;o[n]=e[r]}return o}var Rp=class extends pf{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=kt}getBaseTargetFromProps(t,a){return Ao.has(a)?super.getBaseTargetFromProps(t,a)??ql(a):t[a]}getDefaultValue(t){return Ao.has(t)?this.latestValues[t]??ql(t):void 0}readValueFromInstance(t,a){if(Ao.has(a)){let o=kx(a);return o&&o.default||0}if(h0.includes(a)){let r=getComputedStyle(t)[a];if(typeof r=="string"&&r)return r.trim()}return a=sy.has(a)?a:uf(a),t.getAttribute(a)}scrapeMotionValuesFromProps(t,a,o){return Lp(t,a,o)}build(t,a,o){dp(t,a,this.isSVGTag,o.transformTemplate,o.style)}renderInstance(t,a,o,r){aN(t,a,o,r)}mount(t){this.isSVGTag=Cp(t.tagName),super.mount(t)}};var C8=mf.length;function k0(e){if(!e)return;if(!e.isControllingVariants){let a=e.parent?k0(e.parent)||{}:{};return e.props.initial!==void 0&&(a.initial=e.props.initial),a}let t={};for(let a=0;a<C8;a++){let o=mf[a],r=e.props[o];(Sn(r)||r===!1)&&(t[o]=r)}return t}function N0(e,t){if(!Array.isArray(t))return!1;let a=t.length;if(a!==e.length)return!1;for(let o=0;o<a;o++)if(t[o]!==e[o])return!1;return!0}var L8=[...oy].reverse(),R8=oy.length;function T8(e){return t=>Promise.all(t.map(({animation:a,options:o})=>Mk(e,a,o)))}function V0(e){let t=T8(e),a=oN(),o=!0,r=!1,n=u=>(c,d)=>{let f=Wo(e,d,u==="exit"?e.presenceContext?.custom:void 0);if(f){let{transition:m,transitionEnd:p,...y}=f;c={...c,...y,...p}}return c};function s(u){t=u(e)}function i(u){let{props:c}=e,d=k0(e.parent)||{},f=[],m=new Set,p={},y=1/0;for(let g=0;g<R8;g++){let h=L8[g],x=a[h],S=c[h]!==void 0?c[h]:d[h],v=Sn(S),R=h===u?x.isActive:null;R===!1&&(y=g);let L=S===d[h]&&S!==c[h]&&v;if(L&&(o||r)&&e.manuallyAnimateOnMount&&(L=!1),x.protectedKeys={...p},!x.isActive&&R===null||!S&&!x.prevProp||ss(S)||typeof S=="boolean")continue;if(h==="exit"&&x.isActive&&R!==!0){x.prevResolvedValues&&(p={...p,...x.prevResolvedValues});continue}let C=rN(x.prevProp,S),E=C||h===u&&x.isActive&&!L&&v||g>y&&v,I=!1,A=Array.isArray(S)?S:[S],N=A.reduce(n(h),{});R===!1&&(N={});let{prevResolvedValues:D={}}=x,F={...D,...N},k=O=>{E=!0,m.has(O)&&(I=!0,m.delete(O)),x.needsAnimating[O]=!0;let V=e.getValue(O);V&&(V.liveStyle=!1)};for(let O in F){let V=N[O],w=D[O];if(p.hasOwnProperty(O))continue;let _=!1;lp(V)&&lp(w)?_=!N0(V,w)||C:_=V!==w,_?V!=null?k(O):m.add(O):V!==void 0&&m.has(O)?k(O):x.protectedKeys[O]=!0}x.prevProp=S,x.prevResolvedValues=N,x.isActive&&(p={...p,...N}),(o||r)&&e.blockInitialAnimation&&(E=!1);let z=L&&C;E&&(!z||I)&&f.push(...A.map(O=>{let V={type:h};if(typeof O=="string"&&(o||r)&&!z&&e.manuallyAnimateOnMount&&e.parent){let{parent:w}=e,_=Wo(w,O);if(w.enteringChildren&&_){let{delayChildren:U}=_.transition||{};V.delay=Ux(w.enteringChildren,e,U)}}return{animation:O,options:V}}))}if(m.size){let g={};if(typeof c.initial!="boolean"){let h=Wo(e,Array.isArray(c.initial)?c.initial[0]:c.initial);h&&h.transition&&(g.transition=h.transition)}m.forEach(h=>{let x=e.getBaseTarget(h),S=e.getValue(h);S&&(S.liveStyle=!0),g[h]=x??null}),f.push({animation:g})}let b=!!f.length;return o&&(c.initial===!1||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(b=!1),o=!1,r=!1,b?t(f):Promise.resolve()}function l(u,c){if(a[u].isActive===c)return Promise.resolve();e.variantChildren?.forEach(f=>f.animationState?.setActive(u,c)),a[u].isActive=c;let d=i(u);for(let f in a)a[f].protectedKeys={};return d}return{animateChanges:i,setActive:l,setAnimateFunction:s,getState:()=>a,reset:()=>{a=oN(),r=!0}}}function rN(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!N0(t,e):!1}function ou(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function oN(){return{animate:ou(!0),whileInView:ou(),whileHover:ou(),whileTap:ou(),whileDrag:ou(),whileFocus:ou(),exit:ou()}}function iy(e,t){e.min=t.min,e.max=t.max}function yr(e,t){iy(e.x,t.x),iy(e.y,t.y)}function B0(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}var nN=1e-4,I8=1-nN,w8=1+nN,sN=.01,E8=0-sN,A8=0+sN;function ra(e){return e.max-e.min}function H0(e,t,a){return Math.abs(e-t)<=a}function F0(e,t,a,o=.5){e.origin=o,e.originPoint=qe(t.min,t.max,e.origin),e.scale=ra(a)/ra(t),e.translate=qe(a.min,a.max,e.origin)-e.originPoint,(e.scale>=I8&&e.scale<=w8||isNaN(e.scale))&&(e.scale=1),(e.translate>=E8&&e.translate<=A8||isNaN(e.translate))&&(e.translate=0)}function ru(e,t,a,o){F0(e.x,t.x,a.x,o?o.originX:void 0),F0(e.y,t.y,a.y,o?o.originY:void 0)}function _0(e,t,a,o=0){let r=o?qe(a.min,a.max,o):a.min;e.min=r+t.min,e.max=e.min+ra(t)}function U0(e,t,a,o){_0(e.x,t.x,a.x,o?.x),_0(e.y,t.y,a.y,o?.y)}function z0(e,t,a,o=0){let r=o?qe(a.min,a.max,o):a.min;e.min=t.min-r,e.max=e.min+ra(t)}function hf(e,t,a,o){z0(e.x,t.x,a.x,o?.x),z0(e.y,t.y,a.y,o?.y)}function iN(e,t,a,o,r){return e-=t,e=pp(e,1/a,o),r!==void 0&&(e=pp(e,1/r,o)),e}function D8(e,t=0,a=1,o=.5,r,n=e,s=e){if(Xa.test(t)&&(t=parseFloat(t),t=qe(s.min,s.max,t/100)-s.min),typeof t!="number")return;let i=qe(n.min,n.max,o);e===n&&(i-=t),e.min=iN(e.min,t,a,i,r),e.max=iN(e.max,t,a,i,r)}function lN(e,t,[a,o,r],n,s){D8(e,t[a],t[o],t[r],t.scale,n,s)}var M8=["x","scaleX","originX"],P8=["y","scaleY","originY"];function q0(e,t,a,o){lN(e.x,t,M8,a?a.x:void 0,o?o.x:void 0),lN(e.y,t,P8,a?a.y:void 0,o?o.y:void 0)}function uN(e){return e.translate===0&&e.scale===1}function G0(e){return uN(e.x)&&uN(e.y)}function cN(e,t){return e.min===t.min&&e.max===t.max}function dN(e,t){return cN(e.x,t.x)&&cN(e.y,t.y)}function fN(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function j0(e,t){return fN(e.x,t.x)&&fN(e.y,t.y)}function X0(e){return ra(e.x)/ra(e.y)}function Y0(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function Ko(e){return[e("x"),e("y")]}function mN(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}var gf={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(de.test(e))e=parseFloat(e);else return e;let a=mN(e,t.target.x),o=mN(e,t.target.y);return`${a}% ${o}%`}};var pN={correct:(e,{treeScale:t,projectionDelta:a})=>{let o=e,r=Yt.parse(e);if(r.length>5)return o;let n=Yt.createTransformer(e),s=typeof r[0]!="number"?1:0,i=a.x.scale*t.x,l=a.y.scale*t.y;r[0+s]/=i,r[1+s]/=l;let u=qe(i,l,.5);return typeof r[2+s]=="number"&&(r[2+s]/=u),typeof r[3+s]=="number"&&(r[3+s]/=u),n(r)}};function hN(e,t,a){let o="",r=e.x.translate/t.x,n=e.y.translate/t.y,s=a?.z||0;if((r||n||s)&&(o=`translate3d(${r}px, ${n}px, ${s}px) `),(t.x!==1||t.y!==1)&&(o+=`scale(${1/t.x}, ${1/t.y}) `),a){let{transformPerspective:u,rotate:c,pathRotation:d,rotateX:f,rotateY:m,skewX:p,skewY:y}=a;u&&(o=`perspective(${u}px) ${o}`),c&&(o+=`rotate(${c}deg) `),d&&(o+=`rotate(${d}deg) `),f&&(o+=`rotateX(${f}deg) `),m&&(o+=`rotateY(${m}deg) `),p&&(o+=`skewX(${p}deg) `),y&&(o+=`skewY(${y}deg) `)}let i=e.x.scale*t.x,l=e.y.scale*t.y;return(i!==1||l!==1)&&(o+=`scale(${i}, ${l})`),o||"none"}var O8=cp.length,gN=e=>typeof e=="number"||de.test(e);function yN(e,t,a,o,r,n){r?(e.opacity=qe(0,a.opacity??1,k8(o)),e.opacityExit=qe(t.opacity??1,0,N8(o))):n&&(e.opacity=qe(t.opacity??1,a.opacity??1,o));for(let s=0;s<O8;s++){let i=cp[s],l=xN(t,i),u=xN(a,i);if(l===void 0&&u===void 0)continue;l||(l=0),u||(u=0),l===0||u===0||gN(l)===gN(u)?(e[i]=Math.max(qe(D0(l),D0(u),o),0),(Xa.test(u)||Xa.test(l))&&(e[i]+="%")):e[i]=u}(t.rotate||a.rotate)&&(e.rotate=qe(t.rotate||0,a.rotate||0,o))}function xN(e,t){return e[t]!==void 0?e[t]:e.borderRadius}var k8=SN(0,.5,Km),N8=SN(.5,.95,Xt);function SN(e,t,a){return o=>o<e?0:o>t?1:a(mn(e,t,o))}function bN(e,t,a){let o=mt(e)?e:zr(e);return o.start(Yl("",o,t,a)),o.animation}function bn(e,t,a,o={passive:!0}){return e.addEventListener(t,a,o),()=>e.removeEventListener(t,a,o)}var vN=(e,t)=>e.depth-t.depth;var ly=class{constructor(){this.children=[],this.isDirty=!1}add(t){Bl(this.children,t),this.isDirty=!0}remove(t){hi(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(vN),this.isDirty=!1,this.children.forEach(t)}};function CN(e,t){let a=gt.now(),o=({timestamp:r})=>{let n=r-a;n>=t&&(Eo(o),e(n-t))};return ze.setup(o,!0),()=>Eo(o)}function nu(e){return mt(e)?e.get():e}var uy=class{constructor(){this.members=[]}add(t){Bl(this.members,t);for(let a=this.members.length-1;a>=0;a--){let o=this.members[a];if(o===t||o===this.lead||o===this.prevLead)continue;let r=o.instance;(!r||r.isConnected===!1)&&!o.snapshot&&(hi(this.members,o),o.unmount())}t.scheduleRender()}remove(t){if(hi(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){let a=this.members[this.members.length-1];a&&this.promote(a)}}relegate(t){for(let a=this.members.indexOf(t)-1;a>=0;a--){let o=this.members[a];if(o.isPresent!==!1&&o.instance?.isConnected!==!1)return this.promote(o),!0}return!1}promote(t,a){let o=this.lead;if(t!==o&&(this.prevLead=o,this.lead=t,t.show(),o)){o.updateSnapshot(),t.scheduleRender();let{layoutDependency:r}=o.options,{layoutDependency:n}=t.options;(r===void 0||r!==n)&&(t.resumeFrom=o,a&&(o.preserveOpacity=!0),o.snapshot&&(t.snapshot=o.snapshot,t.snapshot.latestValues=o.animationValues||o.latestValues),t.root?.isUpdating&&(t.isLayoutDirty=!0)),t.options.crossfade===!1&&o.hide()}}exitAnimationComplete(){this.members.forEach(t=>{t.options.onExitComplete?.(),t.resumingFrom?.options.onExitComplete?.()})}scheduleRender(){this.members.forEach(t=>t.instance&&t.scheduleRender(!1))}removeLeadSnapshot(){this.lead?.snapshot&&(this.lead.snapshot=void 0)}};var LN={borderRadius:{...gf,applyTo:[...cp]},borderTopLeftRadius:gf,borderTopRightRadius:gf,borderBottomLeftRadius:gf,borderBottomRightRadius:gf,boxShadow:pN};var su={hasAnimatedSinceResize:!0,hasEverUpdated:!1};Object.assign(tu,{...LN,...tu});var iu={nodes:0,calculatedTargetDeltas:0,calculatedProjections:0},W0=["","X","Y","Z"],V8=1e3,B8=0;function K0(e,t,a,o){let{latestValues:r}=t;r[e]&&(a[e]=r[e],t.setStaticValue(e,0),o&&(o[e]=0))}function PN(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;let{visualElement:t}=e.options;if(!t)return;let a=Gx(t);if(window.MotionHasOptimisedAnimation(a,"transform")){let{layout:r,layoutId:n}=e.options;window.MotionCancelOptimisedAnimation(a,"transform",ze,!(r||n))}let{parent:o}=e;o&&!o.hasCheckedOptimisedAppear&&PN(o)}function cy({attachResizeListener:e,defaultParent:t,measureScroll:a,checkIsScrollRoot:o,resetTransform:r}){return class{constructor(s={},i=t?.()){this.id=B8++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,$l.value&&(iu.nodes=iu.calculatedTargetDeltas=iu.calculatedProjections=0),this.nodes.forEach(z8),this.nodes.forEach(Y8),this.nodes.forEach(W8),this.nodes.forEach(H8),$l.addProjectionMetrics&&$l.addProjectionMetrics(iu)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=i?i.root||i:this,this.path=i?[...i.path,i]:[],this.parent=i,this.depth=i?i.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new ly)}addEventListener(s,i){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new pn),this.eventHandlers.get(s).add(i)}notifyListeners(s,...i){let l=this.eventHandlers.get(s);l&&l.notify(...i)}hasListeners(s){return this.eventHandlers.has(s)}mount(s){if(this.instance)return;this.isSVG=cf(s)&&!Jk(s),this.instance=s;let{layoutId:i,layout:l,visualElement:u}=this.options;if(u&&!u.current&&u.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(l||i)&&(this.isLayoutDirty=!0),e){let c,d=0,f=()=>this.root.updateBlockedByResize=!1;ze.read(()=>{d=window.innerWidth}),e(s,()=>{let m=window.innerWidth;m!==d&&(d=m,this.root.updateBlockedByResize=!0,c&&c(),c=CN(f,250),su.hasAnimatedSinceResize&&(su.hasAnimatedSinceResize=!1,this.nodes.forEach(IN)))})}i&&this.root.registerSharedNode(i,this),this.options.animate!==!1&&u&&(i||l)&&this.addEventListener("didUpdate",({delta:c,hasLayoutChanged:d,hasRelativeLayoutChanged:f,layout:m})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let p=this.options.transition||u.getDefaultTransition()||$8,{onLayoutAnimationStart:y,onLayoutAnimationComplete:b}=u.getProps(),g=!this.targetLayout||!j0(this.targetLayout,m),h=!d&&f;if(this.options.layoutRoot||this.resumeFrom||h||d&&(g||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);let x={...sf(p,"layout"),onPlay:y,onComplete:b};(u.shouldReduceMotion||this.options.layoutRoot)&&(x.delay=0,x.type=!1),this.startAnimation(x),this.setAnimationOrigin(c,h,x.path)}else d||IN(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=m})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Eo(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(K8),this.animationId++)}getTransformTemplate(){let{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&PN(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let c=0;c<this.path.length;c++){let d=this.path[c];d.shouldResetTransform=!0,(typeof d.latestValues.x=="string"||typeof d.latestValues.y=="string")&&(d.isLayoutDirty=!0),d.updateScroll("snapshot"),d.options.layoutRoot&&d.willUpdate(!1)}let{layoutId:i,layout:l}=this.options;if(i===void 0&&!l)return;let u=this.getTransformTemplate();this.prevTransformTemplateValue=u?u(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){let l=this.updateBlockedByResize;this.unblockUpdate(),this.updateBlockedByResize=!1,this.clearAllSnapshots(),l&&this.nodes.forEach(q8),this.nodes.forEach(RN);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(TN);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(G8),this.nodes.forEach(j8),this.nodes.forEach(X8),this.nodes.forEach(F8),this.nodes.forEach(_8)):this.nodes.forEach(TN),this.clearAllSnapshots();let i=gt.now();Tt.delta=fa(0,1e3/60,i-Tt.timestamp),Tt.timestamp=i,Tt.isProcessing=!0,ap.update.process(Tt),ap.preRender.process(Tt),ap.render.process(Tt),Tt.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Ql.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(U8),this.sharedNodes.forEach(Z8)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,ze.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){ze.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!ra(this.snapshot.measuredBox.x)&&!ra(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let l=0;l<this.path.length;l++)this.path[l].updateScroll();let s=this.layout;this.layout=this.measure(!1),this.layoutCorrected||(this.layoutCorrected=kt()),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);let{visualElement:i}=this.options;i&&i.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let i=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(i=!1),i&&this.instance){let l=o(this.instance);this.scroll={animationId:this.root.animationId,phase:s,isRoot:l,offset:a(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!r)return;let s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,i=this.projectionDelta&&!G0(this.projectionDelta),l=this.getTransformTemplate(),u=l?l(this.latestValues,""):void 0,c=u!==this.prevTransformTemplateValue;s&&this.instance&&(i||ns(this.latestValues)||c)&&(r(this.instance,u),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){let i=this.measurePageBox(),l=this.removeElementScroll(i);return s&&(l=this.removeTransform(l)),ej(l),{animationId:this.root.animationId,measuredBox:i,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){let{visualElement:s}=this.options;if(!s)return kt();let i=s.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(tj))){let{scroll:u}=this.root;u&&(gr(i.x,u.offset.x),gr(i.y,u.offset.y))}return i}removeElementScroll(s){let i=kt();if(yr(i,s),this.scroll?.wasRoot)return i;for(let l=0;l<this.path.length;l++){let u=this.path[l],{scroll:c,options:d}=u;u!==this.root&&c&&d.layoutScroll&&(c.wasRoot&&yr(i,s),gr(i.x,c.offset.x),gr(i.y,c.offset.y))}return i}applyTransform(s,i=!1,l){let u=l||kt();yr(u,s);for(let c=0;c<this.path.length;c++){let d=this.path[c];!i&&d.options.layoutScroll&&d.scroll&&d!==d.root&&(gr(u.x,-d.scroll.offset.x),gr(u.y,-d.scroll.offset.y)),ns(d.latestValues)&&hp(u,d.latestValues,d.layout?.layoutBox)}return ns(this.latestValues)&&hp(u,this.latestValues,this.layout?.layoutBox),u}removeTransform(s){let i=kt();yr(i,s);for(let l=0;l<this.path.length;l++){let u=this.path[l];if(!ns(u.latestValues))continue;let c;u.instance&&(Kx(u.latestValues)&&u.updateSnapshot(),c=kt(),yr(c,u.measurePageBox())),q0(i,u.latestValues,u.snapshot?.layoutBox,c)}return ns(this.latestValues)&&q0(i,this.latestValues),i}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Tt.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){let i=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=i.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=i.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=i.isSharedProjectionDirty);let l=!!this.resumingFrom||this!==i;if(!(s||l&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:c,layoutId:d}=this.options;if(!this.layout||!(c||d))return;this.resolvedRelativeTargetAt=Tt.timestamp;let f=this.getClosestProjectingParent();!this.targetDelta&&!this.relativeTarget&&(this.options.layoutAnchor!==!1&&f&&f.layout?this.createRelativeTarget(f,this.layout.layoutBox,f.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=kt(),this.targetWithTransforms=kt()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),U0(this.target,this.relativeTarget,this.relativeParent.target,this.options.layoutAnchor||void 0)):this.targetDelta?(this.resumingFrom?this.applyTransform(this.layout.layoutBox,!1,this.target):yr(this.target,this.layout.layoutBox),v0(this.target,this.targetDelta)):yr(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,this.options.layoutAnchor!==!1&&f&&!!f.resumingFrom==!!this.resumingFrom&&!f.options.layoutScroll&&f.target&&this.animationProgress!==1?this.createRelativeTarget(f,this.target,f.target):this.relativeParent=this.relativeTarget=void 0),$l.value&&iu.calculatedTargetDeltas++)}getClosestProjectingParent(){if(!(!this.parent||Kx(this.parent.latestValues)||S0(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(s,i,l){this.relativeParent=s,this.forceRelativeParentToResolveTarget(),this.relativeTarget=kt(),this.relativeTargetOrigin=kt(),hf(this.relativeTargetOrigin,i,l,this.options.layoutAnchor||void 0),yr(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){let s=this.getLead(),i=!!this.resumingFrom||this!==s,l=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(l=!1),i&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===Tt.timestamp&&(l=!1),l)return;let{layout:u,layoutId:c}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(u||c))return;yr(this.layoutCorrected,this.layout.layoutBox);let d=this.treeScale.x,f=this.treeScale.y;Gk(this.layoutCorrected,this.treeScale,this.path,i),s.layout&&!s.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(s.target=s.layout.layoutBox,s.targetWithTransforms=kt());let{target:m}=s;if(!m){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(B0(this.prevProjectionDelta.x,this.projectionDelta.x),B0(this.prevProjectionDelta.y,this.projectionDelta.y)),ru(this.projectionDelta,this.layoutCorrected,m,this.latestValues),(this.treeScale.x!==d||this.treeScale.y!==f||!Y0(this.projectionDelta.x,this.prevProjectionDelta.x)||!Y0(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",m)),$l.value&&iu.calculatedProjections++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){if(this.options.visualElement?.scheduleRender(),s){let i=this.getStack();i&&i.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Ci(),this.projectionDelta=Ci(),this.projectionDeltaWithTransform=Ci()}setAnimationOrigin(s,i=!1,l){let u=this.snapshot,c=u?u.latestValues:{},d={...this.latestValues},f=Ci();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!i;let m=kt(),p=u?u.source:void 0,y=this.layout?this.layout.source:void 0,b=p!==y,g=this.getStack(),h=!g||g.members.length<=1,x=!!(b&&!h&&this.options.crossfade===!0&&!this.path.some(J8));this.animationProgress=0;let S,v=l?.interpolateProjection(s);this.mixTargetDelta=R=>{let L=R/1e3,C=v?.(L);C?(f.x.translate=C.x,f.x.scale=qe(s.x.scale,1,L),f.x.origin=s.x.origin,f.x.originPoint=s.x.originPoint,f.y.translate=C.y,f.y.scale=qe(s.y.scale,1,L),f.y.origin=s.y.origin,f.y.originPoint=s.y.originPoint):(wN(f.x,s.x,L),wN(f.y,s.y,L)),this.setTargetDelta(f),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(hf(m,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),Q8(this.relativeTarget,this.relativeTargetOrigin,m,L),S&&dN(this.relativeTarget,S)&&(this.isProjectionDirty=!1),S||(S=kt()),yr(S,this.relativeTarget)),b&&(this.animationValues=d,yN(d,c,this.latestValues,L,x,h)),C&&C.rotate!==void 0&&(this.animationValues||(this.animationValues=d),this.animationValues.pathRotation=C.rotate),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=L},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(Eo(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=ze.update(()=>{su.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=zr(0)),this.motionValue.jump(0,!1),this.currentAnimation=bN(this.motionValue,[0,1e3],{...s,velocity:0,isSync:!0,onUpdate:i=>{this.mixTargetDelta(i),s.onUpdate&&s.onUpdate(i)},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),$O(this.currentAnimation,this),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(V8),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let s=this.getLead(),{targetWithTransforms:i,layout:l,latestValues:u}=s,{target:c}=s;if(!(!i||!c||!l)){if(this!==s&&this.layout&&l&&ON(this.options.animationType,this.layout.layoutBox,l.layoutBox)){c=this.target||kt();let d=ra(this.layout.layoutBox.x);c.x.min=s.target.x.min,c.x.max=c.x.min+d;let f=ra(this.layout.layoutBox.y);c.y.min=s.target.y.min,c.y.max=c.y.min+f}yr(i,c),hp(i,u),ru(this.projectionDeltaWithTransform,this.layoutCorrected,i,u)}}registerSharedNode(s,i){this.sharedNodes.has(s)||this.sharedNodes.set(s,new uy),this.sharedNodes.get(s).add(i);let u=i.options.initialPromotionConfig;i.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(i):void 0})}isLead(){let s=this.getStack();return s?s.lead===this:!0}getLead(){let{layoutId:s}=this.options;return s?this.getStack()?.lead||this:this}getPrevLead(){let{layoutId:s}=this.options;return s?this.getStack()?.prevLead:void 0}getStack(){let{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:i,preserveFollowOpacity:l}={}){let u=this.getStack();u&&u.promote(this,l),s&&(this.projectionDelta=void 0,this.needsReset=!0),i&&this.setOptions({transition:i})}relegate(){let s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){let{visualElement:s}=this.options;if(!s)return;let i=!1,{latestValues:l}=s;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(i=!0),!i)return;let u={};l.z&&K0("z",s,u,this.animationValues);for(let c=0;c<W0.length;c++)K0(`rotate${W0[c]}`,s,u,this.animationValues),K0(`skew${W0[c]}`,s,u,this.animationValues);s.render();for(let c in u)s.setStaticValue(c,u[c]),this.animationValues&&(this.animationValues[c]=u[c]);s.scheduleRender()}applyProjectionStyles(s,i){if(!this.instance||this.isSVG)return;if(!this.isVisible){s.visibility="hidden";return}let l=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,s.visibility="",s.opacity="",s.pointerEvents=nu(i?.pointerEvents)||"",s.transform=l?l(this.latestValues,""):"none";return}let u=this.getLead();if(!this.projectionDelta||!this.layout||!u.target){this.options.layoutId&&(s.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,s.pointerEvents=nu(i?.pointerEvents)||""),this.hasProjected&&!ns(this.latestValues)&&(s.transform=l?l({},""):"none",this.hasProjected=!1);return}s.visibility="";let c=u.animationValues||u.latestValues;this.applyTransformsToTarget();let d=hN(this.projectionDeltaWithTransform,this.treeScale,c);l&&(d=l(c,d)),s.transform=d;let{x:f,y:m}=this.projectionDelta;s.transformOrigin=`${f.origin*100}% ${m.origin*100}% 0`,u.animationValues?s.opacity=u===this?c.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:c.opacityExit:s.opacity=u===this?c.opacity!==void 0?c.opacity:"":c.opacityExit!==void 0?c.opacityExit:0;for(let p in tu){if(c[p]===void 0)continue;let{correct:y,applyTo:b,isCSSVariable:g}=tu[p],h=d==="none"?c[p]:y(c[p],u);if(b){let x=b.length;for(let S=0;S<x;S++)s[b[S]]=h}else g?this.options.visualElement.renderState.vars[p]=h:s[p]=h}this.options.layoutId&&(s.pointerEvents=u===this?nu(i?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>s.currentAnimation?.stop()),this.root.nodes.forEach(RN),this.root.sharedNodes.clear()}}}function F8(e){e.updateLayout()}function _8(e){let t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){let{layoutBox:a,measuredBox:o}=e.layout,{animationType:r}=e.options,n=t.source!==e.layout.source;if(r==="size")Ko(c=>{let d=n?t.measuredBox[c]:t.layoutBox[c],f=ra(d);d.min=a[c].min,d.max=d.min+f});else if(r==="x"||r==="y"){let c=r==="x"?"y":"x";iy(n?t.measuredBox[c]:t.layoutBox[c],a[c])}else ON(r,t.layoutBox,a)&&Ko(c=>{let d=n?t.measuredBox[c]:t.layoutBox[c],f=ra(a[c]);d.max=d.min+f,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[c].max=e.relativeTarget[c].min+f)});let s=Ci();ru(s,a,t.layoutBox);let i=Ci();n?ru(i,e.applyTransform(o,!0),t.measuredBox):ru(i,a,t.layoutBox);let l=!G0(s),u=!1;if(!e.resumeFrom){let c=e.getClosestProjectingParent();if(c&&!c.resumeFrom){let{snapshot:d,layout:f}=c;if(d&&f){let m=e.options.layoutAnchor||void 0,p=kt();hf(p,t.layoutBox,d.layoutBox,m);let y=kt();hf(y,a,f.layoutBox,m),j0(p,y)||(u=!0),c.options.layoutRoot&&(e.relativeTarget=y,e.relativeTargetOrigin=p,e.relativeParent=c)}}}e.notifyListeners("didUpdate",{layout:a,snapshot:t,delta:i,layoutDelta:s,hasLayoutChanged:l,hasRelativeLayoutChanged:u})}else if(e.isLead()){let{onExitComplete:a}=e.options;a&&a()}e.options.transition=void 0}function z8(e){$l.value&&iu.nodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function H8(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function U8(e){e.clearSnapshot()}function RN(e){e.clearMeasurements()}function q8(e){e.isLayoutDirty=!0,e.updateLayout()}function TN(e){e.isLayoutDirty=!1}function G8(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.layout,e.isLayoutDirty=!0)}function j8(e){e.relativeTarget&&e.relativeParent?.isLayoutDirty&&(e.currentAnimation?e.isLayoutDirty=!0:(e.targetDelta=void 0,e.removeRelativeTarget()))}function X8(e){let{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function IN(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Y8(e){e.resolveTargetDelta()}function W8(e){e.calcProjection()}function K8(e){e.resetSkewAndRotation()}function Z8(e){e.removeLeadSnapshot()}function wN(e,t,a){e.translate=qe(t.translate,0,a),e.scale=qe(t.scale,1,a),e.origin=t.origin,e.originPoint=t.originPoint}function EN(e,t,a,o){e.min=qe(t.min,a.min,o),e.max=qe(t.max,a.max,o)}function Q8(e,t,a,o){EN(e.x,t.x,a.x,o),EN(e.y,t.y,a.y,o)}function J8(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}var $8={duration:.45,ease:[.4,0,.1,1]},AN=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),DN=AN("applewebkit/")&&!AN("chrome/")?Math.round:Xt;function MN(e){e.min=DN(e.min),e.max=DN(e.max)}function ej(e){MN(e.x),MN(e.y)}function ON(e,t,a){return e==="position"||e==="preserve-aspect"&&!H0(X0(t),X0(a),.2)}function tj(e){return e!==e.root&&e.scroll?.wasRoot}var kN=cy({attachResizeListener:(e,t)=>bn(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body?.scrollLeft||0,y:document.documentElement.scrollTop||document.body?.scrollTop||0}),checkIsScrollRoot:()=>!0});var fy={current:void 0},Tp=cy({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!fy.current){let e=new kN({});e.mount(window),e.setOptions({layoutScroll:!0}),fy.current=e}return fy.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"});var dy=T(M(),1),ls=T(M(),1);var NN=T(M(),1),is=(0,NN.createContext)({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});var BN=T(M(),1);function VN(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function aj(...e){return t=>{let a=!1,o=e.map(r=>{let n=VN(r,t);return!a&&typeof n=="function"&&(a=!0),n});if(a)return()=>{for(let r=0;r<o.length;r++){let n=o[r];typeof n=="function"?n():VN(e[r],null)}}}}function FN(...e){return BN.useCallback(aj(...e),e)}var Z0=class extends dy.Component{getSnapshotBeforeUpdate(t){let a=this.props.childRef.current;if(Kl(a)&&t.isPresent&&!this.props.isPresent&&this.props.pop!==!1){let o=a.offsetParent,r=Kl(o)&&o.offsetWidth||0,n=Kl(o)&&o.offsetHeight||0,s=getComputedStyle(a),i=this.props.sizeRef.current;i.height=parseFloat(s.height),i.width=parseFloat(s.width),i.top=a.offsetTop,i.left=a.offsetLeft,i.right=r-i.width-i.left,i.bottom=n-i.height-i.top,i.direction=s.direction}return null}componentDidUpdate(){}render(){return this.props.children}};function zN({children:e,isPresent:t,anchorX:a,anchorY:o,root:r,pop:n}){let s=(0,ls.useId)(),i=(0,ls.useRef)(null),l=(0,ls.useRef)({width:0,height:0,top:0,left:0,right:0,bottom:0,direction:"ltr"}),{nonce:u}=(0,ls.useContext)(is),c=n!==!1?e.props?.ref??e?.ref:void 0,d=FN(i,c);return(0,ls.useInsertionEffect)(()=>{let{width:f,height:m,top:p,left:y,right:b,bottom:g,direction:h}=l.current;if(t||n===!1||!i.current||!f||!m)return;let x=h==="rtl",S=a==="left"?x?`right: ${b}`:`left: ${y}`:x?`left: ${y}`:`right: ${b}`,v=o==="bottom"?`bottom: ${g}`:`top: ${p}`;i.current.dataset.motionPopId=s;let R=document.createElement("style");u&&(R.nonce=u);let L=r??document.head;return L.appendChild(R),R.sheet&&R.sheet.insertRule(`
|
|
10
|
+
[data-motion-pop-id="${s}"] {
|
|
11
|
+
position: absolute !important;
|
|
12
|
+
width: ${f}px !important;
|
|
13
|
+
height: ${m}px !important;
|
|
14
|
+
${S}px !important;
|
|
15
|
+
${v}px !important;
|
|
16
|
+
}
|
|
17
|
+
`),()=>{i.current?.removeAttribute("data-motion-pop-id"),L.contains(R)&&L.removeChild(R)}},[t]),(0,_N.jsx)(Z0,{isPresent:t,childRef:i,sizeRef:l,pop:n,children:n===!1?e:dy.cloneElement(e,{ref:d})})}var UN=({children:e,initial:t,isPresent:a,onExitComplete:o,custom:r,presenceAffectsLayout:n,mode:s,anchorX:i,anchorY:l,root:u})=>{let c=di(oj),d=(0,Ti.useId)(),f=(0,Ti.useRef)(a),m=(0,Ti.useRef)(o);mi(()=>{f.current=a,m.current=o});let p=!0,y=(0,Ti.useMemo)(()=>(p=!1,{id:d,initial:t,isPresent:a,custom:r,onExitComplete:b=>{c.set(b,!0);for(let g of c.values())if(!g)return;o&&o()},register:b=>(c.set(b,!1),()=>{c.delete(b),!f.current&&!c.size&&m.current?.()})}),[a,c,o]);return n&&p&&(y={...y}),(0,Ti.useMemo)(()=>{c.forEach((b,g)=>c.set(g,!1))},[a]),HN.useEffect(()=>{!a&&!c.size&&o&&o()},[a]),e=(0,Q0.jsx)(zN,{pop:s==="popLayout",isPresent:a,anchorX:i,anchorY:l,root:u,children:e}),(0,Q0.jsx)(pi.Provider,{value:y,children:e})};function oj(){return new Map}var Ii=T(M(),1);function my(e=!0){let t=(0,Ii.useContext)(pi);if(t===null)return[!0,null];let{isPresent:a,onExitComplete:o,register:r}=t,n=(0,Ii.useId)();(0,Ii.useEffect)(()=>{if(e)return r(n)},[e]);let s=(0,Ii.useCallback)(()=>e&&o&&o(n),[n,o,e]);return!a&&o?[!1,s]:[!0]}var py=T(M(),1),xf=e=>e.key||"";function J0(e){let t=[];return py.Children.forEach(e,a=>{(0,py.isValidElement)(a)&&t.push(a)}),t}var wi=({children:e,custom:t,initial:a=!0,onExitComplete:o,presenceAffectsLayout:r=!0,mode:n="sync",propagate:s=!1,anchorX:i="left",anchorY:l="top",root:u})=>{let[c,d]=my(s),f=(0,vn.useMemo)(()=>J0(e),[e]),m=s&&!c?[]:f.map(xf),p=(0,vn.useRef)(!0),y=di(()=>new Map),b=(0,vn.useRef)(new Set),[g,h]=(0,vn.useState)(f),[x,S]=(0,vn.useState)(f);mi(()=>{s&&!c&&!x.length&&d?.()},[c,s,x.length,d]),mi(()=>{p.current=!1;for(let L=0;L<x.length;L++){let C=xf(x[L]);m.includes(C)?(y.delete(C),b.current.delete(C)):y.get(C)!==!0&&y.set(C,!1)}},[x,m.length,m.join("-")]);let v=[];if(f!==g){let L=[...f],C=0;for(let E of x){let I=m.indexOf(xf(E));I===-1?(L.splice(C++,0,E),v.push(E)):C=I+v.length+1}return v.every(E=>y.get(xf(E)))?L=f:n==="wait"&&(L=v),S(J0(L)),h(f),null}let{forceRender:R}=(0,vn.useContext)(Yc);return(0,Ip.jsx)(Ip.Fragment,{children:x.map(L=>{let C=xf(L),E=s&&!c?!1:f===x||m.includes(C),I=()=>{if(b.current.has(C))return;if(y.has(C))b.current.add(C),y.set(C,!0);else return;let A=!0;y.forEach(N=>{N||(A=!1)}),A&&(R?.(),h([]),s&&d?.(),o&&o())};return(0,Ip.jsx)(UN,{isPresent:E,initial:!p.current||a?void 0:!1,custom:t,presenceAffectsLayout:r,mode:n,root:u,onExitComplete:E?void 0:I,anchorX:i,anchorY:l,children:L},C)})})};var qN=T(M(),1),hy=(0,qN.createContext)({strict:!1});var GN={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},jN=!1;function rj(){if(jN)return;let e={};for(let t in GN)e[t]={isEnabled:a=>GN[t].some(o=>!!a[o])};Sp(e),jN=!0}function gy(){return rj(),O0()}function XN(e){let t=gy();for(let a in e)t[a]={...t[a],...e[a]};Sp(t)}var YN=T(Q(),1),xy=T(M(),1);function yy({children:e,...t}){let a=(0,xy.useContext)(is);t={...a,...t},t.transition=Xl(t.transition,a.transition),t.isStatic=di(()=>t.isStatic);let o=(0,xy.useMemo)(()=>t,[JSON.stringify(t.transition),t.transformPagePoint,t.reducedMotion,t.skipAnimations,t.isValidProp]);return(0,YN.jsx)(is.Provider,{value:o,children:e})}var Ly=T(Q(),1);var vf=T(M(),1);var WN=T(M(),1),Ei=(0,WN.createContext)({});var Sy=T(M(),1);function KN(e,t){if(Li(e)){let{initial:a,animate:o}=e;return{initial:a===!1||Sn(a)?a:void 0,animate:Sn(o)?o:void 0}}return e.inherit!==!1?t:{}}function QN(e){let{initial:t,animate:a}=KN(e,(0,Sy.useContext)(Ei));return(0,Sy.useMemo)(()=>({initial:t,animate:a}),[ZN(t),ZN(a)])}function ZN(e){return Array.isArray(e)?e.join(" "):e}var bf=T(M(),1);var JN=T(M(),1);var yf=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function $0(e,t,a){for(let o in t)!mt(t[o])&&!bp(o,a)&&(e[o]=t[o])}function nj({transformTemplate:e},t){return(0,JN.useMemo)(()=>{let a=yf();return Zl(a,t,e),Object.assign({},a.vars,a.style)},[t])}function sj(e,t){let a=e.style||{},o={};return $0(o,a,e),Object.assign(o,nj(e,t)),o}function $N(e,t){let a={},o=sj(e,t);return e.drag&&e.dragListener!==!1&&(a.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(a.tabIndex=0),a.style=o,a}var eV=T(M(),1);var by=()=>({...yf(),attrs:{}});function tV(e,t,a,o){let r=(0,eV.useMemo)(()=>{let n=by();return dp(n,t,Cp(o),e.transformTemplate,e.style),{...n.attrs,style:{...n.style}}},[t]);if(e.style){let n={};$0(n,e.style,e),r.style={...n,...r.style}}return r}var ij=new Set(["animate","exit","variants","initial","style","values","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function wp(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||ij.has(e)}function lj(e,t){return e.startsWith("on")?!wp(e):t?.(e)??!wp(e)}function aV(e,t,a,o){let r={};for(let n in e)n==="values"&&typeof e.values=="object"||mt(e[n])||(lj(n,o)||a===!0&&wp(n)||!t&&!wp(n)||e.draggable&&n.startsWith("onDrag"))&&(r[n]=e[n]);return r}var oV=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Sf(e){return typeof e!="string"||e.includes("-")?!1:!!(oV.indexOf(e)>-1||/[A-Z]/u.test(e))}function rV(e,t,a,{latestValues:o},r,n=!1,s,i){let u=(s??Sf(e)?tV:$N)(t,o,r,e),c=aV(t,typeof e=="string",n,i),d=e!==bf.Fragment?{...c,...u,ref:a}:{},{children:f}=t,m=(0,bf.useMemo)(()=>mt(f)?f.get():f,[f]);return(0,bf.createElement)(e,{...d,children:m})}var eT=T(M(),1);function uj({scrapeMotionValuesFromProps:e,createRenderState:t},a,o,r){return{latestValues:cj(a,o,r,e),renderState:t()}}function cj(e,t,a,o){let r={},n=o(e,{});for(let f in n)r[f]=nu(n[f]);let{initial:s,animate:i}=e,l=Li(e),u=gp(e);t&&u&&!l&&e.inherit!==!1&&(s===void 0&&(s=t.initial),i===void 0&&(i=t.animate));let c=a?a.initial===!1:!1;c=c||s===!1;let d=c?i:s;if(d&&typeof d!="boolean"&&!ss(d)){let f=Array.isArray(d)?d:[d];for(let m=0;m<f.length;m++){let p=Wl(e,f[m]);if(p){let{transitionEnd:y,transition:b,...g}=p;for(let h in g){let x=g[h];if(Array.isArray(x)){let S=c?x.length-1:0;x=x[S]}x!==null&&(r[h]=x)}for(let h in y)r[h]=y[h]}}}return r}var vy=e=>(t,a)=>{let o=(0,eT.useContext)(Ei),r=(0,eT.useContext)(pi),n=()=>uj(e,t,o,r);return a?n():di(n)};var nV=vy({scrapeMotionValuesFromProps:au,createRenderState:yf});var sV=vy({scrapeMotionValuesFromProps:Lp,createRenderState:by});var iV=Symbol.for("motionComponentSymbol");var lu=T(M(),1);function lV(e,t,a){let o=(0,lu.useRef)(a);(0,lu.useInsertionEffect)(()=>{o.current=a});let r=(0,lu.useRef)(null);return(0,lu.useCallback)(n=>{n&&e.onMount?.(n),t&&(n?t.mount(n):t.unmount());let s=o.current;if(typeof s=="function")if(n){let i=s(n);typeof i=="function"&&(r.current=i)}else r.current?(r.current(),r.current=null):s(n);else s&&(s.current=n)},[t])}var so=T(M(),1);var uV=T(M(),1),Cy=(0,uV.createContext)({});function Ai(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function cV(e,t,a,o,r,n){let{visualElement:s}=(0,so.useContext)(Ei),i=(0,so.useContext)(hy),l=(0,so.useContext)(pi),u=(0,so.useContext)(is),c=u.reducedMotion,d=u.skipAnimations,f=(0,so.useRef)(null),m=(0,so.useRef)(!1);o=o||i.renderer,!f.current&&o&&(f.current=o(e,{visualState:t,parent:s,props:a,presenceContext:l,blockInitialAnimation:l?l.initial===!1:!1,reducedMotionConfig:c,skipAnimations:d,isSVG:n}),m.current&&f.current&&(f.current.manuallyAnimateOnMount=!0));let p=f.current,y=(0,so.useContext)(Cy);p&&!p.projection&&r&&(p.type==="html"||p.type==="svg")&&fj(f.current,a,r,y);let b=(0,so.useRef)(!1);(0,so.useInsertionEffect)(()=>{p&&b.current&&p.update(a,l)});let g=a[up],h=(0,so.useRef)(!!g&&typeof window<"u"&&!window.MotionHandoffIsComplete?.(g)&&window.MotionHasOptimisedAnimation?.(g));return mi(()=>{!m.current||!p||(p.animationState?.animateChanges(),p.enteringChildren=void 0)},[]),mi(()=>{m.current=!0,p&&(b.current=!0,window.MotionIsMounted=!0,p.updateFeatures(),p.scheduleRenderMicrotask(),h.current&&p.animationState&&p.animationState.animateChanges())}),(0,so.useEffect)(()=>{p&&(!h.current&&p.animationState&&p.animationState.animateChanges(),h.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(g)}),h.current=!1),p.enteringChildren=void 0)}),p}function fj(e,t,a,o){let{layoutId:r,layout:n,drag:s,dragConstraints:i,layoutScroll:l,layoutRoot:u,layoutAnchor:c,layoutCrossfade:d}=t;e.projection=new a(e.latestValues,t["data-framer-portal-id"]?void 0:fV(e.parent)),e.projection.setOptions({layoutId:r,layout:n,alwaysMeasureLayout:!!s||i&&Ai(i),visualElement:e,animationType:typeof n=="string"?n:"both",initialPromotionConfig:o,crossfade:d,layoutScroll:l,layoutRoot:u,layoutAnchor:c})}function fV(e){if(e)return e.options.allowProjection!==!1?e.projection:fV(e.parent)}function Ry(e,{forwardMotionProps:t=!1,type:a}={},o,r){o&&XN(o);let n=a?a==="svg":Sf(e),s=n?sV:nV;function i(u,c){let d,f={...(0,vf.useContext)(is),...u,layoutId:dj(u)},{isStatic:m,isValidProp:p}=f,y=QN(u),b=s(u,m);if(!m&&typeof window<"u"){mj(f,o);let g=pj(f);d=g.MeasureLayout,y.visualElement=cV(e,b,f,r,g.ProjectionNode,n)}return(0,Ly.jsxs)(Ei.Provider,{value:y,children:[d&&y.visualElement?(0,Ly.jsx)(d,{visualElement:y.visualElement,...f}):null,rV(e,u,lV(b,y.visualElement,c),b,m,t,n,p)]})}i.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;let l=(0,vf.forwardRef)(i);return l[iV]=e,l}function dj({layoutId:e}){let t=(0,vf.useContext)(Yc).id;return t&&e!==void 0?t+"-"+e:e}function mj(e,t){let a=(0,vf.useContext)(hy).strict}function pj(e){let t=gy(),{drag:a,layout:o}=t;if(!a&&!o)return{};let r={...a,...o};return{MeasureLayout:a?.isEnabled(e)||o?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function dV(e,t){if(typeof Proxy>"u")return Ry;let a=new Map,o=(n,s)=>Ry(n,s,e,t),r=(n,s)=>o(n,s);return new Proxy(r,{get:(n,s)=>s==="create"?o:(a.has(s)||a.set(s,Ry(s,void 0,e,t)),a.get(s))})}var mV=T(M(),1);var pV=(e,t)=>t.isSVG??Sf(e)?new Rp(t):new vp(t,{allowProjection:e!==mV.Fragment});var Ty=class extends da{constructor(t){super(t),t.animationState||(t.animationState=V0(t))}updateAnimationControlsSubscription(){let{animate:t}=this.node.getProps();ss(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:t}=this.node.getProps(),{animate:a}=this.node.prevProps||{};t!==a&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}};var hj=0,Iy=class extends da{constructor(){super(...arguments),this.id=hj++,this.isExitComplete=!1}update(){if(!this.node.presenceContext)return;let{isPresent:t,onExitComplete:a}=this.node.presenceContext,{isPresent:o}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===o)return;if(t&&o===!1){if(this.isExitComplete){let{initial:n,custom:s}=this.node.getProps();if(typeof n=="string"||typeof n=="object"&&n!==null&&!Array.isArray(n)){let i=Wo(this.node,n,s);if(i){let{transition:l,transitionEnd:u,...c}=i;for(let d in c)this.node.getValue(d)?.jump(c[d])}}this.node.blockInitialAnimation=!1,this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive("exit",!1);this.isExitComplete=!1,this.exitAnimation=void 0;return}let r=this.exitAnimation=this.node.animationState.setActive("exit",!t);a&&!t&&r.then(()=>{this.exitAnimation===r&&(this.isExitComplete=!0,a(this.id))})}mount(){let{register:t,onExitComplete:a}=this.node.presenceContext||{};a&&a(this.id),t&&(this.unmount=t(this.id))}unmount(){}};var hV={animation:{Feature:Ty},exit:{Feature:Iy}};function uu(e){return{point:{x:e.pageX,y:e.pageY}}}var gV=e=>t=>Jl(t)&&e(t,uu(t));function Di(e,t,a,o){return bn(e,t,gV(a),o)}var wy=({current:e})=>e?e.ownerDocument.defaultView:null;var xV=(e,t)=>Math.abs(e-t);function yV(e,t){let a=xV(e.x,t.x),o=xV(e.y,t.y);return Math.sqrt(a**2+o**2)}var SV=new Set(["auto","scroll"]),Cf=class{constructor(t,a,{transformPagePoint:o,contextWindow:r=window,dragSnapToOrigin:n=!1,distanceThreshold:s=3,element:i}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=p=>{this.handleScroll(p.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.hasPendingMove=!1,this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=Ey(this.lastRawMoveEventInfo,this.transformPagePoint));let p=tT(this.lastMoveEventInfo,this.history),y=this.startEvent!==null,b=yV(p.offset,{x:0,y:0})>=this.distanceThreshold;if(!y&&!b)return;let{point:g}=p;this.history.push({...g,timestamp:gt.now()});let{onStart:h,onMove:x}=this.handlers;y||(h&&h(this.lastMoveEvent,p),this.startEvent=this.lastMoveEvent),x&&x(this.lastMoveEvent,p)},this.handlePointerMove=(p,y)=>{this.lastMoveEvent=p,this.lastRawMoveEventInfo=y,this.lastMoveEventInfo=Ey(y,this.transformPagePoint),this.hasPendingMove=!0,ze.update(this.updatePoint,!0)},this.handlePointerUp=(p,y)=>{this.hasPendingMove&&this.updatePoint(),this.end();let{onEnd:b,onSessionEnd:g,resumeAnimation:h}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&h&&h(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let x=tT(p.type==="pointercancel"?this.lastMoveEventInfo:Ey(y,this.transformPagePoint),this.history);this.startEvent&&b&&b(p,x),g&&g(p,x)},!Jl(t))return;this.dragSnapToOrigin=n,this.handlers=a,this.transformPagePoint=o,this.distanceThreshold=s,this.contextWindow=r||window;let l=uu(t),u=Ey(l,this.transformPagePoint),{point:c}=u,{timestamp:d}=Tt;this.history=[{...c,timestamp:d}];let{onSessionStart:f}=a;f&&f(t,tT(u,this.history));let m={passive:!0,capture:!0};this.removeListeners=_r(Di(this.contextWindow,"pointermove",this.handlePointerMove,m),Di(this.contextWindow,"pointerup",this.handlePointerUp,m),Di(this.contextWindow,"pointercancel",this.handlePointerUp,m)),i&&this.startScrollTracking(i)}startScrollTracking(t){let a=t.parentElement;for(;a;){let o=getComputedStyle(a);(SV.has(o.overflowX)||SV.has(o.overflowY))&&this.scrollPositions.set(a,{x:a.scrollLeft,y:a.scrollTop}),a=a.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){let a=this.scrollPositions.get(t);if(!a)return;let o=t===window,r=o?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},n={x:r.x-a.x,y:r.y-a.y};n.x===0&&n.y===0||(o?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=n.x,this.lastMoveEventInfo.point.y+=n.y):this.history.length>0&&(this.history[0].x-=n.x,this.history[0].y-=n.y),this.scrollPositions.set(t,r),ze.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Eo(this.updatePoint)}};function Ey(e,t){return t?{point:t(e.point)}:e}function bV(e,t){return{x:e.x-t.x,y:e.y-t.y}}function tT({point:e},t){return{point:e,delta:bV(e,vV(t)),offset:bV(e,gj(t)),velocity:xj(t,.1)}}function gj(e){return e[0]}function vV(e){return e[e.length-1]}function xj(e,t){if(e.length<2)return{x:0,y:0};let a=e.length-1,o=null,r=vV(e);for(;a>=0&&(o=e[a],!(r.timestamp-o.timestamp>oa(t)));)a--;if(!o)return{x:0,y:0};o===e[0]&&e.length>2&&r.timestamp-o.timestamp>oa(t)*2&&(o=e[1]);let n=ba(r.timestamp-o.timestamp);if(n===0)return{x:0,y:0};let s={x:(r.x-o.x)/n,y:(r.y-o.y)/n};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function IV(e,{min:t,max:a},o){return t!==void 0&&e<t?e=o?qe(t,e,o.min):Math.max(e,t):a!==void 0&&e>a&&(e=o?qe(a,e,o.max):Math.min(e,a)),e}function CV(e,t,a){return{min:t!==void 0?e.min+t:void 0,max:a!==void 0?e.max+a-(e.max-e.min):void 0}}function wV(e,{top:t,left:a,bottom:o,right:r}){return{x:CV(e.x,a,r),y:CV(e.y,t,o)}}function LV(e,t){let a=t.min-e.min,o=t.max-e.max;return t.max-t.min<e.max-e.min&&([a,o]=[o,a]),{min:a,max:o}}function EV(e,t){return{x:LV(e.x,t.x),y:LV(e.y,t.y)}}function AV(e,t){let a=.5,o=ra(e),r=ra(t);return r>o?a=mn(t.min,t.max-o,e.min):o>r&&(a=mn(e.min,e.max-r,t.min)),fa(0,1,a)}function DV(e,t){let a={};return t.min!==void 0&&(a.min=t.min-e.min),t.max!==void 0&&(a.max=t.max-e.min),a}var Ay=.35;function MV(e=Ay){return e===!1?e=0:e===!0&&(e=Ay),{x:RV(e,"left","right"),y:RV(e,"top","bottom")}}function RV(e,t,a){return{min:TV(e,t),max:TV(e,a)}}function TV(e,t){return typeof e=="number"?e:e[t]||0}var yj=new WeakMap,My=class{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=kt(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:a=!1,distanceThreshold:o}={}){let{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;let n=d=>{a&&this.snapToCursor(d),this.stopAnimation()},s=(d,f)=>{let{drag:m,dragPropagation:p,onDragStart:y}=this.getProps();if(m&&!p&&(this.openDragLock&&this.openDragLock(),this.openDragLock=L0(m),!this.openDragLock))return;this.latestPointerEvent=d,this.latestPanInfo=f,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Ko(g=>{let h=this.getAxisMotionValue(g).get()||0;if(Xa.test(h)){let{projection:x}=this.visualElement;if(x&&x.layout){let S=x.layout.layoutBox[g];S&&(h=ra(S)*(parseFloat(h)/100))}}this.originPoint[g]=h}),y&&ze.update(()=>y(d,f),!1,!0),lf(this.visualElement,"transform");let{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},i=(d,f)=>{this.latestPointerEvent=d,this.latestPanInfo=f;let{dragPropagation:m,dragDirectionLock:p,onDirectionLock:y,onDrag:b}=this.getProps();if(!m&&!this.openDragLock)return;let{offset:g}=f;if(p&&this.currentDirection===null){this.currentDirection=bj(g),this.currentDirection!==null&&y&&y(this.currentDirection);return}this.updateAxis("x",f.point,g),this.updateAxis("y",f.point,g),this.visualElement.render(),b&&ze.update(()=>b(d,f),!1,!0)},l=(d,f)=>{this.latestPointerEvent=d,this.latestPanInfo=f,this.stop(d,f),this.latestPointerEvent=null,this.latestPanInfo=null},u=()=>{let{dragSnapToOrigin:d}=this.getProps();(d||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:c}=this.getProps();this.panSession=new Cf(t,{onSessionStart:n,onStart:s,onMove:i,onSessionEnd:l,resumeAnimation:u},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:c,distanceThreshold:o,contextWindow:wy(this.visualElement),element:this.visualElement.current})}stop(t,a){let o=t||this.latestPointerEvent,r=a||this.latestPanInfo,n=this.isDragging;if(this.cancel(),!n||!r||!o)return;let{velocity:s}=r;this.startAnimation(s);let{onDragEnd:i}=this.getProps();i&&ze.postRender(()=>i(o,r))}cancel(){this.isDragging=!1;let{projection:t,animationState:a}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.endPanSession();let{dragPropagation:o}=this.getProps();!o&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),a&&a.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(t,a,o){let{drag:r}=this.getProps();if(!o||!Dy(t,r,this.currentDirection))return;let n=this.getAxisMotionValue(t),s=this.originPoint[t]+o[t];this.constraints&&this.constraints[t]&&(s=IV(s,this.constraints[t],this.elastic[t])),n.set(s)}resolveConstraints(){let{dragConstraints:t,dragElastic:a}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,r=this.constraints;t&&Ai(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&o?this.constraints=wV(o.layoutBox,t):this.constraints=!1,this.elastic=MV(a),r!==this.constraints&&!Ai(t)&&o&&this.constraints&&!this.hasMutatedConstraints&&Ko(n=>{this.constraints!==!1&&this.getAxisMotionValue(n)&&(this.constraints[n]=DV(o.layoutBox[n],this.constraints[n]))})}resolveRefConstraints(){let{dragConstraints:t,onMeasureDragConstraints:a}=this.getProps();if(!t||!Ai(t))return!1;let o=t.current;wo(o!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");let{projection:r}=this.visualElement;if(!r||!r.layout)return!1;r.root&&(r.root.scroll=void 0,r.root.updateScroll());let n=C0(o,r.root,this.visualElement.getTransformPagePoint()),s=EV(r.layout.layoutBox,n);if(a){let i=a(g0(s));this.hasMutatedConstraints=!!i,i&&(s=mp(i))}return s}startAnimation(t){let{drag:a,dragMomentum:o,dragElastic:r,dragTransition:n,dragSnapToOrigin:s,onDragTransitionEnd:i}=this.getProps(),l=this.constraints||{},u=Ko(c=>{if(!Dy(c,a,this.currentDirection))return;let d=l&&l[c]||{};(s===!0||s===c)&&(d={min:0,max:0});let f=r?200:1e6,m=r?40:1e7,p={type:"inertia",velocity:o?t[c]:0,bounceStiffness:f,bounceDamping:m,timeConstant:750,restDelta:1,restSpeed:10,...n,...d};return this.startAxisValueAnimation(c,p)});return Promise.all(u).then(i)}startAxisValueAnimation(t,a){let o=this.getAxisMotionValue(t);return lf(this.visualElement,t),o.start(Yl(t,o,0,a,this.visualElement,!1))}stopAnimation(){Ko(t=>this.getAxisMotionValue(t).stop())}getAxisMotionValue(t){let a=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps()[a];return r||this.visualElement.getValue(t,this.visualElement.latestValues[t]??0)}snapToCursor({clientX:t,clientY:a}){let{drag:o}=this.getProps(),r={x:t,y:a},n=this.visualElement.getTransformPagePoint()?.(r)||r,s=this.visualElement.measureViewportBox();Ko(i=>{if(!Dy(i,o,this.currentDirection))return;let l=this.getAxisMotionValue(i),{min:u,max:c}=s[i];l.set((l.get()||0)+n[i]-qe(u,c,.5))})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:t,dragConstraints:a}=this.getProps(),{projection:o}=this.visualElement;if(!Ai(a)||!o||!this.constraints)return;this.stopAnimation();let r=this.constraints,n={x:0,y:0};Ko(i=>{let l=this.getAxisMotionValue(i).get();n[i]=AV({min:l,max:l},r[i])});let{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",o.root&&o.root.updateScroll(),o.updateLayout(),this.constraints=!1,this.resolveConstraints(),Ko(i=>{let l=this.getAxisMotionValue(i);if(!Dy(i,t,null)||!l.get())return;let{min:u,max:c}=this.constraints[i];l.set(qe(u,c,n[i]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;yj.set(this.visualElement,this);let t=this.visualElement.current,a=Di(t,"pointerdown",u=>{let{drag:c,dragListener:d=!0}=this.getProps(),f=u.target,m=f!==t&&w0(f);c&&d&&!m&&this.start(u)}),o,r=()=>{let{dragConstraints:u}=this.getProps();Ai(u)&&u.current&&(this.constraints=this.resolveRefConstraints(),o||(o=Sj(t,u.current,()=>this.scalePositionWithinConstraints())))},{projection:n}=this.visualElement,s=n.addEventListener("measure",r);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),ze.read(r);let i=bn(window,"resize",()=>this.scalePositionWithinConstraints()),l=n.addEventListener("didUpdate",(({delta:u,hasLayoutChanged:c})=>{this.isDragging&&c&&(Ko(d=>{let f=this.getAxisMotionValue(d);f&&(this.originPoint[d]+=u[d].translate,f.set(f.get()+u[d].translate))}),this.visualElement.render())}));return()=>{i(),a(),s(),l&&l(),o&&o()}}getProps(){let t=this.visualElement.getProps(),{drag:a=!1,dragDirectionLock:o=!1,dragPropagation:r=!1,dragConstraints:n=!1,dragElastic:s=Ay,dragMomentum:i=!0}=t;return{...t,drag:a,dragDirectionLock:o,dragPropagation:r,dragConstraints:n,dragElastic:s,dragMomentum:i}}};function PV(e){let t=!0;return()=>{if(t){t=!1;return}e()}}function Sj(e,t,a){let o=ay(e,PV(a)),r=ay(t,PV(a));return()=>{o(),r()}}function Dy(e,t,a){return(t===!0||t===e)&&(a===null||a===e)}function bj(e,t=10){let a=null;return Math.abs(e.y)>t?a="y":Math.abs(e.x)>t&&(a="x"),a}var Py=class extends da{constructor(t){super(t),this.removeGroupControls=Xt,this.removeListeners=Xt,this.controls=new My(t)}mount(){let{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Xt}update(){let{dragControls:t}=this.node.getProps(),{dragControls:a}=this.node.prevProps||{};t!==a&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}};var aT=e=>(t,a)=>{e&&ze.update(()=>e(t,a),!1,!0)},Oy=class extends da{constructor(){super(...arguments),this.removePointerDownListener=Xt}onPointerDown(t){this.session=new Cf(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:wy(this.node)})}createPanHandlers(){let{onPanSessionStart:t,onPanStart:a,onPan:o,onPanEnd:r}=this.node.getProps();return{onSessionStart:aT(t),onStart:aT(a),onMove:aT(o),onEnd:(n,s)=>{delete this.session,r&&ze.postRender(()=>r(n,s))}}}mount(){this.removePointerDownListener=Di(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}};var OV=T(Q(),1);var Ep=T(M(),1);var oT=!1,rT=class extends Ep.Component{componentDidMount(){let{visualElement:t,layoutGroup:a,switchLayoutGroup:o,layoutId:r}=this.props,{projection:n}=t;n&&(a.group&&a.group.add(n),o&&o.register&&r&&o.register(n),oT&&n.root.didUpdate(),n.addEventListener("animationComplete",()=>{this.safeToRemove()}),n.setOptions({...n.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),su.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){let{layoutDependency:a,visualElement:o,drag:r,isPresent:n}=this.props,{projection:s}=o;return s&&(s.isPresent=n,t.layoutDependency!==a&&s.setOptions({...s.options,layoutDependency:a}),oT=!0,r||t.layoutDependency!==a||a===void 0||t.isPresent!==n?s.willUpdate():this.safeToRemove(),t.isPresent!==n&&(n?s.promote():s.relegate()||ze.postRender(()=>{let i=s.getStack();(!i||!i.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){let{visualElement:t,layoutAnchor:a}=this.props,{projection:o}=t;o&&(o.options.layoutAnchor=a,o.root.didUpdate(),Ql.postRender(()=>{!o.currentAnimation&&o.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:t,layoutGroup:a,switchLayoutGroup:o}=this.props,{projection:r}=t;oT=!0,r&&(r.scheduleCheckAfterUnmount(),a&&a.group&&a.group.remove(r),o&&o.deregister&&o.deregister(r))}safeToRemove(){let{safeToRemove:t}=this.props;t&&t()}render(){return null}};function ky(e){let[t,a]=my(),o=(0,Ep.useContext)(Yc);return(0,OV.jsx)(rT,{...e,layoutGroup:o,switchLayoutGroup:(0,Ep.useContext)(Cy),isPresent:t,safeToRemove:a})}var kV={pan:{Feature:Oy},drag:{Feature:Py,ProjectionNode:Tp,MeasureLayout:ky}};function NV(e,t,a){let{props:o}=e;e.animationState&&o.whileHover&&e.animationState.setActive("whileHover",a==="Start");let r="onHover"+a,n=o[r];n&&ze.postRender(()=>n(t,uu(t)))}var Ny=class extends da{mount(){let{current:t}=this.node;t&&(this.unmount=R0(t,(a,o)=>(NV(this.node,o,"Start"),r=>NV(this.node,r,"End"))))}unmount(){}};var Vy=class extends da{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=_r(bn(this.node.current,"focus",()=>this.onFocus()),bn(this.node.current,"blur",()=>this.onBlur()))}unmount(){}};function VV(e,t,a){let{props:o}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&o.whileTap&&e.animationState.setActive("whileTap",a==="Start");let r="onTap"+(a==="End"?"":a),n=o[r];n&&ze.postRender(()=>n(t,uu(t)))}var By=class extends da{mount(){let{current:t}=this.node;if(!t)return;let{globalTapTarget:a,propagate:o}=this.node.props;this.unmount=A0(t,(r,n)=>(VV(this.node,n,"Start"),(s,{success:i})=>VV(this.node,s,i?"End":"Cancel")),{useGlobalTarget:a,stopPropagation:o?.tap===!1})}unmount(){}};var sT=new WeakMap,nT=new WeakMap,vj=e=>{let t=sT.get(e.target);t&&t(e)},Cj=e=>{e.forEach(vj)};function Lj({root:e,...t}){let a=e||document;nT.has(a)||nT.set(a,{});let o=nT.get(a),r=JSON.stringify(t);return o[r]||(o[r]=new IntersectionObserver(Cj,{root:e,...t})),o[r]}function BV(e,t,a){let o=Lj(t);return sT.set(e,a),o.observe(e),()=>{sT.delete(e),o.unobserve(e)}}var Rj={some:0,all:1},Fy=class extends da{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.stopObserver?.();let{viewport:t={}}=this.node.getProps(),{root:a,margin:o,amount:r="some",once:n}=t,s={root:a?a.current:void 0,rootMargin:o,threshold:typeof r=="number"?r:Rj[r]},i=l=>{let{isIntersecting:u}=l;if(this.isInView===u||(this.isInView=u,n&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);let{onViewportEnter:c,onViewportLeave:d}=this.node.getProps(),f=u?c:d;f&&f(l)};this.stopObserver=BV(this.node.current,s,i)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;let{props:t,prevProps:a}=this.node;["amount","margin","root"].some(Tj(t,a))&&this.startObserver()}unmount(){this.stopObserver?.(),this.hasEnteredView=!1,this.isInView=!1}};function Tj({viewport:e={}},{viewport:t={}}={}){return a=>e[a]!==t[a]}var FV={inView:{Feature:Fy},tap:{Feature:By},focus:{Feature:Vy},hover:{Feature:Ny}};var _V={layout:{ProjectionNode:Tp,MeasureLayout:ky}};var zV={...hV,...FV,...kV,..._V};var iT=dV(zV,pV);var HV=T(M(),1);function cu(){!eu.current&&xp();let[e]=(0,HV.useState)(Ri.current);return e}var Ca=iT;var io=T(M(),1);var UV="@keyframes beui-text-shimmer{from{background-position:200% 0}to{background-position:-200% 0}}@media (prefers-reduced-motion: reduce){.beui-text-shimmer{animation:none !important}}",qV="beui-text-shimmer bg-[length:200%_100%] bg-clip-text text-transparent bg-[linear-gradient(110deg,var(--muted-foreground)_30%,var(--foreground)_50%,var(--muted-foreground)_70%)]";function GV(e){return{animation:`beui-text-shimmer ${e}s linear infinite`}}var fu=T(Q(),1);function _y({children:e,as:t="span",duration:a=2.5,className:o}){return(0,fu.jsxs)(fu.Fragment,{children:[(0,fu.jsx)("style",{children:UV}),(0,fu.jsx)(t,{style:GV(a),className:re("inline-block",qV,o),children:e})]})}var XV=T(Q(),1);function jV({children:e="Thinking\u2026",duration:t=1.8,className:a}){return(0,XV.jsx)(_y,{as:"span",duration:t,className:re("font-medium",a),children:e})}var Lf=[.16,1,.3,1];var YV={type:"spring",stiffness:460,damping:30,mass:.55};var du={type:"spring",stiffness:360,damping:32,mass:.6};var KV=T(Q(),1);function WV({open:e,openHeight:t="auto",className:a,style:o,transition:r,...n}){let s=cu()??!1;return(0,KV.jsx)(Ca.div,{...n,"aria-hidden":!e,inert:!e,initial:!1,animate:s?{opacity:e?1:0}:{opacity:e?1:0,clipPath:e?"inset(0 0 0% 0)":"inset(0 0 100% 0)",y:e?0:-4},transition:r??{duration:s?0:e?.22:.14,ease:Lf},className:re("overflow-hidden",a),style:{...o,height:e?t:0,pointerEvents:e?void 0:"none",transformOrigin:"top"}})}var be=T(Q(),1);function wj({item:e}){let t=e.status??"complete";return(0,be.jsxs)("div",{className:"flex min-h-7 items-start gap-2.5 rounded-md px-1.5 py-1",children:[(0,be.jsx)("span",{"aria-hidden":"true",className:"mt-0.5 grid size-4 shrink-0 place-items-center text-muted-foreground/70",children:t==="complete"?(0,be.jsx)(Jn,{className:"size-4",strokeWidth:1.8}):t==="active"?(0,be.jsxs)("span",{className:"relative grid size-3 place-items-center",children:[(0,be.jsx)(Ca.span,{className:"absolute inset-0 rounded-full bg-foreground/10",animate:{opacity:[.35,.8,.35]},transition:{duration:1.5,repeat:Number.POSITIVE_INFINITY}}),(0,be.jsx)("span",{className:"size-1.5 rounded-full bg-foreground/60"})]}):(0,be.jsx)(wm,{className:"size-3",strokeWidth:1.5})}),(0,be.jsx)("span",{className:re("min-w-0 flex-1 leading-5",t==="pending"?"text-muted-foreground/55":"text-foreground/90"),children:e.label}),e.meta?(0,be.jsx)("span",{className:"shrink-0 leading-5 text-muted-foreground/55",children:e.meta}):null]})}function Ej({item:e}){return(0,be.jsx)("div",{className:"rounded-md px-1.5 py-1 leading-5 text-muted-foreground",children:e.content})}function Aj({result:e}){let t=(0,be.jsxs)(be.Fragment,{children:[(0,be.jsx)("span",{"aria-hidden":"true",className:"grid size-5 shrink-0 place-items-center text-muted-foreground",children:e.icon??(0,be.jsx)(ri,{className:"size-3",strokeWidth:2})}),(0,be.jsx)("span",{className:"min-w-0 truncate font-medium text-foreground/90",children:e.title}),e.domain?(0,be.jsx)("span",{className:"min-w-0 truncate text-muted-foreground/55",children:e.domain}):null]}),a=re("flex min-h-7 items-center gap-2 rounded-md px-1.5 py-1 text-left outline-none transition-colors",e.url&&"focus-visible:ring-2 focus-visible:ring-ring");return e.url?(0,be.jsx)("a",{href:e.url,className:a,children:t}):(0,be.jsx)("div",{className:a,children:t})}function Dj({item:e}){let t=cu()??!1,a=t?{opacity:1}:{opacity:0,y:6},o={opacity:1,y:0},r=t?{opacity:0}:{opacity:0,y:-3},n=t?{duration:0}:{opacity:{duration:.18,ease:Lf},y:du,layout:du};return(0,be.jsxs)("div",{className:"space-y-0.5",children:[(0,be.jsxs)("div",{className:"flex min-h-7 items-center gap-2.5 rounded-md px-1.5 py-1 text-muted-foreground",children:[(0,be.jsx)(Br,{"aria-hidden":"true",className:"size-4 shrink-0",strokeWidth:1.7}),(0,be.jsx)("span",{className:"min-w-0 truncate",children:e.query})]}),e.results?.length?(0,be.jsx)("div",{className:"space-y-0.5 pl-4",children:(0,be.jsx)(wi,{initial:!0,mode:"popLayout",children:e.results.map(s=>(0,be.jsx)(Ca.div,{layout:"position",initial:a,animate:o,exit:r,transition:n,children:(0,be.jsx)(Aj,{result:s})},s.id))})}):null,(0,be.jsx)(wi,{initial:!0,children:e.moreCount?(0,be.jsxs)(Ca.div,{initial:a,animate:o,exit:r,transition:n,className:"px-1.5 py-1 pl-8 text-muted-foreground/55",children:["+",e.moreCount," more"]},"more-results"):null})]})}function Mj({action:e}){return e==="read"?(0,be.jsx)(Mm,{className:"size-4"}):e==="edit"||e==="write"?(0,be.jsx)(si,{className:"size-4"}):e==="run"?(0,be.jsx)(Fr,{className:"size-4"}):(0,be.jsx)(li,{className:"size-4"})}function Pj({item:e}){let t=e.action.charAt(0).toUpperCase()+e.action.slice(1);return(0,be.jsxs)("div",{className:"flex min-h-8 min-w-0 items-center gap-2.5 rounded-md px-1.5 py-0.5 leading-5",children:[(0,be.jsx)("span",{"aria-hidden":"true",className:"grid size-4 shrink-0 place-items-center text-muted-foreground/70",children:(0,be.jsx)(Mj,{action:e.action})}),(0,be.jsx)("span",{className:"shrink-0 font-medium text-foreground/90",children:t}),(0,be.jsx)("span",{className:"min-w-0 flex-1 truncate rounded-lg bg-muted/80 px-2.5 py-1 font-mono text-xs text-muted-foreground/70",children:e.target}),typeof e.additions=="number"||typeof e.deletions=="number"?(0,be.jsxs)("span",{className:"flex shrink-0 items-center gap-2 font-mono tabular-nums",children:[typeof e.additions=="number"?(0,be.jsxs)("span",{className:"text-emerald-500",children:["+",e.additions]}):null,typeof e.deletions=="number"?(0,be.jsxs)("span",{className:"text-rose-500",children:["\u2212",e.deletions]}):null]}):null]})}function Oj({kind:e}){return e==="thinking"?(0,be.jsx)(ii,{className:"size-4"}):e==="message"?(0,be.jsx)(Pl,{className:"size-4"}):e==="write"?(0,be.jsx)(si,{className:"size-4"}):e==="run"?(0,be.jsx)(Fr,{className:"size-4"}):e==="read"?(0,be.jsx)(Nm,{className:"size-4"}):(0,be.jsx)(li,{className:"size-4"})}function kj({item:e}){return(0,be.jsxs)("div",{className:"grid min-h-8 grid-cols-[1rem_auto_minmax(0,1fr)] items-center gap-2.5 rounded-md px-1.5 py-0.5",children:[(0,be.jsx)("span",{"aria-hidden":"true",className:"grid size-4 place-items-center text-muted-foreground/70",children:e.icon??(0,be.jsx)(Oj,{kind:e.kind})}),(0,be.jsx)("span",{className:"font-medium text-foreground/90",children:e.label}),e.detail?(0,be.jsx)("span",{className:"min-w-0 truncate rounded-lg bg-muted/80 px-2.5 py-1 font-mono text-xs text-muted-foreground/70",children:e.detail}):(0,be.jsx)("span",{})]})}function ZV({item:e}){return e.type==="text"?(0,be.jsx)(Ej,{item:e}):e.type==="search"?(0,be.jsx)(Dj,{item:e}):e.type==="tool"?(0,be.jsx)(Pj,{item:e}):e.type==="trace"?(0,be.jsx)(kj,{item:e}):(0,be.jsx)(wj,{item:e})}var ma=T(Q(),1);function Nj(e){let t=Math.max(0,Math.round(e));if(t<60)return`${t}s`;let a=Math.floor(t/60),o=t%60;return o===0?`${a}m`:`${a}m ${o}s`}function Vj({open:e,defaultOpen:t,onOpenChange:a}){let[o,r]=(0,io.useState)(t),n=e!==void 0,s=e??o,i=(0,io.useCallback)(l=>{n||r(l),a?.(l)},[n,a]);return[s,i]}function Bj(e){let t=e[0]?.type;return t&&e.every(a=>a.type===t)?t:"mixed"}function Fj(e){return e==="search"?"Searching the web\u2026":e==="tool"?"Running tools\u2026":e==="trace"?"Working through the run\u2026":e==="mixed"?"Working through it\u2026":"Thinking\u2026"}function _j(e,t,a){if(e==="step"||e==="text")return(0,ma.jsxs)(ma.Fragment,{children:["Thought for ",(0,ma.jsx)("span",{className:"tabular-nums",children:Nj(a)})]});if(e==="search")return"Searched the web";if(e==="tool")return`Ran ${t.length} ${t.length===1?"tool":"tools"}`;if(e==="trace"){let o=t.filter(n=>n.type==="trace"&&(n.kind==="thinking"||n.kind==="message")).length,r=t.length-o;return`${r} ${r===1?"tool call":"tool calls"}, ${o} ${o===1?"message":"messages"}`}return`Completed ${t.length} ${t.length===1?"step":"steps"}`}function QV({items:e,contentType:t,status:a="working",duration:o=0,open:r,defaultOpen:n=!1,onOpenChange:s,collapseOnComplete:i=!0,activeLabel:l,summary:u,renderWorkingStatus:c,renderCompletedStatus:d,maxHeight:f=208,className:m,contentClassName:p}){let y=cu()??!1,b=(0,io.useId)(),g=`${b}-trigger`,h=`${b}-content`,x=(0,io.useRef)(null),S=(0,io.useRef)(null),v=(0,io.useRef)(a),[R,L]=(0,io.useState)(0),[C,E]=Vj({open:r,defaultOpen:n,onOpenChange:s}),I=a==="working",A=I||C,N=e.length?Bj(e):t??"mixed",D=Math.min(R,Math.max(0,f)),F=I?Math.max(0,f):D,k=R>f,z=I?Math.min(0,F-R):0;(0,io.useLayoutEffect)(()=>{let _=x.current;if(!_)return;let U=()=>L(_.offsetHeight);if(U(),typeof ResizeObserver>"u")return;let X=new ResizeObserver(U);return X.observe(_),()=>X.disconnect()},[]),(0,io.useEffect)(()=>{v.current==="working"&&a==="complete"&&E(!i),v.current=a},[i,E,a]);let q=()=>{let _=!C;E(_),_&&requestAnimationFrame(()=>S.current?.scrollTo({top:0}))},O=l??Fj(N),V=u??_j(N,e,o),w=k?I?"linear-gradient(to bottom, transparent, black 12px)":"linear-gradient(to bottom, transparent, black 12px, black calc(100% - 12px), transparent)":void 0;return(0,ma.jsxs)("div",{"data-state":I?"working":A?"open":"closed","data-content":N,"aria-busy":I,className:re("w-full text-sm",m),children:[I?(0,ma.jsx)("div",{id:g,role:"status",className:"flex h-7 min-w-0 items-center text-muted-foreground",children:c?c({label:O,duration:o}):(0,ma.jsx)(jV,{children:O})}):(0,ma.jsxs)("button",{id:g,type:"button","aria-expanded":A,"aria-controls":h,onClick:q,className:"group flex h-7 min-w-0 items-center gap-1.5 rounded-md text-left font-medium text-muted-foreground outline-none transition-colors hover:text-foreground focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background",children:[(0,ma.jsx)("span",{className:"truncate",children:d?d({summary:V,duration:o}):V}),(0,ma.jsx)(Ca.span,{"aria-hidden":"true",animate:{rotate:A?180:0},transition:y?{duration:0}:YV,className:"inline-flex shrink-0 text-muted-foreground/70 group-hover:text-foreground",children:(0,ma.jsx)(ti,{className:"size-3.5"})})]}),(0,ma.jsx)(WV,{id:h,role:"region","aria-labelledby":g,open:A,openHeight:F,children:(0,ma.jsx)("div",{ref:S,className:re("scrollbar-hide pr-1",k&&A&&!I?"overflow-y-auto":"overflow-y-hidden"),style:{height:F,maskImage:w,WebkitMaskImage:w},children:(0,ma.jsx)(Ca.div,{ref:x,role:"list",initial:!1,animate:{y:z},transition:y?{duration:0}:du,className:re("space-y-0.5 py-2",p),children:(0,ma.jsx)(wi,{mode:"popLayout",children:e.map(_=>(0,ma.jsx)(Ca.div,{layout:"position",role:"listitem",initial:y?{opacity:1}:{opacity:0,y:6},animate:{opacity:1,y:0},exit:y?{opacity:0}:{opacity:0,y:-3},transition:y?{duration:0}:{opacity:{duration:.18,ease:Lf},y:du,layout:du},children:(0,ma.jsx)(ZV,{item:_})},_.id))})})})})]})}var zy=T(M(),1);function Hy(){let e=(0,zy.useRef)(null);return(0,zy.useEffect)(()=>{let t=e.current;if(!t)return;let a=()=>{t.dataset.fadeTop=String(t.scrollTop>2),t.dataset.fadeBottom=String(t.scrollTop+t.clientHeight<t.scrollHeight-2)};a(),t.addEventListener("scroll",a,{passive:!0});let o=new ResizeObserver(a);return o.observe(t),t.firstElementChild&&o.observe(t.firstElementChild),()=>{t.removeEventListener("scroll",a),o.disconnect()}},[]),e}var JV=T(Q(),1);function lT({className:e,children:t}){let a=Hy();return(0,JV.jsx)("div",{ref:a,className:re("scroll-fade overflow-auto",e),children:t})}var nB=T(M(),1);var Tf=T(M(),1);function Uy(){return typeof window<"u"}function Wt(e){return qy(e)?(e.nodeName||"").toLowerCase():"#document"}function He(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ln(e){var t;return(t=(qy(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function qy(e){return Uy()?e instanceof Node||e instanceof He(e).Node:!1}function we(e){return Uy()?e instanceof Element||e instanceof He(e).Element:!1}function Ue(e){return Uy()?e instanceof HTMLElement||e instanceof He(e).HTMLElement:!1}function Cn(e){return!Uy()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof He(e).ShadowRoot}function pu(e){let{overflow:t,overflowX:a,overflowY:o,display:r}=pa(e);return/auto|scroll|overlay|hidden|clip/.test(t+o+a)&&r!=="inline"&&r!=="contents"}function $V(e){return/^(table|td|th)$/.test(Wt(e))}function Ap(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}var zj=/transform|translate|scale|rotate|perspective|filter/,Hj=/paint|layout|strict|content/,mu=e=>!!e&&e!=="none",uT;function Gy(e){let t=we(e)?pa(e):e;return mu(t.transform)||mu(t.translate)||mu(t.scale)||mu(t.rotate)||mu(t.perspective)||!jy()&&(mu(t.backdropFilter)||mu(t.filter))||zj.test(t.willChange||"")||Hj.test(t.contain||"")}function eB(e){let t=Zo(e);for(;Ue(t)&&!Sr(t);){if(Gy(t))return t;if(Ap(t))return null;t=Zo(t)}return null}function jy(){return uT==null&&(uT=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),uT}function Sr(e){return/^(html|body|#document)$/.test(Wt(e))}function pa(e){return He(e).getComputedStyle(e)}function Dp(e){return we(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Zo(e){if(Wt(e)==="html")return e;let t=e.assignedSlot||e.parentNode||Cn(e)&&e.host||Ln(e);return Cn(t)?t.host:t}function tB(e){let t=Zo(e);return Sr(t)?(e.ownerDocument||e).body:Ue(t)&&pu(t)?t:tB(t)}function Mi(e,t,a){var o;t===void 0&&(t=[]),a===void 0&&(a=!0);let r=tB(e),n=r===((o=e.ownerDocument)==null?void 0:o.body),s=He(r);if(n){let i=Xy(s);return t.concat(s,s.visualViewport||[],pu(r)?r:[],i&&a?Mi(i):[])}else return t.concat(r,Mi(r,[],a))}function Xy(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}var Uj=T(M(),1),Mp={...Uj};var cT=Mp.useInsertionEffect,qj=cT&&cT!==Mp.useLayoutEffect?cT:e=>e();function W(e){let t=at(Gj).current;return t.next=e,qj(t.effect),t.trampoline}function Gj(){let e={next:void 0,callback:jj,trampoline:(...t)=>e.callback?.(...t),effect:()=>{e.callback=e.next}};return e}function jj(){}var aB=T(M(),1),Xj=()=>{},G=typeof document<"u"?aB.useLayoutEffect:Xj;var Yy=T(M(),1),fT=Yy.createContext(void 0);function Rf(e=!1){let t=Yy.useContext(fT);if(t===void 0&&!e)throw new Error(Me(16));return t}var oB=T(M(),1);function rB(e){let{focusableWhenDisabled:t,disabled:a,composite:o=!1,tabIndex:r=0,isNativeButton:n}=e,s=o&&t!==!1,i=o&&t===!1;return{props:oB.useMemo(()=>{let u={onKeyDown(c){a&&t&&c.key!=="Tab"&&c.preventDefault()}};return o||(u.tabIndex=r,!n&&a&&(u.tabIndex=t?r:-1)),(n&&(t||s)||!n&&a)&&(u["aria-disabled"]=a),n&&(!t||i)&&(u.disabled=a),u},[o,a,t,s,i,n,r])}}function ve(e){return e?.ownerDocument||document}function Wy(e,t,{detail:a=0}={}){e.dispatchEvent(new(He(e)).PointerEvent("click",{bubbles:!0,cancelable:!0,composed:!0,detail:a,shiftKey:t.shiftKey,ctrlKey:t.ctrlKey,altKey:t.altKey,metaKey:t.metaKey}))}function Qo(e={}){let{disabled:t=!1,focusableWhenDisabled:a,tabIndex:o=0,native:r=!0,composite:n}=e,s=Tf.useRef(null),i=Rf(!0),l=n??i!==void 0,{props:u}=rB({focusableWhenDisabled:a,disabled:t,composite:l,tabIndex:o,isNativeButton:r}),c=Tf.useCallback(()=>{let m=s.current;dT(m)&&l&&t&&u.disabled===void 0&&m.disabled&&(m.disabled=!1)},[t,u.disabled,l]);G(c,[c]);let d=Tf.useCallback((m={})=>{let{onClick:p,onMouseDown:y,onKeyUp:b,onKeyDown:g,onPointerDown:h,...x}=m;return ja({onClick(S){if(t){S.preventDefault();return}p?.(S)},onMouseDown(S){t||y?.(S)},onKeyDown(S){if(t||(Hm(S),g?.(S),S.baseUIHandlerPrevented))return;let v=S.target===S.currentTarget,R=S.currentTarget,L=dT(R),C=!r&&Yj(R),E=v&&(r?L:!C),I=S.key==="Enter",A=S.key===" ",N=R.getAttribute("role"),D=N?.startsWith("menuitem")||N==="option"||N==="gridcell";if(v&&l&&A){if(S.defaultPrevented&&D)return;S.preventDefault(),(!r||L)&&(S.preventBaseUIHandler(),Wy(R,S));return}if(!E||r||!A&&!I){v&&C&&A&&S.preventDefault();return}S.defaultPrevented||(S.preventDefault(),I&&(S.preventBaseUIHandler(),Wy(R,S)))},onKeyUp(S){if(!t){if(Hm(S),b?.(S),S.target===S.currentTarget&&r&&l&&dT(S.currentTarget)&&S.key===" "){S.preventDefault();return}S.baseUIHandlerPrevented||S.target===S.currentTarget&&!r&&!l&&!S.defaultPrevented&&S.key===" "&&(S.preventBaseUIHandler(),Wy(S.currentTarget,S))}},onPointerDown(S){if(t){S.preventDefault();return}h?.(S)}},r?{type:"button"}:{role:"button"},u,x)},[t,u,l,r]),f=W(m=>{s.current=m,c()});return{getButtonProps:d,buttonRef:f}}function dT(e){return Ue(e)&&e.tagName==="BUTTON"}function Yj(e){return Ue(e)&&e.tagName==="A"&&!!e.href}var mT=nB.forwardRef(function(t,a){let{render:o,className:r,disabled:n=!1,focusableWhenDisabled:s=!1,nativeButton:i=!0,style:l,...u}=t,{getButtonProps:c,buttonRef:d}=Qo({disabled:n,focusableWhenDisabled:s,native:i});return $("button",t,{state:{disabled:n},ref:[a,d],props:[u,c]})});var sB=T(Q(),1),Wj=jc("group/button inline-flex shrink-0 items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/80",outline:"border-border bg-background hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground hover:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)] aria-expanded:bg-secondary aria-expanded:text-secondary-foreground",ghost:"hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50",destructive:"bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",xs:"h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3",sm:"h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5",lg:"h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",icon:"size-8","icon-xs":"size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3","icon-sm":"size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg","icon-lg":"size-9"}},defaultVariants:{variant:"default",size:"default"}});function Do({className:e,variant:t="default",size:a="default",...o}){return(0,sB.jsx)(mT,{"data-slot":"button",className:re(Wj({variant:t,size:a,className:e})),...o})}var iB=T(Q(),1);function us({className:e,...t}){return(0,iB.jsx)("div",{"data-slot":"skeleton",className:re("animate-pulse rounded-md bg-muted",e),...t})}var Rn=T(M(),1);function Pi(e,t,a){let[o,r]=(0,Rn.useState)(),[n,s]=(0,Rn.useState)(!1),[i,l]=(0,Rn.useState)(0),u=(0,Rn.useRef)(e);u.current=e;let c=(0,Rn.useCallback)(async()=>{if(!document.hidden)try{r(await u.current()),s(!1),l(d=>d+1)}catch{s(!0)}},[]);return(0,Rn.useEffect)(()=>{c();let d=setInterval(c,t);return()=>clearInterval(d)},[t,c,...a]),{data:o,error:n,tick:i,reload:c}}var lo=T(Q(),1),Oi="size-4";function Kj(e){let t=(e.name??"").toLowerCase();return e.kind==="say"?{kind:"message",label:"Said",icon:(0,lo.jsx)(Pl,{className:Oi})}:e.kind==="shell"?{kind:"run",label:"Ran command",icon:(0,lo.jsx)(Fr,{className:Oi})}:e.kind==="edit"?{kind:"write",label:"Edited",icon:(0,lo.jsx)(si,{className:Oi})}:/^(read|cat|view|open)$/.test(t)?{kind:"read",label:"Read",icon:(0,lo.jsx)(Dm,{className:Oi})}:/grep|search|rg/.test(t)&&!/web/.test(t)?{kind:"tool",label:"Searched",icon:(0,lo.jsx)(Br,{className:Oi})}:/glob|list|ls|tree|find/.test(t)?{kind:"tool",label:"Listed files",icon:(0,lo.jsx)(Pm,{className:Oi})}:/web|fetch/.test(t)?{kind:"tool",label:"Fetched",icon:(0,lo.jsx)(Om,{className:Oi})}:{kind:"tool",label:e.name??"Tool",icon:(0,lo.jsx)(li,{className:Oi})}}function lB(e){return e.map((t,a)=>{let o=Kj(t);return{id:`step-${a}`,type:"trace",kind:o.kind,icon:o.icon,label:(0,lo.jsxs)(lo.Fragment,{children:[o.label,t.ok===!1&&(0,lo.jsx)("span",{className:"ml-1.5 text-xs font-normal text-destructive",children:"failed"}),t.t!=null&&(0,lo.jsxs)("span",{className:"ml-1.5 text-xs font-normal tabular-nums text-muted-foreground/60",children:["+",es(t.t)]})]}),detail:t.text.length>200?`${t.text.slice(0,199)}\u2026`:t.text}})}var Pe=T(Q(),1);function Pp({title:e,children:t}){return(0,Pe.jsxs)("section",{className:"space-y-2",children:[(0,Pe.jsx)("h4",{className:"text-[11px] font-semibold uppercase tracking-widest text-muted-foreground/80",children:e}),t]})}var pT=({children:e,mono:t})=>(0,Pe.jsx)(lT,{className:re("max-h-60 whitespace-pre-wrap break-words rounded-lg border bg-muted/40 p-3 text-[13px] leading-relaxed",t&&"font-mono text-xs"),children:e});function Zj({patch:e}){return(0,Pe.jsx)(lT,{className:"max-h-72 rounded-lg border bg-muted/40",children:(0,Pe.jsx)("pre",{className:"min-w-max p-3 font-mono text-xs leading-5",children:e.split(`
|
|
18
|
+
`).map((t,a)=>(0,Pe.jsx)("div",{className:re(t.startsWith("+")&&!t.startsWith("+++")&&"bg-success/10 text-success",t.startsWith("-")&&!t.startsWith("---")&&"bg-destructive/10 text-destructive",t.startsWith("@@")&&"text-info"),children:t||" "},a))})})}var uB={worker:"Worker",model:"Model",mode:"Mode",started:"Started",time:"Duration",steps:"Steps",toolCalls:"Tool calls",tokens:"Tokens",returnedTokens:"Returned to agent",cost:"Worker cost",saved:"Saved",group:"Group",directory:"Directory"};function Qj(e,t){return e==="started"?new Date(t).toLocaleString():e==="tokens"||e==="returnedTokens"?ts(Number(t)):e==="cost"?Number(t)?`$${Number(t).toFixed(3)}`:"free":e==="saved"?`~${pr(Number(t))}`:String(t)}function Op({children:e,tone:t}){return(0,Pe.jsx)("p",{className:re("text-[13px]",t==="bad"?"text-destructive":t==="ok"?"text-muted-foreground":"text-warning"),children:e})}function Jj({d:e}){let[t,a]=(0,Ky.useState)(!1),[o,r]=(0,Ky.useState)(!1),[n,s]=(0,Ky.useState)(!1),i=e.state==="running"||e.state==="queued";return(0,Pe.jsxs)("div",{className:"space-y-5",children:[!/^Review of /.test(e.task)&&(0,Pe.jsx)(Pp,{title:"Task",children:(0,Pe.jsx)(pT,{children:e.task})}),(0,Pe.jsx)(Pp,{title:`What it did${e.steps.length?` \xB7 ${e.steps.length}`:""}`,children:e.steps.length?(0,Pe.jsx)(QV,{items:lB(e.steps),status:i?"working":"complete",defaultOpen:!0,collapseOnComplete:!1,maxHeight:260,activeLabel:"Working\u2026"}):(0,Pe.jsx)("p",{className:"text-sm text-muted-foreground",children:i?"Waiting for its first step\u2026":"No activity was recorded for this run."})}),e.answer&&(0,Pe.jsx)(Pp,{title:"Result",children:(0,Pe.jsx)(pT,{children:e.answer})}),e.changes.length>0&&(0,Pe.jsxs)(Pp,{title:`Changes \xB7 ${e.changes.length} file${e.changes.length===1?"":"s"}`,children:[(0,Pe.jsx)("div",{className:"space-y-0.5 font-mono text-xs",children:e.changes.map(l=>(0,Pe.jsxs)("div",{className:"flex gap-2",children:[(0,Pe.jsx)("b",{className:re("w-3",l.status==="A"&&"text-success",l.status==="M"&&"text-warning",l.status==="D"&&"text-destructive"),children:l.status}),(0,Pe.jsx)("span",{className:"break-all",children:l.path})]},l.path))}),e.patch&&(0,Pe.jsxs)(Pe.Fragment,{children:[(0,Pe.jsx)(Do,{variant:"ghost",size:"sm",onClick:()=>a(l=>!l),children:t?"Hide the diff":"Show the diff"}),t&&(0,Pe.jsx)(Zj,{patch:e.patch})]})]}),(0,Pe.jsxs)(Pp,{title:"Details",children:[(0,Pe.jsx)("dl",{className:"grid grid-cols-2 gap-x-6 gap-y-3 sm:grid-cols-3",children:Object.keys(uB).map(l=>{let u=e.info[l];return u==null||u===""||u===0&&l!=="cost"?null:(0,Pe.jsxs)("div",{className:"min-w-0",children:[(0,Pe.jsx)("dt",{className:"text-[11px] uppercase tracking-wide text-muted-foreground/80",children:uB[l]}),(0,Pe.jsx)("dd",{className:"break-words text-[13px]",children:Qj(l,u)})]},l)})}),e.refs&&(0,Pe.jsxs)(Op,{tone:e.refs.valid<e.refs.total?void 0:"ok",children:["References verified: ",e.refs.valid," of ",e.refs.total,e.refs.invalid.length?` \xB7 not found: ${e.refs.invalid.join(", ")}`:""]}),e.attempts.map((l,u)=>(0,Pe.jsxs)(Op,{children:["Fell back from ",l.target,": ",l.error]},u)),e.warnings.map((l,u)=>(0,Pe.jsx)(Op,{children:l},u)),e.verify&&(0,Pe.jsxs)(Op,{tone:e.verify.ok?"ok":"bad",children:["Verify ",e.verify.ok?"passed":"failed",": ",e.verify.command]}),e.error&&(0,Pe.jsx)(Op,{tone:"bad",children:e.error}),(0,Pe.jsxs)("div",{className:"flex gap-1 pt-1",children:[(0,Pe.jsxs)(Do,{variant:"ghost",size:"sm",onClick:()=>{navigator.clipboard?.writeText(e.id),s(!0),setTimeout(()=>s(!1),1400)},children:[n?(0,Pe.jsx)(Jn,{}):(0,Pe.jsx)(Am,{}),n?"Copied":e.id]}),(0,Pe.jsx)(Do,{variant:"ghost",size:"sm",onClick:()=>r(l=>!l),children:o?"Hide full report":"Full report"})]}),o&&(0,Pe.jsx)(pT,{mono:!0,children:e.report})]})]})}function Zy({id:e,live:t}){let{data:a,error:o}=Pi(()=>dr.run(e),t?3e3:6e5,[e,t]);return a?(0,Pe.jsx)(Jj,{d:a}):o?(0,Pe.jsx)("p",{className:"text-sm text-destructive",children:"Could not load this run."}):(0,Pe.jsxs)("div",{className:"space-y-3",children:[(0,Pe.jsx)(us,{className:"h-16"}),(0,Pe.jsx)(us,{className:"h-24"})]})}var An={};Aa(An,{Backdrop:()=>dB,Close:()=>pB,Description:()=>yB,Handle:()=>ih,Popup:()=>gF,Portal:()=>bF,Root:()=>PF,Title:()=>VF,Trigger:()=>HF,Viewport:()=>kF,createHandle:()=>UF});var fB=T(M(),1);var Qy=T(M(),1),hT=Qy.createContext(void 0);function La(e){let t=Qy.useContext(hT);if(!e&&t===void 0)throw new Error(Me(27));return t}var gu={};Aa(gu,{endingStyle:()=>kp,startingStyle:()=>hu});var hu="data-starting-style",kp="data-ending-style";var $j={[hu]:""},eX={[kp]:""},Ya={transitionStatus(e){return e==="starting"?$j:e==="ending"?eX:null}};var xu={};Aa(xu,{align:()=>rX,anchorHidden:()=>yT,closed:()=>xT,endingStyle:()=>aX,open:()=>gT,side:()=>oX,startingStyle:()=>tX});var gT="data-open",xT="data-closed",tX=hu,aX=kp,yT="data-anchor-hidden",oX="data-side",rX="data-align";var yu={};Aa(yu,{popupOpen:()=>Jy,pressed:()=>ST});var Jy="data-popup-open",ST="data-pressed";var nX={[Jy]:""},sX={[Jy]:"",[ST]:""},iX={[gT]:""},lX={[xT]:""},uX={[yT]:""},If={open(e){return e?nX:null}},cB={open(e){return e?sX:null}},Hr={open(e){return e?iX:lX},anchorHidden(e){return e?uX:null}},wf={...Hr,...Ya};var dB=fB.forwardRef(function(t,a){let{render:o,className:r,style:n,forceRender:s=!1,...i}=t,l=La(),u=l.useState("open"),c=l.useState("nested"),d=l.useState("mounted"),f=l.useState("transitionStatus");return $("div",t,{state:{open:u,transitionStatus:f},ref:[l.context.backdropRef,a],stateAttributesMapping:wf,props:[{role:"presentation",hidden:!d,style:{userSelect:"none",WebkitUserSelect:"none"}},i],enabled:s||!c})});var mB=T(M(),1);var ne={};Aa(ne,{cancelOpen:()=>BX,chipRemovePress:()=>SX,clearPress:()=>yX,closePress:()=>gX,closeWatcher:()=>DX,decrementPress:()=>CX,disabled:()=>_X,drag:()=>kX,escapeKey:()=>AX,focusOut:()=>EX,imperativeAction:()=>UX,incrementPress:()=>vX,initial:()=>HX,inputBlur:()=>TX,inputChange:()=>LX,inputClear:()=>RX,inputPaste:()=>IX,inputPress:()=>wX,itemPress:()=>hX,keyboard:()=>PX,linkPress:()=>xX,listNavigation:()=>MX,missing:()=>zX,none:()=>cX,outsidePress:()=>pX,pointer:()=>OX,scrub:()=>VX,siblingOpen:()=>FX,swipe:()=>qX,trackPress:()=>bX,triggerFocus:()=>mX,triggerHover:()=>dX,triggerPress:()=>fX,wheel:()=>NX,windowResize:()=>GX});var cX="none",fX="trigger-press",dX="trigger-hover",mX="trigger-focus",pX="outside-press",hX="item-press",gX="close-press",xX="link-press",yX="clear-press",SX="chip-remove-press",bX="track-press",vX="increment-press",CX="decrement-press",LX="input-change",RX="input-clear",TX="input-blur",IX="input-paste",wX="input-press",EX="focus-out",AX="escape-key",DX="close-watcher",MX="list-navigation",PX="keyboard",OX="pointer",kX="drag",NX="wheel",VX="scrub",BX="cancel-open",FX="sibling-open",_X="disabled",zX="missing",HX="initial",UX="imperative-action",qX="swipe",GX="window-resize";function he(e,t,a,o){let r=!1,n=!1,s=o??Ke;return{reason:e,event:t??new Event("base-ui"),cancel(){r=!0},allowPropagation(){n=!0},get isCanceled(){return r},get isPropagationAllowed(){return n},trigger:a,...s}}var pB=mB.forwardRef(function(t,a){let{render:o,className:r,style:n,disabled:s=!1,nativeButton:i=!0,...l}=t,u=La(),c=u.useState("open"),{getButtonProps:d,buttonRef:f}=Qo({disabled:s,native:i}),m={disabled:s};function p(y){c&&u.setOpen(!1,he(ne.closePress,y.nativeEvent))}return $("button",t,{state:m,ref:[a,f],props:[{onClick:p},l,d]})});var xB=T(M(),1);var $y=T(M(),1);var hB=0;function jX(e,t="mui"){let[a,o]=$y.useState(e),r=e||a;return $y.useEffect(()=>{a==null&&(hB+=1,o(`${t}-${hB}`))},[a,t]),r}var gB=Mp.useId;function ki(e,t){if(gB!==void 0){let a=gB();return e??(t?`${t}-${a}`:a)}return jX(e,t)}function It(e){return ki(e,"base-ui")}var yB=xB.forwardRef(function(t,a){let{render:o,className:r,style:n,id:s,...i}=t,l=La(),u=It(s);return l.useSyncedValueWithCleanup("descriptionElementId",u),$("p",t,{ref:a,props:[{id:u},i]})});var pF=T(M(),1);var uo=T(M(),1);var SB=T(M(),1);function Ef(e){SB.useEffect(e,Io)}var Np=0,Wa=class e{static create(){return new e}currentId=Np;start(t,a){this.clear(),this.currentId=setTimeout(()=>{this.currentId=Np,a()},t)}isStarted(){return this.currentId!==Np}clear=()=>{this.currentId!==Np&&(clearTimeout(this.currentId),this.currentId=Np)};disposeEffect=()=>this.clear};function Qe(){let e=at(Wa.create).current;return Ef(e.disposeEffect),e}var ot={};Aa(ot,{engine:()=>RT,env:()=>IT,mediaQuery:()=>wT,os:()=>CT,screenReader:()=>TT});var CT={};Aa(CT,{android:()=>CB,apple:()=>vT,ios:()=>bT,linux:()=>ZX,mac:()=>LB,windows:()=>KX});function XX(){return typeof navigator>"u"?{userAgent:"",platform:"",maxTouchPoints:0}:{userAgent:navigator.userAgent,platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??0}}var{userAgent:YX,platform:WX,maxTouchPoints:bB}=XX(),Su=YX.toLowerCase(),bu=WX.toLowerCase();var bT=/^i(os$|p)/.test(bu)||bu==="macintel"&&bB>1,vB="android",CB=bu===vB||Su.includes(vB),LB=!bT&&bu.startsWith("mac"),KX=bu.startsWith("win"),ZX=!CB&&/^(linux|chrome os)/.test(bu),vT=LB||bT;var RT={};Aa(RT,{blink:()=>JX,gecko:()=>QX,webkit:()=>LT});var LT=typeof CSS<"u"&&!!CSS.supports?.("-webkit-backdrop-filter:none"),QX=!LT&&Su.includes("firefox"),JX=!LT&&Su.includes("chrom");var TT={};Aa(TT,{voiceOver:()=>$X});var $X=vT;var IT={};Aa(IT,{jsdom:()=>eY});var eY=/jsdom|happydom/.test(Su);var wT={};Aa(wT,{iOS:()=>tY});var tY="@supports (-webkit-touch-callout: none)";function Mo(e){e.preventDefault(),e.stopPropagation()}function RB(e){return"nativeEvent"in e}function Ni(e){return e.pointerType===""&&e.isTrusted?!0:ot.os.android&&e.pointerType?e.type==="click"&&e.buttons===1:e.detail===0&&!e.pointerType}function Af(e){return ot.env.jsdom?!1:!ot.os.android&&e.width===0&&e.height===0||ot.os.android&&e.width===1&&e.height===1&&e.pressure===0&&e.detail===0&&e.pointerType==="mouse"||e.width<1&&e.height<1&&e.pressure===0&&e.detail===0&&e.pointerType==="touch"}function Jo(e,t){let a=["mouse","pen"];return t||a.push("",void 0),a.includes(e)}function TB(e){let t=e.type;return t==="click"||t==="mousedown"||t==="keydown"||t==="keyup"}function _t(e){let t=e.activeElement;for(;t?.shadowRoot?.activeElement!=null;)t=t.shadowRoot.activeElement;return t}function ue(e,t){if(!e||!t)return!1;let a=t.getRootNode?.();if(e.contains(t))return!0;if(a&&Cn(a)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function $e(e){return"composedPath"in e?e.composedPath()[0]??e.target:e.target}var Vp="data-base-ui-focusable";var ET="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])",Bp="ArrowLeft",Fp="ArrowRight",AT="ArrowUp",eS="ArrowDown";var qhe=yu.popupOpen,_p="data-trigger-disabled";function Vi(e,t){if(!we(e))return!1;let a=e;if(t.hasElement(a))return!a.hasAttribute(_p);for(let[,o]of t.entries())if(ue(o,a))return!o.hasAttribute(_p);return!1}function tS(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);let a=e;return a.target!=null&&t.contains(a.target)}function wB(e){return e.matches("html,body")}function vu(e){return Ue(e)&&e.matches(ET)}function DT(e){return e?.closest(`button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${ET}`)!=null}function zp(e){return e?e.getAttribute("role")==="combobox"&&vu(e):!1}function EB(e){if(!e||ot.env.jsdom)return!0;try{return e.matches(":focus-visible")}catch{return!0}}function Cu(e){return e?e.hasAttribute(Vp)?e:e.querySelector(`[${Vp}]`)||e:null}function aY(e,t){return t!=null&&!Jo(t)?0:typeof e=="function"?e():e}function Ur(e,t,a){let o=aY(e,a);return typeof o=="number"?o:o?.[t]}function MT(e){return typeof e=="function"?e():e}function aS(e,t){return t||e==="click"||e==="mousedown"}function AB(e){return e?.includes("mouse")&&e!=="mousedown"}var DB=T(Q(),1),MB=uo.createContext({hasProvider:!1,timeoutMs:0,delayRef:{current:0},initialDelayRef:{current:0},timeout:new Wa,currentIdRef:{current:null},currentContextRef:{current:null}});function oY(e,t){e.current=t.current}function PT(e){let{children:t,delay:a,timeoutMs:o=0}=e,r=uo.useRef(a),n=uo.useRef(a),s=uo.useRef(null),i=uo.useRef(null),l=Qe();return G(()=>{if(n.current=a,!s.current){r.current=a;return}r.current={open:Ur(r.current,"open"),close:Ur(a,"close")}},[a,s,r,n]),(0,DB.jsx)(MB.Provider,{value:uo.useMemo(()=>({hasProvider:!0,delayRef:r,initialDelayRef:n,currentIdRef:s,timeoutMs:o,currentContextRef:i,timeout:l}),[o,l]),children:t})}function OT(e,t={open:!1}){let{open:a}=t,o="rootStore"in e?e.rootStore:e,r=o.useState("floatingId"),n=uo.useContext(MB),{currentIdRef:s,delayRef:i,timeoutMs:l,initialDelayRef:u,currentContextRef:c,hasProvider:d,timeout:f}=n,[m,p]=uo.useState(!1),y=uo.useRef(a);return G(()=>{y.current=a},[a]),G(()=>{function b(){c.current?.setIsInstantPhase(!1),s.current=null,c.current=null,i.current=u.current,f.clear()}if(s.current&&!a&&s.current===r){if(p(!1),l){let g=r;return f.start(l,()=>{o.select("open")||s.current&&s.current!==g||b()}),()=>{(y.current||s.current!==g)&&f.clear()}}b()}},[a,r,s,i,l,u,c,f,o]),G(()=>{if(!a)return;let b=c.current,g=s.current;f.clear(),c.current={onOpenChange:o.setOpen,setIsInstantPhase:p},s.current=r,i.current={open:0,close:Ur(u.current,"close")},g!==null&&g!==r?(p(!0),b?.setIsInstantPhase(!0),b?.onOpenChange(!1,he(ne.none))):(p(!1),b?.setIsInstantPhase(!1))},[a,r,o,s,i,u,c,f]),G(()=>()=>{if(s.current===r){if(c.current=null,!y.current)return;s.current=null,oY(i,u),f.clear()}},[c,s,i,r,u,f]),uo.useMemo(()=>({activeIdRef:s,hasProvider:d,delayRef:i,isInstantPhase:m}),[s,d,i,m])}var Qa=T(M(),1);function Re(e,t,a,o){return e.addEventListener(t,a,o),()=>{e.removeEventListener(t,a,o)}}function Ka(...e){return()=>{for(let t=0;t<e.length;t+=1){let a=e[t];a&&a()}}}function pt(e){let t=at(rY,e).current;return t.next=e,G(t.effect),t}function rY(e){let t={current:e,next:e,effect:()=>{t.current=t.next}};return t}var oS=null,fge=globalThis.requestAnimationFrame,kT=class{callbacks=[];callbacksCount=0;nextId=1;startId=1;isScheduled=!1;tick=t=>{this.isScheduled=!1;let a=this.callbacks,o=this.callbacksCount;if(this.callbacks=[],this.callbacksCount=0,this.startId=this.nextId,o>0)for(let r=0;r<a.length;r+=1)a[r]?.(t)};request(t){let a=this.nextId;return this.nextId+=1,this.callbacks.push(t),this.callbacksCount+=1,(!this.isScheduled||!1)&&(requestAnimationFrame(this.tick),this.isScheduled=!0),a}cancel(t){let a=t-this.startId;a<0||a>=this.callbacks.length||this.callbacks[a]!==null&&(this.callbacks[a]=null,this.callbacksCount-=1)}},rS=new kT;var br=class e{static create(){return new e}static request(t){return rS.request(t)}static cancel(t){return rS.cancel(t)}currentId=oS;request(t){this.cancel(),this.currentId=rS.request(()=>{this.currentId=oS,t()})}cancel=()=>{this.currentId!==oS&&(rS.cancel(this.currentId),this.currentId=oS)};disposeEffect=()=>this.cancel};function co(){let e=at(br.create).current;return Ef(e.disposeEffect),e}var nS=T(M(),1);var PB={clipPath:"inset(50%)",overflow:"hidden",whiteSpace:"nowrap",border:0,padding:0,width:1,height:1,margin:-1},Df={...PB,position:"fixed",top:0,left:0},OB={...PB,position:"absolute"};var kB=T(Q(),1),Mf=nS.forwardRef(function(t,a){let[o,r]=nS.useState();return G(()=>{ot.screenReader.voiceOver&&ot.engine.webkit&&r("button")},[]),(0,kB.jsx)("span",{...t,ref:a,style:Df,"aria-hidden":o?void 0:!0,...{tabIndex:0,role:o},"data-base-ui-focus-guard":""})});var Bi=Math.min,qr=Math.max,Fi=Math.round,Up=Math.floor,Tn=e=>({x:e,y:e}),nY={left:"right",right:"left",bottom:"top",top:"bottom"};function iS(e,t,a){return qr(e,Bi(t,a))}function In(e,t){return typeof e=="function"?e(t):e}function Za(e){return e.split("-")[0]}function vr(e){return e.split("-")[1]}function lS(e){return e==="x"?"y":"x"}function qp(e){return e==="y"?"height":"width"}function Po(e){let t=e[0];return t==="t"||t==="b"?"y":"x"}function Gp(e){return lS(Po(e))}function BB(e,t,a){a===void 0&&(a=!1);let o=vr(e),r=Gp(e),n=qp(r),s=r==="x"?o===(a?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[n]>t.floating[n]&&(s=Hp(s)),[s,Hp(s)]}function FB(e){let t=Hp(e);return[sS(e),t,sS(t)]}function sS(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}var NB=["left","right"],VB=["right","left"],sY=["top","bottom"],iY=["bottom","top"];function lY(e,t,a){switch(e){case"top":case"bottom":return a?t?VB:NB:t?NB:VB;case"left":case"right":return t?sY:iY;default:return[]}}function _B(e,t,a,o){let r=vr(e),n=lY(Za(e),a==="start",o);return r&&(n=n.map(s=>s+"-"+r),t&&(n=n.concat(n.map(sS)))),n}function Hp(e){let t=Za(e);return nY[t]+e.slice(t.length)}function uY(e){var t,a,o,r;return{top:(t=e.top)!=null?t:0,right:(a=e.right)!=null?a:0,bottom:(o=e.bottom)!=null?o:0,left:(r=e.left)!=null?r:0}}function uS(e){return typeof e!="number"?uY(e):{top:e,right:e,bottom:e,left:e}}function cs(e){let{x:t,y:a,width:o,height:r}=e;return{width:o,height:r,top:a,left:t,right:t+o,bottom:a+r,x:t,y:a}}function _i(e,t){return t<0||t>=e.length}function Lu(e,t){return Cr(e.current,{disabledIndices:t})}function Pf(e,t){return Cr(e.current,{decrement:!0,startingIndex:e.current.length,disabledIndices:t})}function Cr(e,{startingIndex:t=-1,decrement:a=!1,disabledIndices:o,amount:r=1}={}){let n=t;do n+=a?-r:r;while(n>=0&&n<=e.length-1&&fs(e,n,o));return n}function fs(e,t,a){if(typeof a=="function"?a(t):a?.includes(t)??!1)return!0;let r=e[t];return r?!Ru(r)||r.matches(":disabled")?!0:!a&&(r.hasAttribute("disabled")||r.getAttribute("aria-disabled")==="true"):!1}function cY(e){return e.visibility==="hidden"||e.visibility==="collapse"}function Ru(e,t=e?pa(e):null){return!e||!e.isConnected||!t||cY(t)?!1:typeof e.checkVisibility=="function"?e.checkVisibility():t.display!=="none"&&t.display!=="contents"}var fY='a[href],button,input,select,textarea,summary,details,iframe,object,embed,[tabindex],[contenteditable]:not([contenteditable="false"]),audio[controls],video[controls]';function dY(e){let t=e.assignedSlot;if(t)return t;if(e.parentElement)return e.parentElement;let a=e.getRootNode();return Cn(a)?a.host:null}function VT(e){for(let t of Array.from(e.children))if(Wt(t)==="summary")return t;return null}function mY(e,t){let a=VT(t);return!!a&&(e===a||ue(a,e))}function zB(e){let t=e?Wt(e):"";return e!=null&&e.matches(fY)&&(t!=="summary"||e.parentElement!=null&&Wt(e.parentElement)==="details"&&VT(e.parentElement)===e)&&(t!=="details"||VT(e)==null)&&(t!=="input"||e.type!=="hidden")}function HB(e){if(!zB(e)||!e.isConnected||e.matches(":disabled"))return!1;for(let t=e;t;t=dY(t)){let a=t!==e,o=Wt(t)==="slot";if(t.hasAttribute("inert")||a&&Wt(t)==="details"&&!t.open&&!mY(e,t)||t.hasAttribute("hidden")||!o&&!pY(t,a))return!1}return!0}function pY(e,t){let a=pa(e);return t?a.display!=="none":Ru(e,a)}function UB(e){let t=e.tabIndex;if(t<0){let a=Wt(e);if(a==="details"||a==="audio"||a==="video"||Ue(e)&&e.isContentEditable)return 0}return t}function NT(e){if(Wt(e)!=="input")return null;let t=e;return t.type==="radio"&&t.name!==""?t:null}function hY(e,t){let a=NT(e);if(!a)return!0;let o=t.find(r=>{let n=NT(r);return n?.name===a.name&&n.form===a.form&&n.checked});return o?o===a:t.find(r=>{let n=NT(r);return n?.name===a.name&&n.form===a.form})===a}function qB(e){if(Ue(e)&&Wt(e)==="slot"){let t=e.assignedElements({flatten:!0});if(t.length>0)return t}return Ue(e)&&e.shadowRoot?Array.from(e.shadowRoot.children):Array.from(e.children)}function GB(e,t){qB(e).forEach(a=>{zB(a)&&t.push(a),GB(a,t)})}function jB(e,t,a){qB(e).forEach(o=>{Ue(o)&&o.matches(t)&&a.push(o),jB(o,t,a)})}function cS(e){return HB(e)&&UB(e)>=0}function BT(e){let t=[];return GB(e,t),t.filter(HB)}function jp(e){let t=BT(e);return t.filter(a=>UB(a)>=0&&hY(a,t))}function XB(e,t){let a=jp(e),o=a.length;if(o===0)return;let r=_t(ve(e)),n=a.indexOf(r),s=n===-1?t===1?0:o-1:n+t;return a[s]}function fS(e){return XB(ve(e).body,1)||e}function dS(e){return XB(ve(e).body,-1)||e}function Tu(e,t){let a=t||e.currentTarget,o=e.relatedTarget;return!o||!ue(a,o)}function YB(e){jp(e).forEach(a=>{a.dataset.tabindex=a.getAttribute("tabindex")||"",a.setAttribute("tabindex","-1")})}function FT(e){let t=[];jB(e,"[data-tabindex]",t),t.forEach(a=>{let o=a.dataset.tabindex;delete a.dataset.tabindex,o?a.setAttribute("tabindex",o):a.removeAttribute("tabindex")})}function Lr(e,t,a=!0){return e.filter(r=>r.parentId===t).flatMap(r=>[...!a||r.context?.open?[r]:[],...Lr(e,r.id,a)])}function _T(e,t){let a=[],o=e.find(r=>r.id===t)?.parentId;for(;o;){let r=e.find(n=>n.id===o);o=r?.parentId,r&&(a=a.concat(r))}return a}function ds(e){return`data-base-ui-${e}`}var mS=0;function Of(e,t={}){let{preventScroll:a=!1,sync:o=!1,shouldFocus:r}=t;cancelAnimationFrame(mS);function n(){r&&!r()||e?.focus({preventScroll:a})}if(o)return n(),Ve;let s=requestAnimationFrame(n);return mS=s,()=>{mS===s&&(cancelAnimationFrame(s),mS=0)}}var zT={inert:new WeakMap,"aria-hidden":new WeakMap},WB="data-base-ui-inert",UT={inert:new WeakSet,"aria-hidden":new WeakSet},Xp=new WeakMap,HT=0;function gY(e){return UT[e]}function JB(e){return e?Cn(e)?e.host:JB(e.parentNode):null}var KB=(e,t)=>t.map(a=>{if(e.contains(a))return a;let o=JB(a);return e.contains(o)?o:null}).filter(a=>a!=null),ZB=e=>{let t=new Set;return e.forEach(a=>{let o=a;for(;o&&!t.has(o);)t.add(o),o=o.parentNode}),t},QB=(e,t,a)=>{let o=[],r=n=>{!n||a.has(n)||Array.from(n.children).forEach(s=>{Wt(s)!=="script"&&(t.has(s)?r(s):o.push(s))})};return r(e),o};function xY(e,t,a,o,{mark:r=!0}){let n=null;o?n="inert":a&&(n="aria-hidden");let s=null,i=null,l=KB(t,e),u=r?QB(t,ZB(l),new Set(l)):[],c=[],d=[];if(n){let f=zT[n],m=gY(n);i=m,s=f;let p=KB(t,Array.from(t.querySelectorAll("[aria-live]"))),y=l.concat(p);QB(t,ZB(y),new Set(y)).forEach(g=>{let h=g.getAttribute(n),x=h!==null&&h!=="false",S=(f.get(g)||0)+1;f.set(g,S),c.push(g),S===1&&x&&m.add(g),x||g.setAttribute(n,n==="inert"?"":"true")})}return r&&u.forEach(f=>{let m=(Xp.get(f)||0)+1;Xp.set(f,m),d.push(f),m===1&&f.setAttribute(WB,"")}),HT+=1,()=>{s&&c.forEach(f=>{let p=(s.get(f)||0)-1;s.set(f,p),p||(!i?.has(f)&&n&&f.removeAttribute(n),i?.delete(f))}),r&&d.forEach(f=>{let m=(Xp.get(f)||0)-1;Xp.set(f,m),m||f.removeAttribute(WB)}),HT-=1,HT||(zT.inert=new WeakMap,zT["aria-hidden"]=new WeakMap,UT.inert=new WeakSet,UT["aria-hidden"]=new WeakSet,Xp=new WeakMap)}}function qT(e,t={}){let{ariaHidden:a=!1,inert:o=!1,mark:r=!0}=t,n=ve(e[0]).body;return xY(e,n,a,o,{mark:r})}var At=T(M(),1),GT=T(Zr(),1);var $B={style:{transition:"none"}},pS="data-base-ui-click-trigger",yY="data-base-ui-swipe-ignore",SY="data-swipe-ignore",Oge=`[${yY}]`,kge=`[${SY}]`,e2={fallbackAxisSide:"none"},t2={fallbackAxisSide:"end"},a2={clipPath:"inset(50%)",position:"fixed",top:0,left:0};var Iu=T(Q(),1),o2=At.createContext(null),jT=()=>At.useContext(o2),bY=ds("portal");function hS(e={}){let{ref:t,container:a,componentProps:o=Ke,elementProps:r}=e,n=ki(),i=jT()?.portalNode,[l,u]=At.useState(null),[c,d]=At.useState(null),f=W(b=>{b!==null&&d(b)}),m=At.useRef(null);G(()=>{if(a===null){m.current&&(m.current=null,d(null),u(null));return}let b=(a&&(qy(a)?a:a.current))??i??document.body;if(b==null){m.current&&(m.current=null,d(null),u(null));return}m.current!==b&&(m.current=b,d(null),u(b))},[a,i]);let p=$("div",o,{ref:[t,f],props:[{id:n,[bY]:""},r]}),y=l&&p?GT.createPortal(p,l):null;return{node:c,nodeId:At.isValidElement(p)?p.props.id:void 0,subtree:y}}var Yp=At.forwardRef(function(t,a){let{render:o,className:r,style:n,children:s,container:i,portalOwnerRole:l,...u}=t,{node:c,nodeId:d,subtree:f}=hS({container:i,ref:a,componentProps:t,elementProps:u}),m=At.useRef(null),p=At.useRef(null),y=At.useRef(null),b=At.useRef(null),[g,h]=At.useState(null),x=At.useRef(!1),S=g?.modal,v=g?.open,R=!!g&&!g.modal&&g.open&&!!c;At.useEffect(()=>{if(!c||S)return;function C(E){c&&E.relatedTarget&&Tu(E)&&(E.type==="focusin"?x.current&&(FT(c),x.current=!1):(YB(c),x.current=!0))}return Ka(Re(c,"focusin",C,!0),Re(c,"focusout",C,!0))},[c,S]),G(()=>{!c||v!==!0||!x.current||(FT(c),x.current=!1)},[v,c]);let L=At.useMemo(()=>({beforeOutsideRef:m,afterOutsideRef:p,beforeInsideRef:y,afterInsideRef:b,portalNode:c,setFocusManagerState:h}),[c]);return(0,Iu.jsxs)(At.Fragment,{children:[f,(0,Iu.jsxs)(o2.Provider,{value:L,children:[R&&c&&(0,Iu.jsx)(Mf,{"data-type":"outside",ref:m,onFocus:C=>{if(Tu(C,c))y.current?.focus();else{let E=g?g.domReference:null;dS(E)?.focus()}}}),R&&c&&(0,Iu.jsx)("span",{role:l,"aria-owns":d,style:a2}),c&>.createPortal(s,c),R&&c&&(0,Iu.jsx)(Mf,{"data-type":"outside",ref:p,onFocus:C=>{if(Tu(C,c))b.current?.focus();else{let E=g?g.domReference:null;fS(E)?.focus(),g?.closeOnFocusOut&&g?.onOpenChange(!1,he(ne.focusOut,C.nativeEvent))}}})]})]})});var wu=T(M(),1);function r2(){let e=new Map;return{emit(t,a){e.get(t)?.forEach(o=>o(a))},on(t,a){e.has(t)||e.set(t,new Set),e.get(t).add(a)},off(t,a){e.get(t)?.delete(a)}}}var vY=T(Q(),1),CY=wu.createContext(null),LY=wu.createContext(null),zi=()=>wu.useContext(CY)?.id||null,Rr=e=>{let t=wu.useContext(LY);return e??t};function Gr(e){return e==null?e:"current"in e?e.current:e}var Wp=T(Q(),1);function RY(e,t){let a=He($e(e));return e instanceof a.KeyboardEvent?"keyboard":e instanceof a.FocusEvent?t||"keyboard":"pointerType"in e?e.pointerType||"keyboard":"touches"in e?"touch":e instanceof a.MouseEvent?t||(e.detail===0?"keyboard":"mouse"):""}var n2=20,Hi=[];function XT(){Hi=Hi.filter(e=>e.deref()?.isConnected)}function s2(e){XT(),e&&Wt(e)!=="body"&&(Hi.push(new WeakRef(e)),Hi.length>n2&&(Hi=Hi.slice(-n2)))}function i2(){return XT(),Hi[Hi.length-1]?.deref()}function TY(e){return e?cS(e)?e:jp(e)[0]||e:null}function l2(e){if(e.hasAttribute("tabindex")&&!e.hasAttribute("data-tabindex")||!e.getAttribute("role")?.includes("dialog"))return;let a=BT(e).filter(r=>{let n=r.getAttribute("data-tabindex")||"";return cS(r)||r.hasAttribute("data-tabindex")&&!n.startsWith("-")}),o=e.getAttribute("tabindex");a.length===0?o!=="0"&&(e.setAttribute("tabindex","0"),e.setAttribute("data-tabindex","0")):(o!=="-1"||e.hasAttribute("data-tabindex")&&e.getAttribute("data-tabindex")!=="-1")&&(e.setAttribute("tabindex","-1"),e.setAttribute("data-tabindex","-1"))}function Kp(e){let{context:t,children:a,disabled:o=!1,initialFocus:r=!0,returnFocus:n=!0,restoreFocus:s=!1,modal:i=!0,closeOnFocusOut:l=!0,openInteractionType:u="",nextFocusableElement:c,previousFocusableElement:d,beforeContentFocusGuardRef:f,externalTree:m,getInsideElements:p}=e,y="rootStore"in t?t.rootStore:t,b=y.useState("open"),g=y.useState("domReferenceElement"),h=y.useState("floatingElement"),{events:x,dataRef:S}=y.context,v=W(()=>S.current.floatingContext?.nodeId),R=r===!1,L=zp(g)&&R,C=pt(r),E=pt(n),I=pt(u),A=pt(b),N=Rr(m),D=jT(),F=Qa.useRef(!1),k=Qa.useRef(!1),z=Qa.useRef(!1),q=Qa.useRef(null),O=Qa.useRef(""),V=Qa.useRef(""),w=Qa.useRef(null),_=Qa.useRef(null),U=mr(w,f,D?.beforeInsideRef),X=mr(_,D?.afterInsideRef),P=Qe(),H=Qe(),B=co(),J=D!=null,Y=Cu(h),te=W((ee=Y)=>ee?jp(ee):[]),ie=W(()=>p?.().filter(ee=>ee!=null)??[]);Qa.useEffect(()=>{if(o||!i)return;function ee(me){me.key==="Tab"&&ue(Y,_t(ve(Y)))&&te().length===0&&!L&&Mo(me)}let ae=ve(Y);return Re(ae,"keydown",ee)},[o,Y,i,L,te]),Qa.useEffect(()=>{if(o||!b)return;let ee=ve(Y);function ae(){z.current=!1}function me(Ee){let pe=$e(Ee),Te=ie(),le=ue(h,pe)||ue(g,pe)||ue(D?.portalNode,pe)||Te.some(Ie=>Ie===pe||ue(Ie,pe));z.current=!le,V.current=Ee.pointerType||"keyboard",pe?.closest(`[${pS}]`)&&(k.current=!0,H.start(0,()=>{k.current=!1}))}function ge(){V.current="keyboard"}return Ka(Re(ee,"pointerdown",me,!0),Re(ee,"pointerup",ae,!0),Re(ee,"pointercancel",ae,!0),Re(ee,"keydown",ge,!0),ae)},[o,h,g,Y,b,D,H,ie]),Qa.useEffect(()=>{if(o||!l)return;let ee=ve(Y);function ae(){k.current=!0,H.start(0,()=>{k.current=!1})}function me(Te){let le=$e(Te);cS(le)&&(q.current=le)}function ge(Te){let le=Te.relatedTarget,Ie=Te.currentTarget,Be=$e(Te);i&&le==null&&Be!=null&&ue(h,Be)&&s2(Be),queueMicrotask(()=>{let Oe=v(),ut=y.context.triggerElements,oe=ie(),fe=le?.hasAttribute(ds("focus-guard"))&&[w.current,_.current,D?.beforeInsideRef.current,D?.afterInsideRef.current,D?.beforeOutsideRef.current,D?.afterOutsideRef.current,Gr(d),Gr(c)].includes(le),K=!(ue(g,le)||ue(h,le)||ue(le,h)||ue(D?.portalNode,le)||oe.some(j=>j===le||ue(j,le))||ut.hasMatchingElement(j=>ue(j,le))||fe||N&&(Lr(N.nodesRef.current,Oe).find(j=>ue(j.context?.elements.floating,le)||ue(j.context?.elements.domReference,le))||_T(N.nodesRef.current,Oe).find(j=>[j.context?.elements.floating,Cu(j.context?.elements.floating)].includes(le)||j.context?.elements.domReference===le)));if(Ie===g&&Y&&l2(Y),s&&Ie!==g&&!Ru(Be)&&_t(ee)===ee.body){if(Ue(Y)&&(Y.focus(),s==="popup")){B.request(()=>{Y.focus()});return}let j=te(),se=q.current,Fe=(se&&j.includes(se)?se:null)||j[j.length-1]||Y;Ue(Fe)&&Fe.focus()}if(S.current.insideReactTree){S.current.insideReactTree=!1;return}(L||!i)&&le&&K&&!k.current&&(L||le!==i2())&&(F.current=!0,y.setOpen(!1,he(ne.focusOut,Te)))})}function Ee(){z.current||(S.current.insideReactTree=!0,P.start(0,()=>{S.current.insideReactTree=!1}))}let pe=Ue(g)?g:null;if(!(!h&&!pe))return Ka(pe&&Re(pe,"focusout",ge),pe&&Re(pe,"pointerdown",ae),h&&Re(h,"focusin",me),h&&Re(h,"focusout",ge),h&&D&&Re(h,"focusout",Ee,!0))},[o,g,h,Y,i,N,D,y,l,s,te,L,v,S,P,H,B,c,d,ie]),Qa.useEffect(()=>{if(o||!h||!b)return;let ee=Array.from(D?.portalNode?.querySelectorAll(`[${ds("portal")}]`)||[]),me=(N?_T(N.nodesRef.current,v()):[]).find(Ie=>zp(Ie.context?.elements.domReference||null))?.context?.elements.domReference,Ee=[...[h,...ee,w.current,_.current,D?.beforeOutsideRef.current,D?.afterOutsideRef.current,...ie()],me,Gr(d),Gr(c),L?g:null].filter(Ie=>Ie!=null),pe=qT(Ee,{ariaHidden:i||L,mark:!1}),Te=[h,...ee].filter(Ie=>Ie!=null),le=qT(Te);return()=>{le(),pe()}},[b,o,g,h,i,D,L,N,v,c,d,ie]),G(()=>{if(!b||o||!Ue(Y))return;O.current="",V.current="";let ee=ve(Y),ae=_t(ee);queueMicrotask(()=>{let me=C.current,ge=typeof me=="function"?me(I.current||""):me;if(ge===void 0||ge===!1||ue(Y,ae))return;let pe=null,Te=()=>(pe==null&&(pe=te(Y)),pe[0]||Y),le;ge===!0||ge===null?le=Te():le=Gr(ge),le=le||Te();let Ie=ue(Y,_t(ee));Of(le,{preventScroll:le===Y,shouldFocus(){if(!A.current)return!1;if(Ie)return!0;let Be=_t(ee);return!(Be!==le&&ue(Y,Be))}})})},[o,b,Y,te,C,I,A]),G(()=>{if(o||!Y)return;let ee=ve(Y),ae=_t(ee),me=I.current==null;s2(ae);function ge(pe){if(pe.open||(O.current=RY(pe.nativeEvent,V.current)),pe.reason===ne.triggerHover&&pe.nativeEvent.type==="mouseleave"&&(F.current=!0),pe.reason===ne.outsidePress)if(pe.nested)F.current=!1;else if(Ni(pe.nativeEvent)||Af(pe.nativeEvent))F.current=!1;else{let Te=!1;ve(Y).createElement("div").focus({get preventScroll(){return Te=!0,!1}}),Te?F.current=!1:F.current=!0}}x.on("openchange",ge);function Ee(pe){let Te=E.current,le=typeof Te=="function"?Te(pe):Te;if(le===void 0||le===!1)return null;le===null&&(le=!0);let Ie=g?.isConnected?g:null,Be=ae?.isConnected&&Wt(ae)!=="body"?ae:null,Oe=me?Be||Ie:Ie||Be;return Oe||(Oe=i2()||null),typeof le=="boolean"?Oe:Gr(le)||Oe||null}return()=>{x.off("openchange",ge);let pe=_t(ee),Te=ie(),le=ue(h,pe)||Te.some(ut=>ut===pe||ue(ut,pe))||N&&Lr(N.nodesRef.current,v(),!1).some(ut=>ue(ut.context?.elements.floating,pe)),Ie=E.current,Be=O.current,Oe=Ee(Be);queueMicrotask(()=>{let ut=TY(Oe),oe=typeof Ie!="boolean";if(Ie&&!F.current&&Ue(ut)&&(!(!oe&&ut!==pe&&pe!==ee.body)||le)){let fe={preventScroll:!0};Be==="keyboard"&&(fe.focusVisible=!0),ut.focus(fe)}F.current=!1})}},[o,h,Y,E,I,x,N,g,v,ie]),G(()=>{if(!ot.engine.webkit||b||!h)return;let ee=_t(ve(h));!Ue(ee)||!vu(ee)||ue(h,ee)&&ee.blur()},[b,h]),G(()=>{if(!(o||!D))return D.setFocusManagerState({modal:i,closeOnFocusOut:l,open:b,onOpenChange:y.setOpen,domReference:g}),()=>{D.setFocusManagerState(null)}},[o,D,i,b,y,l,g]),G(()=>{if(!(o||!Y))return l2(Y),()=>{queueMicrotask(XT)}},[o,Y]);let ce=!o&&(i?!L:!0)&&(J||i);return(0,Wp.jsxs)(Qa.Fragment,{children:[ce&&(0,Wp.jsx)(Mf,{"data-type":"inside",ref:U,onFocus:ee=>{if(i){let ae=te();Of(ae[ae.length-1])}else D?.portalNode&&(F.current=!1,Tu(ee,D.portalNode)?fS(g)?.focus():Gr(d??D.beforeOutsideRef)?.focus())}}),a,ce&&(0,Wp.jsx)(Mf,{"data-type":"inside",ref:X,onFocus:ee=>{i?Of(te()[0]):D?.portalNode&&(l&&(F.current=!0),Tu(ee,D.portalNode)?dS(g)?.focus():Gr(c??D.afterOutsideRef)?.focus())}})]})}var Zp=T(M(),1);function Qp(e,t={}){let{enabled:a=!0,event:o="click",toggle:r=!0,ignoreMouse:n=!1,stickIfOpen:s=!0,touchOpenDelay:i=0,reason:l=ne.triggerPress}=t,u="rootStore"in e?e.rootStore:e,c=u.context.dataRef,d=Zp.useRef(void 0),f=co(),m=Qe(),p=Zp.useMemo(()=>{function y(g,h,x,S){let v=he(l,h,x);g&&S==="touch"&&i>0?m.start(i,()=>{u.setOpen(!0,v)}):u.setOpen(g,v)}function b(g,h,x){let S=c.current.openEvent,v=u.select("domReferenceElement")!==h;return g&&v||!g||!r?!0:S&&s?!x(S.type):!1}return{onPointerDown(g){d.current=Jo(g.pointerType,!0)&&Af(g.nativeEvent)?"virtual":g.pointerType},onMouseDown(g){let h=d.current,x=g.nativeEvent,S=u.select("open");if(g.button!==0||o==="click"||Jo(h,!0)&&n)return;let v=b(S,g.currentTarget,C=>C==="click"||C==="mousedown"),R=$e(x);if(vu(R)){y(v,x,R,h);return}let L=g.currentTarget;f.request(()=>{y(v,x,L,h)})},onClick(g){if(o==="mousedown-only")return;let h=d.current;if(o==="mousedown"&&h){d.current=void 0;return}if(Jo(h,!0)&&n)return;let x=u.select("open"),S=b(x,g.currentTarget,v=>v==="click"||v==="mousedown"||v==="keydown"||v==="keyup");y(S,g.nativeEvent,g.currentTarget,h)},onKeyDown(){d.current=void 0}}},[c,o,n,l,u,s,r,f,m,i]);return Zp.useMemo(()=>a?{reference:p}:Ke,[a,p])}var Oo=T(M(),1);function IY(e,t){let a=null,o=null,r=!1;return{contextElement:e||void 0,getBoundingClientRect(){let n=e?.getBoundingClientRect()||{width:0,height:0,x:0,y:0},s=t.axis==="x"||t.axis==="both",i=t.axis==="y"||t.axis==="both",l=["mouseenter","mousemove"].includes(t.dataRef.current.openEvent?.type||"")&&t.pointerType!=="touch",u=n.width,c=n.height,d=n.x,f=n.y;return a==null&&t.x&&s&&(a=n.x-t.x),o==null&&t.y&&i&&(o=n.y-t.y),d-=a||0,f-=o||0,u=0,c=0,!r||l?(u=t.axis==="y"?n.width:0,c=t.axis==="x"?n.height:0,d=s&&t.x!=null?t.x:d,f=i&&t.y!=null?t.y:f):r&&!l&&(c=t.axis==="x"?n.height:c,u=t.axis==="y"?n.width:u),r=!0,{width:u,height:c,x:d,y:f,top:f,right:d+u,bottom:f+c,left:d}}}}function u2(e){return e!=null&&e.clientX!=null}function YT(e,t={}){let{enabled:a=!0,axis:o="both"}=t,r="rootStore"in e?e.rootStore:e,n=r.useState("open"),s=r.useState("floatingElement"),i=r.useState("domReferenceElement"),l=r.context.dataRef,u=Oo.useRef(!1),c=Oo.useRef(null),[d,f]=Oo.useState(),[m,p]=Oo.useState([]),y=W(S=>{r.set("positionReference",S)}),b=W((S,v,R)=>{u.current||l.current.openEvent&&!u2(l.current.openEvent)||r.set("positionReference",IY(R??i,{x:S,y:v,axis:o,dataRef:l,pointerType:d}))}),g=W(S=>{n?c.current||(b(S.clientX,S.clientY,S.currentTarget),p([])):b(S.clientX,S.clientY,S.currentTarget)}),h=Jo(d)?s:n;Oo.useEffect(()=>{if(!a){y(i);return}if(!h)return;function S(){c.current?.(),c.current=null}let v=He(s);function R(L){let C=$e(L);ue(s,C)?S():b(L.clientX,L.clientY)}return!l.current.openEvent||u2(l.current.openEvent)?c.current=Re(v,"mousemove",R):y(i),S},[h,a,s,l,i,r,b,y,m]),Oo.useEffect(()=>()=>{r.set("positionReference",null)},[r]),Oo.useEffect(()=>{a&&!s&&(u.current=!1)},[a,s]),Oo.useEffect(()=>{!a&&n&&(u.current=!0)},[a,n]);let x=Oo.useMemo(()=>{function S(v){f(v.pointerType)}return{onPointerDown:S,onPointerEnter:S,onMouseMove:g,onMouseEnter:g}},[g]);return Oo.useMemo(()=>a?{reference:x,trigger:x}:{},[a,x])}var fo=T(M(),1);function wY(){return!1}function EY(e){return{escapeKey:typeof e=="boolean"?e:e?.escapeKey??!1,outsidePress:typeof e=="boolean"?e:e?.outsidePress??!0}}function Eu(e,t={}){let{enabled:a=!0,escapeKey:o=!0,outsidePress:r=!0,outsidePressEvent:n="sloppy",referencePress:s=wY,bubbles:i,externalTree:l}=t,u="rootStore"in e?e.rootStore:e,c=u.useState("open"),d=u.useState("floatingElement"),{dataRef:f,events:m}=u.context,p=Rr(l),y=W(typeof r=="function"?r:()=>!1),b=typeof r=="function"?y:r,g=b!==!1,h=W(()=>n),{escapeKey:x,outsidePress:S}=EY(i),v=fo.useRef(!1),R=fo.useRef(!1),L=fo.useRef(!1),C=fo.useRef(!1),E=fo.useRef(!1),I=fo.useRef(""),A=fo.useRef(null),N=Qe(),D=Qe(),F=W(()=>{D.clear(),f.current.insideReactTree=!1}),k=W(P=>{let H=f.current.floatingContext?.nodeId;return(p?Lr(p.nodesRef.current,H):[]).some(J=>J.context?.open&&!J.context.dataRef.current[P])}),z=W(P=>tS(P,u.select("floatingElement"))||tS(P,u.select("domReferenceElement"))),q=W(P=>{s()&&u.setOpen(!1,he(ne.triggerPress,P.nativeEvent))}),O=W(P=>{if(!c||!a||!o||P.key!=="Escape"||E.current||!x&&k("__escapeKeyBubbles"))return;let H=RB(P)?P.nativeEvent:P,B=he(ne.escapeKey,H);u.setOpen(!1,B),B.isCanceled||P.preventDefault(),!x&&!B.isPropagationAllowed&&P.stopPropagation()}),V=W(()=>{f.current.insideReactTree=!0,D.start(0,F)}),w=W(P=>{if(!c||!a||P.button!==0)return;let H=$e(P.nativeEvent);ue(u.select("floatingElement"),H)&&(v.current||(v.current=!0,R.current=!1))}),_=W(P=>{!c||!a||(P.defaultPrevented||P.nativeEvent.defaultPrevented)&&v.current&&(R.current=!0)});fo.useEffect(()=>{function P(H){H.open||(C.current=!1)}return m.on("openchange",P),()=>{m.off("openchange",P)}},[m]),fo.useEffect(()=>{if(!c||!a)return c||(C.current=!1),F;f.current.__escapeKeyBubbles=x,f.current.__outsidePressBubbles=S;let P=new Wa,H=new Wa,B=ve(d);function J(){P.clear(),E.current=!0}function Y(){P.start(ot.engine.webkit?5:0,()=>{E.current=!1})}function te(){L.current=!0,H.start(0,()=>{L.current=!1})}function ie(){v.current=!1,R.current=!1}function ce(){let K=I.current,j=K==="pen"||!K?"mouse":K,se=h(),Fe=typeof se=="function"?se():se;return typeof Fe=="string"?Fe:Fe[j]}function ee(K){let j=ce();return j==="intentional"&&K.type!=="click"||j==="sloppy"&&K.type==="click"}function ae(K){let j=f.current.floatingContext?.nodeId,se=p&&Lr(p.nodesRef.current,j).some(Fe=>tS(K,Fe.context?.elements.floating));return z(K)||se}function me(K){if(ee(K)){K.type!=="click"&&!z(K)&&(H.clear(),L.current=!1),F();return}if(f.current.insideReactTree){F();return}let j=$e(K),se=`[${ds("inert")}]`,Fe=we(j)?j.getRootNode():null,Vt=Array.from((Cn(Fe)?Fe:ve(u.select("floatingElement"))).querySelectorAll(se)),Jt=u.context.triggerElements;if(j&&(Jt.hasElement(j)||Jt.hasMatchingElement(bt=>ue(bt,j))))return;let Et=we(j)?j:null;for(;Et&&!Sr(Et);){let bt=Zo(Et);if(Sr(bt)||!we(bt))break;Et=bt}if(!(Vt.length&&we(j)&&!wB(j)&&!ue(j,u.select("floatingElement"))&&Vt.every(bt=>!ue(Et,bt)))){if(Ue(j)&&!("touches"in K)){let bt=Sr(j),wa=pa(j),Ea=/auto|scroll/,$t=bt||Ea.test(wa.overflowX),Ha=bt||Ea.test(wa.overflowY),ho=$t&&j.clientWidth>0&&j.scrollWidth>j.clientWidth,tr=Ha&&j.clientHeight>0&&j.scrollHeight>j.clientHeight,ha=wa.direction==="rtl",Ht=tr&&(ha?K.offsetX<=j.offsetWidth-j.clientWidth:K.offsetX>j.clientWidth),Ae=ho&&K.offsetY>j.clientHeight;if(Ht||Ae)return}if(!ae(K)){if(ce()==="intentional"){if(K.detail!==0&&!Ni(K)&&!C.current)return;if(L.current){H.clear(),L.current=!1;return}}typeof b=="function"&&!b(K)||k("__outsidePressBubbles")||(u.setOpen(!1,he(ne.outsidePress,K)),F())}}}function ge(K){ce()!=="sloppy"||K.pointerType==="touch"||!u.select("open")||!a||z(K)||me(K)}function Ee(K){if(ce()!=="sloppy"||!u.select("open")||!a||z(K))return;let j=K.touches[0];j&&(A.current={startTime:Date.now(),startX:j.clientX,startY:j.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},N.start(1e3,()=>{A.current&&(A.current.dismissOnTouchEnd=!1,A.current.dismissOnMouseDown=!1)}))}function pe(K,j){let se=$e(K);if(!se)return;let Fe=Re(se,K.type,()=>{j(K),Fe()})}function Te(K){I.current="touch",pe(K,Ee)}function le(K){N.clear(),K.type==="pointerdown"&&(K.button===0&&(C.current=!0),I.current=K.pointerType),!(K.type==="mousedown"&&A.current&&!A.current.dismissOnMouseDown)&&pe(K,j=>{j.type==="pointerdown"?ge(j):me(j)})}function Ie(K){if(K.type==="pointercancel"&&(C.current=!1),!v.current)return;let j=R.current;if(ie(),ce()==="intentional"){if(K.type==="pointercancel"){j&&te();return}if(!ae(K)){if(j){te();return}typeof b=="function"&&!b(K)||(H.clear(),L.current=!0,F())}}}function Be(K){if(ce()!=="sloppy"||!A.current||z(K))return;let j=K.touches[0];if(!j)return;let se=Math.abs(j.clientX-A.current.startX),Fe=Math.abs(j.clientY-A.current.startY),Vt=Math.sqrt(se*se+Fe*Fe);Vt>5&&(A.current.dismissOnTouchEnd=!0),Vt>10&&(me(K),N.clear(),A.current=null)}function Oe(K){pe(K,Be)}function ut(K){ce()!=="sloppy"||!A.current||z(K)||(A.current.dismissOnTouchEnd&&me(K),N.clear(),A.current=null)}function oe(K){pe(K,ut)}let fe=Ka(o&&Ka(Re(B,"keydown",O),Re(B,"compositionstart",J),Re(B,"compositionend",Y)),g&&Ka(Re(B,"click",le,!0),Re(B,"pointerdown",le,!0),Re(B,"pointerup",Ie,!0),Re(B,"pointercancel",Ie,!0),Re(B,"mousedown",le,!0),Re(B,"mouseup",Ie,!0),Re(B,"touchstart",Te,{capture:!0,passive:!0}),Re(B,"touchmove",Oe,{capture:!0,passive:!0}),Re(B,"touchend",oe,{capture:!0,passive:!0})));return()=>{fe(),P.clear(),H.clear(),ie(),L.current=!1,F()}},[f,d,o,g,b,c,a,x,S,O,F,h,k,z,p,u,N]);let U=fo.useMemo(()=>({onKeyDown:O,onPointerDown:q,onClick:q}),[O,q]),X=fo.useMemo(()=>({onKeyDown:O,onPointerDown:_,onMouseDown:_,onClickCapture:V,onMouseDownCapture(P){V(),w(P)},onPointerDownCapture(P){V(),w(P)},onMouseUpCapture:V,onTouchEndCapture:V,onTouchMoveCapture:V}),[O,V,w,_]);return fo.useMemo(()=>a?{reference:U,floating:X,trigger:U}:{},[a,U,X])}var Ja=T(M(),1);function c2(e,t,a){let{reference:o,floating:r}=e,n=Po(t),s=Gp(t),i=qp(s),l=Za(t),u=n==="y",c=o.x+o.width/2-r.width/2,d=o.y+o.height/2-r.height/2,f=o[i]/2-r[i]/2,m;switch(l){case"top":m={x:c,y:o.y-r.height};break;case"bottom":m={x:c,y:o.y+o.height};break;case"right":m={x:o.x+o.width,y:d};break;case"left":m={x:o.x-r.width,y:d};break;default:m={x:o.x,y:o.y}}let p=vr(t);return p&&(m[s]+=f*(p==="end"?1:-1)*(a&&u?-1:1)),m}async function f2(e,t){var a;t===void 0&&(t={});let{x:o,y:r,platform:n,rects:s,elements:i,strategy:l}=e,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:f=!1,padding:m=0}=In(t,e),p=uS(m),b=i[f?d==="floating"?"reference":"floating":d],g=cs(await n.getClippingRect({element:(a=await(n.isElement==null?void 0:n.isElement(b)))==null||a?b:b.contextElement||await(n.getDocumentElement==null?void 0:n.getDocumentElement(i.floating)),boundary:u,rootBoundary:c,strategy:l})),h=d==="floating"?{x:o,y:r,width:s.floating.width,height:s.floating.height}:s.reference,x=await(n.getOffsetParent==null?void 0:n.getOffsetParent(i.floating)),S=await(n.isElement==null?void 0:n.isElement(x))&&await(n.getScale==null?void 0:n.getScale(x))||{x:1,y:1},v=cs(n.convertOffsetParentRelativeRectToViewportRelativeRect?await n.convertOffsetParentRelativeRectToViewportRelativeRect({elements:i,rect:h,offsetParent:x,strategy:l}):h);return{top:(g.top-v.top+p.top)/S.y,bottom:(v.bottom-g.bottom+p.bottom)/S.y,left:(g.left-v.left+p.left)/S.x,right:(v.right-g.right+p.right)/S.x}}var AY=50,d2=async(e,t,a)=>{let{placement:o="bottom",strategy:r="absolute",middleware:n=[],platform:s}=a,i=s.detectOverflow?s:{...s,detectOverflow:f2},l=await(s.isRTL==null?void 0:s.isRTL(t)),u=await s.getElementRects({reference:e,floating:t,strategy:r}),{x:c,y:d}=c2(u,o,l),f=o,m=0,p={};for(let y=0;y<n.length;y++){let b=n[y];if(!b)continue;let{name:g,fn:h}=b,{x,y:S,data:v,reset:R}=await h({x:c,y:d,initialPlacement:o,placement:f,strategy:r,middlewareData:p,rects:u,platform:i,elements:{reference:e,floating:t}});c=x??c,d=S??d,p[g]={...p[g],...v},R&&m<AY&&(m++,typeof R=="object"&&(R.placement&&(f=R.placement),R.rects&&(u=R.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:r}):R.rects),{x:c,y:d}=c2(u,f,l)),y=-1)}return{x:c,y:d,placement:f,strategy:r,middlewareData:p}};var m2=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var a,o;let{placement:r,middlewareData:n,rects:s,initialPlacement:i,platform:l,elements:u}=t,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:m="bestFit",fallbackAxisSideDirection:p="none",flipAlignment:y=!0,...b}=In(e,t);if((a=n.arrow)!=null&&a.alignmentOffset)return{};let g=Za(r),h=Po(i),x=Za(i)===i,S=await(l.isRTL==null?void 0:l.isRTL(u.floating)),v=f||(x||!y?[Hp(i)]:FB(i)),R=p!=="none";!f&&R&&v.push(..._B(i,y,p,S));let L=[i,...v],C=await l.detectOverflow(t,b),E=[],I=((o=n.flip)==null?void 0:o.overflows)||[];if(c&&E.push(C[g]),d){let F=BB(r,s,S);E.push(C[F[0]],C[F[1]])}if(I=[...I,{placement:r,overflows:E}],!E.every(F=>F<=0)){var A,N;let F=(((A=n.flip)==null?void 0:A.index)||0)+1,k=L[F];if(k&&(!(d==="alignment"?h!==Po(k):!1)||I.every(O=>Po(O.placement)===h?O.overflows[0]>0:!0)))return{data:{index:F,overflows:I},reset:{placement:k}};let z=(N=I.filter(q=>q.overflows[0]<=0).sort((q,O)=>q.overflows[1]-O.overflows[1])[0])==null?void 0:N.placement;if(!z)switch(m){case"bestFit":{var D;let q=(D=I.filter(O=>{if(R){let V=Po(O.placement);return V===h||V==="y"}return!0}).map(O=>[O.placement,O.overflows.filter(V=>V>0).reduce((V,w)=>V+w,0)]).sort((O,V)=>O[1]-V[1])[0])==null?void 0:D[0];q&&(z=q);break}case"initialPlacement":z=i;break}if(r!==z)return{reset:{placement:z}}}return{}}}};var p2=new Set(["left","top"]);async function DY(e,t){let{placement:a,platform:o,elements:r}=e,n=await(o.isRTL==null?void 0:o.isRTL(r.floating)),s=Za(a),i=vr(a),l=Po(a)==="y",u=p2.has(s)?-1:1,c=n&&l?-1:1,d=In(t,e),{mainAxis:f,crossAxis:m,alignmentAxis:p}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return i&&typeof p=="number"&&(m=i==="end"?p*-1:p),l?{x:m*c,y:f*u}:{x:f*u,y:m*c}}var h2=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var a,o;let{x:r,y:n,placement:s,middlewareData:i}=t,l=await DY(t,e);return s===((a=i.offset)==null?void 0:a.placement)&&(o=i.arrow)!=null&&o.alignmentOffset?{}:{x:r+l.x,y:n+l.y,data:{...l,placement:s}}}}},g2=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:a,y:o,placement:r,platform:n}=t,{mainAxis:s=!0,crossAxis:i=!1,limiter:l={fn:h=>{let{x,y:S}=h;return{x,y:S}}},...u}=In(e,t),c={x:a,y:o},d=await n.detectOverflow(t,u),f=Po(r),m=lS(f),p=c[m],y=c[f],b=(h,x)=>iS(x+d[h==="y"?"top":"left"],x,x-d[h==="y"?"bottom":"right"]);s&&(p=b(m,p)),i&&(y=b(f,y));let g=l.fn({...t,[m]:p,[f]:y});return{...g,data:{x:g.x-a,y:g.y-o,enabled:{[m]:s,[f]:i}}}}}},x2=function(e){return e===void 0&&(e={}),{options:e,fn(t){var a,o;let{x:r,y:n,placement:s,rects:i,middlewareData:l}=t,{offset:u=0,mainAxis:c=!0,crossAxis:d=!0}=In(e,t),f={x:r,y:n},m=Po(s),p=lS(m),y=f[p],b=f[m],g=In(u,t),h=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:(a=g.mainAxis)!=null?a:0,crossAxis:(o=g.crossAxis)!=null?o:0};if(c){let v=p==="y"?"height":"width",R=i.reference[p]-i.floating[v]+h.mainAxis,L=i.reference[p]+i.reference[v]-h.mainAxis;y<R?y=R:y>L&&(y=L)}if(d){var x,S;let v=p==="y"?"width":"height",R=p2.has(Za(s)),L=i.reference[m]-i.floating[v]+(R&&((x=l.offset)==null?void 0:x[m])||0)+(R?0:h.crossAxis),C=i.reference[m]+i.reference[v]+(R?0:((S=l.offset)==null?void 0:S[m])||0)-(R?h.crossAxis:0);b<L?b=L:b>C&&(b=C)}return{[p]:y,[m]:b}}}},y2=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){let{placement:a,rects:o,platform:r,elements:n}=t,{apply:s=()=>{},...i}=In(e,t),l=await r.detectOverflow(t,i),u=Za(a),c=vr(a),d=Po(a)==="y",{width:f,height:m}=o.floating,p,y;u==="top"||u==="bottom"?(p=u,y=c===(await(r.isRTL==null?void 0:r.isRTL(n.floating))?"start":"end")?"left":"right"):(y=u,p=c==="end"?"top":"bottom");let b=m-l.top-l.bottom,g=f-l.left-l.right,h=Bi(m-l[p],b),x=Bi(f-l[y],g),S=t.middlewareData.shift,v=!S,R=h,L=x;S!=null&&S.enabled.x&&(L=g),S!=null&&S.enabled.y&&(R=b),v&&!c&&(d?L=f-2*qr(l.left,l.right):R=m-2*qr(l.top,l.bottom)),await s({...t,availableWidth:L,availableHeight:R});let C=await r.getDimensions(n.floating);return f!==C.width||m!==C.height?{reset:{rects:!0}}:{}}}};function v2(e){let t=pa(e),a=parseFloat(t.width)||0,o=parseFloat(t.height)||0,r=Ue(e),n=r?e.offsetWidth:a,s=r?e.offsetHeight:o,i=Fi(a)!==n||Fi(o)!==s;return i&&(a=n,o=s),{width:a,height:o,$:i}}function KT(e){return we(e)?e:e.contextElement}function kf(e){let t=KT(e);if(!Ue(t))return Tn(1);let a=t.getBoundingClientRect(),{width:o,height:r,$:n}=v2(t),s=(n?Fi(a.width):a.width)/o,i=(n?Fi(a.height):a.height)/r;return(!s||!Number.isFinite(s))&&(s=1),(!i||!Number.isFinite(i))&&(i=1),{x:s,y:i}}var MY=Tn(0);function C2(e){let t=He(e);return!jy()||!t.visualViewport?MY:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function PY(e,t,a){return t===void 0&&(t=!1),!!a&&t&&a===He(e)}function Au(e,t,a,o){t===void 0&&(t=!1),a===void 0&&(a=!1);let r=e.getBoundingClientRect(),n=KT(e),s=Tn(1);t&&(o?we(o)&&(s=kf(o)):s=kf(e));let i=PY(n,a,o)?C2(n):Tn(0),l=(r.left+i.x)/s.x,u=(r.top+i.y)/s.y,c=r.width/s.x,d=r.height/s.y;if(n&&o){let f=He(n),m=we(o)?He(o):o,p=f,y=Xy(p);for(;y&&m!==p;){let b=kf(y),g=y.getBoundingClientRect(),h=pa(y),x=g.left+(y.clientLeft+parseFloat(h.paddingLeft))*b.x,S=g.top+(y.clientTop+parseFloat(h.paddingTop))*b.y;l*=b.x,u*=b.y,c*=b.x,d*=b.y,l+=x,u+=S,p=He(y),y=Xy(p)}}return cs({width:c,height:d,x:l,y:u})}function gS(e,t){let a=Dp(e).scrollLeft;return t?t.left+a:Au(Ln(e)).left+a}function L2(e,t){let a=e.getBoundingClientRect(),o=a.left+t.scrollLeft-gS(e,a),r=a.top+t.scrollTop;return{x:o,y:r}}function OY(e){let{elements:t,rect:a,offsetParent:o,strategy:r}=e,n=r==="fixed",s=Ln(o),i=t?Ap(t.floating):!1;if(o===s||i&&n)return a;let l={scrollLeft:0,scrollTop:0},u=Tn(1),c=Tn(0),d=Ue(o);if((d||!n)&&((Wt(o)!=="body"||pu(s))&&(l=Dp(o)),d)){let m=Au(o);u=kf(o),c.x=m.x+o.clientLeft,c.y=m.y+o.clientTop}let f=s&&!d&&!n?L2(s,l):Tn(0);return{width:a.width*u.x,height:a.height*u.y,x:a.x*u.x-l.scrollLeft*u.x+c.x+f.x,y:a.y*u.y-l.scrollTop*u.y+c.y+f.y}}function kY(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function NY(e){let t=Dp(e),a=e.ownerDocument.body,o=qr(e.scrollWidth,e.clientWidth,a.scrollWidth,a.clientWidth),r=qr(e.scrollHeight,e.clientHeight,a.scrollHeight,a.clientHeight),n=-t.scrollLeft+gS(e),s=-t.scrollTop;return pa(a).direction==="rtl"&&(n+=qr(e.clientWidth,a.clientWidth)-o),{width:o,height:r,x:n,y:s}}var VY=25;function BY(e,t,a){a===void 0&&(a="viewport");let o=a==="layoutViewport",r=He(e),n=Ln(e),s=r.visualViewport,i=n.clientWidth,l=n.clientHeight,u=0,c=0;if(s){let f=!jy()||t==="fixed";o?f||(u=-s.offsetLeft,c=-s.offsetTop):(i=s.width,l=s.height,f&&(u=s.offsetLeft,c=s.offsetTop))}if(gS(n)<=0){let f=n.ownerDocument,m=f.body,p=getComputedStyle(m),y=f.compatMode==="CSS1Compat"&&parseFloat(p.marginLeft)+parseFloat(p.marginRight)||0,b=Math.abs(n.clientWidth-m.clientWidth-y),g=getComputedStyle(n).scrollbarGutter==="stable both-edges"?b/2:b;g<=VY&&(i-=g)}return{width:i,height:l,x:u,y:c}}function FY(e,t){let a=Au(e,!0,t==="fixed"),o=a.top+e.clientTop,r=a.left+e.clientLeft,n=kf(e),s=e.clientWidth*n.x,i=e.clientHeight*n.y,l=r*n.x,u=o*n.y;return{width:s,height:i,x:l,y:u}}function S2(e,t,a){let o;if(t==="viewport"||t==="layoutViewport")o=BY(e,a,t);else if(t==="document")o=NY(Ln(e));else if(we(t))o=FY(t,a);else{let r=C2(e);o={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return cs(o)}function _Y(e,t){let a=t.get(e);if(a)return a;let o=Mi(e,[],!1).filter(i=>we(i)&&Wt(i)!=="body"),r=null,n=pa(e).position==="fixed",s=n?Zo(e):e;for(;we(s)&&!Sr(s);){let i=pa(s),l=Gy(s),u=r?r.position:n?"fixed":"";!l&&(u==="fixed"||u==="absolute"&&i.position==="static")?o=o.filter(d=>d!==s):r=i,s=Zo(s)}return t.set(e,o),o}function zY(e){let{element:t,boundary:a,rootBoundary:o,strategy:r}=e,s=[...a==="clippingAncestors"?Ap(t)?[]:_Y(t,this._c):[].concat(a),o],i=S2(t,s[0],r),l=i.top,u=i.right,c=i.bottom,d=i.left;for(let f=1;f<s.length;f++){let m=S2(t,s[f],r);l=qr(m.top,l),u=Bi(m.right,u),c=Bi(m.bottom,c),d=qr(m.left,d)}return{width:u-d,height:c-l,x:d,y:l}}function HY(e){let{width:t,height:a}=v2(e);return{width:t,height:a}}function UY(e,t,a){let o=Ue(t),r=Ln(t),n=a==="fixed",s=Au(e,!0,n,t),i={scrollLeft:0,scrollTop:0},l=Tn(0);if((o||!n)&&((Wt(t)!=="body"||pu(r))&&(i=Dp(t)),o)){let f=Au(t,!0,n,t);l.x=f.x+t.clientLeft,l.y=f.y+t.clientTop}!o&&r&&(l.x=gS(r));let u=r&&!o&&!n?L2(r,i):Tn(0),c=s.left+i.scrollLeft-l.x-u.x,d=s.top+i.scrollTop-l.y-u.y;return{x:c,y:d,width:s.width,height:s.height}}function WT(e){return pa(e).position==="static"}function b2(e,t){if(!Ue(e)||pa(e).position==="fixed")return null;if(t)return t(e);let a=e.offsetParent;return Ln(e)===a&&(a=a.ownerDocument.body),a}function R2(e,t){let a=He(e);if(Ap(e))return a;if(!Ue(e)){let r=Zo(e);for(;r&&!Sr(r);){if(we(r)&&!WT(r))return r;r=Zo(r)}return a}let o=b2(e,t);for(;o&&$V(o)&&WT(o);)o=b2(o,t);return o&&Sr(o)&&WT(o)&&!Gy(o)?a:o||eB(e)||a}var qY=async function(e){let t=this.getOffsetParent||R2,a=this.getDimensions,o=await a(e.floating);return{reference:UY(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function GY(e){return pa(e).direction==="rtl"}var Jp={convertOffsetParentRelativeRectToViewportRelativeRect:OY,getDocumentElement:Ln,getClippingRect:zY,getOffsetParent:R2,getElementRects:qY,getClientRects:kY,getDimensions:HY,getScale:kf,isElement:we,isRTL:GY};function T2(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function jY(e,t,a){let o=null,r,n=Ln(e);function s(){var c;clearTimeout(r),(c=o)==null||c.disconnect(),o=null}function i(c,d){c===void 0&&(c=!1),d===void 0&&(d=1),s();let f=e.getBoundingClientRect(),{left:m,top:p,width:y,height:b}=f;if(c||t(),!y||!b)return;let g=Up(p),h=Up(n.clientWidth-(m+y)),x=Up(n.clientHeight-(p+b)),S=Up(m),R={rootMargin:-g+"px "+-h+"px "+-x+"px "+-S+"px",threshold:qr(0,Bi(1,d))||1},L=!0;function C(E){let I=E[0].intersectionRatio;if(!T2(f,e.getBoundingClientRect()))return i();if(I!==d){if(!L)return i();I?i(!1,I):r=setTimeout(()=>{i(!1,1e-7)},1e3)}L=!1}try{o=new IntersectionObserver(C,{...R,root:n.ownerDocument})}catch{o=new IntersectionObserver(C,R)}o.observe(e)}let l=He(e),u=()=>i(a);return l.addEventListener("resize",u),i(!0),()=>{l.removeEventListener("resize",u),s()}}function $p(e,t,a,o){o===void 0&&(o={});let{ancestorScroll:r=!0,ancestorResize:n=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:i=typeof IntersectionObserver=="function",animationFrame:l=!1}=o,u=KT(e),c=r||n?[...u?Mi(u):[],...t?Mi(t):[]]:[];c.forEach(g=>{r&&g.addEventListener("scroll",a),n&&g.addEventListener("resize",a)});let d=u&&i?jY(u,a,n):null,f=-1,m=null;s&&(m=new ResizeObserver(g=>{let[h]=g;h&&h.target===u&&m&&t&&(m.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var x;(x=m)==null||x.observe(t)})),a()}),u&&!l&&m.observe(u),t&&m.observe(t));let p,y=l?Au(e):null;l&&b();function b(){let g=Au(e);y&&!T2(y,g)&&a(),y=g,p=requestAnimationFrame(b)}return a(),()=>{var g;c.forEach(h=>{r&&h.removeEventListener("scroll",a),n&&h.removeEventListener("resize",a)}),d?.(),(g=m)==null||g.disconnect(),m=null,l&&cancelAnimationFrame(p)}}var I2=h2;var w2=g2,E2=m2,A2=y2;var D2=x2,xS=(e,t,a)=>{let o=new Map,r=a??{},n={...Jp,...r.platform,_c:o};return d2(e,t,{...r,platform:n})};var na=T(M(),1),P2=T(M(),1),O2=T(Zr(),1),YY=typeof document<"u",WY=function(){},yS=YY?P2.useLayoutEffect:WY;function SS(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 a,o,r;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(a=e.length,a!==t.length)return!1;for(o=a;o--!==0;)if(!SS(e[o],t[o]))return!1;return!0}if(r=Object.keys(e),a=r.length,a!==Object.keys(t).length)return!1;for(o=a;o--!==0;)if(!{}.hasOwnProperty.call(t,r[o]))return!1;for(o=a;o--!==0;){let n=r[o];if(!(n==="_owner"&&e.$$typeof)&&!SS(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function k2(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function M2(e,t){let a=k2(e);return Math.round(t*a)/a}function ZT(e){let t=na.useRef(e);return yS(()=>{t.current=e}),t}function N2(e){e===void 0&&(e={});let{placement:t="bottom",strategy:a="absolute",middleware:o=[],platform:r,elements:{reference:n,floating:s}={},transform:i=!0,whileElementsMounted:l,open:u}=e,[c,d]=na.useState({x:0,y:0,strategy:a,placement:t,middlewareData:{},isPositioned:!1}),[f,m]=na.useState(o);SS(f,o)||m(o);let[p,y]=na.useState(null),[b,g]=na.useState(null),h=na.useCallback(O=>{O!==R.current&&(R.current=O,y(O))},[]),x=na.useCallback(O=>{O!==L.current&&(L.current=O,g(O))},[]),S=n||p,v=s||b,R=na.useRef(null),L=na.useRef(null),C=na.useRef(c),E=l!=null,I=ZT(l),A=ZT(r),N=ZT(u),D=na.useCallback(()=>{if(!R.current||!L.current)return;let O={placement:t,strategy:a,middleware:f};A.current&&(O.platform=A.current),xS(R.current,L.current,O).then(V=>{let w={...V,isPositioned:N.current!==!1};F.current&&!SS(C.current,w)&&(C.current=w,O2.flushSync(()=>{d(w)}))})},[f,t,a,A,N]);yS(()=>{u===!1&&C.current.isPositioned&&(C.current.isPositioned=!1,d(O=>({...O,isPositioned:!1})))},[u]);let F=na.useRef(!1);yS(()=>(F.current=!0,()=>{F.current=!1}),[]),yS(()=>{if(S&&(R.current=S),v&&(L.current=v),S&&v){if(I.current)return I.current(S,v,D);D()}},[S,v,D,I,E]);let k=na.useMemo(()=>({reference:R,floating:L,setReference:h,setFloating:x}),[h,x]),z=na.useMemo(()=>({reference:S,floating:v}),[S,v]),q=na.useMemo(()=>{let O={position:a,left:0,top:0};if(!z.floating)return O;let V=M2(z.floating,c.x),w=M2(z.floating,c.y);return i?{...O,transform:"translate("+V+"px, "+w+"px)",...k2(z.floating)>=1.5&&{willChange:"transform"}}:{position:a,left:V,top:w}},[a,i,z.floating,c.x,c.y]);return na.useMemo(()=>({...c,update:D,refs:k,elements:z,floatingStyles:q}),[c,D,k,z,q])}var QT=(e,t)=>{let a=I2(e);return{name:a.name,fn:a.fn,options:[e,t]}},JT=(e,t)=>{let a=w2(e);return{name:a.name,fn:a.fn,options:[e,t]}},$T=(e,t)=>({fn:D2(e).fn,options:[e,t]}),eI=(e,t)=>{let a=E2(e);return{name:a.name,fn:a.fn,options:[e,t]}},tI=(e,t)=>{let a=A2(e);return{name:a.name,fn:a.fn,options:[e,t]}};var Nf=class{attachedStores=[];attachedStoreValue=null;storeListeners=new Set;constructor(t,a,o=!0){this.fallbackStore=t,this.componentName=a,this.throwOnMissingTrigger=o}get attachedStore(){return this.attachedStoreValue}get store(){return this.attachedStoreValue??this.fallbackStore}get serverStore(){return this.fallbackStore}subscribeStore(t){return this.storeListeners.add(t),()=>{this.storeListeners.delete(t)}}attachStore(t){return this.attachedStores.push(t),this.setActiveStore(t),()=>{let a=this.attachedStores.lastIndexOf(t);a!==-1&&this.attachedStores.splice(a,1),this.setActiveStore(this.attachedStores[this.attachedStores.length-1]??null)}}setActiveStore(t){this.attachedStoreValue!==t&&(this.attachedStoreValue=t,this.storeListeners.forEach(a=>{a()}))}openByTrigger(t){let a=this.attachedStore;if(a===null)return;let o;if(t){for(let r=this.attachedStores.length-1;r>=0&&!o;r-=1)o=this.attachedStores[r].context.triggerElements.getById(t);o??=this.fallbackStore.context.triggerElements.getById(t)}if(t&&!o&&this.throwOnMissingTrigger)throw new Error(Me(99,this.componentName,t,this.componentName));a.setOpen(!0,he(ne.imperativeAction,void 0,o))}closePopup(){let t=this.attachedStore;t!==null&&t.setOpen(!1,he(ne.imperativeAction))}};var lI=T(M(),1),$2=T(Zr(),1);var K2=T(M(),1);var X2=T(M(),1),nI=T(eh(),1),Y2=T(U2(),1);var q2=T(M(),1);var oI=[],rI;function G2(){return rI}function j2(e){oI.push(e)}function th(e){let t=(a,o)=>{let r=at(d7).current,n;try{rI=r;for(let s of oI)s.before(r);n=e(a,o);for(let s of oI)s.after(r);r.didInitialize=!0}finally{rI=void 0}return n};return t.displayName=e.displayName||e.name,t}function vS(e){return q2.forwardRef(th(e))}function d7(){return{didInitialize:!1}}var m7=Gc(19),p7=m7?g7:x7;function CS(e,t,a,o,r){return p7(e,t,a,o,r)}function h7(e,t,a,o,r){let n=X2.useCallback(()=>t(e.getSnapshot(),a,o,r),[e,t,a,o,r]);return(0,nI.useSyncExternalStore)(e.subscribe,n,n)}j2({before(e){e.syncIndex=0,e.didInitialize||(e.syncTick=1,e.syncHooks=[],e.didChangeStore=!0,e.getSnapshot=()=>{let t=!1;for(let a=0;a<e.syncHooks.length;a+=1){let o=e.syncHooks[a],r=o.selector(o.store.state,o.a1,o.a2,o.a3);Object.is(o.value,r)||(t=!0,o.value=r)}return t&&(e.syncTick+=1),e.syncTick})},after(e){e.syncHooks.length>0&&(e.didChangeStore&&(e.didChangeStore=!1,e.subscribe=t=>{let a=new Set;for(let r of e.syncHooks)a.add(r.store);let o=[];for(let r of a)o.push(r.subscribe(t));return()=>{for(let r of o)r()}}),(0,nI.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot))}});function g7(e,t,a,o,r){let n=G2();if(!n)return h7(e,t,a,o,r);let s=n.syncIndex;n.syncIndex+=1;let i;return n.didInitialize?(i=n.syncHooks[s],(i.store!==e||i.selector!==t||!Object.is(i.a1,a)||!Object.is(i.a2,o)||!Object.is(i.a3,r))&&(i.store!==e&&(n.didChangeStore=!0),i.store=e,i.selector=t,i.a1=a,i.a2=o,i.a3=r,i.value=t(e.getSnapshot(),a,o,r))):(i={store:e,selector:t,a1:a,a2:o,a3:r,value:t(e.getSnapshot(),a,o,r)},n.syncHooks.push(i)),i.value}function x7(e,t,a,o,r){return(0,Y2.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,n=>t(n,a,o,r))}var LS=class{static create(t){return new this(t)}constructor(t){this.state=t,this.listeners=new Set,this.updateTick=0}subscribe=t=>(this.listeners.add(t),()=>{this.listeners.delete(t)});getSnapshot=()=>this.state;setState(t){if(this.state===t)return;this.state=t,this.updateTick+=1;let a=this.updateTick;for(let o of this.listeners){if(a!==this.updateTick)return;o(t)}}update(t){for(let a in t)if(!Object.is(this.state[a],t[a])){this.setState({...this.state,...t});return}}set(t,a){Object.is(this.state[t],a)||this.setState({...this.state,[t]:a})}notifyAll(){let t={...this.state};this.setState(t)}use(t,a,o,r){return CS(this,t,a,o,r)}};var Du=T(M(),1);var Tr=class extends LS{constructor(t,a={},o){super(t),this.context=a,this.selectors=o}useSyncedValue(t,a){Du.useDebugValue(t);let o=this;G(()=>{o.state[t]!==a&&o.set(t,a)},[o,t,a])}useSyncedValueWithCleanup(t,a){let o=this;G(()=>(o.state[t]!==a&&o.set(t,a),()=>{o.set(t,void 0)}),[o,t,a])}useSyncedValues(t){let a=this,o=Object.values(t);G(()=>{a.update(t)},[a,...o])}useControlledProp(t,a){Du.useDebugValue(t);let o=this,r=a!==void 0;G(()=>{r&&!Object.is(o.state[t],a)&&o.setState({...o.state,[t]:a})},[o,t,a,r])}select(t,a,o,r){let n=this.selectors[t];return n(this.state,a,o,r)}useState(t,a,o,r){return Du.useDebugValue(t),CS(this,this.selectors[t],a,o,r)}useContextCallback(t,a){Du.useDebugValue(t);let o=W(a??Ve);this.context[t]=o}useStateSetter(t){let a=Du.useRef(void 0);return a.current===void 0&&(a.current=o=>{this.set(t,o)}),a.current}observe(t,a){let o;typeof t=="function"?o=t:o=this.selectors[t];let r=o(this.state);return a(r,r,this),this.subscribe(n=>{let s=o(n);if(!Object.is(r,s)){let i=r;r=s,a(s,i,this)}})}};var RS=T(M(),1);function W2(){let[,e]=RS.useState({});return RS.useCallback(()=>{e({})},[])}var y7={open:e=>e.open,transitionStatus:e=>e.transitionStatus,domReferenceElement:e=>e.domReferenceElement,referenceElement:e=>e.positionReference??e.referenceElement,floatingElement:e=>e.floatingElement,floatingId:e=>e.floatingId},Ui=class extends Tr{constructor(t){let{syncOnly:a,nested:o,onOpenChange:r,triggerElements:n,...s}=t;super({...s,positionReference:s.referenceElement,domReferenceElement:s.referenceElement},{onOpenChange:r,dataRef:{current:{}},events:r2(),nested:o,triggerElements:n},y7),this.syncOnly=a}syncOpenEvent=(t,a)=>{(!t||!this.state.open||a!=null&&TB(a))&&(this.context.dataRef.current.openEvent=t?a:void 0)};dispatchOpenChange=(t,a)=>{this.syncOpenEvent(t,a.event);let o={open:t,reason:a.reason,nativeEvent:a.event,nested:this.context.nested,triggerElement:a.trigger};this.context.events.emit("openchange",o)};setOpen=(t,a)=>{if(this.syncOnly){this.context.onOpenChange?.(t,a);return}this.dispatchOpenChange(t,a),this.context.onOpenChange?.(t,a)}};function Z2(e){let{popupStore:t,treatPopupAsFloatingElement:a=!1,floatingRootContext:o,floatingId:r,nested:n,onOpenChange:s}=e,i=t.useState("open"),l=t.useState("activeTriggerElement"),u=t.useState(a?"popupElement":"positionerElement"),c=t.context.triggerElements,d=s,f=K2.useRef(null);o===void 0&&f.current===null&&(f.current=new Ui({open:i,transitionStatus:void 0,referenceElement:l,floatingElement:u,triggerElements:c,onOpenChange:d,floatingId:r,syncOnly:!0,nested:n}));let m=o??f.current;return t.useSyncedValue("floatingId",r),G(()=>{let p={open:i,floatingId:r,referenceElement:l,floatingElement:u};we(l)&&(p.domReferenceElement=l),m.state.positionReference===m.state.referenceElement&&(p.positionReference=l),m.update(p)},[i,r,l,u,m]),m.context.onOpenChange=d,m.context.nested=n,m}var sI=T(M(),1);function ko(e,t=!1,a=!1,o=!1){let[r,n]=sI.useState(e&&t?"idle":void 0),[s,i]=sI.useState(e&&!o);return e&&!s&&(i(!0),n("starting")),!e&&s&&r!=="ending"&&!a&&n("ending"),!e&&!s&&r==="ending"&&n(void 0),G(()=>{if(!e&&s&&r!=="ending"&&a){let l=br.request(()=>{n("ending")});return()=>{br.cancel(l)}}},[e,s,r,a]),G(()=>{if(!e||t)return;let l=br.request(()=>{n(void 0)});return()=>{br.cancel(l)}},[t,e]),G(()=>{if(!e||!t)return;e&&s&&r!=="idle"&&n("starting");let l=br.request(()=>{n("idle")});return()=>{br.cancel(l)}},[t,e,s,r]),{mounted:s,setMounted:i,transitionStatus:r}}var Q2=T(M(),1);var iI=T(Zr(),1);var TS=null;function S7(e){if(!TS){let t=[];TS=t,queueMicrotask(()=>{TS=null,iI.flushSync(()=>{for(let a of t)a()})})}TS.push(e)}function Bf(e,t=!1,a=!1){let o=co();return W((r,n=null)=>{o.cancel();let s=Gr(e);if(s==null)return;let i=s,l=()=>{if(!a){iI.flushSync(r);return}S7(()=>{n?.aborted||r()})};if(typeof i.getAnimations!="function"||globalThis.BASE_UI_ANIMATIONS_DISABLED){r();return}function u(){Promise.all(i.getAnimations().map(c=>c.finished)).then(()=>{n?.aborted||l()},()=>{if(n?.aborted)return;if(i.getAnimations().some(d=>d.pending||d.playState!=="finished")){u();return}l()})}if(t){let c=hu;if(!i.hasAttribute(c)){o.request(u);return}let d=new MutationObserver(()=>{i.hasAttribute(c)||(d.disconnect(),u())});d.observe(i,{attributes:!0,attributeFilter:[c]}),n?.addEventListener("abort",()=>d.disconnect(),{once:!0});return}o.request(u)})}function Ra(e){let{enabled:t=!0,open:a,ref:o,batch:r=!1,onComplete:n}=e,s=W(n),i=Bf(o,a,r);Q2.useEffect(()=>{if(!t)return;let l=new AbortController;return i(s,l.signal),()=>{l.abort()}},[t,a,s,i])}var Ff={tabIndex:-1,[Vp]:""};function eF(e){return t=>t==="touch"?e.current:!0}function IS(e,t=!1){let a=ki(),o=zi()!=null,r=at(()=>e(a,o)).current;return Z2({popupStore:r,treatPopupAsFloatingElement:t,floatingRootContext:r.state.floatingRootContext,floatingId:a,nested:o,onOpenChange:r.setOpen}),r}function wS({handle:e,store:t}){return G(()=>e.attachStore(t),[e,t]),null}function J2(e){let t=e.context.triggerElements.size;e.select("open")&&e.state.triggerCount!==t&&e.set("triggerCount",t)}function b7(e,t){let a=lI.useRef(null);return W(o=>{let r=a.current;if(r!==null){if(r.element===o&&r.store===t&&r.id===e)return;a.current=null;let n=r.store;n.context.triggerElements.getById(r.id)===r.element&&(n.context.triggerElements.delete(r.id),J2(n))}o!==null&&e!==void 0&&(a.current={store:t,id:e,element:o},t.context.triggerElements.add(e,o),J2(t))})}function uI(e,t,a,o=!1){let r=e.preventUnmountingOnClose;t?r=!1:o&&(r=!0);let n=a?.id??null,s=e.activeTriggerId,i=e.activeTriggerElement;return(n||t)&&(s=n,i=a??null),{open:t,preventUnmountingOnClose:r,activeTriggerId:s,activeTriggerElement:i}}function v7(e){let t=!1;return e.preventUnmountOnClose=()=>{t=!0},()=>t}function tF(e,t,a,o={}){let r=a.reason,n=r===ne.triggerHover,s=t&&r===ne.triggerFocus,i=!t&&(r===ne.triggerPress||r===ne.escapeKey),l=v7(a);if(e.context.onOpenChange?.(t,a),a.isCanceled)return;o.onBeforeDispatch?.(),e.state.floatingRootContext.dispatchOpenChange(t,a);let u=()=>{let c=uI(e.state,t,a.trigger,l()),d={...o.extraState,...c};s?d.instantType="focus":i?d.instantType="dismiss":n&&(d.instantType=void 0),e.update(d)};n?$2.flushSync(u):u()}function ES(e,t,a,o){let r=a.useState("isMountedByTrigger",e),n=b7(e,a),s=W(l=>{let u=a.select("open"),c=a.select("activeTriggerId");if(c===e){let d={activeTriggerElement:l,...u?o:null};a.update(d);return}if(c==null&&u){let d={activeTriggerId:e??null,activeTriggerElement:l,...o};a.update(d)}}),i=W(l=>{n(l),l&&s(l)});return G(()=>(i(t.current),()=>i(null)),[i,t,a,e]),G(()=>{if(r){let l={activeTriggerElement:t.current,...o};a.update(l)}},[r,a,t,...Object.values(o)]),{registerTrigger:i,isMountedByThisTrigger:r}}function AS(e,t={}){let{closeOnActiveTriggerUnmount:a=!1}=t,o=lI.useRef(null),r=e.useState("open"),n=e.useState("triggerCount"),s=e.useState("activeTriggerId"),i=e.useState("activeTriggerElement");G(()=>{if(!r){o.current=null,e.state.triggerCount!==0&&e.set("triggerCount",0);return}let l=e.context.triggerElements.size,u={};e.state.triggerCount!==l&&(u.triggerCount=l);let c=e.select("activeTriggerId"),d=null;if(c){let f=e.context.triggerElements.getById(c);if(f)o.current=c,f!==e.state.activeTriggerElement&&(u.activeTriggerElement=f);else{for(let[m,p]of e.context.triggerElements.entries())if(p===e.state.activeTriggerElement){u.activeTriggerId=m,u.activeTriggerElement=p,o.current=m;break}u.activeTriggerId===void 0&&(o.current===c?d=c:o.current=null)}}else o.current=null;if(!d&&!c&&l===1){let f=e.context.triggerElements.entries().next();if(!f.done){let[m,p]=f.value;u.activeTriggerId=m,u.activeTriggerElement=p,o.current=m}}(u.triggerCount!==void 0||u.activeTriggerId!==void 0||u.activeTriggerElement!==void 0)&&e.update(u),d&&a&&queueMicrotask(()=>{if(e.select("open")&&e.select("activeTriggerId")===d&&!e.context.triggerElements.getById(d)){let f=he(ne.none);e.setOpen(!1,f),f.isCanceled||e.update({activeTriggerId:null,activeTriggerElement:null})}})},[r,e,n,s,i,a])}function DS(e,t,a,o){let{mounted:r,setMounted:n,transitionStatus:s}=ko(e,!1,!1,o),i=t.useState("preventUnmountingOnClose"),l=e?!1:i;t.useSyncedValues({mounted:r,transitionStatus:s,preventUnmountingOnClose:l});let u=W(()=>{n(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1,preventUnmountingOnClose:!1}),a?.(),t.context.onOpenChangeComplete?.(!1)});return Ra({enabled:r&&!e&&!l,open:e,ref:t.context.popupRef,onComplete(){e||u()}}),{forceUnmount:u,transitionStatus:s}}function MS(e,t){e.useSyncedValues(t),G(()=>()=>{e.update({activeTriggerProps:Ke,inactiveTriggerProps:Ke,popupProps:Ke})},[e])}function aF(e,t){G(()=>{!t&&e.state.openMethod!==null&&e.set("openMethod",null)},[t,e]),G(()=>()=>{e.state.openMethod!==null&&e.set("openMethod",null)},[e])}var wn=class{constructor(){this.idMap=new Map}add(t,a){this.idMap.set(t,a)}delete(t){this.idMap.delete(t)}hasElement(t){for(let a of this.idMap.values())if(a===t)return!0;return!1}hasMatchingElement(t){for(let a of this.idMap.values())if(t(a))return!0;return!1}getById(t){return this.idMap.get(t)}entries(){return this.idMap.entries()}elements(){return this.idMap.values()}get size(){return this.idMap.size}};function PS(e,t,a=!1){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:new Ui({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:a,onOpenChange:void 0}),floatingId:t,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:Ke,inactiveTriggerProps:Ke,popupProps:Ke}}var ah=e=>e.triggerIdProp??e.activeTriggerId,cI=e=>e.openProp??e.open,oF=e=>(e.popupElement?.id??e.floatingId)||void 0;function rF(e,t){return t!==void 0&&cI(e)&&ah(e)===t}function C7(e,t){return rF(e,t)?!0:t!==void 0&&cI(e)&&ah(e)==null&&e.triggerCount===1}var OS={open:cI,mounted:e=>e.mounted,transitionStatus:e=>e.transitionStatus,floatingRootContext:e=>e.floatingRootContext,triggerCount:e=>e.triggerCount,preventUnmountingOnClose:e=>e.preventUnmountingOnClose,payload:e=>e.payload,activeTriggerId:ah,activeTriggerElement:e=>e.mounted?e.activeTriggerElement:null,popupId:oF,isTriggerActive:(e,t)=>t!==void 0&&ah(e)===t,isOpenedByTrigger:(e,t)=>rF(e,t),isMountedByTrigger:(e,t)=>t!==void 0&&ah(e)===t&&e.mounted,triggerProps:(e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps,triggerPopupId:(e,t)=>C7(e,t)?oF(e):void 0,popupProps:e=>e.popupProps,popupElement:e=>e.popupElement,positionerElement:e=>e.positionerElement};var fI=T(M(),1),nF=T(eh(),1);function kS(e){let t=fI.useCallback(o=>e===void 0?Ve:e.subscribeStore(o),[e]),a=fI.useCallback(()=>e===void 0?void 0:e.store,[e]);return(0,nF.useSyncExternalStore)(t,a,()=>e?.serverStore)}function dI(e){let{open:t=!1,onOpenChange:a,elements:o={}}=e,r=ki(),n=zi()!=null,s=at(()=>new Ui({open:t,transitionStatus:void 0,onOpenChange:a,referenceElement:o.reference??null,floatingElement:o.floating??null,triggerElements:new wn,floatingId:r,syncOnly:!1,nested:n})).current;return G(()=>{let i={open:t,floatingId:r};o.reference!==void 0&&(i.referenceElement=o.reference,i.domReferenceElement=we(o.reference)?o.reference:null),o.floating!==void 0&&(i.floatingElement=o.floating),s.update(i)},[t,r,o.reference,o.floating,s]),s.context.onOpenChange=a,s.context.nested=n,s}function sF(e){return L7(e,e.rootContext)}function L7(e,t){let{nodeId:a,externalTree:o}=e,r=t.useState("referenceElement"),n=t.useState("floatingElement"),s=t.useState("domReferenceElement"),i=t.useState("open"),l=t.useState("floatingId"),[u,c]=Ja.useState(null),[d,f]=Ja.useState(void 0),[m,p]=Ja.useState(void 0),y=Ja.useRef(null),b=Rr(o),g=Ja.useMemo(()=>({reference:r,floating:n,domReference:s}),[r,n,s]),h=N2({...e,elements:{...g,...u&&{reference:u}}}),x=we(d)?d:null,S=m===void 0?t.state.floatingElement:m;t.useSyncedValue("referenceElement",d??null),t.useSyncedValue("domReferenceElement",d===void 0?s:x),t.useSyncedValue("floatingElement",S);let v=Ja.useCallback(A=>{let N=we(A)?{getBoundingClientRect:()=>A.getBoundingClientRect(),getClientRects:()=>A.getClientRects(),contextElement:A}:A;c(N),h.refs.setReference(N)},[h.refs]),R=Ja.useCallback(A=>{(we(A)||A===null)&&(y.current=A,f(A)),(we(h.refs.reference.current)||h.refs.reference.current===null||A!==null&&!we(A))&&h.refs.setReference(A)},[h.refs,f]),L=Ja.useCallback(A=>{p(A),h.refs.setFloating(A)},[h.refs]),C=Ja.useMemo(()=>({...h.refs,setReference:R,setFloating:L,setPositionReference:v,domReference:y}),[h.refs,R,L,v]),E=Ja.useMemo(()=>({...h.elements,domReference:s}),[h.elements,s]),I=Ja.useMemo(()=>({...h,dataRef:t.context.dataRef,open:i,onOpenChange:t.setOpen,events:t.context.events,floatingId:l,refs:C,elements:E,nodeId:a,rootStore:t}),[h,C,E,a,t,i,l]);return G(()=>{s&&(y.current=s)},[s]),G(()=>{t.context.dataRef.current.floatingContext=I;let A=b?.nodesRef.current.find(N=>N.id===a);A&&(A.context=I)}),Ja.useMemo(()=>({...h,context:I,refs:C,elements:E,rootStore:t}),[h,C,E,I,t])}var En=T(M(),1);var mI=ot.os.mac&&ot.engine.webkit;function pI(e,t={}){let{enabled:a=!0,delay:o}=t,r="rootStore"in e?e.rootStore:e,{events:n,dataRef:s}=r.context,i=En.useRef(!1),l=En.useRef(null),u=En.useRef(!0),c=Qe();En.useEffect(()=>{let f=r.select("domReferenceElement");if(!a)return;let m=He(f);function p(){let g=r.select("domReferenceElement");!r.select("open")&&Ue(g)&&g===_t(ve(g))&&(i.current=!0,l.current=g)}function y(){u.current=!0}function b(){u.current=!1}return Ka(Re(m,"blur",p),mI&&Re(m,"keydown",y,!0),mI&&Re(m,"pointerdown",b,!0))},[r,a]),En.useEffect(()=>{if(!a)return;function f(m){if(m.reason===ne.triggerPress||m.reason===ne.escapeKey){let p=r.select("domReferenceElement");we(p)&&(l.current=p,i.current=!0)}}return n.on("openchange",f),()=>{n.off("openchange",f)}},[n,a,r]);let d=En.useMemo(()=>{function f(){i.current=!1,l.current=null}return{onMouseLeave(){f()},onFocus(m){let p=m.currentTarget;if(i.current){if(l.current===p)return;f()}let y=$e(m.nativeEvent);if(we(y)){if(mI&&!m.relatedTarget){if(!u.current&&!vu(y))return}else if(!EB(y))return}let b=Vi(m.relatedTarget,r.context.triggerElements),{nativeEvent:g,currentTarget:h}=m,x=typeof o=="function"?o():o;if(r.select("open")&&b||x===0||x===void 0){r.setOpen(!0,he(ne.triggerFocus,g,h));return}c.start(x,()=>{i.current||r.setOpen(!0,he(ne.triggerFocus,g,h))})},onBlur(m){f();let p=m.relatedTarget,y=m.nativeEvent,b=we(p)&&p.hasAttribute(ds("focus-guard"))&&p.getAttribute("data-type")==="outside";c.start(0,()=>{let g=r.select("domReferenceElement"),h=_t(ve(g));!p&&h===g||ue(s.current.floatingContext?.refs.floating.current,h)||ue(g,h)||b||Vi(p??h,r.context.triggerElements)||r.setOpen(!1,he(ne.triggerFocus,y))})}}},[s,o,r,c]);return En.useMemo(()=>a?{reference:d,trigger:d}:{},[a,d])}var gI=T(M(),1);var hI=class e{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new Wa,this.restTimeout=new Wa,this.handleCloseOptions=void 0}static create(){return new e}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose},NS=new WeakMap;function _f(e){if(!e.performedPointerEventsMutation)return;let t=e.pointerEventsScopeElement;t&&NS.get(t)===e&&(e.pointerEventsScopeElement?.style.removeProperty("pointer-events"),e.pointerEventsReferenceElement?.style.removeProperty("pointer-events"),e.pointerEventsFloatingElement?.style.removeProperty("pointer-events"),NS.delete(t)),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null}function VS(e,t){let{scopeElement:a,referenceElement:o,floatingElement:r}=t,n=NS.get(a);n&&n!==e&&_f(n),_f(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=a,e.pointerEventsReferenceElement=o,e.pointerEventsFloatingElement=r,NS.set(a,e),a.style.pointerEvents="none",o.style.pointerEvents="auto",r.style.pointerEvents="auto"}function zf(e){let t=e.context.dataRef.current,a=at(()=>t.hoverInteractionState??hI.create()).current;return t.hoverInteractionState||(t.hoverInteractionState=a),Ef(t.hoverInteractionState.disposeEffect),t.hoverInteractionState}function xI(e,t={}){let{enabled:a=!0,closeDelay:o=0,nodeId:r}=t,n="rootStore"in e?e.rootStore:e,s=n.useState("open"),i=n.useState("floatingElement"),l=n.useState("domReferenceElement"),{dataRef:u}=n.context,c=Rr(),d=zi(),f=zf(n),m=Qe(),p=W(()=>aS(u.current.openEvent?.type,f.interactedInside)),y=W(()=>AB(u.current.openEvent?.type)),b=W(()=>{_f(f)});G(()=>{s||(f.pointerType=void 0,f.restTimeoutPending=!1,f.interactedInside=!1,b())},[s,f,b]),gI.useEffect(()=>b,[b]),G(()=>{if(a&&s&&f.handleCloseOptions?.blockPointerEvents&&y()&&we(l)&&i){let g=l,h=i,x=ve(i),S=c?.nodesRef.current.find(C=>C.id===d)?.context?.elements.floating;S&&(S.style.pointerEvents="");let v=f.pointerEventsScopeElement!==h?f.pointerEventsScopeElement:null,R=S!==h?S:null,L=f.handleCloseOptions?.getScope?.()??v??R??g.closest("[data-rootownerid]")??x.body;return VS(f,{scopeElement:L,referenceElement:g,floatingElement:h}),()=>{b()}}},[a,s,l,i,f,y,c,d,b]),gI.useEffect(()=>{if(!a)return;function g(){return!!(c&&d&&Lr(c.nodesRef.current,d).length>0)}function h(C){let E=Ur(o,"close",f.pointerType),I=()=>{n.setOpen(!1,he(ne.triggerHover,C)),c?.events.emit("floating.closed",C)};E?f.openChangeTimeout.start(E,I):(f.openChangeTimeout.clear(),I())}function x(C){let E=$e(C);if(!DT(E)){f.interactedInside=!1;return}f.interactedInside=E?.closest("[aria-haspopup]")!=null}function S(){f.openChangeTimeout.clear(),m.clear(),c?.events.off("floating.closed",R),b()}function v(C){if(g()&&c){c.events.on("floating.closed",R);return}if(Vi(C.relatedTarget,n.context.triggerElements))return;let E=u.current.floatingContext?.nodeId??r,I=C.relatedTarget;if(!(c&&E&&we(I)&&Lr(c.nodesRef.current,E,!1).some(N=>ue(N.context?.elements.floating,I)))){if(f.handler){f.handler(C);return}b(),y()&&!p()&&h(C)}}function R(C){!c||!d||g()||m.start(0,()=>{c.events.off("floating.closed",R),n.setOpen(!1,he(ne.triggerHover,C)),c.events.emit("floating.closed",C)})}let L=i;return Ka(L&&Re(L,"mouseenter",S),L&&Re(L,"mouseleave",v),L&&Re(L,"pointerdown",x,!0),()=>{c?.events.off("floating.closed",R)})},[a,i,n,u,o,r,y,p,b,f,c,d,m])}var qi=T(M(),1),iF=T(Zr(),1);var R7={current:null};function yI(e,t={}){let{enabled:a=!0,delay:o=0,handleClose:r=null,mouseOnly:n=!1,restMs:s=0,move:i=!0,triggerElementRef:l=R7,externalTree:u,isActiveTrigger:c=!0,getHandleCloseContext:d,isClosing:f,shouldOpen:m,guardStaleOpen:p=!1}=t,y="rootStore"in e?e.rootStore:e,{dataRef:b,events:g}=y.context,h=Rr(u),x=zf(y),S=qi.useRef(!1),v=pt(r),R=pt(o),L=pt(s),C=pt(a),E=pt(m),I=pt(f),A=W(()=>aS(b.current.openEvent?.type,x.interactedInside)),N=W(()=>E.current?.()!==!1),D=W((z,q,O)=>{let V=y.context.triggerElements;if(V.hasElement(q))return!z||!ue(z,q);if(!we(O))return!1;let w=O;return V.hasMatchingElement(_=>ue(_,w))&&(!z||!ue(z,w))}),F=W(()=>{if(!x.handler)return;ve(y.select("domReferenceElement")).removeEventListener("mousemove",x.handler),x.handler=void 0}),k=W(()=>{_f(x)});return c&&(x.handleCloseOptions=r?.__options),qi.useEffect(()=>F,[F]),qi.useEffect(()=>{if(!a)return;function z(q){q.open?S.current=!1:(S.current=q.reason===ne.triggerHover,F(),x.openChangeTimeout.clear(),x.restTimeout.clear(),x.blockMouseMove=!0,x.restTimeoutPending=!1)}return g.on("openchange",z),()=>{g.off("openchange",z)}},[a,g,x,F]),qi.useEffect(()=>{if(!a)return;function z(U,X=!0){let P=Ur(R.current,"close",x.pointerType);P?x.openChangeTimeout.start(P,()=>{y.setOpen(!1,he(ne.triggerHover,U)),h?.events.emit("floating.closed",U)}):X&&(x.openChangeTimeout.clear(),y.setOpen(!1,he(ne.triggerHover,U)),h?.events.emit("floating.closed",U))}let q=l.current??(c?y.select("domReferenceElement"):null);if(!we(q))return;function O(U){if(x.openChangeTimeout.clear(),x.blockMouseMove=!1,n&&!Jo(x.pointerType))return;let X=MT(L.current),P=Ur(R.current,"open",x.pointerType),H=$e(U),B=U.currentTarget??null,J=y.select("domReferenceElement"),Y=B;if(we(H)&&!y.context.triggerElements.hasElement(H)){for(let pe of y.context.triggerElements.elements())if(ue(pe,H)){Y=pe;break}}we(B)&&we(J)&&!y.context.triggerElements.hasElement(B)&&ue(B,J)&&(Y=J);let te=Y==null?!1:D(J,Y,H),ie=y.select("open"),ce=I.current?.()??y.select("transitionStatus")==="ending",ee=!ie&&ce&&S.current,ae=!te&&we(Y)&&we(J)&&ue(J,Y)&&ee,me=X>0&&!P,ge=te&&(ie||ee)||ae,Ee=!ie||te;if(ge){N()&&y.setOpen(!0,he(ne.triggerHover,U,Y));return}me||(P?x.openChangeTimeout.start(P,()=>{Ee&&N()&&y.setOpen(!0,he(ne.triggerHover,U,Y))}):Ee&&N()&&y.setOpen(!0,he(ne.triggerHover,U,Y)))}function V(U){if(A()){k();return}F();let X=y.select("domReferenceElement"),P=ve(X);x.restTimeout.clear(),x.restTimeoutPending=!1;let H=b.current.floatingContext??d?.();if(Vi(U.relatedTarget,y.context.triggerElements))return;if(v.current&&H){y.select("open")||x.openChangeTimeout.clear();let J=l.current;x.handler=v.current({...H,tree:h,x:U.clientX,y:U.clientY,onClose(){k(),F(),C.current&&!A()&&J===y.select("domReferenceElement")&&z(U,!0)}}),P.addEventListener("mousemove",x.handler),x.handler(U);return}(x.pointerType==="touch"?!ue(y.select("floatingElement"),U.relatedTarget):!0)&&z(U)}function w(U){ue(q,U.relatedTarget)||(x.openChangeTimeout.clear(),x.restTimeout.clear(),x.restTimeoutPending=!1)}let _=p?Re(q,"mouseout",w):void 0;return i?Ka(Re(q,"mousemove",O,{once:!0}),Re(q,"mouseenter",O),Re(q,"mouseleave",V),_):Ka(Re(q,"mouseenter",O),Re(q,"mouseleave",V),_)},[F,k,b,R,y,a,v,x,c,D,A,n,i,L,l,h,C,d,I,N,p]),qi.useMemo(()=>{if(!a)return;function z(q){x.pointerType=q.pointerType}return{onPointerDown:z,onPointerEnter:z,onMouseMove(q){let{nativeEvent:O}=q,V=q.currentTarget,w=y.select("domReferenceElement"),_=y.select("open"),U=D(w,V,q.target);if(n&&!Jo(x.pointerType))return;if(_&&U&&x.handleCloseOptions?.blockPointerEvents){let H=y.select("floatingElement");if(H){let B=x.handleCloseOptions?.getScope?.()??V.ownerDocument.body;VS(x,{scopeElement:B,referenceElement:V,floatingElement:H})}}let X=MT(L.current);if(_&&!U||X===0||!U&&x.restTimeoutPending&&q.movementX**2+q.movementY**2<2)return;x.restTimeout.clear();function P(){if(x.restTimeoutPending=!1,A())return;let H=y.select("open");!x.blockMouseMove&&(!H||U)&&N()&&y.setOpen(!0,he(ne.triggerHover,O,V))}x.pointerType==="touch"?iF.flushSync(()=>{P()}):U&&_?P():(x.restTimeoutPending=!0,x.restTimeout.start(X,P))}}},[a,x,A,D,n,y,L,N])}var Fa=T(M(),1);var T7="Escape";function lF(e){return ot.engine.webkit&&e.movementX===0&&e.movementY===0}function FS(e,t,a){switch(e){case"vertical":return t;case"horizontal":return a;default:return t||a}}function BS(e,t){return FS(t,e===AT||e===eS,e===Bp||e===Fp)}function SI(e,t,a){return FS(t,e===eS,a?e===Bp:e===Fp)||e==="Enter"||e===" "||e===""}function I7(e,t,a){return FS(t,a?e===Bp:e===Fp,e===eS)}function w7(e,t,a,o){let r=a?e===Fp:e===Bp,n=e===AT;return t==="both"||t==="horizontal"&&o?e===T7:FS(t,r,n)}function bI(e,t){let{listRef:a,activeIndex:o,onNavigate:r=()=>{},enabled:n=!0,selectedIndex:s=null,allowEscape:i=!1,loopFocus:l=!1,nested:u=!1,rtl:c=!1,virtual:d=!1,focusItemOnOpen:f="auto",focusItemOnHover:m=!0,openOnArrowKeyDown:p=!0,disabledIndices:y=void 0,orientation:b="vertical",parentOrientation:g,id:h,resetOnPointerLeave:x=!0,externalTree:S,grid:v}=t,R=v!=null,L="rootStore"in e?e.rootStore:e,C=L.useState("open"),E=L.useState("floatingElement"),I=L.useState("domReferenceElement"),A=L.context.dataRef,N=Cu(E),D=zp(I),F=pt(N),k=zi(),z=Rr(S),q=Fa.useRef(f),O=Fa.useRef(s??-1),V=Fa.useRef(null),w=Fa.useRef(!0),_=W(oe=>{r(O.current===-1?null:O.current,oe)}),U=Fa.useRef(!!E),X=Fa.useRef(C),P=Fa.useRef(!1),H=Fa.useRef(!1),B=Fa.useRef(null),J=pt(y),Y=pt(C),te=pt(s),ie=pt(x),ce=co(),ee=co(),ae=W(()=>{function oe(se){d?z?.events.emit("virtualfocus",se):B.current=Of(se,{sync:P.current,preventScroll:!0})}let fe=a.current[O.current],K=H.current;fe&&oe(fe),(P.current?se=>se():se=>ce.request(se))(()=>{let se=a.current[O.current]||fe;if(!se)return;fe||oe(se),le&&(K||!w.current)&&se.scrollIntoView?.({block:"nearest",inline:"nearest"})})});G(()=>{A.current.orientation=b},[A,b]),G(()=>{n&&(C&&E?(O.current=s??-1,q.current&&s!=null&&(H.current=!0,_())):U.current&&(O.current=-1,_()))},[n,C,E,s,_]),G(()=>{if(n){if(!C){P.current=!1;return}if(E)if(o==null){if(P.current=!1,te.current!=null)return;if(U.current&&(O.current=-1,ae()),(!X.current||!U.current)&&q.current&&(V.current!=null||q.current===!0&&V.current==null)){let oe=0,fe=()=>{a.current[0]==null?(oe<2&&(oe?j=>ee.request(j):queueMicrotask)(fe),oe+=1):(O.current=V.current==null||SI(V.current,b,c)||u?Lu(a):Pf(a),V.current=null,_())};fe()}}else _i(a.current,o)||(O.current=o,ae(),H.current=!1)}},[n,C,E,o,te,u,a,b,c,_,ae,ee]),G(()=>{if(!n||E||!z||d||!U.current)return;let oe=z.nodesRef.current,fe=oe.find(se=>se.id===k)?.context?.elements.floating,K=_t(ve(I??fe??null)),j=oe.some(se=>se.context&&ue(se.context.elements.floating,K));fe&&!j&&w.current&&fe.focus({preventScroll:!0})},[n,E,I,z,k,d]),G(()=>{X.current=C,U.current=!!E}),G(()=>{C||(V.current=null,q.current=f)},[C,f]);let me=o!=null,ge=W(oe=>{if(!Y.current)return;let fe=a.current.indexOf(oe.currentTarget);fe!==-1&&(O.current!==fe||o!==fe)&&(O.current=fe,_(oe))}),Ee=W(()=>g??z?.nodesRef.current.find(oe=>oe.id===k)?.context?.dataRef?.current.orientation),pe=W(()=>Lu(a,J.current)),Te=W(oe=>{if(w.current=!1,P.current=!0,oe.which===229||!Y.current&&oe.currentTarget===F.current)return;if(u&&w7(oe.key,b,c,R)){BS(oe.key,Ee())||Mo(oe),L.setOpen(!1,he(ne.listNavigation,oe.nativeEvent)),Ue(I)&&(d?z?.events.emit("virtualfocus",I):I.focus());return}let fe=O.current,K=Lu(a,y),j=Pf(a,y);if(D||(oe.key==="Home"&&(Mo(oe),O.current=K,_(oe)),oe.key==="End"&&(Mo(oe),O.current=j,_(oe))),v!=null){let se=v(oe,O.current,a,b,l,c,y,K,j);if(se!=null&&(O.current=se,_(oe)),b==="both")return}if(BS(oe.key,b)){if(Mo(oe),C&&!d&&_t(oe.currentTarget.ownerDocument)===oe.currentTarget){O.current=SI(oe.key,b,c)?K:j,_(oe);return}SI(oe.key,b,c)?l?fe>=j?i&&fe!==a.current.length?O.current=-1:(P.current=!1,O.current=K):O.current=Cr(a.current,{startingIndex:fe,disabledIndices:y}):O.current=Math.min(j,Cr(a.current,{startingIndex:fe,disabledIndices:y})):l?fe<=K?i&&fe!==-1?O.current=a.current.length:(P.current=!1,O.current=j):O.current=Cr(a.current,{startingIndex:fe,decrement:!0,disabledIndices:y}):O.current=Math.max(K,Cr(a.current,{startingIndex:fe,decrement:!0,disabledIndices:y})),_i(a.current,O.current)&&(O.current=-1),_(oe)}}),le=Fa.useMemo(()=>({onFocus(fe){P.current=!0,ge(fe)},onClick:({currentTarget:fe})=>fe.focus({preventScroll:!0}),onMouseMove(fe){lF(fe)||(P.current=!0,H.current=!1,m&&ge(fe))},onPointerLeave(fe){if(!Y.current||!w.current||fe.pointerType==="touch")return;P.current=!0;let K=fe.relatedTarget;if(!(!m||a.current.includes(K))&&ie.current&&(B.current?.(),B.current=null,O.current=-1,_(fe),!d)){let j=F.current,se=_t(ve(j));j&&ue(j,se)&&j.focus({preventScroll:!0})}}}),[ge,Y,F,m,a,_,ie,d]),Ie=Fa.useMemo(()=>d&&C&&me&&{"aria-activedescendant":`${h}-${o}`},[d,C,me,h,o]),Be=Fa.useMemo(()=>({...D?{}:Ie,onKeyDown(oe){if(oe.key==="Tab"&&oe.shiftKey&&C&&!d){let fe=$e(oe.nativeEvent);if(fe&&!ue(F.current,fe))return;Mo(oe),L.setOpen(!1,he(ne.focusOut,oe.nativeEvent)),Ue(I)&&I.focus();return}Te(oe)},onPointerMove(oe){lF(oe)||(w.current=!0)}}),[Ie,Te,F,D,L,C,d,I]),Oe=Fa.useMemo(()=>{function oe(j){L.setOpen(!0,he(ne.listNavigation,j.nativeEvent,j.currentTarget))}function fe(j){f==="auto"&&Ni(j.nativeEvent)&&(q.current=!d)}function K(j){q.current=f,f==="auto"&&Af(j.nativeEvent)&&(q.current=!0)}return{onKeyDown(j){let se=L.select("open");w.current=!1;let Fe=j.key.startsWith("Arrow"),Vt=I7(j.key,Ee(),c),Jt=BS(j.key,b),Et=(u?Vt:Jt)||j.key==="Enter"||j.key.trim()==="";if(d&&se)return Te(j);if(!(!se&&!p&&Fe)){if(Et){let bt=BS(j.key,Ee());V.current=u&&bt?null:j.key}if(u){Vt&&(Mo(j),se?(O.current=pe(),_(j)):oe(j));return}Jt&&(te.current!=null&&(O.current=te.current),Mo(j),!se&&p?oe(j):Te(j),se&&_(j))}},onFocus(j){L.select("open")&&!d&&(O.current=-1,_(j))},onPointerDown:K,onPointerEnter:K,onMouseDown:fe,onClick:fe}},[Te,f,pe,u,_,L,p,b,Ee,c,te,d]),ut=Fa.useMemo(()=>({...Ie,...Oe}),[Ie,Oe]);return Fa.useMemo(()=>n?{reference:ut,floating:Be,item:le,trigger:Oe}:{},[n,ut,Be,Oe,le])}var Mu=T(M(),1);function vI(e,t){let{listRef:a,elementsRef:o,activeIndex:r,onMatch:n,disabledIndices:s,onTyping:i,enabled:l=!0,resetMs:u=750,selectedIndex:c=null}=t,d="rootStore"in e?e.rootStore:e,f=d.useState("open"),m=Qe(),p=Mu.useRef(""),y=Mu.useRef(c??r??-1),b=Mu.useRef(null),g=W(S=>{function v(F){return o?.current[F]}function R(F){let k=v(F);return k&&!Ru(k)||k?.matches(":disabled")?!1:s==null||!fs(Io,F,s)}function L(F,k,z=0){if(F.length===0)return-1;let q=(z%F.length+F.length)%F.length,O=k.toLowerCase();for(let V=0;V<F.length;V+=1){let w=(q+V)%F.length;if(!(!F[w]?.toLowerCase().startsWith(O)||!R(w)))return w}return-1}let C=a.current;if(p.current.length>0&&S.key===" "&&(Mo(S),i?.(!0)),p.current.length>0&&p.current[0]!==" "&&L(C,p.current)===-1&&S.key!==" "&&i?.(!1),C==null||S.key.length!==1||S.ctrlKey||S.metaKey||S.altKey)return;f&&S.key!==" "&&(Mo(S),i?.(!0));let E=p.current==="";E&&(y.current=c??r??-1),C.every((F,k)=>F&&R(k)?F[0]?.toLowerCase()!==F[1]?.toLowerCase():!0)&&p.current===S.key&&(p.current="",y.current=b.current),p.current+=S.key,m.start(u,()=>{p.current="",y.current=b.current,i?.(!1)});let N=((E?c??r??-1:y.current)??0)+1,D=L(C,p.current,N);D!==-1?(n?.(D),b.current=D):S.key!==" "&&(p.current="",i?.(!1))}),h=W(S=>{let v=S.relatedTarget,R=d.select("domReferenceElement"),L=d.select("floatingElement");ue(R,v)||ue(L,v)||(m.clear(),p.current="",y.current=b.current,i?.(!1))});G(()=>{!f&&c!==null||(m.clear(),b.current=null,p.current!==""&&(p.current=""))},[f,c,m]);let x=Mu.useMemo(()=>({onKeyDown:g,onBlur:h}),[g,h]);return Mu.useMemo(()=>l?{reference:x,floating:x}:{},[l,x])}var uF=.1,E7=uF*uF,xt=.5;function _S(e,t,a,o,r,n){return o>=t!=n>=t&&e<=(r-a)*(t-o)/(n-o)+a}function zS(e,t,a,o,r,n,s,i,l,u){let c=!1;return _S(e,t,a,o,r,n)&&(c=!c),_S(e,t,r,n,s,i)&&(c=!c),_S(e,t,s,i,l,u)&&(c=!c),_S(e,t,l,u,a,o)&&(c=!c),c}function A7(e,t,a){return e>=a.x&&e<=a.x+a.width&&t>=a.y&&t<=a.y+a.height}function HS(e,t,a,o,r,n){let s=Math.min(a,r),i=Math.max(a,r),l=Math.min(o,n),u=Math.max(o,n);return e>=s&&e<=i&&t>=l&&t<=u}function CI(e={}){let{blockPointerEvents:t=!1}=e,a=new Wa,o=({x:r,y:n,placement:s,elements:i,onClose:l,nodeId:u,tree:c})=>{let d=s?.split("-")[0],f=!1,m=null,p=null,y=typeof performance<"u"?performance.now():0;function b(h,x){let S=performance.now(),v=S-y;if(m===null||p===null||v===0)return m=h,p=x,y=S,!1;let R=h-m,L=x-p,C=R*R+L*L,E=v*v*E7;return m=h,p=x,y=S,C<E}function g(){a.clear(),l()}return function(x){a.clear();let S=i.domReference,v=i.floating;if(!S||!v||d==null||r==null||n==null)return;let{clientX:R,clientY:L}=x,C=$e(x),E=x.type==="mouseleave",I=ue(v,C),A=ue(S,C);if(I&&(f=!0,!E))return;if(A&&(f=!1,!E)){f=!0;return}if(E&&we(x.relatedTarget)&&ue(v,x.relatedTarget))return;function N(){return!!(c&&Lr(c.nodesRef.current,u).length>0)}function D(){N()||g()}if(N())return;let F=S.getBoundingClientRect(),k=v.getBoundingClientRect(),z=r>k.right-k.width/2,q=n>k.bottom-k.height/2,O=k.width>F.width,V=k.height>F.height,w=(O?F:k).left,_=(O?F:k).right,U=(V?F:k).top,X=(V?F:k).bottom;if(d==="top"&&n>=F.bottom-1||d==="bottom"&&n<=F.top+1||d==="left"&&r>=F.right-1||d==="right"&&r<=F.left+1){D();return}let P=!1;switch(d){case"top":P=HS(R,L,w,F.top+1,_,k.bottom-1);break;case"bottom":P=HS(R,L,w,k.top+1,_,F.bottom-1);break;case"left":P=HS(R,L,k.right-1,X,F.left+1,U);break;case"right":P=HS(R,L,F.right-1,X,k.left+1,U);break;default:}if(P)return;if(f&&!A7(R,L,F)){D();return}if(!E&&b(R,L)){D();return}let H=!1;switch(d){case"top":{let B=O?xt/2:xt*4,J=O||z?r+B:r-B,Y=O?r-B:z?r+B:r-B,te=n+xt+1,ie=z||O?k.bottom-xt:k.top,ce=z?O?k.bottom-xt:k.top:k.bottom-xt;H=zS(R,L,J,te,Y,te,k.left,ie,k.right,ce);break}case"bottom":{let B=O?xt/2:xt*4,J=O||z?r+B:r-B,Y=O?r-B:z?r+B:r-B,te=n-xt,ie=z||O?k.top+xt:k.bottom,ce=z?O?k.top+xt:k.bottom:k.top+xt;H=zS(R,L,J,te,Y,te,k.left,ie,k.right,ce);break}case"left":{let B=V?xt/2:xt*4,J=V||q?n+B:n-B,Y=V?n-B:q?n+B:n-B,te=r+xt+1,ie=q||V?k.right-xt:k.left,ce=q?V?k.right-xt:k.left:k.right-xt;H=zS(R,L,ie,k.top,ce,k.bottom,te,J,te,Y);break}case"right":{let B=V?xt/2:xt*4,J=V||q?n+B:n-B,Y=V?n-B:q?n+B:n-B,te=r-xt,ie=q||V?k.left+xt:k.right,ce=q?V?k.left+xt:k.right:k.left+xt;H=zS(R,L,te,J,te,Y,ie,k.top,ce,k.bottom);break}default:}H?f||a.start(40,D):D()}};return o.__options={...e,blockPointerEvents:t},o}var US=T(M(),1),LI=US.createContext(void 0);function qS(){let e=US.useContext(LI);if(e===void 0)throw new Error(Me(26));return e}var jS="ArrowUp",XS="ArrowDown",YS="ArrowLeft",WS="ArrowRight",KS="Home",ZS="End";var Hf=new Set([jS,XS,YS,WS,KS,ZS]),D7="Shift",fF=[D7,"Control","Alt","Meta"];function M7(e){return Ue(e)&&e.tagName==="INPUT"}function RI(e){return!!(M7(e)&&e.selectionStart!=null||Ue(e)&&e.tagName==="TEXTAREA")}function TI(e,t,a,o){if(!e||!t||!t.scrollTo)return;let r=e.scrollLeft,n=e.scrollTop,s=e.clientWidth<e.scrollWidth,i=e.clientHeight<e.scrollHeight;if(s&&o!=="vertical"){let l=cF(e,t,"left"),u=GS(e),c=GS(t);a==="ltr"&&(l+t.offsetWidth+c.scrollMarginRight>e.scrollLeft+e.clientWidth-u.scrollPaddingRight?r=l+t.offsetWidth+c.scrollMarginRight-e.clientWidth+u.scrollPaddingRight:l-c.scrollMarginLeft<e.scrollLeft+u.scrollPaddingLeft&&(r=l-c.scrollMarginLeft-u.scrollPaddingLeft)),a==="rtl"&&(l-c.scrollMarginLeft<e.scrollLeft+u.scrollPaddingLeft?r=l-c.scrollMarginLeft-u.scrollPaddingLeft:l+t.offsetWidth+c.scrollMarginRight>e.scrollLeft+e.clientWidth-u.scrollPaddingRight&&(r=l+t.offsetWidth+c.scrollMarginRight-e.clientWidth+u.scrollPaddingRight))}if(i&&o!=="horizontal"){let l=cF(e,t,"top"),u=GS(e),c=GS(t);l-c.scrollMarginTop<e.scrollTop+u.scrollPaddingTop?n=l-c.scrollMarginTop-u.scrollPaddingTop:l+t.offsetHeight+c.scrollMarginBottom>e.scrollTop+e.clientHeight-u.scrollPaddingBottom&&(n=l+t.offsetHeight+c.scrollMarginBottom-e.clientHeight+u.scrollPaddingBottom)}e.scrollTo({left:r,top:n,behavior:"auto"})}function cF(e,t,a){let o=a==="left"?"offsetLeft":"offsetTop",r=0;for(;t.offsetParent&&(r+=t[o],t.offsetParent!==e);)t=t.offsetParent;return r}function GS(e){let t=getComputedStyle(e);return{scrollMarginTop:parseFloat(t.scrollMarginTop)||0,scrollMarginRight:parseFloat(t.scrollMarginRight)||0,scrollMarginBottom:parseFloat(t.scrollMarginBottom)||0,scrollMarginLeft:parseFloat(t.scrollMarginLeft)||0,scrollPaddingTop:parseFloat(t.scrollPaddingTop)||0,scrollPaddingRight:parseFloat(t.scrollPaddingRight)||0,scrollPaddingBottom:parseFloat(t.scrollPaddingBottom)||0,scrollPaddingLeft:parseFloat(t.scrollPaddingLeft)||0}}var dF="--nested-dialogs";var Mve=xu.open,Pve=xu.closed,Ove=xu.startingStyle,kve=xu.endingStyle;var mF="data-nested-dialog-open";var QS={...Hr,...Ya,nestedDialogOpen(e){return e?{[mF]:""}:null}};var hF=T(Q(),1),gF=pF.forwardRef(function(t,a){let{render:o,className:r,style:n,finalFocus:s,initialFocus:i,...l}=t,u=La(),c=u.useState("descriptionElementId"),d=u.useState("disablePointerDismissal"),f=u.useState("floatingRootContext"),m=u.useState("popupProps"),p=u.useState("modal"),y=u.useState("mounted"),b=u.useState("nested"),g=u.useState("nestedOpenDialogCount"),h=u.useState("open"),x=u.useState("openMethod"),S=u.useState("titleElementId"),v=u.useState("transitionStatus"),R=u.useState("role"),L=f.useState("floatingId");qS(),Ra({open:h,ref:u.context.popupRef,onComplete(){h&&u.context.onOpenChangeComplete?.(!0)}});let C=i===void 0?eF(u.context.popupRef):i,E=g>0,I=u.useStateSetter("popupElement"),N=$("div",t,{state:{open:h,nested:b,transitionStatus:v,nestedDialogOpen:E},props:[m,{id:L,"aria-labelledby":S,"aria-describedby":c,role:R,...Ff,hidden:!y,onKeyDown(D){Hf.has(D.key)&&D.stopPropagation()},style:{[dF]:g}},l],ref:[a,u.context.popupRef,I],stateAttributesMapping:QS});return(0,hF.jsx)(Kp,{context:f,openInteractionType:x,disabled:!y,closeOnFocusOut:!d,initialFocus:C,returnFocus:s,modal:p!==!1,restoreFocus:"popup",children:N})});var SF=T(M(),1);function Gi(e){return Gc(19)?e:e?"true":void 0}var xF=T(M(),1),yF=T(Q(),1),JS=xF.forwardRef(function(t,a){let{cutout:o,...r}=t,n;if(o){let s=o.getBoundingClientRect();n=`polygon(0% 0%,100% 0%,100% 100%,0% 100%,0% 0%,${s.left}px ${s.top}px,${s.left}px ${s.bottom}px,${s.right}px ${s.bottom}px,${s.right}px ${s.top}px,${s.left}px ${s.top}px)`}return(0,yF.jsx)("div",{ref:a,role:"presentation","data-base-ui-inert":"",...r,style:{position:"fixed",inset:0,userSelect:"none",WebkitUserSelect:"none",clipPath:n}})});var oh=T(Q(),1),bF=SF.forwardRef(function(t,a){let{keepMounted:o=!1,...r}=t,n=La(),s=n.useState("mounted"),i=n.useState("modal"),l=n.useState("open");return s||o?(0,oh.jsx)(LI.Provider,{value:o,children:(0,oh.jsxs)(Yp,{ref:a,...r,children:[s&&i===!0&&(0,oh.jsx)(JS,{ref:n.context.internalBackdropRef,inert:Gi(!l)}),t.children]})}):null});var DF=T(M(),1);var wI=T(M(),1);var vF={},CF={},LF="";function $S(e,t){return pu(e)?e:t}function RF(e,t,a){return/hidden|clip/.test(e.getComputedStyle($S(t,a)).overflowY)}function k7(e){if(typeof document>"u")return!1;let t=ve(e);return He(t).innerWidth-t.documentElement.clientWidth>0}function N7(e){if(!(typeof CSS<"u"&&CSS.supports&&CSS.supports("scrollbar-gutter","stable"))||typeof document>"u")return!1;let a=ve(e),o=a.documentElement,r=a.body,n=$S(o,r),s=n.style.overflowY,i=o.style.scrollbarGutter;o.style.scrollbarGutter="stable",n.style.overflowY="scroll";let l=n.offsetWidth;n.style.overflowY="hidden";let u=n.offsetWidth;return n.style.overflowY=s,o.style.scrollbarGutter=i,l===u}function V7(e){let t=ve(e),a=t.documentElement,o=t.body,r=$S(a,o),n={overflowY:r.style.overflowY,overflowX:r.style.overflowX};return Object.assign(r.style,{overflowY:"hidden",overflowX:"hidden"}),()=>{Object.assign(r.style,n)}}function B7(e){let t=ve(e),a=t.documentElement,o=t.body,r=He(a),n=0,s=0,i=!1,l=br.create();if(ot.engine.webkit&&(r.visualViewport?.scale??1)!==1)return()=>{};function u(){let m=r.getComputedStyle(a),p=r.getComputedStyle(o),g=(m.scrollbarGutter||"").includes("both-edges")?"stable both-edges":"stable";n=a.scrollTop,s=a.scrollLeft,vF={scrollbarGutter:a.style.scrollbarGutter,overflowY:a.style.overflowY,overflowX:a.style.overflowX},LF=a.style.scrollBehavior,CF={position:o.style.position,height:o.style.height,width:o.style.width,boxSizing:o.style.boxSizing,overflowY:o.style.overflowY,overflowX:o.style.overflowX,scrollBehavior:o.style.scrollBehavior};let h=a.scrollHeight>a.clientHeight,x=a.scrollWidth>a.clientWidth,S=m.overflowY==="scroll"||p.overflowY==="scroll",v=m.overflowX==="scroll"||p.overflowX==="scroll",R=Math.max(0,r.innerWidth-o.clientWidth),L=Math.max(0,r.innerHeight-o.clientHeight),C=parseFloat(p.marginTop)+parseFloat(p.marginBottom),E=parseFloat(p.marginLeft)+parseFloat(p.marginRight),I=$S(a,o);if(i=N7(e),i){a.style.scrollbarGutter=g,I.style.overflowY="hidden",I.style.overflowX="hidden";return}Object.assign(a.style,{scrollbarGutter:g,overflowY:"hidden",overflowX:"hidden"}),(h||S)&&(a.style.overflowY="scroll"),(x||v)&&(a.style.overflowX="scroll"),Object.assign(o.style,{position:"relative",height:C||L?`calc(100dvh - ${C+L}px)`:"100dvh",width:E||R?`calc(100vw - ${E+R}px)`:"100vw",boxSizing:"border-box",overflowY:"hidden",overflowX:"hidden",scrollBehavior:"unset"}),o.scrollTop=n,o.scrollLeft=s,a.setAttribute("data-base-ui-scroll-locked",""),a.style.scrollBehavior="unset"}function c(){Object.assign(a.style,vF),Object.assign(o.style,CF),i||(a.scrollTop=n,a.scrollLeft=s,a.removeAttribute("data-base-ui-scroll-locked"),a.style.scrollBehavior=LF)}function d(){c(),l.request(u)}u();let f=Re(r,"resize",d);return()=>{l.cancel(),c(),typeof r.removeEventListener=="function"&&f()}}var II=class{lockCount=0;restore=null;timeoutLock=Wa.create();timeoutUnlock=Wa.create();acquire(t){return this.lockCount+=1,this.lockCount===1&&this.restore===null&&this.timeoutLock.start(0,()=>this.lock(t)),this.release}release=()=>{this.lockCount-=1,this.lockCount===0&&this.restore&&this.timeoutUnlock.start(0,this.unlock)};unlock=()=>{this.lockCount===0&&this.restore&&(this.restore?.(),this.restore=null)};lock(t){if(this.lockCount===0||this.restore!==null)return;let a=ve(t),o=a.documentElement,r=a.body,n=He(o);if(RF(n,o,r)){let i=new n.MutationObserver(()=>{RF(n,o,r)||(i.disconnect(),this.restore=null,this.lock(t))}),l={attributes:!0};i.observe(o,l),i.observe(r,l),this.restore=()=>i.disconnect();return}let s=ot.os.ios||!k7(t);this.restore=s?V7(t):B7(t)}},F7=new II;function eb(e=!0,t=null){G(()=>{if(e)return F7.acquire(t)},[e,t])}function TF({store:e,parentContext:t,isDrawer:a}){let o=e.useState("open"),r=e.useState("disablePointerDismissal"),n=e.useState("modal"),s=e.useState("popupElement"),i=e.useState("floatingRootContext"),[l,u]=wI.useState(0),[c,d]=wI.useState(0),f=l===0,m=Eu(i,{outsidePressEvent(){return e.context.internalBackdropRef.current||e.context.backdropRef.current?"intentional":{mouse:n==="trap-focus"?"sloppy":"intentional",touch:"sloppy"}},outsidePress(p){if(!e.context.outsidePressEnabledRef.current||"button"in p&&p.button!==0)return!1;if("touches"in p){if(p.type==="touchend"){if(p.changedTouches.length!==1||p.touches.length!==0)return!1}else if(p.touches.length!==1)return!1}let y=$e(p);if(f&&!r){if(n){let b=e.context.internalBackdropRef.current,g=e.context.backdropRef.current;return b||g?b===y||g===y||ue(y,s)&&!y?.hasAttribute("data-base-ui-portal"):!0}return!0}return!1},escapeKey:f});return eb(o&&n===!0,s),e.useContextCallback("onNestedDialogOpen",(p,y)=>{u(p),d(y)}),G(()=>(t?.onNestedDialogOpen&&(o?t.onNestedDialogOpen(l+1,c+(a?1:0)):t.onNestedDialogOpen(0,0)),()=>{t?.onNestedDialogOpen&&o&&t.onNestedDialogOpen(0,0)}),[a,o,l,c,t]),MS(e,{activeTriggerProps:m.reference,inactiveTriggerProps:m.trigger,popupProps:m.floating,nestedOpenDialogCount:l,nestedOpenDrawerCount:c}),null}var tb=T(M(),1);var Uf=class extends Tr{setState(t){}update(t){}set(t,a){}notifyAll(){}};var IF={...OS,modal:e=>e.modal,nested:e=>e.nested,nestedOpenDialogCount:e=>e.nestedOpenDialogCount,nestedOpenDrawerCount:e=>e.nestedOpenDrawerCount,disablePointerDismissal:e=>e.disablePointerDismissal,openMethod:e=>e.openMethod,descriptionElementId:e=>e.descriptionElementId,titleElementId:e=>e.titleElementId,viewportElement:e=>e.viewportElement,role:e=>e.role},ab=class extends Tr{constructor(t,a,o){let r=new wn,n=EF(t,r,a,o);super(n,AF(r),IF)}setOpen=(t,a)=>{a.preventUnmountOnClose=()=>{this.set("preventUnmountingOnClose",!0)},!t&&a.trigger==null&&this.state.activeTriggerId!=null&&(a.trigger=this.state.activeTriggerElement??void 0),this.context.onOpenChange?.(t,a),!a.isCanceled&&(this.state.floatingRootContext.dispatchOpenChange(t,a),this.update(uI(this.state,t,a.trigger)))}};function wF(){let e=new wn;return new Uf(Object.freeze(EF(void 0,e)),Object.freeze(AF(e)),IF)}function EF(e,t,a,o=!1){return{...PS(t,a,o),modal:!0,disablePointerDismissal:!1,viewportElement:null,descriptionElementId:void 0,titleElementId:void 0,openMethod:null,nested:!1,nestedOpenDialogCount:0,nestedOpenDrawerCount:0,role:"dialog",...e}}function AF(e){return{popupRef:tb.createRef(),backdropRef:tb.createRef(),internalBackdropRef:tb.createRef(),outsidePressEnabledRef:{current:!0},triggerElements:e,onOpenChange:void 0,onOpenChangeComplete:void 0}}var rh=T(Q(),1);function MF(e,t){let{children:a,open:o,defaultOpen:r=!1,onOpenChange:n,onOpenChangeComplete:s,disablePointerDismissal:i=!1,modal:l=!0,actionsRef:u,handle:c,triggerId:d,defaultTriggerId:f=null}=t,m=e==="drawer",p=e==="alert-dialog",y=p?!0:l,b=p||i,g=p?"alertdialog":"dialog",h=La(!0),x=h!=null,S={modal:y,disablePointerDismissal:b,nested:x,role:g},v=IS((A,N)=>new ab({open:r,openProp:o,activeTriggerId:f,triggerIdProp:d,...S},A,N),!0);v.useControlledProp("openProp",o),v.useControlledProp("triggerIdProp",d),v.useSyncedValues(S),v.useContextCallback("onOpenChange",n),v.useContextCallback("onOpenChangeComplete",s);let R=v.useState("open"),L=v.useState("mounted"),C=v.useState("payload");aF(v,R),AS(v);let{forceUnmount:E}=DS(R,v);DF.useImperativeHandle(u,()=>({unmount:E,close:()=>v.setOpen(!1,he(ne.imperativeAction))}),[E,v]);let I=R||L;return(0,rh.jsxs)(hT.Provider,{value:v,children:[c&&(0,rh.jsx)(wS,{handle:c,store:v}),I&&(0,rh.jsx)(TF,{store:v,parentContext:h?.context,isDrawer:m}),typeof a=="function"?a({payload:C}):a]})}var PF=th(function(t){return MF("dialog",t)});var OF=T(M(),1);var kF=OF.forwardRef(function(t,a){let{render:o,className:r,style:n,children:s,...i}=t,l=qS(),u=La(),c=u.useState("open"),d=u.useState("nested"),f=u.useState("transitionStatus"),m=u.useState("nestedOpenDialogCount"),p=u.useState("mounted"),y=u.useStateSetter("viewportElement"),b=m>0;return $("div",t,{enabled:l||p,state:{open:c,nested:d,transitionStatus:f,nestedDialogOpen:b},ref:[a,y],stateAttributesMapping:QS,props:[{role:"presentation",hidden:!p,style:{pointerEvents:c?void 0:"none"},children:s},i]})});var NF=T(M(),1);var VF=NF.forwardRef(function(t,a){let{render:o,className:r,style:n,id:s,...i}=t,l=La(),u=It(s);return l.useSyncedValueWithCleanup("titleElementId",u),$("h2",t,{ref:a,props:[{id:u},i]})});var zF=T(M(),1);var sh=T(M(),1);var nh=T(M(),1);function BF(e){let t=nh.useRef(""),a=nh.useCallback(r=>{r.defaultPrevented||(t.current=r.pointerType,e(r,r.pointerType))},[e]);return{onClick:nh.useCallback(r=>{if(r.detail===0){e(r,"keyboard");return}"pointerType"in r?e(r,r.pointerType):e(r,t.current),t.current=""},[e]),onPointerDown:a}}var FF=T(M(),1);function qf(e,t){let a=FF.useRef(e),o=W(t);G(()=>{a.current!==e&&o(a.current),a.current=e},[e,o])}function EI(e,t){let a=W((n,s)=>{(typeof e=="function"?e():e)||t(s||(ot.os.ios?"touch":""))}),{onClick:o,onPointerDown:r}=BF(a);return sh.useMemo(()=>({onClick:o,onPointerDown:r}),[o,r])}function _F(e){let[t,a]=sh.useState(null),o=EI(e,a);return qf(e,r=>{r&&!e&&a(null)}),sh.useMemo(()=>({openMethod:t,triggerProps:o}),[t,o])}var HF=vS(function(t,a){let{render:o,className:r,style:n,disabled:s=!1,nativeButton:i=!0,id:l,payload:u,handle:c,...d}=t,f=La(!0),p=kS(c)??f;if(!p)throw new Error(Me(79));let y=It(l),b=p.useState("floatingRootContext"),g=p.useState("isOpenedByTrigger",y),h=p.useState("triggerPopupId",y),x=zF.useRef(null),{registerTrigger:S,isMountedByThisTrigger:v}=ES(y,x,p,{payload:u}),{getButtonProps:R,buttonRef:L}=Qo({disabled:s,native:i}),C=Qp(b),E=EI(()=>p.select("open"),N=>{p.set("openMethod",N)}),I={disabled:s,open:g},A=p.useState("triggerProps",v);return $("button",t,{state:I,ref:[L,a,S,x],props:[C.reference,A,E,{[pS]:"",id:y,"aria-haspopup":"dialog","aria-expanded":g,"aria-controls":h},d,R],stateAttributesMapping:If})});var ih=class extends Nf{constructor(){super(wF(),"Dialog",!1)}open(t){this.openByTrigger(t)}openWithPayload(t){let a=this.attachedStore;a!==null&&(a.set("payload",t),a.setOpen(!0,he(ne.imperativeAction)))}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}};function UF(){return new ih}var mo=T(Q(),1);function qF({...e}){return(0,mo.jsx)(An.Root,{"data-slot":"sheet",...e})}function _7({...e}){return(0,mo.jsx)(An.Portal,{"data-slot":"sheet-portal",...e})}function z7({className:e,...t}){return(0,mo.jsx)(An.Backdrop,{"data-slot":"sheet-overlay",className:re("fixed inset-0 z-50 bg-black/10 transition-opacity duration-150 data-ending-style:opacity-0 data-starting-style:opacity-0 supports-backdrop-filter:backdrop-blur-xs",e),...t})}function GF({className:e,children:t,side:a="right",showCloseButton:o=!0,...r}){return(0,mo.jsxs)(_7,{children:[(0,mo.jsx)(z7,{}),(0,mo.jsxs)(An.Popup,{"data-slot":"sheet-content","data-side":a,className:re("fixed z-50 flex flex-col gap-4 bg-popover bg-clip-padding text-sm text-popover-foreground shadow-lg transition duration-200 ease-in-out data-ending-style:opacity-0 data-starting-style:opacity-0 data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t data-[side=bottom]:data-ending-style:translate-y-[2.5rem] data-[side=bottom]:data-starting-style:translate-y-[2.5rem] data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-r data-[side=left]:data-ending-style:translate-x-[-2.5rem] data-[side=left]:data-starting-style:translate-x-[-2.5rem] data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-l data-[side=right]:data-ending-style:translate-x-[2.5rem] data-[side=right]:data-starting-style:translate-x-[2.5rem] data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=top]:data-ending-style:translate-y-[-2.5rem] data-[side=top]:data-starting-style:translate-y-[-2.5rem] data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm",e),...r,children:[t,o&&(0,mo.jsxs)(An.Close,{"data-slot":"sheet-close",render:(0,mo.jsx)(Do,{variant:"ghost",className:"absolute top-3 right-3",size:"icon-sm"}),children:[(0,mo.jsx)(Ol,{}),(0,mo.jsx)("span",{className:"sr-only",children:"Close"})]})]})]})}function jF({className:e,...t}){return(0,mo.jsx)("div",{"data-slot":"sheet-header",className:re("flex flex-col gap-0.5 p-4",e),...t})}function XF({className:e,...t}){return(0,mo.jsx)(An.Title,{"data-slot":"sheet-title",className:re("text-base font-medium text-foreground",e),...t})}function YF({className:e,...t}){return(0,mo.jsx)(An.Description,{"data-slot":"sheet-description",className:re("text-sm text-muted-foreground",e),...t})}var Kf={};Aa(Kf,{Indicator:()=>y_,List:()=>R_,Panel:()=>b_,Root:()=>$F,Tab:()=>a_});var Kt=T(M(),1);var Pu=T(M(),1);function Ou({controlled:e,default:t,name:a,state:o="value"}){let{current:r}=Pu.useRef(e!==void 0),[n,s]=Pu.useState(t),i=r&&e!==void 0?e:n,l=Pu.useCallback(u=>{r||s(u)},[]);return[i,l]}var ms=T(M(),1);var ob=T(M(),1),AI=ob.createContext({register:()=>{},unregister:()=>{},subscribeMapChange:()=>()=>{},nextIndexRef:{current:0}});function WF(){return ob.useContext(AI)}var KF=T(Q(),1);function Gf(e){let{children:t,elementsRef:a,labelsRef:o,onMapChange:r}=e,n=W(r),[,s]=ms.useState(!1),i=at(U7).current,l=at(H7).current,u=ms.useRef(0),c=ms.useRef(!0),d=ms.useRef(null),f=ms.useRef(null),m=W(()=>{c.current||(c.current=!0,s(v=>!v))}),p=W((v,R)=>{l.set(v,R),m()}),y=W(v=>{l.delete(v),m()}),b=W(v=>{let R=new Map;return a.current.length=0,o&&(o.current.length=0),v.forEach(L=>{R.set(L.element,{...L.registration.metadata??{},index:L.index}),a.current[L.index]=L.element,o&&(o.current[L.index]=L.registration.label!==void 0?L.registration.label:L.registration.textRef?.current?.textContent??L.element.textContent)}),u.current=a.current.length,R});function g(v){if(f.current?.disconnect(),f.current=null,typeof MutationObserver!="function"||v.length<2)return;let R=new MutationObserver(C=>{if(!j7(C))return;let E=null;for(let I of v)if(I.isConnected){if(E&&ZF(E,I)>0){R.disconnect(),m();return}E=I}});f.current=R;let L=new Set;for(let C=1;C<v.length;C+=1){let E=G7(v[C-1],v[C]);E&&L.add(E)}L.forEach(C=>R.observe(C,{childList:!0}))}let h=W(()=>{let[v,R]=q7(l),L=b(v),C=d.current,E=!C||C.length!==v.length||v.some((I,A)=>{let N=C[A];return I.index!==N.index||I.element!==N.element||I.registration.index!==N.registration.index||I.registration.metadata!==N.registration.metadata});g(R),d.current=v,c.current=!1,E&&(i.forEach(I=>I(L)),n(L))});G(()=>(!c.current&&d.current&&b(d.current),()=>{a.current=[],o&&(o.current=[])}),[a,o,b]),G(()=>{c.current&&h()}),G(()=>()=>{f.current?.disconnect(),c.current=!0},[]);let x=W(v=>(i.add(v),()=>{i.delete(v)})),S=ms.useMemo(()=>({register:p,unregister:y,subscribeMapChange:x,nextIndexRef:u}),[p,y,x,u]);return(0,KF.jsx)(AI.Provider,{value:S,children:t})}function H7(){return new Map}function U7(){return new Set}function q7(e){let t=new Set,a=[],o=[];e.forEach((n,s)=>{if(!s.isConnected)return;let i=n.index,l={index:i??-1,element:s,registration:n};i===null?o.push(l):i>=0&&(t.add(i),a.push(l))});let r=0;return o.sort((n,s)=>ZF(n.element,s.element)),o.forEach(n=>{for(;t.has(r);)r+=1;n.index=r,a.push(n),r+=1}),t.size>0&&a.sort((n,s)=>n.index-s.index),[a,o.map(n=>n.element)]}function G7(e,t){let a=e.parentElement;for(;a&&!a.contains(t);)a=a.parentElement;return a}function j7(e){for(let t of e)for(let a=0;a<t.removedNodes.length;a+=1)if(t.removedNodes[a].isConnected)return!0;return!1}function ZF(e,t){return e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_FOLLOWING?-1:1}var rb=T(M(),1),DI=rb.createContext(void 0);function ji(){let e=rb.useContext(DI);if(e===void 0)throw new Error(Me(64));return e}var QF="data-activation-direction";var Dn={tabActivationDirection:e=>({[QF]:e})};var MI=T(Q(),1),$F=Kt.forwardRef(function(t,a){let{className:o,defaultValue:r=0,onValueChange:n,orientation:s="horizontal",render:i,value:l,style:u,...c}=t,d=t.defaultValue!==void 0,f=Kt.useRef([]),[m,p]=Kt.useState(()=>new Map),[y,b]=Ou({controlled:l,default:r,name:"Tabs",state:"value"}),g=l!==void 0,[h,x]=Kt.useState(()=>new Map),S=Kt.useRef(void 0),v=Kt.useCallback(Y=>PI(h,Y),[h]),[R,L]=Kt.useState(()=>({previousValue:y,tabActivationDirection:"none"})),{previousValue:C,tabActivationDirection:E}=R,I=E,A=!1;C!==y&&(I=JF(C,y,s,h),A=C!=null&&y!=null&&v(y)==null);let N=A?C:y,D=C!==N||E!==I;G(()=>{D&&L({previousValue:N,tabActivationDirection:I})},[N,D,I]);let F=W((Y,te)=>{let ie=JF(y,Y,s,h);te.activationDirection=ie,n?.(Y,te),!te.isCanceled&&b(Y)}),k=W((Y,te)=>{n?.(Y,he(te,void 0,void 0,{activationDirection:"none"}))}),z=W((Y,te)=>(p(ie=>{let ce=new Map(ie);return ce.set(Y,te),ce}),()=>{p(ie=>{if(ie.get(Y)!==te)return ie;let ce=new Map(ie);return ce.delete(Y),ce})})),q=Kt.useCallback(Y=>m.get(Y),[m]),O=Kt.useCallback(Y=>{for(let te of h.values())if(Y===te.value)return te.id},[h]),V=Kt.useMemo(()=>({getTabElementBySelectedValue:v,getTabIdByPanelValue:O,getTabPanelIdByValue:q,onValueChange:F,orientation:s,registerMountedTabPanel:z,setTabMap:x,tabActivationDirection:I,value:y}),[v,O,q,F,s,z,x,I,y]),w=Kt.useMemo(()=>{for(let Y of h.values())if(Y.value===y)return Y},[h,y]),_=Kt.useMemo(()=>{for(let Y of h.values())if(!Y.disabled)return Y.value},[h]),U=Kt.useRef(!d),X=Kt.useRef(r),P=Kt.useRef(d),H=Kt.useRef(!1);G(()=>{if(g)return;function Y(ee,ae){b(ee),L({previousValue:ee,tabActivationDirection:"none"}),k(ee,ae),U.current=!1}if(h.size===0){H.current&&y!==null&&!S.current?.isConnected&&Y(null,ne.missing);return}H.current=!0,S.current=h.keys().next().value;let te=w?.disabled,ie=w==null&&y!==null;if(!te&&y===X.current&&(P.current=!1),P.current&&te&&y===X.current)return;let ce=U.current;if(te||ie){let ee=_??null;if(y===ee){U.current=!1;return}let ae=ne.missing;ce?ae=ne.initial:te&&(ae=ne.disabled),Y(ee,ae);return}ce&&w!=null&&(k(y,ne.initial),U.current=!1)},[_,g,k,w,b,h,y]);let J=$("div",t,{state:{orientation:s,tabActivationDirection:I},ref:a,props:c,stateAttributesMapping:Dn});return(0,MI.jsx)(DI.Provider,{value:V,children:(0,MI.jsx)(Gf,{elementsRef:f,children:J})})});function PI(e,t){for(let[a,o]of e.entries())if(t===o.value)return a;return null}function JF(e,t,a,o){if(e==null||t==null)return"none";let[r,n,s]=a==="horizontal"?["left","left","right"]:["top","up","down"],i=PI(o,e),l=PI(o,t);if(i==null||l==null)return i!==l&&(typeof e=="number"||typeof e=="string")&&typeof e==typeof t?t>e?s:n:"none";let u=i.getBoundingClientRect()[r],c=l.getBoundingClientRect()[r];return c<u?n:c>u?s:"none"}var ps=T(M(),1);var lh="data-composite-item-active";var e_=T(M(),1);var ku=T(M(),1);function jf(e={}){let{guess:t,label:a,metadata:o,textRef:r,index:n}=e,{register:s,unregister:i,subscribeMapChange:l,nextIndexRef:u}=WF(),c=ku.useRef(-1),[d,f]=ku.useState(n==null&&t?()=>{if(c.current===-1){let b=u.current;u.current+=1,c.current=b}return c.current}:-1),m=n??d,p=ku.useRef(null),y=ku.useCallback(b=>{let g=p.current;g&&i(g),p.current=b,b&&s(b,{metadata:o??null,index:n??null,label:a,textRef:r})},[n,s,i,o,a,r]);return G(()=>{if(n==null)return l(b=>{let g=p.current?b.get(p.current)?.index:null;g!=null&&f(g)})},[n,l]),{ref:y,index:m}}function t_(e={}){let{highlightItemOnHover:t,highlightedIndex:a,onHighlightedIndexChange:o}=Rf(),{ref:r,index:n}=jf(e),s=a===n,i=e_.useRef(null),l=mr(r,i);return{compositeProps:{tabIndex:s?0:-1,onFocus(){o(n)},onMouseMove(){let c=i.current;if(!t||!c)return;let d=c.hasAttribute("disabled")||c.ariaDisabled==="true";!s&&!d&&c.focus()}},compositeRef:l,index:n}}var nb=T(M(),1),OI=nb.createContext(void 0);function sb(){let e=nb.useContext(OI);if(e===void 0)throw new Error(Me(65));return e}var a_=ps.forwardRef(function(t,a){let{className:o,disabled:r=!1,render:n,value:s,id:i,nativeButton:l=!0,style:u,...c}=t,{value:d,getTabPanelIdByValue:f,onValueChange:m,orientation:p,tabActivationDirection:y}=ji(),{activateOnFocus:b,registerTabResizeObserverElement:g,tabsListElement:h}=sb(),{highlightedIndex:x,onHighlightedIndexChange:S}=Rf(),v=It(i),R=ps.useMemo(()=>({disabled:r,id:v,value:s}),[r,v,s]),{compositeProps:L,compositeRef:C,index:E}=t_({metadata:R}),I=s===d,A=ps.useRef(!1),N=ps.useRef(null),D=W(H=>{N.current?.(),N.current=H?g(H):null});G(()=>{if(A.current){A.current=!1;return}if(!(I&&E>-1&&x!==E))return;let H=h;if(H!=null){let B=_t(ve(H));if(B&&ue(H,B))return}r||S(E)},[I,E,x,S,r,h]);let{getButtonProps:F,buttonRef:k}=Qo({disabled:r,native:l,focusableWhenDisabled:!0}),z=f(s),q=ps.useRef(!1),O=ps.useRef(!1);function V(H){m(s,he(ne.none,H.nativeEvent,void 0,{activationDirection:"none"}))}function w(H){I||r||V(H)}function _(H){I||r||b&&(!q.current||O.current)&&V(H)}function U(H){if(I||r)return;q.current=!0,O.current=H.button===0;let B=ve(H.currentTarget);function J(){q.current=!1,O.current=!1,B.removeEventListener("pointerup",J),B.removeEventListener("pointercancel",J)}B.addEventListener("pointerup",J),B.addEventListener("pointercancel",J)}return $("button",t,{state:{disabled:r,active:I,orientation:p,tabActivationDirection:y},ref:[a,k,C,D],props:[L,{role:"tab","aria-controls":z,"aria-selected":I,id:v,onClick:w,onFocus:_,onPointerDown:U,[lh]:I?"":void 0,onKeyDownCapture(){A.current=!0}},c,F],stateAttributesMapping:Dn})});var Wf=T(M(),1);var IRe=T(M(),1);var o_=T(eh(),1);function Y7(){return Ve}function W7(){return!1}function K7(){return!0}function r_(){return(0,o_.useSyncExternalStore)(Y7,W7,K7)}var ib=T(M(),1),Z7=ib.createContext(void 0),Q7={disableStyleElements:!1};function Xf(){return ib.useContext(Z7)??Q7}var n_=T(Q(),1);function s_(e){let{script:t}=e,{nonce:a}=Xf();return r_()?(0,n_.jsx)("script",{nonce:a,dangerouslySetInnerHTML:{__html:t},suppressHydrationWarning:!0}):null}function Yf(e){let t=pa(e),a=parseFloat(t.width)||0,o=parseFloat(t.height)||0,r=Ue(e),n=r?e.offsetWidth:a,s=r?e.offsetHeight:o;return(Fi(a)!==n||Fi(o)!==s)&&(a=n,o=s),{width:a,height:o}}function i_(e,t){let a=(t??He(e).getComputedStyle(e)).transform,o=0,r=0,n=1;if(a&&a!=="none"){let s=a.match(/matrix(?:3d)?\(([^)]+)\)/);if(s){let i=s[1].split(", ").map(parseFloat);i.length===6?(o=i[4],r=i[5],n=Math.sqrt(i[0]*i[0]+i[1]*i[1])):i.length===16&&(o=i[12],r=i[13],n=i[0])}}return{x:o,y:r,scale:n}}var l_="--active-tab-left",u_="--active-tab-right",c_="--active-tab-top",f_="--active-tab-bottom",d_="--active-tab-width",m_="--active-tab-height";var lb=T(Q(),1),p_,$7={...Dn,activeTabPosition:()=>null,activeTabSize:()=>null},h_=2,y_=Wf.forwardRef(function(t,a){let{className:o,render:r,renderBeforeHydration:n=!1,style:s,...i}=t,{getTabElementBySelectedValue:l,orientation:u,tabActivationDirection:c,value:d}=ji(),{tabsListElement:f,registerIndicatorUpdateListener:m}=sb(),p=W2();Wf.useEffect(()=>m(p),[m,p]);let y=0,b=0,g=0,h=0,x=0,S=0,v=!1;if(d!=null&&f!=null){let N=l(d);if(N!=null){v=!0;let{width:D,height:F}=Yf(N),{width:k,height:z}=Yf(f),q=N.getBoundingClientRect(),O=f.getBoundingClientRect(),V=k>0?O.width/k:1,w=z>0?O.height/z:1,_=e9(N,f);y=_.left,g=_.top;let U=(q.left-O.left)/V+f.scrollLeft-f.clientLeft,X=(q.top-O.top)/w+f.scrollTop-f.clientTop,P=t9(N);Math.abs(U-P.x-y)<=h_&&Math.abs(X-P.y-g)<=h_&&(y=U,g=X),x=D,S=F,b=f.scrollWidth-y-x,h=f.scrollHeight-g-S}}let R=v?{left:y,right:b,top:g,bottom:h}:null,L=v?{width:x,height:S}:null,C=v?{[l_]:`${y}px`,[u_]:`${b}px`,[c_]:`${g}px`,[f_]:`${h}px`,[d_]:`${x}px`,[m_]:`${S}px`}:void 0,E=v&&x>0&&S>0,A=$("span",t,{state:{orientation:u,activeTabPosition:R,activeTabSize:L,tabActivationDirection:c},ref:a,props:[{role:"presentation",style:C,hidden:!E},i,{suppressHydrationWarning:!0}],stateAttributesMapping:$7});return d==null?null:(0,lb.jsxs)(Wf.Fragment,{children:[A,n&&(p_||(p_=(0,lb.jsx)(s_,{script:""})))]})});function e9(e,t){let a=g_(e),o=g_(t),r=a.left-o.left-t.clientLeft,n=a.top-o.top-t.clientTop,s=Zo(e);for(;Ue(s)&&s!==t&&!Sr(s);)r-=s.scrollLeft,n-=s.scrollTop,s=Zo(s);return{left:r,top:n}}function g_(e){let t=0,a=0,o=e;for(;o!=null;){t+=o.offsetLeft,a+=o.offsetTop;let r=o.offsetParent;r!=null&&(t+=r.clientLeft,a+=r.clientTop),o=r}return{left:t,top:a}}function t9(e){let t=He(e).getComputedStyle(e),{x:a,y:o}=i_(e,t),r=a,n=o,{translate:s}=t;if(s&&s!=="none"){let i=s.split(" ");r+=x_(i[0],e.offsetWidth),n+=x_(i[1],e.offsetHeight)}return{x:r,y:n}}function x_(e,t){if(!e)return 0;let a=parseFloat(e);return Number.isFinite(a)?e.endsWith("%")?a/100*t:a:0}var ub=T(M(),1);var S_="data-index";var WRe=gu.startingStyle,KRe=gu.endingStyle;var o9={...Dn,...Ya},b_=ub.forwardRef(function(t,a){let{className:o,value:r,render:n,keepMounted:s=!1,style:i,...l}=t,{value:u,getTabIdByPanelValue:c,orientation:d,tabActivationDirection:f,registerMountedTabPanel:m}=ji(),p=It(),{ref:y,index:b}=jf(),g=r===u,{mounted:h,transitionStatus:x,setMounted:S}=ko(g),v=!h,R=c(r),L={hidden:v,orientation:d,tabActivationDirection:f,transitionStatus:x},C=ub.useRef(null),E=$("div",t,{state:L,ref:[a,y,C],props:[{"aria-labelledby":R,hidden:v,id:p,role:"tabpanel",tabIndex:g?0:-1,inert:Gi(!g),[S_]:b},l],stateAttributesMapping:o9});return Ra({open:g,ref:C,onComplete(){g||S(!1)}}),G(()=>{if(!(p==null||v&&!s))return m(r,p)},[v,s,r,p,m]),s||h?E:null});var jr=T(M(),1);var C_=T(M(),1);var Nu=T(M(),1);function cb(e){return e==null||e.hasAttribute("disabled")||e.getAttribute("aria-disabled")==="true"}function v_(e){let{loopFocus:t=!0,orientation:a="both",grid:o,onLoop:r,direction:n,highlightedIndex:s,onHighlightedIndexChange:i,rootRef:l,enableHomeAndEndKeys:u=!1,stopEventPropagation:c,disabledIndices:d,modifierKeys:f=Io}=e,[m,p]=Nu.useState(0),y=o!=null,b=Nu.useRef(null),g=mr(b,l),h=Nu.useRef([]),x=Nu.useRef(!1),S=Nu.useRef(null),v=s??m,R=W((A,N=!1)=>{if(S.current=h.current[A]??null,(i??p)(A),N){let D=h.current[A];TI(b.current,D,n,a)}}),L=W(A=>{if(A.size===0)return;if(x.current){let k=h.current,z=k.indexOf(S.current);if(z===-1){let q=k[v];!q||fs(k,v,d)?R(r9(k,d)):S.current=q}else z!==v&&R(z);return}x.current=!0;let N=Array.from(A.keys()),D=N.find(k=>k?.hasAttribute(lh))??null,F=D?A.get(D)?.index??-1:-1;if(F!==-1)R(F);else if(fs(N,v,d)){let k=Cr(N,{disabledIndices:d});_i(N,k)||R(k)}TI(b.current,D,n,a)});G(()=>{if(d==null||s!=null||!x.current)return;let A=h.current;if(fs(A,v,d)){let N=Cr(A,{disabledIndices:d});_i(A,N)||R(N)}},[d,s,v,h,R]);let C=W((A,N,D)=>r?r(A,N,D,h):D),E=W(A=>{let N=A.key===KS||A.key===ZS;if(!Hf.has(A.key)||!u&&N||n9(A,f)||!b.current)return;let F=n==="rtl",k=F?YS:WS,z=F?WS:YS,q=a==="vertical"?XS:k,O=a==="vertical"?jS:z,V=$e(A.nativeEvent);if(V!=null&&RI(V)&&!cb(V)){let H=V.selectionStart,B=V.selectionEnd,J=V.value;if(H==null||A.shiftKey||H!==B||A.key!==O&&H<J.length||A.key!==q&&H>0)return}let w=v,_=Lu(h,d),U=Pf(h,d);o!=null&&(w=o({disabledIndices:d,elementsRef:h,event:A,highlightedIndex:v,loopFocus:t,maxIndex:U,minIndex:_,onLoop:C,orientation:a,rtl:F}));let X=a!=="vertical"&&A.key===k||a!=="horizontal"&&A.key===XS,P=a!=="vertical"&&A.key===z||a!=="horizontal"&&A.key===jS;u&&(A.key===KS?w=_:A.key===ZS&&(w=U)),w===v&&(X||P)&&(t&&w===U&&X?(w=_,r&&(w=r(A,v,w,h))):t&&w===_&&P?(w=U,r&&(w=r(A,v,w,h))):w=Cr(h.current,{startingIndex:w,decrement:P,disabledIndices:d})),w!==v&&!_i(h.current,w)&&(c&&A.stopPropagation(),(y||N||X||P)&&A.preventDefault(),R(w,!0),queueMicrotask(()=>{h.current[w]?.focus()}))});return{props:{ref:g,onFocus(A){let N=b.current,D=$e(A.nativeEvent);!N||D==null||!RI(D)||D.setSelectionRange(0,D.value.length)},onKeyDown:E},highlightedIndex:v,onHighlightedIndexChange:R,elementsRef:h,onMapChange:L,relayKeyboardEvent:E}}function r9(e,t){let a=-1;for(let o=0;o<e.length;o+=1){let r=e[o];if(!(!r||fs(e,o,t))){if(r.hasAttribute(lh))return o;a===-1&&(a=o)}}return Math.max(a,0)}function n9(e,t){for(let a of fF)if(!t.includes(a)&&e.getModifierState(a))return!0;return!1}var fb=T(M(),1),s9=fb.createContext(void 0);function No(){return fb.useContext(s9)?.direction??"ltr"}var kI=T(Q(),1);function L_(e){let{render:t,className:a,style:o,refs:r=Io,props:n=Io,state:s=Ke,stateAttributesMapping:i,highlightedIndex:l,onHighlightedIndexChange:u,orientation:c,grid:d,loopFocus:f,onLoop:m,enableHomeAndEndKeys:p,onMapChange:y,stopEventPropagation:b=!0,rootRef:g,disabledIndices:h,modifierKeys:x,highlightItemOnHover:S=!1,tag:v="div",...R}=e,L=No(),{props:C,highlightedIndex:E,onHighlightedIndexChange:I,elementsRef:A,onMapChange:N,relayKeyboardEvent:D}=v_({grid:d,loopFocus:f,onLoop:m,orientation:c,highlightedIndex:l,onHighlightedIndexChange:u,rootRef:g,stopEventPropagation:b,enableHomeAndEndKeys:p,direction:L,disabledIndices:h,modifierKeys:x}),F=$(v,e,{state:s,ref:r,props:[C,...n,R],stateAttributesMapping:i}),k=C_.useMemo(()=>({highlightedIndex:E,onHighlightedIndexChange:I,highlightItemOnHover:S,relayKeyboardEvent:D}),[E,I,S,D]);return(0,kI.jsx)(fT.Provider,{value:k,children:(0,kI.jsx)(Gf,{elementsRef:A,onMapChange:z=>{y?.(z),N(z)},children:F})})}var NI=T(Q(),1),R_=jr.forwardRef(function(t,a){let{activateOnFocus:o=!1,className:r,loopFocus:n=!0,render:s,style:i,...l}=t,{orientation:u,setTabMap:c,tabActivationDirection:d}=ji(),[f,m]=jr.useState(0),[p,y]=jr.useState(null),b=jr.useRef(new Set),g=jr.useRef(new Set),h=jr.useRef(null);G(()=>{if(typeof ResizeObserver>"u")return;let C=new ResizeObserver(()=>{b.current.forEach(E=>{E()})});return h.current=C,p&&C.observe(p),g.current.forEach(E=>{C.observe(E)}),()=>{C.disconnect(),h.current=null}},[p]);let x=W(C=>(b.current.add(C),()=>{b.current.delete(C)})),S=W(C=>(g.current.add(C),h.current?.observe(C),()=>{g.current.delete(C),h.current?.unobserve(C)})),v={orientation:u,tabActivationDirection:d},R={"aria-orientation":u==="vertical"?"vertical":void 0,role:"tablist"},L=jr.useMemo(()=>({activateOnFocus:o,registerIndicatorUpdateListener:x,registerTabResizeObserverElement:S,tabsListElement:p}),[o,x,S,p]);return(0,NI.jsx)(OI.Provider,{value:L,children:(0,NI.jsx)(L_,{render:s,className:r,style:i,state:v,refs:[a,y],props:[R,l],stateAttributesMapping:Dn,highlightedIndex:f,enableHomeAndEndKeys:!0,loopFocus:n,orientation:u,onHighlightedIndexChange:m,onMapChange:c,disabledIndices:Io})})});var pb=T(Q(),1);function db({className:e,orientation:t="horizontal",...a}){return(0,pb.jsx)(Kf.Root,{"data-slot":"tabs","data-orientation":t,className:re("group/tabs flex gap-2 data-horizontal:flex-col",e),...a})}var i9=jc("group/tabs-list inline-flex w-fit items-center justify-center rounded-lg p-[3px] text-muted-foreground group-data-horizontal/tabs:h-8 group-data-vertical/tabs:h-fit group-data-vertical/tabs:flex-col data-[variant=line]:rounded-none",{variants:{variant:{default:"bg-muted",line:"gap-1 bg-transparent"}},defaultVariants:{variant:"default"}});function mb({className:e,variant:t="default",...a}){return(0,pb.jsx)(Kf.List,{"data-slot":"tabs-list","data-variant":t,className:re(i9({variant:t}),e),...a})}function Zf({className:e,...t}){return(0,pb.jsx)(Kf.Tab,{"data-slot":"tabs-trigger",className:re("relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-md border border-transparent px-1.5 py-0.5 text-sm font-medium whitespace-nowrap text-foreground/60 transition-all group-data-vertical/tabs:w-full group-data-vertical/tabs:justify-start hover:text-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 focus-visible:outline-1 focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50 has-data-[icon=inline-end]:pr-1 has-data-[icon=inline-start]:pl-1 aria-disabled:pointer-events-none aria-disabled:opacity-50 dark:text-muted-foreground dark:hover:text-foreground group-data-[variant=default]/tabs-list:data-active:shadow-sm group-data-[variant=line]/tabs-list:data-active:shadow-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4","group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-active:bg-transparent dark:group-data-[variant=line]/tabs-list:data-active:border-transparent dark:group-data-[variant=line]/tabs-list:data-active:bg-transparent","data-active:bg-background data-active:text-foreground dark:data-active:border-input dark:data-active:bg-input/30 dark:data-active:text-foreground","after:absolute after:bg-foreground after:opacity-0 after:transition-opacity group-data-horizontal/tabs:after:inset-x-0 group-data-horizontal/tabs:after:bottom-[-5px] group-data-horizontal/tabs:after:h-0.5 group-data-vertical/tabs:after:inset-y-0 group-data-vertical/tabs:after:-right-1 group-data-vertical/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-active:after:opacity-100",e),...t})}var Mn={};Aa(Mn,{Arrow:()=>nz,Handle:()=>dh,Popup:()=>oz,Portal:()=>z_,Positioner:()=>tz,Provider:()=>iz,Root:()=>D_,Trigger:()=>k_,Viewport:()=>Sz,createHandle:()=>bz});var Qf=T(M(),1);var hb=T(M(),1),VI=hb.createContext(void 0);function Ir(e){let t=hb.useContext(VI);if(t===void 0&&!e)throw new Error(Me(72));return t}var T_=T(M(),1);var I_={...OS,disabled:e=>e.disabled,instantType:e=>e.instantType,isInstantPhase:e=>e.isInstantPhase,trackCursorAxis:e=>e.trackCursorAxis,disableHoverablePopup:e=>e.disableHoverablePopup,lastOpenChangeReason:e=>e.openChangeReason,closeOnClick:e=>e.closeOnClick,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin},gb=class extends Tr{constructor(t,a,o){let r=new wn;super(E_(t,r,a,o),A_(r),I_)}setOpen=(t,a)=>{tF(this,t,a,{extraState:{openChangeReason:a.reason}})};cancelPendingOpen(t){this.state.floatingRootContext.dispatchOpenChange(!1,he(ne.triggerPress,t))}};function w_(){let e=new wn,t=new Uf(Object.freeze(E_(void 0,e)),Object.freeze(A_(e)),I_);return Object.assign(t,{setOpen:Ve,cancelPendingOpen:Ve})}function E_(e,t,a,o=!1){return{...PS(t,a,o),disabled:!1,instantType:void 0,isInstantPhase:!1,trackCursorAxis:"none",disableHoverablePopup:!1,openChangeReason:null,closeOnClick:!0,closeDelay:0,adaptiveOrigin:void 0,...e}}function A_(e){return{popupRef:T_.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerElements:e}}var uh=T(Q(),1),D_=th(function(t){let{disabled:a=!1,defaultOpen:o=!1,open:r,disableHoverablePopup:n=!1,trackCursorAxis:s="none",actionsRef:i,onOpenChange:l,onOpenChangeComplete:u,handle:c,triggerId:d,defaultTriggerId:f=null,children:m}=t,p=IS((A,N)=>new gb({open:o,openProp:r,activeTriggerId:f,triggerIdProp:d},A,N));p.useControlledProp("openProp",r),p.useControlledProp("triggerIdProp",d),p.useContextCallback("onOpenChange",l),p.useContextCallback("onOpenChangeComplete",u);let y=p.useState("open"),b=!a&&y,g=p.useState("activeTriggerId"),h=p.useState("mounted"),x=p.useState("payload");p.useSyncedValues({trackCursorAxis:s,disableHoverablePopup:n,disabled:a}),AS(p,{closeOnActiveTriggerUnmount:!0});let{forceUnmount:S,transitionStatus:v}=DS(b,p),R=p.useState("isInstantPhase"),L=p.useState("instantType"),C=p.useState("lastOpenChangeReason"),E=Qf.useRef(null);G(()=>{y&&a&&p.setOpen(!1,he(ne.disabled))},[y,a,p]),G(()=>{v==="ending"&&C===ne.none||v!=="ending"&&R?(L!=="delay"&&(E.current=L),p.set("instantType","delay")):E.current!==null&&(p.set("instantType",E.current),E.current=null)},[v,R,C,L,p]),G(()=>{b&&g==null&&p.set("payload",void 0)},[p,g,b]),Qf.useImperativeHandle(i,()=>({unmount:S,close:()=>p.setOpen(!1,he(ne.imperativeAction))}),[S,p]);let I=b||h||!a&&s!=="none";return(0,uh.jsxs)(VI.Provider,{value:p,children:[c&&(0,uh.jsx)(wS,{handle:c,store:p}),I&&(0,uh.jsx)(l9,{store:p,disabled:a,trackCursorAxis:s}),typeof m=="function"?m({payload:x}):m]})});function l9({store:e,disabled:t,trackCursorAxis:a}){let o=e.useState("floatingRootContext"),r=Eu(o,{enabled:!t,referencePress:()=>e.select("closeOnClick")}),n=YT(o,{enabled:!t&&a!=="none",axis:a==="none"?void 0:a}),s=Qf.useMemo(()=>ja(n.reference,r.reference),[n.reference,r.reference]);return MS(e,{activeTriggerProps:s,inactiveTriggerProps:s,popupProps:r.floating??Ke}),null}var yb=T(M(),1);var xb=T(M(),1),BI=xb.createContext(void 0);function M_(){return xb.useContext(BI)}var O_="data-base-ui-tooltip-trigger";function P_(e){if("composedPath"in e){let a=e.composedPath();for(let o=0;o<a.length;o+=1){let r=a[o];if(we(r))return r}}let t=e.target;return we(t)?t:null}function u9(e){let t=e;for(;t;){let a=t.closest(`[${O_}]`);if(a)return a;let o=t.getRootNode();t="host"in o&&we(o.host)?o.host:null}return null}var k_=vS(function(t,a){let{render:o,className:r,style:n,handle:s,payload:i,disabled:l,delay:u,closeOnClick:c=!0,closeDelay:d,id:f,...m}=t,p=Ir(!0),b=kS(s)??p;if(!b)throw new Error(Me(82));let g=It(f),h=b.useState("isTriggerActive",g),x=b.useState("isOpenedByTrigger",g),S=b.useState("floatingRootContext"),v=yb.useRef(null),R=d??0,{registerTrigger:L,isMountedByThisTrigger:C}=ES(g,v,b,{payload:i,closeOnClick:c,closeDelay:R}),E=M_(),{activeIdRef:I,delayRef:A,isInstantPhase:N,hasProvider:D}=OT(S,{open:x}),F=zf(S);b.useSyncedValue("isInstantPhase",N);let k=b.useState("disabled"),z=l??k,q=pt(z),O=b.useState("trackCursorAxis"),V=b.useState("disableHoverablePopup"),w=yb.useRef(!1),_=Qe(),U=yb.useRef(void 0);function X(){return D&&I.current!=null?0:u??E??600}function P(ae){let me=v.current;if(!me||!ae)return!1;let ge=u9(ae);return ge!==null&&ge!==me&&ue(me,ge)}function H(ae){let me=P(ae);return w.current=me,me&&(F.openChangeTimeout.clear(),F.restTimeout.clear(),F.restTimeoutPending=!1,_.clear()),me}let B=yI(S,{enabled:!z,mouseOnly:!0,move:!1,handleClose:!V&&O!=="both"?CI():null,restMs:X,delay(){return d==null&&D?{close:Ur(A.current,"close")}:{close:R}},triggerElementRef:v,isActiveTrigger:h,isClosing:()=>b.select("transitionStatus")==="ending",shouldOpen(){return!w.current}}),J=pI(S,{enabled:!z}).reference,Y=ae=>{let me=w.current,ge=P_(ae),Ee=H(ge),pe=v.current,Te=pe&&ge&&ue(pe,ge);if(Ee&&b.select("open")&&b.select("lastOpenChangeReason")===ne.triggerHover){b.setOpen(!1,he(ne.triggerHover,ae));return}if(me&&!Ee&&Te&&!q.current&&!b.select("open")&&pe&&Jo(U.current)){let le=()=>{!w.current&&!q.current&&!b.select("open")&&b.setOpen(!0,he(ne.triggerHover,ae,pe))},Ie=X();Ie===0?(_.clear(),le()):_.start(Ie,le)}},te=b.useState("triggerProps",C);return $("button",t,{state:{open:x},ref:[a,L,v],props:[B,J,C||O!=="none"?te:void 0,{onMouseOver(ae){Y(ae.nativeEvent)},onFocus(ae){P(P_(ae.nativeEvent))&&ae.preventBaseUIHandler()},onMouseLeave(){w.current=!1,_.clear(),U.current=void 0},onPointerEnter(ae){U.current=ae.pointerType},onPointerDown(ae){U.current=ae.pointerType,b.set("closeOnClick",c),c&&!b.select("open")&&b.cancelPendingOpen(ae.nativeEvent)},onClick(ae){c&&!b.select("open")&&b.cancelPendingOpen(ae.nativeEvent)},id:g,[_p]:z?"":void 0,[O_]:z?void 0:""},m],stateAttributesMapping:If})});var __=T(M(),1);var Sb=T(M(),1),FI=Sb.createContext(void 0);function N_(){let e=Sb.useContext(FI);if(e===void 0)throw new Error(Me(70));return e}var bb=T(M(),1),V_=T(Zr(),1);var B_=T(Q(),1),F_=bb.forwardRef(function(t,a){let{children:o,container:r,className:n,render:s,style:i,...l}=t,{node:u,subtree:c}=hS({container:r,ref:a,componentProps:t,elementProps:l});return!c&&!u?null:(0,B_.jsxs)(bb.Fragment,{children:[c,u&&V_.createPortal(o,u)]})});var _I=T(Q(),1),z_=__.forwardRef(function(t,a){let{keepMounted:o=!1,...r}=t;return Ir().useState("mounted")||o?(0,_I.jsx)(FI.Provider,{value:o,children:(0,_I.jsx)(F_,{ref:a,...r})}):null});var Ib=T(M(),1);var vb=T(M(),1),zI=vb.createContext(void 0);function Jf(){let e=vb.useContext(zI);if(e===void 0)throw new Error(Me(71));return e}var $o=T(M(),1);var c9=e=>({name:"arrow",options:e,async fn(t){let{x:a,y:o,placement:r,rects:n,platform:s,elements:i,middlewareData:l}=t,{element:u,padding:c=0,offsetParent:d="real"}=In(e,t)||{};if(u==null)return{};let f=uS(c),m={x:a,y:o},p=Gp(r),y=qp(p),b=await s.getDimensions(u),g=p==="y",h=g?"top":"left",x=g?"bottom":"right",S=g?"clientHeight":"clientWidth",v=n.reference[y]+n.reference[p]-m[p]-n.floating[y],R=m[p]-n.reference[p],L=d==="real"?await s.getOffsetParent?.(u):i.floating,C=i.floating[S]||n.floating[y];(!C||!await s.isElement?.(L))&&(C=i.floating[S]||n.floating[y]);let E=v/2-R/2,I=C/2-b[y]/2-1,A=Math.min(f[h],I),N=Math.min(f[x],I),D=A,F=C-b[y]-N,k=C/2-b[y]/2+E,z=iS(D,k,F),q=!l.arrow&&vr(r)!=null&&k!==z&&n.reference[y]/2-(k<D?A:N)-b[y]/2<0,O=q?k<D?k-D:k-F:0;return{[p]:m[p]+O,data:{[p]:z,centerOffset:k-z-O,...q&&{alignmentOffset:O}},reset:q}}}),H_=(e,t)=>{let{name:a,fn:o}=c9(e);return{name:a,fn:o,options:[e,t]}};var U_={name:"hide",async fn(e){let{width:t,height:a,x:o,y:r}=e.rects.reference,n=t===0&&a===0&&o===0&&r===0,s=await e.platform.detectOverflow(e,{elementContext:"reference"});return{data:{referenceHidden:s.top-a>=0||s.right-t>=0||s.bottom-a>=0||s.left-t>=0||n}}}};var $f={sideX:"left",sideY:"top"};var Cb="--available-width",Lb="--available-height",q_="--anchor-width",G_="--anchor-height",j_="--transform-origin",X_="--positioner-width",Y_="--positioner-height";var K_=Cb,Z_=Lb;function $_(e,t,a){let o=e==="inline-start"||e==="inline-end";return{top:"top",right:o?a?"inline-start":"inline-end":"right",bottom:"bottom",left:o?a?"inline-end":"inline-start":"left"}[t]}function Q_(e,t,a){let{rects:o,placement:r}=e;return{side:$_(t,Za(r),a),align:vr(r)||"center",anchor:{width:o.reference.width,height:o.reference.height},positioner:{width:o.floating.width,height:o.floating.height}}}function Rb(e){return f9(e,sF)}function f9(e,t){let{anchor:a,positionMethod:o="absolute",side:r="bottom",sideOffset:n=0,align:s="center",alignOffset:i=0,collisionBoundary:l,collisionPadding:u=5,sticky:c=!1,arrowPadding:d=5,disableAnchorTracking:f=!1,inline:m,keepMounted:p=!1,floatingRootContext:y,mounted:b,collisionAvoidance:g,shift:h,nodeId:x,adaptiveOrigin:S,lazyFlip:v=!1,externalTree:R}=e,[L,C]=$o.useState(null);!b&&L!==null&&C(null);let E=g.side||"flip",I=g.align||"flip",A=g.fallbackAxisSide||"end",N=h?.crossAxis??!1,D=h?.rootBoundary,F=typeof a=="function"?a:void 0,k=W(F),z=F?k:a,q=pt(a),O=pt(b),w=No()==="rtl",_=L||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":w?"left":"right","inline-start":w?"right":"left"}[r],U=s==="center"?_:`${_}-${s}`,X=u;typeof X=="number"?X={top:X,right:X,bottom:X,left:X}:X&&(X={top:X.top||0,right:X.right||0,bottom:X.bottom||0,left:X.left||0});let P=1,H=r==="bottom"?P:0,B=r==="top"?P:0,J=r==="right"?P:0,Y=r==="left"?P:0,te={boundary:l==="clipping-ancestors"?"clippingAncestors":l,padding:X},ie=$o.useRef(null),ce=pt(n),ee=pt(i),ae=typeof n!="function"?n:0,me=typeof i!="function"?i:0,ge=[];m&&ge.push(m),ge.push(QT(Ae=>{let Dt=Q_(Ae,r,w),Je=typeof ce.current=="function"?ce.current(Dt):ce.current,Bt=typeof ee.current=="function"?ee.current(Dt):ee.current;return{mainAxis:Je,crossAxis:Bt,alignmentAxis:Bt}},[ae,me,w,r]));let Ee=I==="none"&&E!=="shift",pe=!Ee&&(c||N||E==="shift"),Te=E==="none"?null:eI({...te,padding:{top:X.top+P+H,right:X.right+P+Y,bottom:X.bottom+P+B,left:X.left+P+J},mainAxis:!N&&E==="flip",crossAxis:I==="flip"?"alignment":!1,fallbackAxisSideDirection:A}),le=Ee?null:JT({...te,rootBoundary:D,mainAxis:I!=="none",crossAxis:pe,limiter:c||N?void 0:$T(Ae=>{if(!ie.current)return{};let{width:Dt,height:Je}=ie.current.getBoundingClientRect(),Bt=Po(Za(Ae.placement)),go=Bt==="y"?Dt:Je,xo=Bt==="y"?X.left+X.right:X.top+X.bottom;return{offset:go/2+xo/2}})},[te,c,N,D,X,I]);E==="shift"||I==="shift"||s==="center"?ge.push(le,Te):ge.push(Te,le),ge.push(tI({...te,apply({elements:{floating:Ae},availableWidth:Dt,availableHeight:Je,rects:Bt}){if(!O.current)return;let go=Ae.style;go.setProperty(K_,`${Dt}px`),go.setProperty(Z_,`${Je}px`);let xo=He(Ae).devicePixelRatio||1,{x:Gu,y:Cs,width:rl,height:Wr}=Bt.reference,Ze=(Math.round((Gu+rl)*xo)-Math.round(Gu*xo))/xo,Mt=(Math.round((Cs+Wr)*xo)-Math.round(Cs*xo))/xo;go.setProperty(q_,`${Ze}px`),go.setProperty(G_,`${Mt}px`)}}),H_(Ae=>({element:ie.current||ve(Ae.elements.floating).createElement("div"),padding:ie.current?d:0,offsetParent:"floating"}),[d]),{name:"transformOrigin",fn(Ae){let{elements:{floating:Dt},middlewareData:Je,placement:Bt,platform:go,rects:xo,y:Gu}=Ae,Cs=Za(Bt),rl=vr(Bt),Wr=Po(Cs)==="y",Ze=ie.current,Mt=typeof n=="function"?n(Q_(Ae,r,w)):n,Nn;if(!Ze&&rl&&Math.abs(Wr?Je.shift?.x||0:Je.shift?.y||0)<=1)Nn=rl==="start"===(Wr&&go.isRTL?.(Dt)===!0)?"100%":"0%";else{let sl=Wr?Je.arrow?.x||0:Je.arrow?.y||0,bd=Wr?Ze?.clientWidth||0:Ze?.clientHeight||0;Nn=`${sl+bd/2}px`}let nl=Cs==="top"||Cs==="left"?`calc(100% + ${Mt}px)`:`${-Mt}px`;return pe&&Wr&&Math.abs(Je.shift?.y||0)>Mt&&(nl=`${xo.reference.y+xo.reference.height/2-Gu}px`),Dt.style.setProperty(j_,Wr?`${Nn} ${nl}`:`${nl} ${Nn}`),{}}},U_,S),G(()=>{!b&&y&&y.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[b,y]);let Ie=$o.useMemo(()=>({ancestorScroll:!f,elementResize:!f&&typeof ResizeObserver<"u",layoutShift:!f&&typeof IntersectionObserver<"u"}),[f]),{refs:Be,elements:Oe,x:ut,y:oe,middlewareData:fe,update:K,placement:j,context:se,isPositioned:Fe,floatingStyles:Vt}=t({rootContext:y,open:p?b:void 0,placement:U,middleware:ge,strategy:o,whileElementsMounted:p?void 0:(...Ae)=>$p(...Ae,Ie),nodeId:x,externalTree:R}),{sideX:Jt,sideY:Et}=fe.adaptiveOrigin||$f,bt=Fe?o:"fixed",wa=$o.useMemo(()=>{let Ae;return Fe?S?Ae={position:bt,[Jt]:ut,[Et]:oe}:Ae={...Vt,position:bt}:Ae={position:bt,top:0,left:0},Ae[K_]="100vw",Ae[Z_]="100vh",Fe||(Ae.opacity=0),Ae},[S,bt,Jt,ut,Et,oe,Vt,Fe]),Ea=$o.useRef(null);G(()=>{if(!b)return;let Ae=q.current,Dt=typeof Ae=="function"?Ae():Ae,Bt=(J_(Dt)?Dt.current:Dt)||null||null;Bt!==Ea.current&&(Be.setPositionReference(Bt),Ea.current=Bt)},[b,Be,z,q]),$o.useEffect(()=>{if(!b)return;let Ae=q.current;typeof Ae!="function"&&J_(Ae)&&Ae.current!==Ea.current&&(Be.setPositionReference(Ae.current),Ea.current=Ae.current)},[b,Be,z,q]),$o.useEffect(()=>{if(p&&b&&Oe.reference&&Oe.floating)return $p(Oe.reference,Oe.floating,K,Ie)},[p,b,Oe,K,Ie]);let $t=Za(j),Ha=$_(r,$t,w),ho=vr(j)||"center",tr=!!fe.hide?.referenceHidden;G(()=>{v&&b&&Fe&&$t!==_&&C($t)},[v,b,Fe,$t,_]);let ha=$o.useMemo(()=>({position:"absolute",top:fe.arrow?.y,left:fe.arrow?.x}),[fe.arrow]),Ht=fe.arrow?.centerOffset!==0;return $o.useMemo(()=>({positionerStyles:wa,arrowStyles:ha,arrowRef:ie,arrowUncentered:Ht,side:Ha,align:ho,physicalSide:$t,anchorHidden:tr,refs:Be,context:se,isPositioned:Fe,update:K}),[wa,ha,ie,Ht,Ha,ho,$t,tr,Be,se,Fe,K])}function J_(e){return e!=null&&"current"in e}function ed(e){return e==="starting"?$B:Ke}function Tb(e,t,{styles:a,transitionStatus:o,props:r,refs:n,hidden:s,inert:i=!1}){let l={...a};return i&&(l.pointerEvents="none"),$("div",e,{state:t,ref:n,props:[{role:"presentation",hidden:s,style:l},ed(o),r],stateAttributesMapping:Hr})}var ez=T(Q(),1),tz=Ib.forwardRef(function(t,a){let{render:o,className:r,anchor:n,positionMethod:s="absolute",side:i="top",align:l="center",sideOffset:u=0,alignOffset:c=0,collisionBoundary:d="clipping-ancestors",collisionPadding:f=5,arrowPadding:m=5,sticky:p=!1,disableAnchorTracking:y=!1,collisionAvoidance:b=t2,style:g,...h}=t,x=Ir(),S=N_(),v=x.useState("open"),R=x.useState("mounted"),L=x.useState("trackCursorAxis"),C=x.useState("disableHoverablePopup"),E=x.useState("floatingRootContext"),I=x.useState("instantType"),A=x.useState("transitionStatus"),N=x.useState("adaptiveOrigin"),D=Rb({anchor:n,positionMethod:s,floatingRootContext:E,mounted:R,side:i,sideOffset:u,align:l,alignOffset:c,collisionBoundary:d,collisionPadding:f,sticky:p,arrowPadding:m,disableAnchorTracking:y,keepMounted:S,collisionAvoidance:b,adaptiveOrigin:N}),F=Ib.useMemo(()=>({open:v,side:D.side,align:D.align,anchorHidden:D.anchorHidden,instant:L!=="none"?"tracking-cursor":I}),[v,D.side,D.align,D.anchorHidden,L,I]),k=Tb(t,F,{styles:D.positionerStyles,transitionStatus:A,props:h,refs:[a,x.useStateSetter("positionerElement")],hidden:!R,inert:!v||L==="both"||C});return(0,ez.jsx)(zI.Provider,{value:D,children:k})});var az=T(M(),1);var oz=az.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,i=Ir(),{side:l,align:u}=Jf(),c=i.useState("open"),d=i.useState("instantType"),f=i.useState("transitionStatus"),m=i.useState("popupProps"),p=i.useState("floatingRootContext"),y=i.useState("disabled"),b=i.useState("closeDelay");Ra({open:c,ref:i.context.popupRef,onComplete(){c&&i.context.onOpenChangeComplete?.(!0)}}),xI(p,{enabled:!y,closeDelay:b});let g=i.useStateSetter("popupElement");return $("div",t,{state:{open:c,side:l,align:u,instant:d,transitionStatus:f},ref:[a,i.context.popupRef,g],props:[Ff,m,ed(f),s],stateAttributesMapping:wf})});var rz=T(M(),1);var nz=rz.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,i=Ir(),{arrowRef:l,side:u,align:c,arrowUncentered:d,arrowStyles:f}=Jf(),m=i.useState("open"),p=i.useState("instantType");return $("div",t,{state:{open:m,side:u,align:c,uncentered:d,instant:p},ref:[a,l],props:[{style:f,"aria-hidden":!0},s],stateAttributesMapping:Hr})});var sz=T(M(),1);var HI=T(Q(),1),iz=function(t){let{delay:a,closeDelay:o,timeout:r=400}=t,n=sz.useMemo(()=>({open:a,close:o}),[a,o]);return(0,HI.jsx)(BI.Provider,{value:a,children:(0,HI.jsx)(PT,{delay:n,timeoutMs:r,children:t.children})})};var yz=T(M(),1);var _a=T(M(),1),hz=T(Zr(),1);var lz=T(M(),1);function wb(e){let[t,a]=lz.useState({current:e,previous:null});return Object.is(e,t.current)||a({current:e,previous:t.current}),t.previous}var td=T(M(),1);var ch="--popup-width",fh="--popup-height";function fz(e){let{popupElement:t,positionerElement:a,content:o,mounted:r,onMeasureLayout:n,onMeasureLayoutComplete:s,side:i,direction:l}=e,u=Bf(t,!0),c=co(),d=td.useRef(null),f=td.useRef(!0),m=td.useRef(Ve),p=W(n),y=W(s),b=td.useMemo(()=>d9(i,l),[i,l]);G(()=>{if(!r){m.current=Ve,f.current=!0,d.current=null;return}if(!t||!a)return;m.current=cz(t,b),UI(t,"auto");let g=Ab(t,"position","static"),h=Ab(t,"transform","none"),x=Ab(t,"scale","1"),S=cz(a,{[Cb]:"max-content",[Lb]:"max-content"});function v(){g(),h(),S()}function R(){v(),x()}if(p?.(),f.current||d.current===null){Eb(a,"max-content");let I=Yf(t);return d.current=I,Eb(a,I),R(),y?.(null,I),f.current=!1,()=>{m.current(),m.current=Ve}}Eb(a,"max-content");let L=d.current,C=Yf(t);d.current=C,UI(t,L),R(),y?.(L,C),Eb(a,C);let E=new AbortController;return c.request(()=>{UI(t,C),u(()=>{t.style.setProperty(ch,"auto"),t.style.setProperty(fh,"auto")},E.signal)}),()=>{E.abort(),c.cancel(),m.current(),m.current=Ve}},[o,t,a,u,c,r,p,y,b])}function d9(e,t){let a=e==="top",o=e==="left"||e===(t==="rtl"?"inline-end":"inline-start");return!a&&!o?Ke:{position:"absolute",[a?"bottom":"top"]:"0",[o?"right":"left"]:"0"}}function Ab(e,t,a){let o=e.style.getPropertyValue(t);return e.style.setProperty(t,a),()=>{e.style.setProperty(t,o)}}function cz(e,t){let a=[];for(let[o,r]of Object.entries(t))a.push(Ab(e,o,r));return a.length?()=>{a.forEach(o=>o())}:Ve}function UI(e,t){let a=t==="auto"?"auto":`${t.width}px`,o=t==="auto"?"auto":`${t.height}px`;e.style.setProperty(ch,a),e.style.setProperty(fh,o)}function Eb(e,t){let a=t==="max-content"?"max-content":`${t.width}px`,o=t==="max-content"?"max-content":`${t.height}px`;e.style.setProperty(X_,a),e.style.setProperty(Y_,o)}var dz={name:"adaptiveOrigin",async fn(e){let{x:t,y:a,rects:{floating:o},elements:{floating:r},platform:n,strategy:s,placement:i}=e,l=He(r),u=l.getComputedStyle(r);if(!(u.transitionDuration!=="0s"&&u.transitionDuration!==""))return{x:t,y:a,data:$f};let d=await n.getOffsetParent?.(r),f={width:0,height:0};if(s==="fixed"&&l?.visualViewport)f={width:l.visualViewport.width,height:l.visualViewport.height};else if(d===l){let h=ve(r);f={width:h.documentElement.clientWidth,height:h.documentElement.clientHeight}}else await n.isElement?.(d)&&(f=await n.getDimensions(d));let m=Za(i),p=t,y=a;m==="left"&&(p=f.width-(t+o.width)),m==="top"&&(y=f.height-(a+o.height));let b=m==="left"?"right":$f.sideX,g=m==="top"?"bottom":$f.sideY;return{x:p,y,data:{sideX:b,sideY:g}}}};var mz="data-activation-direction";var ad=T(Q(),1),gz={activationDirection:e=>e?{[mz]:e}:null};function xz(e){let{store:t,side:a,children:o}=e,r=No(),n=t.useState("activeTriggerElement"),s=t.useState("activeTriggerId"),i=t.useState("open"),l=t.useState("payload"),u=t.useState("mounted"),c=t.useState("popupElement"),d=t.useState("positionerElement"),f=wb(i?n:null),m=g9(s,l),p=_a.useRef(null),[y,b]=_a.useState(null),[g,h]=_a.useState(null),x=_a.useRef(null),S=_a.useRef(null),v=Bf(x,!0),R=co(),L=_a.useRef(null),[C,E]=_a.useState(null),[I,A]=_a.useState(!1);G(()=>(t.set("adaptiveOrigin",dz),()=>{t.set("adaptiveOrigin",void 0)}),[t]);let N=W(()=>{x.current?.style.setProperty("animation","none"),x.current?.style.setProperty("transition","none"),S.current?.style.setProperty("display","none")}),D=W(V=>{x.current?.style.removeProperty("animation"),x.current?.style.removeProperty("transition"),S.current?.style.removeProperty("display"),V&&E(V)}),F=W(()=>{L.current?.abort();let V=new AbortController;L.current=V,v(()=>{b(null),E(null),p.current=null},V.signal)}),k=_a.useRef(null);G(()=>{(!i||!u)&&(k.current=null)},[i,u]),G(()=>{if(n&&f&&n!==f&&k.current!==n&&p.current){b(p.current),A(!0);let V=h9(f,n);h(V),k.current=n}},[n,f]),G(()=>{y!=null&&(L.current?.abort(),A(!0),R.request(()=>{hz.flushSync(()=>{A(!1)}),F()}))},[m,y,F,R]),G(()=>{let V=x.current;if(!V)return;let w=ve(V).createElement("div");for(let _ of Array.from(V.childNodes))w.appendChild(_.cloneNode(!0));p.current=w});let z=y!=null,q;z?q=(0,ad.jsxs)(_a.Fragment,{children:[(0,ad.jsx)("div",{"data-previous":!0,inert:Gi(!0),ref:S,style:{...C?{[ch]:`${C.width}px`,[fh]:`${C.height}px`}:null,position:"absolute"},"data-ending-style":I?void 0:""},"previous"),(0,ad.jsx)("div",{"data-current":!0,ref:x,"data-starting-style":I?"":void 0,children:o},m)]}):q=(0,ad.jsx)("div",{"data-current":!0,ref:x,children:o},m),G(()=>{let V=S.current;!V||!y||V.replaceChildren(...Array.from(y.childNodes))},[y]),fz({popupElement:c,positionerElement:d,mounted:u,content:l,onMeasureLayout:N,onMeasureLayoutComplete:D,side:a,direction:r});let O={activationDirection:p9(g),transitioning:z};return{children:q,state:O}}function p9(e){if(e)return`${pz(e.horizontal,5,"right","left")} ${pz(e.vertical,5,"down","up")}`}function pz(e,t,a,o){return e>t?a:e<-t?o:""}function h9(e,t){let a=e.getBoundingClientRect(),o=t.getBoundingClientRect(),r={x:a.left+a.width/2,y:a.top+a.height/2},n={x:o.left+o.width/2,y:o.top+o.height/2};return{horizontal:n.x-r.x,vertical:n.y-r.y}}function g9(e,t){let[a,o]=_a.useState(0),r=_a.useRef(e),n=_a.useRef(t),s=_a.useRef(!1);return G(()=>{let i=r.current,l=n.current,u=e!==i,c=t!==l;u?(o(d=>d+1),s.current=!c):s.current&&c&&(o(d=>d+1),s.current=!1),r.current=e,n.current=t},[e,t]),`${e??"current"}-${a}`}var Sz=yz.forwardRef(function(t,a){let{render:o,className:r,style:n,children:s,...i}=t,l=Ir(),u=Jf(),c=l.useState("instantType"),{children:d,state:f}=xz({store:l,side:u.side,children:s}),m={activationDirection:f.activationDirection,transitioning:f.transitioning,instant:c};return $("div",t,{state:m,ref:a,props:[i,{children:d}],stateAttributesMapping:gz})});var dh=class extends Nf{constructor(){super(w_(),"Tooltip")}open(t){this.openByTrigger(t)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}};function bz(){return new dh}var hs=T(Q(),1);function vz({delay:e=0,...t}){return(0,hs.jsx)(Mn.Provider,{"data-slot":"tooltip-provider",delay:e,...t})}function od({...e}){return(0,hs.jsx)(Mn.Root,{"data-slot":"tooltip",...e})}function rd({...e}){return(0,hs.jsx)(Mn.Trigger,{"data-slot":"tooltip-trigger",...e})}function nd({className:e,side:t="top",sideOffset:a=4,align:o="center",alignOffset:r=0,children:n,...s}){return(0,hs.jsx)(Mn.Portal,{children:(0,hs.jsx)(Mn.Positioner,{align:o,alignOffset:r,side:t,sideOffset:a,className:"isolate z-50",children:(0,hs.jsxs)(Mn.Popup,{"data-slot":"tooltip-content",className:re("z-50 inline-flex w-fit max-w-xs origin-(--transform-origin) items-center gap-1.5 rounded-md bg-foreground px-3 py-1.5 text-xs text-background has-data-[slot=kbd]:pr-1.5 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-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 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),...s,children:[n,(0,hs.jsx)(Mn.Arrow,{className:"z-50 size-2.5 translate-y-[calc(-50%-2px)] rotate-45 rounded-[2px] bg-foreground fill-foreground data-[side=bottom]:top-1 data-[side=inline-end]:top-1/2! data-[side=inline-end]:-left-1 data-[side=inline-end]:-translate-y-1/2 data-[side=inline-start]:top-1/2! data-[side=inline-start]:-right-1 data-[side=inline-start]:-translate-y-1/2 data-[side=left]:top-1/2! data-[side=left]:-right-1 data-[side=left]:-translate-y-1/2 data-[side=right]:top-1/2! data-[side=right]:-left-1 data-[side=right]:-translate-y-1/2 data-[side=top]:-bottom-2.5"})]})})})}var Vo=T(M(),1);var Cz=T(Q(),1),x9={running:{Icon:ni,cls:"text-info animate-spin"},queued:{Icon:km,cls:"text-warning animate-pulse"},done:{Icon:ai,cls:"text-success animate-in zoom-in-50 duration-300"},failed:{Icon:oi,cls:"text-destructive animate-in zoom-in-50 duration-300"},timeout:{Icon:Em,cls:"text-warning animate-in zoom-in-50 duration-300"},stopped:{Icon:Im,cls:"text-muted-foreground"}};function Db({state:e,className:t}){let{Icon:a,cls:o}=x9[e];return(0,Cz.jsx)(a,{className:re("size-5 shrink-0",o,t),"aria-label":e})}var Hz=T(M(),1);var jb={};Aa(jb,{Control:()=>Bz,Description:()=>Vz,Error:()=>kz,Item:()=>zz,Label:()=>Oz,Root:()=>Pz,Validity:()=>_z});var Ia=T(M(),1);var Mb=T(M(),1);var Lz="data-valid",Rz="data-invalid";var Vu={badInput:!1,customError:!1,patternMismatch:!1,rangeOverflow:!1,rangeUnderflow:!1,stepMismatch:!1,tooLong:!1,tooShort:!1,typeMismatch:!1,valid:null,valueMissing:!1},S9={valid:null,touched:!1,dirty:!1,filled:!1,focused:!1},Tz={disabled:!1,...S9},$a={valid(e){return e===null?null:e?{[Lz]:""}:{[Rz]:""}}};var b9={invalid:void 0,name:void 0,validityData:{state:Vu,errors:[],error:"",value:"",initialValue:null},setValidityData:Ve,disabled:void 0,setTouched:Ve,setDirty:Ve,setFilled:Ve,setFocused:Ve,validationMode:"onSubmit",shouldValidateOnChange:()=>!1,state:Tz,registerFieldControl:Ve,validation:{getValidationProps:(e,t=Ke)=>t,inputRef:{current:null},registeredInputs:new Map,registerInput:Ve,getInputControl:()=>null,commit:async()=>{},change:Ve}},qI=Mb.createContext(b9);function sa(e=!0){let t=Mb.useContext(qI);if(t.setValidityData===Ve&&!e)throw new Error(Me(28));return t}var Pb=T(M(),1),v9=Pb.createContext(void 0);function Iz(e=!1){let t=Pb.useContext(v9);if(!t&&!e)throw new Error(Me(86));return t}var Ob=T(M(),1);var C9=Ob.createContext({elementRef:{current:null},formRef:{current:{fields:new Map}},errors:{},clearErrors:Ve,validationMode:"onSubmit",submitCountRef:{current:0}});function wr(){return Ob.useContext(C9)}var Xi=T(M(),1);var kb=T(M(),1);var GI=kb.createContext({controlId:void 0,registerControlId:Ve,resetControlId:Ve,labelId:void 0,setLabelId:Ve,messageIds:[],setMessageIds:Ve,getDescriptionProps:e=>e});function Ta(){return kb.useContext(GI)}var wz=T(Q(),1),Nb=function(t){let a=It(),[o,r]=Xi.useState(a),[n,s]=Xi.useState(),[i,l]=Xi.useState([]),u=o===void 0?a:o,c=at(()=>new Map),{messageIds:d}=Ta(),f=W((b,g)=>{let h=c.current;g===void 0?h.delete(b):h.set(b,g),r(x=>{if(h.size===0)return x;let S;for(let v of h.values()){if(v===x)return x;S===void 0&&(S=v)}return S})}),m=W(()=>{c.current.size===0&&r(a)}),p=Xi.useCallback(b=>{let g=b["aria-describedby"]?b["aria-describedby"].split(" "):[];return g.push(...d,...i),{...b,"aria-describedby":Array.from(new Set(g)).join(" ")||void 0}},[d,i]),y=Xi.useMemo(()=>({controlId:u,registerControlId:f,resetControlId:m,labelId:n,setLabelId:s,messageIds:i,setMessageIds:l,getDescriptionProps:p}),[u,f,m,n,s,i,l,p]);return(0,wz.jsx)(GI.Provider,{value:y,children:t.children})};var jI=T(M(),1);function sd(e={}){let{id:t,enabled:a=!0}=e,{controlId:o,registerControlId:r,resetControlId:n}=Ta(),s=It(),i=at(()=>Symbol()),l=jI.useRef(!1),u=jI.useRef(!1),c=W(()=>{!l.current||r===Ve||(l.current=!1,r(i.current,void 0))});return G(()=>{if(!a||r===Ve){c();return}let d;if(t!==void 0)u.current=!0,d=t;else if(u.current)d=s;else{n();return}if(d===void 0){c();return}l.current=!0,r(i.current,d)},[t,a,r,n,s,i,c]),G(()=>c,[c]),(a?o:void 0)??t??s}function Vb(e,t){let a=It(e);return G(()=>(t(a),()=>{t(o=>o===a?void 0:o)}),[a,t]),a}function Bb(e={}){let{id:t,fallbackControlId:a,native:o=!1,setLabelId:r,focusControl:n}=e,{controlId:s,setLabelId:i}=Ta(),l=W(m=>{i(m),r?.(m)}),u=Vb(t,l),c=s??a;function d(m){if(n){n(m,c);return}if(!c)return;let p=ve(m.currentTarget).getElementById(c);Ue(p)&&L9(p)}function f(m){$e(m.nativeEvent)?.closest("button,input,select,textarea")||(!m.defaultPrevented&&m.detail>1&&m.preventDefault(),!o&&d(m))}return o?{id:u,htmlFor:c,onMouseDown:f}:{id:u,onClick:f,onPointerDown(m){m.preventDefault()}}}function L9(e){e.focus({focusVisible:!0})}var gs=T(M(),1);function Bu(e,t){return{...e,state:{...e.state,valid:!t&&e.state.valid}}}var XI=Object.keys(Vu);function R9(e,t){return e.matches(":disabled")?!1:!t||e.form===t?!0:e.form===null&&!e.hasAttribute("form")}function Ez(e,t){let a=null;for(let o of e.keys())if(R9(o,t)){if(!o.validity.valid)return o;a??=o}return a}function Az(e){return{...Vu,valid:!e,customError:e}}function YI(e){return e&&e.validationMessage?[e.validationMessage]:[]}function Dz(e){let{elementRef:t,formRef:a}=wr(),{setValidityData:o,validate:r,validityData:n,validationDebounceTime:s,invalid:i,markedDirtyRef:l,state:u,shouldValidateOnChange:c,validationMode:d,registeredFieldIdRef:f}=e,{controlId:m,getDescriptionProps:p}=Ta(),y=Qe(),b=gs.useRef(null),g=at(()=>new Map).current,h=gs.useRef(0),x=gs.useRef(null),S=gs.useCallback((E,I)=>(g.set(E,I),()=>{g.delete(E)}),[g]),v=W(()=>{let E=Ez(g,t.current);return E&&g.get(E)?.controlRef.current||null}),R=W(async(E,I=!1)=>{h.current+=1;let A=h.current;function N(P,H=i){let B=f.current??m;if(B==null)return;let J=a.current.fields.get(B);if(!J)return;let Y=Bu(P,H);a.current.fields.set(B,{...J,validityData:Y})}function D(P,H){let B=P.valid===!1?H:[];return{value:E,state:P,error:B[0]??"",errors:B,initialValue:n.initialValue}}function F(P,H){let B=P.validity.customError?P.validationMessage:"",J=H.replace(/\r\n?/g,`
|
|
19
|
+
`);P.setCustomValidity(J),x.current=[P,J,B]}function k(){let P=x.current;x.current=null,P&&(!P[0].willValidate||P[0].validationMessage===P[1])&&P[0].setCustomValidity(P[2])}function z(P,H,B){let J=D(P,H);N(J,B),o(J)}function q(P){let H=XI.reduce((J,Y)=>(J[Y]=P.validity[Y],J),{}),B=!1;for(let J of XI)if(J!=="valid"){if(J==="valueMissing"&&H[J])B=!0;else if(H[J])return H}return B&&!l.current&&(H.valid=!0,H.valueMissing=!1),H}function O(){return g.size>0?Ez(g,t.current):b.current}let V=O();function w(){return V=O(),V?.willValidate?q(V):Az(!1)}if(I){if(u.valid!==!1||!V)return;if(!V.validity.valueMissing){k();let P=O(),H=P?.validity.customError?YI(P):[];z(Az(H.length>0),H,!1);return}for(let P of XI)if(P!=="valid"&&P!=="valueMissing"&&P!=="customError"&&V.validity[P])return}y.clear(),k();let _=w(),U=YI(V),X=c();if(U.length===0||X){let P=Array.from(a.current.fields.values()).reduce((J,Y)=>(Y.name&&(J[Y.name]=Y.getValue()),J),{}),H=r(E,P),B;if(typeof H=="object"&&H!==null&&"then"in H){if(_.valid===!1?z(_,U):(d==="onSubmit"||!n.state.customError)&&(_.valid=null,z(_,U)),B=await H,A!==h.current)return;_=w()}else B=H;U=B?[].concat(B).filter(Boolean):[],U.length>0?(_.valid=!1,_.customError=!0,V?.willValidate&&F(V,U.join(`
|
|
20
|
+
`))):U=YI(V)}z(_,U)}),L=W((E,I=!1)=>{if(y.clear(),h.current+=1,I)return;let A=c();A&&E!==""&&s?y.start(s,()=>{R(E)}):R(E,!A)}),C=gs.useCallback((E,I={})=>ja(p(I),u.valid===!1&&!u.disabled&&!E?{"aria-invalid":!0}:Ke),[p,u.disabled,u.valid]);return gs.useMemo(()=>({getValidationProps:C,inputRef:b,registeredInputs:g,registerInput:S,getInputControl:v,commit:R,change:L}),[C,g,S,v,R,L])}var Fb=T(M(),1);function Mz(e){let{change:t,commit:a,invalid:o,markedDirtyRef:r,name:n,setRegisteredFieldName:s,registeredFieldIdRef:i,setValidityData:l,validityData:u}=e,{formRef:c}=wr(),d=Fb.useRef(null),f=Fb.useRef(null),m=Fb.useRef(!1),p=W(()=>{let v=f.current;if(v)return v.getValue?v.getValue():v.value});function y(v){return v.value===void 0?p():v.value}let b=W(()=>{let v=f.current;if(r.current=!0,!v){a(u.value);return}a(y(v))});function g(){let v=f.current;!v||!v.id||c.current.fields.set(v.id,{getValue:p,name:n??v.name,controlRef:v.controlRef,validityData:Bu(u,o),validate:b})}function h(v=f.current?.id){v&&c.current.fields.delete(v)}function x(v){if(m.current)return;m.current=!0;let R=y(v);l(L=>L.initialValue===R?L:{...L,initialValue:R})}G(()=>{let v=f.current;!v||!v.id||(s(n?void 0:v.name),c.current.fields.set(v.id,{getValue:p,name:n??v.name,controlRef:v.controlRef,validityData:Bu(u,o),validate:b}))},[c,p,o,n,s,b,u]),G(()=>{let v=c.current.fields;return()=>{let R=f.current?.id;R&&v.delete(R)}},[c]);let S=W((v,R)=>{if(!R){d.current===v&&(d.current=null,t(void 0,!0),h(),f.current=null,s(void 0),i.current=void 0);return}let L=f.current?.id,C=d.current;C&&C!==v&&t(void 0,!0),d.current=v,f.current=R,n||s(R.name),i.current=R.id,L&&L!==R.id&&h(L),x(R),g()});return[b,S]}var _b=T(Q(),1),T9=Ia.forwardRef(function(t,a){let{errors:o,validationMode:r,submitCountRef:n}=wr(),{render:s,className:i,validate:l,validationDebounceTime:u=0,validationMode:c=r,name:d,disabled:f=!1,invalid:m,dirty:p,touched:y,actionsRef:b,style:g,...h}=t,x=Iz(!0)?.disabled,S=W(l||(()=>null)),v=x||f,[R,L]=Ia.useState(!1),[C,E]=Ia.useState(!1),[I,A]=Ia.useState(!1),[N,D]=Ia.useState(!1),F=p??C,k=y??R,z=Ia.useRef(F),q=Ia.useRef(void 0),[O,V]=Ia.useState(),w=d??O;G(()=>{p!==void 0&&(z.current=p)},[p]);let _=W(Ee=>{p===void 0&&(Ee&&(z.current=!0),E(Ee))}),U=W(Ee=>{y===void 0&&L(Ee)}),X=W(()=>c==="onChange"||c==="onSubmit"&&n.current>0),P=w&&Object.hasOwn(o,w)?o[w]:null,H=!!(Array.isArray(P)?P.length:P),B=m===!0||H,[J,Y]=Ia.useState({state:Vu,error:"",errors:[],value:null,initialValue:null}),te=!B&&(v?null:J.state.valid),ie=Ia.useMemo(()=>({disabled:v,touched:k,dirty:F,valid:te,filled:I,focused:N}),[v,k,F,te,I,N]),ce=Dz({setValidityData:Y,validate:S,validityData:J,validationDebounceTime:u,invalid:B,markedDirtyRef:z,state:ie,shouldValidateOnChange:X,validationMode:c,registeredFieldIdRef:q}),[ee,ae]=Mz({change:ce.change,commit:ce.commit,invalid:B,markedDirtyRef:z,name:d,setRegisteredFieldName:V,registeredFieldIdRef:q,setValidityData:Y,validityData:J});Ia.useImperativeHandle(b,()=>({validate:ee}),[ee]);let me=Ia.useMemo(()=>({invalid:B,name:w,validityData:J,setValidityData:Y,disabled:v,setTouched:U,setDirty:_,setFilled:A,setFocused:D,validationMode:c,shouldValidateOnChange:X,state:ie,registerFieldControl:ae,validation:ce}),[B,w,J,v,U,_,A,D,c,X,ie,ae,ce]),ge=$("div",t,{ref:a,state:ie,props:h,stateAttributesMapping:$a});return(0,_b.jsx)(qI.Provider,{value:me,children:ge})}),Pz=Ia.forwardRef(function(t,a){return(0,_b.jsx)(Nb,{children:(0,_b.jsx)(T9,{...t,ref:a})})});var mh=T(M(),1);var zb=T(M(),1),WI=zb.createContext({disabled:!1});function Hb(){return zb.useContext(WI)}var Oz=mh.forwardRef(function(t,a){let{render:o,className:r,style:n,id:s,nativeLabel:i=!0,...l}=t,u=sa(!1),c=Hb(),{labelId:d}=Ta(),f={...u.state,disabled:u.disabled||c.disabled},m=mh.useRef(null),p=Bb({id:d??s,native:i});return $("label",t,{ref:[a,m],state:f,props:[p,l],stateAttributesMapping:$a})});var Fu=T(M(),1);var KI=T(Q(),1),I9={...$a,...Ya},kz=Fu.forwardRef(function(t,a){let{render:o,id:r,className:n,match:s,style:i,...l}=t,u=It(r),{validityData:c,state:d,name:f}=sa(!1),{setMessageIds:m}=Ta(),{errors:p}=wr(),y=f&&Object.hasOwn(p,f)?p[f]:null,b=!!(Array.isArray(y)?y.length:y),g=typeof s=="string",h=!1;s===!0?h=!0:d.disabled?h=!1:g?h=!!c.state[s]:h=b||c.state.valid===!1;let{mounted:x,transitionStatus:S,setMounted:v}=ko(h);G(()=>{if(!(!h||!u))return m(z=>z.concat(u)),()=>{m(z=>z.filter(q=>q!==u))}},[h,u,m]);let R=Fu.useRef(null),[L,C]=Fu.useState(null),[E,I]=Fu.useState(null),A=c.error;!g&&b?A=y:c.errors.length>1&&(A=c.errors);let N=A;Array.isArray(A)&&(N=A.length>1?(0,KI.jsx)("ul",{children:A.map(z=>(0,KI.jsx)("li",{children:z},z))}):A[0]);let D=Array.isArray(A)?JSON.stringify(A):A;h&&D!==E&&(I(D),C(N)),Ra({open:h,ref:R,onComplete(){h||v(!1)}});let F={...d,transitionStatus:S},k=$("div",t,{ref:[a,R],state:F,props:[{id:u,children:h?N:L},l],stateAttributesMapping:I9,enabled:x});return x?k:null});var Nz=T(M(),1);var Vz=Nz.forwardRef(function(t,a){let{render:o,id:r,className:n,style:s,...i}=t,l=It(r),u=sa(!1),c=Hb(),{setMessageIds:d}=Ta(),f={...u.state,disabled:u.disabled||c.disabled};return G(()=>{if(l)return d(p=>p.concat(l)),()=>{d(p=>p.filter(y=>y!==l))}},[l,d]),$("p",t,{ref:a,state:f,props:[{id:l},i],stateAttributesMapping:$a})});var qb=T(M(),1);function Ub(e,t,a,o,r=!0,n){let{registerFieldControl:s}=sa(),i=at(()=>Symbol());G(()=>{let l=i.current;if(!r){s(l,void 0);return}s(l,{controlRef:e,getValue:o,id:t,name:n,value:a})},[e,r,o,t,n,s,i,a]),G(()=>{let l=i.current;return()=>{s(l,void 0)}},[s,i])}var Bz=qb.forwardRef(function(t,a){let{render:o,className:r,id:n,name:s,value:i,disabled:l=!1,onValueChange:u,defaultValue:c,autoFocus:d=!1,style:f,...m}=t,{state:p,name:y,disabled:b,setTouched:g,setDirty:h,validityData:x,setFocused:S,setFilled:v,validationMode:R,validation:L}=sa(),{clearErrors:C,elementRef:E,submitCountRef:I}=wr(),A=b||l,N=y??s,D={...p,disabled:A},{labelId:F}=Ta(),k=sd({id:n}),[z]=Ou({controlled:i,default:c,name:"FieldControl",state:"value"}),q=i!==void 0,O=q?z:void 0,V=O==null?void 0:String(O),w=W(()=>L.inputRef.current?.value);Ub(L.inputRef,k,V,w,!A,s),G(()=>{let P=V??L.inputRef.current?.value;P!==void 0&&v(P!=="")},[V,L.inputRef,v]),qf(V,()=>{V!==void 0&&(C(N),h(V!==(x.initialValue??"")),L.change(V))});let _=qb.useRef(null),U=Qe();return G(()=>{d&&_.current===_t(ve(_.current))&&S(!0)},[d,S]),$("input",t,{ref:[a,_],state:D,props:[{id:k,disabled:A,name:N,ref:L.inputRef,"aria-labelledby":F,autoFocus:d,...q?{value:O}:{defaultValue:c},onChange(P){let H=P.currentTarget.value,B=he(ne.none,P.nativeEvent);u?.(H,B),!q&&(h(H!==(x.initialValue??"")),v(H!==""),!P.nativeEvent.defaultPrevented&&!B.isCanceled&&(C(N),L.change(H)))},onFocus(){S(!0)},onBlur(P){if(g(!0),S(!1),R==="onBlur"){let H=P.currentTarget.value;L.commit(H),q&&queueMicrotask(()=>{let B=L.inputRef.current?.value;B!==void 0&&B!==H&&B!==(x.initialValue??"")&&L.commit(B)})}},onKeyDown(P){if(P.currentTarget.tagName==="INPUT"&&P.key==="Enter"){g(!0);let H=P.currentTarget.value,B=P.currentTarget.form;if(B&&B===E.current&&!P.defaultPrevented){let J=P.currentTarget,Y=I.current;U.start(0,()=>{I.current===Y&&L.commit(J.value)})}else L.commit(H)}}},m,P=>L.getValidationProps(A,P)],stateAttributesMapping:$a})});var ph=T(M(),1);var Fz=T(Q(),1),_z=function(t){let{children:a}=t,{validityData:o,invalid:r}=sa(!1),n=ph.useMemo(()=>Bu(o,r),[o,r]),s=n.state.valid===!1,{transitionStatus:i}=ko(s),l=ph.useMemo(()=>({...n,validity:n.state,transitionStatus:i}),[n,i]);return(0,Fz.jsx)(ph.Fragment,{children:a(l)})};var Gb=T(M(),1);var ZI=T(Q(),1),zz=Gb.forwardRef(function(t,a){let{render:o,className:r,style:n,disabled:s=!1,...i}=t,{state:l,disabled:u}=sa(!1),c=u||s,d={...l,disabled:c},f=Gb.useMemo(()=>({disabled:c}),[c]),m=$("div",t,{ref:a,state:d,props:i,stateAttributesMapping:$a});return(0,ZI.jsx)(Nb,{children:(0,ZI.jsx)(WI.Provider,{value:f,children:m})})});var Uz=T(Q(),1),QI=Hz.forwardRef(function(t,a){return(0,Uz.jsx)(jb.Control,{ref:a,...t})});var qz=T(Q(),1);function Xb({className:e,type:t,...a}){return(0,qz.jsx)(QI,{type:t,"data-slot":"input",className:re("h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40",e),...a})}var eo={};Aa(eo,{Arrow:()=>VH,Backdrop:()=>yH,Group:()=>XH,GroupLabel:()=>WH,Icon:()=>mH,Item:()=>MH,ItemIndicator:()=>OH,ItemText:()=>kH,Label:()=>sH,List:()=>AH,Popup:()=>wH,Portal:()=>gH,Positioner:()=>vH,Root:()=>aH,ScrollDownArrow:()=>zH,ScrollUpArrow:()=>qH,Separator:()=>QH,Trigger:()=>uH,Value:()=>fH});var zt=T(M(),1);var Gz=T(M(),1);function jz(e){let t=Gz.useRef(!0);t.current&&(t.current=!1,e())}var Yi=T(M(),1),JI=Yi.createContext(void 0),$I=Yi.createContext(void 0),ew=Yi.createContext(void 0);function wt(){let e=Yi.useContext(JI);if(e===void 0)throw new Error(Me(60));return e}function Wi(){let e=Yi.useContext($I);if(e===void 0)throw new Error(Me(101));return e}function Yb(){let e=Yi.useContext(ew);if(e===void 0)throw new Error(Me(61));return e}function Xz(e,t,a=Object.is){let{length:o}=e;if(o!==t.length)return!1;for(let r=0;r<o;r+=1)if(!a(e[r],t[r]))return!1;return!0}var aw=(e,t)=>Object.is(e,t);function xs(e,t,a){return e==null||t==null?Object.is(e,t):a(e,t)}function Yz(e,t,a){return Array.isArray(e)&&Array.isArray(t)?!Xz(e,t,(o,r)=>xs(o,r,a)):e!==t}function tw(e,t,a){return e?e.some(o=>o===void 0?!1:xs(t,o,a)):!1}function hh(e,t,a){return e?e.findIndex(o=>o===void 0?!1:xs(o,t,a)):-1}function w9(e,t){if(t!==aw)return o=>tw(e,o,t);let a=new Set(e);return a.delete(void 0),o=>a.has(o)&&(o!==0||e.some(r=>Object.is(o,r)))}function ow(e,t,a,o){let r=o&&Array.isArray(t)?e.findIndex(w9(t,a)):hh(e,t,a);return r===-1?null:r}function Wz(e,t,a,o,r,n){return tw(o,t,r)?n!=null&&e>n&&tw(o,a[n],r)?n:e:e===n?ow(a,o,r,!0):n}function Kz(e,t,a){return e.filter(o=>!xs(t,o,a))}var Zz=T(M(),1);function Wb(e){if(e==null)return"";if(typeof e=="string")return e;try{return JSON.stringify(e)}catch{return String(e)}}var Qz=T(Q(),1);function E9(e){return typeof e=="object"&&e!=null&&Array.isArray(e.items)}function Jz(e){return E9(e?.[0])}function A9(e){return Jz(e)?e.flatMap(t=>t.items):e}function $z(e){if(!Array.isArray(e))return e!=null&&"null"in e;let t=e;if(Jz(t)){for(let a of t)for(let o of a.items)if(o&&o.value==null&&o.label!=null)return!0;return!1}for(let a of t)if(a&&a.value==null&&a.label!=null)return!0;return!1}function rw(e,t){if(t&&e!=null)return t(e)??"";if(e&&typeof e=="object"){if("label"in e&&e.label!=null)return String(e.label);if("value"in e)return String(e.value)}return Wb(e)}function Ki(e,t){return t&&e!=null?t(e)??"":e&&typeof e=="object"&&"value"in e&&"label"in e?Wb(e.value):Wb(e)}function nw(e,t,a){function o(){return rw(e,a)}if(a&&e!=null)return a(e);if(e&&typeof e=="object"&&"label"in e&&e.label!=null)return e.label;if(t&&!Array.isArray(t))return(Object.hasOwn(t,e)?t[e]:void 0)??o();if(Array.isArray(t)){let n=A9(t);if(e==null||typeof e!="object"){let s=n.find(i=>i.value===e);return s&&s.label!=null?s.label:o()}if("value"in e){let s=n.find(i=>i&&i.value===e.value);if(s&&s.label!=null)return s.label}}return o()}function eH(e,t,a){return e.reduce((o,r,n)=>(n>0&&o.push(", "),o.push((0,Qz.jsx)(Zz.Fragment,{children:nw(r,t,a)},n)),o),[])}var tH={id:e=>e.id,labelId:e=>e.labelId,modal:e=>e.modal,items:e=>e.items,itemToStringLabel:e=>e.itemToStringLabel,isItemEqualToValue:e=>e.isItemEqualToValue,value:e=>e.value,hasSelectedValue:e=>{let{value:t,multiple:a,itemToStringValue:o}=e;return t==null?!1:a&&Array.isArray(t)?t.length>0:Ki(t,o)!==""},hasNullItemLabel:(e,t)=>t?$z(e.items):!1,open:e=>e.open,mounted:e=>e.mounted,forceMount:e=>e.forceMount,transitionStatus:e=>e.transitionStatus,openMethod:e=>e.openMethod,activeIndex:e=>e.activeIndex,selectedIndex:e=>e.selectedIndex,isActive:(e,t)=>e.activeIndex===t,isSelected:(e,t)=>{let a=e.isItemEqualToValue,o=e.value;return e.multiple?Array.isArray(o)&&o.some(r=>xs(t,r,a)):xs(t,o,a)},isSelectedByFocus:(e,t)=>e.selectedIndex===t,popupProps:e=>e.popupProps,triggerProps:e=>e.triggerProps,triggerElement:e=>e.triggerElement,positionerElement:e=>e.positionerElement,listElement:e=>e.listElement,popupSide:e=>e.popupSide,scrollUpArrowVisible:e=>e.scrollUpArrowVisible,scrollDownArrowVisible:e=>e.scrollDownArrowVisible,hasScrollArrows:e=>e.hasScrollArrows};function Er(e,t=Number.MIN_SAFE_INTEGER,a=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,a))}var er=1;function id(e,t){return Math.max(0,e-t)}function ys(e,t){if(t<=0)return 0;let a=Er(e,0,t),o=a,r=t-a,n=o<=er,s=r<=er;return n&&s?o<=r?0:t:n?0:s?t:a}var _u=T(Q(),1);function aH(e){let{id:t,value:a,defaultValue:o=null,onValueChange:r,open:n,defaultOpen:s=!1,onOpenChange:i,name:l,form:u,autoComplete:c,disabled:d=!1,readOnly:f=!1,required:m=!1,modal:p=!0,actionsRef:y,inputRef:b,onOpenChangeComplete:g,items:h,multiple:x=!1,itemToStringLabel:S,itemToStringValue:v,isItemEqualToValue:R=aw,highlightItemOnHover:L=!0,children:C}=e,{clearErrors:E}=wr(),{setDirty:I,setTouched:A,setFocused:N,validityData:D,setFilled:F,name:k,disabled:z,validation:q,validationMode:O}=sa(),V=sd({id:t}),w=z||d,_=k??l,[U,X]=Ou({controlled:a,default:x?o??Io:o,name:"Select",state:"value"}),[P,H]=Ou({controlled:n,default:s,name:"Select",state:"open"}),B=zt.useRef([]),J=zt.useRef([]),Y=zt.useRef(null),te=zt.useRef(null),ie=zt.useRef(0),ce=zt.useRef(null),ee=zt.useRef([]),ae=zt.useRef(!1),me=zt.useRef(null),ge=zt.useRef(null),Ee=zt.useRef({allowSelectedMouseUp:!1,allowUnselectedMouseUp:!1,dragY:0}),pe=zt.useRef(!1),Te=zt.useRef(U),{mounted:le,setMounted:Ie,transitionStatus:Be}=ko(P),{openMethod:Oe,triggerProps:ut}=_F(P),oe=at(()=>new Tr({id:V,labelId:void 0,modal:p,multiple:x,itemToStringLabel:S,itemToStringValue:v,isItemEqualToValue:R,value:U,open:P,mounted:le,transitionStatus:Be,items:h,forceMount:!1,openMethod:null,activeIndex:null,selectedIndex:null,popupProps:Ke,triggerProps:Ke,triggerElement:null,positionerElement:null,listElement:null,popupSide:null,scrollUpArrowVisible:!1,scrollDownArrowVisible:!1,hasScrollArrows:!1},{setValue:Ve,setOpen:Ve,handleScrollArrowVisibility:Ve,onOpenChangeComplete:Ve,listRef:B,popupRef:Y,scrollHandlerRef:te,scrollArrowsMountedCountRef:ie,valueRef:ce,valuesRef:ee,labelsRef:J,typingRef:ae,selectionRef:Ee,firstItemTextRef:me,selectedItemTextRef:ge,alignItemWithTriggerActiveRef:pe,initialValueRef:Te},tH)).current,fe=oe.useState("activeIndex"),K=oe.useState("selectedIndex"),j=oe.useState("triggerElement"),se=oe.useState("positionerElement"),Fe=wb(Oe),Vt=Oe??Fe,Jt=zt.useMemo(()=>x?"":Ki(U,v),[x,U,v]),Et=zt.useMemo(()=>x&&Array.isArray(U)?U.map(Ze=>Ki(Ze,v)):Ki(U,v),[x,U,v]),bt=pt(j),wa=W(()=>Et);Ub(bt,V,U,wa,!w,l);let Ea=x?Array.isArray(U)&&U.length>0:U!=null&&Jt!=="";G(()=>{F(Ea)},[Ea,F]),G(function(){let Mt=ow(ee.current,U,R,x);Mt===null&&(ge.current=null),!P&&oe.set("selectedIndex",Mt)},[x,P,U,R,oe]),qf(U,()=>{E(_),I(Yz(U,D.initialValue,R)),q.change(U)});let $t=W((Ze,Mt)=>{i?.(Ze,Mt),!Mt.isCanceled&&(H(Ze),!Ze&&(Mt.reason===ne.focusOut||Mt.reason===ne.outsidePress)&&(A(!0),N(!1),O==="onBlur"&&q.commit(U)))}),Ha=W(()=>{Ie(!1),oe.update({activeIndex:null,openMethod:null,scrollUpArrowVisible:!1,scrollDownArrowVisible:!1}),g?.(!1)});Ra({enabled:!y,open:P,ref:Y,onComplete(){P||Ha()}}),zt.useImperativeHandle(y,()=>({unmount:Ha}),[Ha]);let ho=W((Ze,Mt)=>{r?.(Ze,Mt),!Mt.isCanceled&&X(Ze)}),tr=W(Ze=>{let Mt=id(Ze.scrollHeight,Ze.clientHeight),Nn=ys(Ze.scrollTop,Mt),nl=Nn>0,sl=Nn<Mt;oe.set("scrollUpArrowVisible",nl),oe.set("scrollDownArrowVisible",sl)}),ha=dI({open:P,onOpenChange:$t,elements:{reference:j,floating:se}}),Ht=Qp(ha,{enabled:!w,event:"mousedown"}),Ae=Eu(ha),Dt=bI(ha,{enabled:!w,listRef:B,activeIndex:fe,selectedIndex:K,disabledIndices:Io,onNavigate(Ze){Ze===null&&!P||oe.set("activeIndex",Ze)},focusItemOnHover:L}),Je=vI(ha,{enabled:!w&&(P||!f&&!x),listRef:J,activeIndex:fe,selectedIndex:K,disabledIndices:Ze=>cb(B.current[Ze]),onMatch(Ze){P?oe.set("activeIndex",Ze):ho(ee.current[Ze],he(ne.none))},onTyping(Ze){ae.current=Ze}}),Bt=zt.useMemo(()=>ja(Je.reference,Dt.reference,Ae.reference,Ht.reference,ut),[Ht.reference,Je.reference,Dt.reference,Ae.reference,ut]),go=zt.useMemo(()=>ja(Ff,Je.floating,Dt.floating,Ae.floating),[Je.floating,Dt.floating,Ae.floating]),xo=Dt.item??Ke;oe.useContextCallback("setValue",ho),oe.useContextCallback("setOpen",$t),oe.useContextCallback("handleScrollArrowVisibility",tr),oe.useContextCallback("onOpenChangeComplete",g),jz(()=>{oe.update({popupProps:go,triggerProps:Bt})}),oe.useSyncedValues({id:V,modal:p,multiple:x,value:U,open:P,mounted:le,transitionStatus:Be,popupProps:go,triggerProps:Bt,items:h,itemToStringLabel:S,itemToStringValue:v,isItemEqualToValue:R,openMethod:Vt});let Gu=zt.useMemo(()=>({disabled:w,readOnly:f,required:m,multiple:x,highlightItemOnHover:L,itemProps:xo}),[w,f,m,x,L,xo]),Cs=mr(b,q.inputRef),rl=x?void 0:_,Wr=zt.useMemo(()=>!x||!Array.isArray(U)||!_?null:U.map(Ze=>{let Mt=Ki(Ze,v);return(0,_u.jsx)("input",{type:"hidden",form:u,name:_,value:Mt,disabled:w},Mt)}),[x,U,u,_,v,w]);return(0,_u.jsxs)(JI.Provider,{value:oe,children:[(0,_u.jsx)($I.Provider,{value:Gu,children:(0,_u.jsx)(ew.Provider,{value:ha,children:C})}),(0,_u.jsx)("input",{...q.getValidationProps(w,{onFocus(){oe.state.triggerElement?.focus({focusVisible:!0})},onChange(Ze){if(Ze.nativeEvent.defaultPrevented||w||f)return;let Mt=Ze.currentTarget.value,Nn=he(ne.none,Ze.nativeEvent);function nl(){if(x)return;let sl=Mt.toLowerCase(),bd=ee.current.findIndex(Iv=>Ki(Iv,v).toLowerCase()===sl||rw(Iv,S).toLowerCase()===sl);bd===-1&&(bd=ee.current.findIndex((Iv,i3)=>{let Tw=J.current[i3];return Tw!=null&&Tw.toLowerCase()===sl}));let Rw=ee.current[bd];Rw!=null&&ho(Rw,Nn)}oe.set("forceMount",!0),queueMicrotask(nl)}}),id:V&&rl==null?`${V}-hidden-input`:void 0,form:u,name:rl,autoComplete:c,value:Jt,disabled:w,required:m&&!(x&&Ea),readOnly:f,ref:Cs,style:_?OB:Df,tabIndex:-1,"aria-hidden":!0,suppressHydrationWarning:!0}),Wr]})}var nH=T(M(),1);function oH(e){return e==null?void 0:`${e}-label`}function rH(e,t){return e??t}var sH=nH.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,i=s;delete i.id;let l=sa(),u=wt(),c=u.useState("triggerElement"),d=u.useState("id"),f=oH(d),m=Bb({id:f,fallbackControlId:c?.id??d,setLabelId(p){let y=typeof p=="function"?p(u.state.labelId):p;u.set("labelId",y)}});return $("div",t,{ref:a,state:l.state,props:[m,s],stateAttributesMapping:$a})});var ld=T(M(),1);var Kb=5;function iH(e,t){let a=D9(t);return e.clientX>=a.left-Kb&&e.clientX<=a.right+Kb&&e.clientY>=a.top-Kb&&e.clientY<=a.bottom+Kb}function D9(e){let t=e.getBoundingClientRect(),a=He(e);if(ot.env.jsdom)return t;let o=a.getComputedStyle(e,"::before"),r=a.getComputedStyle(e,"::after");if(!(o.content!=="none"||r.content!=="none"))return t;let s=parseFloat(o.width)||0,i=parseFloat(o.height)||0,l=parseFloat(r.width)||0,u=parseFloat(r.height)||0,c=Math.max(t.width,s,l),d=Math.max(t.height,i,u),f=c-t.width,m=d-t.height;return{left:t.left-f/2,right:t.right+f/2,top:t.top-m/2,bottom:t.bottom+m/2}}var lMe=yu.popupOpen,uMe=yu.pressed;var lH="data-popup-side";var P9=400,O9={...cB,...$a,popupSide:e=>e?{[lH]:e}:null,value:()=>null},uH=ld.forwardRef(function(t,a){let{render:o,className:r,id:n,disabled:s=!1,nativeButton:i=!0,style:l,...u}=t,{setTouched:c,setFocused:d,validationMode:f,validation:m,state:p,disabled:y}=sa(),{labelId:b}=Ta(),g=wt(),{readOnly:h,required:x,disabled:S}=Wi(),v=y||S||s,R=g.useState("open"),L=g.useState("mounted"),C=g.useState("value"),E=g.useState("triggerProps"),I=g.useState("positionerElement"),A=g.useState("listElement"),N=g.useState("popupSide"),D=g.useState("id"),F=g.useState("labelId"),k=g.useState("hasSelectedValue"),z=L&&I?N:null,q=n??D,O=rH(b,F);sd({id:n});let V=pt(I),w=ld.useRef(null),{getButtonProps:_,buttonRef:U}=Qo({disabled:v,native:i}),X=g.useStateSetter("triggerElement"),P=Qe(),H=Qe(),B=Qe();ld.useEffect(()=>{if(R)return B.start(P9,()=>{g.context.selectionRef.current.allowUnselectedMouseUp=!0,g.context.selectionRef.current.allowSelectedMouseUp=!0}),()=>{B.clear()};g.context.selectionRef.current={allowSelectedMouseUp:!1,allowUnselectedMouseUp:!1,dragY:0},H.clear()},[R,g,H,B]);let J=ja(E,{id:q,role:"combobox","aria-expanded":R,"aria-haspopup":"listbox","aria-controls":R?A?.id??Cu(I)?.id:void 0,"aria-labelledby":O,"aria-readonly":h||void 0,"aria-required":x||void 0,tabIndex:v?-1:0,onFocus(ie){d(!0),R&&g.context.alignItemWithTriggerActiveRef.current&&g.context.setOpen(!1,he(ne.none,ie.nativeEvent)),P.start(0,()=>{g.set("forceMount",!0)})},onBlur(ie){ue(I,ie.relatedTarget)||(c(!0),d(!1),f==="onBlur"&&m.commit(C))},onMouseDown(ie){if(R)return;let ce=ve(ie.currentTarget);function ee(ae){if(!w.current)return;let me=ae.target;ue(w.current,me)||ue(V.current,me)||iH(ae,w.current)||g.context.setOpen(!1,he(ne.cancelOpen,ae))}H.start(0,()=>{ce.addEventListener("mouseup",ee,{once:!0})})}},u,_),Y=m.getValidationProps(v,J);Y.role="combobox";let te={...p,open:R,disabled:v,value:C,readOnly:h,popupSide:z,placeholder:!k};return $("button",t,{ref:[a,w,U,X],state:te,stateAttributesMapping:O9,props:Y})});var cH=T(M(),1);var k9={value:()=>null},fH=cH.forwardRef(function(t,a){let{className:o,render:r,children:n,placeholder:s,style:i,...l}=t,u=wt(),c=u.useState("value"),d=u.useState("items"),f=u.useState("itemToStringLabel"),m=u.useState("hasSelectedValue"),p=!m&&s!=null&&n==null,y=u.useState("hasNullItemLabel",p),b={value:c,placeholder:!m},g=null;return typeof n=="function"?g=n(c):n!=null?g=n:p&&!y?g=s:Array.isArray(c)?g=eH(c,d,f):g=nw(c,d,f),$("span",t,{state:b,ref:[a,u.context.valueRef],props:[{children:g},l],stateAttributesMapping:k9})});var dH=T(M(),1);var mH=dH.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,u={open:wt().useState("open")};return $("span",t,{state:u,ref:a,props:[{"aria-hidden":!0,children:"\u25BC"},s],stateAttributesMapping:If})});var pH=T(M(),1);var hH=T(Q(),1),gH=pH.forwardRef(function(t,a){let o=wt(),r=o.useState("mounted"),n=o.useState("forceMount");return r||n?(0,hH.jsx)(Yp,{ref:a,...t}):null});var xH=T(M(),1);var N9={...Hr,...Ya},yH=xH.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,i=wt(),l=i.useState("open"),u=i.useState("mounted"),c=i.useState("transitionStatus");return $("div",t,{state:{open:l,transitionStatus:c},ref:a,props:[{role:"presentation",hidden:!u,style:{userSelect:"none",WebkitUserSelect:"none"}},s],stateAttributesMapping:N9})});var Ar=T(M(),1);var Zb=T(M(),1),sw=Zb.createContext(void 0);function Zi(){let e=Zb.useContext(sw);if(!e)throw new Error(Me(59));return e}function ud(e,t){e&&Object.assign(e.style,t)}var Qb={position:"relative",maxHeight:"100%",overflowX:"hidden",overflowY:"auto"};var SH=T(M(),1);var V9=20;function bH(e,t,a,o){let[r,n]=SH.useState(!1);G(()=>{if(!e||!t||a==null){n(!1);return}let s=ve(a).documentElement.clientWidth,i=a.offsetWidth;n(s>0&&i>0&&i>=s-V9)},[e,t,a]),eb(e&&(!t||r),o)}var gh=T(Q(),1),B9={position:"fixed"},vH=Ar.forwardRef(function(t,a){let{anchor:o,className:r,render:n,positionMethod:s,side:i,align:l,sideOffset:u,alignOffset:c,collisionBoundary:d="clipping-ancestors",collisionPadding:f,arrowPadding:m,sticky:p,disableAnchorTracking:y,alignItemWithTrigger:b=!0,collisionAvoidance:g=e2,style:h,...x}=t,S=wt(),v=Yb(),R=S.useState("open"),L=S.useState("mounted"),C=S.useState("modal"),E=S.useState("value"),I=S.useState("openMethod"),A=S.useState("positionerElement"),N=S.useState("triggerElement"),D=S.useState("isItemEqualToValue"),F=S.useState("transitionStatus"),k=Ar.useRef(null),z=Ar.useRef(null),[q,O]=Ar.useState(b),V=L&&q&&I!=="touch";!L&&q!==b&&O(b),Ar.useImperativeHandle(S.context.alignItemWithTriggerActiveRef,()=>V),bH((V||C)&&R,I==="touch",A,N);let w=Rb({anchor:o,floatingRootContext:v,positionMethod:s,mounted:L,side:i,sideOffset:u,align:l,alignOffset:c,arrowPadding:m,collisionBoundary:d,collisionPadding:f,sticky:p,disableAnchorTracking:y??V,collisionAvoidance:g,keepMounted:!0}),_=V?"none":w.side,U=V?B9:w.positionerStyles,X={open:R,side:_,align:w.align,anchorHidden:w.anchorHidden};G(()=>{S.set("popupSide",w.side)},[S,w.side]);let P=S.useStateSetter("positionerElement"),H=Tb(t,X,{styles:U,transitionStatus:F,props:x,refs:[a,P],hidden:!L,inert:!R}),B=Ar.useRef(0),J=W(te=>{if(S.context.valuesRef.current.length===0)return;let ie=B.current;B.current=te.size;let ce=he(ne.none);if(ie!==0&&!S.state.multiple&&E!==null&&hh(S.context.valuesRef.current,E,D)===-1){let ae=S.context.initialValueRef.current,ge=ae!=null&&hh(S.context.valuesRef.current,ae,D)!==-1?ae:null;S.context.setValue(ge,ce),ge===null&&(S.set("selectedIndex",null),S.context.selectedItemTextRef.current=null)}if(ie!==0&&S.state.multiple&&Array.isArray(E)){let ee=E.filter(ae=>hh(S.context.valuesRef.current,ae,D)!==-1);ee.length!==E.length&&(S.context.setValue(ee,ce),ee.length===0&&(S.set("selectedIndex",null),S.context.selectedItemTextRef.current=null))}if(R&&V){S.update({scrollUpArrowVisible:!1,scrollDownArrowVisible:!1});let ee={height:""};ud(A,ee),ud(S.context.popupRef.current,ee)}}),Y=Ar.useMemo(()=>({...w,side:_,alignItemWithTriggerActive:V,setControlledAlignItemWithTrigger:O,scrollUpArrowRef:k,scrollDownArrowRef:z}),[w,_,V,O]);return(0,gh.jsx)(Gf,{elementsRef:S.context.listRef,labelsRef:S.context.labelsRef,onMapChange:J,children:(0,gh.jsxs)(sw.Provider,{value:Y,children:[L&&C&&(0,gh.jsx)(JS,{inert:Gi(!R),cutout:N}),H]})})});var Dr=T(M(),1);var CH=T(Q(),1),Jb="base-ui-disable-scrollbar",Ss={className:Jb,getElement(e){return(0,CH.jsx)("style",{nonce:e,href:Jb,precedence:"base-ui:low",children:`.${Jb}{scrollbar-width:none}.${Jb}::-webkit-scrollbar{display:none}`})}};var $b=T(M(),1),F9=$b.createContext(void 0);function LH(e){let t=$b.useContext(F9);if(t===void 0&&!e)throw new Error(Me(69));return t}var iw="--transform-origin";var av=T(Q(),1),z9={...Hr,...Ya},wH=Dr.forwardRef(function(t,a){let{render:o,className:r,style:n,finalFocus:s,...i}=t,l=wt(),{multiple:u,readOnly:c,highlightItemOnHover:d}=Wi(),f=Yb(),{side:m,align:p,alignItemWithTriggerActive:y,isPositioned:b,setControlledAlignItemWithTrigger:g}=Zi(),h=LH(!0)!=null,x=No(),{nonce:S,disableStyleElements:v}=Xf(),R=l.useState("id"),L=l.useState("open"),C=l.useState("openMethod"),E=l.useState("mounted"),I=l.useState("popupProps"),A=l.useState("transitionStatus"),N=l.useState("triggerElement"),D=l.useState("positionerElement"),F=l.useState("listElement"),k=Dr.useRef(!1),z=Dr.useRef(!1),q=Dr.useRef({}),O=co(),V=W(X=>{if(!D||!l.context.popupRef.current||!z.current)return;let P=D.style.top==="0px",H=D.style.bottom==="0px";if(k.current||!y||!P&&!H){l.context.handleScrollArrowVisibility(X);return}let B=TH(D),J=xh(D.getBoundingClientRect().height,"y",B),Y=ve(D),te=He(D),ie=te.getComputedStyle(D),ce=parseFloat(ie.marginTop),ee=parseFloat(ie.marginBottom),ae=RH(te.getComputedStyle(l.context.popupRef.current)),me=Math.min(Y.documentElement.clientHeight-ce-ee,ae),ge=X.scrollTop,Ee=ev(X),pe=null,Te=Oe=>{D.style.height=`${Oe}px`},le=P?Ee-ge:ge,Ie=Math.min(J+le,me);if(le<=er){let Oe=Er(le,0,me-J);Oe>0&&Te(J+Oe),X.scrollTop=P?Ee:0,me-(J+Oe)<=er&&(k.current=!0),l.context.handleScrollArrowVisibility(X);return}if(me-Ie>er)pe=P?1/0:0;else if(H&&ge<Ee){let Oe=J+le-me;pe=ge-(le-Oe)}let Be=Math.ceil(Ie);if(Be!==0&&Te(Be),pe!=null){let Oe=Er(pe,0,ev(X));Math.abs(X.scrollTop-Oe)>er&&(X.scrollTop=Oe)}Be>=me-er&&(k.current=!0),l.context.handleScrollArrowVisibility(X)});Dr.useImperativeHandle(l.context.scrollHandlerRef,()=>V,[V]),Ra({open:L,ref:l.context.popupRef,onComplete(){L&&l.context.onOpenChangeComplete(!0)}});let w={open:L,transitionStatus:A,side:m,align:p};G(()=>{!D||!l.context.popupRef.current||Object.keys(q.current).length||(q.current={top:D.style.top||"0",left:D.style.left||"0",right:D.style.right,height:D.style.height,bottom:D.style.bottom,minHeight:D.style.minHeight,maxHeight:D.style.maxHeight,marginTop:D.style.marginTop,marginBottom:D.style.marginBottom})},[l,D]),G(()=>{L||y||(z.current=!1,k.current=!1,ud(D,q.current))},[L,y,D]),G(()=>{let X=l.context.popupRef.current;if(!L||!N||!D||!X||y&&!b||l.state.transitionStatus==="ending")return;if(z.current=!0,X.style.removeProperty(iw),!y){O.request(()=>l.context.handleScrollArrowVisibility(F||X));return}let P=H9(X);try{let H=l.context.selectedItemTextRef.current;H?.isConnected||(H=!l.select("hasSelectedValue")&&l.context.firstItemTextRef.current?.isConnected?l.context.firstItemTextRef.current:null);let B=l.context.valueRef.current,J=He(D),Y=J.getComputedStyle(D),te=J.getComputedStyle(X),ie=ve(N),ce=TH(N),ee=tv(N.getBoundingClientRect(),ce),ae=tv(D.getBoundingClientRect(),ce),me=ee.height,ge=F||X,Ee=ge.scrollHeight,pe=parseFloat(te.borderBottomWidth),Te=parseFloat(Y.marginTop)||10,le=parseFloat(Y.marginBottom)||10,Ie=parseFloat(Y.minHeight)||100,Be=RH(te),Oe=5,ut=5,oe=20,fe=ie.documentElement.clientHeight-Te-le,K=ie.documentElement.clientWidth,j=fe-ee.bottom+me,se,Fe=x==="rtl"?ee.right-ae.width:ee.left,Vt=0;if(H&&B){let Ht=tv(B.getBoundingClientRect(),ce);se=tv(H.getBoundingClientRect(),ce),Fe=ae.left+(x==="rtl"?Ht.right-se.right:Ht.left-se.left);let Ae=Ht.top-ee.top+Ht.height/2;Vt=se.top-ae.top+se.height/2-Ae}let Jt=j+Vt+le+pe,Et=Math.min(fe,Jt),bt=fe-Te-le,wa=Jt-Et,Ea=K-ut;D.style.left=`${Er(Fe,Oe,Ea-ae.width)}px`,D.style.height=`${Et}px`,D.style.maxHeight="none",D.style.marginTop=`${Te}px`,D.style.marginBottom=`${le}px`,X.style.height="100%";let $t=ev(ge),Ha=wa>=$t-er;Ha&&(Et=Math.min(fe,ae.height)-(wa-$t));let ho=ee.top<oe||ee.bottom>fe-oe||Math.ceil(Et)+er<Math.min(Ee,Ie),tr=(J.visualViewport?.scale??1)!==1&&ot.engine.webkit;if(ho||tr){ud(D,q.current),g(!1);return}let ha=Math.max(Ie,Et);if(Ha){let Ht=Math.max(0,fe-Jt);D.style.top=ae.height>=bt?"0":`${Ht}px`,D.style.height=`${Et}px`,ge.scrollTop=ev(ge)}else D.style.bottom="0",ge.scrollTop=wa;if(se){let Ht=ae.top,Ae=ae.height,Dt=se.top+se.height/2,Je=Er(Ae>0?(Dt-Ht)/Ae*100:50,0,100);X.style.setProperty(iw,`50% ${Je}%`)}(ha===fe||Et>=Be)&&(k.current=!0),l.context.handleScrollArrowVisibility(ge),d&&l.state.selectedIndex===null&&l.state.activeIndex===null&&l.context.listRef.current[0]!=null&&l.set("activeIndex",0)}finally{P()}},[l,L,D,N,y,g,O,F,d,x,b]),Dr.useEffect(()=>{if(!y||!D||!L)return;let X=He(D);function P(H){l.context.setOpen(!1,he(ne.windowResize,H))}return Re(X,"resize",P)},[l,y,D,L]);let _={...F?{role:"presentation"}:{role:"listbox","aria-multiselectable":u||void 0,"aria-readonly":c||void 0,id:`${R}-list`},onKeyDown(X){h&&Hf.has(X.key)&&X.stopPropagation()},onScroll(X){F||V(X.currentTarget)},...y&&{style:F?{height:"100%"}:Qb},className:!F&&y?Ss.className:void 0},U=$("div",t,{ref:[a,l.context.popupRef],state:w,stateAttributesMapping:z9,props:[I,_,ed(A),i]});return(0,av.jsxs)(Dr.Fragment,{children:[!v&&Ss.getElement(S),(0,av.jsx)(Kp,{context:f,modal:!1,disabled:!E,openInteractionType:C,returnFocus:s,restoreFocus:!0,children:U})]})});function RH(e){let t=e.maxHeight;return t.endsWith("px")&&parseFloat(t)||1/0}function ev(e){return id(e.scrollHeight,e.clientHeight)}function TH(e){return Jp.getScale(e)}function xh(e,t,a){return e/a[t]}function tv(e,t){return cs({x:xh(e.x,"x",t),y:xh(e.y,"y",t),width:xh(e.width,"x",t),height:xh(e.height,"y",t)})}var IH=[["transform","none"],["scale","1"],["translate","0 0"]];function H9(e){let{style:t}=e,a={};for(let[o,r]of IH)a[o]=t.getPropertyValue(o),t.setProperty(o,r,"important");return()=>{for(let[o]of IH){let r=a[o];r?t.setProperty(o,r):t.removeProperty(o)}}}var EH=T(M(),1);var AH=EH.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,i=wt(),{multiple:l,readOnly:u}=Wi(),{alignItemWithTriggerActive:c}=Zi(),d=i.useState("hasScrollArrows"),f=i.useState("openMethod"),p={id:`${i.useState("id")}-list`,role:"listbox","aria-multiselectable":l||void 0,"aria-readonly":u||void 0,onScroll(b){i.context.scrollHandlerRef.current?.(b.currentTarget)},...c&&{style:Qb},className:d&&f!=="touch"?Ss.className:void 0},y=i.useStateSetter("listElement");return $("div",t,{ref:[a,y],props:[p,s]})});var Xr=T(M(),1);var ov=T(M(),1),lw=ov.createContext(void 0);function yh(){let e=ov.useContext(lw);if(!e)throw new Error(Me(57));return e}var DH=T(Q(),1),MH=Xr.memo(Xr.forwardRef(function(t,a){let{render:o,className:r,style:n,value:s=null,label:i,disabled:l=!1,nativeButton:u=!1,...c}=t,d=Xr.useRef(null),f=jf({guess:!0,label:i,textRef:d}),m=wt(),{itemProps:p,multiple:y,disabled:b,readOnly:g}=Wi(),h=b||l,x=m.useState("isActive",f.index),S=m.useState("open"),v=m.useState("isSelected",s),R=m.useState("isSelectedByFocus",f.index),L=m.useState("isItemEqualToValue"),C=f.index,E=Xr.useRef(null);G(()=>{let w=m.context.valuesRef.current;return w[C]=s,()=>{delete w[C]}},[C,s,m]),G(()=>{let w=m.state.value,_=m.state.selectedIndex,U=_,X;y&&Array.isArray(w)?(U=Wz(C,s,m.context.valuesRef.current,w,L,_),X=U===C,C===_&&!X&&(m.context.selectedItemTextRef.current=null)):(X=w!==void 0&&xs(s,w,L),X&&(U=C)),m.set("selectedIndex",U),X&&d.current&&(m.context.selectedItemTextRef.current=d.current)},[C,y,L,m,s]);let I=Xr.useRef("mouse"),A=Xr.useRef(!1),{getButtonProps:N,buttonRef:D}=Qo({disabled:h,focusableWhenDisabled:!0,native:u,composite:!0}),F={disabled:h,selected:v,highlighted:x};function k(w){if(b||g)return;let _=m.state.value;if(y){let U=Array.isArray(_)?_:[],X=v?Kz(U,s,L):[...U,s];m.context.setValue(X,he(ne.itemPress,w))}else m.context.setValue(s,he(ne.itemPress,w)),m.context.setOpen(!1,he(ne.itemPress,w))}function z(){m.context.selectionRef.current.dragY=0}let q={role:"option","aria-selected":v,tabIndex:S&&x?0:-1,onKeyDown(w){m.set("activeIndex",C),w.key===" "&&m.context.typingRef.current&&w.preventDefault()},onClick(w){let _=I.current!=="touch",U=w.nativeEvent.pointerType,X=_&&Ni(w.nativeEvent)&&(U!==void 0||x),P=_&&!X&&!A.current;A.current=!1,!(h||P)&&k(w.nativeEvent)},onPointerEnter(w){I.current=w.pointerType},onPointerMove(w){if(w.pointerType==="mouse"&&w.buttons===1){let _=m.context.selectionRef.current;_.dragY+=w.movementY,_.dragY**2>=64&&(_.allowUnselectedMouseUp=!0)}},onPointerDown(w){I.current=w.pointerType,A.current=!0,z()},onMouseUp(){if(z(),h||I.current==="touch"||A.current)return;let w=!m.context.selectionRef.current.allowSelectedMouseUp&&v,_=!m.context.selectionRef.current.allowUnselectedMouseUp&&!v;w||_||(A.current=!0,E.current?.click(),A.current=!1)}},O=$("div",t,{ref:[D,a,f.ref,E],state:F,props:[p,q,c,N]}),V=Xr.useMemo(()=>({selected:v,index:C,textRef:d,selectedByFocus:R}),[v,C,d,R]);return(0,DH.jsx)(lw.Provider,{value:V,children:O})}));var zu=T(M(),1);var PH=T(Q(),1),OH=zu.forwardRef(function(t,a){let{selected:o}=yh();return t.keepMounted||o?(0,PH.jsx)(U9,{...t,ref:a}):null}),U9=zu.memo(zu.forwardRef((e,t)=>{let{render:a,className:o,style:r,keepMounted:n,...s}=e,{selected:i}=yh(),l=zu.useRef(null),{transitionStatus:u,setMounted:c}=ko(i),f=$("span",e,{ref:[t,l],state:{selected:i,transitionStatus:u},props:[{"aria-hidden":!0,children:"\u2714\uFE0F"},s],stateAttributesMapping:Ya});return Ra({batch:!0,enabled:!i,open:i,ref:l,onComplete(){i||c(!1)}}),f}));var cd=T(M(),1);var kH=cd.memo(cd.forwardRef(function(t,a){let{index:o,textRef:r,selectedByFocus:n}=yh(),s=wt(),{render:i,className:l,style:u,...c}=t,d=cd.useCallback(m=>{m&&(o===0&&(s.context.firstItemTextRef.current=m),n&&(s.context.selectedItemTextRef.current=m))},[s,o,n]);return $("div",t,{ref:[d,a,r],props:c})}));var NH=T(M(),1);var VH=NH.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,i=wt(),{side:l,align:u,arrowRef:c,arrowStyles:d,arrowUncentered:f,alignItemWithTriggerActive:m}=Zi(),y={open:i.useState("open"),side:l,align:u,uncentered:f},b=$("div",t,{state:y,ref:[c,a],props:[{style:d,"aria-hidden":!0},s],stateAttributesMapping:wf});return m?null:b});var FH=T(M(),1);var BH=T(M(),1);var rv=BH.forwardRef(function(t,a){let{render:o,className:r,style:n,direction:s,keepMounted:i,...l}=t,u=s==="up",c=wt(),{side:d,scrollDownArrowRef:f,scrollUpArrowRef:m}=Zi(),p=u?"scrollUpArrowVisible":"scrollDownArrowVisible",y=c.useState(p),b=c.useState("openMethod"),g=y&&b!=="touch",h=Qe(),x=u?m:f,{mounted:S,transitionStatus:v,setMounted:R}=ko(g);G(()=>(c.context.scrollArrowsMountedCountRef.current+=1,c.set("hasScrollArrows",!0),()=>{c.context.scrollArrowsMountedCountRef.current=Math.max(0,c.context.scrollArrowsMountedCountRef.current-1),c.context.scrollArrowsMountedCountRef.current===0&&c.set("hasScrollArrows",!1)}),[c]),Ra({open:g,ref:x,onComplete(){g||R(!1)}});let E=$("div",t,{ref:[a,x],state:{direction:s,visible:g,side:d,transitionStatus:v},props:[{"aria-hidden":!0,children:u?"\u25B2":"\u25BC",style:{position:"absolute"},onMouseMove(A){if(A.movementX===0&&A.movementY===0||h.isStarted())return;c.set("activeIndex",null);function N(){let D=c.state.listElement??c.context.popupRef.current;if(!D)return;c.set("activeIndex",null),c.context.handleScrollArrowVisibility(D);let F=id(D.scrollHeight,D.clientHeight),k=ys(D.scrollTop,F),z=k===(u?0:F),q=c.context.listRef.current;if(k!==D.scrollTop&&(D.scrollTop=k),z){h.clear();return}if(q.length>0){let O=x.current?.offsetHeight||0;D.scrollTop=q9(q,u,k,D.clientHeight,O,F)}h.start(40,N)}h.start(40,N)},onMouseLeave(){h.clear()}},l],stateAttributesMapping:Ya});return S||i?E:null});function q9(e,t,a,o,r,n){if(t){let c=0,d=a+r-er;for(let p=0;p<e.length;p+=1){let y=e[p];if(y&&y.offsetTop>=d){c=p;break}}let f=Math.max(0,c-1),m=e[f];return f<c&&m?ys(m.offsetTop-r,n):0}let s=e.length-1,i=a+o-r+er;for(let c=0;c<e.length;c+=1){let d=e[c];if(d&&d.offsetTop+d.offsetHeight>i){s=Math.max(0,c-1);break}}let l=Math.min(e.length-1,s+1),u=e[l];return l>s&&u?ys(u.offsetTop+u.offsetHeight-o+r,n):n}var _H=T(Q(),1),zH=FH.forwardRef(function(t,a){return(0,_H.jsx)(rv,{...t,ref:a,direction:"down"})});var HH=T(M(),1);var UH=T(Q(),1),qH=HH.forwardRef(function(t,a){return(0,UH.jsx)(rv,{...t,ref:a,direction:"up"})});var fd=T(M(),1);var nv=T(M(),1),uw=nv.createContext(void 0);function GH(){let e=nv.useContext(uw);if(e===void 0)throw new Error(Me(56));return e}var jH=T(Q(),1),XH=fd.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,[i,l]=fd.useState(),u=fd.useMemo(()=>({labelId:i,setLabelId:l}),[i,l]),c=$("div",t,{ref:a,props:[{role:"group","aria-labelledby":i},s]});return(0,jH.jsx)(uw.Provider,{value:u,children:c})});var YH=T(M(),1);var WH=YH.forwardRef(function(t,a){let{render:o,className:r,style:n,id:s,...i}=t,{setLabelId:l}=GH(),u=It(s);return G(()=>(l(u),()=>{l(d=>d===u?void 0:d)}),[u,l]),$("div",t,{ref:a,props:[{id:u,"aria-hidden":!0},i]})});var KH=T(M(),1);var ZH=KH.forwardRef(function(t,a){let{className:o,render:r,orientation:n="horizontal",style:s,...i}=t;return $("div",t,{state:{orientation:n},ref:a,props:[{role:"presentation"},i]})});var QH=ZH;var Zt=T(Q(),1),dd=eo.Root;function md({className:e,...t}){return(0,Zt.jsx)(eo.Value,{"data-slot":"select-value",className:re("flex flex-1 text-left",e),...t})}function pd({className:e,size:t="default",children:a,...o}){return(0,Zt.jsxs)(eo.Trigger,{"data-slot":"select-trigger","data-size":t,className:re("flex w-fit items-center justify-between gap-1.5 rounded-lg border border-input bg-transparent py-2 pr-2 pl-2.5 text-sm whitespace-nowrap transition-colors outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-placeholder:text-muted-foreground data-[size=default]:h-8 data-[size=sm]:h-7 data-[size=sm]:rounded-[min(var(--radius-md),10px)] *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-1.5 dark:bg-input/30 dark:hover:bg-input/50 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",e),...o,children:[a,(0,Zt.jsx)(eo.Icon,{render:(0,Zt.jsx)(ti,{className:"pointer-events-none size-4 text-muted-foreground"})})]})}function hd({className:e,children:t,side:a="bottom",sideOffset:o=4,align:r="center",alignOffset:n=0,alignItemWithTrigger:s=!0,...i}){return(0,Zt.jsx)(eo.Portal,{children:(0,Zt.jsx)(eo.Positioner,{side:a,sideOffset:o,align:r,alignOffset:n,alignItemWithTrigger:s,className:"isolate z-50",children:(0,Zt.jsxs)(eo.Popup,{"data-slot":"select-content","data-align-trigger":s,className:re("relative isolate z-50 max-h-(--available-height) w-(--anchor-width) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[align-trigger=true]:animate-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-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 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",e),...i,children:[(0,Zt.jsx)(G9,{}),(0,Zt.jsx)(eo.List,{children:t}),(0,Zt.jsx)(j9,{})]})})})}function Qi({className:e,children:t,...a}){return(0,Zt.jsxs)(eo.Item,{"data-slot":"select-item",className:re("relative flex w-full cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",e),...a,children:[(0,Zt.jsx)(eo.ItemText,{className:"flex flex-1 shrink-0 gap-2 whitespace-nowrap",children:t}),(0,Zt.jsx)(eo.ItemIndicator,{render:(0,Zt.jsx)("span",{className:"pointer-events-none absolute right-2 flex size-4 items-center justify-center"}),children:(0,Zt.jsx)(Jn,{className:"pointer-events-none"})})]})}function G9({className:e,...t}){return(0,Zt.jsx)(eo.ScrollUpArrow,{"data-slot":"select-scroll-up-button",className:re("top-0 z-10 flex w-full cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4",e),...t,children:(0,Zt.jsx)(Tm,{})})}function j9({className:e,...t}){return(0,Zt.jsx)(eo.ScrollDownArrow,{"data-slot":"select-scroll-down-button",className:re("bottom-0 z-10 flex w-full cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4",e),...t,children:(0,Zt.jsx)(ti,{})})}var Ji=T(Q(),1);function sv({className:e,...t}){return(0,Ji.jsx)("div",{"data-slot":"table-container",className:"relative w-full overflow-x-auto",children:(0,Ji.jsx)("table",{"data-slot":"table",className:re("w-full caption-bottom text-sm",e),...t})})}function iv({className:e,...t}){return(0,Ji.jsx)("thead",{"data-slot":"table-header",className:re("[&_tr]:border-b",e),...t})}function lv({className:e,...t}){return(0,Ji.jsx)("tbody",{"data-slot":"table-body",className:re("[&_tr:last-child]:border-0",e),...t})}function $i({className:e,...t}){return(0,Ji.jsx)("tr",{"data-slot":"table-row",className:re("border-b transition-colors hover:bg-muted/50 has-aria-expanded:bg-muted/50 data-[state=selected]:bg-muted",e),...t})}function po({className:e,...t}){return(0,Ji.jsx)("th",{"data-slot":"table-head",className:re("h-10 px-2 text-left align-middle font-medium whitespace-nowrap text-foreground [&:has([role=checkbox])]:pr-0",e),...t})}function za({className:e,...t}){return(0,Ji.jsx)("td",{"data-slot":"table-cell",className:re("p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0",e),...t})}var Se=T(Q(),1),JH={all:"Any state",done:"Done",problem:"Needs attention"},$H={0:"All time",1:"Last 24 hours",7:"Last 7 days",30:"Last 30 days"};function eU({onOpen:e}){let[t,a]=(0,Vo.useState)(""),[o,r]=(0,Vo.useState)(""),[n,s]=(0,Vo.useState)("all"),[i,l]=(0,Vo.useState)("all"),[u,c]=(0,Vo.useState)("0"),[d,f]=(0,Vo.useState)([]),[m,p]=(0,Vo.useState)(),[y,b]=(0,Vo.useState)(!1),[g,h]=(0,Vo.useState)();(0,Vo.useEffect)(()=>{dr.stats(0).then(h).catch(()=>{})},[]),(0,Vo.useEffect)(()=>{let R=setTimeout(()=>r(t),250);return()=>clearTimeout(R)},[t]);let x={q:o,state:n==="all"?void 0:n,model:i==="all"?void 0:i,days:Number(u)||void 0};(0,Vo.useEffect)(()=>{let R=!0;return b(!0),dr.history({...x,limit:30}).then(L=>{R&&(f(L.rows),p(L.total),b(!1))}).catch(()=>R&&b(!1)),()=>{R=!1}},[o,n,i,u]);let S=async()=>{let R=await dr.history({...x,limit:30,before:d.at(-1)?.id});f(L=>[...L,...R.rows])},v=[...new Set((g?.byWorker??[]).map(R=>R.model).filter(Boolean))];return(0,Se.jsxs)("div",{className:"space-y-4",children:[(0,Se.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,Se.jsxs)("div",{className:"relative min-w-56 flex-1",children:[(0,Se.jsx)(Br,{className:"pointer-events-none absolute left-2.5 top-1/2 size-4 -translate-y-1/2 text-muted-foreground"}),(0,Se.jsx)(Xb,{value:t,onChange:R=>a(R.target.value),placeholder:"Search tasks, answers and steps",className:"pl-8"})]}),(0,Se.jsxs)(dd,{value:n,onValueChange:R=>s(R??"all"),items:JH,children:[(0,Se.jsx)(pd,{className:"w-40",children:(0,Se.jsx)(md,{})}),(0,Se.jsx)(hd,{children:Object.entries(JH).map(([R,L])=>(0,Se.jsx)(Qi,{value:R,children:L},R))})]}),(0,Se.jsxs)(dd,{value:i,onValueChange:R=>l(R??"all"),items:{all:"Any model",...Object.fromEntries(v.map(R=>[R,R.split("/").pop()]))},children:[(0,Se.jsx)(pd,{className:"w-44",children:(0,Se.jsx)(md,{})}),(0,Se.jsxs)(hd,{children:[(0,Se.jsx)(Qi,{value:"all",children:"Any model"}),v.map(R=>(0,Se.jsx)(Qi,{value:R,children:R.split("/").pop()},R))]})]}),(0,Se.jsxs)(dd,{value:u,onValueChange:R=>c(R??"0"),items:$H,children:[(0,Se.jsx)(pd,{className:"w-40",children:(0,Se.jsx)(md,{})}),(0,Se.jsx)(hd,{children:Object.entries($H).map(([R,L])=>(0,Se.jsx)(Qi,{value:R,children:L},R))})]})]}),(0,Se.jsx)("div",{className:"overflow-hidden rounded-xl border bg-card animate-in fade-in duration-500",children:(0,Se.jsxs)(sv,{children:[(0,Se.jsx)(iv,{children:(0,Se.jsxs)($i,{className:"hover:bg-transparent",children:[(0,Se.jsx)(po,{className:"w-10"}),(0,Se.jsx)(po,{children:"Task"}),(0,Se.jsx)(po,{className:"hidden md:table-cell",children:"Worker"}),(0,Se.jsx)(po,{className:"hidden text-right sm:table-cell",children:"Time"}),(0,Se.jsx)(po,{className:"hidden text-right lg:table-cell",children:"Tokens"}),(0,Se.jsx)(po,{className:"hidden text-right lg:table-cell",children:"Saved"}),(0,Se.jsx)(po,{className:"text-right",children:"When"})]})}),(0,Se.jsxs)(lv,{children:[y&&!d.length&&[0,1,2,3].map(R=>(0,Se.jsx)($i,{children:(0,Se.jsx)(za,{colSpan:7,children:(0,Se.jsx)(us,{className:"h-6"})})},R)),d.map(R=>(0,Se.jsxs)($i,{className:"cursor-pointer",onClick:()=>e(R.id),children:[(0,Se.jsx)(za,{children:(0,Se.jsx)(Db,{state:R.state,className:"size-4"})}),(0,Se.jsxs)(za,{className:"max-w-0 min-w-48",children:[(0,Se.jsx)("div",{className:"truncate font-medium",children:R.task}),(0,Se.jsxs)("div",{className:"flex items-center gap-1.5 truncate text-xs text-muted-foreground",children:[R.kind,R.verdict&&(0,Se.jsx)(xx,{verdict:R.verdict}),R.files?(0,Se.jsxs)("span",{children:["\xB7 ",R.files," file",R.files===1?"":"s"]}):null]})]}),(0,Se.jsx)(za,{className:"hidden md:table-cell",children:(0,Se.jsx)(Xc,{backend:R.backend,model:R.model})}),(0,Se.jsx)(za,{className:"hidden text-right tabular-nums sm:table-cell",children:R.seconds!=null?es(R.seconds):"-"}),(0,Se.jsx)(za,{className:"hidden text-right tabular-nums text-muted-foreground lg:table-cell",children:R.tokens?ts(R.tokens):"-"}),(0,Se.jsx)(za,{className:"hidden text-right tabular-nums text-success lg:table-cell",children:R.saved?pr(R.saved):"-"}),(0,Se.jsx)(za,{className:"whitespace-nowrap text-right text-muted-foreground",children:(0,Se.jsxs)(od,{children:[(0,Se.jsx)(rd,{render:(0,Se.jsx)("span",{tabIndex:0,className:"cursor-default outline-none focus-visible:underline"}),children:mO(R.startedAt)}),(0,Se.jsx)(nd,{children:new Date(R.startedAt).toLocaleString()})]})})]},R.id)),!y&&!d.length&&(0,Se.jsx)($i,{className:"hover:bg-transparent",children:(0,Se.jsx)(za,{colSpan:7,className:"py-12 text-center text-muted-foreground",children:"No runs match."})})]})]})}),(0,Se.jsxs)("div",{className:"flex items-center justify-between text-sm text-muted-foreground",children:[(0,Se.jsx)("span",{children:m!=null?`${d.length} of ${m} runs`:""}),m!=null&&d.length<m&&(0,Se.jsx)(Do,{variant:"outline",onClick:()=>void S(),children:"Load more"})]})]})}var bs=T(M(),1);var Hu=T(Q(),1);function uv({children:e}){return(0,Hu.jsxs)(od,{children:[(0,Hu.jsx)(rd,{render:(0,Hu.jsx)("span",{tabIndex:0,"aria-label":"What is this?",className:"inline-flex cursor-help items-center text-muted-foreground/70 outline-none hover:text-foreground focus-visible:text-foreground"}),children:(0,Hu.jsx)(Vm,{className:"size-3.5"})}),(0,Hu.jsx)(nd,{className:"max-w-64 text-balance",children:e})]})}var bv=T(M(),1);var Nt=T(M(),1),aU=T(Zr(),1);var Sh=T(M(),1),tU=({ref:e,callback:t,eventType:a="mousedown",eventListenerOptions:o})=>{let r=(0,Sh.useRef)(t);r.current=t;let n=(0,Sh.useRef)(e);n.current=e,(0,Sh.useEffect)(()=>{let s=i=>{let l=i.target;if(!l||!l.isConnected)return;(Array.isArray(n.current)?n.current:[n.current]).filter(d=>!!d.current).every(d=>d.current&&!d.current.contains(l))&&r.current(i)};return document.addEventListener(a,s,o),()=>document.removeEventListener(a,s,o)},[a,o])};var Qt=T(Q(),1),oU=(0,Nt.createContext)(null),gd=()=>{let e=(0,Nt.useContext)(oU);if(!e)throw new Error("useExpandableCardContext must be used within a ExpandableCardProvider");return e},X9=Ca.create(Do),Y9=({children:e,transition:t})=>{let[a,o]=(0,Nt.useState)(!1),r=(0,Nt.useId)(),n=(0,Nt.useRef)(null),s=(0,Nt.useMemo)(()=>({isOpen:a,uniqueId:r,triggerRef:n,setIsOpen:o}),[a,r]);return(0,Qt.jsx)(oU.Provider,{value:s,children:(0,Qt.jsx)(yy,{transition:t,children:e})})},cw=({children:e,transition:t})=>{let a=Nt.default.Children.toArray(e);return(0,Qt.jsx)(Y9,{children:(0,Qt.jsx)(yy,{transition:t,children:a.map(o=>o)})})},cv=(0,Nt.forwardRef)(({children:e,className:t,...a},o)=>{let{isOpen:r,setIsOpen:n,uniqueId:s}=gd(),i=(0,Nt.useCallback)(()=>{n(!0)},[n]);return(0,Qt.jsx)(Ca.div,{ref:o,"data-slot":"expandable-card-body",layoutId:`card-${s}`,className:re("relative bg-card text-card-foreground flex flex-col rounded-xl overflow-hidden shadow-sm pb-2","cursor-pointer select-none",t),onClick:()=>i(),"aria-haspopup":"dialog","aria-expanded":r,"aria-controls":`shadix-ui-expandable-card-${s}`,style:{willChange:"transform, opacity",transform:"translateZ(0)"},...a,children:e})}),fw=({children:e,className:t,...a})=>{let{uniqueId:o}=gd();return(0,Qt.jsx)(Ca.div,{layoutId:`card-content-${o}`,className:re("overflow-hidden p-4",t),"aria-modal":"true",initial:{opacity:0,y:6},animate:{opacity:1,y:0},exit:{opacity:0,y:6},transition:{ease:"easeIn",duration:.3,delay:.2},style:{willChange:"transform, opacity"},"aria-labelledby":`shadix-ui-expandable-card-${o}-title`,"aria-describedby":`shadix-ui-expandable-card-${o}-description`,...a,children:e})},dw=({children:e,className:t})=>{let{isOpen:a,uniqueId:o,setIsOpen:r}=gd(),[n,s]=(0,Nt.useState)(!1),i=(0,Nt.useRef)(null);return tU({ref:i,callback:()=>{r(!1)}}),(0,Nt.useEffect)(()=>(s(!0),()=>s(!1)),[]),(0,Nt.useEffect)(()=>{if(!a)return;let l=c=>c.key==="Escape"&&r(!1),u=document.body.style.overflow;return document.body.style.overflow="hidden",document.addEventListener("keydown",l),()=>{document.removeEventListener("keydown",l),document.body.style.overflow=u}},[a,r]),n?(0,aU.createPortal)((0,Qt.jsx)(wi,{initial:!1,mode:"sync",children:a&&(0,Qt.jsxs)(Qt.Fragment,{children:[(0,Qt.jsx)(Ca.div,{"data-slot":"expandable-card-expand-container",className:"fixed inset-0 h-full w-full bg-white/40 backdrop-blur-sm dark:bg-black/50 z-40",initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.2}},`expandable-backdrop-${o}`),(0,Qt.jsx)("div",{className:"fixed inset-0 z-50 flex items-center justify-center max-w-3xl mx-auto h-fit my-auto px-3 pointer-events-none",children:(0,Qt.jsxs)(cv,{ref:i,className:re("pointer-events-auto",t),children:[e,(0,Qt.jsx)(rU,{})]})})]})}),document.body):null},mw=({className:e,children:t,...a})=>{let{uniqueId:o}=gd();return(0,Qt.jsx)(Ca.h2,{layout:"position",layoutId:`card-title-${o}`,className:re("text-lg font-semibold leading-6 tracking-tight p-0 px-4 !m-0 !mt-2",e),...a,children:t})},pw=({className:e,children:t,...a})=>{let{uniqueId:o}=gd();return(0,Qt.jsx)(Ca.h3,{id:`card-description-${o}`,layout:"position",layoutId:`card-description-${o}`,className:re("text-sm text-muted-foreground px-4",e),...a,children:t})},W9=({className:e,...t})=>(0,Qt.jsx)(Ca.img,{style:{willChange:"transform,scale"},className:re("w-full h-full object-cover object-top not-prose",e),...t}),rU=({className:e,children:t,...a})=>{let{setIsOpen:o,uniqueId:r}=gd(),n=(0,Nt.useCallback)(()=>{o(!1)},[o]);return(0,Qt.jsx)(X9,{layout:"position",layoutId:`card-close-button-${r}`,onClick:n,"aria-label":"Close",size:"icon-sm",className:re("flex absolute top-2 right-2 items-center justify-center rounded-full pointer-events-auto","bg-background/50 hover:bg-background/70 text-foreground/60 cursor-pointer z-[60]",e),initial:{opacity:0},animate:{opacity:1},exit:{opacity:0,transition:{delay:-.2}},transition:{duration:.2,delay:.3},...a,children:t??(0,Qt.jsx)(Ol,{})})};cw.displayName="ExpandableCard";cv.displayName="ExpandableCardBody";fw.displayName="ExpandableCardContent";dw.displayName="ExpandableCardExpandContainer";mw.displayName="ExpandableCardTitle";pw.displayName="ExpandableCardDescription";W9.displayName="ExpandableCardImage";rU.displayName="ExpandableCardCloseButton";var tl={};Aa(tl,{Content:()=>MU,Corner:()=>NU,Root:()=>hU,Scrollbar:()=>DU,Thumb:()=>OU,Viewport:()=>wU});var st=T(M(),1);var fv=T(M(),1),hw=fv.createContext(void 0);function Pn(){let e=fv.useContext(hw);if(e===void 0)throw new Error(Me(53));return e}function Yr(e,t,a){if(!e)return 0;let o=getComputedStyle(e),r=`${t}${a==="x"?"Inline":"Block"}`,n=parseFloat(o[`${r}Start`]);return a==="x"&&t==="margin"?n*2:n+parseFloat(o[`${r}End`])}var nU="data-has-overflow-x",sU="data-has-overflow-y",iU="data-overflow-x-start",lU="data-overflow-x-end",uU="data-overflow-y-start",cU="data-overflow-y-end";var xd=e=>t=>t?{[e]:""}:null,el={hasOverflowX:xd(nU),hasOverflowY:xd(sU),overflowXStart:xd(iU),overflowXEnd:xd(lU),overflowYStart:xd(uU),overflowYEnd:xd(cU),cornerHidden:()=>null};var dv="--scroll-area-corner-height",mv="--scroll-area-corner-width";var dU="data-orientation";var pU=T(Q(),1),Q9={x:0,y:0},mU={width:0,height:0},J9={xStart:!1,xEnd:!1,yStart:!1,yEnd:!1},$9={x:!0,y:!0,corner:!0},hU=st.forwardRef(function(t,a){let{render:o,className:r,overflowEdgeThreshold:n,style:s,...i}=t,{xStart:l,xEnd:u,yStart:c,yEnd:d}=eW(n),f=It(),m=Qe(),p=Qe(),{nonce:y,disableStyleElements:b}=Xf(),[g,h]=st.useState(!1),[x,S]=st.useState(!1),[v,R]=st.useState(!1),[L,C]=st.useState(!1),[E,I]=st.useState(!1),[A,N]=st.useState(mU),[D,F]=st.useState(mU),[k,z]=st.useState(J9),[q,O]=st.useState($9),V=st.useRef(null),w=st.useRef(null),_=st.useRef(null),U=st.useRef(null),X=st.useRef(null),P=st.useRef(null),H=st.useRef(null),B=st.useRef(null),J=st.useRef(0),Y=st.useRef(0),te=st.useRef(0),ie=st.useRef(0),ce=st.useRef("vertical"),ee=st.useRef(Q9),ae=st.useRef(null);function me(K){let j=K?R:S,se=K?m:p;j(!0),se.start(500,()=>{j(!1)})}let ge=W(K=>{let j=K.x-ee.current.x,se=K.y-ee.current.y;ee.current=K,se!==0&&me(!0),j!==0&&me(!1)}),Ee=W(()=>{let K=w.current;K&&ae.current===null&&(ae.current=K.style.scrollSnapType,K.style.scrollSnapType="none")}),pe=W(K=>{if(K.button!==0||B.current!==null&&(ce.current==="vertical"?X.current:P.current)?.hasPointerCapture(B.current))return;B.current=K.pointerId,J.current=K.clientY,Y.current=K.clientX,ce.current=K.currentTarget.getAttribute(dU);let j=w.current;j&&(te.current=j.scrollTop,ie.current=j.scrollLeft,Ee()),(ce.current==="vertical"?X.current:P.current)?.setPointerCapture(K.pointerId)}),Te=W(K=>{if(K.pointerId!==B.current)return;B.current=null,(ce.current==="vertical"?R:S)(!1),ae.current!==null&&(w.current&&(w.current.style.scrollSnapType=ae.current),ae.current=null);let j=ce.current==="vertical"?X.current:P.current;j?.hasPointerCapture(K.pointerId)&&j.releasePointerCapture(K.pointerId)}),le=W(K=>{if(K.pointerId!==B.current)return;if(K.buttons%2===0){Te(K);return}let j=w.current;if(!j)return;let se=ce.current==="vertical",Fe=se?X.current:P.current,Vt=se?_.current:U.current;if(!Fe||!Vt)return;let Jt=se?"y":"x",Et=Yr(Vt,"padding",Jt),bt=Yr(Fe,"margin",Jt),wa=se?Fe.offsetHeight:Fe.offsetWidth,$t=(se?Vt.offsetHeight:Vt.offsetWidth)-wa-Et-bt,Ha=se?K.clientY-J.current:K.clientX-Y.current,ho=$t<=0?0:Ha/$t,tr=se?j.scrollHeight:j.scrollWidth,ha=se?j.clientHeight:j.clientWidth,Ae=(se?te.current:ie.current)+ho*(tr-ha);se?j.scrollTop=Ae:j.scrollLeft=Ae,K.preventDefault(),me(se)});function Ie(K){C(K.pointerType==="touch")}function Be(K){if(Ie(K),K.pointerType!=="touch"){let j=ue(V.current,K.target);h(j)}}let Oe=st.useMemo(()=>({scrolling:x||v,hasOverflowX:!q.x,hasOverflowY:!q.y,overflowXStart:k.xStart,overflowXEnd:k.xEnd,overflowYStart:k.yStart,overflowYEnd:k.yEnd,cornerHidden:q.corner}),[x,v,q.x,q.y,q.corner,k]),ut={role:"presentation",onPointerEnter:Be,onPointerMove:Be,onPointerDown:Ie,onPointerLeave(){h(!1)},style:{position:"relative",[dv]:`${A.height}px`,[mv]:`${A.width}px`}},oe=$("div",t,{state:Oe,ref:[a,V],props:[ut,i],stateAttributesMapping:el}),fe=st.useMemo(()=>({handlePointerDown:pe,handlePointerMove:le,handlePointerUp:Te,handleScroll:ge,disableViewportSnap:Ee,cornerSize:A,setCornerSize:N,thumbSize:D,setThumbSize:F,hasMeasuredScrollbar:E,setHasMeasuredScrollbar:I,touchModality:L,cornerRef:H,scrollingX:x,scrollingY:v,hovering:g,setHovering:h,viewportRef:w,scrollbarYRef:_,scrollbarXRef:U,thumbYRef:X,thumbXRef:P,rootId:f,hiddenState:q,setHiddenState:O,overflowEdges:k,setOverflowEdges:z,viewportState:Oe,overflowEdgeThreshold:{xStart:l,xEnd:u,yStart:c,yEnd:d}}),[pe,le,Te,ge,Ee,A,D,E,L,x,v,g,f,q,k,Oe,l,u,c,d]);return(0,pU.jsxs)(hw.Provider,{value:fe,children:[!b&&Ss.getElement(y),oe]})});function eW(e){let t=typeof e=="number"?{xStart:e,xEnd:e,yStart:e,yEnd:e}:e;return{xStart:Math.max(0,t?.xStart||0),xEnd:Math.max(0,t?.xEnd||0),yStart:Math.max(0,t?.yStart||0),yEnd:Math.max(0,t?.yEnd||0)}}var Uu=T(M(),1);var pv=T(M(),1),gw=pv.createContext(void 0);function gU(){let e=pv.useContext(gw);if(e===void 0)throw new Error(Me(55));return e}var xU="--scroll-area-overflow-x-start",yU="--scroll-area-overflow-x-end",SU="--scroll-area-overflow-y-start",bU="--scroll-area-overflow-y-end";var hv="--scroll-area-thumb-height",gv="--scroll-area-thumb-width";var TU=T(Q(),1),IU=[xU,yU,SU,bU],LU=!1;function aW(){LU||ot.engine.webkit||(typeof CSS<"u"&&"registerProperty"in CSS&&IU.forEach(e=>{try{CSS.registerProperty({name:e,syntax:"<length>",inherits:!1,initialValue:"0px"})}catch{}}),LU=!0)}var wU=Uu.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,{viewportRef:i,scrollbarYRef:l,scrollbarXRef:u,thumbYRef:c,thumbXRef:d,cornerRef:f,cornerSize:m,setCornerSize:p,setThumbSize:y,rootId:b,setHiddenState:g,hiddenState:h,setHasMeasuredScrollbar:x,handleScroll:S,touchModality:v,setHovering:R,setOverflowEdges:L,overflowEdgeThreshold:C,viewportState:E}=Pn(),I=No(),A=Uu.useRef(!0),N=Uu.useRef([NaN,NaN,NaN,NaN]),D=Qe(),F=Qe(),k=W(()=>{let w=i.current,_=l.current,U=u.current,X=c.current,P=d.current,H=f.current;if(!w)return;let B=w.scrollHeight,J=w.scrollWidth,Y=w.clientHeight,te=w.clientWidth,ie=w.scrollTop,ce=w.scrollLeft,ee=N.current,ae=Number.isNaN(ee[0]);if(ee[0]=Y,ee[1]=B,ee[2]=te,ee[3]=J,ae&&x(!0),B===0||J===0)return;let me=oW(w),ge=me.y,Ee=me.x,pe=te/J,Te=Y/B,le=Math.max(0,J-te),Ie=Math.max(0,B-Y),Be=0,Oe=0;Ee||(Be=ys(I==="rtl"?-ce:ce,le),Oe=le-Be);let ut=ge?0:ys(ie,Ie),oe=ge?0:Ie-ut,fe=Ee?0:te,K=ge?0:Y,j=0,se=0;!Ee&&!ge&&(j=_?.offsetWidth||0,se=U?.offsetHeight||0);let Fe=m.width===0&&m.height===0,Vt=Fe?j:0,Jt=Fe?se:0,Et=Yr(U,"padding","x"),bt=Yr(_,"padding","y"),wa=Yr(P,"margin","x"),Ea=Yr(X,"margin","y"),$t=fe-Et-wa,Ha=K-bt-Ea,ho=U?Math.min(U.offsetWidth-Vt,$t):$t,tr=_?Math.min(_.offsetHeight-Jt,Ha):Ha,ha=Math.max(16,ho*pe),Ht=Math.max(16,tr*Te);if(y(Je=>xv(Je,{width:ha,height:Ht})),_&&X){let Je=_.offsetHeight-Ht-bt-Ea,Bt=RU(X,hv,ie,Ie,B,Ht,Je);X.style.transform=`translate3d(0,${Bt}px,0)`}if(U&&P){let Je=U.offsetWidth-ha-Et-wa,Bt=I==="rtl"?-ce:ce,go=RU(P,gv,Bt,le,J,ha,Je);P.style.transform=`translate3d(${I==="rtl"?-go:go}px,0,0)`}let Ae=[Be,Oe,ut,oe];IU.forEach((Je,Bt)=>{w.style.setProperty(Je,`${Ae[Bt]}px`)}),H&&p(Je=>xv(Je,{width:j,height:se})),g(Je=>xv(Je,me));let Dt={xStart:!Ee&&Be>C.xStart,xEnd:!Ee&&Oe>C.xEnd,yStart:!ge&&ut>C.yStart,yEnd:!ge&&oe>C.yEnd};L(Je=>xv(Je,Dt))});G(()=>{aW()},[]),G(()=>{queueMicrotask(k)},[k,h,I,C.xStart,C.xEnd,C.yStart,C.yEnd]),G(()=>{i.current?.matches(":hover")&&R(!0)},[i,R]),G(()=>{let w=i.current;if(typeof ResizeObserver>"u"||!w)return;let _=!1,U=new ResizeObserver(()=>{if(!_){_=!0;let X=N.current;if(X[0]===w.clientHeight&&X[1]===w.scrollHeight&&X[2]===w.clientWidth&&X[3]===w.scrollWidth)return}k()});return U.observe(w),F.start(0,()=>{let X=w.getAnimations({subtree:!0});X.length!==0&&Promise.allSettled(X.map(P=>P.finished)).then(k).catch(()=>{})}),()=>{U.disconnect(),F.clear()}},[k,i,F]);function z(){A.current=!1}let q={role:"presentation",...b&&{"data-id":`${b}-viewport`},tabIndex:h.x&&h.y?-1:0,className:Ss.className,style:{overflow:"scroll"},onScroll(){i.current&&(k(),(v||!A.current)&&S({x:i.current.scrollLeft,y:i.current.scrollTop}),D.start(100,()=>{A.current=!0}))},onWheel:z,onPointerMove:z,onPointerEnter:z,onKeyDown:z},O=$("div",t,{ref:[a,i],state:E,props:[q,s],stateAttributesMapping:el}),V=Uu.useMemo(()=>({computeThumbPosition:k}),[k]);return(0,TU.jsx)(gw.Provider,{value:V,children:O})});function oW(e){let t=e.clientHeight>=e.scrollHeight,a=e.clientWidth>=e.scrollWidth;return{y:t,x:a,corner:t||a}}function xv(e,t){for(let a in t)if(e[a]!==t[a])return t;return e}function RU(e,t,a,o,r,n,s){let i=Er(a,0,o),l=a-i,u=Math.max(16,n*r/(r+Math.abs(l)));return e.style.setProperty(t,l?`${u}px`:""),(o?i/o*s:0)+(l>0?n-u:0)}var Sv=T(M(),1);var yv=T(M(),1),xw=yv.createContext(void 0);function EU(){let e=yv.useContext(xw);if(e===void 0)throw new Error(Me(54));return e}var AU=T(Q(),1),DU=Sv.forwardRef(function(t,a){let{render:o,className:r,orientation:n="vertical",keepMounted:s=!1,style:i,...l}=t,{hovering:u,scrollingX:c,scrollingY:d,hiddenState:f,scrollbarYRef:m,scrollbarXRef:p,viewportRef:y,thumbYRef:b,thumbXRef:g,handlePointerDown:h,handlePointerUp:x,handleScroll:S,disableViewportSnap:v,rootId:R,thumbSize:L,hasMeasuredScrollbar:C,viewportState:E}=Pn(),I=n==="vertical",A={...E,hovering:u,scrolling:I?d:c,orientation:n},N=No(),D=!C&&!s,F=I?f.y:f.x,k=s||!F;Sv.useEffect(()=>{if(!k)return;let O=y.current,V=I?m.current:p.current;if(!V)return;function w(_){if(!O||_.ctrlKey)return;let U=!I,X=U?"scrollLeft":"scrollTop",P=U?_.deltaX:_.deltaY;if(P===0)return;let H=U?O.scrollWidth-O.clientWidth:O.scrollHeight-O.clientHeight,B=U&&N==="rtl"?-H:0,J=U&&N==="rtl"?0:H,Y=O[X];Y<=B&&P<0||Y>=J&&P>0||(_.preventDefault(),O[X]=Math.min(J,Math.max(B,Y+P)),S({x:O.scrollLeft,y:O.scrollTop}))}return Re(V,"wheel",w,{passive:!1})},[N,S,I,p,m,k,y]);let z={...R&&{"data-id":`${R}-scrollbar`},"aria-hidden":!0,onPointerDown(O){if(O.button!==0)return;let V=$e(O.nativeEvent),w=I?b.current:g.current;if(w&&ue(w,V))return;let _=y.current;if(!_)return;let U=I?m.current:p.current;if(!w||!U)return;let X=I?"y":"x",P=Yr(w,"margin",X),H=Yr(U,"padding",X),B=I?w.offsetHeight:w.offsetWidth,J=U.getBoundingClientRect(),Y=I?O.clientY-J.top-B/2-H+P/2:O.clientX-J.left-B/2-H+P/2,te=I?_.scrollHeight:_.scrollWidth,ie=I?_.clientHeight:_.clientWidth,ee=(I?U.offsetHeight:U.offsetWidth)-B-H-P;if(ee<=0)return;let ae=Y/ee,me=te-ie;v(),I?_.scrollTop=ae*me:N==="rtl"?_.scrollLeft=-(1-ae)*me:_.scrollLeft=ae*me,S({x:_.scrollLeft,y:_.scrollTop}),h(O)},onMouseDown(O){O.preventDefault()},onPointerUp:x,onPointerCancel:x,style:{position:"absolute",touchAction:"none",WebkitUserSelect:"none",userSelect:"none",visibility:D?"hidden":void 0,...I?{top:0,bottom:`var(${dv})`,insetInlineEnd:0,[hv]:`${L.height}px`}:{insetInlineStart:0,insetInlineEnd:`var(${mv})`,bottom:0,[gv]:`${L.width}px`}}},q=$("div",t,{ref:[a,I?m:p],state:A,props:[z,l],stateAttributesMapping:el});return k?(0,AU.jsx)(xw.Provider,{value:n,children:q}):null});var bh=T(M(),1);var MU=bh.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,{computeThumbPosition:i}=gU(),{hasMeasuredScrollbar:l,viewportState:u}=Pn(),c=bh.useRef(null),d=bh.useRef(l);return G(()=>{if(typeof ResizeObserver>"u")return;let m=!1,p=new ResizeObserver(()=>{!m&&(m=!0,!d.current)||i()});return c.current&&p.observe(c.current),()=>{p.disconnect()}},[i]),$("div",t,{ref:[a,c],state:u,stateAttributesMapping:el,props:[{role:"presentation",style:{minWidth:"fit-content"}},s]})});var PU=T(M(),1);var OU=PU.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,{thumbYRef:i,thumbXRef:l,handlePointerDown:u,handlePointerMove:c,handlePointerUp:d,scrollingX:f,scrollingY:m,hasMeasuredScrollbar:p}=Pn(),y=EU(),b=y==="vertical";return $("div",t,{ref:[a,b?i:l],state:{scrolling:b?m:f,orientation:y},props:[{onPointerDown:u,onPointerMove:c,onPointerUp:d,onPointerCancel:d,style:{visibility:p?void 0:"hidden",...b?{height:"var(--scroll-area-thumb-height)"}:{width:"var(--scroll-area-thumb-width)"}}},s]})});var kU=T(M(),1);var NU=kU.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,{cornerRef:i,cornerSize:l,hiddenState:u}=Pn(),c=$("div",t,{ref:[a,i],props:[{"aria-hidden":!0,style:{position:"absolute",bottom:0,insetInlineEnd:0,width:l.width,height:l.height}},s]});return u.corner?null:c});var al=T(Q(),1);function VU({className:e,children:t,...a}){let o=Hy();return(0,al.jsxs)(tl.Root,{"data-slot":"scroll-area",className:re("relative",e),...a,children:[(0,al.jsx)(tl.Viewport,{ref:o,"data-slot":"scroll-area-viewport",className:"scroll-fade size-full max-h-[inherit] rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:ring-ring/50 focus-visible:outline-1",children:t}),(0,al.jsx)(rW,{}),(0,al.jsx)(tl.Corner,{})]})}function rW({className:e,orientation:t="vertical",...a}){return(0,al.jsx)(tl.Scrollbar,{"data-slot":"scroll-area-scrollbar","data-orientation":t,orientation:t,className:re("flex touch-none p-px transition-colors select-none data-horizontal:h-2.5 data-horizontal:flex-col data-horizontal:border-t data-horizontal:border-t-transparent data-vertical:h-full data-vertical:w-2.5 data-vertical:border-l data-vertical:border-l-transparent",e),...a,children:(0,al.jsx)(tl.Thumb,{"data-slot":"scroll-area-thumb",className:"relative flex-1 rounded-full bg-border"})})}var it=T(Q(),1);function nW({run:e,active:t}){let[a,o]=(0,bv.useState)(Date.now());return(0,bv.useEffect)(()=>{if(!t)return;let r=setInterval(()=>o(Date.now()),1e3);return()=>clearInterval(r)},[t]),(0,it.jsx)("span",{className:re("text-sm font-semibold tabular-nums",t&&"text-info"),children:t?es((a-Date.parse(e.startedAt))/1e3):e.time})}function BU({run:e,expanded:t}){let a=e.state==="running"||e.state==="queued";return(0,it.jsxs)("div",{className:re("grid grid-cols-[auto_1fr_auto] items-start gap-3.5 p-4 text-left",t&&"pr-12"),children:[(0,it.jsx)(Db,{state:e.state,className:"mt-0.5"}),(0,it.jsxs)("div",{className:"min-w-0 space-y-1.5",children:[(0,it.jsxs)("div",{className:"flex flex-wrap items-center gap-1.5",children:[(0,it.jsx)(Xc,{worker:e.worker}),(0,it.jsx)("span",{className:"text-[13px] text-muted-foreground",children:e.kind}),e.verdict&&(0,it.jsx)(xx,{verdict:e.verdict}),e.changes?(0,it.jsxs)(yx,{children:[e.changes," file",e.changes===1?"":"s"]}):null,e.applied&&(0,it.jsx)(yx,{tone:"good",children:"applied"})]}),(0,it.jsx)(mw,{className:"!mt-0 break-words px-0 text-[15px] font-normal leading-snug tracking-normal",children:e.task}),(a||e.note)&&(0,it.jsx)(pw,{className:"line-clamp-2 break-words px-0 text-[13px]",children:a?(0,it.jsx)(_y,{duration:1.6,children:e.note||"working"}):e.note}),e.state==="running"&&(0,it.jsx)("div",{className:"mt-2 h-[3px] overflow-hidden rounded-full bg-info/15",children:(0,it.jsx)("div",{className:"h-full w-[38%] rounded-full bg-gradient-to-r from-transparent via-info to-transparent",style:{animation:"indeterminate 1.5s cubic-bezier(.22,1,.36,1) infinite"}})})]}),(0,it.jsxs)("div",{className:"flex flex-col items-end gap-0.5",children:[(0,it.jsx)(nW,{run:e,active:a}),(0,it.jsx)("span",{className:"text-xs text-muted-foreground",children:[e.steps?`${e.steps} step${e.steps===1?"":"s"}`:"",e.tokens?`${ts(e.tokens)} tokens`:""].filter(Boolean).join(" \xB7 ")}),e.saved?(0,it.jsxs)("span",{className:"text-xs text-success",children:["~",pr(e.saved)]}):null]})]})}function FU({run:e,index:t}){let a=e.state==="running"||e.state==="queued";return(0,it.jsx)("div",{className:"animate-in fade-in slide-in-from-bottom-2 fill-mode-both",style:{animationDelay:`${Math.min(t,8)*45}ms`,animationDuration:"500ms"},children:(0,it.jsxs)(cw,{children:[(0,it.jsx)(cv,{className:re("rounded-xl border pb-0 shadow-none transition-colors duration-300 hover:border-foreground/25",e.state==="running"&&"border-info/30"),children:(0,it.jsx)(BU,{run:e})}),(0,it.jsxs)(dw,{className:"max-h-[88vh] w-full border pb-0 shadow-2xl",children:[(0,it.jsx)("div",{className:"shrink-0",children:(0,it.jsx)(BU,{run:e,expanded:!0})}),(0,it.jsx)(VU,{className:"max-h-[calc(88vh-6.5rem)] border-t",children:(0,it.jsx)(fw,{className:"px-4 pb-5 pt-4 sm:pl-[3.4rem]",children:(0,it.jsx)(Zy,{id:e.id,live:a})})})]})]})})}var Cv=T(Q(),1);function vv({price:e}){return(0,Cv.jsxs)(Cv.Fragment,{children:["An estimate, not money back. It is what your main model (",e??"Claude Sonnet"," list prices) would have charged to read the tokens the workers read, minus what the workers cost and the cost of reading their reports."]})}var Lv=T(Q(),1);function Rv({value:e,onChange:t,options:a}){return(0,Lv.jsx)(db,{value:e,onValueChange:o=>t(o),children:(0,Lv.jsx)(mb,{children:a.map(o=>(0,Lv.jsx)(Zf,{value:o.value,children:o.label},o.value))})})}var _U=T(Q(),1);function yd({className:e,size:t="default",...a}){return(0,_U.jsx)("div",{"data-slot":"card","data-size":t,className:re("group/card flex flex-col gap-(--card-spacing) overflow-hidden rounded-xl bg-card py-(--card-spacing) text-sm text-card-foreground ring-1 ring-foreground/10 [--card-spacing:--spacing(4)] has-data-[slot=card-footer]:pb-0 has-[>img:first-child]:pt-0 data-[size=sm]:[--card-spacing:--spacing(3)] data-[size=sm]:has-data-[slot=card-footer]:pb-0 *:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl",e),...a})}var et=T(Q(),1);function yw(e,t=450){let[a,o]=(0,bs.useState)(e),[r,n]=(0,bs.useState)(e);if(r!==e){n(e);let s=performance.now(),i=a,l=u=>{let c=Math.min(1,(u-s)/t);o(i+(e-i)*(1-(1-c)**3)),c<1&&requestAnimationFrame(l)};requestAnimationFrame(l)}return a}function Sw({label:e,value:t,tone:a,pulse:o,hint:r}){return(0,et.jsxs)(yd,{className:re("relative gap-1 overflow-hidden px-5 py-4 animate-in fade-in slide-in-from-bottom-1 duration-500 fill-mode-both",o&&"border-info/30"),children:[(0,et.jsxs)("p",{className:"flex items-center gap-1.5 text-xs font-medium uppercase tracking-wide text-muted-foreground",children:[e,r&&(0,et.jsx)(uv,{children:r})]}),(0,et.jsxs)("p",{className:re("flex items-center gap-2.5 text-3xl font-semibold tabular-nums tracking-tight",a),children:[o!==void 0&&(0,et.jsx)("span",{className:re("size-2.5 rounded-full",o?"animate-ping-slow bg-info":"bg-muted-foreground/40")}),t]})]})}var sW=(e,t)=>!t||`${e.task} ${e.worker} ${e.kind} ${e.note}`.toLowerCase().includes(t);function zU({focus:e}){let[t,a]=(0,bs.useState)(40),[o,r]=(0,bs.useState)("all"),[n,s]=(0,bs.useState)(""),[i,l]=(0,bs.useState)(""),{data:u}=Pi(()=>dr.state(t,n||void 0),2e3,[t,n]),c=yw(u?.running??0),d=yw(u?.saved??0),f=yw(u?.runs.filter(p=>p.state==="done").length??0),m=(0,bs.useMemo)(()=>(u?.runs??[]).filter(p=>sW(p,i.trim().toLowerCase())&&(o==="all"||(o==="running"?p.state==="running"||p.state==="queued":p.state==="failed"||p.state==="timeout"||p.state==="stopped"))),[u,i,o]);return(0,et.jsxs)("div",{className:"space-y-5",children:[(0,et.jsxs)("div",{className:"grid gap-3 sm:grid-cols-3",children:[(0,et.jsx)(Sw,{label:"Running now",value:String(Math.round(c)),pulse:(u?.running??0)>0,tone:u?.running?"text-info":void 0}),(0,et.jsx)(Sw,{label:"Finished",value:String(Math.round(f))}),(0,et.jsx)(Sw,{label:"Est. saved this week",value:pr(d),tone:"text-success",hint:(0,et.jsx)(vv,{price:u?.price})})]}),(0,et.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,et.jsxs)("div",{className:"relative min-w-48 flex-1",children:[(0,et.jsx)(Br,{className:"pointer-events-none absolute left-2.5 top-1/2 size-4 -translate-y-1/2 text-muted-foreground"}),(0,et.jsx)(Xb,{value:i,onChange:p=>l(p.target.value),placeholder:"Filter these runs",className:"pl-8"})]}),(0,et.jsx)(Rv,{value:o,onChange:r,options:[{value:"all",label:"All"},{value:"running",label:"Running"},{value:"problem",label:"Needs attention"}]}),u&&u.groups.length>0&&(0,et.jsxs)(dd,{value:n||"all",onValueChange:p=>s(p==="all"?"":p??""),items:{all:"All groups",...Object.fromEntries(u.groups.map(p=>[p,p]))},children:[(0,et.jsx)(pd,{className:"w-40",children:(0,et.jsx)(md,{})}),(0,et.jsxs)(hd,{children:[(0,et.jsx)(Qi,{value:"all",children:"All groups"}),u.groups.map(p=>(0,et.jsx)(Qi,{value:p,children:p},p))]})]})]}),(0,et.jsxs)("div",{className:"space-y-2.5",children:[!u&&[0,1,2].map(p=>(0,et.jsx)(us,{className:"h-24 rounded-xl"},p)),u&&m.length===0&&(0,et.jsxs)("div",{className:"flex flex-col items-center gap-2 py-16 text-center text-muted-foreground animate-in fade-in duration-500",children:[(0,et.jsx)("span",{className:"text-5xl animate-wave",children:"\u{1F3C1}"}),(0,et.jsx)("p",{children:u.runs.length?"Nothing matches this filter.":"All quiet. Workers appear here the moment they start."}),!u.runs.length&&(0,et.jsx)("code",{className:"rounded-lg border bg-card px-3 py-1.5 text-sm text-foreground",children:'pitroom run "your task"'})]}),m.map((p,y)=>(0,et.jsx)(FU,{run:p,index:y},p.id)),u&&u.runs.length>=t&&(0,et.jsx)("div",{className:"flex justify-center pt-1",children:(0,et.jsx)(Do,{variant:"outline",onClick:()=>a(p=>p+40),children:"Show older runs"})})]})]})}var Sd={};Aa(Sd,{Indicator:()=>ZU,Label:()=>e3,Root:()=>XU,Track:()=>WU,Value:()=>JU});var vs=T(M(),1);function bw(e){return Array.isArray(e)?e.map(t=>bw(t)).join(","):e==null?"":String(e)}var HU=new Map;function iW(e,t){let a=JSON.stringify({locale:bw(e),options:t}),o=HU.get(a);if(o)return o;let r=new Intl.NumberFormat(e,t);return HU.set(a,r),r}function vw(e,t,a){return e==null?"":iW(t,a).format(e)}function UU(e,t,a){return(e-t)*100/(a-t)}var Tv=T(M(),1),Cw=Tv.createContext(void 0);function ol(){let e=Tv.useContext(Cw);if(e===void 0)throw new Error(Me(51));return e}var qU="data-complete",GU="data-indeterminate",jU="data-progressing";var On={status(e){return e==="progressing"?{[jU]:""}:e==="complete"?{[qU]:""}:e==="indeterminate"?{[GU]:""}:null}};var vh=T(Q(),1),XU=vs.forwardRef(function(t,a){let{format:o,getAriaValueText:r,locale:n,max:s=100,min:i=0,value:l,render:u,className:c,children:d,style:f,...m}=t,[p,y]=vs.useState(),b="indeterminate",g=null,h=null,x="",S="indeterminate progress";if(l!=null&&Number.isFinite(l)){let E=UU(l,i,s);g=Er(Number.isNaN(E)?0:E,0,100),h=Er(l,i,s),b=h===s?"complete":"progressing",x=o?vw(h,n,o):vw(g/100,n,{style:"percent"}),S=x}let v=vs.useMemo(()=>({status:b}),[b]),R={"aria-labelledby":p,"aria-valuemax":s,"aria-valuemin":i,"aria-valuenow":h??void 0,"aria-valuetext":r?r(x,l):S,role:"progressbar",children:(0,vh.jsxs)(vs.Fragment,{children:[d,(0,vh.jsx)("span",{role:"presentation",style:Df,children:"x"})]})},L=vs.useMemo(()=>({formattedValue:x,percentageValue:g,setLabelId:y,state:v,value:l}),[x,g,y,v,l]),C=$("div",t,{state:v,ref:a,props:[R,m],stateAttributesMapping:On});return(0,vh.jsx)(Cw.Provider,{value:L,children:C})});var YU=T(M(),1);var WU=YU.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,{state:i}=ol();return $("div",t,{state:i,ref:a,props:s,stateAttributesMapping:On})});var KU=T(M(),1);var ZU=KU.forwardRef(function(t,a){let{render:o,className:r,style:n,...s}=t,{percentageValue:i,state:l}=ol(),u=i==null?{}:{insetInlineStart:0,height:"inherit",width:`${i}%`};return $("div",t,{state:l,ref:a,props:[{style:u},s],stateAttributesMapping:On})});var QU=T(M(),1);var JU=QU.forwardRef(function(t,a){let{className:o,render:r,children:n,style:s,...i}=t,{value:l,formattedValue:u,state:c}=ol(),d=c.status==="indeterminate";return $("span",t,{state:c,ref:a,props:[{"aria-hidden":!0,children:typeof n=="function"?n(d?"indeterminate":u,l):d?null:u},i],stateAttributesMapping:On})});var $U=T(M(),1);var e3=$U.forwardRef(function(t,a){let{render:o,className:r,style:n,id:s,...i}=t,{setLabelId:l,state:u}=ol(),c=Vb(s,l);return $("span",t,{state:u,ref:a,props:[{id:c,role:"presentation"},i],stateAttributesMapping:On})});var qu=T(Q(),1);function t3({className:e,children:t,value:a,...o}){return(0,qu.jsxs)(Sd.Root,{value:a,"data-slot":"progress",className:re("flex flex-wrap gap-3",e),...o,children:[t,(0,qu.jsx)(uW,{children:(0,qu.jsx)(cW,{})})]})}function uW({className:e,...t}){return(0,qu.jsx)(Sd.Track,{className:re("relative flex h-1 w-full items-center overflow-x-hidden rounded-full bg-muted",e),"data-slot":"progress-track",...t})}function cW({className:e,...t}){return(0,qu.jsx)(Sd.Indicator,{"data-slot":"progress-indicator",className:re("h-full bg-primary transition-all",e),...t})}var a3=T(M(),1),Le=T(Q(),1);function Ch({label:e,value:t,sub:a,tone:o,hint:r}){return(0,Le.jsxs)(yd,{className:"gap-1 px-5 py-4 animate-in fade-in slide-in-from-bottom-1 duration-500 fill-mode-both",children:[(0,Le.jsxs)("p",{className:"flex items-center gap-1.5 text-xs font-medium uppercase tracking-wide text-muted-foreground",children:[e,r&&(0,Le.jsx)(uv,{children:r})]}),(0,Le.jsx)("p",{className:`text-3xl font-semibold tabular-nums tracking-tight ${o??""}`,children:t}),a&&(0,Le.jsx)("p",{className:"text-xs text-muted-foreground",children:a})]})}function o3(){let[e,t]=(0,a3.useState)("30"),{data:a}=Pi(()=>dr.stats(Number(e)),15e3,[e]),o=a?.totals,r=Math.max(1,...(a?.byDay??[]).map(n=>n.runs));return(0,Le.jsxs)("div",{className:"space-y-5",children:[(0,Le.jsxs)("div",{className:"flex items-center justify-between gap-2",children:[(0,Le.jsx)("h2",{className:"text-lg font-semibold tracking-tight",children:"Statistics"}),(0,Le.jsx)(Rv,{value:e,onChange:t,options:[{value:"7",label:"7 days"},{value:"30",label:"30 days"},{value:"90",label:"90 days"},{value:"0",label:"All"}]})]}),o?(0,Le.jsxs)("div",{className:"grid gap-3 sm:grid-cols-3 lg:grid-cols-5",children:[(0,Le.jsx)(Ch,{label:"Runs",value:String(o.runs),sub:`${o.failed} not ok`}),(0,Le.jsx)(Ch,{label:"Success",value:o.runs?`${Math.round(100*o.ok/o.runs)}%`:"-",tone:"text-success"}),(0,Le.jsx)(Ch,{label:"Worker time",value:es(o.seconds)}),(0,Le.jsx)(Ch,{label:"Tokens",value:ts(o.tokens)}),(0,Le.jsx)(Ch,{label:"Est. saved",value:pr(o.saved),tone:"text-success",hint:(0,Le.jsx)(vv,{price:a?.price})})]}):(0,Le.jsx)("div",{className:"grid gap-3 sm:grid-cols-3 lg:grid-cols-5",children:[0,1,2,3,4].map(n=>(0,Le.jsx)(us,{className:"h-24 rounded-xl"},n))}),a&&a.byDay.length>0&&(0,Le.jsxs)(yd,{className:"gap-3 px-5 py-4 animate-in fade-in duration-700",children:[(0,Le.jsxs)("div",{className:"flex items-baseline justify-between",children:[(0,Le.jsx)("h3",{className:"text-sm font-medium",children:"Runs per day"}),(0,Le.jsxs)("span",{className:"text-xs text-muted-foreground",children:[a.byDay[0]?.day," \u2192 ",a.byDay.at(-1)?.day]})]}),(0,Le.jsx)("div",{className:"flex h-36 items-end gap-1.5",children:a.byDay.map((n,s)=>(0,Le.jsxs)(od,{children:[(0,Le.jsx)(rd,{render:(0,Le.jsx)("div",{className:"group flex h-full max-w-14 flex-1 flex-col justify-end"}),children:(0,Le.jsxs)("div",{className:"flex w-full flex-col justify-end overflow-hidden rounded-t-md transition-opacity group-hover:opacity-80 origin-bottom animate-in slide-in-from-bottom-4 fill-mode-both",style:{height:`${n.runs/r*100}%`,animationDelay:`${s*18}ms`},children:[(0,Le.jsx)("div",{className:"bg-destructive/70",style:{height:`${n.runs?(n.runs-n.ok)/n.runs*100:0}%`}}),(0,Le.jsx)("div",{className:"flex-1 bg-success/80"})]})}),(0,Le.jsxs)(nd,{children:[n.day,": ",n.runs," runs, ",n.ok," ok, ~",pr(n.saved)," saved"]})]},n.day))})]}),a&&(0,Le.jsx)(yd,{className:"overflow-hidden py-0 animate-in fade-in duration-700",children:(0,Le.jsxs)(sv,{children:[(0,Le.jsx)(iv,{children:(0,Le.jsxs)($i,{className:"hover:bg-transparent",children:[(0,Le.jsx)(po,{children:"Worker"}),(0,Le.jsx)(po,{className:"text-right",children:"Runs"}),(0,Le.jsx)(po,{className:"w-44",children:"Success"}),(0,Le.jsx)(po,{className:"hidden text-right sm:table-cell",children:"Avg time"}),(0,Le.jsx)(po,{className:"hidden text-right md:table-cell",children:"Avg tokens"}),(0,Le.jsx)(po,{className:"text-right",children:"Saved"})]})}),(0,Le.jsx)(lv,{children:a.byWorker.map(n=>{let s=Math.round(100*n.ok/n.runs);return(0,Le.jsxs)($i,{children:[(0,Le.jsx)(za,{children:(0,Le.jsx)(Xc,{backend:n.backend,model:n.model})}),(0,Le.jsx)(za,{className:"text-right tabular-nums",children:n.runs}),(0,Le.jsx)(za,{children:(0,Le.jsxs)("div",{className:"flex items-center gap-2",children:[(0,Le.jsx)(t3,{value:s,className:"flex-1"}),(0,Le.jsxs)("span",{className:"w-9 text-right text-xs tabular-nums text-muted-foreground",children:[s,"%"]})]})}),(0,Le.jsx)(za,{className:"hidden text-right tabular-nums sm:table-cell",children:n.avgSeconds!=null?es(n.avgSeconds):"-"}),(0,Le.jsx)(za,{className:"hidden text-right tabular-nums text-muted-foreground md:table-cell",children:n.avgTokens?ts(n.avgTokens):"-"}),(0,Le.jsx)(za,{className:"text-right tabular-nums text-success",children:n.saved?pr(n.saved):"-"})]},`${n.backend}:${n.model}`)})})]})})]})}var Ne=T(Q(),1),fW=/^\d{8}-\d{6}-[0-9a-f]{4}$/;function dW(){return(0,Ne.jsx)("div",{className:"grid size-9 place-items-center rounded-xl bg-gradient-to-br from-brand to-orange-300 shadow-lg shadow-brand/25",children:(0,Ne.jsx)("svg",{viewBox:"0 0 24 24",className:"size-5 fill-white",children:(0,Ne.jsx)("path",{d:"M4 4h4v4H4zm8 0h4v4h-4zM8 8h4v4H8zm8 0h4v4h-4zM4 12h4v4H4zm8 0h4v4h-4zm-4 4h4v4H8zm8 0h4v4h-4z"})})})}function mW(){let[e,t]=(0,kn.useState)(document.documentElement.classList.contains("dark"));return(0,Ne.jsx)(Do,{variant:"ghost",size:"icon","aria-label":"Toggle theme",onClick:()=>{let a=!e;document.documentElement.classList.toggle("dark",a);try{localStorage.setItem("pitroom-theme",a?"dark":"light")}catch{}t(a)},children:e?(0,Ne.jsx)(Fm,{}):(0,Ne.jsx)(Bm,{})})}function pW(){let[e,t]=(0,kn.useState)(!1),[a,o]=(0,kn.useState)(!1);(0,kn.useEffect)(()=>{let n=()=>{t(window.scrollY>8),o(window.scrollY+window.innerHeight<document.documentElement.scrollHeight-8)};n(),window.addEventListener("scroll",n,{passive:!0}),window.addEventListener("resize",n);let s=new ResizeObserver(n);return s.observe(document.body),()=>{window.removeEventListener("scroll",n),window.removeEventListener("resize",n),s.disconnect()}},[]);let r="pointer-events-none fixed inset-x-0 z-30 transition-opacity duration-300";return(0,Ne.jsxs)(Ne.Fragment,{children:[(0,Ne.jsx)("div",{"aria-hidden":!0,className:re(r,"top-0 h-14 bg-gradient-to-b from-background via-background/60 to-transparent",e?"opacity-100":"opacity-0")}),(0,Ne.jsx)("div",{"aria-hidden":!0,className:re(r,"bottom-0 h-20 bg-gradient-to-t from-background via-background/60 to-transparent",a?"opacity-100":"opacity-0")})]})}function r3(){let e=location.hash.slice(1),[t,a]=(0,kn.useState)(e==="history"||e==="stats"?e:"live"),[o,r]=(0,kn.useState)(null),n=fW.test(e)?e:void 0,{data:s,error:i}=Pi(()=>dr.state(1),4e3,[]);return(0,kn.useEffect)(()=>{document.title=`${s?.running?`(${s.running}) `:""}Pitroom`},[s?.running]),(0,kn.useEffect)(()=>{n&&r(n)},[n]),(0,Ne.jsx)(vz,{delay:150,children:(0,Ne.jsxs)("div",{className:"relative min-h-screen",children:[(0,Ne.jsx)("div",{className:"pointer-events-none fixed inset-0 -z-10 bg-[radial-gradient(60rem_30rem_at_85%_-10%,color-mix(in_oklab,var(--brand)_14%,transparent),transparent_60%),radial-gradient(50rem_28rem_at_-10%_0%,color-mix(in_oklab,var(--info)_12%,transparent),transparent_60%)]"}),(0,Ne.jsxs)("main",{className:"mx-auto max-w-4xl px-4 pb-16 pt-8",children:[(0,Ne.jsxs)("header",{className:"mb-6 flex items-center gap-3 animate-in fade-in slide-in-from-top-2 duration-700",children:[(0,Ne.jsx)(dW,{}),(0,Ne.jsxs)("div",{className:"leading-tight",children:[(0,Ne.jsx)("h1",{className:"text-xl font-semibold tracking-tight",children:"Pitroom"}),(0,Ne.jsx)("p",{className:"text-[13px] text-muted-foreground",children:"Your agent's pit crew, live"})]}),(0,Ne.jsx)("div",{className:"flex-1"}),(0,Ne.jsxs)("span",{className:"flex items-center gap-2 text-xs text-muted-foreground",children:[(0,Ne.jsx)("span",{className:re("size-1.5 rounded-full",i?"bg-destructive":"bg-success animate-pulse")}),i?"offline":"live"]}),(0,Ne.jsx)(mW,{})]}),(0,Ne.jsx)(db,{value:t,onValueChange:l=>a(l),children:(0,Ne.jsxs)(mb,{className:"mb-5",children:[(0,Ne.jsx)(Zf,{value:"live",children:"Live"}),(0,Ne.jsx)(Zf,{value:"history",children:"History"}),(0,Ne.jsx)(Zf,{value:"stats",children:"Stats"})]})}),(0,Ne.jsxs)("div",{className:"animate-in fade-in slide-in-from-bottom-1 duration-300",children:[t==="live"&&(0,Ne.jsx)(zU,{focus:n}),t==="history"&&(0,Ne.jsx)(eU,{onOpen:r}),t==="stats"&&(0,Ne.jsx)(o3,{})]},t),(0,Ne.jsxs)("footer",{className:"mt-10 text-center text-xs text-muted-foreground/70",children:["Read-only \xB7 this machine only \xB7 stops itself when left idle (",(0,Ne.jsx)("code",{className:"font-mono",children:"pitroom dash --stop"})," ends it now)"]})]}),(0,Ne.jsx)(pW,{}),(0,Ne.jsx)(qF,{open:!!o,onOpenChange:l=>!l&&r(null),children:(0,Ne.jsxs)(GF,{side:"right",className:"w-full overflow-y-auto sm:max-w-2xl",children:[(0,Ne.jsxs)(jF,{children:[(0,Ne.jsx)(XF,{children:"Run"}),(0,Ne.jsx)(YF,{className:"font-mono text-xs",children:o})]}),(0,Ne.jsx)("div",{className:"px-4 pb-6",children:o&&(0,Ne.jsx)(Zy,{id:o})})]})})]})})}var Lw=T(Q(),1);(0,s3.createRoot)(document.getElementById("root")).render((0,Lw.jsx)(n3.StrictMode,{children:(0,Lw.jsx)(r3,{})}));
|