| Server IP : 173.209.174.21 / Your IP : 216.73.216.89 Web Server : Apache/2.4.58 (Ubuntu) System : Linux wcfs-server 6.8.0-124-generic #124-Ubuntu SMP PREEMPT_DYNAMIC Tue May 26 13:00:45 UTC 2026 x86_64 User : nodor ( 1000) PHP Version : 8.3.6 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /var/www/wcfs/NAOPOS/dist/assets/ |
Upload File : |
var xd=e=>{throw TypeError(e)};var Qa=(e,t,n)=>t.has(e)||xd("Cannot "+n);var j=(e,t,n)=>(Qa(e,t,"read from private field"),n?n.call(e):t.get(e)),ee=(e,t,n)=>t.has(e)?xd("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),G=(e,t,n,r)=>(Qa(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),je=(e,t,n)=>(Qa(e,t,"access private method"),n);var Is=(e,t,n,r)=>({set _(o){G(e,t,o,n)},get _(){return j(e,t,r)}});function Ty(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const o in r)if(o!=="default"&&!(o in e)){const s=Object.getOwnPropertyDescriptor(r,o);s&&Object.defineProperty(e,o,s.get?s:{enumerable:!0,get:()=>r[o]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))r(o);new MutationObserver(o=>{for(const s of o)if(s.type==="childList")for(const i of s.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&r(i)}).observe(document,{childList:!0,subtree:!0});function n(o){const s={};return o.integrity&&(s.integrity=o.integrity),o.referrerPolicy&&(s.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?s.credentials="include":o.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function r(o){if(o.ep)return;o.ep=!0;const s=n(o);fetch(o.href,s)}})();function Dp(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Mp={exports:{}},la={},Lp={exports:{}},q={};/**
* @license React
* react.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/var ks=Symbol.for("react.element"),Py=Symbol.for("react.portal"),Ry=Symbol.for("react.fragment"),jy=Symbol.for("react.strict_mode"),Oy=Symbol.for("react.profiler"),_y=Symbol.for("react.provider"),Ay=Symbol.for("react.context"),Dy=Symbol.for("react.forward_ref"),My=Symbol.for("react.suspense"),Ly=Symbol.for("react.memo"),Iy=Symbol.for("react.lazy"),wd=Symbol.iterator;function Fy(e){return e===null||typeof e!="object"?null:(e=wd&&e[wd]||e["@@iterator"],typeof e=="function"?e:null)}var Ip={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Fp=Object.assign,$p={};function bo(e,t,n){this.props=e,this.context=t,this.refs=$p,this.updater=n||Ip}bo.prototype.isReactComponent={};bo.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")};bo.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function zp(){}zp.prototype=bo.prototype;function Yu(e,t,n){this.props=e,this.context=t,this.refs=$p,this.updater=n||Ip}var qu=Yu.prototype=new zp;qu.constructor=Yu;Fp(qu,bo.prototype);qu.isPureReactComponent=!0;var bd=Array.isArray,Bp=Object.prototype.hasOwnProperty,Xu={current:null},Up={key:!0,ref:!0,__self:!0,__source:!0};function Wp(e,t,n){var r,o={},s=null,i=null;if(t!=null)for(r in t.ref!==void 0&&(i=t.ref),t.key!==void 0&&(s=""+t.key),t)Bp.call(t,r)&&!Up.hasOwnProperty(r)&&(o[r]=t[r]);var a=arguments.length-2;if(a===1)o.children=n;else if(1<a){for(var l=Array(a),u=0;u<a;u++)l[u]=arguments[u+2];o.children=l}if(e&&e.defaultProps)for(r in a=e.defaultProps,a)o[r]===void 0&&(o[r]=a[r]);return{$$typeof:ks,type:e,key:s,ref:i,props:o,_owner:Xu.current}}function $y(e,t){return{$$typeof:ks,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Zu(e){return typeof e=="object"&&e!==null&&e.$$typeof===ks}function zy(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var Sd=/\/+/g;function Ga(e,t){return typeof e=="object"&&e!==null&&e.key!=null?zy(""+e.key):t.toString(36)}function ci(e,t,n,r,o){var s=typeof e;(s==="undefined"||s==="boolean")&&(e=null);var i=!1;if(e===null)i=!0;else switch(s){case"string":case"number":i=!0;break;case"object":switch(e.$$typeof){case ks:case Py:i=!0}}if(i)return i=e,o=o(i),e=r===""?"."+Ga(i,0):r,bd(o)?(n="",e!=null&&(n=e.replace(Sd,"$&/")+"/"),ci(o,t,n,"",function(u){return u})):o!=null&&(Zu(o)&&(o=$y(o,n+(!o.key||i&&i.key===o.key?"":(""+o.key).replace(Sd,"$&/")+"/")+e)),t.push(o)),1;if(i=0,r=r===""?".":r+":",bd(e))for(var a=0;a<e.length;a++){s=e[a];var l=r+Ga(s,a);i+=ci(s,t,n,l,o)}else if(l=Fy(e),typeof l=="function")for(e=l.call(e),a=0;!(s=e.next()).done;)s=s.value,l=r+Ga(s,a++),i+=ci(s,t,n,l,o);else if(s==="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 i}function Fs(e,t,n){if(e==null)return e;var r=[],o=0;return ci(e,r,"","",function(s){return t.call(n,s,o++)}),r}function By(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(n){(e._status===0||e._status===-1)&&(e._status=1,e._result=n)},function(n){(e._status===0||e._status===-1)&&(e._status=2,e._result=n)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var Ue={current:null},di={transition:null},Uy={ReactCurrentDispatcher:Ue,ReactCurrentBatchConfig:di,ReactCurrentOwner:Xu};function Hp(){throw Error("act(...) is not supported in production builds of React.")}q.Children={map:Fs,forEach:function(e,t,n){Fs(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return Fs(e,function(){t++}),t},toArray:function(e){return Fs(e,function(t){return t})||[]},only:function(e){if(!Zu(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};q.Component=bo;q.Fragment=Ry;q.Profiler=Oy;q.PureComponent=Yu;q.StrictMode=jy;q.Suspense=My;q.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Uy;q.act=Hp;q.cloneElement=function(e,t,n){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var r=Fp({},e.props),o=e.key,s=e.ref,i=e._owner;if(t!=null){if(t.ref!==void 0&&(s=t.ref,i=Xu.current),t.key!==void 0&&(o=""+t.key),e.type&&e.type.defaultProps)var a=e.type.defaultProps;for(l in t)Bp.call(t,l)&&!Up.hasOwnProperty(l)&&(r[l]=t[l]===void 0&&a!==void 0?a[l]:t[l])}var l=arguments.length-2;if(l===1)r.children=n;else if(1<l){a=Array(l);for(var u=0;u<l;u++)a[u]=arguments[u+2];r.children=a}return{$$typeof:ks,type:e.type,key:o,ref:s,props:r,_owner:i}};q.createContext=function(e){return e={$$typeof:Ay,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:_y,_context:e},e.Consumer=e};q.createElement=Wp;q.createFactory=function(e){var t=Wp.bind(null,e);return t.type=e,t};q.createRef=function(){return{current:null}};q.forwardRef=function(e){return{$$typeof:Dy,render:e}};q.isValidElement=Zu;q.lazy=function(e){return{$$typeof:Iy,_payload:{_status:-1,_result:e},_init:By}};q.memo=function(e,t){return{$$typeof:Ly,type:e,compare:t===void 0?null:t}};q.startTransition=function(e){var t=di.transition;di.transition={};try{e()}finally{di.transition=t}};q.unstable_act=Hp;q.useCallback=function(e,t){return Ue.current.useCallback(e,t)};q.useContext=function(e){return Ue.current.useContext(e)};q.useDebugValue=function(){};q.useDeferredValue=function(e){return Ue.current.useDeferredValue(e)};q.useEffect=function(e,t){return Ue.current.useEffect(e,t)};q.useId=function(){return Ue.current.useId()};q.useImperativeHandle=function(e,t,n){return Ue.current.useImperativeHandle(e,t,n)};q.useInsertionEffect=function(e,t){return Ue.current.useInsertionEffect(e,t)};q.useLayoutEffect=function(e,t){return Ue.current.useLayoutEffect(e,t)};q.useMemo=function(e,t){return Ue.current.useMemo(e,t)};q.useReducer=function(e,t,n){return Ue.current.useReducer(e,t,n)};q.useRef=function(e){return Ue.current.useRef(e)};q.useState=function(e){return Ue.current.useState(e)};q.useSyncExternalStore=function(e,t,n){return Ue.current.useSyncExternalStore(e,t,n)};q.useTransition=function(){return Ue.current.useTransition()};q.version="18.3.1";Lp.exports=q;var v=Lp.exports;const M=Dp(v),Ju=Ty({__proto__:null,default:M},[v]);/**
* @license React
* react-jsx-runtime.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/var Wy=v,Hy=Symbol.for("react.element"),Vy=Symbol.for("react.fragment"),Qy=Object.prototype.hasOwnProperty,Gy=Wy.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,Ky={key:!0,ref:!0,__self:!0,__source:!0};function Vp(e,t,n){var r,o={},s=null,i=null;n!==void 0&&(s=""+n),t.key!==void 0&&(s=""+t.key),t.ref!==void 0&&(i=t.ref);for(r in t)Qy.call(t,r)&&!Ky.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:Hy,type:e,key:s,ref:i,props:o,_owner:Gy.current}}la.Fragment=Vy;la.jsx=Vp;la.jsxs=Vp;Mp.exports=la;var c=Mp.exports,Qp={exports:{}},at={},Gp={exports:{}},Kp={};/**
* @license React
* scheduler.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/(function(e){function t(k,P){var A=k.length;k.push(P);e:for(;0<A;){var U=A-1>>>1,z=k[U];if(0<o(z,P))k[U]=P,k[A]=z,A=U;else break e}}function n(k){return k.length===0?null:k[0]}function r(k){if(k.length===0)return null;var P=k[0],A=k.pop();if(A!==P){k[0]=A;e:for(var U=0,z=k.length,H=z>>>1;U<H;){var Y=2*(U+1)-1,he=k[Y],Ce=Y+1,J=k[Ce];if(0>o(he,A))Ce<z&&0>o(J,he)?(k[U]=J,k[Ce]=A,U=Ce):(k[U]=he,k[Y]=A,U=Y);else if(Ce<z&&0>o(J,A))k[U]=J,k[Ce]=A,U=Ce;else break e}}return P}function o(k,P){var A=k.sortIndex-P.sortIndex;return A!==0?A:k.id-P.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;e.unstable_now=function(){return s.now()}}else{var i=Date,a=i.now();e.unstable_now=function(){return i.now()-a}}var l=[],u=[],d=1,p=null,y=3,f=!1,b=!1,g=!1,x=typeof setTimeout=="function"?setTimeout:null,h=typeof clearTimeout=="function"?clearTimeout:null,m=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function w(k){for(var P=n(u);P!==null;){if(P.callback===null)r(u);else if(P.startTime<=k)r(u),P.sortIndex=P.expirationTime,t(l,P);else break;P=n(u)}}function S(k){if(g=!1,w(k),!b)if(n(l)!==null)b=!0,T(C);else{var P=n(u);P!==null&&O(S,P.startTime-k)}}function C(k,P){b=!1,g&&(g=!1,h(R),R=-1),f=!0;var A=y;try{for(w(P),p=n(l);p!==null&&(!(p.expirationTime>P)||k&&!W());){var U=p.callback;if(typeof U=="function"){p.callback=null,y=p.priorityLevel;var z=U(p.expirationTime<=P);P=e.unstable_now(),typeof z=="function"?p.callback=z:p===n(l)&&r(l),w(P)}else r(l);p=n(l)}if(p!==null)var H=!0;else{var Y=n(u);Y!==null&&O(S,Y.startTime-P),H=!1}return H}finally{p=null,y=A,f=!1}}var N=!1,E=null,R=-1,D=5,L=-1;function W(){return!(e.unstable_now()-L<D)}function $(){if(E!==null){var k=e.unstable_now();L=k;var P=!0;try{P=E(!0,k)}finally{P?V():(N=!1,E=null)}}else N=!1}var V;if(typeof m=="function")V=function(){m($)};else if(typeof MessageChannel<"u"){var F=new MessageChannel,I=F.port2;F.port1.onmessage=$,V=function(){I.postMessage(null)}}else V=function(){x($,0)};function T(k){E=k,N||(N=!0,V())}function O(k,P){R=x(function(){k(e.unstable_now())},P)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(k){k.callback=null},e.unstable_continueExecution=function(){b||f||(b=!0,T(C))},e.unstable_forceFrameRate=function(k){0>k||125<k?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):D=0<k?Math.floor(1e3/k):5},e.unstable_getCurrentPriorityLevel=function(){return y},e.unstable_getFirstCallbackNode=function(){return n(l)},e.unstable_next=function(k){switch(y){case 1:case 2:case 3:var P=3;break;default:P=y}var A=y;y=P;try{return k()}finally{y=A}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(k,P){switch(k){case 1:case 2:case 3:case 4:case 5:break;default:k=3}var A=y;y=k;try{return P()}finally{y=A}},e.unstable_scheduleCallback=function(k,P,A){var U=e.unstable_now();switch(typeof A=="object"&&A!==null?(A=A.delay,A=typeof A=="number"&&0<A?U+A:U):A=U,k){case 1:var z=-1;break;case 2:z=250;break;case 5:z=1073741823;break;case 4:z=1e4;break;default:z=5e3}return z=A+z,k={id:d++,callback:P,priorityLevel:k,startTime:A,expirationTime:z,sortIndex:-1},A>U?(k.sortIndex=A,t(u,k),n(l)===null&&k===n(u)&&(g?(h(R),R=-1):g=!0,O(S,A-U))):(k.sortIndex=z,t(l,k),b||f||(b=!0,T(C))),k},e.unstable_shouldYield=W,e.unstable_wrapCallback=function(k){var P=y;return function(){var A=y;y=P;try{return k.apply(this,arguments)}finally{y=A}}}})(Kp);Gp.exports=Kp;var Yy=Gp.exports;/**
* @license React
* react-dom.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/var qy=v,it=Yy;function _(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);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 Yp=new Set,ts={};function Er(e,t){fo(e,t),fo(e+"Capture",t)}function fo(e,t){for(ts[e]=t,e=0;e<t.length;e++)Yp.add(t[e])}var on=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Il=Object.prototype.hasOwnProperty,Xy=/^[: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]*$/,Cd={},Ed={};function Zy(e){return Il.call(Ed,e)?!0:Il.call(Cd,e)?!1:Xy.test(e)?Ed[e]=!0:(Cd[e]=!0,!1)}function Jy(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function e0(e,t,n,r){if(t===null||typeof t>"u"||Jy(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.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 We(e,t,n,r,o,s,i){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=i}var Re={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Re[e]=new We(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Re[t]=new We(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Re[e]=new We(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Re[e]=new We(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){Re[e]=new We(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Re[e]=new We(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Re[e]=new We(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Re[e]=new We(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Re[e]=new We(e,5,!1,e.toLowerCase(),null,!1,!1)});var ec=/[\-:]([a-z])/g;function tc(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(ec,tc);Re[t]=new We(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(ec,tc);Re[t]=new We(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(ec,tc);Re[t]=new We(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Re[e]=new We(e,1,!1,e.toLowerCase(),null,!1,!1)});Re.xlinkHref=new We("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Re[e]=new We(e,1,!1,e.toLowerCase(),null,!0,!0)});function nc(e,t,n,r){var o=Re.hasOwnProperty(t)?Re[t]:null;(o!==null?o.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(e0(t,n,o,r)&&(n=null),r||o===null?Zy(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):o.mustUseProperty?e[o.propertyName]=n===null?o.type===3?!1:"":n:(t=o.attributeName,r=o.attributeNamespace,n===null?e.removeAttribute(t):(o=o.type,n=o===3||o===4&&n===!0?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}var fn=qy.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,$s=Symbol.for("react.element"),Mr=Symbol.for("react.portal"),Lr=Symbol.for("react.fragment"),rc=Symbol.for("react.strict_mode"),Fl=Symbol.for("react.profiler"),qp=Symbol.for("react.provider"),Xp=Symbol.for("react.context"),oc=Symbol.for("react.forward_ref"),$l=Symbol.for("react.suspense"),zl=Symbol.for("react.suspense_list"),sc=Symbol.for("react.memo"),Nn=Symbol.for("react.lazy"),Zp=Symbol.for("react.offscreen"),kd=Symbol.iterator;function jo(e){return e===null||typeof e!="object"?null:(e=kd&&e[kd]||e["@@iterator"],typeof e=="function"?e:null)}var pe=Object.assign,Ka;function zo(e){if(Ka===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);Ka=t&&t[1]||""}return`
`+Ka+e}var Ya=!1;function qa(e,t){if(!e||Ya)return"";Ya=!0;var n=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(`
`),s=r.stack.split(`
`),i=o.length-1,a=s.length-1;1<=i&&0<=a&&o[i]!==s[a];)a--;for(;1<=i&&0<=a;i--,a--)if(o[i]!==s[a]){if(i!==1||a!==1)do if(i--,a--,0>a||o[i]!==s[a]){var l=`
`+o[i].replace(" at new "," at ");return e.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",e.displayName)),l}while(1<=i&&0<=a);break}}}finally{Ya=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?zo(e):""}function t0(e){switch(e.tag){case 5:return zo(e.type);case 16:return zo("Lazy");case 13:return zo("Suspense");case 19:return zo("SuspenseList");case 0:case 2:case 15:return e=qa(e.type,!1),e;case 11:return e=qa(e.type.render,!1),e;case 1:return e=qa(e.type,!0),e;default:return""}}function Bl(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 Lr:return"Fragment";case Mr:return"Portal";case Fl:return"Profiler";case rc:return"StrictMode";case $l:return"Suspense";case zl:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Xp:return(e.displayName||"Context")+".Consumer";case qp:return(e._context.displayName||"Context")+".Provider";case oc:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case sc:return t=e.displayName||null,t!==null?t:Bl(e.type)||"Memo";case Nn:t=e._payload,e=e._init;try{return Bl(e(t))}catch{}}return null}function n0(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 Bl(t);case 8:return t===rc?"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 Kn(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Jp(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function r0(e){var t=Jp(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var o=n.get,s=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(i){r=""+i,s.call(this,i)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(i){r=""+i},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function zs(e){e._valueTracker||(e._valueTracker=r0(e))}function eh(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Jp(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Pi(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 Ul(e,t){var n=t.checked;return pe({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Nd(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Kn(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function th(e,t){t=t.checked,t!=null&&nc(e,"checked",t,!1)}function Wl(e,t){th(e,t);var n=Kn(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Hl(e,t.type,n):t.hasOwnProperty("defaultValue")&&Hl(e,t.type,Kn(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Td(e,t,n){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,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function Hl(e,t,n){(t!=="number"||Pi(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Bo=Array.isArray;function Gr(e,t,n,r){if(e=e.options,t){t={};for(var o=0;o<n.length;o++)t["$"+n[o]]=!0;for(n=0;n<e.length;n++)o=t.hasOwnProperty("$"+e[n].value),e[n].selected!==o&&(e[n].selected=o),o&&r&&(e[n].defaultSelected=!0)}else{for(n=""+Kn(n),t=null,o=0;o<e.length;o++){if(e[o].value===n){e[o].selected=!0,r&&(e[o].defaultSelected=!0);return}t!==null||e[o].disabled||(t=e[o])}t!==null&&(t.selected=!0)}}function Vl(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(_(91));return pe({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function Pd(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(_(92));if(Bo(n)){if(1<n.length)throw Error(_(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:Kn(n)}}function nh(e,t){var n=Kn(t.value),r=Kn(t.defaultValue);n!=null&&(n=""+n,n!==e.value&&(e.value=n),t.defaultValue==null&&e.defaultValue!==n&&(e.defaultValue=n)),r!=null&&(e.defaultValue=""+r)}function Rd(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function rh(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 Ql(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?rh(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var Bs,oh=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,r,o){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,o)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(Bs=Bs||document.createElement("div"),Bs.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=Bs.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function ns(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Vo={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},o0=["Webkit","ms","Moz","O"];Object.keys(Vo).forEach(function(e){o0.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Vo[t]=Vo[e]})});function sh(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Vo.hasOwnProperty(e)&&Vo[e]?(""+t).trim():t+"px"}function ih(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,o=sh(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,o):e[n]=o}}var s0=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 Gl(e,t){if(t){if(s0[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(_(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(_(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(_(61))}if(t.style!=null&&typeof t.style!="object")throw Error(_(62))}}function Kl(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 Yl=null;function ic(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var ql=null,Kr=null,Yr=null;function jd(e){if(e=Ps(e)){if(typeof ql!="function")throw Error(_(280));var t=e.stateNode;t&&(t=pa(t),ql(e.stateNode,e.type,t))}}function ah(e){Kr?Yr?Yr.push(e):Yr=[e]:Kr=e}function lh(){if(Kr){var e=Kr,t=Yr;if(Yr=Kr=null,jd(e),t)for(e=0;e<t.length;e++)jd(t[e])}}function uh(e,t){return e(t)}function ch(){}var Xa=!1;function dh(e,t,n){if(Xa)return e(t,n);Xa=!0;try{return uh(e,t,n)}finally{Xa=!1,(Kr!==null||Yr!==null)&&(ch(),lh())}}function rs(e,t){var n=e.stateNode;if(n===null)return null;var r=pa(n);if(r===null)return null;n=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(n&&typeof n!="function")throw Error(_(231,t,typeof n));return n}var Xl=!1;if(on)try{var Oo={};Object.defineProperty(Oo,"passive",{get:function(){Xl=!0}}),window.addEventListener("test",Oo,Oo),window.removeEventListener("test",Oo,Oo)}catch{Xl=!1}function i0(e,t,n,r,o,s,i,a,l){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(d){this.onError(d)}}var Qo=!1,Ri=null,ji=!1,Zl=null,a0={onError:function(e){Qo=!0,Ri=e}};function l0(e,t,n,r,o,s,i,a,l){Qo=!1,Ri=null,i0.apply(a0,arguments)}function u0(e,t,n,r,o,s,i,a,l){if(l0.apply(this,arguments),Qo){if(Qo){var u=Ri;Qo=!1,Ri=null}else throw Error(_(198));ji||(ji=!0,Zl=u)}}function kr(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function fh(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 Od(e){if(kr(e)!==e)throw Error(_(188))}function c0(e){var t=e.alternate;if(!t){if(t=kr(e),t===null)throw Error(_(188));return t!==e?null:e}for(var n=e,r=t;;){var o=n.return;if(o===null)break;var s=o.alternate;if(s===null){if(r=o.return,r!==null){n=r;continue}break}if(o.child===s.child){for(s=o.child;s;){if(s===n)return Od(o),e;if(s===r)return Od(o),t;s=s.sibling}throw Error(_(188))}if(n.return!==r.return)n=o,r=s;else{for(var i=!1,a=o.child;a;){if(a===n){i=!0,n=o,r=s;break}if(a===r){i=!0,r=o,n=s;break}a=a.sibling}if(!i){for(a=s.child;a;){if(a===n){i=!0,n=s,r=o;break}if(a===r){i=!0,r=s,n=o;break}a=a.sibling}if(!i)throw Error(_(189))}}if(n.alternate!==r)throw Error(_(190))}if(n.tag!==3)throw Error(_(188));return n.stateNode.current===n?e:t}function ph(e){return e=c0(e),e!==null?hh(e):null}function hh(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=hh(e);if(t!==null)return t;e=e.sibling}return null}var mh=it.unstable_scheduleCallback,_d=it.unstable_cancelCallback,d0=it.unstable_shouldYield,f0=it.unstable_requestPaint,ve=it.unstable_now,p0=it.unstable_getCurrentPriorityLevel,ac=it.unstable_ImmediatePriority,gh=it.unstable_UserBlockingPriority,Oi=it.unstable_NormalPriority,h0=it.unstable_LowPriority,vh=it.unstable_IdlePriority,ua=null,Wt=null;function m0(e){if(Wt&&typeof Wt.onCommitFiberRoot=="function")try{Wt.onCommitFiberRoot(ua,e,void 0,(e.current.flags&128)===128)}catch{}}var Pt=Math.clz32?Math.clz32:y0,g0=Math.log,v0=Math.LN2;function y0(e){return e>>>=0,e===0?32:31-(g0(e)/v0|0)|0}var Us=64,Ws=4194304;function Uo(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 _i(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,o=e.suspendedLanes,s=e.pingedLanes,i=n&268435455;if(i!==0){var a=i&~o;a!==0?r=Uo(a):(s&=i,s!==0&&(r=Uo(s)))}else i=n&~o,i!==0?r=Uo(i):s!==0&&(r=Uo(s));if(r===0)return 0;if(t!==0&&t!==r&&!(t&o)&&(o=r&-r,s=t&-t,o>=s||o===16&&(s&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0<t;)n=31-Pt(t),o=1<<n,r|=e[n],t&=~o;return r}function x0(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 w0(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,o=e.expirationTimes,s=e.pendingLanes;0<s;){var i=31-Pt(s),a=1<<i,l=o[i];l===-1?(!(a&n)||a&r)&&(o[i]=x0(a,t)):l<=t&&(e.expiredLanes|=a),s&=~a}}function Jl(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function yh(){var e=Us;return Us<<=1,!(Us&4194240)&&(Us=64),e}function Za(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Ns(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Pt(t),e[t]=n}function b0(e,t){var n=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<n;){var o=31-Pt(n),s=1<<o;t[o]=0,r[o]=-1,e[o]=-1,n&=~s}}function lc(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Pt(n),o=1<<r;o&t|e[r]&t&&(e[r]|=t),n&=~o}}var te=0;function xh(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var wh,uc,bh,Sh,Ch,eu=!1,Hs=[],$n=null,zn=null,Bn=null,os=new Map,ss=new Map,Pn=[],S0="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 Ad(e,t){switch(e){case"focusin":case"focusout":$n=null;break;case"dragenter":case"dragleave":zn=null;break;case"mouseover":case"mouseout":Bn=null;break;case"pointerover":case"pointerout":os.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":ss.delete(t.pointerId)}}function _o(e,t,n,r,o,s){return e===null||e.nativeEvent!==s?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:s,targetContainers:[o]},t!==null&&(t=Ps(t),t!==null&&uc(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,o!==null&&t.indexOf(o)===-1&&t.push(o),e)}function C0(e,t,n,r,o){switch(t){case"focusin":return $n=_o($n,e,t,n,r,o),!0;case"dragenter":return zn=_o(zn,e,t,n,r,o),!0;case"mouseover":return Bn=_o(Bn,e,t,n,r,o),!0;case"pointerover":var s=o.pointerId;return os.set(s,_o(os.get(s)||null,e,t,n,r,o)),!0;case"gotpointercapture":return s=o.pointerId,ss.set(s,_o(ss.get(s)||null,e,t,n,r,o)),!0}return!1}function Eh(e){var t=ir(e.target);if(t!==null){var n=kr(t);if(n!==null){if(t=n.tag,t===13){if(t=fh(n),t!==null){e.blockedOn=t,Ch(e.priority,function(){bh(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function fi(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=tu(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);Yl=r,n.target.dispatchEvent(r),Yl=null}else return t=Ps(n),t!==null&&uc(t),e.blockedOn=n,!1;t.shift()}return!0}function Dd(e,t,n){fi(e)&&n.delete(t)}function E0(){eu=!1,$n!==null&&fi($n)&&($n=null),zn!==null&&fi(zn)&&(zn=null),Bn!==null&&fi(Bn)&&(Bn=null),os.forEach(Dd),ss.forEach(Dd)}function Ao(e,t){e.blockedOn===t&&(e.blockedOn=null,eu||(eu=!0,it.unstable_scheduleCallback(it.unstable_NormalPriority,E0)))}function is(e){function t(o){return Ao(o,e)}if(0<Hs.length){Ao(Hs[0],e);for(var n=1;n<Hs.length;n++){var r=Hs[n];r.blockedOn===e&&(r.blockedOn=null)}}for($n!==null&&Ao($n,e),zn!==null&&Ao(zn,e),Bn!==null&&Ao(Bn,e),os.forEach(t),ss.forEach(t),n=0;n<Pn.length;n++)r=Pn[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<Pn.length&&(n=Pn[0],n.blockedOn===null);)Eh(n),n.blockedOn===null&&Pn.shift()}var qr=fn.ReactCurrentBatchConfig,Ai=!0;function k0(e,t,n,r){var o=te,s=qr.transition;qr.transition=null;try{te=1,cc(e,t,n,r)}finally{te=o,qr.transition=s}}function N0(e,t,n,r){var o=te,s=qr.transition;qr.transition=null;try{te=4,cc(e,t,n,r)}finally{te=o,qr.transition=s}}function cc(e,t,n,r){if(Ai){var o=tu(e,t,n,r);if(o===null)ll(e,t,r,Di,n),Ad(e,r);else if(C0(o,e,t,n,r))r.stopPropagation();else if(Ad(e,r),t&4&&-1<S0.indexOf(e)){for(;o!==null;){var s=Ps(o);if(s!==null&&wh(s),s=tu(e,t,n,r),s===null&&ll(e,t,r,Di,n),s===o)break;o=s}o!==null&&r.stopPropagation()}else ll(e,t,r,null,n)}}var Di=null;function tu(e,t,n,r){if(Di=null,e=ic(r),e=ir(e),e!==null)if(t=kr(e),t===null)e=null;else if(n=t.tag,n===13){if(e=fh(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return Di=e,null}function kh(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(p0()){case ac:return 1;case gh:return 4;case Oi:case h0:return 16;case vh:return 536870912;default:return 16}default:return 16}}var Mn=null,dc=null,pi=null;function Nh(){if(pi)return pi;var e,t=dc,n=t.length,r,o="value"in Mn?Mn.value:Mn.textContent,s=o.length;for(e=0;e<n&&t[e]===o[e];e++);var i=n-e;for(r=1;r<=i&&t[n-r]===o[s-r];r++);return pi=o.slice(e,1<r?1-r:void 0)}function hi(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 Vs(){return!0}function Md(){return!1}function lt(e){function t(n,r,o,s,i){this._reactName=n,this._targetInst=o,this.type=r,this.nativeEvent=s,this.target=i,this.currentTarget=null;for(var a in e)e.hasOwnProperty(a)&&(n=e[a],this[a]=n?n(s):s[a]);return this.isDefaultPrevented=(s.defaultPrevented!=null?s.defaultPrevented:s.returnValue===!1)?Vs:Md,this.isPropagationStopped=Md,this}return pe(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=Vs)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=Vs)},persist:function(){},isPersistent:Vs}),t}var So={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},fc=lt(So),Ts=pe({},So,{view:0,detail:0}),T0=lt(Ts),Ja,el,Do,ca=pe({},Ts,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:pc,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!==Do&&(Do&&e.type==="mousemove"?(Ja=e.screenX-Do.screenX,el=e.screenY-Do.screenY):el=Ja=0,Do=e),Ja)},movementY:function(e){return"movementY"in e?e.movementY:el}}),Ld=lt(ca),P0=pe({},ca,{dataTransfer:0}),R0=lt(P0),j0=pe({},Ts,{relatedTarget:0}),tl=lt(j0),O0=pe({},So,{animationName:0,elapsedTime:0,pseudoElement:0}),_0=lt(O0),A0=pe({},So,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),D0=lt(A0),M0=pe({},So,{data:0}),Id=lt(M0),L0={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},I0={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"},F0={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function $0(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=F0[e])?!!t[e]:!1}function pc(){return $0}var z0=pe({},Ts,{key:function(e){if(e.key){var t=L0[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=hi(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?I0[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:pc,charCode:function(e){return e.type==="keypress"?hi(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?hi(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),B0=lt(z0),U0=pe({},ca,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Fd=lt(U0),W0=pe({},Ts,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:pc}),H0=lt(W0),V0=pe({},So,{propertyName:0,elapsedTime:0,pseudoElement:0}),Q0=lt(V0),G0=pe({},ca,{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}),K0=lt(G0),Y0=[9,13,27,32],hc=on&&"CompositionEvent"in window,Go=null;on&&"documentMode"in document&&(Go=document.documentMode);var q0=on&&"TextEvent"in window&&!Go,Th=on&&(!hc||Go&&8<Go&&11>=Go),$d=" ",zd=!1;function Ph(e,t){switch(e){case"keyup":return Y0.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Rh(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Ir=!1;function X0(e,t){switch(e){case"compositionend":return Rh(t);case"keypress":return t.which!==32?null:(zd=!0,$d);case"textInput":return e=t.data,e===$d&&zd?null:e;default:return null}}function Z0(e,t){if(Ir)return e==="compositionend"||!hc&&Ph(e,t)?(e=Nh(),pi=dc=Mn=null,Ir=!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 Th&&t.locale!=="ko"?null:t.data;default:return null}}var J0={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 Bd(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!J0[e.type]:t==="textarea"}function jh(e,t,n,r){ah(r),t=Mi(t,"onChange"),0<t.length&&(n=new fc("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Ko=null,as=null;function ex(e){Bh(e,0)}function da(e){var t=zr(e);if(eh(t))return e}function tx(e,t){if(e==="change")return t}var Oh=!1;if(on){var nl;if(on){var rl="oninput"in document;if(!rl){var Ud=document.createElement("div");Ud.setAttribute("oninput","return;"),rl=typeof Ud.oninput=="function"}nl=rl}else nl=!1;Oh=nl&&(!document.documentMode||9<document.documentMode)}function Wd(){Ko&&(Ko.detachEvent("onpropertychange",_h),as=Ko=null)}function _h(e){if(e.propertyName==="value"&&da(as)){var t=[];jh(t,as,e,ic(e)),dh(ex,t)}}function nx(e,t,n){e==="focusin"?(Wd(),Ko=t,as=n,Ko.attachEvent("onpropertychange",_h)):e==="focusout"&&Wd()}function rx(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return da(as)}function ox(e,t){if(e==="click")return da(t)}function sx(e,t){if(e==="input"||e==="change")return da(t)}function ix(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var jt=typeof Object.is=="function"?Object.is:ix;function ls(e,t){if(jt(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var o=n[r];if(!Il.call(t,o)||!jt(e[o],t[o]))return!1}return!0}function Hd(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Vd(e,t){var n=Hd(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Hd(n)}}function Ah(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Ah(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Dh(){for(var e=window,t=Pi();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Pi(e.document)}return t}function mc(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 ax(e){var t=Dh(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Ah(n.ownerDocument.documentElement,n)){if(r!==null&&mc(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var o=n.textContent.length,s=Math.min(r.start,o);r=r.end===void 0?s:Math.min(r.end,o),!e.extend&&s>r&&(o=r,r=s,s=o),o=Vd(n,s);var i=Vd(n,r);o&&i&&(e.rangeCount!==1||e.anchorNode!==o.node||e.anchorOffset!==o.offset||e.focusNode!==i.node||e.focusOffset!==i.offset)&&(t=t.createRange(),t.setStart(o.node,o.offset),e.removeAllRanges(),s>r?(e.addRange(t),e.extend(i.node,i.offset)):(t.setEnd(i.node,i.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n<t.length;n++)e=t[n],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var lx=on&&"documentMode"in document&&11>=document.documentMode,Fr=null,nu=null,Yo=null,ru=!1;function Qd(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;ru||Fr==null||Fr!==Pi(r)||(r=Fr,"selectionStart"in r&&mc(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}),Yo&&ls(Yo,r)||(Yo=r,r=Mi(nu,"onSelect"),0<r.length&&(t=new fc("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=Fr)))}function Qs(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var $r={animationend:Qs("Animation","AnimationEnd"),animationiteration:Qs("Animation","AnimationIteration"),animationstart:Qs("Animation","AnimationStart"),transitionend:Qs("Transition","TransitionEnd")},ol={},Mh={};on&&(Mh=document.createElement("div").style,"AnimationEvent"in window||(delete $r.animationend.animation,delete $r.animationiteration.animation,delete $r.animationstart.animation),"TransitionEvent"in window||delete $r.transitionend.transition);function fa(e){if(ol[e])return ol[e];if(!$r[e])return e;var t=$r[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Mh)return ol[e]=t[n];return e}var Lh=fa("animationend"),Ih=fa("animationiteration"),Fh=fa("animationstart"),$h=fa("transitionend"),zh=new Map,Gd="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 Zn(e,t){zh.set(e,t),Er(t,[e])}for(var sl=0;sl<Gd.length;sl++){var il=Gd[sl],ux=il.toLowerCase(),cx=il[0].toUpperCase()+il.slice(1);Zn(ux,"on"+cx)}Zn(Lh,"onAnimationEnd");Zn(Ih,"onAnimationIteration");Zn(Fh,"onAnimationStart");Zn("dblclick","onDoubleClick");Zn("focusin","onFocus");Zn("focusout","onBlur");Zn($h,"onTransitionEnd");fo("onMouseEnter",["mouseout","mouseover"]);fo("onMouseLeave",["mouseout","mouseover"]);fo("onPointerEnter",["pointerout","pointerover"]);fo("onPointerLeave",["pointerout","pointerover"]);Er("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Er("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Er("onBeforeInput",["compositionend","keypress","textInput","paste"]);Er("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Er("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Er("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Wo="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(" "),dx=new Set("cancel close invalid load scroll toggle".split(" ").concat(Wo));function Kd(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,u0(r,t,void 0,e),e.currentTarget=null}function Bh(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],o=r.event;r=r.listeners;e:{var s=void 0;if(t)for(var i=r.length-1;0<=i;i--){var a=r[i],l=a.instance,u=a.currentTarget;if(a=a.listener,l!==s&&o.isPropagationStopped())break e;Kd(o,a,u),s=l}else for(i=0;i<r.length;i++){if(a=r[i],l=a.instance,u=a.currentTarget,a=a.listener,l!==s&&o.isPropagationStopped())break e;Kd(o,a,u),s=l}}}if(ji)throw e=Zl,ji=!1,Zl=null,e}function se(e,t){var n=t[lu];n===void 0&&(n=t[lu]=new Set);var r=e+"__bubble";n.has(r)||(Uh(t,e,2,!1),n.add(r))}function al(e,t,n){var r=0;t&&(r|=4),Uh(n,e,r,t)}var Gs="_reactListening"+Math.random().toString(36).slice(2);function us(e){if(!e[Gs]){e[Gs]=!0,Yp.forEach(function(n){n!=="selectionchange"&&(dx.has(n)||al(n,!1,e),al(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Gs]||(t[Gs]=!0,al("selectionchange",!1,t))}}function Uh(e,t,n,r){switch(kh(t)){case 1:var o=k0;break;case 4:o=N0;break;default:o=cc}n=o.bind(null,t,n,e),o=void 0,!Xl||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(o=!0),r?o!==void 0?e.addEventListener(t,n,{capture:!0,passive:o}):e.addEventListener(t,n,!0):o!==void 0?e.addEventListener(t,n,{passive:o}):e.addEventListener(t,n,!1)}function ll(e,t,n,r,o){var s=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var i=r.tag;if(i===3||i===4){var a=r.stateNode.containerInfo;if(a===o||a.nodeType===8&&a.parentNode===o)break;if(i===4)for(i=r.return;i!==null;){var l=i.tag;if((l===3||l===4)&&(l=i.stateNode.containerInfo,l===o||l.nodeType===8&&l.parentNode===o))return;i=i.return}for(;a!==null;){if(i=ir(a),i===null)return;if(l=i.tag,l===5||l===6){r=s=i;continue e}a=a.parentNode}}r=r.return}dh(function(){var u=s,d=ic(n),p=[];e:{var y=zh.get(e);if(y!==void 0){var f=fc,b=e;switch(e){case"keypress":if(hi(n)===0)break e;case"keydown":case"keyup":f=B0;break;case"focusin":b="focus",f=tl;break;case"focusout":b="blur",f=tl;break;case"beforeblur":case"afterblur":f=tl;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":f=Ld;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":f=R0;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":f=H0;break;case Lh:case Ih:case Fh:f=_0;break;case $h:f=Q0;break;case"scroll":f=T0;break;case"wheel":f=K0;break;case"copy":case"cut":case"paste":f=D0;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":f=Fd}var g=(t&4)!==0,x=!g&&e==="scroll",h=g?y!==null?y+"Capture":null:y;g=[];for(var m=u,w;m!==null;){w=m;var S=w.stateNode;if(w.tag===5&&S!==null&&(w=S,h!==null&&(S=rs(m,h),S!=null&&g.push(cs(m,S,w)))),x)break;m=m.return}0<g.length&&(y=new f(y,b,null,n,d),p.push({event:y,listeners:g}))}}if(!(t&7)){e:{if(y=e==="mouseover"||e==="pointerover",f=e==="mouseout"||e==="pointerout",y&&n!==Yl&&(b=n.relatedTarget||n.fromElement)&&(ir(b)||b[sn]))break e;if((f||y)&&(y=d.window===d?d:(y=d.ownerDocument)?y.defaultView||y.parentWindow:window,f?(b=n.relatedTarget||n.toElement,f=u,b=b?ir(b):null,b!==null&&(x=kr(b),b!==x||b.tag!==5&&b.tag!==6)&&(b=null)):(f=null,b=u),f!==b)){if(g=Ld,S="onMouseLeave",h="onMouseEnter",m="mouse",(e==="pointerout"||e==="pointerover")&&(g=Fd,S="onPointerLeave",h="onPointerEnter",m="pointer"),x=f==null?y:zr(f),w=b==null?y:zr(b),y=new g(S,m+"leave",f,n,d),y.target=x,y.relatedTarget=w,S=null,ir(d)===u&&(g=new g(h,m+"enter",b,n,d),g.target=w,g.relatedTarget=x,S=g),x=S,f&&b)t:{for(g=f,h=b,m=0,w=g;w;w=Or(w))m++;for(w=0,S=h;S;S=Or(S))w++;for(;0<m-w;)g=Or(g),m--;for(;0<w-m;)h=Or(h),w--;for(;m--;){if(g===h||h!==null&&g===h.alternate)break t;g=Or(g),h=Or(h)}g=null}else g=null;f!==null&&Yd(p,y,f,g,!1),b!==null&&x!==null&&Yd(p,x,b,g,!0)}}e:{if(y=u?zr(u):window,f=y.nodeName&&y.nodeName.toLowerCase(),f==="select"||f==="input"&&y.type==="file")var C=tx;else if(Bd(y))if(Oh)C=sx;else{C=rx;var N=nx}else(f=y.nodeName)&&f.toLowerCase()==="input"&&(y.type==="checkbox"||y.type==="radio")&&(C=ox);if(C&&(C=C(e,u))){jh(p,C,n,d);break e}N&&N(e,y,u),e==="focusout"&&(N=y._wrapperState)&&N.controlled&&y.type==="number"&&Hl(y,"number",y.value)}switch(N=u?zr(u):window,e){case"focusin":(Bd(N)||N.contentEditable==="true")&&(Fr=N,nu=u,Yo=null);break;case"focusout":Yo=nu=Fr=null;break;case"mousedown":ru=!0;break;case"contextmenu":case"mouseup":case"dragend":ru=!1,Qd(p,n,d);break;case"selectionchange":if(lx)break;case"keydown":case"keyup":Qd(p,n,d)}var E;if(hc)e:{switch(e){case"compositionstart":var R="onCompositionStart";break e;case"compositionend":R="onCompositionEnd";break e;case"compositionupdate":R="onCompositionUpdate";break e}R=void 0}else Ir?Ph(e,n)&&(R="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(R="onCompositionStart");R&&(Th&&n.locale!=="ko"&&(Ir||R!=="onCompositionStart"?R==="onCompositionEnd"&&Ir&&(E=Nh()):(Mn=d,dc="value"in Mn?Mn.value:Mn.textContent,Ir=!0)),N=Mi(u,R),0<N.length&&(R=new Id(R,e,null,n,d),p.push({event:R,listeners:N}),E?R.data=E:(E=Rh(n),E!==null&&(R.data=E)))),(E=q0?X0(e,n):Z0(e,n))&&(u=Mi(u,"onBeforeInput"),0<u.length&&(d=new Id("onBeforeInput","beforeinput",null,n,d),p.push({event:d,listeners:u}),d.data=E))}Bh(p,t)})}function cs(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Mi(e,t){for(var n=t+"Capture",r=[];e!==null;){var o=e,s=o.stateNode;o.tag===5&&s!==null&&(o=s,s=rs(e,n),s!=null&&r.unshift(cs(e,s,o)),s=rs(e,t),s!=null&&r.push(cs(e,s,o))),e=e.return}return r}function Or(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function Yd(e,t,n,r,o){for(var s=t._reactName,i=[];n!==null&&n!==r;){var a=n,l=a.alternate,u=a.stateNode;if(l!==null&&l===r)break;a.tag===5&&u!==null&&(a=u,o?(l=rs(n,s),l!=null&&i.unshift(cs(n,l,a))):o||(l=rs(n,s),l!=null&&i.push(cs(n,l,a)))),n=n.return}i.length!==0&&e.push({event:t,listeners:i})}var fx=/\r\n?/g,px=/\u0000|\uFFFD/g;function qd(e){return(typeof e=="string"?e:""+e).replace(fx,`
`).replace(px,"")}function Ks(e,t,n){if(t=qd(t),qd(e)!==t&&n)throw Error(_(425))}function Li(){}var ou=null,su=null;function iu(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 au=typeof setTimeout=="function"?setTimeout:void 0,hx=typeof clearTimeout=="function"?clearTimeout:void 0,Xd=typeof Promise=="function"?Promise:void 0,mx=typeof queueMicrotask=="function"?queueMicrotask:typeof Xd<"u"?function(e){return Xd.resolve(null).then(e).catch(gx)}:au;function gx(e){setTimeout(function(){throw e})}function ul(e,t){var n=t,r=0;do{var o=n.nextSibling;if(e.removeChild(n),o&&o.nodeType===8)if(n=o.data,n==="/$"){if(r===0){e.removeChild(o),is(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=o}while(n);is(t)}function Un(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 Zd(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var Co=Math.random().toString(36).slice(2),zt="__reactFiber$"+Co,ds="__reactProps$"+Co,sn="__reactContainer$"+Co,lu="__reactEvents$"+Co,vx="__reactListeners$"+Co,yx="__reactHandles$"+Co;function ir(e){var t=e[zt];if(t)return t;for(var n=e.parentNode;n;){if(t=n[sn]||n[zt]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Zd(e);e!==null;){if(n=e[zt])return n;e=Zd(e)}return t}e=n,n=e.parentNode}return null}function Ps(e){return e=e[zt]||e[sn],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function zr(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(_(33))}function pa(e){return e[ds]||null}var uu=[],Br=-1;function Jn(e){return{current:e}}function ie(e){0>Br||(e.current=uu[Br],uu[Br]=null,Br--)}function re(e,t){Br++,uu[Br]=e.current,e.current=t}var Yn={},Me=Jn(Yn),Ye=Jn(!1),vr=Yn;function po(e,t){var n=e.type.contextTypes;if(!n)return Yn;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o={},s;for(s in n)o[s]=t[s];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function qe(e){return e=e.childContextTypes,e!=null}function Ii(){ie(Ye),ie(Me)}function Jd(e,t,n){if(Me.current!==Yn)throw Error(_(168));re(Me,t),re(Ye,n)}function Wh(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var o in r)if(!(o in t))throw Error(_(108,n0(e)||"Unknown",o));return pe({},n,r)}function Fi(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Yn,vr=Me.current,re(Me,e),re(Ye,Ye.current),!0}function ef(e,t,n){var r=e.stateNode;if(!r)throw Error(_(169));n?(e=Wh(e,t,vr),r.__reactInternalMemoizedMergedChildContext=e,ie(Ye),ie(Me),re(Me,e)):ie(Ye),re(Ye,n)}var Jt=null,ha=!1,cl=!1;function Hh(e){Jt===null?Jt=[e]:Jt.push(e)}function xx(e){ha=!0,Hh(e)}function er(){if(!cl&&Jt!==null){cl=!0;var e=0,t=te;try{var n=Jt;for(te=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}Jt=null,ha=!1}catch(o){throw Jt!==null&&(Jt=Jt.slice(e+1)),mh(ac,er),o}finally{te=t,cl=!1}}return null}var Ur=[],Wr=0,$i=null,zi=0,dt=[],ft=0,yr=null,tn=1,nn="";function rr(e,t){Ur[Wr++]=zi,Ur[Wr++]=$i,$i=e,zi=t}function Vh(e,t,n){dt[ft++]=tn,dt[ft++]=nn,dt[ft++]=yr,yr=e;var r=tn;e=nn;var o=32-Pt(r)-1;r&=~(1<<o),n+=1;var s=32-Pt(t)+o;if(30<s){var i=o-o%5;s=(r&(1<<i)-1).toString(32),r>>=i,o-=i,tn=1<<32-Pt(t)+o|n<<o|r,nn=s+e}else tn=1<<s|n<<o|r,nn=e}function gc(e){e.return!==null&&(rr(e,1),Vh(e,1,0))}function vc(e){for(;e===$i;)$i=Ur[--Wr],Ur[Wr]=null,zi=Ur[--Wr],Ur[Wr]=null;for(;e===yr;)yr=dt[--ft],dt[ft]=null,nn=dt[--ft],dt[ft]=null,tn=dt[--ft],dt[ft]=null}var ot=null,rt=null,ue=!1,Tt=null;function Qh(e,t){var n=pt(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,t=e.deletions,t===null?(e.deletions=[n],e.flags|=16):t.push(n)}function tf(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,ot=e,rt=Un(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,ot=e,rt=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=yr!==null?{id:tn,overflow:nn}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=pt(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,ot=e,rt=null,!0):!1;default:return!1}}function cu(e){return(e.mode&1)!==0&&(e.flags&128)===0}function du(e){if(ue){var t=rt;if(t){var n=t;if(!tf(e,t)){if(cu(e))throw Error(_(418));t=Un(n.nextSibling);var r=ot;t&&tf(e,t)?Qh(r,n):(e.flags=e.flags&-4097|2,ue=!1,ot=e)}}else{if(cu(e))throw Error(_(418));e.flags=e.flags&-4097|2,ue=!1,ot=e}}}function nf(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;ot=e}function Ys(e){if(e!==ot)return!1;if(!ue)return nf(e),ue=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!iu(e.type,e.memoizedProps)),t&&(t=rt)){if(cu(e))throw Gh(),Error(_(418));for(;t;)Qh(e,t),t=Un(t.nextSibling)}if(nf(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(_(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){rt=Un(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}rt=null}}else rt=ot?Un(e.stateNode.nextSibling):null;return!0}function Gh(){for(var e=rt;e;)e=Un(e.nextSibling)}function ho(){rt=ot=null,ue=!1}function yc(e){Tt===null?Tt=[e]:Tt.push(e)}var wx=fn.ReactCurrentBatchConfig;function Mo(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(_(309));var r=n.stateNode}if(!r)throw Error(_(147,e));var o=r,s=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===s?t.ref:(t=function(i){var a=o.refs;i===null?delete a[s]:a[s]=i},t._stringRef=s,t)}if(typeof e!="string")throw Error(_(284));if(!n._owner)throw Error(_(290,e))}return e}function qs(e,t){throw e=Object.prototype.toString.call(t),Error(_(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function rf(e){var t=e._init;return t(e._payload)}function Kh(e){function t(h,m){if(e){var w=h.deletions;w===null?(h.deletions=[m],h.flags|=16):w.push(m)}}function n(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=Qn(h,m),h.index=0,h.sibling=null,h}function s(h,m,w){return h.index=w,e?(w=h.alternate,w!==null?(w=w.index,w<m?(h.flags|=2,m):w):(h.flags|=2,m)):(h.flags|=1048576,m)}function i(h){return e&&h.alternate===null&&(h.flags|=2),h}function a(h,m,w,S){return m===null||m.tag!==6?(m=vl(w,h.mode,S),m.return=h,m):(m=o(m,w),m.return=h,m)}function l(h,m,w,S){var C=w.type;return C===Lr?d(h,m,w.props.children,S,w.key):m!==null&&(m.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===Nn&&rf(C)===m.type)?(S=o(m,w.props),S.ref=Mo(h,m,w),S.return=h,S):(S=bi(w.type,w.key,w.props,null,h.mode,S),S.ref=Mo(h,m,w),S.return=h,S)}function u(h,m,w,S){return m===null||m.tag!==4||m.stateNode.containerInfo!==w.containerInfo||m.stateNode.implementation!==w.implementation?(m=yl(w,h.mode,S),m.return=h,m):(m=o(m,w.children||[]),m.return=h,m)}function d(h,m,w,S,C){return m===null||m.tag!==7?(m=gr(w,h.mode,S,C),m.return=h,m):(m=o(m,w),m.return=h,m)}function p(h,m,w){if(typeof m=="string"&&m!==""||typeof m=="number")return m=vl(""+m,h.mode,w),m.return=h,m;if(typeof m=="object"&&m!==null){switch(m.$$typeof){case $s:return w=bi(m.type,m.key,m.props,null,h.mode,w),w.ref=Mo(h,null,m),w.return=h,w;case Mr:return m=yl(m,h.mode,w),m.return=h,m;case Nn:var S=m._init;return p(h,S(m._payload),w)}if(Bo(m)||jo(m))return m=gr(m,h.mode,w,null),m.return=h,m;qs(h,m)}return null}function y(h,m,w,S){var C=m!==null?m.key:null;if(typeof w=="string"&&w!==""||typeof w=="number")return C!==null?null:a(h,m,""+w,S);if(typeof w=="object"&&w!==null){switch(w.$$typeof){case $s:return w.key===C?l(h,m,w,S):null;case Mr:return w.key===C?u(h,m,w,S):null;case Nn:return C=w._init,y(h,m,C(w._payload),S)}if(Bo(w)||jo(w))return C!==null?null:d(h,m,w,S,null);qs(h,w)}return null}function f(h,m,w,S,C){if(typeof S=="string"&&S!==""||typeof S=="number")return h=h.get(w)||null,a(m,h,""+S,C);if(typeof S=="object"&&S!==null){switch(S.$$typeof){case $s:return h=h.get(S.key===null?w:S.key)||null,l(m,h,S,C);case Mr:return h=h.get(S.key===null?w:S.key)||null,u(m,h,S,C);case Nn:var N=S._init;return f(h,m,w,N(S._payload),C)}if(Bo(S)||jo(S))return h=h.get(w)||null,d(m,h,S,C,null);qs(m,S)}return null}function b(h,m,w,S){for(var C=null,N=null,E=m,R=m=0,D=null;E!==null&&R<w.length;R++){E.index>R?(D=E,E=null):D=E.sibling;var L=y(h,E,w[R],S);if(L===null){E===null&&(E=D);break}e&&E&&L.alternate===null&&t(h,E),m=s(L,m,R),N===null?C=L:N.sibling=L,N=L,E=D}if(R===w.length)return n(h,E),ue&&rr(h,R),C;if(E===null){for(;R<w.length;R++)E=p(h,w[R],S),E!==null&&(m=s(E,m,R),N===null?C=E:N.sibling=E,N=E);return ue&&rr(h,R),C}for(E=r(h,E);R<w.length;R++)D=f(E,h,R,w[R],S),D!==null&&(e&&D.alternate!==null&&E.delete(D.key===null?R:D.key),m=s(D,m,R),N===null?C=D:N.sibling=D,N=D);return e&&E.forEach(function(W){return t(h,W)}),ue&&rr(h,R),C}function g(h,m,w,S){var C=jo(w);if(typeof C!="function")throw Error(_(150));if(w=C.call(w),w==null)throw Error(_(151));for(var N=C=null,E=m,R=m=0,D=null,L=w.next();E!==null&&!L.done;R++,L=w.next()){E.index>R?(D=E,E=null):D=E.sibling;var W=y(h,E,L.value,S);if(W===null){E===null&&(E=D);break}e&&E&&W.alternate===null&&t(h,E),m=s(W,m,R),N===null?C=W:N.sibling=W,N=W,E=D}if(L.done)return n(h,E),ue&&rr(h,R),C;if(E===null){for(;!L.done;R++,L=w.next())L=p(h,L.value,S),L!==null&&(m=s(L,m,R),N===null?C=L:N.sibling=L,N=L);return ue&&rr(h,R),C}for(E=r(h,E);!L.done;R++,L=w.next())L=f(E,h,R,L.value,S),L!==null&&(e&&L.alternate!==null&&E.delete(L.key===null?R:L.key),m=s(L,m,R),N===null?C=L:N.sibling=L,N=L);return e&&E.forEach(function($){return t(h,$)}),ue&&rr(h,R),C}function x(h,m,w,S){if(typeof w=="object"&&w!==null&&w.type===Lr&&w.key===null&&(w=w.props.children),typeof w=="object"&&w!==null){switch(w.$$typeof){case $s:e:{for(var C=w.key,N=m;N!==null;){if(N.key===C){if(C=w.type,C===Lr){if(N.tag===7){n(h,N.sibling),m=o(N,w.props.children),m.return=h,h=m;break e}}else if(N.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===Nn&&rf(C)===N.type){n(h,N.sibling),m=o(N,w.props),m.ref=Mo(h,N,w),m.return=h,h=m;break e}n(h,N);break}else t(h,N);N=N.sibling}w.type===Lr?(m=gr(w.props.children,h.mode,S,w.key),m.return=h,h=m):(S=bi(w.type,w.key,w.props,null,h.mode,S),S.ref=Mo(h,m,w),S.return=h,h=S)}return i(h);case Mr:e:{for(N=w.key;m!==null;){if(m.key===N)if(m.tag===4&&m.stateNode.containerInfo===w.containerInfo&&m.stateNode.implementation===w.implementation){n(h,m.sibling),m=o(m,w.children||[]),m.return=h,h=m;break e}else{n(h,m);break}else t(h,m);m=m.sibling}m=yl(w,h.mode,S),m.return=h,h=m}return i(h);case Nn:return N=w._init,x(h,m,N(w._payload),S)}if(Bo(w))return b(h,m,w,S);if(jo(w))return g(h,m,w,S);qs(h,w)}return typeof w=="string"&&w!==""||typeof w=="number"?(w=""+w,m!==null&&m.tag===6?(n(h,m.sibling),m=o(m,w),m.return=h,h=m):(n(h,m),m=vl(w,h.mode,S),m.return=h,h=m),i(h)):n(h,m)}return x}var mo=Kh(!0),Yh=Kh(!1),Bi=Jn(null),Ui=null,Hr=null,xc=null;function wc(){xc=Hr=Ui=null}function bc(e){var t=Bi.current;ie(Bi),e._currentValue=t}function fu(e,t,n){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===n)break;e=e.return}}function Xr(e,t){Ui=e,xc=Hr=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Ke=!0),e.firstContext=null)}function mt(e){var t=e._currentValue;if(xc!==e)if(e={context:e,memoizedValue:t,next:null},Hr===null){if(Ui===null)throw Error(_(308));Hr=e,Ui.dependencies={lanes:0,firstContext:e}}else Hr=Hr.next=e;return t}var ar=null;function Sc(e){ar===null?ar=[e]:ar.push(e)}function qh(e,t,n,r){var o=t.interleaved;return o===null?(n.next=n,Sc(t)):(n.next=o.next,o.next=n),t.interleaved=n,an(e,r)}function an(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var Tn=!1;function Cc(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Xh(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 rn(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Wn(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Z&2){var o=r.pending;return o===null?t.next=t:(t.next=o.next,o.next=t),r.pending=t,an(e,n)}return o=r.interleaved,o===null?(t.next=t,Sc(r)):(t.next=o.next,o.next=t),r.interleaved=t,an(e,n)}function mi(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,lc(e,n)}}function of(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var o=null,s=null;if(n=n.firstBaseUpdate,n!==null){do{var i={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};s===null?o=s=i:s=s.next=i,n=n.next}while(n!==null);s===null?o=s=t:s=s.next=t}else o=s=t;n={baseState:r.baseState,firstBaseUpdate:o,lastBaseUpdate:s,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Wi(e,t,n,r){var o=e.updateQueue;Tn=!1;var s=o.firstBaseUpdate,i=o.lastBaseUpdate,a=o.shared.pending;if(a!==null){o.shared.pending=null;var l=a,u=l.next;l.next=null,i===null?s=u:i.next=u,i=l;var d=e.alternate;d!==null&&(d=d.updateQueue,a=d.lastBaseUpdate,a!==i&&(a===null?d.firstBaseUpdate=u:a.next=u,d.lastBaseUpdate=l))}if(s!==null){var p=o.baseState;i=0,d=u=l=null,a=s;do{var y=a.lane,f=a.eventTime;if((r&y)===y){d!==null&&(d=d.next={eventTime:f,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var b=e,g=a;switch(y=t,f=n,g.tag){case 1:if(b=g.payload,typeof b=="function"){p=b.call(f,p,y);break e}p=b;break e;case 3:b.flags=b.flags&-65537|128;case 0:if(b=g.payload,y=typeof b=="function"?b.call(f,p,y):b,y==null)break e;p=pe({},p,y);break e;case 2:Tn=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,y=o.effects,y===null?o.effects=[a]:y.push(a))}else f={eventTime:f,lane:y,tag:a.tag,payload:a.payload,callback:a.callback,next:null},d===null?(u=d=f,l=p):d=d.next=f,i|=y;if(a=a.next,a===null){if(a=o.shared.pending,a===null)break;y=a,a=y.next,y.next=null,o.lastBaseUpdate=y,o.shared.pending=null}}while(!0);if(d===null&&(l=p),o.baseState=l,o.firstBaseUpdate=u,o.lastBaseUpdate=d,t=o.shared.interleaved,t!==null){o=t;do i|=o.lane,o=o.next;while(o!==t)}else s===null&&(o.shared.lanes=0);wr|=i,e.lanes=i,e.memoizedState=p}}function sf(e,t,n){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=n,typeof o!="function")throw Error(_(191,o));o.call(r)}}}var Rs={},Ht=Jn(Rs),fs=Jn(Rs),ps=Jn(Rs);function lr(e){if(e===Rs)throw Error(_(174));return e}function Ec(e,t){switch(re(ps,t),re(fs,e),re(Ht,Rs),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:Ql(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=Ql(t,e)}ie(Ht),re(Ht,t)}function go(){ie(Ht),ie(fs),ie(ps)}function Zh(e){lr(ps.current);var t=lr(Ht.current),n=Ql(t,e.type);t!==n&&(re(fs,e),re(Ht,n))}function kc(e){fs.current===e&&(ie(Ht),ie(fs))}var de=Jn(0);function Hi(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)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 dl=[];function Nc(){for(var e=0;e<dl.length;e++)dl[e]._workInProgressVersionPrimary=null;dl.length=0}var gi=fn.ReactCurrentDispatcher,fl=fn.ReactCurrentBatchConfig,xr=0,fe=null,be=null,Ee=null,Vi=!1,qo=!1,hs=0,bx=0;function Oe(){throw Error(_(321))}function Tc(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!jt(e[n],t[n]))return!1;return!0}function Pc(e,t,n,r,o,s){if(xr=s,fe=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,gi.current=e===null||e.memoizedState===null?kx:Nx,e=n(r,o),qo){s=0;do{if(qo=!1,hs=0,25<=s)throw Error(_(301));s+=1,Ee=be=null,t.updateQueue=null,gi.current=Tx,e=n(r,o)}while(qo)}if(gi.current=Qi,t=be!==null&&be.next!==null,xr=0,Ee=be=fe=null,Vi=!1,t)throw Error(_(300));return e}function Rc(){var e=hs!==0;return hs=0,e}function Lt(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Ee===null?fe.memoizedState=Ee=e:Ee=Ee.next=e,Ee}function gt(){if(be===null){var e=fe.alternate;e=e!==null?e.memoizedState:null}else e=be.next;var t=Ee===null?fe.memoizedState:Ee.next;if(t!==null)Ee=t,be=e;else{if(e===null)throw Error(_(310));be=e,e={memoizedState:be.memoizedState,baseState:be.baseState,baseQueue:be.baseQueue,queue:be.queue,next:null},Ee===null?fe.memoizedState=Ee=e:Ee=Ee.next=e}return Ee}function ms(e,t){return typeof t=="function"?t(e):t}function pl(e){var t=gt(),n=t.queue;if(n===null)throw Error(_(311));n.lastRenderedReducer=e;var r=be,o=r.baseQueue,s=n.pending;if(s!==null){if(o!==null){var i=o.next;o.next=s.next,s.next=i}r.baseQueue=o=s,n.pending=null}if(o!==null){s=o.next,r=r.baseState;var a=i=null,l=null,u=s;do{var d=u.lane;if((xr&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 p={lane:d,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};l===null?(a=l=p,i=r):l=l.next=p,fe.lanes|=d,wr|=d}u=u.next}while(u!==null&&u!==s);l===null?i=r:l.next=a,jt(r,t.memoizedState)||(Ke=!0),t.memoizedState=r,t.baseState=i,t.baseQueue=l,n.lastRenderedState=r}if(e=n.interleaved,e!==null){o=e;do s=o.lane,fe.lanes|=s,wr|=s,o=o.next;while(o!==e)}else o===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function hl(e){var t=gt(),n=t.queue;if(n===null)throw Error(_(311));n.lastRenderedReducer=e;var r=n.dispatch,o=n.pending,s=t.memoizedState;if(o!==null){n.pending=null;var i=o=o.next;do s=e(s,i.action),i=i.next;while(i!==o);jt(s,t.memoizedState)||(Ke=!0),t.memoizedState=s,t.baseQueue===null&&(t.baseState=s),n.lastRenderedState=s}return[s,r]}function Jh(){}function em(e,t){var n=fe,r=gt(),o=t(),s=!jt(r.memoizedState,o);if(s&&(r.memoizedState=o,Ke=!0),r=r.queue,jc(rm.bind(null,n,r,e),[e]),r.getSnapshot!==t||s||Ee!==null&&Ee.memoizedState.tag&1){if(n.flags|=2048,gs(9,nm.bind(null,n,r,o,t),void 0,null),ke===null)throw Error(_(349));xr&30||tm(n,t,o)}return o}function tm(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=fe.updateQueue,t===null?(t={lastEffect:null,stores:null},fe.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function nm(e,t,n,r){t.value=n,t.getSnapshot=r,om(t)&&sm(e)}function rm(e,t,n){return n(function(){om(t)&&sm(e)})}function om(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!jt(e,n)}catch{return!0}}function sm(e){var t=an(e,1);t!==null&&Rt(t,e,1,-1)}function af(e){var t=Lt();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:ms,lastRenderedState:e},t.queue=e,e=e.dispatch=Ex.bind(null,fe,e),[t.memoizedState,e]}function gs(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=fe.updateQueue,t===null?(t={lastEffect:null,stores:null},fe.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e)),e}function im(){return gt().memoizedState}function vi(e,t,n,r){var o=Lt();fe.flags|=e,o.memoizedState=gs(1|t,n,void 0,r===void 0?null:r)}function ma(e,t,n,r){var o=gt();r=r===void 0?null:r;var s=void 0;if(be!==null){var i=be.memoizedState;if(s=i.destroy,r!==null&&Tc(r,i.deps)){o.memoizedState=gs(t,n,s,r);return}}fe.flags|=e,o.memoizedState=gs(1|t,n,s,r)}function lf(e,t){return vi(8390656,8,e,t)}function jc(e,t){return ma(2048,8,e,t)}function am(e,t){return ma(4,2,e,t)}function lm(e,t){return ma(4,4,e,t)}function um(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 cm(e,t,n){return n=n!=null?n.concat([e]):null,ma(4,4,um.bind(null,t,e),n)}function Oc(){}function dm(e,t){var n=gt();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Tc(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function fm(e,t){var n=gt();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Tc(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function pm(e,t,n){return xr&21?(jt(n,t)||(n=yh(),fe.lanes|=n,wr|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,Ke=!0),e.memoizedState=n)}function Sx(e,t){var n=te;te=n!==0&&4>n?n:4,e(!0);var r=fl.transition;fl.transition={};try{e(!1),t()}finally{te=n,fl.transition=r}}function hm(){return gt().memoizedState}function Cx(e,t,n){var r=Vn(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},mm(e))gm(t,n);else if(n=qh(e,t,n,r),n!==null){var o=ze();Rt(n,e,r,o),vm(n,t,r)}}function Ex(e,t,n){var r=Vn(e),o={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(mm(e))gm(t,o);else{var s=e.alternate;if(e.lanes===0&&(s===null||s.lanes===0)&&(s=t.lastRenderedReducer,s!==null))try{var i=t.lastRenderedState,a=s(i,n);if(o.hasEagerState=!0,o.eagerState=a,jt(a,i)){var l=t.interleaved;l===null?(o.next=o,Sc(t)):(o.next=l.next,l.next=o),t.interleaved=o;return}}catch{}finally{}n=qh(e,t,o,r),n!==null&&(o=ze(),Rt(n,e,r,o),vm(n,t,r))}}function mm(e){var t=e.alternate;return e===fe||t!==null&&t===fe}function gm(e,t){qo=Vi=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function vm(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,lc(e,n)}}var Qi={readContext:mt,useCallback:Oe,useContext:Oe,useEffect:Oe,useImperativeHandle:Oe,useInsertionEffect:Oe,useLayoutEffect:Oe,useMemo:Oe,useReducer:Oe,useRef:Oe,useState:Oe,useDebugValue:Oe,useDeferredValue:Oe,useTransition:Oe,useMutableSource:Oe,useSyncExternalStore:Oe,useId:Oe,unstable_isNewReconciler:!1},kx={readContext:mt,useCallback:function(e,t){return Lt().memoizedState=[e,t===void 0?null:t],e},useContext:mt,useEffect:lf,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,vi(4194308,4,um.bind(null,t,e),n)},useLayoutEffect:function(e,t){return vi(4194308,4,e,t)},useInsertionEffect:function(e,t){return vi(4,2,e,t)},useMemo:function(e,t){var n=Lt();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Lt();return t=n!==void 0?n(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=Cx.bind(null,fe,e),[r.memoizedState,e]},useRef:function(e){var t=Lt();return e={current:e},t.memoizedState=e},useState:af,useDebugValue:Oc,useDeferredValue:function(e){return Lt().memoizedState=e},useTransition:function(){var e=af(!1),t=e[0];return e=Sx.bind(null,e[1]),Lt().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=fe,o=Lt();if(ue){if(n===void 0)throw Error(_(407));n=n()}else{if(n=t(),ke===null)throw Error(_(349));xr&30||tm(r,t,n)}o.memoizedState=n;var s={value:n,getSnapshot:t};return o.queue=s,lf(rm.bind(null,r,s,e),[e]),r.flags|=2048,gs(9,nm.bind(null,r,s,n,t),void 0,null),n},useId:function(){var e=Lt(),t=ke.identifierPrefix;if(ue){var n=nn,r=tn;n=(r&~(1<<32-Pt(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=hs++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=bx++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},Nx={readContext:mt,useCallback:dm,useContext:mt,useEffect:jc,useImperativeHandle:cm,useInsertionEffect:am,useLayoutEffect:lm,useMemo:fm,useReducer:pl,useRef:im,useState:function(){return pl(ms)},useDebugValue:Oc,useDeferredValue:function(e){var t=gt();return pm(t,be.memoizedState,e)},useTransition:function(){var e=pl(ms)[0],t=gt().memoizedState;return[e,t]},useMutableSource:Jh,useSyncExternalStore:em,useId:hm,unstable_isNewReconciler:!1},Tx={readContext:mt,useCallback:dm,useContext:mt,useEffect:jc,useImperativeHandle:cm,useInsertionEffect:am,useLayoutEffect:lm,useMemo:fm,useReducer:hl,useRef:im,useState:function(){return hl(ms)},useDebugValue:Oc,useDeferredValue:function(e){var t=gt();return be===null?t.memoizedState=e:pm(t,be.memoizedState,e)},useTransition:function(){var e=hl(ms)[0],t=gt().memoizedState;return[e,t]},useMutableSource:Jh,useSyncExternalStore:em,useId:hm,unstable_isNewReconciler:!1};function St(e,t){if(e&&e.defaultProps){t=pe({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function pu(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:pe({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var ga={isMounted:function(e){return(e=e._reactInternals)?kr(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=ze(),o=Vn(e),s=rn(r,o);s.payload=t,n!=null&&(s.callback=n),t=Wn(e,s,o),t!==null&&(Rt(t,e,o,r),mi(t,e,o))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=ze(),o=Vn(e),s=rn(r,o);s.tag=1,s.payload=t,n!=null&&(s.callback=n),t=Wn(e,s,o),t!==null&&(Rt(t,e,o,r),mi(t,e,o))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=ze(),r=Vn(e),o=rn(n,r);o.tag=2,t!=null&&(o.callback=t),t=Wn(e,o,r),t!==null&&(Rt(t,e,r,n),mi(t,e,r))}};function uf(e,t,n,r,o,s,i){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,s,i):t.prototype&&t.prototype.isPureReactComponent?!ls(n,r)||!ls(o,s):!0}function ym(e,t,n){var r=!1,o=Yn,s=t.contextType;return typeof s=="object"&&s!==null?s=mt(s):(o=qe(t)?vr:Me.current,r=t.contextTypes,s=(r=r!=null)?po(e,o):Yn),t=new t(n,s),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=ga,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=o,e.__reactInternalMemoizedMaskedChildContext=s),t}function cf(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&ga.enqueueReplaceState(t,t.state,null)}function hu(e,t,n,r){var o=e.stateNode;o.props=n,o.state=e.memoizedState,o.refs={},Cc(e);var s=t.contextType;typeof s=="object"&&s!==null?o.context=mt(s):(s=qe(t)?vr:Me.current,o.context=po(e,s)),o.state=e.memoizedState,s=t.getDerivedStateFromProps,typeof s=="function"&&(pu(e,t,s,n),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&&ga.enqueueReplaceState(o,o.state,null),Wi(e,n,o,r),o.state=e.memoizedState),typeof o.componentDidMount=="function"&&(e.flags|=4194308)}function vo(e,t){try{var n="",r=t;do n+=t0(r),r=r.return;while(r);var o=n}catch(s){o=`
Error generating stack: `+s.message+`
`+s.stack}return{value:e,source:t,stack:o,digest:null}}function ml(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function mu(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var Px=typeof WeakMap=="function"?WeakMap:Map;function xm(e,t,n){n=rn(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Ki||(Ki=!0,ku=r),mu(e,t)},n}function wm(e,t,n){n=rn(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var o=t.value;n.payload=function(){return r(o)},n.callback=function(){mu(e,t)}}var s=e.stateNode;return s!==null&&typeof s.componentDidCatch=="function"&&(n.callback=function(){mu(e,t),typeof r!="function"&&(Hn===null?Hn=new Set([this]):Hn.add(this));var i=t.stack;this.componentDidCatch(t.value,{componentStack:i!==null?i:""})}),n}function df(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Px;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(n)||(o.add(n),e=Ux.bind(null,e,t,n),t.then(e,e))}function ff(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 pf(e,t,n,r,o){return e.mode&1?(e.flags|=65536,e.lanes=o,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=rn(-1,1),t.tag=2,Wn(n,t,1))),n.lanes|=1),e)}var Rx=fn.ReactCurrentOwner,Ke=!1;function Fe(e,t,n,r){t.child=e===null?Yh(t,null,n,r):mo(t,e.child,n,r)}function hf(e,t,n,r,o){n=n.render;var s=t.ref;return Xr(t,o),r=Pc(e,t,n,r,s,o),n=Rc(),e!==null&&!Ke?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,ln(e,t,o)):(ue&&n&&gc(t),t.flags|=1,Fe(e,t,r,o),t.child)}function mf(e,t,n,r,o){if(e===null){var s=n.type;return typeof s=="function"&&!$c(s)&&s.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=s,bm(e,t,s,r,o)):(e=bi(n.type,null,r,t,t.mode,o),e.ref=t.ref,e.return=t,t.child=e)}if(s=e.child,!(e.lanes&o)){var i=s.memoizedProps;if(n=n.compare,n=n!==null?n:ls,n(i,r)&&e.ref===t.ref)return ln(e,t,o)}return t.flags|=1,e=Qn(s,r),e.ref=t.ref,e.return=t,t.child=e}function bm(e,t,n,r,o){if(e!==null){var s=e.memoizedProps;if(ls(s,r)&&e.ref===t.ref)if(Ke=!1,t.pendingProps=r=s,(e.lanes&o)!==0)e.flags&131072&&(Ke=!0);else return t.lanes=e.lanes,ln(e,t,o)}return gu(e,t,n,r,o)}function Sm(e,t,n){var r=t.pendingProps,o=r.children,s=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},re(Qr,tt),tt|=n;else{if(!(n&1073741824))return e=s!==null?s.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,re(Qr,tt),tt|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=s!==null?s.baseLanes:n,re(Qr,tt),tt|=r}else s!==null?(r=s.baseLanes|n,t.memoizedState=null):r=n,re(Qr,tt),tt|=r;return Fe(e,t,o,n),t.child}function Cm(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function gu(e,t,n,r,o){var s=qe(n)?vr:Me.current;return s=po(t,s),Xr(t,o),n=Pc(e,t,n,r,s,o),r=Rc(),e!==null&&!Ke?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,ln(e,t,o)):(ue&&r&&gc(t),t.flags|=1,Fe(e,t,n,o),t.child)}function gf(e,t,n,r,o){if(qe(n)){var s=!0;Fi(t)}else s=!1;if(Xr(t,o),t.stateNode===null)yi(e,t),ym(t,n,r),hu(t,n,r,o),r=!0;else if(e===null){var i=t.stateNode,a=t.memoizedProps;i.props=a;var l=i.context,u=n.contextType;typeof u=="object"&&u!==null?u=mt(u):(u=qe(n)?vr:Me.current,u=po(t,u));var d=n.getDerivedStateFromProps,p=typeof d=="function"||typeof i.getSnapshotBeforeUpdate=="function";p||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(a!==r||l!==u)&&cf(t,i,r,u),Tn=!1;var y=t.memoizedState;i.state=y,Wi(t,r,i,o),l=t.memoizedState,a!==r||y!==l||Ye.current||Tn?(typeof d=="function"&&(pu(t,n,d,r),l=t.memoizedState),(a=Tn||uf(t,n,a,r,y,l,u))?(p||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount()),typeof i.componentDidMount=="function"&&(t.flags|=4194308)):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),i.props=r,i.state=l,i.context=u,r=a):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{i=t.stateNode,Xh(e,t),a=t.memoizedProps,u=t.type===t.elementType?a:St(t.type,a),i.props=u,p=t.pendingProps,y=i.context,l=n.contextType,typeof l=="object"&&l!==null?l=mt(l):(l=qe(n)?vr:Me.current,l=po(t,l));var f=n.getDerivedStateFromProps;(d=typeof f=="function"||typeof i.getSnapshotBeforeUpdate=="function")||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(a!==p||y!==l)&&cf(t,i,r,l),Tn=!1,y=t.memoizedState,i.state=y,Wi(t,r,i,o);var b=t.memoizedState;a!==p||y!==b||Ye.current||Tn?(typeof f=="function"&&(pu(t,n,f,r),b=t.memoizedState),(u=Tn||uf(t,n,u,r,y,b,l)||!1)?(d||typeof i.UNSAFE_componentWillUpdate!="function"&&typeof i.componentWillUpdate!="function"||(typeof i.componentWillUpdate=="function"&&i.componentWillUpdate(r,b,l),typeof i.UNSAFE_componentWillUpdate=="function"&&i.UNSAFE_componentWillUpdate(r,b,l)),typeof i.componentDidUpdate=="function"&&(t.flags|=4),typeof i.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof i.componentDidUpdate!="function"||a===e.memoizedProps&&y===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&y===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=b),i.props=r,i.state=b,i.context=l,r=u):(typeof i.componentDidUpdate!="function"||a===e.memoizedProps&&y===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&y===e.memoizedState||(t.flags|=1024),r=!1)}return vu(e,t,n,r,s,o)}function vu(e,t,n,r,o,s){Cm(e,t);var i=(t.flags&128)!==0;if(!r&&!i)return o&&ef(t,n,!1),ln(e,t,s);r=t.stateNode,Rx.current=t;var a=i&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&i?(t.child=mo(t,e.child,null,s),t.child=mo(t,null,a,s)):Fe(e,t,a,s),t.memoizedState=r.state,o&&ef(t,n,!0),t.child}function Em(e){var t=e.stateNode;t.pendingContext?Jd(e,t.pendingContext,t.pendingContext!==t.context):t.context&&Jd(e,t.context,!1),Ec(e,t.containerInfo)}function vf(e,t,n,r,o){return ho(),yc(o),t.flags|=256,Fe(e,t,n,r),t.child}var yu={dehydrated:null,treeContext:null,retryLane:0};function xu(e){return{baseLanes:e,cachePool:null,transitions:null}}function km(e,t,n){var r=t.pendingProps,o=de.current,s=!1,i=(t.flags&128)!==0,a;if((a=i)||(a=e!==null&&e.memoizedState===null?!1:(o&2)!==0),a?(s=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(o|=1),re(de,o&1),e===null)return du(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(i=r.children,e=r.fallback,s?(r=t.mode,s=t.child,i={mode:"hidden",children:i},!(r&1)&&s!==null?(s.childLanes=0,s.pendingProps=i):s=xa(i,r,0,null),e=gr(e,r,n,null),s.return=t,e.return=t,s.sibling=e,t.child=s,t.child.memoizedState=xu(n),t.memoizedState=yu,e):_c(t,i));if(o=e.memoizedState,o!==null&&(a=o.dehydrated,a!==null))return jx(e,t,i,r,a,o,n);if(s){s=r.fallback,i=t.mode,o=e.child,a=o.sibling;var l={mode:"hidden",children:r.children};return!(i&1)&&t.child!==o?(r=t.child,r.childLanes=0,r.pendingProps=l,t.deletions=null):(r=Qn(o,l),r.subtreeFlags=o.subtreeFlags&14680064),a!==null?s=Qn(a,s):(s=gr(s,i,n,null),s.flags|=2),s.return=t,r.return=t,r.sibling=s,t.child=r,r=s,s=t.child,i=e.child.memoizedState,i=i===null?xu(n):{baseLanes:i.baseLanes|n,cachePool:null,transitions:i.transitions},s.memoizedState=i,s.childLanes=e.childLanes&~n,t.memoizedState=yu,r}return s=e.child,e=s.sibling,r=Qn(s,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function _c(e,t){return t=xa({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Xs(e,t,n,r){return r!==null&&yc(r),mo(t,e.child,null,n),e=_c(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function jx(e,t,n,r,o,s,i){if(n)return t.flags&256?(t.flags&=-257,r=ml(Error(_(422))),Xs(e,t,i,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(s=r.fallback,o=t.mode,r=xa({mode:"visible",children:r.children},o,0,null),s=gr(s,o,i,null),s.flags|=2,r.return=t,s.return=t,r.sibling=s,t.child=r,t.mode&1&&mo(t,e.child,null,i),t.child.memoizedState=xu(i),t.memoizedState=yu,s);if(!(t.mode&1))return Xs(e,t,i,null);if(o.data==="$!"){if(r=o.nextSibling&&o.nextSibling.dataset,r)var a=r.dgst;return r=a,s=Error(_(419)),r=ml(s,r,void 0),Xs(e,t,i,r)}if(a=(i&e.childLanes)!==0,Ke||a){if(r=ke,r!==null){switch(i&-i){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|i)?0:o,o!==0&&o!==s.retryLane&&(s.retryLane=o,an(e,o),Rt(r,e,o,-1))}return Fc(),r=ml(Error(_(421))),Xs(e,t,i,r)}return o.data==="$?"?(t.flags|=128,t.child=e.child,t=Wx.bind(null,e),o._reactRetry=t,null):(e=s.treeContext,rt=Un(o.nextSibling),ot=t,ue=!0,Tt=null,e!==null&&(dt[ft++]=tn,dt[ft++]=nn,dt[ft++]=yr,tn=e.id,nn=e.overflow,yr=t),t=_c(t,r.children),t.flags|=4096,t)}function yf(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),fu(e.return,t,n)}function gl(e,t,n,r,o){var s=e.memoizedState;s===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:o}:(s.isBackwards=t,s.rendering=null,s.renderingStartTime=0,s.last=r,s.tail=n,s.tailMode=o)}function Nm(e,t,n){var r=t.pendingProps,o=r.revealOrder,s=r.tail;if(Fe(e,t,r.children,n),r=de.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&yf(e,n,t);else if(e.tag===19)yf(e,n,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(re(de,r),!(t.mode&1))t.memoizedState=null;else switch(o){case"forwards":for(n=t.child,o=null;n!==null;)e=n.alternate,e!==null&&Hi(e)===null&&(o=n),n=n.sibling;n=o,n===null?(o=t.child,t.child=null):(o=n.sibling,n.sibling=null),gl(t,!1,o,n,s);break;case"backwards":for(n=null,o=t.child,t.child=null;o!==null;){if(e=o.alternate,e!==null&&Hi(e)===null){t.child=o;break}e=o.sibling,o.sibling=n,n=o,o=e}gl(t,!0,n,null,s);break;case"together":gl(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function yi(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function ln(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),wr|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(_(153));if(t.child!==null){for(e=t.child,n=Qn(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=Qn(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Ox(e,t,n){switch(t.tag){case 3:Em(t),ho();break;case 5:Zh(t);break;case 1:qe(t.type)&&Fi(t);break;case 4:Ec(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,o=t.memoizedProps.value;re(Bi,r._currentValue),r._currentValue=o;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(re(de,de.current&1),t.flags|=128,null):n&t.child.childLanes?km(e,t,n):(re(de,de.current&1),e=ln(e,t,n),e!==null?e.sibling:null);re(de,de.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return Nm(e,t,n);t.flags|=128}if(o=t.memoizedState,o!==null&&(o.rendering=null,o.tail=null,o.lastEffect=null),re(de,de.current),r)break;return null;case 22:case 23:return t.lanes=0,Sm(e,t,n)}return ln(e,t,n)}var Tm,wu,Pm,Rm;Tm=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};wu=function(){};Pm=function(e,t,n,r){var o=e.memoizedProps;if(o!==r){e=t.stateNode,lr(Ht.current);var s=null;switch(n){case"input":o=Ul(e,o),r=Ul(e,r),s=[];break;case"select":o=pe({},o,{value:void 0}),r=pe({},r,{value:void 0}),s=[];break;case"textarea":o=Vl(e,o),r=Vl(e,r),s=[];break;default:typeof o.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=Li)}Gl(n,r);var i;n=null;for(u in o)if(!r.hasOwnProperty(u)&&o.hasOwnProperty(u)&&o[u]!=null)if(u==="style"){var a=o[u];for(i in a)a.hasOwnProperty(i)&&(n||(n={}),n[i]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(ts.hasOwnProperty(u)?s||(s=[]):(s=s||[]).push(u,null));for(u in r){var l=r[u];if(a=o!=null?o[u]:void 0,r.hasOwnProperty(u)&&l!==a&&(l!=null||a!=null))if(u==="style")if(a){for(i in a)!a.hasOwnProperty(i)||l&&l.hasOwnProperty(i)||(n||(n={}),n[i]="");for(i in l)l.hasOwnProperty(i)&&a[i]!==l[i]&&(n||(n={}),n[i]=l[i])}else n||(s||(s=[]),s.push(u,n)),n=l;else u==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,a=a?a.__html:void 0,l!=null&&a!==l&&(s=s||[]).push(u,l)):u==="children"?typeof l!="string"&&typeof l!="number"||(s=s||[]).push(u,""+l):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(ts.hasOwnProperty(u)?(l!=null&&u==="onScroll"&&se("scroll",e),s||a===l||(s=[])):(s=s||[]).push(u,l))}n&&(s=s||[]).push("style",n);var u=s;(t.updateQueue=u)&&(t.flags|=4)}};Rm=function(e,t,n,r){n!==r&&(t.flags|=4)};function Lo(e,t){if(!ue)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function _e(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var o=e.child;o!==null;)n|=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;)n|=o.lanes|o.childLanes,r|=o.subtreeFlags,r|=o.flags,o.return=e,o=o.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function _x(e,t,n){var r=t.pendingProps;switch(vc(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return _e(t),null;case 1:return qe(t.type)&&Ii(),_e(t),null;case 3:return r=t.stateNode,go(),ie(Ye),ie(Me),Nc(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(Ys(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Tt!==null&&(Pu(Tt),Tt=null))),wu(e,t),_e(t),null;case 5:kc(t);var o=lr(ps.current);if(n=t.type,e!==null&&t.stateNode!=null)Pm(e,t,n,r,o),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(_(166));return _e(t),null}if(e=lr(Ht.current),Ys(t)){r=t.stateNode,n=t.type;var s=t.memoizedProps;switch(r[zt]=t,r[ds]=s,e=(t.mode&1)!==0,n){case"dialog":se("cancel",r),se("close",r);break;case"iframe":case"object":case"embed":se("load",r);break;case"video":case"audio":for(o=0;o<Wo.length;o++)se(Wo[o],r);break;case"source":se("error",r);break;case"img":case"image":case"link":se("error",r),se("load",r);break;case"details":se("toggle",r);break;case"input":Nd(r,s),se("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!s.multiple},se("invalid",r);break;case"textarea":Pd(r,s),se("invalid",r)}Gl(n,s),o=null;for(var i in s)if(s.hasOwnProperty(i)){var a=s[i];i==="children"?typeof a=="string"?r.textContent!==a&&(s.suppressHydrationWarning!==!0&&Ks(r.textContent,a,e),o=["children",a]):typeof a=="number"&&r.textContent!==""+a&&(s.suppressHydrationWarning!==!0&&Ks(r.textContent,a,e),o=["children",""+a]):ts.hasOwnProperty(i)&&a!=null&&i==="onScroll"&&se("scroll",r)}switch(n){case"input":zs(r),Td(r,s,!0);break;case"textarea":zs(r),Rd(r);break;case"select":case"option":break;default:typeof s.onClick=="function"&&(r.onclick=Li)}r=o,t.updateQueue=r,r!==null&&(t.flags|=4)}else{i=o.nodeType===9?o:o.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=rh(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=i.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=i.createElement(n,{is:r.is}):(e=i.createElement(n),n==="select"&&(i=e,r.multiple?i.multiple=!0:r.size&&(i.size=r.size))):e=i.createElementNS(e,n),e[zt]=t,e[ds]=r,Tm(e,t,!1,!1),t.stateNode=e;e:{switch(i=Kl(n,r),n){case"dialog":se("cancel",e),se("close",e),o=r;break;case"iframe":case"object":case"embed":se("load",e),o=r;break;case"video":case"audio":for(o=0;o<Wo.length;o++)se(Wo[o],e);o=r;break;case"source":se("error",e),o=r;break;case"img":case"image":case"link":se("error",e),se("load",e),o=r;break;case"details":se("toggle",e),o=r;break;case"input":Nd(e,r),o=Ul(e,r),se("invalid",e);break;case"option":o=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},o=pe({},r,{value:void 0}),se("invalid",e);break;case"textarea":Pd(e,r),o=Vl(e,r),se("invalid",e);break;default:o=r}Gl(n,o),a=o;for(s in a)if(a.hasOwnProperty(s)){var l=a[s];s==="style"?ih(e,l):s==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&oh(e,l)):s==="children"?typeof l=="string"?(n!=="textarea"||l!=="")&&ns(e,l):typeof l=="number"&&ns(e,""+l):s!=="suppressContentEditableWarning"&&s!=="suppressHydrationWarning"&&s!=="autoFocus"&&(ts.hasOwnProperty(s)?l!=null&&s==="onScroll"&&se("scroll",e):l!=null&&nc(e,s,l,i))}switch(n){case"input":zs(e),Td(e,r,!1);break;case"textarea":zs(e),Rd(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Kn(r.value));break;case"select":e.multiple=!!r.multiple,s=r.value,s!=null?Gr(e,!!r.multiple,s,!1):r.defaultValue!=null&&Gr(e,!!r.multiple,r.defaultValue,!0);break;default:typeof o.onClick=="function"&&(e.onclick=Li)}switch(n){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 _e(t),null;case 6:if(e&&t.stateNode!=null)Rm(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(_(166));if(n=lr(ps.current),lr(Ht.current),Ys(t)){if(r=t.stateNode,n=t.memoizedProps,r[zt]=t,(s=r.nodeValue!==n)&&(e=ot,e!==null))switch(e.tag){case 3:Ks(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Ks(r.nodeValue,n,(e.mode&1)!==0)}s&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[zt]=t,t.stateNode=r}return _e(t),null;case 13:if(ie(de),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(ue&&rt!==null&&t.mode&1&&!(t.flags&128))Gh(),ho(),t.flags|=98560,s=!1;else if(s=Ys(t),r!==null&&r.dehydrated!==null){if(e===null){if(!s)throw Error(_(318));if(s=t.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(_(317));s[zt]=t}else ho(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;_e(t),s=!1}else Tt!==null&&(Pu(Tt),Tt=null),s=!0;if(!s)return t.flags&65536?t:null}return t.flags&128?(t.lanes=n,t):(r=r!==null,r!==(e!==null&&e.memoizedState!==null)&&r&&(t.child.flags|=8192,t.mode&1&&(e===null||de.current&1?Se===0&&(Se=3):Fc())),t.updateQueue!==null&&(t.flags|=4),_e(t),null);case 4:return go(),wu(e,t),e===null&&us(t.stateNode.containerInfo),_e(t),null;case 10:return bc(t.type._context),_e(t),null;case 17:return qe(t.type)&&Ii(),_e(t),null;case 19:if(ie(de),s=t.memoizedState,s===null)return _e(t),null;if(r=(t.flags&128)!==0,i=s.rendering,i===null)if(r)Lo(s,!1);else{if(Se!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(i=Hi(e),i!==null){for(t.flags|=128,Lo(s,!1),r=i.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=n,n=t.child;n!==null;)s=n,e=r,s.flags&=14680066,i=s.alternate,i===null?(s.childLanes=0,s.lanes=e,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=i.childLanes,s.lanes=i.lanes,s.child=i.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=i.memoizedProps,s.memoizedState=i.memoizedState,s.updateQueue=i.updateQueue,s.type=i.type,e=i.dependencies,s.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return re(de,de.current&1|2),t.child}e=e.sibling}s.tail!==null&&ve()>yo&&(t.flags|=128,r=!0,Lo(s,!1),t.lanes=4194304)}else{if(!r)if(e=Hi(i),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Lo(s,!0),s.tail===null&&s.tailMode==="hidden"&&!i.alternate&&!ue)return _e(t),null}else 2*ve()-s.renderingStartTime>yo&&n!==1073741824&&(t.flags|=128,r=!0,Lo(s,!1),t.lanes=4194304);s.isBackwards?(i.sibling=t.child,t.child=i):(n=s.last,n!==null?n.sibling=i:t.child=i,s.last=i)}return s.tail!==null?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=ve(),t.sibling=null,n=de.current,re(de,r?n&1|2:n&1),t):(_e(t),null);case 22:case 23:return Ic(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?tt&1073741824&&(_e(t),t.subtreeFlags&6&&(t.flags|=8192)):_e(t),null;case 24:return null;case 25:return null}throw Error(_(156,t.tag))}function Ax(e,t){switch(vc(t),t.tag){case 1:return qe(t.type)&&Ii(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return go(),ie(Ye),ie(Me),Nc(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return kc(t),null;case 13:if(ie(de),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(_(340));ho()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return ie(de),null;case 4:return go(),null;case 10:return bc(t.type._context),null;case 22:case 23:return Ic(),null;case 24:return null;default:return null}}var Zs=!1,De=!1,Dx=typeof WeakSet=="function"?WeakSet:Set,B=null;function Vr(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){ge(e,t,r)}else n.current=null}function bu(e,t,n){try{n()}catch(r){ge(e,t,r)}}var xf=!1;function Mx(e,t){if(ou=Ai,e=Dh(),mc(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var o=r.anchorOffset,s=r.focusNode;r=r.focusOffset;try{n.nodeType,s.nodeType}catch{n=null;break e}var i=0,a=-1,l=-1,u=0,d=0,p=e,y=null;t:for(;;){for(var f;p!==n||o!==0&&p.nodeType!==3||(a=i+o),p!==s||r!==0&&p.nodeType!==3||(l=i+r),p.nodeType===3&&(i+=p.nodeValue.length),(f=p.firstChild)!==null;)y=p,p=f;for(;;){if(p===e)break t;if(y===n&&++u===o&&(a=i),y===s&&++d===r&&(l=i),(f=p.nextSibling)!==null)break;p=y,y=p.parentNode}p=f}n=a===-1||l===-1?null:{start:a,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(su={focusedElem:e,selectionRange:n},Ai=!1,B=t;B!==null;)if(t=B,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,B=e;else for(;B!==null;){t=B;try{var b=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(b!==null){var g=b.memoizedProps,x=b.memoizedState,h=t.stateNode,m=h.getSnapshotBeforeUpdate(t.elementType===t.type?g:St(t.type,g),x);h.__reactInternalSnapshotBeforeUpdate=m}break;case 3:var w=t.stateNode.containerInfo;w.nodeType===1?w.textContent="":w.nodeType===9&&w.documentElement&&w.removeChild(w.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(_(163))}}catch(S){ge(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,B=e;break}B=t.return}return b=xf,xf=!1,b}function Xo(e,t,n){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 s=o.destroy;o.destroy=void 0,s!==void 0&&bu(t,n,s)}o=o.next}while(o!==r)}}function va(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function Su(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function jm(e){var t=e.alternate;t!==null&&(e.alternate=null,jm(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[zt],delete t[ds],delete t[lu],delete t[vx],delete t[yx])),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 Om(e){return e.tag===5||e.tag===3||e.tag===4}function wf(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Om(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.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 Cu(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Li));else if(r!==4&&(e=e.child,e!==null))for(Cu(e,t,n),e=e.sibling;e!==null;)Cu(e,t,n),e=e.sibling}function Eu(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(Eu(e,t,n),e=e.sibling;e!==null;)Eu(e,t,n),e=e.sibling}var Te=null,Nt=!1;function xn(e,t,n){for(n=n.child;n!==null;)_m(e,t,n),n=n.sibling}function _m(e,t,n){if(Wt&&typeof Wt.onCommitFiberUnmount=="function")try{Wt.onCommitFiberUnmount(ua,n)}catch{}switch(n.tag){case 5:De||Vr(n,t);case 6:var r=Te,o=Nt;Te=null,xn(e,t,n),Te=r,Nt=o,Te!==null&&(Nt?(e=Te,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Te.removeChild(n.stateNode));break;case 18:Te!==null&&(Nt?(e=Te,n=n.stateNode,e.nodeType===8?ul(e.parentNode,n):e.nodeType===1&&ul(e,n),is(e)):ul(Te,n.stateNode));break;case 4:r=Te,o=Nt,Te=n.stateNode.containerInfo,Nt=!0,xn(e,t,n),Te=r,Nt=o;break;case 0:case 11:case 14:case 15:if(!De&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){o=r=r.next;do{var s=o,i=s.destroy;s=s.tag,i!==void 0&&(s&2||s&4)&&bu(n,t,i),o=o.next}while(o!==r)}xn(e,t,n);break;case 1:if(!De&&(Vr(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){ge(n,t,a)}xn(e,t,n);break;case 21:xn(e,t,n);break;case 22:n.mode&1?(De=(r=De)||n.memoizedState!==null,xn(e,t,n),De=r):xn(e,t,n);break;default:xn(e,t,n)}}function bf(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new Dx),t.forEach(function(r){var o=Hx.bind(null,e,r);n.has(r)||(n.add(r),r.then(o,o))})}}function wt(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var o=n[r];try{var s=e,i=t,a=i;e:for(;a!==null;){switch(a.tag){case 5:Te=a.stateNode,Nt=!1;break e;case 3:Te=a.stateNode.containerInfo,Nt=!0;break e;case 4:Te=a.stateNode.containerInfo,Nt=!0;break e}a=a.return}if(Te===null)throw Error(_(160));_m(s,i,o),Te=null,Nt=!1;var l=o.alternate;l!==null&&(l.return=null),o.return=null}catch(u){ge(o,t,u)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Am(t,e),t=t.sibling}function Am(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(wt(t,e),Mt(e),r&4){try{Xo(3,e,e.return),va(3,e)}catch(g){ge(e,e.return,g)}try{Xo(5,e,e.return)}catch(g){ge(e,e.return,g)}}break;case 1:wt(t,e),Mt(e),r&512&&n!==null&&Vr(n,n.return);break;case 5:if(wt(t,e),Mt(e),r&512&&n!==null&&Vr(n,n.return),e.flags&32){var o=e.stateNode;try{ns(o,"")}catch(g){ge(e,e.return,g)}}if(r&4&&(o=e.stateNode,o!=null)){var s=e.memoizedProps,i=n!==null?n.memoizedProps:s,a=e.type,l=e.updateQueue;if(e.updateQueue=null,l!==null)try{a==="input"&&s.type==="radio"&&s.name!=null&&th(o,s),Kl(a,i);var u=Kl(a,s);for(i=0;i<l.length;i+=2){var d=l[i],p=l[i+1];d==="style"?ih(o,p):d==="dangerouslySetInnerHTML"?oh(o,p):d==="children"?ns(o,p):nc(o,d,p,u)}switch(a){case"input":Wl(o,s);break;case"textarea":nh(o,s);break;case"select":var y=o._wrapperState.wasMultiple;o._wrapperState.wasMultiple=!!s.multiple;var f=s.value;f!=null?Gr(o,!!s.multiple,f,!1):y!==!!s.multiple&&(s.defaultValue!=null?Gr(o,!!s.multiple,s.defaultValue,!0):Gr(o,!!s.multiple,s.multiple?[]:"",!1))}o[ds]=s}catch(g){ge(e,e.return,g)}}break;case 6:if(wt(t,e),Mt(e),r&4){if(e.stateNode===null)throw Error(_(162));o=e.stateNode,s=e.memoizedProps;try{o.nodeValue=s}catch(g){ge(e,e.return,g)}}break;case 3:if(wt(t,e),Mt(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{is(t.containerInfo)}catch(g){ge(e,e.return,g)}break;case 4:wt(t,e),Mt(e);break;case 13:wt(t,e),Mt(e),o=e.child,o.flags&8192&&(s=o.memoizedState!==null,o.stateNode.isHidden=s,!s||o.alternate!==null&&o.alternate.memoizedState!==null||(Mc=ve())),r&4&&bf(e);break;case 22:if(d=n!==null&&n.memoizedState!==null,e.mode&1?(De=(u=De)||d,wt(t,e),De=u):wt(t,e),Mt(e),r&8192){if(u=e.memoizedState!==null,(e.stateNode.isHidden=u)&&!d&&e.mode&1)for(B=e,d=e.child;d!==null;){for(p=B=d;B!==null;){switch(y=B,f=y.child,y.tag){case 0:case 11:case 14:case 15:Xo(4,y,y.return);break;case 1:Vr(y,y.return);var b=y.stateNode;if(typeof b.componentWillUnmount=="function"){r=y,n=y.return;try{t=r,b.props=t.memoizedProps,b.state=t.memoizedState,b.componentWillUnmount()}catch(g){ge(r,n,g)}}break;case 5:Vr(y,y.return);break;case 22:if(y.memoizedState!==null){Cf(p);continue}}f!==null?(f.return=y,B=f):Cf(p)}d=d.sibling}e:for(d=null,p=e;;){if(p.tag===5){if(d===null){d=p;try{o=p.stateNode,u?(s=o.style,typeof s.setProperty=="function"?s.setProperty("display","none","important"):s.display="none"):(a=p.stateNode,l=p.memoizedProps.style,i=l!=null&&l.hasOwnProperty("display")?l.display:null,a.style.display=sh("display",i))}catch(g){ge(e,e.return,g)}}}else if(p.tag===6){if(d===null)try{p.stateNode.nodeValue=u?"":p.memoizedProps}catch(g){ge(e,e.return,g)}}else if((p.tag!==22&&p.tag!==23||p.memoizedState===null||p===e)&&p.child!==null){p.child.return=p,p=p.child;continue}if(p===e)break e;for(;p.sibling===null;){if(p.return===null||p.return===e)break e;d===p&&(d=null),p=p.return}d===p&&(d=null),p.sibling.return=p.return,p=p.sibling}}break;case 19:wt(t,e),Mt(e),r&4&&bf(e);break;case 21:break;default:wt(t,e),Mt(e)}}function Mt(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(Om(n)){var r=n;break e}n=n.return}throw Error(_(160))}switch(r.tag){case 5:var o=r.stateNode;r.flags&32&&(ns(o,""),r.flags&=-33);var s=wf(e);Eu(e,s,o);break;case 3:case 4:var i=r.stateNode.containerInfo,a=wf(e);Cu(e,a,i);break;default:throw Error(_(161))}}catch(l){ge(e,e.return,l)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Lx(e,t,n){B=e,Dm(e)}function Dm(e,t,n){for(var r=(e.mode&1)!==0;B!==null;){var o=B,s=o.child;if(o.tag===22&&r){var i=o.memoizedState!==null||Zs;if(!i){var a=o.alternate,l=a!==null&&a.memoizedState!==null||De;a=Zs;var u=De;if(Zs=i,(De=l)&&!u)for(B=o;B!==null;)i=B,l=i.child,i.tag===22&&i.memoizedState!==null?Ef(o):l!==null?(l.return=i,B=l):Ef(o);for(;s!==null;)B=s,Dm(s),s=s.sibling;B=o,Zs=a,De=u}Sf(e)}else o.subtreeFlags&8772&&s!==null?(s.return=o,B=s):Sf(e)}}function Sf(e){for(;B!==null;){var t=B;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:De||va(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!De)if(n===null)r.componentDidMount();else{var o=t.elementType===t.type?n.memoizedProps:St(t.type,n.memoizedProps);r.componentDidUpdate(o,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var s=t.updateQueue;s!==null&&sf(t,s,r);break;case 3:var i=t.updateQueue;if(i!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}sf(t,i,n)}break;case 5:var a=t.stateNode;if(n===null&&t.flags&4){n=a;var l=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":l.autoFocus&&n.focus();break;case"img":l.src&&(n.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 p=d.dehydrated;p!==null&&is(p)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(_(163))}De||t.flags&512&&Su(t)}catch(y){ge(t,t.return,y)}}if(t===e){B=null;break}if(n=t.sibling,n!==null){n.return=t.return,B=n;break}B=t.return}}function Cf(e){for(;B!==null;){var t=B;if(t===e){B=null;break}var n=t.sibling;if(n!==null){n.return=t.return,B=n;break}B=t.return}}function Ef(e){for(;B!==null;){var t=B;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{va(4,t)}catch(l){ge(t,n,l)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var o=t.return;try{r.componentDidMount()}catch(l){ge(t,o,l)}}var s=t.return;try{Su(t)}catch(l){ge(t,s,l)}break;case 5:var i=t.return;try{Su(t)}catch(l){ge(t,i,l)}}}catch(l){ge(t,t.return,l)}if(t===e){B=null;break}var a=t.sibling;if(a!==null){a.return=t.return,B=a;break}B=t.return}}var Ix=Math.ceil,Gi=fn.ReactCurrentDispatcher,Ac=fn.ReactCurrentOwner,ht=fn.ReactCurrentBatchConfig,Z=0,ke=null,ye=null,Pe=0,tt=0,Qr=Jn(0),Se=0,vs=null,wr=0,ya=0,Dc=0,Zo=null,Ge=null,Mc=0,yo=1/0,Zt=null,Ki=!1,ku=null,Hn=null,Js=!1,Ln=null,Yi=0,Jo=0,Nu=null,xi=-1,wi=0;function ze(){return Z&6?ve():xi!==-1?xi:xi=ve()}function Vn(e){return e.mode&1?Z&2&&Pe!==0?Pe&-Pe:wx.transition!==null?(wi===0&&(wi=yh()),wi):(e=te,e!==0||(e=window.event,e=e===void 0?16:kh(e.type)),e):1}function Rt(e,t,n,r){if(50<Jo)throw Jo=0,Nu=null,Error(_(185));Ns(e,n,r),(!(Z&2)||e!==ke)&&(e===ke&&(!(Z&2)&&(ya|=n),Se===4&&Rn(e,Pe)),Xe(e,r),n===1&&Z===0&&!(t.mode&1)&&(yo=ve()+500,ha&&er()))}function Xe(e,t){var n=e.callbackNode;w0(e,t);var r=_i(e,e===ke?Pe:0);if(r===0)n!==null&&_d(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&_d(n),t===1)e.tag===0?xx(kf.bind(null,e)):Hh(kf.bind(null,e)),mx(function(){!(Z&6)&&er()}),n=null;else{switch(xh(r)){case 1:n=ac;break;case 4:n=gh;break;case 16:n=Oi;break;case 536870912:n=vh;break;default:n=Oi}n=Um(n,Mm.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function Mm(e,t){if(xi=-1,wi=0,Z&6)throw Error(_(327));var n=e.callbackNode;if(Zr()&&e.callbackNode!==n)return null;var r=_i(e,e===ke?Pe:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=qi(e,r);else{t=r;var o=Z;Z|=2;var s=Im();(ke!==e||Pe!==t)&&(Zt=null,yo=ve()+500,mr(e,t));do try{zx();break}catch(a){Lm(e,a)}while(!0);wc(),Gi.current=s,Z=o,ye!==null?t=0:(ke=null,Pe=0,t=Se)}if(t!==0){if(t===2&&(o=Jl(e),o!==0&&(r=o,t=Tu(e,o))),t===1)throw n=vs,mr(e,0),Rn(e,r),Xe(e,ve()),n;if(t===6)Rn(e,r);else{if(o=e.current.alternate,!(r&30)&&!Fx(o)&&(t=qi(e,r),t===2&&(s=Jl(e),s!==0&&(r=s,t=Tu(e,s))),t===1))throw n=vs,mr(e,0),Rn(e,r),Xe(e,ve()),n;switch(e.finishedWork=o,e.finishedLanes=r,t){case 0:case 1:throw Error(_(345));case 2:or(e,Ge,Zt);break;case 3:if(Rn(e,r),(r&130023424)===r&&(t=Mc+500-ve(),10<t)){if(_i(e,0)!==0)break;if(o=e.suspendedLanes,(o&r)!==r){ze(),e.pingedLanes|=e.suspendedLanes&o;break}e.timeoutHandle=au(or.bind(null,e,Ge,Zt),t);break}or(e,Ge,Zt);break;case 4:if(Rn(e,r),(r&4194240)===r)break;for(t=e.eventTimes,o=-1;0<r;){var i=31-Pt(r);s=1<<i,i=t[i],i>o&&(o=i),r&=~s}if(r=o,r=ve()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*Ix(r/1960))-r,10<r){e.timeoutHandle=au(or.bind(null,e,Ge,Zt),r);break}or(e,Ge,Zt);break;case 5:or(e,Ge,Zt);break;default:throw Error(_(329))}}}return Xe(e,ve()),e.callbackNode===n?Mm.bind(null,e):null}function Tu(e,t){var n=Zo;return e.current.memoizedState.isDehydrated&&(mr(e,t).flags|=256),e=qi(e,t),e!==2&&(t=Ge,Ge=n,t!==null&&Pu(t)),e}function Pu(e){Ge===null?Ge=e:Ge.push.apply(Ge,e)}function Fx(e){for(var t=e;;){if(t.flags&16384){var n=t.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var r=0;r<n.length;r++){var o=n[r],s=o.getSnapshot;o=o.value;try{if(!jt(s(),o))return!1}catch{return!1}}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;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 Rn(e,t){for(t&=~Dc,t&=~ya,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-Pt(t),r=1<<n;e[n]=-1,t&=~r}}function kf(e){if(Z&6)throw Error(_(327));Zr();var t=_i(e,0);if(!(t&1))return Xe(e,ve()),null;var n=qi(e,t);if(e.tag!==0&&n===2){var r=Jl(e);r!==0&&(t=r,n=Tu(e,r))}if(n===1)throw n=vs,mr(e,0),Rn(e,t),Xe(e,ve()),n;if(n===6)throw Error(_(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,or(e,Ge,Zt),Xe(e,ve()),null}function Lc(e,t){var n=Z;Z|=1;try{return e(t)}finally{Z=n,Z===0&&(yo=ve()+500,ha&&er())}}function br(e){Ln!==null&&Ln.tag===0&&!(Z&6)&&Zr();var t=Z;Z|=1;var n=ht.transition,r=te;try{if(ht.transition=null,te=1,e)return e()}finally{te=r,ht.transition=n,Z=t,!(Z&6)&&er()}}function Ic(){tt=Qr.current,ie(Qr)}function mr(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,hx(n)),ye!==null)for(n=ye.return;n!==null;){var r=n;switch(vc(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&Ii();break;case 3:go(),ie(Ye),ie(Me),Nc();break;case 5:kc(r);break;case 4:go();break;case 13:ie(de);break;case 19:ie(de);break;case 10:bc(r.type._context);break;case 22:case 23:Ic()}n=n.return}if(ke=e,ye=e=Qn(e.current,null),Pe=tt=t,Se=0,vs=null,Dc=ya=wr=0,Ge=Zo=null,ar!==null){for(t=0;t<ar.length;t++)if(n=ar[t],r=n.interleaved,r!==null){n.interleaved=null;var o=r.next,s=n.pending;if(s!==null){var i=s.next;s.next=o,r.next=i}n.pending=r}ar=null}return e}function Lm(e,t){do{var n=ye;try{if(wc(),gi.current=Qi,Vi){for(var r=fe.memoizedState;r!==null;){var o=r.queue;o!==null&&(o.pending=null),r=r.next}Vi=!1}if(xr=0,Ee=be=fe=null,qo=!1,hs=0,Ac.current=null,n===null||n.return===null){Se=1,vs=t,ye=null;break}e:{var s=e,i=n.return,a=n,l=t;if(t=Pe,a.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){var u=l,d=a,p=d.tag;if(!(d.mode&1)&&(p===0||p===11||p===15)){var y=d.alternate;y?(d.updateQueue=y.updateQueue,d.memoizedState=y.memoizedState,d.lanes=y.lanes):(d.updateQueue=null,d.memoizedState=null)}var f=ff(i);if(f!==null){f.flags&=-257,pf(f,i,a,s,t),f.mode&1&&df(s,u,t),t=f,l=u;var b=t.updateQueue;if(b===null){var g=new Set;g.add(l),t.updateQueue=g}else b.add(l);break e}else{if(!(t&1)){df(s,u,t),Fc();break e}l=Error(_(426))}}else if(ue&&a.mode&1){var x=ff(i);if(x!==null){!(x.flags&65536)&&(x.flags|=256),pf(x,i,a,s,t),yc(vo(l,a));break e}}s=l=vo(l,a),Se!==4&&(Se=2),Zo===null?Zo=[s]:Zo.push(s),s=i;do{switch(s.tag){case 3:s.flags|=65536,t&=-t,s.lanes|=t;var h=xm(s,l,t);of(s,h);break e;case 1:a=l;var m=s.type,w=s.stateNode;if(!(s.flags&128)&&(typeof m.getDerivedStateFromError=="function"||w!==null&&typeof w.componentDidCatch=="function"&&(Hn===null||!Hn.has(w)))){s.flags|=65536,t&=-t,s.lanes|=t;var S=wm(s,a,t);of(s,S);break e}}s=s.return}while(s!==null)}$m(n)}catch(C){t=C,ye===n&&n!==null&&(ye=n=n.return);continue}break}while(!0)}function Im(){var e=Gi.current;return Gi.current=Qi,e===null?Qi:e}function Fc(){(Se===0||Se===3||Se===2)&&(Se=4),ke===null||!(wr&268435455)&&!(ya&268435455)||Rn(ke,Pe)}function qi(e,t){var n=Z;Z|=2;var r=Im();(ke!==e||Pe!==t)&&(Zt=null,mr(e,t));do try{$x();break}catch(o){Lm(e,o)}while(!0);if(wc(),Z=n,Gi.current=r,ye!==null)throw Error(_(261));return ke=null,Pe=0,Se}function $x(){for(;ye!==null;)Fm(ye)}function zx(){for(;ye!==null&&!d0();)Fm(ye)}function Fm(e){var t=Bm(e.alternate,e,tt);e.memoizedProps=e.pendingProps,t===null?$m(e):ye=t,Ac.current=null}function $m(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=Ax(n,t),n!==null){n.flags&=32767,ye=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{Se=6,ye=null;return}}else if(n=_x(n,t,tt),n!==null){ye=n;return}if(t=t.sibling,t!==null){ye=t;return}ye=t=e}while(t!==null);Se===0&&(Se=5)}function or(e,t,n){var r=te,o=ht.transition;try{ht.transition=null,te=1,Bx(e,t,n,r)}finally{ht.transition=o,te=r}return null}function Bx(e,t,n,r){do Zr();while(Ln!==null);if(Z&6)throw Error(_(327));n=e.finishedWork;var o=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(_(177));e.callbackNode=null,e.callbackPriority=0;var s=n.lanes|n.childLanes;if(b0(e,s),e===ke&&(ye=ke=null,Pe=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Js||(Js=!0,Um(Oi,function(){return Zr(),null})),s=(n.flags&15990)!==0,n.subtreeFlags&15990||s){s=ht.transition,ht.transition=null;var i=te;te=1;var a=Z;Z|=4,Ac.current=null,Mx(e,n),Am(n,e),ax(su),Ai=!!ou,su=ou=null,e.current=n,Lx(n),f0(),Z=a,te=i,ht.transition=s}else e.current=n;if(Js&&(Js=!1,Ln=e,Yi=o),s=e.pendingLanes,s===0&&(Hn=null),m0(n.stateNode),Xe(e,ve()),t!==null)for(r=e.onRecoverableError,n=0;n<t.length;n++)o=t[n],r(o.value,{componentStack:o.stack,digest:o.digest});if(Ki)throw Ki=!1,e=ku,ku=null,e;return Yi&1&&e.tag!==0&&Zr(),s=e.pendingLanes,s&1?e===Nu?Jo++:(Jo=0,Nu=e):Jo=0,er(),null}function Zr(){if(Ln!==null){var e=xh(Yi),t=ht.transition,n=te;try{if(ht.transition=null,te=16>e?16:e,Ln===null)var r=!1;else{if(e=Ln,Ln=null,Yi=0,Z&6)throw Error(_(331));var o=Z;for(Z|=4,B=e.current;B!==null;){var s=B,i=s.child;if(B.flags&16){var a=s.deletions;if(a!==null){for(var l=0;l<a.length;l++){var u=a[l];for(B=u;B!==null;){var d=B;switch(d.tag){case 0:case 11:case 15:Xo(8,d,s)}var p=d.child;if(p!==null)p.return=d,B=p;else for(;B!==null;){d=B;var y=d.sibling,f=d.return;if(jm(d),d===u){B=null;break}if(y!==null){y.return=f,B=y;break}B=f}}}var b=s.alternate;if(b!==null){var g=b.child;if(g!==null){b.child=null;do{var x=g.sibling;g.sibling=null,g=x}while(g!==null)}}B=s}}if(s.subtreeFlags&2064&&i!==null)i.return=s,B=i;else e:for(;B!==null;){if(s=B,s.flags&2048)switch(s.tag){case 0:case 11:case 15:Xo(9,s,s.return)}var h=s.sibling;if(h!==null){h.return=s.return,B=h;break e}B=s.return}}var m=e.current;for(B=m;B!==null;){i=B;var w=i.child;if(i.subtreeFlags&2064&&w!==null)w.return=i,B=w;else e:for(i=m;B!==null;){if(a=B,a.flags&2048)try{switch(a.tag){case 0:case 11:case 15:va(9,a)}}catch(C){ge(a,a.return,C)}if(a===i){B=null;break e}var S=a.sibling;if(S!==null){S.return=a.return,B=S;break e}B=a.return}}if(Z=o,er(),Wt&&typeof Wt.onPostCommitFiberRoot=="function")try{Wt.onPostCommitFiberRoot(ua,e)}catch{}r=!0}return r}finally{te=n,ht.transition=t}}return!1}function Nf(e,t,n){t=vo(n,t),t=xm(e,t,1),e=Wn(e,t,1),t=ze(),e!==null&&(Ns(e,1,t),Xe(e,t))}function ge(e,t,n){if(e.tag===3)Nf(e,e,n);else for(;t!==null;){if(t.tag===3){Nf(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(Hn===null||!Hn.has(r))){e=vo(n,e),e=wm(t,e,1),t=Wn(t,e,1),e=ze(),t!==null&&(Ns(t,1,e),Xe(t,e));break}}t=t.return}}function Ux(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=ze(),e.pingedLanes|=e.suspendedLanes&n,ke===e&&(Pe&n)===n&&(Se===4||Se===3&&(Pe&130023424)===Pe&&500>ve()-Mc?mr(e,0):Dc|=n),Xe(e,t)}function zm(e,t){t===0&&(e.mode&1?(t=Ws,Ws<<=1,!(Ws&130023424)&&(Ws=4194304)):t=1);var n=ze();e=an(e,t),e!==null&&(Ns(e,t,n),Xe(e,n))}function Wx(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),zm(e,n)}function Hx(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,o=e.memoizedState;o!==null&&(n=o.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(_(314))}r!==null&&r.delete(t),zm(e,n)}var Bm;Bm=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Ye.current)Ke=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Ke=!1,Ox(e,t,n);Ke=!!(e.flags&131072)}else Ke=!1,ue&&t.flags&1048576&&Vh(t,zi,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;yi(e,t),e=t.pendingProps;var o=po(t,Me.current);Xr(t,n),o=Pc(null,t,r,e,o,n);var s=Rc();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,qe(r)?(s=!0,Fi(t)):s=!1,t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,Cc(t),o.updater=ga,t.stateNode=o,o._reactInternals=t,hu(t,r,e,n),t=vu(null,t,r,!0,s,n)):(t.tag=0,ue&&s&&gc(t),Fe(null,t,o,n),t=t.child),t;case 16:r=t.elementType;e:{switch(yi(e,t),e=t.pendingProps,o=r._init,r=o(r._payload),t.type=r,o=t.tag=Qx(r),e=St(r,e),o){case 0:t=gu(null,t,r,e,n);break e;case 1:t=gf(null,t,r,e,n);break e;case 11:t=hf(null,t,r,e,n);break e;case 14:t=mf(null,t,r,St(r.type,e),n);break e}throw Error(_(306,r,""))}return t;case 0:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:St(r,o),gu(e,t,r,o,n);case 1:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:St(r,o),gf(e,t,r,o,n);case 3:e:{if(Em(t),e===null)throw Error(_(387));r=t.pendingProps,s=t.memoizedState,o=s.element,Xh(e,t),Wi(t,r,null,n);var i=t.memoizedState;if(r=i.element,s.isDehydrated)if(s={element:r,isDehydrated:!1,cache:i.cache,pendingSuspenseBoundaries:i.pendingSuspenseBoundaries,transitions:i.transitions},t.updateQueue.baseState=s,t.memoizedState=s,t.flags&256){o=vo(Error(_(423)),t),t=vf(e,t,r,n,o);break e}else if(r!==o){o=vo(Error(_(424)),t),t=vf(e,t,r,n,o);break e}else for(rt=Un(t.stateNode.containerInfo.firstChild),ot=t,ue=!0,Tt=null,n=Yh(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(ho(),r===o){t=ln(e,t,n);break e}Fe(e,t,r,n)}t=t.child}return t;case 5:return Zh(t),e===null&&du(t),r=t.type,o=t.pendingProps,s=e!==null?e.memoizedProps:null,i=o.children,iu(r,o)?i=null:s!==null&&iu(r,s)&&(t.flags|=32),Cm(e,t),Fe(e,t,i,n),t.child;case 6:return e===null&&du(t),null;case 13:return km(e,t,n);case 4:return Ec(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=mo(t,null,r,n):Fe(e,t,r,n),t.child;case 11:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:St(r,o),hf(e,t,r,o,n);case 7:return Fe(e,t,t.pendingProps,n),t.child;case 8:return Fe(e,t,t.pendingProps.children,n),t.child;case 12:return Fe(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,o=t.pendingProps,s=t.memoizedProps,i=o.value,re(Bi,r._currentValue),r._currentValue=i,s!==null)if(jt(s.value,i)){if(s.children===o.children&&!Ye.current){t=ln(e,t,n);break e}}else for(s=t.child,s!==null&&(s.return=t);s!==null;){var a=s.dependencies;if(a!==null){i=s.child;for(var l=a.firstContext;l!==null;){if(l.context===r){if(s.tag===1){l=rn(-1,n&-n),l.tag=2;var u=s.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}}s.lanes|=n,l=s.alternate,l!==null&&(l.lanes|=n),fu(s.return,n,t),a.lanes|=n;break}l=l.next}}else if(s.tag===10)i=s.type===t.type?null:s.child;else if(s.tag===18){if(i=s.return,i===null)throw Error(_(341));i.lanes|=n,a=i.alternate,a!==null&&(a.lanes|=n),fu(i,n,t),i=s.sibling}else i=s.child;if(i!==null)i.return=s;else for(i=s;i!==null;){if(i===t){i=null;break}if(s=i.sibling,s!==null){s.return=i.return,i=s;break}i=i.return}s=i}Fe(e,t,o.children,n),t=t.child}return t;case 9:return o=t.type,r=t.pendingProps.children,Xr(t,n),o=mt(o),r=r(o),t.flags|=1,Fe(e,t,r,n),t.child;case 14:return r=t.type,o=St(r,t.pendingProps),o=St(r.type,o),mf(e,t,r,o,n);case 15:return bm(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:St(r,o),yi(e,t),t.tag=1,qe(r)?(e=!0,Fi(t)):e=!1,Xr(t,n),ym(t,r,o),hu(t,r,o,n),vu(null,t,r,!0,e,n);case 19:return Nm(e,t,n);case 22:return Sm(e,t,n)}throw Error(_(156,t.tag))};function Um(e,t){return mh(e,t)}function Vx(e,t,n,r){this.tag=e,this.key=n,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 pt(e,t,n,r){return new Vx(e,t,n,r)}function $c(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Qx(e){if(typeof e=="function")return $c(e)?1:0;if(e!=null){if(e=e.$$typeof,e===oc)return 11;if(e===sc)return 14}return 2}function Qn(e,t){var n=e.alternate;return n===null?(n=pt(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function bi(e,t,n,r,o,s){var i=2;if(r=e,typeof e=="function")$c(e)&&(i=1);else if(typeof e=="string")i=5;else e:switch(e){case Lr:return gr(n.children,o,s,t);case rc:i=8,o|=8;break;case Fl:return e=pt(12,n,t,o|2),e.elementType=Fl,e.lanes=s,e;case $l:return e=pt(13,n,t,o),e.elementType=$l,e.lanes=s,e;case zl:return e=pt(19,n,t,o),e.elementType=zl,e.lanes=s,e;case Zp:return xa(n,o,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case qp:i=10;break e;case Xp:i=9;break e;case oc:i=11;break e;case sc:i=14;break e;case Nn:i=16,r=null;break e}throw Error(_(130,e==null?e:typeof e,""))}return t=pt(i,n,t,o),t.elementType=e,t.type=r,t.lanes=s,t}function gr(e,t,n,r){return e=pt(7,e,r,t),e.lanes=n,e}function xa(e,t,n,r){return e=pt(22,e,r,t),e.elementType=Zp,e.lanes=n,e.stateNode={isHidden:!1},e}function vl(e,t,n){return e=pt(6,e,null,t),e.lanes=n,e}function yl(e,t,n){return t=pt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Gx(e,t,n,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=Za(0),this.expirationTimes=Za(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Za(0),this.identifierPrefix=r,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function zc(e,t,n,r,o,s,i,a,l){return e=new Gx(e,t,n,a,l),t===1?(t=1,s===!0&&(t|=8)):t=0,s=pt(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Cc(s),e}function Kx(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Mr,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function Wm(e){if(!e)return Yn;e=e._reactInternals;e:{if(kr(e)!==e||e.tag!==1)throw Error(_(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(qe(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(_(171))}if(e.tag===1){var n=e.type;if(qe(n))return Wh(e,n,t)}return t}function Hm(e,t,n,r,o,s,i,a,l){return e=zc(n,r,!0,e,o,s,i,a,l),e.context=Wm(null),n=e.current,r=ze(),o=Vn(n),s=rn(r,o),s.callback=t??null,Wn(n,s,o),e.current.lanes=o,Ns(e,o,r),Xe(e,r),e}function wa(e,t,n,r){var o=t.current,s=ze(),i=Vn(o);return n=Wm(n),t.context===null?t.context=n:t.pendingContext=n,t=rn(s,i),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=Wn(o,t,i),e!==null&&(Rt(e,o,i,s),mi(e,o,i)),i}function Xi(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 Tf(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function Bc(e,t){Tf(e,t),(e=e.alternate)&&Tf(e,t)}function Yx(){return null}var Vm=typeof reportError=="function"?reportError:function(e){console.error(e)};function Uc(e){this._internalRoot=e}ba.prototype.render=Uc.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(_(409));wa(e,t,null,null)};ba.prototype.unmount=Uc.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;br(function(){wa(null,e,null,null)}),t[sn]=null}};function ba(e){this._internalRoot=e}ba.prototype.unstable_scheduleHydration=function(e){if(e){var t=Sh();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Pn.length&&t!==0&&t<Pn[n].priority;n++);Pn.splice(n,0,e),n===0&&Eh(e)}};function Wc(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Sa(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function Pf(){}function qx(e,t,n,r,o){if(o){if(typeof r=="function"){var s=r;r=function(){var u=Xi(i);s.call(u)}}var i=Hm(t,r,e,0,null,!1,!1,"",Pf);return e._reactRootContainer=i,e[sn]=i.current,us(e.nodeType===8?e.parentNode:e),br(),i}for(;o=e.lastChild;)e.removeChild(o);if(typeof r=="function"){var a=r;r=function(){var u=Xi(l);a.call(u)}}var l=zc(e,0,!1,null,null,!1,!1,"",Pf);return e._reactRootContainer=l,e[sn]=l.current,us(e.nodeType===8?e.parentNode:e),br(function(){wa(t,l,n,r)}),l}function Ca(e,t,n,r,o){var s=n._reactRootContainer;if(s){var i=s;if(typeof o=="function"){var a=o;o=function(){var l=Xi(i);a.call(l)}}wa(t,i,e,o)}else i=qx(n,t,e,o,r);return Xi(i)}wh=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=Uo(t.pendingLanes);n!==0&&(lc(t,n|1),Xe(t,ve()),!(Z&6)&&(yo=ve()+500,er()))}break;case 13:br(function(){var r=an(e,1);if(r!==null){var o=ze();Rt(r,e,1,o)}}),Bc(e,1)}};uc=function(e){if(e.tag===13){var t=an(e,134217728);if(t!==null){var n=ze();Rt(t,e,134217728,n)}Bc(e,134217728)}};bh=function(e){if(e.tag===13){var t=Vn(e),n=an(e,t);if(n!==null){var r=ze();Rt(n,e,t,r)}Bc(e,t)}};Sh=function(){return te};Ch=function(e,t){var n=te;try{return te=e,t()}finally{te=n}};ql=function(e,t,n){switch(t){case"input":if(Wl(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var o=pa(r);if(!o)throw Error(_(90));eh(r),Wl(r,o)}}}break;case"textarea":nh(e,n);break;case"select":t=n.value,t!=null&&Gr(e,!!n.multiple,t,!1)}};uh=Lc;ch=br;var Xx={usingClientEntryPoint:!1,Events:[Ps,zr,pa,ah,lh,Lc]},Io={findFiberByHostInstance:ir,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},Zx={bundleType:Io.bundleType,version:Io.version,rendererPackageName:Io.rendererPackageName,rendererConfig:Io.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:fn.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=ph(e),e===null?null:e.stateNode},findFiberByHostInstance:Io.findFiberByHostInstance||Yx,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var ei=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!ei.isDisabled&&ei.supportsFiber)try{ua=ei.inject(Zx),Wt=ei}catch{}}at.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Xx;at.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Wc(t))throw Error(_(200));return Kx(e,t,null,n)};at.createRoot=function(e,t){if(!Wc(e))throw Error(_(299));var n=!1,r="",o=Vm;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(o=t.onRecoverableError)),t=zc(e,1,!1,null,null,n,!1,r,o),e[sn]=t.current,us(e.nodeType===8?e.parentNode:e),new Uc(t)};at.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(_(188)):(e=Object.keys(e).join(","),Error(_(268,e)));return e=ph(t),e=e===null?null:e.stateNode,e};at.flushSync=function(e){return br(e)};at.hydrate=function(e,t,n){if(!Sa(t))throw Error(_(200));return Ca(null,e,t,!0,n)};at.hydrateRoot=function(e,t,n){if(!Wc(e))throw Error(_(405));var r=n!=null&&n.hydratedSources||null,o=!1,s="",i=Vm;if(n!=null&&(n.unstable_strictMode===!0&&(o=!0),n.identifierPrefix!==void 0&&(s=n.identifierPrefix),n.onRecoverableError!==void 0&&(i=n.onRecoverableError)),t=Hm(t,null,e,1,n??null,o,!1,s,i),e[sn]=t.current,us(e),r)for(e=0;e<r.length;e++)n=r[e],o=n._getVersion,o=o(n._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[n,o]:t.mutableSourceEagerHydrationData.push(n,o);return new ba(t)};at.render=function(e,t,n){if(!Sa(t))throw Error(_(200));return Ca(null,e,t,!1,n)};at.unmountComponentAtNode=function(e){if(!Sa(e))throw Error(_(40));return e._reactRootContainer?(br(function(){Ca(null,null,e,!1,function(){e._reactRootContainer=null,e[sn]=null})}),!0):!1};at.unstable_batchedUpdates=Lc;at.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!Sa(n))throw Error(_(200));if(e==null||e._reactInternals===void 0)throw Error(_(38));return Ca(e,t,n,!1,r)};at.version="18.3.1-next-f1338f8080-20240426";function Qm(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Qm)}catch(e){console.error(e)}}Qm(),Qp.exports=at;var js=Qp.exports;const Gm=Dp(js);var Km,Rf=js;Km=Rf.createRoot,Rf.hydrateRoot;var Ea=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},ka=typeof window>"u"||"Deno"in globalThis;function Ct(){}function Jx(e,t){return typeof e=="function"?e(t):e}function e1(e){return typeof e=="number"&&e>=0&&e!==1/0}function t1(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Ru(e,t){return typeof e=="function"?e(t):e}function n1(e,t){return typeof e=="function"?e(t):e}function jf(e,t){const{type:n="all",exact:r,fetchStatus:o,predicate:s,queryKey:i,stale:a}=e;if(i){if(r){if(t.queryHash!==Hc(i,t.options))return!1}else if(!xs(t.queryKey,i))return!1}if(n!=="all"){const l=t.isActive();if(n==="active"&&!l||n==="inactive"&&l)return!1}return!(typeof a=="boolean"&&t.isStale()!==a||o&&o!==t.state.fetchStatus||s&&!s(t))}function Of(e,t){const{exact:n,status:r,predicate:o,mutationKey:s}=e;if(s){if(!t.options.mutationKey)return!1;if(n){if(ys(t.options.mutationKey)!==ys(s))return!1}else if(!xs(t.options.mutationKey,s))return!1}return!(r&&t.state.status!==r||o&&!o(t))}function Hc(e,t){return((t==null?void 0:t.queryKeyHashFn)||ys)(e)}function ys(e){return JSON.stringify(e,(t,n)=>ju(n)?Object.keys(n).sort().reduce((r,o)=>(r[o]=n[o],r),{}):n)}function xs(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(n=>xs(e[n],t[n])):!1}function Ym(e,t){if(e===t)return e;const n=_f(e)&&_f(t);if(n||ju(e)&&ju(t)){const r=n?e:Object.keys(e),o=r.length,s=n?t:Object.keys(t),i=s.length,a=n?[]:{},l=new Set(r);let u=0;for(let d=0;d<i;d++){const p=n?d:s[d];(!n&&l.has(p)||n)&&e[p]===void 0&&t[p]===void 0?(a[p]=void 0,u++):(a[p]=Ym(e[p],t[p]),a[p]===e[p]&&e[p]!==void 0&&u++)}return o===i&&u===o?e:a}return t}function _f(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function ju(e){if(!Af(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!Af(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function Af(e){return Object.prototype.toString.call(e)==="[object Object]"}function r1(e){return new Promise(t=>{setTimeout(t,e)})}function o1(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?Ym(e,t):t}function s1(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function i1(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var Vc=Symbol();function qm(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===Vc?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var ur,jn,ro,Np,a1=(Np=class extends Ea{constructor(){super();ee(this,ur);ee(this,jn);ee(this,ro);G(this,ro,t=>{if(!ka&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){j(this,jn)||this.setEventListener(j(this,ro))}onUnsubscribe(){var t;this.hasListeners()||((t=j(this,jn))==null||t.call(this),G(this,jn,void 0))}setEventListener(t){var n;G(this,ro,t),(n=j(this,jn))==null||n.call(this),G(this,jn,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){j(this,ur)!==t&&(G(this,ur,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof j(this,ur)=="boolean"?j(this,ur):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},ur=new WeakMap,jn=new WeakMap,ro=new WeakMap,Np),Xm=new a1,oo,On,so,Tp,l1=(Tp=class extends Ea{constructor(){super();ee(this,oo,!0);ee(this,On);ee(this,so);G(this,so,t=>{if(!ka&&window.addEventListener){const n=()=>t(!0),r=()=>t(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",r)}}})}onSubscribe(){j(this,On)||this.setEventListener(j(this,so))}onUnsubscribe(){var t;this.hasListeners()||((t=j(this,On))==null||t.call(this),G(this,On,void 0))}setEventListener(t){var n;G(this,so,t),(n=j(this,On))==null||n.call(this),G(this,On,t(this.setOnline.bind(this)))}setOnline(t){j(this,oo)!==t&&(G(this,oo,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return j(this,oo)}},oo=new WeakMap,On=new WeakMap,so=new WeakMap,Tp),Zi=new l1;function u1(){let e,t;const n=new Promise((o,s)=>{e=o,t=s});n.status="pending",n.catch(()=>{});function r(o){Object.assign(n,o),delete n.resolve,delete n.reject}return n.resolve=o=>{r({status:"fulfilled",value:o}),e(o)},n.reject=o=>{r({status:"rejected",reason:o}),t(o)},n}function c1(e){return Math.min(1e3*2**e,3e4)}function Zm(e){return(e??"online")==="online"?Zi.isOnline():!0}var Jm=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function xl(e){return e instanceof Jm}function eg(e){let t=!1,n=0,r=!1,o;const s=u1(),i=g=>{var x;r||(y(new Jm(g)),(x=e.abort)==null||x.call(e))},a=()=>{t=!0},l=()=>{t=!1},u=()=>Xm.isFocused()&&(e.networkMode==="always"||Zi.isOnline())&&e.canRun(),d=()=>Zm(e.networkMode)&&e.canRun(),p=g=>{var x;r||(r=!0,(x=e.onSuccess)==null||x.call(e,g),o==null||o(),s.resolve(g))},y=g=>{var x;r||(r=!0,(x=e.onError)==null||x.call(e,g),o==null||o(),s.reject(g))},f=()=>new Promise(g=>{var x;o=h=>{(r||u())&&g(h)},(x=e.onPause)==null||x.call(e)}).then(()=>{var g;o=void 0,r||(g=e.onContinue)==null||g.call(e)}),b=()=>{if(r)return;let g;const x=n===0?e.initialPromise:void 0;try{g=x??e.fn()}catch(h){g=Promise.reject(h)}Promise.resolve(g).then(p).catch(h=>{var N;if(r)return;const m=e.retry??(ka?0:3),w=e.retryDelay??c1,S=typeof w=="function"?w(n,h):w,C=m===!0||typeof m=="number"&&n<m||typeof m=="function"&&m(n,h);if(t||!C){y(h);return}n++,(N=e.onFail)==null||N.call(e,n,h),r1(S).then(()=>u()?void 0:f()).then(()=>{t?y(h):b()})})};return{promise:s,cancel:i,continue:()=>(o==null||o(),s),cancelRetry:a,continueRetry:l,canStart:d,start:()=>(d()?b():f().then(b),s)}}var d1=e=>setTimeout(e,0);function f1(){let e=[],t=0,n=a=>{a()},r=a=>{a()},o=d1;const s=a=>{t?e.push(a):o(()=>{n(a)})},i=()=>{const a=e;e=[],a.length&&o(()=>{r(()=>{a.forEach(l=>{n(l)})})})};return{batch:a=>{let l;t++;try{l=a()}finally{t--,t||i()}return l},batchCalls:a=>(...l)=>{s(()=>{a(...l)})},schedule:s,setNotifyFunction:a=>{n=a},setBatchNotifyFunction:a=>{r=a},setScheduler:a=>{o=a}}}var $e=f1(),cr,Pp,tg=(Pp=class{constructor(){ee(this,cr)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),e1(this.gcTime)&&G(this,cr,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(ka?1/0:5*60*1e3))}clearGcTimeout(){j(this,cr)&&(clearTimeout(j(this,cr)),G(this,cr,void 0))}},cr=new WeakMap,Pp),io,dr,ct,fr,Ae,Cs,pr,Et,Xt,Rp,p1=(Rp=class extends tg{constructor(t){super();ee(this,Et);ee(this,io);ee(this,dr);ee(this,ct);ee(this,fr);ee(this,Ae);ee(this,Cs);ee(this,pr);G(this,pr,!1),G(this,Cs,t.defaultOptions),this.setOptions(t.options),this.observers=[],G(this,fr,t.client),G(this,ct,j(this,fr).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,G(this,io,m1(this.options)),this.state=t.state??j(this,io),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=j(this,Ae))==null?void 0:t.promise}setOptions(t){this.options={...j(this,Cs),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&j(this,ct).remove(this)}setData(t,n){const r=o1(this.state.data,t,this.options);return je(this,Et,Xt).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){je(this,Et,Xt).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,o;const n=(r=j(this,Ae))==null?void 0:r.promise;return(o=j(this,Ae))==null||o.cancel(t),n?n.then(Ct).catch(Ct):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(j(this,io))}isActive(){return this.observers.some(t=>n1(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Vc||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Ru(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!t1(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=j(this,Ae))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=j(this,Ae))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),j(this,ct).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(j(this,Ae)&&(j(this,pr)?j(this,Ae).cancel({revert:!0}):j(this,Ae).cancelRetry()),this.scheduleGc()),j(this,ct).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||je(this,Et,Xt).call(this,{type:"invalidate"})}fetch(t,n){var u,d,p;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(j(this,Ae))return j(this,Ae).continueRetry(),j(this,Ae).promise}if(t&&this.setOptions(t),!this.options.queryFn){const y=this.observers.find(f=>f.options.queryFn);y&&this.setOptions(y.options)}const r=new AbortController,o=y=>{Object.defineProperty(y,"signal",{enumerable:!0,get:()=>(G(this,pr,!0),r.signal)})},s=()=>{const y=qm(this.options,n),b=(()=>{const g={client:j(this,fr),queryKey:this.queryKey,meta:this.meta};return o(g),g})();return G(this,pr,!1),this.options.persister?this.options.persister(y,b,this):y(b)},a=(()=>{const y={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:j(this,fr),state:this.state,fetchFn:s};return o(y),y})();(u=this.options.behavior)==null||u.onFetch(a,this),G(this,dr,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((d=a.fetchOptions)==null?void 0:d.meta))&&je(this,Et,Xt).call(this,{type:"fetch",meta:(p=a.fetchOptions)==null?void 0:p.meta});const l=y=>{var f,b,g,x;xl(y)&&y.silent||je(this,Et,Xt).call(this,{type:"error",error:y}),xl(y)||((b=(f=j(this,ct).config).onError)==null||b.call(f,y,this),(x=(g=j(this,ct).config).onSettled)==null||x.call(g,this.state.data,y,this)),this.scheduleGc()};return G(this,Ae,eg({initialPromise:n==null?void 0:n.initialPromise,fn:a.fetchFn,abort:r.abort.bind(r),onSuccess:y=>{var f,b,g,x;if(y===void 0){l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(y)}catch(h){l(h);return}(b=(f=j(this,ct).config).onSuccess)==null||b.call(f,y,this),(x=(g=j(this,ct).config).onSettled)==null||x.call(g,y,this.state.error,this),this.scheduleGc()},onError:l,onFail:(y,f)=>{je(this,Et,Xt).call(this,{type:"failed",failureCount:y,error:f})},onPause:()=>{je(this,Et,Xt).call(this,{type:"pause"})},onContinue:()=>{je(this,Et,Xt).call(this,{type:"continue"})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0})),j(this,Ae).start()}},io=new WeakMap,dr=new WeakMap,ct=new WeakMap,fr=new WeakMap,Ae=new WeakMap,Cs=new WeakMap,pr=new WeakMap,Et=new WeakSet,Xt=function(t){const n=r=>{switch(t.type){case"failed":return{...r,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...h1(r.data,this.options),fetchMeta:t.meta??null};case"success":return G(this,dr,void 0),{...r,data:t.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const o=t.error;return xl(o)&&o.revert&&j(this,dr)?{...j(this,dr),fetchStatus:"idle"}:{...r,error:o,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:o,fetchStatus:"idle",status:"error"};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...t.state}}};this.state=n(this.state),$e.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),j(this,ct).notify({query:this,type:"updated",action:t})})},Rp);function h1(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Zm(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function m1(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var It,jp,g1=(jp=class extends Ea{constructor(t={}){super();ee(this,It);this.config=t,G(this,It,new Map)}build(t,n,r){const o=n.queryKey,s=n.queryHash??Hc(o,n);let i=this.get(s);return i||(i=new p1({client:t,queryKey:o,queryHash:s,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(o)}),this.add(i)),i}add(t){j(this,It).has(t.queryHash)||(j(this,It).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=j(this,It).get(t.queryHash);n&&(t.destroy(),n===t&&j(this,It).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){$e.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return j(this,It).get(t)}getAll(){return[...j(this,It).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>jf(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>jf(t,r)):n}notify(t){$e.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){$e.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){$e.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},It=new WeakMap,jp),Ft,Ie,hr,$t,Cn,Op,v1=(Op=class extends tg{constructor(t){super();ee(this,$t);ee(this,Ft);ee(this,Ie);ee(this,hr);this.mutationId=t.mutationId,G(this,Ie,t.mutationCache),G(this,Ft,[]),this.state=t.state||y1(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){j(this,Ft).includes(t)||(j(this,Ft).push(t),this.clearGcTimeout(),j(this,Ie).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){G(this,Ft,j(this,Ft).filter(n=>n!==t)),this.scheduleGc(),j(this,Ie).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){j(this,Ft).length||(this.state.status==="pending"?this.scheduleGc():j(this,Ie).remove(this))}continue(){var t;return((t=j(this,hr))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var s,i,a,l,u,d,p,y,f,b,g,x,h,m,w,S,C,N,E,R;const n=()=>{je(this,$t,Cn).call(this,{type:"continue"})};G(this,hr,eg({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(D,L)=>{je(this,$t,Cn).call(this,{type:"failed",failureCount:D,error:L})},onPause:()=>{je(this,$t,Cn).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>j(this,Ie).canRun(this)}));const r=this.state.status==="pending",o=!j(this,hr).canStart();try{if(r)n();else{je(this,$t,Cn).call(this,{type:"pending",variables:t,isPaused:o}),await((i=(s=j(this,Ie).config).onMutate)==null?void 0:i.call(s,t,this));const L=await((l=(a=this.options).onMutate)==null?void 0:l.call(a,t));L!==this.state.context&&je(this,$t,Cn).call(this,{type:"pending",context:L,variables:t,isPaused:o})}const D=await j(this,hr).start();return await((d=(u=j(this,Ie).config).onSuccess)==null?void 0:d.call(u,D,t,this.state.context,this)),await((y=(p=this.options).onSuccess)==null?void 0:y.call(p,D,t,this.state.context)),await((b=(f=j(this,Ie).config).onSettled)==null?void 0:b.call(f,D,null,this.state.variables,this.state.context,this)),await((x=(g=this.options).onSettled)==null?void 0:x.call(g,D,null,t,this.state.context)),je(this,$t,Cn).call(this,{type:"success",data:D}),D}catch(D){try{throw await((m=(h=j(this,Ie).config).onError)==null?void 0:m.call(h,D,t,this.state.context,this)),await((S=(w=this.options).onError)==null?void 0:S.call(w,D,t,this.state.context)),await((N=(C=j(this,Ie).config).onSettled)==null?void 0:N.call(C,void 0,D,this.state.variables,this.state.context,this)),await((R=(E=this.options).onSettled)==null?void 0:R.call(E,void 0,D,t,this.state.context)),D}finally{je(this,$t,Cn).call(this,{type:"error",error:D})}}finally{j(this,Ie).runNext(this)}}},Ft=new WeakMap,Ie=new WeakMap,hr=new WeakMap,$t=new WeakSet,Cn=function(t){const n=r=>{switch(t.type){case"failed":return{...r,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"pending":return{...r,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...r,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:t.error,failureCount:r.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=n(this.state),$e.batch(()=>{j(this,Ft).forEach(r=>{r.onMutationUpdate(t)}),j(this,Ie).notify({mutation:this,type:"updated",action:t})})},Op);function y1(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var en,kt,Es,_p,x1=(_p=class extends Ea{constructor(t={}){super();ee(this,en);ee(this,kt);ee(this,Es);this.config=t,G(this,en,new Set),G(this,kt,new Map),G(this,Es,0)}build(t,n,r){const o=new v1({mutationCache:this,mutationId:++Is(this,Es)._,options:t.defaultMutationOptions(n),state:r});return this.add(o),o}add(t){j(this,en).add(t);const n=ti(t);if(typeof n=="string"){const r=j(this,kt).get(n);r?r.push(t):j(this,kt).set(n,[t])}this.notify({type:"added",mutation:t})}remove(t){if(j(this,en).delete(t)){const n=ti(t);if(typeof n=="string"){const r=j(this,kt).get(n);if(r)if(r.length>1){const o=r.indexOf(t);o!==-1&&r.splice(o,1)}else r[0]===t&&j(this,kt).delete(n)}}this.notify({type:"removed",mutation:t})}canRun(t){const n=ti(t);if(typeof n=="string"){const r=j(this,kt).get(n),o=r==null?void 0:r.find(s=>s.state.status==="pending");return!o||o===t}else return!0}runNext(t){var r;const n=ti(t);if(typeof n=="string"){const o=(r=j(this,kt).get(n))==null?void 0:r.find(s=>s!==t&&s.state.isPaused);return(o==null?void 0:o.continue())??Promise.resolve()}else return Promise.resolve()}clear(){$e.batch(()=>{j(this,en).forEach(t=>{this.notify({type:"removed",mutation:t})}),j(this,en).clear(),j(this,kt).clear()})}getAll(){return Array.from(j(this,en))}find(t){const n={exact:!0,...t};return this.getAll().find(r=>Of(n,r))}findAll(t={}){return this.getAll().filter(n=>Of(t,n))}notify(t){$e.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return $e.batch(()=>Promise.all(t.map(n=>n.continue().catch(Ct))))}},en=new WeakMap,kt=new WeakMap,Es=new WeakMap,_p);function ti(e){var t;return(t=e.options.scope)==null?void 0:t.id}function Df(e){return{onFetch:(t,n)=>{var d,p,y,f,b;const r=t.options,o=(y=(p=(d=t.fetchOptions)==null?void 0:d.meta)==null?void 0:p.fetchMore)==null?void 0:y.direction,s=((f=t.state.data)==null?void 0:f.pages)||[],i=((b=t.state.data)==null?void 0:b.pageParams)||[];let a={pages:[],pageParams:[]},l=0;const u=async()=>{let g=!1;const x=w=>{Object.defineProperty(w,"signal",{enumerable:!0,get:()=>(t.signal.aborted?g=!0:t.signal.addEventListener("abort",()=>{g=!0}),t.signal)})},h=qm(t.options,t.fetchOptions),m=async(w,S,C)=>{if(g)return Promise.reject();if(S==null&&w.pages.length)return Promise.resolve(w);const E=(()=>{const W={client:t.client,queryKey:t.queryKey,pageParam:S,direction:C?"backward":"forward",meta:t.options.meta};return x(W),W})(),R=await h(E),{maxPages:D}=t.options,L=C?i1:s1;return{pages:L(w.pages,R,D),pageParams:L(w.pageParams,S,D)}};if(o&&s.length){const w=o==="backward",S=w?w1:Mf,C={pages:s,pageParams:i},N=S(r,C);a=await m(C,N,w)}else{const w=e??s.length;do{const S=l===0?i[0]??r.initialPageParam:Mf(r,a);if(l>0&&S==null)break;a=await m(a,S),l++}while(l<w)}return a};t.options.persister?t.fetchFn=()=>{var g,x;return(x=(g=t.options).persister)==null?void 0:x.call(g,u,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=u}}}function Mf(e,{pages:t,pageParams:n}){const r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function w1(e,{pages:t,pageParams:n}){var r;return t.length>0?(r=e.getPreviousPageParam)==null?void 0:r.call(e,t[0],t,n[0],n):void 0}var me,_n,An,ao,lo,Dn,uo,co,Ap,b1=(Ap=class{constructor(e={}){ee(this,me);ee(this,_n);ee(this,An);ee(this,ao);ee(this,lo);ee(this,Dn);ee(this,uo);ee(this,co);G(this,me,e.queryCache||new g1),G(this,_n,e.mutationCache||new x1),G(this,An,e.defaultOptions||{}),G(this,ao,new Map),G(this,lo,new Map),G(this,Dn,0)}mount(){Is(this,Dn)._++,j(this,Dn)===1&&(G(this,uo,Xm.subscribe(async e=>{e&&(await this.resumePausedMutations(),j(this,me).onFocus())})),G(this,co,Zi.subscribe(async e=>{e&&(await this.resumePausedMutations(),j(this,me).onOnline())})))}unmount(){var e,t;Is(this,Dn)._--,j(this,Dn)===0&&((e=j(this,uo))==null||e.call(this),G(this,uo,void 0),(t=j(this,co))==null||t.call(this),G(this,co,void 0))}isFetching(e){return j(this,me).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return j(this,_n).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=j(this,me).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=j(this,me).build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(Ru(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return j(this,me).findAll(e).map(({queryKey:t,state:n})=>{const r=n.data;return[t,r]})}setQueryData(e,t,n){const r=this.defaultQueryOptions({queryKey:e}),o=j(this,me).get(r.queryHash),s=o==null?void 0:o.state.data,i=Jx(t,s);if(i!==void 0)return j(this,me).build(this,r).setData(i,{...n,manual:!0})}setQueriesData(e,t,n){return $e.batch(()=>j(this,me).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=j(this,me).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=j(this,me);$e.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=j(this,me);return $e.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=$e.batch(()=>j(this,me).findAll(e).map(o=>o.cancel(n)));return Promise.all(r).then(Ct).catch(Ct)}invalidateQueries(e,t={}){return $e.batch(()=>(j(this,me).findAll(e).forEach(n=>{n.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const n={...t,cancelRefetch:t.cancelRefetch??!0},r=$e.batch(()=>j(this,me).findAll(e).filter(o=>!o.isDisabled()&&!o.isStatic()).map(o=>{let s=o.fetch(void 0,n);return n.throwOnError||(s=s.catch(Ct)),o.state.fetchStatus==="paused"?Promise.resolve():s}));return Promise.all(r).then(Ct)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=j(this,me).build(this,t);return n.isStaleByTime(Ru(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Ct).catch(Ct)}fetchInfiniteQuery(e){return e.behavior=Df(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Ct).catch(Ct)}ensureInfiniteQueryData(e){return e.behavior=Df(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Zi.isOnline()?j(this,_n).resumePausedMutations():Promise.resolve()}getQueryCache(){return j(this,me)}getMutationCache(){return j(this,_n)}getDefaultOptions(){return j(this,An)}setDefaultOptions(e){G(this,An,e)}setQueryDefaults(e,t){j(this,ao).set(ys(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...j(this,ao).values()],n={};return t.forEach(r=>{xs(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){j(this,lo).set(ys(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...j(this,lo).values()],n={};return t.forEach(r=>{xs(e,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...j(this,An).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=Hc(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===Vc&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...j(this,An).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){j(this,me).clear(),j(this,_n).clear()}},me=new WeakMap,_n=new WeakMap,An=new WeakMap,ao=new WeakMap,lo=new WeakMap,Dn=new WeakMap,uo=new WeakMap,co=new WeakMap,Ap),S1=v.createContext(void 0),C1=({client:e,children:t})=>(v.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),c.jsx(S1.Provider,{value:e,children:t}));/**
* @remix-run/router v1.23.0
*
* Copyright (c) Remix Software Inc.
*
* This source code is licensed under the MIT license found in the
* LICENSE.md file in the root directory of this source tree.
*
* @license MIT
*/function Ji(){return Ji=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ji.apply(this,arguments)}var In;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(In||(In={}));const Lf="popstate";function E1(e){e===void 0&&(e={});function t(r,o){let{pathname:s,search:i,hash:a}=r.location;return Ou("",{pathname:s,search:i,hash:a},o.state&&o.state.usr||null,o.state&&o.state.key||"default")}function n(r,o){return typeof o=="string"?o:rg(o)}return N1(t,n,null,e)}function Ze(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function ng(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function k1(){return Math.random().toString(36).substr(2,8)}function If(e,t){return{usr:e.state,key:e.key,idx:t}}function Ou(e,t,n,r){return n===void 0&&(n=null),Ji({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Na(t):t,{state:n,key:t&&t.key||r||k1()})}function rg(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function Na(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function N1(e,t,n,r){r===void 0&&(r={});let{window:o=document.defaultView,v5Compat:s=!1}=r,i=o.history,a=In.Pop,l=null,u=d();u==null&&(u=0,i.replaceState(Ji({},i.state,{idx:u}),""));function d(){return(i.state||{idx:null}).idx}function p(){a=In.Pop;let x=d(),h=x==null?null:x-u;u=x,l&&l({action:a,location:g.location,delta:h})}function y(x,h){a=In.Push;let m=Ou(g.location,x,h);u=d()+1;let w=If(m,u),S=g.createHref(m);try{i.pushState(w,"",S)}catch(C){if(C instanceof DOMException&&C.name==="DataCloneError")throw C;o.location.assign(S)}s&&l&&l({action:a,location:g.location,delta:1})}function f(x,h){a=In.Replace;let m=Ou(g.location,x,h);u=d();let w=If(m,u),S=g.createHref(m);i.replaceState(w,"",S),s&&l&&l({action:a,location:g.location,delta:0})}function b(x){let h=o.location.origin!=="null"?o.location.origin:o.location.href,m=typeof x=="string"?x:rg(x);return m=m.replace(/ $/,"%20"),Ze(h,"No window.location.(origin|href) available to create URL for href: "+m),new URL(m,h)}let g={get action(){return a},get location(){return e(o,i)},listen(x){if(l)throw new Error("A history only accepts one active listener");return o.addEventListener(Lf,p),l=x,()=>{o.removeEventListener(Lf,p),l=null}},createHref(x){return t(o,x)},createURL:b,encodeLocation(x){let h=b(x);return{pathname:h.pathname,search:h.search,hash:h.hash}},push:y,replace:f,go(x){return i.go(x)}};return g}var Ff;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Ff||(Ff={}));function T1(e,t,n){return n===void 0&&(n="/"),P1(e,t,n,!1)}function P1(e,t,n,r){let o=typeof t=="string"?Na(t):t,s=ig(o.pathname||"/",n);if(s==null)return null;let i=og(e);R1(i);let a=null;for(let l=0;a==null&&l<i.length;++l){let u=z1(s);a=F1(i[l],u,r)}return a}function og(e,t,n,r){t===void 0&&(t=[]),n===void 0&&(n=[]),r===void 0&&(r="");let o=(s,i,a)=>{let l={relativePath:a===void 0?s.path||"":a,caseSensitive:s.caseSensitive===!0,childrenIndex:i,route:s};l.relativePath.startsWith("/")&&(Ze(l.relativePath.startsWith(r),'Absolute route path "'+l.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),l.relativePath=l.relativePath.slice(r.length));let u=Jr([r,l.relativePath]),d=n.concat(l);s.children&&s.children.length>0&&(Ze(s.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+u+'".')),og(s.children,t,d,u)),!(s.path==null&&!s.index)&&t.push({path:u,score:L1(u,s.index),routesMeta:d})};return e.forEach((s,i)=>{var a;if(s.path===""||!((a=s.path)!=null&&a.includes("?")))o(s,i);else for(let l of sg(s.path))o(s,i,l)}),t}function sg(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,o=n.endsWith("?"),s=n.replace(/\?$/,"");if(r.length===0)return o?[s,""]:[s];let i=sg(r.join("/")),a=[];return a.push(...i.map(l=>l===""?s:[s,l].join("/"))),o&&a.push(...i),a.map(l=>e.startsWith("/")&&l===""?"/":l)}function R1(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:I1(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const j1=/^:[\w-]+$/,O1=3,_1=2,A1=1,D1=10,M1=-2,$f=e=>e==="*";function L1(e,t){let n=e.split("/"),r=n.length;return n.some($f)&&(r+=M1),t&&(r+=_1),n.filter(o=>!$f(o)).reduce((o,s)=>o+(j1.test(s)?O1:s===""?A1:D1),r)}function I1(e,t){return e.length===t.length&&e.slice(0,-1).every((r,o)=>r===t[o])?e[e.length-1]-t[t.length-1]:0}function F1(e,t,n){let{routesMeta:r}=e,o={},s="/",i=[];for(let a=0;a<r.length;++a){let l=r[a],u=a===r.length-1,d=s==="/"?t:t.slice(s.length)||"/",p=zf({path:l.relativePath,caseSensitive:l.caseSensitive,end:u},d),y=l.route;if(!p&&u&&n&&!r[r.length-1].route.index&&(p=zf({path:l.relativePath,caseSensitive:l.caseSensitive,end:!1},d)),!p)return null;Object.assign(o,p.params),i.push({params:o,pathname:Jr([s,p.pathname]),pathnameBase:B1(Jr([s,p.pathnameBase])),route:y}),p.pathnameBase!=="/"&&(s=Jr([s,p.pathnameBase]))}return i}function zf(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=$1(e.path,e.caseSensitive,e.end),o=t.match(n);if(!o)return null;let s=o[0],i=s.replace(/(.)\/+$/,"$1"),a=o.slice(1);return{params:r.reduce((u,d,p)=>{let{paramName:y,isOptional:f}=d;if(y==="*"){let g=a[p]||"";i=s.slice(0,s.length-g.length).replace(/(.)\/+$/,"$1")}const b=a[p];return f&&!b?u[y]=void 0:u[y]=(b||"").replace(/%2F/g,"/"),u},{}),pathname:s,pathnameBase:i,pattern:e}}function $1(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),ng(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],o="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(i,a,l)=>(r.push({paramName:a,isOptional:l!=null}),l?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),o+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?o+="\\/*$":e!==""&&e!=="/"&&(o+="(?:(?=\\/|$))"),[new RegExp(o,t?void 0:"i"),r]}function z1(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return ng(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function ig(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}const Jr=e=>e.join("/").replace(/\/\/+/g,"/"),B1=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/");function U1(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const ag=["post","put","patch","delete"];new Set(ag);const W1=["get",...ag];new Set(W1);/**
* React Router v6.30.1
*
* Copyright (c) Remix Software Inc.
*
* This source code is licensed under the MIT license found in the
* LICENSE.md file in the root directory of this source tree.
*
* @license MIT
*/function ea(){return ea=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ea.apply(this,arguments)}const H1=v.createContext(null),V1=v.createContext(null),lg=v.createContext(null),Ta=v.createContext(null),Pa=v.createContext({outlet:null,matches:[],isDataRoute:!1}),ug=v.createContext(null);function Qc(){return v.useContext(Ta)!=null}function cg(){return Qc()||Ze(!1),v.useContext(Ta).location}function Q1(e,t){return G1(e,t)}function G1(e,t,n,r){Qc()||Ze(!1);let{navigator:o}=v.useContext(lg),{matches:s}=v.useContext(Pa),i=s[s.length-1],a=i?i.params:{};i&&i.pathname;let l=i?i.pathnameBase:"/";i&&i.route;let u=cg(),d;if(t){var p;let x=typeof t=="string"?Na(t):t;l==="/"||(p=x.pathname)!=null&&p.startsWith(l)||Ze(!1),d=x}else d=u;let y=d.pathname||"/",f=y;if(l!=="/"){let x=l.replace(/^\//,"").split("/");f="/"+y.replace(/^\//,"").split("/").slice(x.length).join("/")}let b=T1(e,{pathname:f}),g=Z1(b&&b.map(x=>Object.assign({},x,{params:Object.assign({},a,x.params),pathname:Jr([l,o.encodeLocation?o.encodeLocation(x.pathname).pathname:x.pathname]),pathnameBase:x.pathnameBase==="/"?l:Jr([l,o.encodeLocation?o.encodeLocation(x.pathnameBase).pathname:x.pathnameBase])})),s,n,r);return t&&g?v.createElement(Ta.Provider,{value:{location:ea({pathname:"/",search:"",hash:"",state:null,key:"default"},d),navigationType:In.Pop}},g):g}function K1(){let e=nw(),t=U1(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,o={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return v.createElement(v.Fragment,null,v.createElement("h2",null,"Unexpected Application Error!"),v.createElement("h3",{style:{fontStyle:"italic"}},t),n?v.createElement("pre",{style:o},n):null,null)}const Y1=v.createElement(K1,null);class q1 extends v.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?v.createElement(Pa.Provider,{value:this.props.routeContext},v.createElement(ug.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function X1(e){let{routeContext:t,match:n,children:r}=e,o=v.useContext(H1);return o&&o.static&&o.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(o.staticContext._deepestRenderedBoundaryId=n.route.id),v.createElement(Pa.Provider,{value:t},r)}function Z1(e,t,n,r){var o;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var s;if(!n)return null;if(n.errors)e=n.matches;else if((s=r)!=null&&s.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let i=e,a=(o=n)==null?void 0:o.errors;if(a!=null){let d=i.findIndex(p=>p.route.id&&(a==null?void 0:a[p.route.id])!==void 0);d>=0||Ze(!1),i=i.slice(0,Math.min(i.length,d+1))}let l=!1,u=-1;if(n&&r&&r.v7_partialHydration)for(let d=0;d<i.length;d++){let p=i[d];if((p.route.HydrateFallback||p.route.hydrateFallbackElement)&&(u=d),p.route.id){let{loaderData:y,errors:f}=n,b=p.route.loader&&y[p.route.id]===void 0&&(!f||f[p.route.id]===void 0);if(p.route.lazy||b){l=!0,u>=0?i=i.slice(0,u+1):i=[i[0]];break}}}return i.reduceRight((d,p,y)=>{let f,b=!1,g=null,x=null;n&&(f=a&&p.route.id?a[p.route.id]:void 0,g=p.route.errorElement||Y1,l&&(u<0&&y===0?(b=!0,x=null):u===y&&(b=!0,x=p.route.hydrateFallbackElement||null)));let h=t.concat(i.slice(0,y+1)),m=()=>{let w;return f?w=g:b?w=x:p.route.Component?w=v.createElement(p.route.Component,null):p.route.element?w=p.route.element:w=d,v.createElement(X1,{match:p,routeContext:{outlet:d,matches:h,isDataRoute:n!=null},children:w})};return n&&(p.route.ErrorBoundary||p.route.errorElement||y===0)?v.createElement(q1,{location:n.location,revalidation:n.revalidation,component:g,error:f,children:m(),routeContext:{outlet:null,matches:h,isDataRoute:!0}}):m()},null)}var _u=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(_u||{});function J1(e){let t=v.useContext(V1);return t||Ze(!1),t}function ew(e){let t=v.useContext(Pa);return t||Ze(!1),t}function tw(e){let t=ew(),n=t.matches[t.matches.length-1];return n.route.id||Ze(!1),n.route.id}function nw(){var e;let t=v.useContext(ug),n=J1(_u.UseRouteError),r=tw(_u.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function rw(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function Au(e){Ze(!1)}function ow(e){let{basename:t="/",children:n=null,location:r,navigationType:o=In.Pop,navigator:s,static:i=!1,future:a}=e;Qc()&&Ze(!1);let l=t.replace(/^\/*/,"/"),u=v.useMemo(()=>({basename:l,navigator:s,static:i,future:ea({v7_relativeSplatPath:!1},a)}),[l,a,s,i]);typeof r=="string"&&(r=Na(r));let{pathname:d="/",search:p="",hash:y="",state:f=null,key:b="default"}=r,g=v.useMemo(()=>{let x=ig(d,l);return x==null?null:{location:{pathname:x,search:p,hash:y,state:f,key:b},navigationType:o}},[l,d,p,y,f,b,o]);return g==null?null:v.createElement(lg.Provider,{value:u},v.createElement(Ta.Provider,{children:n,value:g}))}function sw(e){let{children:t,location:n}=e;return Q1(Du(t),n)}new Promise(()=>{});function Du(e,t){t===void 0&&(t=[]);let n=[];return v.Children.forEach(e,(r,o)=>{if(!v.isValidElement(r))return;let s=[...t,o];if(r.type===v.Fragment){n.push.apply(n,Du(r.props.children,s));return}r.type!==Au&&Ze(!1),!r.props.index||!r.props.children||Ze(!1);let i={id:r.props.id||s.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(i.children=Du(r.props.children,s)),n.push(i)}),n}/**
* React Router DOM v6.30.1
*
* Copyright (c) Remix Software Inc.
*
* This source code is licensed under the MIT license found in the
* LICENSE.md file in the root directory of this source tree.
*
* @license MIT
*/const iw="6";try{window.__reactRouterVersion=iw}catch{}const aw="startTransition",Bf=Ju[aw];function lw(e){let{basename:t,children:n,future:r,window:o}=e,s=v.useRef();s.current==null&&(s.current=E1({window:o,v5Compat:!0}));let i=s.current,[a,l]=v.useState({action:i.action,location:i.location}),{v7_startTransition:u}=r||{},d=v.useCallback(p=>{u&&Bf?Bf(()=>l(p)):l(p)},[l,u]);return v.useLayoutEffect(()=>i.listen(d),[i,d]),v.useEffect(()=>rw(r),[r]),v.createElement(ow,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:i,future:r})}var Uf;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(Uf||(Uf={}));var Wf;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(Wf||(Wf={}));var Hf=["light","dark"],uw="(prefers-color-scheme: dark)",cw=v.createContext(void 0),dw={setTheme:e=>{},themes:[]},fw=()=>{var e;return(e=v.useContext(cw))!=null?e:dw};v.memo(({forcedTheme:e,storageKey:t,attribute:n,enableSystem:r,enableColorScheme:o,defaultTheme:s,value:i,attrs:a,nonce:l})=>{let u=s==="system",d=n==="class"?`var d=document.documentElement,c=d.classList;${`c.remove(${a.map(b=>`'${b}'`).join(",")})`};`:`var d=document.documentElement,n='${n}',s='setAttribute';`,p=o?Hf.includes(s)&&s?`if(e==='light'||e==='dark'||!e)d.style.colorScheme=e||'${s}'`:"if(e==='light'||e==='dark')d.style.colorScheme=e":"",y=(b,g=!1,x=!0)=>{let h=i?i[b]:b,m=g?b+"|| ''":`'${h}'`,w="";return o&&x&&!g&&Hf.includes(b)&&(w+=`d.style.colorScheme = '${b}';`),n==="class"?g||h?w+=`c.add(${m})`:w+="null":h&&(w+=`d[s](n,${m})`),w},f=e?`!function(){${d}${y(e)}}()`:r?`!function(){try{${d}var e=localStorage.getItem('${t}');if('system'===e||(!e&&${u})){var t='${uw}',m=window.matchMedia(t);if(m.media!==t||m.matches){${y("dark")}}else{${y("light")}}}else if(e){${i?`var x=${JSON.stringify(i)};`:""}${y(i?"x[e]":"e",!0)}}${u?"":"else{"+y(s,!1,!1)+"}"}${p}}catch(e){}}()`:`!function(){try{${d}var e=localStorage.getItem('${t}');if(e){${i?`var x=${JSON.stringify(i)};`:""}${y(i?"x[e]":"e",!0)}}else{${y(s,!1,!1)};}${p}}catch(t){}}();`;return v.createElement("script",{nonce:l,dangerouslySetInnerHTML:{__html:f}})});var pw=e=>{switch(e){case"success":return gw;case"info":return yw;case"warning":return vw;case"error":return xw;default:return null}},hw=Array(12).fill(0),mw=({visible:e,className:t})=>M.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},M.createElement("div",{className:"sonner-spinner"},hw.map((n,r)=>M.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),gw=M.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},M.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),vw=M.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},M.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),yw=M.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},M.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),xw=M.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},M.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),ww=M.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},M.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),M.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),bw=()=>{let[e,t]=M.useState(document.hidden);return M.useEffect(()=>{let n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e},Mu=1,Sw=class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);this.subscribers.splice(t,1)}),this.publish=e=>{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var t;let{message:n,...r}=e,o=typeof(e==null?void 0:e.id)=="number"||((t=e.id)==null?void 0:t.length)>0?e.id:Mu++,s=this.toasts.find(a=>a.id===o),i=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(o)&&this.dismissedToasts.delete(o),s?this.toasts=this.toasts.map(a=>a.id===o?(this.publish({...a,...e,id:o,title:n}),{...a,...e,id:o,dismissible:i,title:n}):a):this.addToast({title:n,...r,dismissible:i,id:o}),o},this.dismiss=e=>(this.dismissedToasts.add(e),e||this.toasts.forEach(t=>{this.subscribers.forEach(n=>n({id:t.id,dismiss:!0}))}),this.subscribers.forEach(t=>t({id:e,dismiss:!0})),e),this.message=(e,t)=>this.create({...t,message:e}),this.error=(e,t)=>this.create({...t,message:e,type:"error"}),this.success=(e,t)=>this.create({...t,type:"success",message:e}),this.info=(e,t)=>this.create({...t,type:"info",message:e}),this.warning=(e,t)=>this.create({...t,type:"warning",message:e}),this.loading=(e,t)=>this.create({...t,type:"loading",message:e}),this.promise=(e,t)=>{if(!t)return;let n;t.loading!==void 0&&(n=this.create({...t,promise:e,type:"loading",message:t.loading,description:typeof t.description!="function"?t.description:void 0}));let r=e instanceof Promise?e:e(),o=n!==void 0,s,i=r.then(async l=>{if(s=["resolve",l],M.isValidElement(l))o=!1,this.create({id:n,type:"default",message:l});else if(Ew(l)&&!l.ok){o=!1;let u=typeof t.error=="function"?await t.error(`HTTP error! status: ${l.status}`):t.error,d=typeof t.description=="function"?await t.description(`HTTP error! status: ${l.status}`):t.description;this.create({id:n,type:"error",message:u,description:d})}else if(t.success!==void 0){o=!1;let u=typeof t.success=="function"?await t.success(l):t.success,d=typeof t.description=="function"?await t.description(l):t.description;this.create({id:n,type:"success",message:u,description:d})}}).catch(async l=>{if(s=["reject",l],t.error!==void 0){o=!1;let u=typeof t.error=="function"?await t.error(l):t.error,d=typeof t.description=="function"?await t.description(l):t.description;this.create({id:n,type:"error",message:u,description:d})}}).finally(()=>{var l;o&&(this.dismiss(n),n=void 0),(l=t.finally)==null||l.call(t)}),a=()=>new Promise((l,u)=>i.then(()=>s[0]==="reject"?u(s[1]):l(s[1])).catch(u));return typeof n!="string"&&typeof n!="number"?{unwrap:a}:Object.assign(n,{unwrap:a})},this.custom=(e,t)=>{let n=(t==null?void 0:t.id)||Mu++;return this.create({jsx:e(n),id:n,...t}),n},this.getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}},Qe=new Sw,Cw=(e,t)=>{let n=(t==null?void 0:t.id)||Mu++;return Qe.addToast({title:e,...t,id:n}),n},Ew=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",kw=Cw,Nw=()=>Qe.toasts,Tw=()=>Qe.getActiveToasts(),He=Object.assign(kw,{success:Qe.success,info:Qe.info,warning:Qe.warning,error:Qe.error,custom:Qe.custom,message:Qe.message,promise:Qe.promise,dismiss:Qe.dismiss,loading:Qe.loading},{getHistory:Nw,getToasts:Tw});function Pw(e,{insertAt:t}={}){if(typeof document>"u")return;let n=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t==="top"&&n.firstChild?n.insertBefore(r,n.firstChild):n.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}Pw(`:where(html[dir="ltr"]),:where([data-sonner-toaster][dir="ltr"]){--toast-icon-margin-start: -3px;--toast-icon-margin-end: 4px;--toast-svg-margin-start: -1px;--toast-svg-margin-end: 0px;--toast-button-margin-start: auto;--toast-button-margin-end: 0;--toast-close-button-start: 0;--toast-close-button-end: unset;--toast-close-button-transform: translate(-35%, -35%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][dir="rtl"]){--toast-icon-margin-start: 4px;--toast-icon-margin-end: -3px;--toast-svg-margin-start: 0px;--toast-svg-margin-end: -1px;--toast-button-margin-start: 0;--toast-button-margin-end: auto;--toast-close-button-start: unset;--toast-close-button-end: 0;--toast-close-button-transform: translate(35%, -35%)}:where([data-sonner-toaster]){position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1: hsl(0, 0%, 99%);--gray2: hsl(0, 0%, 97.3%);--gray3: hsl(0, 0%, 95.1%);--gray4: hsl(0, 0%, 93%);--gray5: hsl(0, 0%, 90.9%);--gray6: hsl(0, 0%, 88.7%);--gray7: hsl(0, 0%, 85.8%);--gray8: hsl(0, 0%, 78%);--gray9: hsl(0, 0%, 56.1%);--gray10: hsl(0, 0%, 52.3%);--gray11: hsl(0, 0%, 43.5%);--gray12: hsl(0, 0%, 9%);--border-radius: 8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:none;z-index:999999999;transition:transform .4s ease}:where([data-sonner-toaster][data-lifted="true"]){transform:translateY(-10px)}@media (hover: none) and (pointer: coarse){:where([data-sonner-toaster][data-lifted="true"]){transform:none}}:where([data-sonner-toaster][data-x-position="right"]){right:var(--offset-right)}:where([data-sonner-toaster][data-x-position="left"]){left:var(--offset-left)}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:var(--offset-top)}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:var(--offset-bottom)}:where([data-sonner-toast]){--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([data-sonner-toast][data-styled="true"]){padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([data-icon]){display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([data-content]){display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([data-close-button]){position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast] [data-close-button]{background:var(--gray1)}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:-50%;right:-50%;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="false"]){--y: translateY(40%);opacity:0;transition:transform .5s,opacity .2s}:where([data-sonner-toast][data-removed="true"][data-front="false"]):before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y, 0px)) translate(var(--swipe-amount-x, 0px));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--warning-text: hsl(31, 92%, 45%);--error-bg: hsl(359, 100%, 97%);--error-border: hsl(359, 100%, 94%);--error-text: hsl(360, 100%, 45%)}[data-sonner-toaster][data-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-bg-hover: hsl(0, 0%, 12%);--normal-border: hsl(0, 0%, 20%);--normal-border-hover: hsl(0, 0%, 25%);--normal-text: var(--gray1);--success-bg: hsl(150, 100%, 6%);--success-border: hsl(147, 100%, 12%);--success-text: hsl(150, 86%, 65%);--info-bg: hsl(215, 100%, 6%);--info-border: hsl(223, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--warning-text: hsl(46, 87%, 65%);--error-bg: hsl(358, 76%, 10%);--error-border: hsl(357, 89%, 16%);--error-text: hsl(358, 100%, 81%)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success],[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info],[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning],[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error],[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size: 16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:nth-child(1){animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}
`);function ni(e){return e.label!==void 0}var Rw=3,jw="32px",Ow="16px",Vf=4e3,_w=356,Aw=14,Dw=20,Mw=200;function bt(...e){return e.filter(Boolean).join(" ")}function Lw(e){let[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}var Iw=e=>{var t,n,r,o,s,i,a,l,u,d,p;let{invert:y,toast:f,unstyled:b,interacting:g,setHeights:x,visibleToasts:h,heights:m,index:w,toasts:S,expanded:C,removeToast:N,defaultRichColors:E,closeButton:R,style:D,cancelButtonStyle:L,actionButtonStyle:W,className:$="",descriptionClassName:V="",duration:F,position:I,gap:T,loadingIcon:O,expandByDefault:k,classNames:P,icons:A,closeButtonAriaLabel:U="Close toast",pauseWhenPageIsHidden:z}=e,[H,Y]=M.useState(null),[he,Ce]=M.useState(null),[J,hn]=M.useState(!1),[X,ae]=M.useState(!1),[Dt,Nr]=M.useState(!1),[mn,Ds]=M.useState(!1),[Ua,Ms]=M.useState(!1),[Wa,Po]=M.useState(0),[Tr,pd]=M.useState(0),Ro=M.useRef(f.duration||F||Vf),hd=M.useRef(null),tr=M.useRef(null),yy=w===0,xy=w+1<=h,ut=f.type,Pr=f.dismissible!==!1,wy=f.className||"",by=f.descriptionClassName||"",Ls=M.useMemo(()=>m.findIndex(Q=>Q.toastId===f.id)||0,[m,f.id]),Sy=M.useMemo(()=>{var Q;return(Q=f.closeButton)!=null?Q:R},[f.closeButton,R]),md=M.useMemo(()=>f.duration||F||Vf,[f.duration,F]),Ha=M.useRef(0),Rr=M.useRef(0),gd=M.useRef(0),jr=M.useRef(null),[Cy,Ey]=I.split("-"),vd=M.useMemo(()=>m.reduce((Q,ne,le)=>le>=Ls?Q:Q+ne.height,0),[m,Ls]),yd=bw(),ky=f.invert||y,Va=ut==="loading";Rr.current=M.useMemo(()=>Ls*T+vd,[Ls,vd]),M.useEffect(()=>{Ro.current=md},[md]),M.useEffect(()=>{hn(!0)},[]),M.useEffect(()=>{let Q=tr.current;if(Q){let ne=Q.getBoundingClientRect().height;return pd(ne),x(le=>[{toastId:f.id,height:ne,position:f.position},...le]),()=>x(le=>le.filter(vt=>vt.toastId!==f.id))}},[x,f.id]),M.useLayoutEffect(()=>{if(!J)return;let Q=tr.current,ne=Q.style.height;Q.style.height="auto";let le=Q.getBoundingClientRect().height;Q.style.height=ne,pd(le),x(vt=>vt.find(yt=>yt.toastId===f.id)?vt.map(yt=>yt.toastId===f.id?{...yt,height:le}:yt):[{toastId:f.id,height:le,position:f.position},...vt])},[J,f.title,f.description,x,f.id]);let gn=M.useCallback(()=>{ae(!0),Po(Rr.current),x(Q=>Q.filter(ne=>ne.toastId!==f.id)),setTimeout(()=>{N(f)},Mw)},[f,N,x,Rr]);M.useEffect(()=>{if(f.promise&&ut==="loading"||f.duration===1/0||f.type==="loading")return;let Q;return C||g||z&&yd?(()=>{if(gd.current<Ha.current){let ne=new Date().getTime()-Ha.current;Ro.current=Ro.current-ne}gd.current=new Date().getTime()})():Ro.current!==1/0&&(Ha.current=new Date().getTime(),Q=setTimeout(()=>{var ne;(ne=f.onAutoClose)==null||ne.call(f,f),gn()},Ro.current)),()=>clearTimeout(Q)},[C,g,f,ut,z,yd,gn]),M.useEffect(()=>{f.delete&&gn()},[gn,f.delete]);function Ny(){var Q,ne,le;return A!=null&&A.loading?M.createElement("div",{className:bt(P==null?void 0:P.loader,(Q=f==null?void 0:f.classNames)==null?void 0:Q.loader,"sonner-loader"),"data-visible":ut==="loading"},A.loading):O?M.createElement("div",{className:bt(P==null?void 0:P.loader,(ne=f==null?void 0:f.classNames)==null?void 0:ne.loader,"sonner-loader"),"data-visible":ut==="loading"},O):M.createElement(mw,{className:bt(P==null?void 0:P.loader,(le=f==null?void 0:f.classNames)==null?void 0:le.loader),visible:ut==="loading"})}return M.createElement("li",{tabIndex:0,ref:tr,className:bt($,wy,P==null?void 0:P.toast,(t=f==null?void 0:f.classNames)==null?void 0:t.toast,P==null?void 0:P.default,P==null?void 0:P[ut],(n=f==null?void 0:f.classNames)==null?void 0:n[ut]),"data-sonner-toast":"","data-rich-colors":(r=f.richColors)!=null?r:E,"data-styled":!(f.jsx||f.unstyled||b),"data-mounted":J,"data-promise":!!f.promise,"data-swiped":Ua,"data-removed":X,"data-visible":xy,"data-y-position":Cy,"data-x-position":Ey,"data-index":w,"data-front":yy,"data-swiping":Dt,"data-dismissible":Pr,"data-type":ut,"data-invert":ky,"data-swipe-out":mn,"data-swipe-direction":he,"data-expanded":!!(C||k&&J),style:{"--index":w,"--toasts-before":w,"--z-index":S.length-w,"--offset":`${X?Wa:Rr.current}px`,"--initial-height":k?"auto":`${Tr}px`,...D,...f.style},onDragEnd:()=>{Nr(!1),Y(null),jr.current=null},onPointerDown:Q=>{Va||!Pr||(hd.current=new Date,Po(Rr.current),Q.target.setPointerCapture(Q.pointerId),Q.target.tagName!=="BUTTON"&&(Nr(!0),jr.current={x:Q.clientX,y:Q.clientY}))},onPointerUp:()=>{var Q,ne,le,vt;if(mn||!Pr)return;jr.current=null;let yt=Number(((Q=tr.current)==null?void 0:Q.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),vn=Number(((ne=tr.current)==null?void 0:ne.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),nr=new Date().getTime()-((le=hd.current)==null?void 0:le.getTime()),xt=H==="x"?yt:vn,yn=Math.abs(xt)/nr;if(Math.abs(xt)>=Dw||yn>.11){Po(Rr.current),(vt=f.onDismiss)==null||vt.call(f,f),Ce(H==="x"?yt>0?"right":"left":vn>0?"down":"up"),gn(),Ds(!0),Ms(!1);return}Nr(!1),Y(null)},onPointerMove:Q=>{var ne,le,vt,yt;if(!jr.current||!Pr||((ne=window.getSelection())==null?void 0:ne.toString().length)>0)return;let vn=Q.clientY-jr.current.y,nr=Q.clientX-jr.current.x,xt=(le=e.swipeDirections)!=null?le:Lw(I);!H&&(Math.abs(nr)>1||Math.abs(vn)>1)&&Y(Math.abs(nr)>Math.abs(vn)?"x":"y");let yn={x:0,y:0};H==="y"?(xt.includes("top")||xt.includes("bottom"))&&(xt.includes("top")&&vn<0||xt.includes("bottom")&&vn>0)&&(yn.y=vn):H==="x"&&(xt.includes("left")||xt.includes("right"))&&(xt.includes("left")&&nr<0||xt.includes("right")&&nr>0)&&(yn.x=nr),(Math.abs(yn.x)>0||Math.abs(yn.y)>0)&&Ms(!0),(vt=tr.current)==null||vt.style.setProperty("--swipe-amount-x",`${yn.x}px`),(yt=tr.current)==null||yt.style.setProperty("--swipe-amount-y",`${yn.y}px`)}},Sy&&!f.jsx?M.createElement("button",{"aria-label":U,"data-disabled":Va,"data-close-button":!0,onClick:Va||!Pr?()=>{}:()=>{var Q;gn(),(Q=f.onDismiss)==null||Q.call(f,f)},className:bt(P==null?void 0:P.closeButton,(o=f==null?void 0:f.classNames)==null?void 0:o.closeButton)},(s=A==null?void 0:A.close)!=null?s:ww):null,f.jsx||v.isValidElement(f.title)?f.jsx?f.jsx:typeof f.title=="function"?f.title():f.title:M.createElement(M.Fragment,null,ut||f.icon||f.promise?M.createElement("div",{"data-icon":"",className:bt(P==null?void 0:P.icon,(i=f==null?void 0:f.classNames)==null?void 0:i.icon)},f.promise||f.type==="loading"&&!f.icon?f.icon||Ny():null,f.type!=="loading"?f.icon||(A==null?void 0:A[ut])||pw(ut):null):null,M.createElement("div",{"data-content":"",className:bt(P==null?void 0:P.content,(a=f==null?void 0:f.classNames)==null?void 0:a.content)},M.createElement("div",{"data-title":"",className:bt(P==null?void 0:P.title,(l=f==null?void 0:f.classNames)==null?void 0:l.title)},typeof f.title=="function"?f.title():f.title),f.description?M.createElement("div",{"data-description":"",className:bt(V,by,P==null?void 0:P.description,(u=f==null?void 0:f.classNames)==null?void 0:u.description)},typeof f.description=="function"?f.description():f.description):null),v.isValidElement(f.cancel)?f.cancel:f.cancel&&ni(f.cancel)?M.createElement("button",{"data-button":!0,"data-cancel":!0,style:f.cancelButtonStyle||L,onClick:Q=>{var ne,le;ni(f.cancel)&&Pr&&((le=(ne=f.cancel).onClick)==null||le.call(ne,Q),gn())},className:bt(P==null?void 0:P.cancelButton,(d=f==null?void 0:f.classNames)==null?void 0:d.cancelButton)},f.cancel.label):null,v.isValidElement(f.action)?f.action:f.action&&ni(f.action)?M.createElement("button",{"data-button":!0,"data-action":!0,style:f.actionButtonStyle||W,onClick:Q=>{var ne,le;ni(f.action)&&((le=(ne=f.action).onClick)==null||le.call(ne,Q),!Q.defaultPrevented&&gn())},className:bt(P==null?void 0:P.actionButton,(p=f==null?void 0:f.classNames)==null?void 0:p.actionButton)},f.action.label):null))};function Qf(){if(typeof window>"u"||typeof document>"u")return"ltr";let e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function Fw(e,t){let n={};return[e,t].forEach((r,o)=>{let s=o===1,i=s?"--mobile-offset":"--offset",a=s?Ow:jw;function l(u){["top","right","bottom","left"].forEach(d=>{n[`${i}-${d}`]=typeof u=="number"?`${u}px`:u})}typeof r=="number"||typeof r=="string"?l(r):typeof r=="object"?["top","right","bottom","left"].forEach(u=>{r[u]===void 0?n[`${i}-${u}`]=a:n[`${i}-${u}`]=typeof r[u]=="number"?`${r[u]}px`:r[u]}):l(a)}),n}var $w=v.forwardRef(function(e,t){let{invert:n,position:r="bottom-right",hotkey:o=["altKey","KeyT"],expand:s,closeButton:i,className:a,offset:l,mobileOffset:u,theme:d="light",richColors:p,duration:y,style:f,visibleToasts:b=Rw,toastOptions:g,dir:x=Qf(),gap:h=Aw,loadingIcon:m,icons:w,containerAriaLabel:S="Notifications",pauseWhenPageIsHidden:C}=e,[N,E]=M.useState([]),R=M.useMemo(()=>Array.from(new Set([r].concat(N.filter(z=>z.position).map(z=>z.position)))),[N,r]),[D,L]=M.useState([]),[W,$]=M.useState(!1),[V,F]=M.useState(!1),[I,T]=M.useState(d!=="system"?d:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),O=M.useRef(null),k=o.join("+").replace(/Key/g,"").replace(/Digit/g,""),P=M.useRef(null),A=M.useRef(!1),U=M.useCallback(z=>{E(H=>{var Y;return(Y=H.find(he=>he.id===z.id))!=null&&Y.delete||Qe.dismiss(z.id),H.filter(({id:he})=>he!==z.id)})},[]);return M.useEffect(()=>Qe.subscribe(z=>{if(z.dismiss){E(H=>H.map(Y=>Y.id===z.id?{...Y,delete:!0}:Y));return}setTimeout(()=>{Gm.flushSync(()=>{E(H=>{let Y=H.findIndex(he=>he.id===z.id);return Y!==-1?[...H.slice(0,Y),{...H[Y],...z},...H.slice(Y+1)]:[z,...H]})})})}),[]),M.useEffect(()=>{if(d!=="system"){T(d);return}if(d==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?T("dark"):T("light")),typeof window>"u")return;let z=window.matchMedia("(prefers-color-scheme: dark)");try{z.addEventListener("change",({matches:H})=>{T(H?"dark":"light")})}catch{z.addListener(({matches:Y})=>{try{T(Y?"dark":"light")}catch(he){console.error(he)}})}},[d]),M.useEffect(()=>{N.length<=1&&$(!1)},[N]),M.useEffect(()=>{let z=H=>{var Y,he;o.every(Ce=>H[Ce]||H.code===Ce)&&($(!0),(Y=O.current)==null||Y.focus()),H.code==="Escape"&&(document.activeElement===O.current||(he=O.current)!=null&&he.contains(document.activeElement))&&$(!1)};return document.addEventListener("keydown",z),()=>document.removeEventListener("keydown",z)},[o]),M.useEffect(()=>{if(O.current)return()=>{P.current&&(P.current.focus({preventScroll:!0}),P.current=null,A.current=!1)}},[O.current]),M.createElement("section",{ref:t,"aria-label":`${S} ${k}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},R.map((z,H)=>{var Y;let[he,Ce]=z.split("-");return N.length?M.createElement("ol",{key:z,dir:x==="auto"?Qf():x,tabIndex:-1,ref:O,className:a,"data-sonner-toaster":!0,"data-theme":I,"data-y-position":he,"data-lifted":W&&N.length>1&&!s,"data-x-position":Ce,style:{"--front-toast-height":`${((Y=D[0])==null?void 0:Y.height)||0}px`,"--width":`${_w}px`,"--gap":`${h}px`,...f,...Fw(l,u)},onBlur:J=>{A.current&&!J.currentTarget.contains(J.relatedTarget)&&(A.current=!1,P.current&&(P.current.focus({preventScroll:!0}),P.current=null))},onFocus:J=>{J.target instanceof HTMLElement&&J.target.dataset.dismissible==="false"||A.current||(A.current=!0,P.current=J.relatedTarget)},onMouseEnter:()=>$(!0),onMouseMove:()=>$(!0),onMouseLeave:()=>{V||$(!1)},onDragEnd:()=>$(!1),onPointerDown:J=>{J.target instanceof HTMLElement&&J.target.dataset.dismissible==="false"||F(!0)},onPointerUp:()=>F(!1)},N.filter(J=>!J.position&&H===0||J.position===z).map((J,hn)=>{var X,ae;return M.createElement(Iw,{key:J.id,icons:w,index:hn,toast:J,defaultRichColors:p,duration:(X=g==null?void 0:g.duration)!=null?X:y,className:g==null?void 0:g.className,descriptionClassName:g==null?void 0:g.descriptionClassName,invert:n,visibleToasts:b,closeButton:(ae=g==null?void 0:g.closeButton)!=null?ae:i,interacting:V,position:z,style:g==null?void 0:g.style,unstyled:g==null?void 0:g.unstyled,classNames:g==null?void 0:g.classNames,cancelButtonStyle:g==null?void 0:g.cancelButtonStyle,actionButtonStyle:g==null?void 0:g.actionButtonStyle,removeToast:U,toasts:N.filter(Dt=>Dt.position==J.position),heights:D.filter(Dt=>Dt.position==J.position),setHeights:L,expandByDefault:s,gap:h,loadingIcon:m,expanded:W,pauseWhenPageIsHidden:C,swipeDirections:e.swipeDirections})})):null}))});const zw=({...e})=>{const{theme:t="system"}=fw();return c.jsx($w,{theme:t,className:"toaster group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})},Bw=1,Uw=1e6;let wl=0;function Ww(){return wl=(wl+1)%Number.MAX_SAFE_INTEGER,wl.toString()}const bl=new Map,Gf=e=>{if(bl.has(e))return;const t=setTimeout(()=>{bl.delete(e),es({type:"REMOVE_TOAST",toastId:e})},Uw);bl.set(e,t)},Hw=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,Bw)};case"UPDATE_TOAST":return{...e,toasts:e.toasts.map(n=>n.id===t.toast.id?{...n,...t.toast}:n)};case"DISMISS_TOAST":{const{toastId:n}=t;return n?Gf(n):e.toasts.forEach(r=>{Gf(r.id)}),{...e,toasts:e.toasts.map(r=>r.id===n||n===void 0?{...r,open:!1}:r)}}case"REMOVE_TOAST":return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(n=>n.id!==t.toastId)}}},Si=[];let Ci={toasts:[]};function es(e){Ci=Hw(Ci,e),Si.forEach(t=>{t(Ci)})}function Vw({...e}){const t=Ww(),n=o=>es({type:"UPDATE_TOAST",toast:{...o,id:t}}),r=()=>es({type:"DISMISS_TOAST",toastId:t});return es({type:"ADD_TOAST",toast:{...e,id:t,open:!0,onOpenChange:o=>{o||r()}}}),{id:t,dismiss:r,update:n}}function Qw(){const[e,t]=v.useState(Ci);return v.useEffect(()=>(Si.push(t),()=>{const n=Si.indexOf(t);n>-1&&Si.splice(n,1)}),[e]),{...e,toast:Vw,dismiss:n=>es({type:"DISMISS_TOAST",toastId:n})}}function ce(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e==null||e(o),n===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}function Kf(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function dg(...e){return t=>{let n=!1;const r=e.map(o=>{const s=Kf(o,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let o=0;o<r.length;o++){const s=r[o];typeof s=="function"?s():Kf(e[o],null)}}}}function Be(...e){return v.useCallback(dg(...e),e)}function Gw(e,t){const n=v.createContext(t),r=s=>{const{children:i,...a}=s,l=v.useMemo(()=>a,Object.values(a));return c.jsx(n.Provider,{value:l,children:i})};r.displayName=e+"Provider";function o(s){const i=v.useContext(n);if(i)return i;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[r,o]}function Os(e,t=[]){let n=[];function r(s,i){const a=v.createContext(i),l=n.length;n=[...n,i];const u=p=>{var h;const{scope:y,children:f,...b}=p,g=((h=y==null?void 0:y[e])==null?void 0:h[l])||a,x=v.useMemo(()=>b,Object.values(b));return c.jsx(g.Provider,{value:x,children:f})};u.displayName=s+"Provider";function d(p,y){var g;const f=((g=y==null?void 0:y[e])==null?void 0:g[l])||a,b=v.useContext(f);if(b)return b;if(i!==void 0)return i;throw new Error(`\`${p}\` must be used within \`${s}\``)}return[u,d]}const o=()=>{const s=n.map(i=>v.createContext(i));return function(a){const l=(a==null?void 0:a[e])||s;return v.useMemo(()=>({[`__scope${e}`]:{...a,[e]:l}}),[a,l])}};return o.scopeName=e,[r,Kw(o,...t)]}function Kw(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const i=r.reduce((a,{useScope:l,scopeName:u})=>{const p=l(s)[`__scope${u}`];return{...a,...p}},{});return v.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}function ta(e){const t=Yw(e),n=v.forwardRef((r,o)=>{const{children:s,...i}=r,a=v.Children.toArray(s),l=a.find(Xw);if(l){const u=l.props.children,d=a.map(p=>p===l?v.Children.count(u)>1?v.Children.only(null):v.isValidElement(u)?u.props.children:null:p);return c.jsx(t,{...i,ref:o,children:v.isValidElement(u)?v.cloneElement(u,void 0,d):null})}return c.jsx(t,{...i,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function Yw(e){const t=v.forwardRef((n,r)=>{const{children:o,...s}=n;if(v.isValidElement(o)){const i=Jw(o),a=Zw(s,o.props);return o.type!==v.Fragment&&(a.ref=r?dg(r,i):i),v.cloneElement(o,a)}return v.Children.count(o)>1?v.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var fg=Symbol("radix.slottable");function qw(e){const t=({children:n})=>c.jsx(c.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=fg,t}function Xw(e){return v.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===fg}function Zw(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...a)=>{const l=s(...a);return o(...a),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Jw(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function eb(e){const t=e+"CollectionProvider",[n,r]=Os(t),[o,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=g=>{const{scope:x,children:h}=g,m=M.useRef(null),w=M.useRef(new Map).current;return c.jsx(o,{scope:x,itemMap:w,collectionRef:m,children:h})};i.displayName=t;const a=e+"CollectionSlot",l=ta(a),u=M.forwardRef((g,x)=>{const{scope:h,children:m}=g,w=s(a,h),S=Be(x,w.collectionRef);return c.jsx(l,{ref:S,children:m})});u.displayName=a;const d=e+"CollectionItemSlot",p="data-radix-collection-item",y=ta(d),f=M.forwardRef((g,x)=>{const{scope:h,children:m,...w}=g,S=M.useRef(null),C=Be(x,S),N=s(d,h);return M.useEffect(()=>(N.itemMap.set(S,{ref:S,...w}),()=>void N.itemMap.delete(S))),c.jsx(y,{[p]:"",ref:C,children:m})});f.displayName=d;function b(g){const x=s(e+"CollectionConsumer",g);return M.useCallback(()=>{const m=x.collectionRef.current;if(!m)return[];const w=Array.from(m.querySelectorAll(`[${p}]`));return Array.from(x.itemMap.values()).sort((N,E)=>w.indexOf(N.ref.current)-w.indexOf(E.ref.current))},[x.collectionRef,x.itemMap])}return[{Provider:i,Slot:u,ItemSlot:f},b,r]}var tb=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],xe=tb.reduce((e,t)=>{const n=ta(`Primitive.${t}`),r=v.forwardRef((o,s)=>{const{asChild:i,...a}=o,l=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),c.jsx(l,{...a,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function pg(e,t){e&&js.flushSync(()=>e.dispatchEvent(t))}function Qt(e){const t=v.useRef(e);return v.useEffect(()=>{t.current=e}),v.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function nb(e,t=globalThis==null?void 0:globalThis.document){const n=Qt(e);v.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var rb="DismissableLayer",Lu="dismissableLayer.update",ob="dismissableLayer.pointerDownOutside",sb="dismissableLayer.focusOutside",Yf,hg=v.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Ra=v.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:i,onDismiss:a,...l}=e,u=v.useContext(hg),[d,p]=v.useState(null),y=(d==null?void 0:d.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,f]=v.useState({}),b=Be(t,E=>p(E)),g=Array.from(u.layers),[x]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),h=g.indexOf(x),m=d?g.indexOf(d):-1,w=u.layersWithOutsidePointerEventsDisabled.size>0,S=m>=h,C=ab(E=>{const R=E.target,D=[...u.branches].some(L=>L.contains(R));!S||D||(o==null||o(E),i==null||i(E),E.defaultPrevented||a==null||a())},y),N=lb(E=>{const R=E.target;[...u.branches].some(L=>L.contains(R))||(s==null||s(E),i==null||i(E),E.defaultPrevented||a==null||a())},y);return nb(E=>{m===u.layers.size-1&&(r==null||r(E),!E.defaultPrevented&&a&&(E.preventDefault(),a()))},y),v.useEffect(()=>{if(d)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(Yf=y.body.style.pointerEvents,y.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(d)),u.layers.add(d),qf(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(y.body.style.pointerEvents=Yf)}},[d,y,n,u]),v.useEffect(()=>()=>{d&&(u.layers.delete(d),u.layersWithOutsidePointerEventsDisabled.delete(d),qf())},[d,u]),v.useEffect(()=>{const E=()=>f({});return document.addEventListener(Lu,E),()=>document.removeEventListener(Lu,E)},[]),c.jsx(xe.div,{...l,ref:b,style:{pointerEvents:w?S?"auto":"none":void 0,...e.style},onFocusCapture:ce(e.onFocusCapture,N.onFocusCapture),onBlurCapture:ce(e.onBlurCapture,N.onBlurCapture),onPointerDownCapture:ce(e.onPointerDownCapture,C.onPointerDownCapture)})});Ra.displayName=rb;var ib="DismissableLayerBranch",mg=v.forwardRef((e,t)=>{const n=v.useContext(hg),r=v.useRef(null),o=Be(t,r);return v.useEffect(()=>{const s=r.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),c.jsx(xe.div,{...e,ref:o})});mg.displayName=ib;function ab(e,t=globalThis==null?void 0:globalThis.document){const n=Qt(e),r=v.useRef(!1),o=v.useRef(()=>{});return v.useEffect(()=>{const s=a=>{if(a.target&&!r.current){let l=function(){gg(ob,n,u,{discrete:!0})};const u={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=l,t.addEventListener("click",o.current,{once:!0})):l()}else t.removeEventListener("click",o.current);r.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",s),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function lb(e,t=globalThis==null?void 0:globalThis.document){const n=Qt(e),r=v.useRef(!1);return v.useEffect(()=>{const o=s=>{s.target&&!r.current&&gg(sb,n,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function qf(){const e=new CustomEvent(Lu);document.dispatchEvent(e)}function gg(e,t,n,{discrete:r}){const o=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?pg(o,s):o.dispatchEvent(s)}var ub=Ra,cb=mg,un=globalThis!=null&&globalThis.document?v.useLayoutEffect:()=>{},db="Portal",Gc=v.forwardRef((e,t)=>{var a;const{container:n,...r}=e,[o,s]=v.useState(!1);un(()=>s(!0),[]);const i=n||o&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return i?Gm.createPortal(c.jsx(xe.div,{...r,ref:t}),i):null});Gc.displayName=db;function fb(e,t){return v.useReducer((n,r)=>t[n][r]??n,e)}var Eo=e=>{const{present:t,children:n}=e,r=pb(t),o=typeof n=="function"?n({present:r.isPresent}):v.Children.only(n),s=Be(r.ref,hb(o));return typeof n=="function"||r.isPresent?v.cloneElement(o,{ref:s}):null};Eo.displayName="Presence";function pb(e){const[t,n]=v.useState(),r=v.useRef(null),o=v.useRef(e),s=v.useRef("none"),i=e?"mounted":"unmounted",[a,l]=fb(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return v.useEffect(()=>{const u=ri(r.current);s.current=a==="mounted"?u:"none"},[a]),un(()=>{const u=r.current,d=o.current;if(d!==e){const y=s.current,f=ri(u);e?l("MOUNT"):f==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(d&&y!==f?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,l]),un(()=>{if(t){let u;const d=t.ownerDocument.defaultView??window,p=f=>{const g=ri(r.current).includes(f.animationName);if(f.target===t&&g&&(l("ANIMATION_END"),!o.current)){const x=t.style.animationFillMode;t.style.animationFillMode="forwards",u=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=x)})}},y=f=>{f.target===t&&(s.current=ri(r.current))};return t.addEventListener("animationstart",y),t.addEventListener("animationcancel",p),t.addEventListener("animationend",p),()=>{d.clearTimeout(u),t.removeEventListener("animationstart",y),t.removeEventListener("animationcancel",p),t.removeEventListener("animationend",p)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:v.useCallback(u=>{r.current=u?getComputedStyle(u):null,n(u)},[])}}function ri(e){return(e==null?void 0:e.animationName)||"none"}function hb(e){var r,o;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(o=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var mb=Ju[" useInsertionEffect ".trim().toString()]||un;function vg({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,s,i]=gb({defaultProp:t,onChange:n}),a=e!==void 0,l=a?e:o;{const d=v.useRef(e!==void 0);v.useEffect(()=>{const p=d.current;p!==a&&console.warn(`${r} is changing from ${p?"controlled":"uncontrolled"} to ${a?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=a},[a,r])}const u=v.useCallback(d=>{var p;if(a){const y=vb(d)?d(e):d;y!==e&&((p=i.current)==null||p.call(i,y))}else s(d)},[a,e,s,i]);return[l,u]}function gb({defaultProp:e,onChange:t}){const[n,r]=v.useState(e),o=v.useRef(n),s=v.useRef(t);return mb(()=>{s.current=t},[t]),v.useEffect(()=>{var i;o.current!==n&&((i=s.current)==null||i.call(s,n),o.current=n)},[n,o]),[n,r,s]}function vb(e){return typeof e=="function"}var yb=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),xb="VisuallyHidden",ja=v.forwardRef((e,t)=>c.jsx(xe.span,{...e,ref:t,style:{...yb,...e.style}}));ja.displayName=xb;var wb=ja,Kc="ToastProvider",[Yc,bb,Sb]=eb("Toast"),[yg,vk]=Os("Toast",[Sb]),[Cb,Oa]=yg(Kc),xg=e=>{const{__scopeToast:t,label:n="Notification",duration:r=5e3,swipeDirection:o="right",swipeThreshold:s=50,children:i}=e,[a,l]=v.useState(null),[u,d]=v.useState(0),p=v.useRef(!1),y=v.useRef(!1);return n.trim()||console.error(`Invalid prop \`label\` supplied to \`${Kc}\`. Expected non-empty \`string\`.`),c.jsx(Yc.Provider,{scope:t,children:c.jsx(Cb,{scope:t,label:n,duration:r,swipeDirection:o,swipeThreshold:s,toastCount:u,viewport:a,onViewportChange:l,onToastAdd:v.useCallback(()=>d(f=>f+1),[]),onToastRemove:v.useCallback(()=>d(f=>f-1),[]),isFocusedToastEscapeKeyDownRef:p,isClosePausedRef:y,children:i})})};xg.displayName=Kc;var wg="ToastViewport",Eb=["F8"],Iu="toast.viewportPause",Fu="toast.viewportResume",bg=v.forwardRef((e,t)=>{const{__scopeToast:n,hotkey:r=Eb,label:o="Notifications ({hotkey})",...s}=e,i=Oa(wg,n),a=bb(n),l=v.useRef(null),u=v.useRef(null),d=v.useRef(null),p=v.useRef(null),y=Be(t,p,i.onViewportChange),f=r.join("+").replace(/Key/g,"").replace(/Digit/g,""),b=i.toastCount>0;v.useEffect(()=>{const x=h=>{var w;r.length!==0&&r.every(S=>h[S]||h.code===S)&&((w=p.current)==null||w.focus())};return document.addEventListener("keydown",x),()=>document.removeEventListener("keydown",x)},[r]),v.useEffect(()=>{const x=l.current,h=p.current;if(b&&x&&h){const m=()=>{if(!i.isClosePausedRef.current){const N=new CustomEvent(Iu);h.dispatchEvent(N),i.isClosePausedRef.current=!0}},w=()=>{if(i.isClosePausedRef.current){const N=new CustomEvent(Fu);h.dispatchEvent(N),i.isClosePausedRef.current=!1}},S=N=>{!x.contains(N.relatedTarget)&&w()},C=()=>{x.contains(document.activeElement)||w()};return x.addEventListener("focusin",m),x.addEventListener("focusout",S),x.addEventListener("pointermove",m),x.addEventListener("pointerleave",C),window.addEventListener("blur",m),window.addEventListener("focus",w),()=>{x.removeEventListener("focusin",m),x.removeEventListener("focusout",S),x.removeEventListener("pointermove",m),x.removeEventListener("pointerleave",C),window.removeEventListener("blur",m),window.removeEventListener("focus",w)}}},[b,i.isClosePausedRef]);const g=v.useCallback(({tabbingDirection:x})=>{const m=a().map(w=>{const S=w.ref.current,C=[S,...Ib(S)];return x==="forwards"?C:C.reverse()});return(x==="forwards"?m.reverse():m).flat()},[a]);return v.useEffect(()=>{const x=p.current;if(x){const h=m=>{var C,N,E;const w=m.altKey||m.ctrlKey||m.metaKey;if(m.key==="Tab"&&!w){const R=document.activeElement,D=m.shiftKey;if(m.target===x&&D){(C=u.current)==null||C.focus();return}const $=g({tabbingDirection:D?"backwards":"forwards"}),V=$.findIndex(F=>F===R);Sl($.slice(V+1))?m.preventDefault():D?(N=u.current)==null||N.focus():(E=d.current)==null||E.focus()}};return x.addEventListener("keydown",h),()=>x.removeEventListener("keydown",h)}},[a,g]),c.jsxs(cb,{ref:l,role:"region","aria-label":o.replace("{hotkey}",f),tabIndex:-1,style:{pointerEvents:b?void 0:"none"},children:[b&&c.jsx($u,{ref:u,onFocusFromOutsideViewport:()=>{const x=g({tabbingDirection:"forwards"});Sl(x)}}),c.jsx(Yc.Slot,{scope:n,children:c.jsx(xe.ol,{tabIndex:-1,...s,ref:y})}),b&&c.jsx($u,{ref:d,onFocusFromOutsideViewport:()=>{const x=g({tabbingDirection:"backwards"});Sl(x)}})]})});bg.displayName=wg;var Sg="ToastFocusProxy",$u=v.forwardRef((e,t)=>{const{__scopeToast:n,onFocusFromOutsideViewport:r,...o}=e,s=Oa(Sg,n);return c.jsx(ja,{"aria-hidden":!0,tabIndex:0,...o,ref:t,style:{position:"fixed"},onFocus:i=>{var u;const a=i.relatedTarget;!((u=s.viewport)!=null&&u.contains(a))&&r()}})});$u.displayName=Sg;var _s="Toast",kb="toast.swipeStart",Nb="toast.swipeMove",Tb="toast.swipeCancel",Pb="toast.swipeEnd",Cg=v.forwardRef((e,t)=>{const{forceMount:n,open:r,defaultOpen:o,onOpenChange:s,...i}=e,[a,l]=vg({prop:r,defaultProp:o??!0,onChange:s,caller:_s});return c.jsx(Eo,{present:n||a,children:c.jsx(Ob,{open:a,...i,ref:t,onClose:()=>l(!1),onPause:Qt(e.onPause),onResume:Qt(e.onResume),onSwipeStart:ce(e.onSwipeStart,u=>{u.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:ce(e.onSwipeMove,u=>{const{x:d,y:p}=u.detail.delta;u.currentTarget.setAttribute("data-swipe","move"),u.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${d}px`),u.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${p}px`)}),onSwipeCancel:ce(e.onSwipeCancel,u=>{u.currentTarget.setAttribute("data-swipe","cancel"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),u.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),u.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:ce(e.onSwipeEnd,u=>{const{x:d,y:p}=u.detail.delta;u.currentTarget.setAttribute("data-swipe","end"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),u.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${d}px`),u.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${p}px`),l(!1)})})})});Cg.displayName=_s;var[Rb,jb]=yg(_s,{onClose(){}}),Ob=v.forwardRef((e,t)=>{const{__scopeToast:n,type:r="foreground",duration:o,open:s,onClose:i,onEscapeKeyDown:a,onPause:l,onResume:u,onSwipeStart:d,onSwipeMove:p,onSwipeCancel:y,onSwipeEnd:f,...b}=e,g=Oa(_s,n),[x,h]=v.useState(null),m=Be(t,F=>h(F)),w=v.useRef(null),S=v.useRef(null),C=o||g.duration,N=v.useRef(0),E=v.useRef(C),R=v.useRef(0),{onToastAdd:D,onToastRemove:L}=g,W=Qt(()=>{var I;(x==null?void 0:x.contains(document.activeElement))&&((I=g.viewport)==null||I.focus()),i()}),$=v.useCallback(F=>{!F||F===1/0||(window.clearTimeout(R.current),N.current=new Date().getTime(),R.current=window.setTimeout(W,F))},[W]);v.useEffect(()=>{const F=g.viewport;if(F){const I=()=>{$(E.current),u==null||u()},T=()=>{const O=new Date().getTime()-N.current;E.current=E.current-O,window.clearTimeout(R.current),l==null||l()};return F.addEventListener(Iu,T),F.addEventListener(Fu,I),()=>{F.removeEventListener(Iu,T),F.removeEventListener(Fu,I)}}},[g.viewport,C,l,u,$]),v.useEffect(()=>{s&&!g.isClosePausedRef.current&&$(C)},[s,C,g.isClosePausedRef,$]),v.useEffect(()=>(D(),()=>L()),[D,L]);const V=v.useMemo(()=>x?jg(x):null,[x]);return g.viewport?c.jsxs(c.Fragment,{children:[V&&c.jsx(_b,{__scopeToast:n,role:"status","aria-live":r==="foreground"?"assertive":"polite","aria-atomic":!0,children:V}),c.jsx(Rb,{scope:n,onClose:W,children:js.createPortal(c.jsx(Yc.ItemSlot,{scope:n,children:c.jsx(ub,{asChild:!0,onEscapeKeyDown:ce(a,()=>{g.isFocusedToastEscapeKeyDownRef.current||W(),g.isFocusedToastEscapeKeyDownRef.current=!1}),children:c.jsx(xe.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":s?"open":"closed","data-swipe-direction":g.swipeDirection,...b,ref:m,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:ce(e.onKeyDown,F=>{F.key==="Escape"&&(a==null||a(F.nativeEvent),F.nativeEvent.defaultPrevented||(g.isFocusedToastEscapeKeyDownRef.current=!0,W()))}),onPointerDown:ce(e.onPointerDown,F=>{F.button===0&&(w.current={x:F.clientX,y:F.clientY})}),onPointerMove:ce(e.onPointerMove,F=>{if(!w.current)return;const I=F.clientX-w.current.x,T=F.clientY-w.current.y,O=!!S.current,k=["left","right"].includes(g.swipeDirection),P=["left","up"].includes(g.swipeDirection)?Math.min:Math.max,A=k?P(0,I):0,U=k?0:P(0,T),z=F.pointerType==="touch"?10:2,H={x:A,y:U},Y={originalEvent:F,delta:H};O?(S.current=H,oi(Nb,p,Y,{discrete:!1})):Xf(H,g.swipeDirection,z)?(S.current=H,oi(kb,d,Y,{discrete:!1}),F.target.setPointerCapture(F.pointerId)):(Math.abs(I)>z||Math.abs(T)>z)&&(w.current=null)}),onPointerUp:ce(e.onPointerUp,F=>{const I=S.current,T=F.target;if(T.hasPointerCapture(F.pointerId)&&T.releasePointerCapture(F.pointerId),S.current=null,w.current=null,I){const O=F.currentTarget,k={originalEvent:F,delta:I};Xf(I,g.swipeDirection,g.swipeThreshold)?oi(Pb,f,k,{discrete:!0}):oi(Tb,y,k,{discrete:!0}),O.addEventListener("click",P=>P.preventDefault(),{once:!0})}})})})}),g.viewport)})]}):null}),_b=e=>{const{__scopeToast:t,children:n,...r}=e,o=Oa(_s,t),[s,i]=v.useState(!1),[a,l]=v.useState(!1);return Mb(()=>i(!0)),v.useEffect(()=>{const u=window.setTimeout(()=>l(!0),1e3);return()=>window.clearTimeout(u)},[]),a?null:c.jsx(Gc,{asChild:!0,children:c.jsx(ja,{...r,children:s&&c.jsxs(c.Fragment,{children:[o.label," ",n]})})})},Ab="ToastTitle",Eg=v.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e;return c.jsx(xe.div,{...r,ref:t})});Eg.displayName=Ab;var Db="ToastDescription",kg=v.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e;return c.jsx(xe.div,{...r,ref:t})});kg.displayName=Db;var Ng="ToastAction",Tg=v.forwardRef((e,t)=>{const{altText:n,...r}=e;return n.trim()?c.jsx(Rg,{altText:n,asChild:!0,children:c.jsx(qc,{...r,ref:t})}):(console.error(`Invalid prop \`altText\` supplied to \`${Ng}\`. Expected non-empty \`string\`.`),null)});Tg.displayName=Ng;var Pg="ToastClose",qc=v.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e,o=jb(Pg,n);return c.jsx(Rg,{asChild:!0,children:c.jsx(xe.button,{type:"button",...r,ref:t,onClick:ce(e.onClick,o.onClose)})})});qc.displayName=Pg;var Rg=v.forwardRef((e,t)=>{const{__scopeToast:n,altText:r,...o}=e;return c.jsx(xe.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":r||void 0,...o,ref:t})});function jg(e){const t=[];return Array.from(e.childNodes).forEach(r=>{if(r.nodeType===r.TEXT_NODE&&r.textContent&&t.push(r.textContent),Lb(r)){const o=r.ariaHidden||r.hidden||r.style.display==="none",s=r.dataset.radixToastAnnounceExclude==="";if(!o)if(s){const i=r.dataset.radixToastAnnounceAlt;i&&t.push(i)}else t.push(...jg(r))}}),t}function oi(e,t,n,{discrete:r}){const o=n.originalEvent.currentTarget,s=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?pg(o,s):o.dispatchEvent(s)}var Xf=(e,t,n=0)=>{const r=Math.abs(e.x),o=Math.abs(e.y),s=r>o;return t==="left"||t==="right"?s&&r>n:!s&&o>n};function Mb(e=()=>{}){const t=Qt(e);un(()=>{let n=0,r=0;return n=window.requestAnimationFrame(()=>r=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(n),window.cancelAnimationFrame(r)}},[t])}function Lb(e){return e.nodeType===e.ELEMENT_NODE}function Ib(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Sl(e){const t=document.activeElement;return e.some(n=>n===t?!0:(n.focus(),document.activeElement!==t))}var Fb=xg,Og=bg,_g=Cg,Ag=Eg,Dg=kg,Mg=Tg,Lg=qc;function Ig(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=Ig(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Fg(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=Ig(e))&&(r&&(r+=" "),r+=t);return r}const Zf=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,Jf=Fg,$b=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return Jf(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:o,defaultVariants:s}=t,i=Object.keys(o).map(u=>{const d=n==null?void 0:n[u],p=s==null?void 0:s[u];if(d===null)return null;const y=Zf(d)||Zf(p);return o[u][y]}),a=n&&Object.entries(n).reduce((u,d)=>{let[p,y]=d;return y===void 0||(u[p]=y),u},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((u,d)=>{let{class:p,className:y,...f}=d;return Object.entries(f).every(b=>{let[g,x]=b;return Array.isArray(x)?x.includes({...s,...a}[g]):{...s,...a}[g]===x})?[...u,p,y]:u},[]);return Jf(e,i,l,n==null?void 0:n.class,n==null?void 0:n.className)};/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const zb=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),$g=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/var Bb={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"};/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Ub=v.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:s,iconNode:i,...a},l)=>v.createElement("svg",{ref:l,...Bb,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:$g("lucide",o),...a},[...i.map(([u,d])=>v.createElement(u,d)),...Array.isArray(s)?s:[s]]));/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Je=(e,t)=>{const n=v.forwardRef(({className:r,...o},s)=>v.createElement(Ub,{ref:s,iconNode:t,className:$g(`lucide-${zb(e)}`,r),...o}));return n.displayName=`${e}`,n};/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const zg=Je("Banknote",[["rect",{width:"20",height:"12",x:"2",y:"6",rx:"2",key:"9lu3g6"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["path",{d:"M6 12h.01M18 12h.01",key:"113zkx"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Wb=Je("ClipboardList",[["rect",{width:"8",height:"4",x:"8",y:"2",rx:"1",ry:"1",key:"tgr4d6"}],["path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2",key:"116196"}],["path",{d:"M12 11h4",key:"1jrz19"}],["path",{d:"M12 16h4",key:"n85exb"}],["path",{d:"M8 11h.01",key:"1dfujw"}],["path",{d:"M8 16h.01",key:"18s6g9"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Bg=Je("CreditCard",[["rect",{width:"20",height:"14",x:"2",y:"5",rx:"2",key:"ynyp8z"}],["line",{x1:"2",x2:"22",y1:"10",y2:"10",key:"1b3vmo"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Ug=Je("Delete",[["path",{d:"M10 5a2 2 0 0 0-1.344.519l-6.328 5.74a1 1 0 0 0 0 1.481l6.328 5.741A2 2 0 0 0 10 19h10a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2z",key:"1yo7s0"}],["path",{d:"m12 9 6 6",key:"anjzzh"}],["path",{d:"m18 9-6 6",key:"1fp51s"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Hb=Je("Minus",[["path",{d:"M5 12h14",key:"1ays0h"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Vb=Je("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Qb=Je("PrinterCheck",[["path",{d:"M13.5 22H7a1 1 0 0 1-1-1v-6a1 1 0 0 1 1-1h10a1 1 0 0 1 1 1v.5",key:"qeb09x"}],["path",{d:"m16 19 2 2 4-4",key:"1b14m6"}],["path",{d:"M6 18H4a2 2 0 0 1-2-2v-5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v2",key:"1md90i"}],["path",{d:"M6 9V3a1 1 0 0 1 1-1h10a1 1 0 0 1 1 1v6",key:"1itne7"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Gb=Je("Printer",[["path",{d:"M6 18H4a2 2 0 0 1-2-2v-5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v5a2 2 0 0 1-2 2h-2",key:"143wyd"}],["path",{d:"M6 9V3a1 1 0 0 1 1-1h10a1 1 0 0 1 1 1v6",key:"1itne7"}],["rect",{x:"6",y:"14",width:"12",height:"8",rx:"1",key:"1ue0tg"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Kb=Je("Settings2",[["path",{d:"M20 7h-9",key:"3s1dr2"}],["path",{d:"M14 17H5",key:"gfn3mx"}],["circle",{cx:"17",cy:"17",r:"3",key:"18b49y"}],["circle",{cx:"7",cy:"7",r:"3",key:"dfmy0x"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Yb=Je("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const ep=Je("ShoppingCart",[["circle",{cx:"8",cy:"21",r:"1",key:"jimo8o"}],["circle",{cx:"19",cy:"21",r:"1",key:"13723u"}],["path",{d:"M2.05 2.05h2l2.66 12.42a2 2 0 0 0 2 1.58h9.78a2 2 0 0 0 1.95-1.57l1.65-7.43H5.12",key:"9zh506"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const qb=Je("Store",[["path",{d:"m2 7 4.41-4.41A2 2 0 0 1 7.83 2h8.34a2 2 0 0 1 1.42.59L22 7",key:"ztvudi"}],["path",{d:"M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8",key:"1b2hhj"}],["path",{d:"M15 22v-4a2 2 0 0 0-2-2h-2a2 2 0 0 0-2 2v4",key:"2ebpfo"}],["path",{d:"M2 7h20",key:"1fcdvo"}],["path",{d:"M22 7v3a2 2 0 0 1-2 2a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 16 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 12 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 8 12a2.7 2.7 0 0 1-1.59-.63.7.7 0 0 0-.82 0A2.7 2.7 0 0 1 4 12a2 2 0 0 1-2-2V7",key:"6c3vgh"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Xb=Je("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]);/**
* @license lucide-react v0.462.0 - ISC
*
* This source code is licensed under the ISC license.
* See the LICENSE file in the root directory of this source tree.
*/const Wg=Je("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),Xc="-",Zb=e=>{const t=eS(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:i=>{const a=i.split(Xc);return a[0]===""&&a.length!==1&&a.shift(),Hg(a,t)||Jb(i)},getConflictingClassGroupIds:(i,a)=>{const l=n[i]||[];return a&&r[i]?[...l,...r[i]]:l}}},Hg=(e,t)=>{var i;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),o=r?Hg(e.slice(1),r):void 0;if(o)return o;if(t.validators.length===0)return;const s=e.join(Xc);return(i=t.validators.find(({validator:a})=>a(s)))==null?void 0:i.classGroupId},tp=/^\[(.+)\]$/,Jb=e=>{if(tp.test(e)){const t=tp.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},eS=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return nS(Object.entries(e.classGroups),n).forEach(([s,i])=>{zu(i,r,s,t)}),r},zu=(e,t,n,r)=>{e.forEach(o=>{if(typeof o=="string"){const s=o===""?t:np(t,o);s.classGroupId=n;return}if(typeof o=="function"){if(tS(o)){zu(o(r),t,n,r);return}t.validators.push({validator:o,classGroupId:n});return}Object.entries(o).forEach(([s,i])=>{zu(i,np(t,s),n,r)})})},np=(e,t)=>{let n=e;return t.split(Xc).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},tS=e=>e.isThemeGetter,nS=(e,t)=>t?e.map(([n,r])=>{const o=r.map(s=>typeof s=="string"?t+s:typeof s=="object"?Object.fromEntries(Object.entries(s).map(([i,a])=>[t+i,a])):s);return[n,o]}):e,rS=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const o=(s,i)=>{n.set(s,i),t++,t>e&&(t=0,r=n,n=new Map)};return{get(s){let i=n.get(s);if(i!==void 0)return i;if((i=r.get(s))!==void 0)return o(s,i),i},set(s,i){n.has(s)?n.set(s,i):o(s,i)}}},Vg="!",oS=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,o=t[0],s=t.length,i=a=>{const l=[];let u=0,d=0,p;for(let x=0;x<a.length;x++){let h=a[x];if(u===0){if(h===o&&(r||a.slice(x,x+s)===t)){l.push(a.slice(d,x)),d=x+s;continue}if(h==="/"){p=x;continue}}h==="["?u++:h==="]"&&u--}const y=l.length===0?a:a.substring(d),f=y.startsWith(Vg),b=f?y.substring(1):y,g=p&&p>d?p-d:void 0;return{modifiers:l,hasImportantModifier:f,baseClassName:b,maybePostfixModifierPosition:g}};return n?a=>n({className:a,parseClassName:i}):i},sS=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(r=>{r[0]==="["?(t.push(...n.sort(),r),n=[]):n.push(r)}),t.push(...n.sort()),t},iS=e=>({cache:rS(e.cacheSize),parseClassName:oS(e),...Zb(e)}),aS=/\s+/,lS=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o}=t,s=[],i=e.trim().split(aS);let a="";for(let l=i.length-1;l>=0;l-=1){const u=i[l],{modifiers:d,hasImportantModifier:p,baseClassName:y,maybePostfixModifierPosition:f}=n(u);let b=!!f,g=r(b?y.substring(0,f):y);if(!g){if(!b){a=u+(a.length>0?" "+a:a);continue}if(g=r(y),!g){a=u+(a.length>0?" "+a:a);continue}b=!1}const x=sS(d).join(":"),h=p?x+Vg:x,m=h+g;if(s.includes(m))continue;s.push(m);const w=o(g,b);for(let S=0;S<w.length;++S){const C=w[S];s.push(h+C)}a=u+(a.length>0?" "+a:a)}return a};function uS(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=Qg(t))&&(r&&(r+=" "),r+=n);return r}const Qg=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=Qg(e[r]))&&(n&&(n+=" "),n+=t);return n};function cS(e,...t){let n,r,o,s=i;function i(l){const u=t.reduce((d,p)=>p(d),e());return n=iS(u),r=n.cache.get,o=n.cache.set,s=a,a(l)}function a(l){const u=r(l);if(u)return u;const d=lS(l,n);return o(l,d),d}return function(){return s(uS.apply(null,arguments))}}const oe=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},Gg=/^\[(?:([a-z-]+):)?(.+)\]$/i,dS=/^\d+\/\d+$/,fS=new Set(["px","full","screen"]),pS=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,hS=/\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$/,mS=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,gS=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,vS=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Yt=e=>eo(e)||fS.has(e)||dS.test(e),wn=e=>ko(e,"length",kS),eo=e=>!!e&&!Number.isNaN(Number(e)),Cl=e=>ko(e,"number",eo),Fo=e=>!!e&&Number.isInteger(Number(e)),yS=e=>e.endsWith("%")&&eo(e.slice(0,-1)),K=e=>Gg.test(e),bn=e=>pS.test(e),xS=new Set(["length","size","percentage"]),wS=e=>ko(e,xS,Kg),bS=e=>ko(e,"position",Kg),SS=new Set(["image","url"]),CS=e=>ko(e,SS,TS),ES=e=>ko(e,"",NS),$o=()=>!0,ko=(e,t,n)=>{const r=Gg.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},kS=e=>hS.test(e)&&!mS.test(e),Kg=()=>!1,NS=e=>gS.test(e),TS=e=>vS.test(e),PS=()=>{const e=oe("colors"),t=oe("spacing"),n=oe("blur"),r=oe("brightness"),o=oe("borderColor"),s=oe("borderRadius"),i=oe("borderSpacing"),a=oe("borderWidth"),l=oe("contrast"),u=oe("grayscale"),d=oe("hueRotate"),p=oe("invert"),y=oe("gap"),f=oe("gradientColorStops"),b=oe("gradientColorStopPositions"),g=oe("inset"),x=oe("margin"),h=oe("opacity"),m=oe("padding"),w=oe("saturate"),S=oe("scale"),C=oe("sepia"),N=oe("skew"),E=oe("space"),R=oe("translate"),D=()=>["auto","contain","none"],L=()=>["auto","hidden","clip","visible","scroll"],W=()=>["auto",K,t],$=()=>[K,t],V=()=>["",Yt,wn],F=()=>["auto",eo,K],I=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],T=()=>["solid","dashed","dotted","double","none"],O=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],k=()=>["start","end","center","between","around","evenly","stretch"],P=()=>["","0",K],A=()=>["auto","avoid","all","avoid-page","page","left","right","column"],U=()=>[eo,K];return{cacheSize:500,separator:":",theme:{colors:[$o],spacing:[Yt,wn],blur:["none","",bn,K],brightness:U(),borderColor:[e],borderRadius:["none","","full",bn,K],borderSpacing:$(),borderWidth:V(),contrast:U(),grayscale:P(),hueRotate:U(),invert:P(),gap:$(),gradientColorStops:[e],gradientColorStopPositions:[yS,wn],inset:W(),margin:W(),opacity:U(),padding:$(),saturate:U(),scale:U(),sepia:P(),skew:U(),space:$(),translate:$()},classGroups:{aspect:[{aspect:["auto","square","video",K]}],container:["container"],columns:[{columns:[bn]}],"break-after":[{"break-after":A()}],"break-before":[{"break-before":A()}],"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:[...I(),K]}],overflow:[{overflow:L()}],"overflow-x":[{"overflow-x":L()}],"overflow-y":[{"overflow-y":L()}],overscroll:[{overscroll:D()}],"overscroll-x":[{"overscroll-x":D()}],"overscroll-y":[{"overscroll-y":D()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[g]}],"inset-x":[{"inset-x":[g]}],"inset-y":[{"inset-y":[g]}],start:[{start:[g]}],end:[{end:[g]}],top:[{top:[g]}],right:[{right:[g]}],bottom:[{bottom:[g]}],left:[{left:[g]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Fo,K]}],basis:[{basis:W()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",K]}],grow:[{grow:P()}],shrink:[{shrink:P()}],order:[{order:["first","last","none",Fo,K]}],"grid-cols":[{"grid-cols":[$o]}],"col-start-end":[{col:["auto",{span:["full",Fo,K]},K]}],"col-start":[{"col-start":F()}],"col-end":[{"col-end":F()}],"grid-rows":[{"grid-rows":[$o]}],"row-start-end":[{row:["auto",{span:[Fo,K]},K]}],"row-start":[{"row-start":F()}],"row-end":[{"row-end":F()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",K]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",K]}],gap:[{gap:[y]}],"gap-x":[{"gap-x":[y]}],"gap-y":[{"gap-y":[y]}],"justify-content":[{justify:["normal",...k()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...k(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...k(),"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:[x]}],mx:[{mx:[x]}],my:[{my:[x]}],ms:[{ms:[x]}],me:[{me:[x]}],mt:[{mt:[x]}],mr:[{mr:[x]}],mb:[{mb:[x]}],ml:[{ml:[x]}],"space-x":[{"space-x":[E]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[E]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",K,t]}],"min-w":[{"min-w":[K,t,"min","max","fit"]}],"max-w":[{"max-w":[K,t,"none","full","min","max","fit","prose",{screen:[bn]},bn]}],h:[{h:[K,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[K,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[K,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[K,t,"auto","min","max","fit"]}],"font-size":[{text:["base",bn,wn]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Cl]}],"font-family":[{font:[$o]}],"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",K]}],"line-clamp":[{"line-clamp":["none",eo,Cl]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Yt,K]}],"list-image":[{"list-image":["none",K]}],"list-style-type":[{list:["none","disc","decimal",K]}],"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:[...T(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Yt,wn]}],"underline-offset":[{"underline-offset":["auto",Yt,K]}],"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:$()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",K]}],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",K]}],"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:[...I(),bS]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",wS]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},CS]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[b]}],"gradient-via-pos":[{via:[b]}],"gradient-to-pos":[{to:[b]}],"gradient-from":[{from:[f]}],"gradient-via":[{via:[f]}],"gradient-to":[{to:[f]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-ee":[{"rounded-ee":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tl":[{"rounded-tl":[s]}],"rounded-tr":[{"rounded-tr":[s]}],"rounded-br":[{"rounded-br":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"border-w":[{border:[a]}],"border-w-x":[{"border-x":[a]}],"border-w-y":[{"border-y":[a]}],"border-w-s":[{"border-s":[a]}],"border-w-e":[{"border-e":[a]}],"border-w-t":[{"border-t":[a]}],"border-w-r":[{"border-r":[a]}],"border-w-b":[{"border-b":[a]}],"border-w-l":[{"border-l":[a]}],"border-opacity":[{"border-opacity":[h]}],"border-style":[{border:[...T(),"hidden"]}],"divide-x":[{"divide-x":[a]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[a]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[h]}],"divide-style":[{divide:T()}],"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:["",...T()]}],"outline-offset":[{"outline-offset":[Yt,K]}],"outline-w":[{outline:[Yt,wn]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:V()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[h]}],"ring-offset-w":[{"ring-offset":[Yt,wn]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",bn,ES]}],"shadow-color":[{shadow:[$o]}],opacity:[{opacity:[h]}],"mix-blend":[{"mix-blend":[...O(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":O()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",bn,K]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[p]}],saturate:[{saturate:[w]}],sepia:[{sepia:[C]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"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":[p]}],"backdrop-opacity":[{"backdrop-opacity":[h]}],"backdrop-saturate":[{"backdrop-saturate":[w]}],"backdrop-sepia":[{"backdrop-sepia":[C]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[i]}],"border-spacing-x":[{"border-spacing-x":[i]}],"border-spacing-y":[{"border-spacing-y":[i]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",K]}],duration:[{duration:U()}],ease:[{ease:["linear","in","out","in-out",K]}],delay:[{delay:U()}],animate:[{animate:["none","spin","ping","pulse","bounce",K]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[S]}],"scale-x":[{"scale-x":[S]}],"scale-y":[{"scale-y":[S]}],rotate:[{rotate:[Fo,K]}],"translate-x":[{"translate-x":[R]}],"translate-y":[{"translate-y":[R]}],"skew-x":[{"skew-x":[N]}],"skew-y":[{"skew-y":[N]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",K]}],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",K]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":$()}],"scroll-mx":[{"scroll-mx":$()}],"scroll-my":[{"scroll-my":$()}],"scroll-ms":[{"scroll-ms":$()}],"scroll-me":[{"scroll-me":$()}],"scroll-mt":[{"scroll-mt":$()}],"scroll-mr":[{"scroll-mr":$()}],"scroll-mb":[{"scroll-mb":$()}],"scroll-ml":[{"scroll-ml":$()}],"scroll-p":[{"scroll-p":$()}],"scroll-px":[{"scroll-px":$()}],"scroll-py":[{"scroll-py":$()}],"scroll-ps":[{"scroll-ps":$()}],"scroll-pe":[{"scroll-pe":$()}],"scroll-pt":[{"scroll-pt":$()}],"scroll-pr":[{"scroll-pr":$()}],"scroll-pb":[{"scroll-pb":$()}],"scroll-pl":[{"scroll-pl":$()}],"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",K]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Yt,wn,Cl]}],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"]}}},RS=cS(PS);function we(...e){return RS(Fg(e))}const jS=Fb,Yg=v.forwardRef(({className:e,...t},n)=>c.jsx(Og,{ref:n,className:we("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]",e),...t}));Yg.displayName=Og.displayName;const OS=$b("group pointer-events-auto relative flex w-full items-center justify-between space-x-4 overflow-hidden rounded-md border p-6 pr-8 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",{variants:{variant:{default:"border bg-background text-foreground",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground"}},defaultVariants:{variant:"default"}}),qg=v.forwardRef(({className:e,variant:t,...n},r)=>c.jsx(_g,{ref:r,className:we(OS({variant:t}),e),...n}));qg.displayName=_g.displayName;const _S=v.forwardRef(({className:e,...t},n)=>c.jsx(Mg,{ref:n,className:we("inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium ring-offset-background transition-colors group-[.destructive]:border-muted/40 hover:bg-secondary group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 group-[.destructive]:focus:ring-destructive disabled:pointer-events-none disabled:opacity-50",e),...t}));_S.displayName=Mg.displayName;const Xg=v.forwardRef(({className:e,...t},n)=>c.jsx(Lg,{ref:n,className:we("absolute right-2 top-2 rounded-md p-1 text-foreground/50 opacity-0 transition-opacity group-hover:opacity-100 group-[.destructive]:text-red-300 hover:text-foreground group-[.destructive]:hover:text-red-50 focus:opacity-100 focus:outline-none focus:ring-2 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",e),"toast-close":"",...t,children:c.jsx(Wg,{className:"h-4 w-4"})}));Xg.displayName=Lg.displayName;const Zg=v.forwardRef(({className:e,...t},n)=>c.jsx(Ag,{ref:n,className:we("text-sm font-semibold",e),...t}));Zg.displayName=Ag.displayName;const Jg=v.forwardRef(({className:e,...t},n)=>c.jsx(Dg,{ref:n,className:we("text-sm opacity-90",e),...t}));Jg.displayName=Dg.displayName;function AS(){const{toasts:e}=Qw();return c.jsxs(jS,{children:[e.map(function({id:t,title:n,description:r,action:o,...s}){return c.jsxs(qg,{...s,children:[c.jsxs("div",{className:"grid gap-1",children:[n&&c.jsx(Zg,{children:n}),r&&c.jsx(Jg,{children:r})]}),o,c.jsx(Xg,{})]},t)}),c.jsx(Yg,{})]})}var DS=Ju[" useId ".trim().toString()]||(()=>{}),MS=0;function El(e){const[t,n]=v.useState(DS());return un(()=>{e||n(r=>r??String(MS++))},[e]),e||(t?`radix-${t}`:"")}const LS=["top","right","bottom","left"],qn=Math.min,nt=Math.max,na=Math.round,si=Math.floor,Vt=e=>({x:e,y:e}),IS={left:"right",right:"left",bottom:"top",top:"bottom"},FS={start:"end",end:"start"};function Bu(e,t,n){return nt(e,qn(t,n))}function cn(e,t){return typeof e=="function"?e(t):e}function dn(e){return e.split("-")[0]}function No(e){return e.split("-")[1]}function Zc(e){return e==="x"?"y":"x"}function Jc(e){return e==="y"?"height":"width"}const $S=new Set(["top","bottom"]);function Ut(e){return $S.has(dn(e))?"y":"x"}function ed(e){return Zc(Ut(e))}function zS(e,t,n){n===void 0&&(n=!1);const r=No(e),o=ed(e),s=Jc(o);let i=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=ra(i)),[i,ra(i)]}function BS(e){const t=ra(e);return[Uu(e),t,Uu(t)]}function Uu(e){return e.replace(/start|end/g,t=>FS[t])}const rp=["left","right"],op=["right","left"],US=["top","bottom"],WS=["bottom","top"];function HS(e,t,n){switch(e){case"top":case"bottom":return n?t?op:rp:t?rp:op;case"left":case"right":return t?US:WS;default:return[]}}function VS(e,t,n,r){const o=No(e);let s=HS(dn(e),n==="start",r);return o&&(s=s.map(i=>i+"-"+o),t&&(s=s.concat(s.map(Uu)))),s}function ra(e){return e.replace(/left|right|bottom|top/g,t=>IS[t])}function QS(e){return{top:0,right:0,bottom:0,left:0,...e}}function ev(e){return typeof e!="number"?QS(e):{top:e,right:e,bottom:e,left:e}}function oa(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function sp(e,t,n){let{reference:r,floating:o}=e;const s=Ut(t),i=ed(t),a=Jc(i),l=dn(t),u=s==="y",d=r.x+r.width/2-o.width/2,p=r.y+r.height/2-o.height/2,y=r[a]/2-o[a]/2;let f;switch(l){case"top":f={x:d,y:r.y-o.height};break;case"bottom":f={x:d,y:r.y+r.height};break;case"right":f={x:r.x+r.width,y:p};break;case"left":f={x:r.x-o.width,y:p};break;default:f={x:r.x,y:r.y}}switch(No(t)){case"start":f[i]-=y*(n&&u?-1:1);break;case"end":f[i]+=y*(n&&u?-1:1);break}return f}const GS=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:s=[],platform:i}=n,a=s.filter(Boolean),l=await(i.isRTL==null?void 0:i.isRTL(t));let u=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:p}=sp(u,r,l),y=r,f={},b=0;for(let g=0;g<a.length;g++){const{name:x,fn:h}=a[g],{x:m,y:w,data:S,reset:C}=await h({x:d,y:p,initialPlacement:r,placement:y,strategy:o,middlewareData:f,rects:u,platform:i,elements:{reference:e,floating:t}});d=m??d,p=w??p,f={...f,[x]:{...f[x],...S}},C&&b<=50&&(b++,typeof C=="object"&&(C.placement&&(y=C.placement),C.rects&&(u=C.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:o}):C.rects),{x:d,y:p}=sp(u,y,l)),g=-1)}return{x:d,y:p,placement:y,strategy:o,middlewareData:f}};async function ws(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:s,rects:i,elements:a,strategy:l}=e,{boundary:u="clippingAncestors",rootBoundary:d="viewport",elementContext:p="floating",altBoundary:y=!1,padding:f=0}=cn(t,e),b=ev(f),x=a[y?p==="floating"?"reference":"floating":p],h=oa(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(x)))==null||n?x:x.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:u,rootBoundary:d,strategy:l})),m=p==="floating"?{x:r,y:o,width:i.floating.width,height:i.floating.height}:i.reference,w=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),S=await(s.isElement==null?void 0:s.isElement(w))?await(s.getScale==null?void 0:s.getScale(w))||{x:1,y:1}:{x:1,y:1},C=oa(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:m,offsetParent:w,strategy:l}):m);return{top:(h.top-C.top+b.top)/S.y,bottom:(C.bottom-h.bottom+b.bottom)/S.y,left:(h.left-C.left+b.left)/S.x,right:(C.right-h.right+b.right)/S.x}}const KS=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:s,platform:i,elements:a,middlewareData:l}=t,{element:u,padding:d=0}=cn(e,t)||{};if(u==null)return{};const p=ev(d),y={x:n,y:r},f=ed(o),b=Jc(f),g=await i.getDimensions(u),x=f==="y",h=x?"top":"left",m=x?"bottom":"right",w=x?"clientHeight":"clientWidth",S=s.reference[b]+s.reference[f]-y[f]-s.floating[b],C=y[f]-s.reference[f],N=await(i.getOffsetParent==null?void 0:i.getOffsetParent(u));let E=N?N[w]:0;(!E||!await(i.isElement==null?void 0:i.isElement(N)))&&(E=a.floating[w]||s.floating[b]);const R=S/2-C/2,D=E/2-g[b]/2-1,L=qn(p[h],D),W=qn(p[m],D),$=L,V=E-g[b]-W,F=E/2-g[b]/2+R,I=Bu($,F,V),T=!l.arrow&&No(o)!=null&&F!==I&&s.reference[b]/2-(F<$?L:W)-g[b]/2<0,O=T?F<$?F-$:F-V:0;return{[f]:y[f]+O,data:{[f]:I,centerOffset:F-I-O,...T&&{alignmentOffset:O}},reset:T}}}),YS=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:s,rects:i,initialPlacement:a,platform:l,elements:u}=t,{mainAxis:d=!0,crossAxis:p=!0,fallbackPlacements:y,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:g=!0,...x}=cn(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const h=dn(o),m=Ut(a),w=dn(a)===a,S=await(l.isRTL==null?void 0:l.isRTL(u.floating)),C=y||(w||!g?[ra(a)]:BS(a)),N=b!=="none";!y&&N&&C.push(...VS(a,g,b,S));const E=[a,...C],R=await ws(t,x),D=[];let L=((r=s.flip)==null?void 0:r.overflows)||[];if(d&&D.push(R[h]),p){const F=zS(o,i,S);D.push(R[F[0]],R[F[1]])}if(L=[...L,{placement:o,overflows:D}],!D.every(F=>F<=0)){var W,$;const F=(((W=s.flip)==null?void 0:W.index)||0)+1,I=E[F];if(I&&(!(p==="alignment"?m!==Ut(I):!1)||L.every(k=>k.overflows[0]>0&&Ut(k.placement)===m)))return{data:{index:F,overflows:L},reset:{placement:I}};let T=($=L.filter(O=>O.overflows[0]<=0).sort((O,k)=>O.overflows[1]-k.overflows[1])[0])==null?void 0:$.placement;if(!T)switch(f){case"bestFit":{var V;const O=(V=L.filter(k=>{if(N){const P=Ut(k.placement);return P===m||P==="y"}return!0}).map(k=>[k.placement,k.overflows.filter(P=>P>0).reduce((P,A)=>P+A,0)]).sort((k,P)=>k[1]-P[1])[0])==null?void 0:V[0];O&&(T=O);break}case"initialPlacement":T=a;break}if(o!==T)return{reset:{placement:T}}}return{}}}};function ip(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function ap(e){return LS.some(t=>e[t]>=0)}const qS=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=cn(e,t);switch(r){case"referenceHidden":{const s=await ws(t,{...o,elementContext:"reference"}),i=ip(s,n.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:ap(i)}}}case"escaped":{const s=await ws(t,{...o,altBoundary:!0}),i=ip(s,n.floating);return{data:{escapedOffsets:i,escaped:ap(i)}}}default:return{}}}}},tv=new Set(["left","top"]);async function XS(e,t){const{placement:n,platform:r,elements:o}=e,s=await(r.isRTL==null?void 0:r.isRTL(o.floating)),i=dn(n),a=No(n),l=Ut(n)==="y",u=tv.has(i)?-1:1,d=s&&l?-1:1,p=cn(t,e);let{mainAxis:y,crossAxis:f,alignmentAxis:b}=typeof p=="number"?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return a&&typeof b=="number"&&(f=a==="end"?b*-1:b),l?{x:f*d,y:y*u}:{x:y*u,y:f*d}}const ZS=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:s,placement:i,middlewareData:a}=t,l=await XS(t,e);return i===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:o+l.x,y:s+l.y,data:{...l,placement:i}}}}},JS=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:s=!0,crossAxis:i=!1,limiter:a={fn:x=>{let{x:h,y:m}=x;return{x:h,y:m}}},...l}=cn(e,t),u={x:n,y:r},d=await ws(t,l),p=Ut(dn(o)),y=Zc(p);let f=u[y],b=u[p];if(s){const x=y==="y"?"top":"left",h=y==="y"?"bottom":"right",m=f+d[x],w=f-d[h];f=Bu(m,f,w)}if(i){const x=p==="y"?"top":"left",h=p==="y"?"bottom":"right",m=b+d[x],w=b-d[h];b=Bu(m,b,w)}const g=a.fn({...t,[y]:f,[p]:b});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[y]:s,[p]:i}}}}}},eC=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:s,middlewareData:i}=t,{offset:a=0,mainAxis:l=!0,crossAxis:u=!0}=cn(e,t),d={x:n,y:r},p=Ut(o),y=Zc(p);let f=d[y],b=d[p];const g=cn(a,t),x=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(l){const w=y==="y"?"height":"width",S=s.reference[y]-s.floating[w]+x.mainAxis,C=s.reference[y]+s.reference[w]-x.mainAxis;f<S?f=S:f>C&&(f=C)}if(u){var h,m;const w=y==="y"?"width":"height",S=tv.has(dn(o)),C=s.reference[p]-s.floating[w]+(S&&((h=i.offset)==null?void 0:h[p])||0)+(S?0:x.crossAxis),N=s.reference[p]+s.reference[w]+(S?0:((m=i.offset)==null?void 0:m[p])||0)-(S?x.crossAxis:0);b<C?b=C:b>N&&(b=N)}return{[y]:f,[p]:b}}}},tC=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:s,platform:i,elements:a}=t,{apply:l=()=>{},...u}=cn(e,t),d=await ws(t,u),p=dn(o),y=No(o),f=Ut(o)==="y",{width:b,height:g}=s.floating;let x,h;p==="top"||p==="bottom"?(x=p,h=y===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?"start":"end")?"left":"right"):(h=p,x=y==="end"?"top":"bottom");const m=g-d.top-d.bottom,w=b-d.left-d.right,S=qn(g-d[x],m),C=qn(b-d[h],w),N=!t.middlewareData.shift;let E=S,R=C;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(R=w),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(E=m),N&&!y){const L=nt(d.left,0),W=nt(d.right,0),$=nt(d.top,0),V=nt(d.bottom,0);f?R=b-2*(L!==0||W!==0?L+W:nt(d.left,d.right)):E=g-2*($!==0||V!==0?$+V:nt(d.top,d.bottom))}await l({...t,availableWidth:R,availableHeight:E});const D=await i.getDimensions(a.floating);return b!==D.width||g!==D.height?{reset:{rects:!0}}:{}}}};function _a(){return typeof window<"u"}function To(e){return nv(e)?(e.nodeName||"").toLowerCase():"#document"}function st(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Kt(e){var t;return(t=(nv(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function nv(e){return _a()?e instanceof Node||e instanceof st(e).Node:!1}function Ot(e){return _a()?e instanceof Element||e instanceof st(e).Element:!1}function Gt(e){return _a()?e instanceof HTMLElement||e instanceof st(e).HTMLElement:!1}function lp(e){return!_a()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof st(e).ShadowRoot}const nC=new Set(["inline","contents"]);function As(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=_t(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!nC.has(o)}const rC=new Set(["table","td","th"]);function oC(e){return rC.has(To(e))}const sC=[":popover-open",":modal"];function Aa(e){return sC.some(t=>{try{return e.matches(t)}catch{return!1}})}const iC=["transform","translate","scale","rotate","perspective"],aC=["transform","translate","scale","rotate","perspective","filter"],lC=["paint","layout","strict","content"];function td(e){const t=nd(),n=Ot(e)?_t(e):e;return iC.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||aC.some(r=>(n.willChange||"").includes(r))||lC.some(r=>(n.contain||"").includes(r))}function uC(e){let t=Xn(e);for(;Gt(t)&&!xo(t);){if(td(t))return t;if(Aa(t))return null;t=Xn(t)}return null}function nd(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const cC=new Set(["html","body","#document"]);function xo(e){return cC.has(To(e))}function _t(e){return st(e).getComputedStyle(e)}function Da(e){return Ot(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Xn(e){if(To(e)==="html")return e;const t=e.assignedSlot||e.parentNode||lp(e)&&e.host||Kt(e);return lp(t)?t.host:t}function rv(e){const t=Xn(e);return xo(t)?e.ownerDocument?e.ownerDocument.body:e.body:Gt(t)&&As(t)?t:rv(t)}function bs(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=rv(e),s=o===((r=e.ownerDocument)==null?void 0:r.body),i=st(o);if(s){const a=Wu(i);return t.concat(i,i.visualViewport||[],As(o)?o:[],a&&n?bs(a):[])}return t.concat(o,bs(o,[],n))}function Wu(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function ov(e){const t=_t(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Gt(e),s=o?e.offsetWidth:n,i=o?e.offsetHeight:r,a=na(n)!==s||na(r)!==i;return a&&(n=s,r=i),{width:n,height:r,$:a}}function rd(e){return Ot(e)?e:e.contextElement}function to(e){const t=rd(e);if(!Gt(t))return Vt(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:s}=ov(t);let i=(s?na(n.width):n.width)/r,a=(s?na(n.height):n.height)/o;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const dC=Vt(0);function sv(e){const t=st(e);return!nd()||!t.visualViewport?dC:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function fC(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==st(e)?!1:t}function Sr(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),s=rd(e);let i=Vt(1);t&&(r?Ot(r)&&(i=to(r)):i=to(e));const a=fC(s,n,r)?sv(s):Vt(0);let l=(o.left+a.x)/i.x,u=(o.top+a.y)/i.y,d=o.width/i.x,p=o.height/i.y;if(s){const y=st(s),f=r&&Ot(r)?st(r):r;let b=y,g=Wu(b);for(;g&&r&&f!==b;){const x=to(g),h=g.getBoundingClientRect(),m=_t(g),w=h.left+(g.clientLeft+parseFloat(m.paddingLeft))*x.x,S=h.top+(g.clientTop+parseFloat(m.paddingTop))*x.y;l*=x.x,u*=x.y,d*=x.x,p*=x.y,l+=w,u+=S,b=st(g),g=Wu(b)}}return oa({width:d,height:p,x:l,y:u})}function od(e,t){const n=Da(e).scrollLeft;return t?t.left+n:Sr(Kt(e)).left+n}function iv(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-(n?0:od(e,r)),s=r.top+t.scrollTop;return{x:o,y:s}}function pC(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const s=o==="fixed",i=Kt(r),a=t?Aa(t.floating):!1;if(r===i||a&&s)return n;let l={scrollLeft:0,scrollTop:0},u=Vt(1);const d=Vt(0),p=Gt(r);if((p||!p&&!s)&&((To(r)!=="body"||As(i))&&(l=Da(r)),Gt(r))){const f=Sr(r);u=to(r),d.x=f.x+r.clientLeft,d.y=f.y+r.clientTop}const y=i&&!p&&!s?iv(i,l,!0):Vt(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-l.scrollLeft*u.x+d.x+y.x,y:n.y*u.y-l.scrollTop*u.y+d.y+y.y}}function hC(e){return Array.from(e.getClientRects())}function mC(e){const t=Kt(e),n=Da(e),r=e.ownerDocument.body,o=nt(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=nt(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+od(e);const a=-n.scrollTop;return _t(r).direction==="rtl"&&(i+=nt(t.clientWidth,r.clientWidth)-o),{width:o,height:s,x:i,y:a}}function gC(e,t){const n=st(e),r=Kt(e),o=n.visualViewport;let s=r.clientWidth,i=r.clientHeight,a=0,l=0;if(o){s=o.width,i=o.height;const u=nd();(!u||u&&t==="fixed")&&(a=o.offsetLeft,l=o.offsetTop)}return{width:s,height:i,x:a,y:l}}const vC=new Set(["absolute","fixed"]);function yC(e,t){const n=Sr(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,s=Gt(e)?to(e):Vt(1),i=e.clientWidth*s.x,a=e.clientHeight*s.y,l=o*s.x,u=r*s.y;return{width:i,height:a,x:l,y:u}}function up(e,t,n){let r;if(t==="viewport")r=gC(e,n);else if(t==="document")r=mC(Kt(e));else if(Ot(t))r=yC(t,n);else{const o=sv(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return oa(r)}function av(e,t){const n=Xn(e);return n===t||!Ot(n)||xo(n)?!1:_t(n).position==="fixed"||av(n,t)}function xC(e,t){const n=t.get(e);if(n)return n;let r=bs(e,[],!1).filter(a=>Ot(a)&&To(a)!=="body"),o=null;const s=_t(e).position==="fixed";let i=s?Xn(e):e;for(;Ot(i)&&!xo(i);){const a=_t(i),l=td(i);!l&&a.position==="fixed"&&(o=null),(s?!l&&!o:!l&&a.position==="static"&&!!o&&vC.has(o.position)||As(i)&&!l&&av(e,i))?r=r.filter(d=>d!==i):o=a,i=Xn(i)}return t.set(e,r),r}function wC(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=[...n==="clippingAncestors"?Aa(t)?[]:xC(t,this._c):[].concat(n),r],a=i[0],l=i.reduce((u,d)=>{const p=up(t,d,o);return u.top=nt(p.top,u.top),u.right=qn(p.right,u.right),u.bottom=qn(p.bottom,u.bottom),u.left=nt(p.left,u.left),u},up(t,a,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function bC(e){const{width:t,height:n}=ov(e);return{width:t,height:n}}function SC(e,t,n){const r=Gt(t),o=Kt(t),s=n==="fixed",i=Sr(e,!0,s,t);let a={scrollLeft:0,scrollTop:0};const l=Vt(0);function u(){l.x=od(o)}if(r||!r&&!s)if((To(t)!=="body"||As(o))&&(a=Da(t)),r){const f=Sr(t,!0,s,t);l.x=f.x+t.clientLeft,l.y=f.y+t.clientTop}else o&&u();s&&!r&&o&&u();const d=o&&!r&&!s?iv(o,a):Vt(0),p=i.left+a.scrollLeft-l.x-d.x,y=i.top+a.scrollTop-l.y-d.y;return{x:p,y,width:i.width,height:i.height}}function kl(e){return _t(e).position==="static"}function cp(e,t){if(!Gt(e)||_t(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Kt(e)===n&&(n=n.ownerDocument.body),n}function lv(e,t){const n=st(e);if(Aa(e))return n;if(!Gt(e)){let o=Xn(e);for(;o&&!xo(o);){if(Ot(o)&&!kl(o))return o;o=Xn(o)}return n}let r=cp(e,t);for(;r&&oC(r)&&kl(r);)r=cp(r,t);return r&&xo(r)&&kl(r)&&!td(r)?n:r||uC(e)||n}const CC=async function(e){const t=this.getOffsetParent||lv,n=this.getDimensions,r=await n(e.floating);return{reference:SC(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function EC(e){return _t(e).direction==="rtl"}const kC={convertOffsetParentRelativeRectToViewportRelativeRect:pC,getDocumentElement:Kt,getClippingRect:wC,getOffsetParent:lv,getElementRects:CC,getClientRects:hC,getDimensions:bC,getScale:to,isElement:Ot,isRTL:EC};function uv(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function NC(e,t){let n=null,r;const o=Kt(e);function s(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function i(a,l){a===void 0&&(a=!1),l===void 0&&(l=1),s();const u=e.getBoundingClientRect(),{left:d,top:p,width:y,height:f}=u;if(a||t(),!y||!f)return;const b=si(p),g=si(o.clientWidth-(d+y)),x=si(o.clientHeight-(p+f)),h=si(d),w={rootMargin:-b+"px "+-g+"px "+-x+"px "+-h+"px",threshold:nt(0,qn(1,l))||1};let S=!0;function C(N){const E=N[0].intersectionRatio;if(E!==l){if(!S)return i();E?i(!1,E):r=setTimeout(()=>{i(!1,1e-7)},1e3)}E===1&&!uv(u,e.getBoundingClientRect())&&i(),S=!1}try{n=new IntersectionObserver(C,{...w,root:o.ownerDocument})}catch{n=new IntersectionObserver(C,w)}n.observe(e)}return i(!0),s}function TC(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,u=rd(e),d=o||s?[...u?bs(u):[],...bs(t)]:[];d.forEach(h=>{o&&h.addEventListener("scroll",n,{passive:!0}),s&&h.addEventListener("resize",n)});const p=u&&a?NC(u,n):null;let y=-1,f=null;i&&(f=new ResizeObserver(h=>{let[m]=h;m&&m.target===u&&f&&(f.unobserve(t),cancelAnimationFrame(y),y=requestAnimationFrame(()=>{var w;(w=f)==null||w.observe(t)})),n()}),u&&!l&&f.observe(u),f.observe(t));let b,g=l?Sr(e):null;l&&x();function x(){const h=Sr(e);g&&!uv(g,h)&&n(),g=h,b=requestAnimationFrame(x)}return n(),()=>{var h;d.forEach(m=>{o&&m.removeEventListener("scroll",n),s&&m.removeEventListener("resize",n)}),p==null||p(),(h=f)==null||h.disconnect(),f=null,l&&cancelAnimationFrame(b)}}const PC=ZS,RC=JS,jC=YS,OC=tC,_C=qS,dp=KS,AC=eC,DC=(e,t,n)=>{const r=new Map,o={platform:kC,...n},s={...o.platform,_c:r};return GS(e,t,{...o,platform:s})};var MC=typeof document<"u",LC=function(){},Ei=MC?v.useLayoutEffect:LC;function sa(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!sa(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const s=o[r];if(!(s==="_owner"&&e.$$typeof)&&!sa(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function cv(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function fp(e,t){const n=cv(e);return Math.round(t*n)/n}function Nl(e){const t=v.useRef(e);return Ei(()=>{t.current=e}),t}function IC(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:s,floating:i}={},transform:a=!0,whileElementsMounted:l,open:u}=e,[d,p]=v.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[y,f]=v.useState(r);sa(y,r)||f(r);const[b,g]=v.useState(null),[x,h]=v.useState(null),m=v.useCallback(k=>{k!==N.current&&(N.current=k,g(k))},[]),w=v.useCallback(k=>{k!==E.current&&(E.current=k,h(k))},[]),S=s||b,C=i||x,N=v.useRef(null),E=v.useRef(null),R=v.useRef(d),D=l!=null,L=Nl(l),W=Nl(o),$=Nl(u),V=v.useCallback(()=>{if(!N.current||!E.current)return;const k={placement:t,strategy:n,middleware:y};W.current&&(k.platform=W.current),DC(N.current,E.current,k).then(P=>{const A={...P,isPositioned:$.current!==!1};F.current&&!sa(R.current,A)&&(R.current=A,js.flushSync(()=>{p(A)}))})},[y,t,n,W,$]);Ei(()=>{u===!1&&R.current.isPositioned&&(R.current.isPositioned=!1,p(k=>({...k,isPositioned:!1})))},[u]);const F=v.useRef(!1);Ei(()=>(F.current=!0,()=>{F.current=!1}),[]),Ei(()=>{if(S&&(N.current=S),C&&(E.current=C),S&&C){if(L.current)return L.current(S,C,V);V()}},[S,C,V,L,D]);const I=v.useMemo(()=>({reference:N,floating:E,setReference:m,setFloating:w}),[m,w]),T=v.useMemo(()=>({reference:S,floating:C}),[S,C]),O=v.useMemo(()=>{const k={position:n,left:0,top:0};if(!T.floating)return k;const P=fp(T.floating,d.x),A=fp(T.floating,d.y);return a?{...k,transform:"translate("+P+"px, "+A+"px)",...cv(T.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:P,top:A}},[n,a,T.floating,d.x,d.y]);return v.useMemo(()=>({...d,update:V,refs:I,elements:T,floatingStyles:O}),[d,V,I,T,O])}const FC=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?dp({element:r.current,padding:o}).fn(n):{}:r?dp({element:r,padding:o}).fn(n):{}}}},$C=(e,t)=>({...PC(e),options:[e,t]}),zC=(e,t)=>({...RC(e),options:[e,t]}),BC=(e,t)=>({...AC(e),options:[e,t]}),UC=(e,t)=>({...jC(e),options:[e,t]}),WC=(e,t)=>({...OC(e),options:[e,t]}),HC=(e,t)=>({..._C(e),options:[e,t]}),VC=(e,t)=>({...FC(e),options:[e,t]});var QC="Arrow",dv=v.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...s}=e;return c.jsx(xe.svg,{...s,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:c.jsx("polygon",{points:"0,0 30,0 15,10"})})});dv.displayName=QC;var GC=dv;function KC(e){const[t,n]=v.useState(void 0);return un(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const s=o[0];let i,a;if("borderBoxSize"in s){const l=s.borderBoxSize,u=Array.isArray(l)?l[0]:l;i=u.inlineSize,a=u.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var fv="Popper",[pv,hv]=Os(fv),[yk,mv]=pv(fv),gv="PopperAnchor",vv=v.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,s=mv(gv,n),i=v.useRef(null),a=Be(t,i);return v.useEffect(()=>{s.onAnchorChange((r==null?void 0:r.current)||i.current)}),r?null:c.jsx(xe.div,{...o,ref:a})});vv.displayName=gv;var sd="PopperContent",[YC,qC]=pv(sd),yv=v.forwardRef((e,t)=>{var J,hn,X,ae,Dt,Nr;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:s="center",alignOffset:i=0,arrowPadding:a=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:d=0,sticky:p="partial",hideWhenDetached:y=!1,updatePositionStrategy:f="optimized",onPlaced:b,...g}=e,x=mv(sd,n),[h,m]=v.useState(null),w=Be(t,mn=>m(mn)),[S,C]=v.useState(null),N=KC(S),E=(N==null?void 0:N.width)??0,R=(N==null?void 0:N.height)??0,D=r+(s!=="center"?"-"+s:""),L=typeof d=="number"?d:{top:0,right:0,bottom:0,left:0,...d},W=Array.isArray(u)?u:[u],$=W.length>0,V={padding:L,boundary:W.filter(ZC),altBoundary:$},{refs:F,floatingStyles:I,placement:T,isPositioned:O,middlewareData:k}=IC({strategy:"fixed",placement:D,whileElementsMounted:(...mn)=>TC(...mn,{animationFrame:f==="always"}),elements:{reference:x.anchor},middleware:[$C({mainAxis:o+R,alignmentAxis:i}),l&&zC({mainAxis:!0,crossAxis:!1,limiter:p==="partial"?BC():void 0,...V}),l&&UC({...V}),WC({...V,apply:({elements:mn,rects:Ds,availableWidth:Ua,availableHeight:Ms})=>{const{width:Wa,height:Po}=Ds.reference,Tr=mn.floating.style;Tr.setProperty("--radix-popper-available-width",`${Ua}px`),Tr.setProperty("--radix-popper-available-height",`${Ms}px`),Tr.setProperty("--radix-popper-anchor-width",`${Wa}px`),Tr.setProperty("--radix-popper-anchor-height",`${Po}px`)}}),S&&VC({element:S,padding:a}),JC({arrowWidth:E,arrowHeight:R}),y&&HC({strategy:"referenceHidden",...V})]}),[P,A]=bv(T),U=Qt(b);un(()=>{O&&(U==null||U())},[O,U]);const z=(J=k.arrow)==null?void 0:J.x,H=(hn=k.arrow)==null?void 0:hn.y,Y=((X=k.arrow)==null?void 0:X.centerOffset)!==0,[he,Ce]=v.useState();return un(()=>{h&&Ce(window.getComputedStyle(h).zIndex)},[h]),c.jsx("div",{ref:F.setFloating,"data-radix-popper-content-wrapper":"",style:{...I,transform:O?I.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:he,"--radix-popper-transform-origin":[(ae=k.transformOrigin)==null?void 0:ae.x,(Dt=k.transformOrigin)==null?void 0:Dt.y].join(" "),...((Nr=k.hide)==null?void 0:Nr.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:c.jsx(YC,{scope:n,placedSide:P,onArrowChange:C,arrowX:z,arrowY:H,shouldHideArrow:Y,children:c.jsx(xe.div,{"data-side":P,"data-align":A,...g,ref:w,style:{...g.style,animation:O?void 0:"none"}})})})});yv.displayName=sd;var xv="PopperArrow",XC={top:"bottom",right:"left",bottom:"top",left:"right"},wv=v.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,s=qC(xv,r),i=XC[s.placedSide];return c.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[i]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:c.jsx(GC,{...o,ref:n,style:{...o.style,display:"block"}})})});wv.displayName=xv;function ZC(e){return e!==null}var JC=e=>({name:"transformOrigin",options:e,fn(t){var x,h,m;const{placement:n,rects:r,middlewareData:o}=t,i=((x=o.arrow)==null?void 0:x.centerOffset)!==0,a=i?0:e.arrowWidth,l=i?0:e.arrowHeight,[u,d]=bv(n),p={start:"0%",center:"50%",end:"100%"}[d],y=(((h=o.arrow)==null?void 0:h.x)??0)+a/2,f=(((m=o.arrow)==null?void 0:m.y)??0)+l/2;let b="",g="";return u==="bottom"?(b=i?p:`${y}px`,g=`${-l}px`):u==="top"?(b=i?p:`${y}px`,g=`${r.floating.height+l}px`):u==="right"?(b=`${-l}px`,g=i?p:`${f}px`):u==="left"&&(b=`${r.floating.width+l}px`,g=i?p:`${f}px`),{data:{x:b,y:g}}}});function bv(e){const[t,n="center"]=e.split("-");return[t,n]}var e2=vv,t2=yv,n2=wv,[Ma,xk]=Os("Tooltip",[hv]),id=hv(),Sv="TooltipProvider",r2=700,pp="tooltip.open",[o2,Cv]=Ma(Sv),Ev=e=>{const{__scopeTooltip:t,delayDuration:n=r2,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:s}=e,i=v.useRef(!0),a=v.useRef(!1),l=v.useRef(0);return v.useEffect(()=>{const u=l.current;return()=>window.clearTimeout(u)},[]),c.jsx(o2,{scope:t,isOpenDelayedRef:i,delayDuration:n,onOpen:v.useCallback(()=>{window.clearTimeout(l.current),i.current=!1},[]),onClose:v.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>i.current=!0,r)},[r]),isPointerInTransitRef:a,onPointerInTransitChange:v.useCallback(u=>{a.current=u},[]),disableHoverableContent:o,children:s})};Ev.displayName=Sv;var kv="Tooltip",[wk,La]=Ma(kv),Hu="TooltipTrigger",s2=v.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=La(Hu,n),s=Cv(Hu,n),i=id(n),a=v.useRef(null),l=Be(t,a,o.onTriggerChange),u=v.useRef(!1),d=v.useRef(!1),p=v.useCallback(()=>u.current=!1,[]);return v.useEffect(()=>()=>document.removeEventListener("pointerup",p),[p]),c.jsx(e2,{asChild:!0,...i,children:c.jsx(xe.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:l,onPointerMove:ce(e.onPointerMove,y=>{y.pointerType!=="touch"&&!d.current&&!s.isPointerInTransitRef.current&&(o.onTriggerEnter(),d.current=!0)}),onPointerLeave:ce(e.onPointerLeave,()=>{o.onTriggerLeave(),d.current=!1}),onPointerDown:ce(e.onPointerDown,()=>{o.open&&o.onClose(),u.current=!0,document.addEventListener("pointerup",p,{once:!0})}),onFocus:ce(e.onFocus,()=>{u.current||o.onOpen()}),onBlur:ce(e.onBlur,o.onClose),onClick:ce(e.onClick,o.onClose)})})});s2.displayName=Hu;var i2="TooltipPortal",[bk,a2]=Ma(i2,{forceMount:void 0}),wo="TooltipContent",Nv=v.forwardRef((e,t)=>{const n=a2(wo,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...s}=e,i=La(wo,e.__scopeTooltip);return c.jsx(Eo,{present:r||i.open,children:i.disableHoverableContent?c.jsx(Tv,{side:o,...s,ref:t}):c.jsx(l2,{side:o,...s,ref:t})})}),l2=v.forwardRef((e,t)=>{const n=La(wo,e.__scopeTooltip),r=Cv(wo,e.__scopeTooltip),o=v.useRef(null),s=Be(t,o),[i,a]=v.useState(null),{trigger:l,onClose:u}=n,d=o.current,{onPointerInTransitChange:p}=r,y=v.useCallback(()=>{a(null),p(!1)},[p]),f=v.useCallback((b,g)=>{const x=b.currentTarget,h={x:b.clientX,y:b.clientY},m=p2(h,x.getBoundingClientRect()),w=h2(h,m),S=m2(g.getBoundingClientRect()),C=v2([...w,...S]);a(C),p(!0)},[p]);return v.useEffect(()=>()=>y(),[y]),v.useEffect(()=>{if(l&&d){const b=x=>f(x,d),g=x=>f(x,l);return l.addEventListener("pointerleave",b),d.addEventListener("pointerleave",g),()=>{l.removeEventListener("pointerleave",b),d.removeEventListener("pointerleave",g)}}},[l,d,f,y]),v.useEffect(()=>{if(i){const b=g=>{const x=g.target,h={x:g.clientX,y:g.clientY},m=(l==null?void 0:l.contains(x))||(d==null?void 0:d.contains(x)),w=!g2(h,i);m?y():w&&(y(),u())};return document.addEventListener("pointermove",b),()=>document.removeEventListener("pointermove",b)}},[l,d,i,u,y]),c.jsx(Tv,{...e,ref:s})}),[u2,c2]=Ma(kv,{isInside:!1}),d2=qw("TooltipContent"),Tv=v.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:s,onPointerDownOutside:i,...a}=e,l=La(wo,n),u=id(n),{onClose:d}=l;return v.useEffect(()=>(document.addEventListener(pp,d),()=>document.removeEventListener(pp,d)),[d]),v.useEffect(()=>{if(l.trigger){const p=y=>{const f=y.target;f!=null&&f.contains(l.trigger)&&d()};return window.addEventListener("scroll",p,{capture:!0}),()=>window.removeEventListener("scroll",p,{capture:!0})}},[l.trigger,d]),c.jsx(Ra,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:p=>p.preventDefault(),onDismiss:d,children:c.jsxs(t2,{"data-state":l.stateAttribute,...u,...a,ref:t,style:{...a.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[c.jsx(d2,{children:r}),c.jsx(u2,{scope:n,isInside:!0,children:c.jsx(wb,{id:l.contentId,role:"tooltip",children:o||r})})]})})});Nv.displayName=wo;var Pv="TooltipArrow",f2=v.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=id(n);return c2(Pv,n).isInside?null:c.jsx(n2,{...o,...r,ref:t})});f2.displayName=Pv;function p2(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),s=Math.abs(t.left-e.x);switch(Math.min(n,r,o,s)){case s:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function h2(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function m2(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function g2(e,t){const{x:n,y:r}=e;let o=!1;for(let s=0,i=t.length-1;s<t.length;i=s++){const a=t[s],l=t[i],u=a.x,d=a.y,p=l.x,y=l.y;d>r!=y>r&&n<(p-u)*(r-d)/(y-d)+u&&(o=!o)}return o}function v2(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),y2(t)}function y2(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const o=e[r];for(;t.length>=2;){const s=t[t.length-1],i=t[t.length-2];if((s.x-i.x)*(o.y-i.y)>=(s.y-i.y)*(o.x-i.x))t.pop();else break}t.push(o)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;n.length>=2;){const s=n[n.length-1],i=n[n.length-2];if((s.x-i.x)*(o.y-i.y)>=(s.y-i.y)*(o.x-i.x))n.pop();else break}n.push(o)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var x2=Ev,Rv=Nv;const w2=x2,b2=v.forwardRef(({className:e,sideOffset:t=4,...n},r)=>c.jsx(Rv,{ref:r,sideOffset:t,className:we("z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...n}));b2.displayName=Rv.displayName;const S2=({categories:e,selected:t,onSelect:n})=>c.jsx("div",{className:"rounded-2xl border border-slate-300 bg-slate-100 p-3 shadow-sm",children:c.jsx("div",{className:"flex flex-wrap gap-2",children:e.map(r=>{const o=t===r;return c.jsx("button",{type:"button",onClick:()=>n(r),className:"rounded-full border px-4 py-2 text-sm font-semibold tracking-wide transition-all",style:{borderColor:o?"#0f6ea8":"#cbd5e1",backgroundColor:o?"#0f6ea8":"#ffffff",color:o?"#ffffff":"#1e293b",boxShadow:o?"0 6px 18px rgba(15,110,168,0.22)":"0 1px 2px rgba(15,23,42,0.04)"},children:r},r)})})}),C2=({products:e,onAdd:t,onReorder:n})=>{const[r,o]=v.useState(null);return c.jsx("div",{className:"grid grid-cols-2 sm:grid-cols-3 lg:grid-cols-4 gap-3",children:e.map(s=>c.jsxs("button",{draggable:!!n,onDragStart:()=>o(s.id),onDragEnd:()=>o(null),onDragOver:i=>{n&&i.preventDefault()},onDrop:i=>{!n||!r||r===s.id||(i.preventDefault(),n(r,s.id),o(null))},onClick:()=>t(s),className:`flex min-h-[206px] flex-col items-center gap-3 rounded-xl bg-card p-4 shadow-sm border transition-all active:scale-95 ${r===s.id?"border-primary shadow-lg opacity-70 cursor-grabbing":"border-border hover:shadow-md hover:border-primary/30 cursor-grab"}`,children:[s.imageUrl?c.jsx("img",{src:s.imageUrl,alt:s.name,className:"h-28 w-28 rounded-2xl border border-border object-cover shadow-sm"}):c.jsx("span",{className:"rounded-full bg-secondary px-6 py-2.5 text-4xl font-extrabold leading-none text-muted-foreground shadow-sm",children:s.emoji}),c.jsx("span",{className:"flex min-h-[52px] w-full items-center justify-center rounded-lg bg-slate-100 px-3 py-2 text-center text-sm font-bold leading-tight text-slate-900",children:s.name}),c.jsx("span",{className:"text-[11px] font-semibold uppercase tracking-[0.16em] text-muted-foreground",children:s.category}),c.jsxs("span",{className:"text-sm font-bold text-primary",children:["$",s.price.toFixed(2)]})]},s.id))})},E2=({items:e,onUpdateQty:t,onRemove:n,onCheckout:r,onClear:o})=>{const s=e.reduce((l,u)=>l+u.price*u.quantity,0),i=e.reduce((l,u)=>l+u.quantity,0),a=e.reduce((l,u)=>u.taxRate?l+u.price*u.quantity*(u.taxRate/100):l,0);return c.jsxs("div",{className:"flex h-full w-full flex-col rounded-2xl border border-border bg-card shadow-sm",children:[c.jsxs("div",{className:"flex items-center justify-between border-b border-border px-4 py-3",children:[c.jsxs("div",{className:"flex items-center gap-2",children:[c.jsx(ep,{className:"h-5 w-5 text-primary"}),c.jsx("h2",{className:"text-lg font-bold text-foreground",children:"Ticket"}),i>0&&c.jsx("span",{className:"rounded-full bg-primary px-2 py-0.5 text-xs font-bold text-primary-foreground",children:i})]}),e.length>0&&c.jsx("button",{onClick:o,className:"text-xs font-semibold text-destructive hover:underline",children:"Clear"})]}),c.jsx("div",{className:"flex-1 overflow-y-auto px-3 py-2 space-y-1",children:e.length===0?c.jsxs("div",{className:"flex flex-col items-center justify-center h-full text-muted-foreground py-12",children:[c.jsx(ep,{className:"h-12 w-12 mb-2 opacity-30"}),c.jsx("p",{className:"text-sm",children:"No items yet"})]}):e.map(l=>c.jsxs("div",{className:"flex items-center gap-2 rounded-lg bg-background p-2",children:[c.jsx("span",{className:"text-xl",children:l.emoji}),c.jsxs("div",{className:"flex-1 min-w-0",children:[c.jsx("p",{className:"text-sm font-semibold text-foreground truncate",children:l.name}),c.jsxs("p",{className:"text-xs text-muted-foreground",children:["$",l.price.toFixed(2)," each"]})]}),c.jsxs("div",{className:"flex items-center gap-1",children:[c.jsx("button",{onClick:()=>t(l.id,-1),className:"rounded-md bg-secondary p-1 hover:bg-border transition-colors",children:c.jsx(Hb,{className:"h-3.5 w-3.5"})}),c.jsx("span",{className:"w-6 text-center text-sm font-bold",children:l.quantity}),c.jsx("button",{onClick:()=>t(l.id,1),className:"rounded-md bg-secondary p-1 hover:bg-border transition-colors",children:c.jsx(Vb,{className:"h-3.5 w-3.5"})})]}),c.jsxs("p",{className:"w-16 text-right text-sm font-bold text-foreground",children:["$",(l.price*l.quantity).toFixed(2)]}),c.jsx("button",{onClick:()=>n(l.id),className:"rounded-md p-1 text-muted-foreground hover:text-destructive transition-colors",children:c.jsx(Xb,{className:"h-3.5 w-3.5"})})]},l.id))}),c.jsxs("div",{className:"border-t border-border px-4 py-3 space-y-2",children:[c.jsxs("div",{className:"flex justify-between items-baseline",children:[c.jsx("span",{className:"text-sm text-muted-foreground",children:"Subtotal"}),c.jsxs("span",{className:"text-sm font-semibold text-foreground",children:["$",s.toFixed(2)]})]}),a>0&&c.jsxs("div",{className:"flex justify-between items-baseline",children:[c.jsx("span",{className:"text-sm text-muted-foreground",children:"Tax"}),c.jsxs("span",{className:"text-sm font-semibold text-foreground",children:["$",a.toFixed(2)]})]}),c.jsxs("div",{className:"flex justify-between items-baseline pt-1 border-t border-border",children:[c.jsx("span",{className:"text-base font-semibold text-muted-foreground",children:"Total"}),c.jsxs("span",{className:"text-2xl font-extrabold text-foreground",children:["$",(s+a).toFixed(2)]})]}),c.jsx("button",{onClick:r,disabled:e.length===0,className:"w-full rounded-xl bg-success py-3 text-base font-bold text-success-foreground shadow-md hover:opacity-90 transition-opacity disabled:opacity-40 disabled:cursor-not-allowed active:scale-[0.98]",children:"Checkout"})]})]})};function k2(e){return e.replace(/\/+$/,"")}function N2(e){return Array.from(new Set(e.filter(Boolean)))}function T2(){const t=k2("/NAOPOS/dist/"),n=t.endsWith("/dist")?t.replace(/\/dist$/,"/api"):t===""?"/api":`${t}/api`;return N2([n,"/NAOPOS/api","/api"])}async function pn(e,t){const n=T2();let r=null,o=null;for(const s of n)try{const i=await fetch(`${s}${e}`,t);if(i.status!==404)return i;r=i}catch(i){o=i}if(r)return r;throw o instanceof Error?o:new Error("API request failed")}const Ho=[{id:"unleaded",label:"Unleaded",shortLabel:"GAS",taxable:!0,reportCategory:"Unleaded"},{id:"unleaded-plus",label:"Unleaded Plus",shortLabel:"GAS+",taxable:!0,reportCategory:"Unleaded Plus"},{id:"diesel",label:"Diesel",shortLabel:"DSL",taxable:!0,reportCategory:"Diesel"},{id:"off-road-diesel",label:"Off Road Diesel",shortLabel:"ORD",taxable:!1,reportCategory:"Off Road Diesel"},{id:"hardware",label:"Hardware",shortLabel:"HDW",taxable:!0,reportCategory:"Hardware"},{id:"oil",label:"Oil",shortLabel:"OIL",taxable:!0,reportCategory:"Oil"}],En={groceryTaxRate:2,quickButtons:Ho},jv=["Taxable","Non-Taxable","Unleaded","Unleaded Plus","Diesel","Off Road Diesel","Oil","Hardware","Other"],Ov=jv;function P2(e,t,n){return{id:e.id||n.id||`button-${t}`,label:e.label||n.label||"Item",shortLabel:e.shortLabel||n.shortLabel||"BTN",taxable:!!e.taxable,taxRate:typeof e.taxRate=="number"&&!Number.isNaN(e.taxRate)?e.taxRate:n.taxRate,reportCategory:jv.includes(e.reportCategory)?e.reportCategory:n.reportCategory}}function R2(e){const t=e!=null&&e.quickButtons&&e.quickButtons.length>0?e.quickButtons:Ho;return{groceryTaxRate:typeof(e==null?void 0:e.groceryTaxRate)=="number"&&!Number.isNaN(e.groceryTaxRate)?e.groceryTaxRate:En.groceryTaxRate,quickButtons:t.map((n,r)=>P2(n,r,Ho[r]||Ho[Ho.length-1]))}}async function j2(){try{const e=await pn("/settings.php");if(!e.ok)return null;const t=await e.json();return R2(t)}catch(e){return console.error("Failed to load POS settings",e),null}}async function O2(e){try{return(await pn("/settings.php",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).ok}catch(t){return console.error("Failed to save POS settings",t),!1}}const _2=({onAddItem:e})=>{const[t,n]=v.useState("0.00"),[r,o]=v.useState(!0),[s,i]=v.useState(En.groceryTaxRate),[a,l]=v.useState(!1),[u,d]=v.useState(En.groceryTaxRate.toString()),[p,y]=v.useState(!1),[f,b]=v.useState(En.quickButtons),[g,x]=v.useState(!1),[h,m]=v.useState(""),[w,S]=v.useState(null),[C,N]=v.useState(null),E=T=>((parseInt(T,10)||0)/100).toFixed(2);v.useEffect(()=>{let T=!0;return(async()=>{const k=await j2();if(!T)return;const P=k??En;b(P.quickButtons),i(P.groceryTaxRate),d(P.groceryTaxRate.toString()),x(!0)})(),()=>{T=!1}},[]),v.useEffect(()=>{if(!g)return;const T=window.setTimeout(async()=>{const O=await O2({groceryTaxRate:s,quickButtons:f});m(O?"Saved for all devices":"Save failed")},500);return()=>window.clearTimeout(T)},[s,f,g]);const R=T=>{n(O=>{const P=`${O.replace(".","").replace(/^0+/,"")}${T}`;return E(P)})},D=()=>n("0.00"),L=()=>{n(T=>{const O=T.replace(".","").replace(/^0+/,""),k=O.length<=1?"0":O.slice(0,-1);return E(k)})},W=(T="Item",O,k,P)=>{const A=O!==void 0?O:r,U=parseFloat(t),H=U<=0&&C&&C.label===T&&C.taxable===A&&C.taxRate===k&&C.reportCategory===P?C.amount:U;H<=0||(e(H,T,A,k,P),T!=="Item"&&N({amount:H,label:T,taxable:A,taxRate:k,reportCategory:P}),n("0.00"))},$=()=>{const T=parseFloat(u);!Number.isNaN(T)&&T>=0&&T<=100&&i(T),l(!1)},V=(T,O,k)=>{b(P=>P.map(A=>{if(A.id!==T)return A;const U={...A,[O]:k};if(O==="reportCategory"){const z=k;z==="Non-Taxable"?(U.taxable=!1,U.taxRate=void 0):z==="Taxable"&&!U.taxRate&&(U.taxable=!0,U.taxRate=s)}return O==="taxable"&&k===!1&&(U.taxRate=void 0),O==="taxable"&&k===!0&&!U.taxRate&&(U.taxRate=s),U}))},F=()=>{b(En.quickButtons),i(En.groceryTaxRate),d(En.groceryTaxRate.toString())},I=(T,O)=>{b(k=>{const P=k.findIndex(H=>H.id===T),A=k.findIndex(H=>H.id===O);if(P<0||A<0||P===A)return k;const U=[...k],[z]=U.splice(P,1);return U.splice(A,0,z),U})};return c.jsxs("div",{className:"flex flex-col gap-3 rounded-2xl border border-border bg-card p-3 shadow-sm",children:[c.jsxs("div",{className:"rounded-xl border border-border bg-background px-4 py-3 text-right",children:[c.jsx("div",{className:"mb-0.5 text-xs font-semibold text-muted-foreground",children:r?"TAX":"NO TAX"}),c.jsxs("div",{className:"font-mono text-3xl font-extrabold tracking-tight text-foreground",children:["$",t]})]}),c.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[c.jsx("button",{onClick:()=>o(!0),className:`rounded-lg py-2 text-sm font-bold transition-all ${r?"bg-primary text-primary-foreground shadow":"bg-secondary text-secondary-foreground"}`,children:"Taxable"}),c.jsx("button",{onClick:()=>o(!1),className:`rounded-lg py-2 text-sm font-bold transition-all ${r?"bg-secondary text-secondary-foreground":"bg-primary text-primary-foreground shadow"}`,children:"Non-Taxable"})]}),c.jsxs("div",{className:"grid grid-cols-3 gap-2",children:[["7","8","9","4","5","6","1","2","3"].map(T=>c.jsx("button",{onClick:()=>R(T),className:"rounded-lg border border-border bg-background py-3 text-lg font-bold text-foreground transition-all hover:bg-secondary active:scale-95",children:T},T)),c.jsx("button",{onClick:D,className:"rounded-lg border border-destructive/20 bg-destructive/10 py-3 text-sm font-bold text-destructive transition-all hover:bg-destructive/20 active:scale-95",children:"CLR"}),c.jsx("button",{onClick:()=>R("0"),className:"rounded-lg border border-border bg-background py-3 text-lg font-bold text-foreground transition-all hover:bg-secondary active:scale-95",children:"0"}),c.jsx("button",{onClick:L,className:"flex items-center justify-center rounded-lg border border-border bg-background py-3 text-lg font-bold text-foreground transition-all hover:bg-secondary active:scale-95",children:c.jsx(Ug,{className:"h-5 w-5"})})]}),c.jsx("button",{onClick:()=>W(),className:"rounded-xl bg-success py-3 text-base font-bold text-success-foreground shadow-md transition-all hover:opacity-90 active:scale-[0.98]",children:"Enter"}),c.jsxs("div",{className:"grid grid-cols-2 gap-1.5",children:[c.jsxs("div",{className:"relative",children:[c.jsxs("button",{onClick:()=>W(`Grocery (${s}%)`,!0,s,"Taxable"),className:"flex min-h-[54px] w-full items-center justify-center gap-1 rounded-lg border border-success/30 bg-success/15 px-2 py-2 text-[11px] font-bold text-foreground transition-all hover:bg-success hover:text-success-foreground active:scale-95",children:[c.jsx("span",{children:"GRC"}),c.jsxs("span",{children:["Grocery (",s,"%)"]})]}),c.jsx("button",{onClick:()=>{d(s.toString()),l(!0)},className:"absolute -right-1 -top-1 rounded-full bg-muted p-1 transition-colors hover:bg-border",title:"Edit tax rate",children:c.jsx(Yb,{className:"h-3 w-3 text-muted-foreground"})})]}),c.jsxs("button",{onClick:()=>W("Grocery (No Tax)",!1,void 0,"Non-Taxable"),className:"flex min-h-[54px] items-center justify-center gap-1 rounded-lg border border-border bg-secondary px-2 py-2 text-[11px] font-bold text-foreground transition-all hover:bg-muted-foreground hover:text-background active:scale-95",children:[c.jsx("span",{children:"GRC"}),c.jsx("span",{children:"Non-Tax Grocery"})]})]}),a&&c.jsxs("div",{className:"space-y-2 rounded-xl border border-border bg-background p-3",children:[c.jsx("label",{className:"text-xs font-semibold text-muted-foreground",children:"Grocery Tax Rate (%)"}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx("input",{type:"number",min:"0",max:"100",step:"0.01",value:u,onChange:T=>d(T.target.value),className:"flex-1 rounded-lg border border-border bg-card px-3 py-2 text-sm font-bold text-foreground focus:outline-none focus:ring-2 focus:ring-primary"}),c.jsx("button",{onClick:$,className:"rounded-lg bg-primary px-4 py-2 text-sm font-bold text-primary-foreground transition-opacity hover:opacity-90",children:"Save"})]})]}),c.jsx("div",{className:"grid grid-cols-2 gap-1.5",children:f.map(T=>c.jsxs("button",{draggable:!0,onDragStart:()=>S(T.id),onDragEnd:()=>S(null),onDragOver:O=>O.preventDefault(),onDrop:O=>{!w||w===T.id||(O.preventDefault(),I(w,T.id),S(null))},onClick:()=>W(T.label,T.taxable,T.taxable?T.taxRate:void 0,T.reportCategory),className:`flex min-h-[56px] items-center justify-center gap-1.5 rounded-lg border px-2 py-2 text-[11px] font-bold text-foreground transition-all hover:bg-primary hover:text-primary-foreground active:scale-95 ${w===T.id?"border-primary bg-primary/10 opacity-70 shadow-lg cursor-grabbing":"border-primary/20 bg-warm-light cursor-grab"}`,title:"Click to use. Click and drag to reorder.",children:[c.jsx("span",{className:"rounded-full bg-white/70 px-2 py-1 text-base font-extrabold leading-none shadow-sm",children:T.shortLabel}),c.jsx("span",{className:"leading-tight",children:T.label})]},T.id))}),c.jsxs("div",{className:"space-y-2 rounded-xl border border-border bg-background p-2.5",children:[c.jsxs("div",{className:"flex items-center justify-between",children:[c.jsx("p",{className:"text-xs font-semibold text-muted-foreground",children:"Large Button Setup"}),c.jsxs("div",{className:"flex items-center gap-2",children:[h&&c.jsx("span",{className:"text-[10px] font-semibold text-muted-foreground",children:h}),c.jsx("button",{onClick:()=>y(T=>!T),className:"rounded-lg bg-secondary px-2.5 py-1.5 text-[11px] font-bold text-secondary-foreground transition-all hover:bg-border",children:p?"Hide Setup":"Edit Buttons"})]})]}),p&&c.jsxs("div",{className:"space-y-3",children:[f.map(T=>c.jsxs("div",{className:"space-y-2 rounded-lg border border-border bg-card p-3",children:[c.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[c.jsxs("label",{className:"text-xs font-semibold text-muted-foreground",children:["Label",c.jsx("input",{value:T.label,onChange:O=>V(T.id,"label",O.target.value),className:"mt-1 w-full rounded-lg border border-border bg-background px-3 py-2 text-sm font-semibold text-foreground focus:outline-none focus:ring-2 focus:ring-primary"})]}),c.jsxs("label",{className:"text-xs font-semibold text-muted-foreground",children:["Short Tag",c.jsx("input",{value:T.shortLabel,onChange:O=>V(T.id,"shortLabel",O.target.value),className:"mt-1 w-full rounded-lg border border-border bg-background px-3 py-2 text-sm font-semibold text-foreground focus:outline-none focus:ring-2 focus:ring-primary"})]})]}),c.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[c.jsxs("label",{className:"text-xs font-semibold text-muted-foreground",children:["Report Bucket",c.jsx("select",{value:T.reportCategory,onChange:O=>V(T.id,"reportCategory",O.target.value),className:"mt-1 w-full rounded-lg border border-border bg-background px-3 py-2 text-sm font-semibold text-foreground focus:outline-none focus:ring-2 focus:ring-primary",children:Ov.map(O=>c.jsx("option",{value:O,children:O},O))})]}),c.jsxs("label",{className:"text-xs font-semibold text-muted-foreground",children:["Tax Rule",c.jsxs("select",{value:T.taxable?"taxable":"non-taxable",onChange:O=>V(T.id,"taxable",O.target.value==="taxable"),className:"mt-1 w-full rounded-lg border border-border bg-background px-3 py-2 text-sm font-semibold text-foreground focus:outline-none focus:ring-2 focus:ring-primary",children:[c.jsx("option",{value:"taxable",children:"Taxable"}),c.jsx("option",{value:"non-taxable",children:"Non-Taxable"})]})]})]}),c.jsxs("label",{className:"text-xs font-semibold text-muted-foreground",children:["Tax Rate (%)",c.jsx("input",{type:"number",min:"0",max:"100",step:"0.01",value:T.taxRate??"",disabled:!T.taxable,onChange:O=>V(T.id,"taxRate",O.target.value===""?void 0:parseFloat(O.target.value)),className:"mt-1 w-full rounded-lg border border-border bg-background px-3 py-2 text-sm font-semibold text-foreground focus:outline-none focus:ring-2 focus:ring-primary disabled:cursor-not-allowed disabled:opacity-50"})]})]},T.id)),c.jsx("button",{onClick:F,className:"w-full rounded-lg border border-border bg-secondary py-2 text-sm font-bold text-secondary-foreground transition-all hover:bg-border",children:"Reset Default Buttons"})]})]})]})};var Tl="focusScope.autoFocusOnMount",Pl="focusScope.autoFocusOnUnmount",hp={bubbles:!1,cancelable:!0},A2="FocusScope",_v=v.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:s,...i}=e,[a,l]=v.useState(null),u=Qt(o),d=Qt(s),p=v.useRef(null),y=Be(t,g=>l(g)),f=v.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;v.useEffect(()=>{if(r){let g=function(w){if(f.paused||!a)return;const S=w.target;a.contains(S)?p.current=S:kn(p.current,{select:!0})},x=function(w){if(f.paused||!a)return;const S=w.relatedTarget;S!==null&&(a.contains(S)||kn(p.current,{select:!0}))},h=function(w){if(document.activeElement===document.body)for(const C of w)C.removedNodes.length>0&&kn(a)};document.addEventListener("focusin",g),document.addEventListener("focusout",x);const m=new MutationObserver(h);return a&&m.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",x),m.disconnect()}}},[r,a,f.paused]),v.useEffect(()=>{if(a){gp.add(f);const g=document.activeElement;if(!a.contains(g)){const h=new CustomEvent(Tl,hp);a.addEventListener(Tl,u),a.dispatchEvent(h),h.defaultPrevented||(D2($2(Av(a)),{select:!0}),document.activeElement===g&&kn(a))}return()=>{a.removeEventListener(Tl,u),setTimeout(()=>{const h=new CustomEvent(Pl,hp);a.addEventListener(Pl,d),a.dispatchEvent(h),h.defaultPrevented||kn(g??document.body,{select:!0}),a.removeEventListener(Pl,d),gp.remove(f)},0)}}},[a,u,d,f]);const b=v.useCallback(g=>{if(!n&&!r||f.paused)return;const x=g.key==="Tab"&&!g.altKey&&!g.ctrlKey&&!g.metaKey,h=document.activeElement;if(x&&h){const m=g.currentTarget,[w,S]=M2(m);w&&S?!g.shiftKey&&h===S?(g.preventDefault(),n&&kn(w,{select:!0})):g.shiftKey&&h===w&&(g.preventDefault(),n&&kn(S,{select:!0})):h===m&&g.preventDefault()}},[n,r,f.paused]);return c.jsx(xe.div,{tabIndex:-1,...i,ref:y,onKeyDown:b})});_v.displayName=A2;function D2(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(kn(r,{select:t}),document.activeElement!==n)return}function M2(e){const t=Av(e),n=mp(t,e),r=mp(t.reverse(),e);return[n,r]}function Av(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function mp(e,t){for(const n of e)if(!L2(n,{upTo:t}))return n}function L2(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function I2(e){return e instanceof HTMLInputElement&&"select"in e}function kn(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&I2(e)&&t&&e.select()}}var gp=F2();function F2(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=vp(e,t),e.unshift(t)},remove(t){var n;e=vp(e,t),(n=e[0])==null||n.resume()}}}function vp(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function $2(e){return e.filter(t=>t.tagName!=="A")}var Rl=0;function z2(){v.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??yp()),document.body.insertAdjacentElement("beforeend",e[1]??yp()),Rl++,()=>{Rl===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Rl--}},[])}function yp(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var Bt=function(){return Bt=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},Bt.apply(this,arguments)};function Dv(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function B2(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,s;r<o;r++)(s||!(r in t))&&(s||(s=Array.prototype.slice.call(t,0,r)),s[r]=t[r]);return e.concat(s||Array.prototype.slice.call(t))}var ki="right-scroll-bar-position",Ni="width-before-scroll-bar",U2="with-scroll-bars-hidden",W2="--removed-body-scroll-bar-size";function jl(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function H2(e,t){var n=v.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}var V2=typeof window<"u"?v.useLayoutEffect:v.useEffect,xp=new WeakMap;function Q2(e,t){var n=H2(null,function(r){return e.forEach(function(o){return jl(o,r)})});return V2(function(){var r=xp.get(n);if(r){var o=new Set(r),s=new Set(e),i=n.current;o.forEach(function(a){s.has(a)||jl(a,null)}),s.forEach(function(a){o.has(a)||jl(a,i)})}xp.set(n,e)},[e]),n}function G2(e){return e}function K2(e,t){t===void 0&&(t=G2);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(s){var i=t(s,r);return n.push(i),function(){n=n.filter(function(a){return a!==i})}},assignSyncMedium:function(s){for(r=!0;n.length;){var i=n;n=[],i.forEach(s)}n={push:function(a){return s(a)},filter:function(){return n}}},assignMedium:function(s){r=!0;var i=[];if(n.length){var a=n;n=[],a.forEach(s),i=n}var l=function(){var d=i;i=[],d.forEach(s)},u=function(){return Promise.resolve().then(l)};u(),n={push:function(d){i.push(d),u()},filter:function(d){return i=i.filter(d),n}}}};return o}function Y2(e){e===void 0&&(e={});var t=K2(null);return t.options=Bt({async:!0,ssr:!1},e),t}var Mv=function(e){var t=e.sideCar,n=Dv(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return v.createElement(r,Bt({},n))};Mv.isSideCarExport=!0;function q2(e,t){return e.useMedium(t),Mv}var Lv=Y2(),Ol=function(){},Ia=v.forwardRef(function(e,t){var n=v.useRef(null),r=v.useState({onScrollCapture:Ol,onWheelCapture:Ol,onTouchMoveCapture:Ol}),o=r[0],s=r[1],i=e.forwardProps,a=e.children,l=e.className,u=e.removeScrollBar,d=e.enabled,p=e.shards,y=e.sideCar,f=e.noRelative,b=e.noIsolation,g=e.inert,x=e.allowPinchZoom,h=e.as,m=h===void 0?"div":h,w=e.gapMode,S=Dv(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),C=y,N=Q2([n,t]),E=Bt(Bt({},S),o);return v.createElement(v.Fragment,null,d&&v.createElement(C,{sideCar:Lv,removeScrollBar:u,shards:p,noRelative:f,noIsolation:b,inert:g,setCallbacks:s,allowPinchZoom:!!x,lockRef:n,gapMode:w}),i?v.cloneElement(v.Children.only(a),Bt(Bt({},E),{ref:N})):v.createElement(m,Bt({},E,{className:l,ref:N}),a))});Ia.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Ia.classNames={fullWidth:Ni,zeroRight:ki};var X2=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function Z2(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=X2();return t&&e.setAttribute("nonce",t),e}function J2(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function eE(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var tE=function(){var e=0,t=null;return{add:function(n){e==0&&(t=Z2())&&(J2(t,n),eE(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},nE=function(){var e=tE();return function(t,n){v.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Iv=function(){var e=nE(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},rE={left:0,top:0,right:0,gap:0},_l=function(e){return parseInt(e||"",10)||0},oE=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[_l(n),_l(r),_l(o)]},sE=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return rE;var t=oE(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},iE=Iv(),no="data-scroll-locked",aE=function(e,t,n,r){var o=e.left,s=e.top,i=e.right,a=e.gap;return n===void 0&&(n="margin"),`
.`.concat(U2,` {
overflow: hidden `).concat(r,`;
padding-right: `).concat(a,"px ").concat(r,`;
}
body[`).concat(no,`] {
overflow: hidden `).concat(r,`;
overscroll-behavior: contain;
`).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
padding-left: `.concat(o,`px;
padding-top: `).concat(s,`px;
padding-right: `).concat(i,`px;
margin-left:0;
margin-top:0;
margin-right: `).concat(a,"px ").concat(r,`;
`),n==="padding"&&"padding-right: ".concat(a,"px ").concat(r,";")].filter(Boolean).join(""),`
}
.`).concat(ki,` {
right: `).concat(a,"px ").concat(r,`;
}
.`).concat(Ni,` {
margin-right: `).concat(a,"px ").concat(r,`;
}
.`).concat(ki," .").concat(ki,` {
right: 0 `).concat(r,`;
}
.`).concat(Ni," .").concat(Ni,` {
margin-right: 0 `).concat(r,`;
}
body[`).concat(no,`] {
`).concat(W2,": ").concat(a,`px;
}
`)},wp=function(){var e=parseInt(document.body.getAttribute(no)||"0",10);return isFinite(e)?e:0},lE=function(){v.useEffect(function(){return document.body.setAttribute(no,(wp()+1).toString()),function(){var e=wp()-1;e<=0?document.body.removeAttribute(no):document.body.setAttribute(no,e.toString())}},[])},uE=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r;lE();var s=v.useMemo(function(){return sE(o)},[o]);return v.createElement(iE,{styles:aE(s,!t,o,n?"":"!important")})},Vu=!1;if(typeof window<"u")try{var ii=Object.defineProperty({},"passive",{get:function(){return Vu=!0,!0}});window.addEventListener("test",ii,ii),window.removeEventListener("test",ii,ii)}catch{Vu=!1}var _r=Vu?{passive:!1}:!1,cE=function(e){return e.tagName==="TEXTAREA"},Fv=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!cE(e)&&n[t]==="visible")},dE=function(e){return Fv(e,"overflowY")},fE=function(e){return Fv(e,"overflowX")},bp=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var o=$v(e,r);if(o){var s=zv(e,r),i=s[1],a=s[2];if(i>a)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},pE=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},hE=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},$v=function(e,t){return e==="v"?dE(t):fE(t)},zv=function(e,t){return e==="v"?pE(t):hE(t)},mE=function(e,t){return e==="h"&&t==="rtl"?-1:1},gE=function(e,t,n,r,o){var s=mE(e,window.getComputedStyle(t).direction),i=s*r,a=n.target,l=t.contains(a),u=!1,d=i>0,p=0,y=0;do{if(!a)break;var f=zv(e,a),b=f[0],g=f[1],x=f[2],h=g-x-s*b;(b||h)&&$v(e,a)&&(p+=h,y+=b);var m=a.parentNode;a=m&&m.nodeType===Node.DOCUMENT_FRAGMENT_NODE?m.host:m}while(!l&&a!==document.body||l&&(t.contains(a)||t===a));return(d&&(Math.abs(p)<1||!o)||!d&&(Math.abs(y)<1||!o))&&(u=!0),u},ai=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Sp=function(e){return[e.deltaX,e.deltaY]},Cp=function(e){return e&&"current"in e?e.current:e},vE=function(e,t){return e[0]===t[0]&&e[1]===t[1]},yE=function(e){return`
.block-interactivity-`.concat(e,` {pointer-events: none;}
.allow-interactivity-`).concat(e,` {pointer-events: all;}
`)},xE=0,Ar=[];function wE(e){var t=v.useRef([]),n=v.useRef([0,0]),r=v.useRef(),o=v.useState(xE++)[0],s=v.useState(Iv)[0],i=v.useRef(e);v.useEffect(function(){i.current=e},[e]),v.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var g=B2([e.lockRef.current],(e.shards||[]).map(Cp),!0).filter(Boolean);return g.forEach(function(x){return x.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),g.forEach(function(x){return x.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var a=v.useCallback(function(g,x){if("touches"in g&&g.touches.length===2||g.type==="wheel"&&g.ctrlKey)return!i.current.allowPinchZoom;var h=ai(g),m=n.current,w="deltaX"in g?g.deltaX:m[0]-h[0],S="deltaY"in g?g.deltaY:m[1]-h[1],C,N=g.target,E=Math.abs(w)>Math.abs(S)?"h":"v";if("touches"in g&&E==="h"&&N.type==="range")return!1;var R=bp(E,N);if(!R)return!0;if(R?C=E:(C=E==="v"?"h":"v",R=bp(E,N)),!R)return!1;if(!r.current&&"changedTouches"in g&&(w||S)&&(r.current=C),!C)return!0;var D=r.current||C;return gE(D,x,g,D==="h"?w:S,!0)},[]),l=v.useCallback(function(g){var x=g;if(!(!Ar.length||Ar[Ar.length-1]!==s)){var h="deltaY"in x?Sp(x):ai(x),m=t.current.filter(function(C){return C.name===x.type&&(C.target===x.target||x.target===C.shadowParent)&&vE(C.delta,h)})[0];if(m&&m.should){x.cancelable&&x.preventDefault();return}if(!m){var w=(i.current.shards||[]).map(Cp).filter(Boolean).filter(function(C){return C.contains(x.target)}),S=w.length>0?a(x,w[0]):!i.current.noIsolation;S&&x.cancelable&&x.preventDefault()}}},[]),u=v.useCallback(function(g,x,h,m){var w={name:g,delta:x,target:h,should:m,shadowParent:bE(h)};t.current.push(w),setTimeout(function(){t.current=t.current.filter(function(S){return S!==w})},1)},[]),d=v.useCallback(function(g){n.current=ai(g),r.current=void 0},[]),p=v.useCallback(function(g){u(g.type,Sp(g),g.target,a(g,e.lockRef.current))},[]),y=v.useCallback(function(g){u(g.type,ai(g),g.target,a(g,e.lockRef.current))},[]);v.useEffect(function(){return Ar.push(s),e.setCallbacks({onScrollCapture:p,onWheelCapture:p,onTouchMoveCapture:y}),document.addEventListener("wheel",l,_r),document.addEventListener("touchmove",l,_r),document.addEventListener("touchstart",d,_r),function(){Ar=Ar.filter(function(g){return g!==s}),document.removeEventListener("wheel",l,_r),document.removeEventListener("touchmove",l,_r),document.removeEventListener("touchstart",d,_r)}},[]);var f=e.removeScrollBar,b=e.inert;return v.createElement(v.Fragment,null,b?v.createElement(s,{styles:yE(o)}):null,f?v.createElement(uE,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function bE(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const SE=q2(Lv,wE);var Bv=v.forwardRef(function(e,t){return v.createElement(Ia,Bt({},e,{ref:t,sideCar:SE}))});Bv.classNames=Ia.classNames;var CE=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Dr=new WeakMap,li=new WeakMap,ui={},Al=0,Uv=function(e){return e&&(e.host||Uv(e.parentNode))},EE=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=Uv(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},kE=function(e,t,n,r){var o=EE(t,Array.isArray(e)?e:[e]);ui[n]||(ui[n]=new WeakMap);var s=ui[n],i=[],a=new Set,l=new Set(o),u=function(p){!p||a.has(p)||(a.add(p),u(p.parentNode))};o.forEach(u);var d=function(p){!p||l.has(p)||Array.prototype.forEach.call(p.children,function(y){if(a.has(y))d(y);else try{var f=y.getAttribute(r),b=f!==null&&f!=="false",g=(Dr.get(y)||0)+1,x=(s.get(y)||0)+1;Dr.set(y,g),s.set(y,x),i.push(y),g===1&&b&&li.set(y,!0),x===1&&y.setAttribute(n,"true"),b||y.setAttribute(r,"true")}catch(h){console.error("aria-hidden: cannot operate on ",y,h)}})};return d(t),a.clear(),Al++,function(){i.forEach(function(p){var y=Dr.get(p)-1,f=s.get(p)-1;Dr.set(p,y),s.set(p,f),y||(li.has(p)||p.removeAttribute(r),li.delete(p)),f||p.removeAttribute(n)}),Al--,Al||(Dr=new WeakMap,Dr=new WeakMap,li=new WeakMap,ui={})}},NE=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=CE(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),kE(r,o,n,"aria-hidden")):function(){return null}},Fa="Dialog",[Wv,Sk]=Os(Fa),[TE,At]=Wv(Fa),Hv=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:s,modal:i=!0}=e,a=v.useRef(null),l=v.useRef(null),[u,d]=vg({prop:r,defaultProp:o??!1,onChange:s,caller:Fa});return c.jsx(TE,{scope:t,triggerRef:a,contentRef:l,contentId:El(),titleId:El(),descriptionId:El(),open:u,onOpenChange:d,onOpenToggle:v.useCallback(()=>d(p=>!p),[d]),modal:i,children:n})};Hv.displayName=Fa;var Vv="DialogTrigger",PE=v.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=At(Vv,n),s=Be(t,o.triggerRef);return c.jsx(xe.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":ud(o.open),...r,ref:s,onClick:ce(e.onClick,o.onOpenToggle)})});PE.displayName=Vv;var ad="DialogPortal",[RE,Qv]=Wv(ad,{forceMount:void 0}),Gv=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,s=At(ad,t);return c.jsx(RE,{scope:t,forceMount:n,children:v.Children.map(r,i=>c.jsx(Eo,{present:n||s.open,children:c.jsx(Gc,{asChild:!0,container:o,children:i})}))})};Gv.displayName=ad;var ia="DialogOverlay",Kv=v.forwardRef((e,t)=>{const n=Qv(ia,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=At(ia,e.__scopeDialog);return s.modal?c.jsx(Eo,{present:r||s.open,children:c.jsx(OE,{...o,ref:t})}):null});Kv.displayName=ia;var jE=ta("DialogOverlay.RemoveScroll"),OE=v.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=At(ia,n);return c.jsx(Bv,{as:jE,allowPinchZoom:!0,shards:[o.contentRef],children:c.jsx(xe.div,{"data-state":ud(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),Cr="DialogContent",Yv=v.forwardRef((e,t)=>{const n=Qv(Cr,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=At(Cr,e.__scopeDialog);return c.jsx(Eo,{present:r||s.open,children:s.modal?c.jsx(_E,{...o,ref:t}):c.jsx(AE,{...o,ref:t})})});Yv.displayName=Cr;var _E=v.forwardRef((e,t)=>{const n=At(Cr,e.__scopeDialog),r=v.useRef(null),o=Be(t,n.contentRef,r);return v.useEffect(()=>{const s=r.current;if(s)return NE(s)},[]),c.jsx(qv,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:ce(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:ce(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,a=i.button===0&&i.ctrlKey===!0;(i.button===2||a)&&s.preventDefault()}),onFocusOutside:ce(e.onFocusOutside,s=>s.preventDefault())})}),AE=v.forwardRef((e,t)=>{const n=At(Cr,e.__scopeDialog),r=v.useRef(!1),o=v.useRef(!1);return c.jsx(qv,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var i,a;(i=e.onCloseAutoFocus)==null||i.call(e,s),s.defaultPrevented||(r.current||(a=n.triggerRef.current)==null||a.focus(),s.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:s=>{var l,u;(l=e.onInteractOutside)==null||l.call(e,s),s.defaultPrevented||(r.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const i=s.target;((u=n.triggerRef.current)==null?void 0:u.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),qv=v.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:s,...i}=e,a=At(Cr,n),l=v.useRef(null),u=Be(t,l);return z2(),c.jsxs(c.Fragment,{children:[c.jsx(_v,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:s,children:c.jsx(Ra,{role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":ud(a.open),...i,ref:u,onDismiss:()=>a.onOpenChange(!1)})}),c.jsxs(c.Fragment,{children:[c.jsx(DE,{titleId:a.titleId}),c.jsx(LE,{contentRef:l,descriptionId:a.descriptionId})]})]})}),ld="DialogTitle",Xv=v.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=At(ld,n);return c.jsx(xe.h2,{id:o.titleId,...r,ref:t})});Xv.displayName=ld;var Zv="DialogDescription",Jv=v.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=At(Zv,n);return c.jsx(xe.p,{id:o.descriptionId,...r,ref:t})});Jv.displayName=Zv;var ey="DialogClose",ty=v.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=At(ey,n);return c.jsx(xe.button,{type:"button",...r,ref:t,onClick:ce(e.onClick,()=>o.onOpenChange(!1))})});ty.displayName=ey;function ud(e){return e?"open":"closed"}var ny="DialogTitleWarning",[Ck,ry]=Gw(ny,{contentName:Cr,titleName:ld,docsSlug:"dialog"}),DE=({titleId:e})=>{const t=ry(ny),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return v.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},ME="DialogDescriptionWarning",LE=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${ry(ME).contentName}}.`;return v.useEffect(()=>{var s;const o=(s=e.current)==null?void 0:s.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},IE=Hv,FE=Gv,oy=Kv,sy=Yv,iy=Xv,ay=Jv,$E=ty;const cd=IE,zE=FE,ly=v.forwardRef(({className:e,...t},n)=>c.jsx(oy,{ref:n,className:we("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));ly.displayName=oy.displayName;const $a=v.forwardRef(({className:e,children:t,...n},r)=>c.jsxs(zE,{children:[c.jsx(ly,{}),c.jsxs(sy,{ref:r,className:we("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...n,children:[t,c.jsxs($E,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity data-[state=open]:bg-accent data-[state=open]:text-muted-foreground hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none",children:[c.jsx(Wg,{className:"h-4 w-4"}),c.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));$a.displayName=sy.displayName;const za=({className:e,...t})=>c.jsx("div",{className:we("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});za.displayName="DialogHeader";const Ba=v.forwardRef(({className:e,...t},n)=>c.jsx(iy,{ref:n,className:we("text-lg font-semibold leading-none tracking-tight",e),...t}));Ba.displayName=iy.displayName;const BE=v.forwardRef(({className:e,...t},n)=>c.jsx(ay,{ref:n,className:we("text-sm text-muted-foreground",e),...t}));BE.displayName=ay.displayName;const UE=({open:e,onClose:t,onComplete:n,items:r})=>{const[o,s]=v.useState("method"),[i,a]=v.useState("0.00"),l=E=>((parseInt(E,10)||0)/100).toFixed(2),u=r.reduce((E,R)=>E+R.price*R.quantity,0),d=r.reduce((E,R)=>R.taxRate?E+R.price*R.quantity*(R.taxRate/100):E,0),p=u+d,y=E=>{a(R=>{const D=R.replace(".","").replace(/^0+/,"");return l(`${D}${E}`)})},f=()=>a("0.00"),b=()=>{a(E=>{const R=E.replace(".","").replace(/^0+/,""),D=R.length<=1?"0":R.slice(0,-1);return l(D)})},g=parseFloat(i),x=g-p,h=()=>{g>=p&&(n("cash",g),w())},m=()=>{n("credit"),w()},w=()=>{s("method"),a("0.00")},S=()=>{w(),t()},C=[1,5,10,20,50,100],N=E=>{a(l(Math.round(E*100).toString()))};return c.jsx(cd,{open:e,onOpenChange:S,children:c.jsxs($a,{className:"sm:max-w-md bg-card border-border",children:[c.jsx(za,{children:c.jsx(Ba,{className:"text-foreground text-lg font-extrabold",children:o==="method"?"Payment Method":"Cash Payment"})}),c.jsxs("div",{className:"rounded-xl bg-background border border-border px-4 py-3 text-center",children:[c.jsx("p",{className:"text-xs text-muted-foreground font-semibold",children:"Total Due"}),c.jsxs("p",{className:"text-3xl font-extrabold text-foreground font-mono",children:["$",p.toFixed(2)]})]}),o==="method"?c.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[c.jsxs("button",{onClick:()=>s("cash"),className:"flex flex-col items-center gap-2 rounded-xl bg-success/15 border border-success/30 p-6 hover:bg-success hover:text-success-foreground transition-all active:scale-95",children:[c.jsx(zg,{className:"h-10 w-10"}),c.jsx("span",{className:"text-sm font-bold",children:"Cash"})]}),c.jsxs("button",{onClick:m,className:"flex flex-col items-center gap-2 rounded-xl bg-primary/15 border border-primary/30 p-6 hover:bg-primary hover:text-primary-foreground transition-all active:scale-95",children:[c.jsx(Bg,{className:"h-10 w-10"}),c.jsx("span",{className:"text-sm font-bold",children:"Credit Card"})]})]}):c.jsxs("div",{className:"space-y-3",children:[c.jsxs("div",{className:"rounded-xl bg-background border border-border px-4 py-3 text-right",children:[c.jsx("p",{className:"text-xs text-muted-foreground font-semibold",children:"Cash Tendered"}),c.jsxs("p",{className:"text-3xl font-extrabold text-foreground font-mono",children:["$",i]})]}),c.jsxs("div",{className:`rounded-xl border px-4 py-2 text-center ${g>=p?"bg-success/15 border-success/30":"bg-destructive/10 border-destructive/20"}`,children:[c.jsx("p",{className:"text-xs font-semibold text-muted-foreground",children:"Change Due"}),c.jsxs("p",{className:`text-2xl font-extrabold font-mono ${g>=p?"text-success":"text-destructive"}`,children:["$",x>=0?x.toFixed(2):"โ"]})]}),c.jsx("div",{className:"grid grid-cols-3 gap-2",children:C.map(E=>c.jsxs("button",{onClick:()=>N(E),className:"rounded-lg bg-secondary border border-border py-2 text-sm font-bold text-foreground hover:bg-primary hover:text-primary-foreground active:scale-95 transition-all",children:["$",E]},E))}),c.jsxs("div",{className:"grid grid-cols-3 gap-2",children:[["7","8","9","4","5","6","1","2","3"].map(E=>c.jsx("button",{onClick:()=>y(E),className:"rounded-lg bg-background border border-border py-2.5 text-lg font-bold text-foreground hover:bg-secondary active:scale-95 transition-all",children:E},E)),c.jsx("button",{onClick:f,className:"rounded-lg bg-destructive/10 border border-destructive/20 py-2.5 text-sm font-bold text-destructive active:scale-95 transition-all",children:"CLR"}),c.jsx("button",{onClick:()=>y("0"),className:"rounded-lg bg-background border border-border py-2.5 text-lg font-bold text-foreground hover:bg-secondary active:scale-95 transition-all",children:"0"}),c.jsx("button",{onClick:b,className:"rounded-lg bg-background border border-border py-2.5 text-lg font-bold text-foreground hover:bg-secondary active:scale-95 transition-all flex items-center justify-center",children:c.jsx(Ug,{className:"h-5 w-5"})})]}),c.jsxs("div",{className:"grid grid-cols-2 gap-2",children:[c.jsx("button",{onClick:()=>s("method"),className:"rounded-xl bg-secondary py-3 text-sm font-bold text-secondary-foreground hover:bg-border transition-all",children:"Back"}),c.jsx("button",{onClick:h,disabled:g<p,className:"rounded-xl bg-success py-3 text-sm font-bold text-success-foreground shadow-md hover:opacity-90 disabled:opacity-40 disabled:cursor-not-allowed active:scale-[0.98] transition-all",children:"Complete Sale"})]})]})]})})},uy=v.forwardRef(({className:e,...t},n)=>c.jsx("div",{className:"relative w-full overflow-auto",children:c.jsx("table",{ref:n,className:we("w-full caption-bottom text-sm",e),...t})}));uy.displayName="Table";const cy=v.forwardRef(({className:e,...t},n)=>c.jsx("thead",{ref:n,className:we("[&_tr]:border-b",e),...t}));cy.displayName="TableHeader";const dy=v.forwardRef(({className:e,...t},n)=>c.jsx("tbody",{ref:n,className:we("[&_tr:last-child]:border-0",e),...t}));dy.displayName="TableBody";const fy=v.forwardRef(({className:e,...t},n)=>c.jsx("tfoot",{ref:n,className:we("border-t bg-muted/50 font-medium [&>tr]:last:border-b-0",e),...t}));fy.displayName="TableFooter";const Ti=v.forwardRef(({className:e,...t},n)=>c.jsx("tr",{ref:n,className:we("border-b transition-colors data-[state=selected]:bg-muted hover:bg-muted/50",e),...t}));Ti.displayName="TableRow";const sr=v.forwardRef(({className:e,...t},n)=>c.jsx("th",{ref:n,className:we("h-12 px-4 text-left align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0",e),...t}));sr.displayName="TableHead";const et=v.forwardRef(({className:e,...t},n)=>c.jsx("td",{ref:n,className:we("p-4 align-middle [&:has([role=checkbox])]:pr-0",e),...t}));et.displayName="TableCell";const WE=v.forwardRef(({className:e,...t},n)=>c.jsx("caption",{ref:n,className:we("mt-4 text-sm text-muted-foreground",e),...t}));WE.displayName="TableCaption";const Ep=["Taxable","Non-Taxable","Unleaded","Unleaded Plus","Diesel","Off Road Diesel","Oil","Hardware","Other"];function aa(e){const t=e.getFullYear(),n=`${e.getMonth()+1}`.padStart(2,"0"),r=`${e.getDate()}`.padStart(2,"0");return`${t}-${n}-${r}`}function Qu(e,t){const n=e.trim().toLowerCase();return n.includes("off road diesel")?"Off Road Diesel":n.includes("unleaded plus")?"Unleaded Plus":n.includes("unleaded")?"Unleaded":n.includes("diesel")?"Diesel":n.includes("oil")?"Oil":n.includes("hardware")?"Hardware":n.includes("taxable")?"Taxable":n.includes("non-tax")||n.includes("non tax")?"Non-Taxable":t?"Taxable":"Non-Taxable"}function HE(e){var i;const t=((i=e[0])==null?void 0:i.businessDate)??aa(new Date),n=new Map;for(const a of Ep)n.set(a,{category:a,cashSales:0,cashTax:0,creditSales:0,creditTax:0,totalSales:0,totalTax:0,grandTotal:0});for(const a of e)for(const l of a.items){const u=n.get(l.reportCategory)??{category:l.reportCategory,cashSales:0,cashTax:0,creditSales:0,creditTax:0,totalSales:0,totalTax:0,grandTotal:0};a.paymentMethod==="cash"?(u.cashSales+=l.lineTotal,u.cashTax+=l.taxAmount):(u.creditSales+=l.lineTotal,u.creditTax+=l.taxAmount),u.totalSales+=l.lineTotal,u.totalTax+=l.taxAmount,u.grandTotal+=l.lineTotal+l.taxAmount,n.set(u.category,u)}const r=Ep.map(a=>n.get(a)).filter(a=>a.totalSales>0||a.totalTax>0),o=e.filter(a=>a.paymentMethod==="cash").reduce((a,l)=>a+l.total,0),s=e.filter(a=>a.paymentMethod==="credit").reduce((a,l)=>a+l.total,0);return{businessDate:t,totalTransactions:e.length,totalSales:e.reduce((a,l)=>a+l.subtotal,0),totalTax:e.reduce((a,l)=>a+l.tax,0),cashTotal:o,creditTotal:s,categoryBreakdown:r}}const VE=({open:e,onClose:t,sales:n,onClearSales:r})=>{const o=HE(n),s=o.totalSales+o.totalTax;return c.jsx(cd,{open:e,onOpenChange:t,children:c.jsxs($a,{className:"max-h-[85vh] overflow-y-auto border-border bg-card sm:max-w-4xl",children:[c.jsxs(za,{children:[c.jsx(Ba,{className:"text-lg font-extrabold text-foreground",children:"End of Day Report"}),c.jsxs("p",{className:"text-sm text-muted-foreground",children:["Business date: ",o.businessDate]})]}),c.jsxs("div",{className:"grid grid-cols-3 gap-3",children:[c.jsxs("div",{className:"rounded-xl border border-border bg-background p-3 text-center",children:[c.jsx("p",{className:"text-xs font-semibold text-muted-foreground",children:"Grand Total"}),c.jsxs("p",{className:"font-mono text-xl font-extrabold text-foreground",children:["$",s.toFixed(2)]}),c.jsxs("p",{className:"text-xs text-muted-foreground",children:[o.totalTransactions," transactions"]})]}),c.jsxs("div",{className:"rounded-xl border border-success/20 bg-success/10 p-3 text-center",children:[c.jsxs("div",{className:"mb-1 flex items-center justify-center gap-1",children:[c.jsx(zg,{className:"h-4 w-4 text-success"}),c.jsx("p",{className:"text-xs font-semibold text-muted-foreground",children:"Cash"})]}),c.jsxs("p",{className:"font-mono text-xl font-extrabold text-foreground",children:["$",o.cashTotal.toFixed(2)]})]}),c.jsxs("div",{className:"rounded-xl border border-primary/20 bg-primary/10 p-3 text-center",children:[c.jsxs("div",{className:"mb-1 flex items-center justify-center gap-1",children:[c.jsx(Bg,{className:"h-4 w-4 text-primary"}),c.jsx("p",{className:"text-xs font-semibold text-muted-foreground",children:"Credit"})]}),c.jsxs("p",{className:"font-mono text-xl font-extrabold text-foreground",children:["$",o.creditTotal.toFixed(2)]})]})]}),c.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[c.jsxs("div",{className:"rounded-xl border border-border bg-background p-3 text-center",children:[c.jsx("p",{className:"text-xs font-semibold text-muted-foreground",children:"Pre-Tax Sales"}),c.jsxs("p",{className:"font-mono text-lg font-extrabold text-foreground",children:["$",o.totalSales.toFixed(2)]})]}),c.jsxs("div",{className:"rounded-xl border border-border bg-background p-3 text-center",children:[c.jsx("p",{className:"text-xs font-semibold text-muted-foreground",children:"Total Tax Collected"}),c.jsxs("p",{className:"font-mono text-lg font-extrabold text-foreground",children:["$",o.totalTax.toFixed(2)]})]})]}),o.categoryBreakdown.length>0?c.jsx("div",{className:"overflow-hidden rounded-xl border border-border",children:c.jsxs(uy,{children:[c.jsx(cy,{children:c.jsxs(Ti,{className:"bg-secondary/50",children:[c.jsx(sr,{className:"text-xs font-bold",children:"Category"}),c.jsx(sr,{className:"text-right text-xs font-bold",children:"Cash Sales"}),c.jsx(sr,{className:"text-right text-xs font-bold",children:"Cash Tax"}),c.jsx(sr,{className:"text-right text-xs font-bold",children:"Credit Sales"}),c.jsx(sr,{className:"text-right text-xs font-bold",children:"Credit Tax"}),c.jsx(sr,{className:"text-right text-xs font-bold",children:"Grand Total"})]})}),c.jsx(dy,{children:o.categoryBreakdown.map(i=>c.jsxs(Ti,{children:[c.jsx(et,{className:"text-sm font-semibold",children:i.category}),c.jsxs(et,{className:"text-right font-mono text-sm",children:["$",i.cashSales.toFixed(2)]}),c.jsxs(et,{className:"text-right font-mono text-sm",children:["$",i.cashTax.toFixed(2)]}),c.jsxs(et,{className:"text-right font-mono text-sm",children:["$",i.creditSales.toFixed(2)]}),c.jsxs(et,{className:"text-right font-mono text-sm",children:["$",i.creditTax.toFixed(2)]}),c.jsxs(et,{className:"text-right font-mono text-sm font-bold",children:["$",i.grandTotal.toFixed(2)]})]},i.category))}),c.jsx(fy,{children:c.jsxs(Ti,{children:[c.jsx(et,{className:"text-sm font-bold",children:"Total"}),c.jsxs(et,{className:"text-right font-mono text-sm font-bold",children:["$",o.categoryBreakdown.reduce((i,a)=>i+a.cashSales,0).toFixed(2)]}),c.jsxs(et,{className:"text-right font-mono text-sm font-bold",children:["$",o.categoryBreakdown.reduce((i,a)=>i+a.cashTax,0).toFixed(2)]}),c.jsxs(et,{className:"text-right font-mono text-sm font-bold",children:["$",o.categoryBreakdown.reduce((i,a)=>i+a.creditSales,0).toFixed(2)]}),c.jsxs(et,{className:"text-right font-mono text-sm font-bold",children:["$",o.categoryBreakdown.reduce((i,a)=>i+a.creditTax,0).toFixed(2)]}),c.jsxs(et,{className:"text-right font-mono text-sm font-bold",children:["$",s.toFixed(2)]})]})})]})}):c.jsx("div",{className:"py-8 text-center text-muted-foreground",children:c.jsx("p",{className:"text-sm",children:"No sales recorded today"})}),c.jsxs("div",{className:"grid grid-cols-2 gap-2 pt-2",children:[c.jsx("button",{onClick:t,className:"rounded-xl bg-secondary py-3 text-sm font-bold text-secondary-foreground transition-all hover:bg-border",children:"Close"}),n.length>0&&c.jsx("button",{onClick:async()=>{confirm("Clear all sales data for this business day?")&&(await r(),t())},className:"rounded-xl border border-destructive/20 bg-destructive/10 py-3 text-sm font-bold text-destructive transition-all hover:bg-destructive hover:text-destructive-foreground",children:"Clear & Start New Day"})]})]})})},Gu=[{id:"1",name:"Rice 1kg",price:28,category:"Pantry",emoji:"๐"},{id:"2",name:"Beans 1kg",price:35,category:"Pantry",emoji:"๐ซ"},{id:"3",name:"Sugar 1kg",price:32,category:"Pantry",emoji:"๐ฌ"},{id:"4",name:"Cooking Oil 1L",price:45,category:"Pantry",emoji:"๐ซ"},{id:"5",name:"Salt 1kg",price:15,category:"Pantry",emoji:"๐ง"},{id:"6",name:"Flour 1kg",price:22,category:"Pantry",emoji:"๐พ"},{id:"7",name:"Pasta 200g",price:12,category:"Pantry",emoji:"๐"},{id:"8",name:"Canned Tuna",price:25,category:"Pantry",emoji:"๐"},{id:"9",name:"Soda 600ml",price:18,category:"Drinks",emoji:"๐ฅค"},{id:"10",name:"Water 1L",price:12,category:"Drinks",emoji:"๐ง"},{id:"11",name:"Juice 1L",price:28,category:"Drinks",emoji:"๐ง"},{id:"12",name:"Coffee 200g",price:55,category:"Drinks",emoji:"โ"},{id:"13",name:"Milk 1L",price:26,category:"Dairy",emoji:"๐ฅ"},{id:"14",name:"Cheese 250g",price:45,category:"Dairy",emoji:"๐ง"},{id:"15",name:"Cream 250ml",price:28,category:"Dairy",emoji:"๐ถ"},{id:"16",name:"Yogurt",price:15,category:"Dairy",emoji:"๐ฅฃ"},{id:"17",name:"Bread Roll",price:3,category:"Bakery",emoji:"๐ฅ"},{id:"18",name:"Sweet Bread",price:8,category:"Bakery",emoji:"๐"},{id:"19",name:"Tortillas 1kg",price:22,category:"Bakery",emoji:"๐ซ"},{id:"20",name:"Tomatoes 1kg",price:30,category:"Produce",emoji:"๐
"},{id:"21",name:"Onions 1kg",price:25,category:"Produce",emoji:"๐ง
"},{id:"22",name:"Limes 1kg",price:35,category:"Produce",emoji:"๐"},{id:"23",name:"Bananas 1kg",price:20,category:"Produce",emoji:"๐"},{id:"24",name:"Potatoes 1kg",price:28,category:"Produce",emoji:"๐ฅ"},{id:"25",name:"Chicken 1kg",price:85,category:"Meat",emoji:"๐"},{id:"26",name:"Eggs 12ct",price:48,category:"Meat",emoji:"๐ฅ"},{id:"27",name:"Ham 250g",price:38,category:"Meat",emoji:"๐ฅฉ"},{id:"28",name:"Bar Soap",price:18,category:"Cleaning",emoji:"๐งผ"},{id:"29",name:"Bleach 1L",price:22,category:"Cleaning",emoji:"๐งด"},{id:"30",name:"Toilet Paper",price:15,category:"Cleaning",emoji:"๐งป"},{id:"31",name:"Detergent 1kg",price:42,category:"Cleaning",emoji:"๐ซง"}];function py(e,t=0){const n=Gu[t]||Gu[0],r=typeof e.taxable=="boolean"?e.taxable:!!e.taxRate;return{id:e.id||n.id||`product-${t+1}`,name:e.name||n.name||"Item",price:typeof e.price=="number"&&!Number.isNaN(e.price)?e.price:n.price||0,category:e.category||n.category||"General",emoji:e.emoji||n.emoji||"ITEM",imageUrl:e.imageUrl||n.imageUrl,taxable:r,taxRate:r?typeof e.taxRate=="number"&&!Number.isNaN(e.taxRate)?e.taxRate:0:void 0,reportCategory:e.reportCategory||"Non-Taxable"}}function Ku(){return Gu.map((e,t)=>py({...e,taxable:!1,reportCategory:"Non-Taxable"},t))}function QE(e){return["All",...Array.from(new Set(e.map(n=>n.category.trim()).filter(Boolean))).sort((n,r)=>n.localeCompare(r))]}async function GE(){try{const e=await pn("/catalog.php");if(!e.ok)return null;const t=await e.json();return t.products?t.products.map((n,r)=>py(n,r)):[]}catch(e){return console.error("Failed to load catalog",e),null}}async function KE(e){try{return(await pn("/catalog.php",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({products:e})})).ok}catch(t){return console.error("Failed to save catalog",t),!1}}async function kp(e){try{const t=await pn("/catalog.php",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({products:e})});if(t.ok)return{ok:!0};const n=await t.text();try{return{ok:!1,error:JSON.parse(n).error||`Catalog save failed (${t.status})`}}catch{return{ok:!1,error:n||`Catalog save failed (${t.status})`}}}catch(t){return console.error("Failed to save catalog",t),{ok:!1,error:t instanceof Error?t.message:"Catalog save failed"}}}async function YE(e){try{const t=new FormData;t.append("image",e);const n=await pn("/upload_image.php",{method:"POST",body:t}),r=await n.text();try{const o=JSON.parse(r);return n.ok?{ok:!0,imageUrl:o.imageUrl}:{ok:!1,error:o.error||`Image upload failed (${n.status})`}}catch{return{ok:!1,error:r||`Image upload failed (${n.status})`}}}catch(t){return console.error("Failed to upload image",t),{ok:!1,error:t instanceof Error?t.message:"Image upload failed"}}}function qE(e){return e.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"").slice(0,40)}const XE=({open:e,onClose:t,products:n,onSaved:r})=>{const[o,s]=v.useState(n),[i,a]=v.useState(""),[l,u]=v.useState(null);v.useEffect(()=>{s(n)},[n,e]);const d=(x,h,m)=>{s(w=>w.map(S=>{if(S.id!==x)return S;const C={...S,[h]:m};return h==="taxable"&&m===!1&&(C.taxRate=void 0),h==="taxable"&&m===!0&&C.taxRate==null&&(C.taxRate=0),C}))},p=()=>{const x=o.length+1;s(h=>[...h,{id:`custom-${x}`,name:`New Item ${x}`,price:0,category:"General",emoji:"ITEM",imageUrl:"",taxable:!1,reportCategory:"Non-Taxable"}])},y=x=>{s(h=>h.filter(m=>m.id!==x))},f=async()=>{const x=o.map((m,w)=>{var S;return{...m,id:qE(m.id||m.name||`product-${w+1}`),name:m.name.trim()||`Item ${w+1}`,category:m.category.trim()||"General",emoji:m.emoji.trim()||"ITEM",imageUrl:((S=m.imageUrl)==null?void 0:S.trim())||void 0,price:Number(m.price)||0,taxRate:m.taxable?Number(m.taxRate||0):void 0}}),h=await kp(x);a(h.ok?"Saved for all devices":h.error||"Save failed"),h.ok&&r(x)},b=async()=>{const x=Ku(),h=await kp(x);a(h.ok?"Reset to default catalog":h.error||"Reset failed"),h.ok&&(s(x),r(x))},g=async(x,h)=>{if(!h)return;u(x);const m=await YE(h);if(u(null),!m.ok||!m.imageUrl){a(m.error||"Image upload failed");return}d(x,"imageUrl",m.imageUrl),a("Image uploaded")};return c.jsx(cd,{open:e,onOpenChange:t,children:c.jsxs($a,{className:"max-h-[90vh] overflow-y-auto border-border bg-card sm:max-w-5xl",children:[c.jsxs(za,{children:[c.jsx(Ba,{className:"text-lg font-extrabold text-foreground",children:"Catalog Manager"}),c.jsx("p",{className:"text-sm text-muted-foreground",children:"Regular product buttons are saved on the server here."})]}),c.jsx("div",{className:"space-y-3",children:o.map(x=>c.jsxs("div",{className:"grid grid-cols-1 gap-2 rounded-xl border border-border bg-background p-3 md:grid-cols-7",children:[c.jsx("input",{value:x.name,onChange:h=>d(x.id,"name",h.target.value),className:"rounded-lg border border-border bg-card px-3 py-2 text-sm font-semibold text-foreground",placeholder:"Name"}),c.jsx("input",{value:x.category,onChange:h=>d(x.id,"category",h.target.value),className:"rounded-lg border border-border bg-card px-3 py-2 text-sm font-semibold text-foreground",placeholder:"Category"}),c.jsx("input",{type:"number",min:"0",step:"0.01",value:x.price,onChange:h=>d(x.id,"price",parseFloat(h.target.value||"0")),className:"rounded-lg border border-border bg-card px-3 py-2 text-sm font-semibold text-foreground",placeholder:"Price"}),c.jsx("input",{value:x.emoji,onChange:h=>d(x.id,"emoji",h.target.value),className:"rounded-lg border border-border bg-card px-3 py-2 text-sm font-semibold text-foreground",placeholder:"Button tag"}),c.jsxs("div",{className:"space-y-2 rounded-lg border border-dashed border-border bg-card p-2",children:[c.jsx("div",{className:"text-xs font-semibold text-muted-foreground",children:"Product Image"}),x.imageUrl?c.jsx("img",{src:x.imageUrl,alt:x.name,className:"h-16 w-16 rounded-lg border border-border object-cover"}):c.jsx("div",{className:"flex h-16 w-16 items-center justify-center rounded-lg border border-border bg-background text-[11px] font-bold text-muted-foreground",children:"No image"}),c.jsx("input",{type:"file",accept:"image/*",onChange:h=>{var m;return g(x.id,((m=h.target.files)==null?void 0:m[0])??null)},className:"text-xs text-muted-foreground"}),l===x.id&&c.jsx("div",{className:"text-[11px] font-semibold text-muted-foreground",children:"Uploading..."})]}),c.jsx("select",{value:x.reportCategory,onChange:h=>d(x.id,"reportCategory",h.target.value),className:"rounded-lg border border-border bg-card px-3 py-2 text-sm font-semibold text-foreground",children:Ov.map(h=>c.jsx("option",{value:h,children:h},h))}),c.jsxs("div",{className:"flex gap-2",children:[c.jsxs("select",{value:x.taxable?"taxable":"non-taxable",onChange:h=>d(x.id,"taxable",h.target.value==="taxable"),className:"flex-1 rounded-lg border border-border bg-card px-3 py-2 text-sm font-semibold text-foreground",children:[c.jsx("option",{value:"taxable",children:"Taxable"}),c.jsx("option",{value:"non-taxable",children:"Non-Taxable"})]}),c.jsx("input",{type:"number",min:"0",step:"0.01",disabled:!x.taxable,value:x.taxRate??"",onChange:h=>d(x.id,"taxRate",h.target.value===""?void 0:parseFloat(h.target.value)),className:"w-28 rounded-lg border border-border bg-card px-3 py-2 text-sm font-semibold text-foreground disabled:opacity-50",placeholder:"Tax %"}),c.jsx("button",{onClick:()=>y(x.id),className:"rounded-lg border border-destructive/20 bg-destructive/10 px-3 py-2 text-xs font-bold text-destructive",children:"Remove"})]})]},x.id))}),c.jsxs("div",{className:"flex items-center justify-between gap-2 pt-2",children:[c.jsx("div",{className:"text-xs font-semibold text-muted-foreground",children:i}),c.jsxs("div",{className:"flex gap-2",children:[c.jsx("button",{onClick:p,className:"rounded-lg bg-secondary px-4 py-2 text-sm font-bold text-secondary-foreground",children:"Add Product"}),c.jsx("button",{onClick:b,className:"rounded-lg border border-border bg-background px-4 py-2 text-sm font-bold text-foreground",children:"Reset Defaults"}),c.jsx("button",{onClick:f,className:"rounded-lg bg-primary px-4 py-2 text-sm font-bold text-primary-foreground",children:"Save Catalog"})]})]})]})})},Ss="pos-sales";function hy(e){const t=e.map(n=>({...n,timestamp:n.timestamp.toISOString()}));return JSON.stringify(t)}function dd(e){if(!e)return[];try{return JSON.parse(e).map(n=>({...n,timestamp:new Date(n.timestamp)}))}catch(t){return console.error("Failed to parse stored sales",t),[]}}function fd(){return typeof window<"u"&&typeof window.localStorage<"u"}function ZE(e=aa(new Date)){return fd()?dd(window.localStorage.getItem(Ss)).filter(n=>n.businessDate===e):[]}function JE(e){if(!fd())return;const t=dd(window.localStorage.getItem(Ss)),n=new Set(e.map(o=>o.businessDate)),r=t.filter(o=>!n.has(o.businessDate));window.localStorage.setItem(Ss,hy([...r,...e]))}function ek(e){if(!fd())return;const n=dd(window.localStorage.getItem(Ss)).filter(r=>r.businessDate!==e);window.localStorage.setItem(Ss,hy(n))}async function tk(e){try{const t=await pn(`/sales.php?date=${encodeURIComponent(e)}`);if(!t.ok)return null;const n=await t.json();return n.sales?n.sales.map(r=>({...r,timestamp:new Date(r.timestamp)})):[]}catch(t){return console.error("Failed to load sales from server",t),null}}async function nk(e){try{return(await pn("/sales.php",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({...e,timestamp:e.timestamp.toISOString()})})).ok}catch(t){return console.error("Failed to save sale to server",t),!1}}async function rk(e){try{return(await pn("/reset_day.php",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({businessDate:e})})).ok}catch(t){return console.error("Failed to clear sales on server",t),!1}}const qt=27,Dl=29,Le=10,Ne={INIT:[qt,64],BOLD_ON:[qt,69,1],BOLD_OFF:[qt,69,0],ALIGN_CENTER:[qt,97,1],ALIGN_LEFT:[qt,97,0],ALIGN_RIGHT:[qt,97,2],DOUBLE_HEIGHT_ON:[Dl,33,17],DOUBLE_HEIGHT_OFF:[Dl,33,0],CUT_PAPER:[Dl,86,66,3],DRAWER_KICK_PIN2:[qt,112,0,25,120],DRAWER_KICK_PIN5:[qt,112,1,25,120],FEED_LINES:e=>[qt,100,e]},ok=new TextEncoder;function Ve(e){return Array.from(ok.encode(e))}function Sn(e,t,n=42){const r=n-e.length-t.length;return e+" ".repeat(Math.max(1,r))+t}function Ml(e=42){return"-".repeat(e)}function sk(e){const t=[],n=(...o)=>t.push(...o);n(...Ne.INIT),n(...Ne.ALIGN_CENTER),n(...Ne.BOLD_ON),n(...Ne.DOUBLE_HEIGHT_ON),n(...Ve(e.storeName)),n(Le),n(...Ne.DOUBLE_HEIGHT_OFF),n(...Ne.BOLD_OFF),n(...Ve(e.timestamp.toLocaleDateString()+" "+e.timestamp.toLocaleTimeString())),n(Le),n(...Ne.ALIGN_LEFT),n(...Ve(Ml())),n(Le);for(const o of e.items){const s=o.price*o.quantity,i=o.quantity>1?`${o.name} x${o.quantity}`:o.name;n(...Ve(Sn(i,`$${s.toFixed(2)}`))),n(Le),o.taxRate&&o.taxAmount&&o.taxAmount>0&&(n(...Ve(Sn(` Tax ${o.taxRate}%`,`$${o.taxAmount.toFixed(2)}`))),n(Le))}n(...Ve(Ml())),n(Le),n(...Ve(Sn("Subtotal",`$${e.subtotal.toFixed(2)}`))),n(Le),e.tax>0&&(n(...Ve(Sn("Tax",`$${e.tax.toFixed(2)}`))),n(Le)),n(...Ne.BOLD_ON),n(...Ne.DOUBLE_HEIGHT_ON),n(...Ve(Sn("TOTAL",`$${e.total.toFixed(2)}`))),n(Le),n(...Ne.DOUBLE_HEIGHT_OFF),n(...Ne.BOLD_OFF),n(...Ve(Ml())),n(Le);const r=e.paymentMethod==="cash"?"Cash":"Credit Card";return n(...Ve(Sn("Payment",r))),n(Le),e.paymentMethod==="cash"&&e.amountTendered!==void 0&&(n(...Ve(Sn("Tendered",`$${e.amountTendered.toFixed(2)}`))),n(Le),e.changeDue!==void 0&&e.changeDue>0&&(n(...Ne.BOLD_ON),n(...Ve(Sn("Change",`$${e.changeDue.toFixed(2)}`))),n(Le),n(...Ne.BOLD_OFF))),n(Le),n(...Ne.ALIGN_CENTER),n(...Ve("Thank you!")),n(Le),n(...Ne.FEED_LINES(4)),n(...Ne.CUT_PAPER),t}let Fn=null,Gn=null;function my(){return"serial"in navigator}async function ik(){if(!my())throw new Error("WebSerial API is not supported in this browser. Please use Chrome or Edge.");try{return Fn=await navigator.serial.requestPort(),await Fn.open({baudRate:9600}),Gn=Fn.writable.getWriter(),!0}catch(e){return console.error("Failed to connect to printer:",e),Fn=null,Gn=null,!1}}async function ak(){try{Gn&&(Gn.releaseLock(),Gn=null),Fn&&(await Fn.close(),Fn=null)}catch(e){console.error("Error disconnecting printer:",e)}}function Ll(){return Fn!==null&&Gn!==null}async function gy(e){if(!Gn)throw new Error("Printer not connected");await Gn.write(e)}async function vy(){await gy(new Uint8Array(Ne.DRAWER_KICK_PIN2))}async function lk(e){const t=sk(e);await gy(new Uint8Array(t))}async function uk(e){await vy(),await lk(e)}let ck=1e3;function dk(e){return e.reportCategory?e.reportCategory:Qu(e.category,!!e.taxRate)}const fk=()=>{const e=aa(new Date),[t,n]=v.useState("All"),[r,o]=v.useState([]),[s,i]=v.useState(!1),[a,l]=v.useState(!1),[u,d]=v.useState(!1),[p,y]=v.useState([]),[f,b]=v.useState(Ku()),[g,x]=v.useState(!1),h=v.useMemo(()=>QE(f),[f]),m=v.useMemo(()=>t==="All"?f:f.filter(I=>I.category===t),[f,t]),w=v.useCallback(I=>{o(T=>T.find(k=>k.id===I.id)?T.map(k=>k.id===I.id?{...k,quantity:k.quantity+1}:k):[...T,{...I,quantity:1,taxRate:I.taxRate,reportCategory:dk(I),taxable:!!I.taxRate}])},[]),S=v.useCallback((I,T,O,k,P)=>{const A=`manual-${ck++}`,U=O?`${T} (T)`:T;o(z=>[...z,{id:A,name:U,price:I,emoji:O?"TAX":"NTX",quantity:1,taxRate:O?k:void 0,category:T,reportCategory:P??Qu(T,O),taxable:O}])},[]),C=v.useCallback((I,T)=>{o(O=>O.map(k=>k.id===I?{...k,quantity:k.quantity+T}:k).filter(k=>k.quantity>0))},[]),N=v.useCallback(I=>{o(T=>T.filter(O=>O.id!==I))},[]),E=v.useCallback(()=>o([]),[]),R=v.useCallback(()=>{r.length!==0&&i(!0)},[r]),D=v.useCallback(async()=>{if(Ll()){await ak(),x(!1),He.info("Printer disconnected");return}if(!my()){He.error("WebSerial not supported. Use Chrome or Edge.");return}const I=await ik();if(x(I),I){He.success("Printer connected");return}He.error("Could not connect to printer")},[]),L=v.useCallback(async()=>{if(!Ll()){He.error("Connect a printer first");return}try{await vy(),He.success("Drawer opened")}catch{He.error("Failed to open drawer")}},[]);v.useEffect(()=>{let I=!0;return(async()=>{const O=await GE();if(I){if(O&&O.length>0){b(O);return}b(Ku())}})(),()=>{I=!1}},[]),v.useEffect(()=>{let I=!0;return(async()=>{const k=await tk(e)??ZE(e);I&&y(k)})(),()=>{I=!1}},[e]),v.useEffect(()=>{JE(p)},[p]);const W=v.useCallback(async(I,T)=>{const O=r.reduce((X,ae)=>X+ae.price*ae.quantity,0),k=r.reduce((X,ae)=>ae.taxRate?X+ae.price*ae.quantity*(ae.taxRate/100):X,0),P=O+k,A=T?T-P:void 0,U=r.map(X=>{const ae=X.price*X.quantity,Dt=X.taxRate?ae*(X.taxRate/100):0;return{name:X.name,category:X.category||"Other",reportCategory:X.reportCategory||Qu(X.category||X.name,!!X.taxRate),price:X.price,quantity:X.quantity,taxable:!!(X.taxRate||X.taxable),taxRate:X.taxRate,taxAmount:Dt,lineTotal:ae}}),z=new Date,H={id:`sale-${Date.now()}`,items:U,subtotal:O,tax:k,total:P,paymentMethod:I,amountTendered:T,changeDue:A,timestamp:z,businessDate:aa(z)},Y=[...p,H];y(Y),i(!1),o([]);const he=await nk(H);if(Ll())try{const X={storeName:"My Store",items:U.map(ae=>({name:ae.name,quantity:ae.quantity,price:ae.price,taxRate:ae.taxRate,taxAmount:ae.taxAmount})),subtotal:O,tax:k,total:P,paymentMethod:I,amountTendered:T,changeDue:A!==void 0&&A>0?A:void 0,timestamp:z};await uk(X)}catch(X){console.error("Print error:",X),He.error("Failed to print receipt")}const Ce=I==="cash"?"Cash":"Credit Card",J=A!==void 0&&A>0?` | Change $${A.toFixed(2)}`:"",hn=he?"":" | saved locally";He.success(`Sale complete: ${Ce} $${P.toFixed(2)}${J}${hn}`,{duration:4e3})},[r,p]),$=v.useCallback(async()=>{const I=await rk(e);if(ek(e),y([]),I){He.success("Started a new business day");return}He.success("Started a new business day locally")},[e]),V=v.useCallback(I=>{b(I),t!=="All"&&!I.some(T=>T.category===t)&&n("All"),He.success("Catalog saved for all devices")},[t]),F=v.useCallback(async(I,T)=>{const O=f.findIndex(z=>z.id===I),k=f.findIndex(z=>z.id===T);if(O<0||k<0||O===k)return;const P=[...f],[A]=P.splice(O,1);if(P.splice(k,0,A),b(P),!await KE(P)){He.error("Could not save button order");return}He.success("Product button order saved")},[f]);return c.jsxs("div",{className:"flex h-screen flex-col bg-background",children:[c.jsxs("header",{className:"flex items-center gap-3 border-b border-border bg-card px-4 py-3 shadow-sm",children:[c.jsx(qb,{className:"h-7 w-7 text-primary"}),c.jsx("h1",{className:"text-xl font-extrabold tracking-tight text-foreground",children:"My Store"}),c.jsxs("div",{className:"ml-auto flex items-center gap-2",children:[c.jsxs("button",{onClick:()=>d(!0),className:"flex items-center gap-1.5 rounded-lg border border-border bg-secondary px-3 py-1.5 text-sm font-bold text-foreground transition-all hover:bg-primary hover:text-primary-foreground",children:[c.jsx(Kb,{className:"h-4 w-4"}),c.jsx("span",{children:"Catalog"})]}),c.jsxs("button",{onClick:D,className:`flex items-center gap-1.5 rounded-lg border px-3 py-1.5 text-sm font-bold transition-all ${g?"border-success/30 bg-success/15 text-success hover:bg-success hover:text-success-foreground":"border-border bg-secondary text-foreground hover:bg-primary hover:text-primary-foreground"}`,children:[g?c.jsx(Qb,{className:"h-4 w-4"}):c.jsx(Gb,{className:"h-4 w-4"}),c.jsx("span",{className:"hidden sm:inline",children:g?"Printer Connected":"Connect Printer"})]}),g&&c.jsx("button",{onClick:L,className:"flex items-center gap-1.5 rounded-lg border border-border bg-secondary px-3 py-1.5 text-sm font-bold text-foreground transition-all hover:bg-primary hover:text-primary-foreground",children:c.jsx("span",{children:"Open Drawer"})}),c.jsxs("button",{onClick:()=>l(!0),className:"flex items-center gap-1.5 rounded-lg border border-border bg-secondary px-3 py-1.5 text-sm font-bold text-foreground transition-all hover:bg-primary hover:text-primary-foreground",children:[c.jsx(Wb,{className:"h-4 w-4"}),c.jsx("span",{children:"Report"}),p.length>0&&c.jsx("span",{className:"rounded-full bg-primary px-1.5 py-0.5 text-[10px] font-bold text-primary-foreground",children:p.length})]}),c.jsx("span",{className:"text-sm text-muted-foreground",children:"Point of Sale"})]})]}),c.jsxs("div",{className:"flex flex-1 overflow-hidden",children:[c.jsx("div",{className:"hidden w-[260px] flex-shrink-0 overflow-y-auto p-3 md:block lg:w-[280px]",children:c.jsx(_2,{onAddItem:S})}),c.jsxs("div",{className:"flex flex-1 flex-col gap-3 overflow-y-auto p-4",children:[c.jsx(S2,{categories:h,selected:t,onSelect:n}),c.jsx(C2,{products:m,onAdd:w,onReorder:F})]}),c.jsx("div",{className:"hidden w-[340px] flex-shrink-0 p-3 pl-0 md:flex lg:w-[380px]",children:c.jsx(E2,{items:r,onUpdateQty:C,onRemove:N,onCheckout:R,onClear:E})})]}),r.length>0&&c.jsx("div",{className:"border-t border-border bg-card px-4 py-3 md:hidden",children:c.jsxs("button",{onClick:R,className:"w-full rounded-xl bg-success py-3 text-base font-bold text-success-foreground shadow-md active:scale-[0.98]",children:["Checkout | ",r.reduce((I,T)=>I+T.quantity,0)," items"," | $",r.reduce((I,T)=>I+T.price*T.quantity,0).toFixed(2)]})}),c.jsx(UE,{open:s,onClose:()=>i(!1),onComplete:W,items:r}),c.jsx(VE,{open:a,onClose:()=>l(!1),sales:p,onClearSales:$}),c.jsx(XE,{open:u,onClose:()=>d(!1),products:f,onSaved:V})]})},pk=()=>{const e=cg();return v.useEffect(()=>{console.error("404 Error: User attempted to access non-existent route:",e.pathname)},[e.pathname]),c.jsx("div",{className:"flex min-h-screen items-center justify-center bg-muted",children:c.jsxs("div",{className:"text-center",children:[c.jsx("h1",{className:"mb-4 text-4xl font-bold",children:"404"}),c.jsx("p",{className:"mb-4 text-xl text-muted-foreground",children:"Oops! Page not found"}),c.jsx("a",{href:"/",className:"text-primary underline hover:text-primary/90",children:"Return to Home"})]})})},hk=new b1,mk=()=>c.jsx(C1,{client:hk,children:c.jsxs(w2,{children:[c.jsx(AS,{}),c.jsx(zw,{}),c.jsx(lw,{basename:"/NAOPOS/dist/",children:c.jsxs(sw,{children:[c.jsx(Au,{path:"/",element:c.jsx(fk,{})}),c.jsx(Au,{path:"*",element:c.jsx(pk,{})})]})})]})});Km(document.getElementById("root")).render(c.jsx(mk,{}));