@kite-copilot/chat-panel 0.2.33 → 0.2.34
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/dist/auto.cjs +1 -1
- package/dist/auto.js +1 -1
- package/dist/{chunk-5BWUHEPW.js → chunk-URD5MNZI.js} +2 -2
- package/dist/embed.global.js +14 -13
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/dist/embed.global.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
"use strict";var KiteChatEmbed=(()=>{var RS=Object.create;var tl=Object.defineProperty;var DS=Object.getOwnPropertyDescriptor;var MS=Object.getOwnPropertyNames;var NS=Object.getPrototypeOf,ES=Object.prototype.hasOwnProperty;var FS=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,a)=>(typeof require<"u"?require:t)[a]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')});var Na=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),BS=(e,t)=>{for(var a in t)tl(e,a,{get:t[a],enumerable:!0})},ch=(e,t,a,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of MS(t))!ES.call(e,o)&&o!==a&&tl(e,o,{get:()=>t[o],enumerable:!(r=DS(t,o))||r.enumerable});return e};var E=(e,t,a)=>(a=e!=null?RS(NS(e)):{},ch(t||!e||!e.__esModule?tl(a,"default",{value:e,enumerable:!0}):a,e)),OS=e=>ch(tl({},"__esModule",{value:!0}),e);var Ih=Na(ae=>{"use strict";var Ls=Symbol.for("react.element"),VS=Symbol.for("react.portal"),US=Symbol.for("react.fragment"),_S=Symbol.for("react.strict_mode"),zS=Symbol.for("react.profiler"),HS=Symbol.for("react.provider"),qS=Symbol.for("react.context"),WS=Symbol.for("react.forward_ref"),GS=Symbol.for("react.suspense"),jS=Symbol.for("react.memo"),KS=Symbol.for("react.lazy"),fh=Symbol.iterator;function $S(e){return e===null||typeof e!="object"?null:(e=fh&&e[fh]||e["@@iterator"],typeof e=="function"?e:null)}var hh={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},gh=Object.assign,xh={};function Oo(e,t,a){this.props=e,this.context=t,this.refs=xh,this.updater=a||hh}Oo.prototype.isReactComponent={};Oo.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): 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")};Oo.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function yh(){}yh.prototype=Oo.prototype;function yc(e,t,a){this.props=e,this.context=t,this.refs=xh,this.updater=a||hh}var vc=yc.prototype=new yh;vc.constructor=yc;gh(vc,Oo.prototype);vc.isPureReactComponent=!0;var ph=Array.isArray,vh=Object.prototype.hasOwnProperty,Lc={current:null},Lh={key:!0,ref:!0,__self:!0,__source:!0};function Ch(e,t,a){var r,o={},n=null,s=null;if(t!=null)for(r in t.ref!==void 0&&(s=t.ref),t.key!==void 0&&(n=""+t.key),t)vh.call(t,r)&&!Lh.hasOwnProperty(r)&&(o[r]=t[r]);var i=arguments.length-2;if(i===1)o.children=a;else if(1<i){for(var l=Array(i),u=0;u<i;u++)l[u]=arguments[u+2];o.children=l}if(e&&e.defaultProps)for(r in i=e.defaultProps,i)o[r]===void 0&&(o[r]=i[r]);return{$$typeof:Ls,type:e,key:n,ref:s,props:o,_owner:Lc.current}}function XS(e,t){return{$$typeof:Ls,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Cc(e){return typeof e=="object"&&e!==null&&e.$$typeof===Ls}function QS(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(a){return t[a]})}var mh=/\/+/g;function xc(e,t){return typeof e=="object"&&e!==null&&e.key!=null?QS(""+e.key):t.toString(36)}function rl(e,t,a,r,o){var n=typeof e;(n==="undefined"||n==="boolean")&&(e=null);var s=!1;if(e===null)s=!0;else switch(n){case"string":case"number":s=!0;break;case"object":switch(e.$$typeof){case Ls:case VS:s=!0}}if(s)return s=e,o=o(s),e=r===""?"."+xc(s,0):r,ph(o)?(a="",e!=null&&(a=e.replace(mh,"$&/")+"/"),rl(o,t,a,"",function(u){return u})):o!=null&&(Cc(o)&&(o=XS(o,a+(!o.key||s&&s.key===o.key?"":(""+o.key).replace(mh,"$&/")+"/")+e)),t.push(o)),1;if(s=0,r=r===""?".":r+":",ph(e))for(var i=0;i<e.length;i++){n=e[i];var l=r+xc(n,i);s+=rl(n,t,a,l,o)}else if(l=$S(e),typeof l=="function")for(e=l.call(e),i=0;!(n=e.next()).done;)n=n.value,l=r+xc(n,i++),s+=rl(n,t,a,l,o);else if(n==="object")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 al(e,t,a){if(e==null)return e;var r=[],o=0;return rl(e,r,"","",function(n){return t.call(a,n,o++)}),r}function YS(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(a){(e._status===0||e._status===-1)&&(e._status=1,e._result=a)},function(a){(e._status===0||e._status===-1)&&(e._status=2,e._result=a)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var ct={current:null},ol={transition:null},ZS={ReactCurrentDispatcher:ct,ReactCurrentBatchConfig:ol,ReactCurrentOwner:Lc};function Sh(){throw Error("act(...) is not supported in production builds of React.")}ae.Children={map:al,forEach:function(e,t,a){al(e,function(){t.apply(this,arguments)},a)},count:function(e){var t=0;return al(e,function(){t++}),t},toArray:function(e){return al(e,function(t){return t})||[]},only:function(e){if(!Cc(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};ae.Component=Oo;ae.Fragment=US;ae.Profiler=zS;ae.PureComponent=yc;ae.StrictMode=_S;ae.Suspense=GS;ae.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ZS;ae.act=Sh;ae.cloneElement=function(e,t,a){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var r=gh({},e.props),o=e.key,n=e.ref,s=e._owner;if(t!=null){if(t.ref!==void 0&&(n=t.ref,s=Lc.current),t.key!==void 0&&(o=""+t.key),e.type&&e.type.defaultProps)var i=e.type.defaultProps;for(l in t)vh.call(t,l)&&!Lh.hasOwnProperty(l)&&(r[l]=t[l]===void 0&&i!==void 0?i[l]:t[l])}var l=arguments.length-2;if(l===1)r.children=a;else if(1<l){i=Array(l);for(var u=0;u<l;u++)i[u]=arguments[u+2];r.children=i}return{$$typeof:Ls,type:e.type,key:o,ref:n,props:r,_owner:s}};ae.createContext=function(e){return e={$$typeof:qS,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:HS,_context:e},e.Consumer=e};ae.createElement=Ch;ae.createFactory=function(e){var t=Ch.bind(null,e);return t.type=e,t};ae.createRef=function(){return{current:null}};ae.forwardRef=function(e){return{$$typeof:WS,render:e}};ae.isValidElement=Cc;ae.lazy=function(e){return{$$typeof:KS,_payload:{_status:-1,_result:e},_init:YS}};ae.memo=function(e,t){return{$$typeof:jS,type:e,compare:t===void 0?null:t}};ae.startTransition=function(e){var t=ol.transition;ol.transition={};try{e()}finally{ol.transition=t}};ae.unstable_act=Sh;ae.useCallback=function(e,t){return ct.current.useCallback(e,t)};ae.useContext=function(e){return ct.current.useContext(e)};ae.useDebugValue=function(){};ae.useDeferredValue=function(e){return ct.current.useDeferredValue(e)};ae.useEffect=function(e,t){return ct.current.useEffect(e,t)};ae.useId=function(){return ct.current.useId()};ae.useImperativeHandle=function(e,t,a){return ct.current.useImperativeHandle(e,t,a)};ae.useInsertionEffect=function(e,t){return ct.current.useInsertionEffect(e,t)};ae.useLayoutEffect=function(e,t){return ct.current.useLayoutEffect(e,t)};ae.useMemo=function(e,t){return ct.current.useMemo(e,t)};ae.useReducer=function(e,t,a){return ct.current.useReducer(e,t,a)};ae.useRef=function(e){return ct.current.useRef(e)};ae.useState=function(e){return ct.current.useState(e)};ae.useSyncExternalStore=function(e,t,a){return ct.current.useSyncExternalStore(e,t,a)};ae.useTransition=function(){return ct.current.useTransition()};ae.version="18.3.1"});var X=Na((NT,wh)=>{"use strict";wh.exports=Ih()});var Eh=Na(ge=>{"use strict";function kc(e,t){var a=e.length;e.push(t);e:for(;0<a;){var r=a-1>>>1,o=e[r];if(0<nl(o,t))e[r]=t,e[a]=o,a=r;else break e}}function aa(e){return e.length===0?null:e[0]}function il(e){if(e.length===0)return null;var t=e[0],a=e.pop();if(a!==t){e[0]=a;e:for(var r=0,o=e.length,n=o>>>1;r<n;){var s=2*(r+1)-1,i=e[s],l=s+1,u=e[l];if(0>nl(i,a))l<o&&0>nl(u,i)?(e[r]=u,e[l]=a,r=l):(e[r]=i,e[s]=a,r=s);else if(l<o&&0>nl(u,a))e[r]=u,e[l]=a,r=l;else break e}}return t}function nl(e,t){var a=e.sortIndex-t.sortIndex;return a!==0?a:e.id-t.id}typeof performance=="object"&&typeof performance.now=="function"?(kh=performance,ge.unstable_now=function(){return kh.now()}):(Sc=Date,bh=Sc.now(),ge.unstable_now=function(){return Sc.now()-bh});var kh,Sc,bh,ma=[],sr=[],JS=1,jt=null,rt=3,ll=!1,Jr=!1,Ss=!1,Ah=typeof setTimeout=="function"?setTimeout:null,Rh=typeof clearTimeout=="function"?clearTimeout:null,Ph=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function bc(e){for(var t=aa(sr);t!==null;){if(t.callback===null)il(sr);else if(t.startTime<=e)il(sr),t.sortIndex=t.expirationTime,kc(ma,t);else break;t=aa(sr)}}function Pc(e){if(Ss=!1,bc(e),!Jr)if(aa(ma)!==null)Jr=!0,Ac(Tc);else{var t=aa(sr);t!==null&&Rc(Pc,t.startTime-e)}}function Tc(e,t){Jr=!1,Ss&&(Ss=!1,Rh(Is),Is=-1),ll=!0;var a=rt;try{for(bc(t),jt=aa(ma);jt!==null&&(!(jt.expirationTime>t)||e&&!Nh());){var r=jt.callback;if(typeof r=="function"){jt.callback=null,rt=jt.priorityLevel;var o=r(jt.expirationTime<=t);t=ge.unstable_now(),typeof o=="function"?jt.callback=o:jt===aa(ma)&&il(ma),bc(t)}else il(ma);jt=aa(ma)}if(jt!==null)var n=!0;else{var s=aa(sr);s!==null&&Rc(Pc,s.startTime-t),n=!1}return n}finally{jt=null,rt=a,ll=!1}}var ul=!1,sl=null,Is=-1,Dh=5,Mh=-1;function Nh(){return!(ge.unstable_now()-Mh<Dh)}function Ic(){if(sl!==null){var e=ge.unstable_now();Mh=e;var t=!0;try{t=sl(!0,e)}finally{t?Cs():(ul=!1,sl=null)}}else ul=!1}var Cs;typeof Ph=="function"?Cs=function(){Ph(Ic)}:typeof MessageChannel<"u"?(wc=new MessageChannel,Th=wc.port2,wc.port1.onmessage=Ic,Cs=function(){Th.postMessage(null)}):Cs=function(){Ah(Ic,0)};var wc,Th;function Ac(e){sl=e,ul||(ul=!0,Cs())}function Rc(e,t){Is=Ah(function(){e(ge.unstable_now())},t)}ge.unstable_IdlePriority=5;ge.unstable_ImmediatePriority=1;ge.unstable_LowPriority=4;ge.unstable_NormalPriority=3;ge.unstable_Profiling=null;ge.unstable_UserBlockingPriority=2;ge.unstable_cancelCallback=function(e){e.callback=null};ge.unstable_continueExecution=function(){Jr||ll||(Jr=!0,Ac(Tc))};ge.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"):Dh=0<e?Math.floor(1e3/e):5};ge.unstable_getCurrentPriorityLevel=function(){return rt};ge.unstable_getFirstCallbackNode=function(){return aa(ma)};ge.unstable_next=function(e){switch(rt){case 1:case 2:case 3:var t=3;break;default:t=rt}var a=rt;rt=t;try{return e()}finally{rt=a}};ge.unstable_pauseExecution=function(){};ge.unstable_requestPaint=function(){};ge.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var a=rt;rt=e;try{return t()}finally{rt=a}};ge.unstable_scheduleCallback=function(e,t,a){var r=ge.unstable_now();switch(typeof a=="object"&&a!==null?(a=a.delay,a=typeof a=="number"&&0<a?r+a:r):a=r,e){case 1:var o=-1;break;case 2:o=250;break;case 5:o=1073741823;break;case 4:o=1e4;break;default:o=5e3}return o=a+o,e={id:JS++,callback:t,priorityLevel:e,startTime:a,expirationTime:o,sortIndex:-1},a>r?(e.sortIndex=a,kc(sr,e),aa(ma)===null&&e===aa(sr)&&(Ss?(Rh(Is),Is=-1):Ss=!0,Rc(Pc,a-r))):(e.sortIndex=o,kc(ma,e),Jr||ll||(Jr=!0,Ac(Tc))),e};ge.unstable_shouldYield=Nh;ge.unstable_wrapCallback=function(e){var t=rt;return function(){var a=rt;rt=t;try{return e.apply(this,arguments)}finally{rt=a}}}});var Bh=Na((FT,Fh)=>{"use strict";Fh.exports=Eh()});var _y=Na(Bt=>{"use strict";var eI=X(),Et=Bh();function D(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,a=1;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."}var qg=new Set,Gs={};function po(e,t){on(e,t),on(e+"Capture",t)}function on(e,t){for(Gs[e]=t,e=0;e<t.length;e++)qg.add(t[e])}var Ua=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Jc=Object.prototype.hasOwnProperty,tI=/^[: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]*$/,Oh={},Vh={};function aI(e){return Jc.call(Vh,e)?!0:Jc.call(Oh,e)?!1:tI.test(e)?Vh[e]=!0:(Oh[e]=!0,!1)}function rI(e,t,a,r){if(a!==null&&a.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:a!==null?!a.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function oI(e,t,a,r){if(t===null||typeof t>"u"||rI(e,t,a,r))return!0;if(r)return!1;if(a!==null)switch(a.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function mt(e,t,a,r,o,n,s){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=a,this.propertyName=e,this.type=t,this.sanitizeURL=n,this.removeEmptyString=s}var Ze={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ze[e]=new mt(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ze[t]=new mt(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ze[e]=new mt(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ze[e]=new mt(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Ze[e]=new mt(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Ze[e]=new mt(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Ze[e]=new mt(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Ze[e]=new mt(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Ze[e]=new mt(e,5,!1,e.toLowerCase(),null,!1,!1)});var jf=/[\-:]([a-z])/g;function Kf(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(jf,Kf);Ze[t]=new mt(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(jf,Kf);Ze[t]=new mt(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(jf,Kf);Ze[t]=new mt(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Ze[e]=new mt(e,1,!1,e.toLowerCase(),null,!1,!1)});Ze.xlinkHref=new mt("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Ze[e]=new mt(e,1,!1,e.toLowerCase(),null,!0,!0)});function $f(e,t,a,r){var o=Ze.hasOwnProperty(t)?Ze[t]:null;(o!==null?o.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(oI(t,a,o,r)&&(a=null),r||o===null?aI(t)&&(a===null?e.removeAttribute(t):e.setAttribute(t,""+a)):o.mustUseProperty?e[o.propertyName]=a===null?o.type===3?!1:"":a:(t=o.attributeName,r=o.attributeNamespace,a===null?e.removeAttribute(t):(o=o.type,a=o===3||o===4&&a===!0?"":""+a,r?e.setAttributeNS(r,t,a):e.setAttribute(t,a))))}var qa=eI.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,dl=Symbol.for("react.element"),_o=Symbol.for("react.portal"),zo=Symbol.for("react.fragment"),Xf=Symbol.for("react.strict_mode"),ef=Symbol.for("react.profiler"),Wg=Symbol.for("react.provider"),Gg=Symbol.for("react.context"),Qf=Symbol.for("react.forward_ref"),tf=Symbol.for("react.suspense"),af=Symbol.for("react.suspense_list"),Yf=Symbol.for("react.memo"),lr=Symbol.for("react.lazy"),jg=Symbol.for("react.offscreen"),Uh=Symbol.iterator;function ws(e){return e===null||typeof e!="object"?null:(e=Uh&&e[Uh]||e["@@iterator"],typeof e=="function"?e:null)}var Pe=Object.assign,Dc;function Ms(e){if(Dc===void 0)try{throw Error()}catch(a){var t=a.stack.trim().match(/\n( *(at )?)/);Dc=t&&t[1]||""}return`
|
|
2
|
-
`+
|
|
1
|
+
"use strict";var KiteChatEmbed=(()=>{var DS=Object.create;var al=Object.defineProperty;var MS=Object.getOwnPropertyDescriptor;var NS=Object.getOwnPropertyNames;var ES=Object.getPrototypeOf,FS=Object.prototype.hasOwnProperty;var BS=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,a)=>(typeof require<"u"?require:t)[a]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')});var Na=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),OS=(e,t)=>{for(var a in t)al(e,a,{get:t[a],enumerable:!0})},fh=(e,t,a,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of NS(t))!FS.call(e,o)&&o!==a&&al(e,o,{get:()=>t[o],enumerable:!(r=MS(t,o))||r.enumerable});return e};var E=(e,t,a)=>(a=e!=null?DS(ES(e)):{},fh(t||!e||!e.__esModule?al(a,"default",{value:e,enumerable:!0}):a,e)),VS=e=>fh(al({},"__esModule",{value:!0}),e);var wh=Na(ae=>{"use strict";var Ls=Symbol.for("react.element"),US=Symbol.for("react.portal"),_S=Symbol.for("react.fragment"),zS=Symbol.for("react.strict_mode"),HS=Symbol.for("react.profiler"),qS=Symbol.for("react.provider"),WS=Symbol.for("react.context"),GS=Symbol.for("react.forward_ref"),jS=Symbol.for("react.suspense"),KS=Symbol.for("react.memo"),$S=Symbol.for("react.lazy"),ph=Symbol.iterator;function XS(e){return e===null||typeof e!="object"?null:(e=ph&&e[ph]||e["@@iterator"],typeof e=="function"?e:null)}var gh={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},xh=Object.assign,yh={};function Oo(e,t,a){this.props=e,this.context=t,this.refs=yh,this.updater=a||gh}Oo.prototype.isReactComponent={};Oo.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): 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")};Oo.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function vh(){}vh.prototype=Oo.prototype;function vc(e,t,a){this.props=e,this.context=t,this.refs=yh,this.updater=a||gh}var Lc=vc.prototype=new vh;Lc.constructor=vc;xh(Lc,Oo.prototype);Lc.isPureReactComponent=!0;var mh=Array.isArray,Lh=Object.prototype.hasOwnProperty,Cc={current:null},Ch={key:!0,ref:!0,__self:!0,__source:!0};function Sh(e,t,a){var r,o={},n=null,s=null;if(t!=null)for(r in t.ref!==void 0&&(s=t.ref),t.key!==void 0&&(n=""+t.key),t)Lh.call(t,r)&&!Ch.hasOwnProperty(r)&&(o[r]=t[r]);var i=arguments.length-2;if(i===1)o.children=a;else if(1<i){for(var l=Array(i),u=0;u<i;u++)l[u]=arguments[u+2];o.children=l}if(e&&e.defaultProps)for(r in i=e.defaultProps,i)o[r]===void 0&&(o[r]=i[r]);return{$$typeof:Ls,type:e,key:n,ref:s,props:o,_owner:Cc.current}}function QS(e,t){return{$$typeof:Ls,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Sc(e){return typeof e=="object"&&e!==null&&e.$$typeof===Ls}function YS(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(a){return t[a]})}var hh=/\/+/g;function yc(e,t){return typeof e=="object"&&e!==null&&e.key!=null?YS(""+e.key):t.toString(36)}function ol(e,t,a,r,o){var n=typeof e;(n==="undefined"||n==="boolean")&&(e=null);var s=!1;if(e===null)s=!0;else switch(n){case"string":case"number":s=!0;break;case"object":switch(e.$$typeof){case Ls:case US:s=!0}}if(s)return s=e,o=o(s),e=r===""?"."+yc(s,0):r,mh(o)?(a="",e!=null&&(a=e.replace(hh,"$&/")+"/"),ol(o,t,a,"",function(u){return u})):o!=null&&(Sc(o)&&(o=QS(o,a+(!o.key||s&&s.key===o.key?"":(""+o.key).replace(hh,"$&/")+"/")+e)),t.push(o)),1;if(s=0,r=r===""?".":r+":",mh(e))for(var i=0;i<e.length;i++){n=e[i];var l=r+yc(n,i);s+=ol(n,t,a,l,o)}else if(l=XS(e),typeof l=="function")for(e=l.call(e),i=0;!(n=e.next()).done;)n=n.value,l=r+yc(n,i++),s+=ol(n,t,a,l,o);else if(n==="object")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 rl(e,t,a){if(e==null)return e;var r=[],o=0;return ol(e,r,"","",function(n){return t.call(a,n,o++)}),r}function ZS(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(a){(e._status===0||e._status===-1)&&(e._status=1,e._result=a)},function(a){(e._status===0||e._status===-1)&&(e._status=2,e._result=a)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var ct={current:null},nl={transition:null},JS={ReactCurrentDispatcher:ct,ReactCurrentBatchConfig:nl,ReactCurrentOwner:Cc};function Ih(){throw Error("act(...) is not supported in production builds of React.")}ae.Children={map:rl,forEach:function(e,t,a){rl(e,function(){t.apply(this,arguments)},a)},count:function(e){var t=0;return rl(e,function(){t++}),t},toArray:function(e){return rl(e,function(t){return t})||[]},only:function(e){if(!Sc(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};ae.Component=Oo;ae.Fragment=_S;ae.Profiler=HS;ae.PureComponent=vc;ae.StrictMode=zS;ae.Suspense=jS;ae.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=JS;ae.act=Ih;ae.cloneElement=function(e,t,a){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var r=xh({},e.props),o=e.key,n=e.ref,s=e._owner;if(t!=null){if(t.ref!==void 0&&(n=t.ref,s=Cc.current),t.key!==void 0&&(o=""+t.key),e.type&&e.type.defaultProps)var i=e.type.defaultProps;for(l in t)Lh.call(t,l)&&!Ch.hasOwnProperty(l)&&(r[l]=t[l]===void 0&&i!==void 0?i[l]:t[l])}var l=arguments.length-2;if(l===1)r.children=a;else if(1<l){i=Array(l);for(var u=0;u<l;u++)i[u]=arguments[u+2];r.children=i}return{$$typeof:Ls,type:e.type,key:o,ref:n,props:r,_owner:s}};ae.createContext=function(e){return e={$$typeof:WS,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:qS,_context:e},e.Consumer=e};ae.createElement=Sh;ae.createFactory=function(e){var t=Sh.bind(null,e);return t.type=e,t};ae.createRef=function(){return{current:null}};ae.forwardRef=function(e){return{$$typeof:GS,render:e}};ae.isValidElement=Sc;ae.lazy=function(e){return{$$typeof:$S,_payload:{_status:-1,_result:e},_init:ZS}};ae.memo=function(e,t){return{$$typeof:KS,type:e,compare:t===void 0?null:t}};ae.startTransition=function(e){var t=nl.transition;nl.transition={};try{e()}finally{nl.transition=t}};ae.unstable_act=Ih;ae.useCallback=function(e,t){return ct.current.useCallback(e,t)};ae.useContext=function(e){return ct.current.useContext(e)};ae.useDebugValue=function(){};ae.useDeferredValue=function(e){return ct.current.useDeferredValue(e)};ae.useEffect=function(e,t){return ct.current.useEffect(e,t)};ae.useId=function(){return ct.current.useId()};ae.useImperativeHandle=function(e,t,a){return ct.current.useImperativeHandle(e,t,a)};ae.useInsertionEffect=function(e,t){return ct.current.useInsertionEffect(e,t)};ae.useLayoutEffect=function(e,t){return ct.current.useLayoutEffect(e,t)};ae.useMemo=function(e,t){return ct.current.useMemo(e,t)};ae.useReducer=function(e,t,a){return ct.current.useReducer(e,t,a)};ae.useRef=function(e){return ct.current.useRef(e)};ae.useState=function(e){return ct.current.useState(e)};ae.useSyncExternalStore=function(e,t,a){return ct.current.useSyncExternalStore(e,t,a)};ae.useTransition=function(){return ct.current.useTransition()};ae.version="18.3.1"});var X=Na((FT,kh)=>{"use strict";kh.exports=wh()});var Fh=Na(ge=>{"use strict";function bc(e,t){var a=e.length;e.push(t);e:for(;0<a;){var r=a-1>>>1,o=e[r];if(0<sl(o,t))e[r]=t,e[a]=o,a=r;else break e}}function aa(e){return e.length===0?null:e[0]}function ll(e){if(e.length===0)return null;var t=e[0],a=e.pop();if(a!==t){e[0]=a;e:for(var r=0,o=e.length,n=o>>>1;r<n;){var s=2*(r+1)-1,i=e[s],l=s+1,u=e[l];if(0>sl(i,a))l<o&&0>sl(u,i)?(e[r]=u,e[l]=a,r=l):(e[r]=i,e[s]=a,r=s);else if(l<o&&0>sl(u,a))e[r]=u,e[l]=a,r=l;else break e}}return t}function sl(e,t){var a=e.sortIndex-t.sortIndex;return a!==0?a:e.id-t.id}typeof performance=="object"&&typeof performance.now=="function"?(bh=performance,ge.unstable_now=function(){return bh.now()}):(Ic=Date,Ph=Ic.now(),ge.unstable_now=function(){return Ic.now()-Ph});var bh,Ic,Ph,ma=[],sr=[],eI=1,jt=null,rt=3,ul=!1,Zr=!1,Ss=!1,Rh=typeof setTimeout=="function"?setTimeout:null,Dh=typeof clearTimeout=="function"?clearTimeout:null,Th=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function Pc(e){for(var t=aa(sr);t!==null;){if(t.callback===null)ll(sr);else if(t.startTime<=e)ll(sr),t.sortIndex=t.expirationTime,bc(ma,t);else break;t=aa(sr)}}function Tc(e){if(Ss=!1,Pc(e),!Zr)if(aa(ma)!==null)Zr=!0,Rc(Ac);else{var t=aa(sr);t!==null&&Dc(Tc,t.startTime-e)}}function Ac(e,t){Zr=!1,Ss&&(Ss=!1,Dh(Is),Is=-1),ul=!0;var a=rt;try{for(Pc(t),jt=aa(ma);jt!==null&&(!(jt.expirationTime>t)||e&&!Eh());){var r=jt.callback;if(typeof r=="function"){jt.callback=null,rt=jt.priorityLevel;var o=r(jt.expirationTime<=t);t=ge.unstable_now(),typeof o=="function"?jt.callback=o:jt===aa(ma)&&ll(ma),Pc(t)}else ll(ma);jt=aa(ma)}if(jt!==null)var n=!0;else{var s=aa(sr);s!==null&&Dc(Tc,s.startTime-t),n=!1}return n}finally{jt=null,rt=a,ul=!1}}var dl=!1,il=null,Is=-1,Mh=5,Nh=-1;function Eh(){return!(ge.unstable_now()-Nh<Mh)}function wc(){if(il!==null){var e=ge.unstable_now();Nh=e;var t=!0;try{t=il(!0,e)}finally{t?Cs():(dl=!1,il=null)}}else dl=!1}var Cs;typeof Th=="function"?Cs=function(){Th(wc)}:typeof MessageChannel<"u"?(kc=new MessageChannel,Ah=kc.port2,kc.port1.onmessage=wc,Cs=function(){Ah.postMessage(null)}):Cs=function(){Rh(wc,0)};var kc,Ah;function Rc(e){il=e,dl||(dl=!0,Cs())}function Dc(e,t){Is=Rh(function(){e(ge.unstable_now())},t)}ge.unstable_IdlePriority=5;ge.unstable_ImmediatePriority=1;ge.unstable_LowPriority=4;ge.unstable_NormalPriority=3;ge.unstable_Profiling=null;ge.unstable_UserBlockingPriority=2;ge.unstable_cancelCallback=function(e){e.callback=null};ge.unstable_continueExecution=function(){Zr||ul||(Zr=!0,Rc(Ac))};ge.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"):Mh=0<e?Math.floor(1e3/e):5};ge.unstable_getCurrentPriorityLevel=function(){return rt};ge.unstable_getFirstCallbackNode=function(){return aa(ma)};ge.unstable_next=function(e){switch(rt){case 1:case 2:case 3:var t=3;break;default:t=rt}var a=rt;rt=t;try{return e()}finally{rt=a}};ge.unstable_pauseExecution=function(){};ge.unstable_requestPaint=function(){};ge.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var a=rt;rt=e;try{return t()}finally{rt=a}};ge.unstable_scheduleCallback=function(e,t,a){var r=ge.unstable_now();switch(typeof a=="object"&&a!==null?(a=a.delay,a=typeof a=="number"&&0<a?r+a:r):a=r,e){case 1:var o=-1;break;case 2:o=250;break;case 5:o=1073741823;break;case 4:o=1e4;break;default:o=5e3}return o=a+o,e={id:eI++,callback:t,priorityLevel:e,startTime:a,expirationTime:o,sortIndex:-1},a>r?(e.sortIndex=a,bc(sr,e),aa(ma)===null&&e===aa(sr)&&(Ss?(Dh(Is),Is=-1):Ss=!0,Dc(Tc,a-r))):(e.sortIndex=o,bc(ma,e),Zr||ul||(Zr=!0,Rc(Ac))),e};ge.unstable_shouldYield=Eh;ge.unstable_wrapCallback=function(e){var t=rt;return function(){var a=rt;rt=t;try{return e.apply(this,arguments)}finally{rt=a}}}});var Oh=Na((OT,Bh)=>{"use strict";Bh.exports=Fh()});var zy=Na(Bt=>{"use strict";var tI=X(),Et=Oh();function D(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,a=1;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."}var Wg=new Set,Gs={};function fo(e,t){on(e,t),on(e+"Capture",t)}function on(e,t){for(Gs[e]=t,e=0;e<t.length;e++)Wg.add(t[e])}var Ua=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),ef=Object.prototype.hasOwnProperty,aI=/^[: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]*$/,Vh={},Uh={};function rI(e){return ef.call(Uh,e)?!0:ef.call(Vh,e)?!1:aI.test(e)?Uh[e]=!0:(Vh[e]=!0,!1)}function oI(e,t,a,r){if(a!==null&&a.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:a!==null?!a.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function nI(e,t,a,r){if(t===null||typeof t>"u"||oI(e,t,a,r))return!0;if(r)return!1;if(a!==null)switch(a.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function mt(e,t,a,r,o,n,s){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=a,this.propertyName=e,this.type=t,this.sanitizeURL=n,this.removeEmptyString=s}var Ze={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ze[e]=new mt(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ze[t]=new mt(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ze[e]=new mt(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ze[e]=new mt(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Ze[e]=new mt(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Ze[e]=new mt(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Ze[e]=new mt(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Ze[e]=new mt(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Ze[e]=new mt(e,5,!1,e.toLowerCase(),null,!1,!1)});var Kf=/[\-:]([a-z])/g;function $f(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Kf,$f);Ze[t]=new mt(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Kf,$f);Ze[t]=new mt(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Kf,$f);Ze[t]=new mt(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Ze[e]=new mt(e,1,!1,e.toLowerCase(),null,!1,!1)});Ze.xlinkHref=new mt("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Ze[e]=new mt(e,1,!1,e.toLowerCase(),null,!0,!0)});function Xf(e,t,a,r){var o=Ze.hasOwnProperty(t)?Ze[t]:null;(o!==null?o.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(nI(t,a,o,r)&&(a=null),r||o===null?rI(t)&&(a===null?e.removeAttribute(t):e.setAttribute(t,""+a)):o.mustUseProperty?e[o.propertyName]=a===null?o.type===3?!1:"":a:(t=o.attributeName,r=o.attributeNamespace,a===null?e.removeAttribute(t):(o=o.type,a=o===3||o===4&&a===!0?"":""+a,r?e.setAttributeNS(r,t,a):e.setAttribute(t,a))))}var qa=tI.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,cl=Symbol.for("react.element"),_o=Symbol.for("react.portal"),zo=Symbol.for("react.fragment"),Qf=Symbol.for("react.strict_mode"),tf=Symbol.for("react.profiler"),Gg=Symbol.for("react.provider"),jg=Symbol.for("react.context"),Yf=Symbol.for("react.forward_ref"),af=Symbol.for("react.suspense"),rf=Symbol.for("react.suspense_list"),Zf=Symbol.for("react.memo"),lr=Symbol.for("react.lazy"),Kg=Symbol.for("react.offscreen"),_h=Symbol.iterator;function ws(e){return e===null||typeof e!="object"?null:(e=_h&&e[_h]||e["@@iterator"],typeof e=="function"?e:null)}var Pe=Object.assign,Mc;function Ms(e){if(Mc===void 0)try{throw Error()}catch(a){var t=a.stack.trim().match(/\n( *(at )?)/);Mc=t&&t[1]||""}return`
|
|
2
|
+
`+Mc+e}var Nc=!1;function Ec(e,t){if(!e||Nc)return"";Nc=!0;var a=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(u){var r=u}Reflect.construct(e,[],t)}else{try{t.call()}catch(u){r=u}e.call(t.prototype)}else{try{throw Error()}catch(u){r=u}e()}}catch(u){if(u&&r&&typeof u.stack=="string"){for(var o=u.stack.split(`
|
|
3
3
|
`),n=r.stack.split(`
|
|
4
4
|
`),s=o.length-1,i=n.length-1;1<=s&&0<=i&&o[s]!==n[i];)i--;for(;1<=s&&0<=i;s--,i--)if(o[s]!==n[i]){if(s!==1||i!==1)do if(s--,i--,0>i||o[s]!==n[i]){var l=`
|
|
5
|
-
`+o[s].replace(" at new "," at ");return e.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",e.displayName)),l}while(1<=s&&0<=i);break}}}finally{Mc=!1,Error.prepareStackTrace=a}return(e=e?e.displayName||e.name:"")?Ms(e):""}function nI(e){switch(e.tag){case 5:return Ms(e.type);case 16:return Ms("Lazy");case 13:return Ms("Suspense");case 19:return Ms("SuspenseList");case 0:case 2:case 15:return e=Nc(e.type,!1),e;case 11:return e=Nc(e.type.render,!1),e;case 1:return e=Nc(e.type,!0),e;default:return""}}function rf(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case zo:return"Fragment";case _o:return"Portal";case ef:return"Profiler";case Xf:return"StrictMode";case tf:return"Suspense";case af:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Gg:return(e.displayName||"Context")+".Consumer";case Wg:return(e._context.displayName||"Context")+".Provider";case Qf:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Yf:return t=e.displayName||null,t!==null?t:rf(e.type)||"Memo";case lr:t=e._payload,e=e._init;try{return rf(e(t))}catch{}}return null}function sI(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return rf(t);case 8:return t===Xf?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Sr(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Kg(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function iI(e){var t=Kg(e)?"checked":"value",a=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof a<"u"&&typeof a.get=="function"&&typeof a.set=="function"){var o=a.get,n=a.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(s){r=""+s,n.call(this,s)}}),Object.defineProperty(e,t,{enumerable:a.enumerable}),{getValue:function(){return r},setValue:function(s){r=""+s},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function cl(e){e._valueTracker||(e._valueTracker=iI(e))}function $g(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var a=t.getValue(),r="";return e&&(r=Kg(e)?e.checked?"true":"false":e.value),e=r,e!==a?(t.setValue(e),!0):!1}function Ul(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 of(e,t){var a=t.checked;return Pe({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:a??e._wrapperState.initialChecked})}function _h(e,t){var a=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;a=Sr(t.value!=null?t.value:a),e._wrapperState={initialChecked:r,initialValue:a,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Xg(e,t){t=t.checked,t!=null&&$f(e,"checked",t,!1)}function nf(e,t){Xg(e,t);var a=Sr(t.value),r=t.type;if(a!=null)r==="number"?(a===0&&e.value===""||e.value!=a)&&(e.value=""+a):e.value!==""+a&&(e.value=""+a);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?sf(e,t.type,a):t.hasOwnProperty("defaultValue")&&sf(e,t.type,Sr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function zh(e,t,a){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,a||t===e.value||(e.value=t),e.defaultValue=t}a=e.name,a!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,a!==""&&(e.name=a)}function sf(e,t,a){(t!=="number"||Ul(e.ownerDocument)!==e)&&(a==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+a&&(e.defaultValue=""+a))}var Ns=Array.isArray;function Zo(e,t,a,r){if(e=e.options,t){t={};for(var o=0;o<a.length;o++)t["$"+a[o]]=!0;for(a=0;a<e.length;a++)o=t.hasOwnProperty("$"+e[a].value),e[a].selected!==o&&(e[a].selected=o),o&&r&&(e[a].defaultSelected=!0)}else{for(a=""+Sr(a),t=null,o=0;o<e.length;o++){if(e[o].value===a){e[o].selected=!0,r&&(e[o].defaultSelected=!0);return}t!==null||e[o].disabled||(t=e[o])}t!==null&&(t.selected=!0)}}function lf(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(D(91));return Pe({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function Hh(e,t){var a=t.value;if(a==null){if(a=t.children,t=t.defaultValue,a!=null){if(t!=null)throw Error(D(92));if(Ns(a)){if(1<a.length)throw Error(D(93));a=a[0]}t=a}t==null&&(t=""),a=t}e._wrapperState={initialValue:Sr(a)}}function Qg(e,t){var a=Sr(t.value),r=Sr(t.defaultValue);a!=null&&(a=""+a,a!==e.value&&(e.value=a),t.defaultValue==null&&e.defaultValue!==a&&(e.defaultValue=a)),r!=null&&(e.defaultValue=""+r)}function qh(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function Yg(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function uf(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?Yg(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var fl,Zg=(function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,a,r,o){MSApp.execUnsafeLocalFunction(function(){return e(t,a,r,o)})}:e})(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(fl=fl||document.createElement("div"),fl.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=fl.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function js(e,t){if(t){var a=e.firstChild;if(a&&a===e.lastChild&&a.nodeType===3){a.nodeValue=t;return}}e.textContent=t}var Bs={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},lI=["Webkit","ms","Moz","O"];Object.keys(Bs).forEach(function(e){lI.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Bs[t]=Bs[e]})});function Jg(e,t,a){return t==null||typeof t=="boolean"||t===""?"":a||typeof t!="number"||t===0||Bs.hasOwnProperty(e)&&Bs[e]?(""+t).trim():t+"px"}function ex(e,t){e=e.style;for(var a in t)if(t.hasOwnProperty(a)){var r=a.indexOf("--")===0,o=Jg(a,t[a],r);a==="float"&&(a="cssFloat"),r?e.setProperty(a,o):e[a]=o}}var uI=Pe({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function df(e,t){if(t){if(uI[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(D(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(D(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(D(61))}if(t.style!=null&&typeof t.style!="object")throw Error(D(62))}}function cf(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";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 ff=null;function Zf(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var pf=null,Jo=null,en=null;function Wh(e){if(e=di(e)){if(typeof pf!="function")throw Error(D(280));var t=e.stateNode;t&&(t=pu(t),pf(e.stateNode,e.type,t))}}function tx(e){Jo?en?en.push(e):en=[e]:Jo=e}function ax(){if(Jo){var e=Jo,t=en;if(en=Jo=null,Wh(e),t)for(e=0;e<t.length;e++)Wh(t[e])}}function rx(e,t){return e(t)}function ox(){}var Ec=!1;function nx(e,t,a){if(Ec)return e(t,a);Ec=!0;try{return rx(e,t,a)}finally{Ec=!1,(Jo!==null||en!==null)&&(ox(),ax())}}function Ks(e,t){var a=e.stateNode;if(a===null)return null;var r=pu(a);if(r===null)return null;a=r[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":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(a&&typeof a!="function")throw Error(D(231,t,typeof a));return a}var mf=!1;if(Ua)try{Vo={},Object.defineProperty(Vo,"passive",{get:function(){mf=!0}}),window.addEventListener("test",Vo,Vo),window.removeEventListener("test",Vo,Vo)}catch{mf=!1}var Vo;function dI(e,t,a,r,o,n,s,i,l){var u=Array.prototype.slice.call(arguments,3);try{t.apply(a,u)}catch(d){this.onError(d)}}var Os=!1,_l=null,zl=!1,hf=null,cI={onError:function(e){Os=!0,_l=e}};function fI(e,t,a,r,o,n,s,i,l){Os=!1,_l=null,dI.apply(cI,arguments)}function pI(e,t,a,r,o,n,s,i,l){if(fI.apply(this,arguments),Os){if(Os){var u=_l;Os=!1,_l=null}else throw Error(D(198));zl||(zl=!0,hf=u)}}function mo(e){var t=e,a=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(a=t.return),e=t.return;while(e)}return t.tag===3?a:null}function sx(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 Gh(e){if(mo(e)!==e)throw Error(D(188))}function mI(e){var t=e.alternate;if(!t){if(t=mo(e),t===null)throw Error(D(188));return t!==e?null:e}for(var a=e,r=t;;){var o=a.return;if(o===null)break;var n=o.alternate;if(n===null){if(r=o.return,r!==null){a=r;continue}break}if(o.child===n.child){for(n=o.child;n;){if(n===a)return Gh(o),e;if(n===r)return Gh(o),t;n=n.sibling}throw Error(D(188))}if(a.return!==r.return)a=o,r=n;else{for(var s=!1,i=o.child;i;){if(i===a){s=!0,a=o,r=n;break}if(i===r){s=!0,r=o,a=n;break}i=i.sibling}if(!s){for(i=n.child;i;){if(i===a){s=!0,a=n,r=o;break}if(i===r){s=!0,r=n,a=o;break}i=i.sibling}if(!s)throw Error(D(189))}}if(a.alternate!==r)throw Error(D(190))}if(a.tag!==3)throw Error(D(188));return a.stateNode.current===a?e:t}function ix(e){return e=mI(e),e!==null?lx(e):null}function lx(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=lx(e);if(t!==null)return t;e=e.sibling}return null}var ux=Et.unstable_scheduleCallback,jh=Et.unstable_cancelCallback,hI=Et.unstable_shouldYield,gI=Et.unstable_requestPaint,Ne=Et.unstable_now,xI=Et.unstable_getCurrentPriorityLevel,Jf=Et.unstable_ImmediatePriority,dx=Et.unstable_UserBlockingPriority,Hl=Et.unstable_NormalPriority,yI=Et.unstable_LowPriority,cx=Et.unstable_IdlePriority,uu=null,ya=null;function vI(e){if(ya&&typeof ya.onCommitFiberRoot=="function")try{ya.onCommitFiberRoot(uu,e,void 0,(e.current.flags&128)===128)}catch{}}var ia=Math.clz32?Math.clz32:SI,LI=Math.log,CI=Math.LN2;function SI(e){return e>>>=0,e===0?32:31-(LI(e)/CI|0)|0}var pl=64,ml=4194304;function Es(e){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: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 e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function ql(e,t){var a=e.pendingLanes;if(a===0)return 0;var r=0,o=e.suspendedLanes,n=e.pingedLanes,s=a&268435455;if(s!==0){var i=s&~o;i!==0?r=Es(i):(n&=s,n!==0&&(r=Es(n)))}else s=a&~o,s!==0?r=Es(s):n!==0&&(r=Es(n));if(r===0)return 0;if(t!==0&&t!==r&&(t&o)===0&&(o=r&-r,n=t&-t,o>=n||o===16&&(n&4194240)!==0))return t;if((r&4)!==0&&(r|=a&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0<t;)a=31-ia(t),o=1<<a,r|=e[a],t&=~o;return r}function II(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64: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:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function wI(e,t){for(var a=e.suspendedLanes,r=e.pingedLanes,o=e.expirationTimes,n=e.pendingLanes;0<n;){var s=31-ia(n),i=1<<s,l=o[s];l===-1?((i&a)===0||(i&r)!==0)&&(o[s]=II(i,t)):l<=t&&(e.expiredLanes|=i),n&=~i}}function gf(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function fx(){var e=pl;return pl<<=1,(pl&4194240)===0&&(pl=64),e}function Fc(e){for(var t=[],a=0;31>a;a++)t.push(e);return t}function li(e,t,a){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-ia(t),e[t]=a}function kI(e,t){var a=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0<a;){var o=31-ia(a),n=1<<o;t[o]=0,r[o]=-1,e[o]=-1,a&=~n}}function ep(e,t){var a=e.entangledLanes|=t;for(e=e.entanglements;a;){var r=31-ia(a),o=1<<r;o&t|e[r]&t&&(e[r]|=t),a&=~o}}var pe=0;function px(e){return e&=-e,1<e?4<e?(e&268435455)!==0?16:536870912:4:1}var mx,tp,hx,gx,xx,xf=!1,hl=[],mr=null,hr=null,gr=null,$s=new Map,Xs=new Map,dr=[],bI="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 submit".split(" ");function Kh(e,t){switch(e){case"focusin":case"focusout":mr=null;break;case"dragenter":case"dragleave":hr=null;break;case"mouseover":case"mouseout":gr=null;break;case"pointerover":case"pointerout":$s.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Xs.delete(t.pointerId)}}function ks(e,t,a,r,o,n){return e===null||e.nativeEvent!==n?(e={blockedOn:t,domEventName:a,eventSystemFlags:r,nativeEvent:n,targetContainers:[o]},t!==null&&(t=di(t),t!==null&&tp(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,o!==null&&t.indexOf(o)===-1&&t.push(o),e)}function PI(e,t,a,r,o){switch(t){case"focusin":return mr=ks(mr,e,t,a,r,o),!0;case"dragenter":return hr=ks(hr,e,t,a,r,o),!0;case"mouseover":return gr=ks(gr,e,t,a,r,o),!0;case"pointerover":var n=o.pointerId;return $s.set(n,ks($s.get(n)||null,e,t,a,r,o)),!0;case"gotpointercapture":return n=o.pointerId,Xs.set(n,ks(Xs.get(n)||null,e,t,a,r,o)),!0}return!1}function yx(e){var t=ao(e.target);if(t!==null){var a=mo(t);if(a!==null){if(t=a.tag,t===13){if(t=sx(a),t!==null){e.blockedOn=t,xx(e.priority,function(){hx(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 Al(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var a=yf(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(a===null){a=e.nativeEvent;var r=new a.constructor(a.type,a);ff=r,a.target.dispatchEvent(r),ff=null}else return t=di(a),t!==null&&tp(t),e.blockedOn=a,!1;t.shift()}return!0}function $h(e,t,a){Al(e)&&a.delete(t)}function TI(){xf=!1,mr!==null&&Al(mr)&&(mr=null),hr!==null&&Al(hr)&&(hr=null),gr!==null&&Al(gr)&&(gr=null),$s.forEach($h),Xs.forEach($h)}function bs(e,t){e.blockedOn===t&&(e.blockedOn=null,xf||(xf=!0,Et.unstable_scheduleCallback(Et.unstable_NormalPriority,TI)))}function Qs(e){function t(o){return bs(o,e)}if(0<hl.length){bs(hl[0],e);for(var a=1;a<hl.length;a++){var r=hl[a];r.blockedOn===e&&(r.blockedOn=null)}}for(mr!==null&&bs(mr,e),hr!==null&&bs(hr,e),gr!==null&&bs(gr,e),$s.forEach(t),Xs.forEach(t),a=0;a<dr.length;a++)r=dr[a],r.blockedOn===e&&(r.blockedOn=null);for(;0<dr.length&&(a=dr[0],a.blockedOn===null);)yx(a),a.blockedOn===null&&dr.shift()}var tn=qa.ReactCurrentBatchConfig,Wl=!0;function AI(e,t,a,r){var o=pe,n=tn.transition;tn.transition=null;try{pe=1,ap(e,t,a,r)}finally{pe=o,tn.transition=n}}function RI(e,t,a,r){var o=pe,n=tn.transition;tn.transition=null;try{pe=4,ap(e,t,a,r)}finally{pe=o,tn.transition=n}}function ap(e,t,a,r){if(Wl){var o=yf(e,t,a,r);if(o===null)Hc(e,t,r,Gl,a),Kh(e,r);else if(PI(o,e,t,a,r))r.stopPropagation();else if(Kh(e,r),t&4&&-1<bI.indexOf(e)){for(;o!==null;){var n=di(o);if(n!==null&&mx(n),n=yf(e,t,a,r),n===null&&Hc(e,t,r,Gl,a),n===o)break;o=n}o!==null&&r.stopPropagation()}else Hc(e,t,r,null,a)}}var Gl=null;function yf(e,t,a,r){if(Gl=null,e=Zf(r),e=ao(e),e!==null)if(t=mo(e),t===null)e=null;else if(a=t.tag,a===13){if(e=sx(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 Gl=e,null}function vx(e){switch(e){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"resize":case"seeked":case"submit":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"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(xI()){case Jf:return 1;case dx:return 4;case Hl:case yI:return 16;case cx:return 536870912;default:return 16}default:return 16}}var fr=null,rp=null,Rl=null;function Lx(){if(Rl)return Rl;var e,t=rp,a=t.length,r,o="value"in fr?fr.value:fr.textContent,n=o.length;for(e=0;e<a&&t[e]===o[e];e++);var s=a-e;for(r=1;r<=s&&t[a-r]===o[n-r];r++);return Rl=o.slice(e,1<r?1-r:void 0)}function Dl(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 gl(){return!0}function Xh(){return!1}function Ft(e){function t(a,r,o,n,s){this._reactName=a,this._targetInst=o,this.type=r,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)?gl:Xh,this.isPropagationStopped=Xh,this}return Pe(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=gl)},stopPropagation:function(){var a=this.nativeEvent;a&&(a.stopPropagation?a.stopPropagation():typeof a.cancelBubble!="unknown"&&(a.cancelBubble=!0),this.isPropagationStopped=gl)},persist:function(){},isPersistent:gl}),t}var fn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},op=Ft(fn),ui=Pe({},fn,{view:0,detail:0}),DI=Ft(ui),Bc,Oc,Ps,du=Pe({},ui,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:np,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!==Ps&&(Ps&&e.type==="mousemove"?(Bc=e.screenX-Ps.screenX,Oc=e.screenY-Ps.screenY):Oc=Bc=0,Ps=e),Bc)},movementY:function(e){return"movementY"in e?e.movementY:Oc}}),Qh=Ft(du),MI=Pe({},du,{dataTransfer:0}),NI=Ft(MI),EI=Pe({},ui,{relatedTarget:0}),Vc=Ft(EI),FI=Pe({},fn,{animationName:0,elapsedTime:0,pseudoElement:0}),BI=Ft(FI),OI=Pe({},fn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),VI=Ft(OI),UI=Pe({},fn,{data:0}),Yh=Ft(UI),_I={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},zI={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"},HI={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function qI(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=HI[e])?!!t[e]:!1}function np(){return qI}var WI=Pe({},ui,{key:function(e){if(e.key){var t=_I[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Dl(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?zI[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:np,charCode:function(e){return e.type==="keypress"?Dl(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Dl(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),GI=Ft(WI),jI=Pe({},du,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Zh=Ft(jI),KI=Pe({},ui,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:np}),$I=Ft(KI),XI=Pe({},fn,{propertyName:0,elapsedTime:0,pseudoElement:0}),QI=Ft(XI),YI=Pe({},du,{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}),ZI=Ft(YI),JI=[9,13,27,32],sp=Ua&&"CompositionEvent"in window,Vs=null;Ua&&"documentMode"in document&&(Vs=document.documentMode);var ew=Ua&&"TextEvent"in window&&!Vs,Cx=Ua&&(!sp||Vs&&8<Vs&&11>=Vs),Jh=" ",eg=!1;function Sx(e,t){switch(e){case"keyup":return JI.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Ix(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Ho=!1;function tw(e,t){switch(e){case"compositionend":return Ix(t);case"keypress":return t.which!==32?null:(eg=!0,Jh);case"textInput":return e=t.data,e===Jh&&eg?null:e;default:return null}}function aw(e,t){if(Ho)return e==="compositionend"||!sp&&Sx(e,t)?(e=Lx(),Rl=rp=fr=null,Ho=!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 Cx&&t.locale!=="ko"?null:t.data;default:return null}}var rw={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 tg(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!rw[e.type]:t==="textarea"}function wx(e,t,a,r){tx(r),t=jl(t,"onChange"),0<t.length&&(a=new op("onChange","change",null,a,r),e.push({event:a,listeners:t}))}var Us=null,Ys=null;function ow(e){Fx(e,0)}function cu(e){var t=Go(e);if($g(t))return e}function nw(e,t){if(e==="change")return t}var kx=!1;Ua&&(Ua?(yl="oninput"in document,yl||(Uc=document.createElement("div"),Uc.setAttribute("oninput","return;"),yl=typeof Uc.oninput=="function"),xl=yl):xl=!1,kx=xl&&(!document.documentMode||9<document.documentMode));var xl,yl,Uc;function ag(){Us&&(Us.detachEvent("onpropertychange",bx),Ys=Us=null)}function bx(e){if(e.propertyName==="value"&&cu(Ys)){var t=[];wx(t,Ys,e,Zf(e)),nx(ow,t)}}function sw(e,t,a){e==="focusin"?(ag(),Us=t,Ys=a,Us.attachEvent("onpropertychange",bx)):e==="focusout"&&ag()}function iw(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return cu(Ys)}function lw(e,t){if(e==="click")return cu(t)}function uw(e,t){if(e==="input"||e==="change")return cu(t)}function dw(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var ua=typeof Object.is=="function"?Object.is:dw;function Zs(e,t){if(ua(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var a=Object.keys(e),r=Object.keys(t);if(a.length!==r.length)return!1;for(r=0;r<a.length;r++){var o=a[r];if(!Jc.call(t,o)||!ua(e[o],t[o]))return!1}return!0}function rg(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function og(e,t){var a=rg(e);e=0;for(var r;a;){if(a.nodeType===3){if(r=e+a.textContent.length,e<=t&&r>=t)return{node:a,offset:t-e};e=r}e:{for(;a;){if(a.nextSibling){a=a.nextSibling;break e}a=a.parentNode}a=void 0}a=rg(a)}}function Px(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Px(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Tx(){for(var e=window,t=Ul();t instanceof e.HTMLIFrameElement;){try{var a=typeof t.contentWindow.location.href=="string"}catch{a=!1}if(a)e=t.contentWindow;else break;t=Ul(e.document)}return t}function ip(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")}function cw(e){var t=Tx(),a=e.focusedElem,r=e.selectionRange;if(t!==a&&a&&a.ownerDocument&&Px(a.ownerDocument.documentElement,a)){if(r!==null&&ip(a)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in a)a.selectionStart=t,a.selectionEnd=Math.min(e,a.value.length);else if(e=(t=a.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var o=a.textContent.length,n=Math.min(r.start,o);r=r.end===void 0?n:Math.min(r.end,o),!e.extend&&n>r&&(o=r,r=n,n=o),o=og(a,n);var s=og(a,r);o&&s&&(e.rangeCount!==1||e.anchorNode!==o.node||e.anchorOffset!==o.offset||e.focusNode!==s.node||e.focusOffset!==s.offset)&&(t=t.createRange(),t.setStart(o.node,o.offset),e.removeAllRanges(),n>r?(e.addRange(t),e.extend(s.node,s.offset)):(t.setEnd(s.node,s.offset),e.addRange(t)))}}for(t=[],e=a;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof a.focus=="function"&&a.focus(),a=0;a<t.length;a++)e=t[a],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var fw=Ua&&"documentMode"in document&&11>=document.documentMode,qo=null,vf=null,_s=null,Lf=!1;function ng(e,t,a){var r=a.window===a?a.document:a.nodeType===9?a:a.ownerDocument;Lf||qo==null||qo!==Ul(r)||(r=qo,"selectionStart"in r&&ip(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),_s&&Zs(_s,r)||(_s=r,r=jl(vf,"onSelect"),0<r.length&&(t=new op("onSelect","select",null,t,a),e.push({event:t,listeners:r}),t.target=qo)))}function vl(e,t){var a={};return a[e.toLowerCase()]=t.toLowerCase(),a["Webkit"+e]="webkit"+t,a["Moz"+e]="moz"+t,a}var Wo={animationend:vl("Animation","AnimationEnd"),animationiteration:vl("Animation","AnimationIteration"),animationstart:vl("Animation","AnimationStart"),transitionend:vl("Transition","TransitionEnd")},_c={},Ax={};Ua&&(Ax=document.createElement("div").style,"AnimationEvent"in window||(delete Wo.animationend.animation,delete Wo.animationiteration.animation,delete Wo.animationstart.animation),"TransitionEvent"in window||delete Wo.transitionend.transition);function fu(e){if(_c[e])return _c[e];if(!Wo[e])return e;var t=Wo[e],a;for(a in t)if(t.hasOwnProperty(a)&&a in Ax)return _c[e]=t[a];return e}var Rx=fu("animationend"),Dx=fu("animationiteration"),Mx=fu("animationstart"),Nx=fu("transitionend"),Ex=new Map,sg="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error 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(" ");function wr(e,t){Ex.set(e,t),po(t,[e])}for(Ll=0;Ll<sg.length;Ll++)Cl=sg[Ll],ig=Cl.toLowerCase(),lg=Cl[0].toUpperCase()+Cl.slice(1),wr(ig,"on"+lg);var Cl,ig,lg,Ll;wr(Rx,"onAnimationEnd");wr(Dx,"onAnimationIteration");wr(Mx,"onAnimationStart");wr("dblclick","onDoubleClick");wr("focusin","onFocus");wr("focusout","onBlur");wr(Nx,"onTransitionEnd");on("onMouseEnter",["mouseout","mouseover"]);on("onMouseLeave",["mouseout","mouseover"]);on("onPointerEnter",["pointerout","pointerover"]);on("onPointerLeave",["pointerout","pointerover"]);po("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));po("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));po("onBeforeInput",["compositionend","keypress","textInput","paste"]);po("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));po("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));po("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Fs="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(" "),pw=new Set("cancel close invalid load scroll toggle".split(" ").concat(Fs));function ug(e,t,a){var r=e.type||"unknown-event";e.currentTarget=a,pI(r,t,void 0,e),e.currentTarget=null}function Fx(e,t){t=(t&4)!==0;for(var a=0;a<e.length;a++){var r=e[a],o=r.event;r=r.listeners;e:{var n=void 0;if(t)for(var s=r.length-1;0<=s;s--){var i=r[s],l=i.instance,u=i.currentTarget;if(i=i.listener,l!==n&&o.isPropagationStopped())break e;ug(o,i,u),n=l}else for(s=0;s<r.length;s++){if(i=r[s],l=i.instance,u=i.currentTarget,i=i.listener,l!==n&&o.isPropagationStopped())break e;ug(o,i,u),n=l}}}if(zl)throw e=hf,zl=!1,hf=null,e}function ve(e,t){var a=t[kf];a===void 0&&(a=t[kf]=new Set);var r=e+"__bubble";a.has(r)||(Bx(t,e,2,!1),a.add(r))}function zc(e,t,a){var r=0;t&&(r|=4),Bx(a,e,r,t)}var Sl="_reactListening"+Math.random().toString(36).slice(2);function Js(e){if(!e[Sl]){e[Sl]=!0,qg.forEach(function(a){a!=="selectionchange"&&(pw.has(a)||zc(a,!1,e),zc(a,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Sl]||(t[Sl]=!0,zc("selectionchange",!1,t))}}function Bx(e,t,a,r){switch(vx(t)){case 1:var o=AI;break;case 4:o=RI;break;default:o=ap}a=o.bind(null,t,a,e),o=void 0,!mf||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(o=!0),r?o!==void 0?e.addEventListener(t,a,{capture:!0,passive:o}):e.addEventListener(t,a,!0):o!==void 0?e.addEventListener(t,a,{passive:o}):e.addEventListener(t,a,!1)}function Hc(e,t,a,r,o){var n=r;if((t&1)===0&&(t&2)===0&&r!==null)e:for(;;){if(r===null)return;var s=r.tag;if(s===3||s===4){var i=r.stateNode.containerInfo;if(i===o||i.nodeType===8&&i.parentNode===o)break;if(s===4)for(s=r.return;s!==null;){var l=s.tag;if((l===3||l===4)&&(l=s.stateNode.containerInfo,l===o||l.nodeType===8&&l.parentNode===o))return;s=s.return}for(;i!==null;){if(s=ao(i),s===null)return;if(l=s.tag,l===5||l===6){r=n=s;continue e}i=i.parentNode}}r=r.return}nx(function(){var u=n,d=Zf(a),c=[];e:{var p=Ex.get(e);if(p!==void 0){var g=op,C=e;switch(e){case"keypress":if(Dl(a)===0)break e;case"keydown":case"keyup":g=GI;break;case"focusin":C="focus",g=Vc;break;case"focusout":C="blur",g=Vc;break;case"beforeblur":case"afterblur":g=Vc;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":g=Qh;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":g=NI;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":g=$I;break;case Rx:case Dx:case Mx:g=BI;break;case Nx:g=QI;break;case"scroll":g=DI;break;case"wheel":g=ZI;break;case"copy":case"cut":case"paste":g=VI;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":g=Zh}var L=(t&4)!==0,S=!L&&e==="scroll",h=L?p!==null?p+"Capture":null:p;L=[];for(var m=u,x;m!==null;){x=m;var I=x.stateNode;if(x.tag===5&&I!==null&&(x=I,h!==null&&(I=Ks(m,h),I!=null&&L.push(ei(m,I,x)))),S)break;m=m.return}0<L.length&&(p=new g(p,C,null,a,d),c.push({event:p,listeners:L}))}}if((t&7)===0){e:{if(p=e==="mouseover"||e==="pointerover",g=e==="mouseout"||e==="pointerout",p&&a!==ff&&(C=a.relatedTarget||a.fromElement)&&(ao(C)||C[_a]))break e;if((g||p)&&(p=d.window===d?d:(p=d.ownerDocument)?p.defaultView||p.parentWindow:window,g?(C=a.relatedTarget||a.toElement,g=u,C=C?ao(C):null,C!==null&&(S=mo(C),C!==S||C.tag!==5&&C.tag!==6)&&(C=null)):(g=null,C=u),g!==C)){if(L=Qh,I="onMouseLeave",h="onMouseEnter",m="mouse",(e==="pointerout"||e==="pointerover")&&(L=Zh,I="onPointerLeave",h="onPointerEnter",m="pointer"),S=g==null?p:Go(g),x=C==null?p:Go(C),p=new L(I,m+"leave",g,a,d),p.target=S,p.relatedTarget=x,I=null,ao(d)===u&&(L=new L(h,m+"enter",C,a,d),L.target=x,L.relatedTarget=S,I=L),S=I,g&&C)t:{for(L=g,h=C,m=0,x=L;x;x=Uo(x))m++;for(x=0,I=h;I;I=Uo(I))x++;for(;0<m-x;)L=Uo(L),m--;for(;0<x-m;)h=Uo(h),x--;for(;m--;){if(L===h||h!==null&&L===h.alternate)break t;L=Uo(L),h=Uo(h)}L=null}else L=null;g!==null&&dg(c,p,g,L,!1),C!==null&&S!==null&&dg(c,S,C,L,!0)}}e:{if(p=u?Go(u):window,g=p.nodeName&&p.nodeName.toLowerCase(),g==="select"||g==="input"&&p.type==="file")var k=nw;else if(tg(p))if(kx)k=uw;else{k=iw;var T=sw}else(g=p.nodeName)&&g.toLowerCase()==="input"&&(p.type==="checkbox"||p.type==="radio")&&(k=lw);if(k&&(k=k(e,u))){wx(c,k,a,d);break e}T&&T(e,p,u),e==="focusout"&&(T=p._wrapperState)&&T.controlled&&p.type==="number"&&sf(p,"number",p.value)}switch(T=u?Go(u):window,e){case"focusin":(tg(T)||T.contentEditable==="true")&&(qo=T,vf=u,_s=null);break;case"focusout":_s=vf=qo=null;break;case"mousedown":Lf=!0;break;case"contextmenu":case"mouseup":case"dragend":Lf=!1,ng(c,a,d);break;case"selectionchange":if(fw)break;case"keydown":case"keyup":ng(c,a,d)}var R;if(sp)e:{switch(e){case"compositionstart":var A="onCompositionStart";break e;case"compositionend":A="onCompositionEnd";break e;case"compositionupdate":A="onCompositionUpdate";break e}A=void 0}else Ho?Sx(e,a)&&(A="onCompositionEnd"):e==="keydown"&&a.keyCode===229&&(A="onCompositionStart");A&&(Cx&&a.locale!=="ko"&&(Ho||A!=="onCompositionStart"?A==="onCompositionEnd"&&Ho&&(R=Lx()):(fr=d,rp="value"in fr?fr.value:fr.textContent,Ho=!0)),T=jl(u,A),0<T.length&&(A=new Yh(A,e,null,a,d),c.push({event:A,listeners:T}),R?A.data=R:(R=Ix(a),R!==null&&(A.data=R)))),(R=ew?tw(e,a):aw(e,a))&&(u=jl(u,"onBeforeInput"),0<u.length&&(d=new Yh("onBeforeInput","beforeinput",null,a,d),c.push({event:d,listeners:u}),d.data=R))}Fx(c,t)})}function ei(e,t,a){return{instance:e,listener:t,currentTarget:a}}function jl(e,t){for(var a=t+"Capture",r=[];e!==null;){var o=e,n=o.stateNode;o.tag===5&&n!==null&&(o=n,n=Ks(e,a),n!=null&&r.unshift(ei(e,n,o)),n=Ks(e,t),n!=null&&r.push(ei(e,n,o))),e=e.return}return r}function Uo(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function dg(e,t,a,r,o){for(var n=t._reactName,s=[];a!==null&&a!==r;){var i=a,l=i.alternate,u=i.stateNode;if(l!==null&&l===r)break;i.tag===5&&u!==null&&(i=u,o?(l=Ks(a,n),l!=null&&s.unshift(ei(a,l,i))):o||(l=Ks(a,n),l!=null&&s.push(ei(a,l,i)))),a=a.return}s.length!==0&&e.push({event:t,listeners:s})}var mw=/\r\n?/g,hw=/\u0000|\uFFFD/g;function cg(e){return(typeof e=="string"?e:""+e).replace(mw,`
|
|
6
|
-
`).replace(hw,"")}function Il(e,t,a){if(t=cg(t),cg(e)!==t&&a)throw Error(D(425))}function Kl(){}var Cf=null,Sf=null;function If(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var wf=typeof setTimeout=="function"?setTimeout:void 0,gw=typeof clearTimeout=="function"?clearTimeout:void 0,fg=typeof Promise=="function"?Promise:void 0,xw=typeof queueMicrotask=="function"?queueMicrotask:typeof fg<"u"?function(e){return fg.resolve(null).then(e).catch(yw)}:wf;function yw(e){setTimeout(function(){throw e})}function qc(e,t){var a=t,r=0;do{var o=a.nextSibling;if(e.removeChild(a),o&&o.nodeType===8)if(a=o.data,a==="/$"){if(r===0){e.removeChild(o),Qs(t);return}r--}else a!=="$"&&a!=="$?"&&a!=="$!"||r++;a=o}while(a);Qs(t)}function xr(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==="$?")break;if(t==="/$")return null}}return e}function pg(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var a=e.data;if(a==="$"||a==="$!"||a==="$?"){if(t===0)return e;t--}else a==="/$"&&t++}e=e.previousSibling}return null}var pn=Math.random().toString(36).slice(2),xa="__reactFiber$"+pn,ti="__reactProps$"+pn,_a="__reactContainer$"+pn,kf="__reactEvents$"+pn,vw="__reactListeners$"+pn,Lw="__reactHandles$"+pn;function ao(e){var t=e[xa];if(t)return t;for(var a=e.parentNode;a;){if(t=a[_a]||a[xa]){if(a=t.alternate,t.child!==null||a!==null&&a.child!==null)for(e=pg(e);e!==null;){if(a=e[xa])return a;e=pg(e)}return t}e=a,a=e.parentNode}return null}function di(e){return e=e[xa]||e[_a],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Go(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(D(33))}function pu(e){return e[ti]||null}var bf=[],jo=-1;function kr(e){return{current:e}}function Le(e){0>jo||(e.current=bf[jo],bf[jo]=null,jo--)}function xe(e,t){jo++,bf[jo]=e.current,e.current=t}var Ir={},it=kr(Ir),Lt=kr(!1),io=Ir;function nn(e,t){var a=e.type.contextTypes;if(!a)return Ir;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o={},n;for(n in a)o[n]=t[n];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function Ct(e){return e=e.childContextTypes,e!=null}function $l(){Le(Lt),Le(it)}function mg(e,t,a){if(it.current!==Ir)throw Error(D(168));xe(it,t),xe(Lt,a)}function Ox(e,t,a){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return a;r=r.getChildContext();for(var o in r)if(!(o in t))throw Error(D(108,sI(e)||"Unknown",o));return Pe({},a,r)}function Xl(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Ir,io=it.current,xe(it,e),xe(Lt,Lt.current),!0}function hg(e,t,a){var r=e.stateNode;if(!r)throw Error(D(169));a?(e=Ox(e,t,io),r.__reactInternalMemoizedMergedChildContext=e,Le(Lt),Le(it),xe(it,e)):Le(Lt),xe(Lt,a)}var Fa=null,mu=!1,Wc=!1;function Vx(e){Fa===null?Fa=[e]:Fa.push(e)}function Cw(e){mu=!0,Vx(e)}function br(){if(!Wc&&Fa!==null){Wc=!0;var e=0,t=pe;try{var a=Fa;for(pe=1;e<a.length;e++){var r=a[e];do r=r(!0);while(r!==null)}Fa=null,mu=!1}catch(o){throw Fa!==null&&(Fa=Fa.slice(e+1)),ux(Jf,br),o}finally{pe=t,Wc=!1}}return null}var Ko=[],$o=0,Ql=null,Yl=0,Kt=[],$t=0,lo=null,Ba=1,Oa="";function eo(e,t){Ko[$o++]=Yl,Ko[$o++]=Ql,Ql=e,Yl=t}function Ux(e,t,a){Kt[$t++]=Ba,Kt[$t++]=Oa,Kt[$t++]=lo,lo=e;var r=Ba;e=Oa;var o=32-ia(r)-1;r&=~(1<<o),a+=1;var n=32-ia(t)+o;if(30<n){var s=o-o%5;n=(r&(1<<s)-1).toString(32),r>>=s,o-=s,Ba=1<<32-ia(t)+o|a<<o|r,Oa=n+e}else Ba=1<<n|a<<o|r,Oa=e}function lp(e){e.return!==null&&(eo(e,1),Ux(e,1,0))}function up(e){for(;e===Ql;)Ql=Ko[--$o],Ko[$o]=null,Yl=Ko[--$o],Ko[$o]=null;for(;e===lo;)lo=Kt[--$t],Kt[$t]=null,Oa=Kt[--$t],Kt[$t]=null,Ba=Kt[--$t],Kt[$t]=null}var Nt=null,Mt=null,we=!1,sa=null;function _x(e,t){var a=Xt(5,null,null,0);a.elementType="DELETED",a.stateNode=t,a.return=e,t=e.deletions,t===null?(e.deletions=[a],e.flags|=16):t.push(a)}function gg(e,t){switch(e.tag){case 5:var a=e.type;return t=t.nodeType!==1||a.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,Nt=e,Mt=xr(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,Nt=e,Mt=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(a=lo!==null?{id:Ba,overflow:Oa}:null,e.memoizedState={dehydrated:t,treeContext:a,retryLane:1073741824},a=Xt(18,null,null,0),a.stateNode=t,a.return=e,e.child=a,Nt=e,Mt=null,!0):!1;default:return!1}}function Pf(e){return(e.mode&1)!==0&&(e.flags&128)===0}function Tf(e){if(we){var t=Mt;if(t){var a=t;if(!gg(e,t)){if(Pf(e))throw Error(D(418));t=xr(a.nextSibling);var r=Nt;t&&gg(e,t)?_x(r,a):(e.flags=e.flags&-4097|2,we=!1,Nt=e)}}else{if(Pf(e))throw Error(D(418));e.flags=e.flags&-4097|2,we=!1,Nt=e}}}function xg(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Nt=e}function wl(e){if(e!==Nt)return!1;if(!we)return xg(e),we=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!If(e.type,e.memoizedProps)),t&&(t=Mt)){if(Pf(e))throw zx(),Error(D(418));for(;t;)_x(e,t),t=xr(t.nextSibling)}if(xg(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(D(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var a=e.data;if(a==="/$"){if(t===0){Mt=xr(e.nextSibling);break e}t--}else a!=="$"&&a!=="$!"&&a!=="$?"||t++}e=e.nextSibling}Mt=null}}else Mt=Nt?xr(e.stateNode.nextSibling):null;return!0}function zx(){for(var e=Mt;e;)e=xr(e.nextSibling)}function sn(){Mt=Nt=null,we=!1}function dp(e){sa===null?sa=[e]:sa.push(e)}var Sw=qa.ReactCurrentBatchConfig;function Ts(e,t,a){if(e=a.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(a._owner){if(a=a._owner,a){if(a.tag!==1)throw Error(D(309));var r=a.stateNode}if(!r)throw Error(D(147,e));var o=r,n=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===n?t.ref:(t=function(s){var i=o.refs;s===null?delete i[n]:i[n]=s},t._stringRef=n,t)}if(typeof e!="string")throw Error(D(284));if(!a._owner)throw Error(D(290,e))}return e}function kl(e,t){throw e=Object.prototype.toString.call(t),Error(D(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function yg(e){var t=e._init;return t(e._payload)}function Hx(e){function t(h,m){if(e){var x=h.deletions;x===null?(h.deletions=[m],h.flags|=16):x.push(m)}}function a(h,m){if(!e)return null;for(;m!==null;)t(h,m),m=m.sibling;return null}function r(h,m){for(h=new Map;m!==null;)m.key!==null?h.set(m.key,m):h.set(m.index,m),m=m.sibling;return h}function o(h,m){return h=Cr(h,m),h.index=0,h.sibling=null,h}function n(h,m,x){return h.index=x,e?(x=h.alternate,x!==null?(x=x.index,x<m?(h.flags|=2,m):x):(h.flags|=2,m)):(h.flags|=1048576,m)}function s(h){return e&&h.alternate===null&&(h.flags|=2),h}function i(h,m,x,I){return m===null||m.tag!==6?(m=Yc(x,h.mode,I),m.return=h,m):(m=o(m,x),m.return=h,m)}function l(h,m,x,I){var k=x.type;return k===zo?d(h,m,x.props.children,I,x.key):m!==null&&(m.elementType===k||typeof k=="object"&&k!==null&&k.$$typeof===lr&&yg(k)===m.type)?(I=o(m,x.props),I.ref=Ts(h,m,x),I.return=h,I):(I=Vl(x.type,x.key,x.props,null,h.mode,I),I.ref=Ts(h,m,x),I.return=h,I)}function u(h,m,x,I){return m===null||m.tag!==4||m.stateNode.containerInfo!==x.containerInfo||m.stateNode.implementation!==x.implementation?(m=Zc(x,h.mode,I),m.return=h,m):(m=o(m,x.children||[]),m.return=h,m)}function d(h,m,x,I,k){return m===null||m.tag!==7?(m=so(x,h.mode,I,k),m.return=h,m):(m=o(m,x),m.return=h,m)}function c(h,m,x){if(typeof m=="string"&&m!==""||typeof m=="number")return m=Yc(""+m,h.mode,x),m.return=h,m;if(typeof m=="object"&&m!==null){switch(m.$$typeof){case dl:return x=Vl(m.type,m.key,m.props,null,h.mode,x),x.ref=Ts(h,null,m),x.return=h,x;case _o:return m=Zc(m,h.mode,x),m.return=h,m;case lr:var I=m._init;return c(h,I(m._payload),x)}if(Ns(m)||ws(m))return m=so(m,h.mode,x,null),m.return=h,m;kl(h,m)}return null}function p(h,m,x,I){var k=m!==null?m.key:null;if(typeof x=="string"&&x!==""||typeof x=="number")return k!==null?null:i(h,m,""+x,I);if(typeof x=="object"&&x!==null){switch(x.$$typeof){case dl:return x.key===k?l(h,m,x,I):null;case _o:return x.key===k?u(h,m,x,I):null;case lr:return k=x._init,p(h,m,k(x._payload),I)}if(Ns(x)||ws(x))return k!==null?null:d(h,m,x,I,null);kl(h,x)}return null}function g(h,m,x,I,k){if(typeof I=="string"&&I!==""||typeof I=="number")return h=h.get(x)||null,i(m,h,""+I,k);if(typeof I=="object"&&I!==null){switch(I.$$typeof){case dl:return h=h.get(I.key===null?x:I.key)||null,l(m,h,I,k);case _o:return h=h.get(I.key===null?x:I.key)||null,u(m,h,I,k);case lr:var T=I._init;return g(h,m,x,T(I._payload),k)}if(Ns(I)||ws(I))return h=h.get(x)||null,d(m,h,I,k,null);kl(m,I)}return null}function C(h,m,x,I){for(var k=null,T=null,R=m,A=m=0,V=null;R!==null&&A<x.length;A++){R.index>A?(V=R,R=null):V=R.sibling;var U=p(h,R,x[A],I);if(U===null){R===null&&(R=V);break}e&&R&&U.alternate===null&&t(h,R),m=n(U,m,A),T===null?k=U:T.sibling=U,T=U,R=V}if(A===x.length)return a(h,R),we&&eo(h,A),k;if(R===null){for(;A<x.length;A++)R=c(h,x[A],I),R!==null&&(m=n(R,m,A),T===null?k=R:T.sibling=R,T=R);return we&&eo(h,A),k}for(R=r(h,R);A<x.length;A++)V=g(R,h,A,x[A],I),V!==null&&(e&&V.alternate!==null&&R.delete(V.key===null?A:V.key),m=n(V,m,A),T===null?k=V:T.sibling=V,T=V);return e&&R.forEach(function(se){return t(h,se)}),we&&eo(h,A),k}function L(h,m,x,I){var k=ws(x);if(typeof k!="function")throw Error(D(150));if(x=k.call(x),x==null)throw Error(D(151));for(var T=k=null,R=m,A=m=0,V=null,U=x.next();R!==null&&!U.done;A++,U=x.next()){R.index>A?(V=R,R=null):V=R.sibling;var se=p(h,R,U.value,I);if(se===null){R===null&&(R=V);break}e&&R&&se.alternate===null&&t(h,R),m=n(se,m,A),T===null?k=se:T.sibling=se,T=se,R=V}if(U.done)return a(h,R),we&&eo(h,A),k;if(R===null){for(;!U.done;A++,U=x.next())U=c(h,U.value,I),U!==null&&(m=n(U,m,A),T===null?k=U:T.sibling=U,T=U);return we&&eo(h,A),k}for(R=r(h,R);!U.done;A++,U=x.next())U=g(R,h,A,U.value,I),U!==null&&(e&&U.alternate!==null&&R.delete(U.key===null?A:U.key),m=n(U,m,A),T===null?k=U:T.sibling=U,T=U);return e&&R.forEach(function(q){return t(h,q)}),we&&eo(h,A),k}function S(h,m,x,I){if(typeof x=="object"&&x!==null&&x.type===zo&&x.key===null&&(x=x.props.children),typeof x=="object"&&x!==null){switch(x.$$typeof){case dl:e:{for(var k=x.key,T=m;T!==null;){if(T.key===k){if(k=x.type,k===zo){if(T.tag===7){a(h,T.sibling),m=o(T,x.props.children),m.return=h,h=m;break e}}else if(T.elementType===k||typeof k=="object"&&k!==null&&k.$$typeof===lr&&yg(k)===T.type){a(h,T.sibling),m=o(T,x.props),m.ref=Ts(h,T,x),m.return=h,h=m;break e}a(h,T);break}else t(h,T);T=T.sibling}x.type===zo?(m=so(x.props.children,h.mode,I,x.key),m.return=h,h=m):(I=Vl(x.type,x.key,x.props,null,h.mode,I),I.ref=Ts(h,m,x),I.return=h,h=I)}return s(h);case _o:e:{for(T=x.key;m!==null;){if(m.key===T)if(m.tag===4&&m.stateNode.containerInfo===x.containerInfo&&m.stateNode.implementation===x.implementation){a(h,m.sibling),m=o(m,x.children||[]),m.return=h,h=m;break e}else{a(h,m);break}else t(h,m);m=m.sibling}m=Zc(x,h.mode,I),m.return=h,h=m}return s(h);case lr:return T=x._init,S(h,m,T(x._payload),I)}if(Ns(x))return C(h,m,x,I);if(ws(x))return L(h,m,x,I);kl(h,x)}return typeof x=="string"&&x!==""||typeof x=="number"?(x=""+x,m!==null&&m.tag===6?(a(h,m.sibling),m=o(m,x),m.return=h,h=m):(a(h,m),m=Yc(x,h.mode,I),m.return=h,h=m),s(h)):a(h,m)}return S}var ln=Hx(!0),qx=Hx(!1),Zl=kr(null),Jl=null,Xo=null,cp=null;function fp(){cp=Xo=Jl=null}function pp(e){var t=Zl.current;Le(Zl),e._currentValue=t}function Af(e,t,a){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===a)break;e=e.return}}function an(e,t){Jl=e,cp=Xo=null,e=e.dependencies,e!==null&&e.firstContext!==null&&((e.lanes&t)!==0&&(vt=!0),e.firstContext=null)}function Yt(e){var t=e._currentValue;if(cp!==e)if(e={context:e,memoizedValue:t,next:null},Xo===null){if(Jl===null)throw Error(D(308));Xo=e,Jl.dependencies={lanes:0,firstContext:e}}else Xo=Xo.next=e;return t}var ro=null;function mp(e){ro===null?ro=[e]:ro.push(e)}function Wx(e,t,a,r){var o=t.interleaved;return o===null?(a.next=a,mp(t)):(a.next=o.next,o.next=a),t.interleaved=a,za(e,r)}function za(e,t){e.lanes|=t;var a=e.alternate;for(a!==null&&(a.lanes|=t),a=e,e=e.return;e!==null;)e.childLanes|=t,a=e.alternate,a!==null&&(a.childLanes|=t),a=e,e=e.return;return a.tag===3?a.stateNode:null}var ur=!1;function hp(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Gx(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function Va(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function yr(e,t,a){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,(le&2)!==0){var o=r.pending;return o===null?t.next=t:(t.next=o.next,o.next=t),r.pending=t,za(e,a)}return o=r.interleaved,o===null?(t.next=t,mp(r)):(t.next=o.next,o.next=t),r.interleaved=t,za(e,a)}function Ml(e,t,a){if(t=t.updateQueue,t!==null&&(t=t.shared,(a&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,a|=r,t.lanes=a,ep(e,a)}}function vg(e,t){var a=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,a===r)){var o=null,n=null;if(a=a.firstBaseUpdate,a!==null){do{var s={eventTime:a.eventTime,lane:a.lane,tag:a.tag,payload:a.payload,callback:a.callback,next:null};n===null?o=n=s:n=n.next=s,a=a.next}while(a!==null);n===null?o=n=t:n=n.next=t}else o=n=t;a={baseState:r.baseState,firstBaseUpdate:o,lastBaseUpdate:n,shared:r.shared,effects:r.effects},e.updateQueue=a;return}e=a.lastBaseUpdate,e===null?a.firstBaseUpdate=t:e.next=t,a.lastBaseUpdate=t}function eu(e,t,a,r){var o=e.updateQueue;ur=!1;var n=o.firstBaseUpdate,s=o.lastBaseUpdate,i=o.shared.pending;if(i!==null){o.shared.pending=null;var l=i,u=l.next;l.next=null,s===null?n=u:s.next=u,s=l;var d=e.alternate;d!==null&&(d=d.updateQueue,i=d.lastBaseUpdate,i!==s&&(i===null?d.firstBaseUpdate=u:i.next=u,d.lastBaseUpdate=l))}if(n!==null){var c=o.baseState;s=0,d=u=l=null,i=n;do{var p=i.lane,g=i.eventTime;if((r&p)===p){d!==null&&(d=d.next={eventTime:g,lane:0,tag:i.tag,payload:i.payload,callback:i.callback,next:null});e:{var C=e,L=i;switch(p=t,g=a,L.tag){case 1:if(C=L.payload,typeof C=="function"){c=C.call(g,c,p);break e}c=C;break e;case 3:C.flags=C.flags&-65537|128;case 0:if(C=L.payload,p=typeof C=="function"?C.call(g,c,p):C,p==null)break e;c=Pe({},c,p);break e;case 2:ur=!0}}i.callback!==null&&i.lane!==0&&(e.flags|=64,p=o.effects,p===null?o.effects=[i]:p.push(i))}else g={eventTime:g,lane:p,tag:i.tag,payload:i.payload,callback:i.callback,next:null},d===null?(u=d=g,l=c):d=d.next=g,s|=p;if(i=i.next,i===null){if(i=o.shared.pending,i===null)break;p=i,i=p.next,p.next=null,o.lastBaseUpdate=p,o.shared.pending=null}}while(!0);if(d===null&&(l=c),o.baseState=l,o.firstBaseUpdate=u,o.lastBaseUpdate=d,t=o.shared.interleaved,t!==null){o=t;do s|=o.lane,o=o.next;while(o!==t)}else n===null&&(o.shared.lanes=0);co|=s,e.lanes=s,e.memoizedState=c}}function Lg(e,t,a){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],o=r.callback;if(o!==null){if(r.callback=null,r=a,typeof o!="function")throw Error(D(191,o));o.call(r)}}}var ci={},va=kr(ci),ai=kr(ci),ri=kr(ci);function oo(e){if(e===ci)throw Error(D(174));return e}function gp(e,t){switch(xe(ri,t),xe(ai,e),xe(va,ci),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:uf(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=uf(t,e)}Le(va),xe(va,t)}function un(){Le(va),Le(ai),Le(ri)}function jx(e){oo(ri.current);var t=oo(va.current),a=uf(t,e.type);t!==a&&(xe(ai,e),xe(va,a))}function xp(e){ai.current===e&&(Le(va),Le(ai))}var ke=kr(0);function tu(e){for(var t=e;t!==null;){if(t.tag===13){var a=t.memoizedState;if(a!==null&&(a=a.dehydrated,a===null||a.data==="$?"||a.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){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 Gc=[];function yp(){for(var e=0;e<Gc.length;e++)Gc[e]._workInProgressVersionPrimary=null;Gc.length=0}var Nl=qa.ReactCurrentDispatcher,jc=qa.ReactCurrentBatchConfig,uo=0,be=null,_e=null,je=null,au=!1,zs=!1,oi=0,Iw=0;function ot(){throw Error(D(321))}function vp(e,t){if(t===null)return!1;for(var a=0;a<t.length&&a<e.length;a++)if(!ua(e[a],t[a]))return!1;return!0}function Lp(e,t,a,r,o,n){if(uo=n,be=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Nl.current=e===null||e.memoizedState===null?Pw:Tw,e=a(r,o),zs){n=0;do{if(zs=!1,oi=0,25<=n)throw Error(D(301));n+=1,je=_e=null,t.updateQueue=null,Nl.current=Aw,e=a(r,o)}while(zs)}if(Nl.current=ru,t=_e!==null&&_e.next!==null,uo=0,je=_e=be=null,au=!1,t)throw Error(D(300));return e}function Cp(){var e=oi!==0;return oi=0,e}function ga(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return je===null?be.memoizedState=je=e:je=je.next=e,je}function Zt(){if(_e===null){var e=be.alternate;e=e!==null?e.memoizedState:null}else e=_e.next;var t=je===null?be.memoizedState:je.next;if(t!==null)je=t,_e=e;else{if(e===null)throw Error(D(310));_e=e,e={memoizedState:_e.memoizedState,baseState:_e.baseState,baseQueue:_e.baseQueue,queue:_e.queue,next:null},je===null?be.memoizedState=je=e:je=je.next=e}return je}function ni(e,t){return typeof t=="function"?t(e):t}function Kc(e){var t=Zt(),a=t.queue;if(a===null)throw Error(D(311));a.lastRenderedReducer=e;var r=_e,o=r.baseQueue,n=a.pending;if(n!==null){if(o!==null){var s=o.next;o.next=n.next,n.next=s}r.baseQueue=o=n,a.pending=null}if(o!==null){n=o.next,r=r.baseState;var i=s=null,l=null,u=n;do{var d=u.lane;if((uo&d)===d)l!==null&&(l=l.next={lane:0,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),r=u.hasEagerState?u.eagerState:e(r,u.action);else{var c={lane:d,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};l===null?(i=l=c,s=r):l=l.next=c,be.lanes|=d,co|=d}u=u.next}while(u!==null&&u!==n);l===null?s=r:l.next=i,ua(r,t.memoizedState)||(vt=!0),t.memoizedState=r,t.baseState=s,t.baseQueue=l,a.lastRenderedState=r}if(e=a.interleaved,e!==null){o=e;do n=o.lane,be.lanes|=n,co|=n,o=o.next;while(o!==e)}else o===null&&(a.lanes=0);return[t.memoizedState,a.dispatch]}function $c(e){var t=Zt(),a=t.queue;if(a===null)throw Error(D(311));a.lastRenderedReducer=e;var r=a.dispatch,o=a.pending,n=t.memoizedState;if(o!==null){a.pending=null;var s=o=o.next;do n=e(n,s.action),s=s.next;while(s!==o);ua(n,t.memoizedState)||(vt=!0),t.memoizedState=n,t.baseQueue===null&&(t.baseState=n),a.lastRenderedState=n}return[n,r]}function Kx(){}function $x(e,t){var a=be,r=Zt(),o=t(),n=!ua(r.memoizedState,o);if(n&&(r.memoizedState=o,vt=!0),r=r.queue,Sp(Yx.bind(null,a,r,e),[e]),r.getSnapshot!==t||n||je!==null&&je.memoizedState.tag&1){if(a.flags|=2048,si(9,Qx.bind(null,a,r,o,t),void 0,null),Ke===null)throw Error(D(349));(uo&30)!==0||Xx(a,t,o)}return o}function Xx(e,t,a){e.flags|=16384,e={getSnapshot:t,value:a},t=be.updateQueue,t===null?(t={lastEffect:null,stores:null},be.updateQueue=t,t.stores=[e]):(a=t.stores,a===null?t.stores=[e]:a.push(e))}function Qx(e,t,a,r){t.value=a,t.getSnapshot=r,Zx(t)&&Jx(e)}function Yx(e,t,a){return a(function(){Zx(t)&&Jx(e)})}function Zx(e){var t=e.getSnapshot;e=e.value;try{var a=t();return!ua(e,a)}catch{return!0}}function Jx(e){var t=za(e,1);t!==null&&la(t,e,1,-1)}function Cg(e){var t=ga();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:ni,lastRenderedState:e},t.queue=e,e=e.dispatch=bw.bind(null,be,e),[t.memoizedState,e]}function si(e,t,a,r){return e={tag:e,create:t,destroy:a,deps:r,next:null},t=be.updateQueue,t===null?(t={lastEffect:null,stores:null},be.updateQueue=t,t.lastEffect=e.next=e):(a=t.lastEffect,a===null?t.lastEffect=e.next=e:(r=a.next,a.next=e,e.next=r,t.lastEffect=e)),e}function ey(){return Zt().memoizedState}function El(e,t,a,r){var o=ga();be.flags|=e,o.memoizedState=si(1|t,a,void 0,r===void 0?null:r)}function hu(e,t,a,r){var o=Zt();r=r===void 0?null:r;var n=void 0;if(_e!==null){var s=_e.memoizedState;if(n=s.destroy,r!==null&&vp(r,s.deps)){o.memoizedState=si(t,a,n,r);return}}be.flags|=e,o.memoizedState=si(1|t,a,n,r)}function Sg(e,t){return El(8390656,8,e,t)}function Sp(e,t){return hu(2048,8,e,t)}function ty(e,t){return hu(4,2,e,t)}function ay(e,t){return hu(4,4,e,t)}function ry(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function oy(e,t,a){return a=a!=null?a.concat([e]):null,hu(4,4,ry.bind(null,t,e),a)}function Ip(){}function ny(e,t){var a=Zt();t=t===void 0?null:t;var r=a.memoizedState;return r!==null&&t!==null&&vp(t,r[1])?r[0]:(a.memoizedState=[e,t],e)}function sy(e,t){var a=Zt();t=t===void 0?null:t;var r=a.memoizedState;return r!==null&&t!==null&&vp(t,r[1])?r[0]:(e=e(),a.memoizedState=[e,t],e)}function iy(e,t,a){return(uo&21)===0?(e.baseState&&(e.baseState=!1,vt=!0),e.memoizedState=a):(ua(a,t)||(a=fx(),be.lanes|=a,co|=a,e.baseState=!0),t)}function ww(e,t){var a=pe;pe=a!==0&&4>a?a:4,e(!0);var r=jc.transition;jc.transition={};try{e(!1),t()}finally{pe=a,jc.transition=r}}function ly(){return Zt().memoizedState}function kw(e,t,a){var r=Lr(e);if(a={lane:r,action:a,hasEagerState:!1,eagerState:null,next:null},uy(e))dy(t,a);else if(a=Wx(e,t,a,r),a!==null){var o=pt();la(a,e,r,o),cy(a,t,r)}}function bw(e,t,a){var r=Lr(e),o={lane:r,action:a,hasEagerState:!1,eagerState:null,next:null};if(uy(e))dy(t,o);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(o.hasEagerState=!0,o.eagerState=i,ua(i,s)){var l=t.interleaved;l===null?(o.next=o,mp(t)):(o.next=l.next,l.next=o),t.interleaved=o;return}}catch{}a=Wx(e,t,o,r),a!==null&&(o=pt(),la(a,e,r,o),cy(a,t,r))}}function uy(e){var t=e.alternate;return e===be||t!==null&&t===be}function dy(e,t){zs=au=!0;var a=e.pending;a===null?t.next=t:(t.next=a.next,a.next=t),e.pending=t}function cy(e,t,a){if((a&4194240)!==0){var r=t.lanes;r&=e.pendingLanes,a|=r,t.lanes=a,ep(e,a)}}var ru={readContext:Yt,useCallback:ot,useContext:ot,useEffect:ot,useImperativeHandle:ot,useInsertionEffect:ot,useLayoutEffect:ot,useMemo:ot,useReducer:ot,useRef:ot,useState:ot,useDebugValue:ot,useDeferredValue:ot,useTransition:ot,useMutableSource:ot,useSyncExternalStore:ot,useId:ot,unstable_isNewReconciler:!1},Pw={readContext:Yt,useCallback:function(e,t){return ga().memoizedState=[e,t===void 0?null:t],e},useContext:Yt,useEffect:Sg,useImperativeHandle:function(e,t,a){return a=a!=null?a.concat([e]):null,El(4194308,4,ry.bind(null,t,e),a)},useLayoutEffect:function(e,t){return El(4194308,4,e,t)},useInsertionEffect:function(e,t){return El(4,2,e,t)},useMemo:function(e,t){var a=ga();return t=t===void 0?null:t,e=e(),a.memoizedState=[e,t],e},useReducer:function(e,t,a){var r=ga();return t=a!==void 0?a(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=kw.bind(null,be,e),[r.memoizedState,e]},useRef:function(e){var t=ga();return e={current:e},t.memoizedState=e},useState:Cg,useDebugValue:Ip,useDeferredValue:function(e){return ga().memoizedState=e},useTransition:function(){var e=Cg(!1),t=e[0];return e=ww.bind(null,e[1]),ga().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,a){var r=be,o=ga();if(we){if(a===void 0)throw Error(D(407));a=a()}else{if(a=t(),Ke===null)throw Error(D(349));(uo&30)!==0||Xx(r,t,a)}o.memoizedState=a;var n={value:a,getSnapshot:t};return o.queue=n,Sg(Yx.bind(null,r,n,e),[e]),r.flags|=2048,si(9,Qx.bind(null,r,n,a,t),void 0,null),a},useId:function(){var e=ga(),t=Ke.identifierPrefix;if(we){var a=Oa,r=Ba;a=(r&~(1<<32-ia(r)-1)).toString(32)+a,t=":"+t+"R"+a,a=oi++,0<a&&(t+="H"+a.toString(32)),t+=":"}else a=Iw++,t=":"+t+"r"+a.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},Tw={readContext:Yt,useCallback:ny,useContext:Yt,useEffect:Sp,useImperativeHandle:oy,useInsertionEffect:ty,useLayoutEffect:ay,useMemo:sy,useReducer:Kc,useRef:ey,useState:function(){return Kc(ni)},useDebugValue:Ip,useDeferredValue:function(e){var t=Zt();return iy(t,_e.memoizedState,e)},useTransition:function(){var e=Kc(ni)[0],t=Zt().memoizedState;return[e,t]},useMutableSource:Kx,useSyncExternalStore:$x,useId:ly,unstable_isNewReconciler:!1},Aw={readContext:Yt,useCallback:ny,useContext:Yt,useEffect:Sp,useImperativeHandle:oy,useInsertionEffect:ty,useLayoutEffect:ay,useMemo:sy,useReducer:$c,useRef:ey,useState:function(){return $c(ni)},useDebugValue:Ip,useDeferredValue:function(e){var t=Zt();return _e===null?t.memoizedState=e:iy(t,_e.memoizedState,e)},useTransition:function(){var e=$c(ni)[0],t=Zt().memoizedState;return[e,t]},useMutableSource:Kx,useSyncExternalStore:$x,useId:ly,unstable_isNewReconciler:!1};function oa(e,t){if(e&&e.defaultProps){t=Pe({},t),e=e.defaultProps;for(var a in e)t[a]===void 0&&(t[a]=e[a]);return t}return t}function Rf(e,t,a,r){t=e.memoizedState,a=a(r,t),a=a==null?t:Pe({},t,a),e.memoizedState=a,e.lanes===0&&(e.updateQueue.baseState=a)}var gu={isMounted:function(e){return(e=e._reactInternals)?mo(e)===e:!1},enqueueSetState:function(e,t,a){e=e._reactInternals;var r=pt(),o=Lr(e),n=Va(r,o);n.payload=t,a!=null&&(n.callback=a),t=yr(e,n,o),t!==null&&(la(t,e,o,r),Ml(t,e,o))},enqueueReplaceState:function(e,t,a){e=e._reactInternals;var r=pt(),o=Lr(e),n=Va(r,o);n.tag=1,n.payload=t,a!=null&&(n.callback=a),t=yr(e,n,o),t!==null&&(la(t,e,o,r),Ml(t,e,o))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var a=pt(),r=Lr(e),o=Va(a,r);o.tag=2,t!=null&&(o.callback=t),t=yr(e,o,r),t!==null&&(la(t,e,r,a),Ml(t,e,r))}};function Ig(e,t,a,r,o,n,s){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,n,s):t.prototype&&t.prototype.isPureReactComponent?!Zs(a,r)||!Zs(o,n):!0}function fy(e,t,a){var r=!1,o=Ir,n=t.contextType;return typeof n=="object"&&n!==null?n=Yt(n):(o=Ct(t)?io:it.current,r=t.contextTypes,n=(r=r!=null)?nn(e,o):Ir),t=new t(a,n),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=gu,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=o,e.__reactInternalMemoizedMaskedChildContext=n),t}function wg(e,t,a,r){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(a,r),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(a,r),t.state!==e&&gu.enqueueReplaceState(t,t.state,null)}function Df(e,t,a,r){var o=e.stateNode;o.props=a,o.state=e.memoizedState,o.refs={},hp(e);var n=t.contextType;typeof n=="object"&&n!==null?o.context=Yt(n):(n=Ct(t)?io:it.current,o.context=nn(e,n)),o.state=e.memoizedState,n=t.getDerivedStateFromProps,typeof n=="function"&&(Rf(e,t,n,a),o.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof o.getSnapshotBeforeUpdate=="function"||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(t=o.state,typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount(),t!==o.state&&gu.enqueueReplaceState(o,o.state,null),eu(e,a,o,r),o.state=e.memoizedState),typeof o.componentDidMount=="function"&&(e.flags|=4194308)}function dn(e,t){try{var a="",r=t;do a+=nI(r),r=r.return;while(r);var o=a}catch(n){o=`
|
|
5
|
+
`+o[s].replace(" at new "," at ");return e.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",e.displayName)),l}while(1<=s&&0<=i);break}}}finally{Nc=!1,Error.prepareStackTrace=a}return(e=e?e.displayName||e.name:"")?Ms(e):""}function sI(e){switch(e.tag){case 5:return Ms(e.type);case 16:return Ms("Lazy");case 13:return Ms("Suspense");case 19:return Ms("SuspenseList");case 0:case 2:case 15:return e=Ec(e.type,!1),e;case 11:return e=Ec(e.type.render,!1),e;case 1:return e=Ec(e.type,!0),e;default:return""}}function of(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case zo:return"Fragment";case _o:return"Portal";case tf:return"Profiler";case Qf:return"StrictMode";case af:return"Suspense";case rf:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case jg:return(e.displayName||"Context")+".Consumer";case Gg:return(e._context.displayName||"Context")+".Provider";case Yf:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Zf:return t=e.displayName||null,t!==null?t:of(e.type)||"Memo";case lr:t=e._payload,e=e._init;try{return of(e(t))}catch{}}return null}function iI(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return of(t);case 8:return t===Qf?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Sr(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function $g(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function lI(e){var t=$g(e)?"checked":"value",a=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof a<"u"&&typeof a.get=="function"&&typeof a.set=="function"){var o=a.get,n=a.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(s){r=""+s,n.call(this,s)}}),Object.defineProperty(e,t,{enumerable:a.enumerable}),{getValue:function(){return r},setValue:function(s){r=""+s},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function fl(e){e._valueTracker||(e._valueTracker=lI(e))}function Xg(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var a=t.getValue(),r="";return e&&(r=$g(e)?e.checked?"true":"false":e.value),e=r,e!==a?(t.setValue(e),!0):!1}function _l(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 nf(e,t){var a=t.checked;return Pe({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:a??e._wrapperState.initialChecked})}function zh(e,t){var a=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;a=Sr(t.value!=null?t.value:a),e._wrapperState={initialChecked:r,initialValue:a,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Qg(e,t){t=t.checked,t!=null&&Xf(e,"checked",t,!1)}function sf(e,t){Qg(e,t);var a=Sr(t.value),r=t.type;if(a!=null)r==="number"?(a===0&&e.value===""||e.value!=a)&&(e.value=""+a):e.value!==""+a&&(e.value=""+a);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?lf(e,t.type,a):t.hasOwnProperty("defaultValue")&&lf(e,t.type,Sr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Hh(e,t,a){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,a||t===e.value||(e.value=t),e.defaultValue=t}a=e.name,a!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,a!==""&&(e.name=a)}function lf(e,t,a){(t!=="number"||_l(e.ownerDocument)!==e)&&(a==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+a&&(e.defaultValue=""+a))}var Ns=Array.isArray;function Zo(e,t,a,r){if(e=e.options,t){t={};for(var o=0;o<a.length;o++)t["$"+a[o]]=!0;for(a=0;a<e.length;a++)o=t.hasOwnProperty("$"+e[a].value),e[a].selected!==o&&(e[a].selected=o),o&&r&&(e[a].defaultSelected=!0)}else{for(a=""+Sr(a),t=null,o=0;o<e.length;o++){if(e[o].value===a){e[o].selected=!0,r&&(e[o].defaultSelected=!0);return}t!==null||e[o].disabled||(t=e[o])}t!==null&&(t.selected=!0)}}function uf(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(D(91));return Pe({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function qh(e,t){var a=t.value;if(a==null){if(a=t.children,t=t.defaultValue,a!=null){if(t!=null)throw Error(D(92));if(Ns(a)){if(1<a.length)throw Error(D(93));a=a[0]}t=a}t==null&&(t=""),a=t}e._wrapperState={initialValue:Sr(a)}}function Yg(e,t){var a=Sr(t.value),r=Sr(t.defaultValue);a!=null&&(a=""+a,a!==e.value&&(e.value=a),t.defaultValue==null&&e.defaultValue!==a&&(e.defaultValue=a)),r!=null&&(e.defaultValue=""+r)}function Wh(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function Zg(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function df(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?Zg(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var pl,Jg=(function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,a,r,o){MSApp.execUnsafeLocalFunction(function(){return e(t,a,r,o)})}:e})(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(pl=pl||document.createElement("div"),pl.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=pl.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function js(e,t){if(t){var a=e.firstChild;if(a&&a===e.lastChild&&a.nodeType===3){a.nodeValue=t;return}}e.textContent=t}var Bs={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},uI=["Webkit","ms","Moz","O"];Object.keys(Bs).forEach(function(e){uI.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Bs[t]=Bs[e]})});function ex(e,t,a){return t==null||typeof t=="boolean"||t===""?"":a||typeof t!="number"||t===0||Bs.hasOwnProperty(e)&&Bs[e]?(""+t).trim():t+"px"}function tx(e,t){e=e.style;for(var a in t)if(t.hasOwnProperty(a)){var r=a.indexOf("--")===0,o=ex(a,t[a],r);a==="float"&&(a="cssFloat"),r?e.setProperty(a,o):e[a]=o}}var dI=Pe({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function cf(e,t){if(t){if(dI[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(D(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(D(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(D(61))}if(t.style!=null&&typeof t.style!="object")throw Error(D(62))}}function ff(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";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 pf=null;function Jf(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var mf=null,Jo=null,en=null;function Gh(e){if(e=di(e)){if(typeof mf!="function")throw Error(D(280));var t=e.stateNode;t&&(t=mu(t),mf(e.stateNode,e.type,t))}}function ax(e){Jo?en?en.push(e):en=[e]:Jo=e}function rx(){if(Jo){var e=Jo,t=en;if(en=Jo=null,Gh(e),t)for(e=0;e<t.length;e++)Gh(t[e])}}function ox(e,t){return e(t)}function nx(){}var Fc=!1;function sx(e,t,a){if(Fc)return e(t,a);Fc=!0;try{return ox(e,t,a)}finally{Fc=!1,(Jo!==null||en!==null)&&(nx(),rx())}}function Ks(e,t){var a=e.stateNode;if(a===null)return null;var r=mu(a);if(r===null)return null;a=r[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":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(a&&typeof a!="function")throw Error(D(231,t,typeof a));return a}var hf=!1;if(Ua)try{Vo={},Object.defineProperty(Vo,"passive",{get:function(){hf=!0}}),window.addEventListener("test",Vo,Vo),window.removeEventListener("test",Vo,Vo)}catch{hf=!1}var Vo;function cI(e,t,a,r,o,n,s,i,l){var u=Array.prototype.slice.call(arguments,3);try{t.apply(a,u)}catch(d){this.onError(d)}}var Os=!1,zl=null,Hl=!1,gf=null,fI={onError:function(e){Os=!0,zl=e}};function pI(e,t,a,r,o,n,s,i,l){Os=!1,zl=null,cI.apply(fI,arguments)}function mI(e,t,a,r,o,n,s,i,l){if(pI.apply(this,arguments),Os){if(Os){var u=zl;Os=!1,zl=null}else throw Error(D(198));Hl||(Hl=!0,gf=u)}}function po(e){var t=e,a=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(a=t.return),e=t.return;while(e)}return t.tag===3?a:null}function ix(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 jh(e){if(po(e)!==e)throw Error(D(188))}function hI(e){var t=e.alternate;if(!t){if(t=po(e),t===null)throw Error(D(188));return t!==e?null:e}for(var a=e,r=t;;){var o=a.return;if(o===null)break;var n=o.alternate;if(n===null){if(r=o.return,r!==null){a=r;continue}break}if(o.child===n.child){for(n=o.child;n;){if(n===a)return jh(o),e;if(n===r)return jh(o),t;n=n.sibling}throw Error(D(188))}if(a.return!==r.return)a=o,r=n;else{for(var s=!1,i=o.child;i;){if(i===a){s=!0,a=o,r=n;break}if(i===r){s=!0,r=o,a=n;break}i=i.sibling}if(!s){for(i=n.child;i;){if(i===a){s=!0,a=n,r=o;break}if(i===r){s=!0,r=n,a=o;break}i=i.sibling}if(!s)throw Error(D(189))}}if(a.alternate!==r)throw Error(D(190))}if(a.tag!==3)throw Error(D(188));return a.stateNode.current===a?e:t}function lx(e){return e=hI(e),e!==null?ux(e):null}function ux(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=ux(e);if(t!==null)return t;e=e.sibling}return null}var dx=Et.unstable_scheduleCallback,Kh=Et.unstable_cancelCallback,gI=Et.unstable_shouldYield,xI=Et.unstable_requestPaint,Ne=Et.unstable_now,yI=Et.unstable_getCurrentPriorityLevel,ep=Et.unstable_ImmediatePriority,cx=Et.unstable_UserBlockingPriority,ql=Et.unstable_NormalPriority,vI=Et.unstable_LowPriority,fx=Et.unstable_IdlePriority,du=null,ya=null;function LI(e){if(ya&&typeof ya.onCommitFiberRoot=="function")try{ya.onCommitFiberRoot(du,e,void 0,(e.current.flags&128)===128)}catch{}}var ia=Math.clz32?Math.clz32:II,CI=Math.log,SI=Math.LN2;function II(e){return e>>>=0,e===0?32:31-(CI(e)/SI|0)|0}var ml=64,hl=4194304;function Es(e){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: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 e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Wl(e,t){var a=e.pendingLanes;if(a===0)return 0;var r=0,o=e.suspendedLanes,n=e.pingedLanes,s=a&268435455;if(s!==0){var i=s&~o;i!==0?r=Es(i):(n&=s,n!==0&&(r=Es(n)))}else s=a&~o,s!==0?r=Es(s):n!==0&&(r=Es(n));if(r===0)return 0;if(t!==0&&t!==r&&(t&o)===0&&(o=r&-r,n=t&-t,o>=n||o===16&&(n&4194240)!==0))return t;if((r&4)!==0&&(r|=a&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0<t;)a=31-ia(t),o=1<<a,r|=e[a],t&=~o;return r}function wI(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64: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:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function kI(e,t){for(var a=e.suspendedLanes,r=e.pingedLanes,o=e.expirationTimes,n=e.pendingLanes;0<n;){var s=31-ia(n),i=1<<s,l=o[s];l===-1?((i&a)===0||(i&r)!==0)&&(o[s]=wI(i,t)):l<=t&&(e.expiredLanes|=i),n&=~i}}function xf(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function px(){var e=ml;return ml<<=1,(ml&4194240)===0&&(ml=64),e}function Bc(e){for(var t=[],a=0;31>a;a++)t.push(e);return t}function li(e,t,a){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-ia(t),e[t]=a}function bI(e,t){var a=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0<a;){var o=31-ia(a),n=1<<o;t[o]=0,r[o]=-1,e[o]=-1,a&=~n}}function tp(e,t){var a=e.entangledLanes|=t;for(e=e.entanglements;a;){var r=31-ia(a),o=1<<r;o&t|e[r]&t&&(e[r]|=t),a&=~o}}var pe=0;function mx(e){return e&=-e,1<e?4<e?(e&268435455)!==0?16:536870912:4:1}var hx,ap,gx,xx,yx,yf=!1,gl=[],mr=null,hr=null,gr=null,$s=new Map,Xs=new Map,dr=[],PI="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 submit".split(" ");function $h(e,t){switch(e){case"focusin":case"focusout":mr=null;break;case"dragenter":case"dragleave":hr=null;break;case"mouseover":case"mouseout":gr=null;break;case"pointerover":case"pointerout":$s.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Xs.delete(t.pointerId)}}function ks(e,t,a,r,o,n){return e===null||e.nativeEvent!==n?(e={blockedOn:t,domEventName:a,eventSystemFlags:r,nativeEvent:n,targetContainers:[o]},t!==null&&(t=di(t),t!==null&&ap(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,o!==null&&t.indexOf(o)===-1&&t.push(o),e)}function TI(e,t,a,r,o){switch(t){case"focusin":return mr=ks(mr,e,t,a,r,o),!0;case"dragenter":return hr=ks(hr,e,t,a,r,o),!0;case"mouseover":return gr=ks(gr,e,t,a,r,o),!0;case"pointerover":var n=o.pointerId;return $s.set(n,ks($s.get(n)||null,e,t,a,r,o)),!0;case"gotpointercapture":return n=o.pointerId,Xs.set(n,ks(Xs.get(n)||null,e,t,a,r,o)),!0}return!1}function vx(e){var t=to(e.target);if(t!==null){var a=po(t);if(a!==null){if(t=a.tag,t===13){if(t=ix(a),t!==null){e.blockedOn=t,yx(e.priority,function(){gx(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 Rl(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var a=vf(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(a===null){a=e.nativeEvent;var r=new a.constructor(a.type,a);pf=r,a.target.dispatchEvent(r),pf=null}else return t=di(a),t!==null&&ap(t),e.blockedOn=a,!1;t.shift()}return!0}function Xh(e,t,a){Rl(e)&&a.delete(t)}function AI(){yf=!1,mr!==null&&Rl(mr)&&(mr=null),hr!==null&&Rl(hr)&&(hr=null),gr!==null&&Rl(gr)&&(gr=null),$s.forEach(Xh),Xs.forEach(Xh)}function bs(e,t){e.blockedOn===t&&(e.blockedOn=null,yf||(yf=!0,Et.unstable_scheduleCallback(Et.unstable_NormalPriority,AI)))}function Qs(e){function t(o){return bs(o,e)}if(0<gl.length){bs(gl[0],e);for(var a=1;a<gl.length;a++){var r=gl[a];r.blockedOn===e&&(r.blockedOn=null)}}for(mr!==null&&bs(mr,e),hr!==null&&bs(hr,e),gr!==null&&bs(gr,e),$s.forEach(t),Xs.forEach(t),a=0;a<dr.length;a++)r=dr[a],r.blockedOn===e&&(r.blockedOn=null);for(;0<dr.length&&(a=dr[0],a.blockedOn===null);)vx(a),a.blockedOn===null&&dr.shift()}var tn=qa.ReactCurrentBatchConfig,Gl=!0;function RI(e,t,a,r){var o=pe,n=tn.transition;tn.transition=null;try{pe=1,rp(e,t,a,r)}finally{pe=o,tn.transition=n}}function DI(e,t,a,r){var o=pe,n=tn.transition;tn.transition=null;try{pe=4,rp(e,t,a,r)}finally{pe=o,tn.transition=n}}function rp(e,t,a,r){if(Gl){var o=vf(e,t,a,r);if(o===null)qc(e,t,r,jl,a),$h(e,r);else if(TI(o,e,t,a,r))r.stopPropagation();else if($h(e,r),t&4&&-1<PI.indexOf(e)){for(;o!==null;){var n=di(o);if(n!==null&&hx(n),n=vf(e,t,a,r),n===null&&qc(e,t,r,jl,a),n===o)break;o=n}o!==null&&r.stopPropagation()}else qc(e,t,r,null,a)}}var jl=null;function vf(e,t,a,r){if(jl=null,e=Jf(r),e=to(e),e!==null)if(t=po(e),t===null)e=null;else if(a=t.tag,a===13){if(e=ix(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 jl=e,null}function Lx(e){switch(e){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"resize":case"seeked":case"submit":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"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(yI()){case ep:return 1;case cx:return 4;case ql:case vI:return 16;case fx:return 536870912;default:return 16}default:return 16}}var fr=null,op=null,Dl=null;function Cx(){if(Dl)return Dl;var e,t=op,a=t.length,r,o="value"in fr?fr.value:fr.textContent,n=o.length;for(e=0;e<a&&t[e]===o[e];e++);var s=a-e;for(r=1;r<=s&&t[a-r]===o[n-r];r++);return Dl=o.slice(e,1<r?1-r:void 0)}function Ml(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 xl(){return!0}function Qh(){return!1}function Ft(e){function t(a,r,o,n,s){this._reactName=a,this._targetInst=o,this.type=r,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)?xl:Qh,this.isPropagationStopped=Qh,this}return Pe(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=xl)},stopPropagation:function(){var a=this.nativeEvent;a&&(a.stopPropagation?a.stopPropagation():typeof a.cancelBubble!="unknown"&&(a.cancelBubble=!0),this.isPropagationStopped=xl)},persist:function(){},isPersistent:xl}),t}var fn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},np=Ft(fn),ui=Pe({},fn,{view:0,detail:0}),MI=Ft(ui),Oc,Vc,Ps,cu=Pe({},ui,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:sp,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!==Ps&&(Ps&&e.type==="mousemove"?(Oc=e.screenX-Ps.screenX,Vc=e.screenY-Ps.screenY):Vc=Oc=0,Ps=e),Oc)},movementY:function(e){return"movementY"in e?e.movementY:Vc}}),Yh=Ft(cu),NI=Pe({},cu,{dataTransfer:0}),EI=Ft(NI),FI=Pe({},ui,{relatedTarget:0}),Uc=Ft(FI),BI=Pe({},fn,{animationName:0,elapsedTime:0,pseudoElement:0}),OI=Ft(BI),VI=Pe({},fn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),UI=Ft(VI),_I=Pe({},fn,{data:0}),Zh=Ft(_I),zI={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},HI={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"},qI={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function WI(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=qI[e])?!!t[e]:!1}function sp(){return WI}var GI=Pe({},ui,{key:function(e){if(e.key){var t=zI[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Ml(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?HI[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:sp,charCode:function(e){return e.type==="keypress"?Ml(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Ml(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),jI=Ft(GI),KI=Pe({},cu,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Jh=Ft(KI),$I=Pe({},ui,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:sp}),XI=Ft($I),QI=Pe({},fn,{propertyName:0,elapsedTime:0,pseudoElement:0}),YI=Ft(QI),ZI=Pe({},cu,{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}),JI=Ft(ZI),ew=[9,13,27,32],ip=Ua&&"CompositionEvent"in window,Vs=null;Ua&&"documentMode"in document&&(Vs=document.documentMode);var tw=Ua&&"TextEvent"in window&&!Vs,Sx=Ua&&(!ip||Vs&&8<Vs&&11>=Vs),eg=" ",tg=!1;function Ix(e,t){switch(e){case"keyup":return ew.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function wx(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Ho=!1;function aw(e,t){switch(e){case"compositionend":return wx(t);case"keypress":return t.which!==32?null:(tg=!0,eg);case"textInput":return e=t.data,e===eg&&tg?null:e;default:return null}}function rw(e,t){if(Ho)return e==="compositionend"||!ip&&Ix(e,t)?(e=Cx(),Dl=op=fr=null,Ho=!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 Sx&&t.locale!=="ko"?null:t.data;default:return null}}var ow={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 ag(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!ow[e.type]:t==="textarea"}function kx(e,t,a,r){ax(r),t=Kl(t,"onChange"),0<t.length&&(a=new np("onChange","change",null,a,r),e.push({event:a,listeners:t}))}var Us=null,Ys=null;function nw(e){Bx(e,0)}function fu(e){var t=Go(e);if(Xg(t))return e}function sw(e,t){if(e==="change")return t}var bx=!1;Ua&&(Ua?(vl="oninput"in document,vl||(_c=document.createElement("div"),_c.setAttribute("oninput","return;"),vl=typeof _c.oninput=="function"),yl=vl):yl=!1,bx=yl&&(!document.documentMode||9<document.documentMode));var yl,vl,_c;function rg(){Us&&(Us.detachEvent("onpropertychange",Px),Ys=Us=null)}function Px(e){if(e.propertyName==="value"&&fu(Ys)){var t=[];kx(t,Ys,e,Jf(e)),sx(nw,t)}}function iw(e,t,a){e==="focusin"?(rg(),Us=t,Ys=a,Us.attachEvent("onpropertychange",Px)):e==="focusout"&&rg()}function lw(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return fu(Ys)}function uw(e,t){if(e==="click")return fu(t)}function dw(e,t){if(e==="input"||e==="change")return fu(t)}function cw(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var ua=typeof Object.is=="function"?Object.is:cw;function Zs(e,t){if(ua(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var a=Object.keys(e),r=Object.keys(t);if(a.length!==r.length)return!1;for(r=0;r<a.length;r++){var o=a[r];if(!ef.call(t,o)||!ua(e[o],t[o]))return!1}return!0}function og(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function ng(e,t){var a=og(e);e=0;for(var r;a;){if(a.nodeType===3){if(r=e+a.textContent.length,e<=t&&r>=t)return{node:a,offset:t-e};e=r}e:{for(;a;){if(a.nextSibling){a=a.nextSibling;break e}a=a.parentNode}a=void 0}a=og(a)}}function Tx(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Tx(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Ax(){for(var e=window,t=_l();t instanceof e.HTMLIFrameElement;){try{var a=typeof t.contentWindow.location.href=="string"}catch{a=!1}if(a)e=t.contentWindow;else break;t=_l(e.document)}return t}function lp(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")}function fw(e){var t=Ax(),a=e.focusedElem,r=e.selectionRange;if(t!==a&&a&&a.ownerDocument&&Tx(a.ownerDocument.documentElement,a)){if(r!==null&&lp(a)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in a)a.selectionStart=t,a.selectionEnd=Math.min(e,a.value.length);else if(e=(t=a.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var o=a.textContent.length,n=Math.min(r.start,o);r=r.end===void 0?n:Math.min(r.end,o),!e.extend&&n>r&&(o=r,r=n,n=o),o=ng(a,n);var s=ng(a,r);o&&s&&(e.rangeCount!==1||e.anchorNode!==o.node||e.anchorOffset!==o.offset||e.focusNode!==s.node||e.focusOffset!==s.offset)&&(t=t.createRange(),t.setStart(o.node,o.offset),e.removeAllRanges(),n>r?(e.addRange(t),e.extend(s.node,s.offset)):(t.setEnd(s.node,s.offset),e.addRange(t)))}}for(t=[],e=a;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof a.focus=="function"&&a.focus(),a=0;a<t.length;a++)e=t[a],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var pw=Ua&&"documentMode"in document&&11>=document.documentMode,qo=null,Lf=null,_s=null,Cf=!1;function sg(e,t,a){var r=a.window===a?a.document:a.nodeType===9?a:a.ownerDocument;Cf||qo==null||qo!==_l(r)||(r=qo,"selectionStart"in r&&lp(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),_s&&Zs(_s,r)||(_s=r,r=Kl(Lf,"onSelect"),0<r.length&&(t=new np("onSelect","select",null,t,a),e.push({event:t,listeners:r}),t.target=qo)))}function Ll(e,t){var a={};return a[e.toLowerCase()]=t.toLowerCase(),a["Webkit"+e]="webkit"+t,a["Moz"+e]="moz"+t,a}var Wo={animationend:Ll("Animation","AnimationEnd"),animationiteration:Ll("Animation","AnimationIteration"),animationstart:Ll("Animation","AnimationStart"),transitionend:Ll("Transition","TransitionEnd")},zc={},Rx={};Ua&&(Rx=document.createElement("div").style,"AnimationEvent"in window||(delete Wo.animationend.animation,delete Wo.animationiteration.animation,delete Wo.animationstart.animation),"TransitionEvent"in window||delete Wo.transitionend.transition);function pu(e){if(zc[e])return zc[e];if(!Wo[e])return e;var t=Wo[e],a;for(a in t)if(t.hasOwnProperty(a)&&a in Rx)return zc[e]=t[a];return e}var Dx=pu("animationend"),Mx=pu("animationiteration"),Nx=pu("animationstart"),Ex=pu("transitionend"),Fx=new Map,ig="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error 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(" ");function wr(e,t){Fx.set(e,t),fo(t,[e])}for(Cl=0;Cl<ig.length;Cl++)Sl=ig[Cl],lg=Sl.toLowerCase(),ug=Sl[0].toUpperCase()+Sl.slice(1),wr(lg,"on"+ug);var Sl,lg,ug,Cl;wr(Dx,"onAnimationEnd");wr(Mx,"onAnimationIteration");wr(Nx,"onAnimationStart");wr("dblclick","onDoubleClick");wr("focusin","onFocus");wr("focusout","onBlur");wr(Ex,"onTransitionEnd");on("onMouseEnter",["mouseout","mouseover"]);on("onMouseLeave",["mouseout","mouseover"]);on("onPointerEnter",["pointerout","pointerover"]);on("onPointerLeave",["pointerout","pointerover"]);fo("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));fo("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));fo("onBeforeInput",["compositionend","keypress","textInput","paste"]);fo("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));fo("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));fo("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Fs="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(" "),mw=new Set("cancel close invalid load scroll toggle".split(" ").concat(Fs));function dg(e,t,a){var r=e.type||"unknown-event";e.currentTarget=a,mI(r,t,void 0,e),e.currentTarget=null}function Bx(e,t){t=(t&4)!==0;for(var a=0;a<e.length;a++){var r=e[a],o=r.event;r=r.listeners;e:{var n=void 0;if(t)for(var s=r.length-1;0<=s;s--){var i=r[s],l=i.instance,u=i.currentTarget;if(i=i.listener,l!==n&&o.isPropagationStopped())break e;dg(o,i,u),n=l}else for(s=0;s<r.length;s++){if(i=r[s],l=i.instance,u=i.currentTarget,i=i.listener,l!==n&&o.isPropagationStopped())break e;dg(o,i,u),n=l}}}if(Hl)throw e=gf,Hl=!1,gf=null,e}function ve(e,t){var a=t[bf];a===void 0&&(a=t[bf]=new Set);var r=e+"__bubble";a.has(r)||(Ox(t,e,2,!1),a.add(r))}function Hc(e,t,a){var r=0;t&&(r|=4),Ox(a,e,r,t)}var Il="_reactListening"+Math.random().toString(36).slice(2);function Js(e){if(!e[Il]){e[Il]=!0,Wg.forEach(function(a){a!=="selectionchange"&&(mw.has(a)||Hc(a,!1,e),Hc(a,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Il]||(t[Il]=!0,Hc("selectionchange",!1,t))}}function Ox(e,t,a,r){switch(Lx(t)){case 1:var o=RI;break;case 4:o=DI;break;default:o=rp}a=o.bind(null,t,a,e),o=void 0,!hf||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(o=!0),r?o!==void 0?e.addEventListener(t,a,{capture:!0,passive:o}):e.addEventListener(t,a,!0):o!==void 0?e.addEventListener(t,a,{passive:o}):e.addEventListener(t,a,!1)}function qc(e,t,a,r,o){var n=r;if((t&1)===0&&(t&2)===0&&r!==null)e:for(;;){if(r===null)return;var s=r.tag;if(s===3||s===4){var i=r.stateNode.containerInfo;if(i===o||i.nodeType===8&&i.parentNode===o)break;if(s===4)for(s=r.return;s!==null;){var l=s.tag;if((l===3||l===4)&&(l=s.stateNode.containerInfo,l===o||l.nodeType===8&&l.parentNode===o))return;s=s.return}for(;i!==null;){if(s=to(i),s===null)return;if(l=s.tag,l===5||l===6){r=n=s;continue e}i=i.parentNode}}r=r.return}sx(function(){var u=n,d=Jf(a),c=[];e:{var p=Fx.get(e);if(p!==void 0){var g=np,C=e;switch(e){case"keypress":if(Ml(a)===0)break e;case"keydown":case"keyup":g=jI;break;case"focusin":C="focus",g=Uc;break;case"focusout":C="blur",g=Uc;break;case"beforeblur":case"afterblur":g=Uc;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":g=Yh;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":g=EI;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":g=XI;break;case Dx:case Mx:case Nx:g=OI;break;case Ex:g=YI;break;case"scroll":g=MI;break;case"wheel":g=JI;break;case"copy":case"cut":case"paste":g=UI;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":g=Jh}var L=(t&4)!==0,S=!L&&e==="scroll",h=L?p!==null?p+"Capture":null:p;L=[];for(var m=u,x;m!==null;){x=m;var I=x.stateNode;if(x.tag===5&&I!==null&&(x=I,h!==null&&(I=Ks(m,h),I!=null&&L.push(ei(m,I,x)))),S)break;m=m.return}0<L.length&&(p=new g(p,C,null,a,d),c.push({event:p,listeners:L}))}}if((t&7)===0){e:{if(p=e==="mouseover"||e==="pointerover",g=e==="mouseout"||e==="pointerout",p&&a!==pf&&(C=a.relatedTarget||a.fromElement)&&(to(C)||C[_a]))break e;if((g||p)&&(p=d.window===d?d:(p=d.ownerDocument)?p.defaultView||p.parentWindow:window,g?(C=a.relatedTarget||a.toElement,g=u,C=C?to(C):null,C!==null&&(S=po(C),C!==S||C.tag!==5&&C.tag!==6)&&(C=null)):(g=null,C=u),g!==C)){if(L=Yh,I="onMouseLeave",h="onMouseEnter",m="mouse",(e==="pointerout"||e==="pointerover")&&(L=Jh,I="onPointerLeave",h="onPointerEnter",m="pointer"),S=g==null?p:Go(g),x=C==null?p:Go(C),p=new L(I,m+"leave",g,a,d),p.target=S,p.relatedTarget=x,I=null,to(d)===u&&(L=new L(h,m+"enter",C,a,d),L.target=x,L.relatedTarget=S,I=L),S=I,g&&C)t:{for(L=g,h=C,m=0,x=L;x;x=Uo(x))m++;for(x=0,I=h;I;I=Uo(I))x++;for(;0<m-x;)L=Uo(L),m--;for(;0<x-m;)h=Uo(h),x--;for(;m--;){if(L===h||h!==null&&L===h.alternate)break t;L=Uo(L),h=Uo(h)}L=null}else L=null;g!==null&&cg(c,p,g,L,!1),C!==null&&S!==null&&cg(c,S,C,L,!0)}}e:{if(p=u?Go(u):window,g=p.nodeName&&p.nodeName.toLowerCase(),g==="select"||g==="input"&&p.type==="file")var k=sw;else if(ag(p))if(bx)k=dw;else{k=lw;var T=iw}else(g=p.nodeName)&&g.toLowerCase()==="input"&&(p.type==="checkbox"||p.type==="radio")&&(k=uw);if(k&&(k=k(e,u))){kx(c,k,a,d);break e}T&&T(e,p,u),e==="focusout"&&(T=p._wrapperState)&&T.controlled&&p.type==="number"&&lf(p,"number",p.value)}switch(T=u?Go(u):window,e){case"focusin":(ag(T)||T.contentEditable==="true")&&(qo=T,Lf=u,_s=null);break;case"focusout":_s=Lf=qo=null;break;case"mousedown":Cf=!0;break;case"contextmenu":case"mouseup":case"dragend":Cf=!1,sg(c,a,d);break;case"selectionchange":if(pw)break;case"keydown":case"keyup":sg(c,a,d)}var R;if(ip)e:{switch(e){case"compositionstart":var A="onCompositionStart";break e;case"compositionend":A="onCompositionEnd";break e;case"compositionupdate":A="onCompositionUpdate";break e}A=void 0}else Ho?Ix(e,a)&&(A="onCompositionEnd"):e==="keydown"&&a.keyCode===229&&(A="onCompositionStart");A&&(Sx&&a.locale!=="ko"&&(Ho||A!=="onCompositionStart"?A==="onCompositionEnd"&&Ho&&(R=Cx()):(fr=d,op="value"in fr?fr.value:fr.textContent,Ho=!0)),T=Kl(u,A),0<T.length&&(A=new Zh(A,e,null,a,d),c.push({event:A,listeners:T}),R?A.data=R:(R=wx(a),R!==null&&(A.data=R)))),(R=tw?aw(e,a):rw(e,a))&&(u=Kl(u,"onBeforeInput"),0<u.length&&(d=new Zh("onBeforeInput","beforeinput",null,a,d),c.push({event:d,listeners:u}),d.data=R))}Bx(c,t)})}function ei(e,t,a){return{instance:e,listener:t,currentTarget:a}}function Kl(e,t){for(var a=t+"Capture",r=[];e!==null;){var o=e,n=o.stateNode;o.tag===5&&n!==null&&(o=n,n=Ks(e,a),n!=null&&r.unshift(ei(e,n,o)),n=Ks(e,t),n!=null&&r.push(ei(e,n,o))),e=e.return}return r}function Uo(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function cg(e,t,a,r,o){for(var n=t._reactName,s=[];a!==null&&a!==r;){var i=a,l=i.alternate,u=i.stateNode;if(l!==null&&l===r)break;i.tag===5&&u!==null&&(i=u,o?(l=Ks(a,n),l!=null&&s.unshift(ei(a,l,i))):o||(l=Ks(a,n),l!=null&&s.push(ei(a,l,i)))),a=a.return}s.length!==0&&e.push({event:t,listeners:s})}var hw=/\r\n?/g,gw=/\u0000|\uFFFD/g;function fg(e){return(typeof e=="string"?e:""+e).replace(hw,`
|
|
6
|
+
`).replace(gw,"")}function wl(e,t,a){if(t=fg(t),fg(e)!==t&&a)throw Error(D(425))}function $l(){}var Sf=null,If=null;function wf(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var kf=typeof setTimeout=="function"?setTimeout:void 0,xw=typeof clearTimeout=="function"?clearTimeout:void 0,pg=typeof Promise=="function"?Promise:void 0,yw=typeof queueMicrotask=="function"?queueMicrotask:typeof pg<"u"?function(e){return pg.resolve(null).then(e).catch(vw)}:kf;function vw(e){setTimeout(function(){throw e})}function Wc(e,t){var a=t,r=0;do{var o=a.nextSibling;if(e.removeChild(a),o&&o.nodeType===8)if(a=o.data,a==="/$"){if(r===0){e.removeChild(o),Qs(t);return}r--}else a!=="$"&&a!=="$?"&&a!=="$!"||r++;a=o}while(a);Qs(t)}function xr(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==="$?")break;if(t==="/$")return null}}return e}function mg(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var a=e.data;if(a==="$"||a==="$!"||a==="$?"){if(t===0)return e;t--}else a==="/$"&&t++}e=e.previousSibling}return null}var pn=Math.random().toString(36).slice(2),xa="__reactFiber$"+pn,ti="__reactProps$"+pn,_a="__reactContainer$"+pn,bf="__reactEvents$"+pn,Lw="__reactListeners$"+pn,Cw="__reactHandles$"+pn;function to(e){var t=e[xa];if(t)return t;for(var a=e.parentNode;a;){if(t=a[_a]||a[xa]){if(a=t.alternate,t.child!==null||a!==null&&a.child!==null)for(e=mg(e);e!==null;){if(a=e[xa])return a;e=mg(e)}return t}e=a,a=e.parentNode}return null}function di(e){return e=e[xa]||e[_a],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Go(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(D(33))}function mu(e){return e[ti]||null}var Pf=[],jo=-1;function kr(e){return{current:e}}function Le(e){0>jo||(e.current=Pf[jo],Pf[jo]=null,jo--)}function xe(e,t){jo++,Pf[jo]=e.current,e.current=t}var Ir={},it=kr(Ir),Lt=kr(!1),so=Ir;function nn(e,t){var a=e.type.contextTypes;if(!a)return Ir;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o={},n;for(n in a)o[n]=t[n];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function Ct(e){return e=e.childContextTypes,e!=null}function Xl(){Le(Lt),Le(it)}function hg(e,t,a){if(it.current!==Ir)throw Error(D(168));xe(it,t),xe(Lt,a)}function Vx(e,t,a){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return a;r=r.getChildContext();for(var o in r)if(!(o in t))throw Error(D(108,iI(e)||"Unknown",o));return Pe({},a,r)}function Ql(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Ir,so=it.current,xe(it,e),xe(Lt,Lt.current),!0}function gg(e,t,a){var r=e.stateNode;if(!r)throw Error(D(169));a?(e=Vx(e,t,so),r.__reactInternalMemoizedMergedChildContext=e,Le(Lt),Le(it),xe(it,e)):Le(Lt),xe(Lt,a)}var Fa=null,hu=!1,Gc=!1;function Ux(e){Fa===null?Fa=[e]:Fa.push(e)}function Sw(e){hu=!0,Ux(e)}function br(){if(!Gc&&Fa!==null){Gc=!0;var e=0,t=pe;try{var a=Fa;for(pe=1;e<a.length;e++){var r=a[e];do r=r(!0);while(r!==null)}Fa=null,hu=!1}catch(o){throw Fa!==null&&(Fa=Fa.slice(e+1)),dx(ep,br),o}finally{pe=t,Gc=!1}}return null}var Ko=[],$o=0,Yl=null,Zl=0,Kt=[],$t=0,io=null,Ba=1,Oa="";function Jr(e,t){Ko[$o++]=Zl,Ko[$o++]=Yl,Yl=e,Zl=t}function _x(e,t,a){Kt[$t++]=Ba,Kt[$t++]=Oa,Kt[$t++]=io,io=e;var r=Ba;e=Oa;var o=32-ia(r)-1;r&=~(1<<o),a+=1;var n=32-ia(t)+o;if(30<n){var s=o-o%5;n=(r&(1<<s)-1).toString(32),r>>=s,o-=s,Ba=1<<32-ia(t)+o|a<<o|r,Oa=n+e}else Ba=1<<n|a<<o|r,Oa=e}function up(e){e.return!==null&&(Jr(e,1),_x(e,1,0))}function dp(e){for(;e===Yl;)Yl=Ko[--$o],Ko[$o]=null,Zl=Ko[--$o],Ko[$o]=null;for(;e===io;)io=Kt[--$t],Kt[$t]=null,Oa=Kt[--$t],Kt[$t]=null,Ba=Kt[--$t],Kt[$t]=null}var Nt=null,Mt=null,we=!1,sa=null;function zx(e,t){var a=Xt(5,null,null,0);a.elementType="DELETED",a.stateNode=t,a.return=e,t=e.deletions,t===null?(e.deletions=[a],e.flags|=16):t.push(a)}function xg(e,t){switch(e.tag){case 5:var a=e.type;return t=t.nodeType!==1||a.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,Nt=e,Mt=xr(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,Nt=e,Mt=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(a=io!==null?{id:Ba,overflow:Oa}:null,e.memoizedState={dehydrated:t,treeContext:a,retryLane:1073741824},a=Xt(18,null,null,0),a.stateNode=t,a.return=e,e.child=a,Nt=e,Mt=null,!0):!1;default:return!1}}function Tf(e){return(e.mode&1)!==0&&(e.flags&128)===0}function Af(e){if(we){var t=Mt;if(t){var a=t;if(!xg(e,t)){if(Tf(e))throw Error(D(418));t=xr(a.nextSibling);var r=Nt;t&&xg(e,t)?zx(r,a):(e.flags=e.flags&-4097|2,we=!1,Nt=e)}}else{if(Tf(e))throw Error(D(418));e.flags=e.flags&-4097|2,we=!1,Nt=e}}}function yg(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Nt=e}function kl(e){if(e!==Nt)return!1;if(!we)return yg(e),we=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!wf(e.type,e.memoizedProps)),t&&(t=Mt)){if(Tf(e))throw Hx(),Error(D(418));for(;t;)zx(e,t),t=xr(t.nextSibling)}if(yg(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(D(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var a=e.data;if(a==="/$"){if(t===0){Mt=xr(e.nextSibling);break e}t--}else a!=="$"&&a!=="$!"&&a!=="$?"||t++}e=e.nextSibling}Mt=null}}else Mt=Nt?xr(e.stateNode.nextSibling):null;return!0}function Hx(){for(var e=Mt;e;)e=xr(e.nextSibling)}function sn(){Mt=Nt=null,we=!1}function cp(e){sa===null?sa=[e]:sa.push(e)}var Iw=qa.ReactCurrentBatchConfig;function Ts(e,t,a){if(e=a.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(a._owner){if(a=a._owner,a){if(a.tag!==1)throw Error(D(309));var r=a.stateNode}if(!r)throw Error(D(147,e));var o=r,n=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===n?t.ref:(t=function(s){var i=o.refs;s===null?delete i[n]:i[n]=s},t._stringRef=n,t)}if(typeof e!="string")throw Error(D(284));if(!a._owner)throw Error(D(290,e))}return e}function bl(e,t){throw e=Object.prototype.toString.call(t),Error(D(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function vg(e){var t=e._init;return t(e._payload)}function qx(e){function t(h,m){if(e){var x=h.deletions;x===null?(h.deletions=[m],h.flags|=16):x.push(m)}}function a(h,m){if(!e)return null;for(;m!==null;)t(h,m),m=m.sibling;return null}function r(h,m){for(h=new Map;m!==null;)m.key!==null?h.set(m.key,m):h.set(m.index,m),m=m.sibling;return h}function o(h,m){return h=Cr(h,m),h.index=0,h.sibling=null,h}function n(h,m,x){return h.index=x,e?(x=h.alternate,x!==null?(x=x.index,x<m?(h.flags|=2,m):x):(h.flags|=2,m)):(h.flags|=1048576,m)}function s(h){return e&&h.alternate===null&&(h.flags|=2),h}function i(h,m,x,I){return m===null||m.tag!==6?(m=Zc(x,h.mode,I),m.return=h,m):(m=o(m,x),m.return=h,m)}function l(h,m,x,I){var k=x.type;return k===zo?d(h,m,x.props.children,I,x.key):m!==null&&(m.elementType===k||typeof k=="object"&&k!==null&&k.$$typeof===lr&&vg(k)===m.type)?(I=o(m,x.props),I.ref=Ts(h,m,x),I.return=h,I):(I=Ul(x.type,x.key,x.props,null,h.mode,I),I.ref=Ts(h,m,x),I.return=h,I)}function u(h,m,x,I){return m===null||m.tag!==4||m.stateNode.containerInfo!==x.containerInfo||m.stateNode.implementation!==x.implementation?(m=Jc(x,h.mode,I),m.return=h,m):(m=o(m,x.children||[]),m.return=h,m)}function d(h,m,x,I,k){return m===null||m.tag!==7?(m=no(x,h.mode,I,k),m.return=h,m):(m=o(m,x),m.return=h,m)}function c(h,m,x){if(typeof m=="string"&&m!==""||typeof m=="number")return m=Zc(""+m,h.mode,x),m.return=h,m;if(typeof m=="object"&&m!==null){switch(m.$$typeof){case cl:return x=Ul(m.type,m.key,m.props,null,h.mode,x),x.ref=Ts(h,null,m),x.return=h,x;case _o:return m=Jc(m,h.mode,x),m.return=h,m;case lr:var I=m._init;return c(h,I(m._payload),x)}if(Ns(m)||ws(m))return m=no(m,h.mode,x,null),m.return=h,m;bl(h,m)}return null}function p(h,m,x,I){var k=m!==null?m.key:null;if(typeof x=="string"&&x!==""||typeof x=="number")return k!==null?null:i(h,m,""+x,I);if(typeof x=="object"&&x!==null){switch(x.$$typeof){case cl:return x.key===k?l(h,m,x,I):null;case _o:return x.key===k?u(h,m,x,I):null;case lr:return k=x._init,p(h,m,k(x._payload),I)}if(Ns(x)||ws(x))return k!==null?null:d(h,m,x,I,null);bl(h,x)}return null}function g(h,m,x,I,k){if(typeof I=="string"&&I!==""||typeof I=="number")return h=h.get(x)||null,i(m,h,""+I,k);if(typeof I=="object"&&I!==null){switch(I.$$typeof){case cl:return h=h.get(I.key===null?x:I.key)||null,l(m,h,I,k);case _o:return h=h.get(I.key===null?x:I.key)||null,u(m,h,I,k);case lr:var T=I._init;return g(h,m,x,T(I._payload),k)}if(Ns(I)||ws(I))return h=h.get(x)||null,d(m,h,I,k,null);bl(m,I)}return null}function C(h,m,x,I){for(var k=null,T=null,R=m,A=m=0,V=null;R!==null&&A<x.length;A++){R.index>A?(V=R,R=null):V=R.sibling;var U=p(h,R,x[A],I);if(U===null){R===null&&(R=V);break}e&&R&&U.alternate===null&&t(h,R),m=n(U,m,A),T===null?k=U:T.sibling=U,T=U,R=V}if(A===x.length)return a(h,R),we&&Jr(h,A),k;if(R===null){for(;A<x.length;A++)R=c(h,x[A],I),R!==null&&(m=n(R,m,A),T===null?k=R:T.sibling=R,T=R);return we&&Jr(h,A),k}for(R=r(h,R);A<x.length;A++)V=g(R,h,A,x[A],I),V!==null&&(e&&V.alternate!==null&&R.delete(V.key===null?A:V.key),m=n(V,m,A),T===null?k=V:T.sibling=V,T=V);return e&&R.forEach(function(se){return t(h,se)}),we&&Jr(h,A),k}function L(h,m,x,I){var k=ws(x);if(typeof k!="function")throw Error(D(150));if(x=k.call(x),x==null)throw Error(D(151));for(var T=k=null,R=m,A=m=0,V=null,U=x.next();R!==null&&!U.done;A++,U=x.next()){R.index>A?(V=R,R=null):V=R.sibling;var se=p(h,R,U.value,I);if(se===null){R===null&&(R=V);break}e&&R&&se.alternate===null&&t(h,R),m=n(se,m,A),T===null?k=se:T.sibling=se,T=se,R=V}if(U.done)return a(h,R),we&&Jr(h,A),k;if(R===null){for(;!U.done;A++,U=x.next())U=c(h,U.value,I),U!==null&&(m=n(U,m,A),T===null?k=U:T.sibling=U,T=U);return we&&Jr(h,A),k}for(R=r(h,R);!U.done;A++,U=x.next())U=g(R,h,A,U.value,I),U!==null&&(e&&U.alternate!==null&&R.delete(U.key===null?A:U.key),m=n(U,m,A),T===null?k=U:T.sibling=U,T=U);return e&&R.forEach(function(q){return t(h,q)}),we&&Jr(h,A),k}function S(h,m,x,I){if(typeof x=="object"&&x!==null&&x.type===zo&&x.key===null&&(x=x.props.children),typeof x=="object"&&x!==null){switch(x.$$typeof){case cl:e:{for(var k=x.key,T=m;T!==null;){if(T.key===k){if(k=x.type,k===zo){if(T.tag===7){a(h,T.sibling),m=o(T,x.props.children),m.return=h,h=m;break e}}else if(T.elementType===k||typeof k=="object"&&k!==null&&k.$$typeof===lr&&vg(k)===T.type){a(h,T.sibling),m=o(T,x.props),m.ref=Ts(h,T,x),m.return=h,h=m;break e}a(h,T);break}else t(h,T);T=T.sibling}x.type===zo?(m=no(x.props.children,h.mode,I,x.key),m.return=h,h=m):(I=Ul(x.type,x.key,x.props,null,h.mode,I),I.ref=Ts(h,m,x),I.return=h,h=I)}return s(h);case _o:e:{for(T=x.key;m!==null;){if(m.key===T)if(m.tag===4&&m.stateNode.containerInfo===x.containerInfo&&m.stateNode.implementation===x.implementation){a(h,m.sibling),m=o(m,x.children||[]),m.return=h,h=m;break e}else{a(h,m);break}else t(h,m);m=m.sibling}m=Jc(x,h.mode,I),m.return=h,h=m}return s(h);case lr:return T=x._init,S(h,m,T(x._payload),I)}if(Ns(x))return C(h,m,x,I);if(ws(x))return L(h,m,x,I);bl(h,x)}return typeof x=="string"&&x!==""||typeof x=="number"?(x=""+x,m!==null&&m.tag===6?(a(h,m.sibling),m=o(m,x),m.return=h,h=m):(a(h,m),m=Zc(x,h.mode,I),m.return=h,h=m),s(h)):a(h,m)}return S}var ln=qx(!0),Wx=qx(!1),Jl=kr(null),eu=null,Xo=null,fp=null;function pp(){fp=Xo=eu=null}function mp(e){var t=Jl.current;Le(Jl),e._currentValue=t}function Rf(e,t,a){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===a)break;e=e.return}}function an(e,t){eu=e,fp=Xo=null,e=e.dependencies,e!==null&&e.firstContext!==null&&((e.lanes&t)!==0&&(vt=!0),e.firstContext=null)}function Yt(e){var t=e._currentValue;if(fp!==e)if(e={context:e,memoizedValue:t,next:null},Xo===null){if(eu===null)throw Error(D(308));Xo=e,eu.dependencies={lanes:0,firstContext:e}}else Xo=Xo.next=e;return t}var ao=null;function hp(e){ao===null?ao=[e]:ao.push(e)}function Gx(e,t,a,r){var o=t.interleaved;return o===null?(a.next=a,hp(t)):(a.next=o.next,o.next=a),t.interleaved=a,za(e,r)}function za(e,t){e.lanes|=t;var a=e.alternate;for(a!==null&&(a.lanes|=t),a=e,e=e.return;e!==null;)e.childLanes|=t,a=e.alternate,a!==null&&(a.childLanes|=t),a=e,e=e.return;return a.tag===3?a.stateNode:null}var ur=!1;function gp(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function jx(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function Va(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function yr(e,t,a){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,(le&2)!==0){var o=r.pending;return o===null?t.next=t:(t.next=o.next,o.next=t),r.pending=t,za(e,a)}return o=r.interleaved,o===null?(t.next=t,hp(r)):(t.next=o.next,o.next=t),r.interleaved=t,za(e,a)}function Nl(e,t,a){if(t=t.updateQueue,t!==null&&(t=t.shared,(a&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,a|=r,t.lanes=a,tp(e,a)}}function Lg(e,t){var a=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,a===r)){var o=null,n=null;if(a=a.firstBaseUpdate,a!==null){do{var s={eventTime:a.eventTime,lane:a.lane,tag:a.tag,payload:a.payload,callback:a.callback,next:null};n===null?o=n=s:n=n.next=s,a=a.next}while(a!==null);n===null?o=n=t:n=n.next=t}else o=n=t;a={baseState:r.baseState,firstBaseUpdate:o,lastBaseUpdate:n,shared:r.shared,effects:r.effects},e.updateQueue=a;return}e=a.lastBaseUpdate,e===null?a.firstBaseUpdate=t:e.next=t,a.lastBaseUpdate=t}function tu(e,t,a,r){var o=e.updateQueue;ur=!1;var n=o.firstBaseUpdate,s=o.lastBaseUpdate,i=o.shared.pending;if(i!==null){o.shared.pending=null;var l=i,u=l.next;l.next=null,s===null?n=u:s.next=u,s=l;var d=e.alternate;d!==null&&(d=d.updateQueue,i=d.lastBaseUpdate,i!==s&&(i===null?d.firstBaseUpdate=u:i.next=u,d.lastBaseUpdate=l))}if(n!==null){var c=o.baseState;s=0,d=u=l=null,i=n;do{var p=i.lane,g=i.eventTime;if((r&p)===p){d!==null&&(d=d.next={eventTime:g,lane:0,tag:i.tag,payload:i.payload,callback:i.callback,next:null});e:{var C=e,L=i;switch(p=t,g=a,L.tag){case 1:if(C=L.payload,typeof C=="function"){c=C.call(g,c,p);break e}c=C;break e;case 3:C.flags=C.flags&-65537|128;case 0:if(C=L.payload,p=typeof C=="function"?C.call(g,c,p):C,p==null)break e;c=Pe({},c,p);break e;case 2:ur=!0}}i.callback!==null&&i.lane!==0&&(e.flags|=64,p=o.effects,p===null?o.effects=[i]:p.push(i))}else g={eventTime:g,lane:p,tag:i.tag,payload:i.payload,callback:i.callback,next:null},d===null?(u=d=g,l=c):d=d.next=g,s|=p;if(i=i.next,i===null){if(i=o.shared.pending,i===null)break;p=i,i=p.next,p.next=null,o.lastBaseUpdate=p,o.shared.pending=null}}while(!0);if(d===null&&(l=c),o.baseState=l,o.firstBaseUpdate=u,o.lastBaseUpdate=d,t=o.shared.interleaved,t!==null){o=t;do s|=o.lane,o=o.next;while(o!==t)}else n===null&&(o.shared.lanes=0);uo|=s,e.lanes=s,e.memoizedState=c}}function Cg(e,t,a){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],o=r.callback;if(o!==null){if(r.callback=null,r=a,typeof o!="function")throw Error(D(191,o));o.call(r)}}}var ci={},va=kr(ci),ai=kr(ci),ri=kr(ci);function ro(e){if(e===ci)throw Error(D(174));return e}function xp(e,t){switch(xe(ri,t),xe(ai,e),xe(va,ci),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:df(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=df(t,e)}Le(va),xe(va,t)}function un(){Le(va),Le(ai),Le(ri)}function Kx(e){ro(ri.current);var t=ro(va.current),a=df(t,e.type);t!==a&&(xe(ai,e),xe(va,a))}function yp(e){ai.current===e&&(Le(va),Le(ai))}var ke=kr(0);function au(e){for(var t=e;t!==null;){if(t.tag===13){var a=t.memoizedState;if(a!==null&&(a=a.dehydrated,a===null||a.data==="$?"||a.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){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 jc=[];function vp(){for(var e=0;e<jc.length;e++)jc[e]._workInProgressVersionPrimary=null;jc.length=0}var El=qa.ReactCurrentDispatcher,Kc=qa.ReactCurrentBatchConfig,lo=0,be=null,_e=null,je=null,ru=!1,zs=!1,oi=0,ww=0;function ot(){throw Error(D(321))}function Lp(e,t){if(t===null)return!1;for(var a=0;a<t.length&&a<e.length;a++)if(!ua(e[a],t[a]))return!1;return!0}function Cp(e,t,a,r,o,n){if(lo=n,be=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,El.current=e===null||e.memoizedState===null?Tw:Aw,e=a(r,o),zs){n=0;do{if(zs=!1,oi=0,25<=n)throw Error(D(301));n+=1,je=_e=null,t.updateQueue=null,El.current=Rw,e=a(r,o)}while(zs)}if(El.current=ou,t=_e!==null&&_e.next!==null,lo=0,je=_e=be=null,ru=!1,t)throw Error(D(300));return e}function Sp(){var e=oi!==0;return oi=0,e}function ga(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return je===null?be.memoizedState=je=e:je=je.next=e,je}function Zt(){if(_e===null){var e=be.alternate;e=e!==null?e.memoizedState:null}else e=_e.next;var t=je===null?be.memoizedState:je.next;if(t!==null)je=t,_e=e;else{if(e===null)throw Error(D(310));_e=e,e={memoizedState:_e.memoizedState,baseState:_e.baseState,baseQueue:_e.baseQueue,queue:_e.queue,next:null},je===null?be.memoizedState=je=e:je=je.next=e}return je}function ni(e,t){return typeof t=="function"?t(e):t}function $c(e){var t=Zt(),a=t.queue;if(a===null)throw Error(D(311));a.lastRenderedReducer=e;var r=_e,o=r.baseQueue,n=a.pending;if(n!==null){if(o!==null){var s=o.next;o.next=n.next,n.next=s}r.baseQueue=o=n,a.pending=null}if(o!==null){n=o.next,r=r.baseState;var i=s=null,l=null,u=n;do{var d=u.lane;if((lo&d)===d)l!==null&&(l=l.next={lane:0,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),r=u.hasEagerState?u.eagerState:e(r,u.action);else{var c={lane:d,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};l===null?(i=l=c,s=r):l=l.next=c,be.lanes|=d,uo|=d}u=u.next}while(u!==null&&u!==n);l===null?s=r:l.next=i,ua(r,t.memoizedState)||(vt=!0),t.memoizedState=r,t.baseState=s,t.baseQueue=l,a.lastRenderedState=r}if(e=a.interleaved,e!==null){o=e;do n=o.lane,be.lanes|=n,uo|=n,o=o.next;while(o!==e)}else o===null&&(a.lanes=0);return[t.memoizedState,a.dispatch]}function Xc(e){var t=Zt(),a=t.queue;if(a===null)throw Error(D(311));a.lastRenderedReducer=e;var r=a.dispatch,o=a.pending,n=t.memoizedState;if(o!==null){a.pending=null;var s=o=o.next;do n=e(n,s.action),s=s.next;while(s!==o);ua(n,t.memoizedState)||(vt=!0),t.memoizedState=n,t.baseQueue===null&&(t.baseState=n),a.lastRenderedState=n}return[n,r]}function $x(){}function Xx(e,t){var a=be,r=Zt(),o=t(),n=!ua(r.memoizedState,o);if(n&&(r.memoizedState=o,vt=!0),r=r.queue,Ip(Zx.bind(null,a,r,e),[e]),r.getSnapshot!==t||n||je!==null&&je.memoizedState.tag&1){if(a.flags|=2048,si(9,Yx.bind(null,a,r,o,t),void 0,null),Ke===null)throw Error(D(349));(lo&30)!==0||Qx(a,t,o)}return o}function Qx(e,t,a){e.flags|=16384,e={getSnapshot:t,value:a},t=be.updateQueue,t===null?(t={lastEffect:null,stores:null},be.updateQueue=t,t.stores=[e]):(a=t.stores,a===null?t.stores=[e]:a.push(e))}function Yx(e,t,a,r){t.value=a,t.getSnapshot=r,Jx(t)&&ey(e)}function Zx(e,t,a){return a(function(){Jx(t)&&ey(e)})}function Jx(e){var t=e.getSnapshot;e=e.value;try{var a=t();return!ua(e,a)}catch{return!0}}function ey(e){var t=za(e,1);t!==null&&la(t,e,1,-1)}function Sg(e){var t=ga();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:ni,lastRenderedState:e},t.queue=e,e=e.dispatch=Pw.bind(null,be,e),[t.memoizedState,e]}function si(e,t,a,r){return e={tag:e,create:t,destroy:a,deps:r,next:null},t=be.updateQueue,t===null?(t={lastEffect:null,stores:null},be.updateQueue=t,t.lastEffect=e.next=e):(a=t.lastEffect,a===null?t.lastEffect=e.next=e:(r=a.next,a.next=e,e.next=r,t.lastEffect=e)),e}function ty(){return Zt().memoizedState}function Fl(e,t,a,r){var o=ga();be.flags|=e,o.memoizedState=si(1|t,a,void 0,r===void 0?null:r)}function gu(e,t,a,r){var o=Zt();r=r===void 0?null:r;var n=void 0;if(_e!==null){var s=_e.memoizedState;if(n=s.destroy,r!==null&&Lp(r,s.deps)){o.memoizedState=si(t,a,n,r);return}}be.flags|=e,o.memoizedState=si(1|t,a,n,r)}function Ig(e,t){return Fl(8390656,8,e,t)}function Ip(e,t){return gu(2048,8,e,t)}function ay(e,t){return gu(4,2,e,t)}function ry(e,t){return gu(4,4,e,t)}function oy(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function ny(e,t,a){return a=a!=null?a.concat([e]):null,gu(4,4,oy.bind(null,t,e),a)}function wp(){}function sy(e,t){var a=Zt();t=t===void 0?null:t;var r=a.memoizedState;return r!==null&&t!==null&&Lp(t,r[1])?r[0]:(a.memoizedState=[e,t],e)}function iy(e,t){var a=Zt();t=t===void 0?null:t;var r=a.memoizedState;return r!==null&&t!==null&&Lp(t,r[1])?r[0]:(e=e(),a.memoizedState=[e,t],e)}function ly(e,t,a){return(lo&21)===0?(e.baseState&&(e.baseState=!1,vt=!0),e.memoizedState=a):(ua(a,t)||(a=px(),be.lanes|=a,uo|=a,e.baseState=!0),t)}function kw(e,t){var a=pe;pe=a!==0&&4>a?a:4,e(!0);var r=Kc.transition;Kc.transition={};try{e(!1),t()}finally{pe=a,Kc.transition=r}}function uy(){return Zt().memoizedState}function bw(e,t,a){var r=Lr(e);if(a={lane:r,action:a,hasEagerState:!1,eagerState:null,next:null},dy(e))cy(t,a);else if(a=Gx(e,t,a,r),a!==null){var o=pt();la(a,e,r,o),fy(a,t,r)}}function Pw(e,t,a){var r=Lr(e),o={lane:r,action:a,hasEagerState:!1,eagerState:null,next:null};if(dy(e))cy(t,o);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(o.hasEagerState=!0,o.eagerState=i,ua(i,s)){var l=t.interleaved;l===null?(o.next=o,hp(t)):(o.next=l.next,l.next=o),t.interleaved=o;return}}catch{}a=Gx(e,t,o,r),a!==null&&(o=pt(),la(a,e,r,o),fy(a,t,r))}}function dy(e){var t=e.alternate;return e===be||t!==null&&t===be}function cy(e,t){zs=ru=!0;var a=e.pending;a===null?t.next=t:(t.next=a.next,a.next=t),e.pending=t}function fy(e,t,a){if((a&4194240)!==0){var r=t.lanes;r&=e.pendingLanes,a|=r,t.lanes=a,tp(e,a)}}var ou={readContext:Yt,useCallback:ot,useContext:ot,useEffect:ot,useImperativeHandle:ot,useInsertionEffect:ot,useLayoutEffect:ot,useMemo:ot,useReducer:ot,useRef:ot,useState:ot,useDebugValue:ot,useDeferredValue:ot,useTransition:ot,useMutableSource:ot,useSyncExternalStore:ot,useId:ot,unstable_isNewReconciler:!1},Tw={readContext:Yt,useCallback:function(e,t){return ga().memoizedState=[e,t===void 0?null:t],e},useContext:Yt,useEffect:Ig,useImperativeHandle:function(e,t,a){return a=a!=null?a.concat([e]):null,Fl(4194308,4,oy.bind(null,t,e),a)},useLayoutEffect:function(e,t){return Fl(4194308,4,e,t)},useInsertionEffect:function(e,t){return Fl(4,2,e,t)},useMemo:function(e,t){var a=ga();return t=t===void 0?null:t,e=e(),a.memoizedState=[e,t],e},useReducer:function(e,t,a){var r=ga();return t=a!==void 0?a(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=bw.bind(null,be,e),[r.memoizedState,e]},useRef:function(e){var t=ga();return e={current:e},t.memoizedState=e},useState:Sg,useDebugValue:wp,useDeferredValue:function(e){return ga().memoizedState=e},useTransition:function(){var e=Sg(!1),t=e[0];return e=kw.bind(null,e[1]),ga().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,a){var r=be,o=ga();if(we){if(a===void 0)throw Error(D(407));a=a()}else{if(a=t(),Ke===null)throw Error(D(349));(lo&30)!==0||Qx(r,t,a)}o.memoizedState=a;var n={value:a,getSnapshot:t};return o.queue=n,Ig(Zx.bind(null,r,n,e),[e]),r.flags|=2048,si(9,Yx.bind(null,r,n,a,t),void 0,null),a},useId:function(){var e=ga(),t=Ke.identifierPrefix;if(we){var a=Oa,r=Ba;a=(r&~(1<<32-ia(r)-1)).toString(32)+a,t=":"+t+"R"+a,a=oi++,0<a&&(t+="H"+a.toString(32)),t+=":"}else a=ww++,t=":"+t+"r"+a.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},Aw={readContext:Yt,useCallback:sy,useContext:Yt,useEffect:Ip,useImperativeHandle:ny,useInsertionEffect:ay,useLayoutEffect:ry,useMemo:iy,useReducer:$c,useRef:ty,useState:function(){return $c(ni)},useDebugValue:wp,useDeferredValue:function(e){var t=Zt();return ly(t,_e.memoizedState,e)},useTransition:function(){var e=$c(ni)[0],t=Zt().memoizedState;return[e,t]},useMutableSource:$x,useSyncExternalStore:Xx,useId:uy,unstable_isNewReconciler:!1},Rw={readContext:Yt,useCallback:sy,useContext:Yt,useEffect:Ip,useImperativeHandle:ny,useInsertionEffect:ay,useLayoutEffect:ry,useMemo:iy,useReducer:Xc,useRef:ty,useState:function(){return Xc(ni)},useDebugValue:wp,useDeferredValue:function(e){var t=Zt();return _e===null?t.memoizedState=e:ly(t,_e.memoizedState,e)},useTransition:function(){var e=Xc(ni)[0],t=Zt().memoizedState;return[e,t]},useMutableSource:$x,useSyncExternalStore:Xx,useId:uy,unstable_isNewReconciler:!1};function oa(e,t){if(e&&e.defaultProps){t=Pe({},t),e=e.defaultProps;for(var a in e)t[a]===void 0&&(t[a]=e[a]);return t}return t}function Df(e,t,a,r){t=e.memoizedState,a=a(r,t),a=a==null?t:Pe({},t,a),e.memoizedState=a,e.lanes===0&&(e.updateQueue.baseState=a)}var xu={isMounted:function(e){return(e=e._reactInternals)?po(e)===e:!1},enqueueSetState:function(e,t,a){e=e._reactInternals;var r=pt(),o=Lr(e),n=Va(r,o);n.payload=t,a!=null&&(n.callback=a),t=yr(e,n,o),t!==null&&(la(t,e,o,r),Nl(t,e,o))},enqueueReplaceState:function(e,t,a){e=e._reactInternals;var r=pt(),o=Lr(e),n=Va(r,o);n.tag=1,n.payload=t,a!=null&&(n.callback=a),t=yr(e,n,o),t!==null&&(la(t,e,o,r),Nl(t,e,o))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var a=pt(),r=Lr(e),o=Va(a,r);o.tag=2,t!=null&&(o.callback=t),t=yr(e,o,r),t!==null&&(la(t,e,r,a),Nl(t,e,r))}};function wg(e,t,a,r,o,n,s){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,n,s):t.prototype&&t.prototype.isPureReactComponent?!Zs(a,r)||!Zs(o,n):!0}function py(e,t,a){var r=!1,o=Ir,n=t.contextType;return typeof n=="object"&&n!==null?n=Yt(n):(o=Ct(t)?so:it.current,r=t.contextTypes,n=(r=r!=null)?nn(e,o):Ir),t=new t(a,n),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=xu,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=o,e.__reactInternalMemoizedMaskedChildContext=n),t}function kg(e,t,a,r){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(a,r),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(a,r),t.state!==e&&xu.enqueueReplaceState(t,t.state,null)}function Mf(e,t,a,r){var o=e.stateNode;o.props=a,o.state=e.memoizedState,o.refs={},gp(e);var n=t.contextType;typeof n=="object"&&n!==null?o.context=Yt(n):(n=Ct(t)?so:it.current,o.context=nn(e,n)),o.state=e.memoizedState,n=t.getDerivedStateFromProps,typeof n=="function"&&(Df(e,t,n,a),o.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof o.getSnapshotBeforeUpdate=="function"||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(t=o.state,typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount(),t!==o.state&&xu.enqueueReplaceState(o,o.state,null),tu(e,a,o,r),o.state=e.memoizedState),typeof o.componentDidMount=="function"&&(e.flags|=4194308)}function dn(e,t){try{var a="",r=t;do a+=sI(r),r=r.return;while(r);var o=a}catch(n){o=`
|
|
7
7
|
Error generating stack: `+n.message+`
|
|
8
|
-
`+n.stack}return{value:e,source:t,stack:o,digest:null}}function Xc(e,t,a){return{value:e,source:null,stack:a??null,digest:t??null}}function Mf(e,t){try{console.error(t.value)}catch(a){setTimeout(function(){throw a})}}var Rw=typeof WeakMap=="function"?WeakMap:Map;function py(e,t,a){a=Va(-1,a),a.tag=3,a.payload={element:null};var r=t.value;return a.callback=function(){nu||(nu=!0,Hf=r),Mf(e,t)},a}function my(e,t,a){a=Va(-1,a),a.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var o=t.value;a.payload=function(){return r(o)},a.callback=function(){Mf(e,t)}}var n=e.stateNode;return n!==null&&typeof n.componentDidCatch=="function"&&(a.callback=function(){Mf(e,t),typeof r!="function"&&(vr===null?vr=new Set([this]):vr.add(this));var s=t.stack;this.componentDidCatch(t.value,{componentStack:s!==null?s:""})}),a}function kg(e,t,a){var r=e.pingCache;if(r===null){r=e.pingCache=new Rw;var o=new Set;r.set(t,o)}else o=r.get(t),o===void 0&&(o=new Set,r.set(t,o));o.has(a)||(o.add(a),e=Ww.bind(null,e,t,a),t.then(e,e))}function bg(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function Pg(e,t,a,r,o){return(e.mode&1)===0?(e===t?e.flags|=65536:(e.flags|=128,a.flags|=131072,a.flags&=-52805,a.tag===1&&(a.alternate===null?a.tag=17:(t=Va(-1,1),t.tag=2,yr(a,t,1))),a.lanes|=1),e):(e.flags|=65536,e.lanes=o,e)}var Dw=qa.ReactCurrentOwner,vt=!1;function ft(e,t,a,r){t.child=e===null?qx(t,null,a,r):ln(t,e.child,a,r)}function Tg(e,t,a,r,o){a=a.render;var n=t.ref;return an(t,o),r=Lp(e,t,a,r,n,o),a=Cp(),e!==null&&!vt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,Ha(e,t,o)):(we&&a&&lp(t),t.flags|=1,ft(e,t,r,o),t.child)}function Ag(e,t,a,r,o){if(e===null){var n=a.type;return typeof n=="function"&&!Dp(n)&&n.defaultProps===void 0&&a.compare===null&&a.defaultProps===void 0?(t.tag=15,t.type=n,hy(e,t,n,r,o)):(e=Vl(a.type,null,r,t,t.mode,o),e.ref=t.ref,e.return=t,t.child=e)}if(n=e.child,(e.lanes&o)===0){var s=n.memoizedProps;if(a=a.compare,a=a!==null?a:Zs,a(s,r)&&e.ref===t.ref)return Ha(e,t,o)}return t.flags|=1,e=Cr(n,r),e.ref=t.ref,e.return=t,t.child=e}function hy(e,t,a,r,o){if(e!==null){var n=e.memoizedProps;if(Zs(n,r)&&e.ref===t.ref)if(vt=!1,t.pendingProps=r=n,(e.lanes&o)!==0)(e.flags&131072)!==0&&(vt=!0);else return t.lanes=e.lanes,Ha(e,t,o)}return Nf(e,t,a,r,o)}function gy(e,t,a){var r=t.pendingProps,o=r.children,n=e!==null?e.memoizedState:null;if(r.mode==="hidden")if((t.mode&1)===0)t.memoizedState={baseLanes:0,cachePool:null,transitions:null},xe(Yo,Dt),Dt|=a;else{if((a&1073741824)===0)return e=n!==null?n.baseLanes|a:a,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,xe(Yo,Dt),Dt|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=n!==null?n.baseLanes:a,xe(Yo,Dt),Dt|=r}else n!==null?(r=n.baseLanes|a,t.memoizedState=null):r=a,xe(Yo,Dt),Dt|=r;return ft(e,t,o,a),t.child}function xy(e,t){var a=t.ref;(e===null&&a!==null||e!==null&&e.ref!==a)&&(t.flags|=512,t.flags|=2097152)}function Nf(e,t,a,r,o){var n=Ct(a)?io:it.current;return n=nn(t,n),an(t,o),a=Lp(e,t,a,r,n,o),r=Cp(),e!==null&&!vt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,Ha(e,t,o)):(we&&r&&lp(t),t.flags|=1,ft(e,t,a,o),t.child)}function Rg(e,t,a,r,o){if(Ct(a)){var n=!0;Xl(t)}else n=!1;if(an(t,o),t.stateNode===null)Fl(e,t),fy(t,a,r),Df(t,a,r,o),r=!0;else if(e===null){var s=t.stateNode,i=t.memoizedProps;s.props=i;var l=s.context,u=a.contextType;typeof u=="object"&&u!==null?u=Yt(u):(u=Ct(a)?io:it.current,u=nn(t,u));var d=a.getDerivedStateFromProps,c=typeof d=="function"||typeof s.getSnapshotBeforeUpdate=="function";c||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(i!==r||l!==u)&&wg(t,s,r,u),ur=!1;var p=t.memoizedState;s.state=p,eu(t,r,s,o),l=t.memoizedState,i!==r||p!==l||Lt.current||ur?(typeof d=="function"&&(Rf(t,a,d,r),l=t.memoizedState),(i=ur||Ig(t,a,i,r,p,l,u))?(c||typeof s.UNSAFE_componentWillMount!="function"&&typeof s.componentWillMount!="function"||(typeof s.componentWillMount=="function"&&s.componentWillMount(),typeof s.UNSAFE_componentWillMount=="function"&&s.UNSAFE_componentWillMount()),typeof s.componentDidMount=="function"&&(t.flags|=4194308)):(typeof s.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),s.props=r,s.state=l,s.context=u,r=i):(typeof s.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{s=t.stateNode,Gx(e,t),i=t.memoizedProps,u=t.type===t.elementType?i:oa(t.type,i),s.props=u,c=t.pendingProps,p=s.context,l=a.contextType,typeof l=="object"&&l!==null?l=Yt(l):(l=Ct(a)?io:it.current,l=nn(t,l));var g=a.getDerivedStateFromProps;(d=typeof g=="function"||typeof s.getSnapshotBeforeUpdate=="function")||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(i!==c||p!==l)&&wg(t,s,r,l),ur=!1,p=t.memoizedState,s.state=p,eu(t,r,s,o);var C=t.memoizedState;i!==c||p!==C||Lt.current||ur?(typeof g=="function"&&(Rf(t,a,g,r),C=t.memoizedState),(u=ur||Ig(t,a,u,r,p,C,l)||!1)?(d||typeof s.UNSAFE_componentWillUpdate!="function"&&typeof s.componentWillUpdate!="function"||(typeof s.componentWillUpdate=="function"&&s.componentWillUpdate(r,C,l),typeof s.UNSAFE_componentWillUpdate=="function"&&s.UNSAFE_componentWillUpdate(r,C,l)),typeof s.componentDidUpdate=="function"&&(t.flags|=4),typeof s.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof s.componentDidUpdate!="function"||i===e.memoizedProps&&p===e.memoizedState||(t.flags|=4),typeof s.getSnapshotBeforeUpdate!="function"||i===e.memoizedProps&&p===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=C),s.props=r,s.state=C,s.context=l,r=u):(typeof s.componentDidUpdate!="function"||i===e.memoizedProps&&p===e.memoizedState||(t.flags|=4),typeof s.getSnapshotBeforeUpdate!="function"||i===e.memoizedProps&&p===e.memoizedState||(t.flags|=1024),r=!1)}return Ef(e,t,a,r,n,o)}function Ef(e,t,a,r,o,n){xy(e,t);var s=(t.flags&128)!==0;if(!r&&!s)return o&&hg(t,a,!1),Ha(e,t,n);r=t.stateNode,Dw.current=t;var i=s&&typeof a.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&s?(t.child=ln(t,e.child,null,n),t.child=ln(t,null,i,n)):ft(e,t,i,n),t.memoizedState=r.state,o&&hg(t,a,!0),t.child}function yy(e){var t=e.stateNode;t.pendingContext?mg(e,t.pendingContext,t.pendingContext!==t.context):t.context&&mg(e,t.context,!1),gp(e,t.containerInfo)}function Dg(e,t,a,r,o){return sn(),dp(o),t.flags|=256,ft(e,t,a,r),t.child}var Ff={dehydrated:null,treeContext:null,retryLane:0};function Bf(e){return{baseLanes:e,cachePool:null,transitions:null}}function vy(e,t,a){var r=t.pendingProps,o=ke.current,n=!1,s=(t.flags&128)!==0,i;if((i=s)||(i=e!==null&&e.memoizedState===null?!1:(o&2)!==0),i?(n=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(o|=1),xe(ke,o&1),e===null)return Tf(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?((t.mode&1)===0?t.lanes=1:e.data==="$!"?t.lanes=8:t.lanes=1073741824,null):(s=r.children,e=r.fallback,n?(r=t.mode,n=t.child,s={mode:"hidden",children:s},(r&1)===0&&n!==null?(n.childLanes=0,n.pendingProps=s):n=vu(s,r,0,null),e=so(e,r,a,null),n.return=t,e.return=t,n.sibling=e,t.child=n,t.child.memoizedState=Bf(a),t.memoizedState=Ff,e):wp(t,s));if(o=e.memoizedState,o!==null&&(i=o.dehydrated,i!==null))return Mw(e,t,s,r,i,o,a);if(n){n=r.fallback,s=t.mode,o=e.child,i=o.sibling;var l={mode:"hidden",children:r.children};return(s&1)===0&&t.child!==o?(r=t.child,r.childLanes=0,r.pendingProps=l,t.deletions=null):(r=Cr(o,l),r.subtreeFlags=o.subtreeFlags&14680064),i!==null?n=Cr(i,n):(n=so(n,s,a,null),n.flags|=2),n.return=t,r.return=t,r.sibling=n,t.child=r,r=n,n=t.child,s=e.child.memoizedState,s=s===null?Bf(a):{baseLanes:s.baseLanes|a,cachePool:null,transitions:s.transitions},n.memoizedState=s,n.childLanes=e.childLanes&~a,t.memoizedState=Ff,r}return n=e.child,e=n.sibling,r=Cr(n,{mode:"visible",children:r.children}),(t.mode&1)===0&&(r.lanes=a),r.return=t,r.sibling=null,e!==null&&(a=t.deletions,a===null?(t.deletions=[e],t.flags|=16):a.push(e)),t.child=r,t.memoizedState=null,r}function wp(e,t){return t=vu({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function bl(e,t,a,r){return r!==null&&dp(r),ln(t,e.child,null,a),e=wp(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Mw(e,t,a,r,o,n,s){if(a)return t.flags&256?(t.flags&=-257,r=Xc(Error(D(422))),bl(e,t,s,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(n=r.fallback,o=t.mode,r=vu({mode:"visible",children:r.children},o,0,null),n=so(n,o,s,null),n.flags|=2,r.return=t,n.return=t,r.sibling=n,t.child=r,(t.mode&1)!==0&&ln(t,e.child,null,s),t.child.memoizedState=Bf(s),t.memoizedState=Ff,n);if((t.mode&1)===0)return bl(e,t,s,null);if(o.data==="$!"){if(r=o.nextSibling&&o.nextSibling.dataset,r)var i=r.dgst;return r=i,n=Error(D(419)),r=Xc(n,r,void 0),bl(e,t,s,r)}if(i=(s&e.childLanes)!==0,vt||i){if(r=Ke,r!==null){switch(s&-s){case 4:o=2;break;case 16:o=8;break;case 64: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:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:o=32;break;case 536870912:o=268435456;break;default:o=0}o=(o&(r.suspendedLanes|s))!==0?0:o,o!==0&&o!==n.retryLane&&(n.retryLane=o,za(e,o),la(r,e,o,-1))}return Rp(),r=Xc(Error(D(421))),bl(e,t,s,r)}return o.data==="$?"?(t.flags|=128,t.child=e.child,t=Gw.bind(null,e),o._reactRetry=t,null):(e=n.treeContext,Mt=xr(o.nextSibling),Nt=t,we=!0,sa=null,e!==null&&(Kt[$t++]=Ba,Kt[$t++]=Oa,Kt[$t++]=lo,Ba=e.id,Oa=e.overflow,lo=t),t=wp(t,r.children),t.flags|=4096,t)}function Mg(e,t,a){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Af(e.return,t,a)}function Qc(e,t,a,r,o){var n=e.memoizedState;n===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:a,tailMode:o}:(n.isBackwards=t,n.rendering=null,n.renderingStartTime=0,n.last=r,n.tail=a,n.tailMode=o)}function Ly(e,t,a){var r=t.pendingProps,o=r.revealOrder,n=r.tail;if(ft(e,t,r.children,a),r=ke.current,(r&2)!==0)r=r&1|2,t.flags|=128;else{if(e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Mg(e,a,t);else if(e.tag===19)Mg(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}r&=1}if(xe(ke,r),(t.mode&1)===0)t.memoizedState=null;else switch(o){case"forwards":for(a=t.child,o=null;a!==null;)e=a.alternate,e!==null&&tu(e)===null&&(o=a),a=a.sibling;a=o,a===null?(o=t.child,t.child=null):(o=a.sibling,a.sibling=null),Qc(t,!1,o,a,n);break;case"backwards":for(a=null,o=t.child,t.child=null;o!==null;){if(e=o.alternate,e!==null&&tu(e)===null){t.child=o;break}e=o.sibling,o.sibling=a,a=o,o=e}Qc(t,!0,a,null,n);break;case"together":Qc(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Fl(e,t){(t.mode&1)===0&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Ha(e,t,a){if(e!==null&&(t.dependencies=e.dependencies),co|=t.lanes,(a&t.childLanes)===0)return null;if(e!==null&&t.child!==e.child)throw Error(D(153));if(t.child!==null){for(e=t.child,a=Cr(e,e.pendingProps),t.child=a,a.return=t;e.sibling!==null;)e=e.sibling,a=a.sibling=Cr(e,e.pendingProps),a.return=t;a.sibling=null}return t.child}function Nw(e,t,a){switch(t.tag){case 3:yy(t),sn();break;case 5:jx(t);break;case 1:Ct(t.type)&&Xl(t);break;case 4:gp(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,o=t.memoizedProps.value;xe(Zl,r._currentValue),r._currentValue=o;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(xe(ke,ke.current&1),t.flags|=128,null):(a&t.child.childLanes)!==0?vy(e,t,a):(xe(ke,ke.current&1),e=Ha(e,t,a),e!==null?e.sibling:null);xe(ke,ke.current&1);break;case 19:if(r=(a&t.childLanes)!==0,(e.flags&128)!==0){if(r)return Ly(e,t,a);t.flags|=128}if(o=t.memoizedState,o!==null&&(o.rendering=null,o.tail=null,o.lastEffect=null),xe(ke,ke.current),r)break;return null;case 22:case 23:return t.lanes=0,gy(e,t,a)}return Ha(e,t,a)}var Cy,Of,Sy,Iy;Cy=function(e,t){for(var a=t.child;a!==null;){if(a.tag===5||a.tag===6)e.appendChild(a.stateNode);else if(a.tag!==4&&a.child!==null){a.child.return=a,a=a.child;continue}if(a===t)break;for(;a.sibling===null;){if(a.return===null||a.return===t)return;a=a.return}a.sibling.return=a.return,a=a.sibling}};Of=function(){};Sy=function(e,t,a,r){var o=e.memoizedProps;if(o!==r){e=t.stateNode,oo(va.current);var n=null;switch(a){case"input":o=of(e,o),r=of(e,r),n=[];break;case"select":o=Pe({},o,{value:void 0}),r=Pe({},r,{value:void 0}),n=[];break;case"textarea":o=lf(e,o),r=lf(e,r),n=[];break;default:typeof o.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=Kl)}df(a,r);var s;a=null;for(u in o)if(!r.hasOwnProperty(u)&&o.hasOwnProperty(u)&&o[u]!=null)if(u==="style"){var i=o[u];for(s in i)i.hasOwnProperty(s)&&(a||(a={}),a[s]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(Gs.hasOwnProperty(u)?n||(n=[]):(n=n||[]).push(u,null));for(u in r){var l=r[u];if(i=o?.[u],r.hasOwnProperty(u)&&l!==i&&(l!=null||i!=null))if(u==="style")if(i){for(s in i)!i.hasOwnProperty(s)||l&&l.hasOwnProperty(s)||(a||(a={}),a[s]="");for(s in l)l.hasOwnProperty(s)&&i[s]!==l[s]&&(a||(a={}),a[s]=l[s])}else a||(n||(n=[]),n.push(u,a)),a=l;else u==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,i=i?i.__html:void 0,l!=null&&i!==l&&(n=n||[]).push(u,l)):u==="children"?typeof l!="string"&&typeof l!="number"||(n=n||[]).push(u,""+l):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(Gs.hasOwnProperty(u)?(l!=null&&u==="onScroll"&&ve("scroll",e),n||i===l||(n=[])):(n=n||[]).push(u,l))}a&&(n=n||[]).push("style",a);var u=n;(t.updateQueue=u)&&(t.flags|=4)}};Iy=function(e,t,a,r){a!==r&&(t.flags|=4)};function As(e,t){if(!we)switch(e.tailMode){case"hidden":t=e.tail;for(var a=null;t!==null;)t.alternate!==null&&(a=t),t=t.sibling;a===null?e.tail=null:a.sibling=null;break;case"collapsed":a=e.tail;for(var r=null;a!==null;)a.alternate!==null&&(r=a),a=a.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function nt(e){var t=e.alternate!==null&&e.alternate.child===e.child,a=0,r=0;if(t)for(var o=e.child;o!==null;)a|=o.lanes|o.childLanes,r|=o.subtreeFlags&14680064,r|=o.flags&14680064,o.return=e,o=o.sibling;else for(o=e.child;o!==null;)a|=o.lanes|o.childLanes,r|=o.subtreeFlags,r|=o.flags,o.return=e,o=o.sibling;return e.subtreeFlags|=r,e.childLanes=a,t}function Ew(e,t,a){var r=t.pendingProps;switch(up(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return nt(t),null;case 1:return Ct(t.type)&&$l(),nt(t),null;case 3:return r=t.stateNode,un(),Le(Lt),Le(it),yp(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(wl(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,sa!==null&&(Gf(sa),sa=null))),Of(e,t),nt(t),null;case 5:xp(t);var o=oo(ri.current);if(a=t.type,e!==null&&t.stateNode!=null)Sy(e,t,a,r,o),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(D(166));return nt(t),null}if(e=oo(va.current),wl(t)){r=t.stateNode,a=t.type;var n=t.memoizedProps;switch(r[xa]=t,r[ti]=n,e=(t.mode&1)!==0,a){case"dialog":ve("cancel",r),ve("close",r);break;case"iframe":case"object":case"embed":ve("load",r);break;case"video":case"audio":for(o=0;o<Fs.length;o++)ve(Fs[o],r);break;case"source":ve("error",r);break;case"img":case"image":case"link":ve("error",r),ve("load",r);break;case"details":ve("toggle",r);break;case"input":_h(r,n),ve("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!n.multiple},ve("invalid",r);break;case"textarea":Hh(r,n),ve("invalid",r)}df(a,n),o=null;for(var s in n)if(n.hasOwnProperty(s)){var i=n[s];s==="children"?typeof i=="string"?r.textContent!==i&&(n.suppressHydrationWarning!==!0&&Il(r.textContent,i,e),o=["children",i]):typeof i=="number"&&r.textContent!==""+i&&(n.suppressHydrationWarning!==!0&&Il(r.textContent,i,e),o=["children",""+i]):Gs.hasOwnProperty(s)&&i!=null&&s==="onScroll"&&ve("scroll",r)}switch(a){case"input":cl(r),zh(r,n,!0);break;case"textarea":cl(r),qh(r);break;case"select":case"option":break;default:typeof n.onClick=="function"&&(r.onclick=Kl)}r=o,t.updateQueue=r,r!==null&&(t.flags|=4)}else{s=o.nodeType===9?o:o.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=Yg(a)),e==="http://www.w3.org/1999/xhtml"?a==="script"?(e=s.createElement("div"),e.innerHTML="<script></script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=s.createElement(a,{is:r.is}):(e=s.createElement(a),a==="select"&&(s=e,r.multiple?s.multiple=!0:r.size&&(s.size=r.size))):e=s.createElementNS(e,a),e[xa]=t,e[ti]=r,Cy(e,t,!1,!1),t.stateNode=e;e:{switch(s=cf(a,r),a){case"dialog":ve("cancel",e),ve("close",e),o=r;break;case"iframe":case"object":case"embed":ve("load",e),o=r;break;case"video":case"audio":for(o=0;o<Fs.length;o++)ve(Fs[o],e);o=r;break;case"source":ve("error",e),o=r;break;case"img":case"image":case"link":ve("error",e),ve("load",e),o=r;break;case"details":ve("toggle",e),o=r;break;case"input":_h(e,r),o=of(e,r),ve("invalid",e);break;case"option":o=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},o=Pe({},r,{value:void 0}),ve("invalid",e);break;case"textarea":Hh(e,r),o=lf(e,r),ve("invalid",e);break;default:o=r}df(a,o),i=o;for(n in i)if(i.hasOwnProperty(n)){var l=i[n];n==="style"?ex(e,l):n==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&Zg(e,l)):n==="children"?typeof l=="string"?(a!=="textarea"||l!=="")&&js(e,l):typeof l=="number"&&js(e,""+l):n!=="suppressContentEditableWarning"&&n!=="suppressHydrationWarning"&&n!=="autoFocus"&&(Gs.hasOwnProperty(n)?l!=null&&n==="onScroll"&&ve("scroll",e):l!=null&&$f(e,n,l,s))}switch(a){case"input":cl(e),zh(e,r,!1);break;case"textarea":cl(e),qh(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Sr(r.value));break;case"select":e.multiple=!!r.multiple,n=r.value,n!=null?Zo(e,!!r.multiple,n,!1):r.defaultValue!=null&&Zo(e,!!r.multiple,r.defaultValue,!0);break;default:typeof o.onClick=="function"&&(e.onclick=Kl)}switch(a){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}}r&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return nt(t),null;case 6:if(e&&t.stateNode!=null)Iy(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(D(166));if(a=oo(ri.current),oo(va.current),wl(t)){if(r=t.stateNode,a=t.memoizedProps,r[xa]=t,(n=r.nodeValue!==a)&&(e=Nt,e!==null))switch(e.tag){case 3:Il(r.nodeValue,a,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Il(r.nodeValue,a,(e.mode&1)!==0)}n&&(t.flags|=4)}else r=(a.nodeType===9?a:a.ownerDocument).createTextNode(r),r[xa]=t,t.stateNode=r}return nt(t),null;case 13:if(Le(ke),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(we&&Mt!==null&&(t.mode&1)!==0&&(t.flags&128)===0)zx(),sn(),t.flags|=98560,n=!1;else if(n=wl(t),r!==null&&r.dehydrated!==null){if(e===null){if(!n)throw Error(D(318));if(n=t.memoizedState,n=n!==null?n.dehydrated:null,!n)throw Error(D(317));n[xa]=t}else sn(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;nt(t),n=!1}else sa!==null&&(Gf(sa),sa=null),n=!0;if(!n)return t.flags&65536?t:null}return(t.flags&128)!==0?(t.lanes=a,t):(r=r!==null,r!==(e!==null&&e.memoizedState!==null)&&r&&(t.child.flags|=8192,(t.mode&1)!==0&&(e===null||(ke.current&1)!==0?ze===0&&(ze=3):Rp())),t.updateQueue!==null&&(t.flags|=4),nt(t),null);case 4:return un(),Of(e,t),e===null&&Js(t.stateNode.containerInfo),nt(t),null;case 10:return pp(t.type._context),nt(t),null;case 17:return Ct(t.type)&&$l(),nt(t),null;case 19:if(Le(ke),n=t.memoizedState,n===null)return nt(t),null;if(r=(t.flags&128)!==0,s=n.rendering,s===null)if(r)As(n,!1);else{if(ze!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(s=tu(e),s!==null){for(t.flags|=128,As(n,!1),r=s.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=a,a=t.child;a!==null;)n=a,e=r,n.flags&=14680066,s=n.alternate,s===null?(n.childLanes=0,n.lanes=e,n.child=null,n.subtreeFlags=0,n.memoizedProps=null,n.memoizedState=null,n.updateQueue=null,n.dependencies=null,n.stateNode=null):(n.childLanes=s.childLanes,n.lanes=s.lanes,n.child=s.child,n.subtreeFlags=0,n.deletions=null,n.memoizedProps=s.memoizedProps,n.memoizedState=s.memoizedState,n.updateQueue=s.updateQueue,n.type=s.type,e=s.dependencies,n.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),a=a.sibling;return xe(ke,ke.current&1|2),t.child}e=e.sibling}n.tail!==null&&Ne()>cn&&(t.flags|=128,r=!0,As(n,!1),t.lanes=4194304)}else{if(!r)if(e=tu(s),e!==null){if(t.flags|=128,r=!0,a=e.updateQueue,a!==null&&(t.updateQueue=a,t.flags|=4),As(n,!0),n.tail===null&&n.tailMode==="hidden"&&!s.alternate&&!we)return nt(t),null}else 2*Ne()-n.renderingStartTime>cn&&a!==1073741824&&(t.flags|=128,r=!0,As(n,!1),t.lanes=4194304);n.isBackwards?(s.sibling=t.child,t.child=s):(a=n.last,a!==null?a.sibling=s:t.child=s,n.last=s)}return n.tail!==null?(t=n.tail,n.rendering=t,n.tail=t.sibling,n.renderingStartTime=Ne(),t.sibling=null,a=ke.current,xe(ke,r?a&1|2:a&1),t):(nt(t),null);case 22:case 23:return Ap(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&(t.mode&1)!==0?(Dt&1073741824)!==0&&(nt(t),t.subtreeFlags&6&&(t.flags|=8192)):nt(t),null;case 24:return null;case 25:return null}throw Error(D(156,t.tag))}function Fw(e,t){switch(up(t),t.tag){case 1:return Ct(t.type)&&$l(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return un(),Le(Lt),Le(it),yp(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 5:return xp(t),null;case 13:if(Le(ke),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(D(340));sn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Le(ke),null;case 4:return un(),null;case 10:return pp(t.type._context),null;case 22:case 23:return Ap(),null;case 24:return null;default:return null}}var Pl=!1,st=!1,Bw=typeof WeakSet=="function"?WeakSet:Set,O=null;function Qo(e,t){var a=e.ref;if(a!==null)if(typeof a=="function")try{a(null)}catch(r){Re(e,t,r)}else a.current=null}function Vf(e,t,a){try{a()}catch(r){Re(e,t,r)}}var Ng=!1;function Ow(e,t){if(Cf=Wl,e=Tx(),ip(e)){if("selectionStart"in e)var a={start:e.selectionStart,end:e.selectionEnd};else e:{a=(a=e.ownerDocument)&&a.defaultView||window;var r=a.getSelection&&a.getSelection();if(r&&r.rangeCount!==0){a=r.anchorNode;var o=r.anchorOffset,n=r.focusNode;r=r.focusOffset;try{a.nodeType,n.nodeType}catch{a=null;break e}var s=0,i=-1,l=-1,u=0,d=0,c=e,p=null;t:for(;;){for(var g;c!==a||o!==0&&c.nodeType!==3||(i=s+o),c!==n||r!==0&&c.nodeType!==3||(l=s+r),c.nodeType===3&&(s+=c.nodeValue.length),(g=c.firstChild)!==null;)p=c,c=g;for(;;){if(c===e)break t;if(p===a&&++u===o&&(i=s),p===n&&++d===r&&(l=s),(g=c.nextSibling)!==null)break;c=p,p=c.parentNode}c=g}a=i===-1||l===-1?null:{start:i,end:l}}else a=null}a=a||{start:0,end:0}}else a=null;for(Sf={focusedElem:e,selectionRange:a},Wl=!1,O=t;O!==null;)if(t=O,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,O=e;else for(;O!==null;){t=O;try{var C=t.alternate;if((t.flags&1024)!==0)switch(t.tag){case 0:case 11:case 15:break;case 1:if(C!==null){var L=C.memoizedProps,S=C.memoizedState,h=t.stateNode,m=h.getSnapshotBeforeUpdate(t.elementType===t.type?L:oa(t.type,L),S);h.__reactInternalSnapshotBeforeUpdate=m}break;case 3:var x=t.stateNode.containerInfo;x.nodeType===1?x.textContent="":x.nodeType===9&&x.documentElement&&x.removeChild(x.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(D(163))}}catch(I){Re(t,t.return,I)}if(e=t.sibling,e!==null){e.return=t.return,O=e;break}O=t.return}return C=Ng,Ng=!1,C}function Hs(e,t,a){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var o=r=r.next;do{if((o.tag&e)===e){var n=o.destroy;o.destroy=void 0,n!==void 0&&Vf(t,a,n)}o=o.next}while(o!==r)}}function xu(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var a=t=t.next;do{if((a.tag&e)===e){var r=a.create;a.destroy=r()}a=a.next}while(a!==t)}}function Uf(e){var t=e.ref;if(t!==null){var a=e.stateNode;switch(e.tag){case 5:e=a;break;default:e=a}typeof t=="function"?t(e):t.current=e}}function wy(e){var t=e.alternate;t!==null&&(e.alternate=null,wy(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[xa],delete t[ti],delete t[kf],delete t[vw],delete t[Lw])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function ky(e){return e.tag===5||e.tag===3||e.tag===4}function Eg(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||ky(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.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 _f(e,t,a){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?a.nodeType===8?a.parentNode.insertBefore(e,t):a.insertBefore(e,t):(a.nodeType===8?(t=a.parentNode,t.insertBefore(e,a)):(t=a,t.appendChild(e)),a=a._reactRootContainer,a!=null||t.onclick!==null||(t.onclick=Kl));else if(r!==4&&(e=e.child,e!==null))for(_f(e,t,a),e=e.sibling;e!==null;)_f(e,t,a),e=e.sibling}function zf(e,t,a){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?a.insertBefore(e,t):a.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(zf(e,t,a),e=e.sibling;e!==null;)zf(e,t,a),e=e.sibling}var Qe=null,na=!1;function ir(e,t,a){for(a=a.child;a!==null;)by(e,t,a),a=a.sibling}function by(e,t,a){if(ya&&typeof ya.onCommitFiberUnmount=="function")try{ya.onCommitFiberUnmount(uu,a)}catch{}switch(a.tag){case 5:st||Qo(a,t);case 6:var r=Qe,o=na;Qe=null,ir(e,t,a),Qe=r,na=o,Qe!==null&&(na?(e=Qe,a=a.stateNode,e.nodeType===8?e.parentNode.removeChild(a):e.removeChild(a)):Qe.removeChild(a.stateNode));break;case 18:Qe!==null&&(na?(e=Qe,a=a.stateNode,e.nodeType===8?qc(e.parentNode,a):e.nodeType===1&&qc(e,a),Qs(e)):qc(Qe,a.stateNode));break;case 4:r=Qe,o=na,Qe=a.stateNode.containerInfo,na=!0,ir(e,t,a),Qe=r,na=o;break;case 0:case 11:case 14:case 15:if(!st&&(r=a.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){o=r=r.next;do{var n=o,s=n.destroy;n=n.tag,s!==void 0&&((n&2)!==0||(n&4)!==0)&&Vf(a,t,s),o=o.next}while(o!==r)}ir(e,t,a);break;case 1:if(!st&&(Qo(a,t),r=a.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=a.memoizedProps,r.state=a.memoizedState,r.componentWillUnmount()}catch(i){Re(a,t,i)}ir(e,t,a);break;case 21:ir(e,t,a);break;case 22:a.mode&1?(st=(r=st)||a.memoizedState!==null,ir(e,t,a),st=r):ir(e,t,a);break;default:ir(e,t,a)}}function Fg(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var a=e.stateNode;a===null&&(a=e.stateNode=new Bw),t.forEach(function(r){var o=jw.bind(null,e,r);a.has(r)||(a.add(r),r.then(o,o))})}}function ra(e,t){var a=t.deletions;if(a!==null)for(var r=0;r<a.length;r++){var o=a[r];try{var n=e,s=t,i=s;e:for(;i!==null;){switch(i.tag){case 5:Qe=i.stateNode,na=!1;break e;case 3:Qe=i.stateNode.containerInfo,na=!0;break e;case 4:Qe=i.stateNode.containerInfo,na=!0;break e}i=i.return}if(Qe===null)throw Error(D(160));by(n,s,o),Qe=null,na=!1;var l=o.alternate;l!==null&&(l.return=null),o.return=null}catch(u){Re(o,t,u)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Py(t,e),t=t.sibling}function Py(e,t){var a=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(ra(t,e),ha(e),r&4){try{Hs(3,e,e.return),xu(3,e)}catch(L){Re(e,e.return,L)}try{Hs(5,e,e.return)}catch(L){Re(e,e.return,L)}}break;case 1:ra(t,e),ha(e),r&512&&a!==null&&Qo(a,a.return);break;case 5:if(ra(t,e),ha(e),r&512&&a!==null&&Qo(a,a.return),e.flags&32){var o=e.stateNode;try{js(o,"")}catch(L){Re(e,e.return,L)}}if(r&4&&(o=e.stateNode,o!=null)){var n=e.memoizedProps,s=a!==null?a.memoizedProps:n,i=e.type,l=e.updateQueue;if(e.updateQueue=null,l!==null)try{i==="input"&&n.type==="radio"&&n.name!=null&&Xg(o,n),cf(i,s);var u=cf(i,n);for(s=0;s<l.length;s+=2){var d=l[s],c=l[s+1];d==="style"?ex(o,c):d==="dangerouslySetInnerHTML"?Zg(o,c):d==="children"?js(o,c):$f(o,d,c,u)}switch(i){case"input":nf(o,n);break;case"textarea":Qg(o,n);break;case"select":var p=o._wrapperState.wasMultiple;o._wrapperState.wasMultiple=!!n.multiple;var g=n.value;g!=null?Zo(o,!!n.multiple,g,!1):p!==!!n.multiple&&(n.defaultValue!=null?Zo(o,!!n.multiple,n.defaultValue,!0):Zo(o,!!n.multiple,n.multiple?[]:"",!1))}o[ti]=n}catch(L){Re(e,e.return,L)}}break;case 6:if(ra(t,e),ha(e),r&4){if(e.stateNode===null)throw Error(D(162));o=e.stateNode,n=e.memoizedProps;try{o.nodeValue=n}catch(L){Re(e,e.return,L)}}break;case 3:if(ra(t,e),ha(e),r&4&&a!==null&&a.memoizedState.isDehydrated)try{Qs(t.containerInfo)}catch(L){Re(e,e.return,L)}break;case 4:ra(t,e),ha(e);break;case 13:ra(t,e),ha(e),o=e.child,o.flags&8192&&(n=o.memoizedState!==null,o.stateNode.isHidden=n,!n||o.alternate!==null&&o.alternate.memoizedState!==null||(Pp=Ne())),r&4&&Fg(e);break;case 22:if(d=a!==null&&a.memoizedState!==null,e.mode&1?(st=(u=st)||d,ra(t,e),st=u):ra(t,e),ha(e),r&8192){if(u=e.memoizedState!==null,(e.stateNode.isHidden=u)&&!d&&(e.mode&1)!==0)for(O=e,d=e.child;d!==null;){for(c=O=d;O!==null;){switch(p=O,g=p.child,p.tag){case 0:case 11:case 14:case 15:Hs(4,p,p.return);break;case 1:Qo(p,p.return);var C=p.stateNode;if(typeof C.componentWillUnmount=="function"){r=p,a=p.return;try{t=r,C.props=t.memoizedProps,C.state=t.memoizedState,C.componentWillUnmount()}catch(L){Re(r,a,L)}}break;case 5:Qo(p,p.return);break;case 22:if(p.memoizedState!==null){Og(c);continue}}g!==null?(g.return=p,O=g):Og(c)}d=d.sibling}e:for(d=null,c=e;;){if(c.tag===5){if(d===null){d=c;try{o=c.stateNode,u?(n=o.style,typeof n.setProperty=="function"?n.setProperty("display","none","important"):n.display="none"):(i=c.stateNode,l=c.memoizedProps.style,s=l!=null&&l.hasOwnProperty("display")?l.display:null,i.style.display=Jg("display",s))}catch(L){Re(e,e.return,L)}}}else if(c.tag===6){if(d===null)try{c.stateNode.nodeValue=u?"":c.memoizedProps}catch(L){Re(e,e.return,L)}}else if((c.tag!==22&&c.tag!==23||c.memoizedState===null||c===e)&&c.child!==null){c.child.return=c,c=c.child;continue}if(c===e)break e;for(;c.sibling===null;){if(c.return===null||c.return===e)break e;d===c&&(d=null),c=c.return}d===c&&(d=null),c.sibling.return=c.return,c=c.sibling}}break;case 19:ra(t,e),ha(e),r&4&&Fg(e);break;case 21:break;default:ra(t,e),ha(e)}}function ha(e){var t=e.flags;if(t&2){try{e:{for(var a=e.return;a!==null;){if(ky(a)){var r=a;break e}a=a.return}throw Error(D(160))}switch(r.tag){case 5:var o=r.stateNode;r.flags&32&&(js(o,""),r.flags&=-33);var n=Eg(e);zf(e,n,o);break;case 3:case 4:var s=r.stateNode.containerInfo,i=Eg(e);_f(e,i,s);break;default:throw Error(D(161))}}catch(l){Re(e,e.return,l)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Vw(e,t,a){O=e,Ty(e,t,a)}function Ty(e,t,a){for(var r=(e.mode&1)!==0;O!==null;){var o=O,n=o.child;if(o.tag===22&&r){var s=o.memoizedState!==null||Pl;if(!s){var i=o.alternate,l=i!==null&&i.memoizedState!==null||st;i=Pl;var u=st;if(Pl=s,(st=l)&&!u)for(O=o;O!==null;)s=O,l=s.child,s.tag===22&&s.memoizedState!==null?Vg(o):l!==null?(l.return=s,O=l):Vg(o);for(;n!==null;)O=n,Ty(n,t,a),n=n.sibling;O=o,Pl=i,st=u}Bg(e,t,a)}else(o.subtreeFlags&8772)!==0&&n!==null?(n.return=o,O=n):Bg(e,t,a)}}function Bg(e){for(;O!==null;){var t=O;if((t.flags&8772)!==0){var a=t.alternate;try{if((t.flags&8772)!==0)switch(t.tag){case 0:case 11:case 15:st||xu(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!st)if(a===null)r.componentDidMount();else{var o=t.elementType===t.type?a.memoizedProps:oa(t.type,a.memoizedProps);r.componentDidUpdate(o,a.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var n=t.updateQueue;n!==null&&Lg(t,n,r);break;case 3:var s=t.updateQueue;if(s!==null){if(a=null,t.child!==null)switch(t.child.tag){case 5:a=t.child.stateNode;break;case 1:a=t.child.stateNode}Lg(t,s,a)}break;case 5:var i=t.stateNode;if(a===null&&t.flags&4){a=i;var l=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":l.autoFocus&&a.focus();break;case"img":l.src&&(a.src=l.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var u=t.alternate;if(u!==null){var d=u.memoizedState;if(d!==null){var c=d.dehydrated;c!==null&&Qs(c)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(D(163))}st||t.flags&512&&Uf(t)}catch(p){Re(t,t.return,p)}}if(t===e){O=null;break}if(a=t.sibling,a!==null){a.return=t.return,O=a;break}O=t.return}}function Og(e){for(;O!==null;){var t=O;if(t===e){O=null;break}var a=t.sibling;if(a!==null){a.return=t.return,O=a;break}O=t.return}}function Vg(e){for(;O!==null;){var t=O;try{switch(t.tag){case 0:case 11:case 15:var a=t.return;try{xu(4,t)}catch(l){Re(t,a,l)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var o=t.return;try{r.componentDidMount()}catch(l){Re(t,o,l)}}var n=t.return;try{Uf(t)}catch(l){Re(t,n,l)}break;case 5:var s=t.return;try{Uf(t)}catch(l){Re(t,s,l)}}}catch(l){Re(t,t.return,l)}if(t===e){O=null;break}var i=t.sibling;if(i!==null){i.return=t.return,O=i;break}O=t.return}}var Uw=Math.ceil,ou=qa.ReactCurrentDispatcher,kp=qa.ReactCurrentOwner,Qt=qa.ReactCurrentBatchConfig,le=0,Ke=null,Oe=null,Ye=0,Dt=0,Yo=kr(0),ze=0,ii=null,co=0,yu=0,bp=0,qs=null,yt=null,Pp=0,cn=1/0,Ea=null,nu=!1,Hf=null,vr=null,Tl=!1,pr=null,su=0,Ws=0,qf=null,Bl=-1,Ol=0;function pt(){return(le&6)!==0?Ne():Bl!==-1?Bl:Bl=Ne()}function Lr(e){return(e.mode&1)===0?1:(le&2)!==0&&Ye!==0?Ye&-Ye:Sw.transition!==null?(Ol===0&&(Ol=fx()),Ol):(e=pe,e!==0||(e=window.event,e=e===void 0?16:vx(e.type)),e)}function la(e,t,a,r){if(50<Ws)throw Ws=0,qf=null,Error(D(185));li(e,a,r),((le&2)===0||e!==Ke)&&(e===Ke&&((le&2)===0&&(yu|=a),ze===4&&cr(e,Ye)),St(e,r),a===1&&le===0&&(t.mode&1)===0&&(cn=Ne()+500,mu&&br()))}function St(e,t){var a=e.callbackNode;wI(e,t);var r=ql(e,e===Ke?Ye:0);if(r===0)a!==null&&jh(a),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(a!=null&&jh(a),t===1)e.tag===0?Cw(Ug.bind(null,e)):Vx(Ug.bind(null,e)),xw(function(){(le&6)===0&&br()}),a=null;else{switch(px(r)){case 1:a=Jf;break;case 4:a=dx;break;case 16:a=Hl;break;case 536870912:a=cx;break;default:a=Hl}a=By(a,Ay.bind(null,e))}e.callbackPriority=t,e.callbackNode=a}}function Ay(e,t){if(Bl=-1,Ol=0,(le&6)!==0)throw Error(D(327));var a=e.callbackNode;if(rn()&&e.callbackNode!==a)return null;var r=ql(e,e===Ke?Ye:0);if(r===0)return null;if((r&30)!==0||(r&e.expiredLanes)!==0||t)t=iu(e,r);else{t=r;var o=le;le|=2;var n=Dy();(Ke!==e||Ye!==t)&&(Ea=null,cn=Ne()+500,no(e,t));do try{Hw();break}catch(i){Ry(e,i)}while(!0);fp(),ou.current=n,le=o,Oe!==null?t=0:(Ke=null,Ye=0,t=ze)}if(t!==0){if(t===2&&(o=gf(e),o!==0&&(r=o,t=Wf(e,o))),t===1)throw a=ii,no(e,0),cr(e,r),St(e,Ne()),a;if(t===6)cr(e,r);else{if(o=e.current.alternate,(r&30)===0&&!_w(o)&&(t=iu(e,r),t===2&&(n=gf(e),n!==0&&(r=n,t=Wf(e,n))),t===1))throw a=ii,no(e,0),cr(e,r),St(e,Ne()),a;switch(e.finishedWork=o,e.finishedLanes=r,t){case 0:case 1:throw Error(D(345));case 2:to(e,yt,Ea);break;case 3:if(cr(e,r),(r&130023424)===r&&(t=Pp+500-Ne(),10<t)){if(ql(e,0)!==0)break;if(o=e.suspendedLanes,(o&r)!==r){pt(),e.pingedLanes|=e.suspendedLanes&o;break}e.timeoutHandle=wf(to.bind(null,e,yt,Ea),t);break}to(e,yt,Ea);break;case 4:if(cr(e,r),(r&4194240)===r)break;for(t=e.eventTimes,o=-1;0<r;){var s=31-ia(r);n=1<<s,s=t[s],s>o&&(o=s),r&=~n}if(r=o,r=Ne()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*Uw(r/1960))-r,10<r){e.timeoutHandle=wf(to.bind(null,e,yt,Ea),r);break}to(e,yt,Ea);break;case 5:to(e,yt,Ea);break;default:throw Error(D(329))}}}return St(e,Ne()),e.callbackNode===a?Ay.bind(null,e):null}function Wf(e,t){var a=qs;return e.current.memoizedState.isDehydrated&&(no(e,t).flags|=256),e=iu(e,t),e!==2&&(t=yt,yt=a,t!==null&&Gf(t)),e}function Gf(e){yt===null?yt=e:yt.push.apply(yt,e)}function _w(e){for(var t=e;;){if(t.flags&16384){var a=t.updateQueue;if(a!==null&&(a=a.stores,a!==null))for(var r=0;r<a.length;r++){var o=a[r],n=o.getSnapshot;o=o.value;try{if(!ua(n(),o))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 cr(e,t){for(t&=~bp,t&=~yu,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var a=31-ia(t),r=1<<a;e[a]=-1,t&=~r}}function Ug(e){if((le&6)!==0)throw Error(D(327));rn();var t=ql(e,0);if((t&1)===0)return St(e,Ne()),null;var a=iu(e,t);if(e.tag!==0&&a===2){var r=gf(e);r!==0&&(t=r,a=Wf(e,r))}if(a===1)throw a=ii,no(e,0),cr(e,t),St(e,Ne()),a;if(a===6)throw Error(D(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,to(e,yt,Ea),St(e,Ne()),null}function Tp(e,t){var a=le;le|=1;try{return e(t)}finally{le=a,le===0&&(cn=Ne()+500,mu&&br())}}function fo(e){pr!==null&&pr.tag===0&&(le&6)===0&&rn();var t=le;le|=1;var a=Qt.transition,r=pe;try{if(Qt.transition=null,pe=1,e)return e()}finally{pe=r,Qt.transition=a,le=t,(le&6)===0&&br()}}function Ap(){Dt=Yo.current,Le(Yo)}function no(e,t){e.finishedWork=null,e.finishedLanes=0;var a=e.timeoutHandle;if(a!==-1&&(e.timeoutHandle=-1,gw(a)),Oe!==null)for(a=Oe.return;a!==null;){var r=a;switch(up(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&$l();break;case 3:un(),Le(Lt),Le(it),yp();break;case 5:xp(r);break;case 4:un();break;case 13:Le(ke);break;case 19:Le(ke);break;case 10:pp(r.type._context);break;case 22:case 23:Ap()}a=a.return}if(Ke=e,Oe=e=Cr(e.current,null),Ye=Dt=t,ze=0,ii=null,bp=yu=co=0,yt=qs=null,ro!==null){for(t=0;t<ro.length;t++)if(a=ro[t],r=a.interleaved,r!==null){a.interleaved=null;var o=r.next,n=a.pending;if(n!==null){var s=n.next;n.next=o,r.next=s}a.pending=r}ro=null}return e}function Ry(e,t){do{var a=Oe;try{if(fp(),Nl.current=ru,au){for(var r=be.memoizedState;r!==null;){var o=r.queue;o!==null&&(o.pending=null),r=r.next}au=!1}if(uo=0,je=_e=be=null,zs=!1,oi=0,kp.current=null,a===null||a.return===null){ze=1,ii=t,Oe=null;break}e:{var n=e,s=a.return,i=a,l=t;if(t=Ye,i.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){var u=l,d=i,c=d.tag;if((d.mode&1)===0&&(c===0||c===11||c===15)){var p=d.alternate;p?(d.updateQueue=p.updateQueue,d.memoizedState=p.memoizedState,d.lanes=p.lanes):(d.updateQueue=null,d.memoizedState=null)}var g=bg(s);if(g!==null){g.flags&=-257,Pg(g,s,i,n,t),g.mode&1&&kg(n,u,t),t=g,l=u;var C=t.updateQueue;if(C===null){var L=new Set;L.add(l),t.updateQueue=L}else C.add(l);break e}else{if((t&1)===0){kg(n,u,t),Rp();break e}l=Error(D(426))}}else if(we&&i.mode&1){var S=bg(s);if(S!==null){(S.flags&65536)===0&&(S.flags|=256),Pg(S,s,i,n,t),dp(dn(l,i));break e}}n=l=dn(l,i),ze!==4&&(ze=2),qs===null?qs=[n]:qs.push(n),n=s;do{switch(n.tag){case 3:n.flags|=65536,t&=-t,n.lanes|=t;var h=py(n,l,t);vg(n,h);break e;case 1:i=l;var m=n.type,x=n.stateNode;if((n.flags&128)===0&&(typeof m.getDerivedStateFromError=="function"||x!==null&&typeof x.componentDidCatch=="function"&&(vr===null||!vr.has(x)))){n.flags|=65536,t&=-t,n.lanes|=t;var I=my(n,i,t);vg(n,I);break e}}n=n.return}while(n!==null)}Ny(a)}catch(k){t=k,Oe===a&&a!==null&&(Oe=a=a.return);continue}break}while(!0)}function Dy(){var e=ou.current;return ou.current=ru,e===null?ru:e}function Rp(){(ze===0||ze===3||ze===2)&&(ze=4),Ke===null||(co&268435455)===0&&(yu&268435455)===0||cr(Ke,Ye)}function iu(e,t){var a=le;le|=2;var r=Dy();(Ke!==e||Ye!==t)&&(Ea=null,no(e,t));do try{zw();break}catch(o){Ry(e,o)}while(!0);if(fp(),le=a,ou.current=r,Oe!==null)throw Error(D(261));return Ke=null,Ye=0,ze}function zw(){for(;Oe!==null;)My(Oe)}function Hw(){for(;Oe!==null&&!hI();)My(Oe)}function My(e){var t=Fy(e.alternate,e,Dt);e.memoizedProps=e.pendingProps,t===null?Ny(e):Oe=t,kp.current=null}function Ny(e){var t=e;do{var a=t.alternate;if(e=t.return,(t.flags&32768)===0){if(a=Ew(a,t,Dt),a!==null){Oe=a;return}}else{if(a=Fw(a,t),a!==null){a.flags&=32767,Oe=a;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{ze=6,Oe=null;return}}if(t=t.sibling,t!==null){Oe=t;return}Oe=t=e}while(t!==null);ze===0&&(ze=5)}function to(e,t,a){var r=pe,o=Qt.transition;try{Qt.transition=null,pe=1,qw(e,t,a,r)}finally{Qt.transition=o,pe=r}return null}function qw(e,t,a,r){do rn();while(pr!==null);if((le&6)!==0)throw Error(D(327));a=e.finishedWork;var o=e.finishedLanes;if(a===null)return null;if(e.finishedWork=null,e.finishedLanes=0,a===e.current)throw Error(D(177));e.callbackNode=null,e.callbackPriority=0;var n=a.lanes|a.childLanes;if(kI(e,n),e===Ke&&(Oe=Ke=null,Ye=0),(a.subtreeFlags&2064)===0&&(a.flags&2064)===0||Tl||(Tl=!0,By(Hl,function(){return rn(),null})),n=(a.flags&15990)!==0,(a.subtreeFlags&15990)!==0||n){n=Qt.transition,Qt.transition=null;var s=pe;pe=1;var i=le;le|=4,kp.current=null,Ow(e,a),Py(a,e),cw(Sf),Wl=!!Cf,Sf=Cf=null,e.current=a,Vw(a,e,o),gI(),le=i,pe=s,Qt.transition=n}else e.current=a;if(Tl&&(Tl=!1,pr=e,su=o),n=e.pendingLanes,n===0&&(vr=null),vI(a.stateNode,r),St(e,Ne()),t!==null)for(r=e.onRecoverableError,a=0;a<t.length;a++)o=t[a],r(o.value,{componentStack:o.stack,digest:o.digest});if(nu)throw nu=!1,e=Hf,Hf=null,e;return(su&1)!==0&&e.tag!==0&&rn(),n=e.pendingLanes,(n&1)!==0?e===qf?Ws++:(Ws=0,qf=e):Ws=0,br(),null}function rn(){if(pr!==null){var e=px(su),t=Qt.transition,a=pe;try{if(Qt.transition=null,pe=16>e?16:e,pr===null)var r=!1;else{if(e=pr,pr=null,su=0,(le&6)!==0)throw Error(D(331));var o=le;for(le|=4,O=e.current;O!==null;){var n=O,s=n.child;if((O.flags&16)!==0){var i=n.deletions;if(i!==null){for(var l=0;l<i.length;l++){var u=i[l];for(O=u;O!==null;){var d=O;switch(d.tag){case 0:case 11:case 15:Hs(8,d,n)}var c=d.child;if(c!==null)c.return=d,O=c;else for(;O!==null;){d=O;var p=d.sibling,g=d.return;if(wy(d),d===u){O=null;break}if(p!==null){p.return=g,O=p;break}O=g}}}var C=n.alternate;if(C!==null){var L=C.child;if(L!==null){C.child=null;do{var S=L.sibling;L.sibling=null,L=S}while(L!==null)}}O=n}}if((n.subtreeFlags&2064)!==0&&s!==null)s.return=n,O=s;else e:for(;O!==null;){if(n=O,(n.flags&2048)!==0)switch(n.tag){case 0:case 11:case 15:Hs(9,n,n.return)}var h=n.sibling;if(h!==null){h.return=n.return,O=h;break e}O=n.return}}var m=e.current;for(O=m;O!==null;){s=O;var x=s.child;if((s.subtreeFlags&2064)!==0&&x!==null)x.return=s,O=x;else e:for(s=m;O!==null;){if(i=O,(i.flags&2048)!==0)try{switch(i.tag){case 0:case 11:case 15:xu(9,i)}}catch(k){Re(i,i.return,k)}if(i===s){O=null;break e}var I=i.sibling;if(I!==null){I.return=i.return,O=I;break e}O=i.return}}if(le=o,br(),ya&&typeof ya.onPostCommitFiberRoot=="function")try{ya.onPostCommitFiberRoot(uu,e)}catch{}r=!0}return r}finally{pe=a,Qt.transition=t}}return!1}function _g(e,t,a){t=dn(a,t),t=py(e,t,1),e=yr(e,t,1),t=pt(),e!==null&&(li(e,1,t),St(e,t))}function Re(e,t,a){if(e.tag===3)_g(e,e,a);else for(;t!==null;){if(t.tag===3){_g(t,e,a);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(vr===null||!vr.has(r))){e=dn(a,e),e=my(t,e,1),t=yr(t,e,1),e=pt(),t!==null&&(li(t,1,e),St(t,e));break}}t=t.return}}function Ww(e,t,a){var r=e.pingCache;r!==null&&r.delete(t),t=pt(),e.pingedLanes|=e.suspendedLanes&a,Ke===e&&(Ye&a)===a&&(ze===4||ze===3&&(Ye&130023424)===Ye&&500>Ne()-Pp?no(e,0):bp|=a),St(e,t)}function Ey(e,t){t===0&&((e.mode&1)===0?t=1:(t=ml,ml<<=1,(ml&130023424)===0&&(ml=4194304)));var a=pt();e=za(e,t),e!==null&&(li(e,t,a),St(e,a))}function Gw(e){var t=e.memoizedState,a=0;t!==null&&(a=t.retryLane),Ey(e,a)}function jw(e,t){var a=0;switch(e.tag){case 13:var r=e.stateNode,o=e.memoizedState;o!==null&&(a=o.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(D(314))}r!==null&&r.delete(t),Ey(e,a)}var Fy;Fy=function(e,t,a){if(e!==null)if(e.memoizedProps!==t.pendingProps||Lt.current)vt=!0;else{if((e.lanes&a)===0&&(t.flags&128)===0)return vt=!1,Nw(e,t,a);vt=(e.flags&131072)!==0}else vt=!1,we&&(t.flags&1048576)!==0&&Ux(t,Yl,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Fl(e,t),e=t.pendingProps;var o=nn(t,it.current);an(t,a),o=Lp(null,t,r,e,o,a);var n=Cp();return t.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Ct(r)?(n=!0,Xl(t)):n=!1,t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,hp(t),o.updater=gu,t.stateNode=o,o._reactInternals=t,Df(t,r,e,a),t=Ef(null,t,r,!0,n,a)):(t.tag=0,we&&n&&lp(t),ft(null,t,o,a),t=t.child),t;case 16:r=t.elementType;e:{switch(Fl(e,t),e=t.pendingProps,o=r._init,r=o(r._payload),t.type=r,o=t.tag=$w(r),e=oa(r,e),o){case 0:t=Nf(null,t,r,e,a);break e;case 1:t=Rg(null,t,r,e,a);break e;case 11:t=Tg(null,t,r,e,a);break e;case 14:t=Ag(null,t,r,oa(r.type,e),a);break e}throw Error(D(306,r,""))}return t;case 0:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:oa(r,o),Nf(e,t,r,o,a);case 1:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:oa(r,o),Rg(e,t,r,o,a);case 3:e:{if(yy(t),e===null)throw Error(D(387));r=t.pendingProps,n=t.memoizedState,o=n.element,Gx(e,t),eu(t,r,null,a);var s=t.memoizedState;if(r=s.element,n.isDehydrated)if(n={element:r,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=n,t.memoizedState=n,t.flags&256){o=dn(Error(D(423)),t),t=Dg(e,t,r,a,o);break e}else if(r!==o){o=dn(Error(D(424)),t),t=Dg(e,t,r,a,o);break e}else for(Mt=xr(t.stateNode.containerInfo.firstChild),Nt=t,we=!0,sa=null,a=qx(t,null,r,a),t.child=a;a;)a.flags=a.flags&-3|4096,a=a.sibling;else{if(sn(),r===o){t=Ha(e,t,a);break e}ft(e,t,r,a)}t=t.child}return t;case 5:return jx(t),e===null&&Tf(t),r=t.type,o=t.pendingProps,n=e!==null?e.memoizedProps:null,s=o.children,If(r,o)?s=null:n!==null&&If(r,n)&&(t.flags|=32),xy(e,t),ft(e,t,s,a),t.child;case 6:return e===null&&Tf(t),null;case 13:return vy(e,t,a);case 4:return gp(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=ln(t,null,r,a):ft(e,t,r,a),t.child;case 11:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:oa(r,o),Tg(e,t,r,o,a);case 7:return ft(e,t,t.pendingProps,a),t.child;case 8:return ft(e,t,t.pendingProps.children,a),t.child;case 12:return ft(e,t,t.pendingProps.children,a),t.child;case 10:e:{if(r=t.type._context,o=t.pendingProps,n=t.memoizedProps,s=o.value,xe(Zl,r._currentValue),r._currentValue=s,n!==null)if(ua(n.value,s)){if(n.children===o.children&&!Lt.current){t=Ha(e,t,a);break e}}else for(n=t.child,n!==null&&(n.return=t);n!==null;){var i=n.dependencies;if(i!==null){s=n.child;for(var l=i.firstContext;l!==null;){if(l.context===r){if(n.tag===1){l=Va(-1,a&-a),l.tag=2;var u=n.updateQueue;if(u!==null){u=u.shared;var d=u.pending;d===null?l.next=l:(l.next=d.next,d.next=l),u.pending=l}}n.lanes|=a,l=n.alternate,l!==null&&(l.lanes|=a),Af(n.return,a,t),i.lanes|=a;break}l=l.next}}else if(n.tag===10)s=n.type===t.type?null:n.child;else if(n.tag===18){if(s=n.return,s===null)throw Error(D(341));s.lanes|=a,i=s.alternate,i!==null&&(i.lanes|=a),Af(s,a,t),s=n.sibling}else s=n.child;if(s!==null)s.return=n;else for(s=n;s!==null;){if(s===t){s=null;break}if(n=s.sibling,n!==null){n.return=s.return,s=n;break}s=s.return}n=s}ft(e,t,o.children,a),t=t.child}return t;case 9:return o=t.type,r=t.pendingProps.children,an(t,a),o=Yt(o),r=r(o),t.flags|=1,ft(e,t,r,a),t.child;case 14:return r=t.type,o=oa(r,t.pendingProps),o=oa(r.type,o),Ag(e,t,r,o,a);case 15:return hy(e,t,t.type,t.pendingProps,a);case 17:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:oa(r,o),Fl(e,t),t.tag=1,Ct(r)?(e=!0,Xl(t)):e=!1,an(t,a),fy(t,r,o),Df(t,r,o,a),Ef(null,t,r,!0,e,a);case 19:return Ly(e,t,a);case 22:return gy(e,t,a)}throw Error(D(156,t.tag))};function By(e,t){return ux(e,t)}function Kw(e,t,a,r){this.tag=e,this.key=a,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Xt(e,t,a,r){return new Kw(e,t,a,r)}function Dp(e){return e=e.prototype,!(!e||!e.isReactComponent)}function $w(e){if(typeof e=="function")return Dp(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Qf)return 11;if(e===Yf)return 14}return 2}function Cr(e,t){var a=e.alternate;return a===null?(a=Xt(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&14680064,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}function Vl(e,t,a,r,o,n){var s=2;if(r=e,typeof e=="function")Dp(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case zo:return so(a.children,o,n,t);case Xf:s=8,o|=8;break;case ef:return e=Xt(12,a,t,o|2),e.elementType=ef,e.lanes=n,e;case tf:return e=Xt(13,a,t,o),e.elementType=tf,e.lanes=n,e;case af:return e=Xt(19,a,t,o),e.elementType=af,e.lanes=n,e;case jg:return vu(a,o,n,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Wg:s=10;break e;case Gg:s=9;break e;case Qf:s=11;break e;case Yf:s=14;break e;case lr:s=16,r=null;break e}throw Error(D(130,e==null?e:typeof e,""))}return t=Xt(s,a,t,o),t.elementType=e,t.type=r,t.lanes=n,t}function so(e,t,a,r){return e=Xt(7,e,r,t),e.lanes=a,e}function vu(e,t,a,r){return e=Xt(22,e,r,t),e.elementType=jg,e.lanes=a,e.stateNode={isHidden:!1},e}function Yc(e,t,a){return e=Xt(6,e,null,t),e.lanes=a,e}function Zc(e,t,a){return t=Xt(4,e.children!==null?e.children:[],e.key,t),t.lanes=a,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Xw(e,t,a,r,o){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Fc(0),this.expirationTimes=Fc(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Fc(0),this.identifierPrefix=r,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function Mp(e,t,a,r,o,n,s,i,l){return e=new Xw(e,t,a,i,l),t===1?(t=1,n===!0&&(t|=8)):t=0,n=Xt(3,null,null,t),e.current=n,n.stateNode=e,n.memoizedState={element:r,isDehydrated:a,cache:null,transitions:null,pendingSuspenseBoundaries:null},hp(n),e}function Qw(e,t,a){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:_o,key:r==null?null:""+r,children:e,containerInfo:t,implementation:a}}function Oy(e){if(!e)return Ir;e=e._reactInternals;e:{if(mo(e)!==e||e.tag!==1)throw Error(D(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(Ct(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(D(171))}if(e.tag===1){var a=e.type;if(Ct(a))return Ox(e,a,t)}return t}function Vy(e,t,a,r,o,n,s,i,l){return e=Mp(a,r,!0,e,o,n,s,i,l),e.context=Oy(null),a=e.current,r=pt(),o=Lr(a),n=Va(r,o),n.callback=t??null,yr(a,n,o),e.current.lanes=o,li(e,o,r),St(e,r),e}function Lu(e,t,a,r){var o=t.current,n=pt(),s=Lr(o);return a=Oy(a),t.context===null?t.context=a:t.pendingContext=a,t=Va(n,s),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=yr(o,t,s),e!==null&&(la(e,o,s,n),Ml(e,o,s)),s}function lu(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function zg(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var a=e.retryLane;e.retryLane=a!==0&&a<t?a:t}}function Np(e,t){zg(e,t),(e=e.alternate)&&zg(e,t)}function Yw(){return null}var Uy=typeof reportError=="function"?reportError:function(e){console.error(e)};function Ep(e){this._internalRoot=e}Cu.prototype.render=Ep.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(D(409));Lu(e,t,null,null)};Cu.prototype.unmount=Ep.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;fo(function(){Lu(null,e,null,null)}),t[_a]=null}};function Cu(e){this._internalRoot=e}Cu.prototype.unstable_scheduleHydration=function(e){if(e){var t=gx();e={blockedOn:null,target:e,priority:t};for(var a=0;a<dr.length&&t!==0&&t<dr[a].priority;a++);dr.splice(a,0,e),a===0&&yx(e)}};function Fp(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Su(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function Hg(){}function Zw(e,t,a,r,o){if(o){if(typeof r=="function"){var n=r;r=function(){var u=lu(s);n.call(u)}}var s=Vy(t,r,e,0,null,!1,!1,"",Hg);return e._reactRootContainer=s,e[_a]=s.current,Js(e.nodeType===8?e.parentNode:e),fo(),s}for(;o=e.lastChild;)e.removeChild(o);if(typeof r=="function"){var i=r;r=function(){var u=lu(l);i.call(u)}}var l=Mp(e,0,!1,null,null,!1,!1,"",Hg);return e._reactRootContainer=l,e[_a]=l.current,Js(e.nodeType===8?e.parentNode:e),fo(function(){Lu(t,l,a,r)}),l}function Iu(e,t,a,r,o){var n=a._reactRootContainer;if(n){var s=n;if(typeof o=="function"){var i=o;o=function(){var l=lu(s);i.call(l)}}Lu(t,s,e,o)}else s=Zw(a,t,e,o,r);return lu(s)}mx=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var a=Es(t.pendingLanes);a!==0&&(ep(t,a|1),St(t,Ne()),(le&6)===0&&(cn=Ne()+500,br()))}break;case 13:fo(function(){var r=za(e,1);if(r!==null){var o=pt();la(r,e,1,o)}}),Np(e,1)}};tp=function(e){if(e.tag===13){var t=za(e,134217728);if(t!==null){var a=pt();la(t,e,134217728,a)}Np(e,134217728)}};hx=function(e){if(e.tag===13){var t=Lr(e),a=za(e,t);if(a!==null){var r=pt();la(a,e,t,r)}Np(e,t)}};gx=function(){return pe};xx=function(e,t){var a=pe;try{return pe=e,t()}finally{pe=a}};pf=function(e,t,a){switch(t){case"input":if(nf(e,a),t=a.name,a.type==="radio"&&t!=null){for(a=e;a.parentNode;)a=a.parentNode;for(a=a.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<a.length;t++){var r=a[t];if(r!==e&&r.form===e.form){var o=pu(r);if(!o)throw Error(D(90));$g(r),nf(r,o)}}}break;case"textarea":Qg(e,a);break;case"select":t=a.value,t!=null&&Zo(e,!!a.multiple,t,!1)}};rx=Tp;ox=fo;var Jw={usingClientEntryPoint:!1,Events:[di,Go,pu,tx,ax,Tp]},Rs={findFiberByHostInstance:ao,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},ek={bundleType:Rs.bundleType,version:Rs.version,rendererPackageName:Rs.rendererPackageName,rendererConfig:Rs.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:qa.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=ix(e),e===null?null:e.stateNode},findFiberByHostInstance:Rs.findFiberByHostInstance||Yw,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&(Ds=__REACT_DEVTOOLS_GLOBAL_HOOK__,!Ds.isDisabled&&Ds.supportsFiber))try{uu=Ds.inject(ek),ya=Ds}catch{}var Ds;Bt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Jw;Bt.createPortal=function(e,t){var a=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Fp(t))throw Error(D(200));return Qw(e,t,null,a)};Bt.createRoot=function(e,t){if(!Fp(e))throw Error(D(299));var a=!1,r="",o=Uy;return t!=null&&(t.unstable_strictMode===!0&&(a=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(o=t.onRecoverableError)),t=Mp(e,1,!1,null,null,a,!1,r,o),e[_a]=t.current,Js(e.nodeType===8?e.parentNode:e),new Ep(t)};Bt.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(D(188)):(e=Object.keys(e).join(","),Error(D(268,e)));return e=ix(t),e=e===null?null:e.stateNode,e};Bt.flushSync=function(e){return fo(e)};Bt.hydrate=function(e,t,a){if(!Su(t))throw Error(D(200));return Iu(null,e,t,!0,a)};Bt.hydrateRoot=function(e,t,a){if(!Fp(e))throw Error(D(405));var r=a!=null&&a.hydratedSources||null,o=!1,n="",s=Uy;if(a!=null&&(a.unstable_strictMode===!0&&(o=!0),a.identifierPrefix!==void 0&&(n=a.identifierPrefix),a.onRecoverableError!==void 0&&(s=a.onRecoverableError)),t=Vy(t,null,e,1,a??null,o,!1,n,s),e[_a]=t.current,Js(e),r)for(e=0;e<r.length;e++)a=r[e],o=a._getVersion,o=o(a._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[a,o]:t.mutableSourceEagerHydrationData.push(a,o);return new Cu(t)};Bt.render=function(e,t,a){if(!Su(t))throw Error(D(200));return Iu(null,e,t,!1,a)};Bt.unmountComponentAtNode=function(e){if(!Su(e))throw Error(D(40));return e._reactRootContainer?(fo(function(){Iu(null,null,e,!1,function(){e._reactRootContainer=null,e[_a]=null})}),!0):!1};Bt.unstable_batchedUpdates=Tp;Bt.unstable_renderSubtreeIntoContainer=function(e,t,a,r){if(!Su(a))throw Error(D(200));if(e==null||e._reactInternals===void 0)throw Error(D(38));return Iu(e,t,a,!1,r)};Bt.version="18.3.1-next-f1338f8080-20240426"});var Bp=Na((OT,Hy)=>{"use strict";function zy(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(zy)}catch(e){console.error(e)}}zy(),Hy.exports=_y()});var Wy=Na(Op=>{"use strict";var qy=Bp();Op.createRoot=qy.createRoot,Op.hydrateRoot=qy.hydrateRoot;var VT});var ev=Na(ku=>{"use strict";var Mk=X(),Nk=Symbol.for("react.element"),Ek=Symbol.for("react.fragment"),Fk=Object.prototype.hasOwnProperty,Bk=Mk.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,Ok={key:!0,ref:!0,__self:!0,__source:!0};function Jy(e,t,a){var r,o={},n=null,s=null;a!==void 0&&(n=""+a),t.key!==void 0&&(n=""+t.key),t.ref!==void 0&&(s=t.ref);for(r in t)Fk.call(t,r)&&!Ok.hasOwnProperty(r)&&(o[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)o[r]===void 0&&(o[r]=t[r]);return{$$typeof:Nk,type:e,key:n,ref:s,props:o,_owner:Bk.current}}ku.Fragment=Ek;ku.jsx=Jy;ku.jsxs=Jy});var ue=Na((jT,tv)=>{"use strict";tv.exports=ev()});var TT={};BS(TT,{initKiteChat:()=>Zm});var Ra=E(X(),1),vS=E(Wy(),1);var j=E(X(),1);function Gy(e){var t,a,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(a=Gy(e[t]))&&(r&&(r+=" "),r+=a)}else for(a in e)e[a]&&(r&&(r+=" "),r+=a);return r}function wu(){for(var e,t,a=0,r="",o=arguments.length;a<o;a++)(e=arguments[a])&&(t=Gy(e))&&(r&&(r+=" "),r+=t);return r}var tk=e=>{let t=rk(e),{conflictingClassGroups:a,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{let i=s.split("-");return i[0]===""&&i.length!==1&&i.shift(),$y(i,t)||ak(s)},getConflictingClassGroupIds:(s,i)=>{let l=a[s]||[];return i&&r[s]?[...l,...r[s]]:l}}},$y=(e,t)=>{if(e.length===0)return t.classGroupId;let a=e[0],r=t.nextPart.get(a),o=r?$y(e.slice(1),r):void 0;if(o)return o;if(t.validators.length===0)return;let n=e.join("-");return t.validators.find(({validator:s})=>s(n))?.classGroupId},jy=/^\[(.+)\]$/,ak=e=>{if(jy.test(e)){let t=jy.exec(e)[1],a=t?.substring(0,t.indexOf(":"));if(a)return"arbitrary.."+a}},rk=e=>{let{theme:t,prefix:a}=e,r={nextPart:new Map,validators:[]};return nk(Object.entries(e.classGroups),a).forEach(([n,s])=>{Up(s,r,n,t)}),r},Up=(e,t,a,r)=>{e.forEach(o=>{if(typeof o=="string"){let n=o===""?t:Ky(t,o);n.classGroupId=a;return}if(typeof o=="function"){if(ok(o)){Up(o(r),t,a,r);return}t.validators.push({validator:o,classGroupId:a});return}Object.entries(o).forEach(([n,s])=>{Up(s,Ky(t,n),a,r)})})},Ky=(e,t)=>{let a=e;return t.split("-").forEach(r=>{a.nextPart.has(r)||a.nextPart.set(r,{nextPart:new Map,validators:[]}),a=a.nextPart.get(r)}),a},ok=e=>e.isThemeGetter,nk=(e,t)=>t?e.map(([a,r])=>{let o=r.map(n=>typeof n=="string"?t+n:typeof n=="object"?Object.fromEntries(Object.entries(n).map(([s,i])=>[t+s,i])):n);return[a,o]}):e,sk=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,a=new Map,r=new Map,o=(n,s)=>{a.set(n,s),t++,t>e&&(t=0,r=a,a=new Map)};return{get(n){let s=a.get(n);if(s!==void 0)return s;if((s=r.get(n))!==void 0)return o(n,s),s},set(n,s){a.has(n)?a.set(n,s):o(n,s)}}};var ik=e=>{let{separator:t,experimentalParseClassName:a}=e,r=t.length===1,o=t[0],n=t.length,s=i=>{let l=[],u=0,d=0,c;for(let S=0;S<i.length;S++){let h=i[S];if(u===0){if(h===o&&(r||i.slice(S,S+n)===t)){l.push(i.slice(d,S)),d=S+n;continue}if(h==="/"){c=S;continue}}h==="["?u++:h==="]"&&u--}let p=l.length===0?i:i.substring(d),g=p.startsWith("!"),C=g?p.substring(1):p,L=c&&c>d?c-d:void 0;return{modifiers:l,hasImportantModifier:g,baseClassName:C,maybePostfixModifierPosition:L}};return a?i=>a({className:i,parseClassName:s}):s},lk=e=>{if(e.length<=1)return e;let t=[],a=[];return e.forEach(r=>{r[0]==="["?(t.push(...a.sort(),r),a=[]):a.push(r)}),t.push(...a.sort()),t},uk=e=>({cache:sk(e.cacheSize),parseClassName:ik(e),...tk(e)}),dk=/\s+/,ck=(e,t)=>{let{parseClassName:a,getClassGroupId:r,getConflictingClassGroupIds:o}=t,n=[],s=e.trim().split(dk),i="";for(let l=s.length-1;l>=0;l-=1){let u=s[l],{modifiers:d,hasImportantModifier:c,baseClassName:p,maybePostfixModifierPosition:g}=a(u),C=!!g,L=r(C?p.substring(0,g):p);if(!L){if(!C){i=u+(i.length>0?" "+i:i);continue}if(L=r(p),!L){i=u+(i.length>0?" "+i:i);continue}C=!1}let S=lk(d).join(":"),h=c?S+"!":S,m=h+L;if(n.includes(m))continue;n.push(m);let x=o(L,C);for(let I=0;I<x.length;++I){let k=x[I];n.push(h+k)}i=u+(i.length>0?" "+i:i)}return i};function fk(){let e=0,t,a,r="";for(;e<arguments.length;)(t=arguments[e++])&&(a=Xy(t))&&(r&&(r+=" "),r+=a);return r}var Xy=e=>{if(typeof e=="string")return e;let t,a="";for(let r=0;r<e.length;r++)e[r]&&(t=Xy(e[r]))&&(a&&(a+=" "),a+=t);return a};function pk(e,...t){let a,r,o,n=s;function s(l){let u=t.reduce((d,c)=>c(d),e());return a=uk(u),r=a.cache.get,o=a.cache.set,n=i,i(l)}function i(l){let u=r(l);if(u)return u;let d=ck(l,a);return o(l,d),d}return function(){return n(fk.apply(null,arguments))}}var Ce=e=>{let t=a=>a[e]||[];return t.isThemeGetter=!0,t},Qy=/^\[(?:([a-z-]+):)?(.+)\]$/i,mk=/^\d+\/\d+$/,hk=new Set(["px","full","screen"]),gk=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,xk=/\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$/,yk=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,vk=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Lk=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Wa=e=>mn(e)||hk.has(e)||mk.test(e),Pr=e=>hn(e,"length",Tk),mn=e=>!!e&&!Number.isNaN(Number(e)),Vp=e=>hn(e,"number",mn),fi=e=>!!e&&Number.isInteger(Number(e)),Ck=e=>e.endsWith("%")&&mn(e.slice(0,-1)),Z=e=>Qy.test(e),Tr=e=>gk.test(e),Sk=new Set(["length","size","percentage"]),Ik=e=>hn(e,Sk,Yy),wk=e=>hn(e,"position",Yy),kk=new Set(["image","url"]),bk=e=>hn(e,kk,Rk),Pk=e=>hn(e,"",Ak),pi=()=>!0,hn=(e,t,a)=>{let r=Qy.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):a(r[2]):!1},Tk=e=>xk.test(e)&&!yk.test(e),Yy=()=>!1,Ak=e=>vk.test(e),Rk=e=>Lk.test(e);var Dk=()=>{let e=Ce("colors"),t=Ce("spacing"),a=Ce("blur"),r=Ce("brightness"),o=Ce("borderColor"),n=Ce("borderRadius"),s=Ce("borderSpacing"),i=Ce("borderWidth"),l=Ce("contrast"),u=Ce("grayscale"),d=Ce("hueRotate"),c=Ce("invert"),p=Ce("gap"),g=Ce("gradientColorStops"),C=Ce("gradientColorStopPositions"),L=Ce("inset"),S=Ce("margin"),h=Ce("opacity"),m=Ce("padding"),x=Ce("saturate"),I=Ce("scale"),k=Ce("sepia"),T=Ce("skew"),R=Ce("space"),A=Ce("translate"),V=()=>["auto","contain","none"],U=()=>["auto","hidden","clip","visible","scroll"],se=()=>["auto",Z,t],q=()=>[Z,t],No=()=>["",Wa,Pr],ie=()=>["auto",mn,Z],Wt=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],Xr=()=>["solid","dashed","dotted","double","none"],Ae=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Be=()=>["start","end","center","between","around","evenly","stretch"],Gt=()=>["","0",Z],Rt=()=>["auto","avoid","all","avoid-page","page","left","right","column"],ea=()=>[mn,Z];return{cacheSize:500,separator:":",theme:{colors:[pi],spacing:[Wa,Pr],blur:["none","",Tr,Z],brightness:ea(),borderColor:[e],borderRadius:["none","","full",Tr,Z],borderSpacing:q(),borderWidth:No(),contrast:ea(),grayscale:Gt(),hueRotate:ea(),invert:Gt(),gap:q(),gradientColorStops:[e],gradientColorStopPositions:[Ck,Pr],inset:se(),margin:se(),opacity:ea(),padding:q(),saturate:ea(),scale:ea(),sepia:Gt(),skew:ea(),space:q(),translate:q()},classGroups:{aspect:[{aspect:["auto","square","video",Z]}],container:["container"],columns:[{columns:[Tr]}],"break-after":[{"break-after":Rt()}],"break-before":[{"break-before":Rt()}],"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"],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:[...Wt(),Z]}],overflow:[{overflow:U()}],"overflow-x":[{"overflow-x":U()}],"overflow-y":[{"overflow-y":U()}],overscroll:[{overscroll:V()}],"overscroll-x":[{"overscroll-x":V()}],"overscroll-y":[{"overscroll-y":V()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[L]}],"inset-x":[{"inset-x":[L]}],"inset-y":[{"inset-y":[L]}],start:[{start:[L]}],end:[{end:[L]}],top:[{top:[L]}],right:[{right:[L]}],bottom:[{bottom:[L]}],left:[{left:[L]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",fi,Z]}],basis:[{basis:se()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Z]}],grow:[{grow:Gt()}],shrink:[{shrink:Gt()}],order:[{order:["first","last","none",fi,Z]}],"grid-cols":[{"grid-cols":[pi]}],"col-start-end":[{col:["auto",{span:["full",fi,Z]},Z]}],"col-start":[{"col-start":ie()}],"col-end":[{"col-end":ie()}],"grid-rows":[{"grid-rows":[pi]}],"row-start-end":[{row:["auto",{span:[fi,Z]},Z]}],"row-start":[{"row-start":ie()}],"row-end":[{"row-end":ie()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Z]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Z]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal",...Be()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...Be(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...Be(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[m]}],px:[{px:[m]}],py:[{py:[m]}],ps:[{ps:[m]}],pe:[{pe:[m]}],pt:[{pt:[m]}],pr:[{pr:[m]}],pb:[{pb:[m]}],pl:[{pl:[m]}],m:[{m:[S]}],mx:[{mx:[S]}],my:[{my:[S]}],ms:[{ms:[S]}],me:[{me:[S]}],mt:[{mt:[S]}],mr:[{mr:[S]}],mb:[{mb:[S]}],ml:[{ml:[S]}],"space-x":[{"space-x":[R]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[R]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Z,t]}],"min-w":[{"min-w":[Z,t,"min","max","fit"]}],"max-w":[{"max-w":[Z,t,"none","full","min","max","fit","prose",{screen:[Tr]},Tr]}],h:[{h:[Z,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Z,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Z,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Z,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Tr,Pr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Vp]}],"font-family":[{font:[pi]}],"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:["tighter","tight","normal","wide","wider","widest",Z]}],"line-clamp":[{"line-clamp":["none",mn,Vp]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Wa,Z]}],"list-image":[{"list-image":["none",Z]}],"list-style-type":[{list:["none","disc","decimal",Z]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[h]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[h]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...Xr(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Wa,Pr]}],"underline-offset":[{"underline-offset":["auto",Wa,Z]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:q()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Z]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Z]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[h]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...Wt(),wk]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Ik]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},bk]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[C]}],"gradient-via-pos":[{via:[C]}],"gradient-to-pos":[{to:[C]}],"gradient-from":[{from:[g]}],"gradient-via":[{via:[g]}],"gradient-to":[{to:[g]}],rounded:[{rounded:[n]}],"rounded-s":[{"rounded-s":[n]}],"rounded-e":[{"rounded-e":[n]}],"rounded-t":[{"rounded-t":[n]}],"rounded-r":[{"rounded-r":[n]}],"rounded-b":[{"rounded-b":[n]}],"rounded-l":[{"rounded-l":[n]}],"rounded-ss":[{"rounded-ss":[n]}],"rounded-se":[{"rounded-se":[n]}],"rounded-ee":[{"rounded-ee":[n]}],"rounded-es":[{"rounded-es":[n]}],"rounded-tl":[{"rounded-tl":[n]}],"rounded-tr":[{"rounded-tr":[n]}],"rounded-br":[{"rounded-br":[n]}],"rounded-bl":[{"rounded-bl":[n]}],"border-w":[{border:[i]}],"border-w-x":[{"border-x":[i]}],"border-w-y":[{"border-y":[i]}],"border-w-s":[{"border-s":[i]}],"border-w-e":[{"border-e":[i]}],"border-w-t":[{"border-t":[i]}],"border-w-r":[{"border-r":[i]}],"border-w-b":[{"border-b":[i]}],"border-w-l":[{"border-l":[i]}],"border-opacity":[{"border-opacity":[h]}],"border-style":[{border:[...Xr(),"hidden"]}],"divide-x":[{"divide-x":[i]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[i]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[h]}],"divide-style":[{divide:Xr()}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-s":[{"border-s":[o]}],"border-color-e":[{"border-e":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:["",...Xr()]}],"outline-offset":[{"outline-offset":[Wa,Z]}],"outline-w":[{outline:[Wa,Pr]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:No()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[h]}],"ring-offset-w":[{"ring-offset":[Wa,Pr]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Tr,Pk]}],"shadow-color":[{shadow:[pi]}],opacity:[{opacity:[h]}],"mix-blend":[{"mix-blend":[...Ae(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":Ae()}],filter:[{filter:["","none"]}],blur:[{blur:[a]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",Tr,Z]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[c]}],saturate:[{saturate:[x]}],sepia:[{sepia:[k]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[a]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[c]}],"backdrop-opacity":[{"backdrop-opacity":[h]}],"backdrop-saturate":[{"backdrop-saturate":[x]}],"backdrop-sepia":[{"backdrop-sepia":[k]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[s]}],"border-spacing-x":[{"border-spacing-x":[s]}],"border-spacing-y":[{"border-spacing-y":[s]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Z]}],duration:[{duration:ea()}],ease:[{ease:["linear","in","out","in-out",Z]}],delay:[{delay:ea()}],animate:[{animate:["none","spin","ping","pulse","bounce",Z]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[I]}],"scale-x":[{"scale-x":[I]}],"scale-y":[{"scale-y":[I]}],rotate:[{rotate:[fi,Z]}],"translate-x":[{"translate-x":[A]}],"translate-y":[{"translate-y":[A]}],"skew-x":[{"skew-x":[T]}],"skew-y":[{"skew-y":[T]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Z]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],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",Z]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":q()}],"scroll-mx":[{"scroll-mx":q()}],"scroll-my":[{"scroll-my":q()}],"scroll-ms":[{"scroll-ms":q()}],"scroll-me":[{"scroll-me":q()}],"scroll-mt":[{"scroll-mt":q()}],"scroll-mr":[{"scroll-mr":q()}],"scroll-mb":[{"scroll-mb":q()}],"scroll-ml":[{"scroll-ml":q()}],"scroll-p":[{"scroll-p":q()}],"scroll-px":[{"scroll-px":q()}],"scroll-py":[{"scroll-py":q()}],"scroll-ps":[{"scroll-ps":q()}],"scroll-pe":[{"scroll-pe":q()}],"scroll-pt":[{"scroll-pt":q()}],"scroll-pr":[{"scroll-pr":q()}],"scroll-pb":[{"scroll-pb":q()}],"scroll-pl":[{"scroll-pl":q()}],"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",Z]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Wa,Pr,Vp]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}};var Zy=pk(Dk);function Ot(...e){return Zy(wu(e))}var av=E(ue(),1);function Te({className:e,type:t,...a}){return(0,av.jsx)("input",{type:t,"data-slot":"input",className:Ot("file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm","focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]","aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",e),...a})}var Ve=E(X(),1);var ov=E(X(),1);function rv(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function mi(...e){return t=>{let a=!1,r=e.map(o=>{let n=rv(o,t);return!a&&typeof n=="function"&&(a=!0),n});if(a)return()=>{for(let o=0;o<r.length;o++){let n=r[o];typeof n=="function"?n():rv(e[o],null)}}}}function Ga(...e){return ov.useCallback(mi(...e),e)}var bu=E(ue(),1),Vk=Symbol.for("react.lazy"),Pu=Ve[" use ".trim().toString()];function Uk(e){return typeof e=="object"&&e!==null&&"then"in e}function nv(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===Vk&&"_payload"in e&&Uk(e._payload)}function _k(e){let t=zk(e),a=Ve.forwardRef((r,o)=>{let{children:n,...s}=r;nv(n)&&typeof Pu=="function"&&(n=Pu(n._payload));let i=Ve.Children.toArray(n),l=i.find(qk);if(l){let u=l.props.children,d=i.map(c=>c===l?Ve.Children.count(u)>1?Ve.Children.only(null):Ve.isValidElement(u)?u.props.children:null:c);return(0,bu.jsx)(t,{...s,ref:o,children:Ve.isValidElement(u)?Ve.cloneElement(u,void 0,d):null})}return(0,bu.jsx)(t,{...s,ref:o,children:n})});return a.displayName=`${e}.Slot`,a}var sv=_k("Slot");function zk(e){let t=Ve.forwardRef((a,r)=>{let{children:o,...n}=a;if(nv(o)&&typeof Pu=="function"&&(o=Pu(o._payload)),Ve.isValidElement(o)){let s=Gk(o),i=Wk(n,o.props);return o.type!==Ve.Fragment&&(i.ref=r?mi(r,s):s),Ve.cloneElement(o,i)}return Ve.Children.count(o)>1?Ve.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Hk=Symbol("radix.slottable");function qk(e){return Ve.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Hk}function Wk(e,t){let a={...t};for(let r in t){let o=e[r],n=t[r];/^on[A-Z]/.test(r)?o&&n?a[r]=(...i)=>{let l=n(...i);return o(...i),l}:o&&(a[r]=o):r==="style"?a[r]={...o,...n}:r==="className"&&(a[r]=[o,n].filter(Boolean).join(" "))}return{...e,...a}}function Gk(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,a=t&&"isReactWarning"in t&&t.isReactWarning;return a?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,a=t&&"isReactWarning"in t&&t.isReactWarning,a?e.props.ref:e.props.ref||e.ref)}var iv=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,lv=wu,uv=(e,t)=>a=>{var r;if(t?.variants==null)return lv(e,a?.class,a?.className);let{variants:o,defaultVariants:n}=t,s=Object.keys(o).map(u=>{let d=a?.[u],c=n?.[u];if(d===null)return null;let p=iv(d)||iv(c);return o[u][p]}),i=a&&Object.entries(a).reduce((u,d)=>{let[c,p]=d;return p===void 0||(u[c]=p),u},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((u,d)=>{let{class:c,className:p,...g}=d;return Object.entries(g).every(C=>{let[L,S]=C;return Array.isArray(S)?S.includes({...n,...i}[L]):{...n,...i}[L]===S})?[...u,c,p]:u},[]);return lv(e,s,l,a?.class,a?.className)};var dv=E(ue(),1),jk=uv("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2 has-[>svg]:px-3",sm:"h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4",icon:"size-9","icon-sm":"size-8","icon-lg":"size-10"}},defaultVariants:{variant:"default",size:"default"}});function It({className:e,variant:t,size:a,asChild:r=!1,...o}){return(0,dv.jsx)(r?sv:"button",{"data-slot":"button",className:Ot(jk({variant:t,size:a,className:e})),...o})}var Bv=E(X(),1);var G=E(X(),1);var fv=E(X(),1),Zk=E(Bp(),1);var He=E(X(),1);var Tu=E(ue(),1);function cv(e){let t=Kk(e),a=He.forwardRef((r,o)=>{let{children:n,...s}=r,i=He.Children.toArray(n),l=i.find(Xk);if(l){let u=l.props.children,d=i.map(c=>c===l?He.Children.count(u)>1?He.Children.only(null):He.isValidElement(u)?u.props.children:null:c);return(0,Tu.jsx)(t,{...s,ref:o,children:He.isValidElement(u)?He.cloneElement(u,void 0,d):null})}return(0,Tu.jsx)(t,{...s,ref:o,children:n})});return a.displayName=`${e}.Slot`,a}function Kk(e){let t=He.forwardRef((a,r)=>{let{children:o,...n}=a;if(He.isValidElement(o)){let s=Yk(o),i=Qk(n,o.props);return o.type!==He.Fragment&&(i.ref=r?mi(r,s):s),He.cloneElement(o,i)}return He.Children.count(o)>1?He.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var $k=Symbol("radix.slottable");function Xk(e){return He.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===$k}function Qk(e,t){let a={...t};for(let r in t){let o=e[r],n=t[r];/^on[A-Z]/.test(r)?o&&n?a[r]=(...i)=>{let l=n(...i);return o(...i),l}:o&&(a[r]=o):r==="style"?a[r]={...o,...n}:r==="className"&&(a[r]=[o,n].filter(Boolean).join(" "))}return{...e,...a}}function Yk(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,a=t&&"isReactWarning"in t&&t.isReactWarning;return a?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,a=t&&"isReactWarning"in t&&t.isReactWarning,a?e.props.ref:e.props.ref||e.ref)}var pv=E(ue(),1),Jk=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],gn=Jk.reduce((e,t)=>{let a=cv(`Primitive.${t}`),r=fv.forwardRef((o,n)=>{let{asChild:s,...i}=o,l=s?a:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),(0,pv.jsx)(l,{...i,ref:n})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});var wt=E(X(),1);var mv=E(X(),1),hi=globalThis?.document?mv.useLayoutEffect:()=>{};var hv=E(X(),1);function eb(e,t){return hv.useReducer((a,r)=>t[a][r]??a,e)}var xn=e=>{let{present:t,children:a}=e,r=tb(t),o=typeof a=="function"?a({present:r.isPresent}):wt.Children.only(a),n=Ga(r.ref,ab(o));return typeof a=="function"||r.isPresent?wt.cloneElement(o,{ref:n}):null};xn.displayName="Presence";function tb(e){let[t,a]=wt.useState(),r=wt.useRef(null),o=wt.useRef(e),n=wt.useRef("none"),s=e?"mounted":"unmounted",[i,l]=eb(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return wt.useEffect(()=>{let u=Au(r.current);n.current=i==="mounted"?u:"none"},[i]),hi(()=>{let u=r.current,d=o.current;if(d!==e){let p=n.current,g=Au(u);e?l("MOUNT"):g==="none"||u?.display==="none"?l("UNMOUNT"):l(d&&p!==g?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,l]),hi(()=>{if(t){let u,d=t.ownerDocument.defaultView??window,c=g=>{let L=Au(r.current).includes(CSS.escape(g.animationName));if(g.target===t&&L&&(l("ANIMATION_END"),!o.current)){let S=t.style.animationFillMode;t.style.animationFillMode="forwards",u=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=S)})}},p=g=>{g.target===t&&(n.current=Au(r.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",c),t.addEventListener("animationend",c),()=>{d.clearTimeout(u),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",c),t.removeEventListener("animationend",c)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(i),ref:wt.useCallback(u=>{r.current=u?getComputedStyle(u):null,a(u)},[])}}function Au(e){return e?.animationName||"none"}function ab(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,a=t&&"isReactWarning"in t&&t.isReactWarning;return a?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,a=t&&"isReactWarning"in t&&t.isReactWarning,a?e.props.ref:e.props.ref||e.ref)}var ja=E(X(),1),gv=E(ue(),1);function xv(e,t=[]){let a=[];function r(n,s){let i=ja.createContext(s),l=a.length;a=[...a,s];let u=c=>{let{scope:p,children:g,...C}=c,L=p?.[e]?.[l]||i,S=ja.useMemo(()=>C,Object.values(C));return(0,gv.jsx)(L.Provider,{value:S,children:g})};u.displayName=n+"Provider";function d(c,p){let g=p?.[e]?.[l]||i,C=ja.useContext(g);if(C)return C;if(s!==void 0)return s;throw new Error(`\`${c}\` must be used within \`${n}\``)}return[u,d]}let o=()=>{let n=a.map(s=>ja.createContext(s));return function(i){let l=i?.[e]||n;return ja.useMemo(()=>({[`__scope${e}`]:{...i,[e]:l}}),[i,l])}};return o.scopeName=e,[r,rb(o,...t)]}function rb(...e){let t=e[0];if(e.length===1)return t;let a=()=>{let r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(n){let s=r.reduce((i,{useScope:l,scopeName:u})=>{let c=l(n)[`__scope${u}`];return{...i,...c}},{});return ja.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return a.scopeName=t.scopeName,a}var yn=E(X(),1);function Ar(e){let t=yn.useRef(e);return yn.useEffect(()=>{t.current=e}),yn.useMemo(()=>(...a)=>t.current?.(...a),[])}var Ru=E(X(),1),ob=E(ue(),1),nb=Ru.createContext(void 0);function yv(e){let t=Ru.useContext(nb);return e||t||"ltr"}function vv(e,[t,a]){return Math.min(a,Math.max(t,e))}var gA=!!(typeof window<"u"&&window.document&&window.document.createElement);function Rr(e,t,{checkForDefaultPrevented:a=!0}={}){return function(o){if(e?.(o),a===!1||!o.defaultPrevented)return t?.(o)}}var Cv=E(X(),1),ce=E(ue(),1);function sb(e,t){return Cv.useReducer((a,r)=>t[a][r]??a,e)}var _p="ScrollArea",[Sv,PA]=xv(_p),[ib,Jt]=Sv(_p),Iv=G.forwardRef((e,t)=>{let{__scopeScrollArea:a,type:r="hover",dir:o,scrollHideDelay:n=600,...s}=e,[i,l]=G.useState(null),[u,d]=G.useState(null),[c,p]=G.useState(null),[g,C]=G.useState(null),[L,S]=G.useState(null),[h,m]=G.useState(0),[x,I]=G.useState(0),[k,T]=G.useState(!1),[R,A]=G.useState(!1),V=Ga(t,se=>l(se)),U=yv(o);return(0,ce.jsx)(ib,{scope:a,type:r,dir:U,scrollHideDelay:n,scrollArea:i,viewport:u,onViewportChange:d,content:c,onContentChange:p,scrollbarX:g,onScrollbarXChange:C,scrollbarXEnabled:k,onScrollbarXEnabledChange:T,scrollbarY:L,onScrollbarYChange:S,scrollbarYEnabled:R,onScrollbarYEnabledChange:A,onCornerWidthChange:m,onCornerHeightChange:I,children:(0,ce.jsx)(gn.div,{dir:U,...s,ref:V,style:{position:"relative","--radix-scroll-area-corner-width":h+"px","--radix-scroll-area-corner-height":x+"px",...e.style}})})});Iv.displayName=_p;var wv="ScrollAreaViewport",kv=G.forwardRef((e,t)=>{let{__scopeScrollArea:a,children:r,nonce:o,...n}=e,s=Jt(wv,a),i=G.useRef(null),l=Ga(t,i,s.onViewportChange);return(0,ce.jsxs)(ce.Fragment,{children:[(0,ce.jsx)("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"},nonce:o}),(0,ce.jsx)(gn.div,{"data-radix-scroll-area-viewport":"",...n,ref:l,style:{overflowX:s.scrollbarXEnabled?"scroll":"hidden",overflowY:s.scrollbarYEnabled?"scroll":"hidden",...e.style},children:(0,ce.jsx)("div",{ref:s.onContentChange,style:{minWidth:"100%",display:"table"},children:r})})]})});kv.displayName=wv;var La="ScrollAreaScrollbar",zp=G.forwardRef((e,t)=>{let{forceMount:a,...r}=e,o=Jt(La,e.__scopeScrollArea),{onScrollbarXEnabledChange:n,onScrollbarYEnabledChange:s}=o,i=e.orientation==="horizontal";return G.useEffect(()=>(i?n(!0):s(!0),()=>{i?n(!1):s(!1)}),[i,n,s]),o.type==="hover"?(0,ce.jsx)(lb,{...r,ref:t,forceMount:a}):o.type==="scroll"?(0,ce.jsx)(ub,{...r,ref:t,forceMount:a}):o.type==="auto"?(0,ce.jsx)(bv,{...r,ref:t,forceMount:a}):o.type==="always"?(0,ce.jsx)(Hp,{...r,ref:t}):null});zp.displayName=La;var lb=G.forwardRef((e,t)=>{let{forceMount:a,...r}=e,o=Jt(La,e.__scopeScrollArea),[n,s]=G.useState(!1);return G.useEffect(()=>{let i=o.scrollArea,l=0;if(i){let u=()=>{window.clearTimeout(l),s(!0)},d=()=>{l=window.setTimeout(()=>s(!1),o.scrollHideDelay)};return i.addEventListener("pointerenter",u),i.addEventListener("pointerleave",d),()=>{window.clearTimeout(l),i.removeEventListener("pointerenter",u),i.removeEventListener("pointerleave",d)}}},[o.scrollArea,o.scrollHideDelay]),(0,ce.jsx)(xn,{present:a||n,children:(0,ce.jsx)(bv,{"data-state":n?"visible":"hidden",...r,ref:t})})}),ub=G.forwardRef((e,t)=>{let{forceMount:a,...r}=e,o=Jt(La,e.__scopeScrollArea),n=e.orientation==="horizontal",s=Eu(()=>l("SCROLL_END"),100),[i,l]=sb("hidden",{hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}});return G.useEffect(()=>{if(i==="idle"){let u=window.setTimeout(()=>l("HIDE"),o.scrollHideDelay);return()=>window.clearTimeout(u)}},[i,o.scrollHideDelay,l]),G.useEffect(()=>{let u=o.viewport,d=n?"scrollLeft":"scrollTop";if(u){let c=u[d],p=()=>{let g=u[d];c!==g&&(l("SCROLL"),s()),c=g};return u.addEventListener("scroll",p),()=>u.removeEventListener("scroll",p)}},[o.viewport,n,l,s]),(0,ce.jsx)(xn,{present:a||i!=="hidden",children:(0,ce.jsx)(Hp,{"data-state":i==="hidden"?"hidden":"visible",...r,ref:t,onPointerEnter:Rr(e.onPointerEnter,()=>l("POINTER_ENTER")),onPointerLeave:Rr(e.onPointerLeave,()=>l("POINTER_LEAVE"))})})}),bv=G.forwardRef((e,t)=>{let a=Jt(La,e.__scopeScrollArea),{forceMount:r,...o}=e,[n,s]=G.useState(!1),i=e.orientation==="horizontal",l=Eu(()=>{if(a.viewport){let u=a.viewport.offsetWidth<a.viewport.scrollWidth,d=a.viewport.offsetHeight<a.viewport.scrollHeight;s(i?u:d)}},10);return vn(a.viewport,l),vn(a.content,l),(0,ce.jsx)(xn,{present:r||n,children:(0,ce.jsx)(Hp,{"data-state":n?"visible":"hidden",...o,ref:t})})}),Hp=G.forwardRef((e,t)=>{let{orientation:a="vertical",...r}=e,o=Jt(La,e.__scopeScrollArea),n=G.useRef(null),s=G.useRef(0),[i,l]=G.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),u=Rv(i.viewport,i.content),d={...r,sizes:i,onSizesChange:l,hasThumb:u>0&&u<1,onThumbChange:p=>n.current=p,onThumbPointerUp:()=>s.current=0,onThumbPointerDown:p=>s.current=p};function c(p,g){return hb(p,s.current,i,g)}return a==="horizontal"?(0,ce.jsx)(db,{...d,ref:t,onThumbPositionChange:()=>{if(o.viewport&&n.current){let p=o.viewport.scrollLeft,g=Lv(p,i,o.dir);n.current.style.transform=`translate3d(${g}px, 0, 0)`}},onWheelScroll:p=>{o.viewport&&(o.viewport.scrollLeft=p)},onDragScroll:p=>{o.viewport&&(o.viewport.scrollLeft=c(p,o.dir))}}):a==="vertical"?(0,ce.jsx)(cb,{...d,ref:t,onThumbPositionChange:()=>{if(o.viewport&&n.current){let p=o.viewport.scrollTop,g=Lv(p,i);n.current.style.transform=`translate3d(0, ${g}px, 0)`}},onWheelScroll:p=>{o.viewport&&(o.viewport.scrollTop=p)},onDragScroll:p=>{o.viewport&&(o.viewport.scrollTop=c(p))}}):null}),db=G.forwardRef((e,t)=>{let{sizes:a,onSizesChange:r,...o}=e,n=Jt(La,e.__scopeScrollArea),[s,i]=G.useState(),l=G.useRef(null),u=Ga(t,l,n.onScrollbarXChange);return G.useEffect(()=>{l.current&&i(getComputedStyle(l.current))},[l]),(0,ce.jsx)(Tv,{"data-orientation":"horizontal",...o,ref:u,sizes:a,style:{bottom:0,left:n.dir==="rtl"?"var(--radix-scroll-area-corner-width)":0,right:n.dir==="ltr"?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":Nu(a)+"px",...e.style},onThumbPointerDown:d=>e.onThumbPointerDown(d.x),onDragScroll:d=>e.onDragScroll(d.x),onWheelScroll:(d,c)=>{if(n.viewport){let p=n.viewport.scrollLeft+d.deltaX;e.onWheelScroll(p),Mv(p,c)&&d.preventDefault()}},onResize:()=>{l.current&&n.viewport&&s&&r({content:n.viewport.scrollWidth,viewport:n.viewport.offsetWidth,scrollbar:{size:l.current.clientWidth,paddingStart:Mu(s.paddingLeft),paddingEnd:Mu(s.paddingRight)}})}})}),cb=G.forwardRef((e,t)=>{let{sizes:a,onSizesChange:r,...o}=e,n=Jt(La,e.__scopeScrollArea),[s,i]=G.useState(),l=G.useRef(null),u=Ga(t,l,n.onScrollbarYChange);return G.useEffect(()=>{l.current&&i(getComputedStyle(l.current))},[l]),(0,ce.jsx)(Tv,{"data-orientation":"vertical",...o,ref:u,sizes:a,style:{top:0,right:n.dir==="ltr"?0:void 0,left:n.dir==="rtl"?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":Nu(a)+"px",...e.style},onThumbPointerDown:d=>e.onThumbPointerDown(d.y),onDragScroll:d=>e.onDragScroll(d.y),onWheelScroll:(d,c)=>{if(n.viewport){let p=n.viewport.scrollTop+d.deltaY;e.onWheelScroll(p),Mv(p,c)&&d.preventDefault()}},onResize:()=>{l.current&&n.viewport&&s&&r({content:n.viewport.scrollHeight,viewport:n.viewport.offsetHeight,scrollbar:{size:l.current.clientHeight,paddingStart:Mu(s.paddingTop),paddingEnd:Mu(s.paddingBottom)}})}})}),[fb,Pv]=Sv(La),Tv=G.forwardRef((e,t)=>{let{__scopeScrollArea:a,sizes:r,hasThumb:o,onThumbChange:n,onThumbPointerUp:s,onThumbPointerDown:i,onThumbPositionChange:l,onDragScroll:u,onWheelScroll:d,onResize:c,...p}=e,g=Jt(La,a),[C,L]=G.useState(null),S=Ga(t,V=>L(V)),h=G.useRef(null),m=G.useRef(""),x=g.viewport,I=r.content-r.viewport,k=Ar(d),T=Ar(l),R=Eu(c,10);function A(V){if(h.current){let U=V.clientX-h.current.left,se=V.clientY-h.current.top;u({x:U,y:se})}}return G.useEffect(()=>{let V=U=>{let se=U.target;C?.contains(se)&&k(U,I)};return document.addEventListener("wheel",V,{passive:!1}),()=>document.removeEventListener("wheel",V,{passive:!1})},[x,C,I,k]),G.useEffect(T,[r,T]),vn(C,R),vn(g.content,R),(0,ce.jsx)(fb,{scope:a,scrollbar:C,hasThumb:o,onThumbChange:Ar(n),onThumbPointerUp:Ar(s),onThumbPositionChange:T,onThumbPointerDown:Ar(i),children:(0,ce.jsx)(gn.div,{...p,ref:S,style:{position:"absolute",...p.style},onPointerDown:Rr(e.onPointerDown,V=>{V.button===0&&(V.target.setPointerCapture(V.pointerId),h.current=C.getBoundingClientRect(),m.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",g.viewport&&(g.viewport.style.scrollBehavior="auto"),A(V))}),onPointerMove:Rr(e.onPointerMove,A),onPointerUp:Rr(e.onPointerUp,V=>{let U=V.target;U.hasPointerCapture(V.pointerId)&&U.releasePointerCapture(V.pointerId),document.body.style.webkitUserSelect=m.current,g.viewport&&(g.viewport.style.scrollBehavior=""),h.current=null})})})}),Du="ScrollAreaThumb",qp=G.forwardRef((e,t)=>{let{forceMount:a,...r}=e,o=Pv(Du,e.__scopeScrollArea);return(0,ce.jsx)(xn,{present:a||o.hasThumb,children:(0,ce.jsx)(pb,{ref:t,...r})})}),pb=G.forwardRef((e,t)=>{let{__scopeScrollArea:a,style:r,...o}=e,n=Jt(Du,a),s=Pv(Du,a),{onThumbPositionChange:i}=s,l=Ga(t,c=>s.onThumbChange(c)),u=G.useRef(void 0),d=Eu(()=>{u.current&&(u.current(),u.current=void 0)},100);return G.useEffect(()=>{let c=n.viewport;if(c){let p=()=>{if(d(),!u.current){let g=gb(c,i);u.current=g,i()}};return i(),c.addEventListener("scroll",p),()=>c.removeEventListener("scroll",p)}},[n.viewport,d,i]),(0,ce.jsx)(gn.div,{"data-state":s.hasThumb?"visible":"hidden",...o,ref:l,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...r},onPointerDownCapture:Rr(e.onPointerDownCapture,c=>{let g=c.target.getBoundingClientRect(),C=c.clientX-g.left,L=c.clientY-g.top;s.onThumbPointerDown({x:C,y:L})}),onPointerUp:Rr(e.onPointerUp,s.onThumbPointerUp)})});qp.displayName=Du;var Wp="ScrollAreaCorner",Av=G.forwardRef((e,t)=>{let a=Jt(Wp,e.__scopeScrollArea),r=!!(a.scrollbarX&&a.scrollbarY);return a.type!=="scroll"&&r?(0,ce.jsx)(mb,{...e,ref:t}):null});Av.displayName=Wp;var mb=G.forwardRef((e,t)=>{let{__scopeScrollArea:a,...r}=e,o=Jt(Wp,a),[n,s]=G.useState(0),[i,l]=G.useState(0),u=!!(n&&i);return vn(o.scrollbarX,()=>{let d=o.scrollbarX?.offsetHeight||0;o.onCornerHeightChange(d),l(d)}),vn(o.scrollbarY,()=>{let d=o.scrollbarY?.offsetWidth||0;o.onCornerWidthChange(d),s(d)}),u?(0,ce.jsx)(gn.div,{...r,ref:t,style:{width:n,height:i,position:"absolute",right:o.dir==="ltr"?0:void 0,left:o.dir==="rtl"?0:void 0,bottom:0,...e.style}}):null});function Mu(e){return e?parseInt(e,10):0}function Rv(e,t){let a=e/t;return isNaN(a)?0:a}function Nu(e){let t=Rv(e.viewport,e.content),a=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,r=(e.scrollbar.size-a)*t;return Math.max(r,18)}function hb(e,t,a,r="ltr"){let o=Nu(a),n=o/2,s=t||n,i=o-s,l=a.scrollbar.paddingStart+s,u=a.scrollbar.size-a.scrollbar.paddingEnd-i,d=a.content-a.viewport,c=r==="ltr"?[0,d]:[d*-1,0];return Dv([l,u],c)(e)}function Lv(e,t,a="ltr"){let r=Nu(t),o=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,n=t.scrollbar.size-o,s=t.content-t.viewport,i=n-r,l=a==="ltr"?[0,s]:[s*-1,0],u=vv(e,l);return Dv([0,s],[0,i])(u)}function Dv(e,t){return a=>{if(e[0]===e[1]||t[0]===t[1])return t[0];let r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(a-e[0])}}function Mv(e,t){return e>0&&e<t}var gb=(e,t=()=>{})=>{let a={left:e.scrollLeft,top:e.scrollTop},r=0;return(function o(){let n={left:e.scrollLeft,top:e.scrollTop},s=a.left!==n.left,i=a.top!==n.top;(s||i)&&t(),a=n,r=window.requestAnimationFrame(o)})(),()=>window.cancelAnimationFrame(r)};function Eu(e,t){let a=Ar(e),r=G.useRef(0);return G.useEffect(()=>()=>window.clearTimeout(r.current),[]),G.useCallback(()=>{window.clearTimeout(r.current),r.current=window.setTimeout(a,t)},[a,t])}function vn(e,t){let a=Ar(t);hi(()=>{let r=0;if(e){let o=new ResizeObserver(()=>{cancelAnimationFrame(r),r=window.requestAnimationFrame(a)});return o.observe(e),()=>{window.cancelAnimationFrame(r),o.unobserve(e)}}},[e,a])}var Nv=Iv,Ev=kv;var Fv=Av;var Dr=E(ue(),1),Gp=Bv.forwardRef(({className:e,children:t,...a},r)=>(0,Dr.jsxs)(Nv,{"data-slot":"scroll-area",className:Ot("relative",e),...a,children:[(0,Dr.jsx)(Ev,{ref:r,"data-slot":"scroll-area-viewport",className:"focus-visible:ring-ring/50 size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:outline-1",children:t}),(0,Dr.jsx)(yb,{}),(0,Dr.jsx)(Fv,{})]}));Gp.displayName="ScrollArea";function yb({className:e,orientation:t="vertical",...a}){return(0,Dr.jsx)(zp,{"data-slot":"scroll-area-scrollbar",orientation:t,className:Ot("flex touch-none p-px transition-colors select-none",t==="vertical"&&"h-full w-2.5 border-l border-l-transparent",t==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent",e),...a,children:(0,Dr.jsx)(qp,{"data-slot":"scroll-area-thumb",className:"bg-border relative flex-1 rounded-full"})})}var Bu=E(X());var Ov=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),vb=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,a,r)=>r?r.toUpperCase():a.toLowerCase()),jp=e=>{let t=vb(e);return t.charAt(0).toUpperCase()+t.slice(1)},Fu=(...e)=>e.filter((t,a,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===a).join(" ").trim(),Vv=e=>{for(let t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};var gi=E(X());var Uv={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};var _v=(0,gi.forwardRef)(({color:e="currentColor",size:t=24,strokeWidth:a=2,absoluteStrokeWidth:r,className:o="",children:n,iconNode:s,...i},l)=>(0,gi.createElement)("svg",{ref:l,...Uv,width:t,height:t,stroke:e,strokeWidth:r?Number(a)*24/Number(t):a,className:Fu("lucide",o),...!n&&!Vv(i)&&{"aria-hidden":"true"},...i},[...s.map(([u,d])=>(0,gi.createElement)(u,d)),...Array.isArray(n)?n:[n]]));var _=(e,t)=>{let a=(0,Bu.forwardRef)(({className:r,...o},n)=>(0,Bu.createElement)(_v,{ref:n,iconNode:t,className:Fu(`lucide-${Ov(jp(e))}`,`lucide-${e}`,r),...o}));return a.displayName=jp(e),a};var Lb=[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]],xi=_("activity",Lb);var Cb=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],Ln=_("arrow-left",Cb);var Sb=[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]],yi=_("arrow-up",Sb);var Ib=[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]],vi=_("calendar",Ib);var wb=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],Li=_("chevron-down",wb);var kb=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]],da=_("circle-alert",kb);var bb=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],$e=_("circle-check",bb);var Pb=[["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"}]],ca=_("circle-x",Pb);var Tb=[["path",{d:"M12 6v6l4 2",key:"mmk7yg"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],ho=_("clock",Tb);var Ab=[["path",{d:"M15 6v12a3 3 0 1 0 3-3H6a3 3 0 1 0 3 3V6a3 3 0 1 0-3 3h12a3 3 0 1 0-3-3",key:"11bfej"}]],Ka=_("command",Ab);var Rb=[["path",{d:"M20 4v7a4 4 0 0 1-4 4H4",key:"6o5b7l"}],["path",{d:"m9 10-5 5 5 5",key:"1kshq7"}]],$a=_("corner-down-left",Rb);var Db=[["rect",{width:"20",height:"14",x:"2",y:"5",rx:"2",key:"ynyp8z"}],["line",{x1:"2",x2:"22",y1:"10",y2:"10",key:"1b3vmo"}]],go=_("credit-card",Db);var Mb=[["path",{d:"M11.562 3.266a.5.5 0 0 1 .876 0L15.39 8.87a1 1 0 0 0 1.516.294L21.183 5.5a.5.5 0 0 1 .798.519l-2.834 10.246a1 1 0 0 1-.956.734H5.81a1 1 0 0 1-.957-.734L2.02 6.02a.5.5 0 0 1 .798-.519l4.276 3.664a1 1 0 0 0 1.516-.294z",key:"1vdc57"}],["path",{d:"M5 21h14",key:"11awu3"}]],xo=_("crown",Mb);var Nb=[["line",{x1:"12",x2:"12",y1:"2",y2:"22",key:"7eqyqh"}],["path",{d:"M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6",key:"1b0p4s"}]],yo=_("dollar-sign",Nb);var Eb=[["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:"M8 13h2",key:"yr2amv"}],["path",{d:"M14 13h2",key:"un5t4a"}],["path",{d:"M8 17h2",key:"2yhykz"}],["path",{d:"M14 17h2",key:"10kma7"}]],Cn=_("file-spreadsheet",Eb);var Fb=[["path",{d:"m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4",key:"g0fldk"}],["path",{d:"m21 2-9.6 9.6",key:"1j0ho8"}],["circle",{cx:"7.5",cy:"15.5",r:"5.5",key:"yqb3hr"}]],Sn=_("key",Fb);var Bb=[["path",{d:"M18 5a2 2 0 0 1 2 2v8.526a2 2 0 0 0 .212.897l1.068 2.127a1 1 0 0 1-.9 1.45H3.62a1 1 0 0 1-.9-1.45l1.068-2.127A2 2 0 0 0 4 15.526V7a2 2 0 0 1 2-2z",key:"1pdavp"}],["path",{d:"M20.054 15.987H3.946",key:"14rxg9"}]],Ci=_("laptop",Bb);var Ob=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],Vt=_("loader-circle",Ob);var Vb=[["path",{d:"m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7",key:"132q7q"}],["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}]],In=_("mail",Vb);var Ub=[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]],wn=_("map-pin",Ub);var _b=[["path",{d:"m16 6-8.414 8.586a2 2 0 0 0 2.829 2.829l8.414-8.586a4 4 0 1 0-5.657-5.657l-8.379 8.551a6 6 0 1 0 8.485 8.485l8.379-8.551",key:"1miecu"}]],Si=_("paperclip",_b);var zb=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]],kn=_("refresh-cw",zb);var Hb=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],vo=_("search",Hb);var qb=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]],bn=_("shield",qb);var Wb=[["rect",{width:"14",height:"20",x:"5",y:"2",rx:"2",ry:"2",key:"1yt0o3"}],["path",{d:"M12 18h.01",key:"mhygvu"}]],Ii=_("smartphone",Wb);var Gb=[["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"}]],Ca=_("sparkles",Gb);var jb=[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1m0v6g"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z",key:"ohrbg2"}]],kt=_("square-pen",jb);var Kb=[["path",{d:"M16 7h6v6",key:"box55l"}],["path",{d:"m22 7-8.5 8.5-5-5L2 17",key:"1t1m79"}]],wi=_("trending-up",Kb);var $b=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["path",{d:"M16 3.128a4 4 0 0 1 0 7.744",key:"16gr8j"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],Pn=_("users",$b);var Xb=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Mr=_("x",Xb);var Qb=[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]],ki=_("zap",Qb);var De=E(ue(),1);function zv({phase:e,progressSteps:t=[]}){return(0,De.jsxs)("div",{className:"mb-3 rounded-lg bg-muted/40 px-3 py-3 text-xs text-muted-foreground transition-colors",children:[e==="thinking"&&t.length===0&&(0,De.jsxs)("div",{className:"flex items-center gap-2",children:[(0,De.jsx)(Vt,{className:"h-3.5 w-3.5 animate-spin"}),(0,De.jsx)("span",{children:"Thinking\u2026"})]}),e==="searching"&&(0,De.jsxs)("div",{className:"space-y-2 animate-in fade-in-0 duration-300",children:[(0,De.jsxs)("div",{className:"flex items-center gap-2",children:[(0,De.jsx)(vo,{className:"h-3.5 w-3.5 opacity-70"}),(0,De.jsx)("span",{children:"Searching across pages\u2026"})]}),(0,De.jsxs)("ul",{className:"ml-6 list-disc space-y-1",children:[(0,De.jsx)("li",{className:"opacity-90",children:"Checking recent changes"}),(0,De.jsx)("li",{className:"opacity-90",children:"Scanning documentation"}),(0,De.jsx)("li",{className:"opacity-90",children:"Summarizing relevant sections"})]})]}),(e==="thinking"||e==="executing"||e==="responding")&&t.length>0&&(0,De.jsxs)("div",{className:"space-y-2 animate-in fade-in-0 duration-200",children:[t.map((a,r)=>(0,De.jsxs)("div",{className:`flex items-center gap-2 transition-opacity duration-200 ${a.completed?"opacity-60":"opacity-100"}`,children:[a.completed?(0,De.jsx)($e,{className:"h-3.5 w-3.5 text-green-500 flex-shrink-0"}):(0,De.jsx)(Vt,{className:"h-3.5 w-3.5 animate-spin flex-shrink-0"}),(0,De.jsx)("span",{className:a.completed?"line-through":"",children:a.message})]},r)),e==="responding"&&(0,De.jsxs)("div",{className:"flex items-center gap-2 opacity-100 animate-in fade-in-0 duration-200",children:[(0,De.jsx)(Vt,{className:"h-3.5 w-3.5 animate-spin flex-shrink-0"}),(0,De.jsx)("span",{children:"Preparing response..."})]})]})]})}var Hv=E(X(),1);var fa=E(ue(),1);function qv({title:e,links:t}){let[a,r]=Hv.useState(!1);return(0,fa.jsxs)("div",{className:"text-xs text-muted-foreground",children:[(0,fa.jsx)("button",{type:"button",onClick:()=>r(o=>!o),className:"flex w-full items-center gap-2 px-0 py-0","aria-expanded":a,children:(0,fa.jsxs)("div",{className:"flex items-center gap-1.5",children:[a?(0,fa.jsx)(Li,{className:"h-3 w-3 opacity-70"}):(0,fa.jsx)(vo,{className:"h-3 w-3 opacity-70"}),(0,fa.jsx)("span",{children:e})]})}),a&&t.length>0&&(0,fa.jsx)("ul",{className:"ml-5 mt-1 space-y-0.5",children:t.map(o=>(0,fa.jsx)("li",{children:(0,fa.jsx)("a",{href:o.href,target:"_blank",rel:"noreferrer",className:"text-primary hover:underline",children:o.label})},o.href))})]})}var Pi=E(ue(),1),Sa=E(X(),1);var Wv=E(X(),1),Tn=(0,Wv.createContext)({});var Gv=E(X(),1);function An(e){let t=(0,Gv.useRef)(null);return t.current===null&&(t.current=e()),t.current}var $p=E(ue(),1),Qv=E(X(),1),Lo=E(X(),1);var jv=E(X(),1),Nr=(0,jv.createContext)(null);var $v=E(ue(),1),Ou=E(X(),1),Xa=E(X(),1);var Kv=E(X(),1),Rn=(0,Kv.createContext)({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});var Kp=class extends Ou.Component{getSnapshotBeforeUpdate(t){let a=this.props.childRef.current;if(a&&t.isPresent&&!this.props.isPresent){let r=this.props.sizeRef.current;r.height=a.offsetHeight||0,r.width=a.offsetWidth||0,r.top=a.offsetTop,r.left=a.offsetLeft}return null}componentDidUpdate(){}render(){return this.props.children}};function Xv({children:e,isPresent:t}){let a=(0,Xa.useId)(),r=(0,Xa.useRef)(null),o=(0,Xa.useRef)({width:0,height:0,top:0,left:0}),{nonce:n}=(0,Xa.useContext)(Rn);return(0,Xa.useInsertionEffect)(()=>{let{width:s,height:i,top:l,left:u}=o.current;if(t||!r.current||!s||!i)return;r.current.dataset.motionPopId=a;let d=document.createElement("style");return n&&(d.nonce=n),document.head.appendChild(d),d.sheet&&d.sheet.insertRule(`
|
|
8
|
+
`+n.stack}return{value:e,source:t,stack:o,digest:null}}function Qc(e,t,a){return{value:e,source:null,stack:a??null,digest:t??null}}function Nf(e,t){try{console.error(t.value)}catch(a){setTimeout(function(){throw a})}}var Dw=typeof WeakMap=="function"?WeakMap:Map;function my(e,t,a){a=Va(-1,a),a.tag=3,a.payload={element:null};var r=t.value;return a.callback=function(){su||(su=!0,qf=r),Nf(e,t)},a}function hy(e,t,a){a=Va(-1,a),a.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var o=t.value;a.payload=function(){return r(o)},a.callback=function(){Nf(e,t)}}var n=e.stateNode;return n!==null&&typeof n.componentDidCatch=="function"&&(a.callback=function(){Nf(e,t),typeof r!="function"&&(vr===null?vr=new Set([this]):vr.add(this));var s=t.stack;this.componentDidCatch(t.value,{componentStack:s!==null?s:""})}),a}function bg(e,t,a){var r=e.pingCache;if(r===null){r=e.pingCache=new Dw;var o=new Set;r.set(t,o)}else o=r.get(t),o===void 0&&(o=new Set,r.set(t,o));o.has(a)||(o.add(a),e=Gw.bind(null,e,t,a),t.then(e,e))}function Pg(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function Tg(e,t,a,r,o){return(e.mode&1)===0?(e===t?e.flags|=65536:(e.flags|=128,a.flags|=131072,a.flags&=-52805,a.tag===1&&(a.alternate===null?a.tag=17:(t=Va(-1,1),t.tag=2,yr(a,t,1))),a.lanes|=1),e):(e.flags|=65536,e.lanes=o,e)}var Mw=qa.ReactCurrentOwner,vt=!1;function ft(e,t,a,r){t.child=e===null?Wx(t,null,a,r):ln(t,e.child,a,r)}function Ag(e,t,a,r,o){a=a.render;var n=t.ref;return an(t,o),r=Cp(e,t,a,r,n,o),a=Sp(),e!==null&&!vt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,Ha(e,t,o)):(we&&a&&up(t),t.flags|=1,ft(e,t,r,o),t.child)}function Rg(e,t,a,r,o){if(e===null){var n=a.type;return typeof n=="function"&&!Mp(n)&&n.defaultProps===void 0&&a.compare===null&&a.defaultProps===void 0?(t.tag=15,t.type=n,gy(e,t,n,r,o)):(e=Ul(a.type,null,r,t,t.mode,o),e.ref=t.ref,e.return=t,t.child=e)}if(n=e.child,(e.lanes&o)===0){var s=n.memoizedProps;if(a=a.compare,a=a!==null?a:Zs,a(s,r)&&e.ref===t.ref)return Ha(e,t,o)}return t.flags|=1,e=Cr(n,r),e.ref=t.ref,e.return=t,t.child=e}function gy(e,t,a,r,o){if(e!==null){var n=e.memoizedProps;if(Zs(n,r)&&e.ref===t.ref)if(vt=!1,t.pendingProps=r=n,(e.lanes&o)!==0)(e.flags&131072)!==0&&(vt=!0);else return t.lanes=e.lanes,Ha(e,t,o)}return Ef(e,t,a,r,o)}function xy(e,t,a){var r=t.pendingProps,o=r.children,n=e!==null?e.memoizedState:null;if(r.mode==="hidden")if((t.mode&1)===0)t.memoizedState={baseLanes:0,cachePool:null,transitions:null},xe(Yo,Dt),Dt|=a;else{if((a&1073741824)===0)return e=n!==null?n.baseLanes|a:a,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,xe(Yo,Dt),Dt|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=n!==null?n.baseLanes:a,xe(Yo,Dt),Dt|=r}else n!==null?(r=n.baseLanes|a,t.memoizedState=null):r=a,xe(Yo,Dt),Dt|=r;return ft(e,t,o,a),t.child}function yy(e,t){var a=t.ref;(e===null&&a!==null||e!==null&&e.ref!==a)&&(t.flags|=512,t.flags|=2097152)}function Ef(e,t,a,r,o){var n=Ct(a)?so:it.current;return n=nn(t,n),an(t,o),a=Cp(e,t,a,r,n,o),r=Sp(),e!==null&&!vt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,Ha(e,t,o)):(we&&r&&up(t),t.flags|=1,ft(e,t,a,o),t.child)}function Dg(e,t,a,r,o){if(Ct(a)){var n=!0;Ql(t)}else n=!1;if(an(t,o),t.stateNode===null)Bl(e,t),py(t,a,r),Mf(t,a,r,o),r=!0;else if(e===null){var s=t.stateNode,i=t.memoizedProps;s.props=i;var l=s.context,u=a.contextType;typeof u=="object"&&u!==null?u=Yt(u):(u=Ct(a)?so:it.current,u=nn(t,u));var d=a.getDerivedStateFromProps,c=typeof d=="function"||typeof s.getSnapshotBeforeUpdate=="function";c||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(i!==r||l!==u)&&kg(t,s,r,u),ur=!1;var p=t.memoizedState;s.state=p,tu(t,r,s,o),l=t.memoizedState,i!==r||p!==l||Lt.current||ur?(typeof d=="function"&&(Df(t,a,d,r),l=t.memoizedState),(i=ur||wg(t,a,i,r,p,l,u))?(c||typeof s.UNSAFE_componentWillMount!="function"&&typeof s.componentWillMount!="function"||(typeof s.componentWillMount=="function"&&s.componentWillMount(),typeof s.UNSAFE_componentWillMount=="function"&&s.UNSAFE_componentWillMount()),typeof s.componentDidMount=="function"&&(t.flags|=4194308)):(typeof s.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),s.props=r,s.state=l,s.context=u,r=i):(typeof s.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{s=t.stateNode,jx(e,t),i=t.memoizedProps,u=t.type===t.elementType?i:oa(t.type,i),s.props=u,c=t.pendingProps,p=s.context,l=a.contextType,typeof l=="object"&&l!==null?l=Yt(l):(l=Ct(a)?so:it.current,l=nn(t,l));var g=a.getDerivedStateFromProps;(d=typeof g=="function"||typeof s.getSnapshotBeforeUpdate=="function")||typeof s.UNSAFE_componentWillReceiveProps!="function"&&typeof s.componentWillReceiveProps!="function"||(i!==c||p!==l)&&kg(t,s,r,l),ur=!1,p=t.memoizedState,s.state=p,tu(t,r,s,o);var C=t.memoizedState;i!==c||p!==C||Lt.current||ur?(typeof g=="function"&&(Df(t,a,g,r),C=t.memoizedState),(u=ur||wg(t,a,u,r,p,C,l)||!1)?(d||typeof s.UNSAFE_componentWillUpdate!="function"&&typeof s.componentWillUpdate!="function"||(typeof s.componentWillUpdate=="function"&&s.componentWillUpdate(r,C,l),typeof s.UNSAFE_componentWillUpdate=="function"&&s.UNSAFE_componentWillUpdate(r,C,l)),typeof s.componentDidUpdate=="function"&&(t.flags|=4),typeof s.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof s.componentDidUpdate!="function"||i===e.memoizedProps&&p===e.memoizedState||(t.flags|=4),typeof s.getSnapshotBeforeUpdate!="function"||i===e.memoizedProps&&p===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=C),s.props=r,s.state=C,s.context=l,r=u):(typeof s.componentDidUpdate!="function"||i===e.memoizedProps&&p===e.memoizedState||(t.flags|=4),typeof s.getSnapshotBeforeUpdate!="function"||i===e.memoizedProps&&p===e.memoizedState||(t.flags|=1024),r=!1)}return Ff(e,t,a,r,n,o)}function Ff(e,t,a,r,o,n){yy(e,t);var s=(t.flags&128)!==0;if(!r&&!s)return o&&gg(t,a,!1),Ha(e,t,n);r=t.stateNode,Mw.current=t;var i=s&&typeof a.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&s?(t.child=ln(t,e.child,null,n),t.child=ln(t,null,i,n)):ft(e,t,i,n),t.memoizedState=r.state,o&&gg(t,a,!0),t.child}function vy(e){var t=e.stateNode;t.pendingContext?hg(e,t.pendingContext,t.pendingContext!==t.context):t.context&&hg(e,t.context,!1),xp(e,t.containerInfo)}function Mg(e,t,a,r,o){return sn(),cp(o),t.flags|=256,ft(e,t,a,r),t.child}var Bf={dehydrated:null,treeContext:null,retryLane:0};function Of(e){return{baseLanes:e,cachePool:null,transitions:null}}function Ly(e,t,a){var r=t.pendingProps,o=ke.current,n=!1,s=(t.flags&128)!==0,i;if((i=s)||(i=e!==null&&e.memoizedState===null?!1:(o&2)!==0),i?(n=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(o|=1),xe(ke,o&1),e===null)return Af(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?((t.mode&1)===0?t.lanes=1:e.data==="$!"?t.lanes=8:t.lanes=1073741824,null):(s=r.children,e=r.fallback,n?(r=t.mode,n=t.child,s={mode:"hidden",children:s},(r&1)===0&&n!==null?(n.childLanes=0,n.pendingProps=s):n=Lu(s,r,0,null),e=no(e,r,a,null),n.return=t,e.return=t,n.sibling=e,t.child=n,t.child.memoizedState=Of(a),t.memoizedState=Bf,e):kp(t,s));if(o=e.memoizedState,o!==null&&(i=o.dehydrated,i!==null))return Nw(e,t,s,r,i,o,a);if(n){n=r.fallback,s=t.mode,o=e.child,i=o.sibling;var l={mode:"hidden",children:r.children};return(s&1)===0&&t.child!==o?(r=t.child,r.childLanes=0,r.pendingProps=l,t.deletions=null):(r=Cr(o,l),r.subtreeFlags=o.subtreeFlags&14680064),i!==null?n=Cr(i,n):(n=no(n,s,a,null),n.flags|=2),n.return=t,r.return=t,r.sibling=n,t.child=r,r=n,n=t.child,s=e.child.memoizedState,s=s===null?Of(a):{baseLanes:s.baseLanes|a,cachePool:null,transitions:s.transitions},n.memoizedState=s,n.childLanes=e.childLanes&~a,t.memoizedState=Bf,r}return n=e.child,e=n.sibling,r=Cr(n,{mode:"visible",children:r.children}),(t.mode&1)===0&&(r.lanes=a),r.return=t,r.sibling=null,e!==null&&(a=t.deletions,a===null?(t.deletions=[e],t.flags|=16):a.push(e)),t.child=r,t.memoizedState=null,r}function kp(e,t){return t=Lu({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Pl(e,t,a,r){return r!==null&&cp(r),ln(t,e.child,null,a),e=kp(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Nw(e,t,a,r,o,n,s){if(a)return t.flags&256?(t.flags&=-257,r=Qc(Error(D(422))),Pl(e,t,s,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(n=r.fallback,o=t.mode,r=Lu({mode:"visible",children:r.children},o,0,null),n=no(n,o,s,null),n.flags|=2,r.return=t,n.return=t,r.sibling=n,t.child=r,(t.mode&1)!==0&&ln(t,e.child,null,s),t.child.memoizedState=Of(s),t.memoizedState=Bf,n);if((t.mode&1)===0)return Pl(e,t,s,null);if(o.data==="$!"){if(r=o.nextSibling&&o.nextSibling.dataset,r)var i=r.dgst;return r=i,n=Error(D(419)),r=Qc(n,r,void 0),Pl(e,t,s,r)}if(i=(s&e.childLanes)!==0,vt||i){if(r=Ke,r!==null){switch(s&-s){case 4:o=2;break;case 16:o=8;break;case 64: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:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:o=32;break;case 536870912:o=268435456;break;default:o=0}o=(o&(r.suspendedLanes|s))!==0?0:o,o!==0&&o!==n.retryLane&&(n.retryLane=o,za(e,o),la(r,e,o,-1))}return Dp(),r=Qc(Error(D(421))),Pl(e,t,s,r)}return o.data==="$?"?(t.flags|=128,t.child=e.child,t=jw.bind(null,e),o._reactRetry=t,null):(e=n.treeContext,Mt=xr(o.nextSibling),Nt=t,we=!0,sa=null,e!==null&&(Kt[$t++]=Ba,Kt[$t++]=Oa,Kt[$t++]=io,Ba=e.id,Oa=e.overflow,io=t),t=kp(t,r.children),t.flags|=4096,t)}function Ng(e,t,a){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Rf(e.return,t,a)}function Yc(e,t,a,r,o){var n=e.memoizedState;n===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:a,tailMode:o}:(n.isBackwards=t,n.rendering=null,n.renderingStartTime=0,n.last=r,n.tail=a,n.tailMode=o)}function Cy(e,t,a){var r=t.pendingProps,o=r.revealOrder,n=r.tail;if(ft(e,t,r.children,a),r=ke.current,(r&2)!==0)r=r&1|2,t.flags|=128;else{if(e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Ng(e,a,t);else if(e.tag===19)Ng(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}r&=1}if(xe(ke,r),(t.mode&1)===0)t.memoizedState=null;else switch(o){case"forwards":for(a=t.child,o=null;a!==null;)e=a.alternate,e!==null&&au(e)===null&&(o=a),a=a.sibling;a=o,a===null?(o=t.child,t.child=null):(o=a.sibling,a.sibling=null),Yc(t,!1,o,a,n);break;case"backwards":for(a=null,o=t.child,t.child=null;o!==null;){if(e=o.alternate,e!==null&&au(e)===null){t.child=o;break}e=o.sibling,o.sibling=a,a=o,o=e}Yc(t,!0,a,null,n);break;case"together":Yc(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Bl(e,t){(t.mode&1)===0&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Ha(e,t,a){if(e!==null&&(t.dependencies=e.dependencies),uo|=t.lanes,(a&t.childLanes)===0)return null;if(e!==null&&t.child!==e.child)throw Error(D(153));if(t.child!==null){for(e=t.child,a=Cr(e,e.pendingProps),t.child=a,a.return=t;e.sibling!==null;)e=e.sibling,a=a.sibling=Cr(e,e.pendingProps),a.return=t;a.sibling=null}return t.child}function Ew(e,t,a){switch(t.tag){case 3:vy(t),sn();break;case 5:Kx(t);break;case 1:Ct(t.type)&&Ql(t);break;case 4:xp(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,o=t.memoizedProps.value;xe(Jl,r._currentValue),r._currentValue=o;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(xe(ke,ke.current&1),t.flags|=128,null):(a&t.child.childLanes)!==0?Ly(e,t,a):(xe(ke,ke.current&1),e=Ha(e,t,a),e!==null?e.sibling:null);xe(ke,ke.current&1);break;case 19:if(r=(a&t.childLanes)!==0,(e.flags&128)!==0){if(r)return Cy(e,t,a);t.flags|=128}if(o=t.memoizedState,o!==null&&(o.rendering=null,o.tail=null,o.lastEffect=null),xe(ke,ke.current),r)break;return null;case 22:case 23:return t.lanes=0,xy(e,t,a)}return Ha(e,t,a)}var Sy,Vf,Iy,wy;Sy=function(e,t){for(var a=t.child;a!==null;){if(a.tag===5||a.tag===6)e.appendChild(a.stateNode);else if(a.tag!==4&&a.child!==null){a.child.return=a,a=a.child;continue}if(a===t)break;for(;a.sibling===null;){if(a.return===null||a.return===t)return;a=a.return}a.sibling.return=a.return,a=a.sibling}};Vf=function(){};Iy=function(e,t,a,r){var o=e.memoizedProps;if(o!==r){e=t.stateNode,ro(va.current);var n=null;switch(a){case"input":o=nf(e,o),r=nf(e,r),n=[];break;case"select":o=Pe({},o,{value:void 0}),r=Pe({},r,{value:void 0}),n=[];break;case"textarea":o=uf(e,o),r=uf(e,r),n=[];break;default:typeof o.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=$l)}cf(a,r);var s;a=null;for(u in o)if(!r.hasOwnProperty(u)&&o.hasOwnProperty(u)&&o[u]!=null)if(u==="style"){var i=o[u];for(s in i)i.hasOwnProperty(s)&&(a||(a={}),a[s]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(Gs.hasOwnProperty(u)?n||(n=[]):(n=n||[]).push(u,null));for(u in r){var l=r[u];if(i=o?.[u],r.hasOwnProperty(u)&&l!==i&&(l!=null||i!=null))if(u==="style")if(i){for(s in i)!i.hasOwnProperty(s)||l&&l.hasOwnProperty(s)||(a||(a={}),a[s]="");for(s in l)l.hasOwnProperty(s)&&i[s]!==l[s]&&(a||(a={}),a[s]=l[s])}else a||(n||(n=[]),n.push(u,a)),a=l;else u==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,i=i?i.__html:void 0,l!=null&&i!==l&&(n=n||[]).push(u,l)):u==="children"?typeof l!="string"&&typeof l!="number"||(n=n||[]).push(u,""+l):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(Gs.hasOwnProperty(u)?(l!=null&&u==="onScroll"&&ve("scroll",e),n||i===l||(n=[])):(n=n||[]).push(u,l))}a&&(n=n||[]).push("style",a);var u=n;(t.updateQueue=u)&&(t.flags|=4)}};wy=function(e,t,a,r){a!==r&&(t.flags|=4)};function As(e,t){if(!we)switch(e.tailMode){case"hidden":t=e.tail;for(var a=null;t!==null;)t.alternate!==null&&(a=t),t=t.sibling;a===null?e.tail=null:a.sibling=null;break;case"collapsed":a=e.tail;for(var r=null;a!==null;)a.alternate!==null&&(r=a),a=a.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function nt(e){var t=e.alternate!==null&&e.alternate.child===e.child,a=0,r=0;if(t)for(var o=e.child;o!==null;)a|=o.lanes|o.childLanes,r|=o.subtreeFlags&14680064,r|=o.flags&14680064,o.return=e,o=o.sibling;else for(o=e.child;o!==null;)a|=o.lanes|o.childLanes,r|=o.subtreeFlags,r|=o.flags,o.return=e,o=o.sibling;return e.subtreeFlags|=r,e.childLanes=a,t}function Fw(e,t,a){var r=t.pendingProps;switch(dp(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return nt(t),null;case 1:return Ct(t.type)&&Xl(),nt(t),null;case 3:return r=t.stateNode,un(),Le(Lt),Le(it),vp(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(kl(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,sa!==null&&(jf(sa),sa=null))),Vf(e,t),nt(t),null;case 5:yp(t);var o=ro(ri.current);if(a=t.type,e!==null&&t.stateNode!=null)Iy(e,t,a,r,o),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(D(166));return nt(t),null}if(e=ro(va.current),kl(t)){r=t.stateNode,a=t.type;var n=t.memoizedProps;switch(r[xa]=t,r[ti]=n,e=(t.mode&1)!==0,a){case"dialog":ve("cancel",r),ve("close",r);break;case"iframe":case"object":case"embed":ve("load",r);break;case"video":case"audio":for(o=0;o<Fs.length;o++)ve(Fs[o],r);break;case"source":ve("error",r);break;case"img":case"image":case"link":ve("error",r),ve("load",r);break;case"details":ve("toggle",r);break;case"input":zh(r,n),ve("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!n.multiple},ve("invalid",r);break;case"textarea":qh(r,n),ve("invalid",r)}cf(a,n),o=null;for(var s in n)if(n.hasOwnProperty(s)){var i=n[s];s==="children"?typeof i=="string"?r.textContent!==i&&(n.suppressHydrationWarning!==!0&&wl(r.textContent,i,e),o=["children",i]):typeof i=="number"&&r.textContent!==""+i&&(n.suppressHydrationWarning!==!0&&wl(r.textContent,i,e),o=["children",""+i]):Gs.hasOwnProperty(s)&&i!=null&&s==="onScroll"&&ve("scroll",r)}switch(a){case"input":fl(r),Hh(r,n,!0);break;case"textarea":fl(r),Wh(r);break;case"select":case"option":break;default:typeof n.onClick=="function"&&(r.onclick=$l)}r=o,t.updateQueue=r,r!==null&&(t.flags|=4)}else{s=o.nodeType===9?o:o.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=Zg(a)),e==="http://www.w3.org/1999/xhtml"?a==="script"?(e=s.createElement("div"),e.innerHTML="<script></script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=s.createElement(a,{is:r.is}):(e=s.createElement(a),a==="select"&&(s=e,r.multiple?s.multiple=!0:r.size&&(s.size=r.size))):e=s.createElementNS(e,a),e[xa]=t,e[ti]=r,Sy(e,t,!1,!1),t.stateNode=e;e:{switch(s=ff(a,r),a){case"dialog":ve("cancel",e),ve("close",e),o=r;break;case"iframe":case"object":case"embed":ve("load",e),o=r;break;case"video":case"audio":for(o=0;o<Fs.length;o++)ve(Fs[o],e);o=r;break;case"source":ve("error",e),o=r;break;case"img":case"image":case"link":ve("error",e),ve("load",e),o=r;break;case"details":ve("toggle",e),o=r;break;case"input":zh(e,r),o=nf(e,r),ve("invalid",e);break;case"option":o=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},o=Pe({},r,{value:void 0}),ve("invalid",e);break;case"textarea":qh(e,r),o=uf(e,r),ve("invalid",e);break;default:o=r}cf(a,o),i=o;for(n in i)if(i.hasOwnProperty(n)){var l=i[n];n==="style"?tx(e,l):n==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&Jg(e,l)):n==="children"?typeof l=="string"?(a!=="textarea"||l!=="")&&js(e,l):typeof l=="number"&&js(e,""+l):n!=="suppressContentEditableWarning"&&n!=="suppressHydrationWarning"&&n!=="autoFocus"&&(Gs.hasOwnProperty(n)?l!=null&&n==="onScroll"&&ve("scroll",e):l!=null&&Xf(e,n,l,s))}switch(a){case"input":fl(e),Hh(e,r,!1);break;case"textarea":fl(e),Wh(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Sr(r.value));break;case"select":e.multiple=!!r.multiple,n=r.value,n!=null?Zo(e,!!r.multiple,n,!1):r.defaultValue!=null&&Zo(e,!!r.multiple,r.defaultValue,!0);break;default:typeof o.onClick=="function"&&(e.onclick=$l)}switch(a){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}}r&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return nt(t),null;case 6:if(e&&t.stateNode!=null)wy(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(D(166));if(a=ro(ri.current),ro(va.current),kl(t)){if(r=t.stateNode,a=t.memoizedProps,r[xa]=t,(n=r.nodeValue!==a)&&(e=Nt,e!==null))switch(e.tag){case 3:wl(r.nodeValue,a,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&wl(r.nodeValue,a,(e.mode&1)!==0)}n&&(t.flags|=4)}else r=(a.nodeType===9?a:a.ownerDocument).createTextNode(r),r[xa]=t,t.stateNode=r}return nt(t),null;case 13:if(Le(ke),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(we&&Mt!==null&&(t.mode&1)!==0&&(t.flags&128)===0)Hx(),sn(),t.flags|=98560,n=!1;else if(n=kl(t),r!==null&&r.dehydrated!==null){if(e===null){if(!n)throw Error(D(318));if(n=t.memoizedState,n=n!==null?n.dehydrated:null,!n)throw Error(D(317));n[xa]=t}else sn(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;nt(t),n=!1}else sa!==null&&(jf(sa),sa=null),n=!0;if(!n)return t.flags&65536?t:null}return(t.flags&128)!==0?(t.lanes=a,t):(r=r!==null,r!==(e!==null&&e.memoizedState!==null)&&r&&(t.child.flags|=8192,(t.mode&1)!==0&&(e===null||(ke.current&1)!==0?ze===0&&(ze=3):Dp())),t.updateQueue!==null&&(t.flags|=4),nt(t),null);case 4:return un(),Vf(e,t),e===null&&Js(t.stateNode.containerInfo),nt(t),null;case 10:return mp(t.type._context),nt(t),null;case 17:return Ct(t.type)&&Xl(),nt(t),null;case 19:if(Le(ke),n=t.memoizedState,n===null)return nt(t),null;if(r=(t.flags&128)!==0,s=n.rendering,s===null)if(r)As(n,!1);else{if(ze!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(s=au(e),s!==null){for(t.flags|=128,As(n,!1),r=s.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=a,a=t.child;a!==null;)n=a,e=r,n.flags&=14680066,s=n.alternate,s===null?(n.childLanes=0,n.lanes=e,n.child=null,n.subtreeFlags=0,n.memoizedProps=null,n.memoizedState=null,n.updateQueue=null,n.dependencies=null,n.stateNode=null):(n.childLanes=s.childLanes,n.lanes=s.lanes,n.child=s.child,n.subtreeFlags=0,n.deletions=null,n.memoizedProps=s.memoizedProps,n.memoizedState=s.memoizedState,n.updateQueue=s.updateQueue,n.type=s.type,e=s.dependencies,n.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),a=a.sibling;return xe(ke,ke.current&1|2),t.child}e=e.sibling}n.tail!==null&&Ne()>cn&&(t.flags|=128,r=!0,As(n,!1),t.lanes=4194304)}else{if(!r)if(e=au(s),e!==null){if(t.flags|=128,r=!0,a=e.updateQueue,a!==null&&(t.updateQueue=a,t.flags|=4),As(n,!0),n.tail===null&&n.tailMode==="hidden"&&!s.alternate&&!we)return nt(t),null}else 2*Ne()-n.renderingStartTime>cn&&a!==1073741824&&(t.flags|=128,r=!0,As(n,!1),t.lanes=4194304);n.isBackwards?(s.sibling=t.child,t.child=s):(a=n.last,a!==null?a.sibling=s:t.child=s,n.last=s)}return n.tail!==null?(t=n.tail,n.rendering=t,n.tail=t.sibling,n.renderingStartTime=Ne(),t.sibling=null,a=ke.current,xe(ke,r?a&1|2:a&1),t):(nt(t),null);case 22:case 23:return Rp(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&(t.mode&1)!==0?(Dt&1073741824)!==0&&(nt(t),t.subtreeFlags&6&&(t.flags|=8192)):nt(t),null;case 24:return null;case 25:return null}throw Error(D(156,t.tag))}function Bw(e,t){switch(dp(t),t.tag){case 1:return Ct(t.type)&&Xl(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return un(),Le(Lt),Le(it),vp(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 5:return yp(t),null;case 13:if(Le(ke),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(D(340));sn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Le(ke),null;case 4:return un(),null;case 10:return mp(t.type._context),null;case 22:case 23:return Rp(),null;case 24:return null;default:return null}}var Tl=!1,st=!1,Ow=typeof WeakSet=="function"?WeakSet:Set,O=null;function Qo(e,t){var a=e.ref;if(a!==null)if(typeof a=="function")try{a(null)}catch(r){Re(e,t,r)}else a.current=null}function Uf(e,t,a){try{a()}catch(r){Re(e,t,r)}}var Eg=!1;function Vw(e,t){if(Sf=Gl,e=Ax(),lp(e)){if("selectionStart"in e)var a={start:e.selectionStart,end:e.selectionEnd};else e:{a=(a=e.ownerDocument)&&a.defaultView||window;var r=a.getSelection&&a.getSelection();if(r&&r.rangeCount!==0){a=r.anchorNode;var o=r.anchorOffset,n=r.focusNode;r=r.focusOffset;try{a.nodeType,n.nodeType}catch{a=null;break e}var s=0,i=-1,l=-1,u=0,d=0,c=e,p=null;t:for(;;){for(var g;c!==a||o!==0&&c.nodeType!==3||(i=s+o),c!==n||r!==0&&c.nodeType!==3||(l=s+r),c.nodeType===3&&(s+=c.nodeValue.length),(g=c.firstChild)!==null;)p=c,c=g;for(;;){if(c===e)break t;if(p===a&&++u===o&&(i=s),p===n&&++d===r&&(l=s),(g=c.nextSibling)!==null)break;c=p,p=c.parentNode}c=g}a=i===-1||l===-1?null:{start:i,end:l}}else a=null}a=a||{start:0,end:0}}else a=null;for(If={focusedElem:e,selectionRange:a},Gl=!1,O=t;O!==null;)if(t=O,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,O=e;else for(;O!==null;){t=O;try{var C=t.alternate;if((t.flags&1024)!==0)switch(t.tag){case 0:case 11:case 15:break;case 1:if(C!==null){var L=C.memoizedProps,S=C.memoizedState,h=t.stateNode,m=h.getSnapshotBeforeUpdate(t.elementType===t.type?L:oa(t.type,L),S);h.__reactInternalSnapshotBeforeUpdate=m}break;case 3:var x=t.stateNode.containerInfo;x.nodeType===1?x.textContent="":x.nodeType===9&&x.documentElement&&x.removeChild(x.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(D(163))}}catch(I){Re(t,t.return,I)}if(e=t.sibling,e!==null){e.return=t.return,O=e;break}O=t.return}return C=Eg,Eg=!1,C}function Hs(e,t,a){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var o=r=r.next;do{if((o.tag&e)===e){var n=o.destroy;o.destroy=void 0,n!==void 0&&Uf(t,a,n)}o=o.next}while(o!==r)}}function yu(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var a=t=t.next;do{if((a.tag&e)===e){var r=a.create;a.destroy=r()}a=a.next}while(a!==t)}}function _f(e){var t=e.ref;if(t!==null){var a=e.stateNode;switch(e.tag){case 5:e=a;break;default:e=a}typeof t=="function"?t(e):t.current=e}}function ky(e){var t=e.alternate;t!==null&&(e.alternate=null,ky(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[xa],delete t[ti],delete t[bf],delete t[Lw],delete t[Cw])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function by(e){return e.tag===5||e.tag===3||e.tag===4}function Fg(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||by(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.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 zf(e,t,a){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?a.nodeType===8?a.parentNode.insertBefore(e,t):a.insertBefore(e,t):(a.nodeType===8?(t=a.parentNode,t.insertBefore(e,a)):(t=a,t.appendChild(e)),a=a._reactRootContainer,a!=null||t.onclick!==null||(t.onclick=$l));else if(r!==4&&(e=e.child,e!==null))for(zf(e,t,a),e=e.sibling;e!==null;)zf(e,t,a),e=e.sibling}function Hf(e,t,a){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?a.insertBefore(e,t):a.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(Hf(e,t,a),e=e.sibling;e!==null;)Hf(e,t,a),e=e.sibling}var Qe=null,na=!1;function ir(e,t,a){for(a=a.child;a!==null;)Py(e,t,a),a=a.sibling}function Py(e,t,a){if(ya&&typeof ya.onCommitFiberUnmount=="function")try{ya.onCommitFiberUnmount(du,a)}catch{}switch(a.tag){case 5:st||Qo(a,t);case 6:var r=Qe,o=na;Qe=null,ir(e,t,a),Qe=r,na=o,Qe!==null&&(na?(e=Qe,a=a.stateNode,e.nodeType===8?e.parentNode.removeChild(a):e.removeChild(a)):Qe.removeChild(a.stateNode));break;case 18:Qe!==null&&(na?(e=Qe,a=a.stateNode,e.nodeType===8?Wc(e.parentNode,a):e.nodeType===1&&Wc(e,a),Qs(e)):Wc(Qe,a.stateNode));break;case 4:r=Qe,o=na,Qe=a.stateNode.containerInfo,na=!0,ir(e,t,a),Qe=r,na=o;break;case 0:case 11:case 14:case 15:if(!st&&(r=a.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){o=r=r.next;do{var n=o,s=n.destroy;n=n.tag,s!==void 0&&((n&2)!==0||(n&4)!==0)&&Uf(a,t,s),o=o.next}while(o!==r)}ir(e,t,a);break;case 1:if(!st&&(Qo(a,t),r=a.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=a.memoizedProps,r.state=a.memoizedState,r.componentWillUnmount()}catch(i){Re(a,t,i)}ir(e,t,a);break;case 21:ir(e,t,a);break;case 22:a.mode&1?(st=(r=st)||a.memoizedState!==null,ir(e,t,a),st=r):ir(e,t,a);break;default:ir(e,t,a)}}function Bg(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var a=e.stateNode;a===null&&(a=e.stateNode=new Ow),t.forEach(function(r){var o=Kw.bind(null,e,r);a.has(r)||(a.add(r),r.then(o,o))})}}function ra(e,t){var a=t.deletions;if(a!==null)for(var r=0;r<a.length;r++){var o=a[r];try{var n=e,s=t,i=s;e:for(;i!==null;){switch(i.tag){case 5:Qe=i.stateNode,na=!1;break e;case 3:Qe=i.stateNode.containerInfo,na=!0;break e;case 4:Qe=i.stateNode.containerInfo,na=!0;break e}i=i.return}if(Qe===null)throw Error(D(160));Py(n,s,o),Qe=null,na=!1;var l=o.alternate;l!==null&&(l.return=null),o.return=null}catch(u){Re(o,t,u)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Ty(t,e),t=t.sibling}function Ty(e,t){var a=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(ra(t,e),ha(e),r&4){try{Hs(3,e,e.return),yu(3,e)}catch(L){Re(e,e.return,L)}try{Hs(5,e,e.return)}catch(L){Re(e,e.return,L)}}break;case 1:ra(t,e),ha(e),r&512&&a!==null&&Qo(a,a.return);break;case 5:if(ra(t,e),ha(e),r&512&&a!==null&&Qo(a,a.return),e.flags&32){var o=e.stateNode;try{js(o,"")}catch(L){Re(e,e.return,L)}}if(r&4&&(o=e.stateNode,o!=null)){var n=e.memoizedProps,s=a!==null?a.memoizedProps:n,i=e.type,l=e.updateQueue;if(e.updateQueue=null,l!==null)try{i==="input"&&n.type==="radio"&&n.name!=null&&Qg(o,n),ff(i,s);var u=ff(i,n);for(s=0;s<l.length;s+=2){var d=l[s],c=l[s+1];d==="style"?tx(o,c):d==="dangerouslySetInnerHTML"?Jg(o,c):d==="children"?js(o,c):Xf(o,d,c,u)}switch(i){case"input":sf(o,n);break;case"textarea":Yg(o,n);break;case"select":var p=o._wrapperState.wasMultiple;o._wrapperState.wasMultiple=!!n.multiple;var g=n.value;g!=null?Zo(o,!!n.multiple,g,!1):p!==!!n.multiple&&(n.defaultValue!=null?Zo(o,!!n.multiple,n.defaultValue,!0):Zo(o,!!n.multiple,n.multiple?[]:"",!1))}o[ti]=n}catch(L){Re(e,e.return,L)}}break;case 6:if(ra(t,e),ha(e),r&4){if(e.stateNode===null)throw Error(D(162));o=e.stateNode,n=e.memoizedProps;try{o.nodeValue=n}catch(L){Re(e,e.return,L)}}break;case 3:if(ra(t,e),ha(e),r&4&&a!==null&&a.memoizedState.isDehydrated)try{Qs(t.containerInfo)}catch(L){Re(e,e.return,L)}break;case 4:ra(t,e),ha(e);break;case 13:ra(t,e),ha(e),o=e.child,o.flags&8192&&(n=o.memoizedState!==null,o.stateNode.isHidden=n,!n||o.alternate!==null&&o.alternate.memoizedState!==null||(Tp=Ne())),r&4&&Bg(e);break;case 22:if(d=a!==null&&a.memoizedState!==null,e.mode&1?(st=(u=st)||d,ra(t,e),st=u):ra(t,e),ha(e),r&8192){if(u=e.memoizedState!==null,(e.stateNode.isHidden=u)&&!d&&(e.mode&1)!==0)for(O=e,d=e.child;d!==null;){for(c=O=d;O!==null;){switch(p=O,g=p.child,p.tag){case 0:case 11:case 14:case 15:Hs(4,p,p.return);break;case 1:Qo(p,p.return);var C=p.stateNode;if(typeof C.componentWillUnmount=="function"){r=p,a=p.return;try{t=r,C.props=t.memoizedProps,C.state=t.memoizedState,C.componentWillUnmount()}catch(L){Re(r,a,L)}}break;case 5:Qo(p,p.return);break;case 22:if(p.memoizedState!==null){Vg(c);continue}}g!==null?(g.return=p,O=g):Vg(c)}d=d.sibling}e:for(d=null,c=e;;){if(c.tag===5){if(d===null){d=c;try{o=c.stateNode,u?(n=o.style,typeof n.setProperty=="function"?n.setProperty("display","none","important"):n.display="none"):(i=c.stateNode,l=c.memoizedProps.style,s=l!=null&&l.hasOwnProperty("display")?l.display:null,i.style.display=ex("display",s))}catch(L){Re(e,e.return,L)}}}else if(c.tag===6){if(d===null)try{c.stateNode.nodeValue=u?"":c.memoizedProps}catch(L){Re(e,e.return,L)}}else if((c.tag!==22&&c.tag!==23||c.memoizedState===null||c===e)&&c.child!==null){c.child.return=c,c=c.child;continue}if(c===e)break e;for(;c.sibling===null;){if(c.return===null||c.return===e)break e;d===c&&(d=null),c=c.return}d===c&&(d=null),c.sibling.return=c.return,c=c.sibling}}break;case 19:ra(t,e),ha(e),r&4&&Bg(e);break;case 21:break;default:ra(t,e),ha(e)}}function ha(e){var t=e.flags;if(t&2){try{e:{for(var a=e.return;a!==null;){if(by(a)){var r=a;break e}a=a.return}throw Error(D(160))}switch(r.tag){case 5:var o=r.stateNode;r.flags&32&&(js(o,""),r.flags&=-33);var n=Fg(e);Hf(e,n,o);break;case 3:case 4:var s=r.stateNode.containerInfo,i=Fg(e);zf(e,i,s);break;default:throw Error(D(161))}}catch(l){Re(e,e.return,l)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Uw(e,t,a){O=e,Ay(e,t,a)}function Ay(e,t,a){for(var r=(e.mode&1)!==0;O!==null;){var o=O,n=o.child;if(o.tag===22&&r){var s=o.memoizedState!==null||Tl;if(!s){var i=o.alternate,l=i!==null&&i.memoizedState!==null||st;i=Tl;var u=st;if(Tl=s,(st=l)&&!u)for(O=o;O!==null;)s=O,l=s.child,s.tag===22&&s.memoizedState!==null?Ug(o):l!==null?(l.return=s,O=l):Ug(o);for(;n!==null;)O=n,Ay(n,t,a),n=n.sibling;O=o,Tl=i,st=u}Og(e,t,a)}else(o.subtreeFlags&8772)!==0&&n!==null?(n.return=o,O=n):Og(e,t,a)}}function Og(e){for(;O!==null;){var t=O;if((t.flags&8772)!==0){var a=t.alternate;try{if((t.flags&8772)!==0)switch(t.tag){case 0:case 11:case 15:st||yu(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!st)if(a===null)r.componentDidMount();else{var o=t.elementType===t.type?a.memoizedProps:oa(t.type,a.memoizedProps);r.componentDidUpdate(o,a.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var n=t.updateQueue;n!==null&&Cg(t,n,r);break;case 3:var s=t.updateQueue;if(s!==null){if(a=null,t.child!==null)switch(t.child.tag){case 5:a=t.child.stateNode;break;case 1:a=t.child.stateNode}Cg(t,s,a)}break;case 5:var i=t.stateNode;if(a===null&&t.flags&4){a=i;var l=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":l.autoFocus&&a.focus();break;case"img":l.src&&(a.src=l.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var u=t.alternate;if(u!==null){var d=u.memoizedState;if(d!==null){var c=d.dehydrated;c!==null&&Qs(c)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(D(163))}st||t.flags&512&&_f(t)}catch(p){Re(t,t.return,p)}}if(t===e){O=null;break}if(a=t.sibling,a!==null){a.return=t.return,O=a;break}O=t.return}}function Vg(e){for(;O!==null;){var t=O;if(t===e){O=null;break}var a=t.sibling;if(a!==null){a.return=t.return,O=a;break}O=t.return}}function Ug(e){for(;O!==null;){var t=O;try{switch(t.tag){case 0:case 11:case 15:var a=t.return;try{yu(4,t)}catch(l){Re(t,a,l)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var o=t.return;try{r.componentDidMount()}catch(l){Re(t,o,l)}}var n=t.return;try{_f(t)}catch(l){Re(t,n,l)}break;case 5:var s=t.return;try{_f(t)}catch(l){Re(t,s,l)}}}catch(l){Re(t,t.return,l)}if(t===e){O=null;break}var i=t.sibling;if(i!==null){i.return=t.return,O=i;break}O=t.return}}var _w=Math.ceil,nu=qa.ReactCurrentDispatcher,bp=qa.ReactCurrentOwner,Qt=qa.ReactCurrentBatchConfig,le=0,Ke=null,Oe=null,Ye=0,Dt=0,Yo=kr(0),ze=0,ii=null,uo=0,vu=0,Pp=0,qs=null,yt=null,Tp=0,cn=1/0,Ea=null,su=!1,qf=null,vr=null,Al=!1,pr=null,iu=0,Ws=0,Wf=null,Ol=-1,Vl=0;function pt(){return(le&6)!==0?Ne():Ol!==-1?Ol:Ol=Ne()}function Lr(e){return(e.mode&1)===0?1:(le&2)!==0&&Ye!==0?Ye&-Ye:Iw.transition!==null?(Vl===0&&(Vl=px()),Vl):(e=pe,e!==0||(e=window.event,e=e===void 0?16:Lx(e.type)),e)}function la(e,t,a,r){if(50<Ws)throw Ws=0,Wf=null,Error(D(185));li(e,a,r),((le&2)===0||e!==Ke)&&(e===Ke&&((le&2)===0&&(vu|=a),ze===4&&cr(e,Ye)),St(e,r),a===1&&le===0&&(t.mode&1)===0&&(cn=Ne()+500,hu&&br()))}function St(e,t){var a=e.callbackNode;kI(e,t);var r=Wl(e,e===Ke?Ye:0);if(r===0)a!==null&&Kh(a),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(a!=null&&Kh(a),t===1)e.tag===0?Sw(_g.bind(null,e)):Ux(_g.bind(null,e)),yw(function(){(le&6)===0&&br()}),a=null;else{switch(mx(r)){case 1:a=ep;break;case 4:a=cx;break;case 16:a=ql;break;case 536870912:a=fx;break;default:a=ql}a=Oy(a,Ry.bind(null,e))}e.callbackPriority=t,e.callbackNode=a}}function Ry(e,t){if(Ol=-1,Vl=0,(le&6)!==0)throw Error(D(327));var a=e.callbackNode;if(rn()&&e.callbackNode!==a)return null;var r=Wl(e,e===Ke?Ye:0);if(r===0)return null;if((r&30)!==0||(r&e.expiredLanes)!==0||t)t=lu(e,r);else{t=r;var o=le;le|=2;var n=My();(Ke!==e||Ye!==t)&&(Ea=null,cn=Ne()+500,oo(e,t));do try{qw();break}catch(i){Dy(e,i)}while(!0);pp(),nu.current=n,le=o,Oe!==null?t=0:(Ke=null,Ye=0,t=ze)}if(t!==0){if(t===2&&(o=xf(e),o!==0&&(r=o,t=Gf(e,o))),t===1)throw a=ii,oo(e,0),cr(e,r),St(e,Ne()),a;if(t===6)cr(e,r);else{if(o=e.current.alternate,(r&30)===0&&!zw(o)&&(t=lu(e,r),t===2&&(n=xf(e),n!==0&&(r=n,t=Gf(e,n))),t===1))throw a=ii,oo(e,0),cr(e,r),St(e,Ne()),a;switch(e.finishedWork=o,e.finishedLanes=r,t){case 0:case 1:throw Error(D(345));case 2:eo(e,yt,Ea);break;case 3:if(cr(e,r),(r&130023424)===r&&(t=Tp+500-Ne(),10<t)){if(Wl(e,0)!==0)break;if(o=e.suspendedLanes,(o&r)!==r){pt(),e.pingedLanes|=e.suspendedLanes&o;break}e.timeoutHandle=kf(eo.bind(null,e,yt,Ea),t);break}eo(e,yt,Ea);break;case 4:if(cr(e,r),(r&4194240)===r)break;for(t=e.eventTimes,o=-1;0<r;){var s=31-ia(r);n=1<<s,s=t[s],s>o&&(o=s),r&=~n}if(r=o,r=Ne()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*_w(r/1960))-r,10<r){e.timeoutHandle=kf(eo.bind(null,e,yt,Ea),r);break}eo(e,yt,Ea);break;case 5:eo(e,yt,Ea);break;default:throw Error(D(329))}}}return St(e,Ne()),e.callbackNode===a?Ry.bind(null,e):null}function Gf(e,t){var a=qs;return e.current.memoizedState.isDehydrated&&(oo(e,t).flags|=256),e=lu(e,t),e!==2&&(t=yt,yt=a,t!==null&&jf(t)),e}function jf(e){yt===null?yt=e:yt.push.apply(yt,e)}function zw(e){for(var t=e;;){if(t.flags&16384){var a=t.updateQueue;if(a!==null&&(a=a.stores,a!==null))for(var r=0;r<a.length;r++){var o=a[r],n=o.getSnapshot;o=o.value;try{if(!ua(n(),o))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 cr(e,t){for(t&=~Pp,t&=~vu,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var a=31-ia(t),r=1<<a;e[a]=-1,t&=~r}}function _g(e){if((le&6)!==0)throw Error(D(327));rn();var t=Wl(e,0);if((t&1)===0)return St(e,Ne()),null;var a=lu(e,t);if(e.tag!==0&&a===2){var r=xf(e);r!==0&&(t=r,a=Gf(e,r))}if(a===1)throw a=ii,oo(e,0),cr(e,t),St(e,Ne()),a;if(a===6)throw Error(D(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,eo(e,yt,Ea),St(e,Ne()),null}function Ap(e,t){var a=le;le|=1;try{return e(t)}finally{le=a,le===0&&(cn=Ne()+500,hu&&br())}}function co(e){pr!==null&&pr.tag===0&&(le&6)===0&&rn();var t=le;le|=1;var a=Qt.transition,r=pe;try{if(Qt.transition=null,pe=1,e)return e()}finally{pe=r,Qt.transition=a,le=t,(le&6)===0&&br()}}function Rp(){Dt=Yo.current,Le(Yo)}function oo(e,t){e.finishedWork=null,e.finishedLanes=0;var a=e.timeoutHandle;if(a!==-1&&(e.timeoutHandle=-1,xw(a)),Oe!==null)for(a=Oe.return;a!==null;){var r=a;switch(dp(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&Xl();break;case 3:un(),Le(Lt),Le(it),vp();break;case 5:yp(r);break;case 4:un();break;case 13:Le(ke);break;case 19:Le(ke);break;case 10:mp(r.type._context);break;case 22:case 23:Rp()}a=a.return}if(Ke=e,Oe=e=Cr(e.current,null),Ye=Dt=t,ze=0,ii=null,Pp=vu=uo=0,yt=qs=null,ao!==null){for(t=0;t<ao.length;t++)if(a=ao[t],r=a.interleaved,r!==null){a.interleaved=null;var o=r.next,n=a.pending;if(n!==null){var s=n.next;n.next=o,r.next=s}a.pending=r}ao=null}return e}function Dy(e,t){do{var a=Oe;try{if(pp(),El.current=ou,ru){for(var r=be.memoizedState;r!==null;){var o=r.queue;o!==null&&(o.pending=null),r=r.next}ru=!1}if(lo=0,je=_e=be=null,zs=!1,oi=0,bp.current=null,a===null||a.return===null){ze=1,ii=t,Oe=null;break}e:{var n=e,s=a.return,i=a,l=t;if(t=Ye,i.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){var u=l,d=i,c=d.tag;if((d.mode&1)===0&&(c===0||c===11||c===15)){var p=d.alternate;p?(d.updateQueue=p.updateQueue,d.memoizedState=p.memoizedState,d.lanes=p.lanes):(d.updateQueue=null,d.memoizedState=null)}var g=Pg(s);if(g!==null){g.flags&=-257,Tg(g,s,i,n,t),g.mode&1&&bg(n,u,t),t=g,l=u;var C=t.updateQueue;if(C===null){var L=new Set;L.add(l),t.updateQueue=L}else C.add(l);break e}else{if((t&1)===0){bg(n,u,t),Dp();break e}l=Error(D(426))}}else if(we&&i.mode&1){var S=Pg(s);if(S!==null){(S.flags&65536)===0&&(S.flags|=256),Tg(S,s,i,n,t),cp(dn(l,i));break e}}n=l=dn(l,i),ze!==4&&(ze=2),qs===null?qs=[n]:qs.push(n),n=s;do{switch(n.tag){case 3:n.flags|=65536,t&=-t,n.lanes|=t;var h=my(n,l,t);Lg(n,h);break e;case 1:i=l;var m=n.type,x=n.stateNode;if((n.flags&128)===0&&(typeof m.getDerivedStateFromError=="function"||x!==null&&typeof x.componentDidCatch=="function"&&(vr===null||!vr.has(x)))){n.flags|=65536,t&=-t,n.lanes|=t;var I=hy(n,i,t);Lg(n,I);break e}}n=n.return}while(n!==null)}Ey(a)}catch(k){t=k,Oe===a&&a!==null&&(Oe=a=a.return);continue}break}while(!0)}function My(){var e=nu.current;return nu.current=ou,e===null?ou:e}function Dp(){(ze===0||ze===3||ze===2)&&(ze=4),Ke===null||(uo&268435455)===0&&(vu&268435455)===0||cr(Ke,Ye)}function lu(e,t){var a=le;le|=2;var r=My();(Ke!==e||Ye!==t)&&(Ea=null,oo(e,t));do try{Hw();break}catch(o){Dy(e,o)}while(!0);if(pp(),le=a,nu.current=r,Oe!==null)throw Error(D(261));return Ke=null,Ye=0,ze}function Hw(){for(;Oe!==null;)Ny(Oe)}function qw(){for(;Oe!==null&&!gI();)Ny(Oe)}function Ny(e){var t=By(e.alternate,e,Dt);e.memoizedProps=e.pendingProps,t===null?Ey(e):Oe=t,bp.current=null}function Ey(e){var t=e;do{var a=t.alternate;if(e=t.return,(t.flags&32768)===0){if(a=Fw(a,t,Dt),a!==null){Oe=a;return}}else{if(a=Bw(a,t),a!==null){a.flags&=32767,Oe=a;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{ze=6,Oe=null;return}}if(t=t.sibling,t!==null){Oe=t;return}Oe=t=e}while(t!==null);ze===0&&(ze=5)}function eo(e,t,a){var r=pe,o=Qt.transition;try{Qt.transition=null,pe=1,Ww(e,t,a,r)}finally{Qt.transition=o,pe=r}return null}function Ww(e,t,a,r){do rn();while(pr!==null);if((le&6)!==0)throw Error(D(327));a=e.finishedWork;var o=e.finishedLanes;if(a===null)return null;if(e.finishedWork=null,e.finishedLanes=0,a===e.current)throw Error(D(177));e.callbackNode=null,e.callbackPriority=0;var n=a.lanes|a.childLanes;if(bI(e,n),e===Ke&&(Oe=Ke=null,Ye=0),(a.subtreeFlags&2064)===0&&(a.flags&2064)===0||Al||(Al=!0,Oy(ql,function(){return rn(),null})),n=(a.flags&15990)!==0,(a.subtreeFlags&15990)!==0||n){n=Qt.transition,Qt.transition=null;var s=pe;pe=1;var i=le;le|=4,bp.current=null,Vw(e,a),Ty(a,e),fw(If),Gl=!!Sf,If=Sf=null,e.current=a,Uw(a,e,o),xI(),le=i,pe=s,Qt.transition=n}else e.current=a;if(Al&&(Al=!1,pr=e,iu=o),n=e.pendingLanes,n===0&&(vr=null),LI(a.stateNode,r),St(e,Ne()),t!==null)for(r=e.onRecoverableError,a=0;a<t.length;a++)o=t[a],r(o.value,{componentStack:o.stack,digest:o.digest});if(su)throw su=!1,e=qf,qf=null,e;return(iu&1)!==0&&e.tag!==0&&rn(),n=e.pendingLanes,(n&1)!==0?e===Wf?Ws++:(Ws=0,Wf=e):Ws=0,br(),null}function rn(){if(pr!==null){var e=mx(iu),t=Qt.transition,a=pe;try{if(Qt.transition=null,pe=16>e?16:e,pr===null)var r=!1;else{if(e=pr,pr=null,iu=0,(le&6)!==0)throw Error(D(331));var o=le;for(le|=4,O=e.current;O!==null;){var n=O,s=n.child;if((O.flags&16)!==0){var i=n.deletions;if(i!==null){for(var l=0;l<i.length;l++){var u=i[l];for(O=u;O!==null;){var d=O;switch(d.tag){case 0:case 11:case 15:Hs(8,d,n)}var c=d.child;if(c!==null)c.return=d,O=c;else for(;O!==null;){d=O;var p=d.sibling,g=d.return;if(ky(d),d===u){O=null;break}if(p!==null){p.return=g,O=p;break}O=g}}}var C=n.alternate;if(C!==null){var L=C.child;if(L!==null){C.child=null;do{var S=L.sibling;L.sibling=null,L=S}while(L!==null)}}O=n}}if((n.subtreeFlags&2064)!==0&&s!==null)s.return=n,O=s;else e:for(;O!==null;){if(n=O,(n.flags&2048)!==0)switch(n.tag){case 0:case 11:case 15:Hs(9,n,n.return)}var h=n.sibling;if(h!==null){h.return=n.return,O=h;break e}O=n.return}}var m=e.current;for(O=m;O!==null;){s=O;var x=s.child;if((s.subtreeFlags&2064)!==0&&x!==null)x.return=s,O=x;else e:for(s=m;O!==null;){if(i=O,(i.flags&2048)!==0)try{switch(i.tag){case 0:case 11:case 15:yu(9,i)}}catch(k){Re(i,i.return,k)}if(i===s){O=null;break e}var I=i.sibling;if(I!==null){I.return=i.return,O=I;break e}O=i.return}}if(le=o,br(),ya&&typeof ya.onPostCommitFiberRoot=="function")try{ya.onPostCommitFiberRoot(du,e)}catch{}r=!0}return r}finally{pe=a,Qt.transition=t}}return!1}function zg(e,t,a){t=dn(a,t),t=my(e,t,1),e=yr(e,t,1),t=pt(),e!==null&&(li(e,1,t),St(e,t))}function Re(e,t,a){if(e.tag===3)zg(e,e,a);else for(;t!==null;){if(t.tag===3){zg(t,e,a);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(vr===null||!vr.has(r))){e=dn(a,e),e=hy(t,e,1),t=yr(t,e,1),e=pt(),t!==null&&(li(t,1,e),St(t,e));break}}t=t.return}}function Gw(e,t,a){var r=e.pingCache;r!==null&&r.delete(t),t=pt(),e.pingedLanes|=e.suspendedLanes&a,Ke===e&&(Ye&a)===a&&(ze===4||ze===3&&(Ye&130023424)===Ye&&500>Ne()-Tp?oo(e,0):Pp|=a),St(e,t)}function Fy(e,t){t===0&&((e.mode&1)===0?t=1:(t=hl,hl<<=1,(hl&130023424)===0&&(hl=4194304)));var a=pt();e=za(e,t),e!==null&&(li(e,t,a),St(e,a))}function jw(e){var t=e.memoizedState,a=0;t!==null&&(a=t.retryLane),Fy(e,a)}function Kw(e,t){var a=0;switch(e.tag){case 13:var r=e.stateNode,o=e.memoizedState;o!==null&&(a=o.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(D(314))}r!==null&&r.delete(t),Fy(e,a)}var By;By=function(e,t,a){if(e!==null)if(e.memoizedProps!==t.pendingProps||Lt.current)vt=!0;else{if((e.lanes&a)===0&&(t.flags&128)===0)return vt=!1,Ew(e,t,a);vt=(e.flags&131072)!==0}else vt=!1,we&&(t.flags&1048576)!==0&&_x(t,Zl,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Bl(e,t),e=t.pendingProps;var o=nn(t,it.current);an(t,a),o=Cp(null,t,r,e,o,a);var n=Sp();return t.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Ct(r)?(n=!0,Ql(t)):n=!1,t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,gp(t),o.updater=xu,t.stateNode=o,o._reactInternals=t,Mf(t,r,e,a),t=Ff(null,t,r,!0,n,a)):(t.tag=0,we&&n&&up(t),ft(null,t,o,a),t=t.child),t;case 16:r=t.elementType;e:{switch(Bl(e,t),e=t.pendingProps,o=r._init,r=o(r._payload),t.type=r,o=t.tag=Xw(r),e=oa(r,e),o){case 0:t=Ef(null,t,r,e,a);break e;case 1:t=Dg(null,t,r,e,a);break e;case 11:t=Ag(null,t,r,e,a);break e;case 14:t=Rg(null,t,r,oa(r.type,e),a);break e}throw Error(D(306,r,""))}return t;case 0:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:oa(r,o),Ef(e,t,r,o,a);case 1:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:oa(r,o),Dg(e,t,r,o,a);case 3:e:{if(vy(t),e===null)throw Error(D(387));r=t.pendingProps,n=t.memoizedState,o=n.element,jx(e,t),tu(t,r,null,a);var s=t.memoizedState;if(r=s.element,n.isDehydrated)if(n={element:r,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=n,t.memoizedState=n,t.flags&256){o=dn(Error(D(423)),t),t=Mg(e,t,r,a,o);break e}else if(r!==o){o=dn(Error(D(424)),t),t=Mg(e,t,r,a,o);break e}else for(Mt=xr(t.stateNode.containerInfo.firstChild),Nt=t,we=!0,sa=null,a=Wx(t,null,r,a),t.child=a;a;)a.flags=a.flags&-3|4096,a=a.sibling;else{if(sn(),r===o){t=Ha(e,t,a);break e}ft(e,t,r,a)}t=t.child}return t;case 5:return Kx(t),e===null&&Af(t),r=t.type,o=t.pendingProps,n=e!==null?e.memoizedProps:null,s=o.children,wf(r,o)?s=null:n!==null&&wf(r,n)&&(t.flags|=32),yy(e,t),ft(e,t,s,a),t.child;case 6:return e===null&&Af(t),null;case 13:return Ly(e,t,a);case 4:return xp(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=ln(t,null,r,a):ft(e,t,r,a),t.child;case 11:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:oa(r,o),Ag(e,t,r,o,a);case 7:return ft(e,t,t.pendingProps,a),t.child;case 8:return ft(e,t,t.pendingProps.children,a),t.child;case 12:return ft(e,t,t.pendingProps.children,a),t.child;case 10:e:{if(r=t.type._context,o=t.pendingProps,n=t.memoizedProps,s=o.value,xe(Jl,r._currentValue),r._currentValue=s,n!==null)if(ua(n.value,s)){if(n.children===o.children&&!Lt.current){t=Ha(e,t,a);break e}}else for(n=t.child,n!==null&&(n.return=t);n!==null;){var i=n.dependencies;if(i!==null){s=n.child;for(var l=i.firstContext;l!==null;){if(l.context===r){if(n.tag===1){l=Va(-1,a&-a),l.tag=2;var u=n.updateQueue;if(u!==null){u=u.shared;var d=u.pending;d===null?l.next=l:(l.next=d.next,d.next=l),u.pending=l}}n.lanes|=a,l=n.alternate,l!==null&&(l.lanes|=a),Rf(n.return,a,t),i.lanes|=a;break}l=l.next}}else if(n.tag===10)s=n.type===t.type?null:n.child;else if(n.tag===18){if(s=n.return,s===null)throw Error(D(341));s.lanes|=a,i=s.alternate,i!==null&&(i.lanes|=a),Rf(s,a,t),s=n.sibling}else s=n.child;if(s!==null)s.return=n;else for(s=n;s!==null;){if(s===t){s=null;break}if(n=s.sibling,n!==null){n.return=s.return,s=n;break}s=s.return}n=s}ft(e,t,o.children,a),t=t.child}return t;case 9:return o=t.type,r=t.pendingProps.children,an(t,a),o=Yt(o),r=r(o),t.flags|=1,ft(e,t,r,a),t.child;case 14:return r=t.type,o=oa(r,t.pendingProps),o=oa(r.type,o),Rg(e,t,r,o,a);case 15:return gy(e,t,t.type,t.pendingProps,a);case 17:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:oa(r,o),Bl(e,t),t.tag=1,Ct(r)?(e=!0,Ql(t)):e=!1,an(t,a),py(t,r,o),Mf(t,r,o,a),Ff(null,t,r,!0,e,a);case 19:return Cy(e,t,a);case 22:return xy(e,t,a)}throw Error(D(156,t.tag))};function Oy(e,t){return dx(e,t)}function $w(e,t,a,r){this.tag=e,this.key=a,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Xt(e,t,a,r){return new $w(e,t,a,r)}function Mp(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Xw(e){if(typeof e=="function")return Mp(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Yf)return 11;if(e===Zf)return 14}return 2}function Cr(e,t){var a=e.alternate;return a===null?(a=Xt(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&14680064,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}function Ul(e,t,a,r,o,n){var s=2;if(r=e,typeof e=="function")Mp(e)&&(s=1);else if(typeof e=="string")s=5;else e:switch(e){case zo:return no(a.children,o,n,t);case Qf:s=8,o|=8;break;case tf:return e=Xt(12,a,t,o|2),e.elementType=tf,e.lanes=n,e;case af:return e=Xt(13,a,t,o),e.elementType=af,e.lanes=n,e;case rf:return e=Xt(19,a,t,o),e.elementType=rf,e.lanes=n,e;case Kg:return Lu(a,o,n,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Gg:s=10;break e;case jg:s=9;break e;case Yf:s=11;break e;case Zf:s=14;break e;case lr:s=16,r=null;break e}throw Error(D(130,e==null?e:typeof e,""))}return t=Xt(s,a,t,o),t.elementType=e,t.type=r,t.lanes=n,t}function no(e,t,a,r){return e=Xt(7,e,r,t),e.lanes=a,e}function Lu(e,t,a,r){return e=Xt(22,e,r,t),e.elementType=Kg,e.lanes=a,e.stateNode={isHidden:!1},e}function Zc(e,t,a){return e=Xt(6,e,null,t),e.lanes=a,e}function Jc(e,t,a){return t=Xt(4,e.children!==null?e.children:[],e.key,t),t.lanes=a,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Qw(e,t,a,r,o){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=Bc(0),this.expirationTimes=Bc(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Bc(0),this.identifierPrefix=r,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function Np(e,t,a,r,o,n,s,i,l){return e=new Qw(e,t,a,i,l),t===1?(t=1,n===!0&&(t|=8)):t=0,n=Xt(3,null,null,t),e.current=n,n.stateNode=e,n.memoizedState={element:r,isDehydrated:a,cache:null,transitions:null,pendingSuspenseBoundaries:null},gp(n),e}function Yw(e,t,a){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:_o,key:r==null?null:""+r,children:e,containerInfo:t,implementation:a}}function Vy(e){if(!e)return Ir;e=e._reactInternals;e:{if(po(e)!==e||e.tag!==1)throw Error(D(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(Ct(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(D(171))}if(e.tag===1){var a=e.type;if(Ct(a))return Vx(e,a,t)}return t}function Uy(e,t,a,r,o,n,s,i,l){return e=Np(a,r,!0,e,o,n,s,i,l),e.context=Vy(null),a=e.current,r=pt(),o=Lr(a),n=Va(r,o),n.callback=t??null,yr(a,n,o),e.current.lanes=o,li(e,o,r),St(e,r),e}function Cu(e,t,a,r){var o=t.current,n=pt(),s=Lr(o);return a=Vy(a),t.context===null?t.context=a:t.pendingContext=a,t=Va(n,s),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=yr(o,t,s),e!==null&&(la(e,o,s,n),Nl(e,o,s)),s}function uu(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function Hg(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var a=e.retryLane;e.retryLane=a!==0&&a<t?a:t}}function Ep(e,t){Hg(e,t),(e=e.alternate)&&Hg(e,t)}function Zw(){return null}var _y=typeof reportError=="function"?reportError:function(e){console.error(e)};function Fp(e){this._internalRoot=e}Su.prototype.render=Fp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(D(409));Cu(e,t,null,null)};Su.prototype.unmount=Fp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;co(function(){Cu(null,e,null,null)}),t[_a]=null}};function Su(e){this._internalRoot=e}Su.prototype.unstable_scheduleHydration=function(e){if(e){var t=xx();e={blockedOn:null,target:e,priority:t};for(var a=0;a<dr.length&&t!==0&&t<dr[a].priority;a++);dr.splice(a,0,e),a===0&&vx(e)}};function Bp(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Iu(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function qg(){}function Jw(e,t,a,r,o){if(o){if(typeof r=="function"){var n=r;r=function(){var u=uu(s);n.call(u)}}var s=Uy(t,r,e,0,null,!1,!1,"",qg);return e._reactRootContainer=s,e[_a]=s.current,Js(e.nodeType===8?e.parentNode:e),co(),s}for(;o=e.lastChild;)e.removeChild(o);if(typeof r=="function"){var i=r;r=function(){var u=uu(l);i.call(u)}}var l=Np(e,0,!1,null,null,!1,!1,"",qg);return e._reactRootContainer=l,e[_a]=l.current,Js(e.nodeType===8?e.parentNode:e),co(function(){Cu(t,l,a,r)}),l}function wu(e,t,a,r,o){var n=a._reactRootContainer;if(n){var s=n;if(typeof o=="function"){var i=o;o=function(){var l=uu(s);i.call(l)}}Cu(t,s,e,o)}else s=Jw(a,t,e,o,r);return uu(s)}hx=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var a=Es(t.pendingLanes);a!==0&&(tp(t,a|1),St(t,Ne()),(le&6)===0&&(cn=Ne()+500,br()))}break;case 13:co(function(){var r=za(e,1);if(r!==null){var o=pt();la(r,e,1,o)}}),Ep(e,1)}};ap=function(e){if(e.tag===13){var t=za(e,134217728);if(t!==null){var a=pt();la(t,e,134217728,a)}Ep(e,134217728)}};gx=function(e){if(e.tag===13){var t=Lr(e),a=za(e,t);if(a!==null){var r=pt();la(a,e,t,r)}Ep(e,t)}};xx=function(){return pe};yx=function(e,t){var a=pe;try{return pe=e,t()}finally{pe=a}};mf=function(e,t,a){switch(t){case"input":if(sf(e,a),t=a.name,a.type==="radio"&&t!=null){for(a=e;a.parentNode;)a=a.parentNode;for(a=a.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<a.length;t++){var r=a[t];if(r!==e&&r.form===e.form){var o=mu(r);if(!o)throw Error(D(90));Xg(r),sf(r,o)}}}break;case"textarea":Yg(e,a);break;case"select":t=a.value,t!=null&&Zo(e,!!a.multiple,t,!1)}};ox=Ap;nx=co;var ek={usingClientEntryPoint:!1,Events:[di,Go,mu,ax,rx,Ap]},Rs={findFiberByHostInstance:to,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},tk={bundleType:Rs.bundleType,version:Rs.version,rendererPackageName:Rs.rendererPackageName,rendererConfig:Rs.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:qa.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=lx(e),e===null?null:e.stateNode},findFiberByHostInstance:Rs.findFiberByHostInstance||Zw,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&(Ds=__REACT_DEVTOOLS_GLOBAL_HOOK__,!Ds.isDisabled&&Ds.supportsFiber))try{du=Ds.inject(tk),ya=Ds}catch{}var Ds;Bt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ek;Bt.createPortal=function(e,t){var a=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Bp(t))throw Error(D(200));return Yw(e,t,null,a)};Bt.createRoot=function(e,t){if(!Bp(e))throw Error(D(299));var a=!1,r="",o=_y;return t!=null&&(t.unstable_strictMode===!0&&(a=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(o=t.onRecoverableError)),t=Np(e,1,!1,null,null,a,!1,r,o),e[_a]=t.current,Js(e.nodeType===8?e.parentNode:e),new Fp(t)};Bt.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(D(188)):(e=Object.keys(e).join(","),Error(D(268,e)));return e=lx(t),e=e===null?null:e.stateNode,e};Bt.flushSync=function(e){return co(e)};Bt.hydrate=function(e,t,a){if(!Iu(t))throw Error(D(200));return wu(null,e,t,!0,a)};Bt.hydrateRoot=function(e,t,a){if(!Bp(e))throw Error(D(405));var r=a!=null&&a.hydratedSources||null,o=!1,n="",s=_y;if(a!=null&&(a.unstable_strictMode===!0&&(o=!0),a.identifierPrefix!==void 0&&(n=a.identifierPrefix),a.onRecoverableError!==void 0&&(s=a.onRecoverableError)),t=Uy(t,null,e,1,a??null,o,!1,n,s),e[_a]=t.current,Js(e),r)for(e=0;e<r.length;e++)a=r[e],o=a._getVersion,o=o(a._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[a,o]:t.mutableSourceEagerHydrationData.push(a,o);return new Su(t)};Bt.render=function(e,t,a){if(!Iu(t))throw Error(D(200));return wu(null,e,t,!1,a)};Bt.unmountComponentAtNode=function(e){if(!Iu(e))throw Error(D(40));return e._reactRootContainer?(co(function(){wu(null,null,e,!1,function(){e._reactRootContainer=null,e[_a]=null})}),!0):!1};Bt.unstable_batchedUpdates=Ap;Bt.unstable_renderSubtreeIntoContainer=function(e,t,a,r){if(!Iu(a))throw Error(D(200));if(e==null||e._reactInternals===void 0)throw Error(D(38));return wu(e,t,a,!1,r)};Bt.version="18.3.1-next-f1338f8080-20240426"});var Op=Na((UT,qy)=>{"use strict";function Hy(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Hy)}catch(e){console.error(e)}}Hy(),qy.exports=zy()});var Gy=Na(Vp=>{"use strict";var Wy=Op();Vp.createRoot=Wy.createRoot,Vp.hydrateRoot=Wy.hydrateRoot;var _T});var tv=Na(bu=>{"use strict";var Nk=X(),Ek=Symbol.for("react.element"),Fk=Symbol.for("react.fragment"),Bk=Object.prototype.hasOwnProperty,Ok=Nk.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,Vk={key:!0,ref:!0,__self:!0,__source:!0};function ev(e,t,a){var r,o={},n=null,s=null;a!==void 0&&(n=""+a),t.key!==void 0&&(n=""+t.key),t.ref!==void 0&&(s=t.ref);for(r in t)Bk.call(t,r)&&!Vk.hasOwnProperty(r)&&(o[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)o[r]===void 0&&(o[r]=t[r]);return{$$typeof:Ek,type:e,key:n,ref:s,props:o,_owner:Ok.current}}bu.Fragment=Fk;bu.jsx=ev;bu.jsxs=ev});var ue=Na(($T,av)=>{"use strict";av.exports=tv()});var RT={};OS(RT,{initKiteChat:()=>Jm});var Ra=E(X(),1),LS=E(Gy(),1);var j=E(X(),1);function jy(e){var t,a,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(a=jy(e[t]))&&(r&&(r+=" "),r+=a)}else for(a in e)e[a]&&(r&&(r+=" "),r+=a);return r}function ku(){for(var e,t,a=0,r="",o=arguments.length;a<o;a++)(e=arguments[a])&&(t=jy(e))&&(r&&(r+=" "),r+=t);return r}var ak=e=>{let t=ok(e),{conflictingClassGroups:a,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{let i=s.split("-");return i[0]===""&&i.length!==1&&i.shift(),Xy(i,t)||rk(s)},getConflictingClassGroupIds:(s,i)=>{let l=a[s]||[];return i&&r[s]?[...l,...r[s]]:l}}},Xy=(e,t)=>{if(e.length===0)return t.classGroupId;let a=e[0],r=t.nextPart.get(a),o=r?Xy(e.slice(1),r):void 0;if(o)return o;if(t.validators.length===0)return;let n=e.join("-");return t.validators.find(({validator:s})=>s(n))?.classGroupId},Ky=/^\[(.+)\]$/,rk=e=>{if(Ky.test(e)){let t=Ky.exec(e)[1],a=t?.substring(0,t.indexOf(":"));if(a)return"arbitrary.."+a}},ok=e=>{let{theme:t,prefix:a}=e,r={nextPart:new Map,validators:[]};return sk(Object.entries(e.classGroups),a).forEach(([n,s])=>{_p(s,r,n,t)}),r},_p=(e,t,a,r)=>{e.forEach(o=>{if(typeof o=="string"){let n=o===""?t:$y(t,o);n.classGroupId=a;return}if(typeof o=="function"){if(nk(o)){_p(o(r),t,a,r);return}t.validators.push({validator:o,classGroupId:a});return}Object.entries(o).forEach(([n,s])=>{_p(s,$y(t,n),a,r)})})},$y=(e,t)=>{let a=e;return t.split("-").forEach(r=>{a.nextPart.has(r)||a.nextPart.set(r,{nextPart:new Map,validators:[]}),a=a.nextPart.get(r)}),a},nk=e=>e.isThemeGetter,sk=(e,t)=>t?e.map(([a,r])=>{let o=r.map(n=>typeof n=="string"?t+n:typeof n=="object"?Object.fromEntries(Object.entries(n).map(([s,i])=>[t+s,i])):n);return[a,o]}):e,ik=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,a=new Map,r=new Map,o=(n,s)=>{a.set(n,s),t++,t>e&&(t=0,r=a,a=new Map)};return{get(n){let s=a.get(n);if(s!==void 0)return s;if((s=r.get(n))!==void 0)return o(n,s),s},set(n,s){a.has(n)?a.set(n,s):o(n,s)}}};var lk=e=>{let{separator:t,experimentalParseClassName:a}=e,r=t.length===1,o=t[0],n=t.length,s=i=>{let l=[],u=0,d=0,c;for(let S=0;S<i.length;S++){let h=i[S];if(u===0){if(h===o&&(r||i.slice(S,S+n)===t)){l.push(i.slice(d,S)),d=S+n;continue}if(h==="/"){c=S;continue}}h==="["?u++:h==="]"&&u--}let p=l.length===0?i:i.substring(d),g=p.startsWith("!"),C=g?p.substring(1):p,L=c&&c>d?c-d:void 0;return{modifiers:l,hasImportantModifier:g,baseClassName:C,maybePostfixModifierPosition:L}};return a?i=>a({className:i,parseClassName:s}):s},uk=e=>{if(e.length<=1)return e;let t=[],a=[];return e.forEach(r=>{r[0]==="["?(t.push(...a.sort(),r),a=[]):a.push(r)}),t.push(...a.sort()),t},dk=e=>({cache:ik(e.cacheSize),parseClassName:lk(e),...ak(e)}),ck=/\s+/,fk=(e,t)=>{let{parseClassName:a,getClassGroupId:r,getConflictingClassGroupIds:o}=t,n=[],s=e.trim().split(ck),i="";for(let l=s.length-1;l>=0;l-=1){let u=s[l],{modifiers:d,hasImportantModifier:c,baseClassName:p,maybePostfixModifierPosition:g}=a(u),C=!!g,L=r(C?p.substring(0,g):p);if(!L){if(!C){i=u+(i.length>0?" "+i:i);continue}if(L=r(p),!L){i=u+(i.length>0?" "+i:i);continue}C=!1}let S=uk(d).join(":"),h=c?S+"!":S,m=h+L;if(n.includes(m))continue;n.push(m);let x=o(L,C);for(let I=0;I<x.length;++I){let k=x[I];n.push(h+k)}i=u+(i.length>0?" "+i:i)}return i};function pk(){let e=0,t,a,r="";for(;e<arguments.length;)(t=arguments[e++])&&(a=Qy(t))&&(r&&(r+=" "),r+=a);return r}var Qy=e=>{if(typeof e=="string")return e;let t,a="";for(let r=0;r<e.length;r++)e[r]&&(t=Qy(e[r]))&&(a&&(a+=" "),a+=t);return a};function mk(e,...t){let a,r,o,n=s;function s(l){let u=t.reduce((d,c)=>c(d),e());return a=dk(u),r=a.cache.get,o=a.cache.set,n=i,i(l)}function i(l){let u=r(l);if(u)return u;let d=fk(l,a);return o(l,d),d}return function(){return n(pk.apply(null,arguments))}}var Ce=e=>{let t=a=>a[e]||[];return t.isThemeGetter=!0,t},Yy=/^\[(?:([a-z-]+):)?(.+)\]$/i,hk=/^\d+\/\d+$/,gk=new Set(["px","full","screen"]),xk=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,yk=/\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$/,vk=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,Lk=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Ck=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Wa=e=>mn(e)||gk.has(e)||hk.test(e),Pr=e=>hn(e,"length",Ak),mn=e=>!!e&&!Number.isNaN(Number(e)),Up=e=>hn(e,"number",mn),fi=e=>!!e&&Number.isInteger(Number(e)),Sk=e=>e.endsWith("%")&&mn(e.slice(0,-1)),Z=e=>Yy.test(e),Tr=e=>xk.test(e),Ik=new Set(["length","size","percentage"]),wk=e=>hn(e,Ik,Zy),kk=e=>hn(e,"position",Zy),bk=new Set(["image","url"]),Pk=e=>hn(e,bk,Dk),Tk=e=>hn(e,"",Rk),pi=()=>!0,hn=(e,t,a)=>{let r=Yy.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):a(r[2]):!1},Ak=e=>yk.test(e)&&!vk.test(e),Zy=()=>!1,Rk=e=>Lk.test(e),Dk=e=>Ck.test(e);var Mk=()=>{let e=Ce("colors"),t=Ce("spacing"),a=Ce("blur"),r=Ce("brightness"),o=Ce("borderColor"),n=Ce("borderRadius"),s=Ce("borderSpacing"),i=Ce("borderWidth"),l=Ce("contrast"),u=Ce("grayscale"),d=Ce("hueRotate"),c=Ce("invert"),p=Ce("gap"),g=Ce("gradientColorStops"),C=Ce("gradientColorStopPositions"),L=Ce("inset"),S=Ce("margin"),h=Ce("opacity"),m=Ce("padding"),x=Ce("saturate"),I=Ce("scale"),k=Ce("sepia"),T=Ce("skew"),R=Ce("space"),A=Ce("translate"),V=()=>["auto","contain","none"],U=()=>["auto","hidden","clip","visible","scroll"],se=()=>["auto",Z,t],q=()=>[Z,t],No=()=>["",Wa,Pr],ie=()=>["auto",mn,Z],Wt=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],$r=()=>["solid","dashed","dotted","double","none"],Ae=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Be=()=>["start","end","center","between","around","evenly","stretch"],Gt=()=>["","0",Z],Rt=()=>["auto","avoid","all","avoid-page","page","left","right","column"],ea=()=>[mn,Z];return{cacheSize:500,separator:":",theme:{colors:[pi],spacing:[Wa,Pr],blur:["none","",Tr,Z],brightness:ea(),borderColor:[e],borderRadius:["none","","full",Tr,Z],borderSpacing:q(),borderWidth:No(),contrast:ea(),grayscale:Gt(),hueRotate:ea(),invert:Gt(),gap:q(),gradientColorStops:[e],gradientColorStopPositions:[Sk,Pr],inset:se(),margin:se(),opacity:ea(),padding:q(),saturate:ea(),scale:ea(),sepia:Gt(),skew:ea(),space:q(),translate:q()},classGroups:{aspect:[{aspect:["auto","square","video",Z]}],container:["container"],columns:[{columns:[Tr]}],"break-after":[{"break-after":Rt()}],"break-before":[{"break-before":Rt()}],"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"],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:[...Wt(),Z]}],overflow:[{overflow:U()}],"overflow-x":[{"overflow-x":U()}],"overflow-y":[{"overflow-y":U()}],overscroll:[{overscroll:V()}],"overscroll-x":[{"overscroll-x":V()}],"overscroll-y":[{"overscroll-y":V()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[L]}],"inset-x":[{"inset-x":[L]}],"inset-y":[{"inset-y":[L]}],start:[{start:[L]}],end:[{end:[L]}],top:[{top:[L]}],right:[{right:[L]}],bottom:[{bottom:[L]}],left:[{left:[L]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",fi,Z]}],basis:[{basis:se()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Z]}],grow:[{grow:Gt()}],shrink:[{shrink:Gt()}],order:[{order:["first","last","none",fi,Z]}],"grid-cols":[{"grid-cols":[pi]}],"col-start-end":[{col:["auto",{span:["full",fi,Z]},Z]}],"col-start":[{"col-start":ie()}],"col-end":[{"col-end":ie()}],"grid-rows":[{"grid-rows":[pi]}],"row-start-end":[{row:["auto",{span:[fi,Z]},Z]}],"row-start":[{"row-start":ie()}],"row-end":[{"row-end":ie()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Z]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Z]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal",...Be()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...Be(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...Be(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[m]}],px:[{px:[m]}],py:[{py:[m]}],ps:[{ps:[m]}],pe:[{pe:[m]}],pt:[{pt:[m]}],pr:[{pr:[m]}],pb:[{pb:[m]}],pl:[{pl:[m]}],m:[{m:[S]}],mx:[{mx:[S]}],my:[{my:[S]}],ms:[{ms:[S]}],me:[{me:[S]}],mt:[{mt:[S]}],mr:[{mr:[S]}],mb:[{mb:[S]}],ml:[{ml:[S]}],"space-x":[{"space-x":[R]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[R]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Z,t]}],"min-w":[{"min-w":[Z,t,"min","max","fit"]}],"max-w":[{"max-w":[Z,t,"none","full","min","max","fit","prose",{screen:[Tr]},Tr]}],h:[{h:[Z,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Z,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Z,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Z,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Tr,Pr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Up]}],"font-family":[{font:[pi]}],"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:["tighter","tight","normal","wide","wider","widest",Z]}],"line-clamp":[{"line-clamp":["none",mn,Up]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Wa,Z]}],"list-image":[{"list-image":["none",Z]}],"list-style-type":[{list:["none","disc","decimal",Z]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[h]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[h]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...$r(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Wa,Pr]}],"underline-offset":[{"underline-offset":["auto",Wa,Z]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:q()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Z]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Z]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[h]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...Wt(),kk]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",wk]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Pk]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[C]}],"gradient-via-pos":[{via:[C]}],"gradient-to-pos":[{to:[C]}],"gradient-from":[{from:[g]}],"gradient-via":[{via:[g]}],"gradient-to":[{to:[g]}],rounded:[{rounded:[n]}],"rounded-s":[{"rounded-s":[n]}],"rounded-e":[{"rounded-e":[n]}],"rounded-t":[{"rounded-t":[n]}],"rounded-r":[{"rounded-r":[n]}],"rounded-b":[{"rounded-b":[n]}],"rounded-l":[{"rounded-l":[n]}],"rounded-ss":[{"rounded-ss":[n]}],"rounded-se":[{"rounded-se":[n]}],"rounded-ee":[{"rounded-ee":[n]}],"rounded-es":[{"rounded-es":[n]}],"rounded-tl":[{"rounded-tl":[n]}],"rounded-tr":[{"rounded-tr":[n]}],"rounded-br":[{"rounded-br":[n]}],"rounded-bl":[{"rounded-bl":[n]}],"border-w":[{border:[i]}],"border-w-x":[{"border-x":[i]}],"border-w-y":[{"border-y":[i]}],"border-w-s":[{"border-s":[i]}],"border-w-e":[{"border-e":[i]}],"border-w-t":[{"border-t":[i]}],"border-w-r":[{"border-r":[i]}],"border-w-b":[{"border-b":[i]}],"border-w-l":[{"border-l":[i]}],"border-opacity":[{"border-opacity":[h]}],"border-style":[{border:[...$r(),"hidden"]}],"divide-x":[{"divide-x":[i]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[i]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[h]}],"divide-style":[{divide:$r()}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-s":[{"border-s":[o]}],"border-color-e":[{"border-e":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:["",...$r()]}],"outline-offset":[{"outline-offset":[Wa,Z]}],"outline-w":[{outline:[Wa,Pr]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:No()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[h]}],"ring-offset-w":[{"ring-offset":[Wa,Pr]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Tr,Tk]}],"shadow-color":[{shadow:[pi]}],opacity:[{opacity:[h]}],"mix-blend":[{"mix-blend":[...Ae(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":Ae()}],filter:[{filter:["","none"]}],blur:[{blur:[a]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",Tr,Z]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[c]}],saturate:[{saturate:[x]}],sepia:[{sepia:[k]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[a]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[c]}],"backdrop-opacity":[{"backdrop-opacity":[h]}],"backdrop-saturate":[{"backdrop-saturate":[x]}],"backdrop-sepia":[{"backdrop-sepia":[k]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[s]}],"border-spacing-x":[{"border-spacing-x":[s]}],"border-spacing-y":[{"border-spacing-y":[s]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Z]}],duration:[{duration:ea()}],ease:[{ease:["linear","in","out","in-out",Z]}],delay:[{delay:ea()}],animate:[{animate:["none","spin","ping","pulse","bounce",Z]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[I]}],"scale-x":[{"scale-x":[I]}],"scale-y":[{"scale-y":[I]}],rotate:[{rotate:[fi,Z]}],"translate-x":[{"translate-x":[A]}],"translate-y":[{"translate-y":[A]}],"skew-x":[{"skew-x":[T]}],"skew-y":[{"skew-y":[T]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Z]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],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",Z]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":q()}],"scroll-mx":[{"scroll-mx":q()}],"scroll-my":[{"scroll-my":q()}],"scroll-ms":[{"scroll-ms":q()}],"scroll-me":[{"scroll-me":q()}],"scroll-mt":[{"scroll-mt":q()}],"scroll-mr":[{"scroll-mr":q()}],"scroll-mb":[{"scroll-mb":q()}],"scroll-ml":[{"scroll-ml":q()}],"scroll-p":[{"scroll-p":q()}],"scroll-px":[{"scroll-px":q()}],"scroll-py":[{"scroll-py":q()}],"scroll-ps":[{"scroll-ps":q()}],"scroll-pe":[{"scroll-pe":q()}],"scroll-pt":[{"scroll-pt":q()}],"scroll-pr":[{"scroll-pr":q()}],"scroll-pb":[{"scroll-pb":q()}],"scroll-pl":[{"scroll-pl":q()}],"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",Z]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Wa,Pr,Up]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}};var Jy=mk(Mk);function Ot(...e){return Jy(ku(e))}var rv=E(ue(),1);function Te({className:e,type:t,...a}){return(0,rv.jsx)("input",{type:t,"data-slot":"input",className:Ot("file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm","focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px]","aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",e),...a})}var Ve=E(X(),1);var nv=E(X(),1);function ov(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function mi(...e){return t=>{let a=!1,r=e.map(o=>{let n=ov(o,t);return!a&&typeof n=="function"&&(a=!0),n});if(a)return()=>{for(let o=0;o<r.length;o++){let n=r[o];typeof n=="function"?n():ov(e[o],null)}}}}function Ga(...e){return nv.useCallback(mi(...e),e)}var Pu=E(ue(),1),Uk=Symbol.for("react.lazy"),Tu=Ve[" use ".trim().toString()];function _k(e){return typeof e=="object"&&e!==null&&"then"in e}function sv(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===Uk&&"_payload"in e&&_k(e._payload)}function zk(e){let t=Hk(e),a=Ve.forwardRef((r,o)=>{let{children:n,...s}=r;sv(n)&&typeof Tu=="function"&&(n=Tu(n._payload));let i=Ve.Children.toArray(n),l=i.find(Wk);if(l){let u=l.props.children,d=i.map(c=>c===l?Ve.Children.count(u)>1?Ve.Children.only(null):Ve.isValidElement(u)?u.props.children:null:c);return(0,Pu.jsx)(t,{...s,ref:o,children:Ve.isValidElement(u)?Ve.cloneElement(u,void 0,d):null})}return(0,Pu.jsx)(t,{...s,ref:o,children:n})});return a.displayName=`${e}.Slot`,a}var iv=zk("Slot");function Hk(e){let t=Ve.forwardRef((a,r)=>{let{children:o,...n}=a;if(sv(o)&&typeof Tu=="function"&&(o=Tu(o._payload)),Ve.isValidElement(o)){let s=jk(o),i=Gk(n,o.props);return o.type!==Ve.Fragment&&(i.ref=r?mi(r,s):s),Ve.cloneElement(o,i)}return Ve.Children.count(o)>1?Ve.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var qk=Symbol("radix.slottable");function Wk(e){return Ve.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===qk}function Gk(e,t){let a={...t};for(let r in t){let o=e[r],n=t[r];/^on[A-Z]/.test(r)?o&&n?a[r]=(...i)=>{let l=n(...i);return o(...i),l}:o&&(a[r]=o):r==="style"?a[r]={...o,...n}:r==="className"&&(a[r]=[o,n].filter(Boolean).join(" "))}return{...e,...a}}function jk(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,a=t&&"isReactWarning"in t&&t.isReactWarning;return a?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,a=t&&"isReactWarning"in t&&t.isReactWarning,a?e.props.ref:e.props.ref||e.ref)}var lv=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,uv=ku,dv=(e,t)=>a=>{var r;if(t?.variants==null)return uv(e,a?.class,a?.className);let{variants:o,defaultVariants:n}=t,s=Object.keys(o).map(u=>{let d=a?.[u],c=n?.[u];if(d===null)return null;let p=lv(d)||lv(c);return o[u][p]}),i=a&&Object.entries(a).reduce((u,d)=>{let[c,p]=d;return p===void 0||(u[c]=p),u},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((u,d)=>{let{class:c,className:p,...g}=d;return Object.entries(g).every(C=>{let[L,S]=C;return Array.isArray(S)?S.includes({...n,...i}[L]):{...n,...i}[L]===S})?[...u,c,p]:u},[]);return uv(e,s,l,a?.class,a?.className)};var cv=E(ue(),1),Kk=dv("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-9 px-4 py-2 has-[>svg]:px-3",sm:"h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4",icon:"size-9","icon-sm":"size-8","icon-lg":"size-10"}},defaultVariants:{variant:"default",size:"default"}});function It({className:e,variant:t,size:a,asChild:r=!1,...o}){return(0,cv.jsx)(r?iv:"button",{"data-slot":"button",className:Ot(Kk({variant:t,size:a,className:e})),...o})}var Ov=E(X(),1);var G=E(X(),1);var pv=E(X(),1),Jk=E(Op(),1);var He=E(X(),1);var Au=E(ue(),1);function fv(e){let t=$k(e),a=He.forwardRef((r,o)=>{let{children:n,...s}=r,i=He.Children.toArray(n),l=i.find(Qk);if(l){let u=l.props.children,d=i.map(c=>c===l?He.Children.count(u)>1?He.Children.only(null):He.isValidElement(u)?u.props.children:null:c);return(0,Au.jsx)(t,{...s,ref:o,children:He.isValidElement(u)?He.cloneElement(u,void 0,d):null})}return(0,Au.jsx)(t,{...s,ref:o,children:n})});return a.displayName=`${e}.Slot`,a}function $k(e){let t=He.forwardRef((a,r)=>{let{children:o,...n}=a;if(He.isValidElement(o)){let s=Zk(o),i=Yk(n,o.props);return o.type!==He.Fragment&&(i.ref=r?mi(r,s):s),He.cloneElement(o,i)}return He.Children.count(o)>1?He.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Xk=Symbol("radix.slottable");function Qk(e){return He.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Xk}function Yk(e,t){let a={...t};for(let r in t){let o=e[r],n=t[r];/^on[A-Z]/.test(r)?o&&n?a[r]=(...i)=>{let l=n(...i);return o(...i),l}:o&&(a[r]=o):r==="style"?a[r]={...o,...n}:r==="className"&&(a[r]=[o,n].filter(Boolean).join(" "))}return{...e,...a}}function Zk(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,a=t&&"isReactWarning"in t&&t.isReactWarning;return a?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,a=t&&"isReactWarning"in t&&t.isReactWarning,a?e.props.ref:e.props.ref||e.ref)}var mv=E(ue(),1),eb=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],gn=eb.reduce((e,t)=>{let a=fv(`Primitive.${t}`),r=pv.forwardRef((o,n)=>{let{asChild:s,...i}=o,l=s?a:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),(0,mv.jsx)(l,{...i,ref:n})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});var wt=E(X(),1);var hv=E(X(),1),hi=globalThis?.document?hv.useLayoutEffect:()=>{};var gv=E(X(),1);function tb(e,t){return gv.useReducer((a,r)=>t[a][r]??a,e)}var xn=e=>{let{present:t,children:a}=e,r=ab(t),o=typeof a=="function"?a({present:r.isPresent}):wt.Children.only(a),n=Ga(r.ref,rb(o));return typeof a=="function"||r.isPresent?wt.cloneElement(o,{ref:n}):null};xn.displayName="Presence";function ab(e){let[t,a]=wt.useState(),r=wt.useRef(null),o=wt.useRef(e),n=wt.useRef("none"),s=e?"mounted":"unmounted",[i,l]=tb(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return wt.useEffect(()=>{let u=Ru(r.current);n.current=i==="mounted"?u:"none"},[i]),hi(()=>{let u=r.current,d=o.current;if(d!==e){let p=n.current,g=Ru(u);e?l("MOUNT"):g==="none"||u?.display==="none"?l("UNMOUNT"):l(d&&p!==g?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,l]),hi(()=>{if(t){let u,d=t.ownerDocument.defaultView??window,c=g=>{let L=Ru(r.current).includes(CSS.escape(g.animationName));if(g.target===t&&L&&(l("ANIMATION_END"),!o.current)){let S=t.style.animationFillMode;t.style.animationFillMode="forwards",u=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=S)})}},p=g=>{g.target===t&&(n.current=Ru(r.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",c),t.addEventListener("animationend",c),()=>{d.clearTimeout(u),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",c),t.removeEventListener("animationend",c)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(i),ref:wt.useCallback(u=>{r.current=u?getComputedStyle(u):null,a(u)},[])}}function Ru(e){return e?.animationName||"none"}function rb(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,a=t&&"isReactWarning"in t&&t.isReactWarning;return a?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,a=t&&"isReactWarning"in t&&t.isReactWarning,a?e.props.ref:e.props.ref||e.ref)}var ja=E(X(),1),xv=E(ue(),1);function yv(e,t=[]){let a=[];function r(n,s){let i=ja.createContext(s),l=a.length;a=[...a,s];let u=c=>{let{scope:p,children:g,...C}=c,L=p?.[e]?.[l]||i,S=ja.useMemo(()=>C,Object.values(C));return(0,xv.jsx)(L.Provider,{value:S,children:g})};u.displayName=n+"Provider";function d(c,p){let g=p?.[e]?.[l]||i,C=ja.useContext(g);if(C)return C;if(s!==void 0)return s;throw new Error(`\`${c}\` must be used within \`${n}\``)}return[u,d]}let o=()=>{let n=a.map(s=>ja.createContext(s));return function(i){let l=i?.[e]||n;return ja.useMemo(()=>({[`__scope${e}`]:{...i,[e]:l}}),[i,l])}};return o.scopeName=e,[r,ob(o,...t)]}function ob(...e){let t=e[0];if(e.length===1)return t;let a=()=>{let r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(n){let s=r.reduce((i,{useScope:l,scopeName:u})=>{let c=l(n)[`__scope${u}`];return{...i,...c}},{});return ja.useMemo(()=>({[`__scope${t.scopeName}`]:s}),[s])}};return a.scopeName=t.scopeName,a}var yn=E(X(),1);function Ar(e){let t=yn.useRef(e);return yn.useEffect(()=>{t.current=e}),yn.useMemo(()=>(...a)=>t.current?.(...a),[])}var Du=E(X(),1),nb=E(ue(),1),sb=Du.createContext(void 0);function vv(e){let t=Du.useContext(sb);return e||t||"ltr"}function Lv(e,[t,a]){return Math.min(a,Math.max(t,e))}var yA=!!(typeof window<"u"&&window.document&&window.document.createElement);function Rr(e,t,{checkForDefaultPrevented:a=!0}={}){return function(o){if(e?.(o),a===!1||!o.defaultPrevented)return t?.(o)}}var Sv=E(X(),1),ce=E(ue(),1);function ib(e,t){return Sv.useReducer((a,r)=>t[a][r]??a,e)}var zp="ScrollArea",[Iv,AA]=yv(zp),[lb,Jt]=Iv(zp),wv=G.forwardRef((e,t)=>{let{__scopeScrollArea:a,type:r="hover",dir:o,scrollHideDelay:n=600,...s}=e,[i,l]=G.useState(null),[u,d]=G.useState(null),[c,p]=G.useState(null),[g,C]=G.useState(null),[L,S]=G.useState(null),[h,m]=G.useState(0),[x,I]=G.useState(0),[k,T]=G.useState(!1),[R,A]=G.useState(!1),V=Ga(t,se=>l(se)),U=vv(o);return(0,ce.jsx)(lb,{scope:a,type:r,dir:U,scrollHideDelay:n,scrollArea:i,viewport:u,onViewportChange:d,content:c,onContentChange:p,scrollbarX:g,onScrollbarXChange:C,scrollbarXEnabled:k,onScrollbarXEnabledChange:T,scrollbarY:L,onScrollbarYChange:S,scrollbarYEnabled:R,onScrollbarYEnabledChange:A,onCornerWidthChange:m,onCornerHeightChange:I,children:(0,ce.jsx)(gn.div,{dir:U,...s,ref:V,style:{position:"relative","--radix-scroll-area-corner-width":h+"px","--radix-scroll-area-corner-height":x+"px",...e.style}})})});wv.displayName=zp;var kv="ScrollAreaViewport",bv=G.forwardRef((e,t)=>{let{__scopeScrollArea:a,children:r,nonce:o,...n}=e,s=Jt(kv,a),i=G.useRef(null),l=Ga(t,i,s.onViewportChange);return(0,ce.jsxs)(ce.Fragment,{children:[(0,ce.jsx)("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"},nonce:o}),(0,ce.jsx)(gn.div,{"data-radix-scroll-area-viewport":"",...n,ref:l,style:{overflowX:s.scrollbarXEnabled?"scroll":"hidden",overflowY:s.scrollbarYEnabled?"scroll":"hidden",...e.style},children:(0,ce.jsx)("div",{ref:s.onContentChange,style:{minWidth:"100%",display:"table"},children:r})})]})});bv.displayName=kv;var La="ScrollAreaScrollbar",Hp=G.forwardRef((e,t)=>{let{forceMount:a,...r}=e,o=Jt(La,e.__scopeScrollArea),{onScrollbarXEnabledChange:n,onScrollbarYEnabledChange:s}=o,i=e.orientation==="horizontal";return G.useEffect(()=>(i?n(!0):s(!0),()=>{i?n(!1):s(!1)}),[i,n,s]),o.type==="hover"?(0,ce.jsx)(ub,{...r,ref:t,forceMount:a}):o.type==="scroll"?(0,ce.jsx)(db,{...r,ref:t,forceMount:a}):o.type==="auto"?(0,ce.jsx)(Pv,{...r,ref:t,forceMount:a}):o.type==="always"?(0,ce.jsx)(qp,{...r,ref:t}):null});Hp.displayName=La;var ub=G.forwardRef((e,t)=>{let{forceMount:a,...r}=e,o=Jt(La,e.__scopeScrollArea),[n,s]=G.useState(!1);return G.useEffect(()=>{let i=o.scrollArea,l=0;if(i){let u=()=>{window.clearTimeout(l),s(!0)},d=()=>{l=window.setTimeout(()=>s(!1),o.scrollHideDelay)};return i.addEventListener("pointerenter",u),i.addEventListener("pointerleave",d),()=>{window.clearTimeout(l),i.removeEventListener("pointerenter",u),i.removeEventListener("pointerleave",d)}}},[o.scrollArea,o.scrollHideDelay]),(0,ce.jsx)(xn,{present:a||n,children:(0,ce.jsx)(Pv,{"data-state":n?"visible":"hidden",...r,ref:t})})}),db=G.forwardRef((e,t)=>{let{forceMount:a,...r}=e,o=Jt(La,e.__scopeScrollArea),n=e.orientation==="horizontal",s=Fu(()=>l("SCROLL_END"),100),[i,l]=ib("hidden",{hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}});return G.useEffect(()=>{if(i==="idle"){let u=window.setTimeout(()=>l("HIDE"),o.scrollHideDelay);return()=>window.clearTimeout(u)}},[i,o.scrollHideDelay,l]),G.useEffect(()=>{let u=o.viewport,d=n?"scrollLeft":"scrollTop";if(u){let c=u[d],p=()=>{let g=u[d];c!==g&&(l("SCROLL"),s()),c=g};return u.addEventListener("scroll",p),()=>u.removeEventListener("scroll",p)}},[o.viewport,n,l,s]),(0,ce.jsx)(xn,{present:a||i!=="hidden",children:(0,ce.jsx)(qp,{"data-state":i==="hidden"?"hidden":"visible",...r,ref:t,onPointerEnter:Rr(e.onPointerEnter,()=>l("POINTER_ENTER")),onPointerLeave:Rr(e.onPointerLeave,()=>l("POINTER_LEAVE"))})})}),Pv=G.forwardRef((e,t)=>{let a=Jt(La,e.__scopeScrollArea),{forceMount:r,...o}=e,[n,s]=G.useState(!1),i=e.orientation==="horizontal",l=Fu(()=>{if(a.viewport){let u=a.viewport.offsetWidth<a.viewport.scrollWidth,d=a.viewport.offsetHeight<a.viewport.scrollHeight;s(i?u:d)}},10);return vn(a.viewport,l),vn(a.content,l),(0,ce.jsx)(xn,{present:r||n,children:(0,ce.jsx)(qp,{"data-state":n?"visible":"hidden",...o,ref:t})})}),qp=G.forwardRef((e,t)=>{let{orientation:a="vertical",...r}=e,o=Jt(La,e.__scopeScrollArea),n=G.useRef(null),s=G.useRef(0),[i,l]=G.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),u=Dv(i.viewport,i.content),d={...r,sizes:i,onSizesChange:l,hasThumb:u>0&&u<1,onThumbChange:p=>n.current=p,onThumbPointerUp:()=>s.current=0,onThumbPointerDown:p=>s.current=p};function c(p,g){return gb(p,s.current,i,g)}return a==="horizontal"?(0,ce.jsx)(cb,{...d,ref:t,onThumbPositionChange:()=>{if(o.viewport&&n.current){let p=o.viewport.scrollLeft,g=Cv(p,i,o.dir);n.current.style.transform=`translate3d(${g}px, 0, 0)`}},onWheelScroll:p=>{o.viewport&&(o.viewport.scrollLeft=p)},onDragScroll:p=>{o.viewport&&(o.viewport.scrollLeft=c(p,o.dir))}}):a==="vertical"?(0,ce.jsx)(fb,{...d,ref:t,onThumbPositionChange:()=>{if(o.viewport&&n.current){let p=o.viewport.scrollTop,g=Cv(p,i);n.current.style.transform=`translate3d(0, ${g}px, 0)`}},onWheelScroll:p=>{o.viewport&&(o.viewport.scrollTop=p)},onDragScroll:p=>{o.viewport&&(o.viewport.scrollTop=c(p))}}):null}),cb=G.forwardRef((e,t)=>{let{sizes:a,onSizesChange:r,...o}=e,n=Jt(La,e.__scopeScrollArea),[s,i]=G.useState(),l=G.useRef(null),u=Ga(t,l,n.onScrollbarXChange);return G.useEffect(()=>{l.current&&i(getComputedStyle(l.current))},[l]),(0,ce.jsx)(Av,{"data-orientation":"horizontal",...o,ref:u,sizes:a,style:{bottom:0,left:n.dir==="rtl"?"var(--radix-scroll-area-corner-width)":0,right:n.dir==="ltr"?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":Eu(a)+"px",...e.style},onThumbPointerDown:d=>e.onThumbPointerDown(d.x),onDragScroll:d=>e.onDragScroll(d.x),onWheelScroll:(d,c)=>{if(n.viewport){let p=n.viewport.scrollLeft+d.deltaX;e.onWheelScroll(p),Nv(p,c)&&d.preventDefault()}},onResize:()=>{l.current&&n.viewport&&s&&r({content:n.viewport.scrollWidth,viewport:n.viewport.offsetWidth,scrollbar:{size:l.current.clientWidth,paddingStart:Nu(s.paddingLeft),paddingEnd:Nu(s.paddingRight)}})}})}),fb=G.forwardRef((e,t)=>{let{sizes:a,onSizesChange:r,...o}=e,n=Jt(La,e.__scopeScrollArea),[s,i]=G.useState(),l=G.useRef(null),u=Ga(t,l,n.onScrollbarYChange);return G.useEffect(()=>{l.current&&i(getComputedStyle(l.current))},[l]),(0,ce.jsx)(Av,{"data-orientation":"vertical",...o,ref:u,sizes:a,style:{top:0,right:n.dir==="ltr"?0:void 0,left:n.dir==="rtl"?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":Eu(a)+"px",...e.style},onThumbPointerDown:d=>e.onThumbPointerDown(d.y),onDragScroll:d=>e.onDragScroll(d.y),onWheelScroll:(d,c)=>{if(n.viewport){let p=n.viewport.scrollTop+d.deltaY;e.onWheelScroll(p),Nv(p,c)&&d.preventDefault()}},onResize:()=>{l.current&&n.viewport&&s&&r({content:n.viewport.scrollHeight,viewport:n.viewport.offsetHeight,scrollbar:{size:l.current.clientHeight,paddingStart:Nu(s.paddingTop),paddingEnd:Nu(s.paddingBottom)}})}})}),[pb,Tv]=Iv(La),Av=G.forwardRef((e,t)=>{let{__scopeScrollArea:a,sizes:r,hasThumb:o,onThumbChange:n,onThumbPointerUp:s,onThumbPointerDown:i,onThumbPositionChange:l,onDragScroll:u,onWheelScroll:d,onResize:c,...p}=e,g=Jt(La,a),[C,L]=G.useState(null),S=Ga(t,V=>L(V)),h=G.useRef(null),m=G.useRef(""),x=g.viewport,I=r.content-r.viewport,k=Ar(d),T=Ar(l),R=Fu(c,10);function A(V){if(h.current){let U=V.clientX-h.current.left,se=V.clientY-h.current.top;u({x:U,y:se})}}return G.useEffect(()=>{let V=U=>{let se=U.target;C?.contains(se)&&k(U,I)};return document.addEventListener("wheel",V,{passive:!1}),()=>document.removeEventListener("wheel",V,{passive:!1})},[x,C,I,k]),G.useEffect(T,[r,T]),vn(C,R),vn(g.content,R),(0,ce.jsx)(pb,{scope:a,scrollbar:C,hasThumb:o,onThumbChange:Ar(n),onThumbPointerUp:Ar(s),onThumbPositionChange:T,onThumbPointerDown:Ar(i),children:(0,ce.jsx)(gn.div,{...p,ref:S,style:{position:"absolute",...p.style},onPointerDown:Rr(e.onPointerDown,V=>{V.button===0&&(V.target.setPointerCapture(V.pointerId),h.current=C.getBoundingClientRect(),m.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",g.viewport&&(g.viewport.style.scrollBehavior="auto"),A(V))}),onPointerMove:Rr(e.onPointerMove,A),onPointerUp:Rr(e.onPointerUp,V=>{let U=V.target;U.hasPointerCapture(V.pointerId)&&U.releasePointerCapture(V.pointerId),document.body.style.webkitUserSelect=m.current,g.viewport&&(g.viewport.style.scrollBehavior=""),h.current=null})})})}),Mu="ScrollAreaThumb",Wp=G.forwardRef((e,t)=>{let{forceMount:a,...r}=e,o=Tv(Mu,e.__scopeScrollArea);return(0,ce.jsx)(xn,{present:a||o.hasThumb,children:(0,ce.jsx)(mb,{ref:t,...r})})}),mb=G.forwardRef((e,t)=>{let{__scopeScrollArea:a,style:r,...o}=e,n=Jt(Mu,a),s=Tv(Mu,a),{onThumbPositionChange:i}=s,l=Ga(t,c=>s.onThumbChange(c)),u=G.useRef(void 0),d=Fu(()=>{u.current&&(u.current(),u.current=void 0)},100);return G.useEffect(()=>{let c=n.viewport;if(c){let p=()=>{if(d(),!u.current){let g=xb(c,i);u.current=g,i()}};return i(),c.addEventListener("scroll",p),()=>c.removeEventListener("scroll",p)}},[n.viewport,d,i]),(0,ce.jsx)(gn.div,{"data-state":s.hasThumb?"visible":"hidden",...o,ref:l,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...r},onPointerDownCapture:Rr(e.onPointerDownCapture,c=>{let g=c.target.getBoundingClientRect(),C=c.clientX-g.left,L=c.clientY-g.top;s.onThumbPointerDown({x:C,y:L})}),onPointerUp:Rr(e.onPointerUp,s.onThumbPointerUp)})});Wp.displayName=Mu;var Gp="ScrollAreaCorner",Rv=G.forwardRef((e,t)=>{let a=Jt(Gp,e.__scopeScrollArea),r=!!(a.scrollbarX&&a.scrollbarY);return a.type!=="scroll"&&r?(0,ce.jsx)(hb,{...e,ref:t}):null});Rv.displayName=Gp;var hb=G.forwardRef((e,t)=>{let{__scopeScrollArea:a,...r}=e,o=Jt(Gp,a),[n,s]=G.useState(0),[i,l]=G.useState(0),u=!!(n&&i);return vn(o.scrollbarX,()=>{let d=o.scrollbarX?.offsetHeight||0;o.onCornerHeightChange(d),l(d)}),vn(o.scrollbarY,()=>{let d=o.scrollbarY?.offsetWidth||0;o.onCornerWidthChange(d),s(d)}),u?(0,ce.jsx)(gn.div,{...r,ref:t,style:{width:n,height:i,position:"absolute",right:o.dir==="ltr"?0:void 0,left:o.dir==="rtl"?0:void 0,bottom:0,...e.style}}):null});function Nu(e){return e?parseInt(e,10):0}function Dv(e,t){let a=e/t;return isNaN(a)?0:a}function Eu(e){let t=Dv(e.viewport,e.content),a=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,r=(e.scrollbar.size-a)*t;return Math.max(r,18)}function gb(e,t,a,r="ltr"){let o=Eu(a),n=o/2,s=t||n,i=o-s,l=a.scrollbar.paddingStart+s,u=a.scrollbar.size-a.scrollbar.paddingEnd-i,d=a.content-a.viewport,c=r==="ltr"?[0,d]:[d*-1,0];return Mv([l,u],c)(e)}function Cv(e,t,a="ltr"){let r=Eu(t),o=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,n=t.scrollbar.size-o,s=t.content-t.viewport,i=n-r,l=a==="ltr"?[0,s]:[s*-1,0],u=Lv(e,l);return Mv([0,s],[0,i])(u)}function Mv(e,t){return a=>{if(e[0]===e[1]||t[0]===t[1])return t[0];let r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(a-e[0])}}function Nv(e,t){return e>0&&e<t}var xb=(e,t=()=>{})=>{let a={left:e.scrollLeft,top:e.scrollTop},r=0;return(function o(){let n={left:e.scrollLeft,top:e.scrollTop},s=a.left!==n.left,i=a.top!==n.top;(s||i)&&t(),a=n,r=window.requestAnimationFrame(o)})(),()=>window.cancelAnimationFrame(r)};function Fu(e,t){let a=Ar(e),r=G.useRef(0);return G.useEffect(()=>()=>window.clearTimeout(r.current),[]),G.useCallback(()=>{window.clearTimeout(r.current),r.current=window.setTimeout(a,t)},[a,t])}function vn(e,t){let a=Ar(t);hi(()=>{let r=0;if(e){let o=new ResizeObserver(()=>{cancelAnimationFrame(r),r=window.requestAnimationFrame(a)});return o.observe(e),()=>{window.cancelAnimationFrame(r),o.unobserve(e)}}},[e,a])}var Ev=wv,Fv=bv;var Bv=Rv;var Dr=E(ue(),1),jp=Ov.forwardRef(({className:e,children:t,...a},r)=>(0,Dr.jsxs)(Ev,{"data-slot":"scroll-area",className:Ot("relative",e),...a,children:[(0,Dr.jsx)(Fv,{ref:r,"data-slot":"scroll-area-viewport",className:"focus-visible:ring-ring/50 size-full rounded-[inherit] transition-[color,box-shadow] outline-none focus-visible:ring-[3px] focus-visible:outline-1",children:t}),(0,Dr.jsx)(vb,{}),(0,Dr.jsx)(Bv,{})]}));jp.displayName="ScrollArea";function vb({className:e,orientation:t="vertical",...a}){return(0,Dr.jsx)(Hp,{"data-slot":"scroll-area-scrollbar",orientation:t,className:Ot("flex touch-none p-px transition-colors select-none",t==="vertical"&&"h-full w-2.5 border-l border-l-transparent",t==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent",e),...a,children:(0,Dr.jsx)(Wp,{"data-slot":"scroll-area-thumb",className:"bg-border relative flex-1 rounded-full"})})}var Ou=E(X());var Vv=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Lb=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,a,r)=>r?r.toUpperCase():a.toLowerCase()),Kp=e=>{let t=Lb(e);return t.charAt(0).toUpperCase()+t.slice(1)},Bu=(...e)=>e.filter((t,a,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===a).join(" ").trim(),Uv=e=>{for(let t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};var gi=E(X());var _v={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};var zv=(0,gi.forwardRef)(({color:e="currentColor",size:t=24,strokeWidth:a=2,absoluteStrokeWidth:r,className:o="",children:n,iconNode:s,...i},l)=>(0,gi.createElement)("svg",{ref:l,..._v,width:t,height:t,stroke:e,strokeWidth:r?Number(a)*24/Number(t):a,className:Bu("lucide",o),...!n&&!Uv(i)&&{"aria-hidden":"true"},...i},[...s.map(([u,d])=>(0,gi.createElement)(u,d)),...Array.isArray(n)?n:[n]]));var _=(e,t)=>{let a=(0,Ou.forwardRef)(({className:r,...o},n)=>(0,Ou.createElement)(zv,{ref:n,iconNode:t,className:Bu(`lucide-${Vv(Kp(e))}`,`lucide-${e}`,r),...o}));return a.displayName=Kp(e),a};var Cb=[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]],xi=_("activity",Cb);var Sb=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],Ln=_("arrow-left",Sb);var Ib=[["path",{d:"m5 12 7-7 7 7",key:"hav0vg"}],["path",{d:"M12 19V5",key:"x0mq9r"}]],yi=_("arrow-up",Ib);var wb=[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]],vi=_("calendar",wb);var kb=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],Li=_("chevron-down",kb);var bb=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]],da=_("circle-alert",bb);var Pb=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],$e=_("circle-check",Pb);var Tb=[["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"}]],ca=_("circle-x",Tb);var Ab=[["path",{d:"M12 6v6l4 2",key:"mmk7yg"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],mo=_("clock",Ab);var Rb=[["path",{d:"M15 6v12a3 3 0 1 0 3-3H6a3 3 0 1 0 3 3V6a3 3 0 1 0-3 3h12a3 3 0 1 0-3-3",key:"11bfej"}]],Ka=_("command",Rb);var Db=[["path",{d:"M20 4v7a4 4 0 0 1-4 4H4",key:"6o5b7l"}],["path",{d:"m9 10-5 5 5 5",key:"1kshq7"}]],$a=_("corner-down-left",Db);var Mb=[["rect",{width:"20",height:"14",x:"2",y:"5",rx:"2",key:"ynyp8z"}],["line",{x1:"2",x2:"22",y1:"10",y2:"10",key:"1b3vmo"}]],ho=_("credit-card",Mb);var Nb=[["path",{d:"M11.562 3.266a.5.5 0 0 1 .876 0L15.39 8.87a1 1 0 0 0 1.516.294L21.183 5.5a.5.5 0 0 1 .798.519l-2.834 10.246a1 1 0 0 1-.956.734H5.81a1 1 0 0 1-.957-.734L2.02 6.02a.5.5 0 0 1 .798-.519l4.276 3.664a1 1 0 0 0 1.516-.294z",key:"1vdc57"}],["path",{d:"M5 21h14",key:"11awu3"}]],go=_("crown",Nb);var Eb=[["line",{x1:"12",x2:"12",y1:"2",y2:"22",key:"7eqyqh"}],["path",{d:"M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6",key:"1b0p4s"}]],xo=_("dollar-sign",Eb);var Fb=[["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:"M8 13h2",key:"yr2amv"}],["path",{d:"M14 13h2",key:"un5t4a"}],["path",{d:"M8 17h2",key:"2yhykz"}],["path",{d:"M14 17h2",key:"10kma7"}]],Cn=_("file-spreadsheet",Fb);var Bb=[["path",{d:"m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4",key:"g0fldk"}],["path",{d:"m21 2-9.6 9.6",key:"1j0ho8"}],["circle",{cx:"7.5",cy:"15.5",r:"5.5",key:"yqb3hr"}]],Sn=_("key",Bb);var Ob=[["path",{d:"M18 5a2 2 0 0 1 2 2v8.526a2 2 0 0 0 .212.897l1.068 2.127a1 1 0 0 1-.9 1.45H3.62a1 1 0 0 1-.9-1.45l1.068-2.127A2 2 0 0 0 4 15.526V7a2 2 0 0 1 2-2z",key:"1pdavp"}],["path",{d:"M20.054 15.987H3.946",key:"14rxg9"}]],Ci=_("laptop",Ob);var Vb=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],Vt=_("loader-circle",Vb);var Ub=[["path",{d:"m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7",key:"132q7q"}],["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}]],In=_("mail",Ub);var _b=[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]],wn=_("map-pin",_b);var zb=[["path",{d:"M5 12h14",key:"1ays0h"}]],Si=_("minus",zb);var Hb=[["path",{d:"m16 6-8.414 8.586a2 2 0 0 0 2.829 2.829l8.414-8.586a4 4 0 1 0-5.657-5.657l-8.379 8.551a6 6 0 1 0 8.485 8.485l8.379-8.551",key:"1miecu"}]],Ii=_("paperclip",Hb);var qb=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]],kn=_("refresh-cw",qb);var Wb=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],yo=_("search",Wb);var Gb=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]],bn=_("shield",Gb);var jb=[["rect",{width:"14",height:"20",x:"5",y:"2",rx:"2",ry:"2",key:"1yt0o3"}],["path",{d:"M12 18h.01",key:"mhygvu"}]],wi=_("smartphone",jb);var Kb=[["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"}]],Ca=_("sparkles",Kb);var $b=[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1m0v6g"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z",key:"ohrbg2"}]],kt=_("square-pen",$b);var Xb=[["path",{d:"M16 7h6v6",key:"box55l"}],["path",{d:"m22 7-8.5 8.5-5-5L2 17",key:"1t1m79"}]],ki=_("trending-up",Xb);var Qb=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["path",{d:"M16 3.128a4 4 0 0 1 0 7.744",key:"16gr8j"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],Pn=_("users",Qb);var Yb=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],vo=_("x",Yb);var Zb=[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]],bi=_("zap",Zb);var De=E(ue(),1);function Hv({phase:e,progressSteps:t=[]}){return(0,De.jsxs)("div",{className:"mb-3 rounded-lg bg-muted/40 px-3 py-3 text-xs text-muted-foreground transition-colors",children:[e==="thinking"&&t.length===0&&(0,De.jsxs)("div",{className:"flex items-center gap-2",children:[(0,De.jsx)(Vt,{className:"h-3.5 w-3.5 animate-spin"}),(0,De.jsx)("span",{children:"Thinking\u2026"})]}),e==="searching"&&(0,De.jsxs)("div",{className:"space-y-2 animate-in fade-in-0 duration-300",children:[(0,De.jsxs)("div",{className:"flex items-center gap-2",children:[(0,De.jsx)(yo,{className:"h-3.5 w-3.5 opacity-70"}),(0,De.jsx)("span",{children:"Searching across pages\u2026"})]}),(0,De.jsxs)("ul",{className:"ml-6 list-disc space-y-1",children:[(0,De.jsx)("li",{className:"opacity-90",children:"Checking recent changes"}),(0,De.jsx)("li",{className:"opacity-90",children:"Scanning documentation"}),(0,De.jsx)("li",{className:"opacity-90",children:"Summarizing relevant sections"})]})]}),(e==="thinking"||e==="executing"||e==="responding")&&t.length>0&&(0,De.jsxs)("div",{className:"space-y-2 animate-in fade-in-0 duration-200",children:[t.map((a,r)=>(0,De.jsxs)("div",{className:`flex items-center gap-2 transition-opacity duration-200 ${a.completed?"opacity-60":"opacity-100"}`,children:[a.completed?(0,De.jsx)($e,{className:"h-3.5 w-3.5 text-green-500 flex-shrink-0"}):(0,De.jsx)(Vt,{className:"h-3.5 w-3.5 animate-spin flex-shrink-0"}),(0,De.jsx)("span",{className:a.completed?"line-through":"",children:a.message})]},r)),e==="responding"&&(0,De.jsxs)("div",{className:"flex items-center gap-2 opacity-100 animate-in fade-in-0 duration-200",children:[(0,De.jsx)(Vt,{className:"h-3.5 w-3.5 animate-spin flex-shrink-0"}),(0,De.jsx)("span",{children:"Preparing response..."})]})]})]})}var qv=E(X(),1);var fa=E(ue(),1);function Wv({title:e,links:t}){let[a,r]=qv.useState(!1);return(0,fa.jsxs)("div",{className:"text-xs text-muted-foreground",children:[(0,fa.jsx)("button",{type:"button",onClick:()=>r(o=>!o),className:"flex w-full items-center gap-2 px-0 py-0","aria-expanded":a,children:(0,fa.jsxs)("div",{className:"flex items-center gap-1.5",children:[a?(0,fa.jsx)(Li,{className:"h-3 w-3 opacity-70"}):(0,fa.jsx)(yo,{className:"h-3 w-3 opacity-70"}),(0,fa.jsx)("span",{children:e})]})}),a&&t.length>0&&(0,fa.jsx)("ul",{className:"ml-5 mt-1 space-y-0.5",children:t.map(o=>(0,fa.jsx)("li",{children:(0,fa.jsx)("a",{href:o.href,target:"_blank",rel:"noreferrer",className:"text-primary hover:underline",children:o.label})},o.href))})]})}var Ti=E(ue(),1),Sa=E(X(),1);var Gv=E(X(),1),Tn=(0,Gv.createContext)({});var jv=E(X(),1);function An(e){let t=(0,jv.useRef)(null);return t.current===null&&(t.current=e()),t.current}var Xp=E(ue(),1),Yv=E(X(),1),Lo=E(X(),1);var Kv=E(X(),1),Mr=(0,Kv.createContext)(null);var Xv=E(ue(),1),Vu=E(X(),1),Xa=E(X(),1);var $v=E(X(),1),Rn=(0,$v.createContext)({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});var $p=class extends Vu.Component{getSnapshotBeforeUpdate(t){let a=this.props.childRef.current;if(a&&t.isPresent&&!this.props.isPresent){let r=this.props.sizeRef.current;r.height=a.offsetHeight||0,r.width=a.offsetWidth||0,r.top=a.offsetTop,r.left=a.offsetLeft}return null}componentDidUpdate(){}render(){return this.props.children}};function Qv({children:e,isPresent:t}){let a=(0,Xa.useId)(),r=(0,Xa.useRef)(null),o=(0,Xa.useRef)({width:0,height:0,top:0,left:0}),{nonce:n}=(0,Xa.useContext)(Rn);return(0,Xa.useInsertionEffect)(()=>{let{width:s,height:i,top:l,left:u}=o.current;if(t||!r.current||!s||!i)return;r.current.dataset.motionPopId=a;let d=document.createElement("style");return n&&(d.nonce=n),document.head.appendChild(d),d.sheet&&d.sheet.insertRule(`
|
|
9
9
|
[data-motion-pop-id="${a}"] {
|
|
10
10
|
position: absolute !important;
|
|
11
11
|
width: ${s}px !important;
|
|
@@ -13,30 +13,30 @@ Error generating stack: `+n.message+`
|
|
|
13
13
|
top: ${l}px !important;
|
|
14
14
|
left: ${u}px !important;
|
|
15
15
|
}
|
|
16
|
-
`),()=>{document.head.removeChild(d)}},[t]),(0,$v.jsx)(Kp,{isPresent:t,childRef:r,sizeRef:o,children:Ou.cloneElement(e,{ref:r})})}var Yv=({children:e,initial:t,isPresent:a,onExitComplete:r,custom:o,presenceAffectsLayout:n,mode:s})=>{let i=An(Yb),l=(0,Lo.useId)(),u=(0,Lo.useCallback)(c=>{i.set(c,!0);for(let p of i.values())if(!p)return;r&&r()},[i,r]),d=(0,Lo.useMemo)(()=>({id:l,initial:t,isPresent:a,custom:o,onExitComplete:u,register:c=>(i.set(c,!1),()=>i.delete(c))}),n?[Math.random(),u]:[a,u]);return(0,Lo.useMemo)(()=>{i.forEach((c,p)=>i.set(p,!1))},[a]),Qv.useEffect(()=>{!a&&!i.size&&r&&r()},[a]),s==="popLayout"&&(e=(0,$p.jsx)(Xv,{isPresent:a,children:e})),(0,$p.jsx)(Nr.Provider,{value:d,children:e})};function Yb(){return new Map}var Er=E(X(),1);function Vu(e=!0){let t=(0,Er.useContext)(Nr);if(t===null)return[!0,null];let{isPresent:a,onExitComplete:r,register:o}=t,n=(0,Er.useId)();(0,Er.useEffect)(()=>{e&&o(n)},[e]);let s=(0,Er.useCallback)(()=>e&&r&&r(n),[n,r,e]);return!a&&r?[!1,s]:[!0]}var Uu=E(X(),1),bi=e=>e.key||"";function Xp(e){let t=[];return Uu.Children.forEach(e,a=>{(0,Uu.isValidElement)(a)&&t.push(a)}),t}var _u=E(X(),1);var Dn=typeof window<"u";var zu=Dn?_u.useLayoutEffect:_u.useEffect;var Qp=({children:e,custom:t,initial:a=!0,onExitComplete:r,presenceAffectsLayout:o=!0,mode:n="sync",propagate:s=!1})=>{let[i,l]=Vu(s),u=(0,Sa.useMemo)(()=>Xp(e),[e]),d=s&&!i?[]:u.map(bi),c=(0,Sa.useRef)(!0),p=(0,Sa.useRef)(u),g=An(()=>new Map),[C,L]=(0,Sa.useState)(u),[S,h]=(0,Sa.useState)(u);zu(()=>{c.current=!1,p.current=u;for(let I=0;I<S.length;I++){let k=bi(S[I]);d.includes(k)?g.delete(k):g.get(k)!==!0&&g.set(k,!1)}},[S,d.length,d.join("-")]);let m=[];if(u!==C){let I=[...u];for(let k=0;k<S.length;k++){let T=S[k],R=bi(T);d.includes(R)||(I.splice(k,0,T),m.push(T))}n==="wait"&&m.length&&(I=m),h(Xp(I)),L(u);return}let{forceRender:x}=(0,Sa.useContext)(Tn);return(0,Pi.jsx)(Pi.Fragment,{children:S.map(I=>{let k=bi(I),T=s&&!i?!1:u===S||d.includes(k),R=()=>{if(g.has(k))g.set(k,!0);else return;let A=!0;g.forEach(V=>{V||(A=!1)}),A&&(x?.(),h(p.current),s&&l?.(),r&&r())};return(0,Pi.jsx)(Yv,{isPresent:T,initial:!c.current||a?void 0:!1,custom:T?void 0:t,presenceAffectsLayout:o,mode:n,onExitComplete:T?void 0:R,children:I},k)})})};var he=e=>e;var Qa=he,pa=he;function Co(e){let t;return()=>(t===void 0&&(t=e()),t)}var Ut=(e,t,a)=>{let r=t-e;return r===0?1:(a-e)/r};var Ee=e=>e*1e3,Je=e=>e/1e3;var Mn={skipAnimations:!1,useManualTiming:!1};function Zv(e){let t=new Set,a=new Set,r=!1,o=!1,n=new WeakSet,s={delta:0,timestamp:0,isProcessing:!1};function i(u){n.has(u)&&(l.schedule(u),e()),u(s)}let l={schedule:(u,d=!1,c=!1)=>{let g=c&&r?t:a;return d&&n.add(u),g.has(u)||g.add(u),u},cancel:u=>{a.delete(u),n.delete(u)},process:u=>{if(s=u,r){o=!0;return}r=!0,[t,a]=[a,t],t.forEach(i),t.clear(),r=!1,o&&(o=!1,l.process(u))}};return l}var Hu=["read","resolveKeyframes","update","preRender","render","postRender"],Zb=40;function qu(e,t){let a=!1,r=!0,o={delta:0,timestamp:0,isProcessing:!1},n=()=>a=!0,s=Hu.reduce((h,m)=>(h[m]=Zv(n),h),{}),{read:i,resolveKeyframes:l,update:u,preRender:d,render:c,postRender:p}=s,g=()=>{let h=Mn.useManualTiming?o.timestamp:performance.now();a=!1,o.delta=r?1e3/60:Math.max(Math.min(h-o.timestamp,Zb),1),o.timestamp=h,o.isProcessing=!0,i.process(o),l.process(o),u.process(o),d.process(o),c.process(o),p.process(o),o.isProcessing=!1,a&&t&&(r=!1,e(g))},C=()=>{a=!0,r=!0,o.isProcessing||e(g)};return{schedule:Hu.reduce((h,m)=>{let x=s[m];return h[m]=(I,k=!1,T=!1)=>(a||C(),x.schedule(I,k,T)),h},{}),cancel:h=>{for(let m=0;m<Hu.length;m++)s[Hu[m]].cancel(h)},state:o,steps:s}}var{schedule:J,cancel:_t,state:Fe,steps:Wu}=qu(typeof requestAnimationFrame<"u"?requestAnimationFrame:he,!0);var Jv=E(X(),1),Gu=(0,Jv.createContext)({strict:!1});var e0={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"]},Ya={};for(let e in e0)Ya[e]={isEnabled:t=>e0[e].some(a=>!!t[a])};function t0(e){for(let t in e)Ya[t]={...Ya[t],...e[t]}}var Jb=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Ti(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||Jb.has(e)}var a0=e=>!Ti(e);function eP(e){e&&(a0=t=>t.startsWith("on")?!Ti(t):e(t))}try{eP(FS("@emotion/is-prop-valid").default)}catch{}function r0(e,t,a){let r={};for(let o in e)o==="values"&&typeof e.values=="object"||(a0(o)||a===!0&&Ti(o)||!t&&!Ti(o)||e.draggable&&o.startsWith("onDrag"))&&(r[o]=e[o]);return r}function o0(e){if(typeof Proxy>"u")return e;let t=new Map,a=(...r)=>e(...r);return new Proxy(a,{get:(r,o)=>o==="create"?e:(t.has(o)||t.set(o,e(o)),t.get(o))})}var Yu=E(ue(),1);var Fn=E(X(),1);var n0=E(X(),1),Fr=(0,n0.createContext)({});var $u=E(X(),1);function Za(e){return typeof e=="string"||Array.isArray(e)}function Br(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}var ju=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Ai=["initial",...ju];function So(e){return Br(e.animate)||Ai.some(t=>Za(e[t]))}function Ku(e){return!!(So(e)||e.variants)}function s0(e,t){if(So(e)){let{initial:a,animate:r}=e;return{initial:a===!1||Za(a)?a:void 0,animate:Za(r)?r:void 0}}return e.inherit!==!1?t:{}}function l0(e){let{initial:t,animate:a}=s0(e,(0,$u.useContext)(Fr));return(0,$u.useMemo)(()=>({initial:t,animate:a}),[i0(t),i0(a)])}function i0(e){return Array.isArray(e)?e.join(" "):e}var u0=Symbol.for("motionComponentSymbol");var d0=E(X(),1);function Ja(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function c0(e,t,a){return(0,d0.useCallback)(r=>{r&&e.onMount&&e.onMount(r),t&&(r?t.mount(r):t.unmount()),a&&(typeof a=="function"?a(r):Ja(a)&&(a.current=r))},[t])}var bt=E(X(),1);var Nn=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase();var tP="framerAppearId",Xu="data-"+Nn(tP);var{schedule:En,cancel:KM}=qu(queueMicrotask,!1);var f0=E(X(),1),Qu=(0,f0.createContext)({});function p0(e,t,a,r,o){var n,s;let{visualElement:i}=(0,bt.useContext)(Fr),l=(0,bt.useContext)(Gu),u=(0,bt.useContext)(Nr),d=(0,bt.useContext)(Rn).reducedMotion,c=(0,bt.useRef)(null);r=r||l.renderer,!c.current&&r&&(c.current=r(e,{visualState:t,parent:i,props:a,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:d}));let p=c.current,g=(0,bt.useContext)(Qu);p&&!p.projection&&o&&(p.type==="html"||p.type==="svg")&&aP(c.current,a,o,g);let C=(0,bt.useRef)(!1);(0,bt.useInsertionEffect)(()=>{p&&C.current&&p.update(a,u)});let L=a[Xu],S=(0,bt.useRef)(!!L&&!(!((n=window.MotionHandoffIsComplete)===null||n===void 0)&&n.call(window,L))&&((s=window.MotionHasOptimisedAnimation)===null||s===void 0?void 0:s.call(window,L)));return zu(()=>{p&&(C.current=!0,window.MotionIsMounted=!0,p.updateFeatures(),En.render(p.render),S.current&&p.animationState&&p.animationState.animateChanges())}),(0,bt.useEffect)(()=>{p&&(!S.current&&p.animationState&&p.animationState.animateChanges(),S.current&&(queueMicrotask(()=>{var h;(h=window.MotionHandoffMarkAsComplete)===null||h===void 0||h.call(window,L)}),S.current=!1))}),p}function aP(e,t,a,r){let{layoutId:o,layout:n,drag:s,dragConstraints:i,layoutScroll:l,layoutRoot:u}=t;e.projection=new a(e.latestValues,t["data-framer-portal-id"]?void 0:m0(e.parent)),e.projection.setOptions({layoutId:o,layout:n,alwaysMeasureLayout:!!s||i&&Ja(i),visualElement:e,animationType:typeof n=="string"?n:"both",initialPromotionConfig:r,layoutScroll:l,layoutRoot:u})}function m0(e){if(e)return e.options.allowProjection!==!1?e.projection:m0(e.parent)}function h0({preloadedFeatures:e,createVisualElement:t,useRender:a,useVisualState:r,Component:o}){var n,s;e&&t0(e);function i(u,d){let c,p={...(0,Fn.useContext)(Rn),...u,layoutId:rP(u)},{isStatic:g}=p,C=l0(u),L=r(u,g);if(!g&&Dn){oP(p,e);let S=nP(p);c=S.MeasureLayout,C.visualElement=p0(o,L,p,t,S.ProjectionNode)}return(0,Yu.jsxs)(Fr.Provider,{value:C,children:[c&&C.visualElement?(0,Yu.jsx)(c,{visualElement:C.visualElement,...p}):null,a(o,u,c0(L,C.visualElement,d),L,g,C.visualElement)]})}i.displayName=`motion.${typeof o=="string"?o:`create(${(s=(n=o.displayName)!==null&&n!==void 0?n:o.name)!==null&&s!==void 0?s:""})`}`;let l=(0,Fn.forwardRef)(i);return l[u0]=o,l}function rP({layoutId:e}){let t=(0,Fn.useContext)(Tn).id;return t&&e!==void 0?t+"-"+e:e}function oP(e,t){let a=(0,Fn.useContext)(Gu).strict}function nP(e){let{drag:t,layout:a}=Ya;if(!t&&!a)return{};let r={...t,...a};return{MeasureLayout:t?.isEnabled(e)||a?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}var g0=["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 Bn(e){return typeof e!="string"||e.includes("-")?!1:!!(g0.indexOf(e)>-1||/[A-Z]/u.test(e))}var Yp=E(X(),1);function x0(e){let t=[{},{}];return e?.values.forEach((a,r)=>{t[0][r]=a.get(),t[1][r]=a.getVelocity()}),t}function On(e,t,a,r){if(typeof t=="function"){let[o,n]=x0(r);t=t(a!==void 0?a:e.custom,o,n)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){let[o,n]=x0(r);t=t(a!==void 0?a:e.custom,o,n)}return t}var Ri=e=>Array.isArray(e);var y0=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),v0=e=>Ri(e)?e[e.length-1]||0:e;var ye=e=>!!(e&&e.getVelocity);function Vn(e){let t=ye(e)?e.get():e;return y0(t)?t.toValue():t}function sP({scrapeMotionValuesFromProps:e,createRenderState:t,onUpdate:a},r,o,n){let s={latestValues:iP(r,o,n,e),renderState:t()};return a&&(s.onMount=i=>a({props:r,current:i,...s}),s.onUpdate=i=>a(i)),s}var Zu=e=>(t,a)=>{let r=(0,Yp.useContext)(Fr),o=(0,Yp.useContext)(Nr),n=()=>sP(e,t,r,o);return a?n():An(n)};function iP(e,t,a,r){let o={},n=r(e,{});for(let p in n)o[p]=Vn(n[p]);let{initial:s,animate:i}=e,l=So(e),u=Ku(e);t&&u&&!l&&e.inherit!==!1&&(s===void 0&&(s=t.initial),i===void 0&&(i=t.animate));let d=a?a.initial===!1:!1;d=d||s===!1;let c=d?i:s;if(c&&typeof c!="boolean"&&!Br(c)){let p=Array.isArray(c)?c:[c];for(let g=0;g<p.length;g++){let C=On(e,p[g]);if(C){let{transitionEnd:L,transition:S,...h}=C;for(let m in h){let x=h[m];if(Array.isArray(x)){let I=d?x.length-1:0;x=x[I]}x!==null&&(o[m]=x)}for(let m in L)o[m]=L[m]}}}return o}var Ia=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Pt=new Set(Ia);var L0=e=>t=>typeof t=="string"&&t.startsWith(e),Ju=L0("--"),lP=L0("var(--"),Un=e=>lP(e)?uP.test(e.split("/*")[0].trim()):!1,uP=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;var ed=(e,t)=>t&&typeof e=="number"?t.transform(e):e;var et=(e,t,a)=>a>t?t:a<e?e:a;var wa={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},er={...wa,transform:e=>et(0,1,e)},Di={...wa,default:1};var Mi=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),ka=Mi("deg"),ht=Mi("%"),H=Mi("px"),C0=Mi("vh"),S0=Mi("vw"),Zp={...ht,parse:e=>ht.parse(e)/100,transform:e=>ht.transform(e*100)};var I0={borderWidth:H,borderTopWidth:H,borderRightWidth:H,borderBottomWidth:H,borderLeftWidth:H,borderRadius:H,radius:H,borderTopLeftRadius:H,borderTopRightRadius:H,borderBottomRightRadius:H,borderBottomLeftRadius:H,width:H,maxWidth:H,height:H,maxHeight:H,top:H,right:H,bottom:H,left:H,padding:H,paddingTop:H,paddingRight:H,paddingBottom:H,paddingLeft:H,margin:H,marginTop:H,marginRight:H,marginBottom:H,marginLeft:H,backgroundPositionX:H,backgroundPositionY:H};var w0={rotate:ka,rotateX:ka,rotateY:ka,rotateZ:ka,scale:Di,scaleX:Di,scaleY:Di,scaleZ:Di,skew:ka,skewX:ka,skewY:ka,distance:H,translateX:H,translateY:H,translateZ:H,x:H,y:H,z:H,perspective:H,transformPerspective:H,opacity:er,originX:Zp,originY:Zp,originZ:H};var Jp={...wa,transform:Math.round};var _n={...I0,...w0,zIndex:Jp,size:H,fillOpacity:er,strokeOpacity:er,numOctaves:Jp};var dP={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},cP=Ia.length;function k0(e,t,a){let r="",o=!0;for(let n=0;n<cP;n++){let s=Ia[n],i=e[s];if(i===void 0)continue;let l=!0;if(typeof i=="number"?l=i===(s.startsWith("scale")?1:0):l=parseFloat(i)===0,!l||a){let u=ed(i,_n[s]);if(!l){o=!1;let d=dP[s]||s;r+=`${d}(${u}) `}a&&(t[s]=u)}}return r=r.trim(),a?r=a(t,o?"":r):o&&(r="none"),r}function zn(e,t,a){let{style:r,vars:o,transformOrigin:n}=e,s=!1,i=!1;for(let l in t){let u=t[l];if(Pt.has(l)){s=!0;continue}else if(Ju(l)){o[l]=u;continue}else{let d=ed(u,_n[l]);l.startsWith("origin")?(i=!0,n[l]=d):r[l]=d}}if(t.transform||(s||a?r.transform=k0(t,e.transform,a):r.transform&&(r.transform="none")),i){let{originX:l="50%",originY:u="50%",originZ:d=0}=n;r.transformOrigin=`${l} ${u} ${d}`}}var fP={offset:"stroke-dashoffset",array:"stroke-dasharray"},pP={offset:"strokeDashoffset",array:"strokeDasharray"};function b0(e,t,a=1,r=0,o=!0){e.pathLength=1;let n=o?fP:pP;e[n.offset]=H.transform(-r);let s=H.transform(t),i=H.transform(a);e[n.array]=`${s} ${i}`}function P0(e,t,a){return typeof e=="string"?e:H.transform(t+a*e)}function T0(e,t,a){let r=P0(t,e.x,e.width),o=P0(a,e.y,e.height);return`${r} ${o}`}function Hn(e,{attrX:t,attrY:a,attrScale:r,originX:o,originY:n,pathLength:s,pathSpacing:i=1,pathOffset:l=0,...u},d,c){if(zn(e,u,c),d){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};let{attrs:p,style:g,dimensions:C}=e;p.transform&&(C&&(g.transform=p.transform),delete p.transform),C&&(o!==void 0||n!==void 0||g.transform)&&(g.transformOrigin=T0(C,o!==void 0?o:.5,n!==void 0?n:.5)),t!==void 0&&(p.x=t),a!==void 0&&(p.y=a),r!==void 0&&(p.scale=r),s!==void 0&&b0(p,s,i,l,!1)}var qn=()=>({style:{},transform:{},transformOrigin:{},vars:{}});var td=()=>({...qn(),attrs:{}});var Wn=e=>typeof e=="string"&&e.toLowerCase()==="svg";function ad(e,{style:t,vars:a},r,o){Object.assign(e.style,t,o&&o.getProjectionStyles(r));for(let n in a)e.style.setProperty(n,a[n])}var rd=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"]);function od(e,t,a,r){ad(e,t,void 0,r);for(let o in t.attrs)e.setAttribute(rd.has(o)?o:Nn(o),t.attrs[o])}var Gn={};function A0(e){Object.assign(Gn,e)}function nd(e,{layout:t,layoutId:a}){return Pt.has(e)||e.startsWith("origin")||(t||a!==void 0)&&(!!Gn[e]||e==="opacity")}function jn(e,t,a){var r;let{style:o}=e,n={};for(let s in o)(ye(o[s])||t.style&&ye(t.style[s])||nd(s,e)||((r=a?.getValue(s))===null||r===void 0?void 0:r.liveStyle)!==void 0)&&(n[s]=o[s]);return n}function sd(e,t,a){let r=jn(e,t,a);for(let o in e)if(ye(e[o])||ye(t[o])){let n=Ia.indexOf(o)!==-1?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o;r[n]=e[o]}return r}function mP(e,t){try{t.dimensions=typeof e.getBBox=="function"?e.getBBox():e.getBoundingClientRect()}catch{t.dimensions={x:0,y:0,width:0,height:0}}}var R0=["x","y","width","height","cx","cy","r"],D0={useVisualState:Zu({scrapeMotionValuesFromProps:sd,createRenderState:td,onUpdate:({props:e,prevProps:t,current:a,renderState:r,latestValues:o})=>{if(!a)return;let n=!!e.drag;if(!n){for(let i in o)if(Pt.has(i)){n=!0;break}}if(!n)return;let s=!t;if(t)for(let i=0;i<R0.length;i++){let l=R0[i];e[l]!==t[l]&&(s=!0)}s&&J.read(()=>{mP(a,r),J.render(()=>{Hn(r,o,Wn(a.tagName),e.transformTemplate),od(a,r)})})}})};var M0={useVisualState:Zu({scrapeMotionValuesFromProps:jn,createRenderState:qn})};var Kn=E(X(),1);var N0=E(X(),1);function em(e,t,a){for(let r in t)!ye(t[r])&&!nd(r,a)&&(e[r]=t[r])}function hP({transformTemplate:e},t){return(0,N0.useMemo)(()=>{let a=qn();return zn(a,t,e),Object.assign({},a.vars,a.style)},[t])}function gP(e,t){let a=e.style||{},r={};return em(r,a,e),Object.assign(r,hP(e,t)),r}function E0(e,t){let a={},r=gP(e,t);return e.drag&&e.dragListener!==!1&&(a.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(a.tabIndex=0),a.style=r,a}var F0=E(X(),1);function B0(e,t,a,r){let o=(0,F0.useMemo)(()=>{let n=td();return Hn(n,t,Wn(r),e.transformTemplate),{...n.attrs,style:{...n.style}}},[t]);if(e.style){let n={};em(n,e.style,e),o.style={...n,...o.style}}return o}function O0(e=!1){return(a,r,o,{latestValues:n},s)=>{let l=(Bn(a)?B0:E0)(r,n,s,a),u=r0(r,typeof a=="string",e),d=a!==Kn.Fragment?{...u,...l,ref:o}:{},{children:c}=r,p=(0,Kn.useMemo)(()=>ye(c)?c.get():c,[c]);return(0,Kn.createElement)(a,{...d,children:p})}}function V0(e,t){return function(r,{forwardMotionProps:o}={forwardMotionProps:!1}){let s={...Bn(r)?D0:M0,preloadedFeatures:e,useRender:O0(o),createVisualElement:t,Component:r};return h0(s)}}function tm(e,t){if(!Array.isArray(t))return!1;let a=t.length;if(a!==e.length)return!1;for(let r=0;r<a;r++)if(t[r]!==e[r])return!1;return!0}function Or(e,t,a){let r=e.getProps();return On(r,t,a!==void 0?a:r.custom,e)}var am=Co(()=>window.ScrollTimeline!==void 0);var Ni=class{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}get finished(){return Promise.all(this.animations.map(t=>"finished"in t?t.finished:t))}getAll(t){return this.animations[0][t]}setAll(t,a){for(let r=0;r<this.animations.length;r++)this.animations[r][t]=a}attachTimeline(t,a){let r=this.animations.map(o=>{if(am()&&o.attachTimeline)return o.attachTimeline(t);if(typeof a=="function")return a(o)});return()=>{r.forEach((o,n)=>{o&&o(),this.animations[n].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get startTime(){return this.getAll("startTime")}get duration(){let t=0;for(let a=0;a<this.animations.length;a++)t=Math.max(t,this.animations[a].duration);return t}runAll(t){this.animations.forEach(a=>a[t]())}flatten(){this.runAll("flatten")}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}};var Ei=class extends Ni{then(t,a){return Promise.all(this.animations).then(t).catch(a)}};function Vr(e,t){return e?e[t]||e.default||e:void 0}function $n(e){let t=0,a=50,r=e.next(t);for(;!r.done&&t<2e4;)t+=a,r=e.next(t);return t>=2e4?1/0:t}function Ur(e){return typeof e=="function"}function Fi(e,t){e.timeline=t,e.onfinish=null}var Xn=e=>Array.isArray(e)&&typeof e[0]=="number";var om={linearEasing:void 0};function U0(e,t){let a=Co(e);return()=>{var r;return(r=om[t])!==null&&r!==void 0?r:a()}}var _r=U0(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing");var Bi=(e,t,a=10)=>{let r="",o=Math.max(Math.round(t/a),2);for(let n=0;n<o;n++)r+=e(Ut(0,o-1,n))+", ";return`linear(${r.substring(0,r.length-2)})`};function ld(e){return!!(typeof e=="function"&&_r()||!e||typeof e=="string"&&(e in id||_r())||Xn(e)||Array.isArray(e)&&e.every(ld))}var Qn=([e,t,a,r])=>`cubic-bezier(${e}, ${t}, ${a}, ${r})`,id={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Qn([0,.65,.55,1]),circOut:Qn([.55,0,1,.45]),backIn:Qn([.31,.01,.66,-.59]),backOut:Qn([.33,1.53,.69,.99])};function Yn(e,t){if(e)return typeof e=="function"&&_r()?Bi(e,t):Xn(e)?Qn(e):Array.isArray(e)?e.map(a=>Yn(a,t)||id.easeOut):id[e]}var zt={x:!1,y:!1};function Zn(){return zt.x||zt.y}function nm(e,t,a){var r;if(e instanceof Element)return[e];if(typeof e=="string"){let o=document;t&&(o=t.current);let n=(r=a?.[e])!==null&&r!==void 0?r:o.querySelectorAll(e);return n?Array.from(n):[]}return Array.from(e)}function ud(e,t){let a=nm(e),r=new AbortController,o={passive:!0,...t,signal:r.signal};return[a,o,()=>r.abort()]}function _0(e){return t=>{t.pointerType==="touch"||Zn()||e(t)}}function sm(e,t,a={}){let[r,o,n]=ud(e,a),s=_0(i=>{let{target:l}=i,u=t(i);if(typeof u!="function"||!l)return;let d=_0(c=>{u(c),l.removeEventListener("pointerleave",d)});l.addEventListener("pointerleave",d,o)});return r.forEach(i=>{i.addEventListener("pointerenter",s,o)}),n}var dd=(e,t)=>t?e===t?!0:dd(e,t.parentElement):!1;var Io=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;var xP=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function z0(e){return xP.has(e.tagName)||e.tabIndex!==-1}var wo=new WeakSet;function H0(e){return t=>{t.key==="Enter"&&e(t)}}function im(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}var q0=(e,t)=>{let a=e.currentTarget;if(!a)return;let r=H0(()=>{if(wo.has(a))return;im(a,"down");let o=H0(()=>{im(a,"up")}),n=()=>im(a,"cancel");a.addEventListener("keyup",o,t),a.addEventListener("blur",n,t)});a.addEventListener("keydown",r,t),a.addEventListener("blur",()=>a.removeEventListener("keydown",r),t)};function W0(e){return Io(e)&&!Zn()}function lm(e,t,a={}){let[r,o,n]=ud(e,a),s=i=>{let l=i.currentTarget;if(!W0(i)||wo.has(l))return;wo.add(l);let u=t(i),d=(g,C)=>{window.removeEventListener("pointerup",c),window.removeEventListener("pointercancel",p),!(!W0(g)||!wo.has(l))&&(wo.delete(l),typeof u=="function"&&u(g,{success:C}))},c=g=>{d(g,a.useGlobalTarget||dd(l,g.target))},p=g=>{d(g,!1)};window.addEventListener("pointerup",c,o),window.addEventListener("pointercancel",p,o)};return r.forEach(i=>{!z0(i)&&i.getAttribute("tabindex")===null&&(i.tabIndex=0),(a.useGlobalTarget?window:i).addEventListener("pointerdown",s,o),i.addEventListener("focus",u=>q0(u,o),o)}),n}function um(e){return e==="x"||e==="y"?zt[e]?null:(zt[e]=!0,()=>{zt[e]=!1}):zt.x||zt.y?null:(zt.x=zt.y=!0,()=>{zt.x=zt.y=!1})}var cd=new Set(["width","height","top","left","right","bottom",...Ia]);var fd;function vP(){fd=void 0}var lt={now:()=>(fd===void 0&<.set(Fe.isProcessing||Mn.useManualTiming?Fe.timestamp:performance.now()),fd),set:e=>{fd=e,queueMicrotask(vP)}};function Jn(e,t){e.indexOf(t)===-1&&e.push(t)}function es(e,t){let a=e.indexOf(t);a>-1&&e.splice(a,1)}var zr=class{constructor(){this.subscriptions=[]}add(t){return Jn(this.subscriptions,t),()=>es(this.subscriptions,t)}notify(t,a,r){let o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](t,a,r);else for(let n=0;n<o;n++){let s=this.subscriptions[n];s&&s(t,a,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}};function pd(e,t){return t?e*(1e3/t):0}var j0=30,LP=e=>!isNaN(parseFloat(e)),K0={current:void 0},dm=class{constructor(t,a={}){this.version="11.18.2",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(r,o=!0)=>{let n=lt.now();this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),o&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=a.owner}setCurrent(t){this.current=t,this.updatedAt=lt.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=LP(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,a){this.events[t]||(this.events[t]=new zr);let r=this.events[t].add(a);return t==="change"?()=>{r(),J.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(let t in this.events)this.events[t].clear()}attach(t,a){this.passiveEffect=t,this.stopPassiveEffect=a}set(t,a=!0){!a||!this.passiveEffect?this.updateAndNotify(t,a):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,a,r){this.set(a),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,a=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,a&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return K0.current&&K0.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){let t=lt.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>j0)return 0;let a=Math.min(this.updatedAt-this.prevUpdatedAt,j0);return pd(parseFloat(this.current)-parseFloat(this.prevFrameValue),a)}start(t){return this.stop(),new Promise(a=>{this.hasAnimated=!0,this.animation=t(a),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function tr(e,t){return new dm(e,t)}function CP(e,t,a){e.hasValue(t)?e.getValue(t).set(a):e.addValue(t,tr(a))}function $0(e,t){let a=Or(e,t),{transitionEnd:r={},transition:o={},...n}=a||{};n={...n,...r};for(let s in n){let i=v0(n[s]);CP(e,s,i)}}function X0(e){return!!(ye(e)&&e.add)}function Oi(e,t){let a=e.getValue("willChange");if(X0(a))return a.add(t)}function md(e){return e.props[Xu]}var hd={current:!1};var Q0=(e,t,a)=>(((1-3*a+3*t)*e+(3*a-6*t))*e+3*t)*e,SP=1e-7,IP=12;function wP(e,t,a,r,o){let n,s,i=0;do s=t+(a-t)/2,n=Q0(s,r,o)-e,n>0?a=s:t=s;while(Math.abs(n)>SP&&++i<IP);return s}function Hr(e,t,a,r){if(e===t&&a===r)return he;let o=n=>wP(n,0,1,e,a);return n=>n===0||n===1?n:Q0(o(n),t,r)}var gd=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2;var xd=e=>t=>1-e(1-t);var cm=Hr(.33,1.53,.69,.99),Vi=xd(cm),yd=gd(Vi);var vd=e=>(e*=2)<1?.5*Vi(e):.5*(2-Math.pow(2,-10*(e-1)));var Ld=e=>1-Math.sin(Math.acos(e)),Cd=xd(Ld),Sd=gd(Ld);var Id=e=>/^0[^.\s]+$/u.test(e);function Y0(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||Id(e):!0}var qr=e=>Math.round(e*1e5)/1e5;var ts=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Z0(e){return e==null}var J0=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu;var as=(e,t)=>a=>!!(typeof a=="string"&&J0.test(a)&&a.startsWith(e)||t&&!Z0(a)&&Object.prototype.hasOwnProperty.call(a,t)),wd=(e,t,a)=>r=>{if(typeof r!="string")return r;let[o,n,s,i]=r.match(ts);return{[e]:parseFloat(o),[t]:parseFloat(n),[a]:parseFloat(s),alpha:i!==void 0?parseFloat(i):1}};var kP=e=>et(0,255,e),fm={...wa,transform:e=>Math.round(kP(e))},ba={test:as("rgb","red"),parse:wd("red","green","blue"),transform:({red:e,green:t,blue:a,alpha:r=1})=>"rgba("+fm.transform(e)+", "+fm.transform(t)+", "+fm.transform(a)+", "+qr(er.transform(r))+")"};function bP(e){let t="",a="",r="",o="";return e.length>5?(t=e.substring(1,3),a=e.substring(3,5),r=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),a=e.substring(2,3),r=e.substring(3,4),o=e.substring(4,5),t+=t,a+=a,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(a,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}}var Ui={test:as("#"),parse:bP,transform:ba.transform};var Wr={test:as("hsl","hue"),parse:wd("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:a,alpha:r=1})=>"hsla("+Math.round(e)+", "+ht.transform(qr(t))+", "+ht.transform(qr(a))+", "+qr(er.transform(r))+")"};var Ue={test:e=>ba.test(e)||Ui.test(e)||Wr.test(e),parse:e=>ba.test(e)?ba.parse(e):Wr.test(e)?Wr.parse(e):Ui.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?ba.transform(e):Wr.transform(e)};var eL=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function PP(e){var t,a;return isNaN(e)&&typeof e=="string"&&(((t=e.match(ts))===null||t===void 0?void 0:t.length)||0)+(((a=e.match(eL))===null||a===void 0?void 0:a.length)||0)>0}var aL="number",rL="color",TP="var",AP="var(",tL="${}",RP=/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(),a=[],r={color:[],number:[],var:[]},o=[],n=0,i=t.replace(RP,l=>(Ue.test(l)?(r.color.push(n),o.push(rL),a.push(Ue.parse(l))):l.startsWith(AP)?(r.var.push(n),o.push(TP),a.push(l)):(r.number.push(n),o.push(aL),a.push(parseFloat(l))),++n,tL)).split(tL);return{values:a,split:i,indexes:r,types:o}}function oL(e){return ko(e).values}function nL(e){let{split:t,types:a}=ko(e),r=t.length;return o=>{let n="";for(let s=0;s<r;s++)if(n+=t[s],o[s]!==void 0){let i=a[s];i===aL?n+=qr(o[s]):i===rL?n+=Ue.transform(o[s]):n+=o[s]}return n}}var DP=e=>typeof e=="number"?0:e;function MP(e){let t=oL(e);return nL(e)(t.map(DP))}var gt={test:PP,parse:oL,createTransformer:nL,getAnimatableNone:MP};var NP=new Set(["brightness","contrast","saturate","opacity"]);function EP(e){let[t,a]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;let[r]=a.match(ts)||[];if(!r)return e;let o=a.replace(r,""),n=NP.has(t)?1:0;return r!==a&&(n*=100),t+"("+n+o+")"}var FP=/\b([a-z-]*)\(.*?\)/gu,_i={...gt,getAnimatableNone:e=>{let t=e.match(FP);return t?t.map(EP).join(" "):e}};var BP={..._n,color:Ue,backgroundColor:Ue,outlineColor:Ue,fill:Ue,stroke:Ue,borderColor:Ue,borderTopColor:Ue,borderRightColor:Ue,borderBottomColor:Ue,borderLeftColor:Ue,filter:_i,WebkitFilter:_i},rs=e=>BP[e];function kd(e,t){let a=rs(e);return a!==_i&&(a=gt),a.getAnimatableNone?a.getAnimatableNone(t):void 0}var OP=new Set(["auto","none","0"]);function sL(e,t,a){let r=0,o;for(;r<e.length&&!o;){let n=e[r];typeof n=="string"&&!OP.has(n)&&ko(n).values.length&&(o=e[r]),r++}if(o&&a)for(let n of t)e[n]=kd(a,o)}var pm=e=>e===wa||e===H,iL=(e,t)=>parseFloat(e.split(", ")[t]),lL=(e,t)=>(a,{transform:r})=>{if(r==="none"||!r)return 0;let o=r.match(/^matrix3d\((.+)\)$/u);if(o)return iL(o[1],t);{let n=r.match(/^matrix\((.+)\)$/u);return n?iL(n[1],e):0}},VP=new Set(["x","y","z"]),UP=Ia.filter(e=>!VP.has(e));function uL(e){let t=[];return UP.forEach(a=>{let r=e.getValue(a);r!==void 0&&(t.push([a,r.get()]),r.set(a.startsWith("scale")?1:0))}),t}var bo={width:({x:e},{paddingLeft:t="0",paddingRight:a="0"})=>e.max-e.min-parseFloat(t)-parseFloat(a),height:({y:e},{paddingTop:t="0",paddingBottom:a="0"})=>e.max-e.min-parseFloat(t)-parseFloat(a),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:lL(4,13),y:lL(5,14)};bo.translateX=bo.x;bo.translateY=bo.y;var Po=new Set,mm=!1,hm=!1;function dL(){if(hm){let e=Array.from(Po).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),a=new Map;t.forEach(r=>{let o=uL(r);o.length&&(a.set(r,o),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();let o=a.get(r);o&&o.forEach(([n,s])=>{var i;(i=r.getValue(n))===null||i===void 0||i.set(s)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}hm=!1,mm=!1,Po.forEach(e=>e.complete()),Po.clear()}function cL(){Po.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(hm=!0)})}function fL(){cL(),dL()}var Gr=class{constructor(t,a,r,o,n,s=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...t],this.onComplete=a,this.name=r,this.motionValue=o,this.element=n,this.isAsync=s}scheduleResolve(){this.isScheduled=!0,this.isAsync?(Po.add(this),mm||(mm=!0,J.read(cL),J.resolveKeyframes(dL))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:t,name:a,element:r,motionValue:o}=this;for(let n=0;n<t.length;n++)if(t[n]===null)if(n===0){let s=o?.get(),i=t[t.length-1];if(s!==void 0)t[0]=s;else if(r&&a){let l=r.readValue(a,i);l!=null&&(t[0]=l)}t[0]===void 0&&(t[0]=i),o&&s===void 0&&o.set(t[0])}else t[n]=t[n-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),Po.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,Po.delete(this))}resume(){this.isComplete||this.scheduleResolve()}};var bd=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);var _P=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function zP(e){let t=_P.exec(e);if(!t)return[,];let[,a,r,o]=t;return[`--${a??r}`,o]}var HP=4;function gm(e,t,a=1){pa(a<=HP,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);let[r,o]=zP(e);if(!r)return;let n=window.getComputedStyle(t).getPropertyValue(r);if(n){let s=n.trim();return bd(s)?parseFloat(s):s}return Un(o)?gm(o,t,a+1):o}var Pd=e=>t=>t.test(e);var pL={test:e=>e==="auto",parse:e=>e};var xm=[wa,H,ht,ka,S0,C0,pL],ym=e=>xm.find(Pd(e));var os=class extends Gr{constructor(t,a,r,o,n){super(t,a,r,o,n,!0)}readKeyframes(){let{unresolvedKeyframes:t,element:a,name:r}=this;if(!a||!a.current)return;super.readKeyframes();for(let l=0;l<t.length;l++){let u=t[l];if(typeof u=="string"&&(u=u.trim(),Un(u))){let d=gm(u,a.current);d!==void 0&&(t[l]=d),l===t.length-1&&(this.finalKeyframe=u)}}if(this.resolveNoneKeyframes(),!cd.has(r)||t.length!==2)return;let[o,n]=t,s=ym(o),i=ym(n);if(s!==i)if(pm(s)&&pm(i))for(let l=0;l<t.length;l++){let u=t[l];typeof u=="string"&&(t[l]=parseFloat(u))}else this.needsMeasurement=!0}resolveNoneKeyframes(){let{unresolvedKeyframes:t,name:a}=this,r=[];for(let o=0;o<t.length;o++)Y0(t[o])&&r.push(o);r.length&&sL(t,r,a)}measureInitialState(){let{element:t,unresolvedKeyframes:a,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=bo[r](t.measureViewportBox(),window.getComputedStyle(t.current)),a[0]=this.measuredOrigin;let o=a[a.length-1];o!==void 0&&t.getValue(r,o).jump(o,!1)}measureEndState(){var t;let{element:a,name:r,unresolvedKeyframes:o}=this;if(!a||!a.current)return;let n=a.getValue(r);n&&n.jump(this.measuredOrigin,!1);let s=o.length-1,i=o[s];o[s]=bo[r](a.measureViewportBox(),window.getComputedStyle(a.current)),i!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=i),!((t=this.removedTransforms)===null||t===void 0)&&t.length&&this.removedTransforms.forEach(([l,u])=>{a.getValue(l).set(u)}),this.resolveNoneKeyframes()}};var vm=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(gt.test(e)||e==="0")&&!e.startsWith("url("));function qP(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 mL(e,t,a,r){let o=e[0];if(o===null)return!1;if(t==="display"||t==="visibility")return!0;let n=e[e.length-1],s=vm(o,t),i=vm(n,t);return Qa(s===i,`You are trying to animate ${t} from "${o}" to "${n}". ${o} is not an animatable value - to enable this animation set ${o} to a value animatable to ${n} via the \`style\` property.`),!s||!i?!1:qP(e)||(a==="spring"||Ur(a))&&r}var WP=e=>e!==null;function jr(e,{repeat:t,repeatType:a="loop"},r){let o=e.filter(WP),n=t&&a!=="loop"&&t%2===1?0:o.length-1;return!n||r===void 0?o[n]:r}var GP=40,ns=class{constructor({autoplay:t=!0,delay:a=0,type:r="keyframes",repeat:o=0,repeatDelay:n=0,repeatType:s="loop",...i}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=lt.now(),this.options={autoplay:t,delay:a,type:r,repeat:o,repeatDelay:n,repeatType:s,...i},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt?this.resolvedAt-this.createdAt>GP?this.resolvedAt:this.createdAt:this.createdAt}get resolved(){return!this._resolved&&!this.hasAttemptedResolve&&fL(),this._resolved}onKeyframesResolved(t,a){this.resolvedAt=lt.now(),this.hasAttemptedResolve=!0;let{name:r,type:o,velocity:n,delay:s,onComplete:i,onUpdate:l,isGenerator:u}=this.options;if(!u&&!mL(t,r,o,n))if(hd.current||!s){l&&l(jr(t,this.options,a)),i&&i(),this.resolveFinishedPromise();return}else this.options.duration=0;let d=this.initPlayback(t,a);d!==!1&&(this._resolved={keyframes:t,finalKeyframe:a,...d},this.onPostResolved())}onPostResolved(){}then(t,a){return this.currentFinishedPromise.then(t,a)}flatten(){this.options.type="keyframes",this.options.ease="linear"}updateFinishedPromise(){this.currentFinishedPromise=new Promise(t=>{this.resolveFinishedPromise=t})}};var ne=(e,t,a)=>e+(t-e)*a;function Lm(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 hL({hue:e,saturation:t,lightness:a,alpha:r}){e/=360,t/=100,a/=100;let o=0,n=0,s=0;if(!t)o=n=s=a;else{let i=a<.5?a*(1+t):a+t-a*t,l=2*a-i;o=Lm(l,i,e+1/3),n=Lm(l,i,e),s=Lm(l,i,e-1/3)}return{red:Math.round(o*255),green:Math.round(n*255),blue:Math.round(s*255),alpha:r}}function ss(e,t){return a=>a>0?t:e}var Cm=(e,t,a)=>{let r=e*e,o=a*(t*t-r)+r;return o<0?0:Math.sqrt(o)},jP=[Ui,ba,Wr],KP=e=>jP.find(t=>t.test(e));function gL(e){let t=KP(e);if(Qa(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`),!t)return!1;let a=t.parse(e);return t===Wr&&(a=hL(a)),a}var Sm=(e,t)=>{let a=gL(e),r=gL(t);if(!a||!r)return ss(e,t);let o={...a};return n=>(o.red=Cm(a.red,r.red,n),o.green=Cm(a.green,r.green,n),o.blue=Cm(a.blue,r.blue,n),o.alpha=ne(a.alpha,r.alpha,n),ba.transform(o))};var $P=(e,t)=>a=>t(e(a)),Pa=(...e)=>e.reduce($P);var Td=new Set(["none","hidden"]);function xL(e,t){return Td.has(e)?a=>a<=0?e:t:a=>a>=1?t:e}function XP(e,t){return a=>ne(e,t,a)}function Ad(e){return typeof e=="number"?XP:typeof e=="string"?Un(e)?ss:Ue.test(e)?Sm:ZP:Array.isArray(e)?yL:typeof e=="object"?Ue.test(e)?Sm:QP:ss}function yL(e,t){let a=[...e],r=a.length,o=e.map((n,s)=>Ad(n)(n,t[s]));return n=>{for(let s=0;s<r;s++)a[s]=o[s](n);return a}}function QP(e,t){let a={...e,...t},r={};for(let o in a)e[o]!==void 0&&t[o]!==void 0&&(r[o]=Ad(e[o])(e[o],t[o]));return o=>{for(let n in r)a[n]=r[n](o);return a}}function YP(e,t){var a;let r=[],o={color:0,var:0,number:0};for(let n=0;n<t.values.length;n++){let s=t.types[n],i=e.indexes[s][o[s]],l=(a=e.values[i])!==null&&a!==void 0?a:0;r[n]=l,o[s]++}return r}var ZP=(e,t)=>{let a=gt.createTransformer(t),r=ko(e),o=ko(t);return r.indexes.var.length===o.indexes.var.length&&r.indexes.color.length===o.indexes.color.length&&r.indexes.number.length>=o.indexes.number.length?Td.has(e)&&!o.values.length||Td.has(t)&&!r.values.length?xL(e,t):Pa(yL(YP(r,o),o.values),a):(Qa(!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.`),ss(e,t))};function Rd(e,t,a){return typeof e=="number"&&typeof t=="number"&&typeof a=="number"?ne(e,t,a):Ad(e)(e,t)}var JP=5;function Dd(e,t,a){let r=Math.max(t-JP,0);return pd(a-e(r),t-r)}var Se={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};var Im=.001;function vL({duration:e=Se.duration,bounce:t=Se.bounce,velocity:a=Se.velocity,mass:r=Se.mass}){let o,n;Qa(e<=Ee(Se.maxDuration),"Spring duration must be 10 seconds or less");let s=1-t;s=et(Se.minDamping,Se.maxDamping,s),e=et(Se.minDuration,Se.maxDuration,Je(e)),s<1?(o=u=>{let d=u*s,c=d*e,p=d-a,g=Md(u,s),C=Math.exp(-c);return Im-p/g*C},n=u=>{let c=u*s*e,p=c*a+a,g=Math.pow(s,2)*Math.pow(u,2)*e,C=Math.exp(-c),L=Md(Math.pow(u,2),s);return(-o(u)+Im>0?-1:1)*((p-g)*C)/L}):(o=u=>{let d=Math.exp(-u*e),c=(u-a)*e+1;return-Im+d*c},n=u=>{let d=Math.exp(-u*e),c=(a-u)*(e*e);return d*c});let i=5/e,l=t1(o,n,i);if(e=Ee(e),isNaN(l))return{stiffness:Se.stiffness,damping:Se.damping,duration:e};{let u=Math.pow(l,2)*r;return{stiffness:u,damping:s*2*Math.sqrt(r*u),duration:e}}}var e1=12;function t1(e,t,a){let r=a;for(let o=1;o<e1;o++)r=r-e(r)/t(r);return r}function Md(e,t){return e*Math.sqrt(1-t*t)}var a1=["duration","bounce"],r1=["stiffness","damping","mass"];function LL(e,t){return t.some(a=>e[a]!==void 0)}function o1(e){let t={velocity:Se.velocity,stiffness:Se.stiffness,damping:Se.damping,mass:Se.mass,isResolvedFromDuration:!1,...e};if(!LL(e,r1)&&LL(e,a1))if(e.visualDuration){let a=e.visualDuration,r=2*Math.PI/(a*1.2),o=r*r,n=2*et(.05,1,1-(e.bounce||0))*Math.sqrt(o);t={...t,mass:Se.mass,stiffness:o,damping:n}}else{let a=vL(e);t={...t,...a,mass:Se.mass},t.isResolvedFromDuration=!0}return t}function Nd(e=Se.visualDuration,t=Se.bounce){let a=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e,{restSpeed:r,restDelta:o}=a,n=a.keyframes[0],s=a.keyframes[a.keyframes.length-1],i={done:!1,value:n},{stiffness:l,damping:u,mass:d,duration:c,velocity:p,isResolvedFromDuration:g}=o1({...a,velocity:-Je(a.velocity||0)}),C=p||0,L=u/(2*Math.sqrt(l*d)),S=s-n,h=Je(Math.sqrt(l/d)),m=Math.abs(S)<5;r||(r=m?Se.restSpeed.granular:Se.restSpeed.default),o||(o=m?Se.restDelta.granular:Se.restDelta.default);let x;if(L<1){let k=Md(h,L);x=T=>{let R=Math.exp(-L*h*T);return s-R*((C+L*h*S)/k*Math.sin(k*T)+S*Math.cos(k*T))}}else if(L===1)x=k=>s-Math.exp(-h*k)*(S+(C+h*S)*k);else{let k=h*Math.sqrt(L*L-1);x=T=>{let R=Math.exp(-L*h*T),A=Math.min(k*T,300);return s-R*((C+L*h*S)*Math.sinh(A)+k*S*Math.cosh(A))/k}}let I={calculatedDuration:g&&c||null,next:k=>{let T=x(k);if(g)i.done=k>=c;else{let R=0;L<1&&(R=k===0?Ee(C):Dd(x,k,T));let A=Math.abs(R)<=r,V=Math.abs(s-T)<=o;i.done=A&&V}return i.value=i.done?s:T,i},toString:()=>{let k=Math.min($n(I),2e4),T=Bi(R=>I.next(k*R).value,k,30);return k+"ms "+T}};return I}function wm({keyframes:e,velocity:t=0,power:a=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:n=500,modifyTarget:s,min:i,max:l,restDelta:u=.5,restSpeed:d}){let c=e[0],p={done:!1,value:c},g=A=>i!==void 0&&A<i||l!==void 0&&A>l,C=A=>i===void 0?l:l===void 0||Math.abs(i-A)<Math.abs(l-A)?i:l,L=a*t,S=c+L,h=s===void 0?S:s(S);h!==S&&(L=h-c);let m=A=>-L*Math.exp(-A/r),x=A=>h+m(A),I=A=>{let V=m(A),U=x(A);p.done=Math.abs(V)<=u,p.value=p.done?h:U},k,T,R=A=>{g(p.value)&&(k=A,T=Nd({keyframes:[p.value,C(p.value)],velocity:Dd(x,A,p.value),damping:o,stiffness:n,restDelta:u,restSpeed:d}))};return R(0),{calculatedDuration:null,next:A=>{let V=!1;return!T&&k===void 0&&(V=!0,I(A),R(A)),k!==void 0&&A>=k?T.next(A-k):(!V&&I(A),p)}}}var CL=Hr(.42,0,1,1),SL=Hr(0,0,.58,1),Ed=Hr(.42,0,.58,1);var IL=e=>Array.isArray(e)&&typeof e[0]!="number";var wL={linear:he,easeIn:CL,easeInOut:Ed,easeOut:SL,circIn:Ld,circInOut:Sd,circOut:Cd,backIn:Vi,backInOut:yd,backOut:cm,anticipate:vd},km=e=>{if(Xn(e)){pa(e.length===4,"Cubic bezier arrays must contain four numerical values.");let[t,a,r,o]=e;return Hr(t,a,r,o)}else if(typeof e=="string")return pa(wL[e]!==void 0,`Invalid easing type '${e}'`),wL[e];return e};function n1(e,t,a){let r=[],o=a||Rd,n=e.length-1;for(let s=0;s<n;s++){let i=o(e[s],e[s+1]);if(t){let l=Array.isArray(t)?t[s]||he:t;i=Pa(l,i)}r.push(i)}return r}function kL(e,t,{clamp:a=!0,ease:r,mixer:o}={}){let n=e.length;if(pa(n===t.length,"Both input and output ranges must be the same 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=n1(t,r,o),l=i.length,u=d=>{if(s&&d<e[0])return t[0];let c=0;if(l>1)for(;c<e.length-2&&!(d<e[c+1]);c++);let p=Ut(e[c],e[c+1],d);return i[c](p)};return a?d=>u(et(e[0],e[n-1],d)):u}function bL(e,t){let a=e[e.length-1];for(let r=1;r<=t;r++){let o=Ut(0,t,r);e.push(ne(a,1,o))}}function PL(e){let t=[0];return bL(t,e.length-1),t}function TL(e,t){return e.map(a=>a*t)}function s1(e,t){return e.map(()=>t||Ed).splice(0,e.length-1)}function zi({duration:e=300,keyframes:t,times:a,ease:r="easeInOut"}){let o=IL(r)?r.map(km):km(r),n={done:!1,value:t[0]},s=TL(a&&a.length===t.length?a:PL(t),e),i=kL(s,t,{ease:Array.isArray(o)?o:s1(t,o)});return{calculatedDuration:e,next:l=>(n.value=i(l),n.done=l>=e,n)}}var AL=e=>{let t=({timestamp:a})=>e(a);return{start:()=>J.update(t,!0),stop:()=>_t(t),now:()=>Fe.isProcessing?Fe.timestamp:lt.now()}};var i1={decay:wm,inertia:wm,tween:zi,keyframes:zi,spring:Nd},l1=e=>e/100,To=class extends ns{constructor(t){super(t),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.teardown();let{onStop:l}=this.options;l&&l()};let{name:a,motionValue:r,element:o,keyframes:n}=this.options,s=o?.KeyframeResolver||Gr,i=(l,u)=>this.onKeyframesResolved(l,u);this.resolver=new s(n,i,a,r,o),this.resolver.scheduleResolve()}flatten(){super.flatten(),this._resolved&&Object.assign(this._resolved,this.initPlayback(this._resolved.keyframes))}initPlayback(t){let{type:a="keyframes",repeat:r=0,repeatDelay:o=0,repeatType:n,velocity:s=0}=this.options,i=Ur(a)?a:i1[a]||zi,l,u;i!==zi&&typeof t[0]!="number"&&(l=Pa(l1,Rd(t[0],t[1])),t=[0,100]);let d=i({...this.options,keyframes:t});n==="mirror"&&(u=i({...this.options,keyframes:[...t].reverse(),velocity:-s})),d.calculatedDuration===null&&(d.calculatedDuration=$n(d));let{calculatedDuration:c}=d,p=c+o,g=p*(r+1)-o;return{generator:d,mirroredGenerator:u,mapPercentToKeyframes:l,calculatedDuration:c,resolvedDuration:p,totalDuration:g}}onPostResolved(){let{autoplay:t=!0}=this.options;this.play(),this.pendingPlayState==="paused"||!t?this.pause():this.state=this.pendingPlayState}tick(t,a=!1){let{resolved:r}=this;if(!r){let{keyframes:A}=this.options;return{done:!0,value:A[A.length-1]}}let{finalKeyframe:o,generator:n,mirroredGenerator:s,mapPercentToKeyframes:i,keyframes:l,calculatedDuration:u,totalDuration:d,resolvedDuration:c}=r;if(this.startTime===null)return n.next(0);let{delay:p,repeat:g,repeatType:C,repeatDelay:L,onUpdate:S}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-d/this.speed,this.startTime)),a?this.currentTime=t:this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=Math.round(t-this.startTime)*this.speed;let h=this.currentTime-p*(this.speed>=0?1:-1),m=this.speed>=0?h<0:h>d;this.currentTime=Math.max(h,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=d);let x=this.currentTime,I=n;if(g){let A=Math.min(this.currentTime,d)/c,V=Math.floor(A),U=A%1;!U&&A>=1&&(U=1),U===1&&V--,V=Math.min(V,g+1),V%2&&(C==="reverse"?(U=1-U,L&&(U-=L/c)):C==="mirror"&&(I=s)),x=et(0,1,U)*c}let k=m?{done:!1,value:l[0]}:I.next(x);i&&(k.value=i(k.value));let{done:T}=k;!m&&u!==null&&(T=this.speed>=0?this.currentTime>=d:this.currentTime<=0);let R=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&T);return R&&o!==void 0&&(k.value=jr(l,this.options,o)),S&&S(k.value),R&&this.finish(),k}get duration(){let{resolved:t}=this;return t?Je(t.calculatedDuration):0}get time(){return Je(this.currentTime)}set time(t){t=Ee(t),this.currentTime=t,this.holdTime!==null||this.speed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.speed)}get speed(){return this.playbackSpeed}set speed(t){let a=this.playbackSpeed!==t;this.playbackSpeed=t,a&&(this.time=Je(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;let{driver:t=AL,onPlay:a,startTime:r}=this.options;this.driver||(this.driver=t(n=>this.tick(n))),a&&a();let o=this.driver.now();this.holdTime!==null?this.startTime=o-this.holdTime:this.startTime?this.state==="finished"&&(this.startTime=o):this.startTime=r??this.calcStartTime(),this.state==="finished"&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var t;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=(t=this.currentTime)!==null&&t!==void 0?t:0}complete(){this.state!=="running"&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";let{onComplete:t}=this.options;t&&t()}cancel(){this.cancelTime!==null&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}};var RL=new Set(["opacity","clipPath","filter","transform"]);function DL(e,t,a,{delay:r=0,duration:o=300,repeat:n=0,repeatType:s="loop",ease:i="easeInOut",times:l}={}){let u={[t]:a};l&&(u.offset=l);let d=Yn(i,o);return Array.isArray(d)&&(u.easing=d),e.animate(u,{delay:r,duration:o,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:n+1,direction:s==="reverse"?"alternate":"normal"})}var ML=Co(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));var Fd=10,u1=2e4;function d1(e){return Ur(e.type)||e.type==="spring"||!ld(e.ease)}function c1(e,t){let a=new To({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0}),r={done:!1,value:e[0]},o=[],n=0;for(;!r.done&&n<u1;)r=a.sample(n),o.push(r.value),n+=Fd;return{times:void 0,keyframes:o,duration:n-Fd,ease:"linear"}}var NL={anticipate:vd,backInOut:yd,circInOut:Sd};function f1(e){return e in NL}var Hi=class extends ns{constructor(t){super(t);let{name:a,motionValue:r,element:o,keyframes:n}=this.options;this.resolver=new os(n,(s,i)=>this.onKeyframesResolved(s,i),a,r,o),this.resolver.scheduleResolve()}initPlayback(t,a){let{duration:r=300,times:o,ease:n,type:s,motionValue:i,name:l,startTime:u}=this.options;if(!i.owner||!i.owner.current)return!1;if(typeof n=="string"&&_r()&&f1(n)&&(n=NL[n]),d1(this.options)){let{onComplete:c,onUpdate:p,motionValue:g,element:C,...L}=this.options,S=c1(t,L);t=S.keyframes,t.length===1&&(t[1]=t[0]),r=S.duration,o=S.times,n=S.ease,s="keyframes"}let d=DL(i.owner.current,l,t,{...this.options,duration:r,times:o,ease:n});return d.startTime=u??this.calcStartTime(),this.pendingTimeline?(Fi(d,this.pendingTimeline),this.pendingTimeline=void 0):d.onfinish=()=>{let{onComplete:c}=this.options;i.set(jr(t,this.options,a)),c&&c(),this.cancel(),this.resolveFinishedPromise()},{animation:d,duration:r,times:o,type:s,ease:n,keyframes:t}}get duration(){let{resolved:t}=this;if(!t)return 0;let{duration:a}=t;return Je(a)}get time(){let{resolved:t}=this;if(!t)return 0;let{animation:a}=t;return Je(a.currentTime||0)}set time(t){let{resolved:a}=this;if(!a)return;let{animation:r}=a;r.currentTime=Ee(t)}get speed(){let{resolved:t}=this;if(!t)return 1;let{animation:a}=t;return a.playbackRate}set speed(t){let{resolved:a}=this;if(!a)return;let{animation:r}=a;r.playbackRate=t}get state(){let{resolved:t}=this;if(!t)return"idle";let{animation:a}=t;return a.playState}get startTime(){let{resolved:t}=this;if(!t)return null;let{animation:a}=t;return a.startTime}attachTimeline(t){if(!this._resolved)this.pendingTimeline=t;else{let{resolved:a}=this;if(!a)return he;let{animation:r}=a;Fi(r,t)}return he}play(){if(this.isStopped)return;let{resolved:t}=this;if(!t)return;let{animation:a}=t;a.playState==="finished"&&this.updateFinishedPromise(),a.play()}pause(){let{resolved:t}=this;if(!t)return;let{animation:a}=t;a.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.resolveFinishedPromise(),this.updateFinishedPromise();let{resolved:t}=this;if(!t)return;let{animation:a,keyframes:r,duration:o,type:n,ease:s,times:i}=t;if(a.playState==="idle"||a.playState==="finished")return;if(this.time){let{motionValue:u,onUpdate:d,onComplete:c,element:p,...g}=this.options,C=new To({...g,keyframes:r,duration:o,type:n,ease:s,times:i,isGenerator:!0}),L=Ee(this.time);u.setWithVelocity(C.sample(L-Fd).value,C.sample(L).value,Fd)}let{onStop:l}=this.options;l&&l(),this.cancel()}complete(){let{resolved:t}=this;t&&t.animation.finish()}cancel(){let{resolved:t}=this;t&&t.animation.cancel()}static supports(t){let{motionValue:a,name:r,repeatDelay:o,repeatType:n,damping:s,type:i}=t;if(!a||!a.owner||!(a.owner.current instanceof HTMLElement))return!1;let{onUpdate:l,transformTemplate:u}=a.owner.getProps();return ML()&&r&&RL.has(r)&&!l&&!u&&!o&&n!=="mirror"&&s!==0&&i!=="inertia"}};var p1={type:"spring",stiffness:500,damping:25,restSpeed:10},m1=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),h1={type:"keyframes",duration:.8},g1={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},EL=(e,{keyframes:t})=>t.length>2?h1:Pt.has(e)?e.startsWith("scale")?m1(t[1]):p1:g1;function FL({when:e,delay:t,delayChildren:a,staggerChildren:r,staggerDirection:o,repeat:n,repeatType:s,repeatDelay:i,from:l,elapsed:u,...d}){return!!Object.keys(d).length}var is=(e,t,a,r={},o,n)=>s=>{let i=Vr(r,e)||{},l=i.delay||r.delay||0,{elapsed:u=0}=r;u=u-Ee(l);let d={keyframes:Array.isArray(a)?a:[null,a],ease:"easeOut",velocity:t.getVelocity(),...i,delay:-u,onUpdate:p=>{t.set(p),i.onUpdate&&i.onUpdate(p)},onComplete:()=>{s(),i.onComplete&&i.onComplete()},name:e,motionValue:t,element:n?void 0:o};FL(i)||(d={...d,...EL(e,d)}),d.duration&&(d.duration=Ee(d.duration)),d.repeatDelay&&(d.repeatDelay=Ee(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let c=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(d.duration=0,d.delay===0&&(c=!0)),(hd.current||Mn.skipAnimations)&&(c=!0,d.duration=0,d.delay=0),c&&!n&&t.get()!==void 0){let p=jr(d.keyframes,i);if(p!==void 0)return J.update(()=>{d.onUpdate(p),d.onComplete()}),new Ei([])}return!n&&Hi.supports(d)?new Hi(d):new To(d)};function x1({protectedKeys:e,needsAnimating:t},a){let r=e.hasOwnProperty(a)&&t[a]!==!0;return t[a]=!1,r}function Bd(e,t,{delay:a=0,transitionOverride:r,type:o}={}){var n;let{transition:s=e.getDefaultTransition(),transitionEnd:i,...l}=t;r&&(s=r);let u=[],d=o&&e.animationState&&e.animationState.getState()[o];for(let c in l){let p=e.getValue(c,(n=e.latestValues[c])!==null&&n!==void 0?n:null),g=l[c];if(g===void 0||d&&x1(d,c))continue;let C={delay:a,...Vr(s||{},c)},L=!1;if(window.MotionHandoffAnimation){let h=md(e);if(h){let m=window.MotionHandoffAnimation(h,c,J);m!==null&&(C.startTime=m,L=!0)}}Oi(e,c),p.start(is(c,p,g,e.shouldReduceMotion&&cd.has(c)?{type:!1}:C,e,L));let S=p.animation;S&&u.push(S)}return i&&Promise.all(u).then(()=>{J.update(()=>{i&&$0(e,i)})}),u}function Od(e,t,a={}){var r;let o=Or(e,t,a.type==="exit"?(r=e.presenceContext)===null||r===void 0?void 0:r.custom:void 0),{transition:n=e.getDefaultTransition()||{}}=o||{};a.transitionOverride&&(n=a.transitionOverride);let s=o?()=>Promise.all(Bd(e,o,a)):()=>Promise.resolve(),i=e.variantChildren&&e.variantChildren.size?(u=0)=>{let{delayChildren:d=0,staggerChildren:c,staggerDirection:p}=n;return y1(e,t,d+u,c,p,a)}:()=>Promise.resolve(),{when:l}=n;if(l){let[u,d]=l==="beforeChildren"?[s,i]:[i,s];return u().then(()=>d())}else return Promise.all([s(),i(a.delay)])}function y1(e,t,a=0,r=0,o=1,n){let s=[],i=(e.variantChildren.size-1)*r,l=o===1?(u=0)=>u*r:(u=0)=>i-u*r;return Array.from(e.variantChildren).sort(v1).forEach((u,d)=>{u.notify("AnimationStart",t),s.push(Od(u,t,{...n,delay:a+l(d)}).then(()=>u.notify("AnimationComplete",t)))}),Promise.all(s)}function v1(e,t){return e.sortNodePosition(t)}function BL(e,t,a={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){let o=t.map(n=>Od(e,n,a));r=Promise.all(o)}else if(typeof t=="string")r=Od(e,t,a);else{let o=typeof t=="function"?Or(e,t,a.custom):t;r=Promise.all(Bd(e,o,a))}return r.then(()=>{e.notify("AnimationComplete",t)})}var L1=Ai.length;function bm(e){if(!e)return;if(!e.isControllingVariants){let a=e.parent?bm(e.parent)||{}:{};return e.props.initial!==void 0&&(a.initial=e.props.initial),a}let t={};for(let a=0;a<L1;a++){let r=Ai[a],o=e.props[r];(Za(o)||o===!1)&&(t[r]=o)}return t}var C1=[...ju].reverse(),S1=ju.length;function I1(e){return t=>Promise.all(t.map(({animation:a,options:r})=>BL(e,a,r)))}function VL(e){let t=I1(e),a=OL(),r=!0,o=l=>(u,d)=>{var c;let p=Or(e,d,l==="exit"?(c=e.presenceContext)===null||c===void 0?void 0:c.custom:void 0);if(p){let{transition:g,transitionEnd:C,...L}=p;u={...u,...L,...C}}return u};function n(l){t=l(e)}function s(l){let{props:u}=e,d=bm(e.parent)||{},c=[],p=new Set,g={},C=1/0;for(let S=0;S<S1;S++){let h=C1[S],m=a[h],x=u[h]!==void 0?u[h]:d[h],I=Za(x),k=h===l?m.isActive:null;k===!1&&(C=S);let T=x===d[h]&&x!==u[h]&&I;if(T&&r&&e.manuallyAnimateOnMount&&(T=!1),m.protectedKeys={...g},!m.isActive&&k===null||!x&&!m.prevProp||Br(x)||typeof x=="boolean")continue;let R=w1(m.prevProp,x),A=R||h===l&&m.isActive&&!T&&I||S>C&&I,V=!1,U=Array.isArray(x)?x:[x],se=U.reduce(o(h),{});k===!1&&(se={});let{prevResolvedValues:q={}}=m,No={...q,...se},ie=Ae=>{A=!0,p.has(Ae)&&(V=!0,p.delete(Ae)),m.needsAnimating[Ae]=!0;let Be=e.getValue(Ae);Be&&(Be.liveStyle=!1)};for(let Ae in No){let Be=se[Ae],Gt=q[Ae];if(g.hasOwnProperty(Ae))continue;let Rt=!1;Ri(Be)&&Ri(Gt)?Rt=!tm(Be,Gt):Rt=Be!==Gt,Rt?Be!=null?ie(Ae):p.add(Ae):Be!==void 0&&p.has(Ae)?ie(Ae):m.protectedKeys[Ae]=!0}m.prevProp=x,m.prevResolvedValues=se,m.isActive&&(g={...g,...se}),r&&e.blockInitialAnimation&&(A=!1),A&&(!(T&&R)||V)&&c.push(...U.map(Ae=>({animation:Ae,options:{type:h}})))}if(p.size){let S={};p.forEach(h=>{let m=e.getBaseTarget(h),x=e.getValue(h);x&&(x.liveStyle=!0),S[h]=m??null}),c.push({animation:S})}let L=!!c.length;return r&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(L=!1),r=!1,L?t(c):Promise.resolve()}function i(l,u){var d;if(a[l].isActive===u)return Promise.resolve();(d=e.variantChildren)===null||d===void 0||d.forEach(p=>{var g;return(g=p.animationState)===null||g===void 0?void 0:g.setActive(l,u)}),a[l].isActive=u;let c=s(l);for(let p in a)a[p].protectedKeys={};return c}return{animateChanges:s,setActive:i,setAnimateFunction:n,getState:()=>a,reset:()=>{a=OL(),r=!0}}}function w1(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!tm(t,e):!1}function Ao(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function OL(){return{animate:Ao(!0),whileInView:Ao(),whileHover:Ao(),whileTap:Ao(),whileDrag:Ao(),whileFocus:Ao(),exit:Ao()}}var Xe=class{constructor(t){this.isMounted=!1,this.node=t}update(){}};var Vd=class extends Xe{constructor(t){super(t),t.animationState||(t.animationState=VL(t))}updateAnimationControlsSubscription(){let{animate:t}=this.node.getProps();Br(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(){var t;this.node.animationState.reset(),(t=this.unmountControls)===null||t===void 0||t.call(this)}};var k1=0,Ud=class extends Xe{constructor(){super(...arguments),this.id=k1++}update(){if(!this.node.presenceContext)return;let{isPresent:t,onExitComplete:a}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;let o=this.node.animationState.setActive("exit",!t);a&&!t&&o.then(()=>a(this.id))}mount(){let{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}};var UL={animation:{Feature:Vd},exit:{Feature:Ud}};function ar(e,t,a,r={passive:!0}){return e.addEventListener(t,a,r),()=>e.removeEventListener(t,a)}function rr(e){return{point:{x:e.pageX,y:e.pageY}}}var _L=e=>t=>Io(t)&&e(t,rr(t));function Kr(e,t,a,r){return ar(e,t,_L(a),r)}var zL=(e,t)=>Math.abs(e-t);function HL(e,t){let a=zL(e.x,t.x),r=zL(e.y,t.y);return Math.sqrt(a**2+r**2)}var ls=class{constructor(t,a,{transformPagePoint:r,contextWindow:o,dragSnapToOrigin:n=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let c=Tm(this.lastMoveEventInfo,this.history),p=this.startEvent!==null,g=HL(c.offset,{x:0,y:0})>=3;if(!p&&!g)return;let{point:C}=c,{timestamp:L}=Fe;this.history.push({...C,timestamp:L});let{onStart:S,onMove:h}=this.handlers;p||(S&&S(this.lastMoveEvent,c),this.startEvent=this.lastMoveEvent),h&&h(this.lastMoveEvent,c)},this.handlePointerMove=(c,p)=>{this.lastMoveEvent=c,this.lastMoveEventInfo=Pm(p,this.transformPagePoint),J.update(this.updatePoint,!0)},this.handlePointerUp=(c,p)=>{this.end();let{onEnd:g,onSessionEnd:C,resumeAnimation:L}=this.handlers;if(this.dragSnapToOrigin&&L&&L(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let S=Tm(c.type==="pointercancel"?this.lastMoveEventInfo:Pm(p,this.transformPagePoint),this.history);this.startEvent&&g&&g(c,S),C&&C(c,S)},!Io(t))return;this.dragSnapToOrigin=n,this.handlers=a,this.transformPagePoint=r,this.contextWindow=o||window;let s=rr(t),i=Pm(s,this.transformPagePoint),{point:l}=i,{timestamp:u}=Fe;this.history=[{...l,timestamp:u}];let{onSessionStart:d}=a;d&&d(t,Tm(i,this.history)),this.removeListeners=Pa(Kr(this.contextWindow,"pointermove",this.handlePointerMove),Kr(this.contextWindow,"pointerup",this.handlePointerUp),Kr(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),_t(this.updatePoint)}};function Pm(e,t){return t?{point:t(e.point)}:e}function qL(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Tm({point:e},t){return{point:e,delta:qL(e,WL(t)),offset:qL(e,b1(t)),velocity:P1(t,.1)}}function b1(e){return e[0]}function WL(e){return e[e.length-1]}function P1(e,t){if(e.length<2)return{x:0,y:0};let a=e.length-1,r=null,o=WL(e);for(;a>=0&&(r=e[a],!(o.timestamp-r.timestamp>Ee(t)));)a--;if(!r)return{x:0,y:0};let n=Je(o.timestamp-r.timestamp);if(n===0)return{x:0,y:0};let s={x:(o.x-r.x)/n,y:(o.y-r.y)/n};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}var $L=1e-4,T1=1-$L,A1=1+$L,XL=.01,R1=0-XL,D1=0+XL;function tt(e){return e.max-e.min}function QL(e,t,a){return Math.abs(e-t)<=a}function GL(e,t,a,r=.5){e.origin=r,e.originPoint=ne(t.min,t.max,e.origin),e.scale=tt(a)/tt(t),e.translate=ne(a.min,a.max,e.origin)-e.originPoint,(e.scale>=T1&&e.scale<=A1||isNaN(e.scale))&&(e.scale=1),(e.translate>=R1&&e.translate<=D1||isNaN(e.translate))&&(e.translate=0)}function us(e,t,a,r){GL(e.x,t.x,a.x,r?r.originX:void 0),GL(e.y,t.y,a.y,r?r.originY:void 0)}function jL(e,t,a){e.min=a.min+t.min,e.max=e.min+tt(t)}function YL(e,t,a){jL(e.x,t.x,a.x),jL(e.y,t.y,a.y)}function KL(e,t,a){e.min=t.min-a.min,e.max=e.min+tt(t)}function ds(e,t,a){KL(e.x,t.x,a.x),KL(e.y,t.y,a.y)}function aC(e,{min:t,max:a},r){return t!==void 0&&e<t?e=r?ne(t,e,r.min):Math.max(e,t):a!==void 0&&e>a&&(e=r?ne(a,e,r.max):Math.min(e,a)),e}function ZL(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 rC(e,{top:t,left:a,bottom:r,right:o}){return{x:ZL(e.x,a,o),y:ZL(e.y,t,r)}}function JL(e,t){let a=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([a,r]=[r,a]),{min:a,max:r}}function oC(e,t){return{x:JL(e.x,t.x),y:JL(e.y,t.y)}}function nC(e,t){let a=.5,r=tt(e),o=tt(t);return o>r?a=Ut(t.min,t.max-r,e.min):r>o&&(a=Ut(e.min,e.max-o,t.min)),et(0,1,a)}function sC(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 _d=.35;function iC(e=_d){return e===!1?e=0:e===!0&&(e=_d),{x:eC(e,"left","right"),y:eC(e,"top","bottom")}}function eC(e,t,a){return{min:tC(e,t),max:tC(e,a)}}function tC(e,t){return typeof e=="number"?e:e[t]||0}var lC=()=>({translate:0,scale:1,origin:0,originPoint:0}),Ro=()=>({x:lC(),y:lC()}),uC=()=>({min:0,max:0}),Ie=()=>({x:uC(),y:uC()});function Tt(e){return[e("x"),e("y")]}function zd({top:e,left:t,right:a,bottom:r}){return{x:{min:t,max:a},y:{min:e,max:r}}}function dC({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function cC(e,t){if(!t)return e;let a=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:a.y,left:a.x,bottom:r.y,right:r.x}}function Am(e){return e===void 0||e===1}function Hd({scale:e,scaleX:t,scaleY:a}){return!Am(e)||!Am(t)||!Am(a)}function or(e){return Hd(e)||Rm(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function Rm(e){return fC(e.x)||fC(e.y)}function fC(e){return e&&e!=="0%"}function qi(e,t,a){let r=e-a,o=t*r;return a+o}function pC(e,t,a,r,o){return o!==void 0&&(e=qi(e,o,r)),qi(e,a,r)+t}function Dm(e,t=0,a=1,r,o){e.min=pC(e.min,t,a,r,o),e.max=pC(e.max,t,a,r,o)}function Mm(e,{x:t,y:a}){Dm(e.x,t.translate,t.scale,t.originPoint),Dm(e.y,a.translate,a.scale,a.originPoint)}var mC=.999999999999,hC=1.0000000000001;function xC(e,t,a,r=!1){let o=a.length;if(!o)return;t.x=t.y=1;let n,s;for(let i=0;i<o;i++){n=a[i],s=n.projectionDelta;let{visualElement:l}=n.options;l&&l.props.style&&l.props.style.display==="contents"||(r&&n.options.layoutScroll&&n.scroll&&n!==n.root&&Do(e,{x:-n.scroll.offset.x,y:-n.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,Mm(e,s)),r&&or(n.latestValues)&&Do(e,n.latestValues))}t.x<hC&&t.x>mC&&(t.x=1),t.y<hC&&t.y>mC&&(t.y=1)}function $r(e,t){e.min=e.min+t,e.max=e.max+t}function gC(e,t,a,r,o=.5){let n=ne(e.min,e.max,o);Dm(e,t,a,n,r)}function Do(e,t){gC(e.x,t.x,t.scaleX,t.scale,t.originX),gC(e.y,t.y,t.scaleY,t.scale,t.originY)}function Nm(e,t){return zd(cC(e.getBoundingClientRect(),t))}function yC(e,t,a){let r=Nm(e,a),{scroll:o}=t;return o&&($r(r.x,o.offset.x),$r(r.y,o.offset.y)),r}var qd=({current:e})=>e?e.ownerDocument.defaultView:null;var M1=new WeakMap,Gd=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=Ie(),this.visualElement=t}start(t,{snapToCursor:a=!1}={}){let{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;let o=d=>{let{dragSnapToOrigin:c}=this.getProps();c?this.pauseAnimation():this.stopAnimation(),a&&this.snapToCursor(rr(d).point)},n=(d,c)=>{let{drag:p,dragPropagation:g,onDragStart:C}=this.getProps();if(p&&!g&&(this.openDragLock&&this.openDragLock(),this.openDragLock=um(p),!this.openDragLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Tt(S=>{let h=this.getAxisMotionValue(S).get()||0;if(ht.test(h)){let{projection:m}=this.visualElement;if(m&&m.layout){let x=m.layout.layoutBox[S];x&&(h=tt(x)*(parseFloat(h)/100))}}this.originPoint[S]=h}),C&&J.postRender(()=>C(d,c)),Oi(this.visualElement,"transform");let{animationState:L}=this.visualElement;L&&L.setActive("whileDrag",!0)},s=(d,c)=>{let{dragPropagation:p,dragDirectionLock:g,onDirectionLock:C,onDrag:L}=this.getProps();if(!p&&!this.openDragLock)return;let{offset:S}=c;if(g&&this.currentDirection===null){this.currentDirection=N1(S),this.currentDirection!==null&&C&&C(this.currentDirection);return}this.updateAxis("x",c.point,S),this.updateAxis("y",c.point,S),this.visualElement.render(),L&&L(d,c)},i=(d,c)=>this.stop(d,c),l=()=>Tt(d=>{var c;return this.getAnimationState(d)==="paused"&&((c=this.getAxisMotionValue(d).animation)===null||c===void 0?void 0:c.play())}),{dragSnapToOrigin:u}=this.getProps();this.panSession=new ls(t,{onSessionStart:o,onStart:n,onMove:s,onSessionEnd:i,resumeAnimation:l},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,contextWindow:qd(this.visualElement)})}stop(t,a){let r=this.isDragging;if(this.cancel(),!r)return;let{velocity:o}=a;this.startAnimation(o);let{onDragEnd:n}=this.getProps();n&&J.postRender(()=>n(t,a))}cancel(){this.isDragging=!1;let{projection:t,animationState:a}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;let{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),a&&a.setActive("whileDrag",!1)}updateAxis(t,a,r){let{drag:o}=this.getProps();if(!r||!Wd(t,o,this.currentDirection))return;let n=this.getAxisMotionValue(t),s=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(s=aC(s,this.constraints[t],this.elastic[t])),n.set(s)}resolveConstraints(){var t;let{dragConstraints:a,dragElastic:r}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(t=this.visualElement.projection)===null||t===void 0?void 0:t.layout,n=this.constraints;a&&Ja(a)?this.constraints||(this.constraints=this.resolveRefConstraints()):a&&o?this.constraints=rC(o.layoutBox,a):this.constraints=!1,this.elastic=iC(r),n!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&Tt(s=>{this.constraints!==!1&&this.getAxisMotionValue(s)&&(this.constraints[s]=sC(o.layoutBox[s],this.constraints[s]))})}resolveRefConstraints(){let{dragConstraints:t,onMeasureDragConstraints:a}=this.getProps();if(!t||!Ja(t))return!1;let r=t.current;pa(r!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");let{projection:o}=this.visualElement;if(!o||!o.layout)return!1;let n=yC(r,o.root,this.visualElement.getTransformPagePoint()),s=oC(o.layout.layoutBox,n);if(a){let i=a(dC(s));this.hasMutatedConstraints=!!i,i&&(s=zd(i))}return s}startAnimation(t){let{drag:a,dragMomentum:r,dragElastic:o,dragTransition:n,dragSnapToOrigin:s,onDragTransitionEnd:i}=this.getProps(),l=this.constraints||{},u=Tt(d=>{if(!Wd(d,a,this.currentDirection))return;let c=l&&l[d]||{};s&&(c={min:0,max:0});let p=o?200:1e6,g=o?40:1e7,C={type:"inertia",velocity:r?t[d]:0,bounceStiffness:p,bounceDamping:g,timeConstant:750,restDelta:1,restSpeed:10,...n,...c};return this.startAxisValueAnimation(d,C)});return Promise.all(u).then(i)}startAxisValueAnimation(t,a){let r=this.getAxisMotionValue(t);return Oi(this.visualElement,t),r.start(is(t,r,0,a,this.visualElement,!1))}stopAnimation(){Tt(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Tt(t=>{var a;return(a=this.getAxisMotionValue(t).animation)===null||a===void 0?void 0:a.pause()})}getAnimationState(t){var a;return(a=this.getAxisMotionValue(t).animation)===null||a===void 0?void 0:a.state}getAxisMotionValue(t){let a=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),o=r[a];return o||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Tt(a=>{let{drag:r}=this.getProps();if(!Wd(a,r,this.currentDirection))return;let{projection:o}=this.visualElement,n=this.getAxisMotionValue(a);if(o&&o.layout){let{min:s,max:i}=o.layout.layoutBox[a];n.set(t[a]-ne(s,i,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:t,dragConstraints:a}=this.getProps(),{projection:r}=this.visualElement;if(!Ja(a)||!r||!this.constraints)return;this.stopAnimation();let o={x:0,y:0};Tt(s=>{let i=this.getAxisMotionValue(s);if(i&&this.constraints!==!1){let l=i.get();o[s]=nC({min:l,max:l},this.constraints[s])}});let{transformTemplate:n}=this.visualElement.getProps();this.visualElement.current.style.transform=n?n({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Tt(s=>{if(!Wd(s,t,null))return;let i=this.getAxisMotionValue(s),{min:l,max:u}=this.constraints[s];i.set(ne(l,u,o[s]))})}addListeners(){if(!this.visualElement.current)return;M1.set(this.visualElement,this);let t=this.visualElement.current,a=Kr(t,"pointerdown",l=>{let{drag:u,dragListener:d=!0}=this.getProps();u&&d&&this.start(l)}),r=()=>{let{dragConstraints:l}=this.getProps();Ja(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:o}=this.visualElement,n=o.addEventListener("measure",r);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),J.read(r);let s=ar(window,"resize",()=>this.scalePositionWithinConstraints()),i=o.addEventListener("didUpdate",(({delta:l,hasLayoutChanged:u})=>{this.isDragging&&u&&(Tt(d=>{let c=this.getAxisMotionValue(d);c&&(this.originPoint[d]+=l[d].translate,c.set(c.get()+l[d].translate))}),this.visualElement.render())}));return()=>{s(),a(),n(),i&&i()}}getProps(){let t=this.visualElement.getProps(),{drag:a=!1,dragDirectionLock:r=!1,dragPropagation:o=!1,dragConstraints:n=!1,dragElastic:s=_d,dragMomentum:i=!0}=t;return{...t,drag:a,dragDirectionLock:r,dragPropagation:o,dragConstraints:n,dragElastic:s,dragMomentum:i}}};function Wd(e,t,a){return(t===!0||t===e)&&(a===null||a===e)}function N1(e,t=10){let a=null;return Math.abs(e.y)>t?a="y":Math.abs(e.x)>t&&(a="x"),a}var jd=class extends Xe{constructor(t){super(t),this.removeGroupControls=he,this.removeListeners=he,this.controls=new Gd(t)}mount(){let{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||he}unmount(){this.removeGroupControls(),this.removeListeners()}};var vC=e=>(t,a)=>{e&&J.postRender(()=>e(t,a))},Kd=class extends Xe{constructor(){super(...arguments),this.removePointerDownListener=he}onPointerDown(t){this.session=new ls(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:qd(this.node)})}createPanHandlers(){let{onPanSessionStart:t,onPanStart:a,onPan:r,onPanEnd:o}=this.node.getProps();return{onSessionStart:vC(t),onStart:vC(a),onMove:r,onEnd:(n,s)=>{delete this.session,o&&J.postRender(()=>o(n,s))}}}mount(){this.removePointerDownListener=Kr(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 SC=E(ue(),1),Wi=E(X(),1);var cs={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function LC(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}var fs={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(H.test(e))e=parseFloat(e);else return e;let a=LC(e,t.target.x),r=LC(e,t.target.y);return`${a}% ${r}%`}};var CC={correct:(e,{treeScale:t,projectionDelta:a})=>{let r=e,o=gt.parse(e);if(o.length>5)return r;let n=gt.createTransformer(e),s=typeof o[0]!="number"?1:0,i=a.x.scale*t.x,l=a.y.scale*t.y;o[0+s]/=i,o[1+s]/=l;let u=ne(i,l,.5);return typeof o[2+s]=="number"&&(o[2+s]/=u),typeof o[3+s]=="number"&&(o[3+s]/=u),n(o)}};var Em=class extends Wi.Component{componentDidMount(){let{visualElement:t,layoutGroup:a,switchLayoutGroup:r,layoutId:o}=this.props,{projection:n}=t;A0(E1),n&&(a.group&&a.group.add(n),r&&r.register&&o&&r.register(n),n.root.didUpdate(),n.addEventListener("animationComplete",()=>{this.safeToRemove()}),n.setOptions({...n.options,onExitComplete:()=>this.safeToRemove()})),cs.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){let{layoutDependency:a,visualElement:r,drag:o,isPresent:n}=this.props,s=r.projection;return s&&(s.isPresent=n,o||t.layoutDependency!==a||a===void 0?s.willUpdate():this.safeToRemove(),t.isPresent!==n&&(n?s.promote():s.relegate()||J.postRender(()=>{let i=s.getStack();(!i||!i.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){let{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),En.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:t,layoutGroup:a,switchLayoutGroup:r}=this.props,{projection:o}=t;o&&(o.scheduleCheckAfterUnmount(),a&&a.group&&a.group.remove(o),r&&r.deregister&&r.deregister(o))}safeToRemove(){let{safeToRemove:t}=this.props;t&&t()}render(){return null}};function $d(e){let[t,a]=Vu(),r=(0,Wi.useContext)(Tn);return(0,SC.jsx)(Em,{...e,layoutGroup:r,switchLayoutGroup:(0,Wi.useContext)(Qu),isPresent:t,safeToRemove:a})}var E1={borderRadius:{...fs,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:fs,borderTopRightRadius:fs,borderBottomLeftRadius:fs,borderBottomRightRadius:fs,boxShadow:CC};function IC(e,t,a){let r=ye(e)?e:tr(e);return r.start(is("",r,t,a)),r.animation}function wC(e){return e instanceof SVGElement&&e.tagName!=="svg"}var kC=(e,t)=>e.depth-t.depth;var Xd=class{constructor(){this.children=[],this.isDirty=!1}add(t){Jn(this.children,t),this.isDirty=!0}remove(t){es(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(kC),this.isDirty=!1,this.children.forEach(t)}};function bC(e,t){let a=lt.now(),r=({timestamp:o})=>{let n=o-a;n>=t&&(_t(r),e(n-t))};return J.read(r,!0),()=>_t(r)}var RC=["TopLeft","TopRight","BottomLeft","BottomRight"],F1=RC.length,PC=e=>typeof e=="string"?parseFloat(e):e,TC=e=>typeof e=="number"||H.test(e);function DC(e,t,a,r,o,n){o?(e.opacity=ne(0,a.opacity!==void 0?a.opacity:1,B1(r)),e.opacityExit=ne(t.opacity!==void 0?t.opacity:1,0,O1(r))):n&&(e.opacity=ne(t.opacity!==void 0?t.opacity:1,a.opacity!==void 0?a.opacity:1,r));for(let s=0;s<F1;s++){let i=`border${RC[s]}Radius`,l=AC(t,i),u=AC(a,i);if(l===void 0&&u===void 0)continue;l||(l=0),u||(u=0),l===0||u===0||TC(l)===TC(u)?(e[i]=Math.max(ne(PC(l),PC(u),r),0),(ht.test(u)||ht.test(l))&&(e[i]+="%")):e[i]=u}(t.rotate||a.rotate)&&(e.rotate=ne(t.rotate||0,a.rotate||0,r))}function AC(e,t){return e[t]!==void 0?e[t]:e.borderRadius}var B1=MC(0,.5,Cd),O1=MC(.5,.95,he);function MC(e,t,a){return r=>r<e?0:r>t?1:a(Ut(e,t,r))}function NC(e,t){e.min=t.min,e.max=t.max}function Ht(e,t){NC(e.x,t.x),NC(e.y,t.y)}function Fm(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function EC(e,t,a,r,o){return e-=t,e=qi(e,1/a,r),o!==void 0&&(e=qi(e,1/o,r)),e}function V1(e,t=0,a=1,r=.5,o,n=e,s=e){if(ht.test(t)&&(t=parseFloat(t),t=ne(s.min,s.max,t/100)-s.min),typeof t!="number")return;let i=ne(n.min,n.max,r);e===n&&(i-=t),e.min=EC(e.min,t,a,i,o),e.max=EC(e.max,t,a,i,o)}function FC(e,t,[a,r,o],n,s){V1(e,t[a],t[r],t[o],t.scale,n,s)}var U1=["x","scaleX","originX"],_1=["y","scaleY","originY"];function Bm(e,t,a,r){FC(e.x,t,U1,a?a.x:void 0,r?r.x:void 0),FC(e.y,t,_1,a?a.y:void 0,r?r.y:void 0)}function BC(e){return e.translate===0&&e.scale===1}function Om(e){return BC(e.x)&&BC(e.y)}function OC(e,t){return e.min===t.min&&e.max===t.max}function UC(e,t){return OC(e.x,t.x)&&OC(e.y,t.y)}function VC(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Vm(e,t){return VC(e.x,t.x)&&VC(e.y,t.y)}function Um(e){return tt(e.x)/tt(e.y)}function _m(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}var Qd=class{constructor(){this.members=[]}add(t){Jn(this.members,t),t.scheduleRender()}remove(t){if(es(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){let a=this.members.findIndex(o=>t===o);if(a===0)return!1;let r;for(let o=a;o>=0;o--){let n=this.members[o];if(n.isPresent!==!1){r=n;break}}return r?(this.promote(r),!0):!1}promote(t,a){let r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,a&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);let{crossfade:o}=t.options;o===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{let{options:a,resumingFrom:r}=t;a.onExitComplete&&a.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}};function _C(e,t,a){let r="",o=e.x.translate/t.x,n=e.y.translate/t.y,s=a?.z||0;if((o||n||s)&&(r=`translate3d(${o}px, ${n}px, ${s}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),a){let{transformPerspective:u,rotate:d,rotateX:c,rotateY:p,skewX:g,skewY:C}=a;u&&(r=`perspective(${u}px) ${r}`),d&&(r+=`rotate(${d}deg) `),c&&(r+=`rotateX(${c}deg) `),p&&(r+=`rotateY(${p}deg) `),g&&(r+=`skewX(${g}deg) `),C&&(r+=`skewY(${C}deg) `)}let i=e.x.scale*t.x,l=e.y.scale*t.y;return(i!==1||l!==1)&&(r+=`scale(${i}, ${l})`),r||"none"}var Mo={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},Gi=typeof window<"u"&&window.MotionDebug!==void 0,zm=["","X","Y","Z"],z1={visibility:"hidden"},zC=1e3,H1=0;function Hm(e,t,a,r){let{latestValues:o}=t;o[e]&&(a[e]=o[e],t.setStaticValue(e,0),r&&(r[e]=0))}function XC(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;let{visualElement:t}=e.options;if(!t)return;let a=md(t);if(window.MotionHasOptimisedAnimation(a,"transform")){let{layout:o,layoutId:n}=e.options;window.MotionCancelOptimisedAnimation(a,"transform",J,!(o||n))}let{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&XC(r)}function Yd({attachResizeListener:e,defaultParent:t,measureScroll:a,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(s={},i=t?.()){this.id=H1++,this.animationId=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,Gi&&(Mo.totalNodes=Mo.resolvedTargetDeltas=Mo.recalculatedProjection=0),this.nodes.forEach(G1),this.nodes.forEach(Q1),this.nodes.forEach(Y1),this.nodes.forEach(j1),Gi&&window.MotionDebug.record(Mo)},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 Xd)}addEventListener(s,i){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new zr),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,i=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=wC(s),this.instance=s;let{layoutId:l,layout:u,visualElement:d}=this.options;if(d&&!d.current&&d.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),i&&(u||l)&&(this.isLayoutDirty=!0),e){let c,p=()=>this.root.updateBlockedByResize=!1;e(s,()=>{this.root.updateBlockedByResize=!0,c&&c(),c=bC(p,250),cs.hasAnimatedSinceResize&&(cs.hasAnimatedSinceResize=!1,this.nodes.forEach(qC))})}l&&this.root.registerSharedNode(l,this),this.options.animate!==!1&&d&&(l||u)&&this.addEventListener("didUpdate",({delta:c,hasLayoutChanged:p,hasRelativeTargetChanged:g,layout:C})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let L=this.options.transition||d.getDefaultTransition()||aT,{onLayoutAnimationStart:S,onLayoutAnimationComplete:h}=d.getProps(),m=!this.targetLayout||!Vm(this.targetLayout,C)||g,x=!p&&g;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||x||p&&(m||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(c,x);let I={...Vr(L,"layout"),onPlay:S,onComplete:h};(d.shouldReduceMotion||this.options.layoutRoot)&&(I.delay=0,I.type=!1),this.startAnimation(I)}else p||qC(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=C})}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,_t(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(Z1),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&&XC(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d<this.path.length;d++){let c=this.path[d];c.shouldResetTransform=!0,c.updateScroll("snapshot"),c.options.layoutRoot&&c.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()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(HC);return}this.isUpdating||this.nodes.forEach($1),this.isUpdating=!1,this.nodes.forEach(X1),this.nodes.forEach(q1),this.nodes.forEach(W1),this.clearAllSnapshots();let i=lt.now();Fe.delta=et(0,1e3/60,i-Fe.timestamp),Fe.timestamp=i,Fe.isProcessing=!0,Wu.update.process(Fe),Wu.preRender.process(Fe),Wu.render.process(Fe),Fe.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,En.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(K1),this.sharedNodes.forEach(J1)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,J.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){J.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}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=Ie(),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){let l=r(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(!o)return;let s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,i=this.projectionDelta&&!Om(this.projectionDelta),l=this.getTransformTemplate(),u=l?l(this.latestValues,""):void 0,d=u!==this.prevTransformTemplateValue;s&&(i||or(this.latestValues)||d)&&(o(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)),rT(l),{animationId:this.root.animationId,measuredBox:i,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){var s;let{visualElement:i}=this.options;if(!i)return Ie();let l=i.measureViewportBox();if(!(((s=this.scroll)===null||s===void 0?void 0:s.wasRoot)||this.path.some(oT))){let{scroll:d}=this.root;d&&($r(l.x,d.offset.x),$r(l.y,d.offset.y))}return l}removeElementScroll(s){var i;let l=Ie();if(Ht(l,s),!((i=this.scroll)===null||i===void 0)&&i.wasRoot)return l;for(let u=0;u<this.path.length;u++){let d=this.path[u],{scroll:c,options:p}=d;d!==this.root&&c&&p.layoutScroll&&(c.wasRoot&&Ht(l,s),$r(l.x,c.offset.x),$r(l.y,c.offset.y))}return l}applyTransform(s,i=!1){let l=Ie();Ht(l,s);for(let u=0;u<this.path.length;u++){let d=this.path[u];!i&&d.options.layoutScroll&&d.scroll&&d!==d.root&&Do(l,{x:-d.scroll.offset.x,y:-d.scroll.offset.y}),or(d.latestValues)&&Do(l,d.latestValues)}return or(this.latestValues)&&Do(l,this.latestValues),l}removeTransform(s){let i=Ie();Ht(i,s);for(let l=0;l<this.path.length;l++){let u=this.path[l];if(!u.instance||!or(u.latestValues))continue;Hd(u.latestValues)&&u.updateSnapshot();let d=Ie(),c=u.measurePageBox();Ht(d,c),Bm(i,u.latestValues,u.snapshot?u.snapshot.layoutBox:void 0,d)}return or(this.latestValues)&&Bm(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!==Fe.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){var i;let l=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=l.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=l.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=l.isSharedProjectionDirty);let u=!!this.resumingFrom||this!==l;if(!(s||u&&this.isSharedProjectionDirty||this.isProjectionDirty||!((i=this.parent)===null||i===void 0)&&i.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:c,layoutId:p}=this.options;if(!(!this.layout||!(c||p))){if(this.resolvedRelativeTargetAt=Fe.timestamp,!this.targetDelta&&!this.relativeTarget){let g=this.getClosestProjectingParent();g&&g.layout&&this.animationProgress!==1?(this.relativeParent=g,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Ie(),this.relativeTargetOrigin=Ie(),ds(this.relativeTargetOrigin,this.layout.layoutBox,g.layout.layoutBox),Ht(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)){if(this.target||(this.target=Ie(),this.targetWithTransforms=Ie()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),YL(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):Ht(this.target,this.layout.layoutBox),Mm(this.target,this.targetDelta)):Ht(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;let g=this.getClosestProjectingParent();g&&!!g.resumingFrom==!!this.resumingFrom&&!g.options.layoutScroll&&g.target&&this.animationProgress!==1?(this.relativeParent=g,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Ie(),this.relativeTargetOrigin=Ie(),ds(this.relativeTargetOrigin,this.target,g.target),Ht(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}Gi&&Mo.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||Hd(this.parent.latestValues)||Rm(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var s;let i=this.getLead(),l=!!this.resumingFrom||this!==i,u=!0;if((this.isProjectionDirty||!((s=this.parent)===null||s===void 0)&&s.isProjectionDirty)&&(u=!1),l&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(u=!1),this.resolvedRelativeTargetAt===Fe.timestamp&&(u=!1),u)return;let{layout:d,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||!(d||c))return;Ht(this.layoutCorrected,this.layout.layoutBox);let p=this.treeScale.x,g=this.treeScale.y;xC(this.layoutCorrected,this.treeScale,this.path,l),i.layout&&!i.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(i.target=i.layout.layoutBox,i.targetWithTransforms=Ie());let{target:C}=i;if(!C){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Fm(this.prevProjectionDelta.x,this.projectionDelta.x),Fm(this.prevProjectionDelta.y,this.projectionDelta.y)),us(this.projectionDelta,this.layoutCorrected,C,this.latestValues),(this.treeScale.x!==p||this.treeScale.y!==g||!_m(this.projectionDelta.x,this.prevProjectionDelta.x)||!_m(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",C)),Gi&&Mo.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){var i;if((i=this.options.visualElement)===null||i===void 0||i.scheduleRender(),s){let l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Ro(),this.projectionDelta=Ro(),this.projectionDeltaWithTransform=Ro()}setAnimationOrigin(s,i=!1){let l=this.snapshot,u=l?l.latestValues:{},d={...this.latestValues},c=Ro();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!i;let p=Ie(),g=l?l.source:void 0,C=this.layout?this.layout.source:void 0,L=g!==C,S=this.getStack(),h=!S||S.members.length<=1,m=!!(L&&!h&&this.options.crossfade===!0&&!this.path.some(tT));this.animationProgress=0;let x;this.mixTargetDelta=I=>{let k=I/1e3;WC(c.x,s.x,k),WC(c.y,s.y,k),this.setTargetDelta(c),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(ds(p,this.layout.layoutBox,this.relativeParent.layout.layoutBox),eT(this.relativeTarget,this.relativeTargetOrigin,p,k),x&&UC(this.relativeTarget,x)&&(this.isProjectionDirty=!1),x||(x=Ie()),Ht(x,this.relativeTarget)),L&&(this.animationValues=d,DC(d,u,this.latestValues,k,m,h)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=k},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(_t(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=J.update(()=>{cs.hasAnimatedSinceResize=!0,this.currentAnimation=IC(0,zC,{...s,onUpdate:i=>{this.mixTargetDelta(i),s.onUpdate&&s.onUpdate(i)},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);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(zC),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let s=this.getLead(),{targetWithTransforms:i,target:l,layout:u,latestValues:d}=s;if(!(!i||!l||!u)){if(this!==s&&this.layout&&u&&QC(this.options.animationType,this.layout.layoutBox,u.layoutBox)){l=this.target||Ie();let c=tt(this.layout.layoutBox.x);l.x.min=s.target.x.min,l.x.max=l.x.min+c;let p=tt(this.layout.layoutBox.y);l.y.min=s.target.y.min,l.y.max=l.y.min+p}Ht(i,l),Do(i,d),us(this.projectionDeltaWithTransform,this.layoutCorrected,i,d)}}registerSharedNode(s,i){this.sharedNodes.has(s)||this.sharedNodes.set(s,new Qd),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(){var s;let{layoutId:i}=this.options;return i?((s=this.getStack())===null||s===void 0?void 0:s.lead)||this:this}getPrevLead(){var s;let{layoutId:i}=this.options;return i?(s=this.getStack())===null||s===void 0?void 0:s.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&&Hm("z",s,u,this.animationValues);for(let d=0;d<zm.length;d++)Hm(`rotate${zm[d]}`,s,u,this.animationValues),Hm(`skew${zm[d]}`,s,u,this.animationValues);s.render();for(let d in u)s.setStaticValue(d,u[d]),this.animationValues&&(this.animationValues[d]=u[d]);s.scheduleRender()}getProjectionStyles(s){var i,l;if(!this.instance||this.isSVG)return;if(!this.isVisible)return z1;let u={visibility:""},d=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,u.opacity="",u.pointerEvents=Vn(s?.pointerEvents)||"",u.transform=d?d(this.latestValues,""):"none",u;let c=this.getLead();if(!this.projectionDelta||!this.layout||!c.target){let L={};return this.options.layoutId&&(L.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,L.pointerEvents=Vn(s?.pointerEvents)||""),this.hasProjected&&!or(this.latestValues)&&(L.transform=d?d({},""):"none",this.hasProjected=!1),L}let p=c.animationValues||c.latestValues;this.applyTransformsToTarget(),u.transform=_C(this.projectionDeltaWithTransform,this.treeScale,p),d&&(u.transform=d(p,u.transform));let{x:g,y:C}=this.projectionDelta;u.transformOrigin=`${g.origin*100}% ${C.origin*100}% 0`,c.animationValues?u.opacity=c===this?(l=(i=p.opacity)!==null&&i!==void 0?i:this.latestValues.opacity)!==null&&l!==void 0?l:1:this.preserveOpacity?this.latestValues.opacity:p.opacityExit:u.opacity=c===this?p.opacity!==void 0?p.opacity:"":p.opacityExit!==void 0?p.opacityExit:0;for(let L in Gn){if(p[L]===void 0)continue;let{correct:S,applyTo:h}=Gn[L],m=u.transform==="none"?p[L]:S(p[L],c);if(h){let x=h.length;for(let I=0;I<x;I++)u[h[I]]=m}else u[L]=m}return this.options.layoutId&&(u.pointerEvents=c===this?Vn(s?.pointerEvents)||"":"none"),u}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>{var i;return(i=s.currentAnimation)===null||i===void 0?void 0:i.stop()}),this.root.nodes.forEach(HC),this.root.sharedNodes.clear()}}}function q1(e){e.updateLayout()}function W1(e){var t;let a=((t=e.resumeFrom)===null||t===void 0?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&a&&e.hasListeners("didUpdate")){let{layoutBox:r,measuredBox:o}=e.layout,{animationType:n}=e.options,s=a.source!==e.layout.source;n==="size"?Tt(c=>{let p=s?a.measuredBox[c]:a.layoutBox[c],g=tt(p);p.min=r[c].min,p.max=p.min+g}):QC(n,a.layoutBox,r)&&Tt(c=>{let p=s?a.measuredBox[c]:a.layoutBox[c],g=tt(r[c]);p.max=p.min+g,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[c].max=e.relativeTarget[c].min+g)});let i=Ro();us(i,r,a.layoutBox);let l=Ro();s?us(l,e.applyTransform(o,!0),a.measuredBox):us(l,r,a.layoutBox);let u=!Om(i),d=!1;if(!e.resumeFrom){let c=e.getClosestProjectingParent();if(c&&!c.resumeFrom){let{snapshot:p,layout:g}=c;if(p&&g){let C=Ie();ds(C,a.layoutBox,p.layoutBox);let L=Ie();ds(L,r,g.layoutBox),Vm(C,L)||(d=!0),c.options.layoutRoot&&(e.relativeTarget=L,e.relativeTargetOrigin=C,e.relativeParent=c)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:a,delta:l,layoutDelta:i,hasLayoutChanged:u,hasRelativeTargetChanged:d})}else if(e.isLead()){let{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function G1(e){Gi&&Mo.totalNodes++,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 j1(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function K1(e){e.clearSnapshot()}function HC(e){e.clearMeasurements()}function $1(e){e.isLayoutDirty=!1}function X1(e){let{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function qC(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Q1(e){e.resolveTargetDelta()}function Y1(e){e.calcProjection()}function Z1(e){e.resetSkewAndRotation()}function J1(e){e.removeLeadSnapshot()}function WC(e,t,a){e.translate=ne(t.translate,0,a),e.scale=ne(t.scale,1,a),e.origin=t.origin,e.originPoint=t.originPoint}function GC(e,t,a,r){e.min=ne(t.min,a.min,r),e.max=ne(t.max,a.max,r)}function eT(e,t,a,r){GC(e.x,t.x,a.x,r),GC(e.y,t.y,a.y,r)}function tT(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}var aT={duration:.45,ease:[.4,0,.1,1]},jC=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),KC=jC("applewebkit/")&&!jC("chrome/")?Math.round:he;function $C(e){e.min=KC(e.min),e.max=KC(e.max)}function rT(e){$C(e.x),$C(e.y)}function QC(e,t,a){return e==="position"||e==="preserve-aspect"&&!QL(Um(t),Um(a),.2)}function oT(e){var t;return e!==e.root&&((t=e.scroll)===null||t===void 0?void 0:t.wasRoot)}var YC=Yd({attachResizeListener:(e,t)=>ar(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0});var qm={current:void 0},Zd=Yd({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!qm.current){let e=new YC({});e.mount(window),e.setOptions({layoutScroll:!0}),qm.current=e}return qm.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"});var ZC={pan:{Feature:Kd},drag:{Feature:jd,ProjectionNode:Zd,MeasureLayout:$d}};function JC(e,t,a){let{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",a==="Start");let o="onHover"+a,n=r[o];n&&J.postRender(()=>n(t,rr(t)))}var Jd=class extends Xe{mount(){let{current:t}=this.node;t&&(this.unmount=sm(t,a=>(JC(this.node,a,"Start"),r=>JC(this.node,r,"End"))))}unmount(){}};var ec=class extends Xe{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=Pa(ar(this.node.current,"focus",()=>this.onFocus()),ar(this.node.current,"blur",()=>this.onBlur()))}unmount(){}};function eS(e,t,a){let{props:r}=e;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",a==="Start");let o="onTap"+(a==="End"?"":a),n=r[o];n&&J.postRender(()=>n(t,rr(t)))}var tc=class extends Xe{mount(){let{current:t}=this.node;t&&(this.unmount=lm(t,a=>(eS(this.node,a,"Start"),(r,{success:o})=>eS(this.node,r,o?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}};var Gm=new WeakMap,Wm=new WeakMap,nT=e=>{let t=Gm.get(e.target);t&&t(e)},sT=e=>{e.forEach(nT)};function iT({root:e,...t}){let a=e||document;Wm.has(a)||Wm.set(a,{});let r=Wm.get(a),o=JSON.stringify(t);return r[o]||(r[o]=new IntersectionObserver(sT,{root:e,...t})),r[o]}function tS(e,t,a){let r=iT(t);return Gm.set(e,a),r.observe(e),()=>{Gm.delete(e),r.unobserve(e)}}var lT={some:0,all:1},ac=class extends Xe{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();let{viewport:t={}}=this.node.getProps(),{root:a,margin:r,amount:o="some",once:n}=t,s={root:a?a.current:void 0,rootMargin:r,threshold:typeof o=="number"?o:lT[o]},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:d,onViewportLeave:c}=this.node.getProps(),p=u?d:c;p&&p(l)};return tS(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(uT(t,a))&&this.startObserver()}unmount(){}};function uT({viewport:e={}},{viewport:t={}}={}){return a=>e[a]!==t[a]}var aS={inView:{Feature:ac},tap:{Feature:tc},focus:{Feature:ec},hover:{Feature:Jd}};var rS={layout:{ProjectionNode:Zd,MeasureLayout:$d}};var lS=E(X(),1);var ji={current:null},rc={current:!1};function oS(){if(rc.current=!0,!!Dn)if(window.matchMedia){let e=window.matchMedia("(prefers-reduced-motion)"),t=()=>ji.current=e.matches;e.addListener(t),t()}else ji.current=!1}var dT=[...xm,Ue,gt],nS=e=>dT.find(Pd(e));var jm=new WeakMap;function sS(e,t,a){for(let r in t){let o=t[r],n=a[r];if(ye(o))e.addValue(r,o);else if(ye(n))e.addValue(r,tr(o,{owner:e}));else if(n!==o)if(e.hasValue(r)){let s=e.getValue(r);s.liveStyle===!0?s.jump(o):s.hasAnimated||s.set(o)}else{let s=e.getStaticValue(r);e.addValue(r,tr(s!==void 0?s:o,{owner:e}))}}for(let r in a)t[r]===void 0&&e.removeValue(r);return t}var iS=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],oc=class{scrapeMotionValuesFromProps(t,a,r){return{}}constructor({parent:t,props:a,presenceContext:r,reducedMotionConfig:o,blockInitialAnimation:n,visualState:s},i={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Gr,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{let g=lt.now();this.renderScheduledAt<g&&(this.renderScheduledAt=g,J.render(this.render,!1,!0))};let{latestValues:l,renderState:u,onUpdate:d}=s;this.onUpdate=d,this.latestValues=l,this.baseTarget={...l},this.initialValues=a.initial?{...l}:{},this.renderState=u,this.parent=t,this.props=a,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=o,this.options=i,this.blockInitialAnimation=!!n,this.isControllingVariants=So(a),this.isVariantNode=Ku(a),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);let{willChange:c,...p}=this.scrapeMotionValuesFromProps(a,{},this);for(let g in p){let C=p[g];l[g]!==void 0&&ye(C)&&C.set(l[g],!1)}}mount(t){this.current=t,jm.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,r)=>this.bindToMotionValue(r,a)),rc.current||oS(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:ji.current,this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){jm.delete(this.current),this.projection&&this.projection.unmount(),_t(this.notifyUpdate),_t(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(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}bindToMotionValue(t,a){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();let r=Pt.has(t),o=a.on("change",i=>{this.latestValues[t]=i,this.props.onUpdate&&J.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0)}),n=a.on("renderRequest",this.scheduleRender),s;window.MotionCheckAppearSync&&(s=window.MotionCheckAppearSync(this,t,a)),this.valueSubscriptions.set(t,()=>{o(),n(),s&&s(),a.owner&&a.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Ya){let a=Ya[t];if(!a)continue;let{isEnabled:r,Feature:o}=a;if(!this.features[t]&&o&&r(this.props)&&(this.features[t]=new o(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):Ie()}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 r=0;r<iS.length;r++){let o=iS[r];this.propEventSubscriptions[o]&&(this.propEventSubscriptions[o](),delete this.propEventSubscriptions[o]);let n="on"+o,s=t[n];s&&(this.propEventSubscriptions[o]=this.on(o,s))}this.prevMotionValues=sS(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue(),this.onUpdate&&this.onUpdate(this)}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 r=this.values.get(t);a!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,a),this.values.set(t,a),this.latestValues[t]=a.get())}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 r=this.values.get(t);return r===void 0&&a!==void 0&&(r=tr(a===null?void 0:a,{owner:this}),this.addValue(t,r)),r}readValue(t,a){var r;let o=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(r=this.getBaseTargetFromProps(this.props,t))!==null&&r!==void 0?r:this.readValueFromInstance(this.current,t,this.options);return o!=null&&(typeof o=="string"&&(bd(o)||Id(o))?o=parseFloat(o):!nS(o)&>.test(a)&&(o=kd(t,a)),this.setBaseTarget(t,ye(o)?o.get():o)),ye(o)?o.get():o}setBaseTarget(t,a){this.baseTarget[t]=a}getBaseTarget(t){var a;let{initial:r}=this.props,o;if(typeof r=="string"||typeof r=="object"){let s=On(this.props,r,(a=this.presenceContext)===null||a===void 0?void 0:a.custom);s&&(o=s[t])}if(r&&o!==void 0)return o;let n=this.getBaseTargetFromProps(this.props,t);return n!==void 0&&!ye(n)?n:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,a){return this.events[t]||(this.events[t]=new zr),this.events[t].add(a)}notify(t,...a){this.events[t]&&this.events[t].notify(...a)}};var ps=class extends oc{constructor(){super(...arguments),this.KeyframeResolver=os}sortInstanceNodePosition(t,a){return t.compareDocumentPosition(a)&2?1:-1}getBaseTargetFromProps(t,a){return t.style?t.style[a]:void 0}removeValueFromRenderState(t,{vars:a,style:r}){delete a[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:t}=this.props;ye(t)&&(this.childSubscription=t.on("change",a=>{this.current&&(this.current.textContent=`${a}`)}))}};function cT(e){return window.getComputedStyle(e)}var nc=class extends ps{constructor(){super(...arguments),this.type="html",this.renderInstance=ad}readValueFromInstance(t,a){if(Pt.has(a)){let r=rs(a);return r&&r.default||0}else{let r=cT(t),o=(Ju(a)?r.getPropertyValue(a):r[a])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:a}){return Nm(t,a)}build(t,a,r){zn(t,a,r.transformTemplate)}scrapeMotionValuesFromProps(t,a,r){return jn(t,a,r)}};var sc=class extends ps{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Ie}getBaseTargetFromProps(t,a){return t[a]}readValueFromInstance(t,a){if(Pt.has(a)){let r=rs(a);return r&&r.default||0}return a=rd.has(a)?a:Nn(a),t.getAttribute(a)}scrapeMotionValuesFromProps(t,a,r){return sd(t,a,r)}build(t,a,r){Hn(t,a,this.isSVGTag,r.transformTemplate)}renderInstance(t,a,r,o){od(t,a,r,o)}mount(t){this.isSVGTag=Wn(t.tagName),super.mount(t)}};var uS=(e,t)=>Bn(e)?new sc(t):new nc(t,{allowProjection:e!==lS.Fragment});var dS=V0({...UL,...aS,...ZC,...rS},uS);var Km=o0(dS);var Ki=E(ue(),1);function cS({x:e,y:t,visible:a,onClick:r=!1}){return(0,Ki.jsx)(Qp,{children:a&&(0,Ki.jsx)(Km.div,{className:"fixed pointer-events-none z-[9999]",initial:{opacity:0,scale:.5},animate:{opacity:1,scale:1,x:e,y:t},exit:{opacity:0,scale:.5},transition:{type:"spring",stiffness:200,damping:20},style:{left:0,top:0},children:(0,Ki.jsx)("svg",{width:"32",height:"32",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,Ki.jsx)("path",{d:"M3 3L10.07 19.97L12.58 12.58L19.97 10.07L3 3Z",fill:"#C4B5FD"})})})})}var ms=E(X(),1);function fS(){let[e,t]=ms.useState({x:0,y:0,visible:!1,onClick:!1}),a=ms.useCallback(n=>{let s=document.querySelector(n.selector);if(s){let i=s.getBoundingClientRect(),l=n.offset?.x||0,u=n.offset?.y||0;t({x:i.left+i.width/2+l,y:i.top+i.height/2+u,visible:!0,onClick:n.onClick||!1})}},[]),r=ms.useCallback(()=>{t(n=>({...n,visible:!1}))},[]),o=ms.useCallback(()=>{t(n=>({...n,visible:!0}))},[]);return{cursorState:e,moveTo:a,hide:r,show:o}}var hs=E(ue(),1);function ut({className:e,...t}){return(0,hs.jsx)("div",{"data-slot":"card",className:Ot("bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm",e),...t})}function Ta({className:e,...t}){return(0,hs.jsx)("div",{"data-slot":"card-header",className:Ot("@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-2 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",e),...t})}function Aa({className:e,...t}){return(0,hs.jsx)("div",{"data-slot":"card-title",className:Ot("leading-none font-semibold",e),...t})}function $m({className:e,...t}){return(0,hs.jsx)("div",{"data-slot":"card-description",className:Ot("text-muted-foreground text-sm",e),...t})}function dt({className:e,...t}){return(0,hs.jsx)("div",{"data-slot":"card-content",className:Ot("px-6",e),...t})}var y=E(ue(),1),Xm=e=>new Date(e).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"}),ic=(e,t="USD")=>new Intl.NumberFormat("en-US",{style:"currency",currency:t}).format(e),Qm=e=>{switch(e){case"Enterprise":return xo;case"Professional":return ki;default:return xi}},lc=e=>{switch(e){case"Enterprise":return"bg-purple-50 text-purple-700 border-purple-200";case"Professional":return"bg-blue-50 text-blue-700 border-blue-200";default:return"bg-gray-50 text-gray-700 border-gray-200"}};function $i({status:e,type:t="default"}){let r=(()=>{let n=e.toLowerCase();if(t==="transaction")switch(n){case"paid":return{color:"bg-emerald-50 text-emerald-700 border-emerald-200",icon:$e};case"failed":return{color:"bg-red-50 text-red-700 border-red-200",icon:ca};case"pending":return{color:"bg-amber-50 text-amber-700 border-amber-200",icon:ho};case"refunded":return{color:"bg-slate-50 text-slate-700 border-slate-200",icon:kn};default:return{color:"bg-gray-50 text-gray-700 border-gray-200",icon:da}}if(t==="subscription")switch(n){case"active":return{color:"bg-emerald-50 text-emerald-700 border-emerald-200",icon:$e};case"cancelled":return{color:"bg-slate-50 text-slate-700 border-slate-200",icon:ca};case"past_due":return{color:"bg-red-50 text-red-700 border-red-200",icon:da};case"trialing":return{color:"bg-blue-50 text-blue-700 border-blue-200",icon:ho};default:return{color:"bg-gray-50 text-gray-700 border-gray-200",icon:da}}switch(n){case"active":return{color:"bg-emerald-50 text-emerald-700 border-emerald-200",icon:$e};case"inactive":return{color:"bg-slate-50 text-slate-700 border-slate-200",icon:ca};default:return{color:"bg-gray-50 text-gray-700 border-gray-200",icon:da}}})(),o=r.icon;return(0,y.jsxs)("span",{className:`inline-flex items-center gap-1.5 px-2.5 py-1 rounded-full text-xs font-medium border ${r.color}`,children:[(0,y.jsx)(o,{className:"h-3 w-3"}),e]})}function fT({subscription:e}){let t=Qm(e.plan);return(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)("div",{className:`h-1 ${e.status==="active"?"bg-emerald-500":e.status==="past_due"?"bg-red-500":"bg-slate-300"}`}),(0,y.jsx)(Ta,{className:"pb-3",children:(0,y.jsxs)("div",{className:"flex items-start justify-between",children:[(0,y.jsxs)("div",{className:"space-y-1",children:[(0,y.jsxs)(Aa,{className:"text-base font-semibold text-gray-900 flex items-center gap-2",children:[(0,y.jsx)(go,{className:"h-4 w-4 text-gray-500"}),e.id]}),e.customer_email&&(0,y.jsxs)($m,{className:"text-sm text-gray-500 flex items-center gap-1.5",children:[(0,y.jsx)(In,{className:"h-3 w-3"}),e.customer_email]})]}),(0,y.jsx)($i,{status:e.status,type:"subscription"})]})}),(0,y.jsx)(dt,{className:"pt-0",children:(0,y.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,y.jsxs)("div",{className:"space-y-3",children:[(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Plan"}),(0,y.jsxs)("span",{className:`inline-flex items-center gap-1.5 px-2.5 py-1 rounded-md text-xs font-medium border ${lc(e.plan)}`,children:[(0,y.jsx)(t,{className:"h-3 w-3"}),e.plan]})]}),(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Billing"}),(0,y.jsxs)("div",{className:"text-sm font-medium text-gray-900",children:[ic(e.amount,e.currency)," / ",e.billing_cycle]})]})]}),(0,y.jsxs)("div",{className:"space-y-3",children:[(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Current Period"}),(0,y.jsxs)("div",{className:"text-sm text-gray-700",children:[Xm(e.current_period_start)," - ",Xm(e.current_period_end)]})]}),(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Created"}),(0,y.jsx)("div",{className:"text-sm text-gray-700",children:Xm(e.created_at)})]})]})]})})]})}function pT({subscriptions:e,maxItems:t=5}){let a=e.slice(0,t),r=e.length>t;return e.length===0?(0,y.jsx)(ut,{className:"border-gray-200 shadow-sm bg-white",children:(0,y.jsxs)(dt,{className:"py-8 text-center",children:[(0,y.jsx)(go,{className:"h-10 w-10 text-gray-300 mx-auto mb-3"}),(0,y.jsx)("p",{className:"text-sm text-gray-500",children:"No subscriptions found"})]})}):(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(go,{className:"h-4 w-4"}),e.length," Subscription",e.length!==1?"s":""]})}),(0,y.jsxs)(dt,{className:"p-0",children:[(0,y.jsx)("div",{className:"divide-y divide-gray-100",children:a.map(o=>{let n=Qm(o.plan);return(0,y.jsx)("div",{className:"px-4 py-3 hover:bg-gray-50 transition-colors",children:(0,y.jsxs)("div",{className:"flex items-center justify-between",children:[(0,y.jsxs)("div",{className:"flex items-center gap-3 min-w-0",children:[(0,y.jsx)("div",{className:`p-2 rounded-lg ${lc(o.plan).replace("text-","text-").replace("border-","bg-").split(" ")[0]}`,children:(0,y.jsx)(n,{className:"h-4 w-4"})}),(0,y.jsxs)("div",{className:"min-w-0",children:[(0,y.jsx)("div",{className:"text-sm font-medium text-gray-900 truncate",children:o.customer_email||o.customer_id}),(0,y.jsxs)("div",{className:"text-xs text-gray-500",children:[o.plan," \xB7 ",ic(o.amount,o.currency),"/",o.billing_cycle]})]})]}),(0,y.jsx)($i,{status:o.status,type:"subscription"})]})},o.id)})}),r&&(0,y.jsx)("div",{className:"px-4 py-2 bg-gray-50 border-t border-gray-100 text-center",children:(0,y.jsxs)("span",{className:"text-xs text-gray-500",children:["+",e.length-t," more subscription",e.length-t!==1?"s":""]})})]})]})}function mT({customer:e}){let t=Qm(e.subscription);return(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)("div",{className:`h-1 ${e.status==="active"?"bg-emerald-500":"bg-slate-300"}`}),(0,y.jsx)(Ta,{className:"pb-3",children:(0,y.jsxs)("div",{className:"flex items-start justify-between",children:[(0,y.jsx)("div",{className:"flex items-center gap-3",children:(0,y.jsxs)("div",{children:[(0,y.jsx)(Aa,{className:"text-base font-semibold text-gray-900",children:e.name}),(0,y.jsxs)($m,{className:"text-sm text-gray-500 flex items-center gap-1",children:[(0,y.jsx)(In,{className:"h-3 w-3"}),e.email]})]})}),(0,y.jsx)($i,{status:e.status,type:"customer"})]})}),(0,y.jsx)(dt,{className:"pt-0",children:(0,y.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,y.jsxs)("div",{className:"space-y-3",children:[(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Plan"}),(0,y.jsxs)("span",{className:`inline-flex items-center gap-1.5 px-2.5 py-1 rounded-md text-xs font-medium border ${lc(e.subscription)}`,children:[(0,y.jsx)(t,{className:"h-3 w-3"}),e.subscription]})]}),(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Revenue"}),(0,y.jsxs)("div",{className:"text-sm font-medium text-gray-900 flex items-center gap-1",children:[(0,y.jsx)(yo,{className:"h-3 w-3 text-emerald-500"}),e.revenue]})]})]}),(0,y.jsxs)("div",{className:"space-y-3",children:[(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Location"}),(0,y.jsxs)("div",{className:"text-sm text-gray-700 flex items-center gap-1",children:[(0,y.jsx)(wn,{className:"h-3 w-3 text-gray-400"}),e.location||"Not specified"]})]}),(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Customer Since"}),(0,y.jsxs)("div",{className:"text-sm text-gray-700 flex items-center gap-1",children:[(0,y.jsx)(vi,{className:"h-3 w-3 text-gray-400"}),e.joinDate]})]})]})]})})]})}function hT({customers:e,maxItems:t=5}){let a=e.slice(0,t),r=e.length>t;return e.length===0?(0,y.jsx)(ut,{className:"border-gray-200 shadow-sm bg-white",children:(0,y.jsxs)(dt,{className:"py-8 text-center",children:[(0,y.jsx)(Pn,{className:"h-10 w-10 text-gray-300 mx-auto mb-3"}),(0,y.jsx)("p",{className:"text-sm text-gray-500",children:"No customers found"})]})}):(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(Pn,{className:"h-4 w-4"}),e.length," Customer",e.length!==1?"s":""]})}),(0,y.jsxs)(dt,{className:"p-0",children:[(0,y.jsx)("div",{className:"divide-y divide-gray-100",children:a.map(o=>(0,y.jsx)("div",{className:"px-4 py-3 hover:bg-gray-50 transition-colors",children:(0,y.jsxs)("div",{className:"flex items-center justify-between",children:[(0,y.jsx)("div",{className:"flex items-center gap-3 min-w-0",children:(0,y.jsxs)("div",{className:"min-w-0",children:[(0,y.jsx)("div",{className:"text-sm font-medium text-gray-900 truncate",children:o.name}),(0,y.jsx)("div",{className:"text-xs text-gray-500 truncate",children:o.email})]})}),(0,y.jsxs)("div",{className:"flex items-center gap-2",children:[(0,y.jsx)("span",{className:`px-2 py-0.5 rounded text-xs font-medium ${lc(o.subscription)}`,children:o.subscription}),(0,y.jsx)($i,{status:o.status,type:"customer"})]})]})},o.id))}),r&&(0,y.jsx)("div",{className:"px-4 py-2 bg-gray-50 border-t border-gray-100 text-center",children:(0,y.jsxs)("span",{className:"text-xs text-gray-500",children:["+",e.length-t," more customer",e.length-t!==1?"s":""]})})]})]})}function pS({transactions:e,maxItems:t=5}){let a=e.slice(0,t),r=e.length>t;return e.length===0?(0,y.jsx)(ut,{className:"border-gray-200 shadow-sm bg-white",children:(0,y.jsxs)(dt,{className:"py-8 text-center",children:[(0,y.jsx)(yo,{className:"h-10 w-10 text-gray-300 mx-auto mb-3"}),(0,y.jsx)("p",{className:"text-sm text-gray-500",children:"No transactions found"})]})}):(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(yo,{className:"h-4 w-4"}),e.length," Transaction",e.length!==1?"s":""]})}),(0,y.jsxs)(dt,{className:"p-0",children:[(0,y.jsx)("div",{className:"divide-y divide-gray-100",children:a.map(o=>(0,y.jsx)("div",{className:"px-4 py-3 hover:bg-gray-50 transition-colors",children:(0,y.jsxs)("div",{className:"flex items-center justify-between",children:[(0,y.jsxs)("div",{className:"flex items-center gap-3 min-w-0",children:[(0,y.jsx)("div",{className:`p-2 rounded-lg ${o.status==="paid"?"bg-emerald-50":o.status==="failed"?"bg-red-50":o.status==="refunded"?"bg-slate-50":"bg-amber-50"}`,children:o.status==="paid"?(0,y.jsx)($e,{className:"h-4 w-4 text-emerald-600"}):o.status==="failed"?(0,y.jsx)(ca,{className:"h-4 w-4 text-red-600"}):o.status==="refunded"?(0,y.jsx)(kn,{className:"h-4 w-4 text-slate-600"}):(0,y.jsx)(ho,{className:"h-4 w-4 text-amber-600"})}),(0,y.jsxs)("div",{className:"min-w-0",children:[(0,y.jsx)("div",{className:"text-sm font-medium text-gray-900 truncate",children:o.customer}),(0,y.jsxs)("div",{className:"text-xs text-gray-500",children:[o.date,o.decline_reason&&(0,y.jsxs)("span",{className:"text-red-500 ml-2",children:["\xB7 ",o.decline_reason]})]})]})]}),(0,y.jsxs)("div",{className:"flex items-center gap-3",children:[(0,y.jsxs)("span",{className:`text-sm font-semibold ${o.status==="paid"?"text-emerald-600":o.status==="failed"?"text-red-600":o.status==="refunded"?"text-slate-600":"text-amber-600"}`,children:[o.status==="refunded"?"-":"",o.amount]}),(0,y.jsx)($i,{status:o.status,type:"transaction"})]})]})},o.id))}),r&&(0,y.jsx)("div",{className:"px-4 py-2 bg-gray-50 border-t border-gray-100 text-center",children:(0,y.jsxs)("span",{className:"text-xs text-gray-500",children:["+",e.length-t," more transaction",e.length-t!==1?"s":""]})})]})]})}function gT({apiKeys:e}){return e.length===0?(0,y.jsx)(ut,{className:"border-gray-200 shadow-sm bg-white",children:(0,y.jsxs)(dt,{className:"py-8 text-center",children:[(0,y.jsx)(Sn,{className:"h-10 w-10 text-gray-300 mx-auto mb-3"}),(0,y.jsx)("p",{className:"text-sm text-gray-500",children:"No API keys found"})]})}):(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(Sn,{className:"h-4 w-4"}),e.length," API Key",e.length!==1?"s":""]})}),(0,y.jsx)(dt,{className:"p-0",children:(0,y.jsx)("div",{className:"divide-y divide-gray-100",children:e.map((t,a)=>(0,y.jsx)("div",{className:"px-4 py-3 hover:bg-gray-50 transition-colors",children:(0,y.jsxs)("div",{className:"flex items-center justify-between",children:[(0,y.jsxs)("div",{className:"min-w-0",children:[(0,y.jsx)("div",{className:"text-sm font-medium text-gray-900",children:t.name}),(0,y.jsxs)("div",{className:"text-xs text-gray-500 font-mono",children:[t.key.slice(0,12),"...",t.key.slice(-4)]})]}),(0,y.jsxs)("div",{className:"text-xs text-gray-500",children:["Last used: ",t.lastUsed]})]})},a))})})]})}function xT({sessions:e}){let t=a=>{let r=a.toLowerCase();return r.includes("mobile")||r.includes("iphone")||r.includes("android")?Ii:Ci};return e.length===0?(0,y.jsx)(ut,{className:"border-gray-200 shadow-sm bg-white",children:(0,y.jsxs)(dt,{className:"py-8 text-center",children:[(0,y.jsx)(bn,{className:"h-10 w-10 text-gray-300 mx-auto mb-3"}),(0,y.jsx)("p",{className:"text-sm text-gray-500",children:"No active sessions"})]})}):(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(bn,{className:"h-4 w-4"}),e.length," Active Session",e.length!==1?"s":""]})}),(0,y.jsx)(dt,{className:"p-0",children:(0,y.jsx)("div",{className:"divide-y divide-gray-100",children:e.map((a,r)=>{let o=t(a.device);return(0,y.jsx)("div",{className:"px-4 py-3 hover:bg-gray-50 transition-colors",children:(0,y.jsxs)("div",{className:"flex items-center justify-between",children:[(0,y.jsxs)("div",{className:"flex items-center gap-3",children:[(0,y.jsx)("div",{className:"p-2 rounded-lg bg-gray-100",children:(0,y.jsx)(o,{className:"h-4 w-4 text-gray-600"})}),(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-sm font-medium text-gray-900",children:a.device}),(0,y.jsxs)("div",{className:"text-xs text-gray-500 flex items-center gap-1",children:[(0,y.jsx)(wn,{className:"h-3 w-3"}),a.location]})]})]}),(0,y.jsx)("div",{className:"text-xs text-gray-500",children:a.time})]})},r)})})})]})}function yT({stats:e}){return(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(wi,{className:"h-4 w-4"}),"Dashboard Overview"]})}),(0,y.jsx)(dt,{className:"p-4",children:(0,y.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[e.revenue&&(0,y.jsxs)("div",{className:"p-3 rounded-lg bg-emerald-50 border border-emerald-100",children:[(0,y.jsx)("div",{className:"text-xs text-emerald-600 font-medium mb-1",children:"Revenue"}),(0,y.jsx)("div",{className:"text-lg font-bold text-emerald-700",children:ic(e.revenue.total)}),e.revenue.change!==0&&(0,y.jsxs)("div",{className:`text-xs ${e.revenue.change>0?"text-emerald-600":"text-red-600"}`,children:[e.revenue.change>0?"+":"",e.revenue.change,"% from last period"]})]}),e.subscriptions&&(0,y.jsxs)("div",{className:"p-3 rounded-lg bg-blue-50 border border-blue-100",children:[(0,y.jsx)("div",{className:"text-xs text-blue-600 font-medium mb-1",children:"Subscriptions"}),(0,y.jsxs)("div",{className:"text-lg font-bold text-blue-700",children:[e.subscriptions.active," active"]}),(0,y.jsxs)("div",{className:"text-xs text-blue-600",children:[e.subscriptions.total," total"]})]}),e.customers&&(0,y.jsxs)("div",{className:"p-3 rounded-lg bg-purple-50 border border-purple-100",children:[(0,y.jsx)("div",{className:"text-xs text-purple-600 font-medium mb-1",children:"Customers"}),(0,y.jsx)("div",{className:"text-lg font-bold text-purple-700",children:e.customers.total}),e.customers.new>0&&(0,y.jsxs)("div",{className:"text-xs text-purple-600",children:["+",e.customers.new," new this period"]})]}),e.transactions&&(0,y.jsxs)("div",{className:"p-3 rounded-lg bg-amber-50 border border-amber-100",children:[(0,y.jsx)("div",{className:"text-xs text-amber-600 font-medium mb-1",children:"Transactions"}),(0,y.jsxs)("div",{className:"text-lg font-bold text-amber-700",children:[e.transactions.successful," successful"]}),e.transactions.failed>0&&(0,y.jsxs)("div",{className:"text-xs text-red-600",children:[e.transactions.failed," failed"]})]})]})})]})}function vT({customers:e}){return e.length===0?(0,y.jsx)(ut,{className:"border-gray-200 shadow-sm bg-white",children:(0,y.jsxs)(dt,{className:"py-8 text-center",children:[(0,y.jsx)(xo,{className:"h-10 w-10 text-gray-300 mx-auto mb-3"}),(0,y.jsx)("p",{className:"text-sm text-gray-500",children:"No top customers data"})]})}):(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(xo,{className:"h-4 w-4 text-amber-500"}),"Top Customers"]})}),(0,y.jsx)(dt,{className:"p-0",children:(0,y.jsx)("div",{className:"divide-y divide-gray-100",children:e.map((t,a)=>(0,y.jsx)("div",{className:"px-4 py-3 hover:bg-gray-50 transition-colors",children:(0,y.jsxs)("div",{className:"flex items-center justify-between",children:[(0,y.jsxs)("div",{className:"flex items-center gap-3 min-w-0",children:[(0,y.jsx)("div",{className:`h-6 w-6 rounded-full flex items-center justify-center text-xs font-bold ${a===0?"bg-amber-100 text-amber-700":a===1?"bg-slate-100 text-slate-700":a===2?"bg-orange-100 text-orange-700":"bg-gray-100 text-gray-700"}`,children:a+1}),(0,y.jsxs)("div",{className:"min-w-0",children:[(0,y.jsx)("div",{className:"text-sm font-medium text-gray-900 truncate",children:t.name}),(0,y.jsx)("div",{className:"text-xs text-gray-500 truncate",children:t.email})]})]}),(0,y.jsx)("div",{className:"text-sm font-semibold text-emerald-600",children:typeof t.revenue=="number"?ic(t.revenue):t.revenue})]})},a))})})]})}function mS({type:e,data:t}){if(!t)return null;switch(e){case"subscription":return(0,y.jsx)(fT,{subscription:t});case"subscriptions":let a=t.subscriptions||t||[];return(0,y.jsx)(pT,{subscriptions:Array.isArray(a)?a:[a]});case"customer":return(0,y.jsx)(mT,{customer:t.customer||t});case"customers":let r=t.customers||t||[];return(0,y.jsx)(hT,{customers:Array.isArray(r)?r:[r]});case"transactions":let o=t.transactions||t||[];return(0,y.jsx)(pS,{transactions:Array.isArray(o)?o:[o]});case"transaction":return(0,y.jsx)(pS,{transactions:[t],maxItems:1});case"dashboard_stats":return(0,y.jsx)(yT,{stats:t});case"top_customers":let n=t.customers||t||[];return(0,y.jsx)(vT,{customers:Array.isArray(n)?n:[n]});case"api_keys":let s=t.api_keys||t||[];return(0,y.jsx)(gT,{apiKeys:Array.isArray(s)?s:[s]});case"sessions":let i=t.sessions||t||[];return(0,y.jsx)(xT,{sessions:Array.isArray(i)?i:[i]});default:return null}}var f=E(ue(),1),LT="http://localhost:5002",xS=340;function CT(e){return e.replace(/\\\\n/g,`
|
|
16
|
+
`),()=>{document.head.removeChild(d)}},[t]),(0,Xv.jsx)($p,{isPresent:t,childRef:r,sizeRef:o,children:Vu.cloneElement(e,{ref:r})})}var Zv=({children:e,initial:t,isPresent:a,onExitComplete:r,custom:o,presenceAffectsLayout:n,mode:s})=>{let i=An(Jb),l=(0,Lo.useId)(),u=(0,Lo.useCallback)(c=>{i.set(c,!0);for(let p of i.values())if(!p)return;r&&r()},[i,r]),d=(0,Lo.useMemo)(()=>({id:l,initial:t,isPresent:a,custom:o,onExitComplete:u,register:c=>(i.set(c,!1),()=>i.delete(c))}),n?[Math.random(),u]:[a,u]);return(0,Lo.useMemo)(()=>{i.forEach((c,p)=>i.set(p,!1))},[a]),Yv.useEffect(()=>{!a&&!i.size&&r&&r()},[a]),s==="popLayout"&&(e=(0,Xp.jsx)(Qv,{isPresent:a,children:e})),(0,Xp.jsx)(Mr.Provider,{value:d,children:e})};function Jb(){return new Map}var Nr=E(X(),1);function Uu(e=!0){let t=(0,Nr.useContext)(Mr);if(t===null)return[!0,null];let{isPresent:a,onExitComplete:r,register:o}=t,n=(0,Nr.useId)();(0,Nr.useEffect)(()=>{e&&o(n)},[e]);let s=(0,Nr.useCallback)(()=>e&&r&&r(n),[n,r,e]);return!a&&r?[!1,s]:[!0]}var _u=E(X(),1),Pi=e=>e.key||"";function Qp(e){let t=[];return _u.Children.forEach(e,a=>{(0,_u.isValidElement)(a)&&t.push(a)}),t}var zu=E(X(),1);var Dn=typeof window<"u";var Hu=Dn?zu.useLayoutEffect:zu.useEffect;var Yp=({children:e,custom:t,initial:a=!0,onExitComplete:r,presenceAffectsLayout:o=!0,mode:n="sync",propagate:s=!1})=>{let[i,l]=Uu(s),u=(0,Sa.useMemo)(()=>Qp(e),[e]),d=s&&!i?[]:u.map(Pi),c=(0,Sa.useRef)(!0),p=(0,Sa.useRef)(u),g=An(()=>new Map),[C,L]=(0,Sa.useState)(u),[S,h]=(0,Sa.useState)(u);Hu(()=>{c.current=!1,p.current=u;for(let I=0;I<S.length;I++){let k=Pi(S[I]);d.includes(k)?g.delete(k):g.get(k)!==!0&&g.set(k,!1)}},[S,d.length,d.join("-")]);let m=[];if(u!==C){let I=[...u];for(let k=0;k<S.length;k++){let T=S[k],R=Pi(T);d.includes(R)||(I.splice(k,0,T),m.push(T))}n==="wait"&&m.length&&(I=m),h(Qp(I)),L(u);return}let{forceRender:x}=(0,Sa.useContext)(Tn);return(0,Ti.jsx)(Ti.Fragment,{children:S.map(I=>{let k=Pi(I),T=s&&!i?!1:u===S||d.includes(k),R=()=>{if(g.has(k))g.set(k,!0);else return;let A=!0;g.forEach(V=>{V||(A=!1)}),A&&(x?.(),h(p.current),s&&l?.(),r&&r())};return(0,Ti.jsx)(Zv,{isPresent:T,initial:!c.current||a?void 0:!1,custom:T?void 0:t,presenceAffectsLayout:o,mode:n,onExitComplete:T?void 0:R,children:I},k)})})};var he=e=>e;var Qa=he,pa=he;function Co(e){let t;return()=>(t===void 0&&(t=e()),t)}var Ut=(e,t,a)=>{let r=t-e;return r===0?1:(a-e)/r};var Ee=e=>e*1e3,Je=e=>e/1e3;var Mn={skipAnimations:!1,useManualTiming:!1};function Jv(e){let t=new Set,a=new Set,r=!1,o=!1,n=new WeakSet,s={delta:0,timestamp:0,isProcessing:!1};function i(u){n.has(u)&&(l.schedule(u),e()),u(s)}let l={schedule:(u,d=!1,c=!1)=>{let g=c&&r?t:a;return d&&n.add(u),g.has(u)||g.add(u),u},cancel:u=>{a.delete(u),n.delete(u)},process:u=>{if(s=u,r){o=!0;return}r=!0,[t,a]=[a,t],t.forEach(i),t.clear(),r=!1,o&&(o=!1,l.process(u))}};return l}var qu=["read","resolveKeyframes","update","preRender","render","postRender"],eP=40;function Wu(e,t){let a=!1,r=!0,o={delta:0,timestamp:0,isProcessing:!1},n=()=>a=!0,s=qu.reduce((h,m)=>(h[m]=Jv(n),h),{}),{read:i,resolveKeyframes:l,update:u,preRender:d,render:c,postRender:p}=s,g=()=>{let h=Mn.useManualTiming?o.timestamp:performance.now();a=!1,o.delta=r?1e3/60:Math.max(Math.min(h-o.timestamp,eP),1),o.timestamp=h,o.isProcessing=!0,i.process(o),l.process(o),u.process(o),d.process(o),c.process(o),p.process(o),o.isProcessing=!1,a&&t&&(r=!1,e(g))},C=()=>{a=!0,r=!0,o.isProcessing||e(g)};return{schedule:qu.reduce((h,m)=>{let x=s[m];return h[m]=(I,k=!1,T=!1)=>(a||C(),x.schedule(I,k,T)),h},{}),cancel:h=>{for(let m=0;m<qu.length;m++)s[qu[m]].cancel(h)},state:o,steps:s}}var{schedule:J,cancel:_t,state:Fe,steps:Gu}=Wu(typeof requestAnimationFrame<"u"?requestAnimationFrame:he,!0);var e0=E(X(),1),ju=(0,e0.createContext)({strict:!1});var t0={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"]},Ya={};for(let e in t0)Ya[e]={isEnabled:t=>t0[e].some(a=>!!t[a])};function a0(e){for(let t in e)Ya[t]={...Ya[t],...e[t]}}var tP=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Ai(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||tP.has(e)}var r0=e=>!Ai(e);function aP(e){e&&(r0=t=>t.startsWith("on")?!Ai(t):e(t))}try{aP(BS("@emotion/is-prop-valid").default)}catch{}function o0(e,t,a){let r={};for(let o in e)o==="values"&&typeof e.values=="object"||(r0(o)||a===!0&&Ai(o)||!t&&!Ai(o)||e.draggable&&o.startsWith("onDrag"))&&(r[o]=e[o]);return r}function n0(e){if(typeof Proxy>"u")return e;let t=new Map,a=(...r)=>e(...r);return new Proxy(a,{get:(r,o)=>o==="create"?e:(t.has(o)||t.set(o,e(o)),t.get(o))})}var Zu=E(ue(),1);var Fn=E(X(),1);var s0=E(X(),1),Er=(0,s0.createContext)({});var Xu=E(X(),1);function Za(e){return typeof e=="string"||Array.isArray(e)}function Fr(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}var Ku=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Ri=["initial",...Ku];function So(e){return Fr(e.animate)||Ri.some(t=>Za(e[t]))}function $u(e){return!!(So(e)||e.variants)}function i0(e,t){if(So(e)){let{initial:a,animate:r}=e;return{initial:a===!1||Za(a)?a:void 0,animate:Za(r)?r:void 0}}return e.inherit!==!1?t:{}}function u0(e){let{initial:t,animate:a}=i0(e,(0,Xu.useContext)(Er));return(0,Xu.useMemo)(()=>({initial:t,animate:a}),[l0(t),l0(a)])}function l0(e){return Array.isArray(e)?e.join(" "):e}var d0=Symbol.for("motionComponentSymbol");var c0=E(X(),1);function Ja(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function f0(e,t,a){return(0,c0.useCallback)(r=>{r&&e.onMount&&e.onMount(r),t&&(r?t.mount(r):t.unmount()),a&&(typeof a=="function"?a(r):Ja(a)&&(a.current=r))},[t])}var bt=E(X(),1);var Nn=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase();var rP="framerAppearId",Qu="data-"+Nn(rP);var{schedule:En,cancel:ZM}=Wu(queueMicrotask,!1);var p0=E(X(),1),Yu=(0,p0.createContext)({});function m0(e,t,a,r,o){var n,s;let{visualElement:i}=(0,bt.useContext)(Er),l=(0,bt.useContext)(ju),u=(0,bt.useContext)(Mr),d=(0,bt.useContext)(Rn).reducedMotion,c=(0,bt.useRef)(null);r=r||l.renderer,!c.current&&r&&(c.current=r(e,{visualState:t,parent:i,props:a,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:d}));let p=c.current,g=(0,bt.useContext)(Yu);p&&!p.projection&&o&&(p.type==="html"||p.type==="svg")&&oP(c.current,a,o,g);let C=(0,bt.useRef)(!1);(0,bt.useInsertionEffect)(()=>{p&&C.current&&p.update(a,u)});let L=a[Qu],S=(0,bt.useRef)(!!L&&!(!((n=window.MotionHandoffIsComplete)===null||n===void 0)&&n.call(window,L))&&((s=window.MotionHasOptimisedAnimation)===null||s===void 0?void 0:s.call(window,L)));return Hu(()=>{p&&(C.current=!0,window.MotionIsMounted=!0,p.updateFeatures(),En.render(p.render),S.current&&p.animationState&&p.animationState.animateChanges())}),(0,bt.useEffect)(()=>{p&&(!S.current&&p.animationState&&p.animationState.animateChanges(),S.current&&(queueMicrotask(()=>{var h;(h=window.MotionHandoffMarkAsComplete)===null||h===void 0||h.call(window,L)}),S.current=!1))}),p}function oP(e,t,a,r){let{layoutId:o,layout:n,drag:s,dragConstraints:i,layoutScroll:l,layoutRoot:u}=t;e.projection=new a(e.latestValues,t["data-framer-portal-id"]?void 0:h0(e.parent)),e.projection.setOptions({layoutId:o,layout:n,alwaysMeasureLayout:!!s||i&&Ja(i),visualElement:e,animationType:typeof n=="string"?n:"both",initialPromotionConfig:r,layoutScroll:l,layoutRoot:u})}function h0(e){if(e)return e.options.allowProjection!==!1?e.projection:h0(e.parent)}function g0({preloadedFeatures:e,createVisualElement:t,useRender:a,useVisualState:r,Component:o}){var n,s;e&&a0(e);function i(u,d){let c,p={...(0,Fn.useContext)(Rn),...u,layoutId:nP(u)},{isStatic:g}=p,C=u0(u),L=r(u,g);if(!g&&Dn){sP(p,e);let S=iP(p);c=S.MeasureLayout,C.visualElement=m0(o,L,p,t,S.ProjectionNode)}return(0,Zu.jsxs)(Er.Provider,{value:C,children:[c&&C.visualElement?(0,Zu.jsx)(c,{visualElement:C.visualElement,...p}):null,a(o,u,f0(L,C.visualElement,d),L,g,C.visualElement)]})}i.displayName=`motion.${typeof o=="string"?o:`create(${(s=(n=o.displayName)!==null&&n!==void 0?n:o.name)!==null&&s!==void 0?s:""})`}`;let l=(0,Fn.forwardRef)(i);return l[d0]=o,l}function nP({layoutId:e}){let t=(0,Fn.useContext)(Tn).id;return t&&e!==void 0?t+"-"+e:e}function sP(e,t){let a=(0,Fn.useContext)(ju).strict}function iP(e){let{drag:t,layout:a}=Ya;if(!t&&!a)return{};let r={...t,...a};return{MeasureLayout:t?.isEnabled(e)||a?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}var x0=["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 Bn(e){return typeof e!="string"||e.includes("-")?!1:!!(x0.indexOf(e)>-1||/[A-Z]/u.test(e))}var Zp=E(X(),1);function y0(e){let t=[{},{}];return e?.values.forEach((a,r)=>{t[0][r]=a.get(),t[1][r]=a.getVelocity()}),t}function On(e,t,a,r){if(typeof t=="function"){let[o,n]=y0(r);t=t(a!==void 0?a:e.custom,o,n)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){let[o,n]=y0(r);t=t(a!==void 0?a:e.custom,o,n)}return t}var Di=e=>Array.isArray(e);var v0=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),L0=e=>Di(e)?e[e.length-1]||0:e;var ye=e=>!!(e&&e.getVelocity);function Vn(e){let t=ye(e)?e.get():e;return v0(t)?t.toValue():t}function lP({scrapeMotionValuesFromProps:e,createRenderState:t,onUpdate:a},r,o,n){let s={latestValues:uP(r,o,n,e),renderState:t()};return a&&(s.onMount=i=>a({props:r,current:i,...s}),s.onUpdate=i=>a(i)),s}var Ju=e=>(t,a)=>{let r=(0,Zp.useContext)(Er),o=(0,Zp.useContext)(Mr),n=()=>lP(e,t,r,o);return a?n():An(n)};function uP(e,t,a,r){let o={},n=r(e,{});for(let p in n)o[p]=Vn(n[p]);let{initial:s,animate:i}=e,l=So(e),u=$u(e);t&&u&&!l&&e.inherit!==!1&&(s===void 0&&(s=t.initial),i===void 0&&(i=t.animate));let d=a?a.initial===!1:!1;d=d||s===!1;let c=d?i:s;if(c&&typeof c!="boolean"&&!Fr(c)){let p=Array.isArray(c)?c:[c];for(let g=0;g<p.length;g++){let C=On(e,p[g]);if(C){let{transitionEnd:L,transition:S,...h}=C;for(let m in h){let x=h[m];if(Array.isArray(x)){let I=d?x.length-1:0;x=x[I]}x!==null&&(o[m]=x)}for(let m in L)o[m]=L[m]}}}return o}var Ia=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Pt=new Set(Ia);var C0=e=>t=>typeof t=="string"&&t.startsWith(e),ed=C0("--"),dP=C0("var(--"),Un=e=>dP(e)?cP.test(e.split("/*")[0].trim()):!1,cP=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;var td=(e,t)=>t&&typeof e=="number"?t.transform(e):e;var et=(e,t,a)=>a>t?t:a<e?e:a;var wa={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},er={...wa,transform:e=>et(0,1,e)},Mi={...wa,default:1};var Ni=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),ka=Ni("deg"),ht=Ni("%"),H=Ni("px"),S0=Ni("vh"),I0=Ni("vw"),Jp={...ht,parse:e=>ht.parse(e)/100,transform:e=>ht.transform(e*100)};var w0={borderWidth:H,borderTopWidth:H,borderRightWidth:H,borderBottomWidth:H,borderLeftWidth:H,borderRadius:H,radius:H,borderTopLeftRadius:H,borderTopRightRadius:H,borderBottomRightRadius:H,borderBottomLeftRadius:H,width:H,maxWidth:H,height:H,maxHeight:H,top:H,right:H,bottom:H,left:H,padding:H,paddingTop:H,paddingRight:H,paddingBottom:H,paddingLeft:H,margin:H,marginTop:H,marginRight:H,marginBottom:H,marginLeft:H,backgroundPositionX:H,backgroundPositionY:H};var k0={rotate:ka,rotateX:ka,rotateY:ka,rotateZ:ka,scale:Mi,scaleX:Mi,scaleY:Mi,scaleZ:Mi,skew:ka,skewX:ka,skewY:ka,distance:H,translateX:H,translateY:H,translateZ:H,x:H,y:H,z:H,perspective:H,transformPerspective:H,opacity:er,originX:Jp,originY:Jp,originZ:H};var em={...wa,transform:Math.round};var _n={...w0,...k0,zIndex:em,size:H,fillOpacity:er,strokeOpacity:er,numOctaves:em};var fP={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},pP=Ia.length;function b0(e,t,a){let r="",o=!0;for(let n=0;n<pP;n++){let s=Ia[n],i=e[s];if(i===void 0)continue;let l=!0;if(typeof i=="number"?l=i===(s.startsWith("scale")?1:0):l=parseFloat(i)===0,!l||a){let u=td(i,_n[s]);if(!l){o=!1;let d=fP[s]||s;r+=`${d}(${u}) `}a&&(t[s]=u)}}return r=r.trim(),a?r=a(t,o?"":r):o&&(r="none"),r}function zn(e,t,a){let{style:r,vars:o,transformOrigin:n}=e,s=!1,i=!1;for(let l in t){let u=t[l];if(Pt.has(l)){s=!0;continue}else if(ed(l)){o[l]=u;continue}else{let d=td(u,_n[l]);l.startsWith("origin")?(i=!0,n[l]=d):r[l]=d}}if(t.transform||(s||a?r.transform=b0(t,e.transform,a):r.transform&&(r.transform="none")),i){let{originX:l="50%",originY:u="50%",originZ:d=0}=n;r.transformOrigin=`${l} ${u} ${d}`}}var mP={offset:"stroke-dashoffset",array:"stroke-dasharray"},hP={offset:"strokeDashoffset",array:"strokeDasharray"};function P0(e,t,a=1,r=0,o=!0){e.pathLength=1;let n=o?mP:hP;e[n.offset]=H.transform(-r);let s=H.transform(t),i=H.transform(a);e[n.array]=`${s} ${i}`}function T0(e,t,a){return typeof e=="string"?e:H.transform(t+a*e)}function A0(e,t,a){let r=T0(t,e.x,e.width),o=T0(a,e.y,e.height);return`${r} ${o}`}function Hn(e,{attrX:t,attrY:a,attrScale:r,originX:o,originY:n,pathLength:s,pathSpacing:i=1,pathOffset:l=0,...u},d,c){if(zn(e,u,c),d){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};let{attrs:p,style:g,dimensions:C}=e;p.transform&&(C&&(g.transform=p.transform),delete p.transform),C&&(o!==void 0||n!==void 0||g.transform)&&(g.transformOrigin=A0(C,o!==void 0?o:.5,n!==void 0?n:.5)),t!==void 0&&(p.x=t),a!==void 0&&(p.y=a),r!==void 0&&(p.scale=r),s!==void 0&&P0(p,s,i,l,!1)}var qn=()=>({style:{},transform:{},transformOrigin:{},vars:{}});var ad=()=>({...qn(),attrs:{}});var Wn=e=>typeof e=="string"&&e.toLowerCase()==="svg";function rd(e,{style:t,vars:a},r,o){Object.assign(e.style,t,o&&o.getProjectionStyles(r));for(let n in a)e.style.setProperty(n,a[n])}var od=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"]);function nd(e,t,a,r){rd(e,t,void 0,r);for(let o in t.attrs)e.setAttribute(od.has(o)?o:Nn(o),t.attrs[o])}var Gn={};function R0(e){Object.assign(Gn,e)}function sd(e,{layout:t,layoutId:a}){return Pt.has(e)||e.startsWith("origin")||(t||a!==void 0)&&(!!Gn[e]||e==="opacity")}function jn(e,t,a){var r;let{style:o}=e,n={};for(let s in o)(ye(o[s])||t.style&&ye(t.style[s])||sd(s,e)||((r=a?.getValue(s))===null||r===void 0?void 0:r.liveStyle)!==void 0)&&(n[s]=o[s]);return n}function id(e,t,a){let r=jn(e,t,a);for(let o in e)if(ye(e[o])||ye(t[o])){let n=Ia.indexOf(o)!==-1?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o;r[n]=e[o]}return r}function gP(e,t){try{t.dimensions=typeof e.getBBox=="function"?e.getBBox():e.getBoundingClientRect()}catch{t.dimensions={x:0,y:0,width:0,height:0}}}var D0=["x","y","width","height","cx","cy","r"],M0={useVisualState:Ju({scrapeMotionValuesFromProps:id,createRenderState:ad,onUpdate:({props:e,prevProps:t,current:a,renderState:r,latestValues:o})=>{if(!a)return;let n=!!e.drag;if(!n){for(let i in o)if(Pt.has(i)){n=!0;break}}if(!n)return;let s=!t;if(t)for(let i=0;i<D0.length;i++){let l=D0[i];e[l]!==t[l]&&(s=!0)}s&&J.read(()=>{gP(a,r),J.render(()=>{Hn(r,o,Wn(a.tagName),e.transformTemplate),nd(a,r)})})}})};var N0={useVisualState:Ju({scrapeMotionValuesFromProps:jn,createRenderState:qn})};var Kn=E(X(),1);var E0=E(X(),1);function tm(e,t,a){for(let r in t)!ye(t[r])&&!sd(r,a)&&(e[r]=t[r])}function xP({transformTemplate:e},t){return(0,E0.useMemo)(()=>{let a=qn();return zn(a,t,e),Object.assign({},a.vars,a.style)},[t])}function yP(e,t){let a=e.style||{},r={};return tm(r,a,e),Object.assign(r,xP(e,t)),r}function F0(e,t){let a={},r=yP(e,t);return e.drag&&e.dragListener!==!1&&(a.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(a.tabIndex=0),a.style=r,a}var B0=E(X(),1);function O0(e,t,a,r){let o=(0,B0.useMemo)(()=>{let n=ad();return Hn(n,t,Wn(r),e.transformTemplate),{...n.attrs,style:{...n.style}}},[t]);if(e.style){let n={};tm(n,e.style,e),o.style={...n,...o.style}}return o}function V0(e=!1){return(a,r,o,{latestValues:n},s)=>{let l=(Bn(a)?O0:F0)(r,n,s,a),u=o0(r,typeof a=="string",e),d=a!==Kn.Fragment?{...u,...l,ref:o}:{},{children:c}=r,p=(0,Kn.useMemo)(()=>ye(c)?c.get():c,[c]);return(0,Kn.createElement)(a,{...d,children:p})}}function U0(e,t){return function(r,{forwardMotionProps:o}={forwardMotionProps:!1}){let s={...Bn(r)?M0:N0,preloadedFeatures:e,useRender:V0(o),createVisualElement:t,Component:r};return g0(s)}}function am(e,t){if(!Array.isArray(t))return!1;let a=t.length;if(a!==e.length)return!1;for(let r=0;r<a;r++)if(t[r]!==e[r])return!1;return!0}function Br(e,t,a){let r=e.getProps();return On(r,t,a!==void 0?a:r.custom,e)}var rm=Co(()=>window.ScrollTimeline!==void 0);var Ei=class{constructor(t){this.stop=()=>this.runAll("stop"),this.animations=t.filter(Boolean)}get finished(){return Promise.all(this.animations.map(t=>"finished"in t?t.finished:t))}getAll(t){return this.animations[0][t]}setAll(t,a){for(let r=0;r<this.animations.length;r++)this.animations[r][t]=a}attachTimeline(t,a){let r=this.animations.map(o=>{if(rm()&&o.attachTimeline)return o.attachTimeline(t);if(typeof a=="function")return a(o)});return()=>{r.forEach((o,n)=>{o&&o(),this.animations[n].stop()})}}get time(){return this.getAll("time")}set time(t){this.setAll("time",t)}get speed(){return this.getAll("speed")}set speed(t){this.setAll("speed",t)}get startTime(){return this.getAll("startTime")}get duration(){let t=0;for(let a=0;a<this.animations.length;a++)t=Math.max(t,this.animations[a].duration);return t}runAll(t){this.animations.forEach(a=>a[t]())}flatten(){this.runAll("flatten")}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}};var Fi=class extends Ei{then(t,a){return Promise.all(this.animations).then(t).catch(a)}};function Or(e,t){return e?e[t]||e.default||e:void 0}function $n(e){let t=0,a=50,r=e.next(t);for(;!r.done&&t<2e4;)t+=a,r=e.next(t);return t>=2e4?1/0:t}function Vr(e){return typeof e=="function"}function Bi(e,t){e.timeline=t,e.onfinish=null}var Xn=e=>Array.isArray(e)&&typeof e[0]=="number";var nm={linearEasing:void 0};function _0(e,t){let a=Co(e);return()=>{var r;return(r=nm[t])!==null&&r!==void 0?r:a()}}var Ur=_0(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing");var Oi=(e,t,a=10)=>{let r="",o=Math.max(Math.round(t/a),2);for(let n=0;n<o;n++)r+=e(Ut(0,o-1,n))+", ";return`linear(${r.substring(0,r.length-2)})`};function ud(e){return!!(typeof e=="function"&&Ur()||!e||typeof e=="string"&&(e in ld||Ur())||Xn(e)||Array.isArray(e)&&e.every(ud))}var Qn=([e,t,a,r])=>`cubic-bezier(${e}, ${t}, ${a}, ${r})`,ld={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Qn([0,.65,.55,1]),circOut:Qn([.55,0,1,.45]),backIn:Qn([.31,.01,.66,-.59]),backOut:Qn([.33,1.53,.69,.99])};function Yn(e,t){if(e)return typeof e=="function"&&Ur()?Oi(e,t):Xn(e)?Qn(e):Array.isArray(e)?e.map(a=>Yn(a,t)||ld.easeOut):ld[e]}var zt={x:!1,y:!1};function Zn(){return zt.x||zt.y}function sm(e,t,a){var r;if(e instanceof Element)return[e];if(typeof e=="string"){let o=document;t&&(o=t.current);let n=(r=a?.[e])!==null&&r!==void 0?r:o.querySelectorAll(e);return n?Array.from(n):[]}return Array.from(e)}function dd(e,t){let a=sm(e),r=new AbortController,o={passive:!0,...t,signal:r.signal};return[a,o,()=>r.abort()]}function z0(e){return t=>{t.pointerType==="touch"||Zn()||e(t)}}function im(e,t,a={}){let[r,o,n]=dd(e,a),s=z0(i=>{let{target:l}=i,u=t(i);if(typeof u!="function"||!l)return;let d=z0(c=>{u(c),l.removeEventListener("pointerleave",d)});l.addEventListener("pointerleave",d,o)});return r.forEach(i=>{i.addEventListener("pointerenter",s,o)}),n}var cd=(e,t)=>t?e===t?!0:cd(e,t.parentElement):!1;var Io=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;var vP=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function H0(e){return vP.has(e.tagName)||e.tabIndex!==-1}var wo=new WeakSet;function q0(e){return t=>{t.key==="Enter"&&e(t)}}function lm(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}var W0=(e,t)=>{let a=e.currentTarget;if(!a)return;let r=q0(()=>{if(wo.has(a))return;lm(a,"down");let o=q0(()=>{lm(a,"up")}),n=()=>lm(a,"cancel");a.addEventListener("keyup",o,t),a.addEventListener("blur",n,t)});a.addEventListener("keydown",r,t),a.addEventListener("blur",()=>a.removeEventListener("keydown",r),t)};function G0(e){return Io(e)&&!Zn()}function um(e,t,a={}){let[r,o,n]=dd(e,a),s=i=>{let l=i.currentTarget;if(!G0(i)||wo.has(l))return;wo.add(l);let u=t(i),d=(g,C)=>{window.removeEventListener("pointerup",c),window.removeEventListener("pointercancel",p),!(!G0(g)||!wo.has(l))&&(wo.delete(l),typeof u=="function"&&u(g,{success:C}))},c=g=>{d(g,a.useGlobalTarget||cd(l,g.target))},p=g=>{d(g,!1)};window.addEventListener("pointerup",c,o),window.addEventListener("pointercancel",p,o)};return r.forEach(i=>{!H0(i)&&i.getAttribute("tabindex")===null&&(i.tabIndex=0),(a.useGlobalTarget?window:i).addEventListener("pointerdown",s,o),i.addEventListener("focus",u=>W0(u,o),o)}),n}function dm(e){return e==="x"||e==="y"?zt[e]?null:(zt[e]=!0,()=>{zt[e]=!1}):zt.x||zt.y?null:(zt.x=zt.y=!0,()=>{zt.x=zt.y=!1})}var fd=new Set(["width","height","top","left","right","bottom",...Ia]);var pd;function CP(){pd=void 0}var lt={now:()=>(pd===void 0&<.set(Fe.isProcessing||Mn.useManualTiming?Fe.timestamp:performance.now()),pd),set:e=>{pd=e,queueMicrotask(CP)}};function Jn(e,t){e.indexOf(t)===-1&&e.push(t)}function es(e,t){let a=e.indexOf(t);a>-1&&e.splice(a,1)}var _r=class{constructor(){this.subscriptions=[]}add(t){return Jn(this.subscriptions,t),()=>es(this.subscriptions,t)}notify(t,a,r){let o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](t,a,r);else for(let n=0;n<o;n++){let s=this.subscriptions[n];s&&s(t,a,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}};function md(e,t){return t?e*(1e3/t):0}var K0=30,SP=e=>!isNaN(parseFloat(e)),$0={current:void 0},cm=class{constructor(t,a={}){this.version="11.18.2",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(r,o=!0)=>{let n=lt.now();this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),o&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(t),this.owner=a.owner}setCurrent(t){this.current=t,this.updatedAt=lt.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=SP(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,a){this.events[t]||(this.events[t]=new _r);let r=this.events[t].add(a);return t==="change"?()=>{r(),J.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(let t in this.events)this.events[t].clear()}attach(t,a){this.passiveEffect=t,this.stopPassiveEffect=a}set(t,a=!0){!a||!this.passiveEffect?this.updateAndNotify(t,a):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,a,r){this.set(a),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,a=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,a&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return $0.current&&$0.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){let t=lt.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>K0)return 0;let a=Math.min(this.updatedAt-this.prevUpdatedAt,K0);return md(parseFloat(this.current)-parseFloat(this.prevFrameValue),a)}start(t){return this.stop(),new Promise(a=>{this.hasAnimated=!0,this.animation=t(a),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function tr(e,t){return new cm(e,t)}function IP(e,t,a){e.hasValue(t)?e.getValue(t).set(a):e.addValue(t,tr(a))}function X0(e,t){let a=Br(e,t),{transitionEnd:r={},transition:o={},...n}=a||{};n={...n,...r};for(let s in n){let i=L0(n[s]);IP(e,s,i)}}function Q0(e){return!!(ye(e)&&e.add)}function Vi(e,t){let a=e.getValue("willChange");if(Q0(a))return a.add(t)}function hd(e){return e.props[Qu]}var gd={current:!1};var Y0=(e,t,a)=>(((1-3*a+3*t)*e+(3*a-6*t))*e+3*t)*e,wP=1e-7,kP=12;function bP(e,t,a,r,o){let n,s,i=0;do s=t+(a-t)/2,n=Y0(s,r,o)-e,n>0?a=s:t=s;while(Math.abs(n)>wP&&++i<kP);return s}function zr(e,t,a,r){if(e===t&&a===r)return he;let o=n=>bP(n,0,1,e,a);return n=>n===0||n===1?n:Y0(o(n),t,r)}var xd=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2;var yd=e=>t=>1-e(1-t);var fm=zr(.33,1.53,.69,.99),Ui=yd(fm),vd=xd(Ui);var Ld=e=>(e*=2)<1?.5*Ui(e):.5*(2-Math.pow(2,-10*(e-1)));var Cd=e=>1-Math.sin(Math.acos(e)),Sd=yd(Cd),Id=xd(Cd);var wd=e=>/^0[^.\s]+$/u.test(e);function Z0(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||wd(e):!0}var Hr=e=>Math.round(e*1e5)/1e5;var ts=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function J0(e){return e==null}var eL=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu;var as=(e,t)=>a=>!!(typeof a=="string"&&eL.test(a)&&a.startsWith(e)||t&&!J0(a)&&Object.prototype.hasOwnProperty.call(a,t)),kd=(e,t,a)=>r=>{if(typeof r!="string")return r;let[o,n,s,i]=r.match(ts);return{[e]:parseFloat(o),[t]:parseFloat(n),[a]:parseFloat(s),alpha:i!==void 0?parseFloat(i):1}};var PP=e=>et(0,255,e),pm={...wa,transform:e=>Math.round(PP(e))},ba={test:as("rgb","red"),parse:kd("red","green","blue"),transform:({red:e,green:t,blue:a,alpha:r=1})=>"rgba("+pm.transform(e)+", "+pm.transform(t)+", "+pm.transform(a)+", "+Hr(er.transform(r))+")"};function TP(e){let t="",a="",r="",o="";return e.length>5?(t=e.substring(1,3),a=e.substring(3,5),r=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),a=e.substring(2,3),r=e.substring(3,4),o=e.substring(4,5),t+=t,a+=a,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(a,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}}var _i={test:as("#"),parse:TP,transform:ba.transform};var qr={test:as("hsl","hue"),parse:kd("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:a,alpha:r=1})=>"hsla("+Math.round(e)+", "+ht.transform(Hr(t))+", "+ht.transform(Hr(a))+", "+Hr(er.transform(r))+")"};var Ue={test:e=>ba.test(e)||_i.test(e)||qr.test(e),parse:e=>ba.test(e)?ba.parse(e):qr.test(e)?qr.parse(e):_i.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?ba.transform(e):qr.transform(e)};var tL=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function AP(e){var t,a;return isNaN(e)&&typeof e=="string"&&(((t=e.match(ts))===null||t===void 0?void 0:t.length)||0)+(((a=e.match(tL))===null||a===void 0?void 0:a.length)||0)>0}var rL="number",oL="color",RP="var",DP="var(",aL="${}",MP=/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(),a=[],r={color:[],number:[],var:[]},o=[],n=0,i=t.replace(MP,l=>(Ue.test(l)?(r.color.push(n),o.push(oL),a.push(Ue.parse(l))):l.startsWith(DP)?(r.var.push(n),o.push(RP),a.push(l)):(r.number.push(n),o.push(rL),a.push(parseFloat(l))),++n,aL)).split(aL);return{values:a,split:i,indexes:r,types:o}}function nL(e){return ko(e).values}function sL(e){let{split:t,types:a}=ko(e),r=t.length;return o=>{let n="";for(let s=0;s<r;s++)if(n+=t[s],o[s]!==void 0){let i=a[s];i===rL?n+=Hr(o[s]):i===oL?n+=Ue.transform(o[s]):n+=o[s]}return n}}var NP=e=>typeof e=="number"?0:e;function EP(e){let t=nL(e);return sL(e)(t.map(NP))}var gt={test:AP,parse:nL,createTransformer:sL,getAnimatableNone:EP};var FP=new Set(["brightness","contrast","saturate","opacity"]);function BP(e){let[t,a]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;let[r]=a.match(ts)||[];if(!r)return e;let o=a.replace(r,""),n=FP.has(t)?1:0;return r!==a&&(n*=100),t+"("+n+o+")"}var OP=/\b([a-z-]*)\(.*?\)/gu,zi={...gt,getAnimatableNone:e=>{let t=e.match(OP);return t?t.map(BP).join(" "):e}};var VP={..._n,color:Ue,backgroundColor:Ue,outlineColor:Ue,fill:Ue,stroke:Ue,borderColor:Ue,borderTopColor:Ue,borderRightColor:Ue,borderBottomColor:Ue,borderLeftColor:Ue,filter:zi,WebkitFilter:zi},rs=e=>VP[e];function bd(e,t){let a=rs(e);return a!==zi&&(a=gt),a.getAnimatableNone?a.getAnimatableNone(t):void 0}var UP=new Set(["auto","none","0"]);function iL(e,t,a){let r=0,o;for(;r<e.length&&!o;){let n=e[r];typeof n=="string"&&!UP.has(n)&&ko(n).values.length&&(o=e[r]),r++}if(o&&a)for(let n of t)e[n]=bd(a,o)}var mm=e=>e===wa||e===H,lL=(e,t)=>parseFloat(e.split(", ")[t]),uL=(e,t)=>(a,{transform:r})=>{if(r==="none"||!r)return 0;let o=r.match(/^matrix3d\((.+)\)$/u);if(o)return lL(o[1],t);{let n=r.match(/^matrix\((.+)\)$/u);return n?lL(n[1],e):0}},_P=new Set(["x","y","z"]),zP=Ia.filter(e=>!_P.has(e));function dL(e){let t=[];return zP.forEach(a=>{let r=e.getValue(a);r!==void 0&&(t.push([a,r.get()]),r.set(a.startsWith("scale")?1:0))}),t}var bo={width:({x:e},{paddingLeft:t="0",paddingRight:a="0"})=>e.max-e.min-parseFloat(t)-parseFloat(a),height:({y:e},{paddingTop:t="0",paddingBottom:a="0"})=>e.max-e.min-parseFloat(t)-parseFloat(a),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:uL(4,13),y:uL(5,14)};bo.translateX=bo.x;bo.translateY=bo.y;var Po=new Set,hm=!1,gm=!1;function cL(){if(gm){let e=Array.from(Po).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),a=new Map;t.forEach(r=>{let o=dL(r);o.length&&(a.set(r,o),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();let o=a.get(r);o&&o.forEach(([n,s])=>{var i;(i=r.getValue(n))===null||i===void 0||i.set(s)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}gm=!1,hm=!1,Po.forEach(e=>e.complete()),Po.clear()}function fL(){Po.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(gm=!0)})}function pL(){fL(),cL()}var Wr=class{constructor(t,a,r,o,n,s=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...t],this.onComplete=a,this.name=r,this.motionValue=o,this.element=n,this.isAsync=s}scheduleResolve(){this.isScheduled=!0,this.isAsync?(Po.add(this),hm||(hm=!0,J.read(fL),J.resolveKeyframes(cL))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:t,name:a,element:r,motionValue:o}=this;for(let n=0;n<t.length;n++)if(t[n]===null)if(n===0){let s=o?.get(),i=t[t.length-1];if(s!==void 0)t[0]=s;else if(r&&a){let l=r.readValue(a,i);l!=null&&(t[0]=l)}t[0]===void 0&&(t[0]=i),o&&s===void 0&&o.set(t[0])}else t[n]=t[n-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),Po.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,Po.delete(this))}resume(){this.isComplete||this.scheduleResolve()}};var Pd=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);var HP=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function qP(e){let t=HP.exec(e);if(!t)return[,];let[,a,r,o]=t;return[`--${a??r}`,o]}var WP=4;function xm(e,t,a=1){pa(a<=WP,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);let[r,o]=qP(e);if(!r)return;let n=window.getComputedStyle(t).getPropertyValue(r);if(n){let s=n.trim();return Pd(s)?parseFloat(s):s}return Un(o)?xm(o,t,a+1):o}var Td=e=>t=>t.test(e);var mL={test:e=>e==="auto",parse:e=>e};var ym=[wa,H,ht,ka,I0,S0,mL],vm=e=>ym.find(Td(e));var os=class extends Wr{constructor(t,a,r,o,n){super(t,a,r,o,n,!0)}readKeyframes(){let{unresolvedKeyframes:t,element:a,name:r}=this;if(!a||!a.current)return;super.readKeyframes();for(let l=0;l<t.length;l++){let u=t[l];if(typeof u=="string"&&(u=u.trim(),Un(u))){let d=xm(u,a.current);d!==void 0&&(t[l]=d),l===t.length-1&&(this.finalKeyframe=u)}}if(this.resolveNoneKeyframes(),!fd.has(r)||t.length!==2)return;let[o,n]=t,s=vm(o),i=vm(n);if(s!==i)if(mm(s)&&mm(i))for(let l=0;l<t.length;l++){let u=t[l];typeof u=="string"&&(t[l]=parseFloat(u))}else this.needsMeasurement=!0}resolveNoneKeyframes(){let{unresolvedKeyframes:t,name:a}=this,r=[];for(let o=0;o<t.length;o++)Z0(t[o])&&r.push(o);r.length&&iL(t,r,a)}measureInitialState(){let{element:t,unresolvedKeyframes:a,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=bo[r](t.measureViewportBox(),window.getComputedStyle(t.current)),a[0]=this.measuredOrigin;let o=a[a.length-1];o!==void 0&&t.getValue(r,o).jump(o,!1)}measureEndState(){var t;let{element:a,name:r,unresolvedKeyframes:o}=this;if(!a||!a.current)return;let n=a.getValue(r);n&&n.jump(this.measuredOrigin,!1);let s=o.length-1,i=o[s];o[s]=bo[r](a.measureViewportBox(),window.getComputedStyle(a.current)),i!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=i),!((t=this.removedTransforms)===null||t===void 0)&&t.length&&this.removedTransforms.forEach(([l,u])=>{a.getValue(l).set(u)}),this.resolveNoneKeyframes()}};var Lm=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(gt.test(e)||e==="0")&&!e.startsWith("url("));function GP(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 hL(e,t,a,r){let o=e[0];if(o===null)return!1;if(t==="display"||t==="visibility")return!0;let n=e[e.length-1],s=Lm(o,t),i=Lm(n,t);return Qa(s===i,`You are trying to animate ${t} from "${o}" to "${n}". ${o} is not an animatable value - to enable this animation set ${o} to a value animatable to ${n} via the \`style\` property.`),!s||!i?!1:GP(e)||(a==="spring"||Vr(a))&&r}var jP=e=>e!==null;function Gr(e,{repeat:t,repeatType:a="loop"},r){let o=e.filter(jP),n=t&&a!=="loop"&&t%2===1?0:o.length-1;return!n||r===void 0?o[n]:r}var KP=40,ns=class{constructor({autoplay:t=!0,delay:a=0,type:r="keyframes",repeat:o=0,repeatDelay:n=0,repeatType:s="loop",...i}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=lt.now(),this.options={autoplay:t,delay:a,type:r,repeat:o,repeatDelay:n,repeatType:s,...i},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt?this.resolvedAt-this.createdAt>KP?this.resolvedAt:this.createdAt:this.createdAt}get resolved(){return!this._resolved&&!this.hasAttemptedResolve&&pL(),this._resolved}onKeyframesResolved(t,a){this.resolvedAt=lt.now(),this.hasAttemptedResolve=!0;let{name:r,type:o,velocity:n,delay:s,onComplete:i,onUpdate:l,isGenerator:u}=this.options;if(!u&&!hL(t,r,o,n))if(gd.current||!s){l&&l(Gr(t,this.options,a)),i&&i(),this.resolveFinishedPromise();return}else this.options.duration=0;let d=this.initPlayback(t,a);d!==!1&&(this._resolved={keyframes:t,finalKeyframe:a,...d},this.onPostResolved())}onPostResolved(){}then(t,a){return this.currentFinishedPromise.then(t,a)}flatten(){this.options.type="keyframes",this.options.ease="linear"}updateFinishedPromise(){this.currentFinishedPromise=new Promise(t=>{this.resolveFinishedPromise=t})}};var ne=(e,t,a)=>e+(t-e)*a;function Cm(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 gL({hue:e,saturation:t,lightness:a,alpha:r}){e/=360,t/=100,a/=100;let o=0,n=0,s=0;if(!t)o=n=s=a;else{let i=a<.5?a*(1+t):a+t-a*t,l=2*a-i;o=Cm(l,i,e+1/3),n=Cm(l,i,e),s=Cm(l,i,e-1/3)}return{red:Math.round(o*255),green:Math.round(n*255),blue:Math.round(s*255),alpha:r}}function ss(e,t){return a=>a>0?t:e}var Sm=(e,t,a)=>{let r=e*e,o=a*(t*t-r)+r;return o<0?0:Math.sqrt(o)},$P=[_i,ba,qr],XP=e=>$P.find(t=>t.test(e));function xL(e){let t=XP(e);if(Qa(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`),!t)return!1;let a=t.parse(e);return t===qr&&(a=gL(a)),a}var Im=(e,t)=>{let a=xL(e),r=xL(t);if(!a||!r)return ss(e,t);let o={...a};return n=>(o.red=Sm(a.red,r.red,n),o.green=Sm(a.green,r.green,n),o.blue=Sm(a.blue,r.blue,n),o.alpha=ne(a.alpha,r.alpha,n),ba.transform(o))};var QP=(e,t)=>a=>t(e(a)),Pa=(...e)=>e.reduce(QP);var Ad=new Set(["none","hidden"]);function yL(e,t){return Ad.has(e)?a=>a<=0?e:t:a=>a>=1?t:e}function YP(e,t){return a=>ne(e,t,a)}function Rd(e){return typeof e=="number"?YP:typeof e=="string"?Un(e)?ss:Ue.test(e)?Im:e1:Array.isArray(e)?vL:typeof e=="object"?Ue.test(e)?Im:ZP:ss}function vL(e,t){let a=[...e],r=a.length,o=e.map((n,s)=>Rd(n)(n,t[s]));return n=>{for(let s=0;s<r;s++)a[s]=o[s](n);return a}}function ZP(e,t){let a={...e,...t},r={};for(let o in a)e[o]!==void 0&&t[o]!==void 0&&(r[o]=Rd(e[o])(e[o],t[o]));return o=>{for(let n in r)a[n]=r[n](o);return a}}function JP(e,t){var a;let r=[],o={color:0,var:0,number:0};for(let n=0;n<t.values.length;n++){let s=t.types[n],i=e.indexes[s][o[s]],l=(a=e.values[i])!==null&&a!==void 0?a:0;r[n]=l,o[s]++}return r}var e1=(e,t)=>{let a=gt.createTransformer(t),r=ko(e),o=ko(t);return r.indexes.var.length===o.indexes.var.length&&r.indexes.color.length===o.indexes.color.length&&r.indexes.number.length>=o.indexes.number.length?Ad.has(e)&&!o.values.length||Ad.has(t)&&!r.values.length?yL(e,t):Pa(vL(JP(r,o),o.values),a):(Qa(!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.`),ss(e,t))};function Dd(e,t,a){return typeof e=="number"&&typeof t=="number"&&typeof a=="number"?ne(e,t,a):Rd(e)(e,t)}var t1=5;function Md(e,t,a){let r=Math.max(t-t1,0);return md(a-e(r),t-r)}var Se={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};var wm=.001;function LL({duration:e=Se.duration,bounce:t=Se.bounce,velocity:a=Se.velocity,mass:r=Se.mass}){let o,n;Qa(e<=Ee(Se.maxDuration),"Spring duration must be 10 seconds or less");let s=1-t;s=et(Se.minDamping,Se.maxDamping,s),e=et(Se.minDuration,Se.maxDuration,Je(e)),s<1?(o=u=>{let d=u*s,c=d*e,p=d-a,g=Nd(u,s),C=Math.exp(-c);return wm-p/g*C},n=u=>{let c=u*s*e,p=c*a+a,g=Math.pow(s,2)*Math.pow(u,2)*e,C=Math.exp(-c),L=Nd(Math.pow(u,2),s);return(-o(u)+wm>0?-1:1)*((p-g)*C)/L}):(o=u=>{let d=Math.exp(-u*e),c=(u-a)*e+1;return-wm+d*c},n=u=>{let d=Math.exp(-u*e),c=(a-u)*(e*e);return d*c});let i=5/e,l=r1(o,n,i);if(e=Ee(e),isNaN(l))return{stiffness:Se.stiffness,damping:Se.damping,duration:e};{let u=Math.pow(l,2)*r;return{stiffness:u,damping:s*2*Math.sqrt(r*u),duration:e}}}var a1=12;function r1(e,t,a){let r=a;for(let o=1;o<a1;o++)r=r-e(r)/t(r);return r}function Nd(e,t){return e*Math.sqrt(1-t*t)}var o1=["duration","bounce"],n1=["stiffness","damping","mass"];function CL(e,t){return t.some(a=>e[a]!==void 0)}function s1(e){let t={velocity:Se.velocity,stiffness:Se.stiffness,damping:Se.damping,mass:Se.mass,isResolvedFromDuration:!1,...e};if(!CL(e,n1)&&CL(e,o1))if(e.visualDuration){let a=e.visualDuration,r=2*Math.PI/(a*1.2),o=r*r,n=2*et(.05,1,1-(e.bounce||0))*Math.sqrt(o);t={...t,mass:Se.mass,stiffness:o,damping:n}}else{let a=LL(e);t={...t,...a,mass:Se.mass},t.isResolvedFromDuration=!0}return t}function Ed(e=Se.visualDuration,t=Se.bounce){let a=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e,{restSpeed:r,restDelta:o}=a,n=a.keyframes[0],s=a.keyframes[a.keyframes.length-1],i={done:!1,value:n},{stiffness:l,damping:u,mass:d,duration:c,velocity:p,isResolvedFromDuration:g}=s1({...a,velocity:-Je(a.velocity||0)}),C=p||0,L=u/(2*Math.sqrt(l*d)),S=s-n,h=Je(Math.sqrt(l/d)),m=Math.abs(S)<5;r||(r=m?Se.restSpeed.granular:Se.restSpeed.default),o||(o=m?Se.restDelta.granular:Se.restDelta.default);let x;if(L<1){let k=Nd(h,L);x=T=>{let R=Math.exp(-L*h*T);return s-R*((C+L*h*S)/k*Math.sin(k*T)+S*Math.cos(k*T))}}else if(L===1)x=k=>s-Math.exp(-h*k)*(S+(C+h*S)*k);else{let k=h*Math.sqrt(L*L-1);x=T=>{let R=Math.exp(-L*h*T),A=Math.min(k*T,300);return s-R*((C+L*h*S)*Math.sinh(A)+k*S*Math.cosh(A))/k}}let I={calculatedDuration:g&&c||null,next:k=>{let T=x(k);if(g)i.done=k>=c;else{let R=0;L<1&&(R=k===0?Ee(C):Md(x,k,T));let A=Math.abs(R)<=r,V=Math.abs(s-T)<=o;i.done=A&&V}return i.value=i.done?s:T,i},toString:()=>{let k=Math.min($n(I),2e4),T=Oi(R=>I.next(k*R).value,k,30);return k+"ms "+T}};return I}function km({keyframes:e,velocity:t=0,power:a=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:n=500,modifyTarget:s,min:i,max:l,restDelta:u=.5,restSpeed:d}){let c=e[0],p={done:!1,value:c},g=A=>i!==void 0&&A<i||l!==void 0&&A>l,C=A=>i===void 0?l:l===void 0||Math.abs(i-A)<Math.abs(l-A)?i:l,L=a*t,S=c+L,h=s===void 0?S:s(S);h!==S&&(L=h-c);let m=A=>-L*Math.exp(-A/r),x=A=>h+m(A),I=A=>{let V=m(A),U=x(A);p.done=Math.abs(V)<=u,p.value=p.done?h:U},k,T,R=A=>{g(p.value)&&(k=A,T=Ed({keyframes:[p.value,C(p.value)],velocity:Md(x,A,p.value),damping:o,stiffness:n,restDelta:u,restSpeed:d}))};return R(0),{calculatedDuration:null,next:A=>{let V=!1;return!T&&k===void 0&&(V=!0,I(A),R(A)),k!==void 0&&A>=k?T.next(A-k):(!V&&I(A),p)}}}var SL=zr(.42,0,1,1),IL=zr(0,0,.58,1),Fd=zr(.42,0,.58,1);var wL=e=>Array.isArray(e)&&typeof e[0]!="number";var kL={linear:he,easeIn:SL,easeInOut:Fd,easeOut:IL,circIn:Cd,circInOut:Id,circOut:Sd,backIn:Ui,backInOut:vd,backOut:fm,anticipate:Ld},bm=e=>{if(Xn(e)){pa(e.length===4,"Cubic bezier arrays must contain four numerical values.");let[t,a,r,o]=e;return zr(t,a,r,o)}else if(typeof e=="string")return pa(kL[e]!==void 0,`Invalid easing type '${e}'`),kL[e];return e};function i1(e,t,a){let r=[],o=a||Dd,n=e.length-1;for(let s=0;s<n;s++){let i=o(e[s],e[s+1]);if(t){let l=Array.isArray(t)?t[s]||he:t;i=Pa(l,i)}r.push(i)}return r}function bL(e,t,{clamp:a=!0,ease:r,mixer:o}={}){let n=e.length;if(pa(n===t.length,"Both input and output ranges must be the same 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=i1(t,r,o),l=i.length,u=d=>{if(s&&d<e[0])return t[0];let c=0;if(l>1)for(;c<e.length-2&&!(d<e[c+1]);c++);let p=Ut(e[c],e[c+1],d);return i[c](p)};return a?d=>u(et(e[0],e[n-1],d)):u}function PL(e,t){let a=e[e.length-1];for(let r=1;r<=t;r++){let o=Ut(0,t,r);e.push(ne(a,1,o))}}function TL(e){let t=[0];return PL(t,e.length-1),t}function AL(e,t){return e.map(a=>a*t)}function l1(e,t){return e.map(()=>t||Fd).splice(0,e.length-1)}function Hi({duration:e=300,keyframes:t,times:a,ease:r="easeInOut"}){let o=wL(r)?r.map(bm):bm(r),n={done:!1,value:t[0]},s=AL(a&&a.length===t.length?a:TL(t),e),i=bL(s,t,{ease:Array.isArray(o)?o:l1(t,o)});return{calculatedDuration:e,next:l=>(n.value=i(l),n.done=l>=e,n)}}var RL=e=>{let t=({timestamp:a})=>e(a);return{start:()=>J.update(t,!0),stop:()=>_t(t),now:()=>Fe.isProcessing?Fe.timestamp:lt.now()}};var u1={decay:km,inertia:km,tween:Hi,keyframes:Hi,spring:Ed},d1=e=>e/100,To=class extends ns{constructor(t){super(t),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.teardown();let{onStop:l}=this.options;l&&l()};let{name:a,motionValue:r,element:o,keyframes:n}=this.options,s=o?.KeyframeResolver||Wr,i=(l,u)=>this.onKeyframesResolved(l,u);this.resolver=new s(n,i,a,r,o),this.resolver.scheduleResolve()}flatten(){super.flatten(),this._resolved&&Object.assign(this._resolved,this.initPlayback(this._resolved.keyframes))}initPlayback(t){let{type:a="keyframes",repeat:r=0,repeatDelay:o=0,repeatType:n,velocity:s=0}=this.options,i=Vr(a)?a:u1[a]||Hi,l,u;i!==Hi&&typeof t[0]!="number"&&(l=Pa(d1,Dd(t[0],t[1])),t=[0,100]);let d=i({...this.options,keyframes:t});n==="mirror"&&(u=i({...this.options,keyframes:[...t].reverse(),velocity:-s})),d.calculatedDuration===null&&(d.calculatedDuration=$n(d));let{calculatedDuration:c}=d,p=c+o,g=p*(r+1)-o;return{generator:d,mirroredGenerator:u,mapPercentToKeyframes:l,calculatedDuration:c,resolvedDuration:p,totalDuration:g}}onPostResolved(){let{autoplay:t=!0}=this.options;this.play(),this.pendingPlayState==="paused"||!t?this.pause():this.state=this.pendingPlayState}tick(t,a=!1){let{resolved:r}=this;if(!r){let{keyframes:A}=this.options;return{done:!0,value:A[A.length-1]}}let{finalKeyframe:o,generator:n,mirroredGenerator:s,mapPercentToKeyframes:i,keyframes:l,calculatedDuration:u,totalDuration:d,resolvedDuration:c}=r;if(this.startTime===null)return n.next(0);let{delay:p,repeat:g,repeatType:C,repeatDelay:L,onUpdate:S}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-d/this.speed,this.startTime)),a?this.currentTime=t:this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=Math.round(t-this.startTime)*this.speed;let h=this.currentTime-p*(this.speed>=0?1:-1),m=this.speed>=0?h<0:h>d;this.currentTime=Math.max(h,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=d);let x=this.currentTime,I=n;if(g){let A=Math.min(this.currentTime,d)/c,V=Math.floor(A),U=A%1;!U&&A>=1&&(U=1),U===1&&V--,V=Math.min(V,g+1),V%2&&(C==="reverse"?(U=1-U,L&&(U-=L/c)):C==="mirror"&&(I=s)),x=et(0,1,U)*c}let k=m?{done:!1,value:l[0]}:I.next(x);i&&(k.value=i(k.value));let{done:T}=k;!m&&u!==null&&(T=this.speed>=0?this.currentTime>=d:this.currentTime<=0);let R=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&T);return R&&o!==void 0&&(k.value=Gr(l,this.options,o)),S&&S(k.value),R&&this.finish(),k}get duration(){let{resolved:t}=this;return t?Je(t.calculatedDuration):0}get time(){return Je(this.currentTime)}set time(t){t=Ee(t),this.currentTime=t,this.holdTime!==null||this.speed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.speed)}get speed(){return this.playbackSpeed}set speed(t){let a=this.playbackSpeed!==t;this.playbackSpeed=t,a&&(this.time=Je(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved){this.pendingPlayState="running";return}if(this.isStopped)return;let{driver:t=RL,onPlay:a,startTime:r}=this.options;this.driver||(this.driver=t(n=>this.tick(n))),a&&a();let o=this.driver.now();this.holdTime!==null?this.startTime=o-this.holdTime:this.startTime?this.state==="finished"&&(this.startTime=o):this.startTime=r??this.calcStartTime(),this.state==="finished"&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var t;if(!this._resolved){this.pendingPlayState="paused";return}this.state="paused",this.holdTime=(t=this.currentTime)!==null&&t!==void 0?t:0}complete(){this.state!=="running"&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";let{onComplete:t}=this.options;t&&t()}cancel(){this.cancelTime!==null&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}};var DL=new Set(["opacity","clipPath","filter","transform"]);function ML(e,t,a,{delay:r=0,duration:o=300,repeat:n=0,repeatType:s="loop",ease:i="easeInOut",times:l}={}){let u={[t]:a};l&&(u.offset=l);let d=Yn(i,o);return Array.isArray(d)&&(u.easing=d),e.animate(u,{delay:r,duration:o,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:n+1,direction:s==="reverse"?"alternate":"normal"})}var NL=Co(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));var Bd=10,c1=2e4;function f1(e){return Vr(e.type)||e.type==="spring"||!ud(e.ease)}function p1(e,t){let a=new To({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0}),r={done:!1,value:e[0]},o=[],n=0;for(;!r.done&&n<c1;)r=a.sample(n),o.push(r.value),n+=Bd;return{times:void 0,keyframes:o,duration:n-Bd,ease:"linear"}}var EL={anticipate:Ld,backInOut:vd,circInOut:Id};function m1(e){return e in EL}var qi=class extends ns{constructor(t){super(t);let{name:a,motionValue:r,element:o,keyframes:n}=this.options;this.resolver=new os(n,(s,i)=>this.onKeyframesResolved(s,i),a,r,o),this.resolver.scheduleResolve()}initPlayback(t,a){let{duration:r=300,times:o,ease:n,type:s,motionValue:i,name:l,startTime:u}=this.options;if(!i.owner||!i.owner.current)return!1;if(typeof n=="string"&&Ur()&&m1(n)&&(n=EL[n]),f1(this.options)){let{onComplete:c,onUpdate:p,motionValue:g,element:C,...L}=this.options,S=p1(t,L);t=S.keyframes,t.length===1&&(t[1]=t[0]),r=S.duration,o=S.times,n=S.ease,s="keyframes"}let d=ML(i.owner.current,l,t,{...this.options,duration:r,times:o,ease:n});return d.startTime=u??this.calcStartTime(),this.pendingTimeline?(Bi(d,this.pendingTimeline),this.pendingTimeline=void 0):d.onfinish=()=>{let{onComplete:c}=this.options;i.set(Gr(t,this.options,a)),c&&c(),this.cancel(),this.resolveFinishedPromise()},{animation:d,duration:r,times:o,type:s,ease:n,keyframes:t}}get duration(){let{resolved:t}=this;if(!t)return 0;let{duration:a}=t;return Je(a)}get time(){let{resolved:t}=this;if(!t)return 0;let{animation:a}=t;return Je(a.currentTime||0)}set time(t){let{resolved:a}=this;if(!a)return;let{animation:r}=a;r.currentTime=Ee(t)}get speed(){let{resolved:t}=this;if(!t)return 1;let{animation:a}=t;return a.playbackRate}set speed(t){let{resolved:a}=this;if(!a)return;let{animation:r}=a;r.playbackRate=t}get state(){let{resolved:t}=this;if(!t)return"idle";let{animation:a}=t;return a.playState}get startTime(){let{resolved:t}=this;if(!t)return null;let{animation:a}=t;return a.startTime}attachTimeline(t){if(!this._resolved)this.pendingTimeline=t;else{let{resolved:a}=this;if(!a)return he;let{animation:r}=a;Bi(r,t)}return he}play(){if(this.isStopped)return;let{resolved:t}=this;if(!t)return;let{animation:a}=t;a.playState==="finished"&&this.updateFinishedPromise(),a.play()}pause(){let{resolved:t}=this;if(!t)return;let{animation:a}=t;a.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,this.state==="idle")return;this.resolveFinishedPromise(),this.updateFinishedPromise();let{resolved:t}=this;if(!t)return;let{animation:a,keyframes:r,duration:o,type:n,ease:s,times:i}=t;if(a.playState==="idle"||a.playState==="finished")return;if(this.time){let{motionValue:u,onUpdate:d,onComplete:c,element:p,...g}=this.options,C=new To({...g,keyframes:r,duration:o,type:n,ease:s,times:i,isGenerator:!0}),L=Ee(this.time);u.setWithVelocity(C.sample(L-Bd).value,C.sample(L).value,Bd)}let{onStop:l}=this.options;l&&l(),this.cancel()}complete(){let{resolved:t}=this;t&&t.animation.finish()}cancel(){let{resolved:t}=this;t&&t.animation.cancel()}static supports(t){let{motionValue:a,name:r,repeatDelay:o,repeatType:n,damping:s,type:i}=t;if(!a||!a.owner||!(a.owner.current instanceof HTMLElement))return!1;let{onUpdate:l,transformTemplate:u}=a.owner.getProps();return NL()&&r&&DL.has(r)&&!l&&!u&&!o&&n!=="mirror"&&s!==0&&i!=="inertia"}};var h1={type:"spring",stiffness:500,damping:25,restSpeed:10},g1=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),x1={type:"keyframes",duration:.8},y1={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},FL=(e,{keyframes:t})=>t.length>2?x1:Pt.has(e)?e.startsWith("scale")?g1(t[1]):h1:y1;function BL({when:e,delay:t,delayChildren:a,staggerChildren:r,staggerDirection:o,repeat:n,repeatType:s,repeatDelay:i,from:l,elapsed:u,...d}){return!!Object.keys(d).length}var is=(e,t,a,r={},o,n)=>s=>{let i=Or(r,e)||{},l=i.delay||r.delay||0,{elapsed:u=0}=r;u=u-Ee(l);let d={keyframes:Array.isArray(a)?a:[null,a],ease:"easeOut",velocity:t.getVelocity(),...i,delay:-u,onUpdate:p=>{t.set(p),i.onUpdate&&i.onUpdate(p)},onComplete:()=>{s(),i.onComplete&&i.onComplete()},name:e,motionValue:t,element:n?void 0:o};BL(i)||(d={...d,...FL(e,d)}),d.duration&&(d.duration=Ee(d.duration)),d.repeatDelay&&(d.repeatDelay=Ee(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let c=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(d.duration=0,d.delay===0&&(c=!0)),(gd.current||Mn.skipAnimations)&&(c=!0,d.duration=0,d.delay=0),c&&!n&&t.get()!==void 0){let p=Gr(d.keyframes,i);if(p!==void 0)return J.update(()=>{d.onUpdate(p),d.onComplete()}),new Fi([])}return!n&&qi.supports(d)?new qi(d):new To(d)};function v1({protectedKeys:e,needsAnimating:t},a){let r=e.hasOwnProperty(a)&&t[a]!==!0;return t[a]=!1,r}function Od(e,t,{delay:a=0,transitionOverride:r,type:o}={}){var n;let{transition:s=e.getDefaultTransition(),transitionEnd:i,...l}=t;r&&(s=r);let u=[],d=o&&e.animationState&&e.animationState.getState()[o];for(let c in l){let p=e.getValue(c,(n=e.latestValues[c])!==null&&n!==void 0?n:null),g=l[c];if(g===void 0||d&&v1(d,c))continue;let C={delay:a,...Or(s||{},c)},L=!1;if(window.MotionHandoffAnimation){let h=hd(e);if(h){let m=window.MotionHandoffAnimation(h,c,J);m!==null&&(C.startTime=m,L=!0)}}Vi(e,c),p.start(is(c,p,g,e.shouldReduceMotion&&fd.has(c)?{type:!1}:C,e,L));let S=p.animation;S&&u.push(S)}return i&&Promise.all(u).then(()=>{J.update(()=>{i&&X0(e,i)})}),u}function Vd(e,t,a={}){var r;let o=Br(e,t,a.type==="exit"?(r=e.presenceContext)===null||r===void 0?void 0:r.custom:void 0),{transition:n=e.getDefaultTransition()||{}}=o||{};a.transitionOverride&&(n=a.transitionOverride);let s=o?()=>Promise.all(Od(e,o,a)):()=>Promise.resolve(),i=e.variantChildren&&e.variantChildren.size?(u=0)=>{let{delayChildren:d=0,staggerChildren:c,staggerDirection:p}=n;return L1(e,t,d+u,c,p,a)}:()=>Promise.resolve(),{when:l}=n;if(l){let[u,d]=l==="beforeChildren"?[s,i]:[i,s];return u().then(()=>d())}else return Promise.all([s(),i(a.delay)])}function L1(e,t,a=0,r=0,o=1,n){let s=[],i=(e.variantChildren.size-1)*r,l=o===1?(u=0)=>u*r:(u=0)=>i-u*r;return Array.from(e.variantChildren).sort(C1).forEach((u,d)=>{u.notify("AnimationStart",t),s.push(Vd(u,t,{...n,delay:a+l(d)}).then(()=>u.notify("AnimationComplete",t)))}),Promise.all(s)}function C1(e,t){return e.sortNodePosition(t)}function OL(e,t,a={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){let o=t.map(n=>Vd(e,n,a));r=Promise.all(o)}else if(typeof t=="string")r=Vd(e,t,a);else{let o=typeof t=="function"?Br(e,t,a.custom):t;r=Promise.all(Od(e,o,a))}return r.then(()=>{e.notify("AnimationComplete",t)})}var S1=Ri.length;function Pm(e){if(!e)return;if(!e.isControllingVariants){let a=e.parent?Pm(e.parent)||{}:{};return e.props.initial!==void 0&&(a.initial=e.props.initial),a}let t={};for(let a=0;a<S1;a++){let r=Ri[a],o=e.props[r];(Za(o)||o===!1)&&(t[r]=o)}return t}var I1=[...Ku].reverse(),w1=Ku.length;function k1(e){return t=>Promise.all(t.map(({animation:a,options:r})=>OL(e,a,r)))}function UL(e){let t=k1(e),a=VL(),r=!0,o=l=>(u,d)=>{var c;let p=Br(e,d,l==="exit"?(c=e.presenceContext)===null||c===void 0?void 0:c.custom:void 0);if(p){let{transition:g,transitionEnd:C,...L}=p;u={...u,...L,...C}}return u};function n(l){t=l(e)}function s(l){let{props:u}=e,d=Pm(e.parent)||{},c=[],p=new Set,g={},C=1/0;for(let S=0;S<w1;S++){let h=I1[S],m=a[h],x=u[h]!==void 0?u[h]:d[h],I=Za(x),k=h===l?m.isActive:null;k===!1&&(C=S);let T=x===d[h]&&x!==u[h]&&I;if(T&&r&&e.manuallyAnimateOnMount&&(T=!1),m.protectedKeys={...g},!m.isActive&&k===null||!x&&!m.prevProp||Fr(x)||typeof x=="boolean")continue;let R=b1(m.prevProp,x),A=R||h===l&&m.isActive&&!T&&I||S>C&&I,V=!1,U=Array.isArray(x)?x:[x],se=U.reduce(o(h),{});k===!1&&(se={});let{prevResolvedValues:q={}}=m,No={...q,...se},ie=Ae=>{A=!0,p.has(Ae)&&(V=!0,p.delete(Ae)),m.needsAnimating[Ae]=!0;let Be=e.getValue(Ae);Be&&(Be.liveStyle=!1)};for(let Ae in No){let Be=se[Ae],Gt=q[Ae];if(g.hasOwnProperty(Ae))continue;let Rt=!1;Di(Be)&&Di(Gt)?Rt=!am(Be,Gt):Rt=Be!==Gt,Rt?Be!=null?ie(Ae):p.add(Ae):Be!==void 0&&p.has(Ae)?ie(Ae):m.protectedKeys[Ae]=!0}m.prevProp=x,m.prevResolvedValues=se,m.isActive&&(g={...g,...se}),r&&e.blockInitialAnimation&&(A=!1),A&&(!(T&&R)||V)&&c.push(...U.map(Ae=>({animation:Ae,options:{type:h}})))}if(p.size){let S={};p.forEach(h=>{let m=e.getBaseTarget(h),x=e.getValue(h);x&&(x.liveStyle=!0),S[h]=m??null}),c.push({animation:S})}let L=!!c.length;return r&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(L=!1),r=!1,L?t(c):Promise.resolve()}function i(l,u){var d;if(a[l].isActive===u)return Promise.resolve();(d=e.variantChildren)===null||d===void 0||d.forEach(p=>{var g;return(g=p.animationState)===null||g===void 0?void 0:g.setActive(l,u)}),a[l].isActive=u;let c=s(l);for(let p in a)a[p].protectedKeys={};return c}return{animateChanges:s,setActive:i,setAnimateFunction:n,getState:()=>a,reset:()=>{a=VL(),r=!0}}}function b1(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!am(t,e):!1}function Ao(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function VL(){return{animate:Ao(!0),whileInView:Ao(),whileHover:Ao(),whileTap:Ao(),whileDrag:Ao(),whileFocus:Ao(),exit:Ao()}}var Xe=class{constructor(t){this.isMounted=!1,this.node=t}update(){}};var Ud=class extends Xe{constructor(t){super(t),t.animationState||(t.animationState=UL(t))}updateAnimationControlsSubscription(){let{animate:t}=this.node.getProps();Fr(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(){var t;this.node.animationState.reset(),(t=this.unmountControls)===null||t===void 0||t.call(this)}};var P1=0,_d=class extends Xe{constructor(){super(...arguments),this.id=P1++}update(){if(!this.node.presenceContext)return;let{isPresent:t,onExitComplete:a}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;let o=this.node.animationState.setActive("exit",!t);a&&!t&&o.then(()=>a(this.id))}mount(){let{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}};var _L={animation:{Feature:Ud},exit:{Feature:_d}};function ar(e,t,a,r={passive:!0}){return e.addEventListener(t,a,r),()=>e.removeEventListener(t,a)}function rr(e){return{point:{x:e.pageX,y:e.pageY}}}var zL=e=>t=>Io(t)&&e(t,rr(t));function jr(e,t,a,r){return ar(e,t,zL(a),r)}var HL=(e,t)=>Math.abs(e-t);function qL(e,t){let a=HL(e.x,t.x),r=HL(e.y,t.y);return Math.sqrt(a**2+r**2)}var ls=class{constructor(t,a,{transformPagePoint:r,contextWindow:o,dragSnapToOrigin:n=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let c=Am(this.lastMoveEventInfo,this.history),p=this.startEvent!==null,g=qL(c.offset,{x:0,y:0})>=3;if(!p&&!g)return;let{point:C}=c,{timestamp:L}=Fe;this.history.push({...C,timestamp:L});let{onStart:S,onMove:h}=this.handlers;p||(S&&S(this.lastMoveEvent,c),this.startEvent=this.lastMoveEvent),h&&h(this.lastMoveEvent,c)},this.handlePointerMove=(c,p)=>{this.lastMoveEvent=c,this.lastMoveEventInfo=Tm(p,this.transformPagePoint),J.update(this.updatePoint,!0)},this.handlePointerUp=(c,p)=>{this.end();let{onEnd:g,onSessionEnd:C,resumeAnimation:L}=this.handlers;if(this.dragSnapToOrigin&&L&&L(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let S=Am(c.type==="pointercancel"?this.lastMoveEventInfo:Tm(p,this.transformPagePoint),this.history);this.startEvent&&g&&g(c,S),C&&C(c,S)},!Io(t))return;this.dragSnapToOrigin=n,this.handlers=a,this.transformPagePoint=r,this.contextWindow=o||window;let s=rr(t),i=Tm(s,this.transformPagePoint),{point:l}=i,{timestamp:u}=Fe;this.history=[{...l,timestamp:u}];let{onSessionStart:d}=a;d&&d(t,Am(i,this.history)),this.removeListeners=Pa(jr(this.contextWindow,"pointermove",this.handlePointerMove),jr(this.contextWindow,"pointerup",this.handlePointerUp),jr(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),_t(this.updatePoint)}};function Tm(e,t){return t?{point:t(e.point)}:e}function WL(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Am({point:e},t){return{point:e,delta:WL(e,GL(t)),offset:WL(e,T1(t)),velocity:A1(t,.1)}}function T1(e){return e[0]}function GL(e){return e[e.length-1]}function A1(e,t){if(e.length<2)return{x:0,y:0};let a=e.length-1,r=null,o=GL(e);for(;a>=0&&(r=e[a],!(o.timestamp-r.timestamp>Ee(t)));)a--;if(!r)return{x:0,y:0};let n=Je(o.timestamp-r.timestamp);if(n===0)return{x:0,y:0};let s={x:(o.x-r.x)/n,y:(o.y-r.y)/n};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}var XL=1e-4,R1=1-XL,D1=1+XL,QL=.01,M1=0-QL,N1=0+QL;function tt(e){return e.max-e.min}function YL(e,t,a){return Math.abs(e-t)<=a}function jL(e,t,a,r=.5){e.origin=r,e.originPoint=ne(t.min,t.max,e.origin),e.scale=tt(a)/tt(t),e.translate=ne(a.min,a.max,e.origin)-e.originPoint,(e.scale>=R1&&e.scale<=D1||isNaN(e.scale))&&(e.scale=1),(e.translate>=M1&&e.translate<=N1||isNaN(e.translate))&&(e.translate=0)}function us(e,t,a,r){jL(e.x,t.x,a.x,r?r.originX:void 0),jL(e.y,t.y,a.y,r?r.originY:void 0)}function KL(e,t,a){e.min=a.min+t.min,e.max=e.min+tt(t)}function ZL(e,t,a){KL(e.x,t.x,a.x),KL(e.y,t.y,a.y)}function $L(e,t,a){e.min=t.min-a.min,e.max=e.min+tt(t)}function ds(e,t,a){$L(e.x,t.x,a.x),$L(e.y,t.y,a.y)}function rC(e,{min:t,max:a},r){return t!==void 0&&e<t?e=r?ne(t,e,r.min):Math.max(e,t):a!==void 0&&e>a&&(e=r?ne(a,e,r.max):Math.min(e,a)),e}function JL(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 oC(e,{top:t,left:a,bottom:r,right:o}){return{x:JL(e.x,a,o),y:JL(e.y,t,r)}}function eC(e,t){let a=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([a,r]=[r,a]),{min:a,max:r}}function nC(e,t){return{x:eC(e.x,t.x),y:eC(e.y,t.y)}}function sC(e,t){let a=.5,r=tt(e),o=tt(t);return o>r?a=Ut(t.min,t.max-r,e.min):r>o&&(a=Ut(e.min,e.max-o,t.min)),et(0,1,a)}function iC(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 zd=.35;function lC(e=zd){return e===!1?e=0:e===!0&&(e=zd),{x:tC(e,"left","right"),y:tC(e,"top","bottom")}}function tC(e,t,a){return{min:aC(e,t),max:aC(e,a)}}function aC(e,t){return typeof e=="number"?e:e[t]||0}var uC=()=>({translate:0,scale:1,origin:0,originPoint:0}),Ro=()=>({x:uC(),y:uC()}),dC=()=>({min:0,max:0}),Ie=()=>({x:dC(),y:dC()});function Tt(e){return[e("x"),e("y")]}function Hd({top:e,left:t,right:a,bottom:r}){return{x:{min:t,max:a},y:{min:e,max:r}}}function cC({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function fC(e,t){if(!t)return e;let a=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:a.y,left:a.x,bottom:r.y,right:r.x}}function Rm(e){return e===void 0||e===1}function qd({scale:e,scaleX:t,scaleY:a}){return!Rm(e)||!Rm(t)||!Rm(a)}function or(e){return qd(e)||Dm(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function Dm(e){return pC(e.x)||pC(e.y)}function pC(e){return e&&e!=="0%"}function Wi(e,t,a){let r=e-a,o=t*r;return a+o}function mC(e,t,a,r,o){return o!==void 0&&(e=Wi(e,o,r)),Wi(e,a,r)+t}function Mm(e,t=0,a=1,r,o){e.min=mC(e.min,t,a,r,o),e.max=mC(e.max,t,a,r,o)}function Nm(e,{x:t,y:a}){Mm(e.x,t.translate,t.scale,t.originPoint),Mm(e.y,a.translate,a.scale,a.originPoint)}var hC=.999999999999,gC=1.0000000000001;function yC(e,t,a,r=!1){let o=a.length;if(!o)return;t.x=t.y=1;let n,s;for(let i=0;i<o;i++){n=a[i],s=n.projectionDelta;let{visualElement:l}=n.options;l&&l.props.style&&l.props.style.display==="contents"||(r&&n.options.layoutScroll&&n.scroll&&n!==n.root&&Do(e,{x:-n.scroll.offset.x,y:-n.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,Nm(e,s)),r&&or(n.latestValues)&&Do(e,n.latestValues))}t.x<gC&&t.x>hC&&(t.x=1),t.y<gC&&t.y>hC&&(t.y=1)}function Kr(e,t){e.min=e.min+t,e.max=e.max+t}function xC(e,t,a,r,o=.5){let n=ne(e.min,e.max,o);Mm(e,t,a,n,r)}function Do(e,t){xC(e.x,t.x,t.scaleX,t.scale,t.originX),xC(e.y,t.y,t.scaleY,t.scale,t.originY)}function Em(e,t){return Hd(fC(e.getBoundingClientRect(),t))}function vC(e,t,a){let r=Em(e,a),{scroll:o}=t;return o&&(Kr(r.x,o.offset.x),Kr(r.y,o.offset.y)),r}var Wd=({current:e})=>e?e.ownerDocument.defaultView:null;var E1=new WeakMap,jd=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=Ie(),this.visualElement=t}start(t,{snapToCursor:a=!1}={}){let{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;let o=d=>{let{dragSnapToOrigin:c}=this.getProps();c?this.pauseAnimation():this.stopAnimation(),a&&this.snapToCursor(rr(d).point)},n=(d,c)=>{let{drag:p,dragPropagation:g,onDragStart:C}=this.getProps();if(p&&!g&&(this.openDragLock&&this.openDragLock(),this.openDragLock=dm(p),!this.openDragLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Tt(S=>{let h=this.getAxisMotionValue(S).get()||0;if(ht.test(h)){let{projection:m}=this.visualElement;if(m&&m.layout){let x=m.layout.layoutBox[S];x&&(h=tt(x)*(parseFloat(h)/100))}}this.originPoint[S]=h}),C&&J.postRender(()=>C(d,c)),Vi(this.visualElement,"transform");let{animationState:L}=this.visualElement;L&&L.setActive("whileDrag",!0)},s=(d,c)=>{let{dragPropagation:p,dragDirectionLock:g,onDirectionLock:C,onDrag:L}=this.getProps();if(!p&&!this.openDragLock)return;let{offset:S}=c;if(g&&this.currentDirection===null){this.currentDirection=F1(S),this.currentDirection!==null&&C&&C(this.currentDirection);return}this.updateAxis("x",c.point,S),this.updateAxis("y",c.point,S),this.visualElement.render(),L&&L(d,c)},i=(d,c)=>this.stop(d,c),l=()=>Tt(d=>{var c;return this.getAnimationState(d)==="paused"&&((c=this.getAxisMotionValue(d).animation)===null||c===void 0?void 0:c.play())}),{dragSnapToOrigin:u}=this.getProps();this.panSession=new ls(t,{onSessionStart:o,onStart:n,onMove:s,onSessionEnd:i,resumeAnimation:l},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,contextWindow:Wd(this.visualElement)})}stop(t,a){let r=this.isDragging;if(this.cancel(),!r)return;let{velocity:o}=a;this.startAnimation(o);let{onDragEnd:n}=this.getProps();n&&J.postRender(()=>n(t,a))}cancel(){this.isDragging=!1;let{projection:t,animationState:a}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;let{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),a&&a.setActive("whileDrag",!1)}updateAxis(t,a,r){let{drag:o}=this.getProps();if(!r||!Gd(t,o,this.currentDirection))return;let n=this.getAxisMotionValue(t),s=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(s=rC(s,this.constraints[t],this.elastic[t])),n.set(s)}resolveConstraints(){var t;let{dragConstraints:a,dragElastic:r}=this.getProps(),o=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(t=this.visualElement.projection)===null||t===void 0?void 0:t.layout,n=this.constraints;a&&Ja(a)?this.constraints||(this.constraints=this.resolveRefConstraints()):a&&o?this.constraints=oC(o.layoutBox,a):this.constraints=!1,this.elastic=lC(r),n!==this.constraints&&o&&this.constraints&&!this.hasMutatedConstraints&&Tt(s=>{this.constraints!==!1&&this.getAxisMotionValue(s)&&(this.constraints[s]=iC(o.layoutBox[s],this.constraints[s]))})}resolveRefConstraints(){let{dragConstraints:t,onMeasureDragConstraints:a}=this.getProps();if(!t||!Ja(t))return!1;let r=t.current;pa(r!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");let{projection:o}=this.visualElement;if(!o||!o.layout)return!1;let n=vC(r,o.root,this.visualElement.getTransformPagePoint()),s=nC(o.layout.layoutBox,n);if(a){let i=a(cC(s));this.hasMutatedConstraints=!!i,i&&(s=Hd(i))}return s}startAnimation(t){let{drag:a,dragMomentum:r,dragElastic:o,dragTransition:n,dragSnapToOrigin:s,onDragTransitionEnd:i}=this.getProps(),l=this.constraints||{},u=Tt(d=>{if(!Gd(d,a,this.currentDirection))return;let c=l&&l[d]||{};s&&(c={min:0,max:0});let p=o?200:1e6,g=o?40:1e7,C={type:"inertia",velocity:r?t[d]:0,bounceStiffness:p,bounceDamping:g,timeConstant:750,restDelta:1,restSpeed:10,...n,...c};return this.startAxisValueAnimation(d,C)});return Promise.all(u).then(i)}startAxisValueAnimation(t,a){let r=this.getAxisMotionValue(t);return Vi(this.visualElement,t),r.start(is(t,r,0,a,this.visualElement,!1))}stopAnimation(){Tt(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Tt(t=>{var a;return(a=this.getAxisMotionValue(t).animation)===null||a===void 0?void 0:a.pause()})}getAnimationState(t){var a;return(a=this.getAxisMotionValue(t).animation)===null||a===void 0?void 0:a.state}getAxisMotionValue(t){let a=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),o=r[a];return o||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Tt(a=>{let{drag:r}=this.getProps();if(!Gd(a,r,this.currentDirection))return;let{projection:o}=this.visualElement,n=this.getAxisMotionValue(a);if(o&&o.layout){let{min:s,max:i}=o.layout.layoutBox[a];n.set(t[a]-ne(s,i,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:t,dragConstraints:a}=this.getProps(),{projection:r}=this.visualElement;if(!Ja(a)||!r||!this.constraints)return;this.stopAnimation();let o={x:0,y:0};Tt(s=>{let i=this.getAxisMotionValue(s);if(i&&this.constraints!==!1){let l=i.get();o[s]=sC({min:l,max:l},this.constraints[s])}});let{transformTemplate:n}=this.visualElement.getProps();this.visualElement.current.style.transform=n?n({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Tt(s=>{if(!Gd(s,t,null))return;let i=this.getAxisMotionValue(s),{min:l,max:u}=this.constraints[s];i.set(ne(l,u,o[s]))})}addListeners(){if(!this.visualElement.current)return;E1.set(this.visualElement,this);let t=this.visualElement.current,a=jr(t,"pointerdown",l=>{let{drag:u,dragListener:d=!0}=this.getProps();u&&d&&this.start(l)}),r=()=>{let{dragConstraints:l}=this.getProps();Ja(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:o}=this.visualElement,n=o.addEventListener("measure",r);o&&!o.layout&&(o.root&&o.root.updateScroll(),o.updateLayout()),J.read(r);let s=ar(window,"resize",()=>this.scalePositionWithinConstraints()),i=o.addEventListener("didUpdate",(({delta:l,hasLayoutChanged:u})=>{this.isDragging&&u&&(Tt(d=>{let c=this.getAxisMotionValue(d);c&&(this.originPoint[d]+=l[d].translate,c.set(c.get()+l[d].translate))}),this.visualElement.render())}));return()=>{s(),a(),n(),i&&i()}}getProps(){let t=this.visualElement.getProps(),{drag:a=!1,dragDirectionLock:r=!1,dragPropagation:o=!1,dragConstraints:n=!1,dragElastic:s=zd,dragMomentum:i=!0}=t;return{...t,drag:a,dragDirectionLock:r,dragPropagation:o,dragConstraints:n,dragElastic:s,dragMomentum:i}}};function Gd(e,t,a){return(t===!0||t===e)&&(a===null||a===e)}function F1(e,t=10){let a=null;return Math.abs(e.y)>t?a="y":Math.abs(e.x)>t&&(a="x"),a}var Kd=class extends Xe{constructor(t){super(t),this.removeGroupControls=he,this.removeListeners=he,this.controls=new jd(t)}mount(){let{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||he}unmount(){this.removeGroupControls(),this.removeListeners()}};var LC=e=>(t,a)=>{e&&J.postRender(()=>e(t,a))},$d=class extends Xe{constructor(){super(...arguments),this.removePointerDownListener=he}onPointerDown(t){this.session=new ls(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Wd(this.node)})}createPanHandlers(){let{onPanSessionStart:t,onPanStart:a,onPan:r,onPanEnd:o}=this.node.getProps();return{onSessionStart:LC(t),onStart:LC(a),onMove:r,onEnd:(n,s)=>{delete this.session,o&&J.postRender(()=>o(n,s))}}}mount(){this.removePointerDownListener=jr(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 IC=E(ue(),1),Gi=E(X(),1);var cs={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function CC(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}var fs={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(H.test(e))e=parseFloat(e);else return e;let a=CC(e,t.target.x),r=CC(e,t.target.y);return`${a}% ${r}%`}};var SC={correct:(e,{treeScale:t,projectionDelta:a})=>{let r=e,o=gt.parse(e);if(o.length>5)return r;let n=gt.createTransformer(e),s=typeof o[0]!="number"?1:0,i=a.x.scale*t.x,l=a.y.scale*t.y;o[0+s]/=i,o[1+s]/=l;let u=ne(i,l,.5);return typeof o[2+s]=="number"&&(o[2+s]/=u),typeof o[3+s]=="number"&&(o[3+s]/=u),n(o)}};var Fm=class extends Gi.Component{componentDidMount(){let{visualElement:t,layoutGroup:a,switchLayoutGroup:r,layoutId:o}=this.props,{projection:n}=t;R0(B1),n&&(a.group&&a.group.add(n),r&&r.register&&o&&r.register(n),n.root.didUpdate(),n.addEventListener("animationComplete",()=>{this.safeToRemove()}),n.setOptions({...n.options,onExitComplete:()=>this.safeToRemove()})),cs.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){let{layoutDependency:a,visualElement:r,drag:o,isPresent:n}=this.props,s=r.projection;return s&&(s.isPresent=n,o||t.layoutDependency!==a||a===void 0?s.willUpdate():this.safeToRemove(),t.isPresent!==n&&(n?s.promote():s.relegate()||J.postRender(()=>{let i=s.getStack();(!i||!i.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){let{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),En.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:t,layoutGroup:a,switchLayoutGroup:r}=this.props,{projection:o}=t;o&&(o.scheduleCheckAfterUnmount(),a&&a.group&&a.group.remove(o),r&&r.deregister&&r.deregister(o))}safeToRemove(){let{safeToRemove:t}=this.props;t&&t()}render(){return null}};function Xd(e){let[t,a]=Uu(),r=(0,Gi.useContext)(Tn);return(0,IC.jsx)(Fm,{...e,layoutGroup:r,switchLayoutGroup:(0,Gi.useContext)(Yu),isPresent:t,safeToRemove:a})}var B1={borderRadius:{...fs,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:fs,borderTopRightRadius:fs,borderBottomLeftRadius:fs,borderBottomRightRadius:fs,boxShadow:SC};function wC(e,t,a){let r=ye(e)?e:tr(e);return r.start(is("",r,t,a)),r.animation}function kC(e){return e instanceof SVGElement&&e.tagName!=="svg"}var bC=(e,t)=>e.depth-t.depth;var Qd=class{constructor(){this.children=[],this.isDirty=!1}add(t){Jn(this.children,t),this.isDirty=!0}remove(t){es(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(bC),this.isDirty=!1,this.children.forEach(t)}};function PC(e,t){let a=lt.now(),r=({timestamp:o})=>{let n=o-a;n>=t&&(_t(r),e(n-t))};return J.read(r,!0),()=>_t(r)}var DC=["TopLeft","TopRight","BottomLeft","BottomRight"],O1=DC.length,TC=e=>typeof e=="string"?parseFloat(e):e,AC=e=>typeof e=="number"||H.test(e);function MC(e,t,a,r,o,n){o?(e.opacity=ne(0,a.opacity!==void 0?a.opacity:1,V1(r)),e.opacityExit=ne(t.opacity!==void 0?t.opacity:1,0,U1(r))):n&&(e.opacity=ne(t.opacity!==void 0?t.opacity:1,a.opacity!==void 0?a.opacity:1,r));for(let s=0;s<O1;s++){let i=`border${DC[s]}Radius`,l=RC(t,i),u=RC(a,i);if(l===void 0&&u===void 0)continue;l||(l=0),u||(u=0),l===0||u===0||AC(l)===AC(u)?(e[i]=Math.max(ne(TC(l),TC(u),r),0),(ht.test(u)||ht.test(l))&&(e[i]+="%")):e[i]=u}(t.rotate||a.rotate)&&(e.rotate=ne(t.rotate||0,a.rotate||0,r))}function RC(e,t){return e[t]!==void 0?e[t]:e.borderRadius}var V1=NC(0,.5,Sd),U1=NC(.5,.95,he);function NC(e,t,a){return r=>r<e?0:r>t?1:a(Ut(e,t,r))}function EC(e,t){e.min=t.min,e.max=t.max}function Ht(e,t){EC(e.x,t.x),EC(e.y,t.y)}function Bm(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function FC(e,t,a,r,o){return e-=t,e=Wi(e,1/a,r),o!==void 0&&(e=Wi(e,1/o,r)),e}function _1(e,t=0,a=1,r=.5,o,n=e,s=e){if(ht.test(t)&&(t=parseFloat(t),t=ne(s.min,s.max,t/100)-s.min),typeof t!="number")return;let i=ne(n.min,n.max,r);e===n&&(i-=t),e.min=FC(e.min,t,a,i,o),e.max=FC(e.max,t,a,i,o)}function BC(e,t,[a,r,o],n,s){_1(e,t[a],t[r],t[o],t.scale,n,s)}var z1=["x","scaleX","originX"],H1=["y","scaleY","originY"];function Om(e,t,a,r){BC(e.x,t,z1,a?a.x:void 0,r?r.x:void 0),BC(e.y,t,H1,a?a.y:void 0,r?r.y:void 0)}function OC(e){return e.translate===0&&e.scale===1}function Vm(e){return OC(e.x)&&OC(e.y)}function VC(e,t){return e.min===t.min&&e.max===t.max}function _C(e,t){return VC(e.x,t.x)&&VC(e.y,t.y)}function UC(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Um(e,t){return UC(e.x,t.x)&&UC(e.y,t.y)}function _m(e){return tt(e.x)/tt(e.y)}function zm(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}var Yd=class{constructor(){this.members=[]}add(t){Jn(this.members,t),t.scheduleRender()}remove(t){if(es(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){let a=this.members.findIndex(o=>t===o);if(a===0)return!1;let r;for(let o=a;o>=0;o--){let n=this.members[o];if(n.isPresent!==!1){r=n;break}}return r?(this.promote(r),!0):!1}promote(t,a){let r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,a&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);let{crossfade:o}=t.options;o===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{let{options:a,resumingFrom:r}=t;a.onExitComplete&&a.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}};function zC(e,t,a){let r="",o=e.x.translate/t.x,n=e.y.translate/t.y,s=a?.z||0;if((o||n||s)&&(r=`translate3d(${o}px, ${n}px, ${s}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),a){let{transformPerspective:u,rotate:d,rotateX:c,rotateY:p,skewX:g,skewY:C}=a;u&&(r=`perspective(${u}px) ${r}`),d&&(r+=`rotate(${d}deg) `),c&&(r+=`rotateX(${c}deg) `),p&&(r+=`rotateY(${p}deg) `),g&&(r+=`skewX(${g}deg) `),C&&(r+=`skewY(${C}deg) `)}let i=e.x.scale*t.x,l=e.y.scale*t.y;return(i!==1||l!==1)&&(r+=`scale(${i}, ${l})`),r||"none"}var Mo={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},ji=typeof window<"u"&&window.MotionDebug!==void 0,Hm=["","X","Y","Z"],q1={visibility:"hidden"},HC=1e3,W1=0;function qm(e,t,a,r){let{latestValues:o}=t;o[e]&&(a[e]=o[e],t.setStaticValue(e,0),r&&(r[e]=0))}function QC(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;let{visualElement:t}=e.options;if(!t)return;let a=hd(t);if(window.MotionHasOptimisedAnimation(a,"transform")){let{layout:o,layoutId:n}=e.options;window.MotionCancelOptimisedAnimation(a,"transform",J,!(o||n))}let{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&QC(r)}function Zd({attachResizeListener:e,defaultParent:t,measureScroll:a,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(s={},i=t?.()){this.id=W1++,this.animationId=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,ji&&(Mo.totalNodes=Mo.resolvedTargetDeltas=Mo.recalculatedProjection=0),this.nodes.forEach(K1),this.nodes.forEach(Z1),this.nodes.forEach(J1),this.nodes.forEach($1),ji&&window.MotionDebug.record(Mo)},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 Qd)}addEventListener(s,i){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new _r),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,i=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=kC(s),this.instance=s;let{layoutId:l,layout:u,visualElement:d}=this.options;if(d&&!d.current&&d.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),i&&(u||l)&&(this.isLayoutDirty=!0),e){let c,p=()=>this.root.updateBlockedByResize=!1;e(s,()=>{this.root.updateBlockedByResize=!0,c&&c(),c=PC(p,250),cs.hasAnimatedSinceResize&&(cs.hasAnimatedSinceResize=!1,this.nodes.forEach(WC))})}l&&this.root.registerSharedNode(l,this),this.options.animate!==!1&&d&&(l||u)&&this.addEventListener("didUpdate",({delta:c,hasLayoutChanged:p,hasRelativeTargetChanged:g,layout:C})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let L=this.options.transition||d.getDefaultTransition()||oT,{onLayoutAnimationStart:S,onLayoutAnimationComplete:h}=d.getProps(),m=!this.targetLayout||!Um(this.targetLayout,C)||g,x=!p&&g;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||x||p&&(m||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(c,x);let I={...Or(L,"layout"),onPlay:S,onComplete:h};(d.shouldReduceMotion||this.options.layoutRoot)&&(I.delay=0,I.type=!1),this.startAnimation(I)}else p||WC(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=C})}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,_t(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(eT),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&&QC(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d<this.path.length;d++){let c=this.path[d];c.shouldResetTransform=!0,c.updateScroll("snapshot"),c.options.layoutRoot&&c.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()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(qC);return}this.isUpdating||this.nodes.forEach(Q1),this.isUpdating=!1,this.nodes.forEach(Y1),this.nodes.forEach(G1),this.nodes.forEach(j1),this.clearAllSnapshots();let i=lt.now();Fe.delta=et(0,1e3/60,i-Fe.timestamp),Fe.timestamp=i,Fe.isProcessing=!0,Gu.update.process(Fe),Gu.preRender.process(Fe),Gu.render.process(Fe),Fe.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,En.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(X1),this.sharedNodes.forEach(tT)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,J.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){J.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}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=Ie(),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){let l=r(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(!o)return;let s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,i=this.projectionDelta&&!Vm(this.projectionDelta),l=this.getTransformTemplate(),u=l?l(this.latestValues,""):void 0,d=u!==this.prevTransformTemplateValue;s&&(i||or(this.latestValues)||d)&&(o(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)),nT(l),{animationId:this.root.animationId,measuredBox:i,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){var s;let{visualElement:i}=this.options;if(!i)return Ie();let l=i.measureViewportBox();if(!(((s=this.scroll)===null||s===void 0?void 0:s.wasRoot)||this.path.some(sT))){let{scroll:d}=this.root;d&&(Kr(l.x,d.offset.x),Kr(l.y,d.offset.y))}return l}removeElementScroll(s){var i;let l=Ie();if(Ht(l,s),!((i=this.scroll)===null||i===void 0)&&i.wasRoot)return l;for(let u=0;u<this.path.length;u++){let d=this.path[u],{scroll:c,options:p}=d;d!==this.root&&c&&p.layoutScroll&&(c.wasRoot&&Ht(l,s),Kr(l.x,c.offset.x),Kr(l.y,c.offset.y))}return l}applyTransform(s,i=!1){let l=Ie();Ht(l,s);for(let u=0;u<this.path.length;u++){let d=this.path[u];!i&&d.options.layoutScroll&&d.scroll&&d!==d.root&&Do(l,{x:-d.scroll.offset.x,y:-d.scroll.offset.y}),or(d.latestValues)&&Do(l,d.latestValues)}return or(this.latestValues)&&Do(l,this.latestValues),l}removeTransform(s){let i=Ie();Ht(i,s);for(let l=0;l<this.path.length;l++){let u=this.path[l];if(!u.instance||!or(u.latestValues))continue;qd(u.latestValues)&&u.updateSnapshot();let d=Ie(),c=u.measurePageBox();Ht(d,c),Om(i,u.latestValues,u.snapshot?u.snapshot.layoutBox:void 0,d)}return or(this.latestValues)&&Om(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!==Fe.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){var i;let l=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=l.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=l.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=l.isSharedProjectionDirty);let u=!!this.resumingFrom||this!==l;if(!(s||u&&this.isSharedProjectionDirty||this.isProjectionDirty||!((i=this.parent)===null||i===void 0)&&i.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:c,layoutId:p}=this.options;if(!(!this.layout||!(c||p))){if(this.resolvedRelativeTargetAt=Fe.timestamp,!this.targetDelta&&!this.relativeTarget){let g=this.getClosestProjectingParent();g&&g.layout&&this.animationProgress!==1?(this.relativeParent=g,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Ie(),this.relativeTargetOrigin=Ie(),ds(this.relativeTargetOrigin,this.layout.layoutBox,g.layout.layoutBox),Ht(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)){if(this.target||(this.target=Ie(),this.targetWithTransforms=Ie()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),ZL(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):Ht(this.target,this.layout.layoutBox),Nm(this.target,this.targetDelta)):Ht(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;let g=this.getClosestProjectingParent();g&&!!g.resumingFrom==!!this.resumingFrom&&!g.options.layoutScroll&&g.target&&this.animationProgress!==1?(this.relativeParent=g,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Ie(),this.relativeTargetOrigin=Ie(),ds(this.relativeTargetOrigin,this.target,g.target),Ht(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}ji&&Mo.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||qd(this.parent.latestValues)||Dm(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var s;let i=this.getLead(),l=!!this.resumingFrom||this!==i,u=!0;if((this.isProjectionDirty||!((s=this.parent)===null||s===void 0)&&s.isProjectionDirty)&&(u=!1),l&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(u=!1),this.resolvedRelativeTargetAt===Fe.timestamp&&(u=!1),u)return;let{layout:d,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||!(d||c))return;Ht(this.layoutCorrected,this.layout.layoutBox);let p=this.treeScale.x,g=this.treeScale.y;yC(this.layoutCorrected,this.treeScale,this.path,l),i.layout&&!i.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(i.target=i.layout.layoutBox,i.targetWithTransforms=Ie());let{target:C}=i;if(!C){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Bm(this.prevProjectionDelta.x,this.projectionDelta.x),Bm(this.prevProjectionDelta.y,this.projectionDelta.y)),us(this.projectionDelta,this.layoutCorrected,C,this.latestValues),(this.treeScale.x!==p||this.treeScale.y!==g||!zm(this.projectionDelta.x,this.prevProjectionDelta.x)||!zm(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",C)),ji&&Mo.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){var i;if((i=this.options.visualElement)===null||i===void 0||i.scheduleRender(),s){let l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Ro(),this.projectionDelta=Ro(),this.projectionDeltaWithTransform=Ro()}setAnimationOrigin(s,i=!1){let l=this.snapshot,u=l?l.latestValues:{},d={...this.latestValues},c=Ro();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!i;let p=Ie(),g=l?l.source:void 0,C=this.layout?this.layout.source:void 0,L=g!==C,S=this.getStack(),h=!S||S.members.length<=1,m=!!(L&&!h&&this.options.crossfade===!0&&!this.path.some(rT));this.animationProgress=0;let x;this.mixTargetDelta=I=>{let k=I/1e3;GC(c.x,s.x,k),GC(c.y,s.y,k),this.setTargetDelta(c),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(ds(p,this.layout.layoutBox,this.relativeParent.layout.layoutBox),aT(this.relativeTarget,this.relativeTargetOrigin,p,k),x&&_C(this.relativeTarget,x)&&(this.isProjectionDirty=!1),x||(x=Ie()),Ht(x,this.relativeTarget)),L&&(this.animationValues=d,MC(d,u,this.latestValues,k,m,h)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=k},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(_t(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=J.update(()=>{cs.hasAnimatedSinceResize=!0,this.currentAnimation=wC(0,HC,{...s,onUpdate:i=>{this.mixTargetDelta(i),s.onUpdate&&s.onUpdate(i)},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);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(HC),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let s=this.getLead(),{targetWithTransforms:i,target:l,layout:u,latestValues:d}=s;if(!(!i||!l||!u)){if(this!==s&&this.layout&&u&&YC(this.options.animationType,this.layout.layoutBox,u.layoutBox)){l=this.target||Ie();let c=tt(this.layout.layoutBox.x);l.x.min=s.target.x.min,l.x.max=l.x.min+c;let p=tt(this.layout.layoutBox.y);l.y.min=s.target.y.min,l.y.max=l.y.min+p}Ht(i,l),Do(i,d),us(this.projectionDeltaWithTransform,this.layoutCorrected,i,d)}}registerSharedNode(s,i){this.sharedNodes.has(s)||this.sharedNodes.set(s,new Yd),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(){var s;let{layoutId:i}=this.options;return i?((s=this.getStack())===null||s===void 0?void 0:s.lead)||this:this}getPrevLead(){var s;let{layoutId:i}=this.options;return i?(s=this.getStack())===null||s===void 0?void 0:s.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&&qm("z",s,u,this.animationValues);for(let d=0;d<Hm.length;d++)qm(`rotate${Hm[d]}`,s,u,this.animationValues),qm(`skew${Hm[d]}`,s,u,this.animationValues);s.render();for(let d in u)s.setStaticValue(d,u[d]),this.animationValues&&(this.animationValues[d]=u[d]);s.scheduleRender()}getProjectionStyles(s){var i,l;if(!this.instance||this.isSVG)return;if(!this.isVisible)return q1;let u={visibility:""},d=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,u.opacity="",u.pointerEvents=Vn(s?.pointerEvents)||"",u.transform=d?d(this.latestValues,""):"none",u;let c=this.getLead();if(!this.projectionDelta||!this.layout||!c.target){let L={};return this.options.layoutId&&(L.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,L.pointerEvents=Vn(s?.pointerEvents)||""),this.hasProjected&&!or(this.latestValues)&&(L.transform=d?d({},""):"none",this.hasProjected=!1),L}let p=c.animationValues||c.latestValues;this.applyTransformsToTarget(),u.transform=zC(this.projectionDeltaWithTransform,this.treeScale,p),d&&(u.transform=d(p,u.transform));let{x:g,y:C}=this.projectionDelta;u.transformOrigin=`${g.origin*100}% ${C.origin*100}% 0`,c.animationValues?u.opacity=c===this?(l=(i=p.opacity)!==null&&i!==void 0?i:this.latestValues.opacity)!==null&&l!==void 0?l:1:this.preserveOpacity?this.latestValues.opacity:p.opacityExit:u.opacity=c===this?p.opacity!==void 0?p.opacity:"":p.opacityExit!==void 0?p.opacityExit:0;for(let L in Gn){if(p[L]===void 0)continue;let{correct:S,applyTo:h}=Gn[L],m=u.transform==="none"?p[L]:S(p[L],c);if(h){let x=h.length;for(let I=0;I<x;I++)u[h[I]]=m}else u[L]=m}return this.options.layoutId&&(u.pointerEvents=c===this?Vn(s?.pointerEvents)||"":"none"),u}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>{var i;return(i=s.currentAnimation)===null||i===void 0?void 0:i.stop()}),this.root.nodes.forEach(qC),this.root.sharedNodes.clear()}}}function G1(e){e.updateLayout()}function j1(e){var t;let a=((t=e.resumeFrom)===null||t===void 0?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&a&&e.hasListeners("didUpdate")){let{layoutBox:r,measuredBox:o}=e.layout,{animationType:n}=e.options,s=a.source!==e.layout.source;n==="size"?Tt(c=>{let p=s?a.measuredBox[c]:a.layoutBox[c],g=tt(p);p.min=r[c].min,p.max=p.min+g}):YC(n,a.layoutBox,r)&&Tt(c=>{let p=s?a.measuredBox[c]:a.layoutBox[c],g=tt(r[c]);p.max=p.min+g,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[c].max=e.relativeTarget[c].min+g)});let i=Ro();us(i,r,a.layoutBox);let l=Ro();s?us(l,e.applyTransform(o,!0),a.measuredBox):us(l,r,a.layoutBox);let u=!Vm(i),d=!1;if(!e.resumeFrom){let c=e.getClosestProjectingParent();if(c&&!c.resumeFrom){let{snapshot:p,layout:g}=c;if(p&&g){let C=Ie();ds(C,a.layoutBox,p.layoutBox);let L=Ie();ds(L,r,g.layoutBox),Um(C,L)||(d=!0),c.options.layoutRoot&&(e.relativeTarget=L,e.relativeTargetOrigin=C,e.relativeParent=c)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:a,delta:l,layoutDelta:i,hasLayoutChanged:u,hasRelativeTargetChanged:d})}else if(e.isLead()){let{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function K1(e){ji&&Mo.totalNodes++,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 $1(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function X1(e){e.clearSnapshot()}function qC(e){e.clearMeasurements()}function Q1(e){e.isLayoutDirty=!1}function Y1(e){let{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function WC(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Z1(e){e.resolveTargetDelta()}function J1(e){e.calcProjection()}function eT(e){e.resetSkewAndRotation()}function tT(e){e.removeLeadSnapshot()}function GC(e,t,a){e.translate=ne(t.translate,0,a),e.scale=ne(t.scale,1,a),e.origin=t.origin,e.originPoint=t.originPoint}function jC(e,t,a,r){e.min=ne(t.min,a.min,r),e.max=ne(t.max,a.max,r)}function aT(e,t,a,r){jC(e.x,t.x,a.x,r),jC(e.y,t.y,a.y,r)}function rT(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}var oT={duration:.45,ease:[.4,0,.1,1]},KC=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),$C=KC("applewebkit/")&&!KC("chrome/")?Math.round:he;function XC(e){e.min=$C(e.min),e.max=$C(e.max)}function nT(e){XC(e.x),XC(e.y)}function YC(e,t,a){return e==="position"||e==="preserve-aspect"&&!YL(_m(t),_m(a),.2)}function sT(e){var t;return e!==e.root&&((t=e.scroll)===null||t===void 0?void 0:t.wasRoot)}var ZC=Zd({attachResizeListener:(e,t)=>ar(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0});var Wm={current:void 0},Jd=Zd({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Wm.current){let e=new ZC({});e.mount(window),e.setOptions({layoutScroll:!0}),Wm.current=e}return Wm.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"});var JC={pan:{Feature:$d},drag:{Feature:Kd,ProjectionNode:Jd,MeasureLayout:Xd}};function eS(e,t,a){let{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",a==="Start");let o="onHover"+a,n=r[o];n&&J.postRender(()=>n(t,rr(t)))}var ec=class extends Xe{mount(){let{current:t}=this.node;t&&(this.unmount=im(t,a=>(eS(this.node,a,"Start"),r=>eS(this.node,r,"End"))))}unmount(){}};var tc=class extends Xe{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=Pa(ar(this.node.current,"focus",()=>this.onFocus()),ar(this.node.current,"blur",()=>this.onBlur()))}unmount(){}};function tS(e,t,a){let{props:r}=e;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",a==="Start");let o="onTap"+(a==="End"?"":a),n=r[o];n&&J.postRender(()=>n(t,rr(t)))}var ac=class extends Xe{mount(){let{current:t}=this.node;t&&(this.unmount=um(t,a=>(tS(this.node,a,"Start"),(r,{success:o})=>tS(this.node,r,o?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}};var jm=new WeakMap,Gm=new WeakMap,iT=e=>{let t=jm.get(e.target);t&&t(e)},lT=e=>{e.forEach(iT)};function uT({root:e,...t}){let a=e||document;Gm.has(a)||Gm.set(a,{});let r=Gm.get(a),o=JSON.stringify(t);return r[o]||(r[o]=new IntersectionObserver(lT,{root:e,...t})),r[o]}function aS(e,t,a){let r=uT(t);return jm.set(e,a),r.observe(e),()=>{jm.delete(e),r.unobserve(e)}}var dT={some:0,all:1},rc=class extends Xe{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();let{viewport:t={}}=this.node.getProps(),{root:a,margin:r,amount:o="some",once:n}=t,s={root:a?a.current:void 0,rootMargin:r,threshold:typeof o=="number"?o:dT[o]},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:d,onViewportLeave:c}=this.node.getProps(),p=u?d:c;p&&p(l)};return aS(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(cT(t,a))&&this.startObserver()}unmount(){}};function cT({viewport:e={}},{viewport:t={}}={}){return a=>e[a]!==t[a]}var rS={inView:{Feature:rc},tap:{Feature:ac},focus:{Feature:tc},hover:{Feature:ec}};var oS={layout:{ProjectionNode:Jd,MeasureLayout:Xd}};var uS=E(X(),1);var Ki={current:null},oc={current:!1};function nS(){if(oc.current=!0,!!Dn)if(window.matchMedia){let e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Ki.current=e.matches;e.addListener(t),t()}else Ki.current=!1}var fT=[...ym,Ue,gt],sS=e=>fT.find(Td(e));var Km=new WeakMap;function iS(e,t,a){for(let r in t){let o=t[r],n=a[r];if(ye(o))e.addValue(r,o);else if(ye(n))e.addValue(r,tr(o,{owner:e}));else if(n!==o)if(e.hasValue(r)){let s=e.getValue(r);s.liveStyle===!0?s.jump(o):s.hasAnimated||s.set(o)}else{let s=e.getStaticValue(r);e.addValue(r,tr(s!==void 0?s:o,{owner:e}))}}for(let r in a)t[r]===void 0&&e.removeValue(r);return t}var lS=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],nc=class{scrapeMotionValuesFromProps(t,a,r){return{}}constructor({parent:t,props:a,presenceContext:r,reducedMotionConfig:o,blockInitialAnimation:n,visualState:s},i={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Wr,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{let g=lt.now();this.renderScheduledAt<g&&(this.renderScheduledAt=g,J.render(this.render,!1,!0))};let{latestValues:l,renderState:u,onUpdate:d}=s;this.onUpdate=d,this.latestValues=l,this.baseTarget={...l},this.initialValues=a.initial?{...l}:{},this.renderState=u,this.parent=t,this.props=a,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=o,this.options=i,this.blockInitialAnimation=!!n,this.isControllingVariants=So(a),this.isVariantNode=$u(a),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);let{willChange:c,...p}=this.scrapeMotionValuesFromProps(a,{},this);for(let g in p){let C=p[g];l[g]!==void 0&&ye(C)&&C.set(l[g],!1)}}mount(t){this.current=t,Km.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,r)=>this.bindToMotionValue(r,a)),oc.current||nS(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Ki.current,this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){Km.delete(this.current),this.projection&&this.projection.unmount(),_t(this.notifyUpdate),_t(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(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}bindToMotionValue(t,a){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();let r=Pt.has(t),o=a.on("change",i=>{this.latestValues[t]=i,this.props.onUpdate&&J.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0)}),n=a.on("renderRequest",this.scheduleRender),s;window.MotionCheckAppearSync&&(s=window.MotionCheckAppearSync(this,t,a)),this.valueSubscriptions.set(t,()=>{o(),n(),s&&s(),a.owner&&a.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Ya){let a=Ya[t];if(!a)continue;let{isEnabled:r,Feature:o}=a;if(!this.features[t]&&o&&r(this.props)&&(this.features[t]=new o(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):Ie()}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 r=0;r<lS.length;r++){let o=lS[r];this.propEventSubscriptions[o]&&(this.propEventSubscriptions[o](),delete this.propEventSubscriptions[o]);let n="on"+o,s=t[n];s&&(this.propEventSubscriptions[o]=this.on(o,s))}this.prevMotionValues=iS(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue(),this.onUpdate&&this.onUpdate(this)}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 r=this.values.get(t);a!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,a),this.values.set(t,a),this.latestValues[t]=a.get())}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 r=this.values.get(t);return r===void 0&&a!==void 0&&(r=tr(a===null?void 0:a,{owner:this}),this.addValue(t,r)),r}readValue(t,a){var r;let o=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(r=this.getBaseTargetFromProps(this.props,t))!==null&&r!==void 0?r:this.readValueFromInstance(this.current,t,this.options);return o!=null&&(typeof o=="string"&&(Pd(o)||wd(o))?o=parseFloat(o):!sS(o)&>.test(a)&&(o=bd(t,a)),this.setBaseTarget(t,ye(o)?o.get():o)),ye(o)?o.get():o}setBaseTarget(t,a){this.baseTarget[t]=a}getBaseTarget(t){var a;let{initial:r}=this.props,o;if(typeof r=="string"||typeof r=="object"){let s=On(this.props,r,(a=this.presenceContext)===null||a===void 0?void 0:a.custom);s&&(o=s[t])}if(r&&o!==void 0)return o;let n=this.getBaseTargetFromProps(this.props,t);return n!==void 0&&!ye(n)?n:this.initialValues[t]!==void 0&&o===void 0?void 0:this.baseTarget[t]}on(t,a){return this.events[t]||(this.events[t]=new _r),this.events[t].add(a)}notify(t,...a){this.events[t]&&this.events[t].notify(...a)}};var ps=class extends nc{constructor(){super(...arguments),this.KeyframeResolver=os}sortInstanceNodePosition(t,a){return t.compareDocumentPosition(a)&2?1:-1}getBaseTargetFromProps(t,a){return t.style?t.style[a]:void 0}removeValueFromRenderState(t,{vars:a,style:r}){delete a[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:t}=this.props;ye(t)&&(this.childSubscription=t.on("change",a=>{this.current&&(this.current.textContent=`${a}`)}))}};function pT(e){return window.getComputedStyle(e)}var sc=class extends ps{constructor(){super(...arguments),this.type="html",this.renderInstance=rd}readValueFromInstance(t,a){if(Pt.has(a)){let r=rs(a);return r&&r.default||0}else{let r=pT(t),o=(ed(a)?r.getPropertyValue(a):r[a])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:a}){return Em(t,a)}build(t,a,r){zn(t,a,r.transformTemplate)}scrapeMotionValuesFromProps(t,a,r){return jn(t,a,r)}};var ic=class extends ps{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Ie}getBaseTargetFromProps(t,a){return t[a]}readValueFromInstance(t,a){if(Pt.has(a)){let r=rs(a);return r&&r.default||0}return a=od.has(a)?a:Nn(a),t.getAttribute(a)}scrapeMotionValuesFromProps(t,a,r){return id(t,a,r)}build(t,a,r){Hn(t,a,this.isSVGTag,r.transformTemplate)}renderInstance(t,a,r,o){nd(t,a,r,o)}mount(t){this.isSVGTag=Wn(t.tagName),super.mount(t)}};var dS=(e,t)=>Bn(e)?new ic(t):new sc(t,{allowProjection:e!==uS.Fragment});var cS=U0({..._L,...rS,...JC,...oS},dS);var $m=n0(cS);var $i=E(ue(),1);function fS({x:e,y:t,visible:a,onClick:r=!1}){return(0,$i.jsx)(Yp,{children:a&&(0,$i.jsx)($m.div,{className:"fixed pointer-events-none z-[9999]",initial:{opacity:0,scale:.5},animate:{opacity:1,scale:1,x:e,y:t},exit:{opacity:0,scale:.5},transition:{type:"spring",stiffness:200,damping:20},style:{left:0,top:0},children:(0,$i.jsx)("svg",{width:"32",height:"32",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,$i.jsx)("path",{d:"M3 3L10.07 19.97L12.58 12.58L19.97 10.07L3 3Z",fill:"#C4B5FD"})})})})}var ms=E(X(),1);function pS(){let[e,t]=ms.useState({x:0,y:0,visible:!1,onClick:!1}),a=ms.useCallback(n=>{let s=document.querySelector(n.selector);if(s){let i=s.getBoundingClientRect(),l=n.offset?.x||0,u=n.offset?.y||0;t({x:i.left+i.width/2+l,y:i.top+i.height/2+u,visible:!0,onClick:n.onClick||!1})}},[]),r=ms.useCallback(()=>{t(n=>({...n,visible:!1}))},[]),o=ms.useCallback(()=>{t(n=>({...n,visible:!0}))},[]);return{cursorState:e,moveTo:a,hide:r,show:o}}var hs=E(ue(),1);function ut({className:e,...t}){return(0,hs.jsx)("div",{"data-slot":"card",className:Ot("bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm",e),...t})}function Ta({className:e,...t}){return(0,hs.jsx)("div",{"data-slot":"card-header",className:Ot("@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-2 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",e),...t})}function Aa({className:e,...t}){return(0,hs.jsx)("div",{"data-slot":"card-title",className:Ot("leading-none font-semibold",e),...t})}function Xm({className:e,...t}){return(0,hs.jsx)("div",{"data-slot":"card-description",className:Ot("text-muted-foreground text-sm",e),...t})}function dt({className:e,...t}){return(0,hs.jsx)("div",{"data-slot":"card-content",className:Ot("px-6",e),...t})}var y=E(ue(),1),Qm=e=>new Date(e).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"}),lc=(e,t="USD")=>new Intl.NumberFormat("en-US",{style:"currency",currency:t}).format(e),Ym=e=>{switch(e){case"Enterprise":return go;case"Professional":return bi;default:return xi}},uc=e=>{switch(e){case"Enterprise":return"bg-purple-50 text-purple-700 border-purple-200";case"Professional":return"bg-blue-50 text-blue-700 border-blue-200";default:return"bg-gray-50 text-gray-700 border-gray-200"}};function Xi({status:e,type:t="default"}){let r=(()=>{let n=e.toLowerCase();if(t==="transaction")switch(n){case"paid":return{color:"bg-emerald-50 text-emerald-700 border-emerald-200",icon:$e};case"failed":return{color:"bg-red-50 text-red-700 border-red-200",icon:ca};case"pending":return{color:"bg-amber-50 text-amber-700 border-amber-200",icon:mo};case"refunded":return{color:"bg-slate-50 text-slate-700 border-slate-200",icon:kn};default:return{color:"bg-gray-50 text-gray-700 border-gray-200",icon:da}}if(t==="subscription")switch(n){case"active":return{color:"bg-emerald-50 text-emerald-700 border-emerald-200",icon:$e};case"cancelled":return{color:"bg-slate-50 text-slate-700 border-slate-200",icon:ca};case"past_due":return{color:"bg-red-50 text-red-700 border-red-200",icon:da};case"trialing":return{color:"bg-blue-50 text-blue-700 border-blue-200",icon:mo};default:return{color:"bg-gray-50 text-gray-700 border-gray-200",icon:da}}switch(n){case"active":return{color:"bg-emerald-50 text-emerald-700 border-emerald-200",icon:$e};case"inactive":return{color:"bg-slate-50 text-slate-700 border-slate-200",icon:ca};default:return{color:"bg-gray-50 text-gray-700 border-gray-200",icon:da}}})(),o=r.icon;return(0,y.jsxs)("span",{className:`inline-flex items-center gap-1.5 px-2.5 py-1 rounded-full text-xs font-medium border ${r.color}`,children:[(0,y.jsx)(o,{className:"h-3 w-3"}),e]})}function mT({subscription:e}){let t=Ym(e.plan);return(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)("div",{className:`h-1 ${e.status==="active"?"bg-emerald-500":e.status==="past_due"?"bg-red-500":"bg-slate-300"}`}),(0,y.jsx)(Ta,{className:"pb-3",children:(0,y.jsxs)("div",{className:"flex items-start justify-between",children:[(0,y.jsxs)("div",{className:"space-y-1",children:[(0,y.jsxs)(Aa,{className:"text-base font-semibold text-gray-900 flex items-center gap-2",children:[(0,y.jsx)(ho,{className:"h-4 w-4 text-gray-500"}),e.id]}),e.customer_email&&(0,y.jsxs)(Xm,{className:"text-sm text-gray-500 flex items-center gap-1.5",children:[(0,y.jsx)(In,{className:"h-3 w-3"}),e.customer_email]})]}),(0,y.jsx)(Xi,{status:e.status,type:"subscription"})]})}),(0,y.jsx)(dt,{className:"pt-0",children:(0,y.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,y.jsxs)("div",{className:"space-y-3",children:[(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Plan"}),(0,y.jsxs)("span",{className:`inline-flex items-center gap-1.5 px-2.5 py-1 rounded-md text-xs font-medium border ${uc(e.plan)}`,children:[(0,y.jsx)(t,{className:"h-3 w-3"}),e.plan]})]}),(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Billing"}),(0,y.jsxs)("div",{className:"text-sm font-medium text-gray-900",children:[lc(e.amount,e.currency)," / ",e.billing_cycle]})]})]}),(0,y.jsxs)("div",{className:"space-y-3",children:[(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Current Period"}),(0,y.jsxs)("div",{className:"text-sm text-gray-700",children:[Qm(e.current_period_start)," - ",Qm(e.current_period_end)]})]}),(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Created"}),(0,y.jsx)("div",{className:"text-sm text-gray-700",children:Qm(e.created_at)})]})]})]})})]})}function hT({subscriptions:e,maxItems:t=5}){let a=e.slice(0,t),r=e.length>t;return e.length===0?(0,y.jsx)(ut,{className:"border-gray-200 shadow-sm bg-white",children:(0,y.jsxs)(dt,{className:"py-8 text-center",children:[(0,y.jsx)(ho,{className:"h-10 w-10 text-gray-300 mx-auto mb-3"}),(0,y.jsx)("p",{className:"text-sm text-gray-500",children:"No subscriptions found"})]})}):(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(ho,{className:"h-4 w-4"}),e.length," Subscription",e.length!==1?"s":""]})}),(0,y.jsxs)(dt,{className:"p-0",children:[(0,y.jsx)("div",{className:"divide-y divide-gray-100",children:a.map(o=>{let n=Ym(o.plan);return(0,y.jsx)("div",{className:"px-4 py-3 hover:bg-gray-50 transition-colors",children:(0,y.jsxs)("div",{className:"flex items-center justify-between",children:[(0,y.jsxs)("div",{className:"flex items-center gap-3 min-w-0",children:[(0,y.jsx)("div",{className:`p-2 rounded-lg ${uc(o.plan).replace("text-","text-").replace("border-","bg-").split(" ")[0]}`,children:(0,y.jsx)(n,{className:"h-4 w-4"})}),(0,y.jsxs)("div",{className:"min-w-0",children:[(0,y.jsx)("div",{className:"text-sm font-medium text-gray-900 truncate",children:o.customer_email||o.customer_id}),(0,y.jsxs)("div",{className:"text-xs text-gray-500",children:[o.plan," \xB7 ",lc(o.amount,o.currency),"/",o.billing_cycle]})]})]}),(0,y.jsx)(Xi,{status:o.status,type:"subscription"})]})},o.id)})}),r&&(0,y.jsx)("div",{className:"px-4 py-2 bg-gray-50 border-t border-gray-100 text-center",children:(0,y.jsxs)("span",{className:"text-xs text-gray-500",children:["+",e.length-t," more subscription",e.length-t!==1?"s":""]})})]})]})}function gT({customer:e}){let t=Ym(e.subscription);return(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)("div",{className:`h-1 ${e.status==="active"?"bg-emerald-500":"bg-slate-300"}`}),(0,y.jsx)(Ta,{className:"pb-3",children:(0,y.jsxs)("div",{className:"flex items-start justify-between",children:[(0,y.jsx)("div",{className:"flex items-center gap-3",children:(0,y.jsxs)("div",{children:[(0,y.jsx)(Aa,{className:"text-base font-semibold text-gray-900",children:e.name}),(0,y.jsxs)(Xm,{className:"text-sm text-gray-500 flex items-center gap-1",children:[(0,y.jsx)(In,{className:"h-3 w-3"}),e.email]})]})}),(0,y.jsx)(Xi,{status:e.status,type:"customer"})]})}),(0,y.jsx)(dt,{className:"pt-0",children:(0,y.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,y.jsxs)("div",{className:"space-y-3",children:[(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Plan"}),(0,y.jsxs)("span",{className:`inline-flex items-center gap-1.5 px-2.5 py-1 rounded-md text-xs font-medium border ${uc(e.subscription)}`,children:[(0,y.jsx)(t,{className:"h-3 w-3"}),e.subscription]})]}),(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Revenue"}),(0,y.jsxs)("div",{className:"text-sm font-medium text-gray-900 flex items-center gap-1",children:[(0,y.jsx)(xo,{className:"h-3 w-3 text-emerald-500"}),e.revenue]})]})]}),(0,y.jsxs)("div",{className:"space-y-3",children:[(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Location"}),(0,y.jsxs)("div",{className:"text-sm text-gray-700 flex items-center gap-1",children:[(0,y.jsx)(wn,{className:"h-3 w-3 text-gray-400"}),e.location||"Not specified"]})]}),(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-xs text-gray-500 mb-1",children:"Customer Since"}),(0,y.jsxs)("div",{className:"text-sm text-gray-700 flex items-center gap-1",children:[(0,y.jsx)(vi,{className:"h-3 w-3 text-gray-400"}),e.joinDate]})]})]})]})})]})}function xT({customers:e,maxItems:t=5}){let a=e.slice(0,t),r=e.length>t;return e.length===0?(0,y.jsx)(ut,{className:"border-gray-200 shadow-sm bg-white",children:(0,y.jsxs)(dt,{className:"py-8 text-center",children:[(0,y.jsx)(Pn,{className:"h-10 w-10 text-gray-300 mx-auto mb-3"}),(0,y.jsx)("p",{className:"text-sm text-gray-500",children:"No customers found"})]})}):(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(Pn,{className:"h-4 w-4"}),e.length," Customer",e.length!==1?"s":""]})}),(0,y.jsxs)(dt,{className:"p-0",children:[(0,y.jsx)("div",{className:"divide-y divide-gray-100",children:a.map(o=>(0,y.jsx)("div",{className:"px-4 py-3 hover:bg-gray-50 transition-colors",children:(0,y.jsxs)("div",{className:"flex items-center justify-between",children:[(0,y.jsx)("div",{className:"flex items-center gap-3 min-w-0",children:(0,y.jsxs)("div",{className:"min-w-0",children:[(0,y.jsx)("div",{className:"text-sm font-medium text-gray-900 truncate",children:o.name}),(0,y.jsx)("div",{className:"text-xs text-gray-500 truncate",children:o.email})]})}),(0,y.jsxs)("div",{className:"flex items-center gap-2",children:[(0,y.jsx)("span",{className:`px-2 py-0.5 rounded text-xs font-medium ${uc(o.subscription)}`,children:o.subscription}),(0,y.jsx)(Xi,{status:o.status,type:"customer"})]})]})},o.id))}),r&&(0,y.jsx)("div",{className:"px-4 py-2 bg-gray-50 border-t border-gray-100 text-center",children:(0,y.jsxs)("span",{className:"text-xs text-gray-500",children:["+",e.length-t," more customer",e.length-t!==1?"s":""]})})]})]})}function mS({transactions:e,maxItems:t=5}){let a=e.slice(0,t),r=e.length>t;return e.length===0?(0,y.jsx)(ut,{className:"border-gray-200 shadow-sm bg-white",children:(0,y.jsxs)(dt,{className:"py-8 text-center",children:[(0,y.jsx)(xo,{className:"h-10 w-10 text-gray-300 mx-auto mb-3"}),(0,y.jsx)("p",{className:"text-sm text-gray-500",children:"No transactions found"})]})}):(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(xo,{className:"h-4 w-4"}),e.length," Transaction",e.length!==1?"s":""]})}),(0,y.jsxs)(dt,{className:"p-0",children:[(0,y.jsx)("div",{className:"divide-y divide-gray-100",children:a.map(o=>(0,y.jsx)("div",{className:"px-4 py-3 hover:bg-gray-50 transition-colors",children:(0,y.jsxs)("div",{className:"flex items-center justify-between",children:[(0,y.jsxs)("div",{className:"flex items-center gap-3 min-w-0",children:[(0,y.jsx)("div",{className:`p-2 rounded-lg ${o.status==="paid"?"bg-emerald-50":o.status==="failed"?"bg-red-50":o.status==="refunded"?"bg-slate-50":"bg-amber-50"}`,children:o.status==="paid"?(0,y.jsx)($e,{className:"h-4 w-4 text-emerald-600"}):o.status==="failed"?(0,y.jsx)(ca,{className:"h-4 w-4 text-red-600"}):o.status==="refunded"?(0,y.jsx)(kn,{className:"h-4 w-4 text-slate-600"}):(0,y.jsx)(mo,{className:"h-4 w-4 text-amber-600"})}),(0,y.jsxs)("div",{className:"min-w-0",children:[(0,y.jsx)("div",{className:"text-sm font-medium text-gray-900 truncate",children:o.customer}),(0,y.jsxs)("div",{className:"text-xs text-gray-500",children:[o.date,o.decline_reason&&(0,y.jsxs)("span",{className:"text-red-500 ml-2",children:["\xB7 ",o.decline_reason]})]})]})]}),(0,y.jsxs)("div",{className:"flex items-center gap-3",children:[(0,y.jsxs)("span",{className:`text-sm font-semibold ${o.status==="paid"?"text-emerald-600":o.status==="failed"?"text-red-600":o.status==="refunded"?"text-slate-600":"text-amber-600"}`,children:[o.status==="refunded"?"-":"",o.amount]}),(0,y.jsx)(Xi,{status:o.status,type:"transaction"})]})]})},o.id))}),r&&(0,y.jsx)("div",{className:"px-4 py-2 bg-gray-50 border-t border-gray-100 text-center",children:(0,y.jsxs)("span",{className:"text-xs text-gray-500",children:["+",e.length-t," more transaction",e.length-t!==1?"s":""]})})]})]})}function yT({apiKeys:e}){return e.length===0?(0,y.jsx)(ut,{className:"border-gray-200 shadow-sm bg-white",children:(0,y.jsxs)(dt,{className:"py-8 text-center",children:[(0,y.jsx)(Sn,{className:"h-10 w-10 text-gray-300 mx-auto mb-3"}),(0,y.jsx)("p",{className:"text-sm text-gray-500",children:"No API keys found"})]})}):(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(Sn,{className:"h-4 w-4"}),e.length," API Key",e.length!==1?"s":""]})}),(0,y.jsx)(dt,{className:"p-0",children:(0,y.jsx)("div",{className:"divide-y divide-gray-100",children:e.map((t,a)=>(0,y.jsx)("div",{className:"px-4 py-3 hover:bg-gray-50 transition-colors",children:(0,y.jsxs)("div",{className:"flex items-center justify-between",children:[(0,y.jsxs)("div",{className:"min-w-0",children:[(0,y.jsx)("div",{className:"text-sm font-medium text-gray-900",children:t.name}),(0,y.jsxs)("div",{className:"text-xs text-gray-500 font-mono",children:[t.key.slice(0,12),"...",t.key.slice(-4)]})]}),(0,y.jsxs)("div",{className:"text-xs text-gray-500",children:["Last used: ",t.lastUsed]})]})},a))})})]})}function vT({sessions:e}){let t=a=>{let r=a.toLowerCase();return r.includes("mobile")||r.includes("iphone")||r.includes("android")?wi:Ci};return e.length===0?(0,y.jsx)(ut,{className:"border-gray-200 shadow-sm bg-white",children:(0,y.jsxs)(dt,{className:"py-8 text-center",children:[(0,y.jsx)(bn,{className:"h-10 w-10 text-gray-300 mx-auto mb-3"}),(0,y.jsx)("p",{className:"text-sm text-gray-500",children:"No active sessions"})]})}):(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(bn,{className:"h-4 w-4"}),e.length," Active Session",e.length!==1?"s":""]})}),(0,y.jsx)(dt,{className:"p-0",children:(0,y.jsx)("div",{className:"divide-y divide-gray-100",children:e.map((a,r)=>{let o=t(a.device);return(0,y.jsx)("div",{className:"px-4 py-3 hover:bg-gray-50 transition-colors",children:(0,y.jsxs)("div",{className:"flex items-center justify-between",children:[(0,y.jsxs)("div",{className:"flex items-center gap-3",children:[(0,y.jsx)("div",{className:"p-2 rounded-lg bg-gray-100",children:(0,y.jsx)(o,{className:"h-4 w-4 text-gray-600"})}),(0,y.jsxs)("div",{children:[(0,y.jsx)("div",{className:"text-sm font-medium text-gray-900",children:a.device}),(0,y.jsxs)("div",{className:"text-xs text-gray-500 flex items-center gap-1",children:[(0,y.jsx)(wn,{className:"h-3 w-3"}),a.location]})]})]}),(0,y.jsx)("div",{className:"text-xs text-gray-500",children:a.time})]})},r)})})})]})}function LT({stats:e}){return(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(ki,{className:"h-4 w-4"}),"Dashboard Overview"]})}),(0,y.jsx)(dt,{className:"p-4",children:(0,y.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[e.revenue&&(0,y.jsxs)("div",{className:"p-3 rounded-lg bg-emerald-50 border border-emerald-100",children:[(0,y.jsx)("div",{className:"text-xs text-emerald-600 font-medium mb-1",children:"Revenue"}),(0,y.jsx)("div",{className:"text-lg font-bold text-emerald-700",children:lc(e.revenue.total)}),e.revenue.change!==0&&(0,y.jsxs)("div",{className:`text-xs ${e.revenue.change>0?"text-emerald-600":"text-red-600"}`,children:[e.revenue.change>0?"+":"",e.revenue.change,"% from last period"]})]}),e.subscriptions&&(0,y.jsxs)("div",{className:"p-3 rounded-lg bg-blue-50 border border-blue-100",children:[(0,y.jsx)("div",{className:"text-xs text-blue-600 font-medium mb-1",children:"Subscriptions"}),(0,y.jsxs)("div",{className:"text-lg font-bold text-blue-700",children:[e.subscriptions.active," active"]}),(0,y.jsxs)("div",{className:"text-xs text-blue-600",children:[e.subscriptions.total," total"]})]}),e.customers&&(0,y.jsxs)("div",{className:"p-3 rounded-lg bg-purple-50 border border-purple-100",children:[(0,y.jsx)("div",{className:"text-xs text-purple-600 font-medium mb-1",children:"Customers"}),(0,y.jsx)("div",{className:"text-lg font-bold text-purple-700",children:e.customers.total}),e.customers.new>0&&(0,y.jsxs)("div",{className:"text-xs text-purple-600",children:["+",e.customers.new," new this period"]})]}),e.transactions&&(0,y.jsxs)("div",{className:"p-3 rounded-lg bg-amber-50 border border-amber-100",children:[(0,y.jsx)("div",{className:"text-xs text-amber-600 font-medium mb-1",children:"Transactions"}),(0,y.jsxs)("div",{className:"text-lg font-bold text-amber-700",children:[e.transactions.successful," successful"]}),e.transactions.failed>0&&(0,y.jsxs)("div",{className:"text-xs text-red-600",children:[e.transactions.failed," failed"]})]})]})})]})}function CT({customers:e}){return e.length===0?(0,y.jsx)(ut,{className:"border-gray-200 shadow-sm bg-white",children:(0,y.jsxs)(dt,{className:"py-8 text-center",children:[(0,y.jsx)(go,{className:"h-10 w-10 text-gray-300 mx-auto mb-3"}),(0,y.jsx)("p",{className:"text-sm text-gray-500",children:"No top customers data"})]})}):(0,y.jsxs)(ut,{className:"border-gray-200 shadow-sm bg-white overflow-hidden",children:[(0,y.jsx)(Ta,{className:"pb-2 border-b border-gray-100",children:(0,y.jsxs)(Aa,{className:"text-sm font-medium text-gray-700 flex items-center gap-2",children:[(0,y.jsx)(go,{className:"h-4 w-4 text-amber-500"}),"Top Customers"]})}),(0,y.jsx)(dt,{className:"p-0",children:(0,y.jsx)("div",{className:"divide-y divide-gray-100",children:e.map((t,a)=>(0,y.jsx)("div",{className:"px-4 py-3 hover:bg-gray-50 transition-colors",children:(0,y.jsxs)("div",{className:"flex items-center justify-between",children:[(0,y.jsxs)("div",{className:"flex items-center gap-3 min-w-0",children:[(0,y.jsx)("div",{className:`h-6 w-6 rounded-full flex items-center justify-center text-xs font-bold ${a===0?"bg-amber-100 text-amber-700":a===1?"bg-slate-100 text-slate-700":a===2?"bg-orange-100 text-orange-700":"bg-gray-100 text-gray-700"}`,children:a+1}),(0,y.jsxs)("div",{className:"min-w-0",children:[(0,y.jsx)("div",{className:"text-sm font-medium text-gray-900 truncate",children:t.name}),(0,y.jsx)("div",{className:"text-xs text-gray-500 truncate",children:t.email})]})]}),(0,y.jsx)("div",{className:"text-sm font-semibold text-emerald-600",children:typeof t.revenue=="number"?lc(t.revenue):t.revenue})]})},a))})})]})}function hS({type:e,data:t}){if(!t)return null;switch(e){case"subscription":return(0,y.jsx)(mT,{subscription:t});case"subscriptions":let a=t.subscriptions||t||[];return(0,y.jsx)(hT,{subscriptions:Array.isArray(a)?a:[a]});case"customer":return(0,y.jsx)(gT,{customer:t.customer||t});case"customers":let r=t.customers||t||[];return(0,y.jsx)(xT,{customers:Array.isArray(r)?r:[r]});case"transactions":let o=t.transactions||t||[];return(0,y.jsx)(mS,{transactions:Array.isArray(o)?o:[o]});case"transaction":return(0,y.jsx)(mS,{transactions:[t],maxItems:1});case"dashboard_stats":return(0,y.jsx)(LT,{stats:t});case"top_customers":let n=t.customers||t||[];return(0,y.jsx)(CT,{customers:Array.isArray(n)?n:[n]});case"api_keys":let s=t.api_keys||t||[];return(0,y.jsx)(yT,{apiKeys:Array.isArray(s)?s:[s]});case"sessions":let i=t.sessions||t||[];return(0,y.jsx)(vT,{sessions:Array.isArray(i)?i:[i]});default:return null}}var f=E(ue(),1),ST="http://localhost:5002",yS=340;function IT(e){return e.replace(/\\\\n/g,`
|
|
17
17
|
`).replace(/\\\\t/g," ").replace(/\\\\"/g,'"').replace(/\\\\\\\\/g,"\\").replace(/\\n/g,`
|
|
18
|
-
`).replace(/\\t/g," ").replace(/\\"/g,'"').replace(/\\\\/g,"\\")}function
|
|
18
|
+
`).replace(/\\t/g," ").replace(/\\"/g,'"').replace(/\\\\/g,"\\")}function gS(e){if(!e)return null;let t=e.split(`
|
|
19
19
|
`),a=[],r=null,o=!1,n=[],s="",i=u=>{let d=[],c=u,p=0;for(;c.length>0;){let g=c.match(/^`([^`]+)`/);if(g){d.push((0,f.jsx)("code",{className:"bg-gray-100 px-1 py-0.5 rounded text-xs font-mono",children:g[1]},p++)),c=c.slice(g[0].length);continue}let C=c.match(/^\*\*([^*]+)\*\*/);if(C){d.push((0,f.jsx)("strong",{children:C[1]},p++)),c=c.slice(C[0].length);continue}let L=c.match(/^\*([^*]+)\*/);if(L){d.push((0,f.jsx)("em",{children:L[1]},p++)),c=c.slice(L[0].length);continue}let S=c.match(/^\[([^\]]+)\]\(([^)]+)\)/);if(S){d.push((0,f.jsx)("a",{href:S[2],className:"kite-link",target:"_blank",rel:"noopener noreferrer",children:S[1]},p++)),c=c.slice(S[0].length);continue}let h=c.match(/^(https?:\/\/[^\s<>]+|www\.[^\s<>]+)/);if(h){let I=h[1],k=I.startsWith("www.")?`https://${I}`:I;d.push((0,f.jsx)("a",{href:k,className:"kite-link",target:"_blank",rel:"noopener noreferrer",children:I},p++)),c=c.slice(I.length);continue}let m=c.match(/^([a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,})/);if(m){let I=m[1];d.push((0,f.jsx)("a",{href:`mailto:${I}`,className:"kite-link",children:I},p++)),c=c.slice(I.length);continue}let x=c.search(/[`*\[@h]/);if(x===-1){d.push(c);break}else x===0?(d.push(c[0]),c=c.slice(1)):(d.push(c.slice(0,x)),c=c.slice(x))}return d.length===1?d[0]:(0,f.jsx)(f.Fragment,{children:d})},l=()=>{if(r){let u=r.type==="ul"?"ul":"ol";a.push((0,f.jsx)(u,{className:`${r.type==="ul"?"list-disc":"list-decimal"} ml-4 my-1`,children:r.items.map((d,c)=>(0,f.jsx)("li",{className:"ml-2",children:d},c))},a.length)),r=null}};for(let u=0;u<t.length;u++){let d=t[u];if(d.startsWith("```")){o?(a.push((0,f.jsx)("pre",{className:"bg-gray-100 rounded p-2 my-1 overflow-x-auto",children:(0,f.jsx)("code",{className:"text-xs font-mono",children:n.join(`
|
|
20
|
-
`)})},a.length)),o=!1,n=[],s=""):(l(),o=!0,s=d.slice(3).trim());continue}if(o){n.push(d);continue}let c=d.match(/^(#{1,6})\s+(.+)/);if(c){l();let C=c[1].length,L=i(c[2]),S=C===1?"text-lg font-bold my-1":C===2?"text-base font-bold my-1":"text-sm font-semibold my-1";a.push((0,f.jsx)("div",{className:S,children:L},a.length));continue}let p=d.match(/^[-*]\s+(.+)/);if(p){(!r||r.type!=="ul")&&(l(),r={type:"ul",items:[]}),r.items.push(i(p[1]));continue}let g=d.match(/^\d+[.)]\s+(.+)/);if(g){(!r||r.type!=="ol")&&(l(),r={type:"ol",items:[]}),r.items.push(i(g[1]));continue}if(d.trim()===""){l(),a.push((0,f.jsx)("div",{className:"h-2"},a.length));continue}if(d.match(/^[-*_]{3,}$/)){l(),a.push((0,f.jsx)("hr",{className:"my-2 border-gray-200"},a.length));continue}l(),a.push((0,f.jsx)("div",{children:i(d)},a.length))}return l(),(0,f.jsx)(f.Fragment,{children:a})}var ST=[{id:"changing-layouts",label:"Changing layouts",prompt:"How do I change the layout of my profiles or folders?",icon:"layout"},{id:"bulk-uploads",label:"Bulk uploads",prompt:"How do I bulk upload profiles using a CSV file?",icon:"upload"},{id:"example-setups",label:"Example setups",prompt:"Can you show me some example folder setups?",icon:"setup"}],gS=[{id:"customers",title:"Customer Management",topics:[{id:"add-customer",label:"Add a new customer",prompt:"How do I add a new customer to the system and what information is required?"},{id:"customer-details",label:"View customer details",prompt:"Show me how to view and edit customer information and their payment history."}]},{id:"payments",title:"Payment Processing",topics:[{id:"process-payment",label:"Process a payment",prompt:"How do I process a one-time payment for a customer?"},{id:"refund-payment",label:"Issue a refund",prompt:"Walk me through issuing a refund for a customer payment."}]},{id:"subscriptions",title:"Subscription Management",topics:[{id:"create-subscription",label:"Create a subscription",prompt:"How do I set up a new subscription plan for a customer?"},{id:"update-subscription",label:"Update subscription tier",prompt:"How can I change a customer's subscription plan or upgrade them?"}]},{id:"billing",title:"Billing",topics:[{id:"payment-methods",label:"Manage payment methods",prompt:"How do customers add or update their payment methods?"}]}],Ym={"getting-started":{id:"getting-started",title:"Getting started",steps:[{text:"Step 1: Let's open the Customers page. This is where you'll manage all your customers - you can view, add, and edit customer information here.",navigation:{page:"customers"},cursorTarget:{selector:'[data-page="customers"]',offset:{x:0,y:0},onClick:!0}},{text:"Step 2: Now let's open the Add customer dialog. This is where you'll enter information for your first customer, including their name, email, and other details.",navigation:{page:"customers"},cursorTarget:{selector:'[data-testid="add-customer-button"]',offset:{x:0,y:0},onClick:!0}},{text:"Step 3: Let's open the Settings page. This is where you manage your account settings, company information, and preferences. We're going to verify your company address is correct.",navigation:{page:"settings",subtab:"general"},cursorTarget:{selector:'[data-page="settings"]',offset:{x:0,y:0},onClick:!0}},{text:"Step 4: Here's the address field in the Company Information section. It's important to verify this address is accurate since it's used for billing and shipping purposes. Make sure it's up to date.",navigation:{page:"settings",subtab:"general"},cursorTarget:{selector:'[data-testid="company-address-input"]',offset:{x:0,y:0},onClick:!1}},{text:"Step 5: Let's open the API Keys tab. This section shows all your API keys - you'll need these to connect your application to our services. We're going to create a production API key.",navigation:{page:"settings",subtab:"api"},cursorTarget:{selector:'[data-settings-tab="api"]',offset:{x:0,y:0},onClick:!0}},{text:"Step 6: Let's open the Create API Key dialog. Here you can create a new API key for your application. You'll want to give it a descriptive name like 'Production Key' so you can easily identify it later.",navigation:{page:"settings",subtab:"api"},cursorTarget:{selector:'[data-testid="create-api-key-button"]',offset:{x:0,y:0},onClick:!0}}]},"add-api-key":{id:"add-api-key",title:"How to add an API key",steps:[{text:"Step 1: Let's open the Settings page. This is where you manage your account settings and preferences. We need to go here to access the API Keys section.",navigation:{page:"settings",subtab:"general"},cursorTarget:{selector:'[data-page="settings"]',offset:{x:0,y:0},onClick:!1}},{text:"Step 2: Let's open the API Keys tab. This section shows all your API keys and allows you to create new ones. You'll need API keys to connect your application to our services.",navigation:{page:"settings",subtab:"api"},cursorTarget:{selector:'[data-settings-tab="api"]',offset:{x:0,y:0},onClick:!0}},{text:"Step 3: Let's open the Create API Key dialog. This is where you'll create your new API key - you can give it a name to help you identify it later, then click Create to generate it.",navigation:{page:"settings",subtab:"api"},cursorTarget:{selector:'[data-testid="create-api-key-button"]',offset:{x:0,y:0},onClick:!0}}]},"refund-payment":{id:"refund-payment",title:"How to refund a payment",steps:[{text:"Step 1: Let's open the Home page. This is your dashboard where you can view today's activity, your payment overview, and recent transactions. We need to go here to find the payment you want to refund.",navigation:{page:"dashboard"},cursorTarget:{selector:'[data-page="dashboard"]',offset:{x:0,y:0},onClick:!0}},{text:"Step 2: Scroll down to see the Recent transactions section at the bottom. This shows your latest payment transactions with their status. We're looking for a transaction with 'paid' status - only paid transactions can be refunded.",navigation:{page:"dashboard"},cursorTarget:{selector:'[data-testid="recent-activity-card"]',offset:{x:0,y:0},onClick:!1}},{text:"Step 3: Let's open the dropdown menu for this paid transaction. Each transaction has a menu button (three dots) that gives you options like refunding. Click it to see the available actions, including the 'Refund payment' option.",navigation:{page:"dashboard"},cursorTarget:{selector:'[data-testid="transaction-menu-button"]',offset:{x:0,y:0},onClick:!0}}]}},IT=[];function wT({isOpen:e=!0,onClose:t,onOpen:a,onBack:r,onNavigate:o,onActionComplete:n,currentPage:s,agentUrl:i=LT,startingQuestions:l,startingQuestionsEndpoint:u,userId:d,orgId:c,userName:p,userEmail:g,userOrganization:C}={}){let[L,S]=j.useState(IT),[h,m]=j.useState(""),[x,I]=j.useState(()=>crypto.randomUUID()),[k,T]=j.useState(!1),R=j.useRef(null),A=j.useCallback(()=>{I(crypto.randomUUID()),T(!1),R.current&&(R.current.close(),R.current=null)},[]),V=j.useRef({}),U=L.length===0,[se,q]=j.useState("idle"),[No,ie]=j.useState([]),Wt=j.useRef([]),Xr=L.length?L[L.length-1].role:void 0,[Ae,Be]=j.useState("landing"),[Gt,Rt]=j.useState(void 0),[ea,eh]=j.useState(l||ST),[LS,th]=j.useState(!1);j.useEffect(()=>{u&&!l&&(th(!0),fetch(u).then(v=>v.json()).then(v=>{Array.isArray(v)&&v.length>0&&eh(v)}).catch(v=>{console.warn("[KiteChat] Failed to fetch starting questions:",v)}).finally(()=>th(!1)))},[u,l]),j.useEffect(()=>{l&&eh(l)},[l]);let[me,Qr]=j.useState(void 0),Me=j.useRef(void 0),ah=j.useRef(null),[xs,Xi]=j.useState(!1);j.useEffect(()=>{window.resetIntegrationNotification=()=>{localStorage.removeItem("gmailNotificationSeen"),console.log("Integration notification reset! Click the Integrations tab to see it again.")};let v=()=>{if(!localStorage.getItem("gmailNotificationSeen")){Be("landing"),Rt(void 0);let B=Date.now(),F="I see you're exploring integrations. Let me know if there are any other connections we should add.",N={id:B,role:"assistant",kind:"text",content:"",isNotificationMessage:!0};S(Y=>[...Y,N]),Da(B,F),localStorage.setItem("gmailNotificationSeen","true")}};return window.addEventListener("integrationTabClicked",v),()=>{window.removeEventListener("integrationTabClicked",v)}},[]),j.useEffect(()=>{me?(!Me.current||Me.current.id!==me.id||Me.current.stepIndex!==me.stepIndex)&&(Me.current=me):Me.current=void 0},[me]);let[ys,Qi]=j.useState(null),[qe,uc]=j.useState(null),[re,oe]=j.useState({}),rh=j.useRef(null),dc=j.useRef(null),Yi=j.useRef(null),{cursorState:Zi,moveTo:Yr,hide:Eo}=fS(),[Zr,cc]=j.useState(null),[oh,nr]=j.useState(null),fc=j.useRef(null),Fo=j.useRef(null),[nh,vs]=j.useState(!1),[Bo,Ji]=j.useState(""),sh=j.useRef(null);j.useEffect(()=>{if(!me||me.id!=="add-api-key"||me.stepIndex!==2)return;let b=setInterval(()=>{let B=document.querySelector('[role="dialog"]'),F=Me.current;if(B&&F&&F.id==="add-api-key"&&F.stepIndex===2){Eo();let N=Date.now()+1;S(Y=>[...Y,{id:N,role:"assistant",kind:"guideComplete",content:"Perfect! The dialog is now open. You can enter a name and create your API key."}]),Qr(void 0),Xi(!0)}},300);return()=>clearInterval(b)},[me,Eo]),j.useEffect(()=>()=>{Object.values(V.current).forEach(v=>window.clearInterval(v)),V.current={},Wt.current.forEach(v=>window.clearTimeout(v)),Wt.current=[]},[]),j.useEffect(()=>{if(me&&L.length>0){let v=L[L.length-1];if((v.kind==="guideStep"||v.kind==="guideComplete")&&Yi.current&&dc.current){let b=dc.current,B=Yi.current,F=b.getBoundingClientRect(),Y=B.getBoundingClientRect().top-F.top+b.scrollTop;b.scrollTop=Y}}else!me&&L.length>0&&rh.current?.scrollIntoView({behavior:"smooth"})},[L,se,me]);let ih=j.useMemo(()=>{for(let v=L.length-1;v>=0;v--){let b=L[v];if(b.kind==="bulkSummary"&&b.bulkSummary?.navigationPage&&b.bulkSummary.successes>0)return b.bulkSummary.navigationPage}return null},[L]);j.useEffect(()=>{ah.current=ih},[ih]),j.useEffect(()=>{fc.current=oh},[oh]),j.useEffect(()=>{let v=b=>{if((b.metaKey||b.ctrlKey)&&b.key==="Enter"){let B=fc.current;if(B){b.preventDefault(),b.stopPropagation(),hc(B);return}if(qe){b.preventDefault(),b.stopPropagation(),mc();return}if(ys){b.preventDefault(),b.stopPropagation(),pc(ys);return}let F=ah.current;if(console.log("[DEBUG] Keyboard handler - latestBulkSummaryNavigation:",F,"onNavigate:",!!o),F&&o){console.log("[DEBUG] Navigating via keyboard to:",F.page),b.preventDefault(),b.stopPropagation(),o(F.page,F.subtab);return}if(xs){b.preventDefault(),b.stopPropagation(),uh();return}if(Me.current){b.preventDefault(),b.stopPropagation(),gc();return}}};return window.addEventListener("keydown",v),()=>window.removeEventListener("keydown",v)},[qe,ys,me,xs,o]);let lh=j.useCallback(v=>{if(!i)return;R.current&&R.current.close();let b=i.replace(/^http/,"ws")+`/ws/escalation/${v}`,B=new WebSocket(b);B.onmessage=F=>{try{let N=JSON.parse(F.data);N.type==="agent_message"?S(Y=>{let Q=N.content,P=N.message_id;return(P?Y.some(w=>w.serverMessageId===P):Y.slice(-5).some(w=>w.content===Q))?(console.debug("[KiteChat] Skipping duplicate agent message:",P||Q.slice(0,30)),Y):[...Y,{id:Date.now(),role:"agent",kind:"text",content:Q,serverMessageId:P}]}):N.type==="error"&&console.error("[KiteChat] Escalation error:",N.message)}catch(N){console.error("[KiteChat] Failed to parse escalation message:",N)}},B.onerror=F=>{console.error("[KiteChat] Escalation WebSocket error:",F)},B.onclose=()=>{console.log("[KiteChat] Escalation WebSocket closed")},R.current=B},[i]),CS=j.useCallback(async v=>{if(!R.current||R.current.readyState!==WebSocket.OPEN)return console.error("[KiteChat] Escalation WebSocket not connected"),!1;try{return R.current.send(JSON.stringify({type:"user_message",content:v})),!0}catch(b){return console.error("[KiteChat] Failed to send escalated message:",b),!1}},[]);j.useEffect(()=>()=>{R.current&&R.current.close()},[]),j.useEffect(()=>{k&&x&&lh(x)},[k,x,lh]);function Da(v,b,B){let F=b||"",N=B;if(b&&b.startsWith("{")&&b.includes('"response"'))try{let M=0,w=0;for(let K=0;K<b.length;K++)if(b[K]==="{")M++;else if(b[K]==="}"&&(M--,M===0)){w=K+1;break}let $=w>0?b.slice(0,w):b,ee=JSON.parse($);ee.response&&typeof ee.response=="string"&&(F=ee.response,!N&&ee.followups&&(N=ee.followups))}catch{}F=CT(F);let Y=F.split(" "),Q=0,P=window.setInterval(()=>{Q+=1,S(M=>M.map(w=>w.id===v?{...w,content:Y.slice(0,Q).join(" ")}:w)),Q>=Y.length&&(window.clearInterval(P),delete V.current[v],N&&N.length>0&&S(M=>M.map(w=>w.id===v?{...w,followups:N}:w)),q("idle"))},25);V.current[v]=P}function SS(v,b){S(B=>B.map(F=>F.id===v?{...F,followupSelected:!0}:F)),el(b.label)}function uh(){Object.values(V.current).forEach(v=>window.clearInterval(v)),V.current={},Wt.current.forEach(v=>window.clearTimeout(v)),Wt.current=[],Eo(),A(),S([]),m(""),q("idle"),Be("landing"),Rt(void 0),Qr(void 0),Xi(!1),Qi(null),uc(null),oe({}),r&&r()}function AT(v){Be("folder"),Rt(v)}function IS(){Be("landing"),Rt(void 0)}function wS(v){v.preventDefault();let b=h.trim();if(Zr){if(!b){let B={id:Date.now(),role:"assistant",kind:"text",content:"Please describe what you'd like to do with this CSV file. For example: 'Create customers from this file' or 'Add these subscriptions'."};S(F=>[...F,B]);return}bS(b,Zr),m(""),cc(null),Fo.current&&(Fo.current.value="");return}if(b){if(k){let B={id:Date.now(),role:"user",content:b};S(F=>[...F,B]),CS(b),m("");return}el(b),m("")}}function kS(v){let b={dashboard:"dashboard",customers:"customers page",payments:"payments page",settings:"settings page",support:"support page",disputes:"disputes page",radar:"radar page"};if(v.page==="settings"&&v.subtab){let B={general:"General",billing:"Billing",security:"Security",api:"API Keys",notifications:"Notifications",integrations:"Integrations"};return`${b.settings} (${B[v.subtab]} tab)`}return b[v.page]}function pc(v){o&&o(v.page,v.subtab),Qi(null),S(b=>b.map(B=>B.kind==="navigationAction"&&B.navigationTarget?.page===v.page&&B.navigationTarget?.subtab===v.subtab?{...B,navigationTarget:void 0}:B))}function mc(){if(!qe)return;let v=re;if(qe.type!=="updateCompanyInfo"){if(qe.type==="addApiKey"){let b=v;if(!b.name||!b.name.trim())return}else if(qe.type==="addCustomer"){let b=v;if(!b.name||!b.name.trim()||!b.email||!b.email.trim())return}else if(qe.type==="changePassword"){let b=v;if(!b.currentPassword||!b.newPassword||!b.confirmPassword||b.newPassword!==b.confirmPassword)return}else if(qe.type==="addWebhook"){let b=v;if(!b.url||!b.url.trim())return}else if(qe.type==="addPaymentMethod"){let b=v;if(!b.cardNumber||!b.expiryDate)return}else if(qe.type==="deleteApiKey"){let b=v;if(!b.keyId&&!b.name)return}else if(qe.type==="refundPayment"){let b=v;if(!b.transactionId&&!b.customer)return}else if(qe.type==="createSubscription"){let b=v;if(!b.customerEmail&&!b.customerId)return}else if((qe.type==="toggleBlockRule"||qe.type==="enableBlockRule"||qe.type==="disableBlockRule")&&!v.ruleId)return}n&&n(qe.type,v),S(b=>b.map(B=>B.kind==="actionForm"&&B.actionType===qe.type?{...B,isSubmitted:!0}:B)),uc(null),oe({})}async function el(v){Wt.current.forEach(Q=>window.clearTimeout(Q)),Wt.current=[];let B=[...L].reverse().find(Q=>Q.role==="assistant")?.isNotificationMessage===!0,F=Date.now(),N={id:F,role:"user",content:v};if(S(Q=>Q.map(P=>P.followups&&P.followups.length>0?{...P,followupSelected:!0}:P).concat(N)),B){let Q=Date.now()+1,P={id:Q,role:"assistant",kind:"text",content:""};S(M=>[...M,P]),Da(Q,"Thank you, your feedback is saved.");return}Qi(null),q("thinking"),ie([]);let Y=!1;try{let Q=new AbortController,P=setTimeout(()=>Q.abort(),6e4),M=await fetch(`${i}/chat/stream`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({session_id:x,message:v,current_page:s||"dashboard",user_id:d,user_name:p,user_email:g,user_organization:C,org_id:c}),signal:Q.signal});if(clearTimeout(P),!M.ok)throw new Error(`Agent request failed: ${M.status}`);let w=M.body?.getReader();if(!w)throw new Error("No response body");let $=new TextDecoder,ee="";for(;;){let{done:K,value:fe}=await w.read();if(K)break;ee+=$.decode(fe,{stream:!0});let We=ee.split(`
|
|
20
|
+
`)})},a.length)),o=!1,n=[],s=""):(l(),o=!0,s=d.slice(3).trim());continue}if(o){n.push(d);continue}let c=d.match(/^(#{1,6})\s+(.+)/);if(c){l();let C=c[1].length,L=i(c[2]),S=C===1?"text-lg font-bold my-1":C===2?"text-base font-bold my-1":"text-sm font-semibold my-1";a.push((0,f.jsx)("div",{className:S,children:L},a.length));continue}let p=d.match(/^[-*]\s+(.+)/);if(p){(!r||r.type!=="ul")&&(l(),r={type:"ul",items:[]}),r.items.push(i(p[1]));continue}let g=d.match(/^\d+[.)]\s+(.+)/);if(g){(!r||r.type!=="ol")&&(l(),r={type:"ol",items:[]}),r.items.push(i(g[1]));continue}if(d.trim()===""){l(),a.push((0,f.jsx)("div",{className:"h-2"},a.length));continue}if(d.match(/^[-*_]{3,}$/)){l(),a.push((0,f.jsx)("hr",{className:"my-2 border-gray-200"},a.length));continue}l(),a.push((0,f.jsx)("div",{children:i(d)},a.length))}return l(),(0,f.jsx)(f.Fragment,{children:a})}var wT=[{id:"changing-layouts",label:"Changing layouts",prompt:"How do I change the layout of my profiles or folders?",icon:"layout"},{id:"bulk-uploads",label:"Bulk uploads",prompt:"How do I bulk upload profiles using a CSV file?",icon:"upload"},{id:"example-setups",label:"Example setups",prompt:"Can you show me some example folder setups?",icon:"setup"}],xS=[{id:"customers",title:"Customer Management",topics:[{id:"add-customer",label:"Add a new customer",prompt:"How do I add a new customer to the system and what information is required?"},{id:"customer-details",label:"View customer details",prompt:"Show me how to view and edit customer information and their payment history."}]},{id:"payments",title:"Payment Processing",topics:[{id:"process-payment",label:"Process a payment",prompt:"How do I process a one-time payment for a customer?"},{id:"refund-payment",label:"Issue a refund",prompt:"Walk me through issuing a refund for a customer payment."}]},{id:"subscriptions",title:"Subscription Management",topics:[{id:"create-subscription",label:"Create a subscription",prompt:"How do I set up a new subscription plan for a customer?"},{id:"update-subscription",label:"Update subscription tier",prompt:"How can I change a customer's subscription plan or upgrade them?"}]},{id:"billing",title:"Billing",topics:[{id:"payment-methods",label:"Manage payment methods",prompt:"How do customers add or update their payment methods?"}]}],Zm={"getting-started":{id:"getting-started",title:"Getting started",steps:[{text:"Step 1: Let's open the Customers page. This is where you'll manage all your customers - you can view, add, and edit customer information here.",navigation:{page:"customers"},cursorTarget:{selector:'[data-page="customers"]',offset:{x:0,y:0},onClick:!0}},{text:"Step 2: Now let's open the Add customer dialog. This is where you'll enter information for your first customer, including their name, email, and other details.",navigation:{page:"customers"},cursorTarget:{selector:'[data-testid="add-customer-button"]',offset:{x:0,y:0},onClick:!0}},{text:"Step 3: Let's open the Settings page. This is where you manage your account settings, company information, and preferences. We're going to verify your company address is correct.",navigation:{page:"settings",subtab:"general"},cursorTarget:{selector:'[data-page="settings"]',offset:{x:0,y:0},onClick:!0}},{text:"Step 4: Here's the address field in the Company Information section. It's important to verify this address is accurate since it's used for billing and shipping purposes. Make sure it's up to date.",navigation:{page:"settings",subtab:"general"},cursorTarget:{selector:'[data-testid="company-address-input"]',offset:{x:0,y:0},onClick:!1}},{text:"Step 5: Let's open the API Keys tab. This section shows all your API keys - you'll need these to connect your application to our services. We're going to create a production API key.",navigation:{page:"settings",subtab:"api"},cursorTarget:{selector:'[data-settings-tab="api"]',offset:{x:0,y:0},onClick:!0}},{text:"Step 6: Let's open the Create API Key dialog. Here you can create a new API key for your application. You'll want to give it a descriptive name like 'Production Key' so you can easily identify it later.",navigation:{page:"settings",subtab:"api"},cursorTarget:{selector:'[data-testid="create-api-key-button"]',offset:{x:0,y:0},onClick:!0}}]},"add-api-key":{id:"add-api-key",title:"How to add an API key",steps:[{text:"Step 1: Let's open the Settings page. This is where you manage your account settings and preferences. We need to go here to access the API Keys section.",navigation:{page:"settings",subtab:"general"},cursorTarget:{selector:'[data-page="settings"]',offset:{x:0,y:0},onClick:!1}},{text:"Step 2: Let's open the API Keys tab. This section shows all your API keys and allows you to create new ones. You'll need API keys to connect your application to our services.",navigation:{page:"settings",subtab:"api"},cursorTarget:{selector:'[data-settings-tab="api"]',offset:{x:0,y:0},onClick:!0}},{text:"Step 3: Let's open the Create API Key dialog. This is where you'll create your new API key - you can give it a name to help you identify it later, then click Create to generate it.",navigation:{page:"settings",subtab:"api"},cursorTarget:{selector:'[data-testid="create-api-key-button"]',offset:{x:0,y:0},onClick:!0}}]},"refund-payment":{id:"refund-payment",title:"How to refund a payment",steps:[{text:"Step 1: Let's open the Home page. This is your dashboard where you can view today's activity, your payment overview, and recent transactions. We need to go here to find the payment you want to refund.",navigation:{page:"dashboard"},cursorTarget:{selector:'[data-page="dashboard"]',offset:{x:0,y:0},onClick:!0}},{text:"Step 2: Scroll down to see the Recent transactions section at the bottom. This shows your latest payment transactions with their status. We're looking for a transaction with 'paid' status - only paid transactions can be refunded.",navigation:{page:"dashboard"},cursorTarget:{selector:'[data-testid="recent-activity-card"]',offset:{x:0,y:0},onClick:!1}},{text:"Step 3: Let's open the dropdown menu for this paid transaction. Each transaction has a menu button (three dots) that gives you options like refunding. Click it to see the available actions, including the 'Refund payment' option.",navigation:{page:"dashboard"},cursorTarget:{selector:'[data-testid="transaction-menu-button"]',offset:{x:0,y:0},onClick:!0}}]}},kT=[];function bT({isOpen:e=!0,onClose:t,onOpen:a,onBack:r,onNavigate:o,onActionComplete:n,currentPage:s,agentUrl:i=ST,startingQuestions:l,startingQuestionsEndpoint:u,userId:d,orgId:c,userName:p,userEmail:g,userOrganization:C}={}){let[L,S]=j.useState(kT),[h,m]=j.useState(""),[x,I]=j.useState(()=>crypto.randomUUID()),[k,T]=j.useState(!1),R=j.useRef(null),A=j.useCallback(()=>{I(crypto.randomUUID()),T(!1),R.current&&(R.current.close(),R.current=null)},[]),V=j.useRef({}),U=L.length===0,[se,q]=j.useState("idle"),[No,ie]=j.useState([]),Wt=j.useRef([]),$r=L.length?L[L.length-1].role:void 0,[Ae,Be]=j.useState("landing"),[Gt,Rt]=j.useState(void 0),[ea,th]=j.useState(l||wT),[CS,ah]=j.useState(!1);j.useEffect(()=>{u&&!l&&(ah(!0),fetch(u).then(v=>v.json()).then(v=>{Array.isArray(v)&&v.length>0&&th(v)}).catch(v=>{console.warn("[KiteChat] Failed to fetch starting questions:",v)}).finally(()=>ah(!1)))},[u,l]),j.useEffect(()=>{l&&th(l)},[l]);let[me,Xr]=j.useState(void 0),Me=j.useRef(void 0),rh=j.useRef(null),[xs,Qi]=j.useState(!1);j.useEffect(()=>{window.resetIntegrationNotification=()=>{localStorage.removeItem("gmailNotificationSeen"),console.log("Integration notification reset! Click the Integrations tab to see it again.")};let v=()=>{if(!localStorage.getItem("gmailNotificationSeen")){Be("landing"),Rt(void 0);let B=Date.now(),F="I see you're exploring integrations. Let me know if there are any other connections we should add.",N={id:B,role:"assistant",kind:"text",content:"",isNotificationMessage:!0};S(Y=>[...Y,N]),Da(B,F),localStorage.setItem("gmailNotificationSeen","true")}};return window.addEventListener("integrationTabClicked",v),()=>{window.removeEventListener("integrationTabClicked",v)}},[]),j.useEffect(()=>{me?(!Me.current||Me.current.id!==me.id||Me.current.stepIndex!==me.stepIndex)&&(Me.current=me):Me.current=void 0},[me]);let[ys,Yi]=j.useState(null),[qe,dc]=j.useState(null),[re,oe]=j.useState({}),oh=j.useRef(null),cc=j.useRef(null),Zi=j.useRef(null),{cursorState:Ji,moveTo:Qr,hide:Eo}=pS(),[Yr,fc]=j.useState(null),[nh,nr]=j.useState(null),pc=j.useRef(null),Fo=j.useRef(null),[sh,vs]=j.useState(!1),[Bo,el]=j.useState(""),ih=j.useRef(null);j.useEffect(()=>{if(!me||me.id!=="add-api-key"||me.stepIndex!==2)return;let b=setInterval(()=>{let B=document.querySelector('[role="dialog"]'),F=Me.current;if(B&&F&&F.id==="add-api-key"&&F.stepIndex===2){Eo();let N=Date.now()+1;S(Y=>[...Y,{id:N,role:"assistant",kind:"guideComplete",content:"Perfect! The dialog is now open. You can enter a name and create your API key."}]),Xr(void 0),Qi(!0)}},300);return()=>clearInterval(b)},[me,Eo]),j.useEffect(()=>()=>{Object.values(V.current).forEach(v=>window.clearInterval(v)),V.current={},Wt.current.forEach(v=>window.clearTimeout(v)),Wt.current=[]},[]),j.useEffect(()=>{if(me&&L.length>0){let v=L[L.length-1];if((v.kind==="guideStep"||v.kind==="guideComplete")&&Zi.current&&cc.current){let b=cc.current,B=Zi.current,F=b.getBoundingClientRect(),Y=B.getBoundingClientRect().top-F.top+b.scrollTop;b.scrollTop=Y}}else!me&&L.length>0&&oh.current?.scrollIntoView({behavior:"smooth"})},[L,se,me]);let lh=j.useMemo(()=>{for(let v=L.length-1;v>=0;v--){let b=L[v];if(b.kind==="bulkSummary"&&b.bulkSummary?.navigationPage&&b.bulkSummary.successes>0)return b.bulkSummary.navigationPage}return null},[L]);j.useEffect(()=>{rh.current=lh},[lh]),j.useEffect(()=>{pc.current=nh},[nh]),j.useEffect(()=>{let v=b=>{if((b.metaKey||b.ctrlKey)&&b.key==="Enter"){let B=pc.current;if(B){b.preventDefault(),b.stopPropagation(),gc(B);return}if(qe){b.preventDefault(),b.stopPropagation(),hc();return}if(ys){b.preventDefault(),b.stopPropagation(),mc(ys);return}let F=rh.current;if(console.log("[DEBUG] Keyboard handler - latestBulkSummaryNavigation:",F,"onNavigate:",!!o),F&&o){console.log("[DEBUG] Navigating via keyboard to:",F.page),b.preventDefault(),b.stopPropagation(),o(F.page,F.subtab);return}if(xs){b.preventDefault(),b.stopPropagation(),dh();return}if(Me.current){b.preventDefault(),b.stopPropagation(),xc();return}}};return window.addEventListener("keydown",v),()=>window.removeEventListener("keydown",v)},[qe,ys,me,xs,o]);let uh=j.useCallback(v=>{if(!i)return;R.current&&R.current.close();let b=i.replace(/^http/,"ws")+`/ws/escalation/${v}`,B=new WebSocket(b);B.onmessage=F=>{try{let N=JSON.parse(F.data);N.type==="agent_message"?S(Y=>{let Q=N.content,P=N.message_id;return(P?Y.some(w=>w.serverMessageId===P):Y.slice(-5).some(w=>w.content===Q))?(console.debug("[KiteChat] Skipping duplicate agent message:",P||Q.slice(0,30)),Y):[...Y,{id:Date.now(),role:"agent",kind:"text",content:Q,serverMessageId:P}]}):N.type==="error"&&console.error("[KiteChat] Escalation error:",N.message)}catch(N){console.error("[KiteChat] Failed to parse escalation message:",N)}},B.onerror=F=>{console.error("[KiteChat] Escalation WebSocket error:",F)},B.onclose=()=>{console.log("[KiteChat] Escalation WebSocket closed")},R.current=B},[i]),SS=j.useCallback(async v=>{if(!R.current||R.current.readyState!==WebSocket.OPEN)return console.error("[KiteChat] Escalation WebSocket not connected"),!1;try{return R.current.send(JSON.stringify({type:"user_message",content:v})),!0}catch(b){return console.error("[KiteChat] Failed to send escalated message:",b),!1}},[]);j.useEffect(()=>()=>{R.current&&R.current.close()},[]),j.useEffect(()=>{k&&x&&uh(x)},[k,x,uh]);function Da(v,b,B){let F=b||"",N=B;if(b&&b.startsWith("{")&&b.includes('"response"'))try{let M=0,w=0;for(let K=0;K<b.length;K++)if(b[K]==="{")M++;else if(b[K]==="}"&&(M--,M===0)){w=K+1;break}let $=w>0?b.slice(0,w):b,ee=JSON.parse($);ee.response&&typeof ee.response=="string"&&(F=ee.response,!N&&ee.followups&&(N=ee.followups))}catch{}F=IT(F);let Y=F.split(" "),Q=0,P=window.setInterval(()=>{Q+=1,S(M=>M.map(w=>w.id===v?{...w,content:Y.slice(0,Q).join(" ")}:w)),Q>=Y.length&&(window.clearInterval(P),delete V.current[v],N&&N.length>0&&S(M=>M.map(w=>w.id===v?{...w,followups:N}:w)),q("idle"))},25);V.current[v]=P}function IS(v,b){S(B=>B.map(F=>F.id===v?{...F,followupSelected:!0}:F)),tl(b.label)}function dh(){Object.values(V.current).forEach(v=>window.clearInterval(v)),V.current={},Wt.current.forEach(v=>window.clearTimeout(v)),Wt.current=[],Eo(),A(),S([]),m(""),q("idle"),Be("landing"),Rt(void 0),Xr(void 0),Qi(!1),Yi(null),dc(null),oe({}),r&&r()}function DT(v){Be("folder"),Rt(v)}function wS(){Be("landing"),Rt(void 0)}function kS(v){v.preventDefault();let b=h.trim();if(Yr){if(!b){let B={id:Date.now(),role:"assistant",kind:"text",content:"Please describe what you'd like to do with this CSV file. For example: 'Create customers from this file' or 'Add these subscriptions'."};S(F=>[...F,B]);return}PS(b,Yr),m(""),fc(null),Fo.current&&(Fo.current.value="");return}if(b){if(k){let B={id:Date.now(),role:"user",content:b};S(F=>[...F,B]),SS(b),m("");return}tl(b),m("")}}function bS(v){let b={dashboard:"dashboard",customers:"customers page",payments:"payments page",settings:"settings page",support:"support page",disputes:"disputes page",radar:"radar page"};if(v.page==="settings"&&v.subtab){let B={general:"General",billing:"Billing",security:"Security",api:"API Keys",notifications:"Notifications",integrations:"Integrations"};return`${b.settings} (${B[v.subtab]} tab)`}return b[v.page]}function mc(v){o&&o(v.page,v.subtab),Yi(null),S(b=>b.map(B=>B.kind==="navigationAction"&&B.navigationTarget?.page===v.page&&B.navigationTarget?.subtab===v.subtab?{...B,navigationTarget:void 0}:B))}function hc(){if(!qe)return;let v=re;if(qe.type!=="updateCompanyInfo"){if(qe.type==="addApiKey"){let b=v;if(!b.name||!b.name.trim())return}else if(qe.type==="addCustomer"){let b=v;if(!b.name||!b.name.trim()||!b.email||!b.email.trim())return}else if(qe.type==="changePassword"){let b=v;if(!b.currentPassword||!b.newPassword||!b.confirmPassword||b.newPassword!==b.confirmPassword)return}else if(qe.type==="addWebhook"){let b=v;if(!b.url||!b.url.trim())return}else if(qe.type==="addPaymentMethod"){let b=v;if(!b.cardNumber||!b.expiryDate)return}else if(qe.type==="deleteApiKey"){let b=v;if(!b.keyId&&!b.name)return}else if(qe.type==="refundPayment"){let b=v;if(!b.transactionId&&!b.customer)return}else if(qe.type==="createSubscription"){let b=v;if(!b.customerEmail&&!b.customerId)return}else if((qe.type==="toggleBlockRule"||qe.type==="enableBlockRule"||qe.type==="disableBlockRule")&&!v.ruleId)return}n&&n(qe.type,v),S(b=>b.map(B=>B.kind==="actionForm"&&B.actionType===qe.type?{...B,isSubmitted:!0}:B)),dc(null),oe({})}async function tl(v){Wt.current.forEach(Q=>window.clearTimeout(Q)),Wt.current=[];let B=[...L].reverse().find(Q=>Q.role==="assistant")?.isNotificationMessage===!0,F=Date.now(),N={id:F,role:"user",content:v};if(S(Q=>Q.map(P=>P.followups&&P.followups.length>0?{...P,followupSelected:!0}:P).concat(N)),B){let Q=Date.now()+1,P={id:Q,role:"assistant",kind:"text",content:""};S(M=>[...M,P]),Da(Q,"Thank you, your feedback is saved.");return}Yi(null),q("thinking"),ie([]);let Y=!1;try{let Q=new AbortController,P=setTimeout(()=>Q.abort(),6e4),M=await fetch(`${i}/chat/stream`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({session_id:x,message:v,current_page:s||"dashboard",user_id:d,user_name:p,user_email:g,user_organization:C,org_id:c}),signal:Q.signal});if(clearTimeout(P),!M.ok)throw new Error(`Agent request failed: ${M.status}`);let w=M.body?.getReader();if(!w)throw new Error("No response body");let $=new TextDecoder,ee="";for(;;){let{done:K,value:fe}=await w.read();if(K)break;ee+=$.decode(fe,{stream:!0});let We=ee.split(`
|
|
21
21
|
|
|
22
22
|
`);ee=We.pop()||"";for(let at of We){if(!at.trim())continue;let Ma=at.split(`
|
|
23
|
-
`),Ge="",ta="";for(let W of Ma)W.startsWith("event: ")?Ge=W.slice(7):W.startsWith("data: ")&&(ta=W.slice(6));if(!(!Ge||!ta))try{let W=JSON.parse(ta);if(Ge==="progress")W.status==="thinking"?(q("thinking"),ie([{message:W.message,completed:!1}])):W.status==="searching"?(q("thinking"),ie([{message:W.message||"Searching knowledge base...",completed:!1}])):W.status==="evaluating"?(q("thinking"),ie([{message:W.message||"Evaluating sources...",completed:!1}])):W.status==="executing"?(q("executing"),ie(z=>{let te=z.map(xt=>({...xt,completed:!0})),de=te[te.length-1];return(!de||de.message!==W.message)&&te.push({message:W.message,completed:!1}),te})):W.status==="responding"&&(q("responding"),ie(z=>z.map(te=>({...te,completed:!0}))));else if(Ge==="response"){ie([]),Y=!0;let z=W;if(z.action==="navigate"&&z.navigation){let te={page:z.navigation.page,subtab:z.navigation.subtab};
|
|
23
|
+
`),Ge="",ta="";for(let W of Ma)W.startsWith("event: ")?Ge=W.slice(7):W.startsWith("data: ")&&(ta=W.slice(6));if(!(!Ge||!ta))try{let W=JSON.parse(ta);if(Ge==="progress")W.status==="thinking"?(q("thinking"),ie([{message:W.message,completed:!1}])):W.status==="searching"?(q("thinking"),ie([{message:W.message||"Searching knowledge base...",completed:!1}])):W.status==="evaluating"?(q("thinking"),ie([{message:W.message||"Evaluating sources...",completed:!1}])):W.status==="executing"?(q("executing"),ie(z=>{let te=z.map(xt=>({...xt,completed:!0})),de=te[te.length-1];return(!de||de.message!==W.message)&&te.push({message:W.message,completed:!1}),te})):W.status==="responding"&&(q("responding"),ie(z=>z.map(te=>({...te,completed:!0}))));else if(Ge==="response"){ie([]),Y=!0;let z=W;if(z.action==="navigate"&&z.navigation){let te={page:z.navigation.page,subtab:z.navigation.subtab};Yi(te);let de={id:F+1,role:"assistant",kind:"navigationAction",content:z.response||`I can take you to the ${bS(te)}.`,navigationTarget:te};S(xt=>[...xt,de]),q("idle")}else if(z.action==="show_form"&&z.actionType){dc({type:z.actionType,data:z.actionData||{}}),oe(z.actionData||{});let te={id:F+1,role:"assistant",kind:"actionForm",content:z.response||z.message||"Please fill in the details below:",actionType:z.actionType,actionData:z.actionData||{}};S(de=>[...de,te]),q("idle")}else if(z.action==="suggest_bulk"){let te=F+1,de={id:te,role:"assistant",kind:"text",content:""};S(xt=>[...xt,de]),Da(te,z.response||z.message||"For bulk operations, you can upload a CSV file - just click the \u{1F4CE} button!",z.followups),Y=!0}else if(z.action==="bulk_preview"){nr(z.bulk_session_id);let te={id:F+1,role:"assistant",kind:"bulkPreview",content:z.message||`I found ${z.csv_data?.rowCount||0} items. Here's a preview:`,csvData:z.csv_data?{rowCount:z.csv_data.rowCount,columns:z.csv_data.columns,sampleRows:z.csv_data.sampleRows,fileName:"From context"}:void 0,suggestedAction:z.suggested_action,bulkSessionId:z.bulk_session_id};S(de=>[...de,te]),q("idle"),Y=!0}else if(z.action==="execute"&&z.executionResult){let te=F+1,de={id:te,role:"assistant",kind:"text",content:"",structuredData:z.structuredData||void 0};S(xt=>[...xt,de]),Da(te,z.response||"Action completed successfully.",z.followups),Y=!0,setTimeout(()=>{window.dispatchEvent(new CustomEvent("agentActionComplete",{detail:{result:z.executionResult}}))},100)}else{let te=F+1,de={id:te,role:"assistant",kind:"text",content:""};S(xt=>[...xt,de]),Da(te,z.response||z.message||"",z.followups),Y=!0}}else if(Ge==="error"){q("idle"),ie([]),Y=!0;let z=F+1,te={id:z,role:"assistant",kind:"text",content:""};S(de=>[...de,te]),Da(z,W.message||"An error occurred processing your request.")}else if(Ge==="done")ie([]),q("idle"),Y=!0;else if(Ge==="escalation"){T(!0),q("idle");let te={id:Date.now()+2,role:"assistant",kind:"text",content:W.message||"You've been connected to our support queue. An agent will be with you shortly."};S(de=>[...de,te])}}catch(W){console.error("Failed to parse SSE event:",W)}}}ie([]),Y||q("idle")}catch(Q){console.error("Agent request failed:",Q),ie([]);let P=F+1,M={id:P,role:"assistant",kind:"text",content:""};S($=>[...$,M]);let w="I'm having trouble connecting to my backend.";Q instanceof Error&&(Q.name==="AbortError"?w="The request timed out. The server might be busy - please try again.":Q.message.includes("Failed to fetch")||Q.message.includes("NetworkError")?w="I'm having trouble connecting to my backend. Please make sure the agent server is running on port 5002.":Q.message.includes("Agent request failed:")&&(w="The server encountered an error. Please try again.")),w+=" For simple navigation requests, I can still help you locally.",Da(P,w)}finally{ie([])}}async function PS(v,b){Wt.current.forEach(N=>window.clearTimeout(N)),Wt.current=[];let B=Date.now(),F={id:B,role:"user",content:`\u{1F4CE} ${b.name}
|
|
24
24
|
|
|
25
25
|
${v}`};S(N=>[...N,F]),q("thinking"),ie([{message:"Analyzing CSV file...",completed:!1}]);try{let N=new FormData;N.append("file",b),N.append("message",v),N.append("session_id",x),N.append("current_page",s||"dashboard"),c&&N.append("org_id",c);let Y=new AbortController,Q=setTimeout(()=>Y.abort(),12e4),P=await fetch(`${i}/chat/bulk/stream`,{method:"POST",body:N,signal:Y.signal});if(clearTimeout(Q),!P.ok)throw new Error(`Bulk upload failed: ${P.status}`);let M=P.body?.getReader();if(!M)throw new Error("No response body");let w=new TextDecoder,$="",ee=null;for(;;){let{done:K,value:fe}=await M.read();if(K)break;$+=w.decode(fe,{stream:!0});let We=$.split(`
|
|
26
26
|
|
|
27
27
|
`);$=We.pop()||"";for(let at of We){if(!at.trim())continue;let Ma=at.split(`
|
|
28
|
-
`),Ge="",ta="";for(let W of Ma)W.startsWith("event: ")?Ge=W.slice(7):W.startsWith("data: ")&&(ta=W.slice(6));if(!(!Ge||!ta))try{let W=JSON.parse(ta);if(Ge==="preview"){q("idle"),ie([]),ee=W.bulk_session_id,nr(ee);let z={id:B+1,role:"assistant",kind:"bulkPreview",content:W.message||`I found ${W.csv_data.rowCount} rows in your CSV. Here's a preview:`,csvData:{rowCount:W.csv_data.rowCount,columns:W.csv_data.columns,sampleRows:W.csv_data.sampleRows,fileName:b.name},suggestedAction:W.suggested_action,bulkSessionId:ee||void 0};S(te=>[...te,z])}else if(Ge==="progress")q("executing"),ie([{message:`Processing row ${W.row} of ${W.total}...`,completed:!1}]),S(z=>z[z.length-1]?.kind==="bulkProgress"?z.map((de,xt)=>xt===z.length-1?{...de,bulkProgress:{processed:W.row,total:W.total,successes:W.successes||0,failures:W.failures||0}}:de):[...z,{id:Date.now(),role:"assistant",kind:"bulkProgress",bulkProgress:{processed:W.row,total:W.total,successes:W.successes||0,failures:W.failures||0}}]);else if(Ge==="summary")q("idle"),ie([]),nr(null),S(z=>[...z.filter(de=>de.kind!=="bulkProgress"),{id:Date.now(),role:"assistant",kind:"bulkSummary",content:W.message,bulkSummary:{total:W.total,successes:W.successes,failures:W.failures||[],navigationPage:W.navigationPage}}]),setTimeout(()=>{window.dispatchEvent(new CustomEvent("agentActionComplete",{detail:{result:{bulk:!0,total:W.total,successes:W.successes}}}))},100);else if(Ge==="error"){q("idle"),ie([]),nr(null);let z={id:B+1,role:"assistant",kind:"text",content:W.message||"An error occurred processing your CSV file."};S(te=>[...te,z])}else Ge==="done"&&(q("idle"),ie([]))}catch(W){console.error("Failed to parse bulk SSE event:",W)}}}ie([]),q("idle")}catch(N){console.error("Bulk upload failed:",N),ie([]),q("idle");let Y="I'm having trouble processing your CSV file.";N instanceof Error&&(N.name==="AbortError"?Y="The bulk upload request timed out. The file might be too large or the server is busy - please try again.":N.message.includes("Failed to fetch")||N.message.includes("NetworkError")?Y="I'm having trouble connecting to my backend. Please make sure the agent server is running on port 5002.":N.message.includes("Bulk upload failed:")&&(Y="The server encountered an error processing your CSV file. Please try again.")),Y+=" Please try again.";let Q={id:B+1,role:"assistant",kind:"text",content:Y};S(P=>[...P,Q])}}async function
|
|
28
|
+
`),Ge="",ta="";for(let W of Ma)W.startsWith("event: ")?Ge=W.slice(7):W.startsWith("data: ")&&(ta=W.slice(6));if(!(!Ge||!ta))try{let W=JSON.parse(ta);if(Ge==="preview"){q("idle"),ie([]),ee=W.bulk_session_id,nr(ee);let z={id:B+1,role:"assistant",kind:"bulkPreview",content:W.message||`I found ${W.csv_data.rowCount} rows in your CSV. Here's a preview:`,csvData:{rowCount:W.csv_data.rowCount,columns:W.csv_data.columns,sampleRows:W.csv_data.sampleRows,fileName:b.name},suggestedAction:W.suggested_action,bulkSessionId:ee||void 0};S(te=>[...te,z])}else if(Ge==="progress")q("executing"),ie([{message:`Processing row ${W.row} of ${W.total}...`,completed:!1}]),S(z=>z[z.length-1]?.kind==="bulkProgress"?z.map((de,xt)=>xt===z.length-1?{...de,bulkProgress:{processed:W.row,total:W.total,successes:W.successes||0,failures:W.failures||0}}:de):[...z,{id:Date.now(),role:"assistant",kind:"bulkProgress",bulkProgress:{processed:W.row,total:W.total,successes:W.successes||0,failures:W.failures||0}}]);else if(Ge==="summary")q("idle"),ie([]),nr(null),S(z=>[...z.filter(de=>de.kind!=="bulkProgress"),{id:Date.now(),role:"assistant",kind:"bulkSummary",content:W.message,bulkSummary:{total:W.total,successes:W.successes,failures:W.failures||[],navigationPage:W.navigationPage}}]),setTimeout(()=>{window.dispatchEvent(new CustomEvent("agentActionComplete",{detail:{result:{bulk:!0,total:W.total,successes:W.successes}}}))},100);else if(Ge==="error"){q("idle"),ie([]),nr(null);let z={id:B+1,role:"assistant",kind:"text",content:W.message||"An error occurred processing your CSV file."};S(te=>[...te,z])}else Ge==="done"&&(q("idle"),ie([]))}catch(W){console.error("Failed to parse bulk SSE event:",W)}}}ie([]),q("idle")}catch(N){console.error("Bulk upload failed:",N),ie([]),q("idle");let Y="I'm having trouble processing your CSV file.";N instanceof Error&&(N.name==="AbortError"?Y="The bulk upload request timed out. The file might be too large or the server is busy - please try again.":N.message.includes("Failed to fetch")||N.message.includes("NetworkError")?Y="I'm having trouble connecting to my backend. Please make sure the agent server is running on port 5002.":N.message.includes("Bulk upload failed:")&&(Y="The server encountered an error processing your CSV file. Please try again.")),Y+=" Please try again.";let Q={id:B+1,role:"assistant",kind:"text",content:Y};S(P=>[...P,Q])}}async function gc(v){q("executing"),ie([{message:"Starting bulk operation...",completed:!1}]);try{let b=await fetch(`${i}/chat/bulk/confirm`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({bulk_session_id:v})});if(!b.ok)throw new Error(`Confirm failed: ${b.status}`);let B=b.body?.getReader();if(!B)throw new Error("No response body");let F=new TextDecoder,N="";for(;;){let{done:Y,value:Q}=await B.read();if(Y)break;N+=F.decode(Q,{stream:!0});let P=N.split(`
|
|
29
29
|
|
|
30
30
|
`);N=P.pop()||"";for(let M of P){if(!M.trim())continue;let w=M.split(`
|
|
31
|
-
`),$="",ee="";for(let K of w)K.startsWith("event: ")?$=K.slice(7):K.startsWith("data: ")&&(ee=K.slice(6));if(!(!$||!ee))try{let K=JSON.parse(ee);if($==="progress")ie([{message:`Processing row ${K.row} of ${K.total}...`,completed:!1}]),S(fe=>fe[fe.length-1]?.kind==="bulkProgress"?fe.map((at,Ma)=>Ma===fe.length-1?{...at,bulkProgress:{processed:K.row,total:K.total,successes:K.successes||0,failures:K.failures||0}}:at):[...fe,{id:Date.now(),role:"assistant",kind:"bulkProgress",bulkProgress:{processed:K.row,total:K.total,successes:K.successes||0,failures:K.failures||0}}]);else if($==="summary")console.log("[DEBUG] Received summary event - data:",K),console.log("[DEBUG] navigationPage from backend:",K.navigationPage),q("idle"),ie([]),nr(null),S(fe=>{let We=fe.filter(Ma=>Ma.kind!=="bulkProgress"&&Ma.kind!=="bulkPreview"),at={id:Date.now(),role:"assistant",kind:"bulkSummary",content:K.message,bulkSummary:{total:K.total,successes:K.successes,failures:K.failures||[],navigationPage:K.navigationPage}};return console.log("[DEBUG] Creating bulkSummary message:",at),[...We,at]}),setTimeout(()=>{window.dispatchEvent(new CustomEvent("agentActionComplete",{detail:{result:{bulk:!0,total:K.total,successes:K.successes}}}))},100);else if($==="error"){q("idle"),ie([]),nr(null);let fe={id:Date.now(),role:"assistant",kind:"text",content:K.message||"An error occurred during bulk processing."};S(We=>[...We,fe])}}catch(K){console.error("Failed to parse confirm SSE event:",K)}}}}catch(b){console.error("Bulk confirm failed:",b),q("idle"),ie([]),nr(null);let B={id:Date.now(),role:"assistant",kind:"text",content:"Failed to start bulk operation. Please try again."};S(F=>[...F,B])}}function PS(){nr(null),S(v=>v.filter(b=>b.kind!=="bulkPreview"))}function dh(v){el(v)}function TS(v){let b=Date.now()+Math.floor(Math.random()*1e3);S(B=>[...B,{id:b,role:"assistant",kind:"text",content:v}])}function RT(v){let b=Ym[v];if(!b)return;Be("landing"),Rt(void 0);let B={id:v,stepIndex:0};Qr(B),Me.current=B,TS(`I'll help you with ${b.title}.`);let F=b.steps[0],N=F.cursorTarget?.selector.includes("[data-page="),Y=F.cursorTarget?.selector.includes("[data-settings-tab=");if(F.cursorTarget&&(N||Y)){let P=F.cursorTarget;Y&&F.navigation&&o&&o(F.navigation.page,void 0),setTimeout(()=>{let w=()=>{let $=document.querySelector(P.selector);$&&$.offsetParent!==null?(Yr(P),P.onClick&&setTimeout(()=>{$.click()},1200)):setTimeout(w,200)};w()},Y?800:400)}else if(F.navigation&&o&&o(F.navigation.page,F.navigation.subtab),F.cursorTarget){let P=F.cursorTarget,M=P.selector.includes("data-settings-tab"),w=P.selector.includes("dialog")||P.selector.includes("api-key-name-input");setTimeout(()=>{let ee=()=>{let K=document.querySelector(P.selector);K&&K.offsetParent!==null?(Yr(P),P.onClick&&setTimeout(()=>{K.click()},1e3)):M||w?setTimeout(ee,200):(Yr(P),P.onClick&&setTimeout(()=>{let fe=document.querySelector(P.selector);fe&&fe.click()},1e3))};ee()},w?700:M?600:400)}let Q={id:Date.now()+1,role:"assistant",kind:"guideStep",content:"",guideStepIndex:0};S(P=>[...P,Q]),Da(Q.id,F.text)}function gc(){if(!me)return;let v=Ym[me.id];if(!v)return;let b=Me.current;(!b||b.id!==me.id)&&(b=me,Me.current=me);let F=b.stepIndex+1;if(F>=v.steps.length){Eo();let w=Date.now()+1;S($=>[...$,{id:w,role:"assistant",kind:"guideComplete",content:"Guide Complete"}]),Qr(void 0),Xi(!0);return}let N=v.steps[F],Y={id:me.id,stepIndex:F};Qr(Y),Me.current=Y;let Q={id:Date.now()+1,role:"assistant",kind:"guideStep",content:"",guideStepIndex:F};S(w=>[...w,Q]);let P=N.cursorTarget?.selector.includes("[data-page="),M=N.cursorTarget?.selector.includes("[data-settings-tab=");if(N.cursorTarget&&(P||M)){let w=N.cursorTarget;M&&N.navigation&&o&&o(N.navigation.page,void 0),setTimeout(()=>{let ee=Me.current;if(!ee||ee.id!==v.id||ee.stepIndex!==F)return;let K=()=>{let fe=Me.current;if(!fe||fe.id!==v.id||fe.stepIndex!==F)return;let We=document.querySelector(w.selector);We&&We.offsetParent!==null?(Yr(w),w.onClick&&setTimeout(()=>{let at=Me.current;!at||at.id!==v.id||at.stepIndex!==F||We.click()},1200)):setTimeout(K,200)};K()},M?800:400)}else if(N.navigation&&o&&o(N.navigation.page,N.navigation.subtab),N.cursorTarget){let w=N.cursorTarget,$=w.selector.includes("dialog")||w.selector.includes("api-key-name-input"),ee=w.selector.includes("data-settings-tab"),K=N.navigation?.subtab&&ee&&w.selector.includes(`data-settings-tab="${N.navigation.subtab}"`),fe=w.onClick&&!K,We=!!N.navigation,Ge=(!!N.navigation?.subtab?700:We?400:0)+($?700:ee?600:400);setTimeout(()=>{let ta=Me.current;if(!ta||ta.id!==v.id||ta.stepIndex!==F)return;let W=()=>{let z=Me.current;if(!z||z.id!==v.id||z.stepIndex!==F)return;let te=document.querySelector(w.selector);te&&te.offsetParent!==null?(Yr(w),fe&&setTimeout(()=>{let de=Me.current;!de||de.id!==v.id||de.stepIndex!==F||te.click()},1e3)):$||ee||w.selector.includes("data-testid")?setTimeout(W,200):(Yr(w),fe&&setTimeout(()=>{let de=Me.current;if(!de||de.id!==v.id||de.stepIndex!==F)return;let xt=document.querySelector(w.selector);xt&&xt.click()},1e3))};W()},Ge)}else Eo();Da(Q.id,N.text)}function AS(){if(!me)return;let v=Ym[me.id];if(!v)return;let b=me.stepIndex-1;if(b>=0){Qr({id:me.id,stepIndex:b});let B=v.steps[b];B.navigation&&o&&o(B.navigation.page,B.navigation.subtab),B.cursorTarget?setTimeout(()=>{Yr(B.cursorTarget)},500):Eo();let F=L.filter(N=>N.kind!=="guideStep"&&N.kind!=="guideComplete");S([...F,{id:Date.now(),role:"assistant",kind:"guideStep",content:B.text}])}}return e?(0,f.jsxs)("section",{className:`fixed top-0 right-0 z-40 flex flex-col bg-white border-l border-gray-200 h-full overflow-hidden transition-transform duration-300 ${e?"translate-x-0":"translate-x-full"}`,style:{width:`${xS}px`},children:[(0,f.jsxs)("div",{className:"flex items-center justify-between px-4 py-3 border-b border-gray-100 bg-gradient-to-r from-gray-50 to-white shrink-0",children:[(0,f.jsxs)("div",{className:"flex items-center gap-2.5",children:[(0,f.jsx)(Ca,{className:"h-3.5 w-3.5 text-black",fill:"currentColor"}),(0,f.jsx)("h3",{className:"text-sm font-semibold text-gray-800",children:"Copilot"})]}),(0,f.jsxs)("div",{className:"flex items-center gap-1",children:[(0,f.jsx)(It,{variant:"ghost",size:"sm",className:"h-7 w-7 p-0 text-gray-400 hover:text-gray-600 hover:bg-gray-100 rounded-full",onClick:()=>{A(),S([]),Be("landing"),Rt(void 0),Qr(void 0),Me.current=void 0,Xi(!1)},children:(0,f.jsx)(kt,{className:"h-3 w-3"})}),(0,f.jsx)(It,{variant:"ghost",size:"sm",className:"h-7 w-7 p-0 text-gray-400 hover:text-gray-600 hover:bg-gray-100 rounded-full",onClick:()=>t?.(),children:(0,f.jsx)(Mr,{className:"h-3.5 w-3.5"})})]})]}),(0,f.jsx)("div",{className:U?"grid flex-1 place-items-center transition-all duration-300":"flex flex-1 flex-col transition-all duration-300 min-h-0 overflow-hidden",children:U?(0,f.jsxs)("div",{className:"w-full overflow-y-auto px-4",children:[(0,f.jsx)("div",{className:"py-3 transition-all duration-300",children:(0,f.jsx)("h2",{className:"text-center text-2xl font-semibold text-gray-900",children:Ae==="folder"?gS.find(v=>v.id===Gt)?.title||"":"How can I help?"})}),(0,f.jsxs)("div",{className:"pb-4 px-4",children:[Ae==="landing"&&(0,f.jsx)(f.Fragment,{children:(0,f.jsx)("div",{className:"flex flex-col gap-1",children:LS?(0,f.jsx)("div",{className:"flex items-center justify-center py-4",children:(0,f.jsx)(Vt,{className:"h-4 w-4 animate-spin text-gray-400"})}):ea.map((v,b)=>{let B=["bg-blue-400","bg-green-400","bg-purple-400","bg-orange-400","bg-pink-400"];return(0,f.jsxs)(It,{type:"button",size:"sm",variant:"ghost",className:"w-full justify-start rounded-lg px-3 py-1.5 text-xs text-gray-700 hover:bg-gray-100 h-auto",onClick:()=>dh(v.prompt),children:[(0,f.jsx)("span",{className:`mr-2 inline-block h-1.5 w-1.5 rounded-full ${B[b%B.length]}`}),v.label]},v.id)})})}),Ae==="folder"&&(0,f.jsxs)(f.Fragment,{children:[(0,f.jsxs)("div",{className:"mb-3 flex items-center gap-2",children:[(0,f.jsx)(It,{type:"button",size:"icon",variant:"ghost",className:"h-7 w-7 rounded-full hover:bg-gray-100",onClick:IS,"aria-label":"Back to suggestions",children:(0,f.jsx)(Ln,{className:"h-4 w-4 text-gray-500"})}),(0,f.jsx)("span",{className:"text-xs font-medium uppercase tracking-wide text-gray-400",children:"Topics"})]}),(0,f.jsx)("div",{className:"flex flex-col gap-1.5",children:gS.find(v=>v.id===Gt)?.topics.map(v=>(0,f.jsx)(It,{type:"button",size:"sm",variant:"secondary",className:"justify-start rounded-xl border border-gray-200 bg-gray-50 px-3 py-2.5 text-xs text-gray-700 shadow-none transition-all hover:bg-gray-100 hover:border-gray-300 h-auto",onClick:()=>dh(v.prompt),children:v.label},v.id))})]})]})]}):(0,f.jsx)(f.Fragment,{children:(0,f.jsx)("div",{className:"flex-1 min-h-0 overflow-hidden",children:(0,f.jsx)(Gp,{ref:dc,className:"h-full",children:(0,f.jsxs)("div",{className:"flex flex-col gap-2 px-4 py-3",children:[L.map((v,b)=>{let B=v.role==="user",F=b>0?L[b-1].role:void 0,N=F!==void 0&&F!==v.role,Y=Me.current||me,Q=!1;if(Y&&v.kind==="guideStep"?v.guideStepIndex!==void 0?Q=v.guideStepIndex===Y.stepIndex:Q=b===L.length-1:v.kind==="guideComplete"&&(Q=b===L.length-1),v.kind==="guideStep"&&!Q)return null;if(B)return(0,f.jsx)("div",{className:`flex justify-end ${N?"mt-3":""}`,children:(0,f.jsx)("div",{className:"max-w-[260px] rounded-2xl rounded-br-md bg-gray-900 px-3.5 py-2.5 text-sm text-white shadow-sm",children:v.content})},v.id);if(v.role==="agent")return(0,f.jsx)("div",{className:`flex justify-start ${N?"mt-3":""}`,children:(0,f.jsx)("div",{className:"max-w-[260px] rounded-2xl rounded-bl-md bg-blue-500 px-3.5 py-2.5 text-sm text-white shadow-sm",children:(0,f.jsx)("div",{className:"whitespace-pre-wrap leading-relaxed",children:hS(v.content||"")})})},v.id);if(v.kind==="searchSummary")return(0,f.jsx)("div",{className:`${N?"mt-3":""}`,children:(0,f.jsx)(qv,{title:v.title??"Search results",links:v.links??[]})},v.id);if(v.kind==="guideComplete")return(0,f.jsx)("div",{ref:Q?Yi:null,className:`${N?"mt-3":""}`,children:(0,f.jsxs)("div",{className:"flex items-center gap-2 rounded-xl bg-green-50 border border-green-200 px-3 py-2.5 text-sm leading-6",children:[(0,f.jsx)($e,{className:"h-5 w-5 text-green-600 flex-shrink-0"}),(0,f.jsx)("span",{className:"font-medium text-green-800",children:v.content})]})},v.id);if(v.kind==="navigationAction")return(0,f.jsxs)("div",{className:`${N?"mt-3":""}`,children:[(0,f.jsx)("div",{className:"whitespace-pre-wrap text-sm leading-6 mb-2 text-gray-700",children:v.content||""}),v.navigationTarget&&(0,f.jsx)("div",{className:"mt-2",children:(0,f.jsxs)(It,{type:"button",size:"sm",variant:"secondary",className:"h-8 rounded-xl px-3 text-xs gap-1.5 bg-gray-100 hover:bg-gray-200 border border-gray-200",onClick:()=>v.navigationTarget&&pc(v.navigationTarget),children:[(0,f.jsx)("span",{children:"Confirm"}),(0,f.jsxs)("span",{className:"flex items-center gap-0.5 text-gray-400",children:[(0,f.jsx)(Ka,{className:"h-3 w-3"}),(0,f.jsx)($a,{className:"h-3 w-3"})]})]})})]},v.id);if(v.kind==="actionForm"){let P=v.actionType,M=Object.keys(re).length>0?re:v.actionData||{};if(v.isSubmitted){let w="";return P==="updateCompanyInfo"?w="Company information has been updated successfully.":P==="addApiKey"?w="API key has been added successfully.":P==="addCustomer"?w="Customer has been added successfully.":P==="enable2FA"?w="Two-factor authentication has been enabled successfully.":P==="disable2FA"?w="Two-factor authentication has been disabled successfully.":P==="changePassword"?w="Your password has been changed successfully.":P==="revokeSession"?w="Session has been revoked successfully.":P==="toggleNotification"?w="Notification preferences have been updated successfully.":P==="connectIntegration"?w="Integration has been connected successfully.":P==="disconnectIntegration"?w="Integration has been disconnected successfully.":P==="addPaymentMethod"?w="Payment method has been added successfully.":P==="removePaymentMethod"?w="Payment method has been removed successfully.":P==="deleteApiKey"?w="API key has been deleted successfully.":P==="addWebhook"?w="Webhook endpoint has been added successfully.":P==="updateCurrency"?w="Currency preference has been updated successfully.":P==="updateTimezone"?w="Timezone has been updated successfully.":P==="refundPayment"?w="Refund has been processed successfully.":P==="exportCertificate"?w="Certificate of Incorporation has been downloaded successfully.":P==="createSubscription"?w="Subscription has been created successfully.":P==="toggleBlockRule"||P==="enableBlockRule"||P==="disableBlockRule"?w="Block rule has been updated successfully.":w="Action completed successfully.",(0,f.jsx)("div",{className:`${N?"mt-3":""}`,children:(0,f.jsx)("div",{className:"whitespace-pre-wrap text-sm leading-6 text-gray-700",children:w})},v.id)}return(0,f.jsxs)("div",{className:`min-w-0 ${N?"mt-3":""}`,children:[(0,f.jsx)("div",{className:"whitespace-pre-wrap text-sm leading-6 mb-3 text-gray-700",children:v.content||""}),P==="updateCompanyInfo"&&(0,f.jsxs)("div",{className:"space-y-2 bg-gray-50 rounded-lg p-2 border border-gray-200 overflow-hidden",children:[(0,f.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Company Name"}),(0,f.jsx)(Te,{placeholder:"Acme Corporation",value:M.companyName||"",onChange:w=>oe({...re,companyName:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Email"}),(0,f.jsx)(Te,{type:"email",placeholder:"contact@acme.com",value:M.email||"",onChange:w=>oe({...re,email:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Address"}),(0,f.jsx)(Te,{placeholder:"123 Main St, San Francisco, CA",value:M.address||"",onChange:w=>oe({...re,address:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Phone"}),(0,f.jsx)(Te,{type:"tel",placeholder:"+1 (555) 123-4567",value:M.phone||"",onChange:w=>oe({...re,phone:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Website"}),(0,f.jsx)(Te,{type:"url",placeholder:"https://acme.com",value:M.website||"",onChange:w=>oe({...re,website:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]})]}),P==="addApiKey"&&(0,f.jsx)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"API Key Name"}),(0,f.jsx)(Te,{placeholder:"Production Key",value:M.name||"",onChange:w=>oe({...re,name:w.target.value}),className:"h-8 text-xs border-gray-200"})]})}),P==="addCustomer"&&(0,f.jsxs)("div",{className:"space-y-2 bg-gray-50 rounded-lg p-2 border border-gray-200 overflow-hidden",children:[(0,f.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Company Name"}),(0,f.jsx)(Te,{placeholder:"Acme Corporation",value:M.name||"",onChange:w=>oe({...re,name:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Email"}),(0,f.jsx)(Te,{type:"email",placeholder:"contact@acme.com",value:M.email||"",onChange:w=>oe({...re,email:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Location"}),(0,f.jsx)(Te,{placeholder:"San Francisco, CA",value:M.location||"",onChange:w=>oe({...re,location:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Subscription Tier"}),(0,f.jsxs)("select",{value:M.subscription||"Starter",onChange:w=>oe({...re,subscription:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"Starter",children:"Starter"}),(0,f.jsx)("option",{value:"Professional",children:"Professional"}),(0,f.jsx)("option",{value:"Enterprise",children:"Enterprise"})]})]})]}),(P==="enable2FA"||P==="disable2FA")&&(0,f.jsx)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:(0,f.jsx)("p",{className:"text-xs text-black",children:P==="enable2FA"?"This will enable two-factor authentication for your account. You'll need to set up an authenticator app.":"This will disable two-factor authentication for your account. Your account will be less secure."})}),P==="changePassword"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Current Password"}),(0,f.jsx)(Te,{type:"password",value:M.currentPassword||"",onChange:w=>oe({...re,currentPassword:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"New Password"}),(0,f.jsx)(Te,{type:"password",value:M.newPassword||"",onChange:w=>oe({...re,newPassword:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Confirm New Password"}),(0,f.jsx)(Te,{type:"password",value:M.confirmPassword||"",onChange:w=>oe({...re,confirmPassword:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]}),P==="toggleNotification"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Notification Type"}),(0,f.jsxs)("select",{value:M.notificationType||"paymentReceived",onChange:w=>oe({...re,notificationType:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"paymentReceived",children:"Payment Received"}),(0,f.jsx)("option",{value:"paymentFailed",children:"Payment Failed"}),(0,f.jsx)("option",{value:"invoicePaid",children:"Invoice Paid"}),(0,f.jsx)("option",{value:"monthlySummary",children:"Monthly Summary"}),(0,f.jsx)("option",{value:"productUpdates",children:"Product Updates"})]})]}),(0,f.jsxs)("div",{className:"flex items-center gap-2",children:[(0,f.jsx)("input",{type:"checkbox",checked:M.enabled!==!1,onChange:w=>oe({...re,enabled:w.target.checked}),className:"h-4 w-4 rounded border-gray-300 text-primary focus:ring-primary"}),(0,f.jsx)("label",{className:"text-xs text-black",children:"Enable this notification"})]})]}),(P==="connectIntegration"||P==="disconnectIntegration")&&(0,f.jsx)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Integration"}),(0,f.jsxs)("select",{value:M.integrationName||"Slack",onChange:w=>oe({...re,integrationName:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"Slack",children:"Slack"}),(0,f.jsx)("option",{value:"Zapier",children:"Zapier"}),(0,f.jsx)("option",{value:"Webhook",children:"Webhook"})]})]})}),P==="addPaymentMethod"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Card Number"}),(0,f.jsx)(Te,{placeholder:"1234 5678 9012 3456",value:M.cardNumber||"",onChange:w=>oe({...re,cardNumber:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Expiry Date"}),(0,f.jsx)(Te,{placeholder:"MM/YY",value:M.expiryDate||"",onChange:w=>oe({...re,expiryDate:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]}),P==="removePaymentMethod"&&(0,f.jsx)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:(0,f.jsx)("p",{className:"text-xs text-black",children:"This will remove the default payment method from your account."})}),P==="refundPayment"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Transaction ID or Customer Name"}),(0,f.jsx)(Te,{placeholder:"e.g., txn_1234 or Acme Corp",value:M.transactionId||M.customer||"",onChange:w=>{let $=w.target.value;$.startsWith("txn_")||/^\d+$/.test($)?oe({...re,transactionId:$,customer:void 0}):oe({...re,customer:$,transactionId:void 0})},className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Amount (optional)"}),(0,f.jsx)(Te,{placeholder:"$0.00",value:M.amount||"",onChange:w=>oe({...re,amount:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Reason (optional)"}),(0,f.jsx)(Te,{placeholder:"e.g., Customer request",value:M.reason||"",onChange:w=>oe({...re,reason:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]}),P==="deleteApiKey"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"API Key Name or ID"}),(0,f.jsx)(Te,{placeholder:"Production Key",value:M.keyId||M.name||"",onChange:w=>oe({...re,keyId:w.target.value,name:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsx)("p",{className:"text-xs text-red-600",children:"Warning: This action cannot be undone. The API key will be permanently deleted."})]}),P==="addWebhook"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Webhook URL"}),(0,f.jsx)(Te,{type:"url",placeholder:"https://example.com/webhook",value:M.url||"",onChange:w=>oe({...re,url:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Name (optional)"}),(0,f.jsx)(Te,{placeholder:"Production Webhook",value:M.name||"",onChange:w=>oe({...re,name:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]}),P==="updateCurrency"&&(0,f.jsx)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Currency"}),(0,f.jsxs)("select",{value:M.currency||"USD",onChange:w=>oe({...re,currency:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"USD",children:"USD ($)"}),(0,f.jsx)("option",{value:"EUR",children:"EUR (\u20AC)"}),(0,f.jsx)("option",{value:"GBP",children:"GBP (\xA3)"}),(0,f.jsx)("option",{value:"JPY",children:"JPY (\xA5)"})]})]})}),P==="updateTimezone"&&(0,f.jsx)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Timezone"}),(0,f.jsxs)("select",{value:M.timezone||"America/Los_Angeles",onChange:w=>oe({...re,timezone:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"America/Los_Angeles",children:"Pacific Time (PT)"}),(0,f.jsx)("option",{value:"America/New_York",children:"Eastern Time (ET)"}),(0,f.jsx)("option",{value:"Europe/London",children:"GMT"}),(0,f.jsx)("option",{value:"Asia/Tokyo",children:"JST"})]})]})}),P==="revokeSession"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Device/Session"}),(0,f.jsx)(Te,{placeholder:"MacBook Pro",value:M.device||"",onChange:w=>oe({...re,device:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsx)("p",{className:"text-xs text-black",children:"This will sign out the device and invalidate its session."})]}),P==="createSubscription"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Customer Email"}),(0,f.jsx)(Te,{type:"email",placeholder:"customer@example.com",value:M.customerEmail||"",onChange:w=>oe({...re,customerEmail:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Plan"}),(0,f.jsxs)("select",{value:M.plan||"Starter",onChange:w=>oe({...re,plan:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"Starter",children:"Starter ($29/mo)"}),(0,f.jsx)("option",{value:"Professional",children:"Professional ($99/mo)"}),(0,f.jsx)("option",{value:"Enterprise",children:"Enterprise ($299/mo)"})]})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Billing Cycle"}),(0,f.jsxs)("select",{value:M.billingCycle||"monthly",onChange:w=>oe({...re,billingCycle:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"monthly",children:"Monthly"}),(0,f.jsx)("option",{value:"yearly",children:"Yearly (Save 15%)"})]})]})]}),P==="exportCertificate"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsx)("p",{className:"text-xs text-black",children:"This will export your certificate of incorporation document."}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Format"}),(0,f.jsxs)("select",{value:M.format||"pdf",onChange:w=>oe({...re,format:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"pdf",children:"PDF"}),(0,f.jsx)("option",{value:"json",children:"JSON"})]})]})]}),(P==="toggleBlockRule"||P==="enableBlockRule"||P==="disableBlockRule")&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Block Rule"}),(0,f.jsxs)("select",{value:M.ruleId||"rule_1",onChange:w=>oe({...re,ruleId:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"rule_1",children:"Block if risk level = 'highest'"}),(0,f.jsx)("option",{value:"rule_2",children:"Block if matches Stripe block lists"}),(0,f.jsx)("option",{value:"rule_3",children:"Block if CVC verification fails"}),(0,f.jsx)("option",{value:"rule_4",children:"Block if Postal code verification fails"})]})]}),(0,f.jsx)("p",{className:"text-xs text-black",children:P==="enableBlockRule"?"This will enable the selected block rule to actively block matching payments.":P==="disableBlockRule"?"This will disable the selected block rule. Matching payments will no longer be blocked.":"This will toggle the selected block rule's state."})]}),(0,f.jsx)("div",{className:"mt-3",children:(0,f.jsxs)(It,{type:"button",size:"sm",variant:"secondary",className:"h-8 rounded-xl px-3 text-xs gap-1.5 bg-gray-100 hover:bg-gray-200 border border-gray-200",onClick:mc,children:[(0,f.jsx)("span",{children:"Confirm"}),(0,f.jsxs)("span",{className:"flex items-center gap-0.5 text-gray-400",children:[(0,f.jsx)(Ka,{className:"h-3 w-3"}),(0,f.jsx)($a,{className:"h-3 w-3"})]})]})})]},v.id)}if(v.kind==="bulkPreview"&&v.csvData)return(0,f.jsxs)("div",{className:`${N?"mt-3":""}`,children:[(0,f.jsx)("div",{className:"whitespace-pre-wrap text-sm leading-6 mb-3 text-gray-700",children:v.content||""}),(0,f.jsxs)("div",{className:"bg-gray-50 rounded-lg border border-gray-200 overflow-hidden",children:[(0,f.jsxs)("div",{className:"bg-gray-100 px-3 py-2 border-b border-gray-200 flex items-center gap-2",children:[(0,f.jsx)(Cn,{className:"h-4 w-4 text-gray-600"}),(0,f.jsx)("span",{className:"text-xs font-medium text-gray-700",children:v.csvData.fileName}),(0,f.jsxs)("span",{className:"text-xs text-gray-500",children:["\u2022 ",v.csvData.rowCount," rows"]})]}),(0,f.jsxs)("div",{className:"px-3 py-2 border-b border-gray-100",children:[(0,f.jsx)("div",{className:"text-[10px] uppercase tracking-wider text-gray-500 mb-1",children:"Columns"}),(0,f.jsx)("div",{className:"flex flex-wrap gap-1",children:v.csvData.columns.map((P,M)=>(0,f.jsx)("span",{className:"text-xs bg-blue-100 text-blue-700 px-1.5 py-0.5 rounded",children:P},M))})]}),v.csvData.sampleRows.length>0&&(0,f.jsxs)("div",{className:"px-3 py-2",children:[(0,f.jsx)("div",{className:"text-[10px] uppercase tracking-wider text-gray-500 mb-1",children:"Sample Data"}),(0,f.jsx)("div",{className:"space-y-1",children:v.csvData.sampleRows.slice(0,3).map((P,M)=>(0,f.jsxs)("div",{className:"text-xs text-gray-600 bg-white rounded px-2 py-1 border border-gray-100",children:[Object.entries(P).slice(0,3).map(([w,$],ee)=>(0,f.jsxs)("span",{children:[ee>0&&" \u2022 ",(0,f.jsxs)("span",{className:"text-gray-400",children:[w,":"]})," ",$]},w)),Object.keys(P).length>3&&(0,f.jsxs)("span",{className:"text-gray-400",children:[" ","..."]})]},M))})]}),v.suggestedAction&&(0,f.jsx)("div",{className:"px-3 py-2 bg-blue-50 border-t border-blue-100",children:(0,f.jsxs)("span",{className:"text-xs text-blue-700",children:["Suggested action:"," ",(0,f.jsx)("strong",{children:v.suggestedAction.replace(/_/g," ")})]})})]}),v.bulkSessionId&&(0,f.jsxs)("div",{className:"mt-3 flex items-center gap-2",children:[(0,f.jsxs)(It,{type:"button",size:"sm",variant:"secondary",className:"h-8 rounded-xl px-3 text-xs gap-1.5 bg-gray-100 hover:bg-gray-200 border border-gray-200",onClick:()=>v.bulkSessionId&&hc(v.bulkSessionId),children:[(0,f.jsxs)("span",{children:["Process ",v.csvData.rowCount," rows"]}),(0,f.jsxs)("span",{className:"flex items-center gap-0.5 text-gray-400",children:[(0,f.jsx)(Ka,{className:"h-3 w-3"}),(0,f.jsx)($a,{className:"h-3 w-3"})]})]}),(0,f.jsx)(It,{type:"button",size:"sm",variant:"ghost",className:"h-8 rounded-xl px-3 text-xs text-gray-500 hover:text-gray-700 hover:bg-gray-100",onClick:PS,children:"Cancel"})]})]},v.id);if(v.kind==="bulkProgress"&&v.bulkProgress){let{processed:P,total:M,successes:w,failures:$}=v.bulkProgress,ee=Math.round(P/M*100);return(0,f.jsx)("div",{className:`${N?"mt-3":""}`,children:(0,f.jsxs)("div",{className:"bg-gray-50 rounded-lg border border-gray-200 p-3",children:[(0,f.jsxs)("div",{className:"flex items-center gap-2 mb-2",children:[(0,f.jsx)(Vt,{className:"h-4 w-4 animate-spin text-blue-600"}),(0,f.jsxs)("span",{className:"text-sm font-medium text-gray-700",children:["Processing... ",P," of ",M]})]}),(0,f.jsx)("div",{className:"h-2 bg-gray-200 rounded-full overflow-hidden mb-2",children:(0,f.jsx)("div",{className:"h-full bg-blue-600 transition-all duration-300",style:{width:`${ee}%`}})}),(0,f.jsxs)("div",{className:"flex items-center gap-3 text-xs text-gray-600",children:[(0,f.jsxs)("span",{className:"flex items-center gap-1",children:[(0,f.jsx)($e,{className:"h-3 w-3 text-green-600"}),w," successful"]}),$>0&&(0,f.jsxs)("span",{className:"flex items-center gap-1 text-red-600",children:[(0,f.jsx)(Mr,{className:"h-3 w-3"}),$," failed"]})]})]})},v.id)}if(v.kind==="bulkSummary"&&v.bulkSummary){let{total:P,successes:M,failures:w,navigationPage:$}=v.bulkSummary,ee=w.length>0,K=$?.page==="customers"?"Customers":$?.page==="dashboard"?"Dashboard":$?.page==="settings"?"Settings":"Results";return(0,f.jsx)("div",{className:`${N?"mt-3":""}`,children:(0,f.jsxs)("div",{className:`rounded-lg border p-3 ${ee?"bg-amber-50 border-amber-200":"bg-green-50 border-green-200"}`,children:[(0,f.jsxs)("div",{className:"flex items-center gap-2 mb-2",children:[(0,f.jsx)($e,{className:`h-5 w-5 ${ee?"text-amber-600":"text-green-600"}`}),(0,f.jsx)("span",{className:"text-sm font-medium text-gray-800",children:"Bulk operation complete"})]}),(0,f.jsx)("div",{className:"text-sm text-gray-600 mb-2",children:v.content||`Processed ${P} rows: ${M} successful${ee?`, ${w.length} failed`:""}.`}),(0,f.jsxs)("div",{className:"flex items-center gap-4 text-xs",children:[(0,f.jsxs)("span",{className:"flex items-center gap-1 text-green-700",children:[(0,f.jsx)($e,{className:"h-3 w-3"}),M," successful"]}),ee&&(0,f.jsxs)("span",{className:"flex items-center gap-1 text-red-600",children:[(0,f.jsx)(Mr,{className:"h-3 w-3"}),w.length," failed"]})]}),ee&&(0,f.jsxs)("div",{className:"mt-3 pt-2 border-t border-amber-200",children:[(0,f.jsx)("div",{className:"text-[10px] uppercase tracking-wider text-amber-700 mb-1",children:"Failed Rows"}),(0,f.jsxs)("div",{className:"space-y-1 max-h-32 overflow-y-auto",children:[w.slice(0,5).map((fe,We)=>(0,f.jsxs)("div",{className:"text-xs text-red-700 bg-red-50 rounded px-2 py-1",children:["Row ",fe.row,":"," ",fe.error||"Unknown error"]},We)),w.length>5&&(0,f.jsxs)("div",{className:"text-xs text-amber-600",children:["...and ",w.length-5," more"]})]})]}),$&&M>0&&(0,f.jsx)("div",{className:"mt-3 pt-2 border-t border-gray-200",children:(0,f.jsxs)("button",{type:"button",onClick:fe=>{fe.preventDefault(),fe.stopPropagation(),console.log("[DEBUG] Button clicked - navigationPage:",$,"onNavigate:",!!o),o&&$.page?(console.log("[DEBUG] Calling onNavigate with page:",$.page),o($.page,$.subtab)):console.log("[DEBUG] Condition failed - onNavigate:",!!o,"navigationPage.page:",$.page)},className:"flex items-center gap-2 text-xs text-gray-500 hover:text-gray-700 transition-colors group cursor-pointer",children:[(0,f.jsxs)("span",{className:"flex items-center gap-1 px-1.5 py-0.5 bg-gray-100 rounded text-[10px] font-medium text-gray-600 group-hover:bg-gray-200",children:[(0,f.jsx)(Ka,{className:"h-2.5 w-2.5"}),(0,f.jsx)("span",{children:"+"}),(0,f.jsx)($a,{className:"h-2.5 w-2.5"})]}),(0,f.jsxs)("span",{children:["View ",K]})]})})]})},v.id)}return(0,f.jsx)(j.Fragment,{children:(0,f.jsxs)("div",{ref:Q?Yi:null,className:`${N?"mt-3":""}`,children:[(0,f.jsx)("div",{className:"text-sm leading-6 text-gray-700",children:(()=>{let P=v.content||"";if(v.kind==="guideStep"){let M=P.match(/^(Step\s+\d+:)([\s\S]*)/);if(M)return(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)("strong",{children:M[1]}),M[2]]})}return v.role==="assistant"&&P?hS(P):P||(0,f.jsx)("span",{className:"opacity-70",children:"Thinking\u2026"})})()}),v.role==="assistant"&&v.structuredData&&(0,f.jsx)("div",{className:"mt-3",children:(0,f.jsx)(mS,{type:v.structuredData.type,data:v.structuredData.data})}),v.role==="assistant"&&v.followups&&v.followups.length>0&&!v.followupSelected&&(0,f.jsx)("div",{className:"mt-3 flex flex-wrap gap-1.5",children:v.followups.map(P=>(0,f.jsx)("button",{type:"button",onClick:()=>SS(v.id,P),className:`inline-flex items-center px-3 py-1.5 text-xs font-medium rounded-xl
|
|
31
|
+
`),$="",ee="";for(let K of w)K.startsWith("event: ")?$=K.slice(7):K.startsWith("data: ")&&(ee=K.slice(6));if(!(!$||!ee))try{let K=JSON.parse(ee);if($==="progress")ie([{message:`Processing row ${K.row} of ${K.total}...`,completed:!1}]),S(fe=>fe[fe.length-1]?.kind==="bulkProgress"?fe.map((at,Ma)=>Ma===fe.length-1?{...at,bulkProgress:{processed:K.row,total:K.total,successes:K.successes||0,failures:K.failures||0}}:at):[...fe,{id:Date.now(),role:"assistant",kind:"bulkProgress",bulkProgress:{processed:K.row,total:K.total,successes:K.successes||0,failures:K.failures||0}}]);else if($==="summary")console.log("[DEBUG] Received summary event - data:",K),console.log("[DEBUG] navigationPage from backend:",K.navigationPage),q("idle"),ie([]),nr(null),S(fe=>{let We=fe.filter(Ma=>Ma.kind!=="bulkProgress"&&Ma.kind!=="bulkPreview"),at={id:Date.now(),role:"assistant",kind:"bulkSummary",content:K.message,bulkSummary:{total:K.total,successes:K.successes,failures:K.failures||[],navigationPage:K.navigationPage}};return console.log("[DEBUG] Creating bulkSummary message:",at),[...We,at]}),setTimeout(()=>{window.dispatchEvent(new CustomEvent("agentActionComplete",{detail:{result:{bulk:!0,total:K.total,successes:K.successes}}}))},100);else if($==="error"){q("idle"),ie([]),nr(null);let fe={id:Date.now(),role:"assistant",kind:"text",content:K.message||"An error occurred during bulk processing."};S(We=>[...We,fe])}}catch(K){console.error("Failed to parse confirm SSE event:",K)}}}}catch(b){console.error("Bulk confirm failed:",b),q("idle"),ie([]),nr(null);let B={id:Date.now(),role:"assistant",kind:"text",content:"Failed to start bulk operation. Please try again."};S(F=>[...F,B])}}function TS(){nr(null),S(v=>v.filter(b=>b.kind!=="bulkPreview"))}function ch(v){tl(v)}function AS(v){let b=Date.now()+Math.floor(Math.random()*1e3);S(B=>[...B,{id:b,role:"assistant",kind:"text",content:v}])}function MT(v){let b=Zm[v];if(!b)return;Be("landing"),Rt(void 0);let B={id:v,stepIndex:0};Xr(B),Me.current=B,AS(`I'll help you with ${b.title}.`);let F=b.steps[0],N=F.cursorTarget?.selector.includes("[data-page="),Y=F.cursorTarget?.selector.includes("[data-settings-tab=");if(F.cursorTarget&&(N||Y)){let P=F.cursorTarget;Y&&F.navigation&&o&&o(F.navigation.page,void 0),setTimeout(()=>{let w=()=>{let $=document.querySelector(P.selector);$&&$.offsetParent!==null?(Qr(P),P.onClick&&setTimeout(()=>{$.click()},1200)):setTimeout(w,200)};w()},Y?800:400)}else if(F.navigation&&o&&o(F.navigation.page,F.navigation.subtab),F.cursorTarget){let P=F.cursorTarget,M=P.selector.includes("data-settings-tab"),w=P.selector.includes("dialog")||P.selector.includes("api-key-name-input");setTimeout(()=>{let ee=()=>{let K=document.querySelector(P.selector);K&&K.offsetParent!==null?(Qr(P),P.onClick&&setTimeout(()=>{K.click()},1e3)):M||w?setTimeout(ee,200):(Qr(P),P.onClick&&setTimeout(()=>{let fe=document.querySelector(P.selector);fe&&fe.click()},1e3))};ee()},w?700:M?600:400)}let Q={id:Date.now()+1,role:"assistant",kind:"guideStep",content:"",guideStepIndex:0};S(P=>[...P,Q]),Da(Q.id,F.text)}function xc(){if(!me)return;let v=Zm[me.id];if(!v)return;let b=Me.current;(!b||b.id!==me.id)&&(b=me,Me.current=me);let F=b.stepIndex+1;if(F>=v.steps.length){Eo();let w=Date.now()+1;S($=>[...$,{id:w,role:"assistant",kind:"guideComplete",content:"Guide Complete"}]),Xr(void 0),Qi(!0);return}let N=v.steps[F],Y={id:me.id,stepIndex:F};Xr(Y),Me.current=Y;let Q={id:Date.now()+1,role:"assistant",kind:"guideStep",content:"",guideStepIndex:F};S(w=>[...w,Q]);let P=N.cursorTarget?.selector.includes("[data-page="),M=N.cursorTarget?.selector.includes("[data-settings-tab=");if(N.cursorTarget&&(P||M)){let w=N.cursorTarget;M&&N.navigation&&o&&o(N.navigation.page,void 0),setTimeout(()=>{let ee=Me.current;if(!ee||ee.id!==v.id||ee.stepIndex!==F)return;let K=()=>{let fe=Me.current;if(!fe||fe.id!==v.id||fe.stepIndex!==F)return;let We=document.querySelector(w.selector);We&&We.offsetParent!==null?(Qr(w),w.onClick&&setTimeout(()=>{let at=Me.current;!at||at.id!==v.id||at.stepIndex!==F||We.click()},1200)):setTimeout(K,200)};K()},M?800:400)}else if(N.navigation&&o&&o(N.navigation.page,N.navigation.subtab),N.cursorTarget){let w=N.cursorTarget,$=w.selector.includes("dialog")||w.selector.includes("api-key-name-input"),ee=w.selector.includes("data-settings-tab"),K=N.navigation?.subtab&&ee&&w.selector.includes(`data-settings-tab="${N.navigation.subtab}"`),fe=w.onClick&&!K,We=!!N.navigation,Ge=(!!N.navigation?.subtab?700:We?400:0)+($?700:ee?600:400);setTimeout(()=>{let ta=Me.current;if(!ta||ta.id!==v.id||ta.stepIndex!==F)return;let W=()=>{let z=Me.current;if(!z||z.id!==v.id||z.stepIndex!==F)return;let te=document.querySelector(w.selector);te&&te.offsetParent!==null?(Qr(w),fe&&setTimeout(()=>{let de=Me.current;!de||de.id!==v.id||de.stepIndex!==F||te.click()},1e3)):$||ee||w.selector.includes("data-testid")?setTimeout(W,200):(Qr(w),fe&&setTimeout(()=>{let de=Me.current;if(!de||de.id!==v.id||de.stepIndex!==F)return;let xt=document.querySelector(w.selector);xt&&xt.click()},1e3))};W()},Ge)}else Eo();Da(Q.id,N.text)}function RS(){if(!me)return;let v=Zm[me.id];if(!v)return;let b=me.stepIndex-1;if(b>=0){Xr({id:me.id,stepIndex:b});let B=v.steps[b];B.navigation&&o&&o(B.navigation.page,B.navigation.subtab),B.cursorTarget?setTimeout(()=>{Qr(B.cursorTarget)},500):Eo();let F=L.filter(N=>N.kind!=="guideStep"&&N.kind!=="guideComplete");S([...F,{id:Date.now(),role:"assistant",kind:"guideStep",content:B.text}])}}return e?(0,f.jsxs)("section",{className:`fixed top-0 right-0 z-40 flex flex-col bg-white border-l border-gray-200 h-full overflow-hidden transition-transform duration-300 ${e?"translate-x-0":"translate-x-full"}`,style:{width:`${yS}px`},children:[(0,f.jsxs)("div",{className:"flex items-center justify-between px-4 py-3 border-b border-gray-100 bg-gradient-to-r from-gray-50 to-white shrink-0",children:[(0,f.jsxs)("div",{className:"flex items-center gap-2.5",children:[(0,f.jsx)(Ca,{className:"h-3.5 w-3.5 text-black",fill:"currentColor"}),(0,f.jsx)("h3",{className:"text-sm font-semibold text-gray-800",children:"Copilot"})]}),(0,f.jsxs)("div",{className:"flex items-center gap-1",children:[(0,f.jsx)(It,{variant:"ghost",size:"sm",className:"h-7 w-7 p-0 text-gray-400 hover:text-gray-600 hover:bg-gray-100 rounded-full",onClick:()=>{A(),S([]),Be("landing"),Rt(void 0),Xr(void 0),Me.current=void 0,Qi(!1)},children:(0,f.jsx)(kt,{className:"h-3 w-3"})}),(0,f.jsx)(It,{variant:"ghost",size:"sm",className:"h-7 w-7 p-0 text-gray-400 hover:text-gray-600 hover:bg-gray-100 rounded-full",onClick:()=>t?.(),children:(0,f.jsx)(Si,{className:"h-3.5 w-3.5"})})]})]}),(0,f.jsx)("div",{className:U?"grid flex-1 place-items-center transition-all duration-300":"flex flex-1 flex-col transition-all duration-300 min-h-0 overflow-hidden",children:U?(0,f.jsxs)("div",{className:"w-full overflow-y-auto px-4",children:[(0,f.jsx)("div",{className:"py-3 transition-all duration-300",children:(0,f.jsx)("h2",{className:"text-center text-2xl font-semibold text-gray-900",children:Ae==="folder"?xS.find(v=>v.id===Gt)?.title||"":"How can I help?"})}),(0,f.jsxs)("div",{className:"pb-4 px-4",children:[Ae==="landing"&&(0,f.jsx)(f.Fragment,{children:(0,f.jsx)("div",{className:"flex flex-col gap-1",children:CS?(0,f.jsx)("div",{className:"flex items-center justify-center py-4",children:(0,f.jsx)(Vt,{className:"h-4 w-4 animate-spin text-gray-400"})}):ea.map((v,b)=>{let B=["bg-blue-400","bg-green-400","bg-purple-400","bg-orange-400","bg-pink-400"];return(0,f.jsxs)(It,{type:"button",size:"sm",variant:"ghost",className:"w-full justify-start rounded-lg px-3 py-1.5 text-xs text-gray-700 hover:bg-gray-100 h-auto",onClick:()=>ch(v.prompt),children:[(0,f.jsx)("span",{className:`mr-2 inline-block h-1.5 w-1.5 rounded-full ${B[b%B.length]}`}),v.label]},v.id)})})}),Ae==="folder"&&(0,f.jsxs)(f.Fragment,{children:[(0,f.jsxs)("div",{className:"mb-3 flex items-center gap-2",children:[(0,f.jsx)(It,{type:"button",size:"icon",variant:"ghost",className:"h-7 w-7 rounded-full hover:bg-gray-100",onClick:wS,"aria-label":"Back to suggestions",children:(0,f.jsx)(Ln,{className:"h-4 w-4 text-gray-500"})}),(0,f.jsx)("span",{className:"text-xs font-medium uppercase tracking-wide text-gray-400",children:"Topics"})]}),(0,f.jsx)("div",{className:"flex flex-col gap-1.5",children:xS.find(v=>v.id===Gt)?.topics.map(v=>(0,f.jsx)(It,{type:"button",size:"sm",variant:"secondary",className:"justify-start rounded-xl border border-gray-200 bg-gray-50 px-3 py-2.5 text-xs text-gray-700 shadow-none transition-all hover:bg-gray-100 hover:border-gray-300 h-auto",onClick:()=>ch(v.prompt),children:v.label},v.id))})]})]})]}):(0,f.jsx)(f.Fragment,{children:(0,f.jsx)("div",{className:"flex-1 min-h-0 overflow-hidden",children:(0,f.jsx)(jp,{ref:cc,className:"h-full",children:(0,f.jsxs)("div",{className:"flex flex-col gap-2 px-4 py-3",children:[L.map((v,b)=>{let B=v.role==="user",F=b>0?L[b-1].role:void 0,N=F!==void 0&&F!==v.role,Y=Me.current||me,Q=!1;if(Y&&v.kind==="guideStep"?v.guideStepIndex!==void 0?Q=v.guideStepIndex===Y.stepIndex:Q=b===L.length-1:v.kind==="guideComplete"&&(Q=b===L.length-1),v.kind==="guideStep"&&!Q)return null;if(B)return(0,f.jsx)("div",{className:`flex justify-end ${N?"mt-3":""}`,children:(0,f.jsx)("div",{className:"max-w-[260px] rounded-2xl rounded-br-md bg-gray-900 px-3.5 py-2.5 text-sm text-white shadow-sm",children:v.content})},v.id);if(v.role==="agent")return(0,f.jsx)("div",{className:`flex justify-start ${N?"mt-3":""}`,children:(0,f.jsx)("div",{className:"max-w-[260px] rounded-2xl rounded-bl-md bg-blue-500 px-3.5 py-2.5 text-sm text-white shadow-sm",children:(0,f.jsx)("div",{className:"whitespace-pre-wrap leading-relaxed",children:gS(v.content||"")})})},v.id);if(v.kind==="searchSummary")return(0,f.jsx)("div",{className:`${N?"mt-3":""}`,children:(0,f.jsx)(Wv,{title:v.title??"Search results",links:v.links??[]})},v.id);if(v.kind==="guideComplete")return(0,f.jsx)("div",{ref:Q?Zi:null,className:`${N?"mt-3":""}`,children:(0,f.jsxs)("div",{className:"flex items-center gap-2 rounded-xl bg-green-50 border border-green-200 px-3 py-2.5 text-sm leading-6",children:[(0,f.jsx)($e,{className:"h-5 w-5 text-green-600 flex-shrink-0"}),(0,f.jsx)("span",{className:"font-medium text-green-800",children:v.content})]})},v.id);if(v.kind==="navigationAction")return(0,f.jsxs)("div",{className:`${N?"mt-3":""}`,children:[(0,f.jsx)("div",{className:"whitespace-pre-wrap text-sm leading-6 mb-2 text-gray-700",children:v.content||""}),v.navigationTarget&&(0,f.jsx)("div",{className:"mt-2",children:(0,f.jsxs)(It,{type:"button",size:"sm",variant:"secondary",className:"h-8 rounded-xl px-3 text-xs gap-1.5 bg-gray-100 hover:bg-gray-200 border border-gray-200",onClick:()=>v.navigationTarget&&mc(v.navigationTarget),children:[(0,f.jsx)("span",{children:"Confirm"}),(0,f.jsxs)("span",{className:"flex items-center gap-0.5 text-gray-400",children:[(0,f.jsx)(Ka,{className:"h-3 w-3"}),(0,f.jsx)($a,{className:"h-3 w-3"})]})]})})]},v.id);if(v.kind==="actionForm"){let P=v.actionType,M=Object.keys(re).length>0?re:v.actionData||{};if(v.isSubmitted){let w="";return P==="updateCompanyInfo"?w="Company information has been updated successfully.":P==="addApiKey"?w="API key has been added successfully.":P==="addCustomer"?w="Customer has been added successfully.":P==="enable2FA"?w="Two-factor authentication has been enabled successfully.":P==="disable2FA"?w="Two-factor authentication has been disabled successfully.":P==="changePassword"?w="Your password has been changed successfully.":P==="revokeSession"?w="Session has been revoked successfully.":P==="toggleNotification"?w="Notification preferences have been updated successfully.":P==="connectIntegration"?w="Integration has been connected successfully.":P==="disconnectIntegration"?w="Integration has been disconnected successfully.":P==="addPaymentMethod"?w="Payment method has been added successfully.":P==="removePaymentMethod"?w="Payment method has been removed successfully.":P==="deleteApiKey"?w="API key has been deleted successfully.":P==="addWebhook"?w="Webhook endpoint has been added successfully.":P==="updateCurrency"?w="Currency preference has been updated successfully.":P==="updateTimezone"?w="Timezone has been updated successfully.":P==="refundPayment"?w="Refund has been processed successfully.":P==="exportCertificate"?w="Certificate of Incorporation has been downloaded successfully.":P==="createSubscription"?w="Subscription has been created successfully.":P==="toggleBlockRule"||P==="enableBlockRule"||P==="disableBlockRule"?w="Block rule has been updated successfully.":w="Action completed successfully.",(0,f.jsx)("div",{className:`${N?"mt-3":""}`,children:(0,f.jsx)("div",{className:"whitespace-pre-wrap text-sm leading-6 text-gray-700",children:w})},v.id)}return(0,f.jsxs)("div",{className:`min-w-0 ${N?"mt-3":""}`,children:[(0,f.jsx)("div",{className:"whitespace-pre-wrap text-sm leading-6 mb-3 text-gray-700",children:v.content||""}),P==="updateCompanyInfo"&&(0,f.jsxs)("div",{className:"space-y-2 bg-gray-50 rounded-lg p-2 border border-gray-200 overflow-hidden",children:[(0,f.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Company Name"}),(0,f.jsx)(Te,{placeholder:"Acme Corporation",value:M.companyName||"",onChange:w=>oe({...re,companyName:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Email"}),(0,f.jsx)(Te,{type:"email",placeholder:"contact@acme.com",value:M.email||"",onChange:w=>oe({...re,email:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Address"}),(0,f.jsx)(Te,{placeholder:"123 Main St, San Francisco, CA",value:M.address||"",onChange:w=>oe({...re,address:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Phone"}),(0,f.jsx)(Te,{type:"tel",placeholder:"+1 (555) 123-4567",value:M.phone||"",onChange:w=>oe({...re,phone:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Website"}),(0,f.jsx)(Te,{type:"url",placeholder:"https://acme.com",value:M.website||"",onChange:w=>oe({...re,website:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]})]}),P==="addApiKey"&&(0,f.jsx)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"API Key Name"}),(0,f.jsx)(Te,{placeholder:"Production Key",value:M.name||"",onChange:w=>oe({...re,name:w.target.value}),className:"h-8 text-xs border-gray-200"})]})}),P==="addCustomer"&&(0,f.jsxs)("div",{className:"space-y-2 bg-gray-50 rounded-lg p-2 border border-gray-200 overflow-hidden",children:[(0,f.jsxs)("div",{className:"grid grid-cols-2 gap-2",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Company Name"}),(0,f.jsx)(Te,{placeholder:"Acme Corporation",value:M.name||"",onChange:w=>oe({...re,name:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Email"}),(0,f.jsx)(Te,{type:"email",placeholder:"contact@acme.com",value:M.email||"",onChange:w=>oe({...re,email:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Location"}),(0,f.jsx)(Te,{placeholder:"San Francisco, CA",value:M.location||"",onChange:w=>oe({...re,location:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Subscription Tier"}),(0,f.jsxs)("select",{value:M.subscription||"Starter",onChange:w=>oe({...re,subscription:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"Starter",children:"Starter"}),(0,f.jsx)("option",{value:"Professional",children:"Professional"}),(0,f.jsx)("option",{value:"Enterprise",children:"Enterprise"})]})]})]}),(P==="enable2FA"||P==="disable2FA")&&(0,f.jsx)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:(0,f.jsx)("p",{className:"text-xs text-black",children:P==="enable2FA"?"This will enable two-factor authentication for your account. You'll need to set up an authenticator app.":"This will disable two-factor authentication for your account. Your account will be less secure."})}),P==="changePassword"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Current Password"}),(0,f.jsx)(Te,{type:"password",value:M.currentPassword||"",onChange:w=>oe({...re,currentPassword:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"New Password"}),(0,f.jsx)(Te,{type:"password",value:M.newPassword||"",onChange:w=>oe({...re,newPassword:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Confirm New Password"}),(0,f.jsx)(Te,{type:"password",value:M.confirmPassword||"",onChange:w=>oe({...re,confirmPassword:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]}),P==="toggleNotification"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Notification Type"}),(0,f.jsxs)("select",{value:M.notificationType||"paymentReceived",onChange:w=>oe({...re,notificationType:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"paymentReceived",children:"Payment Received"}),(0,f.jsx)("option",{value:"paymentFailed",children:"Payment Failed"}),(0,f.jsx)("option",{value:"invoicePaid",children:"Invoice Paid"}),(0,f.jsx)("option",{value:"monthlySummary",children:"Monthly Summary"}),(0,f.jsx)("option",{value:"productUpdates",children:"Product Updates"})]})]}),(0,f.jsxs)("div",{className:"flex items-center gap-2",children:[(0,f.jsx)("input",{type:"checkbox",checked:M.enabled!==!1,onChange:w=>oe({...re,enabled:w.target.checked}),className:"h-4 w-4 rounded border-gray-300 text-primary focus:ring-primary"}),(0,f.jsx)("label",{className:"text-xs text-black",children:"Enable this notification"})]})]}),(P==="connectIntegration"||P==="disconnectIntegration")&&(0,f.jsx)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Integration"}),(0,f.jsxs)("select",{value:M.integrationName||"Slack",onChange:w=>oe({...re,integrationName:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"Slack",children:"Slack"}),(0,f.jsx)("option",{value:"Zapier",children:"Zapier"}),(0,f.jsx)("option",{value:"Webhook",children:"Webhook"})]})]})}),P==="addPaymentMethod"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Card Number"}),(0,f.jsx)(Te,{placeholder:"1234 5678 9012 3456",value:M.cardNumber||"",onChange:w=>oe({...re,cardNumber:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Expiry Date"}),(0,f.jsx)(Te,{placeholder:"MM/YY",value:M.expiryDate||"",onChange:w=>oe({...re,expiryDate:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]}),P==="removePaymentMethod"&&(0,f.jsx)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:(0,f.jsx)("p",{className:"text-xs text-black",children:"This will remove the default payment method from your account."})}),P==="refundPayment"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Transaction ID or Customer Name"}),(0,f.jsx)(Te,{placeholder:"e.g., txn_1234 or Acme Corp",value:M.transactionId||M.customer||"",onChange:w=>{let $=w.target.value;$.startsWith("txn_")||/^\d+$/.test($)?oe({...re,transactionId:$,customer:void 0}):oe({...re,customer:$,transactionId:void 0})},className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Amount (optional)"}),(0,f.jsx)(Te,{placeholder:"$0.00",value:M.amount||"",onChange:w=>oe({...re,amount:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Reason (optional)"}),(0,f.jsx)(Te,{placeholder:"e.g., Customer request",value:M.reason||"",onChange:w=>oe({...re,reason:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]}),P==="deleteApiKey"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"API Key Name or ID"}),(0,f.jsx)(Te,{placeholder:"Production Key",value:M.keyId||M.name||"",onChange:w=>oe({...re,keyId:w.target.value,name:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsx)("p",{className:"text-xs text-red-600",children:"Warning: This action cannot be undone. The API key will be permanently deleted."})]}),P==="addWebhook"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Webhook URL"}),(0,f.jsx)(Te,{type:"url",placeholder:"https://example.com/webhook",value:M.url||"",onChange:w=>oe({...re,url:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Name (optional)"}),(0,f.jsx)(Te,{placeholder:"Production Webhook",value:M.name||"",onChange:w=>oe({...re,name:w.target.value}),className:"h-8 text-xs border-gray-200"})]})]}),P==="updateCurrency"&&(0,f.jsx)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Currency"}),(0,f.jsxs)("select",{value:M.currency||"USD",onChange:w=>oe({...re,currency:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"USD",children:"USD ($)"}),(0,f.jsx)("option",{value:"EUR",children:"EUR (\u20AC)"}),(0,f.jsx)("option",{value:"GBP",children:"GBP (\xA3)"}),(0,f.jsx)("option",{value:"JPY",children:"JPY (\xA5)"})]})]})}),P==="updateTimezone"&&(0,f.jsx)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Timezone"}),(0,f.jsxs)("select",{value:M.timezone||"America/Los_Angeles",onChange:w=>oe({...re,timezone:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"America/Los_Angeles",children:"Pacific Time (PT)"}),(0,f.jsx)("option",{value:"America/New_York",children:"Eastern Time (ET)"}),(0,f.jsx)("option",{value:"Europe/London",children:"GMT"}),(0,f.jsx)("option",{value:"Asia/Tokyo",children:"JST"})]})]})}),P==="revokeSession"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Device/Session"}),(0,f.jsx)(Te,{placeholder:"MacBook Pro",value:M.device||"",onChange:w=>oe({...re,device:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsx)("p",{className:"text-xs text-black",children:"This will sign out the device and invalidate its session."})]}),P==="createSubscription"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Customer Email"}),(0,f.jsx)(Te,{type:"email",placeholder:"customer@example.com",value:M.customerEmail||"",onChange:w=>oe({...re,customerEmail:w.target.value}),className:"h-8 text-xs border-gray-200"})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Plan"}),(0,f.jsxs)("select",{value:M.plan||"Starter",onChange:w=>oe({...re,plan:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"Starter",children:"Starter ($29/mo)"}),(0,f.jsx)("option",{value:"Professional",children:"Professional ($99/mo)"}),(0,f.jsx)("option",{value:"Enterprise",children:"Enterprise ($299/mo)"})]})]}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Billing Cycle"}),(0,f.jsxs)("select",{value:M.billingCycle||"monthly",onChange:w=>oe({...re,billingCycle:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"monthly",children:"Monthly"}),(0,f.jsx)("option",{value:"yearly",children:"Yearly (Save 15%)"})]})]})]}),P==="exportCertificate"&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsx)("p",{className:"text-xs text-black",children:"This will export your certificate of incorporation document."}),(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Format"}),(0,f.jsxs)("select",{value:M.format||"pdf",onChange:w=>oe({...re,format:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"pdf",children:"PDF"}),(0,f.jsx)("option",{value:"json",children:"JSON"})]})]})]}),(P==="toggleBlockRule"||P==="enableBlockRule"||P==="disableBlockRule")&&(0,f.jsxs)("div",{className:"space-y-3 bg-gray-50 rounded-lg p-3 border border-gray-200",children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("label",{className:"text-xs font-medium text-black mb-1.5 block",children:"Block Rule"}),(0,f.jsxs)("select",{value:M.ruleId||"rule_1",onChange:w=>oe({...re,ruleId:w.target.value}),className:"h-8 w-full rounded-md border border-gray-200 bg-transparent px-3 py-1 text-xs shadow-xs transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] outline-none",children:[(0,f.jsx)("option",{value:"rule_1",children:"Block if risk level = 'highest'"}),(0,f.jsx)("option",{value:"rule_2",children:"Block if matches Stripe block lists"}),(0,f.jsx)("option",{value:"rule_3",children:"Block if CVC verification fails"}),(0,f.jsx)("option",{value:"rule_4",children:"Block if Postal code verification fails"})]})]}),(0,f.jsx)("p",{className:"text-xs text-black",children:P==="enableBlockRule"?"This will enable the selected block rule to actively block matching payments.":P==="disableBlockRule"?"This will disable the selected block rule. Matching payments will no longer be blocked.":"This will toggle the selected block rule's state."})]}),(0,f.jsx)("div",{className:"mt-3",children:(0,f.jsxs)(It,{type:"button",size:"sm",variant:"secondary",className:"h-8 rounded-xl px-3 text-xs gap-1.5 bg-gray-100 hover:bg-gray-200 border border-gray-200",onClick:hc,children:[(0,f.jsx)("span",{children:"Confirm"}),(0,f.jsxs)("span",{className:"flex items-center gap-0.5 text-gray-400",children:[(0,f.jsx)(Ka,{className:"h-3 w-3"}),(0,f.jsx)($a,{className:"h-3 w-3"})]})]})})]},v.id)}if(v.kind==="bulkPreview"&&v.csvData)return(0,f.jsxs)("div",{className:`${N?"mt-3":""}`,children:[(0,f.jsx)("div",{className:"whitespace-pre-wrap text-sm leading-6 mb-3 text-gray-700",children:v.content||""}),(0,f.jsxs)("div",{className:"bg-gray-50 rounded-lg border border-gray-200 overflow-hidden",children:[(0,f.jsxs)("div",{className:"bg-gray-100 px-3 py-2 border-b border-gray-200 flex items-center gap-2",children:[(0,f.jsx)(Cn,{className:"h-4 w-4 text-gray-600"}),(0,f.jsx)("span",{className:"text-xs font-medium text-gray-700",children:v.csvData.fileName}),(0,f.jsxs)("span",{className:"text-xs text-gray-500",children:["\u2022 ",v.csvData.rowCount," rows"]})]}),(0,f.jsxs)("div",{className:"px-3 py-2 border-b border-gray-100",children:[(0,f.jsx)("div",{className:"text-[10px] uppercase tracking-wider text-gray-500 mb-1",children:"Columns"}),(0,f.jsx)("div",{className:"flex flex-wrap gap-1",children:v.csvData.columns.map((P,M)=>(0,f.jsx)("span",{className:"text-xs bg-blue-100 text-blue-700 px-1.5 py-0.5 rounded",children:P},M))})]}),v.csvData.sampleRows.length>0&&(0,f.jsxs)("div",{className:"px-3 py-2",children:[(0,f.jsx)("div",{className:"text-[10px] uppercase tracking-wider text-gray-500 mb-1",children:"Sample Data"}),(0,f.jsx)("div",{className:"space-y-1",children:v.csvData.sampleRows.slice(0,3).map((P,M)=>(0,f.jsxs)("div",{className:"text-xs text-gray-600 bg-white rounded px-2 py-1 border border-gray-100",children:[Object.entries(P).slice(0,3).map(([w,$],ee)=>(0,f.jsxs)("span",{children:[ee>0&&" \u2022 ",(0,f.jsxs)("span",{className:"text-gray-400",children:[w,":"]})," ",$]},w)),Object.keys(P).length>3&&(0,f.jsxs)("span",{className:"text-gray-400",children:[" ","..."]})]},M))})]}),v.suggestedAction&&(0,f.jsx)("div",{className:"px-3 py-2 bg-blue-50 border-t border-blue-100",children:(0,f.jsxs)("span",{className:"text-xs text-blue-700",children:["Suggested action:"," ",(0,f.jsx)("strong",{children:v.suggestedAction.replace(/_/g," ")})]})})]}),v.bulkSessionId&&(0,f.jsxs)("div",{className:"mt-3 flex items-center gap-2",children:[(0,f.jsxs)(It,{type:"button",size:"sm",variant:"secondary",className:"h-8 rounded-xl px-3 text-xs gap-1.5 bg-gray-100 hover:bg-gray-200 border border-gray-200",onClick:()=>v.bulkSessionId&&gc(v.bulkSessionId),children:[(0,f.jsxs)("span",{children:["Process ",v.csvData.rowCount," rows"]}),(0,f.jsxs)("span",{className:"flex items-center gap-0.5 text-gray-400",children:[(0,f.jsx)(Ka,{className:"h-3 w-3"}),(0,f.jsx)($a,{className:"h-3 w-3"})]})]}),(0,f.jsx)(It,{type:"button",size:"sm",variant:"ghost",className:"h-8 rounded-xl px-3 text-xs text-gray-500 hover:text-gray-700 hover:bg-gray-100",onClick:TS,children:"Cancel"})]})]},v.id);if(v.kind==="bulkProgress"&&v.bulkProgress){let{processed:P,total:M,successes:w,failures:$}=v.bulkProgress,ee=Math.round(P/M*100);return(0,f.jsx)("div",{className:`${N?"mt-3":""}`,children:(0,f.jsxs)("div",{className:"bg-gray-50 rounded-lg border border-gray-200 p-3",children:[(0,f.jsxs)("div",{className:"flex items-center gap-2 mb-2",children:[(0,f.jsx)(Vt,{className:"h-4 w-4 animate-spin text-blue-600"}),(0,f.jsxs)("span",{className:"text-sm font-medium text-gray-700",children:["Processing... ",P," of ",M]})]}),(0,f.jsx)("div",{className:"h-2 bg-gray-200 rounded-full overflow-hidden mb-2",children:(0,f.jsx)("div",{className:"h-full bg-blue-600 transition-all duration-300",style:{width:`${ee}%`}})}),(0,f.jsxs)("div",{className:"flex items-center gap-3 text-xs text-gray-600",children:[(0,f.jsxs)("span",{className:"flex items-center gap-1",children:[(0,f.jsx)($e,{className:"h-3 w-3 text-green-600"}),w," successful"]}),$>0&&(0,f.jsxs)("span",{className:"flex items-center gap-1 text-red-600",children:[(0,f.jsx)(vo,{className:"h-3 w-3"}),$," failed"]})]})]})},v.id)}if(v.kind==="bulkSummary"&&v.bulkSummary){let{total:P,successes:M,failures:w,navigationPage:$}=v.bulkSummary,ee=w.length>0,K=$?.page==="customers"?"Customers":$?.page==="dashboard"?"Dashboard":$?.page==="settings"?"Settings":"Results";return(0,f.jsx)("div",{className:`${N?"mt-3":""}`,children:(0,f.jsxs)("div",{className:`rounded-lg border p-3 ${ee?"bg-amber-50 border-amber-200":"bg-green-50 border-green-200"}`,children:[(0,f.jsxs)("div",{className:"flex items-center gap-2 mb-2",children:[(0,f.jsx)($e,{className:`h-5 w-5 ${ee?"text-amber-600":"text-green-600"}`}),(0,f.jsx)("span",{className:"text-sm font-medium text-gray-800",children:"Bulk operation complete"})]}),(0,f.jsx)("div",{className:"text-sm text-gray-600 mb-2",children:v.content||`Processed ${P} rows: ${M} successful${ee?`, ${w.length} failed`:""}.`}),(0,f.jsxs)("div",{className:"flex items-center gap-4 text-xs",children:[(0,f.jsxs)("span",{className:"flex items-center gap-1 text-green-700",children:[(0,f.jsx)($e,{className:"h-3 w-3"}),M," successful"]}),ee&&(0,f.jsxs)("span",{className:"flex items-center gap-1 text-red-600",children:[(0,f.jsx)(vo,{className:"h-3 w-3"}),w.length," failed"]})]}),ee&&(0,f.jsxs)("div",{className:"mt-3 pt-2 border-t border-amber-200",children:[(0,f.jsx)("div",{className:"text-[10px] uppercase tracking-wider text-amber-700 mb-1",children:"Failed Rows"}),(0,f.jsxs)("div",{className:"space-y-1 max-h-32 overflow-y-auto",children:[w.slice(0,5).map((fe,We)=>(0,f.jsxs)("div",{className:"text-xs text-red-700 bg-red-50 rounded px-2 py-1",children:["Row ",fe.row,":"," ",fe.error||"Unknown error"]},We)),w.length>5&&(0,f.jsxs)("div",{className:"text-xs text-amber-600",children:["...and ",w.length-5," more"]})]})]}),$&&M>0&&(0,f.jsx)("div",{className:"mt-3 pt-2 border-t border-gray-200",children:(0,f.jsxs)("button",{type:"button",onClick:fe=>{fe.preventDefault(),fe.stopPropagation(),console.log("[DEBUG] Button clicked - navigationPage:",$,"onNavigate:",!!o),o&&$.page?(console.log("[DEBUG] Calling onNavigate with page:",$.page),o($.page,$.subtab)):console.log("[DEBUG] Condition failed - onNavigate:",!!o,"navigationPage.page:",$.page)},className:"flex items-center gap-2 text-xs text-gray-500 hover:text-gray-700 transition-colors group cursor-pointer",children:[(0,f.jsxs)("span",{className:"flex items-center gap-1 px-1.5 py-0.5 bg-gray-100 rounded text-[10px] font-medium text-gray-600 group-hover:bg-gray-200",children:[(0,f.jsx)(Ka,{className:"h-2.5 w-2.5"}),(0,f.jsx)("span",{children:"+"}),(0,f.jsx)($a,{className:"h-2.5 w-2.5"})]}),(0,f.jsxs)("span",{children:["View ",K]})]})})]})},v.id)}return(0,f.jsx)(j.Fragment,{children:(0,f.jsxs)("div",{ref:Q?Zi:null,className:`${N?"mt-3":""}`,children:[(0,f.jsx)("div",{className:"text-sm leading-6 text-gray-700",children:(()=>{let P=v.content||"";if(v.kind==="guideStep"){let M=P.match(/^(Step\s+\d+:)([\s\S]*)/);if(M)return(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)("strong",{children:M[1]}),M[2]]})}return v.role==="assistant"&&P?gS(P):P||(0,f.jsx)("span",{className:"opacity-70",children:"Thinking\u2026"})})()}),v.role==="assistant"&&v.structuredData&&(0,f.jsx)("div",{className:"mt-3",children:(0,f.jsx)(hS,{type:v.structuredData.type,data:v.structuredData.data})}),v.role==="assistant"&&v.followups&&v.followups.length>0&&!v.followupSelected&&(0,f.jsx)("div",{className:"mt-3 flex flex-wrap gap-1.5",children:v.followups.map(P=>(0,f.jsx)("button",{type:"button",onClick:()=>IS(v.id,P),className:`inline-flex items-center px-3 py-1.5 text-xs font-medium rounded-xl
|
|
32
32
|
bg-white hover:bg-gray-50 text-gray-600 hover:text-gray-800
|
|
33
33
|
border border-gray-200 hover:border-gray-300 shadow-sm
|
|
34
|
-
transition-all duration-150 ease-in-out`,children:P.label},P.id))})]})},v.id)}),(me||xs)&&(0,f.jsxs)("div",{className:"mt-3 flex items-center gap-2",children:[me&&me.stepIndex>0&&(0,f.jsx)(It,{type:"button",size:"sm",variant:"secondary",className:"h-7 w-7 rounded-full p-0 bg-gray-100 hover:bg-gray-200 border border-gray-200",onClick:
|
|
34
|
+
transition-all duration-150 ease-in-out`,children:P.label},P.id))})]})},v.id)}),(me||xs)&&(0,f.jsxs)("div",{className:"mt-3 flex items-center gap-2",children:[me&&me.stepIndex>0&&(0,f.jsx)(It,{type:"button",size:"sm",variant:"secondary",className:"h-7 w-7 rounded-full p-0 bg-gray-100 hover:bg-gray-200 border border-gray-200",onClick:RS,children:(0,f.jsx)(Ln,{className:"h-3.5 w-3.5 text-gray-600"})}),(0,f.jsxs)(It,{type:"button",size:"sm",variant:"secondary",className:"h-8 rounded-xl px-3 text-xs gap-1.5 bg-gray-100 hover:bg-gray-200 border border-gray-200",onClick:xs?dh:xc,children:[(0,f.jsx)("span",{children:xs?"Done":"Next"}),(0,f.jsxs)("span",{className:"flex items-center gap-0.5 text-gray-400",children:[(0,f.jsx)(Ka,{className:"h-3 w-3"}),(0,f.jsx)($a,{className:"h-3 w-3"})]})]})]}),(se==="thinking"||se==="searching"||se==="executing"||se==="responding")&&(0,f.jsx)("div",{className:`${$r==="user"?"mt-3":""}`,children:(0,f.jsx)(Hv,{phase:se,progressSteps:No})}),!me&&(0,f.jsx)("div",{ref:oh})]})})})})}),(0,f.jsxs)("div",{className:"px-4 py-3 border-t border-gray-100 bg-gray-50/50 shrink-0",children:[Yr&&(0,f.jsxs)("div",{className:"mb-2 flex items-center gap-2 rounded-xl bg-blue-50 border border-blue-200 px-3 py-2",children:[(0,f.jsx)(Cn,{className:"h-4 w-4 text-blue-600"}),(0,f.jsx)("span",{className:"text-xs text-blue-700 flex-1 truncate",children:Yr.name}),(0,f.jsx)("button",{type:"button",onClick:()=>{fc(null),Fo.current&&(Fo.current.value="")},className:"text-blue-600 hover:text-blue-800",children:(0,f.jsx)(vo,{className:"h-4 w-4"})})]}),(0,f.jsxs)("form",{onSubmit:kS,className:"w-full",children:[(0,f.jsx)("input",{ref:Fo,type:"file",accept:".csv",className:"hidden",onChange:v=>{let b=v.target.files?.[0];b&&fc(b)}}),(0,f.jsxs)("div",{className:"flex w-full items-start gap-2 rounded-xl border border-gray-200 bg-white px-3 py-2 shadow-sm",children:[(0,f.jsx)(It,{type:"button",size:"icon",variant:"ghost",onClick:()=>Fo.current?.click(),className:"h-5 w-5 rounded-full text-gray-400 hover:text-gray-600 hover:bg-gray-100",title:"Upload CSV for bulk operations",children:(0,f.jsx)(Ii,{className:"h-2.5 w-2.5"})}),(0,f.jsx)("textarea",{placeholder:Yr?"Describe what to do with this CSV...":"Ask anything...",value:h,onChange:v=>m(v.target.value),rows:1,className:"flex-1 border-0 bg-transparent focus-visible:ring-0 focus-visible:ring-offset-0 text-sm placeholder:text-gray-400 resize-none overflow-hidden outline-none",style:{minHeight:"20px",maxHeight:"120px"},onInput:v=>{let b=v.target;b.style.height="auto",b.style.height=Math.min(b.scrollHeight,120)+"px"},onKeyDown:v=>{if(v.key==="Enter"&&!v.shiftKey&&!v.metaKey&&!v.ctrlKey){if(v.preventDefault(),h.trim()||Yr){let b=v.currentTarget.closest("form");b&&b.requestSubmit()}return}if((v.metaKey||v.ctrlKey)&&v.key==="Enter"){let b=pc.current;if(b){v.preventDefault(),v.stopPropagation(),gc(b);return}if(qe){v.preventDefault(),v.stopPropagation(),hc();return}if(ys){v.preventDefault(),v.stopPropagation(),mc(ys);return}if(Me.current){v.preventDefault(),v.stopPropagation(),xc();return}}}}),(0,f.jsx)(It,{type:"submit",size:"icon",disabled:!h.trim()&&!Yr,className:"h-6 w-6 rounded-full bg-gray-900 hover:bg-gray-800 disabled:bg-gray-300",children:(0,f.jsx)(yi,{className:"h-2.5 w-2.5"})})]})]})]}),(0,f.jsx)(fS,{x:Ji.x,y:Ji.y,visible:Ji.visible,onClick:Ji.onClick})]}):(0,f.jsx)("div",{className:"fixed bottom-6 left-1/2 -translate-x-1/2 z-50",children:(0,f.jsx)("div",{className:`flex items-center gap-3 rounded-2xl bg-white border border-gray-200 shadow-lg px-4 py-2 hover:shadow-xl transition-all duration-300 ease-out focus-within:border-gray-700 ${sh?"w-[480px]":"w-[320px]"}`,children:sh?(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)("input",{ref:ih,type:"text",value:Bo,onChange:v=>el(v.target.value),onKeyDown:v=>{v.key==="Enter"&&Bo.trim()?(v.preventDefault(),a?.(),tl(Bo.trim()),el(""),vs(!1)):v.key==="Escape"&&(vs(!1),el(""))},onBlur:()=>{Bo.trim()||setTimeout(()=>vs(!1),200)},placeholder:"Ask a question...",className:"flex-1 text-sm text-gray-700 outline-none bg-transparent"}),(0,f.jsxs)("div",{className:"flex items-center gap-2",children:[(0,f.jsx)("span",{className:"text-xs text-gray-400 font-medium",children:"\u21B5 Enter"}),(0,f.jsx)("button",{onClick:()=>{a?.(),Bo.trim()&&m(Bo),el(""),vs(!1)},className:"h-7 w-7 rounded-lg bg-gray-100 hover:bg-gray-200 flex items-center justify-center transition-colors cursor-pointer",children:(0,f.jsx)(Ca,{className:"h-3.5 w-3.5 text-black",fill:"currentColor"})})]})]}):(0,f.jsxs)("div",{className:"flex items-center gap-3 w-full",children:[(0,f.jsxs)("button",{onClick:()=>{vs(!0),setTimeout(()=>ih.current?.focus(),100)},className:"flex items-center gap-3 flex-1 group",children:[(0,f.jsx)("span",{className:"text-sm text-gray-500 flex-1 text-left",children:"Ask a question..."}),(0,f.jsx)("span",{className:"text-xs text-gray-400 font-medium",children:"\u2318I"})]}),(0,f.jsx)("button",{onClick:()=>{a?.()},className:"h-7 w-7 rounded-lg bg-gray-100 hover:bg-gray-200 flex items-center justify-center transition-colors",children:(0,f.jsx)(Ca,{className:"h-3.5 w-3.5 text-black",fill:"currentColor"})})]})})})}function vS({onNavigate:e,onActionComplete:t,currentPage:a,agentUrl:r,startingQuestions:o,startingQuestionsEndpoint:n,defaultOpen:s=!1,isOpen:i,onOpenChange:l,userId:u,orgId:d,userName:c,userEmail:p,userOrganization:g}){let[C,L]=j.useState(s),S=i!==void 0?i:C,h=m=>{i===void 0&&L(m),l?.(m)};return j.useEffect(()=>{let m=document.body.style.paddingRight,x=document.body.style.transition;return document.body.style.transition="padding-right 0.3s ease",document.body.style.paddingRight=S?`${yS}px`:"0px",()=>{document.body.style.paddingRight=m,document.body.style.transition=x}},[S]),(0,f.jsx)(bT,{isOpen:S,onClose:()=>h(!1),onOpen:()=>h(!0),onNavigate:e,onActionComplete:t,currentPage:a,agentUrl:r,startingQuestions:o,startingQuestionsEndpoint:n,userId:u,orgId:d,userName:c,userEmail:p,userOrganization:g})}var eh=E(ue(),1),gs=null,At=null,qt={};function PT({initialConfig:e}){let[t,a]=(0,Ra.useState)(e),[r,o]=(0,Ra.useState)(e.currentPage||"dashboard"),[n,s]=(0,Ra.useState)(!1),i=(0,Ra.useRef)(!1);return(0,Ra.useEffect)(()=>{i.current=n},[n]),(0,Ra.useEffect)(()=>(qt.setCurrentPage=o,qt.setConfig=l=>a(u=>({...u,...l})),qt.setIsOpen=s,qt.getIsOpen=()=>i.current,()=>{qt={}}),[]),(0,Ra.useEffect)(()=>{t.theme==="dark"?At?.classList.add("dark"):At?.classList.remove("dark")},[t.theme]),(0,eh.jsx)(vS,{isOpen:n,onOpenChange:s,currentPage:r,agentUrl:t.agentUrl,onNavigate:(l,u)=>t.onNavigate?.(l,u),onActionComplete:t.onActionComplete,startingQuestions:t.startingQuestions,startingQuestionsEndpoint:t.startingQuestionsEndpoint,userId:t.userId,orgId:t.orgId,userName:t.userName,userEmail:t.userEmail,userOrganization:t.userOrganization})}function TT(){if(console.log("[KiteChat-Debug] injectStyles called",{existingStyle:!!document.getElementById("kite-chat-styles"),cssContentLength:47618}),document.getElementById("kite-chat-styles"))return;let e=document.createElement("style");e.id="kite-chat-styles",e.textContent=`/*! tailwindcss v4.1.17 | MIT License | https://tailwindcss.com */
|
|
35
35
|
@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){#kite-chat-root *,#kite-chat-root :before,#kite-chat-root :after,#kite-chat-root ::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-divide-y-reverse:0;--tw-border-style:solid;--tw-gradient-position:initial;--tw-gradient-from:#0000;--tw-gradient-via:#0000;--tw-gradient-to:#0000;--tw-gradient-stops:initial;--tw-gradient-via-stops:initial;--tw-gradient-from-position:0%;--tw-gradient-via-position:50%;--tw-gradient-to-position:100%;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-outline-style:solid;--tw-duration:initial;--tw-ease:initial}}:root,#kite-chat-root{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--color-red-50:oklch(97.1% .013 17.38);--color-red-200:oklch(88.5% .062 18.334);--color-red-500:oklch(63.7% .237 25.331);--color-red-600:oklch(57.7% .245 27.325);--color-red-700:oklch(50.5% .213 27.518);--color-orange-100:oklch(95.4% .038 75.164);--color-orange-400:oklch(75% .183 55.934);--color-orange-700:oklch(55.3% .195 38.402);--color-amber-50:oklch(98.7% .022 95.277);--color-amber-100:oklch(96.2% .059 95.617);--color-amber-200:oklch(92.4% .12 95.746);--color-amber-500:oklch(76.9% .188 70.08);--color-amber-600:oklch(66.6% .179 58.318);--color-amber-700:oklch(55.5% .163 48.998);--color-green-50:oklch(98.2% .018 155.826);--color-green-200:oklch(92.5% .084 155.995);--color-green-400:oklch(79.2% .209 151.711);--color-green-500:oklch(72.3% .219 149.579);--color-green-600:oklch(62.7% .194 149.214);--color-green-700:oklch(52.7% .154 150.069);--color-green-800:oklch(44.8% .119 151.328);--color-emerald-50:oklch(97.9% .021 166.113);--color-emerald-100:oklch(95% .052 163.051);--color-emerald-200:oklch(90.5% .093 164.15);--color-emerald-500:oklch(69.6% .17 162.48);--color-emerald-600:oklch(59.6% .145 163.225);--color-emerald-700:oklch(50.8% .118 165.612);--color-blue-50:oklch(97% .014 254.604);--color-blue-100:oklch(93.2% .032 255.585);--color-blue-200:oklch(88.2% .059 254.128);--color-blue-400:oklch(70.7% .165 254.624);--color-blue-500:oklch(62.3% .214 259.815);--color-blue-600:oklch(54.6% .245 262.881);--color-blue-700:oklch(48.8% .243 264.376);--color-blue-800:oklch(42.4% .199 265.638);--color-purple-50:oklch(97.7% .014 308.299);--color-purple-100:oklch(94.6% .033 307.174);--color-purple-200:oklch(90.2% .063 306.703);--color-purple-400:oklch(71.4% .203 305.504);--color-purple-600:oklch(55.8% .288 302.321);--color-purple-700:oklch(49.6% .265 301.924);--color-pink-400:oklch(71.8% .202 349.761);--color-slate-50:oklch(98.4% .003 247.858);--color-slate-100:oklch(96.8% .007 247.896);--color-slate-200:oklch(92.9% .013 255.508);--color-slate-300:oklch(86.9% .022 252.894);--color-slate-600:oklch(44.6% .043 257.281);--color-slate-700:oklch(37.2% .044 257.287);--color-gray-50:oklch(98.5% .002 247.839);--color-gray-100:oklch(96.7% .003 264.542);--color-gray-200:oklch(92.8% .006 264.531);--color-gray-300:oklch(87.2% .01 258.338);--color-gray-400:oklch(70.7% .022 261.325);--color-gray-500:oklch(55.1% .027 264.364);--color-gray-600:oklch(44.6% .03 256.802);--color-gray-700:oklch(37.3% .034 259.733);--color-gray-800:oklch(27.8% .033 256.848);--color-gray-900:oklch(21% .034 264.665);--color-black:#000;--color-white:#fff;--spacing:.25rem;--text-xs:.75rem;--text-xs--line-height:calc(1/.75);--text-sm:.875rem;--text-sm--line-height:calc(1.25/.875);--text-base:1rem;--text-base--line-height:calc(1.5/1);--text-lg:1.125rem;--text-lg--line-height:calc(1.75/1.125);--text-2xl:1.5rem;--text-2xl--line-height:calc(2/1.5);--font-weight-medium:500;--font-weight-semibold:600;--font-weight-bold:700;--tracking-wide:.025em;--tracking-wider:.05em;--leading-relaxed:1.625;--radius-2xl:1rem;--ease-out:cubic-bezier(0,0,.2,1);--ease-in-out:cubic-bezier(.4,0,.2,1);--animate-spin:spin 1s linear infinite;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono)}#kite-chat-root *,#kite-chat-root :after,#kite-chat-root :before,#kite-chat-root ::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}#kite-chat-root ::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}#kite-chat-root,#kite-chat-root{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}#kite-chat-root hr{height:0;color:inherit;border-top-width:1px}#kite-chat-root abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}#kite-chat-root h1,#kite-chat-root h2,#kite-chat-root h3,#kite-chat-root h4,#kite-chat-root h5,#kite-chat-root h6{font-size:inherit;font-weight:inherit}#kite-chat-root a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}#kite-chat-root b,#kite-chat-root strong{font-weight:bolder}#kite-chat-root code,#kite-chat-root kbd,#kite-chat-root samp,#kite-chat-root pre{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}#kite-chat-root small{font-size:80%}#kite-chat-root sub,#kite-chat-root sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}#kite-chat-root sub{bottom:-.25em}#kite-chat-root sup{top:-.5em}#kite-chat-root table{text-indent:0;border-color:inherit;border-collapse:collapse}#kite-chat-root :-moz-focusring{outline:auto}#kite-chat-root progress{vertical-align:baseline}#kite-chat-root summary{display:list-item}#kite-chat-root ol,#kite-chat-root ul,#kite-chat-root menu{list-style:none}#kite-chat-root img,#kite-chat-root svg,#kite-chat-root video,#kite-chat-root canvas,#kite-chat-root audio,#kite-chat-root iframe,#kite-chat-root embed,#kite-chat-root object{vertical-align:middle;display:block}#kite-chat-root img,#kite-chat-root video{max-width:100%;height:auto}#kite-chat-root button,#kite-chat-root input,#kite-chat-root select,#kite-chat-root optgroup,#kite-chat-root textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}#kite-chat-root ::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}#kite-chat-root :where(select:is([multiple],[size])) optgroup{font-weight:bolder}#kite-chat-root :where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}#kite-chat-root ::file-selector-button{margin-inline-end:4px}#kite-chat-root ::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){#kite-chat-root ::placeholder{color:currentColor}@supports (color:color-mix(in lab, red, red)){#kite-chat-root ::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}#kite-chat-root textarea{resize:vertical}#kite-chat-root ::-webkit-search-decoration{-webkit-appearance:none}#kite-chat-root ::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}#kite-chat-root ::-webkit-datetime-edit{display:inline-flex}#kite-chat-root ::-webkit-datetime-edit-fields-wrapper{padding:0}#kite-chat-root ::-webkit-datetime-edit{padding-block:0}#kite-chat-root ::-webkit-datetime-edit-year-field{padding-block:0}#kite-chat-root ::-webkit-datetime-edit-month-field{padding-block:0}#kite-chat-root ::-webkit-datetime-edit-day-field{padding-block:0}#kite-chat-root ::-webkit-datetime-edit-hour-field{padding-block:0}#kite-chat-root ::-webkit-datetime-edit-minute-field{padding-block:0}#kite-chat-root ::-webkit-datetime-edit-second-field{padding-block:0}#kite-chat-root ::-webkit-datetime-edit-millisecond-field{padding-block:0}#kite-chat-root ::-webkit-datetime-edit-meridiem-field{padding-block:0}#kite-chat-root ::-webkit-calendar-picker-indicator{line-height:1}#kite-chat-root :-moz-ui-invalid{box-shadow:none}#kite-chat-root button,#kite-chat-root input:where([type=button],[type=reset],[type=submit]){appearance:button}#kite-chat-root ::file-selector-button{appearance:button}#kite-chat-root ::-webkit-inner-spin-button{height:auto}#kite-chat-root ::-webkit-outer-spin-button{height:auto}#kite-chat-root [hidden]:where(:not([hidden=until-found])){display:none!important}#kite-chat-root .\\@container\\/card-header{container:card-header/inline-size}#kite-chat-root .pointer-events-none{pointer-events:none}#kite-chat-root .collapse{visibility:collapse}#kite-chat-root .visible{visibility:visible}#kite-chat-root .fixed{position:fixed}#kite-chat-root .relative{position:relative}#kite-chat-root .top-0{top:calc(var(--spacing)*0)}#kite-chat-root .top-1\\/2{top:50%}#kite-chat-root .right-0{right:calc(var(--spacing)*0)}#kite-chat-root .bottom-6{bottom:calc(var(--spacing)*6)}#kite-chat-root .left-1\\/2{left:50%}#kite-chat-root .z-40{z-index:40}#kite-chat-root .z-50{z-index:50}#kite-chat-root .z-\\[9999\\]{z-index:9999}#kite-chat-root .col-start-2{grid-column-start:2}#kite-chat-root .row-span-2{grid-row:span 2/span 2}#kite-chat-root .row-start-1{grid-row-start:1}#kite-chat-root .container{width:100%}@media (min-width:40rem){#kite-chat-root .container{max-width:40rem}}@media (min-width:48rem){#kite-chat-root .container{max-width:48rem}}@media (min-width:64rem){#kite-chat-root .container{max-width:64rem}}@media (min-width:80rem){#kite-chat-root .container{max-width:80rem}}@media (min-width:96rem){#kite-chat-root .container{max-width:96rem}}#kite-chat-root .mx-auto{margin-inline:auto}#kite-chat-root .my-1{margin-block:calc(var(--spacing)*1)}#kite-chat-root .my-2{margin-block:calc(var(--spacing)*2)}#kite-chat-root .mt-1{margin-top:calc(var(--spacing)*1)}#kite-chat-root .mt-2{margin-top:calc(var(--spacing)*2)}#kite-chat-root .mt-3{margin-top:calc(var(--spacing)*3)}#kite-chat-root .mr-2{margin-right:calc(var(--spacing)*2)}#kite-chat-root .mb-1{margin-bottom:calc(var(--spacing)*1)}#kite-chat-root .mb-1\\.5{margin-bottom:calc(var(--spacing)*1.5)}#kite-chat-root .mb-2{margin-bottom:calc(var(--spacing)*2)}#kite-chat-root .mb-3{margin-bottom:calc(var(--spacing)*3)}#kite-chat-root .mb-4{margin-bottom:calc(var(--spacing)*4)}#kite-chat-root .ml-2{margin-left:calc(var(--spacing)*2)}#kite-chat-root .ml-4{margin-left:calc(var(--spacing)*4)}#kite-chat-root .ml-5{margin-left:calc(var(--spacing)*5)}#kite-chat-root .ml-6{margin-left:calc(var(--spacing)*6)}#kite-chat-root .block{display:block}#kite-chat-root .contents{display:contents}#kite-chat-root .flex{display:flex}#kite-chat-root .grid{display:grid}#kite-chat-root .hidden{display:none}#kite-chat-root .inline{display:inline}#kite-chat-root .inline-block{display:inline-block}#kite-chat-root .inline-flex{display:inline-flex}#kite-chat-root .table{display:table}#kite-chat-root .size-8{width:calc(var(--spacing)*8);height:calc(var(--spacing)*8)}#kite-chat-root .size-9{width:calc(var(--spacing)*9);height:calc(var(--spacing)*9)}#kite-chat-root .size-10{width:calc(var(--spacing)*10);height:calc(var(--spacing)*10)}#kite-chat-root .size-full{width:100%;height:100%}#kite-chat-root .h-1{height:calc(var(--spacing)*1)}#kite-chat-root .h-1\\.5{height:calc(var(--spacing)*1.5)}#kite-chat-root .h-2{height:calc(var(--spacing)*2)}#kite-chat-root .h-2\\.5{height:calc(var(--spacing)*2.5)}#kite-chat-root .h-3{height:calc(var(--spacing)*3)}#kite-chat-root .h-3\\.5{height:calc(var(--spacing)*3.5)}#kite-chat-root .h-4{height:calc(var(--spacing)*4)}#kite-chat-root .h-5{height:calc(var(--spacing)*5)}#kite-chat-root .h-6{height:calc(var(--spacing)*6)}#kite-chat-root .h-7{height:calc(var(--spacing)*7)}#kite-chat-root .h-8{height:calc(var(--spacing)*8)}#kite-chat-root .h-9{height:calc(var(--spacing)*9)}#kite-chat-root .h-10{height:calc(var(--spacing)*10)}#kite-chat-root .h-16{height:calc(var(--spacing)*16)}#kite-chat-root .h-auto{height:auto}#kite-chat-root .h-full{height:100%}#kite-chat-root .max-h-32{max-height:calc(var(--spacing)*32)}#kite-chat-root .min-h-0{min-height:calc(var(--spacing)*0)}#kite-chat-root .w-1\\.5{width:calc(var(--spacing)*1.5)}#kite-chat-root .w-2\\.5{width:calc(var(--spacing)*2.5)}#kite-chat-root .w-3{width:calc(var(--spacing)*3)}#kite-chat-root .w-3\\.5{width:calc(var(--spacing)*3.5)}#kite-chat-root .w-4{width:calc(var(--spacing)*4)}#kite-chat-root .w-5{width:calc(var(--spacing)*5)}#kite-chat-root .w-6{width:calc(var(--spacing)*6)}#kite-chat-root .w-7{width:calc(var(--spacing)*7)}#kite-chat-root .w-10{width:calc(var(--spacing)*10)}#kite-chat-root .w-\\[320px\\]{width:320px}#kite-chat-root .w-\\[480px\\]{width:480px}#kite-chat-root .w-full{width:100%}#kite-chat-root .max-w-\\[260px\\]{max-width:260px}#kite-chat-root .min-w-0{min-width:calc(var(--spacing)*0)}#kite-chat-root .flex-1{flex:1}#kite-chat-root .flex-shrink-0,#kite-chat-root .shrink-0{flex-shrink:0}#kite-chat-root .-translate-x-1\\/2{--tw-translate-x:calc(calc(1/2*100%)*-1);translate:var(--tw-translate-x)var(--tw-translate-y)}#kite-chat-root .translate-x-0{--tw-translate-x:calc(var(--spacing)*0);translate:var(--tw-translate-x)var(--tw-translate-y)}#kite-chat-root .translate-x-full{--tw-translate-x:100%;translate:var(--tw-translate-x)var(--tw-translate-y)}#kite-chat-root .transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}#kite-chat-root .animate-spin{animation:var(--animate-spin)}#kite-chat-root .cursor-pointer{cursor:pointer}#kite-chat-root .touch-none{touch-action:none}#kite-chat-root .resize-none{resize:none}#kite-chat-root .list-decimal{list-style-type:decimal}#kite-chat-root .list-disc{list-style-type:disc}#kite-chat-root .auto-rows-min{grid-auto-rows:min-content}#kite-chat-root .grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}#kite-chat-root .grid-rows-\\[auto_auto\\]{grid-template-rows:auto auto}#kite-chat-root .flex-col{flex-direction:column}#kite-chat-root .flex-wrap{flex-wrap:wrap}#kite-chat-root .place-items-center{place-items:center}#kite-chat-root .items-center{align-items:center}#kite-chat-root .items-start{align-items:flex-start}#kite-chat-root .justify-between{justify-content:space-between}#kite-chat-root .justify-center{justify-content:center}#kite-chat-root .justify-end{justify-content:flex-end}#kite-chat-root .justify-start{justify-content:flex-start}#kite-chat-root .gap-0\\.5{gap:calc(var(--spacing)*.5)}#kite-chat-root .gap-1{gap:calc(var(--spacing)*1)}#kite-chat-root .gap-1\\.5{gap:calc(var(--spacing)*1.5)}#kite-chat-root .gap-2{gap:calc(var(--spacing)*2)}#kite-chat-root .gap-2\\.5{gap:calc(var(--spacing)*2.5)}#kite-chat-root .gap-3{gap:calc(var(--spacing)*3)}#kite-chat-root .gap-4{gap:calc(var(--spacing)*4)}#kite-chat-root .gap-6{gap:calc(var(--spacing)*6)}#kite-chat-root :where(.space-y-0\\.5>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*.5)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*.5)*calc(1 - var(--tw-space-y-reverse)))}#kite-chat-root :where(.space-y-1>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*1)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*1)*calc(1 - var(--tw-space-y-reverse)))}#kite-chat-root :where(.space-y-2>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*2)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*2)*calc(1 - var(--tw-space-y-reverse)))}#kite-chat-root :where(.space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing)*3)*var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing)*3)*calc(1 - var(--tw-space-y-reverse)))}#kite-chat-root :where(.divide-y>:not(:last-child)){--tw-divide-y-reverse:0;border-bottom-style:var(--tw-border-style);border-top-style:var(--tw-border-style);border-top-width:calc(1px*var(--tw-divide-y-reverse));border-bottom-width:calc(1px*calc(1 - var(--tw-divide-y-reverse)))}#kite-chat-root :where(.divide-gray-100>:not(:last-child)){border-color:var(--color-gray-100)}#kite-chat-root .self-start{align-self:flex-start}#kite-chat-root .justify-self-end{justify-self:flex-end}#kite-chat-root .truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}#kite-chat-root .overflow-hidden{overflow:hidden}#kite-chat-root .overflow-x-auto{overflow-x:auto}#kite-chat-root .overflow-y-auto{overflow-y:auto}#kite-chat-root .rounded{border-radius:.25rem}#kite-chat-root .rounded-2xl{border-radius:var(--radius-2xl)}#kite-chat-root .rounded-\\[inherit\\]{border-radius:inherit}#kite-chat-root .rounded-full{border-radius:3.40282e38px}#kite-chat-root .rounded-lg{border-radius:var(--kite-radius)}#kite-chat-root .rounded-md{border-radius:calc(var(--kite-radius) - 2px)}#kite-chat-root .rounded-xl{border-radius:calc(var(--kite-radius) + 4px)}#kite-chat-root .rounded-l-lg{border-top-left-radius:var(--kite-radius);border-bottom-left-radius:var(--kite-radius)}#kite-chat-root .rounded-br-md{border-bottom-right-radius:calc(var(--kite-radius) - 2px)}#kite-chat-root .rounded-bl-md{border-bottom-left-radius:calc(var(--kite-radius) - 2px)}#kite-chat-root .border{border-style:var(--tw-border-style);border-width:1px}#kite-chat-root .border-0{border-style:var(--tw-border-style);border-width:0}#kite-chat-root .border-t{border-top-style:var(--tw-border-style);border-top-width:1px}#kite-chat-root .border-r-0{border-right-style:var(--tw-border-style);border-right-width:0}#kite-chat-root .border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}#kite-chat-root .border-l{border-left-style:var(--tw-border-style);border-left-width:1px}#kite-chat-root .border-amber-100{border-color:var(--color-amber-100)}#kite-chat-root .border-amber-200{border-color:var(--color-amber-200)}#kite-chat-root .border-blue-100{border-color:var(--color-blue-100)}#kite-chat-root .border-blue-200{border-color:var(--color-blue-200)}#kite-chat-root .border-emerald-100{border-color:var(--color-emerald-100)}#kite-chat-root .border-emerald-200{border-color:var(--color-emerald-200)}#kite-chat-root .border-gray-100{border-color:var(--color-gray-100)}#kite-chat-root .border-gray-200{border-color:var(--color-gray-200)}#kite-chat-root .border-gray-300{border-color:var(--color-gray-300)}#kite-chat-root .border-green-200{border-color:var(--color-green-200)}#kite-chat-root .border-input{border-color:var(--kite-input)}#kite-chat-root .border-primary\\/20{border-color:var(--kite-primary)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .border-primary\\/20{border-color:color-mix(in oklab,var(--kite-primary)20%,transparent)}}#kite-chat-root .border-purple-100{border-color:var(--color-purple-100)}#kite-chat-root .border-purple-200{border-color:var(--color-purple-200)}#kite-chat-root .border-red-200{border-color:var(--color-red-200)}#kite-chat-root .border-slate-200{border-color:var(--color-slate-200)}#kite-chat-root .border-t-transparent{border-top-color:#0000}#kite-chat-root .border-l-transparent{border-left-color:#0000}#kite-chat-root .bg-amber-50{background-color:var(--color-amber-50)}#kite-chat-root .bg-amber-100{background-color:var(--color-amber-100)}#kite-chat-root .bg-background{background-color:var(--kite-background)}#kite-chat-root .bg-blue-50{background-color:var(--color-blue-50)}#kite-chat-root .bg-blue-100{background-color:var(--color-blue-100)}#kite-chat-root .bg-blue-400{background-color:var(--color-blue-400)}#kite-chat-root .bg-blue-500{background-color:var(--color-blue-500)}#kite-chat-root .bg-blue-600{background-color:var(--color-blue-600)}#kite-chat-root .bg-border{background-color:var(--kite-border)}#kite-chat-root .bg-card{background-color:var(--kite-card)}#kite-chat-root .bg-destructive{background-color:var(--kite-destructive)}#kite-chat-root .bg-emerald-50{background-color:var(--color-emerald-50)}#kite-chat-root .bg-emerald-500{background-color:var(--color-emerald-500)}#kite-chat-root .bg-gray-50{background-color:var(--color-gray-50)}#kite-chat-root .bg-gray-50\\/50{background-color:#f9fafb80}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .bg-gray-50\\/50{background-color:color-mix(in oklab,var(--color-gray-50)50%,transparent)}}#kite-chat-root .bg-gray-100{background-color:var(--color-gray-100)}#kite-chat-root .bg-gray-200{background-color:var(--color-gray-200)}#kite-chat-root .bg-gray-900{background-color:var(--color-gray-900)}#kite-chat-root .bg-green-50{background-color:var(--color-green-50)}#kite-chat-root .bg-green-400{background-color:var(--color-green-400)}#kite-chat-root .bg-muted\\/40{background-color:var(--kite-muted)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .bg-muted\\/40{background-color:color-mix(in oklab,var(--kite-muted)40%,transparent)}}#kite-chat-root .bg-orange-100{background-color:var(--color-orange-100)}#kite-chat-root .bg-orange-400{background-color:var(--color-orange-400)}#kite-chat-root .bg-pink-400{background-color:var(--color-pink-400)}#kite-chat-root .bg-primary,#kite-chat-root .bg-primary\\/5{background-color:var(--kite-primary)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .bg-primary\\/5{background-color:color-mix(in oklab,var(--kite-primary)5%,transparent)}}#kite-chat-root .bg-purple-50{background-color:var(--color-purple-50)}#kite-chat-root .bg-purple-400{background-color:var(--color-purple-400)}#kite-chat-root .bg-red-50{background-color:var(--color-red-50)}#kite-chat-root .bg-red-500{background-color:var(--color-red-500)}#kite-chat-root .bg-secondary{background-color:var(--kite-secondary)}#kite-chat-root .bg-slate-50{background-color:var(--color-slate-50)}#kite-chat-root .bg-slate-100{background-color:var(--color-slate-100)}#kite-chat-root .bg-slate-300{background-color:var(--color-slate-300)}#kite-chat-root .bg-transparent{background-color:#0000}#kite-chat-root .bg-white{background-color:var(--color-white)}#kite-chat-root .bg-gradient-to-r{--tw-gradient-position:to right in oklab;background-image:linear-gradient(var(--tw-gradient-stops))}#kite-chat-root .from-gray-50{--tw-gradient-from:var(--color-gray-50);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}#kite-chat-root .to-white{--tw-gradient-to:var(--color-white);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position),var(--tw-gradient-from)var(--tw-gradient-from-position),var(--tw-gradient-to)var(--tw-gradient-to-position))}#kite-chat-root .p-0{padding:calc(var(--spacing)*0)}#kite-chat-root .p-2{padding:calc(var(--spacing)*2)}#kite-chat-root .p-3{padding:calc(var(--spacing)*3)}#kite-chat-root .p-4{padding:calc(var(--spacing)*4)}#kite-chat-root .p-px{padding:1px}#kite-chat-root .px-0{padding-inline:calc(var(--spacing)*0)}#kite-chat-root .px-1{padding-inline:calc(var(--spacing)*1)}#kite-chat-root .px-1\\.5{padding-inline:calc(var(--spacing)*1.5)}#kite-chat-root .px-2{padding-inline:calc(var(--spacing)*2)}#kite-chat-root .px-2\\.5{padding-inline:calc(var(--spacing)*2.5)}#kite-chat-root .px-3{padding-inline:calc(var(--spacing)*3)}#kite-chat-root .px-3\\.5{padding-inline:calc(var(--spacing)*3.5)}#kite-chat-root .px-4{padding-inline:calc(var(--spacing)*4)}#kite-chat-root .px-6{padding-inline:calc(var(--spacing)*6)}#kite-chat-root .py-0{padding-block:calc(var(--spacing)*0)}#kite-chat-root .py-0\\.5{padding-block:calc(var(--spacing)*.5)}#kite-chat-root .py-1{padding-block:calc(var(--spacing)*1)}#kite-chat-root .py-1\\.5{padding-block:calc(var(--spacing)*1.5)}#kite-chat-root .py-2{padding-block:calc(var(--spacing)*2)}#kite-chat-root .py-2\\.5{padding-block:calc(var(--spacing)*2.5)}#kite-chat-root .py-3{padding-block:calc(var(--spacing)*3)}#kite-chat-root .py-4{padding-block:calc(var(--spacing)*4)}#kite-chat-root .py-6{padding-block:calc(var(--spacing)*6)}#kite-chat-root .py-8{padding-block:calc(var(--spacing)*8)}#kite-chat-root .pt-0{padding-top:calc(var(--spacing)*0)}#kite-chat-root .pt-2{padding-top:calc(var(--spacing)*2)}#kite-chat-root .pb-2{padding-bottom:calc(var(--spacing)*2)}#kite-chat-root .pb-3{padding-bottom:calc(var(--spacing)*3)}#kite-chat-root .pb-4{padding-bottom:calc(var(--spacing)*4)}#kite-chat-root .text-center{text-align:center}#kite-chat-root .text-left{text-align:left}#kite-chat-root .font-mono{font-family:var(--font-mono)}#kite-chat-root .text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}#kite-chat-root .text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}#kite-chat-root .text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}#kite-chat-root .text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}#kite-chat-root .text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}#kite-chat-root .text-\\[10px\\]{font-size:10px}#kite-chat-root .leading-6{--tw-leading:calc(var(--spacing)*6);line-height:calc(var(--spacing)*6)}#kite-chat-root .leading-none{--tw-leading:1;line-height:1}#kite-chat-root .leading-relaxed{--tw-leading:var(--leading-relaxed);line-height:var(--leading-relaxed)}#kite-chat-root .font-bold{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}#kite-chat-root .font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}#kite-chat-root .font-semibold{--tw-font-weight:var(--font-weight-semibold);font-weight:var(--font-weight-semibold)}#kite-chat-root .tracking-wide{--tw-tracking:var(--tracking-wide);letter-spacing:var(--tracking-wide)}#kite-chat-root .tracking-wider{--tw-tracking:var(--tracking-wider);letter-spacing:var(--tracking-wider)}#kite-chat-root .whitespace-nowrap{white-space:nowrap}#kite-chat-root .whitespace-pre-wrap{white-space:pre-wrap}#kite-chat-root .text-amber-500{color:var(--color-amber-500)}#kite-chat-root .text-amber-600{color:var(--color-amber-600)}#kite-chat-root .text-amber-700{color:var(--color-amber-700)}#kite-chat-root .text-black{color:var(--color-black)}#kite-chat-root .text-blue-600{color:var(--color-blue-600)}#kite-chat-root .text-blue-700{color:var(--color-blue-700)}#kite-chat-root .text-card-foreground{color:var(--kite-card-foreground)}#kite-chat-root .text-emerald-500{color:var(--color-emerald-500)}#kite-chat-root .text-emerald-600{color:var(--color-emerald-600)}#kite-chat-root .text-emerald-700{color:var(--color-emerald-700)}#kite-chat-root .text-gray-300{color:var(--color-gray-300)}#kite-chat-root .text-gray-400{color:var(--color-gray-400)}#kite-chat-root .text-gray-500{color:var(--color-gray-500)}#kite-chat-root .text-gray-600{color:var(--color-gray-600)}#kite-chat-root .text-gray-700{color:var(--color-gray-700)}#kite-chat-root .text-gray-800{color:var(--color-gray-800)}#kite-chat-root .text-gray-900{color:var(--color-gray-900)}#kite-chat-root .text-green-500{color:var(--color-green-500)}#kite-chat-root .text-green-600{color:var(--color-green-600)}#kite-chat-root .text-green-700{color:var(--color-green-700)}#kite-chat-root .text-green-800{color:var(--color-green-800)}#kite-chat-root .text-muted-foreground{color:var(--kite-muted-foreground)}#kite-chat-root .text-orange-700{color:var(--color-orange-700)}#kite-chat-root .text-primary{color:var(--kite-primary)}#kite-chat-root .text-primary-foreground{color:var(--kite-primary-foreground)}#kite-chat-root .text-purple-600{color:var(--color-purple-600)}#kite-chat-root .text-purple-700{color:var(--color-purple-700)}#kite-chat-root .text-red-500{color:var(--color-red-500)}#kite-chat-root .text-red-600{color:var(--color-red-600)}#kite-chat-root .text-red-700{color:var(--color-red-700)}#kite-chat-root .text-secondary-foreground{color:var(--kite-secondary-foreground)}#kite-chat-root .text-slate-600{color:var(--color-slate-600)}#kite-chat-root .text-slate-700{color:var(--color-slate-700)}#kite-chat-root .text-white{color:var(--color-white)}#kite-chat-root .uppercase{text-transform:uppercase}#kite-chat-root .italic{font-style:italic}#kite-chat-root .line-through{text-decoration-line:line-through}#kite-chat-root .underline-offset-4{text-underline-offset:4px}#kite-chat-root .opacity-60{opacity:.6}#kite-chat-root .opacity-70{opacity:.7}#kite-chat-root .opacity-90{opacity:.9}#kite-chat-root .opacity-100{opacity:1}#kite-chat-root .shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a),0 4px 6px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}#kite-chat-root .shadow-md{--tw-shadow:0 4px 6px -1px var(--tw-shadow-color,#0000001a),0 2px 4px -2px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}#kite-chat-root .shadow-none{--tw-shadow:0 0 #0000;box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}#kite-chat-root .shadow-sm{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}#kite-chat-root .shadow-xs{--tw-shadow:0 1px 2px 0 var(--tw-shadow-color,#0000000d);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}#kite-chat-root .outline{outline-style:var(--tw-outline-style);outline-width:1px}#kite-chat-root .transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}#kite-chat-root .transition-\\[color\\,box-shadow\\]{transition-property:color,box-shadow;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}#kite-chat-root .transition-all{transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}#kite-chat-root .transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}#kite-chat-root .transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}#kite-chat-root .transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}#kite-chat-root .duration-150{--tw-duration:.15s;transition-duration:.15s}#kite-chat-root .duration-200{--tw-duration:.2s;transition-duration:.2s}#kite-chat-root .duration-300{--tw-duration:.3s;transition-duration:.3s}#kite-chat-root .ease-in-out{--tw-ease:var(--ease-in-out);transition-timing-function:var(--ease-in-out)}#kite-chat-root .ease-out{--tw-ease:var(--ease-out);transition-timing-function:var(--ease-out)}#kite-chat-root .outline-none{--tw-outline-style:none;outline-style:none}#kite-chat-root .select-none{-webkit-user-select:none;user-select:none}@media (hover:hover){#kite-chat-root .group-hover\\:bg-gray-200:is(:where(.group):hover *){background-color:var(--color-gray-200)}}#kite-chat-root .selection\\:bg-primary ::selection{background-color:var(--kite-primary)}#kite-chat-root .selection\\:bg-primary::selection{background-color:var(--kite-primary)}#kite-chat-root .selection\\:text-primary-foreground ::selection{color:var(--kite-primary-foreground)}#kite-chat-root .selection\\:text-primary-foreground::selection{color:var(--kite-primary-foreground)}#kite-chat-root .file\\:inline-flex::file-selector-button{display:inline-flex}#kite-chat-root .file\\:h-7::file-selector-button{height:calc(var(--spacing)*7)}#kite-chat-root .file\\:border-0::file-selector-button{border-style:var(--tw-border-style);border-width:0}#kite-chat-root .file\\:bg-transparent::file-selector-button{background-color:#0000}#kite-chat-root .file\\:text-sm::file-selector-button{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}#kite-chat-root .file\\:font-medium::file-selector-button{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}#kite-chat-root .file\\:text-foreground::file-selector-button{color:var(--kite-foreground)}#kite-chat-root .placeholder\\:text-gray-400::placeholder{color:var(--color-gray-400)}#kite-chat-root .placeholder\\:text-muted-foreground::placeholder{color:var(--kite-muted-foreground)}#kite-chat-root .focus-within\\:border-gray-700:focus-within{border-color:var(--color-gray-700)}@media (hover:hover){#kite-chat-root .hover\\:border-gray-300:hover{border-color:var(--color-gray-300)}#kite-chat-root .hover\\:border-primary\\/30:hover{border-color:var(--kite-primary)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .hover\\:border-primary\\/30:hover{border-color:color-mix(in oklab,var(--kite-primary)30%,transparent)}}#kite-chat-root .hover\\:bg-accent:hover{background-color:var(--kite-accent)}#kite-chat-root .hover\\:bg-destructive\\/90:hover{background-color:var(--kite-destructive)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .hover\\:bg-destructive\\/90:hover{background-color:color-mix(in oklab,var(--kite-destructive)90%,transparent)}}#kite-chat-root .hover\\:bg-gray-50:hover{background-color:var(--color-gray-50)}#kite-chat-root .hover\\:bg-gray-100:hover{background-color:var(--color-gray-100)}#kite-chat-root .hover\\:bg-gray-200:hover{background-color:var(--color-gray-200)}#kite-chat-root .hover\\:bg-gray-800:hover{background-color:var(--color-gray-800)}#kite-chat-root .hover\\:bg-primary\\/10:hover{background-color:var(--kite-primary)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .hover\\:bg-primary\\/10:hover{background-color:color-mix(in oklab,var(--kite-primary)10%,transparent)}}#kite-chat-root .hover\\:bg-primary\\/90:hover{background-color:var(--kite-primary)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .hover\\:bg-primary\\/90:hover{background-color:color-mix(in oklab,var(--kite-primary)90%,transparent)}}#kite-chat-root .hover\\:bg-secondary\\/80:hover{background-color:var(--kite-secondary)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .hover\\:bg-secondary\\/80:hover{background-color:color-mix(in oklab,var(--kite-secondary)80%,transparent)}}#kite-chat-root .hover\\:text-accent-foreground:hover{color:var(--kite-accent-foreground)}#kite-chat-root .hover\\:text-blue-800:hover{color:var(--color-blue-800)}#kite-chat-root .hover\\:text-gray-600:hover{color:var(--color-gray-600)}#kite-chat-root .hover\\:text-gray-700:hover{color:var(--color-gray-700)}#kite-chat-root .hover\\:text-gray-800:hover{color:var(--color-gray-800)}#kite-chat-root .hover\\:underline:hover{text-decoration-line:underline}#kite-chat-root .hover\\:shadow-xl:hover{--tw-shadow:0 20px 25px -5px var(--tw-shadow-color,#0000001a),0 8px 10px -6px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}}#kite-chat-root .focus\\:ring-primary:focus{--tw-ring-color:var(--kite-primary)}#kite-chat-root .focus-visible\\:border-ring:focus-visible{border-color:var(--kite-ring)}#kite-chat-root .focus-visible\\:ring-0:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(0px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}#kite-chat-root .focus-visible\\:ring-\\[3px\\]:focus-visible{--tw-ring-shadow:var(--tw-ring-inset,)0 0 0 calc(3px + var(--tw-ring-offset-width))var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}#kite-chat-root .focus-visible\\:ring-destructive\\/20:focus-visible{--tw-ring-color:var(--kite-destructive)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .focus-visible\\:ring-destructive\\/20:focus-visible{--tw-ring-color:color-mix(in oklab,var(--kite-destructive)20%,transparent)}}#kite-chat-root .focus-visible\\:ring-ring\\/50:focus-visible{--tw-ring-color:var(--kite-ring)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .focus-visible\\:ring-ring\\/50:focus-visible{--tw-ring-color:color-mix(in oklab,var(--kite-ring)50%,transparent)}}#kite-chat-root .focus-visible\\:ring-offset-0:focus-visible{--tw-ring-offset-width:0px;--tw-ring-offset-shadow:var(--tw-ring-inset,)0 0 0 var(--tw-ring-offset-width)var(--tw-ring-offset-color)}#kite-chat-root .focus-visible\\:outline-1:focus-visible{outline-style:var(--tw-outline-style);outline-width:1px}#kite-chat-root .disabled\\:pointer-events-none:disabled{pointer-events:none}#kite-chat-root .disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}#kite-chat-root .disabled\\:bg-gray-300:disabled{background-color:var(--color-gray-300)}#kite-chat-root .disabled\\:opacity-50:disabled{opacity:.5}#kite-chat-root .has-data-\\[slot\\=card-action\\]\\:grid-cols-\\[1fr_auto\\]:has([data-slot=card-action]){grid-template-columns:1fr auto}#kite-chat-root .has-\\[\\>svg\\]\\:px-2\\.5:has(>svg){padding-inline:calc(var(--spacing)*2.5)}#kite-chat-root .has-\\[\\>svg\\]\\:px-3:has(>svg){padding-inline:calc(var(--spacing)*3)}#kite-chat-root .has-\\[\\>svg\\]\\:px-4:has(>svg){padding-inline:calc(var(--spacing)*4)}#kite-chat-root .aria-invalid\\:border-destructive[aria-invalid=true]{border-color:var(--kite-destructive)}#kite-chat-root .aria-invalid\\:ring-destructive\\/20[aria-invalid=true]{--tw-ring-color:var(--kite-destructive)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .aria-invalid\\:ring-destructive\\/20[aria-invalid=true]{--tw-ring-color:color-mix(in oklab,var(--kite-destructive)20%,transparent)}}@media (min-width:48rem){#kite-chat-root .md\\:text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}}#kite-chat-root .dark\\:border-input:is(.dark *){border-color:var(--kite-input)}#kite-chat-root .dark\\:bg-destructive\\/60:is(.dark *){background-color:var(--kite-destructive)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .dark\\:bg-destructive\\/60:is(.dark *){background-color:color-mix(in oklab,var(--kite-destructive)60%,transparent)}}#kite-chat-root .dark\\:bg-input\\/30:is(.dark *){background-color:var(--kite-input)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .dark\\:bg-input\\/30:is(.dark *){background-color:color-mix(in oklab,var(--kite-input)30%,transparent)}}@media (hover:hover){#kite-chat-root .dark\\:hover\\:bg-accent\\/50:is(.dark *):hover{background-color:var(--kite-accent)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .dark\\:hover\\:bg-accent\\/50:is(.dark *):hover{background-color:color-mix(in oklab,var(--kite-accent)50%,transparent)}}#kite-chat-root .dark\\:hover\\:bg-input\\/50:is(.dark *):hover{background-color:var(--kite-input)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .dark\\:hover\\:bg-input\\/50:is(.dark *):hover{background-color:color-mix(in oklab,var(--kite-input)50%,transparent)}}}#kite-chat-root .dark\\:focus-visible\\:ring-destructive\\/40:is(.dark *):focus-visible{--tw-ring-color:var(--kite-destructive)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .dark\\:focus-visible\\:ring-destructive\\/40:is(.dark *):focus-visible{--tw-ring-color:color-mix(in oklab,var(--kite-destructive)40%,transparent)}}#kite-chat-root .dark\\:aria-invalid\\:ring-destructive\\/40:is(.dark *)[aria-invalid=true]{--tw-ring-color:var(--kite-destructive)}@supports (color:color-mix(in lab, red, red)){#kite-chat-root .dark\\:aria-invalid\\:ring-destructive\\/40:is(.dark *)[aria-invalid=true]{--tw-ring-color:color-mix(in oklab,var(--kite-destructive)40%,transparent)}}#kite-chat-root .\\[\\&_svg\\]\\:pointer-events-none svg{pointer-events:none}#kite-chat-root .\\[\\&_svg\\]\\:shrink-0 svg{flex-shrink:0}#kite-chat-root .\\[\\&_svg\\:not\\(\\[class\\*\\=\\'size-\\'\\]\\)\\]\\:size-4 svg:not([class*=size-]){width:calc(var(--spacing)*4);height:calc(var(--spacing)*4)}#kite-chat-root .\\[\\.border-b\\]\\:pb-6.border-b{padding-bottom:calc(var(--spacing)*6)}#kite-chat-root .\\[\\.border-t\\]\\:pt-6.border-t{padding-top:calc(var(--spacing)*6)}:root{--kite-radius:.625rem;--kite-background:oklch(100% 0 0);--kite-foreground:oklch(14.5% 0 0);--kite-card:oklch(100% 0 0);--kite-card-foreground:oklch(14.5% 0 0);--kite-popover:oklch(100% 0 0);--kite-popover-foreground:oklch(14.5% 0 0);--kite-primary:oklch(20.5% 0 0);--kite-primary-foreground:oklch(98.5% 0 0);--kite-secondary:oklch(97% 0 0);--kite-secondary-foreground:oklch(20.5% 0 0);--kite-muted:oklch(97% 0 0);--kite-muted-foreground:oklch(55.6% 0 0);--kite-accent:oklch(97% 0 0);--kite-accent-foreground:oklch(20.5% 0 0);--kite-destructive:oklch(57.7% .245 27.325);--kite-destructive-foreground:oklch(98.5% 0 0);--kite-border:oklch(92.2% 0 0);--kite-input:oklch(92.2% 0 0);--kite-ring:oklch(70.8% 0 0)}.dark{--kite-background:oklch(14.5% 0 0);--kite-foreground:oklch(98.5% 0 0);--kite-card:oklch(20.5% 0 0);--kite-card-foreground:oklch(98.5% 0 0);--kite-popover:oklch(20.5% 0 0);--kite-popover-foreground:oklch(98.5% 0 0);--kite-primary:oklch(92.2% 0 0);--kite-primary-foreground:oklch(20.5% 0 0);--kite-secondary:oklch(26.9% 0 0);--kite-secondary-foreground:oklch(98.5% 0 0);--kite-muted:oklch(26.9% 0 0);--kite-muted-foreground:oklch(70.8% 0 0);--kite-accent:oklch(26.9% 0 0);--kite-accent-foreground:oklch(98.5% 0 0);--kite-destructive:oklch(70.4% .191 22.216);--kite-destructive-foreground:oklch(98.5% 0 0);--kite-border:oklch(100% 0 0/.1);--kite-input:oklch(100% 0 0/.15);--kite-ring:oklch(55.6% 0 0);--kite-link:oklch(65% .15 250)}#kite-chat-root *{border-color:var(--kite-border)}#kite-chat-root section form input{color:var(--kite-foreground,#1a1a1a)!important}#kite-chat-root section form input::placeholder{color:var(--kite-muted-foreground,#9ca3af)!important}#kite-chat-root section .space-y-1>div+div{margin-top:.625rem}#kite-chat-root section>div.flex-1>div.overflow-y-auto{padding:1rem 1.25rem!important}#kite-chat-root section .mt-6.pt-4.border-t{margin-top:1.25rem;padding-top:1rem}#kite-chat-root section button.w-full.text-left.px-3{padding:.75rem 1rem}#kite-chat-root section .text-sm.leading-6{line-height:1.625rem}@keyframes spin{to{transform:rotate(360deg)}}#kite-chat-root .animate-spin{animation:1s linear infinite spin}#kite-chat-root [data-motion]{will-change:transform,opacity}#kite-chat-root a,#kite-chat-root .kite-link{word-break:break-word;overflow-wrap:break-word;-webkit-hyphens:auto;hyphens:auto;text-decoration:none;color:var(--kite-link)!important}#kite-chat-root a:hover,#kite-chat-root .kite-link:hover{text-decoration:underline}#kite-chat-root .text-sm.leading-6{overflow-wrap:break-word;word-break:break-word;max-width:100%}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-divide-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-gradient-position{syntax:"*";inherits:false}@property --tw-gradient-from{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-via{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-to{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-stops{syntax:"*";inherits:false}@property --tw-gradient-via-stops{syntax:"*";inherits:false}@property --tw-gradient-from-position{syntax:"<length-percentage>";inherits:false;initial-value:0%}@property --tw-gradient-via-position{syntax:"<length-percentage>";inherits:false;initial-value:50%}@property --tw-gradient-to-position{syntax:"<length-percentage>";inherits:false;initial-value:100%}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}#kite-chat-root{--kite-link:oklch(55% .15 250)}`,document.head.appendChild(e),console.log("[KiteChat-Debug] Style injected",{styleInHead:!!document.getElementById("kite-chat-styles"),cssLength:e.textContent?.length||0});let t=document.createElement("style");t.id="kite-chat-position",t.textContent=`
|
|
36
36
|
#kite-chat-root {
|
|
37
37
|
/* Container is just a mount point - ChatPanel handles its own positioning */
|
|
38
38
|
}
|
|
39
|
-
`,document.head.appendChild(t)}function
|
|
39
|
+
`,document.head.appendChild(t)}function Jm(){console.log("[KiteChat-Debug] init() called",{hasConfig:!!window.KiteChatConfig,configKeys:window.KiteChatConfig?Object.keys(window.KiteChatConfig):[]});let e=window.KiteChatConfig;if(!e){console.error("[KiteChat] Missing window.KiteChatConfig"),console.log("[KiteChat-Debug] FAIL: no config");return}if(!e.userId||!e.orgId){console.error("[KiteChat] userId and orgId are required"),console.log("[KiteChat-Debug] FAIL: missing userId/orgId",{hasUserId:!!e.userId,hasOrgId:!!e.orgId});return}if(gs){console.warn("[KiteChat] Already initialized");return}if(TT(),e.container){let t=typeof e.container=="string"?document.querySelector(e.container):e.container;if(console.log("[KiteChat-Debug] Using custom container",{containerSelector:typeof e.container=="string"?e.container:"HTMLElement",foundContainer:!!t,containerId:t?.id||"NO_ID",containerClasses:t?.className||""}),!t){console.error(`[KiteChat] Container not found: ${e.container}`);return}At=document.createElement("div"),At.id="kite-chat-root",t.appendChild(At),console.log("[KiteChat-Debug] Created inner wrapper with kite-chat-root ID inside custom container")}else At=document.createElement("div"),At.id="kite-chat-root",document.body.appendChild(At),console.log("[KiteChat-Debug] Created default container",{containerId:At.id});console.log("[KiteChat-Debug] About to render",{finalContainerId:At?.id||"NO_ID",finalContainerClasses:At?.className||""}),gs=(0,LS.createRoot)(At),gs.render((0,eh.jsx)(PT,{initialConfig:e})),window.KiteChat=AT(),console.log("[KiteChat] Initialized")}function AT(){return{setCurrentPage:e=>qt.setCurrentPage?.(e),setUser:(e,t)=>qt.setConfig?.({userId:e,orgId:t}),setConfig:e=>qt.setConfig?.(e),open:()=>qt.setIsOpen?.(!0),close:()=>qt.setIsOpen?.(!1),toggle:()=>{let e=qt.getIsOpen?.()??!1;qt.setIsOpen?.(!e)},isOpen:()=>qt.getIsOpen?.()??!1,destroy:()=>{gs?.unmount(),gs=null,At?.remove(),At=null,window.KiteChat=void 0},isMounted:()=>gs!==null}}typeof window<"u"&&(document.readyState==="loading"?document.addEventListener("DOMContentLoaded",Jm):Jm());return VS(RT);})();
|
|
40
40
|
/*! Bundled license information:
|
|
41
41
|
|
|
42
42
|
react/cjs/react.production.min.js:
|
|
@@ -107,6 +107,7 @@ lucide-react/dist/esm/icons/laptop.js:
|
|
|
107
107
|
lucide-react/dist/esm/icons/loader-circle.js:
|
|
108
108
|
lucide-react/dist/esm/icons/mail.js:
|
|
109
109
|
lucide-react/dist/esm/icons/map-pin.js:
|
|
110
|
+
lucide-react/dist/esm/icons/minus.js:
|
|
110
111
|
lucide-react/dist/esm/icons/paperclip.js:
|
|
111
112
|
lucide-react/dist/esm/icons/refresh-cw.js:
|
|
112
113
|
lucide-react/dist/esm/icons/search.js:
|